README.md
1```
2
3 ::::::::::::::::::::
4 ::: :::
5 _____ _______ __. ________ ________ ________. :::
6 _) _//__ __/ __ / |.\ __ /.\ __ /.\ _. | :::
7 .\____ /.\ )/ / || )/ | )/ | \| | :::
8 | )/ | __/| \ _____| _____| | |_ :::
9 |____ |_____| |_____/____\\ |____\\ | |____/ :::
10 - -- -- \_____| -H7--------------------------- `----' ----- ::: - -
11 ::: :::
12 ::::::::::::::::::::
13
14```
15
16# Spleen
17
18Spleen is a monospaced bitmap font available in 6 sizes:
19
20- 5x8
21- 6x12
22- 8x16
23- 12x24
24- 16x32
25- 32x64
26
27Each size is provided in the Glyph Bitmap Distribution Format (BDF), and
28release tarballs contain the fonts in the following formats: `PCF`, `PSF`
29(for the Linux console), `OTB`, `OTF`, `WOFF`, `WOFF2`, `.dfont` for macOS
30users, and `FON` for Windows users.
31
32All font sizes contain all ISO/IEC 8859-1 characters (Basic Latin and Latin-1
33Supplement Unicode block), Latin Extended-A characters, as well as Box Drawing,
34Block Elements, and Braille Patterns Unicode blocks, except for the 5x8 and the
356x12 versions.
36
37Due to character size constraints, the 5x8 version only contains printable
38ASCII characters, the Braille Patterns Unicode block, and light Box Drawing
39characters. Please also note that there is no OpenType version for this size.
40
41As of Spleen 1.8.0, there is now a 6x12 version containing the same Unicode
42blocks as the 5x8 version and the Latin-1 Supplement Unicode block.
43
44As of Spleen 2.0.0, the 8x16, 16x32 and 32x64 versions have full support for
45Code page 437 (IBM PC).
46
47Spleen also has support for Powerline symbols out of the box.
48
49The font name is a reference to Baudelaire.
50
51## Screenshots
52
53The following screenshots show Spleen 16x32 displaying code and prose.
54
55![Spleen - Hello][1]
56
57![Spleen - L'etranger][2]
58
59ASCII characters for all sizes:
60
61Spleen 5x8:
62
63![Spleen - ASCII characters - 5x8][3]
64
65Spleen 6x12:
66
67![Spleen - ASCII characters - 6x12][4]
68
69Spleen 8x16:
70
71![Spleen - ASCII characters - 8x16][5]
72
73Spleen 12x24:
74
75![Spleen - ASCII characters - 12x24][6]
76
77Spleen 16x32:
78![Spleen - ASCII characters - 16x32][7]
79
80Spleen 32x64:
81![Spleen - ASCII characters - 32x64][8]
82
83## XLFD font names
84
85```
86-misc-spleen-medium-r-normal--8-80-72-72-c-50-iso10646-1
87-misc-spleen-medium-r-normal--12-120-72-72-c-60-iso10646-1
88-misc-spleen-medium-r-normal--16-160-72-72-c-80-iso10646-1
89-misc-spleen-medium-r-normal--24-240-72-72-c-120-iso10646-1
90-misc-spleen-medium-r-normal--32-320-72-72-c-160-iso10646-1
91-misc-spleen-medium-r-normal--64-640-72-72-c-320-iso10646-1
92```
93
94## Packages
95
96Spleen packages are available for:
97
98- [OpenBSD][9]
99- [NetBSD][10]
100- [FreeBSD][11]
101- [Arch Linux][12]
102- [Void Linux][13]
103- [Nix][14]
104- [Debian][15]
105- [Ubuntu][16]
106- [MacPorts][17]
107- [Guix][18]
108- [Gentoo][19]
109- [Alpine Linux][20]
110
111## Manual installation
112
113### *BSD and Linux
114
115Clone the repository, convert the files to the Portable Compiled Format
116(PCF) using **bdftopcf** and run **mkfontdir** in the directory.
117
118Alternatively, release tarballs provide PCF files for each size.
119
120OTB versions are also available.
121
122### macOS
123
124macOS users should use the `.dfont` files provided in the release tarballs.
125
126### DOS
127
128DOS users should run the **SPLEEN.COM** executable provided in the release
129tarballs to enable the font.
130
131This has been tested in DOSBox and FreeDOS on real hardware.
132
133### Windows
134
135Windows users should use the `.fon` or `.otf` files provided in the release
136tarballs.
137
138## Usage
139
140### *BSD and Linux
141
142Update the font path to include **Spleen**:
143
144 xset +fp /usr/local/share/fonts/spleen/
145
146Update **.Xdefaults** and add one of the following directives:
147
148 xterm*faceName: spleen:pixelsize=8:antialias=false
149 xterm*faceName: spleen:pixelsize=12:antialias=false
150 xterm*faceName: spleen:pixelsize=16:antialias=false
151 xterm*faceName: spleen:pixelsize=24:antialias=false
152 xterm*faceName: spleen:pixelsize=32:antialias=false
153 xterm*faceName: spleen:pixelsize=64:antialias=false
154
155Launch **xterm**.
156
157Ubuntu has bitmap fonts support disabled by default, instructions to enable
158it are available [here][21].
159
160### Linux console
161
162Release tarballs provide PSF files for each size, `setfont` can be used
163to load and set the desired font.
164
165### NetBSD console
166
167NetBSD has .fnt files for each size which can be loaded using wsfontload(8).
168
169For example, to load Spleen 16x32:
170
171 wsfontload -N spleen-16x32 -w 16 -h 32 /usr/share/wscons/fonts/spleen-16x32.fnt
172 wsconsctl -dw font=spleen-16x32
173
174### FreeBSD console
175
176The FreeBSD package contains .fnt files which can be loaded using
177vidcontrol(1).
178
179For example, to load Spleen 16x32:
180
181 vidcontrol -f /usr/local/share/fonts/spleen/spleen-16x32.fnt
182
183### OpenType versions
184
185Spleen release tarballs now contains OTF versions generated automatically
186from the BDF files, using [bdf2sfd][22]. Each font has a different name,
187allowing them to be installed alongside.
188
189Please note that OTF versions should be used as last resort, always prefer
190bitmap versions if they are supported on your platform.
191
192They should be used in the exact size specified below, with anti-aliasing
193disabled.
194
195- Spleen 6x12: 9 Pt (12 pixels)
196- Spleen 8x16: 12 Pt (16 pixels)
197- Spleen 12x24: 18 Pt (24 pixels)
198- Spleen 16x32: 24 Pt (32 pixels)
199- Spleen 32x64: 48 Pt (64 pixels)
200
201### Web Fonts
202
203Release tarballs provide WOFF and WOFF2 versions suitable for use on the Web.
204
205As with the OpenType versions from which they are generated, WOFF and WOFF2
206fonts should be used at their native pixel sizes, with font smoothing and
207anti-aliasing disabled when possible, to preserve the original bitmap
208appearance.
209
210## License
211
212Spleen is released under the BSD 2-Clause license. See `LICENSE` file for
213details.
214
215## Author
216
217Spleen is developed by Frederic Cambus.
218
219- Site: https://www.cambus.net
220
221## Resources
222
223- [Spleen - Monospaced bitmap fonts][23] (2018)
224- [New console font Spleen made default][24] (2019)
225- [NetBSD, CTWM, and Spleen][25] (2021)
226- [Spleen 2.0.0 released with full CP437 support][26] (2023)
227
228GitHub: https://github.com/fcambus/spleen
229
230## Trivia
231
232- Spleen was imported in the OpenBSD src tree in [September 2018][27]
233- Spleen is the default font for OpenBSD consoles since [January 2019][28]
234- Spleen was imported in the NetBSD src tree in [March 2019][29]
235- Spleen 12x24 was used in the Haiku [kernel debugger][30] (on high resolution
236 displays) from May 2021 to June 2022
237- Spleen was imported in the FreeBSD base system in [May 2023][31]
238- [msTERM][32], a Terminal program for MailStation devices uses Spleen 5x8
239- [FBInk][33], a library to print text & images to an eInk Linux framebuffer
240 embeds Spleen 16x32
241- [U8g2][34], a monochrome graphics library for embedded devices includes
242 all Spleen sizes
243- [Ansilove][35], an ANSI and ASCII art to PNG converter includes Spleen
244
245[1]: https://www.cambus.net/content/2018/09/spleen-hello.png
246[2]: https://www.cambus.net/content/2018/09/spleen-etranger.png
247[3]: https://www.cambus.net/files/spleen/spleen-5x8.png
248[4]: https://www.cambus.net/files/spleen/spleen-6x12.png
249[5]: https://www.cambus.net/files/spleen/spleen-8x16.png
250[6]: https://www.cambus.net/files/spleen/spleen-12x24.png
251[7]: https://www.cambus.net/files/spleen/spleen-16x32.png
252[8]: https://www.cambus.net/files/spleen/spleen-32x64.png
253[9]: https://openports.pl/path/fonts/spleen
254[10]: https://pkgsrc.se/fonts/spleen
255[11]: https://www.freshports.org/x11-fonts/spleen/
256[12]: https://aur.archlinux.org/packages/spleen-font/
257[13]: https://github.com/void-linux/void-packages/tree/master/srcpkgs/font-spleen
258[14]: https://github.com/NixOS/nixpkgs/tree/master/pkgs/by-name/sp/spleen
259[15]: https://packages.debian.org/search?keywords=spleen
260[16]: https://packages.ubuntu.com/search?keywords=spleen
261[17]: https://ports.macports.org/port/font-spleen/
262[18]: https://packages.guix.gnu.org/packages/font-spleen/
263[19]: https://packages.gentoo.org/packages/media-fonts/spleen
264[20]: https://pkgs.alpinelinux.org/packages?name=font-spleen
265[21]: https://wiki.ubuntu.com/Fonts#Enabling_Bitmapped_Fonts
266[22]: https://github.com/fcambus/bdf2sfd
267[23]: https://www.cambus.net/spleen-monospaced-bitmap-fonts/
268[24]: https://undeadly.org/cgi?action=article;sid=20190110064857
269[25]: https://www.cambus.net/netbsd-ctwm-and-spleen/
270[26]: https://www.cambus.net/spleen-2.0.0-released-with-full-cp437-support/
271[27]: https://freshbsd.org/openbsd/src/commit/5raMrDMpYlPYW01H
272[28]: https://freshbsd.org/openbsd/src/commit/MoBCxKiAlFajRvSm
273[29]: https://freshbsd.org/netbsd/src/commit/TAJuMl9caBpVjGfB
274[30]: https://git.haiku-os.org/haiku/commit/?id=29a109bd6c01ce71bb61177ee9ff0417e74c1e18
275[31]: https://cgit.freebsd.org/src/commit/?id=0d66206fff44
276[32]: https://github.com/jcs/msTERM
277[33]: https://github.com/NiLuJe/FBInk
278[34]: https://github.com/olikraus/u8g2/wiki/fntgrpspleen
279[35]: https://www.ansilove.org
280