├── source ├── lib │ ├── batchGenerators │ │ ├── __init__.py │ │ ├── webFontsGenerator │ │ │ ├── ttfautohint │ │ │ ├── __init__.py │ │ │ └── autohint.py │ │ └── desktopFontsGenerator │ │ │ └── __init__.py │ ├── main.py │ ├── batchCompileTools.py │ └── batchSettings.py └── html │ ├── imgs │ ├── batch.png │ └── batch-menu.png │ └── index.md ├── .gitignore ├── README.md ├── tests ├── designspace_featuresInclude │ ├── thin.ufo │ │ ├── features.fea │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── kern.fea │ ├── thick.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── instances │ │ ├── E-Thick.ufo │ │ │ ├── glyphs │ │ │ │ ├── layerinfo.plist │ │ │ │ ├── contents.plist │ │ │ │ ├── A_.glif │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ │ ├── E-Thin.ufo │ │ │ ├── glyphs │ │ │ │ ├── layerinfo.plist │ │ │ │ ├── contents.plist │ │ │ │ ├── A_.glif │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ │ └── E-Style_2.ufo │ │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ └── test.designspace ├── designspace_features │ ├── thin.ufo │ │ ├── features.fea │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── thick.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ └── test.designspace ├── designspace_simple │ ├── thick.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── contents.plist │ │ │ ├── layerinfo.plist │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── thin.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── contents.plist │ │ │ ├── layerinfo.plist │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── instances │ │ ├── E-Thick.ufo │ │ │ ├── glyphs │ │ │ │ ├── contents.plist │ │ │ │ ├── layerinfo.plist │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── fontinfo.plist │ │ │ └── lib.plist │ │ ├── E-Thin.ufo │ │ │ ├── glyphs │ │ │ │ ├── contents.plist │ │ │ │ ├── layerinfo.plist │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── fontinfo.plist │ │ │ └── lib.plist │ │ └── E-Style_2.ufo │ │ │ ├── glyphs │ │ │ ├── contents.plist │ │ │ ├── layerinfo.plist │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── fontinfo.plist │ │ │ └── lib.plist │ └── test.designspace ├── designspace_missingGlyph │ ├── thick.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── contents.plist │ │ │ ├── layerinfo.plist │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── thin.ufo │ │ ├── glyphs.background │ │ │ ├── contents.plist │ │ │ └── layerinfo.plist │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── metainfo.plist │ │ ├── layercontents.plist │ │ ├── fontinfo.plist │ │ └── lib.plist │ ├── instances │ │ ├── E-Thin.ufo │ │ │ ├── glyphs │ │ │ │ ├── layerinfo.plist │ │ │ │ ├── contents.plist │ │ │ │ ├── A_.glif │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ │ ├── E-Style_2.ufo │ │ │ ├── glyphs │ │ │ │ ├── layerinfo.plist │ │ │ │ ├── contents.plist │ │ │ │ ├── A_.glif │ │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ │ └── E-Thick.ufo │ │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ │ ├── layercontents.plist │ │ │ ├── metainfo.plist │ │ │ ├── lib.plist │ │ │ └── fontinfo.plist │ └── test.designspace └── designspace_missingKerningPair │ ├── thick.ufo │ ├── glyphs.background │ │ ├── contents.plist │ │ └── layerinfo.plist │ ├── glyphs │ │ ├── layerinfo.plist │ │ ├── contents.plist │ │ ├── A_.glif │ │ └── E_.glif │ ├── metainfo.plist │ ├── layercontents.plist │ ├── fontinfo.plist │ └── lib.plist │ ├── thin.ufo │ ├── glyphs.background │ │ ├── contents.plist │ │ └── layerinfo.plist │ ├── glyphs │ │ ├── layerinfo.plist │ │ ├── contents.plist │ │ ├── A_.glif │ │ └── E_.glif │ ├── kerning.plist │ ├── metainfo.plist │ ├── layercontents.plist │ ├── fontinfo.plist │ └── lib.plist │ ├── instances │ ├── E-Style_2.ufo │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── layercontents.plist │ │ ├── metainfo.plist │ │ ├── lib.plist │ │ └── fontinfo.plist │ ├── E-Thick.ufo │ │ ├── glyphs │ │ │ ├── layerinfo.plist │ │ │ ├── contents.plist │ │ │ ├── A_.glif │ │ │ └── E_.glif │ │ ├── layercontents.plist │ │ ├── metainfo.plist │ │ ├── lib.plist │ │ └── fontinfo.plist │ └── E-Thin.ufo │ │ ├── glyphs │ │ ├── layerinfo.plist │ │ ├── contents.plist │ │ ├── A_.glif │ │ └── E_.glif │ │ ├── kerning.plist │ │ ├── layercontents.plist │ │ ├── metainfo.plist │ │ ├── lib.plist │ │ └── fontinfo.plist │ └── test.designspace ├── info.yaml └── .github └── workflows └── validate_build.yml /source/lib/batchGenerators/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.pyc 2 | .DS_Store 3 | 4 | tests/binaries 5 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Batch 2 | 3 | Documentation is [here](source/html/index.md) -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/features.fea: -------------------------------------------------------------------------------- 1 | include(kern.fea); -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/kern.fea: -------------------------------------------------------------------------------- 1 | feature kern { 2 | pos A E 500; 3 | } kern; -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/features.fea: -------------------------------------------------------------------------------- 1 | feature kern { 2 | pos A E 500; 3 | } kern; -------------------------------------------------------------------------------- /source/html/imgs/batch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/typemytype/batchRoboFontExtension/HEAD/source/html/imgs/batch.png -------------------------------------------------------------------------------- /source/html/imgs/batch-menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/typemytype/batchRoboFontExtension/HEAD/source/html/imgs/batch-menu.png -------------------------------------------------------------------------------- /source/lib/batchGenerators/webFontsGenerator/ttfautohint: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/typemytype/batchRoboFontExtension/HEAD/source/lib/batchGenerators/webFontsGenerator/ttfautohint -------------------------------------------------------------------------------- /info.yaml: -------------------------------------------------------------------------------- 1 | name: Batch 2 | developer: TypeMyType 3 | developerURL: http://typemytype.com 4 | launchAtStartUp: true 5 | mainScript: main.py 6 | version: '2.6.b1' 7 | addToMenu: [] 8 | html: true 9 | requiresVersionMajor: '4' 10 | requiresVersionMinor: 4b 11 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs.background/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /.github/workflows/validate_build.yml: -------------------------------------------------------------------------------- 1 | name: Validate and Build the Extension 2 | on: 3 | push 4 | 5 | jobs: 6 | validate_and_build: 7 | runs-on: ubuntu-latest 8 | steps: 9 | - name: Validate and Build 10 | uses: typemytype/roboFont-Extension-action@v0.1.0 11 | with: 12 | autotagging: true -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | E 6 | E_.glif 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs.background/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0,0.8,0.2,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/glyphs/layerinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | color 6 | 0.498,0,0.498,0.7 7 | 8 | 9 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/kerning.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | 7 | E 8 | 100 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/kerning.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | 7 | E 8 | 100 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/glyphs/contents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | A 6 | A_.glif 7 | E 8 | E_.glif 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/metainfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | creator 6 | com.github.fonttools.ufoLib 7 | formatVersion 8 | 3 9 | 10 | 11 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/layercontents.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | foreground 7 | glyphs 8 | 9 | 10 | background 11 | glyphs.background 12 | 13 | 14 | 15 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 700.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | E 17 | A 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 400.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | E 17 | A 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 700.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | A 17 | E 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 400.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | A 17 | E 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 700.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | E 17 | A 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 400.0 10 | 11 | 12 | designspace.mathmodel 13 | fonttools.varlib 14 | public.glyphOrder 15 | 16 | E 17 | A 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 10 | 700.0 11 | 400.0 12 | 13 | 14 | 15 | designspace.mathmodel 16 | fonttools.varlib 17 | public.glyphOrder 18 | 19 | E 20 | A 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 10 | 700.0 11 | 400.0 12 | 13 | 14 | 15 | designspace.mathmodel 16 | fonttools.varlib 17 | public.glyphOrder 18 | 19 | A 20 | E 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | designspace.location 6 | 7 | 8 | weight 9 | 10 | 700.0 11 | 400.0 12 | 13 | 14 | 15 | designspace.mathmodel 16 | fonttools.varlib 17 | public.glyphOrder 18 | 19 | E 20 | A 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/glyphs/A_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /source/lib/main.py: -------------------------------------------------------------------------------- 1 | import AppKit 2 | 3 | from mojo.tools import CallbackWrapper 4 | 5 | import batch 6 | # just import batchCompileTools to make them available everywhere else 7 | import batchCompileTools 8 | 9 | 10 | class BatchMenu(object): 11 | 12 | def __init__(self): 13 | title = "Batch..." 14 | mainMenu = AppKit.NSApp().mainMenu() 15 | fileMenu = mainMenu.itemWithTitle_("File") 16 | 17 | if not fileMenu: 18 | return 19 | 20 | fileMenu = fileMenu.submenu() 21 | 22 | if fileMenu.itemWithTitle_(title): 23 | return 24 | 25 | index = fileMenu.indexOfItemWithTitle_("Generate Font") 26 | self.target = CallbackWrapper(self.callback) 27 | 28 | newItem = AppKit.NSMenuItem.alloc().initWithTitle_action_keyEquivalent_(title, "action:", "") 29 | newItem.setTarget_(self.target) 30 | 31 | fileMenu.insertItem_atIndex_(newItem, index + 1) 32 | 33 | def callback(self, sender): 34 | OpenWindow(batch.BatchController) 35 | 36 | 37 | BatchMenu() 38 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Style_2 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Style_2 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Style_2 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thick 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Thin 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/fontinfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | ascender 6 | 750 7 | capHeight 8 | 750 9 | descender 10 | -250 11 | familyName 12 | E 13 | guidelines 14 | 15 | postscriptBlueValues 16 | 17 | postscriptFamilyBlues 18 | 19 | postscriptFamilyOtherBlues 20 | 21 | postscriptOtherBlues 22 | 23 | postscriptStemSnapH 24 | 25 | postscriptStemSnapV 26 | 27 | styleName 28 | Style_2 29 | unitsPerEm 30 | 1000.0 31 | xHeight 32 | 500 33 | 34 | 35 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Style_2.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/instances/E-Thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/instances/E-Style_2.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thick.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Thin.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/instances/E-Style_2.ufo/glyphs/E_.glif: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | -------------------------------------------------------------------------------- /tests/designspace_features/test.designspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/test.designspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/test.designspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/test.designspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /tests/designspace_simple/test.designspace: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /source/lib/batchGenerators/desktopFontsGenerator/__init__.py: -------------------------------------------------------------------------------- 1 | import os 2 | from mojo.roboFont import RFont 3 | 4 | from batchGenerators.batchTools import removeTree, generatePaths, postProcessCollector 5 | 6 | 7 | def build(root, generateOptions, settings, progress, report): 8 | binaryFormats = [] 9 | if generateOptions.get("desktopFontGenerate_OTF"): 10 | binaryFormats.append(("otf", postProcessCollector())) 11 | if generateOptions.get("desktopFontGenerate_TTF"): 12 | binaryFormats.append(("ttf", postProcessCollector())) 13 | # if generateOptions.get("desktopFontGenerate_PFA"): 14 | # binaryFormats.append(("pfa", postProcessCollector())) 15 | # if generateOptions.get("desktopFontGenerate_VFB"): 16 | # binaryFormats.append(("vfb", postProcessCollector())) 17 | 18 | if not binaryFormats: 19 | return 20 | 21 | report.writeTitle("Batch Generated Desktop Fonts:") 22 | progress.setText("Collecting Data...") 23 | 24 | desktopFontsRoot = os.path.join(root, "Desktop") 25 | removeTree(desktopFontsRoot) 26 | 27 | generatePaths( 28 | sourceUFOs=generateOptions["sourceUFOs"], 29 | binaryFormats=binaryFormats, 30 | decompose=settings["desktopFontsDecompose"], 31 | removeOverlap=settings["desktopFontsRemoveOverlap"], 32 | autohint=settings["desktopFontsAutohint"], 33 | releaseMode=settings["desktopFontsReleaseMode"], 34 | keepFileNames=settings["batchSettingExportKeepFileNames"], 35 | suffix=settings["desktopFontsSuffix"], 36 | exportInFolders=settings["batchSettingExportInSubFolders"], 37 | root=desktopFontsRoot, 38 | report=report, 39 | progress=progress 40 | ) 41 | -------------------------------------------------------------------------------- /source/html/index.md: -------------------------------------------------------------------------------- 1 | # Batch 2 | 3 | 4 | **Batch is a RoboFont extension to generate binary fonts in batch.** 5 | 6 | - supports UFO, OpenType (TTF/CFF) and designSpace files as input 7 | - generates .otf .ttf .pfa .woff2 & variable fonts 8 | 9 | ## Documentation 10 | 11 | - [Sources](#sources) 12 | - [Desktop Fonts](#desktop-fonts) 13 | - [Web fonts](#web-fonts) 14 | - [Variable fonts](#variable-fonts) 15 | - [Settings](#settings) 16 | 17 | 18 | Once installed, Batch will add itself to the *File* menu: 19 | 20 | ![](imgs/batch-menu.png) 21 | 22 | 23 | # Sources 24 | 25 | Use the *Sources* section to choose which fonts to use as input. 26 | 27 | **Add fonts by dragging files into the list or use the + - buttons.** 28 | 29 | The following types of input files are supported: 30 | 31 | - UFO fonts 32 | - OpenType fonts (CFF/TTF) 33 | - UFO's folder 34 | - designspace file 35 | 36 | If a designspace file is provided, it will be expanded into all it's sources and instances, the instances can be generated as seperate static desktop and web fonts. 37 | 38 | 39 | ![](imgs/batch.png) 40 | 41 | # Export formats 42 | 43 | ## Desktop Fonts 44 | 45 | - .otf 46 | - .ttf 47 | 48 | ## Web Fonts 49 | 50 | - .otf 51 | - .otf (woff2) 52 | - .ttf 53 | - .ttf (woff2) 54 | 55 | ## Variable Fonts 56 | 57 | - .otf 58 | - .otf (woff2) 59 | - .ttf 60 | - .ttf (woff2) 61 | 62 | *Note: It is required to provide a designSpace file.* 63 | 64 | 65 | Batch will try to optimize the designspace data by performing the following actions: 66 | 67 | * Add off-curve points where needed to make contours compatible. 68 | * Add axes to the design space if they are missing. 69 | * Add missing glyphs by generating them from the design space. 70 | * Add kerning pairs to make kerning compatible. 71 | 72 | 73 | Settings 74 | -------- 75 | 76 | Click on the gears icon in the toolbar to open the *Settings* sheet. 77 | 78 | ## Desktop Fonts 79 | 80 | ### Generate 81 | 82 | - **Decompose** 83 | - **Remove Overlap** 84 | - **Autohint** 85 | - **Release Mode** 86 | 87 | ### Suffix 88 | 89 | A suffix added to to the export path. 90 | 91 | ## Web Fonts 92 | 93 | ### Generate 94 | 95 | - **Decompose** 96 | - **Remove Overlap** 97 | - **Autohint** 98 | - **Release Mode** 99 | - **Generate HTML** build a test html page with the Batch generated fonts. 100 | 101 | ### Suffix 102 | 103 | A suffix added to to the export path. 104 | 105 | ### TTF Autohint 106 | 107 | see the documentation of [ttf autohint](https://freetype.org/ttfautohint/doc/ttfautohint.html) 108 | 109 | ## Variable Fonts 110 | 111 | ### Generate 112 | 113 | - **Interpolate to Fit Axis Extremes** generate missing extremes for all axis. 114 | - **Autohint** 115 | 116 | ### Suffix 117 | 118 | A suffix added to to the export path 119 | 120 | ## Batch Settings 121 | 122 | - **Export in sub-folders** 123 | - **Use familyName-styleName** or **Keep file names** 124 | - **Store Export Report** 125 | - **Debug** 126 | 127 | -------------------------------------------------------------------------------- /tests/designspace_simple/thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_simple/thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_features/thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_features/thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_featuresInclude/thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_missingGlyph/thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_missingKerningPair/thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | public.glyphOrder 31 | 32 | space 33 | A 34 | B 35 | C 36 | D 37 | E 38 | F 39 | G 40 | H 41 | I 42 | J 43 | K 44 | L 45 | M 46 | N 47 | O 48 | P 49 | Q 50 | R 51 | S 52 | T 53 | U 54 | V 55 | W 56 | X 57 | Y 58 | Z 59 | a 60 | b 61 | c 62 | d 63 | e 64 | f 65 | g 66 | h 67 | i 68 | j 69 | k 70 | l 71 | m 72 | n 73 | o 74 | p 75 | q 76 | r 77 | s 78 | t 79 | u 80 | v 81 | w 82 | x 83 | y 84 | z 85 | zero 86 | one 87 | two 88 | three 89 | four 90 | five 91 | six 92 | seven 93 | eight 94 | nine 95 | 96 | 97 | 98 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thick.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | designspace.location 31 | 32 | 33 | weight 34 | 700.0 35 | 36 | 37 | designspace.mathmodel 38 | fonttools.varlib 39 | public.glyphOrder 40 | 41 | space 42 | A 43 | B 44 | C 45 | D 46 | E 47 | F 48 | G 49 | H 50 | I 51 | J 52 | K 53 | L 54 | M 55 | N 56 | O 57 | P 58 | Q 59 | R 60 | S 61 | T 62 | U 63 | V 64 | W 65 | X 66 | Y 67 | Z 68 | a 69 | b 70 | c 71 | d 72 | e 73 | f 74 | g 75 | h 76 | i 77 | j 78 | k 79 | l 80 | m 81 | n 82 | o 83 | p 84 | q 85 | r 86 | s 87 | t 88 | u 89 | v 90 | w 91 | x 92 | y 93 | z 94 | zero 95 | one 96 | two 97 | three 98 | four 99 | five 100 | six 101 | seven 102 | eight 103 | nine 104 | 105 | 106 | 107 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Thin.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | designspace.location 31 | 32 | 33 | weight 34 | 400.0 35 | 36 | 37 | designspace.mathmodel 38 | fonttools.varlib 39 | public.glyphOrder 40 | 41 | space 42 | A 43 | B 44 | C 45 | D 46 | E 47 | F 48 | G 49 | H 50 | I 51 | J 52 | K 53 | L 54 | M 55 | N 56 | O 57 | P 58 | Q 59 | R 60 | S 61 | T 62 | U 63 | V 64 | W 65 | X 66 | Y 67 | Z 68 | a 69 | b 70 | c 71 | d 72 | e 73 | f 74 | g 75 | h 76 | i 77 | j 78 | k 79 | l 80 | m 81 | n 82 | o 83 | p 84 | q 85 | r 86 | s 87 | t 88 | u 89 | v 90 | w 91 | x 92 | y 93 | z 94 | zero 95 | one 96 | two 97 | three 98 | four 99 | five 100 | six 101 | seven 102 | eight 103 | nine 104 | 105 | 106 | 107 | -------------------------------------------------------------------------------- /tests/designspace_simple/instances/E-Style_2.ufo/lib.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.defcon.sortDescriptor 6 | 7 | 8 | ascending 9 | basic 10 | type 11 | characterSet 12 | 13 | 14 | com.typemytype.robofont.compileSettings.autohint 15 | 16 | com.typemytype.robofont.compileSettings.checkOutlines 17 | 18 | com.typemytype.robofont.compileSettings.createDummyDSIG 19 | 20 | com.typemytype.robofont.compileSettings.decompose 21 | 22 | com.typemytype.robofont.compileSettings.generateFormat 23 | 0 24 | com.typemytype.robofont.compileSettings.releaseMode 25 | 26 | com.typemytype.robofont.italicSlantOffset 27 | 0 28 | com.typemytype.robofont.shouldAddPointsInSplineConversion 29 | 1 30 | designspace.location 31 | 32 | 33 | weight 34 | 35 | 700.0 36 | 400.0 37 | 38 | 39 | 40 | designspace.mathmodel 41 | fonttools.varlib 42 | public.glyphOrder 43 | 44 | space 45 | A 46 | B 47 | C 48 | D 49 | E 50 | F 51 | G 52 | H 53 | I 54 | J 55 | K 56 | L 57 | M 58 | N 59 | O 60 | P 61 | Q 62 | R 63 | S 64 | T 65 | U 66 | V 67 | W 68 | X 69 | Y 70 | Z 71 | a 72 | b 73 | c 74 | d 75 | e 76 | f 77 | g 78 | h 79 | i 80 | j 81 | k 82 | l 83 | m 84 | n 85 | o 86 | p 87 | q 88 | r 89 | s 90 | t 91 | u 92 | v 93 | w 94 | x 95 | y 96 | z 97 | zero 98 | one 99 | two 100 | three 101 | four 102 | five 103 | six 104 | seven 105 | eight 106 | nine 107 | 108 | 109 | 110 | -------------------------------------------------------------------------------- /source/lib/batchCompileTools.py: -------------------------------------------------------------------------------- 1 | from batchGenerators.batchTools import Report, DummyProgress 2 | import batchGenerators 3 | import batchSettings 4 | 5 | 6 | def generateDesktopFonts(ufoPathsOrObjects, destinationRoot, format="ttf", decompose=True, removeOverlap=True, autohint=False, releaseMode=True, suffix=""): 7 | if not isinstance(ufoPathsOrObjects, list): 8 | ufoPathsOrObjects = [ufoPathsOrObjects] 9 | report = Report() 10 | generateOptions = dict( 11 | sourceUFOs=ufoPathsOrObjects, 12 | ) 13 | settings = dict(batchSettings.defaultSettings) 14 | settings.update( 15 | dict( 16 | batchSettingExportInSubFolders=False, 17 | desktopFontsAutohint=autohint, 18 | desktopFontsDecompose=decompose, 19 | desktopFontsReleaseMode=releaseMode, 20 | desktopFontsRemoveOverlap=removeOverlap, 21 | desktopFontsSuffix=suffix 22 | ) 23 | ) 24 | if format == "ttf": 25 | generateOptions["desktopFontGenerate_TTF"] = True 26 | if format == "otf": 27 | generateOptions["desktopFontGenerate_OTF"] = True 28 | 29 | batchGenerators.desktopFontsGenerator.build( 30 | root=destinationRoot, 31 | generateOptions=generateOptions, 32 | settings=settings, 33 | progress=DummyProgress(), 34 | report=report 35 | ) 36 | return report.get() 37 | 38 | 39 | def generateWebFonts(ufoPathsOrObjects, destinationRoot, format="ttf", woff=False, decompose=True, removeOverlap=True, autohint=False, releaseMode=True, suffix="", html=False, htmlPreview=None): 40 | if not isinstance(ufoPathsOrObjects, list): 41 | ufoPathsOrObjects = [ufoPathsOrObjects] 42 | report = Report() 43 | generateOptions = dict( 44 | sourceUFOs=ufoPathsOrObjects, 45 | ) 46 | settings = dict(batchSettings.defaultSettings) 47 | settings.update( 48 | dict( 49 | batchSettingExportInSubFolders=False, 50 | webFontsAutohint=autohint, 51 | webFontsDecompose=decompose, 52 | webFontsGenerateHTML=html, 53 | webFontsReleaseMode=releaseMode, 54 | webFontsRemoveOverlap=removeOverlap, 55 | webFontsSuffix=suffix 56 | ) 57 | ) 58 | if htmlPreview: 59 | settings["webFontsHtmlPreview"] = htmlPreview 60 | if format == "ttf" and woff: 61 | generateOptions["webFontGenerate_TTFWOFF2"] = True 62 | if format == "otf" and woff: 63 | generateOptions["webFontGenerate_OTFWOFF2"] = True 64 | if format == "ttf" and not woff: 65 | generateOptions["webFontGenerate_TTF"] = True 66 | if format == "otf" and not woff: 67 | generateOptions["webFontGenerate_OTF"] = True 68 | 69 | batchGenerators.webFontsGenerator.build( 70 | root=destinationRoot, 71 | generateOptions=generateOptions, 72 | settings=settings, 73 | progress=DummyProgress(), 74 | report=report 75 | ) 76 | return report.get() 77 | 78 | 79 | def generateVariableFonts(designspacePathsOrObjects, destinationRoot, format="ttf", woff=False, autohint=False, fitToExtremes=False, suffix=""): 80 | if not isinstance(designspacePathsOrObjects, list): 81 | designspacePathsOrObjects = [designspacePathsOrObjects] 82 | report = Report() 83 | generateOptions = dict( 84 | sourceDesignspaces=designspacePathsOrObjects, 85 | ) 86 | settings = dict(batchSettings.defaultSettings) 87 | settings.update( 88 | dict( 89 | batchSettingExportInSubFolders=False, 90 | variableFontsAutohint=autohint, 91 | variableFontsInterpolateToFitAxesExtremes=fitToExtremes, 92 | variableFontsSuffix=suffix 93 | ) 94 | ) 95 | if format == "ttf" and woff: 96 | generateOptions["variableFontGenerate_TTFWOFF2"] = True 97 | if format == "otf" and woff: 98 | generateOptions["variableFontGenerate_OTFWOFF2"] = True 99 | if format == "ttf" and not woff: 100 | generateOptions["variableFontGenerate_TTF"] = True 101 | if format == "otf" and not woff: 102 | generateOptions["variableFontGenerate_OTF"] = True 103 | 104 | batchGenerators.variableFontsGenerator.build( 105 | root=destinationRoot, 106 | generateOptions=generateOptions, 107 | settings=settings, 108 | progress=DummyProgress(), 109 | report=report 110 | ) 111 | return report.get() 112 | -------------------------------------------------------------------------------- /source/lib/batchGenerators/webFontsGenerator/__init__.py: -------------------------------------------------------------------------------- 1 | import os 2 | import shutil 3 | import re 4 | 5 | from fontTools.ttLib import TTFont 6 | 7 | from mojo.compile import autohint as OTFAutohint 8 | 9 | from batchGenerators.batchTools import generatePaths, WOFF2Builder, removeTree, postProcessCollector, CSSWriter, HTMLWriter 10 | 11 | from .autohint import TTFAutohint 12 | 13 | 14 | percentageRe = re.compile(r"%(?!\((familyName|styleName)\)s)") 15 | 16 | 17 | cssFormatExtMap = { 18 | ".otf": "opentype", 19 | ".ttf": "truetype", 20 | ".woff": "woff", 21 | ".woff2": "woff2" 22 | 23 | } 24 | 25 | 26 | def htmlBuilder(htmlPreview, reportHTML, reportCSS): 27 | 28 | def wrapper(sourcePath, destinationPath): 29 | font = TTFont(sourcePath) 30 | familyName = font["name"].getBestFamilyName() 31 | styleName = font["name"].getBestSubFamilyName() 32 | font.close() 33 | 34 | _, ext = os.path.splitext(sourcePath) 35 | 36 | cssFontName = f"{familyName}_{styleName}" 37 | 38 | reportCSS.write("@font-face {") 39 | reportCSS.indent() 40 | reportCSS.write(f"font-family: '{cssFontName}';") 41 | reportCSS.write(f"src: url('{destinationPath}') format('{cssFormatExtMap[ext]}');") 42 | reportCSS.write("font-weight: normal;") 43 | reportCSS.write("font-style: normal;") 44 | reportCSS.dedent() 45 | reportCSS.write("}") 46 | reportCSS.newLine() 47 | 48 | reportHTML.write(f"
") 49 | html = htmlPreview 50 | html = percentageRe.sub("%", html) 51 | html = html % dict(familyName=familyName, styleName=styleName, fileName=os.path.basename(destinationPath)) 52 | reportHTML.write(html.encode("ascii", 'xmlcharrefreplace').decode("utf-8")) 53 | reportHTML.write("
") 54 | 55 | return wrapper 56 | 57 | 58 | def autohintBuilder(autohintOptions, report): 59 | 60 | def wrapper(sourcePath, destinationPath): 61 | font = TTFont(sourcePath) 62 | isTTF = "glyf" in font 63 | font.close() 64 | if isTTF: 65 | result = TTFAutohint(sourcePath, destinationPath, autohintOptions) 66 | else: 67 | result = OTFAutohint(sourcePath) 68 | shutil.copyfile(sourcePath, destinationPath) 69 | report.writeItems(result) 70 | return wrapper 71 | 72 | 73 | def build(root, generateOptions, settings, progress, report): 74 | if settings["webFontsAutohint"]: 75 | autohintFunc = autohintBuilder(settings, report) 76 | else: 77 | autohintFunc = None 78 | 79 | if settings["webFontsGenerateHTML"]: 80 | reportHTML = HTMLWriter(cssFileName="font.css", style=settings["webFontsHtmlPreviewCSS"]) 81 | reportCSS = CSSWriter() 82 | 83 | htmlBuilderFunc = htmlBuilder( 84 | htmlPreview=settings["webFontsHtmlPreview"], 85 | reportHTML=reportHTML, 86 | reportCSS=reportCSS 87 | ) 88 | else: 89 | htmlBuilderFunc = None 90 | 91 | binaryFormats = [] 92 | if generateOptions.get("webFontGenerate_OTF"): 93 | binaryFormats.append(("otf", postProcessCollector(autohintFunc, htmlBuilderFunc))) 94 | if generateOptions.get("webFontGenerate_OTFWOFF2"): 95 | binaryFormats.append(("otf-woff2", postProcessCollector(autohintFunc, WOFF2Builder, htmlBuilderFunc))) 96 | if generateOptions.get("webFontGenerate_TTF"): 97 | binaryFormats.append(("ttf", postProcessCollector(autohintFunc, htmlBuilderFunc))) 98 | if generateOptions.get("webFontGenerate_TTFWOFF2"): 99 | binaryFormats.append(("ttf-woff2", postProcessCollector(autohintFunc, WOFF2Builder, htmlBuilderFunc))) 100 | # if generateOptions["webFontGenerate_SVG"]: 101 | # binaryFormats.append(("svg", None)) 102 | 103 | if not binaryFormats: 104 | return 105 | 106 | webFontsRoot = os.path.join(root, "Web") 107 | removeTree(webFontsRoot) 108 | 109 | report.writeTitle("Batch Generated Web Fonts:") 110 | progress.setText("Collecting Data...") 111 | 112 | generatePaths( 113 | sourceUFOs=generateOptions["sourceUFOs"], 114 | binaryFormats=binaryFormats, 115 | decompose=settings["webFontsDecompose"], 116 | removeOverlap=settings["webFontsRemoveOverlap"], 117 | autohint=False, 118 | releaseMode=settings["webFontsReleaseMode"], 119 | keepFileNames=settings["batchSettingExportKeepFileNames"], 120 | suffix=settings["webFontsSuffix"], 121 | exportInFolders=settings["batchSettingExportInSubFolders"], 122 | root=webFontsRoot, 123 | report=report, 124 | progress=progress 125 | ) 126 | 127 | if settings["webFontsGenerateHTML"]: 128 | reportCSS.save(os.path.join(webFontsRoot, "font.css")) 129 | reportHTML.save(os.path.join(webFontsRoot, "preview.html")) 130 | -------------------------------------------------------------------------------- /source/lib/batchGenerators/webFontsGenerator/autohint.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | from fontTools.ttLib import TTFont 4 | 5 | from mojo.compile import executeCommand 6 | 7 | from batchGenerators.batchTools import updateWithDefaultValues 8 | 9 | 10 | ttfautohint = os.path.join(os.path.dirname(__file__), "ttfautohint") 11 | os.chmod(ttfautohint, 0o0777) 12 | 13 | 14 | defaultOptions = { 15 | "ttfautohintHintSetRangeMinimum": 8, 16 | "ttfautohintHintSetRangeMaximum": 50, 17 | 18 | "ttfautohintHintLimit": 200, 19 | "ttfautohintNoHintLimit": False, 20 | 21 | "ttfautohintXHeightIncreaseLimit": 14, 22 | "ttfautohintNoXHeightIncreaseLimit": False, 23 | 24 | "ttfautohintFallbackScript": False, 25 | 26 | "ttfautohintPreHinted": False, 27 | "ttfautohintSymbolFont": False, 28 | "ttfautohintAddTTFAutohintInfo": False, 29 | "ttfautohintOverrideFontLicenseRestrictions": False, 30 | 31 | "ttfautohintGrayScale": False, 32 | "ttfautohintCDIClearType": True, 33 | "ttfautohintDWClearType": False, 34 | } 35 | 36 | 37 | def TTFAutohint(sourcePath, destinationPath, options=dict()): 38 | """ 39 | Options: 40 | --debug print debugging information 41 | -f, --latin-fallback set fallback script to latin 42 | -G, --hinting-limit=N switch off hinting above this PPEM value 43 | (default: 200); value 0 means no limit 44 | -h, --help display this help and exit 45 | -i, --ignore-restrictions override font license restrictions 46 | -l, --hinting-range-min=N the minimum PPEM value for hint sets 47 | (default: 8) 48 | -n --no-info don't add ttfautohint info 49 | to the version string(s) in the `name' table 50 | -p, --pre-hinting apply original hints in advance 51 | -r, --hinting-range-max=N the maximum PPEM value for hint sets 52 | (default: 50) 53 | -s, --symbol input is symbol font 54 | -v, --verbose show progress information 55 | -V, --version print version information and exit 56 | -w, --strong-stem-width=S use strong stem width routine for modes S, 57 | where S is a string of up to three letters 58 | with possible values `g' for grayscale, 59 | `G' for GDI ClearType, and `D' for 60 | DirectWrite ClearType (default: G) 61 | -x, --increase-x-height=N increase x height for sizes in the range 62 | 6<=PPEM<=N; value 0 switches off this feature 63 | (default: 14) 64 | -X, --x-height-snapping-exceptions=STRING 65 | specify a comma-separated list of 66 | x-height snapping exceptions 67 | 68 | """ 69 | updateWithDefaultValues(options, defaultOptions) 70 | 71 | hintRangeMinimum = str(options["ttfautohintHintSetRangeMinimum"]) 72 | hintRangeMaximum = str(options["ttfautohintHintSetRangeMaximum"]) 73 | fallbackScript = options["ttfautohintFallbackScript"] 74 | hintingLimit = options["ttfautohintHintLimit"] 75 | noHintingLimit = options["ttfautohintNoHintLimit"] 76 | if noHintingLimit: 77 | hintingLimit = 0 78 | hintingLimit = str(hintingLimit) 79 | 80 | xHeightIncreaseLimit = options["ttfautohintXHeightIncreaseLimit"] 81 | noXHeightIncreaseLimit = options["ttfautohintNoXHeightIncreaseLimit"] 82 | if noXHeightIncreaseLimit: 83 | xHeightIncreaseLimit = 0 84 | xHeightIncreaseLimit = str(xHeightIncreaseLimit) 85 | 86 | preHinting = options["ttfautohintPreHinted"] 87 | symbolFont = options["ttfautohintSymbolFont"] 88 | if not symbolFont: 89 | f = TTFont(sourcePath) 90 | symbolFont = "o" not in f.getGlyphOrder() 91 | f.close() 92 | 93 | addTTFAutoHintInfo = options["ttfautohintAddTTFAutohintInfo"] 94 | overRideFontLicense = options["ttfautohintOverrideFontLicenseRestrictions"] 95 | 96 | grayScale = options["ttfautohintGrayScale"] 97 | if grayScale: 98 | grayScale = "g" 99 | else: 100 | grayScale = "" 101 | 102 | gdiClearType = options["ttfautohintCDIClearType"] 103 | if gdiClearType: 104 | gdiClearType = "G" 105 | else: 106 | gdiClearType = "" 107 | 108 | dwClearType = options["ttfautohintDWClearType"] 109 | if dwClearType: 110 | dwClearType = "D" 111 | else: 112 | dwClearType = "" 113 | 114 | cmd = [ttfautohint] 115 | cmd.extend(["-G", hintingLimit]) 116 | cmd.extend(["-l", hintRangeMinimum]) 117 | cmd.extend(["-r", hintRangeMaximum]) 118 | cmd.extend(["-x", xHeightIncreaseLimit]) 119 | 120 | if fallbackScript: 121 | cmd.append("-f") 122 | if not addTTFAutoHintInfo: 123 | cmd.append("-n") 124 | if preHinting: 125 | cmd.append("-p") 126 | if symbolFont: 127 | cmd.append("-s") 128 | if not overRideFontLicense: 129 | cmd.append("-i") 130 | 131 | cmd.extend(["-w", grayScale + gdiClearType + dwClearType]) 132 | cmd.extend([sourcePath, destinationPath]) 133 | result = executeCommand(cmd) 134 | return result 135 | -------------------------------------------------------------------------------- /source/lib/batchSettings.py: -------------------------------------------------------------------------------- 1 | import ezui 2 | 3 | from mojo.extensions import getExtensionDefault, setExtensionDefault 4 | 5 | 6 | webFontsHtmlPreviewCSS = """.test { 7 | word-wrap: break-word; 8 | } 9 | 10 | .title { 11 | font-size: 30px; 12 | background-color: black; 13 | color: white; 14 | display: inline-block; 15 | padding-left: 5px; 16 | padding-right: 5px; 17 | margin-bottom: 3px; 18 | margin-top: 10px; 19 | } 20 | 21 | .small { 22 | font-size: 10px; 23 | } 24 | 25 | .big { 26 | font-size: 50px; 27 | } 28 | """ 29 | 30 | webFontsHtmlPreview = """
%(familyName)s %(styleName)s (%(fileName)s)
31 |
32 |
abcdefghijklmnopqrstuvwxyz
33 |
ABCDEFGHIJKLMNOPQRSTUVWXYZ
34 |
0123456789
35 |
36 | 37 |
38 |
abcdefghijklmnopqrstuvwxyz
39 |
ABCDEFGHIJKLMNOPQRSTUVWXYZ
40 |
0123456789
41 |
42 | """ 43 | 44 | 45 | defaultSettings = dict( 46 | batchSettingExportDebug=0, 47 | batchSettingExportInSubFolders=0, 48 | batchSettingExportKeepFileNames=0, 49 | batchSettingStoreReport=1, 50 | 51 | desktopFontsAutohint=0, 52 | desktopFontsDecompose=1, 53 | desktopFontsReleaseMode=0, 54 | desktopFontsRemoveOverlap=1, 55 | desktopFontsSuffix="", 56 | 57 | ttfautohintAddTTFAutohintInfo=0, 58 | ttfautohintCDIClearType=0, 59 | ttfautohintDWClearType=0, 60 | ttfautohintFallbackScript=0, 61 | ttfautohintGrayScale=0, 62 | ttfautohintHintLimit=50, 63 | ttfautohintHintSetRangeMaximum=50, 64 | ttfautohintHintSetRangeMinimum=50, 65 | ttfautohintNoHintLimit=0, 66 | ttfautohintNoXHeightIncreaseLimit=0, 67 | ttfautohintOverrideFontLicenseRestrictions=0, 68 | ttfautohintPreHinted=0, 69 | ttfautohintSymbolFont=0, 70 | ttfautohintXHeightIncreaseLimit=50, 71 | 72 | variableFontsAutohint=0, 73 | variableFontsInterpolateToFitAxesExtremes=0, 74 | variableFontsSuffix="", 75 | 76 | webFontsAutohint=0, 77 | webFontsDecompose=0, 78 | webFontsGenerateHTML=0, 79 | webFontsHtmlPreview=webFontsHtmlPreview, 80 | webFontsHtmlPreviewCSS=webFontsHtmlPreviewCSS, 81 | webFontsReleaseMode=0, 82 | webFontsRemoveOverlap=0, 83 | webFontsSuffix="", 84 | ) 85 | 86 | # update settings when new keys are added 87 | settings = getExtensionDefault("com.typemytype.batch.settings", dict()) 88 | for key, value in defaultSettings.items(): 89 | if key not in settings: 90 | settings[key] = value 91 | setExtensionDefault("com.typemytype.batch.settings", settings) 92 | 93 | 94 | class BatchSettingsController(ezui.WindowController): 95 | 96 | def build(self, parent): 97 | content = """ 98 | = Tabs 99 | * Tab: Desktop Fonts = ScrollingTwoColumnForm @desktopFontsForm 100 | > : Generate: 101 | > [ ] Decompose @desktopFontsDecompose 102 | > [ ] Remove Overlap @desktopFontsRemoveOverlap 103 | > [ ] Autohint @desktopFontsAutohint 104 | > [ ] Release Mode @desktopFontsReleaseMode 105 | > : Suffix: 106 | > [_ _] @desktopFontsSuffix 107 | 108 | 109 | * Tab: Web Fonts = ScrollingTwoColumnForm @webFontsForm 110 | > : Generate: 111 | > [ ] Decompose @webFontsDecompose 112 | > [ ] Remove Overlap @webFontsRemoveOverlap 113 | > [ ] Autohint @webFontsAutohint 114 | > [ ] Release Mode @webFontsReleaseMode 115 | > [ ] Generate HTML @webFontsGenerateHTML 116 | > : Suffix: 117 | > [_ _] @webFontsSuffix 118 | 119 | > !§ TTF Autohint 120 | 121 | > : Hint Set Range Minimum: 122 | > ---X--- [__] @ttfautohintHintSetRangeMinimum 123 | > : Hint Set Range Maximum: 124 | > ---X--- [__] @ttfautohintHintSetRangeMaximum 125 | > : Hint Limit: 126 | > ---X--- [__] @ttfautohintHintLimit 127 | > [ ] No Hinting Limit @ttfautohintNoHintLimit 128 | > : X Height Increase Limit: 129 | > ---X--- [__] @ttfautohintXHeightIncreaseLimit 130 | > [ ] No X Height Increase Limit @ttfautohintNoXHeightIncreaseLimit 131 | > --- 132 | > [ ] Fallback Script (Latin) @ttfautohintFallbackScript 133 | > [ ] Pre Hinted @ttfautohintPreHinted 134 | > [ ] Symbol Font @ttfautohintSymbolFont 135 | > [ ] Add ttfautohint Info @ttfautohintAddTTFAutohintInfo 136 | > [ ] Override Font License Restrictions @ttfautohintOverrideFontLicenseRestrictions 137 | > : Stem Width and Positioning: 138 | > [ ] Gray Scale @ttfautohintGrayScale 139 | > [ ] GDI ClearType @ttfautohintCDIClearType 140 | > [ ] DW ClearType @ttfautohintDWClearType 141 | 142 | > !§ HTML Preview 143 | > : HTML Preview: 144 | > * CodeEditor @webFontsHtmlPreview 145 | > : CSS Style: 146 | > * CodeEditor @webFontsHtmlPreviewCSS 147 | 148 | 149 | * Tab: Variable Fonts = ScrollingTwoColumnForm @variableFontsForm 150 | > : Generate: 151 | > [ ] Interpolate to Fit Axis Extremes @variableFontsInterpolateToFitAxesExtremes 152 | > [ ] Autohint @variableFontsAutohint 153 | > : Suffix: 154 | > [_ _] @variableFontsSuffix 155 | 156 | * Tab: Batch Settings = ScrollingTwoColumnForm @batchSettingsForm 157 | > : 158 | > [ ] Export in sub-folders @batchSettingExportInSubFolders 159 | > --- 160 | > : 161 | > ( ) Use familyName-styleName @batchSettingExportKeepFileNames 162 | > ( ) Keep file names 163 | > --- 164 | > [ ] Store Export Report @batchSettingStoreReport 165 | > --- 166 | > [ ] Debug @batchSettingExportDebug 167 | 168 | =---= 169 | ( Cancel ) @cancel 170 | ( Apply ) @apply 171 | """ 172 | descriptionData = dict( 173 | desktopFontsForm=dict( 174 | titleColumnWidth=180, 175 | itemColumnWidth=300, 176 | ), 177 | webFontsForm=dict( 178 | titleColumnWidth=180, 179 | itemColumnWidth=300, 180 | ), 181 | variableFontsForm=dict( 182 | titleColumnWidth=180, 183 | itemColumnWidth=300, 184 | ), 185 | batchSettingsForm=dict( 186 | titleColumnWidth=180, 187 | itemColumnWidth=300, 188 | ), 189 | ttfautohintHintSetRangeMinimum=dict( 190 | valueType="integer", 191 | ), 192 | ttfautohintHintSetRangeMaximum=dict( 193 | valueType="integer", 194 | ), 195 | ttfautohintHintLimit=dict( 196 | valueType="integer", 197 | ), 198 | ttfautohintXHeightIncreaseLimit=dict( 199 | valueType="integer", 200 | ), 201 | cancel=dict( 202 | width=85, 203 | keyEquivalent=chr(27), 204 | ), 205 | apply=dict( 206 | width=85, 207 | ), 208 | ) 209 | self.w = ezui.EZSheet( 210 | parent=parent, 211 | content=content, 212 | descriptionData=descriptionData, 213 | size=(700, 500), 214 | minSize=(700, 250), 215 | defaultButton="apply", 216 | controller=self 217 | ) 218 | data = getExtensionDefault("com.typemytype.batch.settings", defaultSettings) 219 | self.w.setItemValues(data) 220 | 221 | self.ttfautohintHintLimit = self.w.getItem("ttfautohintHintLimit") 222 | self.ttfautohintXHeightIncreaseLimit = self.w.getItem("ttfautohintXHeightIncreaseLimit") 223 | self.ttfautohintNoHintLimitCallback(self.w.getItem("ttfautohintNoHintLimit")) 224 | self.ttfautohintNoXHeightIncreaseLimitCallback(self.w.getItem("ttfautohintNoXHeightIncreaseLimit")) 225 | 226 | def started(self): 227 | self.w.open() 228 | 229 | def ttfautohintNoHintLimitCallback(self, sender): 230 | self.ttfautohintHintLimit.enable(not sender.get()) 231 | 232 | def ttfautohintNoXHeightIncreaseLimitCallback(self, sender): 233 | self.ttfautohintXHeightIncreaseLimit.enable(not sender.get()) 234 | 235 | def cancelCallback(self, sender): 236 | self.w.close() 237 | 238 | def applyCallback(self, sender): 239 | setExtensionDefault("com.typemytype.batch.settings", self.w.getItemValues()) 240 | self.w.close() 241 | --------------------------------------------------------------------------------