Closed anthonyc-r closed 2 years ago
Cheers, I've removed the excessive whitespace and log. I've also added a check if GSScaleFactor is unset and thus scale equals 0.
I think the code is OK now. I am still unsure wether we need this change. When somebody manually changes the scaling factor she could as well switch off the font hinting by setting the other environment value to 33, which also is the default value. Maybe we should document this better?
Setting this to '17' appears to disable font hinting completely, perhaps a better patch would just set hinting to 17 if GSScaleFactor is set to anything other than 1, and GSFontHinting is not explicitly set. I see what you mean about being able to just explicitly set this, however I think that it shouldn't be possible to 'break' rendering by just setting scaling alone...
I don't know how difficult a change it would be, but perhaps respecting the advancements list (in GSShowGlyphsWithAdvances) would also allow for font hinting and scaling to be set together?
I've updated my commit to still allow for font hinting to be set via GSFontHinting.
I really like the new code. Thank you for the patch.
…isplay issues
This commit disables font hinting in the cairo backend if GSScaleFactor is not 1. It fixes an issue I posted under libs-gui here: https://github.com/gnustep/libs-gui/issues/134.