MAN page from Mandrake Other console-tools-19990415-10mdk.i586.rpm
CONSOLECHARS
Section: Linux User's Manual (8)
Updated: 31 Oct 1997
Index
NAME
consolechars - load EGA/VGA console screen font, screen-font map, and/orapplication-charset map.
SYNOPSIS
consolechars [-v|--verbose] [-V|--version] [-h|--help] [-1|--g1][-n|--no-act] [--force-no-sfm] [-H|--char-height=N][--tty=device][-m|--acm=|--app-charset-map=acm] [-M|--old-acm=acm.orig][-f|--font=font.new] [-F|--old-font=font.orig][--old-font-raw=font.orig] [--old-font-psf-with-sfm=font.orig.psf][--old-font-psf=font.orig.psf][-u|--sfm=|--screen-font-map=sfm] [-U|--old-sfm=sfm.orig][-k|--sfm-fallback]
DESCRIPTION
Theconsolecharscommand loads a font into the EGA/VGA character generator, and optionallyoutputs the previous font. This command reads an 8xHfont from the file and loads it into the character generator memory. Usuallythe font sizeHwill be read from the file, but some file-formats do not contain enoughinformation for this, especially therawfile format, which only contains the font bitmaps. In this case, H will becomputed from the file size, which implies these files cannot be compressed.If the input file has codepage format, containing the three fonts 8x8, 8x14and 8x16, one of the options-H 8, -H 14 or -H 16must be used to select one. Codepage format is also recognized by size, andcannot be compressed.
As currently there is no mode switching support in the Linux kernel, consolecharshas nothing to do with the current EGA/VGA mode. It's totally user'sresponsibility to choose a font matching the current video mode.
OPTIONS
- -h --help
- Display a short help message and exit.
- -V --version
- Display version-number and exit.
- -v --verbose
- Display onstderrinformations on what's going on.
- -n --no_act
- Do not change the console state; do not write anything to any file. Implies--verbose.
- -1 --g1
- Activate the G1 charset instead of G0 (see--acm).
- --tty=device
- Usedeviceas console device for ioctls, instead of guessing which one to use,which usually chooses the current tty. This can be useful for testingwhen under X, in conjunction with--no-act- actual ioctls are refused for some reason then.
COMMANDS
- -f --font=file
- Thefont fileis a file containing the bitmap-description (glyph) of characters. Sincefonts may contain the glyphs for arbitrary character-sets, knowledge aboutthese characters may come either in the font-file (eg. in PSF files), or inseparate screen-font-map files (see--sfmoption).
Font-files can be compressed withgzip(1) or compress(1),with the exception ofraw and codepagefile-formats.
Raw font files are binary files of size 256*Hbytes, containing bit images for each of 256 characters, one byte per scanline, and Hbytes per character (0 < H<= 32); His computed from the file-size, thus raw font files cannot be compressed. Theother font-formats are described elsewhere.
- -d --default-font
- Load a default font. The-Hoption can be given to force a given char-height.
- -m --acm --app-charset-map=file
- Load a user-definedApplication-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 calledscreen map).This map characterizes the 8-bit encoding used by the application, hence itsnew name. If no ACM is provided using the--acmoption, thetrivialmap is assumed. Unless the--g1option in specified, theG0charset is then selected, and set to use the ACM just loaded. If--g1is specified, theG1charset is used instead of G0.There are 2 types of ACM's recognized by the--acmoption, which can be fed in binary or ASCII form. Binary maps are checked bysize, and contain an array of 256 bytes (old style 8-bit to font-positionmaps) or 256 unicodes (8-bit to UCS2 maps). Because of this check, you shouldnot 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), ineither of the C decimal, octal, hex, or character syntaxes for integers, andthe unicode is formed either with the `U+' prefix and 4 hex digits, or withanUTF8-encoded characterenclosed between single quotes; unspecified mappings default to ASCII(identity) for characters in the range 0-127, and to 0xFFFD (the replacementcharacter) 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 theposition in the font; unspecified mappings default to straight-to-fontidentity mapping.
An old-style mapping is equivalent to a new-style mapping where the secondbytebwould be replaced by the unicodeU+F000 | b,ie. in thestraight-to-font zone.However, due to the differences of defaults regarding unspecified mappings,just converting each mapping individually will not be sufficient to get anequivalent ACM.
- -M --old-acm=file
- 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 curentconsole-font is described by aScreen-Font Map(formerly calledUnicode mapping table).Some fonts have a SFM included in the font file, and an explicit one can beindicated using the--sfmoption.consolecharswill load such a builtin SFM, unless a--force-no-sfmoption is given. One may add a SFM to a psf font usingpsfaddtable(1). - --force-no-sfm
- Prevent the loading of a SFM when loading a font containing one. You shoulduse this option with care, as you probably don't want to have a font withouta SFM; it could cause trouble.
- -U --old-sfm=file
- Save current SFM into a file.
- -k --sfm-fallback=file
- Use the givenfileas a SFM fallback table, to supplement the SFM. Multiple-koptions may be given.
A fallback table tells, for some UCS2 characters you're interested todisplay, which character's glyph it may use if its own is notavailable according to the SFM in use.
If a SFM was to be loaded, fallback mappings are added to this mapbefore it is loaded. If there was not (ie. no--sfmoption was given, and a font without SFM was loaded, or the--force-no-sfmoption was given), then the current SFM is requested from the kernel,the the fallback mappings are added, and the resulting SFM is loaded.
- -F --old-font=file
- 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.
- --old-font-psf-with-sfm=file
- Save old font in PSF format, with corresponding SFM (PSF mode 2 or 3).
- --old-font-psf=file
- Save old font in PSF format (PSF mode 0 or 1). Usually a bad idea.
- --old-font-raw=file
- Save old font in RAW format. Usually an even worse idea.
- -H --char-height=N
- When loading a font from a codepage file, or a default font, specify whichfont-size to use.Nshould be a number between 1 and 31.
HISTORY
consolecharswas originally called
setfont(8),but was renamed (in version 1997.10.28 of the Linux Console Tools) to allowfor changing the command-line options while providing backward compatibilitywith the old `kbd' package.
FILES
/usr/lib/kbd/consolefonts/is the default directory for fonts.
/usr/lib/kbd/consoletrans/is the default directory for both ACM's and SFM's.
BUGS
For implementation reasons, binary ACM's and ASCII 8-bit ACM'scannot be compressed nor piped. This is not likely to change (except if agood reason is given to the maintainer, or a patch is submitted), because Iconsider these formats to be obsolete.
AUTHORS
Eugene G. Crosser <crosserAATTpccross.msk.su>
Andries E. Brouwer <aebAATTcwi.nl>
Extended by Yann Dirson <dirsonAATTdebian.org>
SEE ALSO
psfaddtable(1),
psfstriptable(1).
Index
- NAME
- SYNOPSIS
- DESCRIPTION
- OPTIONS
- COMMANDS
- HISTORY
- FILES
- BUGS
- AUTHORS
- SEE ALSO
This document was created byman2html,using the manual pages.