mirror of
https://github.com/ryanoasis/nerd-fonts.git
synced 2024-12-19 20:12:52 +02:00
07a23bda90
[why] Some fonts might have a non-standard (i.e. broken) weight naming scheme: They put a blank or a dash between the modifier and the weight, for example "Extra Bold" or "Demi-Condensed", when they mean "ExtraBold" resp "DemiCondensed". The former happens with CartographCF, the later with IBM3270. [how] Automatically allow a dash between modifier and weight, which comes up as CamelCase boundary. Insert an optional dash (r'-?') into such boundaries. For the further lookup we need to remove the dash in the found keyword, if there is any, to get back to standard naming. This might break if the font name ends in a modifier. So we can not really distinguish Font Name Extra Bold Italic => Font Name - ExtraBold Italic => Font Name Extra - Bold Italic The known modifiers are 'Demi', 'Ultra', 'Semi', 'Extra'. It is possible but unlikely that a font name ends in one of these. For example "Modern Ultra - Bold". [note] The question arises if we should not parse the PSname instead of the Fullname; and stick to the dash there as boundary. The problem might be prepatched fonts with broken naming, that would be parsed completely wrong then. So maybe the current approach is still the best, with the caveat given above (fontnames ending in a modifier). [note 2] Funny enough the variable allow_regex_token was not used at all :-> Some leftover? Anyhow we use it now. [note 3] We can still not remove the special handling for IBM3270, because the font initially looks like a PSname and this is parsed as such, which breaks the name in the incorrect place: PSname template = "Name-StylesWeights" Fullname of 3270 = "IBM 3270 Semi-Condensed" Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de> |
||
---|---|---|
.. | ||
data | ||
lib | ||
name_parser | ||
archive-font-patcher.sh | ||
archive-fonts.sh | ||
docker-entrypoint.sh | ||
fetch-archives.sh | ||
fpfix.py | ||
generate-casks.sh | ||
generate-css.sh | ||
generate-extraglyphs.py | ||
generate-font-image-previews.sh | ||
generate-fontconfig.sh | ||
generate-glyph-info-from-set.py | ||
generate-original-source.py | ||
generate-sample-set.sh | ||
generate-webfonts.sh | ||
get-font-names-from-json.sh | ||
gotta-patch-em-all-font-patcher!.sh | ||
optimize-original-source.sh | ||
README.md | ||
release.sh | ||
standardize-and-complete-readmes.sh | ||
test-fonts.sh | ||
test-powerlines.sh | ||
tests.sh | ||
update-all-contributors-website.py | ||
version-bump.sh |
Contents
Note: Usually you need to call the scripts in this directory while actually being in this directory (i.e. pwd = .../nerd-fonts/bin/scripts
).
archive-font-patcher.sh
: Archives the font patcher script and subscripts and the required source glyph files [1]archive-fonts.sh
: Creates the release zip file of one or more font(s) from existingpatched-fonts/
content [1]data/
: Contains plain text files used to generate the CSS and cheat sheet filesdata/sankey/
: Contains instructions on how to create the sankey glyph table manually [3]docker-entrypoint.sh
: This script is packaged into the docker container and is usually used to start patching [2]fetch-archives.sh
: Script to download the release zip archives [6]fpfix.py
: Can be used to set isFixedPitch property in a font [x]generate-casks.sh
: Generates cask files for fonts from data inarchives/
[6]generate-css.sh
: Generates the Nerd Fonts CCS, which can be used to access the glyphs on a web page, and the Cheat Sheet [1]generate-extraglyphs.py:
Generatesextraglyphs.sfd
from Hack Regular [4]generate-fontconfig.sh
: Generates font configuration to enable use of unpatched fonts with Symbols Only Nerd Font [1]generate-font-image-previews.sh
: Generates the preview images fornerdfonts.com
(i.e. gh-pages) [3]generate-glyph-info-from-set.py
: Generate thei_xxx.sh
file from a glyph source (font) file, if the glyphs are named correctly [4]generate-original-source.py
: Generateoriginal-source.otf
from single glyph svgs. [5]generate-sample-set.sh
: Generate one patched font file from each source font (for manual checks) [4]generate-webfonts.sh
: Generate woff and woff2 font files from the SymbolsOnly font (for the gh-pages) [1]get-font-names-from-json.sh
: Helper to setup the CI font matrix fromdata/fonts.json
[1]gotta-patch-em-all-font-patcher!.sh
: Patch one or more fonts 'complete' with and withoutmono
and with and withoutwindows compat
[1]Hack/
: Special additional post patching script for Hack, invoked via Hack'sconfig.cfg
(not used when self-patching)lib/
: See its own READMEname_parser/
: Suite to set up sane Family and SubFamily names, used byfont-patcher
(on demand)optimize-original-source.sh
: Run all icons insrc/svgs
through inkscape to simplify (remove nodes and edges) [5]release.sh
: Rough process how a release is created, not used (see.github/workflows/release.yml
)standardize-and-complete-readmes.sh
: Used bygotta-patch-em-all-font-patcher!.sh
test-fonts.sh
: Print-to-debug all glyphs we patch in [4]test-powerlines.sh
: Print-to-debug powerline examples [4]tests.sh
: Create some font usage gif movie? [x]update-all-contributors-website.py
: Update the contributors page onnerdfonts.com
(i.e. gh-pages) [7]version-bump.sh
: Change version number in all scripts on a new release [1]
[1] Used by CI (github release workflow) [2] Used by CI (github docker-release workflow) [3] To be used manually (sigh) [4] To be used manually [5] Used by CI (github packsvgs workflow) [6] Used by CI (github casks workflow) [7] Used by CI (github contributors workflow) [x] Probably not used by anything