Date: Sun, 30 Jul 2000 16:40:03 -0700 (PDT) From: Ben Smithurst <ben@FreeBSD.org> To: freebsd-doc@freebsd.org Subject: Re: docs/20298: man 5 keymap missing in 4.1 (Stable) Message-ID: <200007302340.QAA16422@freefall.freebsd.org>
index | next in thread | raw e-mail
The following reply was made to PR docs/20298; it has been noted by GNATS.
From: Ben Smithurst <ben@FreeBSD.org>
To: eighner@io.com
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: docs/20298: man 5 keymap missing in 4.1 (Stable)
Date: Mon, 31 Jul 2000 00:20:27 +0100
eighner@io.com wrote:
> include keymap(5) if it exists or remove dead references to it.
ok, I've had a quick shot at this.
WARNING: WARNING: WARNING:
This is *NOT* by any means close to being complete, and some things
in it may be just plain wrong. Obviously I intend to make it a bit
more complete, and check things in a bit more detail by reading the
syscons/kbdcontrol source more carefully, but any comments on what
I've done so far would be welcome. The main things which are missing
really are definitions of most of the ASCII control codes, the other
kbdcontrol code words (those near the top of usr.sbin/kbdcontrol/lex.l)
and the accent names. Various quoting and other markup could probably
be improved too, but I'll get round to that soon.
.\" $FreeBSD$
.\"
.Dt KEYMAP 5
.Dd July 30, 2000
.Os
.Sh NAME
.Nm keymap
.Nd keyboard mapping files for
.Xr kbdcontrol 1
.Sh DESCRIPTION
The
.Nm
files which reside in
.Pa /usr/share/syscons/keymaps
provide a means for specifying the layout of the console keyboard.
The files are read by
.Xr kbdcontrol 1
which then configures the
.Xr syscons 4
driver appropriately.
.Pp
Each line of a
.Nm
file is either a
.Em key definition
line or an
.Em accent definition
line.
If the first field is numeric,
the line is assumed to be a key definition line,
otherwise the first field must be a valid accent code,
and the line is assumed to be an accent definition line.
Accent definition lines may continue over multiple lines.
.Pp
Each key definition line should consist of 10 fields:
.Pp
.Bl -bullet -compact
.It
.Em scan code .
XXX - describe this!
.It
.Em base .
This field specifies the action of the key when it is pressed alone.
.It
.Em shift .
.It
.Em cntrl .
.It
.Em cntrl shift .
.It
.Em alt
.It
.Em alt shift .
.It
.Em alt cntrl .
.It
.Em alt cntrl shift .
These seven fields specify the action of the key when it is pressed
in conjunction with the specified modifier key or keys.
.It
.Em lock state
XXX - describe this!
.El
.Pp
In each place that an action for a key is required,
that action may either be a single ASCII character,
enclosed within single quotes,
or a mnemonic code.
A single quoted ASCII character simply specifies that the action of the key
is to produce that character.
If a mnemonic code is used, it may be the string
.Ql nop ,
which specifies that no action should be taken,
one of the ASCII control character names,
or a mnemonic for another function.
.Pp
The following is a list of the ASCII control codes,
along with their ASCII character value.
.Pp
.Bl -tag -width "XXX (\XXX)"
.It nul (0)
A NUL byte.
.It soh (1)
.It stx (2)
.It etx (3)
.It eot (4)
.It enq (5)
.It ack (6)
.It bel (7)
Sounds the terminal's bell.
.It bs (8)
Backspace.
.It ht (9)
Horizontal tab.
.It nl (10)
Newline.
.It vt (11)
.It np (12)
.It cr (13)
Carriage return.
.It so (14)
.It si (15)
.It dle (16)
.It dc1 (17)
.It dc2 (18)
.It dc3 (19)
.It dc4 (20)
.It nak (21)
.It syn (22)
.It etb (23)
.It can (24)
.It em (25)
.It sub (26)
.It esc (27)
Escape.
.It fs (28)
.It gs (29)
.It rs (30)
.It us (31)
.El
.Pp
The following is a list of other valid mnemonics which do not correspond to
an ASCII control code.
.Pp
.Bl -tag -width XXXXXXXXXXXXXXX
.It Ql lshift
The left shift key.
.It Ql rshift
The right shift key.
.It Ql clock
The caps lock key.
.It Ql nlock
The num lock key.
.It Ql slock
The scroll lock key.
.It Ql lalt|alt
The left alt key.
.It Ql btab
.It Ql lctrl|ctrl
The left control key.
.It Ql nscr
.It Ql pscr
.It Ql rctrl
The right control key.
.It Ql ralt
The right alt key.
.It Ql alock
.It Ql ashift
.It Ql meta
.It Ql boot
Reboot the system.
.It Ql debug
Drop into the interactive kernel debugger
.Po
.Xr ddb 4
.Pc .
.It Ql susp
.It Ql saver
Activate the
.Xr syscons 4
screen saver,
if one is configured
(see also
.Xr splash 4 ) .
.It Ql panic
Call the
.Xr panic 9
kernel function.
.It Ql lshifta|shifta
.It Ql rshifta
.It Ql lctrla|ctrla
.It Ql rctrla
.It Ql lalta|alta
.It Ql ralta
.El
.Pp
Each accent definition should begin with the symbolic name of the accent
being defined:
.Bl -tag -width "XXXX"
.It Ql dgra
.It Ql dacu
Acute.
.It Ql dcir
Circumflex.
.It Ql dtil
.It Ql dmac
.It Ql dbre
.It Ql ddot
.It Ql duml
Umlaut.
.It Ql dsla
.It Ql drin
.It Ql dced
.It Ql dapo
.It Ql ddac
.It Ql dogo
.It Ql dcar
.El
.Pp
After the accent name should be the character to be used to represent that
accent on the console.
This may either be a single ASCII character within single quotes,
or the ASCII value of the character to be used,
in decimal.
.Pp
Following this should be a sequence of definitions of how a single ASCII
character should be accented.
Each definition should consist of an opening parenthesis,
the character being defined,
the character as it should be presented with the current accent,
and a closing parenthesis.
All four items must be separated by white space,
and each character may be either a single quoted character or an ASCII value,
as usual.
.Sh EXAMPLES
The following is an example of a definition for the escape key:
.Pp
.Bd -literal
001 esc esc esc esc esc esc debug esc O
.Ed
Note that this has the default action of entering the kernel debugger when
escape is pressed in conjunction with the control and alt keys.
.Pp
The following is an example of how an accent definition should look:
.Pp
.Bd -literal
dgra '`' ( 'a' 224 ) ( 'A' 192 ) ( 'e' 232 ) ( 'E' 200 )
( 'i' 236 ) ( 'I' 204 ) ( 'o' 242 ) ( 'O' 210 )
( 'u' 249 ) ( 'U' 217 )
.Ed
.Pp
Note that the accent is specified as a normal ASCII character,
and that all vowels,
both uppercase and lowercase,
are defined here.
.Pp
.Sh FILES
.Bl -tag -width "/usr/share/syscons/keymaps/*" -compact
.It Pa /usr/share/syscons/keymaps/*
Default system keymap files.
.El
.Sh SEE ALSO
.Xr kbdcontrol 1 ,
.Xr splash 4 ,
.Xr syscons 4
.Sh AUTHORS
This manual page was written by
.An Ben Smithurst Aq ben@FreeBSD.org .
--
Ben Smithurst / ben@FreeBSD.org / PGP: 0x99392F7D
FreeBSD Documentation Project /
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-doc" in the body of the message
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200007302340.QAA16422>
