msdf-atlas-gen icon indicating copy to clipboard operation
msdf-atlas-gen copied to clipboard

How do I output all glyphs, but with the "unicode" field included in the JSON where appropriate?

Open oviano opened this issue 1 year ago • 1 comments

Loving the whole system by the way, been using this for years.

I have been using a CharSet.txt consisting of basically 0x0000 -> 0x10ffff.

I realised though that this misses out glyph index 0, which is ".notdef".

So I thought, ok, I should generate using GlyphSet.txt. However, although this seems to work, in that it outputs the glyphs in the range, I noticed the entries in the JSON now don't have the "unicode" field.

So how can I get it to output all glyphs in a font (surely a common requirement?) but include their unicodes, or say, zero, or some undefined value if they don't have a unicode value (such as .notdef amongst some others)?

oviano avatar Nov 08 '23 18:11 oviano

I recently added an -allglyphs option but it still doesn't provide Unicode values because the mapping between glyphs and Unicode characters is a bit more complex, but I will try to find a solution at some point in the future (currently I don't have much time for this project unfortunately).

Chlumsky avatar Mar 03 '24 23:03 Chlumsky