Re: @page margin boxes and text-decoration

Bjoern Hoehrmann wrote:
> * Michael Day wrote:
>> In this example, will the text be underlined:
>>
>> @page {
>>     text-decoration: underline;
>>     @top { content: "Hello, world!" }
>> }
>>
>> The text-decoration property is not inherited, but when applied to 
>> blocks it does result in the decoration being applied to all the 
>> children of the block.
> 
> I am unsure where the confusion arises from, according to the draft the
> text-decoration declaration sets the initial value of the property in
> the margin boxes, so, as I understand that, this would essentially be
> the same as
> 
>   @page { @top {
>     text-decoration: underline;
>     content: "Hello, world!"
>   } }
> 
> See <http://www.w3.org/TR/css3-page/#page-properties>.

Please refer to the latest Editor's Draft, as there have been many
fixes and clarifications to the spec since its last official publication.

http://dev.w3.org/csswg/css3-page/#page-properties

The new draft explicitly uses the normal inheritance mechanism to
propagate values from @page to @margin-box.

Wrt text-decoration

http://www.w3.org/TR/CSS21/text.html#decoration

CSS2.1 says that "for all other elements, the decorations are propagated
to an anonymous inline box that wraps all the in-flow inline children of
the element, and to any block-level in-flow descendants". It looks like
we'll need to specify in css3-page that @margin-boxes are to be considered
descendants of the @page box.

~fantasai

Received on Monday, 19 January 2009 21:30:55 UTC