W3C home > Mailing lists > Public > www-style@w3.org > January 2012

Re: Adding a font to the current stack (smarter fallbacks)

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Wed, 11 Jan 2012 09:41:51 -0800
Message-ID: <CAAWBYDDc+nCPZGfNMQpBDtwiRyTNWwUJEYj1+DzcNZYtDrMV5Q@mail.gmail.com>
To: Matthew Wilcox <elvendil@gmail.com>
Cc: www-style@w3.org
On Wed, Jan 11, 2012 at 2:45 AM, Matthew Wilcox <elvendil@gmail.com> wrote:
> Can we get a way (or is there already a proposed way) to add a font on top
> of an existing font stack?
> It is tedious and a maintenance issue to have to re-declare entire font
> stacks throughout a stylesheet just because I want to use a different font
> on one particular element of the page.
> e.g.,
> html { font : 125%/1.3 MelbourneRegular, "Helvetica Neue", Helvetica, Arial,
> sans-serif; }
> then later on I need to change a font for one particular paragraph and have
> to write:
> #special {  font-family : LeagueGothicRegular, MelbourneRegular, "Helvetica
> Neue", Helvetica, Arial, sans-serif;  }
> because if I were to write
> #special { font-family: LeagueGothicRegular; }
> It replaces the entire font stack instead of just attempting to load that
> font, and if failing falling back to the inherited font-stack.

This is a common problem for *all* list-valued properties in CSS;
right now, they're always atomic, and you must re-specify the entire
list if you want to change one part of it.

We'd like to fix it, but no one's figured out how to do so yet.
Suggestions welcome.  ^_^

Received on Wednesday, 11 January 2012 17:42:40 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:38:54 UTC