W3C home > Mailing lists > Public > www-style@w3.org > February 2013

RE: Media feature based on parent width instead of viewport/device width

From: François REMY <francois.remy.dev@outlook.com>
Date: Sat, 9 Feb 2013 15:38:25 +0100
Message-ID: <DUB404-EAS23981455A7568FE70C75703A5040@phx.gbl>
To: "'Mike Gossmann'" <mike@c572.ca>, <www-style@w3.org>
± I found this thread while looking to see if an idea I wanted to propose was
± already in the works. This proposal is very close, so I'm tacking my
± suggestions onto it, as I think it addresses the problem of loops in the layout
± (infinite or otherwise).

Sorry for late response. As you probably guessed, this solution isn't acceptable either, and that's why you didn't get any response to this message until now. Since I've got a few free time today, I'm going to write down the reasons why this solution doesn't do the trick.

The solution won't work because it makes the assumption that the layout of previous element has been computed already when the matching of CSS rules is performed on an element. In reality, the matching phase is performed completely upfront, and the layout isn't done on an element-per-element basis but one time per rendering, when the matching and cascading phases are done.

Changing this is not possible for many reason, including performance ones, but also because it would make it impossible to perform the matching, the cascading and the page layout in parallel without a lot of synchronization code, effectively making it impracticable.

Don't hesitate to ask for further details if needed,
François
Received on Saturday, 9 February 2013 14:39:03 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:05 GMT