- From: Dean Jackson <dino@apple.com>
- Date: Mon, 21 Mar 2016 14:34:39 -0700
- To: Rik Cabanier <cabanier@gmail.com>
- Cc: www-style list <www-style@w3.org>
- Message-Id: <1A630926-F3DD-4130-A0FC-AC14E485396B@apple.com>
> On Mar 21, 2016, at 2:19 PM, Rik Cabanier <cabanier@gmail.com> wrote: > > > > - media queries to detect different screens so you can special case content > > Yes. > > > - be able to specify out-of-range colors > > Out of what range? color() will allow you to specify colors in something other than the sRGB space, which is your only option at the moment. > > I'm unsure if it's a good idea to allow the profile right in the color definition. > > For my own experience, PDF allows this but it's a very problematic workflow; mainly because things get complicated really fast. > We now go out of our way to avoid creating content that uses this feature. For instance, Illustrator and Photoshop make you choose a single profile and just create colors in that space (regardless of what you see in the UI). InDesign still supports this but you have to go deep in the advanced settings to turn it on. I'm not sure there is a better workflow for the Web. The other option would be to request a colorspace for the entire document and have media queries that isolate sections of the styling if the browser supports that, and then the typical rgb function would use 0-1 values in the colorspace. But the developer is probably going to want to do that based on whether the device supports wider gamut, so it would cause multiple nesting. I don't want to make this too complicated. I doubt that people are going to want to specify a huge number of colors by hand that are outside sRGB, in the near future at least. It's more likely going to be something like this: :root { --my-color: rgb(255, 0, 0); } @media (color-gamut: p3) { :root { --my-color: color(p3, 100%, 0%, 0%); } } Then var(--my-color) will be the brightest red on the display. Dean
Received on Monday, 21 March 2016 21:35:09 UTC