vt(4) fnt format

Ed Maste emaste at freebsd.org
Mon Dec 21 15:12:41 UTC 2020


On Mon, 21 Dec 2020 at 09:45, Daniel Lovasko <daniel.lovasko at gmail.com> wrote:
>
> Hello,
>
> The vt(4) virtual terminal allows changing the current font via the
> vidcontrol(1) utility. Some fonts can be found in "/usr/share/vt/fonts",
> where these font files have the ".fnt" extension.
>
> Is there an available description of this format?

The data structures are defined in sys/sys/font.h, and there are some
comments that explain the format. As I look now though I see at least
one error that I'll correct soon (the comment refers to two glyph
maps, but there are four).

A font file starts with a font_header struct, followed by glyph data
(of size determined by fh_width, fh_height, and fh_glyph_count) and
four sets of maps (each of a size determined by fh_map_count[]).


More information about the freebsd-hackers mailing list