-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Vietnamese glyphs #137
base: main
Are you sure you want to change the base?
Commits on Sep 26, 2024
-
generate: allow to specify where to place diacritics
Various scripts have diacritics on positions other than the top of base characters. This commit adds support for the (optional) `placement` key in diacritic.json, allowing diacritics to be placed in any of the four positions: above, below, to the left, and to the right of the glyph. The default when not specified is "above". The placement respects the spacing specified by the `diacriticSpace` key in characters.json.
Configuration menu - View commit details
-
Copy full SHA for 925016f - Browse repository at this point
Copy the full SHA 925016fView commit details -
generate: add support for multiple diacritics on a single glyph
This allows to define a glyph with multiple diacritics attached. Currently overlaps are not handled (spacing is currently shared for all of them), meaning stacking diacritics in the same direction is not possible.
Configuration menu - View commit details
-
Copy full SHA for e909d6f - Browse repository at this point
Copy the full SHA e909d6fView commit details -
metadata: add various missing glyphs for Vietnamese
This adds various missing glyphs for Vietnamese. Note that some characters require multiple diacritics in different positions. There is a hack in diacritics.json to force monocraft.py to include many glyphs in the generation step. For example, the glyph "LATIN SMALL LETTER A WITH CIRCUMFLEX AND DOT BELOW" contain two diacritics `circumflex` and `dot_below`. generate_diacritics.py parses this as containing one diacritic: `circumflex_and_dot_below`, which it will not find in diacritics.json without this hack, and thus the glyph will not be generated. For a proper fix, the logic to determine which diacritics should be considered (lines 37-38, generate_diacritics.py) should be fixed to consult the list in characters.json instead.
Configuration menu - View commit details
-
Copy full SHA for fea89b4 - Browse repository at this point
Copy the full SHA fea89b4View commit details -
generate: add support for offsetting the diacritic
This commit adds support for two optional keys in diacritics.json: offsetX and offsetY. This allows the glyph to be shifted relative to the base position.
Configuration menu - View commit details
-
Copy full SHA for d6836df - Browse repository at this point
Copy the full SHA d6836dfView commit details -
generate: raise glyph ascent height
Some Vietnamese glyphs are very tall with their diacritics, which causes the top of them to sometimes be cut off in some programs. This raises the font ascent by 1 pixel size to accomodate those glyphs. As a side effect, however, this also messes with font sizing in a lot of programs.
Configuration menu - View commit details
-
Copy full SHA for 4c6706d - Browse repository at this point
Copy the full SHA 4c6706dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6cb8acb - Browse repository at this point
Copy the full SHA 6cb8acbView commit details -
glyph: change horn characters to be identical to Minecraft
The original variant looks better in text, but is different from the font in-game.
Configuration menu - View commit details
-
Copy full SHA for 26c7b8e - Browse repository at this point
Copy the full SHA 26c7b8eView commit details -
diacritic: offset diacritics to be identical to Minecraft
The original variant looks better in text, but is different from the font in-game.
Configuration menu - View commit details
-
Copy full SHA for a66d7ff - Browse repository at this point
Copy the full SHA a66d7ffView commit details -
generate: bump ascent height for very taaaaall Vietnamese glyphs
The last size bump did not take into account capital letters.
Configuration menu - View commit details
-
Copy full SHA for d00b996 - Browse repository at this point
Copy the full SHA d00b996View commit details -
Configuration menu - View commit details
-
Copy full SHA for 93a8382 - Browse repository at this point
Copy the full SHA 93a8382View commit details -
Configuration menu - View commit details
-
Copy full SHA for d447d65 - Browse repository at this point
Copy the full SHA d447d65View commit details