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

The computed value of fill-opacity and stroke-opacity should never be a percentage #402

Closed
jarek-foksa opened this issue Apr 1, 2018 · 2 comments

Comments

@jarek-foksa
Copy link

Currently the spec allows the computed value of fill-opacity and stroke-opacity to be either a number or a percentage.

This doesn't seem to be useful and it's inconsistent with the definition of "opacity" in CSS Color Module Level 4.

@jarek-foksa jarek-foksa changed the title The computed value of fill-opacity stroke-opacity should never be a percentage The computed value of fill-opacity and stroke-opacity should never be a percentage Apr 1, 2018
@longsonr
Copy link

longsonr commented Apr 1, 2018

The general rule for computed values is that the representation that uses the smallest number of characters wins. Firefox obeys that rule and only outputs numbers.

@AmeliaBR
Copy link
Contributor

AmeliaBR commented Apr 1, 2018

Agreed, the computed value should always be a number. The current Editor's draft of CSS Color 4 uses the following wording:

Computed value: the specified value converted to a number, clamped to the range [0,1]

That is clearer than the WD text, and much better than the SVG text, which allows two different representations of equal values.

@dstorey dstorey closed this as completed in 2ce2900 May 2, 2018
dstorey added a commit that referenced this issue May 2, 2018
Fix #402 Use CCS Colour L4 definition for computed value of *-opacity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants