Split off documentation on keyboard file. - sam - An updated version of the sam text editor.
(HTM) git clone git://vernunftzentrum.de/sam.git
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) LICENSE
---
(DIR) commit c39a4076c24b965ae6d99a9cca2a01a014e109eb
(DIR) parent fc7ada1716e13b59bb1d54d25eea39c84164a28c
(HTM) Author: Rob King <jking@deadpixi.com>
Date: Thu, 11 Aug 2016 23:10:17 -0500
Split off documentation on keyboard file.
Diffstat:
doc/keyboard | 2 +-
doc/keyboard.5 | 169 +++++++++++++++++++++++++++++++
doc/sam.1 | 94 ++-----------------------------
3 files changed, 174 insertions(+), 91 deletions(-)
---
(DIR) diff --git a/doc/keyboard b/doc/keyboard
@@ -11,7 +11,7 @@ cO 0xa9 ©
sa 0xaa ª
<< 0xab «
no 0xac ¬
--- 0xad
+-- 0xad SOFT HYPHEN
rO 0xae ®
__ 0xaf ¯
de 0xb0 °
(DIR) diff --git a/doc/keyboard.5 b/doc/keyboard.5
@@ -0,0 +1,169 @@
+.Dd $Mdocdate$
+.Dt KEYBOARD 5
+.Os
+.Sh NAME
+.Nm keyboard
+.Nd map key sequences to Unicode codepoints
+.Sh SYNOPSIS
+.Pa ~/.keyboard
+.Sh DESCRIPTION
+A
+.Nm
+file in the user's home directory can be used to describe key sequences that are composed
+into Unicode code points by the
+.Xr sam 1
+editor.
+.Pp
+Each line in the file is of the form
+.Bd -literal -offset indent
+cc hex comment
+.Ed
+.Pp
+where
+.Em "cc"
+is two characters naming two characters to be typed,
+.Em hex
+is a single integer
+.Po
+using C conventions
+.Pc
+naming a Unicode code point in the Basic Multilingual Plane, and
+.Em comment
+is the remainder of the line.
+.Pp
+.Xr sam 1
+will read in this file at startup.
+While running, any time the system's
+.Em Compose
+key
+.Po
+if configured
+.Pc
+is pressed, or the
+.Em Mod1
+key
+.Po
+usually
+.Dq "Alt"
+.Pc
+is held down, and the two keys described by
+.Em cc
+are typed,
+the Unicode code point named by
+.Em hex
+will be inserted into the file.
+.Pp
+If the two typed characters do not match a configured composition sequence,
+they will be inserted verbatim.
+.Pp
+Note that the first character of a composition sequence may not be
+.Dq "X"
+.Po
+upper case letter X
+.Pc ","
+because this would conflict with the editor's mechanism for inserting raw codepoints
+.Po
+see
+.Xr sam 1
+.Pc "."
+.Sh EXAMPLE
+Given the
+.Pa ".keyboard"
+line:
+.Bd -literal -offset indent
+12 0x00BD \[u00BD]
+.Ed
+.Pp
+then typing the characters 1 and 2 while holding down the
+.Em Mod1
+key in
+.Xr sam 1
+will insert Unicode code point 0x00BD
+.Pq \[u00BD]
+into the current file.
+.Pp
+Note that after the hexadecimal codepoint specification,
+the rest of the line is ignored and is therefore usable as a comment field.
+.Sh DEFAULTS
+If no
+.Pa ".keyboard"
+file is present, the following key sequences are defined by default:
+.Pp
+.TS
+box;
+c | c | c | c | c | c | c | c
+- | - | - | - | - | - | - | -
+c | c | c | c | c | c | c | c.
+Keys Codepoint Keys Codepoint Keys Codepoint Keys Codepoint
+!! \[u00A1] c$ \[u00A2] l$ \[u00A3] g$ \[u00A4]
+y$ \[u00A5] || \[u00A6] SS \[u00A7] "" \[u00A8]
+cO \[u00A9] sa \[u00AA] << \[u00AB] no \[u00AC]
+-- (SOFT HYPHEN) rO \[u00AE] __ \[u00AF] de \[u00B0]
++- \[u00B1] s2 \[u00B2] s3 \[u00B3] '' \[u00B4]
+mi \[u00B5] pg \[u00B6] .. \[u00B7] ,, \[u00B8]
+s1 \[u00B9] so \[u00BA] >> \[u00BB] 14 \[u00BC]
+12 \[u00BD] 34 \[u00BE] ?? \[u00BF] `A \[u00C0]
+'A \[u00C1] ^A \[u00C2] ~A \[u00C3] "A \[u00C4]
+oA \[u00C5] AE \[u00C6] ,C \[u00C7] `E \[u00C8]
+'E \[u00C9] ^E \[u00CA] "E \[u00CB] `I \[u00CC]
+'I \[u00CD] ^I \[u00CE] "I \[u00CF] D- \[u00D0]
+~N \[u00D1] `O \[u00D2] 'O \[u00D3] ^O \[u00D4]
+~O \[u00D5] "O \[u00D6] mu \[u00D7] /O \[u00D8]
+`U \[u00D9] 'U \[u00DA] ^U \[u00DB] "U \[u00DC]
+'Y \[u00DD] |P \[u00DE] ss \[u00DF] `a \[u00E0]
+'a \[u00E1] ^a \[u00E2] ~a \[u00E3] "a \[u00E4]
+oa \[u00E5] ae \[u00E6] ,c \[u00E7] `e \[u00E8]
+'e \[u00E9] ^e \[u00EA] "e \[u00EB] `i \[u00EC]
+'i \[u00ED] ^i \[u00EE] "i \[u00EF] d- \[u00F0]
+~n \[u00F1] `o \[u00F2] 'o \[u00F3] ^o \[u00F4]
+~o \[u00F5] "o \[u00F6] -: \[u00F7] /o \[u00F8]
+`u \[u00F9] 'u \[u00FA] ^u \[u00FB] "u \[u00FC]
+'y \[u00FD] |p \[u00FE] "y \[u00FF] wk \[u2654]
+.TE
+.TS
+box;
+c | c | c | c | c | c | c | c
+- | - | - | - | - | - | - | -
+c | c | c | c | c | c | c | c.
+Keys Codepoint Keys Codepoint Keys Codepoint Keys Codepoint
+wq \[u2655] wr \[u2656] wb \[u2657] wn \[u2658]
+wp \[u2659] bk \[u265A] bq \[u265B] br \[u265C]
+bb \[u265D] bn \[u265E] bp \[u265F] *a \[u03B1]
+*b \[u03B2] *g \[u03B3] *d \[u03B4] *e \[u03B5]
+*z \[u03B6] *y \[u03B7] *h \[u03B8] *i \[u03B9]
+*k \[u03BA] *l \[u03BB] *m \[u03BC] *n \[u03BD]
+*c \[u03BE] *o \[u03BF] *p \[u03C0] *r \[u03C1]
+ts \[u03C2] *s \[u03C3] *t \[u03C4] *u \[u03C5]
+*f \[u03C6] *x \[u03C7] *q \[u03C8] *w \[u03C9]
+*A \[u0391] *B \[u0392] *G \[u0393] *D \[u0394]
+*E \[u0395] *Z \[u0396] *Y \[u0397] *H \[u0398]
+*I \[u0399] *K \[u039A] *L \[u039B] *M \[u039C]
+*N \[u039D] *C \[u039E] *O \[u039F] *P \[u03A0]
+*R \[u03A1] *S \[u03A3] *T \[u03A4] *U \[u03A5]
+*F \[u03A6] *X \[u03A7] *Q \[u03A8] *W \[u03A9]
+<- \[u2190] ua \[u2191] -> \[u2192] da \[u2193]
+ab \[u2194] V= \[u21D0] =V \[u21D2] fa \[u2200]
+te \[u2203] pd \[u2202] es \[u2205] De \[u2206]
+gr \[u2207] mo \[u2208] !m \[u2209] st \[u220D]
+** \[u2217] bu \[u2219] sr \[u221A] pt \[u221D]
+if \[u221E] an \[u2220] l& \[u2227] l| \[u2228]
+ca \[u2229] cu \[u222A] is \[u222B] tf \[u2234]
+~= \[u2243] cg \[u2245] ~~ \[u2248] != \[u2260]
+== \[u2261] <= \[u2266] >= \[u2267] sb \[u2282]
+sp \[u2283] !b \[u2284] ib \[u2286] ip \[u2287]
+O+ \[u2295] O- \[u2296] Ox \[u2297] tu \[u22A2]
+Tu \[u22A8] lz \[u22C4] el \[u22EF] :( \[u2639]
+:) \[u263A] ;) \[u263B] ta (TAB)
+.TE
+.Sh ENVIRONMENT
+The following environment variables affect the operation of
+.Nm sam ":"
+.Bl -tag -width Ds
+.It Ev HOME
+Names the directory to be searched for the user's
+.Pa ".keyboard"
+file.
+.Sh SEE ALSO
+.Xr sam 1
+.Sh BUGS
+Only codepoints in the Basic Multilingual Plane may be specified.
(DIR) diff --git a/doc/sam.1 b/doc/sam.1
@@ -903,96 +903,10 @@ character is typed, followed by exactly four lowercase hexadecimal digits naming
Commonly used codepoints can be entered with an abbreviated two-character sequence.
These sequence definitions are read from a file called
.Pa ".keyboard"
-in the user's home directory.
-Each line in this file consists of two characters
-.Po
-the upper-case X character may not be the first of the two characters
-.Pc ","
-followed by any number of spaces, and a hexadecimal number.
-Holding down the compose key and typing the two listed characters will insert the codepoint indicated by the number.
-For example, given the
-.Pa ".keyboard"
-line:
-.Bd -literal -offset indent
-12 0x00BD
-.Ed
-.Pp
-then typing the characters 1 and 2 while holding down the compose key will insert Unicode code point 0x00BD
-.Pq \[u00BD]
-into the file.
-.Pp
-After the hexadecimal codepoint specification, the rest of the line is ignored and is therefore usable as a comment field.
-.Pp
-If no
-.Pa ".keyboard"
-file is present, the following key sequences are defined by default:
-.Pp
-.TS
-box;
-c | c | c | c | c | c | c | c
-- | - | - | - | - | - | - | -
-c | c | c | c | c | c | c | c.
-Keys Codepoint Keys Codepoint Keys Codepoint Keys Codepoint
-!! \[u00A1] c$ \[u00A2] l$ \[u00A3] g$ \[u00A4]
-y$ \[u00A5] || \[u00A6] SS \[u00A7] "" \[u00A8]
-cO \[u00A9] sa \[u00AA] << \[u00AB] no \[u00AC]
--- \[u00AD] rO \[u00AE] __ \[u00AF] de \[u00B0]
-+- \[u00B1] s2 \[u00B2] s3 \[u00B3] '' \[u00B4]
-mi \[u00B5] pg \[u00B6] .. \[u00B7] ,, \[u00B8]
-s1 \[u00B9] so \[u00BA] >> \[u00BB] 14 \[u00BC]
-12 \[u00BD] 34 \[u00BE] ?? \[u00BF] `A \[u00C0]
-'A \[u00C1] ^A \[u00C2] ~A \[u00C3] "A \[u00C4]
-oA \[u00C5] AE \[u00C6] ,C \[u00C7] `E \[u00C8]
-'E \[u00C9] ^E \[u00CA] "E \[u00CB] `I \[u00CC]
-'I \[u00CD] ^I \[u00CE] "I \[u00CF] D- \[u00D0]
-~N \[u00D1] `O \[u00D2] 'O \[u00D3] ^O \[u00D4]
-~O \[u00D5] "O \[u00D6] mu \[u00D7] /O \[u00D8]
-`U \[u00D9] 'U \[u00DA] ^U \[u00DB] "U \[u00DC]
-'Y \[u00DD] |P \[u00DE] ss \[u00DF] `a \[u00E0]
-'a \[u00E1] ^a \[u00E2] ~a \[u00E3] "a \[u00E4]
-oa \[u00E5] ae \[u00E6] ,c \[u00E7] `e \[u00E8]
-'e \[u00E9] ^e \[u00EA] "e \[u00EB] `i \[u00EC]
-'i \[u00ED] ^i \[u00EE] "i \[u00EF] d- \[u00F0]
-~n \[u00F1] `o \[u00F2] 'o \[u00F3] ^o \[u00F4]
-~o \[u00F5] "o \[u00F6] -: \[u00F7] /o \[u00F8]
-`u \[u00F9] 'u \[u00FA] ^u \[u00FB] "u \[u00FC]
-'y \[u00FD] |p \[u00FE] "y \[u00FF] wk \[u2654]
-.TE
-.TS
-box;
-c | c | c | c | c | c | c | c
-- | - | - | - | - | - | - | -
-c | c | c | c | c | c | c | c.
-Keys Codepoint Keys Codepoint Keys Codepoint Keys Codepoint
-wq \[u2655] wr \[u2656] wb \[u2657] wn \[u2658]
-wp \[u2659] bk \[u265A] bq \[u265B] br \[u265C]
-bb \[u265D] bn \[u265E] bp \[u265F] *a \[u03B1]
-*b \[u03B2] *g \[u03B3] *d \[u03B4] *e \[u03B5]
-*z \[u03B6] *y \[u03B7] *h \[u03B8] *i \[u03B9]
-*k \[u03BA] *l \[u03BB] *m \[u03BC] *n \[u03BD]
-*c \[u03BE] *o \[u03BF] *p \[u03C0] *r \[u03C1]
-ts \[u03C2] *s \[u03C3] *t \[u03C4] *u \[u03C5]
-*f \[u03C6] *x \[u03C7] *q \[u03C8] *w \[u03C9]
-*A \[u0391] *B \[u0392] *G \[u0393] *D \[u0394]
-*E \[u0395] *Z \[u0396] *Y \[u0397] *H \[u0398]
-*I \[u0399] *K \[u039A] *L \[u039B] *M \[u039C]
-*N \[u039D] *C \[u039E] *O \[u039F] *P \[u03A0]
-*R \[u03A1] *S \[u03A3] *T \[u03A4] *U \[u03A5]
-*F \[u03A6] *X \[u03A7] *Q \[u03A8] *W \[u03A9]
-<- \[u2190] ua \[u2191] -> \[u2192] da \[u2193]
-ab \[u2194] V= \[u21D0] =V \[u21D2] fa \[u2200]
-te \[u2203] pd \[u2202] es \[u2205] De \[u2206]
-gr \[u2207] mo \[u2208] !m \[u2209] st \[u220D]
-** \[u2217] bu \[u2219] sr \[u221A] pt \[u221D]
-if \[u221E] an \[u2220] l& \[u2227] l| \[u2228]
-ca \[u2229] cu \[u222A] is \[u222B] tf \[u2234]
-~= \[u2243] cg \[u2245] ~~ \[u2248] != \[u2260]
-== \[u2261] <= \[u2266] >= \[u2267] sb \[u2282]
-sp \[u2283] !b \[u2284] ib \[u2286] ip \[u2287]
-O+ \[u2295] O- \[u2296] Ox \[u2297] tu \[u22A2]
-Tu \[u22A8] lz \[u22C4] el \[u22EF] :( \[u2639]
-:) \[u263A] ;) \[u263B] ta TAB
-.TE
+in the user's home directory,
+see
+.Xr keyboard 5
+for more information on that file and its format.
.Sh ENVIRONMENT
The following environment variables affect the operation of
.Nm sam ":"