diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-10-18 08:53:40 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-10-18 08:53:40 +0000 |
commit | d6583bb2a13f329cf0332ef2570eb8bb8fc0e39c (patch) | |
tree | ece253b876159b39c620e62b6c9b1174642e070e /sys/arch/i386/isa/pcvt/Util/keycap |
initial import of NetBSD tree
Diffstat (limited to 'sys/arch/i386/isa/pcvt/Util/keycap')
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/Makefile | 19 | ||||
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/keycap.3 | 121 | ||||
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/keycap.5 | 133 | ||||
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/keycap.c | 377 | ||||
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/keycap.h | 49 | ||||
-rw-r--r-- | sys/arch/i386/isa/pcvt/Util/keycap/keycap.src | 613 |
6 files changed, 1312 insertions, 0 deletions
diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/Makefile b/sys/arch/i386/isa/pcvt/Util/keycap/Makefile new file mode 100644 index 00000000000..940b272bc06 --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/Makefile @@ -0,0 +1,19 @@ +LIB = keycap +CAPDIR = $(DESTDIR)/usr/share/misc +CAPPATH = $(CAPDIR)/keycap.pcvt +KEYCAPSRC= keycap.src +CFLAGS += -DKEYCAP_PATH=\"$(CAPPATH)\" +SRCS = keycap.c +MAN3 = keycap.${MAN3EXT} +MAN5 = keycap.${MAN5EXT} +#CLEANFILES+= keycap.0 keycap.0 + +beforeinstall: + @if [ ! -d ${DESTDIR}${LIBDIR} ]; then mkdir ${DESTDIR}${LIBDIR};fi + @${ECHO} "Saving old keycap database" + -mv -f ${DESTDIR}${CAPPATH} ${DESTDIR}${CAPPATH}.BAK + install -c -m ${LIBMODE} -o ${LIBOWN} -g ${LIBGRP} \ + ${.CURDIR}/${KEYCAPSRC} ${DESTDIR}${CAPPATH} + + +.include <bsd.lib.mk> diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/keycap.3 b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.3 new file mode 100644 index 00000000000..7eb59dcb230 --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.3 @@ -0,0 +1,121 @@ +.\" +.\" Copyright (c) 1992,1993,1994 Hellmuth Michaelis +.\" +.\" Copyright (c) 1990 The Regents of the University of California. +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by the University of +.\" California, Berkeley and its contributors. +.\" 4. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" @(#)keycap.3, 3.00, Last Edit-Date: [Sun Jan 2 13:46:43 1994] +.\" +.Dd January 3, 1993 +.Dt KEYCAP 3 +.Sh NAME +.Nm kgetent , +.Nm kgetnum , +.Nm kgetflag , +.Nm kgetstr +.Nd routines for accessing the keycap database +.Sh SYNOPSIS +.Fn kgetent "char *bp" "char *name" +.Fn kgetnum "char *id" +.Fn kgetflag "char *id" +.Ft char * +.Fn kgetstr "char *id" "char *area" +.Sh DESCRIPTION +These functions extract and use capabilities from a keyboard capability data +base, usually +.Pa /usr/share/misc/keycap , +the format of which is described in +.Xr keycap 5 . +.Pp +The +.Fn kgetent +function +extracts the entry for keyboard mapping +.Fa name +into the buffer at +.Fa bp . +The +.Fa bp +argument +should be a character buffer of size +1024 and must be retained through all subsequent calls to +.Fn kgetnum , +.Fn kgetflag , +and +.Fn kgetstr . +The +.Fn kgetent +function +returns \-1 if none of the +.Nm keycap +data base files could be opened, +0 if the map name given does not have an entry, +and 1 if all goes well. +.Pp +The +.Fn kgetnum +function +gets the numeric value of capability +.Fa id , +returning \-1 if is not given for the map. +.Pp +The +.Fn kgetflag +function +returns 1 if the specified capability is present in +the map's entry, 0 if it is not. +.Pp +The +.Fn kgetstr +function +returns the string value of the capability +.Fa id , +places it in the buffer at +.Fa area , +and advances the +.Fa area +pointer. +The +.Fn kgetstr +function +returns +.Dv NULL +if the capability was not found. +.Pp +.Sh FILES +.Bl -tag -width /usr/share/misc/keycap -compact +.It Pa /usr/share/misc/keycap +Keyboard capabilities database (if nothing else chosen during installation). +.El +.Sh SEE ALSO +.Xr kcon 1 , +.Xr keycap 5 diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/keycap.5 b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.5 new file mode 100644 index 00000000000..8a11f59a507 --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.5 @@ -0,0 +1,133 @@ +.\" +.\" Copyright (c) 1992,1993,1994 Hellmuth Michaelis +.\" +.\" Copyright (c) 1990 The Regents of the University of California. +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by the University of +.\" California, Berkeley and its contributors. +.\" 4. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" @(#)keycap.5, 3.00, Last Edit-Date: [Sun Jan 2 13:45:59 1994] +.\" +.Dd January 3, 1993 +.Dt KEYCAP 5 +.Sh NAME +.Nm keycap +.Nd keyboard mapping data base +.Sh SYNOPSIS +.Nm keycap +.Sh DESCRIPTION +The +.Nm keycap +file +is a data base describing keyboard mappings, used by +.Xr kcon 1 . +.Pp +Entries in +.Nm keycap +consist of a number of `:'-separated fields. +The first entry for each mapping gives the names that are known for the +mapping, separated by `|' characters. +All names but the first and last +should be in lower case and contain no blanks; +the last name may well contain +upper case and blanks for readability. +.Sh CAPABILITIES +.Pp +.Bl -column indent indent +.Sy Name Type Description +.It "de bool Resets Keyboard mapping to compiled-in default" +.It "D<n> bool Disables key <n> completely" + +.It "m<n> num specify key numbers for ALT keys +.It "l<n> num specify key numbers for ALTGR keys +.It "h<n> num specify key numbers for SHIFT keys +.It "t<n> num specify key numbers for CONTROL keys +.It "ca<n> num specify key number for the CAPS LOCK key +.It "sh<n> num specify key number for the SHIFT LOCK key +.It "nl<n> num specify key number for the NUM LOCK key +.It "sc<n> num specify key number for the SCROLL LOCK key + +.It "K<n> str bind a string to a unshifted (normal) key +.It "S<n> str bind a string to a shifted key +.It "C<n> str bind a string to a control key +.It "A<n> str bind a string to a altgr key + +.It "tc str Entry of similar map \- must be last." +.El + +Parameter <n> describing the key number can have values from 1 to 128. + +A string parameter may have up to 15 characters. + +.Pp +.Ss A Sample Entry +The following entry, which describes a test entry, is among the very +easy entries in the +.Nm keycap +file as of this writing. +.Pp +.Bd -literal +tt\||test\||Test entry which swaps y and z:\e + :K22=z:S22=Z:C22=\e032:\e + :K46=y:S46=Y:C46=\e031: + +.Ed +.Pp +Entries may continue onto multiple lines by giving a \e as the last +character of a line. Comments may be included on lines beginning with +.Dq # . +.Sh FILES +.Bl -tag -width /usr/share/misc/keycap -compact +.It Pa /usr/share/misc/keycap +File containing keyboard mapping descriptions. +.El +.Sh SEE ALSO +.Xr kcon 1 , +.Xr keycap 3 , +.Sh EXAMPLES +The entry +.Dq Li l1#60 +sets the keynumber for the ALTGR key to 60. + +The entry +.Dq Li K100=hugo +binds the string 'hugo' to the key number 100. + +The entry +.Dq Li K100=^D +binds the control character EOT (0x04) to the key number 100. + +The entry +.Dq Li K100=\e000 +binds the control character NUL (0x00) to the key number 100. + + + + diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/keycap.c b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.c new file mode 100644 index 00000000000..f70e987b0f6 --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.c @@ -0,0 +1,377 @@ +/*- + * Copyright (c) 1992, 1993 The Regents of the University of California. + * All rights reserved. + * + * This code is derived from software contributed to Berkeley by + * Holger Veit + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + +static char *id = + "@(#)keycap.c, 3.20, Last Edit-Date: [Tue Dec 20 14:51:50 1994]"; + +/*---------------------------------------------------------------------------* + * + * keycap.c Keyboard capabilities database handling + * ------------------------------------------------------- + * + * converted from printcap by Holger Veit (veit@du9ds3.uni-duisburg.de) + * + * BUG: Should use a "last" pointer in tbuf, so that searching + * for capabilities alphabetically would not be a n**2/2 + * process when large numbers of capabilities are given. + * + * Note: If we add a last pointer now we will screw up the + * tc capability. We really should compile termcap. + * + * modified by Hellmuth Michaelis (hm@hcshh.hcs.de) to fit into the + * vt220 driver pcvt 2.0 distribution + * + * -hm header conversion & cosmetic changes for pcvt 2.0 distribution + * -hm debugging remapping + * -hm cleaning up from termcap .... + * -hm split off header file keycap.h + * + *---------------------------------------------------------------------------*/ + +#include <stdio.h> +#include <ctype.h> + +#include "keycap.h" + +#define KEYCAP_BUFSIZ 1024 + +#define MAXHOP 32 /* max number of tc= indirections */ + +char *getenv(); + +static FILE *pfp = NULL; /* keycap data base file pointer */ +static char *tbuf; +static int hopcount; /* detect infinite loops in keycap, init 0 */ + +static int knchktc(); +static int knamatch(); +static char *kdecode(); + +/*---------------------------------------------------------------------------* + * match a name + *---------------------------------------------------------------------------*/ +static char *nmatch(id,cstr) +char *id,*cstr; +{ + register n = strlen(id); + register char *c = cstr+n; + + if (strncmp(id,cstr,n)==0 && + (*c==':' || *c=='|' || *c=='=' || *c=='#') || *c=='@') + return c; + return 0; +} + +/*---------------------------------------------------------------------------* + * Get an entry for keyboard name in buffer bp from the keycap file. + * Parse is very rudimentary, we just notice escaped newlines. + *---------------------------------------------------------------------------*/ +kgetent(bp, name) +char *bp, *name; +{ + register char *cp; + register int c; + register int i = 0, cnt = 0; + char ibuf[KEYCAP_BUFSIZ]; + char *cp2; + int tf; + + tbuf = bp; + tf = 0; + + tf = open(KEYCAP_PATH, 0); + + if (tf < 0) + return (-1); + for (;;) { + cp = bp; + for (;;) { + if (i == cnt) { + cnt = read(tf, ibuf, KEYCAP_BUFSIZ); + if (cnt <= 0) { + close(tf); + return (0); + } + i = 0; + } + c = ibuf[i++]; + if (c == '\n') { + if (cp > bp && cp[-1] == '\\'){ + cp--; + continue; + } + break; + } + if (cp >= bp+KEYCAP_BUFSIZ) { + write(2,"Keycap entry too long\n", 23); + break; + } else + *cp++ = c; + } + *cp = 0; + + /* + * The real work for the match. + */ + if (knamatch(name)) { + close(tf); + return(knchktc()); + } + } +} + +/*---------------------------------------------------------------------------* + * knchktc: check the last entry, see if it's tc=xxx. If so, recursively + * find xxx and append that entry (minus the names) to take the place of + * the tc=xxx entry. Note that this works because of the left to right scan. + *---------------------------------------------------------------------------*/ +static int knchktc() +{ + register char *p, *q; + char tcname[16]; /* name of similar keyboard */ + char tcbuf[KEYCAP_BUFSIZ]; + char *holdtbuf = tbuf; + int l; + + p = tbuf + strlen(tbuf) - 2; /* before the last colon */ + while (*--p != ':') + if (p<tbuf) { + write(2, "Bad keycap entry\n", 18); + return (0); + } + p++; + /* p now points to beginning of last field */ + if (p[0] != 't' || p[1] != 'c') + return(1); + strcpy(tcname,p+3); + q = tcname; + while (q && *q != ':') + q++; + *q = 0; + if (++hopcount > MAXHOP) { + write(2, "Infinite tc= loop\n", 18); + return (0); + } + if (kgetent(tcbuf, tcname) != 1) + return(0); + for (q=tcbuf; *q != ':'; q++) + ; + l = p - holdtbuf + strlen(q); + if (l > KEYCAP_BUFSIZ) { + write(2, "Keycap entry too long\n", 23); + q[KEYCAP_BUFSIZ - (p-tbuf)] = 0; + } + strcpy(p, q+1); + tbuf = holdtbuf; + return(1); +} + +/*---------------------------------------------------------------------------* + * knamatch deals with name matching. The first field of the keycap entry + * is a sequence of names separated by |'s, so we compare against each such + * name. The normal : terminator after the last name (before the first field) + * stops us. + *---------------------------------------------------------------------------*/ +static int knamatch(np) +char *np; +{ + register char *Np, *Bp; + + Bp = tbuf; + if (*Bp == '#' || *Bp == 0) + return(0); + for (;;) { + for (Np = np; *Np && *Bp == *Np; Bp++, Np++) + continue; + if (*Np == 0 && (*Bp == '|' || *Bp == ':' || *Bp == 0)) + return (1); + while (*Bp && *Bp != ':' && *Bp != '|') + Bp++; + if (*Bp == 0 || *Bp == ':') + return (0); + Bp++; + } +} + +/*---------------------------------------------------------------------------* + * Skip to the next field. Notice that this is very dumb, not knowing about + * \: escapes or any such. If necessary, :'s can be put into the keycap file + * in octal. + *---------------------------------------------------------------------------*/ +static char *kskip(bp) +char *bp; +{ + while (*bp && *bp != ':') + bp++; + if (*bp == ':') + bp++; + return (bp); +} + +/*---------------------------------------------------------------------------* + * Return the (numeric) option id. Numeric options look like 'li#80' i.e. + * the option string is separated from the numeric value by a # character. + * If the option is not found we return -1. Note that we handle octal + * numbers beginning with 0. + *---------------------------------------------------------------------------*/ +int kgetnum(id) +char *id; +{ + register int i, base; + register char *bp = tbuf,*xp; + + for (;;) { + bp = kskip(bp); + if (*bp == 0) + return (-1); + if ((xp=nmatch(id,bp)) == 0) + continue; + bp = xp; /* we have an entry */ + if (*bp == '@') + return(-1); + if (*bp != '#') + continue; + bp++; + base = 10; + if (*bp == '0') + base = 8; + i = 0; + while (isdigit(*bp)) + i *= base, i += *bp++ - '0'; + return (i); + } +} + +/*---------------------------------------------------------------------------* + * Handle a flag option. Flag options are given "naked", i.e. followed by + * a : or the end of the buffer. Return 1 if we find the option, or 0 if + * it is not given. + *---------------------------------------------------------------------------*/ +int kgetflag(id) +char *id; +{ + register char *bp = tbuf,*xp; + + for (;;) { + bp = kskip(bp); + if (!*bp) + return (0); + if ((xp=nmatch(id,bp)) != 0) { + bp = xp; + if (!*bp || *bp == ':') + return (1); + else if (*bp == '@') + return(0); + } + } +} + +/*---------------------------------------------------------------------------* + * Get a string valued option. These are given as 'cl=^Z'. Much decoding + * is done on the strings, and the strings are placed in area, which is a + * ref parameter which is updated. No checking on area overflow. + *---------------------------------------------------------------------------*/ +char *kgetstr(id, area) +char *id; +char **area; +{ + register char *bp = tbuf,*xp; + + for (;;) { + bp = kskip(bp); + if (!*bp) + return (0); + if ((xp = nmatch(id,bp)) == 0) + continue; + bp = xp; + if (*bp == '@') + return(0); + if (*bp != '=') + continue; + bp++; + return (kdecode(bp, area)); + } +} + +/*---------------------------------------------------------------------------* + * kdecode does the grung work to decode the string capability escapes. + *---------------------------------------------------------------------------*/ +static char *kdecode(str, area) +char *str; +char **area; +{ + register char *cp; + register int c; + register char *dp; + int i; + + cp = *area; + while ((c = *str++) && c != ':') { + switch (c) { + + case '^': + c = *str++ & 037; + break; + + case '\\': + dp = "E\033^^\\\\::n\nr\rt\tb\bf\f"; + c = *str++; +nextc: + if (*dp++ == c) { + c = *dp++; + break; + } + dp++; + if (*dp) + goto nextc; + if (isdigit(c)) { + c -= '0', i = 2; + do + c <<= 3, c |= *str++ - '0'; + while (--i && isdigit(*str)); + } + break; + } + *cp++ = c; + } + *cp++ = 0; + str = *area; + *area = cp; + return (str); +} + +/*-------------------------------- EOF --------------------------------------*/ diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/keycap.h b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.h new file mode 100644 index 00000000000..1dc4c3e1e6e --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.h @@ -0,0 +1,49 @@ +/*- + * Copyright (c) 1992, 1993 The Regents of the University of California. + * All rights reserved. + * + * This code is derived from software contributed to Berkeley by + * Holger Veit + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * @(#)keycap.h, 3.20, Last Edit-Date: [Tue Dec 20 14:52:11 1994] + */ + +#ifndef _KEYCAP_H_ +#define _KEYCAP_H_ + +int kgetent( char*, char* ); +int kgetnum( char* ); +int kgetflag( char* ); +char *kgetstr( char*, char** ); + +#endif /* _KEYCAP_H_ */ + +/*-------------------------------- EOF -------------------------------------*/ diff --git a/sys/arch/i386/isa/pcvt/Util/keycap/keycap.src b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.src new file mode 100644 index 00000000000..af50d728c69 --- /dev/null +++ b/sys/arch/i386/isa/pcvt/Util/keycap/keycap.src @@ -0,0 +1,613 @@ +# Copyright (c) 1992, 1993, 1994 Hellmuth Michaelis, Joerg Wunsch and +# Holger Veit. +# +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# 3. All advertising materials mentioning features or use of this software +# must display the following acknowledgement: +# This product includes software developed by Hellmuth Michaelis, +# Joerg Wunsch and Holger Veit. +# 4. The names of the Authors may not be used to endorse or promote +# products derived from this software without specific prior written +# permission. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# @(#)keycap.src, 3.20, Last Edit-Date: [Wed Mar 8 20:53:01 1995] +# +#--------------------------------------------------------------------------- +# +# keyboard mappings for vt220 emulator pcvt 3.00 +# ---------------------------------------------- +# +# DEC MCS and/or ISO-Latin-1 Characterset used +# +# MF II Keyboards fully supported +# AT Keyboards lack a ALTGR Key, so they cannot be handled by +# the current driver implementation .... sorry +# +# If you design a new entry for national keyboards, please +# send it to hm@hcshh.hcs.de, thank you ! +# +# Many entries are taken from the 386BSD patchkit 0.2.4 codrv +# +#--------------------------------------------------------------------------- +# +# -hm patch from Thomas Gellekum +# -hm renamed finnish "f8" entry to "f1" +# +#--------------------------------------------------------------------------- + +df|default|default entry:\ + :de: + +tt|test|Test entry which swaps y and z:\ + :K22=z:S22=Z:C22=\032:\ + :K46=y:S46=Y:C46=\031: + +# from codrv, untested +be|belgium|Belgian mapping:\ + :K1=\262:S1=\263:\ + :K2=&:S2=1:A2=|:\ + :K3=\351:S3=2:A3=@:\ + :K4=":S4=3:A4=#:\ + :K5=':S5=4:\ + :K6=(:S6=5:\ + :K7=\247:S7=6:A7=\136:\ + :K8=\350:S8=7:\ + :K9=!:S9=8:\ + :K10=\347:S10=9:A10={:\ + :K11=\340:S11=0:A11=}:\ + :K12=):S12=\260:\ + :K13=-:S13=_:\ + :K17=a:S17=A:C17=^A:\ + :K18=z:S18=Z:C18=^z:\ + :K27=\136:S27=\250:A27=[:p1#27:\ + :K28=$:S28=*:A28=]:\ + :K31=q:S31=Q:C31=^q:\ + :K40=m:S40=M:C40=^m:\ + :K41=\371:S41=%:A41=':p2#41:\ + :K42=\265:S42=\243:A42=\264:p3#42:\ + :K45=<:S45=>:A45=\\:\ + :K46=w:S46=W:C46=^w:\ + :K52=,:S52=\077:\ + :K53=;:S53=.:\ + :K54=\072:S54=/:\ + :K55==:S55=+:A55=~:\ + :l1#62:a0: + +# from codrv, untested +ca|canadafr|Canadian French mapping:\ + :K1=#:S1=|:A1=\\:\ + :A2=\261:S3=":A3=@:S4=/:A4=\243:A5=\242:\ + :A6=\244:S7=\077:A7=\254:S8=&:A8=\246:S9=*:A9=\262:\ + :S10=(:A10=\263:S11=):A11=\274:\ + :K12=-:S12=_:A12=\275:\ + :K13==:S13=+:A13=\276:\ + :A25=\247:A26=\266:\ + :K27=\136:S27=\136:A27=[:\ + :K28=\270:S28=\250:A28=]:p1#28:\ + :A40=~:K41=`:S41=`:A41={:\ + :K42=<:S42=>:A42=}:\ + :K45=\253:S45=\273:A45=\260:\ + :A49=\253:A50=\273:A51=\260:\ + :A52=\265:K53=,:S53=,:A53=-:\ + :K54=\351:S54=\311:A54=':\ + :l1#62:a0: + +# from codrv, untested +c1|swissde|Swiss German mapping:\ + :K1=\247:S1=\260:p1#1:\ + :S2=+:A2=|:S3=":A3=@:S4=*:A4=#:S5=\347:S7=&:A7=\254:\ + :S8=/:A8=\246:S9=(:A9=\242:S10=):S11==:\ + :K12=`:S12=\077:A12=':p2#12:\ + :K13=^:S13=\\:A13=~:p3#13:\ + :K22=z:S22=Z:C22=\032:\ + :S27=\350:K27=\374:A27=[:\ + :K28=\250:S28=!:A28=]:\ + :S40=\351:K40=\366:\ + :S41=\340:K41=\344:A41={:\ + :K42=$:S42=\243:A42=}:\ + :K45=<:S45=>:A45=\\:\ + :K46=y:S46=Y:C46=\031: + :S53=;:S54=\072:K55=-:S55=_:\ + :l1#62:a0: + +# from codrv, untested +c2|swissfr|Swiss French mapping:\ + :K27=\350:S27=\374:A27=[:\ + :K40=\351:S40=\366:\ + :K41=\340:S41=\344:A41={:\ + :tc=swissde: + +# more programmer-like than an original German kbd, you needn't +# have gum-fingers to get `{}' and the like:-) +# maps: ae -> [, oe -> \, ue -> ], Ae -> {, Oe -> |, Ue -> } +# umlaute are available as AltGr- and Control-Mappings +# also maps Pause -> ^Z +# +# (from Joerg Wunsch) +# +# l1/m1 bindings: left Alt is AltGr +# Emacs functions: +# C79/C89: ctrl-{leftarrow,rightarrow} {backward,forward} word +# A79/A89: {backward,forward} sexp +# C83/C84: ctrl-{uparrow,downarrow} {backward,forward} window +# +de-prog|germany-prog|programmer's mapping for german keyboard:\ + :K27=]:S27=}:A27=\374:C27=\334:\ + :K40=\\:S40=|:A40=\366:C40=\326:\ + :K41=[:S41={:A41=\344:C41=\304:\ + :K126=\032:C126=\003:\ + :tc=de: +# :l1#60:l2#62:\ +# :C79=^[B:K79=^[[D:S79=^[OD:A79=^[^B:\ +# :C89=^[F:K89=^[[C:S89=^[OC:A89=^[^F:\ +# :C83=^U-1^XO:K83=^[[A:S84=^[OA:\ +# :C84=^XO:K84=^[[B:S84=^[OB:\ + +de|germany|German mapping for MF II-Keyboard:\ + :K1=\136:S1=\260:\ + :S3=\042:S4=\247:S7=&:S8=/:S9=(:S10=):S11=\075:\ + :A3=\262:A4=\263:A8={:A9=[:A10=]:A11=}:A12=\134:\ + :K12=\337:S12=?:C12=\034:\ + :K13=':S13=`:\ + :A17=\100:\ + :K22=z:S22=Z:C22=\032:\ + :K27=\374:S27=\334:\ + :K28=+:S28=*:A28=\176:\ + :K29=\043:S29=':A29=\174:\ + :K40=\366:S40=\326:\ + :K41=\344:S41=\304:\ + :A45=\174:\ + :K46=y:S46=Y:C46=\031:\ + :A52=\265:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :l1#62: + +de-at|germany-at|German mapping for AT-Keyboard:\ + :K1=<:S1=>:\ + :S3=\042:\ + :S4=\247:\ + :S7=&:\ + :S8=/:\ + :S9=(:\ + :S10=):\ + :S11=\075:\ + :K12=\337:S12=?:C12=\034:\ + :K13=':S13=`:\ + :K14=#:S14=\136:\ + :K22=z:S22=Z:C22=\032:\ + :K27=\374:S27=\334:\ + :K28=+:S28=*:\ + :K29=\043:S29=':\ + :K40=\366:S40=\326:\ + :K41=\344:S41=\304:\ + :K46=y:S46=Y:C46=\031:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + +# from codrv, untested +# Includes improvements by Thomas Hiller (hiller@fzi.de) +# and Andreas Israel (ai@hrz.tu-chemnitz.de) +de-hi|germany-hiller|yet another German mapping:\ + :K1=\136:S1=\260:C1=|:\ + :S3=\042:S4=#:S7=&:S8=/:S9=(:S10=):S11=\075:\ + :A8={:A9=[:A10=]:A11=}:A17=@:A28=~:\ + :K12=\337:S12=\077:C12=\036:A12=\\:\ + :K13=':S13=`:C13=\134:p1#13:\ + :K22=z:S22=Z:C22=\032:\ + :K27=\374:S27=\334:C27=\035:\ + :K28=+:S28=*:C28=\000:\ + :K29=<:S29=>:C29=\134:\ + :K40=\366:S40=\326:C40=\034:\ + :K41=\344:S41=\304:C41=\033:\ + :K46=y:S46=Y:C46=\031:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :l1#62:a0: + +# from codrv, untested +# Contribution by Thomas Hiller (hiller@fzi.de) +# "K42 may not work on 102 keys kbds, K29 seems to work" +d1|de-102|german with mf2:\ + :K29=#:\ + :K42=#:\ + :K45=<:S45=>:A45=|:\ + :tc=germany: + +# from codrv, untested +hv|holgi|Holgi's special MF1 keyboard mapping:\ + :K1=<:S1=>:C1=|:\ + :K29=#:S29=\136:A29=\\:C29=~:\ + :tc=germany: + +# from codrv, untested +# Contributed by Andreas Israel (ai@hrz.tu-chemnitz.de) +de-ai|nixmf2|ct22|nix|nix7|German Nixdorf MF2:\ + :A28=~:\ + :K29=#:S29=':\ + :K45=<:S45=>:A45=|:\ + :tc=germany: + +# from codrv, untested +dk|denmark|Danish mapping:\ + :K1=\275:S1=\247:\ + :S3=":A3=@:\ + :A4=\243:\ + :S5=\244:A5=$:\ + :S7=&:S8=/:A8={:S9=(:A9=[:S10=):A10=]:S11==:A11=}:\ + :K12=+:S12=\077:\ + :K13=':S13=`:A13=|:p1#13:\ + :K27=\345:S27=\305:\ + :K28=\250:S28=\136:A28=~:p2#28:\ + :K40=\346:S40=\306:\ + :K41=\370:S41=\330:\ + :K42=:S42=*:\ + :K45=<:S45=>:A45=\\:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :l1#62:a0: + +# from codrv, untested +# Finnish keyboard map with 7-bit versions of the national +# chars. The Latin1 chars are available with Alt-7, Alt-8, etc +# (where normally you would have the 7-bit ones). +# Makes C/C++ programming more comfortable, since the 7-bit chars +# (|\{[}]) are needed much more often than the Latin1 chars. +# -- Petri.Wessman@hut.fi +fi|finland|finland7b|finland-ascii|Finnish ASCII mapping:\ + :l1#60:l2#62:\ + :A8=\344:A9=\304:A10=\305:A11=\345:A12=\326:A13=\366:\ + :K40=|:S40=\\:K41={:S41=[:K27=}:S27=]:\ + :S1=\275:K1=\247:\ + :S3=":A3=@:\ + :A4=\243:\ + :S5=$:A5=$:\ + :S7=&:S8=/:S9=(:S10=):S11==:\ + :K12=+:S12=\077:\ + :K13=':S13=`:\ + :K28=~:S28=\136:A28=~:\ + :K29=':S29=*:\ + :K45=<:S45=>:A45=|:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :a0: + +# from codrv, untested +# Finnish keyboard map with the Latin1 national chars in +# their "right" place. --Petri.Wessman@hut.fi +f1|finland8b|finland-latin1|Finnish Latin1 mapping:\ + :A8={:A9=[:A10=]:A11=}:A12=\\:\ + :K40=\366:S40=\326:K41=\344:S41=\304:K27=\345:S27=\305:\ + :tc=finland: + + +# French keyboard mapping +# From Matthieu Herrb <matthieu@laas.fr> +# For 102 keys keyboards, produces 8 bits characters +# with ISO Latin-1 encoding +f8|france-iso-8859-1|French ISO 8859-1 102 keys keyboard:\ + :l1#62:\ + :K1=\262:S1=:\ + :K2=&:S2=1:\ + :K3=\351:S3=2:C3=\211:A3=~:\ + :K4=":S4=3:A4=#:\ + :K5=':S5=4:A5={:\ + :K6=(:S6=5:A6=[:\ + :K7=-:S7=6:C7=\036:A7=|:\ + :K8=\350:S8=7:C8=\210:A8=`:\ + :K9=_:S9=8:C9=\037:A9=\\:\ + :K10=\347:S10=9:C10=\207:A10=\136:\ + :K11=\340:S11=0:C11=\340:A11=@:\ + :K12=):S12=\260:A12=]:\ + :A13=}:\ + :K17=a:S17=A:C17=\001:\ + :K18=z:S18=Z:C18=\032:\ + :D27:\ + :K28=$:S28=\243:\ + :K29=*:S29=\265:\ + :K31=q:S31=Q:C31=\021:\ + :K40=m:S40=M:C40=\015;\ + :K41=\371:C41=\231:S41=%:\ + :K42=*:S42=\265:\ + :K46=w:S46=W:C46=\027:\ + :K52=,:S52=?:\ + :K53=;:S53=.:\ + :K54=\072:S54=/:C54=\037\ + :K55=!:S55=\266: + +# fr|france|French mapping:\ +# :de: +# +# from codrv, untested +# f1|france120|French 120 mapping:\ +# :tc=belgium: +# +# +# from codrv, untested +#f2|france189|French 189 mapping:\ +# :S1=:A1=':p3#1:\ +# :A2=:A3=~:A5={:A6=[:A7=|:A8=`:\ +# :S9=_:A9=\\:A10=\136:A11=@:A12=]:A13=}:\ +# :A27=:A28=\244:A41=:A42=:\ +# :A45=:!:S45=\247:\ +# :tc=belgium: + +# From: Andy Duplain, duplain@rtf.bt.co.uk +gb|greatbritain|British mapping for MF-2 keyboard:\ + :S1=|:S3=":C3=2:C12=-:S41=@:K42=#:S42=~:C42=#:K45=\\:S45=|:C45=\\: + +# from codrv, untested +# This entry has been corrected by Mike Trim (mtrim@crucible.demon.co.uk) +# (hv's comment: For the keys # and ~ you might also check the following +# line +# :K42=#:S42=~:\ +# Also I think I was wrong with the ALTGR key. If you need one, add this: +# :l1#62: +g1|greatbritain166|British 166 mapping:\ + :K1=`:S1=\254:A1=|:\ + :S3=":S4=\243:\ + :K41=':S41=@:\ + :K29=#:S29=~:\ + :K45=\\:S45=|: + +# from codrv, untested +g2|greatbritain168|British 168 mapping:\ + :K1=\\:S1=|:\ + :S3=":S4=\243:S7=&:S8=:S9=(:S10=):A10=\261:\ + :S11=#:A11=\260:S12=:K13=\254:S13=-:\ + :K27=@:S27=`:\ + :K28=[:S28={:A28=~:\ + :K40=;:S40=+:\ + :K41=\072:S41=*:A41=\136:\ + :K42=]:S42=}:\ + :K45=|:S45=_:\ + :A52=\265:\ + :l1#62:a0: + +# from codrv, untested +is:iceland:Island mapping:\ + :K1=\260:S1=\250:p1#1:\ + :S2=":S7=&:S8=/:A8={:S9=(:A9=[:S10=):A10=]:S11==:A11=}:\ + :K12=\\:S12=\326:\ + :K13=':S13=`:A13=|:\ + :A17=@:K27=\360:S27=\320:\ + :K28=':S28=\077:A28=~:\ + :K40=\346:S40=\306:\ + :K41=':S41=':A41=\136:p2#41:\ + :K42=+:S42=*:A42=`:p3#42:\ + :K45=<:S45=>:A45=|:\ + :S53=;:S54=\072:\ + :K54=\376:S54=\336:\ + :K104=,:104=,:\ + :l1#62:a0: + +# from codrv, untested +i1|italy141|Italian 141 mapping:\ + :K1=\\:S1=|:\ + :S3=":S4=\243:S7=&:S8=/:S9=(:S10=):S11==:\ + :K12=':S12=\077:\ + :K13=\354:S13=\136:\ + :K27=\350:S27=\351:\A27=[:\ + :K28=+:S28=*:A28=]:\ + :K40=\362:S40=\347:A40=@:\ + :K41=\340:S41=\260:A41=#:\ + :K42=\371:S42=\247:\ + :K45=<:S45=>:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :l1#62:a0: + +# from codrv, untested +i2|italy142|Italian 142 mapping:\ + :A8={:A9=[:A10=]:A11=}:\ + :A17=@:A27=:A28=~:A40=:A41=:\ + :tc=italy141:a0: + +# from codrv, untested +nl|netherlands|Dutch mapping:\ + :K1=@:S1=\247:A1=\254:\ + :A2=\271:S3=":A3=\262:S4=#:A4=\263:A5=\274:A6=\275:S7=&:\ + :A7=\276:S8=_:A8=\243:S9=(:A9={:S10=):A10=}:S11=':\ + :K12=/:S12=\077:A12=\\:\ + :K13=\260:S13=~:A13=\270:p1#13:\ + :K20=\266:K27=\250:S27=^:p2#27:\ + :K28=*:S28=|:\ + :K40=+:S40=\261:\ + :K41=':S41=`:\ + :K42=<:S42=>:\ + :K45=[:S45=]:A45=|:\ + :S53=;:S54=\072:K55=-:S55=_:\ + :K104=,:S104=,:\ + :l1#62:a0: + +# from codrv, untested +no|norway|Norwegian mapping:\ + :K1=|:\ + :K13=\\:S13=`:A13=':p1#13:\ + :K41=\346:S41=\306:\ + :K40=\370:S40=\330:\ + :A45=:\ + :tc=denmark: + +# from codrv, untested +pt|portugal|Portugesian mapping:\ + :K1=\\:S1=|:\ + :S3=":A3=@:A4=\243:A5=\247:S7=&:S8=/:A8={:S9=(:A9=[:\ + :S10=):A10=]:S11=}:A11==:\ + :K12=':S12=\077:\ + :K13=\253:S13=\273:\ + :K40=\347:S40=\307:\ + :K41=\272:S41=\252:\ + :K42=~:S42=^:p1#42:\ + :K45=<:S45=>:\ + :S53=;:S54=\072:K55=-:S55=_:\ + :l1#62:a0: + +# from codrv, untested +es|spain|Spainish mapping:\ + :K1=\272:S1=\252:A1=\\:\ + :A2=|:S3=":A3=@:S4=:A4=#:S7=&:A7=\254:S8=/:S9=(:S10=):S11==:\ + :K12=':S12=\077:p1#12:\ + :K13=\277:S13=\241:\ + :K27=`:S27=^:A27=[:p2#27:\ + :K28=+:S28=*:A28=]:\ + :K40=\361:S41=\321:\ + :K41=/:S41=\250:A41={:p3#41:\ + :K42=\347:S42=\307:A42=}:\ + :K45=<:S45=>:\ + :S53=;:S54=\072:\ + :K55=-:S55=_:\ + :K104=,:S104=,:\ + :l1#62:a0: + +# from codrv, untested +# Contributed by Mats O Jansson, moj@stacken.kth.se +# "Here is my map, rather large, but i want ALTGR normaly to be dead. +# Only seven bit national characters have been placed where national characters +# is on the keyboard." +# We can help this man, just use the 'a0' capability -hv- +s1|sweden1|Swedish mapping:\ + :l1#62:a0:\ + :D1:\ + :K12=+:K13=':K29=':\ + :S2=!:S3=":S4=#:S5=$:S6=%:S7=&:S8=/:\ + :S9=(:S10=):S11=\075:S12=\077:S13=`:S29=*:\ + :C2=:C3=\000:C4=\033:C5=\034:C6=\035:C7=:C8=:C9=:\ + :C10=:C11=:C12=:C13=:C29=:\ + :A3=\100:A5=$:A8={:\ + :A9=[:A10=]:A11=}:A12=\134:\ + :K27=]:K28=:\ + :S27=}:S28=\136:\ + :C27=\035:C28=:\ + :A28=\176:\ + :K40=\134:K41=[:\ + :S40=|:S41={:\ + :C40=\034:C41=\033:\ + :K45=<:K53=,:K54=.:K55=-:\ + :S45=>:S53=;:S54=\072:S55=_:\ + :C45=\034:C53=:C54=:C55=:\ + :A45=|:\ + :C61=\000: + +# from codrv, untested +# Contributed by Mats O Jansson, moj@stacken.kth.se +# "Here is my map, rather large, but i want ALTGR normaly to be dead. +# Only seven bit national characters have been placed where national +# characters is on the keyboard." +# We can help this man, just use the 'a0' capability -hv- +# Corrected by Paul Pries, 5322@msg.abc.se (Some national shifts were +# wrong). +sa|sweden1a|Swedish 7bit mapping ISO 646:\ + :l1#62:a0:\ + :D1:\ + :K12=+:K13=':K29=':\ + :S2=!:S3=":S4=#:S5=$:S6=%:S7=&:S8=/:\ + :S9=(:S10=):S11=\075:S12=\077:S13=`:S29=*:\ + :C2=:C3=\000:C4=\033:C5=\034:C6=\035:C7=:C8=:C9=:\ + :C10=:C11=:C12=:C13=:C29=:\ + :A3=\100:A5=$:A8={:\ + :A9=[:A10=]:A11=}:A12=\134:\ + :K27=}:K28=:\ + :S27=]:S28=\136:\ + :C27=\035:C28=:\ + :A28=\176:\ + :S40=\134:S41=[:\ + :K40=|:K41={:\ + :C40=\034:C41=\033:\ + :K45=<:K53=,:K54=.:K55=-:\ + :S45=>:S53=;:S54=\072:S55=_:\ + :C45=\034:C53=:C54=:C55=:\ + :A45=|:\ + :C61=\000: + +# from codrv, untested +# Swedish keyboard map with national characters. +# Paul Pries, 5322@msg.abc.se +s2|sweden2|Swedish 8bit mapping ISO 8859-1:\ + :l1#62:\ + :K1=\247:S1=:\ + :K12=+:K13=':K29=':\ + :S2=!:S3=":S4=#:S5=$:S6=%:S7=&:S8=/:\ + :S9=(:S10=):S11=\075:S12=\077:S13=`:S29=*:\ + :C2=:C3=\000:C4=\033:C5=\034:C6=\035:C7=:C8=:C9=:\ + :C10=:C11=:C12=:C13=:C29=:\ + :A3=\100:A4=\234:A5=$:A8={:\ + :A9=[:A10=]:A11=}:A12=\134:\ + :K27=\206:K28=:\ + :S27=\217:S28=\136:\ + :C27=\035:C28=:\ + :A28=\176:\ + :S40=\231:S41=\216:\ + :K40=\224:K41=\204:\ + :C40=\034:C41=\033:\ + :K45=<:K53=,:K54=.:K55=-:\ + :S45=>:S53=;:S54=\072:S55=_:\ + :C45=\034:C53=:C54=:C55=:\ + :A45=|:\ + :C61=\000: + +# +# tg: my idiosyncratic mappings (thomas@ghpc8.ihf.rwth-aachen.de) +# +# the six function keys above the cursor keys are arranged +# identical to a real VT220: +# +# find insert remove +# select up down +# +# since i don't have a use for the numbers on the keypad, +# i map NumLock, /, *, - to PF1-PF4; +# + is mapped to SS3 l, shifted + is mapped to SS3 m +# +# they convinced me finally to add some support for german umlauts. +# so, i stole the mapping from jörg wunsch's de-prog entry. +# +# tg +# + +tg:\ + :l1#62:\ + :A12=\337:\ + :A27=\374:C27=\334:\ + :A40=\366:C40=\326:\ + :A41=\344:C41=\304:\ + :K126=\032:C126=\003:\ + :K75=[1~:S75=[1~:C75=[1~:\ + :K76=[4~:S76=[4~:C76=[4~:\ + :K80=[2~:S80=[2~:C80=[2~:\ + :K81=[5~:S81=[5~:C81=[5~:\ + :K85=[3~:S85=[3~:C85=[3~:\ + :K86=[6~:S86=[6~:C86=[6~:\ + :K90=OP:S90=OP:C90=OP:\ + :K95=OQ:S95=OQ:C95=OQ:\ + :K100=OR:S100=OR:C100=OR:\ + :K104=On:S104=On:C104=On:\ + :K105=OS:S105=OS:C105=OS:\ + :K106=Ol:S106=Om:\ + :K108=OM:S108=OM:C108=OM: + +us|usa|United States mapping:\ + :de: + +# EOF |