2022 Developer Survey is open! Take survey.

Hot answers tagged

106 votes

How to view a TTF font file?

I use character maps heavily and decides to make one which you access from anywhere using a web interface and requires no installation. Works best on Chrome. Features Select your own font file ...
user avatar
52 votes

Fix terminal after displaying a binary file

I've had an occasion where none of the usual tricks, reset or stty sane, worked (after accidentally calling print on a python bytearray). I had success with method 2 listed on this helpful blog. I've ...
user avatar
48 votes
Accepted

Do any open source Linux terminals and fonts support ligatures?

So there are a few open source fonts targeting programmers that support ligatures, namely FiraCode Hasklig Monoid Iosevka CascadiaCode However, very few opensource terminals that run natively on ...
user avatar
  • 22.5k
38 votes
Accepted

How Can I Improve the Font Rendering In Firefox

I've had this issue for ages, maybe it's time to do something about it! It comes done to ClearType, Microsoft and patents from what I read. Most *nix distro's disable any patent protected font ...
user avatar
  • 1,071
34 votes
Accepted

Find font file from font name on Linux

Have you tried ? fc-list | grep -i "media" Also give a try to fc-scan, fc-match
user avatar
  • 13.5k
31 votes
Accepted

Command to list all monospace fonts known to fontconfig

The command fc-list can list all available fonts according to their properties. In your case one needs to search for the spacing corresponding to mono, that would be 100, so fc-list :spacing=100. ...
user avatar
  • 43.1k
30 votes

Find the best font for rendering a codepoint

Using fontconfig, > fc-list ':charset=<hex_code1> <hex_code2>' e.g. > fc-list ':charset=2713 2717' will display any font filenames containing ✓ and ✗. To get the codepoint ...
user avatar
28 votes

Is there a unix command line tool that can analyze font files?

In Linux, if you have .ttf fonts, you most probably also have fontconfig, which comes with the fc-scan utility. You can parse the output for the information you want, or use the badly documented --...
user avatar
  • 2,948
28 votes
Accepted

Why won't some unicode characters print to my terminal?

help printf defers to printf(1) for the escape sequences interpreted, and the docs for GNU printf says: printf interprets two character syntaxes introduced in ISO C 99: \u for 16-bit Unicode (ISO/...
user avatar
  • 64k
26 votes

How to view a TTF font file?

display OpenSans-CondBold.ttf display is part of imagemagick, so you will need it to be installed. Answer possible thanks to this forum post. This problem has been bugging me for years, because it ...
user avatar
  • 2,126
25 votes

How to install Microsoft True Type fonts for Centos 7?

This is documented at: http://mscorefonts2.sourceforge.net/ yum install curl cabextract xorg-x11-font-utils fontconfig yum install https://downloads.sourceforge.net/project/mscorefonts2/rpms/msttcore-...
user avatar
20 votes
Accepted

Where can I find a modern version of the "rock" (or "t") console typeface?

AFAIK there is no existing ports of this font to any outline variant. Here are however some detail, and hacks, that might help you on the way. The t.fnt, Tektite, was created by the (former?) clySmic ...
user avatar
  • 26.1k
20 votes
Accepted

How does fontconfig actually work?

TL;DR: Understanding fontconfig requires understanding why it was created and what problems it is trying to solve. That require a lot of understanding of Xorg. Font configuration on UNIX machines ...
user avatar
  • 8,173
19 votes

How to make Chinese characters display properly on Chromium

This page has specific information for installing font packages on Debian. https://en.wikipedia.org/wiki/Help:Multilingual_support_(East_Asian) Chinese (both Simplified & Traditional) Serif: ...
user avatar
  • 627
19 votes
Accepted

Set system font in LXDE?

I found it - the "Default font" combo is (mis)placed in the "Widget" tab. I really don't understand why they didn't put it in the "Font" tab.
user avatar
  • 5,360
18 votes

What fonts are good for unicode glyphs

I came across this in 2016. A single TTF/OTF font is never going to cover all utf-8 characters. There is a hard limit of 65535 glyphs in a font, and over 1 million utf-8 glphys. You will need to use ...
user avatar
18 votes
Accepted

How do I figure out which font file is chosen for a system generic font alias?

fc-match is the utility to use. For example, fc-match monospace will tell you the font used for monospace, and fc-match -s monospace will tell you fallback fonts as well, in order. The first font on ...
user avatar
18 votes
Accepted

How to get the real name of font?

Check the output from the fc-list command (in a terminal window): /usr/share/fonts/TTF/LiberationMono-Italic.ttf: Liberation Mono:style=Italic /usr/share/fonts/TTF/VeraMono.ttf: Bitstream Vera Sans ...
user avatar
  • 563
17 votes
Accepted

What is the GNOME Classic Monospace font?

You can use fc-match to see which fonts match that pattern: # fc-match "Monospace" DejaVuSansMono.ttf: "DejaVu Sans Mono" "Book" To see the whole priority list matching that pattern, use: fc-match -...
user avatar
  • 1,715
16 votes

Find the best font for rendering a codepoint

This is not necessarily the best method, and it sure isn't user-friendly, but it's easy to get working: here's a Python script to do it. Install the Python-fontconfig library. Either get it from your ...
user avatar
15 votes

Fix terminal after displaying a binary file

No single prior answer worked for me. But this seemed to do the trick in .bashrc add: alias fix='reset; stty sane; tput rs1; clear; echo -e "\033c"' and then when the problem occurs type this (even ...
user avatar
14 votes

How can I find the default (font) resource XTerm is using?

You can use lsof to list all files by given process id and grep for fonts. lsof -p <process_id_of_xterm> | grep fonts for example, lsof -p `ps -a | grep xterm | cut -d' ' -f1` | grep fonts ...
user avatar
  • 141
14 votes

How to install many fonts at once on Linux?

If you need to install a lot of fonts, then copy the files to ~/.fonts or /usr/share/fonts for system-wide installation and issue the command fc-cache -fv.
user avatar
  • 4,366
14 votes
Accepted

Larger "xterm" fonts on HIDPI displays

You have hinted the answer yourself by referencing https://en.wikipedia.org/wiki/Fixed_(typeface) This is the standard fixed bitmap font which has been expanded by Markus Kuhn to have a rather ...
user avatar
13 votes
Accepted

Strange character overlap in terminal

For terminal emulators, you should choose a monospace (a.k.a. fixed with) font. The letters are positioned in a grid, rather than as it would look nice according to the width of each individual letter....
user avatar
  • 4,500
13 votes
Accepted

Using Consolas font on Linux

The most hassle-free way to install a font that doesn't come prepackaged by your distribution is probably to drop it under /usr/local/share/fonts or ~/.fonts. For this, you need the font file in some ...
user avatar
  • 26.3k
12 votes

Can I change the font of the text-mode console?

/etc/default/console-setup et al. have been superseded on systemd operating systems, although you will find that some operating systems such as Debian try to maintain the older configuration system. ...
user avatar
  • 62.1k
12 votes
Accepted

Font size issues with Emacs in linum-mode

You can just define the linum size in your init config so it doesn't depend on default-face: (set-face-attribute 'linum nil :height 100) If you are not using linum-mode as a global default (ie such ...
user avatar
  • 136
11 votes
Accepted

Where can I set global Java Options?

You know how to set the variable in a shell, but for the record you can write: export _JAVA_OPTIONS='-Dawt.useSystemAAFontSettings=on' and all programs you start from this shell session after that ...
user avatar
11 votes

How can I set the default font size for all Qt5 apps?

QT_DEVICE_PIXEL_RATIO is deprecated since 5.4; instead, use QT_SCALE_FACTOR. I use it, setting it to 1.5, with good results (e.g., VirtualBox 5.1)
user avatar
  • 111

Only top scored, non community-wiki answers of a minimum length are eligible