Re: [css-font-loading] load, check and testing for character coverage

Hi Tab,

You wrote:

> I have not so far heard *any* justification for why calling .check()
> with a font that *does not exist* is something that an author would
> want to do on purpose[…]

But earlier in the thread, John provided you with justification. You wrote:

>> The third case is that the search for matching font faces returns
>> nothing, indicating that some of your sample characters can't be
>> rendered by *any* of the fonts in the list. This is an error
>> condition; either you misspelled your font names, or you're planning
>> on using some characters that nothing can render. Either way, we
>> definitely shouldn't return "true" (using that font string won't
>> render like you expected), and probably shouldn't return "false"
>> either (.load() won't do anything). This is why, near the end of the
>> f2f, I suggested throwing in this case instead.

And John replied:

> It's not correct to say that it's an "error". Fontlists may or may not
> cover the range of characters used. Look at the localization links at
> the bottom of the Facebook landing page (www.facebook.com) for which
> the fontlist is always 'arial, helvetica, lucida grande, sans-serif'.
> For some of the items in the list, system font fallback will occur.
> That's not an "error", that's the nature of fontlists in CSS.
>
> The check() method is there simply to allow users to determine whether
> all fonts that might need to be loaded have actually been loaded[…]

I find John's example to be a pretty compelling one.


Ted

Received on Friday, 1 April 2016 20:30:22 UTC