Re: [css3-fonts] "font-feature-settings: none" shorthand?

On Fri, May 31, 2013 at 1:17 AM, John Daggett <jdaggett@mozilla.com> wrote:

>
> Glenn Adams wrote:
>
> > > > My interpretation of that is "ideological fascism". In any case,
> > > > I'm not proposing something that can't be expressed already. I'm
> > > > just proposing a shorthand. It is irrelevant if the shorthand
> > > > makes it easier for an author to abuse himself.
> > >
> > > Um, discussions of fascism aside I don't think what you're describing
> > > is any sort of improvement over:
> > >
> > > font-variant: none;
> > > font-feature-settings: normal;
> > >
> > > This is pretty dang close to what you've described as the use case.
> >
> > Not really.
> >
> > Let's say for script S, the following features are enabled by default:
> >
> > 'ccmp'
> > 'liga'
> > 'loca'
> > 'kern'
> > 'mark'
> > 'mkmk'
> >
> > Now I could specify:
> >
> > font-feature-settings:
> > 'ccmp' off,
> > 'liga' off,
> > 'loca' off,
> > 'kern' off,
> > 'mark' off,
> > 'mkmk' off;
> >
> > that is, if I happen to know that the implementation enables these
> > by default and that the font I'm using uses these, or I could
> > specify:
> >
> >   font-feature-settings: none;
> >
> > or, if you prefer,
> >
> >   font-feature-settings: off;
> >
> > or, if you prefer a wildcard:
> >
> >   font-feature-settings: * off;
> >
> > In any case, this is not what you get by:
> >
> >   font-variant: none; font-feature-settings: normal;
>
> Of those features you've listed, I think only ligatures and kerning
> would be default features that an author would disable to achieve an
> "all features off" state:
>
>   font-variant: none;
>   font-kerning: none;
>   font-feature-settings: normal;
>
> That's a much more natural expression of "all features off".
>
> I think the problem here is that you're equating an author's wish to
> disable typographic features as meaning literally "turn off the
> OpenType layout engine".  I don't think they are the same, hence I
> don't think a 'none' property value or wildcard notation serves a real
> use case.
>

Let me ask a question, does font-feature-settings: normal mean the same as
enumerating every feature tag and specifying 'off'? If it does not, then
there is a use case for adding a none value.

I don't know what you mean by OpenType *layout* engine. This feature
effects OpenType GSUB/GPOS processing. The effect of specifying
font-feature-settings: none should be the same as turning of GSUB/GPOS
processing, or at least rendering void the effects of that processing.


>
> > Frankly, this is a very straightforward syntactic shorthand, easily
> > implementable (if one supports font-feature-settings at all).
>
> No doubt it's easy to implement, but the question is whether this

would do more harm than good.
>

The issue of harm is nonsense and irrelevant. The purpose of these features
as stated is "low-level control". You can't have your cake and eat it too.
The proposed shorthand isn't something that isn't already present in this
feature, however, it has the added benefit that the author does not have to
know the set of features being turned off. If there were an API in the Font
interfaces that allowed JS code to query all the features enabled by
default, then this wouldn't be as useful. But there is no such interface.
So as it is, the author would have to guess which are enabled and then
enumerate them all. Having this shorthand means they don't have to guess
and get it wrong (and thus not get the desired results - no GSUB/GPOS
features enabled).

As for the notion of "harm", I've already heard quite a few negative
comments about this property in the WK community, particularly about it
violating the traditional separation of Web content from platform specific
details. Since this feature is clearly OpenType bound, it violates that
separation.

Personally, I prefer keeping the feature, but I'm trying to make it more
useful by giving authors the fine grained control they wish.




>
> Cheers,
>
> John Daggett
>
>

Received on Friday, 31 May 2013 15:23:47 UTC