mirror of
https://github.com/ToxicFrog/Ligaturizer.git
synced 2024-09-11 09:55:47 +03:00
Programming Fonts with Ligatures added (& a script to add them to other fonts)
coding-fontsfontfont-ligaturesligaturesmonospace-fontprogramming-fontprogramming-fontsstarred-repostarred-toxicfrog-repo
images | ||
input-fonts | ||
output-fonts | ||
.gitignore | ||
FiraCode-Medium.otf | ||
ligatures.py | ||
ligaturize.py | ||
README.md |
Ligaturizer
Add ligatures to any coding font!
This repo contains 2 things:
- Programming fonts with ligatures added (in
output-fonts/
), including:
- Anonymous Pro
- CamingoCode
- Cousine
- DejaVu Sans Mono
- Droid Sans Mono
- edlo
- Hack
- Inconsolata & Inconsolata-g
- IBM Plex Mono: Regular, Semibold
- Meslo (LGL, LGLDZ, LGM, LGMDZ, LGS, LGSDZ)
- Oxygen Mono
- Roboto Mono
- SF Mono: Regular, Semibold
- Ubuntu Mono
- A fontforge python script (ligaturize.py) that adds the ligatures from Fira Code to a font without ligatures
Here's a couple examples of the fonts generated: SF Mono with ligatures (note the !=
and ->
):
Credit This awesome script was written by IlyaSkriblovsky for adding ligatures to Deja Vu Sans Mono (dv-code-font). I made a few changes to generalize the script so that it works for any font, so that I could add ligatures to my favorite fonts.
Requirements
Using the Fonts: See the FiraCode README for a list of supported editors.
Script: This script requires FontForge python bindings. For Debian/Ubuntu they are available in python-fontforge
package. For macOS,
they are available via brew (brew install fontforge
).
Using the Script
- Move/copy the font you want to ligaturize into
input-fonts/
(or somewhere else convenient). - Edit
ligatures.py
to disable any ligatures you don't want. - Run the script:
$ fontforge -lang=py ligaturize.py <INPUT> <OUTPUT>
, e.g.$ fontforge -lang=py ligaturize.py input-fonts/Cousine-Regular.ttf output-fonts/CousineLigaturized-Regular.ttf
Misc.
For more awesome programming fonts with ligatures, check out: