mirror of
https://github.com/ToxicFrog/Ligaturizer.git
synced 2024-09-11 09:55:47 +03:00
Add Google Fonts submodule for those fonts present in it
The following fonts are now loaded from the submodule rather than checked in: - Cousine - Roboto Mono - Inconsolata - Anonymous Pro - IBM Plex Mono - Oxygen Mono - Source Code Pro - Ubuntu Mono This also means a bunch of new output fonts have been added for variants not present in the original input-fonts.
This commit is contained in:
parent
01b7c2bb01
commit
d5db9c0f5a
4
.gitmodules
vendored
4
.gitmodules
vendored
@ -1,3 +1,7 @@
|
||||
[submodule "fira"]
|
||||
path = fira
|
||||
url = https://github.com/tonsky/FiraCode
|
||||
[submodule "google-fonts"]
|
||||
path = input-fonts/google
|
||||
url = https://github.com/google/fonts.git
|
||||
shallow = true
|
||||
|
29
build.py
29
build.py
@ -25,10 +25,10 @@ SCALE_CHARACTER_GLYPHS_THRESHOLD = 0.1
|
||||
|
||||
prefixed_fonts = [
|
||||
# Apache 2.0 license
|
||||
'Cousine*',
|
||||
'google/apache/cousine/*.ttf',
|
||||
'Droid*',
|
||||
'Meslo*',
|
||||
'Roboto*',
|
||||
'google/apache/robotomono/*.ttf',
|
||||
|
||||
# MIT license
|
||||
'DejaVu*',
|
||||
@ -37,7 +37,7 @@ prefixed_fonts = [
|
||||
# SIL OFL with no Reserved Font Name
|
||||
'Edlo*',
|
||||
'FantasqueSansMono-Normal/*',
|
||||
'Inconsolata*',
|
||||
'google/ofl/inconsolata/*.ttf',
|
||||
]
|
||||
|
||||
#### Fonts that need to be renamed. ####
|
||||
@ -51,14 +51,14 @@ renamed_fonts = {
|
||||
'FantasqueSansMono-NoLoopK/*': 'Liga Fantasque Sans Mono NoLoopK',
|
||||
|
||||
# SIL OFL with reserved name
|
||||
'Anonymous*': 'Liganymous',
|
||||
'IBMPlexMono*': 'Ligalex Mono',
|
||||
'OxygenMono*': 'Liga O2 Mono',
|
||||
'SourceCodePro*': 'LigaSrc Pro',
|
||||
'google/ofl/anonymouspro/*.ttf': 'Liganymous',
|
||||
'google/ofl/ibmplexmono/*.ttf': 'Ligalex Mono',
|
||||
'google/ofl/oxygenmono/*.ttf': 'Liga O2 Mono',
|
||||
'google/ofl/sourcecodepro/*.ttf': 'LigaSrc Pro',
|
||||
'SourceCodeVariable*': 'LigaSrc Variable',
|
||||
|
||||
# UFL
|
||||
'UbuntuMono*': 'Ubuntu Mono Ligaturized',
|
||||
'google/ufl/ubuntumono/*.ttf': 'Ubuntu Mono Ligaturized',
|
||||
}
|
||||
|
||||
#### Fonts we can't ligaturize. ####
|
||||
@ -74,12 +74,17 @@ renamed_fonts = {
|
||||
|
||||
#### No user serviceable parts below this line. ####
|
||||
|
||||
import sys
|
||||
from glob import glob
|
||||
from os import path
|
||||
from ligaturize import ligaturize_font
|
||||
|
||||
for pattern in prefixed_fonts:
|
||||
for input_file in glob(path.join('input-fonts', pattern)):
|
||||
files = glob(path.join('input-fonts', pattern))
|
||||
if not files:
|
||||
print("Error: pattern 'input-fonts/%s' didn't match any files." % pattern)
|
||||
sys.exit(1)
|
||||
for input_file in files:
|
||||
ligaturize_font(
|
||||
input_file, ligature_font_file=None, output_dir='output-fonts/',
|
||||
prefix=LIGATURIZED_FONT_NAME_PREFIX, output_name=None,
|
||||
@ -87,7 +92,11 @@ for pattern in prefixed_fonts:
|
||||
scale_character_glyphs_threshold=SCALE_CHARACTER_GLYPHS_THRESHOLD)
|
||||
|
||||
for pattern,name in renamed_fonts.iteritems():
|
||||
for input_file in glob(path.join('input-fonts', pattern)):
|
||||
files = glob(path.join('input-fonts', pattern))
|
||||
if not files:
|
||||
print("Error: pattern 'input-fonts/%s' didn't match any files." % pattern)
|
||||
sys.exit(1)
|
||||
for input_file in files:
|
||||
ligaturize_font(
|
||||
input_file, ligature_font_file=None, output_dir='output-fonts/',
|
||||
prefix=None, output_name=name,
|
||||
|
2
fira
2
fira
@ -1 +1 @@
|
||||
Subproject commit 30862e05b00f41c9179a9424e382755a5ef954f0
|
||||
Subproject commit ade27f514af43920eb4c40d354c8e0a36e9ebb12
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
1
input-fonts/google
Submodule
1
input-fonts/google
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit 08b5f47811dfdea8be45ca44836c4229fc306953
|
Binary file not shown.
BIN
output-fonts/LigaCousine-BoldItalic.ttf
Normal file
BIN
output-fonts/LigaCousine-BoldItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaCousine-Italic.ttf
Normal file
BIN
output-fonts/LigaCousine-Italic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaCousine-Regular.ttf
Normal file
BIN
output-fonts/LigaCousine-Regular.ttf
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
output-fonts/LigaInconsolata-Bold.ttf
Normal file
BIN
output-fonts/LigaInconsolata-Bold.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
output-fonts/LigaRobotoMono-Bold.ttf
Normal file
BIN
output-fonts/LigaRobotoMono-Bold.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMono-BoldItalic.ttf
Normal file
BIN
output-fonts/LigaRobotoMono-BoldItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMono-Italic.ttf
Normal file
BIN
output-fonts/LigaRobotoMono-Italic.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoLight-Light.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoLight-Light.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoLight-LightItalic.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoLight-LightItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoMedium-Medium.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoMedium-Medium.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoMedium-MediumItalic.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoMedium-MediumItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoThin-Thin.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoThin-Thin.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaRobotoMonoThin-ThinItalic.ttf
Normal file
BIN
output-fonts/LigaRobotoMonoThin-ThinItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaSrcPro-Black.ttf
Normal file
BIN
output-fonts/LigaSrcPro-Black.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
output-fonts/LigaSrcPro-ExtraLight.ttf
Normal file
BIN
output-fonts/LigaSrcPro-ExtraLight.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaSrcPro-Light.ttf
Normal file
BIN
output-fonts/LigaSrcPro-Light.ttf
Normal file
Binary file not shown.
BIN
output-fonts/LigaSrcPro-Medium.ttf
Normal file
BIN
output-fonts/LigaSrcPro-Medium.ttf
Normal file
Binary file not shown.
Binary file not shown.
BIN
output-fonts/LigaSrcPro-SemiBold.ttf
Normal file
BIN
output-fonts/LigaSrcPro-SemiBold.ttf
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
output-fonts/Liganymous-Bold.ttf
Normal file
BIN
output-fonts/Liganymous-Bold.ttf
Normal file
Binary file not shown.
BIN
output-fonts/Liganymous-BoldItalic.ttf
Normal file
BIN
output-fonts/Liganymous-BoldItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/Liganymous-Italic.ttf
Normal file
BIN
output-fonts/Liganymous-Italic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/Liganymous-Regular.ttf
Normal file
BIN
output-fonts/Liganymous-Regular.ttf
Normal file
Binary file not shown.
BIN
output-fonts/UbuntuMonoLigaturized-Bold.ttf
Normal file
BIN
output-fonts/UbuntuMonoLigaturized-Bold.ttf
Normal file
Binary file not shown.
BIN
output-fonts/UbuntuMonoLigaturized-BoldItalic.ttf
Normal file
BIN
output-fonts/UbuntuMonoLigaturized-BoldItalic.ttf
Normal file
Binary file not shown.
BIN
output-fonts/UbuntuMonoLigaturized-Italic.ttf
Normal file
BIN
output-fonts/UbuntuMonoLigaturized-Italic.ttf
Normal file
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user