1
0
Fork 0
mirror of synced 2024-05-02 11:43:04 +12:00

Fira Code v3

This commit is contained in:
Nikita Prokopov 2020-04-09 18:56:19 +02:00
parent 1d7e14a927
commit 947ced5555
65 changed files with 255 additions and 162 deletions

File diff suppressed because one or more lines are too long

View file

@ -1,6 +1,6 @@
## Fira Code: monospaced font with programming ligatures
## Fira Code: free monospaced font with programming ligatures
<img src="./showcases/fira_code_logo.svg">
<img src="./extras/logo.svg">
### Problem
@ -8,60 +8,77 @@ Programmers use a lot of symbols, often encoded with several characters. For the
### Solution
#### [Download v.2](https://github.com/tonsky/FiraCode/releases/download/2/FiraCode_2.zip) · [How to install](https://github.com/tonsky/FiraCode/wiki) · [Troubleshooting](https://github.com/tonsky/FiraCode/wiki#troubleshooting) · [News & updates](https://twitter.com/FiraCode)
Fira Code is a free monospaced font containing ligatures for common programming multi-character combinations. This is just a font rendering feature: underlying code remains ASCII-compatible. This helps to read and understand code faster. For some frequent sequences like `..` or `//`, ligatures allow us to correct spacing.
<a href="https://patreon.com/tonsky" target="_blank"><img src="./fira_code_patreon.png"></a>
### Download & Install
Fira Code is an extension of the Fira Mono font containing a set of ligatures for common programming multi-character combinations. This is just a font rendering feature: underlying code remains ASCII-compatible. This helps to read and understand code faster. For some frequent sequences like `..` or `//`, ligatures allow us to correct spacing.
**<a href="https://github.com/tonsky/FiraCode/releases/download/3/FiraCode_3.zip">Download Fira Code v3</a>**
<img src="./showcases/all_ligatures.png">
Then:
- <a href="https://github.com/tonsky/FiraCode/wiki">How to Install</a>
- <a href="https://github.com/tonsky/FiraCode/wiki#troubleshooting">Troubleshooting</a>
- <a href="https://twitter.com/FiraCode">News & Updates</a>
### Support
<a href="https://github.com/sponsors/tonsky" target="_blank"><img src="./extras/sponsor.png"></a>
Fira Code is a personal, free-time project with no funding and huge [feature request backlog](https://github.com/tonsky/FiraCode/issues). If you love it, consider supporting its development via [GitHub Sponsors](https://github.com/sponsors/tonsky) or [Patreon](https://patreon.com/tonsky). Any help counts!
### Whats in the box?
Left: ligatures as rendered in Fira Code. Right: same character sequences without ligatures.
<img src="./showcases/v3/all_ligatures.png">
Fira Code comes with a few different character variants, so that everyone can choose whats best for them. [How to enable](https://github.com/tonsky/FiraCode/wiki/How-to-enable-stylistic-sets)
<img src="./showcases/v3/stylistic_sets.png">
In addition to that, Fira Code contains huge variety of Unicode characters well-suited for technical writing, math formulas and terminal UIs.
<img src="./showcases/v3/unicode.png">
### Code examples
Ruby:
<img src="./showcases/ruby.png">
<img src="./showcases/v3/ruby.png">
JavaScript:
<img src="./showcases/javascript.png">
<img src="./showcases/v3/javascript.png">
PHP:
<img src="./showcases/php.png">
<img src="./showcases/v3/php.png">
Erlang:
<img src="./showcases/erlang.png">
<img src="./showcases/v3/erlang.png">
Elixir:
<img src="/showcases/elixir.png">
<img src="/showcases/v3/elixir.png">
Go:
<img src="./showcases/go.png">
<img src="./showcases/v3/go.png">
LiveScript:
<img src="./showcases/livescript.png">
<img src="./showcases/v3/livescript.png">
Clojure:
<img src="./showcases/clojure.png">
<img src="./showcases/v3/clojure.png">
Swift:
<img src="./showcases/swift.png">
<img src="./showcases/v3/swift.png">
### Stylistic sets
See [How to enable](https://github.com/tonsky/FiraCode/wiki/How-to-enable-stylistic-sets)
<img src="./showcases/stylistic_sets.png">
### Terminal support
### Terminal compatibility list
| Works | Doesnt work |
| ------------------ | ------------------ |
@ -80,7 +97,7 @@ See [How to enable](https://github.com/tonsky/FiraCode/wiki/How-to-enable-stylis
| **Windows Terminal** |
| **ZOC** (macOS) |
### Editor support
### Editor compatibility list
| Works | Doesnt work |
| ----- | -------------- |
@ -184,17 +201,21 @@ code { font-family: 'Fira Code', monospace; }
### Alternatives
Other monospaced fonts with ligatures:
Other free monospaced fonts with ligatures:
- [Hasklig](https://github.com/i-tu/Hasklig) (free)
- [PragmataPro](http://www.fsd.it/fonts/pragmatapro.htm) (€59)
- [Monoid](http://larsenwork.com/monoid/) (free)
- [Fixedsys Excelsior](https://github.com/kika/fixedsys) (free)
- [Iosevka](https://be5invis.github.io/Iosevka/) (free)
- [DejaVu Sans Code](https://github.com/SSNikolaevich/DejaVuSansCode) (free)
- [Victor Mono](https://rubjo.github.io/victor-mono/) (free)
- [Cascadia Code](https://github.com/microsoft/cascadia-code) (free)
- [JetBrains Mono](https://github.com/JetBrains/JetBrainsMono) (free)
- [Hasklig](https://github.com/i-tu/Hasklig)
- [Monoid](http://larsenwork.com/monoid/)
- [Fixedsys Excelsior](https://github.com/kika/fixedsys)
- [Iosevka](https://be5invis.github.io/Iosevka/)
- [DejaVu Sans Code](https://github.com/SSNikolaevich/DejaVuSansCode)
- [Victor Mono](https://rubjo.github.io/victor-mono/)
- [Cascadia Code](https://github.com/microsoft/cascadia-code)
- [JetBrains Mono](https://github.com/JetBrains/JetBrainsMono)
Paid monospaced fonts with ligatures:
- [PragmataPro](http://www.fsd.it/fonts/pragmatapro.htm)
- [Mono Lisa](https://monolisa.dev/)
### Building Fira Code locally

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -64,7 +64,7 @@ take = (n, [x, <i>...</i>xs]:list) <i>--></i>
last3 = reverse <i>>></i> take 3 <i>>></i> reverse</div>
<div class="code semibold"><b># Fira Code Medium</b>
<div class="code semibold"><b># Fira Code SemiBold</b>
take = (n, [x, <i>...</i>xs]:list) <i>--></i>
| n <i><=</i> 0 <i>=></i> []

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

Before

Width:  |  Height:  |  Size: 56 KiB

After

Width:  |  Height:  |  Size: 56 KiB

BIN
extras/sponsor.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

BIN
extras/texture.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

26
script/build_variable Executable file
View file

@ -0,0 +1,26 @@
#!/bin/bash -e
rm -rf distr/variable_ttf
fontmake -g FiraCode.glyphs -o variable --output-dir distr/variable_ttf
# -------------------------------------------------------------
# fix variable font metadata as needed ------------------------
firaCodeVF=distr/variable_ttf/FiraCode-VF.ttf
# fix variable font metadata very important
gftools fix-vf-meta $firaCodeVF
# other fixes for metadata and hinting
gftools fix-nonhinting $firaCodeVF $firaCodeVF
gftools fix-gasp --autofix $firaCodeVF
gftools fix-dsig --autofix $firaCodeVF
# cleanup of temp files
tempFiles=$(ls distr/variable_ttf/*.fix && ls distr/variable_ttf/*-gasp*)
for temp in $tempFiles
do
rm -rf $temp
done
# TODO (late 2019?): use TTFautohint-VF for variable font (current support is minimal)

15
script/build_woff Executable file
View file

@ -0,0 +1,15 @@
#!/bin/bash -e
# requires sfnt2woff-zopfli (get from https://github.com/bramstein/homebrew-webfonttools)
rm -rf distr/woff
ttfs=$(ls distr/*/*.ttf)
for ttf in $ttfs; do
sfnt2woff-zopfli $ttf
done
mkdir -p distr/woff
woffs=$(ls distr/*/*.woff)
for woff in $woffs; do
mv $woff distr/woff/$(basename $woff)
done

15
script/build_woff2 Executable file
View file

@ -0,0 +1,15 @@
#!/bin/bash -e
# requires woff2_compress (get from https://github.com/bramstein/homebrew-webfonttools)
rm -rf distr/woff2
ttfs=$(ls distr/*/*.ttf)
for ttf in $ttfs; do
woff2_compress $ttf
done
mkdir -p distr/woff2
woff2s=$(ls distr/*/*.woff2)
for woff2 in $woff2s; do
mv $woff2 distr/woff2/$(basename $woff2)
done

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 123 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 266 KiB

BIN
showcases/v3/clojure.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

BIN
showcases/v3/elixir.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

BIN
showcases/v3/erlang.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View file

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

BIN
showcases/v3/go.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

BIN
showcases/v3/javascript.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

BIN
showcases/v3/livescript.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

BIN
showcases/v3/php.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 41 KiB

BIN
showcases/v3/ruby.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

View file

@ -1,29 +1,29 @@
.= .- := ::= =:= __
.= .- ..= := ::= =:= __
== != === !== =/= =!=
<-< <<- <-- <- <-> -> --> ->> >->
<=< <<= <== <=> => ==> =>> >=>
<=< <<= <== <<->> <=> => ==> =>> >=>
>>= >>- >- <~> -< -<< =<<
<-| <=| /\ \/ |-> |=>
<~~ <~ ~~ ~> ~~>
<<< << <= <> >= >> >>>
{. {| [| <: :> |] |} .}
<<< << <= <> >= >> >>>
{. {| [| <: :> |] |} .}
<||| <|| <| <|> |> ||> |||>
<$ <$> $>
<+ <+> +>
<* <*> *>
\ \\ /* */ /// //
\n \\ /* */ /// //
</ <!-- </> --> />
0xF www fl Fl Tl
0xF www Fl Tl Il fi fj
;; :: ::: !! ?? %% &&
|| .. ... ..< .? ?. ?:
|| .. ... ..< .? ?.
-- --- ++ +++ ** ***
~= ~- -~ ~@
=~ !~ ~- -~ ~@
^= ?= /= /==
-| _|_ |- ||- |= ||=
#! #= ## ### ####
@ -37,12 +37,22 @@ a-b a-A B-b A-B -a -A a- A-
a+b a+A B+b A+B +a +A a+ A+
a:b a:A B:b A:B :a :A a: A:
# Powerline
      
# Stylistic sets
r 0 123456789 & && $ <$ <$> $> @ <= >=
# Unicode
≢ ẞ ᐅ ᐊ ∴ ∵ ⎈ ‖ ∧ ⊢ ⊣ ⊥ ⊦ ⊧ ⊨ ⊩ ⊪ ⊫ ⊬ ⊭ ⊮ ⊯
⟲⟳ ⟰ ⟱ ⟴ ⟵ ⟶ ⟷ ⟸ ⟹ ⟺ ⟻ ⟼ ⟽ ⟾ ⟿
↩ ⇞ ⇟ ⇤ ⇥ ⌀ ⌃ ⌄ ⌅ ⌆ ⌘ ⌤ ⌥ ⎇ ⎋ ⏏ ☐ ☑ ☒
↩ ⇞ ⇟ ⇤ ⇥ ⌀ ⌃ ⌄ ⌅ ⌆ ⌘ ⌤ ⌥ ⎇ ⎋ ⏏ ☐ ☑ ☒ ▤ ▦ ▧ ▨ ▩
␆ ␈ ␇ ␣ ␢ ␘ ␍ ␐ ␡ ␥ ␔ ␑ ␓ ␒ ␙ ␃ ␄ ␗ ␅ ␛ ␜ ␌ ␝ ␉ ␊ ␕ ␤ ␀ ␞ ␏ ␎ ␠ ␁ ␂ ␚ ␦ ␖ ␟ ␋
𝔹 ∀ ∃ ∄ ∅ ⊂ ⊃ ⊄ ⊅ ⊆ ⊇ ⊈ ⊉ ⊊ ⊋ ∈ ∉ ∊ ∋ ∌ ∍
☰ ☱ ☲ ☳ ☴ ☵ ☶ ☷ 「a」 「a」
# Box drawing
@ -51,9 +61,15 @@ a:b a:A B:b A:B :a :A a: A:
╎ ╏ ┆ ┇ ┊ ┋
╰╍╍╍╍╯ ╰┅┅┅┅╯ ╰┉┉┉┉╯
┌─┬─┐ ╔╦═╗ ┏━┳┓ ╒═╤═╗ ╭─┰─╮
├─┼─┤ ╠╬═╣ ┣━╋┫ ├─┼─╢ ┝━╋━┥
└─┴─┘ ╚╩═╝ ┗━┻┛ ╘═╧═╝ ╰─┸─╯
# Blocks
|███ | 50%
|███ | 50%
▖ ▗ ▙ ▚ ▛ ▜ ▞ ▟
▁▂▃▄▅▆▇█▀▔

Binary file not shown.

After

Width:  |  Height:  |  Size: 70 KiB

BIN
showcases/v3/swift.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 43 KiB

BIN
showcases/v3/unicode.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB