Sophie

Sophie

distrib > Fedora > 18 > i386 > by-pkgid > e254a62edb229a95acb351ee11adc8d3 > files > 5

xkeyboard-config-2.6-8.fc18.src.rpm

From 690ea60dcb6793879489c17ab5d85afd272fa0f7 Mon Sep 17 00:00:00 2001
From: Walter Bender <walter.bender@gmail.com>
Date: Sat, 20 Apr 2013 16:02:25 +0000
Subject: add support for the OLPC mechanical non-membrane keyboard

Patch updated against current tree.

> From: Paul Fox <pgf@laptop.org>
> Date: Tue, 20 Jul 2010 16:22:40 -0400
> Subject: [PATCH] add support for the OLPC "mechanical" (non-membrane) keyboard
>  model(s). to aid in this, add keycodes/olpc with aliases to avoid needing to
>  use BKSL and TLDE, which don't appear anywhere near their "traditional"
>  position on the olpcm mechanical keyboards.
---
Index: xkeyboard-config-2.6/keycodes/Makefile.am
===================================================================
--- xkeyboard-config-2.6.orig/keycodes/Makefile.am
+++ xkeyboard-config-2.6/keycodes/Makefile.am
@@ -12,6 +12,7 @@ fujitsu \
 hp \
 ibm \
 macintosh \
+olpc \
 sony \
 sun \
 xfree86 \
Index: xkeyboard-config-2.6/keycodes/olpc
===================================================================
--- /dev/null
+++ xkeyboard-config-2.6/keycodes/olpc
@@ -0,0 +1,23 @@
+
+// OLPC's mechanical keyboard moves several keys to the AA row.  make
+// them easier to write symbol files naturally.
+
+// see http://wiki.laptop.org/go/OLPC_English_Non-membrane_Keyboard
+// and http://wiki.laptop.org/go/OLPC_Spanish_Non-membrane_Keyboard
+
+default
+xkb_keycodes "olpc" {
+
+   alias <AE00> = <TLDE>;	// many OLPC keyboards don't put tilde there
+   alias <AC12> = <BKSL>;	// on model olpc, physical position of BKSL
+
+};
+
+default
+xkb_keycodes "olpcm" {
+
+   alias <AA02> = <BKSL>;	// on model olpcm, new physical position of BKSL
+   alias <AA06> = <AE12>;	// on model olpcm, new physical position of =+
+   alias <AA07> = <AC11>;	// on model olpcm, new physical position of '"
+
+};
Index: xkeyboard-config-2.6/rules/base.ml_c.part
===================================================================
--- xkeyboard-config-2.6.orig/rules/base.ml_c.part
+++ xkeyboard-config-2.6/rules/base.ml_c.part
@@ -1,4 +1,5 @@
   pc98		nec_vndr/jp	=	pc98(basic)
   *		jp		=	complete+japan
-  olpc         *               =       olpc
+  olpc          *               =       olpc
+  olpcm         *               =       olpc
   *		*		=	complete
Index: xkeyboard-config-2.6/rules/base.ml_s.part
===================================================================
--- xkeyboard-config-2.6.orig/rules/base.ml_s.part
+++ xkeyboard-config-2.6/rules/base.ml_s.part
@@ -35,6 +35,8 @@
   nokiasu8w	*			=	nokia_vndr/su-8w(%l)
   olpc		$olpclayouts		=	olpc+%l%(m)
   olpc		*			=	olpc+%l%(v)
+  olpcm		$olpclayouts		=	olpc+%l%(m)
+  olpcm		*			=	olpc+%l%(v)
  $thinkpads   	br			=	pc+br(thinkpad)
   htcdream	$htcdreamlayouts	=	%l(htcdream)
   *	   	$nonlatin		=	pc+us+%l%(v):2
Index: xkeyboard-config-2.6/rules/evdev.m_k.part
===================================================================
--- xkeyboard-config-2.6.orig/rules/evdev.m_k.part
+++ xkeyboard-config-2.6/rules/evdev.m_k.part
@@ -1,3 +1,5 @@
   pc98		=	evdev(pc98)
   applealu_jis	=	evdev+macintosh(jisevdev)
+  olpc          =       evdev+olpc(olpc)
+  olpcm         =       evdev+olpc(olpcm)
   *		=	evdev
Index: xkeyboard-config-2.6/symbols/es
===================================================================
--- xkeyboard-config-2.6.orig/symbols/es
+++ xkeyboard-config-2.6/symbols/es
@@ -158,10 +158,12 @@ xkb_symbols "mac" {
 partial alphanumeric_keys
 xkb_symbols "olpc" {
 
+    // http://wiki.laptop.org/go/OLPC_Spanish_Keyboard
+
     include "us(basic)"
     name[Group1]="Spanish";
 
-    key <TLDE> { [    masculine,    ordfeminine      ] };
+    key <AE00> { [    masculine,    ordfeminine      ] };
     key <AE01> { [            1,         exclam,             bar ] };
     key <AE02> { [            2,       quotedbl,              at ] };
     key <AE03> { [            3,     dead_grave,      numbersign,   grave           ] };
@@ -180,7 +182,7 @@ xkb_symbols "olpc" {
 
     key <AC10> { [       ntilde,        Ntilde                  ] };
     key <AC11> { [         plus,       asterisk,      dead_tilde ] };
-    key <BKSL> { [ bracketright,     braceright,      section    ] };
+    key <AC12> { [ bracketright,     braceright,      section    ] };
 
     key <AB08> { [        comma,      semicolon                  ] };
     key <AB09> { [       period,          colon                  ] };
@@ -190,6 +192,47 @@ xkb_symbols "olpc" {
 
     include "level3(ralt_switch)"
 };
+
+partial alphanumeric_keys
+xkb_symbols "olpcm" {
+
+    // Mechanical (non-membrane) OLPC Spanish keyboard layout.
+    // See: http://wiki.laptop.org/go/OLPC_Spanish_Non-membrane_Keyboard
+
+    include "us(basic)"
+    name[Group1]="Spain";
+
+    key <AE00> { [    questiondown,    exclamdown, backslash      ] };
+    key <AE01> { [            1,         exclam,             bar ] };
+    key <AE02> { [            2,       quotedbl,              at ] };
+    key <AE03> { [            3,     dead_grave,      numbersign,   grave           ] };
+    key <AE04> { [            4,     dollar,     asciitilde,     dead_tilde ] };
+    key <AE05> { [            5,        percent,     asciicircum,   dead_circumflex ] };
+    key <AE06> { [            6,      ampersand,         notsign ] };
+    key <AE07> { [            7,          slash,       backslash ] };   // no '\' label on olpcm, leave for compatibility
+    key <AE08> { [            8,      parenleft,    masculine                ] };
+    key <AE09> { [            9,     parenright,    ordfeminine                 ] };
+    key <AE10> { [            0,          equal                  ] };
+    key <AE11> { [   apostrophe,       question                  ] };
+
+    key <AD03> { [            e,              E,        EuroSign ] };
+    key <AD11> { [   dead_acute, dead_diaeresis,     dead_abovering, acute  ] };
+    key <AD12> { [  plus,      asterisk                  ] };
+
+    key <AC10> { [       ntilde,        Ntilde                  ] };
+    // no AC11 or AC12 on olpcm
+
+    key <AB08> { [        comma,      semicolon                  ] };
+    key <AB09> { [       period,          colon                  ] };
+    key <AB10> { [        minus,     underscore                  ] };
+
+    key <AA02>  { [        less,        greater ] };
+    key <AA06>  { [  bracketleft,      braceleft,   ccedilla,         Ccedilla  ] };
+    key <AA07>  { [  bracketright,     braceright                ] };
+
+
+    include "level3(ralt_switch)"
+};
 
 partial alphanumeric_keys
 xkb_symbols "deadtilde" {
Index: xkeyboard-config-2.6/symbols/olpc
===================================================================
--- xkeyboard-config-2.6.orig/symbols/olpc
+++ xkeyboard-config-2.6/symbols/olpc
@@ -13,9 +13,9 @@ xkb_symbols "olpc" {
     modifier_map Mod4 { KP_Prior  }; // KP_Prior is the "O" game key
     modifier_map Mod5 { KP_Next   }; // KP_Next  is the "X" game key
 
-    key <I220> { [ XF86Search    ] }; // search key
-    key <I221> { [ XF86Meeting   ] }; // fn+search key
+    key <I220> { [ XF86Search    ] }; // search key (unpopulated on olpcm, harmless)
+    key <I221> { [ XF86Meeting   ] }; // fn+search key (unpopulated on olpcm, harmless)
     key <I236> { [ XF86Start     ] }; // gear key (fn+space)
-    key <I147> { [ XF86TaskPane  ] }; // frame key (the top-right key)
-    key <I224> { [ XF86Messenger ] }; // overlay key (next to frame key)
+    key <I147> { [ XF86TaskPane  ] }; // frame key (the top-right key) (unpopulated on olpcm, harmless)
+    key <I224> { [ XF86Messenger ] }; // overlay key (next to frame key) (unpopulated on olpcm, harmless)
 };
Index: xkeyboard-config-2.6/symbols/us
===================================================================
--- xkeyboard-config-2.6.orig/symbols/us
+++ xkeyboard-config-2.6/symbols/us
@@ -1033,7 +1033,7 @@ xkb_symbols "olpc" {
    key <AC07>  { [         j,          J,    EuroSign,         EuroSign ] };
    key <AC10>  { [ semicolon,      colon,   masculine,      ordfeminine ] };
    key <AC11>  { [ apostrophe,  quotedbl,    currency,         currency ] };
-   key <BKSL>  { [ backslash,        bar,      section,         section ] };
+   key <AC12>  { [ backslash,        bar,      section,         section ] };
 
    key <AB03>  { [         c,          C,    ccedilla,         Ccedilla ] };
    key <AB06>  { [         n,          N,      ntilde,           Ntilde ] };
@@ -1054,6 +1054,63 @@ xkb_symbols "olpc2" {
    include "group(olpc)"
 };
 
+xkb_symbols "olpcm" {
+
+   include "us(basic)"
+   name[Group1]= "USA";
+
+   // Mechanical (non-membrane) OLPC int'l US English keyboard layout.
+   // See: http://wiki.laptop.org/go/OLPC_English_Non-membrane_Keyboard
+
+   key <TLDE> { [     grave, asciitilde,    dead_grave, dead_tilde ] };
+   key <AE01> { [         1,     exclam,    exclamdown, exclamdown ] };
+   key <AE02> { [         2,         at,       notsign,    notsign ] };
+   key <AE03> { [         3, numbersign,     0x1000300,  0x1000300 ] }; // combining grave
+   key <AE04> { [         4,     dollar,     0x1000301,  0x1000301 ] }; // combining acute
+   key <AE05> { [         5,    percent,     0x1000306,  0x1000306 ] }; // combining breve above
+   key <AE06> { [         6,asciicircum,     0x100030A,  0x100030A ] }; // combining ring above
+   key <AE07> { [         7,  ampersand,     0x1000302,  0x1000302 ] }; // combining circumflex above
+   key <AE08> { [         8,   asterisk,     0x100030C,  0x100030C ] }; // combining caron above
+   key <AE09> { [         9,  parenleft,     0x1000307,  0x1000307 ] }; // combining dot above
+   key <AE10> { [         0, parenright,     0x1000308,  0x1000308 ] }; // combining diaeresis above
+   key <AE11> { [     minus, underscore,     0x1000304,  0x1000304 ] }; // combining macron above
+
+   key <AD01> { [         q,          Q,  Greek_omega, Greek_OMEGA ] };
+   key <AD02> { [         w,          W,       oslash,      Oslash ] };
+   key <AD03> { [         e,          E,           oe,          OE ] };
+   key <AD04> { [         r,          R,    0x1000327,   0x1000327 ] }; // combining cedilla
+   key <AD05> { [         t,          T,    0x100032E,   0x100032E ] }; // combining breve below
+   key <AD06> { [         y,          Y,    0x1000325,   0x1000325 ] }; // combining ring below
+   key <AD07> { [         u,          U,    0x100032D,   0x100032D ] }; // combining circumflex below
+   key <AD08> { [         i,          I,    0x100032C,   0x100032C ] }; // combining caron below
+   key <AD09> { [         o,          O,    0x1000323,   0x1000323 ] }; // combining dot below
+   key <AD10> { [         p,          P,    0x1000324,   0x1000324 ] }; // combining diaeresis below
+   key <AD11> { [ bracketleft,  braceleft,  0x1000331,   0x1000331 ] }; // combining macron below
+   key <AD12> { [bracketright, braceright,  0x1000330,   0x1000330 ] }; // combining tilde below
+
+   key <AC01>  { [         a,          A,          ae,               AE ] };
+   key <AC02>  { [         s,          S,      ssharp,        0x1001E9C ] }; // uppercase S sharp
+   key <AC03>  { [         d,          D,         eth,              ETH ] };
+   key <AC04>  { [         f,          F,       thorn,            THORN ] };
+   key <AC06>  { [         h,          H,    sterling,         sterling ] };
+   key <AC07>  { [         j,          J,    EuroSign,         EuroSign ] };
+   key <AC10>  { [ semicolon,      colon,   masculine,      ordfeminine ] };
+   // no AC11 or AC12 on olpcm
+
+   key <AB03>  { [         c,          C,    ccedilla,         Ccedilla ] };
+   key <AB06>  { [         n,          N,      ntilde,           Ntilde ] };
+   key <AB07>  { [         m,          M,          mu,               mu ] };
+   key <AB08>  { [     comma,     less,  guillemotleft,   guillemotleft ] };
+   key <AB09>  { [    period,  greater, guillemotright,  guillemotright ] };
+   key <AB10>  { [     slash,   question, questiondown,    questiondown ] };
+
+   key <AA02>  { [ backslash,        bar,      section,         section ] };
+   key <AA06>  { [     equal,       plus,     0x1000303,  0x1000303 ] };
+   key <AA07>  { [ apostrophe,  quotedbl,    currency,         currency ] };
+
+   include "level3(ralt_switch)"
+};
+
 // Based on Cherokee Nation Official Layout
 // http://www.cherokee.org/extras/downloads/font/Keyboard.htm