Check out my first novel, midnight's simulacra!

Fonts: Difference between revisions

From dankwiki
(Created page with "Fonts can be installed by copying the appropriate .otf or .ttf file to ~/.fonts. Some fonts worth checking out: ==Inconsolata== * http://levien.com/type/myfonts/inconsolata.h...")
 
No edit summary
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
Fonts can be installed by copying the appropriate .otf or .ttf file to ~/.fonts. Some fonts worth checking out:
Fonts can be installed by copying the appropriate .otf or .ttf file to ~/.fonts.


==Inconsolata==
==Working with font-config==
* Dereference a font alias with `fc-match`:
<nowiki>
[schwarzgerat](0) $ fc-match sans-serif
DejaVuSans.ttf: "DejaVu Sans" "Book"
[schwarzgerat](0) $ </nowiki>
 
* What font is used for this character?
<nowiki>
#!/bin/sh
set -e
CHAR="$1"
for i in sans serif mono ; do
  FC_DEBUG=4 pango-view --font=$i -q -t "$CHAR" 2>&1 | \
    grep -o 'family: "[^"]\+' | cut -c 10- | tail -n 1
done</nowiki>
 
* Clear font cache/indexes: <tt>fc-cache -f -v</tt>
 
==Some fonts worth checking out==
===Inconsolata===
* http://levien.com/type/myfonts/inconsolata.html
* http://levien.com/type/myfonts/inconsolata.html
* http://www.google.com/webfonts/specimen/Inconsolata
* http://www.google.com/webfonts/specimen/Inconsolata
==Consolas==
===Consolas===
* http://www.microsoft.com/en-us/download/details.aspx?id=17879
* http://www.microsoft.com/en-us/download/details.aspx?id=17879
==Monaco==
===Monaco===
* http://www.gringod.com/wp-upload/software/Fonts/Monaco_Linux.ttf
* http://www.gringod.com/wp-upload/software/Fonts/Monaco_Linux.ttf
===Hack===
* https://github.com/source-foundry/Hack

Latest revision as of 09:42, 24 November 2020

Fonts can be installed by copying the appropriate .otf or .ttf file to ~/.fonts.

Working with font-config

  • Dereference a font alias with `fc-match`:
[schwarzgerat](0) $ fc-match sans-serif
DejaVuSans.ttf: "DejaVu Sans" "Book"
[schwarzgerat](0) $ 
  • What font is used for this character?
#!/bin/sh
set -e
CHAR="$1"
for i in sans serif mono ; do
  FC_DEBUG=4 pango-view --font=$i -q -t "$CHAR" 2>&1 | \
    grep -o 'family: "[^"]\+' | cut -c 10- | tail -n 1
done
  • Clear font cache/indexes: fc-cache -f -v

Some fonts worth checking out

Inconsolata

Consolas

Monaco

Hack