W3C home > Mailing lists > Public > www-style@w3.org > May 2014

Re: [css-font-loading] feedback

From: Rik Cabanier <cabanier@gmail.com>
Date: Wed, 28 May 2014 13:34:33 -0700
Message-ID: <CAGN7qDDiOPabEOE0gVdg1eTVcMs4VZkN07mtOTbwzxiPxAB15Q@mail.gmail.com>
To: Anne van Kesteren <annevk@annevk.nl>
Cc: "www-style@w3.org" <www-style@w3.org>, Domenic Denicola <domenic@domenicdenicola.com>
On Mon, May 26, 2014 at 6:51 AM, Anne van Kesteren <annevk@annevk.nl> wrote:

> Context: http://dev.w3.org/csswg/css-font-loading/
> ready() doesn't seem different from .loaded in how it's used. So we
> should make it a property with a getter.
> Should FontFaceSource be on the CSS global instead? CSS.fonts rather
> than document.fonts in a document environment and self.fonts in a
> worker environment.
> In the FontFace constructor you set status to "loading" at some point,
> but it's not clear from which task or microtask this is done. How can
> this be observed?
> You say "reject with a NetworkError" but you don't define
> NetworkError. Maybe you mean a DOMException whose name is
> "NetworkError"? Same for exception/error names mentioned elsewhere.
> You need to use the [Exposed] attribute to make sure your interfaces
> are actually available in workers. See e.g. URL or Encoding for
> examples.

Is there anything you can actually do today with a font in a worker? It
seems like this should be put at-risk immediately  :-)

The spec doesn't mention anything about CORS or fetching. Should it not
reference or at least mention it?
You can construct a 'FontFace' with random data. Wouldn't that be
dangerous? Also, passing invalid font data should fail somehow but your
algorithm doesn't cover that.
Received on Wednesday, 28 May 2014 20:35:01 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:43 UTC