adobe-type-tools / afdko

Adobe Font Development Kit for OpenType
https://adobe-type-tools.github.io/afdko/
Other
1.06k stars 167 forks source link

[otfstemhist] cannot specify glyphs via GID #1699

Closed frankrolf closed 1 year ago

frankrolf commented 1 year ago

I have a Thai font for which I’d like to analyze stem information. The Thai glyph names look like this:

koKai-thai
khoKhai-thai
khoKhuat-thai
khoKhwai-thai
khoKhon-thai
khoRakhang-thai

etc.

Since I cannot specify those dashed glyph names with the -g option (#1698), I am resorting to GIDs. According to otfstemhist -h, -g is the option for this. koKai-thai is at GID 52, so I do

otfstemhist -g 52,53,54 my_font.ufo

WARNING: glyph ID <52> from glyph selection list option is not in font. <xxx Traditional-Regular>.
WARNING: glyph ID <53> from glyph selection list option is not in font. <xxx Traditional-Regular>.
WARNING: glyph ID <54> from glyph selection list option is not in font. <xxx Traditional-Regular>.
ERROR: Selected glyph list is empty for font <xxx Traditional-Regular>.

even when trying otfstemhist -g 0,1,2 my_font.ufo, I get the same output.

I think getting glyphs via GID from a UFO might have never been implemented – it also does not work for psstemhist.

frankrolf commented 1 year ago

ha! https://github.com/adobe-type-tools/afdko/issues/1680