W3C home > Mailing lists > Public > www-html@w3.org > November 1999

The "title" attribute of "style" elements

From: Ian Hickson <py8ieh@bath.ac.uk>
Date: Thu, 4 Nov 1999 19:11:52 +0000 (GMT)
To: www-html@w3.org
cc: www-html-editor@w3.org, Dave Raggett <dsr@w3.org>, lehors@w3.org, ij@w3.org
Message-ID: <Pine.GSO.4.04.9911041902020.21507-100000@mary.bath.ac.uk>

Would it be a valid (if 'progressive') interpretation of the spec to
treat the "title" attribute of the "style" element in much the same
way as the "title" attribute of the "link" element is treated when
used with stylesheets?

I would like to propose that this be explicitly specified in the new
HTML 4.01 specification, so that alternate stylesheets can be included
without having to make them external to HTML documents.

For example:

 <style type="text/css">
    /* persistent stylesheet */
 </style>

 <style type="text/css" title="a">
    /* preferred stylesheet (alternative called "a") */
 </style>

 <style type="text/css" title="b">
    /* alternative stylesheet (first part of alternative called "b") */
 </style>

 <style type="text/css" title="b">
    /* alternative stylesheet (second part of alternative called "b") */
 </style>

[Note that this is not 100% backwards compatible, since in HTML 4.0
browsers all the style elements, even those with title attributes,
will get used, whereas if using this proposal only the first will. I
suggest that this is a very minor detail since very few documents ever
include more than one style element anyway, let alone style elements
with title attributes.]

Cheers,
-- 
Ian Hickson
"So far, people have shown a reasonable amount of sense in evaluating
souls (whether they are properly priced)."
  -- Nick Gibbins; Author of http://totl.net/Soul/, 1999-10-05
Received on Thursday, 4 November 1999 14:11:57 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:15:40 GMT