Re: Testsuite flags

On Tue, Aug 23, 2016 at 10:17 PM, Gérard Talbot <www-style@gtalbot.org> wrote:
> Le 2016-08-18 02:15, fantasai a écrit :
>>
>> On 08/17/2016 09:48 PM, Geoffrey Sneddon wrote:
>>>
>>>
>
>>> I'd like to drop font, and vastly reduce the number of tests that
>>> require fonts to be installed by just relying on @font-face more (I hope
>>> we've reached a point where we can rely on it now!). Obviously we can't
>>> completely eliminate having to install fonts, but we can make it rare.
>>
>>
>> I think we can, indeed, do that. If a UA doesn't support @font-face,
>> then it can just assume that any test that includes @font-face and
>> isn't testing @font-face requires special font installation.
>> We should document that maybe. :)
>
>
>
>
> Regarding font flag
> - - - - - - - - - -
>
> I am for dropping the font flag and use @font-face, but...
>
> How do you propose that we should use the @font-face then? With or without
> woff files? I ask because .woff files and .woff2 files may not be rendered
> the same way across browsers... How well do we know if woff files are
> rendered the same across browsers and platforms?

Given they're just handed off to the platform layer the rendering
shouldn't be an issue (and we can likely use our current TTF files
anyway), and I don't expect this to be an issue.

> Other questions.
>
> Shouldn't we always use src: local() to avoid, prevent downloading and
> loading processes?
>
> If the font file to be downloaded and installed (.otf or .ttf and/or .woff
> or .woff2)'s filesize is big (say > 50Kb), can this affect automation of
> test results? Eg mplus-1p-regular.woff filesize is greater than 700Kb and it
> is currently being used in 468 tests right now.

It shouldn't affect automation any more than any @font-face test does.
The size shouldn't really be an issue given (excluding MS whose
systems I know little about) in the test systems everything is being
served from localhost and then the latency of the request dominates
the time taken.

We *could* use local() *but* it has the potential of ending up with
people using the wrong version of the font face and hence getting
bogus results for the tests. One advantage of using @font-face is we
have a far better guarantee as to the right font being used for the
test.

> Let's say I copy and paste the mplus-1p-regular.woff and the
> mplus-1p-regular.ttf files in a /support folder. Then what would be the best
> recommendable coding practice for testing and test authors here?
>
>  @font-face
>    {
>      font-family: "mplus-1p-regular";
>      src: url("support/mplus-1p-regular.woff") format("woff");
>      /* filesize: 803300 bytes (784.5 KBytes) */
>    }
>
> or
>
>  @font-face
>    {
>      font-family: "mplus-1p-regular";
>      src: local(M+1p) ,
>      url(support/mplus-1p-regular.ttf) format("opentype") ,
>      url("support/mplus-1p-regular.woff") format("woff");
>    }
>
> or something else?
>
> I am convinced we need some clear, explicit guidelines on how to use
> @font-face.

I think we need agreement as to whether we want local or not, and what
font formats we want to require (which probably depends on browser
support; we probably should be happy with TTF/OTF/WOFF, but not
WOFF2). We probably want to limit the number of alternate font formats
used as there's little advantage to giving many as it makes it
plausible that the different formats end up out of sync or otherwise
wrong.

/gsnedders

Received on Monday, 29 August 2016 17:32:35 UTC