The Unix PC 3B1 system font, for modern computers

栏目: IT技术 · 发布时间: 6年前

内容简介:Convert the venerable AT&T UNIX PC font to the modern BDF bitmap formatThe

The UNIX PC 3B1 system font, for modern computers

Convert the venerable AT&T UNIX PC font to the modern BDF bitmap format

The unixpc-system.8.bdf font file that this tool produces has, for your convenience, been committed to the root of this respoitory. The font makes your Linux terminal look charmingly like the classic UNIX desktop machine of yore:

The Unix PC 3B1 system font, for modern computers

I want to thank Timothy Allen for his library bdflib which made this project not only possible but also fun.

Installation and Use

Create your ~/.fonts directory if it does not already exist, install the BDF font file from this repository, and activate ~/.fonts as an X Windows font directory. An xterm should then be able use the font:

mkdir -p ~/.fonts
wget -P ~/.fonts https://raw.githubusercontent.com/brandon-rhodes/unixpc-font-bdf/master/unixpc-system.8.bdf
mkfontdir ~/.fonts
xset fp+ ~/.fonts
xset fp rehash
xterm -fa '' -font '-unixpc-system-*' -fb '-unixpc-system-*'

Studying the UNIX PC base filesystem

The Makefile in this directory can not only build the font file, but also offers a few intermediate targets that might interest fans of the old UNIX PC:

  • make fs downloads the UNIX PC 3B1 "Foundation Set" and "Development Set" diskettes from www.unixpc.org and extracts them into the directory fs , giving you a base UNIX PC filesystem to browse right on your modern machine.

  • make font.h copies into the repository root the C header file that defines the UNIX PC binary .ft font file format, in case you want to study it yourself.

  • make foundation.cpio and make development.cpio download the raw floppy diskette contents without extracting them to a local directory, in case the raw CPIO archives are of more use to you.

Other fonts

If you want to study the other fonts that came with the UNIX PC, run make fs as described above, and then look inside the filesystem image:

$ ls -l fs/usr/lib/wfont/

You will find terminal fonts, several fonts offering special characters and drawing characters, and large-format fonts with much more detail than the basic 9x12 pixel font that the UNIX PC used by default. You can use the conversion program to turn any of them into a modern BDF file:

$ python convert.py fs/usr/lib/wfont/PLAIN.R.E.24.A > tmp.bdf

Design note

Pixels on the UNIX PC screen were not square: they were tall rectangles. This means that the UNIX PC 9x12 terminal font did not, in fact, display squarish little characters with a 3:4 aspect ratio, but taller and more elegant characters.

To simulate their appreance on a modern display where pixels are squares, the convert.py script sets an internal value scale = 2 that produces 2 rows of pixels for every 1 input row of pixels. While this, strictly speaking, produces an error in the other direction by making the letters stretch taller than they would have on the UNIX PC, the result is visually more beautiful and more readable.

If someone were to convert the font into a scalable format, then experiments could be made with intermediate ratios that even more closely matched the UNIX PC display. But I am happy enough with the double-height version of the font and am not at this point planning further experiments.


以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

数据结构

数据结构

邓俊辉 / 清华大学出版社 / 2013-9 / 39.00元

《清华大学计算机系列教材:数据结构(C++语言版)(第3版)》按照面向对象程序设计的思想,根据作者多年的教学积累,系统地介绍各类数据结构的功能、表示和实现,对比各类数据结构适用的应用环境;结合实际问题展示算法设计的一般性模式与方法、算法实现的主流技巧,以及算法效率的评判依据和分析方法;以高度概括的体例为线索贯穿全书,并通过对比和类比揭示数据结构与算法的内在联系,帮助读者形成整体性认识。一起来看看 《数据结构》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

在线进制转换器
在线进制转换器

各进制数互转换器

RGB HSV 转换
RGB HSV 转换

RGB HSV 互转工具