Roman | ||
RomanMM | ||
.gitignore | ||
build.sh | ||
features.family | ||
features.tables | ||
FontMenuNameDB | ||
GlyphOrderAndAliasDB | ||
GlyphOrderAndAliasDB_TT | ||
hasklig_example.png | ||
LICENSE.txt | ||
ReadMe.html | ||
README.md | ||
relnotes.txt | ||
Roadmap.txt | ||
SourceCodePro.enc | ||
SourceCodeProReadMe.html | ||
SourceCodeProSample.png | ||
widthsAdjust.mark |
N.B. This is a fork of the Source Code Pro repository
Hasklig - Ligatures for Haskell code
Programming languages are limited to relatively few characters. As a result of a limited character set, combined character operators surfaced quite early, such as the widely used arrow (->
), comprised of a hyphen and greater sign. It looks like an arrow if you know the analogy and squint a bit.
Composite glyphs become especially problematic in languages such as Haskell which utilize these complicated operators (<-
, ::
, =>
, -<
, >>=
etc.) extensively (over 100 in lens
alone!). Prettified code improves readability considerably - some Haskell programmers have even resorted to unicode symbols (ie. ⇒
, ←
etc.). This opens a whole new can of worms. In addition to encoding/compatibility problems and all the reasons it never worked out in APL, these symbols are one-character-wide and therefore eye-strainingly small.
Hasklig solves this problem the way typographers have always solved ill-fitting characters which co-occur often: ligatures. The underlying code stays the same — only the representation changes.
Hasklig
Source Code Pro
Support
Let me know how your editor is supported.
Editors and terminals with known ligature support
- Leksah
- TextEdit
- Atom (add
text-rendering: optimizeLegibility;
to your.editor
css.) - Chocolat
- Kate
- KWrite
- gEdit
- Konsole
No ligature support
- iTerm2
- Terminal (OSX)
- Sublime Text (Vote for the enhancement here)
- MacVim
To Do
- Glyph substitution for
\
→λ
and.
→∘
- Terminal support (for example iTerm2)