Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Should fix-vf-meta set a flag value for the "regular" values to set ELIDABLE_AXIS_VALUE_NAME? #111

Closed
thundernixon opened this issue Jan 18, 2019 · 4 comments

Comments

@thundernixon
Copy link
Contributor

As I understand it, the Flags value of and entry in the AxisValue fields of the STAT table specify which instances have names that can be left out of composed font names.

I'm unclear on this, but based on what I can tell from the (MS OT STAT Flags spec](https://docs.microsoft.com/en-us/typography/opentype/spec/stat#flags), it seems that for an AxisValue like "Regular," the flags should be set to 2 rather than 0, as a current process of fontmake + fix-vf-meta will result in.

The spec says of the ELIDABLE_AXIS_VALUE_NAME value:

If set, it indicates that the axis value represents the “normal” value for the axis and may be omitted when composing name strings.

This is different from the elidedFallbackNameID, which I didn't initially realize. Whereas the 2 of the elidedFallbackNameID refers to nameID 2, the 2 in the Flags value would just state an axis value can be left out of composed names. I'm not sure how vital this is, however, as MS Word already does leave the "Regular" name off of composed font names.

Here's a current Regular entry:

<AxisValue index="1" Format="1">
    <AxisIndex value="0"/>
    <Flags value="0"/>
    <!-- Regular -->
    <ValueNameID value="259"/>
    <Value value="400.0"/>
</AxisValue>

Here's what I suspect it should be (line 3 changed):

<AxisValue index="1" Format="1">
    <AxisIndex value="0"/>
    <Flags value="2"/>
    <!-- Regular -->
    <ValueNameID value="259"/>
    <Value value="400.0"/>
</AxisValue>

I'm posting this because I've been looking into this value, and I think it could be a spot where we could slightly improve the meta fixer. However, I have uncertainty on whether I'm reading the spec in a completely correct way, so if I am misunderstanding the Flags entry, we shouldn't change this.

@thundernixon
Copy link
Contributor Author

thundernixon commented Jan 18, 2019

Here's a particular example that seems to indicate that Flags should be set as I suggested above:

image

example source

@m4rc1e
Copy link
Collaborator

m4rc1e commented Jan 18, 2019

Good find. I'll look into this on Monday.

@davelab6
Copy link
Member

davelab6 commented Jan 19, 2019 via email

@m4rc1e
Copy link
Collaborator

m4rc1e commented Aug 23, 2020

This has been fixed in #237

@m4rc1e m4rc1e closed this as completed Aug 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants