samsa icon indicating copy to clipboard operation
samsa copied to clipboard

[web app] Are there metrics labels available?

Open arrowtype opened this issue 2 years ago • 3 comments

Looking at a font in Samsa, I see that one of the font metrics(?) plunges way down around wght=200, and I’m not sure why, or what that value might be:

https://github.com/Lorp/samsa/assets/45946693/12e83349-51f2-4def-b7cf-945d248b703d

Is there a way to see a label for that within the app?

arrowtype avatar May 29 '23 22:05 arrowtype

Oh, I think I found it!

image

Looks like it might be stro (strikeout offset) within the mvar table.

I’ll dig a little further to see if I’ve set that with a silly mistake, somewhere.

arrowtype avatar May 29 '23 22:05 arrowtype

The OT Spec relates stro to OS/2.yStrikeoutPosition:

'stro' strikeout offset OS/2.yStrikeoutPosition

So, after looking into the font slightly further, I’m wondering if Samsa is being inaccurate here.

If I use the FontTools Instancer to instance the variable font at wght=200 vs wght=750 (opsz=72 in both), then inspect with TTX, the OS/2.yStrikeoutPosition is different but pretty similar:

  • <yStrikeoutPosition value="633"/> for wght=200
  • <yStrikeoutPosition value="615"/> for wght=750

Here’s a variable font that exhibits the issue (it has a limited/trial glyphset, so I can share it here, and folks are welcome to use it for testing purposes / inspecting internal font data:): AT-NameSansVariable.Trial.ttf.zip

arrowtype avatar May 29 '23 22:05 arrowtype

Thanks for the report. I didn’t complete MVAR handling to my satisfaction, so I don’t think it’s reliable for now. I’ll take a look soon.

Lorp avatar May 30 '23 13:05 Lorp