Skip to content

Commit

Permalink
Renamed input/output directories
Browse files Browse the repository at this point in the history
Also cleaned up README.
  • Loading branch information
rojiani committed Oct 4, 2017
1 parent 094e29f commit 885b583
Show file tree
Hide file tree
Showing 42 changed files with 31 additions and 22 deletions.
49 changes: 29 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,25 @@

![](img.png)

This repo contains:
1. A script [ligaturize.py](ligaturize.py) to add the ligatures from [Fira Code](https://github.com/tonsky/FiraCode) to a font without ligatures
2. Programming fonts with ligatures added (generated using the above script), including:

* Anonymous Pro
* CamingoCode
* Cousine
* DejaVu Sans Mono
* Droid Sans Mono
* Hack
* Inconsolata-g
* Inconsolata
* Meslo (sizes: LGL, LGLDZ, LGM, LGMDZ, LGS, LGSDZ)
* Oxygen Mono
* Roboto Mono
* SF Mono
* Ubuntu Mono
* edlo
**Add ligatures to any coding font!**

What this repo contains:
1. Programming fonts with ligatures added (in `output-fonts/`), including:
* Anonymous Pro
* CamingoCode
* Cousine
* DejaVu Sans Mono
* Droid Sans Mono
* Hack
* Inconsolata-g
* Inconsolata
* Meslo (sizes: LGL, LGLDZ, LGM, LGMDZ, LGS, LGSDZ)
* Oxygen Mono
* Roboto Mono
* SF Mono
* Ubuntu Mono
* edlo
2. A script [ligaturize.py](ligaturize.py) that adds the ligatures from [Fira Code](https://github.com/tonsky/FiraCode) to a font without ligatures

**Credit**: This awesome script was written by [IlyaSkriblovsky](https://github.com/IlyaSkriblovsky) for adding ligatures to Deja Vu Sans Mono ([dv-code-font](https://github.com/IlyaSkriblovsky/dv-code-font)). I've just made a few minor changes to generalize the script so that it works for any given font.

Expand All @@ -30,13 +31,21 @@ they are available via brew (`brew install fontforge`).
**Using the Fonts**: See the [FiraCode README](https://github.com/tonsky/FiraCode) for a list of supported editors.

## Using the Script ##
1. Move/copy the font you want to ligaturize into `source-fonts/`
1. Move/copy the font you want to ligaturize into `input-fonts/`
2. Run the script: `$ fontforge -lang=py ligaturize.py`
3. You'll be prompted for the name of the font, and the name for the generated font. Example:

```shell
❯ fontforge -lang=py ligaturize.py
...
Enter the source font filename (including extension): RobotoMono-Regular.ttf
Enter a name for your ligaturized font -- or press ENTER to use the same name: <PRESS ENTER>
...
Generated ligaturized font Roboto Mono L in ligaturized-fonts/RobotoMono.ttf
```

```shell
❯ fontforge -lang=py ligaturize.py
Copyright (c) 2000-2014 by George Williams. See AUTHORS for Contributors.
...
Enter the source font filename (including extension): RobotoMono-Regular.ttf
Enter a name for your ligaturized font -- or press ENTER to use the same name: RobotoMonoL
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file added input-fonts/SFMono-Regular.otf
Binary file not shown.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions ligaturize.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
import os

# Constants
SOURCE_FONT_DIR = "source-fonts"
OUTPUT_FONT_DIR = "ligaturized-fonts"
SOURCE_FONT_DIR = "input-fonts"
OUTPUT_FONT_DIR = "output-fonts"
COPYRIGHT = '\nProgramming ligatures added by Ilya Skriblovsky from FiraCode\nFiraCode Copyright (c) 2015 by Nikita Prokopov'

def get_input_fontname():
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file not shown.
Binary file not shown.
File renamed without changes.
File renamed without changes.
Binary file removed source-fonts/SFMono-Regular.otf
Binary file not shown.

0 comments on commit 885b583

Please sign in to comment.