W3C home > Mailing lists > Public > www-style@w3.org > October 2010

Re: @font-face and slow downloading

From: Yuzo Fujishima <yuzo@google.com>
Date: Thu, 21 Oct 2010 14:11:43 +0900
Message-ID: <AANLkTimRS8364B2Ao6323-G=BaAyCWrgtScDt30R2wTC@mail.gmail.com>
To: David Singer <singer@apple.com>
Cc: www-style list <www-style@w3.org>
On Thu, Oct 21, 2010 at 9:48 AM, David Singer <singer@apple.com> wrote:

> I think that the choice of whether to show (a) nothing (b) a substitute
> font, when the correct one is not (yet) available is very much a user and  
> UA
> question.  I don't think timeouts or author indications have much place,  
> or
> will be much help.  How do they know whether I am an impatient SOB who  
> wants
> something readable soon, or a precision SOB who only wants things to look
> right?


I agree.



> However, I am struggling with the question of whether a temporary
> substitute font is different from a fallback font.  Maybe it isn't --  
> after
> all, if the UA picks the temporary subset 'for the time being' and actual
> download takes longer than the user keeps the page open, it's not material
> that it wasn't a permanent fallback.


I think one goal here would be to keep the number of font changes to the
minimum.
That's actually the rationale behind my proposal earlier in this thread.

  16         <style>
  17         @font-face {
  18             font-family: samplefont;
  19             src: url([URL]), local([LocalFont]);
  20         }
  21         </style>
  22         <span style="font-family: samplefont, [OtherFont]">Hello</span>
  23
  24         If [LocalFont] is a valid local font, it is used as the
fallback.
  25         Otherwise, [OtherFont] is used.

If downloading [URL] takes long and eventually failed, [localFont] is used.

If we use [localFont] for the tentative drawing, the user will not see any
changes at the moment the downloading failed.

If we use [OtherFont] for the tentative drawing, text is first rendered
in [OtherFont] and then in [localFont] at the moment of download failure.

Yuzo




> Maybe we should insist on a fallback list including at least one 'normal'
> font, for downloadable faces, and say that the UA 'may' show a fallback
> before the downloaded font is available, but if it does, must re-render
> using the downloaded font when it becomes available?

> David Singer
> Multimedia and Software Standards, Apple Inc.
Received on Thursday, 21 October 2010 05:12:44 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:33 GMT