Do not scale openTypeOS2WeightClass with other font info#5
Do not scale openTypeOS2WeightClass with other font info#5ryanbugden merged 3 commits intoryanbugden:mainfrom
Conversation
|
Good catch, thanks Stephen! I'm now questioning the following. What do you think? I think these work together to describe italic angle, correct? So we probably don't need to scale them. Angle, not units Recommended pixels per em maybe shouldn't change as long as an em represents the same design. Probably don't want to scale hinting tolerances/thresholds by default. Could lead to unexpected results. Any others we can ditch? |
|
Hey Ryan, thanks! Good points on most of those – I think you’re right that anything to do with slant angles should remain untouched, along with the As for ps hinting, I think we should not scale Blue Scale, as that is tied to font sizes in use (and indeed, that is not currently in the list). However, I believe we should scale Blue Fuzz and Blue Shift, because those are tied to the UPM granularity and internal font measurements. If Blue Shift is set to 4 units to suppress “serif cups” at 1000UPM, then the font is scaled up 4x to 4000UPM, the Blue Shift now needs to be 20 units to suppress those same serif cup details. If Blue Fuzz is set to 1 to give some wiggle room for snapping points to alignment zones, it should scale up with the UPM to preserve that relative wiggle room, as outlines scale. https://glyphsapp.com/learn/hinting-postscript-autohinting Looking at the list, I don’t see anything else needing changes. |
|
Okay @ryanbugden, I formatted the list for a bit more clarity, and then I removed items that I agree should be removed. See new commits for details. Cheers! |
|
Amazing, thank you very much for this PR @arrowtype ! |
First, this extension is super nicely done – thank you, Ryan! So much is done so well, here. I love the option to scale by cap-height, etc.
This PR fixes one small glitch I’ve encountered: the current extension scales the
openTypeOS2WeightClass, which it probably shouldn’t, as scaling a font shouldn’t affect its overall design.Example: currently, a font with
openTypeOS2WeightClassof 900, if scaled up from a UPM of 1000 to 4000, will get a new Weight Class value of 3600. This is out of spec, and will fail to build if run through FontMake, due to ufoLib2’s _validate_weight_class validator.Todo:
I need to test this before declaring it definitely works. But, the code is simple enough, and I think it will.Okay, yeah, testing it, it seems to fix the problem.