[PATCH] protocol: Document how clients are supposed to get the xkb keycode

Rui Matos tiagomatos at gmail.com
Tue Mar 25 08:35:39 PDT 2014


This encodes what everyone is doing and avoids other implementers
having to guess.
---

Jasper suggested that it would be nice if the compositor sent keycodes
that clients could use directly as an index in the keymap. I suppose
we can't do that at this point so we should at least document it
clearly in the protocol so that implementers don't have to guess.


 protocol/wayland.xml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/protocol/wayland.xml b/protocol/wayland.xml
index 3aa89af..db1b349 100644
--- a/protocol/wayland.xml
+++ b/protocol/wayland.xml
@@ -1503,7 +1503,8 @@
       </description>
       <entry name="no_keymap" value="0"
 	     summary="no keymap; client must understand how to interpret the raw keycode"/>
-      <entry name="xkb_v1" value="1" summary="libxkbcommon compatible"/>
+      <entry name="xkb_v1" value="1"
+             summary="libxkbcommon compatible; to determine the xkb keycode, clients must add 8 to the key event keycode"/>
     </enum>
 
     <event name="keymap">
-- 
1.9.0



More information about the wayland-devel mailing list