Re: Revised SVG stuff

2022-01-19 Thread Werner LEMBERG
>> OK. If necessary, please modify the code! I think the code spoty >> in question is the right place to avoid auto-hinting for OT-SVG >> glyphs. > > Umm, if I change `cff_slot_load` and `TT_Load_Glyph` so that they > return errors if an SVG table is found but a glyph isn't, then how > am I

Re: Revised SVG stuff

2022-01-18 Thread Moazin K
> > > Instead, it'll resort to whatever type of glyph is found. That's > > the current behavior of cff_slot_load and TT_Load_Glyph. > > OK. If necessary, please modify the code! I think the code spoty in > question is the right place to avoid auto-hinting for OT-SVG glyphs. > Umm, if I change

Re: Revised SVG stuff

2022-01-18 Thread Werner LEMBERG
>> If I understand this correctly it means that a test for the SVG >> table is not sufficient. Instead, you have to actually do the call >> to `driver->clazz->load_glyph`, and if this fails, FreeType should >> try to load a bitmap font, and if this fails, it should proceed >> with auto-hinting

Re: Revised SVG stuff

2022-01-17 Thread Moazin K
Hi Werner, If I understand this correctly it means that a test for the SVG table > is not sufficient. Instead, you have to actually do the call to > `driver->clazz->load_glyph`, and if this fails, FreeType should try to > load a bitmap font, and if this fails, it should proceed with >

Re: Revised SVG stuff

2022-01-16 Thread Werner LEMBERG
>> > I'm not sure how to add a check that can prevent hinting to be >> > run for OT-SVG glyphs. Whether or not a glyph index has a >> > corresponding SVG glyph in the table is determined later on >> > inside cff_slot_load or TT_Load_Glyph. Any ideas on how to >> > prevent autohinting from being

Re: Revised SVG stuff

2022-01-15 Thread Moazin K
Hi Werner, > > The reason why the autohinting code seems to get triggered for that > > font is because `ttface->num_locations` is 1 > > The actual value is 321, the number of normal (i.e., non-SVG) glyphs > in the TrueType font. > Yea, sorry, that's correct. > > for this font while it's 0 for

Re: Revised SVG stuff

2022-01-15 Thread Werner LEMBERG
> The reason why the autohinting code seems to get triggered for that > font is because `ttface->num_locations` is 1 The actual value is 321, the number of normal (i.e., non-SVG) glyphs in the TrueType font. > for this font while it's 0 for all other fonts that I had in my test > collection.

Re: Revised SVG stuff

2022-01-15 Thread Moazin K
Hi Werner, I just got some time to quickly check this bug. The reason why the autohinting code seems to get triggered for that font is because `ttface->num_locations` is 1 for this font while it's 0 for all other fonts that I had in my test collection. This check happens in FT_Load_Glyph in