Subject: kern/6775: Swap posisions of Control-L and Capslock for wscons
To: None <gnats-bugs@gnats.netbsd.org>
From: URA Hiroshi <ura@yamato.ibm.co.jp>
List: netbsd-bugs
Date: 01/09/1999 23:13:38
Note: There was a bad value `non-critica' for the field `>Severity:'.
It was set to the default value of `serious'.
>Number: 6775
>Category: kern
>Synopsis: Swap posisions of Control-L and Capslock for wscons
>Confidential: no
>Severity: serious
>Priority: low
>Responsible: kern-bug-people (Kernel Bug People)
>State: open
>Class: change-request
>Submitter-Id: net
>Arrival-Date: Sat Jan 9 06:20:00 1999
>Last-Modified:
>Originator: URA Hiroshi
>Organization:
>Release: NetBSD-current, 1.3I, 1999/01/09
>Environment:
System: NetBSD mattari.yamato.ibm.com 1.3I NetBSD 1.3I (MATTARI) #1: Sat Jan 9 05:08:41 JST 1999 ura@mattari.yamato.ibm.com:/usr/local/src/netbsd-current/src/sys/arch/i386/compile/MATTARI i386
>Description:
Control-L key is in a ``wrong'' posision on many pc keyboards.
The following patch is fixed.
>How-To-Repeat:
>Fix:
--- /usr/local/src/netbsd-current/src/sys/dev/pckbc/wskbdmap_mfii.c Wed Jan 6 21:21:27 1999
+++ dev/pckbc/wskbdmap_mfii.c Sat Jan 9 05:18:33 1999
@@ -335,6 +335,12 @@
KC(207), KS_Select, /* replace end */
};
+static const keysym_t pckbd_keydesc_swapctrlcaps[] = {
+/* pos command normal shifted */
+ KC(29), KS_Caps_Lock,
+ KC(58), KS_Cmd1, KS_Control_L,
+};
+
#define KBD_MAP(name, base, map) \
{ name, base, sizeof(map)/sizeof(keysym_t), map }
@@ -348,6 +354,7 @@
KBD_MAP(KB_IT, KB_US, pckbd_keydesc_it),
KBD_MAP(KB_UK, KB_US, pckbd_keydesc_uk),
KBD_MAP(KB_US | KB_DECLK, KB_US, pckbd_keydesc_us_declk),
+ KBD_MAP(KB_US | KB_SWAPCTRLCAPS, KB_US, pckbd_keydesc_swapctrlcaps),
{0, 0, 0, 0}
};
--- /usr/local/src/netbsd-current/src/sys/dev/wscons/wskbdmap_mfii.h Tue Dec 29 21:16:06 1998
+++ dev/wscons/wskbdmap_mfii.h Sat Jan 9 05:18:54 1999
@@ -277,6 +277,12 @@
KC(207), KS_Select, /* replace end */
};
+static const keysym_t pckbd_keydesc_swapctrlcaps[] = {
+/* pos command normal shifted */
+ KC(29), KS_Caps_Lock,
+ KC(58), KS_Cmd1, KS_Control_L,
+};
+
#define KBD_MAP(name, base, map) \
{ name, base, sizeof(map)/sizeof(keysym_t), map }
@@ -288,6 +294,7 @@
KBD_MAP(KB_DK | KB_NODEAD, KB_DK, pckbd_keydesc_dk_nodead),
KBD_MAP(KB_IT, KB_US, pckbd_keydesc_it),
KBD_MAP(KB_US | KB_DECLK, KB_US, pckbd_keydesc_us_declk),
+ KBD_MAP(KB_US | KB_SWAPCTRLCAPS, KB_US, pckbd_keydesc_swapctrlcaps),
{0, 0, 0, 0}
};
--- /usr/local/src/netbsd-current/src/sys/dev/wscons/wsksymdef.h Wed Jan 6 21:21:29 1999
+++ dev/wscons/wsksymdef.h Sat Jan 9 04:58:14 1999
@@ -457,6 +457,7 @@
#define KB_NODEAD 0x0001
#define KB_DECLK 0x0002 /* DEC LKnnn layout */
#define KB_LK401 0x0004 /* DEC LK401 instead LK201 */
+#define KB_SWAPCTRLCAPS 0x0008 /* Swap Control-L and Caps-Lock */
#define KB_NAMETAB \
{ KB_USER, "user" }, \
@@ -468,6 +469,7 @@
{ KB_UK, "uk" }, \
{ KB_NODEAD, "nodead" }, \
{ KB_DECLK, "declk" }, \
- { KB_LK401, "lk401" }
+ { KB_LK401, "lk401" }, \
+ { KB_SWAPCTRLCAPS, "swapctrlcaps" }
#endif /* !_DEV_WSCONS_WSKSYMDEF_H_ */
>Audit-Trail:
>Unformatted: