summaryrefslogtreecommitdiff
path: root/symbols
diff options
context:
space:
mode:
authorAndres Gomez <andres.gomez@jolla.com>2015-05-28 19:48:10 +0300
committerSergey Udaltsov <sergey.udaltsov@gmail.com>2016-01-14 01:16:33 +0000
commit09b8c8d782a00ea89a98e80de1b5dfe97981ea6b (patch)
tree1d65b36639c9b6f8add2467bfd762f366f87716a /symbols
parentd5090d4ad9addd2247f4a44e13a4a46be9c98d8c (diff)
Added sbj keymap for Jolla phone
This extended keymap includes keycodes beyond the 255 which are not handled by X11 so it is only suitable for the use with libraries that support extended keycodes, like libxkbcommon. https://bugs.freedesktop.org/show_bug.cgi?id=92238
Diffstat (limited to 'symbols')
-rw-r--r--symbols/Makefile.am2
-rw-r--r--symbols/jolla_vndr/Makefile.am4
-rw-r--r--symbols/jolla_vndr/sbj57
3 files changed, 62 insertions, 1 deletions
diff --git a/symbols/Makefile.am b/symbols/Makefile.am
index 3226d414..3f00283a 100644
--- a/symbols/Makefile.am
+++ b/symbols/Makefile.am
@@ -1,4 +1,4 @@
-SUBDIRS = digital_vndr fujitsu_vndr hp_vndr macintosh_vndr nec_vndr nokia_vndr sharp_vndr sgi_vndr sony_vndr sun_vndr xfree68_vndr
+SUBDIRS = digital_vndr fujitsu_vndr hp_vndr jolla_vndr macintosh_vndr nec_vndr nokia_vndr sharp_vndr sgi_vndr sony_vndr sun_vndr xfree68_vndr
symbolsdir = $(xkb_base)/symbols
symbols_DATA = \
diff --git a/symbols/jolla_vndr/Makefile.am b/symbols/jolla_vndr/Makefile.am
new file mode 100644
index 00000000..7e43bb32
--- /dev/null
+++ b/symbols/jolla_vndr/Makefile.am
@@ -0,0 +1,4 @@
+symbolsdir = $(xkb_base)/symbols/jolla_vndr
+
+dist_symbols_DATA = \
+sbj
diff --git a/symbols/jolla_vndr/sbj b/symbols/jolla_vndr/sbj
new file mode 100644
index 00000000..d2388c39
--- /dev/null
+++ b/symbols/jolla_vndr/sbj
@@ -0,0 +1,57 @@
+// Instructions
+//
+// 1. Set basic layout by:
+// setxkbmap -rules evdev -model jollasbj -layout cz
+//
+// 2. Set variant by:
+// setxkbmap -rules evdev -model jollasbj -layout cz -variant qwerty
+// In practice this is equivalent to:
+// setxkbmap -rules evdev -model jollasbj -layout cz_qwerty
+// However, the latter form isn't portable so always use the -variant option.
+//
+// 3. Set multilayout by:
+// setxkbmap -rules evdev -model jollasbj -layout "us,cz" -variant ",qwerty" -option grp:ctrl_shift_toggle
+// This sets the basic us layout active. You can switch to qwerty
+// variant of cz layout by pressing ctrl+shift.
+//
+// Pitfalls
+//
+// 1. Many to one mappings
+//
+// Higher level input method components don't necessarily handle many to
+// one mappings correctly. They may assume that there exists only a one
+// to one mapping between a hardware key and a symbol. Therefore you
+// should take care not to introduce many to one mappings for keys that
+// are going to be reverse mapped from a symbol to a hardware key.
+//
+// Currently at least the modifier keys are affected. Clients may set
+// states, such as autorepeat, for hardware keys by reverse mapping a
+// modifier symbol to a hardware key and then setting the state for the
+// first hardware key that maps to the symbol. The correct way would be
+// to modify the state of all hardware keys mapping to a given symbol.
+//
+// We are nice and keep the mappings one to one for clients that don't
+// choose to handle many to one mappings.
+
+
+
+default partial alphanumeric_keys
+xkb_symbols "common" {
+ include "pc(pc105)"
+ include "jolla_vndr/sbj(common-keys)"
+
+ // This section should not be included by any other section. It's
+ // referenced only once by rule file to allow multiple layout
+ // configurations.
+};
+
+partial hidden alphanumeric_keys
+xkb_symbols "common-keys" {
+
+ // These keycodes are beyond the X11 255 limit value so it would
+ // only be valid for the use with SW which supports extended keycodes,
+ // like xkbcommon.
+
+ // generated from the headset, must always be in the map.
+ key <I264> { [ XF86Phone ] };
+};