The consolechars command loads a font into the EGA/VGA character generator, and optionally outputs the previous font. This command reads an 8xH font from the file and loads it into the character generator memory. Usually the font size H will be read from the file, but some file-formats do not contain enough information for this, especially the raw file format, which only contains the font bitmaps. In this case, H will be computed from the file size, which implies these files cannot be compressed. If the input file has codepage format, containing the three fonts 8x8, 8x14 and 8x16, one of the options -H 8, -H 14 or -H 16 must be used to select one. Codepage format is also recognized by size, and cannot be compressed.
Display a short help message and exit.
Display version-number and exit.
Display on stderr informations on what's going on.
Do not change the console state; do not write anything to any file. Implies --verbose.
Activate the G1 charset instead of G0 (see --acm).
The font file is a file containing the bitmap-description (glyph) of characters. Since fonts may contain the glyphs for arbitrary character-sets, knowledge about these characters may come either in the font-file (eg. in PSF files), or in separate screen-font-map files (see --sfm option).
Raw font files are binary files of size 256*H bytes, containing bit images for each of 256 characters, one byte per scan line, and H bytes per character (0 H H is computed from the file-size, thus raw font files cannot be compressed. The other font-formats are described elsewhere.
Load a default font. The -H option can be given to force a given char-height.
-m --acm --app-charset-map=file
Load a user-defined Application-Charset Map (ACM) - save current ACM. The mapping from 8-bit characters sent to the screen into Unicode (UCS2) characters by the running application is described by an ACM (formerly called screen map). This map characterizes the 8-bit encoding used by the application, hence its new name. If no ACM is provided using the --acm option, the trivial map is assumed. Unless the --g1 option in specified, the G0 charset is then selected, and set to use the ACM just loaded. If --g1 is specified, the G1 charset is used instead of G0.
There are 2 types of ACM's recognized by the --acm option, which can be fed in binary or ASCII form. Binary maps are checked by size, and contain an array of 256 bytes (old style 8-bit to font-position maps) or 256 unicodes (8-bit to UCS2 maps). Because of this check, you should not compress or pipe them. In the ASCII format, new style (UCS2) ACM's are composed of lines of the form `byte unicode' where each first byte is the one to map (from the Application-Charset), in either of the C decimal, octal, hex, or character syntaxes for integers, and the unicode is formed either with the `U+' prefix and 4 hex digits, or with an UTF8-encoded character enclosed between single quotes; unspecified mappings default to ASCII (identity) for characters in the range 0-127, and to 0xFFFD (the replacement character) for those in the range 128-255. Old style (8-bit) maps in the ASCII format are composed of lines of the form `byte byte' where the first byte has the same meaning as above, and the second one is the position in the font; unspecified mappings default to straight-to-font identity mapping. An old-style mapping is equivalent to a new-style mapping where the second byte b would be replaced by the unicode U+F000 | b, ie. in the straight-to-font zone. However, due to the differences of defaults regarding unspecified mappings, just converting each mapping individually will not be sufficient to get an equivalent ACM.
Saves the previous ACM can be saved to a file.
-u --sfm --screen-font-map=file
Load a Screen Font Map (SFM) The correspondance between Unicode values and the glyphs in the curent console-font is described by a Screen-Font Map (formerly called Unicode mapping table). Some fonts have a SFM included in the font file, and an explicit one can be indicated using the --sfm option. consolechars will load such a builtin SFM, unless a --force-no-sfm option is given. One may add a SFM to a psf font using psfaddtable(1).
Prevent the loading of a SFM when loading a font containing one. You should use this option with care, as you probably don't want to have a font without a SFM; it could cause trouble.
Save current SFM into a file.
Use the given file as a SFM fallback table, to supplement the SFM. Multiple -k options may be given.
A fallback table tells, for some UCS2 characters you're interested to display, which character's glyph it may use if its own is not available according to the SFM in use.
If a SFM was to be loaded, fallback mappings are added to this map before it is loaded. If there was not (ie. no --sfm option was given, and a font without SFM was loaded, or the --force-no-sfm option was given), then the current SFM is requested from the kernel, the the fallback mappings are added, and the resulting SFM is loaded.
Save old font in the prefered format. It is currently the same as using --old-font-psf-with-sfm, but may change when a better format is supported.
Save old font in PSF format, with corresponding SFM (PSF mode 2 or 3).
Save old font in PSF format (PSF mode 0 or 1). Usually a bad idea.
Save old font in RAW format. Usually an even worse idea.
/usr/share/consolefonts/ is the default directory for fonts.