- From: Håkon Wium Lie <howcome@opera.com>
- Date: Thu, 23 Jan 2014 02:06:51 +0100
- To: liam@w3.org
- Cc: Alan Stearns <stearns@adobe.com>, "CSS WWW Style \(www-style\@w3.org\)" <www-style@w3.org>
Liam R E Quin wrote:
> > For me, the separation of style from
> > structure one of the foundations CSS stands on. Probably THE
> > foundation. So I don't think we should break that priciple, even if it
> > seems convenient to do so.
>
> How does this square with, for example, putting two h1 elements in a
> document so you can use element() to take one out as a running header?
Generally, I'd use strings to set running headers. Like this:
@page { @top-center { content: string(header) }}
h1 { string-set: header }
In which case there is no need to duplicate content.
If the running header has structure (e.g., if there's an <em>
element inside the header), one has two option:
- duplicate the content and use the element() function.
http://books.spec.whatwg.org/#running-elements
I don't think this is tag abuse, but being able to clone the document
may still appeal to some. A solution for this is sketched here, in the
copy() function:
http://books.spec.whatwg.org/#cloning,-fixing-and-clearing-elements-in-named-areas
This is still early work.
> Isn't the answer here templates + regions?
What would the code look like?
-h&kon
Håkon Wium Lie CTO °þe®ª
howcome@opera.com http://people.opera.com/howcome
Received on Thursday, 23 January 2014 01:07:25 UTC