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
[cssom-view] Return real values for colorDepth and pixelDepth (closes #993) #994
Conversation
@zcorpan PTAL |
f06c3d1
to
2209385
Compare
c30c2d9
to
ae3ace8
Compare
Thank you for the comments @dbaron. I have applied them apart from the example one: do you have recommendations for a better, less misleading, example? In practices, I would be surprised if the non-comforming implementations also implement the css color gamut which hopefully makes the example not insane in practice but I would be happy to put something else in the spec :) |
While that example itself is fine because such implementations wouldn't match the p3 media query, people might start from that code and modify it to do other things. Would the high-gamut devices report 48? If so, maybe it's better to test >= 48? |
ae3ace8
to
7ec160a
Compare
cssom-view/Overview.bs
Outdated
output device, it should return the closest estimation such as, for example, the | ||
number of bits used by the frame buffer sent to the display or any internal | ||
representation that would be the closest to the value the output device would | ||
use. The user agent must return the same value for these attributes and the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same value seems wrong. The color media query is per component, whereas here is all components together. There's also this complication:
If different color components are represented by different number of bits, the smallest number is used.
I suppose an integer-divide by 3 should give the same value as the color media query?
7ec160a
to
e026386
Compare
@zcorpan, I've rephrased. WDYT? |
Looks good to me. |
Final review from @dbaron would be nice. |
Fixes #993