mirror of
https://github.com/ryanoasis/nerd-fonts.git
synced 2024-09-19 09:51:48 +02:00
font-patcher: Fix windows Mono family names with --makegroups
[why] Without --makegroups the font family is "Name NFM", but with it enabled we get "Name NF Mono". [how] Mimic the old short-naming also for the groups. This feels a bit strange, why do we need to specify the names three times for `inject_suffix()`, slightly different. At some point this should probably be unified. def inject_suffix(self, fullname, fontname, family): """Add a custom additonal string that shows up in the resulting names""" In principle Family + Subfamily -> Fullname -> Fontname Somehow we rename not according to the default rules. Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
This commit is contained in:
parent
bb17fde9af
commit
f240e073f0
1 changed files with 5 additions and 1 deletions
|
@ -629,7 +629,11 @@ class font_patcher:
|
||||||
font.appendSFNTName(str('English (US)'), str('SubFamily'), subFamily)
|
font.appendSFNTName(str('English (US)'), str('SubFamily'), subFamily)
|
||||||
else:
|
else:
|
||||||
fam_suffix = projectNameSingular if not self.args.windows else projectNameAbbreviation
|
fam_suffix = projectNameSingular if not self.args.windows else projectNameAbbreviation
|
||||||
fam_suffix += ' Mono' if self.args.single else ''
|
if self.args.single:
|
||||||
|
if self.args.windows:
|
||||||
|
fam_suffix += 'M'
|
||||||
|
else:
|
||||||
|
fam_suffix += ' Mono'
|
||||||
n.inject_suffix(verboseAdditionalFontNameSuffix, additionalFontNameSuffix, fam_suffix)
|
n.inject_suffix(verboseAdditionalFontNameSuffix, additionalFontNameSuffix, fam_suffix)
|
||||||
n.rename_font(font)
|
n.rename_font(font)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue