MAPSCRN(8)
โจ mapscrn(8) โ the System Manager's Manual page, but make it a group chat โจ
okay bestie, gather round, because we're talking about mapscrn โ a little command from the kbd world, living in section 8 of the manual (that's the system manager's manual, for the girlies keeping notes ๐
).
๐ NAME ๐
mapscrn โ load screen output mapping table. that's it. that's the whole job. loading a mapping table for your screen output. iconic behavior honestly ๐
๐ธ SYNOPSIS ๐ธ
mapscrn [options] mapfile
you give it some options, you give it a mapfile, it does the thing. simple as. โจ
๐ฆ DESCRIPTION ๐ฆ
okay so first things first, and I need you to sit down for this one: mapscrn is obsolete. ๐ญ fr fr. its whole function got built-in into setfont. BUT โ and this is the important part โ for backwards compatibility it's still hanging around as its own separate command. so it's giving retired-but-still-shows-up-to-the-party energy. we love her for that ๐
so what does she actually do? the mapscrn command loads a user defined output character mapping table into the console driver. ๐ซถ
and then โ plot twist โ the console driver can later be put into use user-defined mapping table mode by outputting a special escape sequence to the console device. that sequence is:
<esc>(Kfor the G0 character set<esc>)Kfor the G1 character set
and when you pass the -o option, the old map gets saved in map.orig. keeping receipts, as she should. ๐
๐ง USE ๐ง
so there are two kinds of mapping tables and you need to know which one you're dealing with:
- direct-to-font tables โ these give a font position for each user byte value.
- user-to-unicode tables โ these give a unicode value for each user byte.
and the corresponding glyph is now found using the unicode index of the font. iykyk ๐
now, examples because that's how we learn:
mapscrn trivial
this one sets up a one-to-one direct-to-font table where user bytes directly address the font. super useful for fonts that are in the same order as the character set one uses. lowkey perfect for that scenario โจ
and a command like:
mapscrn 8859-2
sets up a user-to-unicode table that assumes the user uses ISO 8859-2. periodt. ๐
๐ INPUT FORMAT ๐
mapscrn can read the map in either of two formats:
- 256 or 512 bytes binary data
- two-column text file
Format (1) is a direct image of the translation table. and here's the breakdown:
- the 256-bytes tables are direct-to-font
- the 512-bytes tables are user-to-unicode
Format (2) is used to fill the table as follows: the cell with the offset mentioned in the first column is filled with the value mentioned in the second column. and then โ vibe check โ when values larger than 255 occur, or values are written using the U+xxxx notation, the table is assumed to be a user-to-unicode table. otherwise? it's a direct-to-font table. no cap ๐ง
values in the file may be specified in one of several formats, and bestie there are six:
- Decimal: string of decimal digits not starting with
'0' - Octal: string of octal digits beginning with
'0' - Hexadecimal: string of hexadecimal digits preceded by
"0x" - Unicode: string of four hexadecimal digits preceded by
"U+" - Character: single character enclosed in single quotes. (and the binary value is used.) โ note that blank, comma, tab character and
'#'cannot be specified with this format. ๐ - UTF-8 Character: single (possibly multi-byte) UTF-8 character, enclosed in single quotes.
โ ๏ธ okay important one: control characters (with codes < 32) cannot be re-mapped with mapscrn because they have special meaning for the driver. that's not a suggestion, that's just how it is. ๐
๐ OPTIONS ๐
-o,--output=FILEโ save the old map to the FILE. keeping the old one safe, we love a backup moment ๐พ-C,--console=DEVโ the console device to be used.-v,--verboseโ be more verbose. she's a talker, let her talk ๐ฃ๏ธ-V,--versionโ print version number.-h,--helpโ print this usage message.
๐ FILES ๐
/usr/share/kbd/consoletransโ the default directory for screen mappings. that's home base bestie ๐
๐ SEE ALSO ๐
setfont(8)โ the main character who absorbedmapscrn's whole job. go say hi ๐
โญ AUTHOR โญ
Copyright (C) 1993 Eugene G. Crosser <crosser@pccross.msk.su>
This software and documentation may be distributed freely. ๐ซถ (generous queen behavior, honestly)
and that's the whole page bestie!! โจ this was the kbd manual page, dated 24 October 2024, and you can find it filed under MAPSCRN(8). go forth and map those screens, you've got this ๐
๐๐ฆ๐ธ๐
๐ฆ where this page comes from
- arch rolling: kbd 2.10.0-1 ยท GPL-2.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- opensuse-leap 16.0: kbd 2.7.1-160000.3.1 ยท GPL-2.0-or-later AND GPL-3.0-or-later
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms