W3C home > Mailing lists > Public > www-style@w3.org > June 1997

Re: CSS and presentational markup

From: Todd Fahrner <fahrner@pobox.com>
Date: Fri, 6 Jun 1997 10:38:17 -0700
Message-Id: <v03102805afbdf57b1813@[206.86.219.22]>
To: Chris Lilley <Chris.Lilley@sophia.inria.fr>, www-style@w3.org
At 4:49 PM +0200 6/6/1997, Chris Lilley wrote:

> http://www.w3.org/TR/REC-CSS1-961217.html#the-cascade
>
>   " The UA may choose to honor other stylistic HTML attributes, for
>     example 'ALIGN'. If so, these attributes are translated to the
>     corresponding CSS rules with specificity equal to 1. The rules are
>     assumed to be at the start of the author style sheet and may be
>     overridden by subsequent style sheet rules. In a transition phase,
>     this policy will make it easier for stylistic attributes to coexist
>     with style sheets. "
>
> So whether you can over-ride a particular piece of markup depends on
> it's specificity.

As I read this, all stylistic attributes on HTML elements (as opposed to
inline STYLE calls) should always be overridden by author stylesheets, or
by user stylesheets where "!important" is declared.

> > More troubling, IE4b1 and NS4b5 each have unique sets of
> > presentational elements/attributes that CSS can override. NS4, for
> > example, will ignore <font size=+1> on an element if CSS specifies a
> > fixed size, while IE4 will honor the markup.
>
>
> Fine, notice the "may choose to"

No - the UA honors the markup over the author-stylesheet (which has greater
specificity because it's later in the cascade).

> >  There's no apparent
> > rhyme or reason. I haven't done an exhaustive survey, but it appears
> > that NS4b5 will override presentational markup more often than IE4b1
> > will.
> >
> > I think CSS should always be able to override all presentational
> > markup and attributes,
>
> It can, by including rules of greater specificity.

But the betas are not playing by the rules now. Are you saying authors
should have to declare "!important" to override a garden-variety <font>
tag? That will munge "!important" declarations in user stylesheets -
something not to be undertaken lightly.

> > including positioning achieved by means of
> > tables.
>
> perhaps you could give an example here. I know what you mean by
> "positioning achieved by means of tables" but I don't see how one could
> easily get rid of the effect of the table such that the presentation
> is as clean as if the table was not there.

Neither do I - yet. Let's say I'm doing margins with empty table cells,
with pixel-widths specified (i know, i know - the horror). Could you wrap
all the table apparatus in a <span> and set its display to "none"? Then
style/position the content with CSS-P? OK, so that's invalid HTML. Or let
the table render and simply override with CSS-P?, ignoring the "parent"
table element?

Many, many authors will care how their documents are rendered in NS 3.0
until CSS browsers achieve better than 80% penetration. I'm exploring
transitional strategies.

__________________
Todd Fahrner
mailto:fahrner@pobox.com
http://www.verso.com/
Received on Friday, 6 June 1997 13:38:25 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:53:50 GMT