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

Re: style switcher

From: Bert Bos <bert@w3.org>
Date: Fri, 6 Jun 2003 16:10:54 +0200
Message-ID: <16096.41198.396406.615508@lanalana.inria.fr>
To: www-style@w3.org

David Woolley writes:
> > Also, questions about user agents don't belong on this list;
> As formulated, the question was off topic, but one can reformulates it
> as:
> CSS2 provides for alternative style sheets but provides no guidance
> on how user agents should handle them, with the result that users cannot
> rely on anything more than selecting from a menu on each individual page.

Alternative style sheets have been in the CSS spec since many years,
but it hasn't been very long that they have become usable at all. I
think that's why not much thought has gone into the user interface
aspects of it yet.

It is probably not the task of the CSS spec to define how the UI
should work. There may be room for some suggestions and best
practices. But I think that we have to let browsers try out different
things first and see what works best. Things like tabbed browsing, the
link navigation bar, right-click, F11-full screen, etc. are some
things that didn't come out of any specification either.

> I would propose that the reccommendation should:
> 1) encourage user agents to provide mechanisms to allow users to apply
>   alternate style sheet selections to whole classes of URLs, starting
>   with URLs with a common domain name (not necessarily fully qualified).
>   A powerful user agent might then be expected to consider other parts
>   of the URL and other information available to it.

Some things that might be worth trying out:

  - bookmarks that store not only the URL, but also the title of the
    selected style sheet (and any cookies, if the user has them turned

  - ditto for the history list

  - using the style sheet titles in the history list, try to use a
    style sheet of the same name when browing another page on the same
    site (or sub-site, based on longest URL prefix)

  - on a page with OBJECTs that have style sheets themselves (like
    embedded SVG or HTML pages), use style sheets of the same name for
    the page and for its embeddings, recursively, if possible.

  - ditto for frame sets.

User style sheets are another under-utilized feature. They exist in
most browsers now, but there is usually only room for one style sheet.
There could be user style sheets per URL or site, just as many
browsers now offer cookie policies and Javascript policies per URL or

> 2) propose a registry of alternative style sheet names, that would allow,
>    for example, a name to be registered for style sheets optimised for
>    a particular sort of colour blindness (there is more than one) or
>    those requiring large fonts (possibly really meaning little variation
>    in font size), or even more frivolous ones in the way that various
>    X Window managers can mimic other operating environments.

The problem with that is that the list will be language-dependent. The
titles are meant for human consumption, not for computers. (Browsers
are only expected to look for two things: whether the title is empty
and whether two titles are the same.)

Maybe this is more something to express in the media attribute, using
the Media Queries syntax.

On the other hand, being consistent is usually a good idea, and if
certain names come to be associated with certain kinds of functions,
then a designer should generally follow the established practice.

  Bert Bos                                ( W 3 C ) http://www.w3.org/
  http://www.w3.org/people/bos/                              W3C/ERCIM
  bert@w3.org                             2004 Rt des Lucioles / BP 93
  +33 (0)4 92 38 76 92            06902 Sophia Antipolis Cedex, France
Received on Friday, 6 June 2003 10:10:55 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:07 UTC