Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SVG: Support for fill-opacity and stroke-opacity #1371

Closed
pbregener opened this issue Jun 1, 2021 · 1 comment
Closed

SVG: Support for fill-opacity and stroke-opacity #1371

pbregener opened this issue Jun 1, 2021 · 1 comment
Labels
bug Existing features not working as expected
Milestone

Comments

@pbregener
Copy link
Contributor

The old cairo-based weasyprint supported fill-opacity and stroke-opacity.
The new cairo-less version only seems to support opacity so far.

Do you have plans to bring this functionality back?
I have tons of automatically generated SVGs that use those attributes.

Simple example:

rect.svg:

<svg width="100" height="100">
  <rect x="10" y="10" width="80" height="80"
    style="fill:red;fill-opacity:0.3;stroke-width:10;stroke:black;stroke-opacity:0.2"/>
</svg>

and test.html

<html>
<body>
<img src="rect.svg" style="width:100%;">
</body>
</html>
@liZe liZe closed this as completed in c0c9879 Jun 2, 2021
@liZe liZe added the bug Existing features not working as expected label Jun 3, 2021
@liZe liZe added this to the 53.0 milestone Jun 3, 2021
@pbregener
Copy link
Contributor Author

Great job on the "proper" fix!
I can confirm that it works, and I can also confirm that it fixes some other opacity-related issues that I hadn't been able to reproduce and report, yet 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Existing features not working as expected
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants