aboutsummaryrefslogtreecommitdiff
path: root/libX11/specs
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-09-14 14:23:18 +0200
committermarha <marha@users.sourceforge.net>2011-09-14 14:23:18 +0200
commit16b53769eba7d5d8249a217aa29287d72b7713c2 (patch)
tree0f763704293799f7fce6ed4f0f57188159660607 /libX11/specs
parent24a692ce832161d3b794110dd82b1508d38a0887 (diff)
downloadvcxsrv-16b53769eba7d5d8249a217aa29287d72b7713c2.tar.gz
vcxsrv-16b53769eba7d5d8249a217aa29287d72b7713c2.tar.bz2
vcxsrv-16b53769eba7d5d8249a217aa29287d72b7713c2.zip
libX11 git update 14 sep 2011
Diffstat (limited to 'libX11/specs')
-rw-r--r--libX11/specs/XIM/xim.xml7826
-rw-r--r--libX11/specs/XKB/Makefile.am61
-rw-r--r--libX11/specs/XKB/XKBlib-1.svg767
-rw-r--r--libX11/specs/XKB/XKBlib-10.svg1441
-rw-r--r--libX11/specs/XKB/XKBlib-11.svg920
-rw-r--r--libX11/specs/XKB/XKBlib-12.svg687
-rw-r--r--libX11/specs/XKB/XKBlib-13.svg186
-rw-r--r--libX11/specs/XKB/XKBlib-14.svg557
-rw-r--r--libX11/specs/XKB/XKBlib-15.svg885
-rw-r--r--libX11/specs/XKB/XKBlib-16.svg643
-rw-r--r--libX11/specs/XKB/XKBlib-17.svg626
-rw-r--r--libX11/specs/XKB/XKBlib-18.svg907
-rw-r--r--libX11/specs/XKB/XKBlib-19.svg582
-rw-r--r--libX11/specs/XKB/XKBlib-2.svg761
-rw-r--r--libX11/specs/XKB/XKBlib-20.svg379
-rw-r--r--libX11/specs/XKB/XKBlib-21.svg976
-rw-r--r--libX11/specs/XKB/XKBlib-3.svg1133
-rw-r--r--libX11/specs/XKB/XKBlib-4.svg574
-rw-r--r--libX11/specs/XKB/XKBlib-5.svg542
-rw-r--r--libX11/specs/XKB/XKBlib-6.svg551
-rw-r--r--libX11/specs/XKB/XKBlib-7.svg352
-rw-r--r--libX11/specs/XKB/XKBlib-8.svg1143
-rw-r--r--libX11/specs/XKB/XKBlib-9.svg2075
-rw-r--r--libX11/specs/XKB/acknowledgement.xml35
-rw-r--r--libX11/specs/XKB/ch01.xml404
-rw-r--r--libX11/specs/XKB/ch02.xml818
-rw-r--r--libX11/specs/XKB/ch03.xml247
-rw-r--r--libX11/specs/XKB/ch04.xml825
-rw-r--r--libX11/specs/XKB/ch05.xml977
-rw-r--r--libX11/specs/XKB/ch06.xml413
-rw-r--r--libX11/specs/XKB/ch07.xml446
-rw-r--r--libX11/specs/XKB/ch08.xml2087
-rw-r--r--libX11/specs/XKB/ch09.xml1060
-rw-r--r--libX11/specs/XKB/ch10.xml5347
-rw-r--r--libX11/specs/XKB/ch11.xml572
-rw-r--r--libX11/specs/XKB/ch12.xml841
-rw-r--r--libX11/specs/XKB/ch13.xml4146
-rw-r--r--libX11/specs/XKB/ch14.xml1637
-rw-r--r--libX11/specs/XKB/ch15.xml2600
-rw-r--r--libX11/specs/XKB/ch16.xml4794
-rw-r--r--libX11/specs/XKB/ch17.xml1789
-rw-r--r--libX11/specs/XKB/ch18.xml1182
-rw-r--r--libX11/specs/XKB/ch19.xml328
-rw-r--r--libX11/specs/XKB/ch20.xml1188
-rw-r--r--libX11/specs/XKB/ch21.xml2043
-rw-r--r--libX11/specs/XKB/ch22.xml216
-rw-r--r--libX11/specs/XKB/glossary.xml1016
-rw-r--r--libX11/specs/XKB/xkblib.xml106
-rw-r--r--libX11/specs/i18n/compose/Makefile.am20
-rw-r--r--libX11/specs/i18n/compose/compose-chart.pl388
-rw-r--r--libX11/specs/i18n/compose/docbook-nl.am128
-rw-r--r--libX11/specs/i18n/framework/framework.xml7
-rw-r--r--libX11/specs/i18n/trans/trans.xml8
-rw-r--r--libX11/specs/libX11/libX11.xml295
54 files changed, 56473 insertions, 4064 deletions
diff --git a/libX11/specs/XIM/xim.xml b/libX11/specs/XIM/xim.xml
index 923a59d7c..fbb603c20 100644
--- a/libX11/specs/XIM/xim.xml
+++ b/libX11/specs/XIM/xim.xml
@@ -1,3912 +1,3914 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
- "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-
-
-<!-- lifted from troff+ms+XMan by doclifter -->
-<article class="specification" id="xim">
-
-<articleinfo>
- <title>The Input Method Protocol</title>
- <subtitle>X Consortium Standard</subtitle>
- <releaseinfo>X Version 11, Release 6.4</releaseinfo>
- <authorgroup>
- <author>
- <firstname>Masahiko</firstname><surname>Narita</surname>
- <affiliation><orgname>FUJITSU Limited.</orgname></affiliation>
- </author>
- <author>
- <firstname>Hideki</firstname><surname>Hiura</surname>
- <affiliation><orgname>SunSoft, Inc.</orgname></affiliation>
- </author>
- </authorgroup>
- <copyright><year>1993</year><year>1994</year><holder>X Consortium</holder></copyright>
- <copyright><year>1993</year><year>1994</year><holder>FUJITSU LIMITED</holder></copyright>
- <copyright><year>1993</year><year>1994</year><holder>Oracle and/or its affiliates</holder></copyright>
- <releaseinfo>Version 1.0</releaseinfo>
- <affiliation><orgname>X Consortium</orgname></affiliation>
- <productnumber>X Version 11, Release 7</productnumber>
-
-<abstract>
-<para>
-This specifies a protocol between IM library and IM (Input Method) Server for internationalized text input, which is indepedent from any specific language, any specific input method and the transport layer used in communication between the IM library and the IM Server, and uses a client-server model. This protocol allows user to use his/her favorite method for all applications within the stand-along distrubuted environment.
-</para>
-</abstract>
-
-<legalnotice>
-<para>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the &ldquo;Software&rdquo;), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</para>
-
-<para>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</para>
-
-<para>THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</para>
-
-<para>Except as contained in this notice, the name of the X Consortium shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from the X Consortium.</para>
-
-<para>X Window System is a trademark of The Open Group.</para>
-
-<para>Permission to use,copy and distribute this documetation for any purpose and without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. Fujitsu and Sun Microsystems make no representation about the suitability for any purpose of the information in this documen. This documentation is provided as is without express implied warranty.
-</para>
-
-</legalnotice>
-
-</articleinfo>
-
-<sect1 id="Introduction">
-<title>Introduction</title>
-<sect2 id="Scope">
-<title>Scope</title>
-<!-- .XS -->
-<!-- (SN Scope -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-The internationalization in the
-X Window System
-Version 11, Release 5 (X11R5) provides a common API which application
-developers can use to create portable internationalized programs and to
-adapt them to the requirements of different native languages, local customs,
-and character string encodings (this is called "localization").
-As one of its internationalization mechanisms X11R5 has defined a functional
-interface for internationalized text input, called XIM (X Input Method).
-</para>
-<para>
-<!-- .LP -->
-When a client-server model is used with an IM (Input Method) implementation,
-a protocol must be established between the client and the server.
-However, the protocol used to interface Input Method Servers (IM Servers)
-with the Input Method libraries (IM libraries) to which applications are
-linked was not addressed in X11R5.
-This led application developers to depend on vendor-specific input methods,
-decreased the user's choice of available input methods, and made it more
-difficult for developers to create portable applications. This paper describes
-the Input Method Protocol developed for X11R6 to resolve the above problems
-and to address the requirements of existing and future input methods.
-</para>
-<para>
-<!-- .LP -->
-The Input Method Protocol is independent from the transport layer used in
-communication between the IM library and the IM Server.
-Thus, the input method protocol can be built on any inter-process
-communication mechanism, such as TCP/IP or the X protocol.
-</para>
-<para>
-In addition, the protocol provides for future extensions such as differing
-input model types.
-</para>
-</sect2>
-
-<sect2 id="Background">
-<title>Background</title>
-<!-- .XS -->
-<!-- (SN Background -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-Text input is much more simple for some languages than
-others. English, for instance, uses an alphabet of a manageable size,
-and input consists of pressing the corresponding key on a keyboard,
-perhaps in combination with a shift key for capital letters or special
-characters.
-</para>
-<para>
-<!-- .LP -->
-Some languages have larger alphabets, or modifiers such as accents,
-which require the addition of special key combinations in order to enter
-text. These input methods may require "dead-keys" or "compose-keys"
-which, when followed by different combinations of key strokes,
-generate different characters.
-</para>
-<para>
-<!-- .LP -->
-Text input for ideographic languages is much less simple. In these
-languages, characters represent actual objects rather than phonetic
-sounds used in pronouncing a word, and the number of characters
-in these languages may continue to grow. In Japanese, for instance, most
-text input methods involve entering characters in a phonetic alphabet,
-after which the input method searches a dictionary for possible
-ideographic equivalents (of which there may be many). The input method then
-presents the candidate characters for the user to choose from.
-</para>
-<para>
-<!-- .LP -->
-In Japanese, either Kana (phonetic symbols) or Roman letters are
-typed and then a region is selected for conversion to Kanji. Several
-Kanji characters may have the same phonetic representation. If that
-is the case with the string entered, a menu of characters is presented
-and the user must choose the appropriate one. If no choice is necessary
-or a preference has been established, the input method does the
-substitution directly.
-</para>
-<para>
-<!-- .LP -->
-These complicated input methods must present state information (Status Area),
-text entry and edit space (Preedit Area), and menu/choice presentations
-(Auxiliary Area). Much of the protocol between the IM library and the IM
-Server involves managing these IM areas.
-Because of the size and complexity of these input methods, and because
-of how widely they vary from one language or locale to another, they are
-usually implemented as separate processes which can serve many client
-processes on the same computer or network.
-</para>
-<para>
-<!-- .LP -->
-</para>
-</sect2>
-<sect2 id="Input_Method_Styles">
-<title>Input Method Styles</title>
-<!-- .XS -->
-<!-- (SN Input Method Styles -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-X11 internationalization support includes the following four types of
-input method:
-<!-- .RS -->
-</para>
-
-<variablelist>
- <varlistentry>
- <term>- on-the-spot:</term>
- <listitem>
- <para>
-The client application is directed by the IM Server to display all
-pre-edit data at the site of text insertion. The client registers
-callbacks invoked by the input method during pre-editing.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>- off-the-spot:</term>
- <listitem>
- <para>
-The client application provides display windows for the pre-edit data
-to the input method which displays into them directly.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>- over-the-spot:</term>
- <listitem>
- <para>
-The input method displays pre-edit data in a window which it brings up
-directly over the text insertion position.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>- root-window:</term>
- <listitem>
- <para>
-The input method displays all pre-edit data in a separate area of the
-screen in a window specific to the input method.
- </para>
- </listitem>
- </varlistentry>
-</variablelist>
-
-<para>
-Client applications must choose from the available input methods
-supported by the IM Server and provide the display areas and callbacks
-required by the input method.
-</para>
-</sect2>
-
-</sect1>
-<sect1 id="Architecture">
-<title>Architecture</title>
-<!-- .XS -->
-<!-- (SN Architecture -->
-<!-- .XE -->
-<sect2 id="Implementation_Model">
-<title>Implementation Model</title>
-<!-- .XS -->
-<!-- (SN Implementation Model -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-Within the X Window System environment, the following two typical
-architectural models can be used as an input method's implementation
-model.
-</para>
-
-<variablelist>
- <varlistentry>
- <term>- Client/Server model:</term>
- <listitem>
- <para>
-A separate process, the IM Server, processes input and handles preediting,
-converting, and committing. The IM library within the application, acting
-as client to the IM Server, simply receives the committed string from the
-IM Server.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>- Library model:</term>
- <listitem>
- <para>
-All input is handled by the IM library within the application. The
-event process is closed within the IM library and a separate IM Server
-process may not be required.
- </para>
- </listitem>
- </varlistentry>
-</variablelist>
-
-<para>
-<!-- .LP -->
-Most languages which need complex preediting, such as Asian languages,
-are implemented using the Client/Server IM model. Other languages
-which need only dead key or compose key processing, such as European
-languages, are implemented using the Library model.
-</para>
-<para>
-<!-- .LP -->
-In this paper, we discuss mainly the Client/Server IM model and the
-protocol used in communication between the IM library (client) and the IM
-Server.
-</para>
-</sect2>
-
-<sect2 id="Structure_of_IM">
-<title>Structure of IM</title>
-<!-- .XS -->
-<!-- (SN Structure of IM -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-When the client connects or disconnects to the IM Server, an open or close
-operation occurs between the client and the IM Server.
-</para>
-<para>
-<!-- .LP -->
-The IM can be specified at the time of XOpenIM() by setting the locale
-of the client and a locale modifier. Since the IM remembers
-the locale at the time of creation XOpenIM() can be called
-multiple times (with the
-setting for the locale and the locale modifier changed) to support
-multiple languages.
-</para>
-<para>
-<!-- .LP -->
-In addition, the supported IM type can be obtained using XGetIMValues().
-</para>
-<para>
-<!-- .LP -->
-The client usually holds multiple input (text) fields. Xlib provides a
-value type called the "Input Context" (IC) to manage each individual
-input field. An IC can be created by specifying XIM using XCreateIC(),
-and it can be destroyed using XDestroyIC().
-</para>
-<para>
-<!-- .LP -->
-The IC can specify the type of IM which is supported by XIM for each
-input field, so each input field can handle a different type of IM.
-</para>
-<para>
-<!-- .LP -->
-Most importantly information such as the committed string sent from
-the IM Server to the client, is exchanged based on each IC.
-</para>
-<para>
-<!-- .LP -->
-Since each IC corresponds to an input field, the focused input field
-should be announced to the IM Server using XSetICFocus(). (XUnsetICFocus()
-can also be used to change the focus.)
-</para>
-<para>
-<!-- .LP -->
-</para>
-</sect2>
-<sect2 id="Event_Handling_Model">
-<title>Event Handling Model</title>
-<!-- .XS -->
-<!-- (SN Event Handling Model -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-Existing input methods support either the FrontEnd method, the BackEnd method,
-or both. This protocol specifically supports the BackEnd method as
-the default method, but also supports the FrontEnd method as an optional
-IM Server extension.
-</para>
-<para>
-<!-- .LP -->
-The difference between the FrontEnd and BackEnd methods is in how
-events are delivered to the IM Server. (Fig. 1) <!-- xref -->
-</para>
-
-<sect3 id="BackEnd_Method">
-<title>BackEnd Method</title>
-<!-- .XS -->
-<!-- (SN BackEnd Method -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-In the BackEnd method, client window input events are always delivered
-to the IM library, which then passes them to the IM Server. Events are
-handled serially in the order delivered, and therefore there is no
-synchronization problem between the IM library and the IM Server.
-</para>
-<para>
-<!-- .LP -->
-Using this method, the IM library forwards all KeyPress and KeyRelease
-events to the IM Server (as required by the Event Flow Control model
-described in
-<link linkend="event_flow_control">
-<xref linkend="event_flow_control"></xref></link>)
-and synchronizes with the IM Server (as described in
-<link linkend="filtering_events">
-<xref linkend="filtering_events"></xref></link>).
-
-</para>
-</sect3>
-
-<sect3 id="FrontEnd_Method">
-<title>FrontEnd Method</title>
-<!-- .XS -->
-<!-- (SN FrontEnd Method -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-In the FrontEnd method, client window input events are delivered by the
-X server directly to both the IM Server and the IM library. Therefore this
-method provides much better interactive performance while preediting
-(particularly in cases such as when the IM Server is running locally on
-the user's workstation and the client application is running on another
-workstation over a relatively slow network).
-</para>
-<para>
-<!-- .LP -->
-However, the FrontEnd model may have synchronization problems between
-the key events handled in the IM Server and other events handled in the
-client, and these problems could possibly cause the loss or duplication
-of key events. For this reason, the BackEnd method is the core method
-supported, and the FrontEnd method is made available as an extension for
-performance purposes. (Refer to
-<link linkend="common_extensions">
-<xref linkend="common_extensions"></xref></link>
-for more information.)
-</para>
-
-<mediaobject id="flow_of_events">
- <imageobject>
- <imagedata format="SVG" fileref="eventflow.svg"/>
- </imageobject>
- <caption>The flow of events</caption>
-</mediaobject>
-
-<!--
-<para>
-Fig.1 The Flow of Events
-</para>
--->
-
-</sect3>
-</sect2>
-
-<sect2 id="event_flow_control">
-<title>Event Flow Control</title>
-<!-- .XS -->
-<!-- (SN Event Flow Control -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-This protocol supports two event flow models for communication between the
-IM library and the IM Server (Static and Dynamic).
-</para>
-<para>
-<!-- .LP -->
-Static Event Flow requires that input events always be sent to the IM
-Server from the client.
-</para>
-<para>
-<!-- .LP -->
-Dynamic Event Flow, however, requires only that those input events which
-need to be processed (converted) be sent to the IM Server from the client.
-</para>
-<para>
-<!-- .LP -->
-For instance, in the case of inputing a combination of ASCII characters
-and Chinese characters, ASCII characters do not need to be processed in
-the IM Server, so their key events do not have to be sent to the IM
-Server. On the other hand, key events necessary for composing Chinese
-characters must be sent to the IM Server.
-</para>
-<para>
-<!-- .LP -->
-Thus, by adopting the Dynamic Event Flow, the number of requests among the
-X Server, the client, and the IM Server is significantly reduced, and the
-number of context switches is also reduced, resulting in improved performance.
-The IM Server can send
-<function>XIM_REGISTER_TRIGGERKEYS </function>
-message in order to switch the event flow in the Dynamic Event Flow.
-</para>
-<para>
-<!-- .LP -->
-The protocol for this process is described in
-<link linkend="event_flow_control_2">
-<xref linkend="event_flow_control_2"></xref></link>.
-</para>
-</sect2>
-</sect1>
-
-<sect1 id="Default_Preconnection_Convention">
-<title>Default Preconnection Convention</title>
-<!-- .XS -->
-<!-- (SN Default Preconnection Convention -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-IM Servers are strongly encouraged to register their symbolic
-names as the ATOM names into the IM Server directory property,
-<function>XIM_SERVERS,</function>
-on the root window of the screen_number 0.
-This property can contain a list of ATOMs, and the each ATOM represents
-each possible IM Server.
-IM Server names are restricted to POSIX Portable Filename Character Set.
-To discover if the IM Server is active, see if there is an owner for
-the selection with that atom name. To learn the address of that IM Server,
-convert the selection target
-<function>TRANSPORT,</function>
-which will return a string form of the transport address(es).
-To learn the supported locales of that IM Server, convert the selection target
-<function>LOCALES,</function>
-which will return a set of names of the supported locales in the syntax
-X/Open defines.
-</para>
-<para>
-<!-- .LP -->
-The basic semantics to determine the IM Server if there are
-multiple ATOMs are found in
-<function>XIM_SERVERS</function>
-property, is first fit if the IM Server name is not given as
-a X modifier's category
-<function>im.</function>
-</para>
-<para>
-<!-- .LP -->
-The address information retrievable from the
-<function>TRANSPORT</function>
-target is a transport-specific name.
-The preregistered formats for transport-specific names are listed in
-<link linkend="transport_list">
-<xref linkend="transport_list"></xref></link>.
-Additional transport-specific names may be registered with X Consortium.
-</para>
-
-<para>
-For environments that lack X connections, or for IM Servers which
-do not use the X Window System, the preconnection convention with IM Server
-may be given outside the X Window system (e.g. using a Name Service).
-</para>
-</sect1>
-
-<sect1 id="Protocol">
-<title>Protocol</title>
-<!-- .XS -->
-<!-- (SN Protocol -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-The protocol described below uses the bi-directional
-synchronous/asynchronous request/reply/error model and is specified
-using the same conventions outlined in Section 2 of the core X Window
-System protocol [1]:
-</para>
-
-<sect2 id="Basic_Requests_Packet_Format">
-<title>Basic Requests Packet Format</title>
-<!-- .XS -->
-<!-- (SN Basic Requests Packet Format -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-This section describes the requests that may be exchanged between the client
-and the IM Server.
-</para>
-<para>
-<!-- .LP -->
-The basic request packet header format is as follows.
-</para>
-<literallayout class="monospaced">
- major-opcode: CARD8
- minor-opcode: CARD8
- length: CARD16
-</literallayout>
-
-<para>
-The MAJOR-OPCODE specifies which core request or extension package this
-packet represents. If the MAJOR-OPCODE corresponds to a core request,
-the MINOR-OPCODE contains 8 bits of request-specific data.
-(If the MINOR-OPCODE is not used, it is 0.)
-Otherwise, the MAJOR-OPCODE and the MINOR-OPCODE are specified by
-<function>XIM_QUERY_EXTENSION</function>
-message. (Refer to 4.7. Query the supported extension protocol list.)
-The LENGTH field specifies the number of 4 bytes elements following the
-header. If no additional data is followed by the header, the LENGTH field
-will be 0.
-</para>
-</sect2>
-
-<sect2 id="Data_Types">
-<title>Data Types</title>
-<!-- .XS -->
-<!-- (SN Data Types -->
-<!-- .XE -->
-<para>
-The following data types are used in the core X IM Server protocol:
-</para>
-
-<literallayout class="monospaced">
-BITMASK16
- CARD16
-BITMASK32
- CARD32
-PADDING FORMAT
- Where N is some expression, and Pad(N) is the number of bytes needed to round N up to a
-
- Pad(N) = (4 - (N mod 4)) mod 4
-
-LPCE
- 1 A character from the4 X Portable Character Set in Latin Portable
- Character Encoding
-
-STRING
- 2 n length of string in bytes
- n LISTofLPCE string
- p unused, p=Pad(2+n)
-
-STR
- 1 n length of name in bytes
- n STRING8 name
-
-XIMATTR
- 2 CARD16 attribute ID (*1)
- 2 CARD16 type of the value (*2)
- 2 n length of im-attribute
- n STRING8 im-attribute
- p unused, p = Pad(2+n)
-
-The im-attribute argument specifies XIM values such as XNQueryInputStyle.
-
-XICATTR
- 2 CARD16 attribute ID (*1)
- 2 CARD16 type of the value (*2)
- 2 n length of ic-attribute
- n STRING8 ic-attribute
- p unused, p = Pad(2+n)
-
-(*1) XIMATTR and XICATTR are used during the setup stage and XIMATTRIBUTE and
- XICATTRIBUTE are used after each attribute ID has been recognized by
- the IM Server and the IM library.
-
-(*2) The value types are defined as follows:
-</literallayout>
-<informaltable id="valuetypes" frame="none">
- <tgroup cols="5">
- <colspec colname="col1" colsep="0"/>
- <colspec colname="col2" colsep="0"/>
- <colspec colname="col3" colsep="0"/>
- <colspec colname="col4" colsep="0"/>
- <colspec colname="col5" colsep="0"/>
- <spanspec namest="col3" nameend="col5" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry>values</entry>
- <entry>data</entry>
- <entry>format</entry>
- <!-- <entry spanname="span-horiz">format</entry> -->
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>#0</entry>
- <entry>Separator of NestedList</entry>
- <entry>-----(*3)</entry>
- </row>
- <row rowsep="0">
- <entry>#1</entry>
- <entry>byte data</entry>
- <entry>CARD8</entry>
- </row>
- <row rowsep="0">
- <entry>#2</entry>
- <entry>word data</entry>
- <entry>CARD16</entry>
- </row>
- <row rowsep="0">
- <entry>#3</entry>
- <entry>long data</entry>
- <entry>CARD32</entry>
- </row>
- <row rowsep="0">
- <entry>#4</entry>
- <entry>char data</entry>
- <entry>STRING8</entry>
- </row>
- <row rowsep="0">
- <entry>#5</entry>
- <entry>Window</entry>
- <entry>CARD32</entry>
- </row>
- <row rowsep="0">
- <entry>#10</entry>
- <entry>XIMStyles</entry>
- <entry>2</entry>
- <entry>n</entry>
- <entry>number of XIMStyle list</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>2</entry>
- <entry></entry>
- <entry>unused</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>n</entry>
- <entry>CARD32</entry>
- <entry>XIMStyle list</entry>
- </row>
- <row rowsep="0">
- <entry>#11</entry>
- <entry>XRectangle</entry>
- <entry>2</entry>
- <entry>INT16</entry>
- <entry>X</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>2</entry>
- <entry>INT16</entry>
- <entry>Y</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>2</entry>
- <entry>CARD16</entry>
- <entry>width</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>2</entry>
- <entry>CARD16</entry>
- <entry>height</entry>
- </row>
- <row rowsep="0">
- <entry>#12</entry>
- <entry>XPoint</entry>
- <entry>2</entry>
- <entry>INT16</entry>
- <entry>X</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>2</entry>
- <entry>INT16</entry>
- <entry>Y</entry>
- </row>
- <row rowsep="0">
- <entry>#13</entry>
- <entry>XFontSet</entry>
- <entry>2</entry>
- <entry>n</entry>
- <entry>length of Base font name</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>n</entry>
- <entry>STRING8</entry>
- <entry>Base font name list</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>p</entry>
- <entry></entry>
- <entry>unused, p = Pad(2+n)</entry>
- </row>
- <row rowsep="0">
- <entry>#15</entry>
- <entry>XIMHotKeyTriggers</entry>
- <entry>4</entry>
- <entry>n</entry>
- <entry>number of XIMTRIGGERKEY list (*4)</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>n</entry>
- <entry>XIMTRIGGERKEY</entry>
- <entry>XIMHotkeyTrigger list</entry>
- </row>
- <row rowsep="0">
- <entry></entry>
- <entry></entry>
- <entry>n</entry>
- <entry>XIMHOTKEYSTATE</entry>
- <entry>HotKey processing state</entry>
- </row>
- <row rowsep="0">
- <entry>#17</entry>
- <entry>XIMStringConversion</entry>
- <entry>XIMSTRCONVTEXT</entry>
- <entry></entry>
- <entry></entry>
- </row>
- <row rowsep="0">
- <entry>#18</entry>
- <entry>XIMPreeditState</entry>
- <entry>XIMPREEDITSTATE</entry>
- </row>
- <row rowsep="0">
- <entry>#19</entry>
- <entry>XIMResetState</entry>
- <entry>XIMRESETSTATE</entry>
- </row>
- <row rowsep="0">
- <entry>#x7fff</entry>
- <entry>NestedList</entry>
- <entry>-----</entry>
- </row>
- </tbody>
- </tgroup>
-</informaltable>
-
-<literallayout class="monospaced">
-(*3) The IC value for the separator of NestedList is defined as follows,
- #define XNSeparatorofNestedList "separatorofNestedList"
- , which is registered in X Consortium and cannot be used for any other purpose.
-
-(*4) LISTofFOO
- A Type name of the form LISTof FOO means a counted list of elements of type FOO.
- The size of the length field may vary (it is not necessarily the same
- size as a FOO), and in some cases, it may be implicit.
-XIMTRIGGERKEY
- 4 CARD32 keysym
- 4 CARD32 modifier
- 4 CARD32 modifier mask
-
-ENCODINGINFO
- 2 n length of encoding info
- n STRING8 encoding info
- p unused, p=Pad(2+n)
-
-
- 1 CARD8 extension major-opcode
- 1 CARD8 extension minor-opcode
- 2 n length of extension name
- n STRING8 extension name
- p unused, p = Pad(n)
-
-XIMATTRIBUTE
- 2 CARD16 attribute ID
- 2 n value length
- n value
- p unused, p = Pad(n)
-
-XICATTRIBUTE
- 2 CARD16 attribute ID
- 2 n value length
- n value
- p unused, p = Pad(n)
-
-
-
-XIMSTRCONVTEXT
- 2 CARD16 XIMStringConversionFeedback
- #x0000001 XIMStringConversionLeftEdge
- #x0000002 XIMStringConversionRightEdge
- #x0000004 XIMStringConversionTopEdge
- #x0000008 XIMStringConversionBottomEdge
- #x0000010 XIMStringConversionConvealed
- #x0000020 XIMStringConversionWrapped
- 2 n byte length of the retrieved string
- n STRING8 retrieved string
- p unused, p = Pad(n)
- 2 m byte length of feedback array
- 2 unused
- m LISTofXIMSTRCONVFEEDBACK feedback array(*1)
-
-(*1) This field is reserved for future use.
-
-XIMFEEDBACK
- 4 CARD32 XIMFeedback
- #x000001 XIMReverse
- #x000002 XIMUnderline
- #x000004 XIMHighlight
- #x000008 XIMPrimary
- #x000010 XIMSecondary
- #x000020 XIMTertiary
- #x000040 XIMVisibleToForward
- #x000080 XIMVisibleToBackward
- #x000100 XIMVisibleCenter
-
-XIMHOTKEYSTATE
- 4 CARD32 XIMHotKeyState
- #x0000001 XIMHotKeyStateON
- #x0000002 XIMHotKeyStateOFF
-
-XIMPREEDITSTATE
- 4 CARD32 XIMPreeditState
- #x0000001 XIMPreeditEnable
- #x0000002 XIMPreeditDisable
-
-XIMRESETSTATE
- 4 CARD32 XIMResetState
- #x0000001 XIMInitialState
- #x0000002 XIMPreserveState
-</literallayout>
-</sect2>
-
-<sect2 id="Error_Notification">
-<title>Error Notification</title>
-<!-- .XS -->
-<!-- (SN Error Notification -->
-<!-- .XE -->
-<para>
-Both the IM Server and the IM library return
-<function>XIM_ERROR</function>
-messages instead of the corresponding reply messages if any errors occur
-during data processing.
-</para>
-
-<para>
-At most one error is generated per request. If more than one error condition
-is encountered in processing a request, the choice of which error is returned
-is implementation-dependent.
-</para>
-
-<literallayout class="monospaced">
-XIM_ERROR (IM Server &lt;--&gt; IM library)
-<!-- .sp 6p -->
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 BITMASK16 flag (*1)
- #0000 Both Input-Method-ID and Input-Context-ID are invalid
- #0001 Input-Method-ID is valid
- #0002 Input-Context-ID is valid
- 2 CARD16 Error Code
- #1 BadAlloc
- #2 BadStyle
- #3 BadClientWindow
- #4 BadFocusWindow
- #5 BadArea
- #6 BadSpotLocation
- #7 BadColormap
- #8 BadAtom
- #9 BadPixel
- #10 BadPixmap
- #11 BadName
- #12 BadCursor
- #13 BadProtocol
- #14 BadForeground
- #15 BadBackground
- #16 LocaleNotSupported
- #999 BadSomething (*2)
- 2 n byte length of error detail.
- 2 CARD16 type of error detail (*3)
- n STRING8 error detail (*4)
- p unused, p = Pad(n)
-
-(*1) Before an IM is created, both Input-Method-ID and
- Input-Context-ID are invalid.
- Before an IC is created, only Input-Method-ID is valid.
- After that, both of Input-Method-ID and Input-Context-ID are valid.
-
-(*2) Unspecific error, for example "language engine died"
-
-(*3) This field is reserved for future use.
-
-(*4) Vendor defined detail error message
-</literallayout>
-</sect2>
-
-<sect2 id="Connection_Establishment">
-<title>Connection Establishment</title>
-<!-- .XS -->
-<!-- (SN Connection Establishment -->
-<!-- .XE -->
-<para>
-<function>XIM_CONNECT</function>
-message requests to establish a connection over a mutually-understood virtual
-stream.
-</para>
-
-<literallayout class="monospaced">
-XIM_CONNECT (IM library -&gt; IM Server)
- 1 byte order
- #x42 MSB first
- #x6c LSB first
- 1 unused
- 2 CARD16 client-major-protocol-version (*1)
- 2 CARD16 client-minor-protocol-version (*1)
- 2 CARD16 number of client-auth-protocol-names
- n LISTofSTRING client-auth-protocol-names
-
-(*1) Specify the version of IM Protocol that the client supports.
-</literallayout>
-
-<para>
-A client must send
-<function>XIM_CONNECT</function>
-message as the first message on the connection.
-The list specifies the names of authentication protocols the sending
-IM Server is willing to perform.
-(If the client need not authenticate, the list may be omited.)
-</para>
-
-<para>
-<function>XIM_AUTH_REQUIRED </function>
-message is used to send the authentication protocol name and protocol-specific
-data.
-</para>
-
-<literallayout class="monospaced">
-XIM_AUTH_REQUIRED (IM library &lt;--&gt; IM Server)
-
- 1 CARD8 auth-protocol-index
- 3 unused
- 2 n length of authentication data
- 2 unused
- n &lt;varies&gt; data
- p unused, p = Pad(n)
-</literallayout>
-
-<para>
-The auth-protocol is specified by an index into the list of names
-given in the
-<function>XIM_CONNECT</function>
-or
-<function>XIM_AUTH_SETUP</function>
-message. Any protocol-specific data that might be required is also sent.
-</para>
-
-<para>
-The IM library sends
-<function>XIM_AUTH_REPLY</function>
-message as the reply to
-<function>XIM_AUTH_REQUIRED</function>
-message, if the IM Server is authenticated.
-</para>
-
-<literallayout class="monospaced">
-XIM_AUTH_REPLY (IM library -&gt; IM Server)
- 2 n length of authentication data
- 2 unused
- 2 n length of authentication data
- 2 unused
- n &lt;varies&gt; data
- p unused, p = Pad(n)
-</literallayout>
-
-<para>
-The auth data is specific to the authentication protocol in use.
-</para>
-<para>
-<!-- .LP -->
-<function>XIM_AUTH_NEXT </function>
-message requests to send more auth data.
-</para>
-
-<literallayout class="monospaced">
-XIM_AUTH_NEXT (IM library &lt;--&gt; IM Server)
- 2 n length of authentication data
- 2 unused
- n &lt;varies&gt; data
- p unused, p = Pad(n)
-</literallayout>
-<para>
-The auth data is specific to the authentication protocol in use.
-</para>
-
-<para>
-<!-- .LP -->
-The IM Server sends
-<function>XIM_AUTH_SETUP</function>
-message to authenticate the client.
-</para>
-
-<literallayout class="monospaced">
-XIM_AUTH_SETUP (IM Server -&gt; IM library)
- 2 CARD16 number of client-auth-protocol-names
- 2 unused
- n LISTofSTRING server-auth-protocol-names
-</literallayout>
-
-<para>
-The list specifies the names of authentication protocols the
-client is willing to perform.
-</para>
-
-<para>
-<function>XIM_AUTH_NG</function>
-message requests to give up the connection.
-</para>
-
-<para>
-XIM_AUTH_NG (IM library &lt;--&gt; IM Server)
-</para>
-
-<para>
-The IM Server sends
-<function>XIM_CONNECT_REPLY</function>
-message as the reply to
-<function>XIM_CONNECT</function>
-or
-<function>XIM_AUTH_REQUIRED</function>
-message.
-</para>
-
-<literallayout class="monospaced">
-XIM_CONNECT_REPLY (IM Server -&gt; IM library)
- 2 CARD16 server-major-protocol-version (*1)
- 2 CARD16 server-minor-protocol-version (*1)
-
-(*1) Specify the version of IM Protocol that the IM Server supports.
-This document specifies major version one, minor version zero.
-</literallayout>
-
-<para>
-Here are the state diagrams for the client and the IM Server.
-</para>
-
-<para>
-State transitions for the client
-</para>
-
-<variablelist>
- <varlistentry>
- <term><emphasis remap='I'>init_status</emphasis>:</term>
- <listitem>
- <para>
-Use authorization function -&gt; <emphasis remap='I'>client_ask</emphasis>
- </para>
- <para>
-Not use authorization function -&gt; <emphasis remap='I'>client_no_check</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>start</emphasis>:</term>
- <listitem>
- <para>
-Send <function>XIM_CONNECT</function>
- </para>
- <para>
-If <emphasis remap='I'>client_ask</emphasis> -&gt; <emphasis remap='I'>client_wait1</emphasis>
- </para>
- <para>
-If <emphasis remap='I'>client_no_check</emphasis>,
-client-auth-protocol-names may be omited -&gt; <emphasis remap='I'>client_wait2</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>client_wait1</emphasis>:</term>
- <listitem>
- <para>
-Receive <function>XIM_AUTH_REQUIRED</function>
--&gt; <emphasis remap='I'>client_check</emphasis>
- </para>
- <para>
-Receive &lt;other&gt; -&gt; <emphasis remap='I'>client_NG</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>client_check</emphasis>:</term>
- <listitem>
- <para>
-If no more auth needed, send <function>XIM_AUTH_REPLY</function>
--&gt; <emphasis remap='I'>client_wait2</emphasis>
- </para>
- <para>
-If good auth data, send <function>XIM_AUTH_NEXT</function>
--&gt; <emphasis remap='I'>client_wait1</emphasis>
- </para>
- <para>
-If bad auth data, send <function>XIM_AUTH_NG</function>
--&gt; give up on this protocol
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>client_wait2</emphasis>:</term>
- <listitem>
- <para>
-Receive <function>XIM_CONNECT_REPLY</function>
--&gt; connect Receive
-<function>XIM_AUTH_SETUP </function>
--&gt; <emphasis remap='I'>client_more</emphasis>
- </para>
- <para>
-Receive <function>XIM_AUTH_NEXT</function>
--&gt; <emphasis remap='I'>client_more</emphasis>
- </para>
- <para>
-Receive <function>XIM_AUTH_NG</function>
--&gt; give up on this protocol
- </para>
- <para>
-Receive &lt;other&gt; -&gt; <emphasis remap='I'>client_NG</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>client_more</emphasis>:</term>
- <listitem>
- <para>
-Send <function>XIM_AUTH_REQUIRED</function>
--&gt; <emphasis remap='I'>client_wait2</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>client_NG</emphasis>:</term>
- <listitem>
- <para>
-Send <function>XIM_AUTH_NG</function>
--&gt; give up on this protocol
- </para>
- </listitem>
- </varlistentry>
-</variablelist>
-
-<para>
-State transitions for the IM Server
-</para>
-
-<variablelist>
- <varlistentry>
- <term><emphasis remap='I'>init_status</emphasis>:</term>
- <listitem>
- <para>
-Use authorization function -&gt; <emphasis remap='I'>server_ask</emphasis>
- </para>
- <para>
-Not use authorization function -&gt; <emphasis remap='I'>server_no_check</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>start</emphasis>:</term>
- <listitem>
- <para>
-Receive <function>XIM_CONNECT</function>
- </para>
- <para>
--&gt; <emphasis remap='I'>start2</emphasis>
-Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>start2</emphasis>:</term>
- <listitem>
- <para>
-If <emphasis remap='I'>client_ask</emphasis>, send
-<function>XIM_AUTH_REQUIRED</function>
--&gt; <emphasis remap='I'>server_wait1</emphasis>
- </para>
- <para>
-If <emphasis remap='I'>client_no_check</emphasis> and
-<emphasis remap='I'>server_ask</emphasis>, send
-<function>XIM_AUTH_SETUP</function>
--&gt; <emphasis remap='I'>server_wait2</emphasis>
- </para>
- <para>
-If <emphasis remap='I'>client_no_check</emphasis> and
-<emphasis remap='I'>server_no_check</emphasis>, send
-<function>XIM_CONNECT_REPLY</function>
--&gt; connect
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server_wait1</emphasis>:</term>
- <listitem>
- <para>
-Receive
-<function>XIM_AUTH_REPLY</function>
--&gt; <emphasis remap='I'>server2</emphasis>
- </para>
- <para>
-Receive
-<function>XIM_AUTH_NEXT</function>
--&gt; <emphasis remap='I'>server_more</emphasis>
- </para>
- <para>
-Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server_more</emphasis></term>
- <listitem>
- <para>
-Send
-<function>XIM_AUTH_REQUIRED</function>
--&gt; <emphasis remap='I'>server_wait1</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server2</emphasis></term>
- <listitem>
- <para>
-If <emphasis remap='I'>server_ask</emphasis>, send
-<function>XIM_AUTH_SETUP</function>
--&gt; <emphasis remap='I'>server_wait2</emphasis>
- </para>
- <para>
-If <emphasis remap='I'>server_no_check</emphasis>, send
-<function>XIM_CONNECT_REPLY </function>
--&gt; connect
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server_wait2</emphasis></term>
- <listitem>
- <para>
-Receive
-<function>XIM_AUTH_REQUIRED</function>
--&gt; <emphasis remap='I'>server_check</emphasis>
- </para>
- <para>
-Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server_check</emphasis></term>
- <listitem>
- <para>
-If no more auth data, send
-<function>XIM_CONNECT_REPLY</function>
--&gt; connect
- </para>
- <para>
-If bad auth data, send
-<function>XIM_AUTH_NG</function>
--&gt; give up on this protocol
- </para>
- <para>
-If good auth data, send
-<function>XIM_AUTH_NEXT</function>
--&gt; <emphasis remap='I'>server_wait2</emphasis>
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><emphasis remap='I'>server_NG</emphasis></term>
- <listitem>
- <para>
-Send
-<function>XIM_AUTH_NG</function>
--&gt; give up on this protocol
- </para>
- </listitem>
- </varlistentry>
-</variablelist>
-
-<para>
-<function>XIM_DISCONNECT </function>
-message requests to shutdown the connection over a mutually-understood
-virtual stream.
-</para>
-
-<para>
-XIM_DISCONNECT (IM library -&gt; IM Server)
-</para>
-
-<para>
-<function>XIM_DISCONNECT</function>
-is a synchronous request. The IM library should wait until it receives
-either an
-<function>XIM_DISCONNECT_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<para>
-XIM_DISCONNECT_REPLY (IM Server -&gt; IM library)
-</para>
-
-<para>
-<function>XIM_OPEN</function>
-requests to establish a logical connection between the IM library and the IM
-Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_OPEN (IM library -&gt; IM Server)
- n STR locale name
- p unused, p = Pad(n)
-</literallayout>
-
-<para>
-<function>XIM_OPEN</function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_OPEN_REPLY</function>
-packet or an <function>XIM_ERROR </function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_OPEN_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 n byte length of IM attributes supported
- n LISTofXIMATTR IM attributes supported
- 2 m byte length of IC attributes supported
- 2 CARD16 unused
- m LISTofXICATTR IC attributes supported
-</literallayout>
-
-<para>
-<function>XIM_OPEN_REPLY</function>
-message returns all supported IM and IC attributes in LISTofXIMATTR and
-LISTofXICATTR. These IM and IC attribute IDs are used to reduce the amount
-of data which must be transferred via the network. In addition, this
-indicates to the IM library what kinds of IM/IC attributes can be used
-in this session, and what types of data will be exchanged. This allows
-the IM Server provider and application writer to support IM system
-enhancements with new IM/IC attributes, without modifying Xlib.
-The IC value for the separator of NestedList must be included in the
-LISTofXICATTR.
-</para>
-
-<para>
-<function>XIM_CLOSE </function>
-message requests to shutdown the logical connection between the IM library
-and the IM Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_CLOSE (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 unused
-</literallayout>
-
-<para>
-<function>XIM_CLOSE</function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_CLOSE_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_CLOSE_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 unused
-</literallayout>
-
-</sect2>
-
-<sect2 id="event_flow_control_2">
-<title>Event Flow Control</title>
-<!-- .XS -->
-<!-- (SN Event Flow Control -->
-<!-- .XE -->
-<para>
-<!-- .LP -->
-An IM Server must send
-<function>XIM_SET_EVENT_MASK </function>
-message to the IM library in order for events to be forwarded to the IM
-Server, since the IM library initially doesn't forward any events to the
-IM Server. In the protocol, the IM Server will specify masks of X events
-to be forwarded and which need to be synchronized by the IM library.
-</para>
-
-<literallayout class="monospaced">
-XIM_SET_EVENT_MASK (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 EVENTMASK forward-event-mask (*1)
- 4 EVENTMASK synchronous-event-mask (*2)
-
-(*1) Specify all the events to be forwarded to the IM Server by the IM library.
-(*2) Specify the events to be forwarded with synchronous flag on by the IM library.
-</literallayout>
-
-<para>
-<function>XIM_SET_EVENT_MASK </function>
-is an asynchronous request. The event masks are valid immediately after
-they are set until changed by another
-<function>XIM_SET_EVENT_MASK</function>
-message. If input-context-ID is set to zero, the default value of the
-input-method-ID will be changed to the event masks specified in the request.
-That value will be used for the IC's which have no individual values.
-</para>
-
-<para>
-Using the Dynamic Event Flow model, an IM Server sends
-<function>XIM_REGISTER_TRIGGERKEYS </function>
-message to the IM library before sending
-<function>XIM_OPEN_REPLY</function>
-message.
-Or the IM library may suppose that the IM Server uses the Static Event Flow
-model.
-</para>
-
-<literallayout class="monospaced">
-XIM_REGISTER_TRIGGERKEYS (IM Server -&gt; IM library)
-<!-- .sp 6p -->
- 2 CARD16 input-method-ID
- 2 unused
- 4 n byte length of on-keys
- n LISTofXIMTRIGGERKEY on-keys list
- 4 m byte length of off-keys
- m LISTofXIMTRIGGERKEY off-keys list
-</literallayout>
-
-<para>
-<function>XIM_REGISTER_TRIGGERKEYS</function>
-is an asynchronous request.
-The IM Server notifys the IM library of on-keys and off-keys lists with
-this message.
-</para>
-
-<para>
-The IM library notifys the IM Server with
-<function>XIM_TRIGGER_NOTIFY </function>
-message that a key event matching either on-keys or off-keys has been occurred.
-</para>
-
-<literallayout class="monospaced">
-XIM_TRIGGER_NOTIFY (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 CARD32 flag
- #0 on-keys list
- #1 off-keys list
- 4 CARD32 index of keys list
- 4 EVENTMASK client-select-event-mask (*1)
-
-(*1) Specify the events currently selected by the IM library with XSelectInput.
-
-</literallayout>
-
-<para>
-<function>XIM_TRIGGER_NOTIFY </function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_TRIGGER_NOTIFY_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_TRIGGER_NOTIFY_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect2>
-
-<sect2 id="Encoding_Negotiation">
-<title>Encoding Negotiation</title>
-<para>
-<function>XIM_ENCODING_NEGOTIATION</function>
-message requests to decide which encoding to be sent across the wire.
-When the negotiation fails, the fallback default encoding is Portable
-Character Encoding.
-</para>
-
-<literallayout class="monospaced">
-XIM_ENCODING_NEGOTIATION (IM library -&gt; IM Server).sp 6p
- 2 CARD16 input-method-ID
- 2 n byte length of encodings listed by name
- n LISTofSTR list of encodings supported in the IM library.
- p unused, p = Pad(n)
- 2 m byte length of encodings listed by detailed data
- 2 unused
- m LISTofENCODINGINFO list of encordings supported in the IM library
-</literallayout>
-
-<para>
-The IM Server must choose one encoding from the list sent by the IM library.
-If index of the encording determined is -1 to indicate that the negotiation
-is failed, the fallback default encoding is used.
-The message must be issued after sending
-<function>XIM_OPEN</function> message via XOpenIM().
-The name of encoding may be registered with X Consortium.
-</para>
-
-<para>
-<function>XIM_ENCODING_NEGOTIATION</function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_ENCODING_NEGOTIATION_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_ENCODING_NEGOTIATION_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 category of the encoding determined.
- #0 name
- #1 detailed data
- 2 INT16 index of the encoding determinated.
- 2 unused
-</literallayout>
-
-</sect2>
-
-<sect2 id="Query_the_supported_extension_protocol_list">
-<title>Query the supported extension protocol list</title>
-<para>
-<function>XIM_QUERY_EXTENSION</function>
-message requests to query the IM extensions supported by the IM Server to
-which the client is being connected.
-</para>
-
-<literallayout class="monospaced">
-XIM_QUERY_EXTENSION (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 n byte length of extensions supported by the IM library
- n LISTofSTR extensions supported by the IM library
- p unused, p = Pad(n)
-</literallayout>
-
-<para>
-An example of a supported extension is FrontEnd.
-The message must be issued after sending
-<function>XIM_OPEN </function> message via XOpenIM().
-</para>
-
-<para>
-If n is 0, the IM library queries the IM Server for all extensions.
-</para>
-
-<para>
-If n is not 0, the IM library queries whether the IM Server supports the
-contents specified in the list.
-</para>
-
-<para>
-If a client uses an extension request without previously having issued a
-<function>XIM_QUERY_EXTENSION</function>
-message for that extension, the IM Server responds with a
-<function>BadProtocol</function>
-error. If the IM Server encounters a request with an unknown MAJOR-OPCODE
-or MINOR-OPCODE, it responds with a
-<function>BadProtocol</function> error.
-</para>
-
-<para>
-<function>XIM_QUERY_EXTENSION</function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_QUERY_EXTENSION_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_QUERY_EXTENSION_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 n byte length of extensions supported by both the IM library and the IM Server
- n LISTofEXT list of extensions supported by both the IM library and the IM Server
-
-</literallayout>
-
-<para>
-<function>XIM_QUERY_EXTENSION_REPLY</function>
-message returns the list of extensions supported by both the IM library and
-the IM Server. If the list passed in
-<function>XIM_QUERY_EXTENSION</function>
-message is NULL, the IM Server returns the full list of extensions supported
-by the IM Server. If the list is not NULL, the IM Server returns the
-extensions in the list that are supported by the IM Server.
-</para>
-
-<para>
-<!-- .LP -->
-A zero-length string is not a valid extension name. The IM library should
-disregard any zero-length strings that are returned in the extension list.
-The IM library does not use the requests which are not supported by the IM
-Server.
-</para>
-
-</sect2>
-
-<sect2 id="Setting_IM_Values">
-<title>Setting IM Values</title>
-<para>
-<function>XIM_SET_IM_VALUES </function>
-requests to set attributes to the IM.
-</para>
-
-<literallayout class="monospaced">
-XIM_SET_IM_VALUES (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 n byte length of im-attribute
- n LISTofXIMATTRIBUTE im-attributes
-</literallayout>
-
-<para>
-The im-attributes in
-<function>XIM_SET_IM_VALUES</function>
-message are specified as a LISTofXIMATTRIBUTE, specifying the attributes
-to be set. Attributes other than the ones returned by
-<function>XIM_OPEN_REPLY</function>
-message should not be specified.
-</para>
-
-<para>
-<function>XIM_SET_IM_VALUES </function>
-is a synchronous request. The IM library should wait until receiving
-either an
-<function>XIM_SET_IM_VALUES_REPLY</function>
-packet or an
-<function>XIM_ERROR</function>
-packet, because it must receive the error attribute if
-<function>XIM_ERROR</function> message is returned.
-</para>
-
-<literallayout class="monospaced">
-XIM_SET_IM_VALUES_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 unused
-</literallayout>
-
-<para>
-<function>XIM_SET_IM_VALUES_REPLY</function>
-message returns the input-method-ID to distinguish replies from multiple IMs.
-</para>
-
-</sect2>
-<sect2 id="Getting_IM_Values">
-<title>Getting IM Values</title>
-<para>
-<function>XIM_GET_IM_VALUES </function>
-requests to query IM values supported by the IM Server currently being
-connected.
-</para>
-
-<literallayout class="monospaced">
-XIM_GET_IM_VALUES (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 n byte length of im-attribute-id
- n LISTofCARD16 im-attribute-id
- p unused, p=Pad(n)
-</literallayout>
-
-<para>
-<function>XIM_GET_IM_VALUES</function>
-is a synchronous request. The IM library should wait until it receives
-either an
-<function>XIM_GET_IM_VALUES_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_GET_IM_VALUES_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 n byte length of im-attributes returned
- n LISTofXIMATTRIBUTE im-attributes returned
-</literallayout>
-
-<para>
-The IM Server returns IM values with
-<function>XIM_GET_IM_VALUES_REPLY</function>
-message. The order of the returned im-attribute values corresponds directly
-to that of the list passed with the
-<function>XIM_GET_IM_VALUES</function> message.
-</para>
-
-</sect2>
-<sect2 id="Creating_an_IC">
-<title>Creating an IC</title>
-<para>
-<function>XIM_CREATE_IC</function> message requests to create an IC.
-</para>
-
-<literallayout class="monospaced">
-XIM_CREATE_IC (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 n byte length of ic-attributes
- n LISTofXICATTRIBUTE ic-attributes
-</literallayout>
-
-<para>
-The input-context-id is specified by the IM Server to identify the client
-(IC). (It is not specified by the client in
-<function>XIM_CREATE_IC</function>
-message.), and it should not be set to zero.
-</para>
-
-<para>
-<function>XIM_CREATE_IC</function>
-is a synchronous request which returns the input-context-ID.
-The IM library should wait until it receives either an
-<function>XIM_CREATE_IC_REPLY</function>
-packet or an
-<function>XIM_ERROR</function>
-packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_CREATE_IC_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect2>
-<sect2 id="Destroying_the_IC">
-<title>Destroying the IC</title>
-<para>
-<function>XIM_DESTROY_IC</function>
-message requests to destroy the IC.
-</para>
-
-<literallayout class="monospaced">
-XIM_DESTROY_IC (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-<function>XIM_DESTROY_IC </function>
-is a synchronous request. The IM library should not free its resources
-until it receives an
-<function>XIM_DESTROY_IC_REPLY</function>
-message because <function>XIM_DESTROY_IC</function>
-message may result in Callback packets such as
-<function>XIM_PREEDIT_DRAW</function>
-and <function>XIM_PREEDIT_DONE.</function>
-</para>
-
-<literallayout class="monospaced">
-XIM_DESTROY_IC_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect2>
-
-<sect2 id="Setting_IC_Values">
-<title>Setting IC Values</title>
-<para>
-<function>XIM_SET_IC_VALUES</function>
-messages requests to set attributes to the IC.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_SET_IC_VALUES (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 n byte length of ic-attributes
- 2 unused
- n LISTofXICATTRIBUTE ic-attributes
-</literallayout>
-
-<para>
-The ic-attributes in
-<function>XIM_SET_IC_VALUES</function>
-message are specified as a LISTofXICATTRIBUTE, specifying the attributes
-to be set. Attributes other than the ones returned by
-<function>XIM_OPEN_REPLY</function> message should not be specified.
-</para>
-
-<para>
-<function>XIM_SET_IC_VALUES </function>
-is a synchronous request. The IM library should wait until receiving
-either an <function>XIM_SET_IC_VALUES_REPLY </function>
-packet or an <function>XIM_ERROR</function>
-packet, because it must receive the error attribute if
-<function>XIM_ERROR</function> message is returned.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_SET_IC_VALUES_REPLY (IM Server -&gt; IM library)
-<!-- .sp 6p -->
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect2>
-<sect2 id="Getting_IC_Values">
-<title>Getting IC Values</title>
-<para>
-<function>XIM_GET_IC_VALUES</function>
-message requests to query IC values supported by the IM Server currently
-being connected.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_GET_IC_VALUES (IM library -&gt; IM Server)
-<!-- .sp 6p -->
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 n byte length of ic-attribute-id
- n LISTofCARD16 ic-attribute-id
- p unused, p=Pad(2+n)
-</literallayout>
-
-<para>
-In LISTofCARD16, the appearance of the ic-attribute-id for the separator
-of NestedList shows the end of the heading nested list.
-</para>
-
-<para>
-<function>XIM_GET_IC_VALUES</function>
-is a synchronous request and returns each attribute with its values to
-show the correspondence. The IM library should wait until receiving
-either an <function>XIM_GET_IC_VALUES_REPLY</function>
-packet or an <function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_GET_IC_VALUES_REPLY (IM Server -&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 n byte length of ic-attribute
- 2 unused
- n LISTofXICATTRIBUTE ic-attribute
-</literallayout>
-
-</sect2>
-<sect2 id="Setting_IC_Focus">
-<title>Setting IC Focus</title>
-<para>
-<function>XIM_SET_IC_FOCUS</function>
-message requests to set the focus to the IC.
-</para>
-
-<literallayout class="monospaced">
-XIM_SET_IC_FOCUS (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-<function>XIM_SET_IC_FOCUS</function> is an asynchronous request.
-</para>
-
-</sect2>
-<sect2 id="Unsetting_IC_Focus">
-<title>Unsetting IC Focus</title>
-<para>
-<function>XIM_UNSET_IC_FOCUS</function>
-message requests to unset the focus to the focused IC.
-</para>
-
-<literallayout class="monospaced">
-XIM_UNSET_IC_FOCUS (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-<function>XIM_UNSET_IC_FOCUS</function>
-is an asynchronous request.
-</para>
-
-</sect2>
-
-<sect2 id="filtering_events">
-<title>Filtering Events</title>
-<para>
-Event filtering is mainly provided for BackEnd method to allow input method
-to capture X events transparently to clients.
-</para>
-
-<para>
-X Events are forwarded by
-<function>XIM_FORWARD_EVENT</function> message.
-This message can be operated both synchronously and asynchronously.
-If the requester sets the synchronous flag, the receiver must send
-<function>XIM_SYNC_REPLY</function>
-message back to the requester when all the data processing is done.
-</para>
-<para>
-Protocol flow of BackEnd model
-</para>
-
-<para>
-With BackEnd method, the protocol flow can be classified into two
-methods in terms of synchronization, depending on the synchronous-eventmask
-of <function>XIM_SET_EVENT_MASK</function>
-message. One can be called on-demand-synchronous method and another
-can be called as full-synchronous method.
-</para>
-
-<para>
-In on-demand-synchronous method, the IM library always receives
-<function>XIM_FORWARD_EVENT</function>
-or
-<function>XIM_COMMIT</function>
-message as a synchronous request. Also, the IM Server needs to synchronously
-process the correspondent reply from the IM library and the following
-<function>XIM_FORWARD_EVENT</function>
-message sent from the IM library when any of the event causes the IM Server
-to send
-<function>XIM_FORWARD_EVENT</function>
-or
-<function>XIM_COMMIT</function>
-message to the IM library, so that the input service is consistent. If the
-IM library gets the control back from the application after receiving the
-synchronous request, the IM library replies for the synchronous request before
-processing any of the events. In this time, the IM Server blocks
-<function>XIM_FORWARD_EVENT</function>
-message which is sent by the IM library, and handles it after receiving the
-reply. However, the IM Server handles the other protocols at any time.
-</para>
-
-<para>
-In full-synchronous method, the IM library always sends
-<function>XIM_FORWARD_EVENT</function>
-message to the IM Server as a synchronous request. Therefore, the reply to it
-from the IM Server will be put between the
-<function>XIM_FORWARD_EVENT</function> message and its
-<function>XIM_SYNC_REPLY</function> message. In case of sending
-<function>XIM_FORWARD_EVENT</function> or
-<function>XIM_COMMIT</function>
-message, the IM Server should set the synchronous flag off. Because the
-synchronization can be done by the following
-<function>XIM_SYNC_REPLY</function> message.
-</para>
-
-<para>
-Following chart shows one of the simplest protocol flow which only
-deals with keyevents for preediting operation.
-</para>
-
-<mediaobject id="sampleprotocolflow">
- <imageobject>
- <imagedata format="SVG" fileref="sampleprotocolflow1.svg"/>
- </imageobject>
- <caption>Sample Protocol Flow</caption>
-</mediaobject>
-
-
-<para>
-Following chart shows one of the complex protocol flow, which deals
-with multiple focus windows and button press event as well as keyevent,
-and the focus is moved by the application triggered by both of keyevent
-and button press event.
-</para>
-<mediaobject id="sampleprotocolflow2">
- <imageobject>
- <imagedata format="SVG" fileref="sampleprotocolflow2.svg"/>
- </imageobject>
- <caption>Sample Protocol Flow 2</caption>
-</mediaobject>
-
-<literallayout class="monospaced">
-XIM_FORWARD_EVENT (IM library &lt;--&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 BITMASK16 flag
- #0001 synchronous
- #0002 request filtering (*1)
- #0004 request lookupstring (*2)
- 2 CARD16 serial number
- XEVENT X event
-
-(*1) Indicate the receiver should filter events and possible preedit may be invoked.
-
-(*2) Indicate the receiver should only do lookup string. The IM Server is expected
-to just do a conversion of the key event to the best candidate. This bit may
-affect the state of the preedit state (e.g. compose of dead key sequences).
-</literallayout>
-
-<para>
-XEVENT format is same as the X Protocol event format(xEvent).
-As the value of xEvent's sequenceNumber is the bottom of 16 bit of XEvent's
-xany.serial, the top of 16 bit is sent by serial number(INT16).
-</para>
-
-<para>
-<function>XIM_FORWARD_EVENT</function>
-message is used for forwarding the events from the IM library to the IM Server
-in order for IM to be able to filter the event. On the other hand, this
-message is also used for forwarding the events from the IM Server to the IM
-library if the event forwarded from the IM library is not filtered.
-The IM Server, which receives
-<function>XIM_FORWARD_EVENT</function>
-message without synchronous bit, should set synchronous bit.
-If both "request event filtering" and "request lookupstring" flag are
-set, then both filtering and lookup should be done for the same event.
-</para>
-
-</sect2>
-
-<sect2 id="Synchronizing_with_the_IM_Server">
-<title>Synchronizing with the IM Server</title>
-
-<para>
-<function>XIM_SYNC</function>
-message requests to synchronize the IM library and the IM Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_SYNC (IM library &lt;--&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-This synchronization can be started either on the IM library side or on the
-IM Server side. The side which receives
-<function>XIM_SYNC</function>
-message should process all XIM requests before replying. The input-context-ID
-is necessary to distinguish the IC with which the IM library and the IM
-Server are synchronized.
-</para>
-
-<literallayout class="monospaced">
-XIM_SYNC_REPLY (IM Server &lt;--&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-
-
-<para>
-The side which receives
-<function>XIM_FORWARD_EVENT, </function>
-<function>XIM_COMMIT</function>
-or any other message with synchronous bit, should process all XIM request
-before replying, and send
-<function>XIM_SYNC_REPLY</function>
-message as the reply to the previous message.
-</para>
-
-</sect2>
-
-<sect2 id="Sending_a_committed_string">
-<title>Sending a committed string</title>
-<para>
-When the IM Server commits a string, the IM Server sends either the committed
-string or list of KeySym, or both, by
-<function>XIM_COMMIT</function>
-message.
-</para>
-
-<literallayout class="monospaced">
-XIM_COMMIT (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 BITMASK16 flag
- #0001 synchronous
- #0002 XLookupChars
- #0004 XLookupKeySym
- #0006 XLookupBoth = XLookupChars | XLookupKeySym
-</literallayout>
-
-<para>
-If flag is XLookupKeySym, the arguments continue as follows:
-</para>
-
-<literallayout class="monospaced">
- 2 unused
- 4 KEYSYM KeySym
-</literallayout>
-
-<para>
-If flag is XLookupChars, the arguments continue as follows
-</para>
-
-<literallayout class="monospaced">
- 2 m byte length of committed string
- m LISTofBYTE committed string
- p unused, p = Pad(m)
-</literallayout>
-
-<para>
-If flag is XLookupBoth, the arguments continue as follows
-</para>
-
-<literallayout class="monospaced">
- 2 unused
- 4 KEYSYM KeySym
- 2 n byte length of committed string
- n LISTofBYTE committed string
- p unused, p = Pad(2+n)
-</literallayout>
-
-<para>
-The IM Server which receives
-<function>XIM_COMMIT</function>
-message without synchronous bit should set synchronous bit.
-</para>
-
-</sect2>
-
-<sect2 id="Reset_IC">
-<title>Reset IC</title>
-<para>
-<function>XIM_RESET_IC</function>
-message requests to reset the status of IC in the IM Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_RESET_IC (IM library -&gt; IM Server)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-
-<para>
-<function>XIM_RESET_IC</function>
-is a synchronous request. The IM library should wait until receiving either an
-<function>XIM_RESET_IC_REPLY</function> packet or an
-<function>XIM_ERROR</function> packet.
-</para>
-
-<literallayout class="monospaced">
-XIM_RESET_IC_REPLY (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 n byte length of preedit string
- n LISTofBYTE preedit string
- p unused, p = Pad(2+n)
-</literallayout>
-
-<para>
-<function>XIM_RESET_IC_REPLY </function>
-message returns the input-context-ID to distinguish replies from multiple ICs.
-</para>
-
-</sect2>
-<sect2 id="Callbacks">
-<title>Callbacks</title>
-<para>
-If XIMStyle has XIMPreeditArea or XIMStatusArea set, XIMGeometryCallback
-may be used, and if XIMPreeditCallback and/or XIMStatusCallback are set,
-corresponding callbacks may be used.
-</para>
-
-<para>
-Any callback request may be sent from an IM Server to an IM client
-asynchronously in response to any request previously sent by the IM client
-to the IM Server.
-</para>
-
-<para>
-When an IM Server needs to send a callback request synchronously with
-the request previously sent by an IM client, the IM Server sends it
-before replying to the previous request.
-</para>
-
-<sect3 id="Negotiating_geometry">
-<title>Negotiating geometry</title>
-<para>
-The IM Server sends
-<function>XIM_GEOMETRY </function>
-message to start geometry negotiation, if XIMStyle has XIMPreeditArea or
-XIMStatusArea set.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_GEOMETRY (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-There is always a single Focus Window, even if some input fields have only
-one IC.
-</para>
-
-</sect3>
-
-<sect3 id="Converting_a_string">
-<title>Converting a string</title>
-
-<literallayout class="monospaced">
-XIM_STR_CONVERSION (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 CARD16 XIMStringConversionPosition
- 2 unused
- 4 CARD32 XIMCaretDirection
- #0 XIMForwardChar
- #1 XIMBackwardChar
- #2 XIMForwardWord
- #3 XIMBackwardWord
- #4 XIMCaretUp
- #5 XIMCaretDown
- #6 XIMNextLine
- #7 XIMCPreviousLine
- #8 XIMLineStart
- #9 XIMLineEnd
- #10 XIMAbsolutePosition
- #11 XIMDontChange
- 2 CARD16 factor
- 2 CARD16 XIMStringConversionOperation
- #0001 XIMStringConversionSubstitution
- #0002 XIMStringConversionRetrieval
- 2 INT16 byte length to multiply the XIMStringConversionType
-</literallayout>
-
-<para>
-<function>XIM_STR_CONVERSION </function>
-message may be used to start the string conversion from the IM Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_STR_CONVERSION_REPLY (IM library -&gt; IM Server)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 CARD32 XIMStringConversionFeedback
- XIMSTRCONVTEXT XIMStringConversionText
-</literallayout>
-
-<para>
-<function>XIM_STR_CONVERSION_REPLY </function>
-message returns the string to be converted and the feedback information array.
-</para>
-</sect3>
-
-<sect3 id="Preedit_Callbacks">
-<title>Preedit Callbacks</title>
-
-<para>
-The IM Server sends
-<function>XIM_PREEDIT_START </function>
-message to call the XIMPreeditStartCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_START (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-The reply to this message must be sent synchronously. The reply forwards
-the return value from the callback function to the IM Server.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_START_REPLY (IM library -&gt; IM Server)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 INT32 return value
-</literallayout>
-
-<para>
-<function>XIM_PREEDIT_START_REPLY</function>
-message returns the input-context-ID to distinguish replies from multiple
-IC's. The return value contains the return value of the function
-XIMPreeditStartCallback.
-</para>
-
-<para>
-The IM Server sends
-<function>XIM_PREEDIT_DRAW </function>
-message to call the XIMPreeditDrawCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_DRAW (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 INT32 caret
- 4 INT32 chg_first
- 4 INT32 chg_length
- 4 BITMASK32 status
- #x0000001 no string
- #x0000002 no feedback
- 2 n length of preedit string
- n STRING8 preedit string
- p unused, p = Pad(2+n)
- 2 m byte length of feedback array
- 2 unused
- m LISTofXIMFEEDBACK feedback array
-</literallayout>
-
-<para>
-The fields "caret", "chg_first" and "chg_length" correspond to the
-fields of XIMPreeditDrawCallbackStruct.
-When the "no string" bit of the status field is set, the text field of
-XIMPreeditDrawCallbackStruct is NULL.
-When the "no feedback" bit of the status field is set, the text feedback
-field of XIMPreeditDrawCallbackStruct is NULL.
-When the above bits are not set, "preedit string" contains the preedit
-string to be displayed, and the feedback array contains feedback information.
-</para>
-
-<para>
-The IM Server sends
-<function>XIM_PREEDIT_CARET</function>
-message to call the PreeditCaretCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_CARET (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 INT32 position
- 4 CARD32 direction
- #0 XIMForwardChar
- #1 XIMBackwardChar
- #2 XIMForwardWord
- #3 XIMBackwardWord
- #4 XIMCaretUp
- #5 XIMCaretDown
- #6 XIMNextLine
- #7 XIMCPreviousLine
- #8 XIMLineStart
- #9 XIMLineEnd
- #10 XIMAbsolutePosition
- #11 XIMDontChange
- 4 CARD32 style
- #0 XIMInvisible
- #1 XIMCPrimary
- #2 XIMSecondary
-</literallayout>
-
-<para>
-Each entry corresponds to a field of XIMPreeditCaretCallbackStruct.
-Since this callback sets the caret position, its reply must be sent
-synchronously.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_CARET_REPLY (IM library -&gt; IM Server)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 CARD32 position
-</literallayout>
-
-<para>
-The position is the value returned by the callback function after it
-has been called.
-</para>
-
-<para>
-The IM Server sends
-<function>XIM_PREEDIT_DONE </function>
-message to call the XIMPreeditDoneCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_PREEDIT_DONE (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect3>
-
-<sect3 id="Preedit_state_notify">
-<title>Preedit state notify</title>
-
-<literallayout class="monospaced">
-XIM_PREEDITSTATE (IM Server -&gt; IM Library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 BITMASK32 XIMPreeditState
- #x0000000 XIMPreeditUnknown
- #x0000001 XIMPreeditEnable
- #x0000002 XIMPreeditDisable
-</literallayout>
-
-<para>
-<function>XIM_PREEDITSTATE</function>
-message is used to call the XIMPreeditStateNotifyCallback function.
-</para>
-
-</sect3>
-
-<sect3 id="Status_Callbacks">
-<title>Status Callbacks</title>
-
-<para>
-The IM Server sends
-<function>XIM_STATUS_START </function>
-message to call the XIMStatusStartCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_STATUS_START (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-<para>
-The IM Server sends
-<function>XIM_STATUS_DRAW </function>
-message to call the XIMStatusDrawCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_STATUS_DRAW (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 CARD32 type
- #0 XIMTextType
- #1 XIMBitmapType
-</literallayout>
-
-<para>
-If type is XIMTextType, the arguments continue as follows.
-</para>
-
-<literallayout class="monospaced">
- 4 BITMASK32 status
- #x0000001 no string
- #x0000002 no feedback
- 2 n length of status string
- n STRING8 status string
- p unused, p = Pad(2+n)
- 2 m byte length of feedback array
- 2 unused
- m LISTofXIMFEEDBACK feedback array
-</literallayout>
-
-<para>
-If type is XIMBitmapType, the arguments continue as follows.
-</para>
-
-<literallayout class="monospaced">
- 4 PIXMAP pixmap data
-</literallayout>
-
-<para>
-The field "type" corresponds to the field in XIMStatusDrawCallbackStruct.
-</para>
-
-<para>
-The IM Server sends
-<function>XIM_STATUS_DONE </function>
-message to call the XIMStatusDoneCallback function.
-</para>
-
-<literallayout class="monospaced">
-XIM_STATUS_DONE (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
-</literallayout>
-
-</sect3>
-</sect2>
-</sect1>
-
-<sect1 id="Acknowledgements">
-<title>Acknowledgements</title>
-<para>
-This document represents the culmination of several years of debate and
-experiments done under the auspices of the MIT X Consortium i18n working
-group. Although this was a group effort, the author remains responsible
-for any errors or omissions.
-</para>
-
-<para>
-We would like to thank to all members of this group.
-And we would like to make special thanks to the following people
-(in alphabetical order) for their participation in the IM Protocol
-design,
-Hector Chan, Takashi Fujiwara, Yoshio Horiuchi, Makoto Inada,
-Hiromu Inukai, Mickael Kung, Seiji Kuwari, Franky Ling, Hiroyuki Machida,
-Hiroyuki Miyamoto, Frank Rojas, Bob Scheifler, Makiko Shimamura,
-Shoji Sugiyama, Hidetoshi Tajima, Masaki Takeuchi, Makoto Wakamatsu,
-Masaki Wakao, Nobuyuki Tanaka, Shigeru Yamada, Katsuhisa Yano, Jinsoo Yoon.
-</para>
-
-</sect1>
-
-<bibliography>
-<title>References</title>
-<biblioentry>
- <title>X Window System Protocol Version 11</title>
- <author><firstname>Robert W.</firstname><surname>Scheifler</surname></author>
-</biblioentry>
-
-<biblioentry>
- <title>Xlib - C Language X Interface"</title>
- <author><firstname>Robert W.</firstname><surname>Scheifler</surname></author>
-</biblioentry>
-</bibliography>
-
-<appendix id="common_extensions">
-<title>Common Extensions</title>
-<para>
-Extension opcodes and packet names (e.g.
-<function>XIM_EXT_SET_EVENT_MASK</function>
-) for additional extensions may be registered with X Consortium.
-The following is a commonly well-known extended packet.
-</para>
-
-<para>
-(1) Extension to manipulate the event handling\fP
-</para>
-
-<para>
-<!-- .LP -->
-<function>XIM_EXT_SET_EVENT_MASK </function>
-message specifies the set of event masks that the IM library should manipulate.
-</para>
-
-<literallayout class="monospaced">
-XIM_EXT_SET_EVENT_MASK (IM Server -&gt; IM library)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 4 EVENTMASK filter-event-mask (*1)
- 4 EVENTMASK intercept-event-mask (*2)
- 4 EVENTMASK select-event-mask (*3)
- 4 EVENTMASK forward-event-mask (*4)
- 4 EVENTMASK synchronous-event-mask (*5)
-
- (*1) Specify the events to be neglected by the IM library via XFilterEvent.
- (*2) Specify the events to be deselected by the IM library with XSelectInput.
- (*3) Specify the events to be selected by the IM library with XSelectInput.
- (*4) Specify all the events to be forwarded to the IM Server by the IM library.
- (*5) Specify the events to be forwarded with synchronous flag on by the IM library.
-</literallayout>
-
-<para>
-<!-- .LP -->
-The IM library must reply
-<function>XIM_SYNC_REPLY</function>
-message to the IM Server. This request is valid after the ic is created.
-</para>
-
-<para>
-(2) Extension for improvement of performance.
-</para>
-<para>
-The following requests may be used for improvement of performance.
-</para>
-
-<para>
-<function>XIM_EXT_FORWARD_KEYEVENT</function>
-message may be used instead of
-<function>XIM_FORWARD_EVENT</function>
-message.
-</para>
-
-<literallayout class="monospaced">
-XIM_EXT_FORWARD_KEYEVENT (IM Server &lt;--&gt; IM library)
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 BITMASK16 flag
- #0001 synchronous
- 2 CARD16 sequence number
- 1 BYTE xEvent.u.u.type
- 1 BYTE keycode
- 2 CARD16 state
- 4 CARD32 time
- 4 CARD32 window
-</literallayout>
-
-<para>
-<function>XIM_EXT_MOVE</function>
-message may be used to change the spot location instead of
-<function></function>
-XIM_SET_IC_VALUES
-message.
-It is effective only if the client specified XIMPreeditPosition.
-</para>
-
-
-<literallayout class="monospaced">
-XIM_EXT_MOVE (IM library -&gt; IM Server)
-
- 2 CARD16 input-method-ID
- 2 CARD16 input-context-ID
- 2 INT16 X
- 2 INT16 Y
-</literallayout>
-
-<para>
-<function>XIM_EXT_MOVE</function>
-message is a asynchronous request.
-</para>
-
-</appendix>
-<appendix id="transport_list">
-<title>Transport List</title>
-
-<para>
-The list of transport specific IM Server address format registered
-</para>
-
-<para>
-The following format represents the ATOM contained in
-<function>XIM_SERVERS</function>
-property and the string returned from the request converting
-selection target LOCALES and TRANSPORT.
-</para>
-<literallayout class="monospaced">
- "{<emphasis remap='I'>category</emphasis>=[<emphasis remap='I'>value</emphasis>,...]}..."
-</literallayout>
-<para>
-The following categories are currently registered.
-</para>
-
-<literallayout class="monospaced">
-<function>server</function>;: IM Server name (used for XIM_SERVERS)
-<function>locale</function>;: XPG4 locale name (LOCALES)
-<function>transport</function>;: transport-specific name (TRANSPORT)
-</literallayout>
-
-<para>
-The preregistered formats for transport-specific names are as follows:
-</para>
-
-<para>
-<function>TCP/IP Names</function>
-</para>
-
-<para>
-The following syntax should be used for system internal domain names:
-</para>
-<literallayout class="monospaced">
-&lt;<emphasis remap='I'>local name</emphasis>&gt; ::= "local/"&lt;<emphasis remap='I'>hostname</emphasis>&gt;":"&lt;<emphasis remap='I'>pathname</emphasis>&gt;
-</literallayout>
-<para>
-Where &lt;<emphasis remap='I'>pathname</emphasis>&gt; is a path name of socket address.
-</para>
-
-<para>
-IM Server's name should be set to &lt;<emphasis remap='I'>pathname</emphasis>&gt; to run multiple IM Server
-at the same time
-</para>
-
-<para>
-The following syntax should be used for Internet domain names:
-</para>
-<literallayout class="monospaced">
-&lt;<emphasis remap='I'>TCP name</emphasis>&gt; ::= "tcp/"&lt;<emphasis remap='I'>hostname</emphasis>&gt;":"&lt;<emphasis remap='I'>ipportnumber</emphasis>&gt;
-</literallayout>
-<para>
-where &lt;<emphasis remap='I'>hostname</emphasis>&gt; is either symbolic (such as expo.lcs.mit.edu) or
-numeric decimal (such as 18.30.0.212). The &lt;<emphasis remap='I'>ipportnumber</emphasis>&gt; is the
-port on which the IM Server is listening for connections.
-For example:
-</para>
-<literallayout class="monospaced">
-tcp/expo.lcs.mit.edu:8012
-tcp/18.30.0.212:7890
-</literallayout>
-
-<para>
-<function>DECnet Names</function>
-</para>
-
-<para>
-The following syntax should be used for DECnet names:
-</para>
-<literallayout class="monospaced">
-&lt;<emphasis remap='I'>DECnet name</emphasis>&gt; ::= "decnet/"&lt;<emphasis remap='I'>nodename</emphasis>&gt;"::IMSERVER$"&lt;<emphasis remap='I'>objname</emphasis>&gt;
-</literallayout>
-<para>
-where &lt;<emphasis remap='I'>nodename</emphasis>&gt; is either
-symbolic (such as SRVNOD) or the numeric
-decimal form of the DECnet address (such as 44.70).
-The &lt;<emphasis remap='I'>objname</emphasis>&gt;
-is normal, case-insensitive DECnet object name. For example:
-</para>
-
-<literallayout class="monospaced">
-DECNET/SRVNOD::IMSERVER$DEFAULT
-decnet/44.70::IMSERVER$other
-</literallayout>
-
-<para>
-<function>X Names</function>
-</para>
-
-<para>
-The following syntax should be used for X names:
-</para>
-<literallayout class="monospaced">
-&lt;<emphasis remap='I'>X name</emphasis>&gt; ::= "X/"
-</literallayout>
-
-<para>
-If a given category has multiple values, the value is evaluated in order of
-setting.
-</para>
-
-</appendix>
-<appendix id="protocol_number">
-<title>Protocol Number</title>
-
-<para>
-<function>Major Protocol number</function>
-</para>
-
-<literallayout class="monospaced">
-XIM_CONNECT #001
-XIM_CONNECT_REPLY #002
-XIM_DISCONNECT #003
-XIM_DISCONNECT_REPLY #004
-
-XIM_AUTH_REQUIRED #010
-XIM_AUTH_REPLY #011
-XIM_AUTH_NEXT #012
-XIM_AUTH_SETUP #013
-XIM_AUTH_NG #014
-
-XIM_ERROR #020
-
-XIM_OPEN #030
-XIM_OPEN_REPLY #031
-XIM_CLOSE #032
-XIM_CLOSE_REPLY #033
-XIM_REGISTER_TRIGGERKEYS #034
-XIM_TRIGGER_NOTIFY #035
-XIM_TRIGGER_NOTIFY_REPLY #036
-XIM_SET_EVENT_MASK #037
-XIM_ENCODING_NEGOTIATION #038
-XIM_ENCODING_NEGOTIATION_REPLY #039
-XIM_QUERY_EXTENSION #040
-XIM_QUERY_EXTENSION_REPLY #041
-XIM_SET_IM_VALUES #042
-XIM_SET_IM_VALUES_REPLY #043
-XIM_GET_IM_VALUES #044
-XIM_GET_IM_VALUES_REPLY #045
-
-XIM_CREATE_IC #050
-XIM_CREATE_IC_REPLY #051
-XIM_DESTROY_IC #052
-XIM_DESTROY_IC_REPLY #053
-XIM_SET_IC_VALUES #054
-XIM_SET_IC_VALUES_REPLY #055
-XIM_GET_IC_VALUES #056
-XIM_GET_IC_VALUES_REPLY #057
-XIM_SET_IC_FOCUS #058
-XIM_UNSET_IC_FOCUS #059
-XIM_FORWARD_EVENT #060
-XIM_SYNC #061
-XIM_SYNC_REPLY #062
-XIM_COMMIT #063
-XIM_RESET_IC #064
-XIM_RESET_IC_REPLY #065
-
-XIM_GEOMETRY #070
-XIM_STR_CONVERSION #071
-XIM_STR_CONVERSION_REPLY #072
-XIM_PREEDIT_START #073
-XIM_PREEDIT_START_REPLY #074
-XIM_PREEDIT_DRAW #075
-XIM_PREEDIT_CARET #076
-XIM_PREEDIT_CARET_REPLY #077
-XIM_PREEDIT_DONE #078
-XIM_STATUS_START #079
-XIM_STATUS_DRAW #080
-XIM_STATUS_DONE #081
-XIM_PREEDITSTATE #082
-
-(*) The IM Server's extension protocol number should be more than #128.
-</literallayout>
-</appendix>
-
-<appendix id="implementation_tips">
-
-<title>Implementation Tips</title>
-<para>
-(1) FrontEnd Method
-</para>
-
-<para>
-FrontEnd method is recognized as a performance acceleration by the
-trade off of the variety of the reliability.
-</para>
-
-<para>
-In order to use the FrontEnd method, the IM library must query the IM
-Server to see if the FrontEnd extension is available. The query is
-made by using the
-<function>XIM_QUERY_EXTENSION</function>
-message. The IM Server may send
-<function>XIM_EXT_SET_EVENT_MASK</function>
-message with intercept-event-mask, forward-event-mask, and
-synchronous-event-mask values set after replying
-<function>XIM_QUERY_EXTENSION_REPLY</function>
-message.
-</para>
-
-<para>
-FrontEnd method can be implemented in a couple of ways depending on
-how the IM Server utilize
-<function>XIM_EXT_SET_EVENT_MASK</function>
-message.
-</para>
-
-<para>
-One approach is to update both of the input mask and the filter-event-mask
-depending on the preeidting state. The sample protocol sequence using the
-static event flow is as follows:
-</para>
-
-<mediaobject id="staticflow">
- <imageobject>
- <imagedata scale="75" format="SVG" fileref="staticflow.svg"/>
- </imageobject>
- <caption>The flow of events</caption>
-</mediaobject>
-
-<para>
-To pursuit a maximum performance regardless of the preediting mode,
-the IM Server may use the dynamic event flow with the following
-sample protocol sequence.
-</para>
-
-<mediaobject id="dynamicflow">
- <imageobject>
- <imagedata scale="75" format="SVG" fileref="dynamicflow.svg"/>
- </imageobject>
- <caption>The flow of events</caption>
-</mediaobject>
-
-<para>
-This method can reduce the XIM protocol traffic dramatically
-by updating intercept-event-mask and select-event-mask accordingly.
-The tradeoff of this performance improvement is that the key
-events may be lost or disordered in some particular situation, such as
-when the user types the keyboard in following sequence really fast:
-</para>
-
-<para>
-&lt;preediting on key&gt;"some strings"&lt;preediting off
-key&gt;"another string"
-</para>
-
-<para>
-Since this method requires the input mask updates to the both the IM Server
-and Xlib when turning on and off the preediting, and there is a time lag
-till the requests take effect when two client issues the input mask updates
-simultaneously.
-</para>
-
-<para>
-Another approach of the FrontEnd method is to update the filter-event-mask
-depending on the preediting state and not to update the input mask.
-The IM Server must register both of the preediting on key list and off key
-list by
-<function>XIM_REGISTER_TRIGGERKEYS</function>
-message.
-In this method, Both the IM Server and the IM client select the same
-events on the same client's window, so that the events are delivered
-to both of the IM Server and the client. The preediting on and off
-states are expressed by whether the key events are filtered or not.
-The sample protocol sequence are as follows:
-</para>
-
-<para>
-&lt;&lt;Using static event flow&gt;&gt;
-</para>
-
-<mediaobject id="staticflowsampleseq">
- <imageobject>
- <imagedata scale="75" format="SVG" fileref="staticflowsampleseq.svg"/>
- </imageobject>
- <caption>The flow of events</caption>
-</mediaobject>
-
-<para>
-&lt;&lt;Using the dynamic event flow&gt;&gt;
-</para>
-
-<mediaobject id="dynamicflowsampleseq">
- <imageobject>
- <imagedata scale="75" format="SVG" fileref="dynamicflowsampleseq.svg"/>
- </imageobject>
- <caption>The flow of events</caption>
-</mediaobject>
-
-<para>
-This method does not have the problem of the time lag when going across
-the preediting on and off mode, however, the amount of the performance
-acceleration is not as good as the method described above.
-</para>
-
-<para>
-In general, the FrontEnd method requires some synchronization to some
-of the X protocols, such as the ChangeWindowAttribute protocol for the
-event mask change or the GrabKey protocol, since it relies on the X's
-principal event dispatching mechanism. Any X protocol bindings do not
-consider the synchronization might cause some mis-synchronization
-between the IM clients and the IM Server.
-</para>
-
-<para>
-(2) Transport Layer
-</para>
-
-<para>
-The Xlib XIM implementation is layered into three functions, a protocol
-layer, an interface layer and a transport layer. The purpose of this
-layering is to make the protocol independent of transport implementation.
-Each function of these layers are:
-</para>
-
-<variablelist>
- <varlistentry>
- <term>The protocol layer</term>
- <listitem>
- <para>
-implements overall function of XIM and calls the interface layer
-functions when it needs to communicate to IM Server.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>The interface layer</term>
- <listitem>
- <para>
-separates the implementation of the transport layer from the protocol
-layer, in other words, it provides implementation independent hook for
-the transport layer functions.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>The transport layer</term>
- <listitem>
- <para>
-handles actual data communication with IM Server. It is done by a set
-of several functions named transporters.
- </para>
- </listitem>
- </varlistentry>
-</variablelist>
-
-<para>
-The interface layer and the transport layer make various communication
-channels usable such as X Protocol, TCP/IP, DECnet or STREAM.
-The following is a sample implementation for the transporter using
-the X connection.
-Refer to "xtrans" for the transporter using Socket Transport. <!-- xref ?-->
-</para>
-
-<para>
-At the beginning of the X Transport connection for the XIM transport
-mechanism, two different windows must be created either in an Xlib XIM
-or in an IM Server, with which the Xlib and the IM Server exchange the
-XIM transports by using the ClientMessage events and Window Properties.
-In the following, the window created by the Xlib is referred as the
-"client communication window", and on the other hand, the window created
-by the IM Server is referred as the "IMS communication window".
-</para>
-
-<para>
-Connection
-</para>
-
-<para>
-In order to establish a connection, a communication window is created.
-A ClientMessage in the following event's format is sent to the owner
-window of XIM_SERVER selection, which the IM Server has created.
-</para>
-
-<para>
-Refer to "The Input Method Protocol" for the XIM_SERVER atom. <!-- xref -->
-</para>
-
-<table frame="none" id="clientmessage_sent_to_the_ims_window">
-<title>The ClientMessage sent to the IMS window.</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Structure Member</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>IMS Window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_XCONNECT", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>32</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[0]</entry>
- <entry>client communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[1]</entry>
- <entry>client-major-transport-version (*1)</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[2]</entry>
- <entry>client-major-transport-version (*1)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-In order to establish the connection (to notify the IM Server communication
-window), the IM Server sends a ClientMessage in the following event's
-format to the client communication window.
-</para>
-
-<table frame="none" id="clientmessage_sent_by_the_im_server">
-<title>The ClientMessage sent by the IM Server.</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Structure Member</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>client communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_XCONNECT", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>32</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[0]</entry>
- <entry>IMS communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[1]</entry>
- <entry>server-major-transport-version (*1)</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[2]</entry>
- <entry>server-minor-transport-version (*1)</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[3]</entry>
- <entry>dividing size between ClientMessage and Property (*2)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-(*1) major/minor-transport-version
-</para>
-<para>
-The read/write method is decided by the combination of
-major/minor-transport-version, as follows:
-</para>
-
-
-<table frame="all" id="readwrite_method_and_the_majorminor_transport_version">
-<title>The read/write method and the major/minor-transport-version</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="1"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3*" colsep="1"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Transport-version</entry>
- <entry>read/write</entry>
- </row>
- <row>
- <entry>major</entry>
- <entry>minor</entry>
- <entry></entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry morerows="2">0</entry>
- <entry>0</entry>
- <entry>only-CM &amp; Property-with-CM</entry>
- </row>
- <row rowsep="0">
- <entry>1</entry>
- <entry>only-CM &amp; multi-CM</entry>
- </row>
- <row rowsep="1">
- <entry>2</entry>
- <entry>only-CM &amp; multi-CM &amp; Property-with-CM</entry>
- </row>
- <row rowsep="1">
- <entry>1</entry>
- <entry>0</entry>
- <entry>PropertyNotify</entry>
- </row>
- <row rowsep="0">
- <entry morerows="1">2</entry>
- <entry>0</entry>
- <entry>only-CM &amp; PropertyNotify</entry>
- </row>
- <row>
- <entry>1</entry>
- <entry>only-CM &amp; multi-CM &amp; PropertyNotify</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<literallayout class="monospaced">
-only-CM : data is sent via a ClientMessage
-multi-CM : data is sent via multiple ClientMessages
-Property-with-CM : data is written in Property, and its Atom
- is send via ClientMessage
-PropertyNotify : data is written in Property, and its Atom
- is send via PropertyNotify
-
-</literallayout>
-
-<para>
-The method to decide major/minor-transport-version is as follows:
-</para>
-
-<itemizedlist>
- <listitem>
- <para>
-The client sends 0 as major/minor-transport-version to the IM Server.
-The client must support all methods in Table D-3.
-The client may send another number as major/minor-transport-version to
-use other method than the above in the future.
- </para>
- </listitem>
- <listitem>
- <para>
-The IM Server sends its major/minor-transport-version number to
-the client. The client sends data using the method specified by the
-IM Server.
- </para>
- </listitem>
- <listitem>
- <para>
-If major/minor-transport-version number is not available, it is regarded
-as 0.
-<!-- .RE -->
- </para>
- </listitem>
-</itemizedlist>
-
-<para>
-(*2) dividing size between ClientMessage and Property
-</para>
-
-<para>
-If data is sent via both of multi-CM and Property, specify the dividing
-size between ClientMessage and Property. The data, which is smaller than
-this size, is sent via multi-CM (or only-CM), and the data, which is
-lager than this size, is sent via Property.
-</para>
-
-<para>
-<emphasis role="bold">read/write</emphasis>
-</para>
-
-<para>
-The data is transferred via either ClientMessage or Window Property in
-the X Window System.
-</para>
-
-<para>
-Format for the data from the Client to the IM Server
-</para>
-
-<para>
-ClientMessage
-</para>
-
-<para>
-If data is sent via ClientMessage event, the format is as follows:
-</para>
-
-
-<table frame="none" id="clientmessage_events_format_first_or_middle">
-<title>The ClientMessage event's format (first or middle)</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Structure Member</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>IMS communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_MOREDATA", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>char</entry>
- <entry>data.b[20]</entry>
- <entry>(read/write DATA : 20 byte)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<table frame="none" id="clientmessage_events_format_only_or_last">
-<title>The ClientMessage event's format (only or last)</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Structure Member</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>IMS communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>char</entry>
- <entry>data.b[20]</entry>
- <entry>(read/write DATA : MAX 20 byte) (*1)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-(*1) If the data is smaller than 20 byte, all data other than available data
-must be 0.
-</para>
-
-<para>
-Property
-</para>
-
-<para>
-In the case of large data, data will be sent via the Window Property
-for the efficiency. There are the following two methods to notify
-Property, and transport-version is decided which method is used.
-</para>
-
-<itemizedlist>
- <listitem>
- <para>
-The XChangeProperty function is used to store data in the client
-communication window, and Atom of the stored data is notified to the
-IM Server via ClientMessage event.
- </para>
- </listitem>
- <listitem>
- <para>
-The XChangeProperty function is used to store data in the client
-communication window, and Atom of the stored data is notified to the
-IM Server via PropertyNotify event.
- </para>
- </listitem>
-</itemizedlist>
-
-<para>
-The arguments of the XChangeProperty are as follows:
-</para>
-
-<table frame="none" id="xchangeproperty_events_format">
-<title>The XChangeProperty event's format</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Argument</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>IMS communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>property</entry>
- <entry>read/write property Atom (*1)</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>type</entry>
- <entry>XA_STRING </entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>mode</entry>
- <entry>PropModeAppend</entry>
- </row>
- <row rowsep="0">
- <entry>u_char</entry>
- <entry>*data</entry>
- <entry>read/write DATA</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>nelements</entry>
- <entry>length of DATA</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-The read/write property ATOM allocates the following strings by
-<function>XInternAtom</function>.
-</para>
-
-<para>
-"_clientXXX"
-</para>
-
-<para>
-The client changes the property with the mode of PropModeAppend and
-the IM Server will read it with the delete mode i.e. (delete = True).
-</para>
-
-<para>
-If Atom is notified via ClientMessage event, the format of the ClientMessage
-is as follows:
-</para>
-
-<table frame="none" id="clientmessage_events_format_to_send_atom_of_property">
-<title>The ClientMessage event's format to send Atom of property</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry spanname="span-horiz">Structure Members</entry>
- <entry>Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>IMS communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>32</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[0]</entry>
- <entry>length of read/write property Atom</entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[1]</entry>
- <entry>read/write property Atom</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-Format for the data from the IM Server to the Client
-</para>
-
-<para>
-<!-- .LP -->
-<!-- .RS -->
-<!-- .B -->
-ClientMessage
-</para>
-<para>
-<!-- .LP -->
-The format of the ClientMessage is as follows:
-</para>
-
-
-
-<table frame="none" id="clientmessage_events_format_for_first_or_middle">
-<title>The ClientMessage event's format (first or middle)</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry align="left" spanname="span-horiz">Structure Members</entry>
- <entry align="left">Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event </entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>client communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_MOREDATA", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>char</entry>
- <entry>data.b[20]</entry>
- <entry>(read/write DATA : 20 byte)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-
-<table frame="none" id="clientmessage_events_format_for_only_or_last">
-<title>The ClientMessage event's format (only or last)</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry align="left" spanname="span-horiz">Structure Members</entry>
- <entry align="left">Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage</entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event </entry>
- <entry>Set by the X Window System</entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>client communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>char</entry>
- <entry>data.b[20]</entry>
- <entry>(read/write DATA : MAX 20 byte) (*1)</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-(*1) If the data size is smaller than 20 bytes, all data other than available
-data must be 0.
-</para>
-
-<para>
-Property
-</para>
-
-<para>
-In the case of large data, data will be sent via the Window Property
-for the efficiency. There are the following two methods to notify
-Property, and transport-version is decided which method is used.
-</para>
-
-<itemizedlist>
- <listitem>
- <para>
-The XChangeProperty function is used to store data in the IMS
-communication window, and Atom of the property is sent via the
-ClientMessage event.
- </para>
- </listitem>
- <listitem>
- <para>
-The XChangeProperty function is used to store data in the IMS
-communication window, and Atom of the property is sent via
-PropertyNotify event.
- </para>
- </listitem>
-</itemizedlist>
-
-<para>
-The arguments of the XChangeProperty are as follows:
-</para>
-
-<table frame="none" id="xchangeproperty_events_format_2">
-<title>The XChangeProperty event's format</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*" colsep="1"/>
- <colspec colname="col3" colwidth="3.5*" colsep="0"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry align="left" spanname="span-horiz">Argument</entry>
- <entry align="left">Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display which to connects</entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>client communication window ID</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>property</entry>
- <entry>read/write property Atom (*1)</entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>type</entry>
- <entry>XA_STRING</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>8</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>mode</entry>
- <entry>PropModeAppend</entry>
- </row>
- <row rowsep="0">
- <entry>u_char</entry>
- <entry>*data</entry>
- <entry>read/write DATA</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>nelements</entry>
- <entry>length of DATA</entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-(*1) The read/write property ATOM allocates some strings, which are not
-allocated by the client, by <function>XInternAtom</function>.
-</para>
-
-<para>
-The IM Server changes the property with the mode of PropModeAppend and
-the client reads it with the delete mode, i.e. (delete = True).
-</para>
-
-<para>
-If Atom is notified via ClientMessage event, the format of the ClientMessage
-is as follows:
-</para>
-
-
-<table frame="none" id="clientmessage_events_format_to_send_atom_of_property_2">
-<title>The ClientMessage event's format to send Atom of property</title>
- <tgroup cols="3">
- <colspec colname="col1" colwidth="1*" colsep="0"/>
- <colspec colname="col2" colwidth="1*"/>
- <colspec colname="col3" colwidth="3.5*"/>
- <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
- <thead>
- <row>
- <entry align="left" spanname="span-horiz">Structure Member</entry>
- <entry align="left">Contents</entry>
- </row>
- </thead>
- <tbody>
- <row rowsep="0">
- <entry>int</entry>
- <entry>type</entry>
- <entry>ClientMessage </entry>
- </row>
- <row rowsep="0">
- <entry>u_long</entry>
- <entry>serial</entry>
- <entry>Set by the X Window System </entry>
- </row>
- <row rowsep="0">
- <entry>Bool</entry>
- <entry>send_event</entry>
- <entry>Set by the X Window System </entry>
- </row>
- <row rowsep="0">
- <entry>Display</entry>
- <entry>*display</entry>
- <entry>The display to which connects </entry>
- </row>
- <row rowsep="0">
- <entry>Window</entry>
- <entry>window</entry>
- <entry>client communication window ID </entry>
- </row>
- <row rowsep="0">
- <entry>Atom</entry>
- <entry>message_type</entry>
- <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
- </row>
- <row rowsep="0">
- <entry>int</entry>
- <entry>format</entry>
- <entry>32 </entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[0]</entry>
- <entry>length of read/write property ATOM </entry>
- </row>
- <row rowsep="0">
- <entry>long</entry>
- <entry>data.l[1]</entry>
- <entry>read/write property ATOM </entry>
- </row>
- </tbody>
- </tgroup>
-</table>
-
-<para>
-Closing Connection
-</para>
-
-<para>
-If the client disconnect with the IM Server, shutdown function should
-free the communication window properties and etc..
-</para>
-</appendix>
-</article>
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+<!ENTITY % defs SYSTEM "defs.ent"> %defs;
+]>
+
+
+<!-- lifted from troff+ms+XMan by doclifter -->
+<article class="specification" id="xim">
+
+<articleinfo>
+ <title>The Input Method Protocol</title>
+ <subtitle>X Consortium Standard</subtitle>
+ <releaseinfo>X Version 11, Release &fullrelvers;</releaseinfo>
+ <authorgroup>
+ <author>
+ <firstname>Masahiko</firstname><surname>Narita</surname>
+ <affiliation><orgname>FUJITSU Limited.</orgname></affiliation>
+ </author>
+ <author>
+ <firstname>Hideki</firstname><surname>Hiura</surname>
+ <affiliation><orgname>SunSoft, Inc.</orgname></affiliation>
+ </author>
+ </authorgroup>
+ <copyright><year>1993</year><year>1994</year><holder>X Consortium</holder></copyright>
+ <copyright><year>1993</year><year>1994</year><holder>FUJITSU LIMITED</holder></copyright>
+ <copyright><year>1993</year><year>1994</year><holder>Oracle and/or its affiliates</holder></copyright>
+ <releaseinfo>Version 1.0</releaseinfo>
+ <affiliation><orgname>X Consortium</orgname></affiliation>
+
+<abstract>
+<para>
+This specifies a protocol between IM library and IM (Input Method) Server for internationalized text input, which is indepedent from any specific language, any specific input method and the transport layer used in communication between the IM library and the IM Server, and uses a client-server model. This protocol allows user to use his/her favorite method for all applications within the stand-along distrubuted environment.
+</para>
+</abstract>
+
+<legalnotice>
+<para>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the &ldquo;Software&rdquo;), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</para>
+
+<para>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</para>
+
+<para>THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</para>
+
+<para>Except as contained in this notice, the name of the X Consortium shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from the X Consortium.</para>
+
+<para>X Window System is a trademark of The Open Group.</para>
+
+<para>Permission to use,copy and distribute this documetation for any purpose and without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. Fujitsu and Sun Microsystems make no representation about the suitability for any purpose of the information in this documen. This documentation is provided as is without express implied warranty.
+</para>
+
+</legalnotice>
+
+</articleinfo>
+
+<sect1 id="Introduction">
+<title>Introduction</title>
+<sect2 id="Scope">
+<title>Scope</title>
+<!-- .XS -->
+<!-- (SN Scope -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+The internationalization in the
+X Window System
+Version 11, Release 5 (X11R5) provides a common API which application
+developers can use to create portable internationalized programs and to
+adapt them to the requirements of different native languages, local customs,
+and character string encodings (this is called "localization").
+As one of its internationalization mechanisms X11R5 has defined a functional
+interface for internationalized text input, called XIM (X Input Method).
+</para>
+<para>
+<!-- .LP -->
+When a client-server model is used with an IM (Input Method) implementation,
+a protocol must be established between the client and the server.
+However, the protocol used to interface Input Method Servers (IM Servers)
+with the Input Method libraries (IM libraries) to which applications are
+linked was not addressed in X11R5.
+This led application developers to depend on vendor-specific input methods,
+decreased the user's choice of available input methods, and made it more
+difficult for developers to create portable applications. This paper describes
+the Input Method Protocol developed for X11R6 to resolve the above problems
+and to address the requirements of existing and future input methods.
+</para>
+<para>
+<!-- .LP -->
+The Input Method Protocol is independent from the transport layer used in
+communication between the IM library and the IM Server.
+Thus, the input method protocol can be built on any inter-process
+communication mechanism, such as TCP/IP or the X protocol.
+</para>
+<para>
+In addition, the protocol provides for future extensions such as differing
+input model types.
+</para>
+</sect2>
+
+<sect2 id="Background">
+<title>Background</title>
+<!-- .XS -->
+<!-- (SN Background -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+Text input is much more simple for some languages than
+others. English, for instance, uses an alphabet of a manageable size,
+and input consists of pressing the corresponding key on a keyboard,
+perhaps in combination with a shift key for capital letters or special
+characters.
+</para>
+<para>
+<!-- .LP -->
+Some languages have larger alphabets, or modifiers such as accents,
+which require the addition of special key combinations in order to enter
+text. These input methods may require "dead-keys" or "compose-keys"
+which, when followed by different combinations of key strokes,
+generate different characters.
+</para>
+<para>
+<!-- .LP -->
+Text input for ideographic languages is much less simple. In these
+languages, characters represent actual objects rather than phonetic
+sounds used in pronouncing a word, and the number of characters
+in these languages may continue to grow. In Japanese, for instance, most
+text input methods involve entering characters in a phonetic alphabet,
+after which the input method searches a dictionary for possible
+ideographic equivalents (of which there may be many). The input method then
+presents the candidate characters for the user to choose from.
+</para>
+<para>
+<!-- .LP -->
+In Japanese, either Kana (phonetic symbols) or Roman letters are
+typed and then a region is selected for conversion to Kanji. Several
+Kanji characters may have the same phonetic representation. If that
+is the case with the string entered, a menu of characters is presented
+and the user must choose the appropriate one. If no choice is necessary
+or a preference has been established, the input method does the
+substitution directly.
+</para>
+<para>
+<!-- .LP -->
+These complicated input methods must present state information (Status Area),
+text entry and edit space (Preedit Area), and menu/choice presentations
+(Auxiliary Area). Much of the protocol between the IM library and the IM
+Server involves managing these IM areas.
+Because of the size and complexity of these input methods, and because
+of how widely they vary from one language or locale to another, they are
+usually implemented as separate processes which can serve many client
+processes on the same computer or network.
+</para>
+<para>
+<!-- .LP -->
+</para>
+</sect2>
+<sect2 id="Input_Method_Styles">
+<title>Input Method Styles</title>
+<!-- .XS -->
+<!-- (SN Input Method Styles -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+X11 internationalization support includes the following four types of
+input method:
+<!-- .RS -->
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term>- on-the-spot:</term>
+ <listitem>
+ <para>
+The client application is directed by the IM Server to display all
+pre-edit data at the site of text insertion. The client registers
+callbacks invoked by the input method during pre-editing.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>- off-the-spot:</term>
+ <listitem>
+ <para>
+The client application provides display windows for the pre-edit data
+to the input method which displays into them directly.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>- over-the-spot:</term>
+ <listitem>
+ <para>
+The input method displays pre-edit data in a window which it brings up
+directly over the text insertion position.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>- root-window:</term>
+ <listitem>
+ <para>
+The input method displays all pre-edit data in a separate area of the
+screen in a window specific to the input method.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+Client applications must choose from the available input methods
+supported by the IM Server and provide the display areas and callbacks
+required by the input method.
+</para>
+</sect2>
+
+</sect1>
+<sect1 id="Architecture">
+<title>Architecture</title>
+<!-- .XS -->
+<!-- (SN Architecture -->
+<!-- .XE -->
+<sect2 id="Implementation_Model">
+<title>Implementation Model</title>
+<!-- .XS -->
+<!-- (SN Implementation Model -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+Within the X Window System environment, the following two typical
+architectural models can be used as an input method's implementation
+model.
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term>- Client/Server model:</term>
+ <listitem>
+ <para>
+A separate process, the IM Server, processes input and handles preediting,
+converting, and committing. The IM library within the application, acting
+as client to the IM Server, simply receives the committed string from the
+IM Server.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>- Library model:</term>
+ <listitem>
+ <para>
+All input is handled by the IM library within the application. The
+event process is closed within the IM library and a separate IM Server
+process may not be required.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+<!-- .LP -->
+Most languages which need complex preediting, such as Asian languages,
+are implemented using the Client/Server IM model. Other languages
+which need only dead key or compose key processing, such as European
+languages, are implemented using the Library model.
+</para>
+<para>
+<!-- .LP -->
+In this paper, we discuss mainly the Client/Server IM model and the
+protocol used in communication between the IM library (client) and the IM
+Server.
+</para>
+</sect2>
+
+<sect2 id="Structure_of_IM">
+<title>Structure of IM</title>
+<!-- .XS -->
+<!-- (SN Structure of IM -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+When the client connects or disconnects to the IM Server, an open or close
+operation occurs between the client and the IM Server.
+</para>
+<para>
+<!-- .LP -->
+The IM can be specified at the time of XOpenIM() by setting the locale
+of the client and a locale modifier. Since the IM remembers
+the locale at the time of creation XOpenIM() can be called
+multiple times (with the
+setting for the locale and the locale modifier changed) to support
+multiple languages.
+</para>
+<para>
+<!-- .LP -->
+In addition, the supported IM type can be obtained using XGetIMValues().
+</para>
+<para>
+<!-- .LP -->
+The client usually holds multiple input (text) fields. Xlib provides a
+value type called the "Input Context" (IC) to manage each individual
+input field. An IC can be created by specifying XIM using XCreateIC(),
+and it can be destroyed using XDestroyIC().
+</para>
+<para>
+<!-- .LP -->
+The IC can specify the type of IM which is supported by XIM for each
+input field, so each input field can handle a different type of IM.
+</para>
+<para>
+<!-- .LP -->
+Most importantly information such as the committed string sent from
+the IM Server to the client, is exchanged based on each IC.
+</para>
+<para>
+<!-- .LP -->
+Since each IC corresponds to an input field, the focused input field
+should be announced to the IM Server using XSetICFocus(). (XUnsetICFocus()
+can also be used to change the focus.)
+</para>
+<para>
+<!-- .LP -->
+</para>
+</sect2>
+<sect2 id="Event_Handling_Model">
+<title>Event Handling Model</title>
+<!-- .XS -->
+<!-- (SN Event Handling Model -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+Existing input methods support either the FrontEnd method, the BackEnd method,
+or both. This protocol specifically supports the BackEnd method as
+the default method, but also supports the FrontEnd method as an optional
+IM Server extension.
+</para>
+<para>
+<!-- .LP -->
+The difference between the FrontEnd and BackEnd methods is in how
+events are delivered to the IM Server. (Fig. 1) <!-- xref -->
+</para>
+
+<sect3 id="BackEnd_Method">
+<title>BackEnd Method</title>
+<!-- .XS -->
+<!-- (SN BackEnd Method -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+In the BackEnd method, client window input events are always delivered
+to the IM library, which then passes them to the IM Server. Events are
+handled serially in the order delivered, and therefore there is no
+synchronization problem between the IM library and the IM Server.
+</para>
+<para>
+<!-- .LP -->
+Using this method, the IM library forwards all KeyPress and KeyRelease
+events to the IM Server (as required by the Event Flow Control model
+described in
+<link linkend="event_flow_control">
+<xref linkend="event_flow_control"></xref></link>)
+and synchronizes with the IM Server (as described in
+<link linkend="filtering_events">
+<xref linkend="filtering_events"></xref></link>).
+
+</para>
+</sect3>
+
+<sect3 id="FrontEnd_Method">
+<title>FrontEnd Method</title>
+<!-- .XS -->
+<!-- (SN FrontEnd Method -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+In the FrontEnd method, client window input events are delivered by the
+X server directly to both the IM Server and the IM library. Therefore this
+method provides much better interactive performance while preediting
+(particularly in cases such as when the IM Server is running locally on
+the user's workstation and the client application is running on another
+workstation over a relatively slow network).
+</para>
+<para>
+<!-- .LP -->
+However, the FrontEnd model may have synchronization problems between
+the key events handled in the IM Server and other events handled in the
+client, and these problems could possibly cause the loss or duplication
+of key events. For this reason, the BackEnd method is the core method
+supported, and the FrontEnd method is made available as an extension for
+performance purposes. (Refer to
+<link linkend="common_extensions">
+<xref linkend="common_extensions"></xref></link>
+for more information.)
+</para>
+
+<mediaobject id="flow_of_events">
+ <imageobject>
+ <imagedata format="SVG" fileref="eventflow.svg"/>
+ </imageobject>
+ <caption>The flow of events</caption>
+</mediaobject>
+
+<!--
+<para>
+Fig.1 The Flow of Events
+</para>
+-->
+
+</sect3>
+</sect2>
+
+<sect2 id="event_flow_control">
+<title>Event Flow Control</title>
+<!-- .XS -->
+<!-- (SN Event Flow Control -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+This protocol supports two event flow models for communication between the
+IM library and the IM Server (Static and Dynamic).
+</para>
+<para>
+<!-- .LP -->
+Static Event Flow requires that input events always be sent to the IM
+Server from the client.
+</para>
+<para>
+<!-- .LP -->
+Dynamic Event Flow, however, requires only that those input events which
+need to be processed (converted) be sent to the IM Server from the client.
+</para>
+<para>
+<!-- .LP -->
+For instance, in the case of inputing a combination of ASCII characters
+and Chinese characters, ASCII characters do not need to be processed in
+the IM Server, so their key events do not have to be sent to the IM
+Server. On the other hand, key events necessary for composing Chinese
+characters must be sent to the IM Server.
+</para>
+<para>
+<!-- .LP -->
+Thus, by adopting the Dynamic Event Flow, the number of requests among the
+X Server, the client, and the IM Server is significantly reduced, and the
+number of context switches is also reduced, resulting in improved performance.
+The IM Server can send
+<function>XIM_REGISTER_TRIGGERKEYS </function>
+message in order to switch the event flow in the Dynamic Event Flow.
+</para>
+<para>
+<!-- .LP -->
+The protocol for this process is described in
+<link linkend="event_flow_control_2">
+<xref linkend="event_flow_control_2"></xref></link>.
+</para>
+</sect2>
+</sect1>
+
+<sect1 id="Default_Preconnection_Convention">
+<title>Default Preconnection Convention</title>
+<!-- .XS -->
+<!-- (SN Default Preconnection Convention -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+IM Servers are strongly encouraged to register their symbolic
+names as the ATOM names into the IM Server directory property,
+<function>XIM_SERVERS,</function>
+on the root window of the screen_number 0.
+This property can contain a list of ATOMs, and the each ATOM represents
+each possible IM Server.
+IM Server names are restricted to POSIX Portable Filename Character Set.
+To discover if the IM Server is active, see if there is an owner for
+the selection with that atom name. To learn the address of that IM Server,
+convert the selection target
+<function>TRANSPORT,</function>
+which will return a string form of the transport address(es).
+To learn the supported locales of that IM Server, convert the selection target
+<function>LOCALES,</function>
+which will return a set of names of the supported locales in the syntax
+X/Open defines.
+</para>
+<para>
+<!-- .LP -->
+The basic semantics to determine the IM Server if there are
+multiple ATOMs are found in
+<function>XIM_SERVERS</function>
+property, is first fit if the IM Server name is not given as
+a X modifier's category
+<function>im.</function>
+</para>
+<para>
+<!-- .LP -->
+The address information retrievable from the
+<function>TRANSPORT</function>
+target is a transport-specific name.
+The preregistered formats for transport-specific names are listed in
+<link linkend="transport_list">
+<xref linkend="transport_list"></xref></link>.
+Additional transport-specific names may be registered with X Consortium.
+</para>
+
+<para>
+For environments that lack X connections, or for IM Servers which
+do not use the X Window System, the preconnection convention with IM Server
+may be given outside the X Window system (e.g. using a Name Service).
+</para>
+</sect1>
+
+<sect1 id="Protocol">
+<title>Protocol</title>
+<!-- .XS -->
+<!-- (SN Protocol -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+The protocol described below uses the bi-directional
+synchronous/asynchronous request/reply/error model and is specified
+using the same conventions outlined in Section 2 of the core X Window
+System protocol [1]:
+</para>
+
+<sect2 id="Basic_Requests_Packet_Format">
+<title>Basic Requests Packet Format</title>
+<!-- .XS -->
+<!-- (SN Basic Requests Packet Format -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+This section describes the requests that may be exchanged between the client
+and the IM Server.
+</para>
+<para>
+<!-- .LP -->
+The basic request packet header format is as follows.
+</para>
+<literallayout class="monospaced">
+ major-opcode: CARD8
+ minor-opcode: CARD8
+ length: CARD16
+</literallayout>
+
+<para>
+The MAJOR-OPCODE specifies which core request or extension package this
+packet represents. If the MAJOR-OPCODE corresponds to a core request,
+the MINOR-OPCODE contains 8 bits of request-specific data.
+(If the MINOR-OPCODE is not used, it is 0.)
+Otherwise, the MAJOR-OPCODE and the MINOR-OPCODE are specified by
+<function>XIM_QUERY_EXTENSION</function>
+message. (Refer to 4.7. Query the supported extension protocol list.)
+The LENGTH field specifies the number of 4 bytes elements following the
+header. If no additional data is followed by the header, the LENGTH field
+will be 0.
+</para>
+</sect2>
+
+<sect2 id="Data_Types">
+<title>Data Types</title>
+<!-- .XS -->
+<!-- (SN Data Types -->
+<!-- .XE -->
+<para>
+The following data types are used in the core X IM Server protocol:
+</para>
+
+<literallayout class="monospaced">
+BITMASK16
+ CARD16
+BITMASK32
+ CARD32
+PADDING FORMAT
+ Where N is some expression, and Pad(N) is the number of bytes needed to round N up to a
+
+ Pad(N) = (4 - (N mod 4)) mod 4
+
+LPCE
+ 1 A character from the4 X Portable Character Set in Latin Portable
+ Character Encoding
+
+STRING
+ 2 n length of string in bytes
+ n LISTofLPCE string
+ p unused, p=Pad(2+n)
+
+STR
+ 1 n length of name in bytes
+ n STRING8 name
+
+XIMATTR
+ 2 CARD16 attribute ID (*1)
+ 2 CARD16 type of the value (*2)
+ 2 n length of im-attribute
+ n STRING8 im-attribute
+ p unused, p = Pad(2+n)
+
+The im-attribute argument specifies XIM values such as XNQueryInputStyle.
+
+XICATTR
+ 2 CARD16 attribute ID (*1)
+ 2 CARD16 type of the value (*2)
+ 2 n length of ic-attribute
+ n STRING8 ic-attribute
+ p unused, p = Pad(2+n)
+
+(*1) XIMATTR and XICATTR are used during the setup stage and XIMATTRIBUTE and
+ XICATTRIBUTE are used after each attribute ID has been recognized by
+ the IM Server and the IM library.
+
+(*2) The value types are defined as follows:
+</literallayout>
+<informaltable id="valuetypes" frame="none">
+ <tgroup cols="5">
+ <colspec colname="col1" colsep="0"/>
+ <colspec colname="col2" colsep="0"/>
+ <colspec colname="col3" colsep="0"/>
+ <colspec colname="col4" colsep="0"/>
+ <colspec colname="col5" colsep="0"/>
+ <spanspec namest="col3" nameend="col5" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry>values</entry>
+ <entry>data</entry>
+ <entry>format</entry>
+ <!-- <entry spanname="span-horiz">format</entry> -->
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>#0</entry>
+ <entry>Separator of NestedList</entry>
+ <entry>-----(*3)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#1</entry>
+ <entry>byte data</entry>
+ <entry>CARD8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#2</entry>
+ <entry>word data</entry>
+ <entry>CARD16</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#3</entry>
+ <entry>long data</entry>
+ <entry>CARD32</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#4</entry>
+ <entry>char data</entry>
+ <entry>STRING8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#5</entry>
+ <entry>Window</entry>
+ <entry>CARD32</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#10</entry>
+ <entry>XIMStyles</entry>
+ <entry>2</entry>
+ <entry>n</entry>
+ <entry>number of XIMStyle list</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>2</entry>
+ <entry></entry>
+ <entry>unused</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>n</entry>
+ <entry>CARD32</entry>
+ <entry>XIMStyle list</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#11</entry>
+ <entry>XRectangle</entry>
+ <entry>2</entry>
+ <entry>INT16</entry>
+ <entry>X</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>2</entry>
+ <entry>INT16</entry>
+ <entry>Y</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>2</entry>
+ <entry>CARD16</entry>
+ <entry>width</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>2</entry>
+ <entry>CARD16</entry>
+ <entry>height</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#12</entry>
+ <entry>XPoint</entry>
+ <entry>2</entry>
+ <entry>INT16</entry>
+ <entry>X</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>2</entry>
+ <entry>INT16</entry>
+ <entry>Y</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#13</entry>
+ <entry>XFontSet</entry>
+ <entry>2</entry>
+ <entry>n</entry>
+ <entry>length of Base font name</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>n</entry>
+ <entry>STRING8</entry>
+ <entry>Base font name list</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>p</entry>
+ <entry></entry>
+ <entry>unused, p = Pad(2+n)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#15</entry>
+ <entry>XIMHotKeyTriggers</entry>
+ <entry>4</entry>
+ <entry>n</entry>
+ <entry>number of XIMTRIGGERKEY list (*4)</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>n</entry>
+ <entry>XIMTRIGGERKEY</entry>
+ <entry>XIMHotkeyTrigger list</entry>
+ </row>
+ <row rowsep="0">
+ <entry></entry>
+ <entry></entry>
+ <entry>n</entry>
+ <entry>XIMHOTKEYSTATE</entry>
+ <entry>HotKey processing state</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#17</entry>
+ <entry>XIMStringConversion</entry>
+ <entry>XIMSTRCONVTEXT</entry>
+ <entry></entry>
+ <entry></entry>
+ </row>
+ <row rowsep="0">
+ <entry>#18</entry>
+ <entry>XIMPreeditState</entry>
+ <entry>XIMPREEDITSTATE</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#19</entry>
+ <entry>XIMResetState</entry>
+ <entry>XIMRESETSTATE</entry>
+ </row>
+ <row rowsep="0">
+ <entry>#x7fff</entry>
+ <entry>NestedList</entry>
+ <entry>-----</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</informaltable>
+
+<literallayout class="monospaced">
+(*3) The IC value for the separator of NestedList is defined as follows,
+ #define XNSeparatorofNestedList "separatorofNestedList"
+ , which is registered in X Consortium and cannot be used for any other purpose.
+
+(*4) LISTofFOO
+ A Type name of the form LISTof FOO means a counted list of elements of type FOO.
+ The size of the length field may vary (it is not necessarily the same
+ size as a FOO), and in some cases, it may be implicit.
+XIMTRIGGERKEY
+ 4 CARD32 keysym
+ 4 CARD32 modifier
+ 4 CARD32 modifier mask
+
+ENCODINGINFO
+ 2 n length of encoding info
+ n STRING8 encoding info
+ p unused, p=Pad(2+n)
+
+
+ 1 CARD8 extension major-opcode
+ 1 CARD8 extension minor-opcode
+ 2 n length of extension name
+ n STRING8 extension name
+ p unused, p = Pad(n)
+
+XIMATTRIBUTE
+ 2 CARD16 attribute ID
+ 2 n value length
+ n value
+ p unused, p = Pad(n)
+
+XICATTRIBUTE
+ 2 CARD16 attribute ID
+ 2 n value length
+ n value
+ p unused, p = Pad(n)
+
+
+
+XIMSTRCONVTEXT
+ 2 CARD16 XIMStringConversionFeedback
+ #x0000001 XIMStringConversionLeftEdge
+ #x0000002 XIMStringConversionRightEdge
+ #x0000004 XIMStringConversionTopEdge
+ #x0000008 XIMStringConversionBottomEdge
+ #x0000010 XIMStringConversionConvealed
+ #x0000020 XIMStringConversionWrapped
+ 2 n byte length of the retrieved string
+ n STRING8 retrieved string
+ p unused, p = Pad(n)
+ 2 m byte length of feedback array
+ 2 unused
+ m LISTofXIMSTRCONVFEEDBACK feedback array(*1)
+
+(*1) This field is reserved for future use.
+
+XIMFEEDBACK
+ 4 CARD32 XIMFeedback
+ #x000001 XIMReverse
+ #x000002 XIMUnderline
+ #x000004 XIMHighlight
+ #x000008 XIMPrimary
+ #x000010 XIMSecondary
+ #x000020 XIMTertiary
+ #x000040 XIMVisibleToForward
+ #x000080 XIMVisibleToBackward
+ #x000100 XIMVisibleCenter
+
+XIMHOTKEYSTATE
+ 4 CARD32 XIMHotKeyState
+ #x0000001 XIMHotKeyStateON
+ #x0000002 XIMHotKeyStateOFF
+
+XIMPREEDITSTATE
+ 4 CARD32 XIMPreeditState
+ #x0000001 XIMPreeditEnable
+ #x0000002 XIMPreeditDisable
+
+XIMRESETSTATE
+ 4 CARD32 XIMResetState
+ #x0000001 XIMInitialState
+ #x0000002 XIMPreserveState
+</literallayout>
+</sect2>
+
+<sect2 id="Error_Notification">
+<title>Error Notification</title>
+<!-- .XS -->
+<!-- (SN Error Notification -->
+<!-- .XE -->
+<para>
+Both the IM Server and the IM library return
+<function>XIM_ERROR</function>
+messages instead of the corresponding reply messages if any errors occur
+during data processing.
+</para>
+
+<para>
+At most one error is generated per request. If more than one error condition
+is encountered in processing a request, the choice of which error is returned
+is implementation-dependent.
+</para>
+
+<literallayout class="monospaced">
+XIM_ERROR (IM Server &lt;--&gt; IM library)
+<!-- .sp 6p -->
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 BITMASK16 flag (*1)
+ #0000 Both Input-Method-ID and Input-Context-ID are invalid
+ #0001 Input-Method-ID is valid
+ #0002 Input-Context-ID is valid
+ 2 CARD16 Error Code
+ #1 BadAlloc
+ #2 BadStyle
+ #3 BadClientWindow
+ #4 BadFocusWindow
+ #5 BadArea
+ #6 BadSpotLocation
+ #7 BadColormap
+ #8 BadAtom
+ #9 BadPixel
+ #10 BadPixmap
+ #11 BadName
+ #12 BadCursor
+ #13 BadProtocol
+ #14 BadForeground
+ #15 BadBackground
+ #16 LocaleNotSupported
+ #999 BadSomething (*2)
+ 2 n byte length of error detail.
+ 2 CARD16 type of error detail (*3)
+ n STRING8 error detail (*4)
+ p unused, p = Pad(n)
+
+(*1) Before an IM is created, both Input-Method-ID and
+ Input-Context-ID are invalid.
+ Before an IC is created, only Input-Method-ID is valid.
+ After that, both of Input-Method-ID and Input-Context-ID are valid.
+
+(*2) Unspecific error, for example "language engine died"
+
+(*3) This field is reserved for future use.
+
+(*4) Vendor defined detail error message
+</literallayout>
+</sect2>
+
+<sect2 id="Connection_Establishment">
+<title>Connection Establishment</title>
+<!-- .XS -->
+<!-- (SN Connection Establishment -->
+<!-- .XE -->
+<para>
+<function>XIM_CONNECT</function>
+message requests to establish a connection over a mutually-understood virtual
+stream.
+</para>
+
+<literallayout class="monospaced">
+XIM_CONNECT (IM library -&gt; IM Server)
+ 1 byte order
+ #x42 MSB first
+ #x6c LSB first
+ 1 unused
+ 2 CARD16 client-major-protocol-version (*1)
+ 2 CARD16 client-minor-protocol-version (*1)
+ 2 CARD16 number of client-auth-protocol-names
+ n LISTofSTRING client-auth-protocol-names
+
+(*1) Specify the version of IM Protocol that the client supports.
+</literallayout>
+
+<para>
+A client must send
+<function>XIM_CONNECT</function>
+message as the first message on the connection.
+The list specifies the names of authentication protocols the sending
+IM Server is willing to perform.
+(If the client need not authenticate, the list may be omited.)
+</para>
+
+<para>
+<function>XIM_AUTH_REQUIRED </function>
+message is used to send the authentication protocol name and protocol-specific
+data.
+</para>
+
+<literallayout class="monospaced">
+XIM_AUTH_REQUIRED (IM library &lt;--&gt; IM Server)
+
+ 1 CARD8 auth-protocol-index
+ 3 unused
+ 2 n length of authentication data
+ 2 unused
+ n &lt;varies&gt; data
+ p unused, p = Pad(n)
+</literallayout>
+
+<para>
+The auth-protocol is specified by an index into the list of names
+given in the
+<function>XIM_CONNECT</function>
+or
+<function>XIM_AUTH_SETUP</function>
+message. Any protocol-specific data that might be required is also sent.
+</para>
+
+<para>
+The IM library sends
+<function>XIM_AUTH_REPLY</function>
+message as the reply to
+<function>XIM_AUTH_REQUIRED</function>
+message, if the IM Server is authenticated.
+</para>
+
+<literallayout class="monospaced">
+XIM_AUTH_REPLY (IM library -&gt; IM Server)
+ 2 n length of authentication data
+ 2 unused
+ 2 n length of authentication data
+ 2 unused
+ n &lt;varies&gt; data
+ p unused, p = Pad(n)
+</literallayout>
+
+<para>
+The auth data is specific to the authentication protocol in use.
+</para>
+<para>
+<!-- .LP -->
+<function>XIM_AUTH_NEXT </function>
+message requests to send more auth data.
+</para>
+
+<literallayout class="monospaced">
+XIM_AUTH_NEXT (IM library &lt;--&gt; IM Server)
+ 2 n length of authentication data
+ 2 unused
+ n &lt;varies&gt; data
+ p unused, p = Pad(n)
+</literallayout>
+<para>
+The auth data is specific to the authentication protocol in use.
+</para>
+
+<para>
+<!-- .LP -->
+The IM Server sends
+<function>XIM_AUTH_SETUP</function>
+message to authenticate the client.
+</para>
+
+<literallayout class="monospaced">
+XIM_AUTH_SETUP (IM Server -&gt; IM library)
+ 2 CARD16 number of client-auth-protocol-names
+ 2 unused
+ n LISTofSTRING server-auth-protocol-names
+</literallayout>
+
+<para>
+The list specifies the names of authentication protocols the
+client is willing to perform.
+</para>
+
+<para>
+<function>XIM_AUTH_NG</function>
+message requests to give up the connection.
+</para>
+
+<para>
+XIM_AUTH_NG (IM library &lt;--&gt; IM Server)
+</para>
+
+<para>
+The IM Server sends
+<function>XIM_CONNECT_REPLY</function>
+message as the reply to
+<function>XIM_CONNECT</function>
+or
+<function>XIM_AUTH_REQUIRED</function>
+message.
+</para>
+
+<literallayout class="monospaced">
+XIM_CONNECT_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 server-major-protocol-version (*1)
+ 2 CARD16 server-minor-protocol-version (*1)
+
+(*1) Specify the version of IM Protocol that the IM Server supports.
+This document specifies major version one, minor version zero.
+</literallayout>
+
+<para>
+Here are the state diagrams for the client and the IM Server.
+</para>
+
+<para>
+State transitions for the client
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term><emphasis remap='I'>init_status</emphasis>:</term>
+ <listitem>
+ <para>
+Use authorization function -&gt; <emphasis remap='I'>client_ask</emphasis>
+ </para>
+ <para>
+Not use authorization function -&gt; <emphasis remap='I'>client_no_check</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>start</emphasis>:</term>
+ <listitem>
+ <para>
+Send <function>XIM_CONNECT</function>
+ </para>
+ <para>
+If <emphasis remap='I'>client_ask</emphasis> -&gt; <emphasis remap='I'>client_wait1</emphasis>
+ </para>
+ <para>
+If <emphasis remap='I'>client_no_check</emphasis>,
+client-auth-protocol-names may be omited -&gt; <emphasis remap='I'>client_wait2</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>client_wait1</emphasis>:</term>
+ <listitem>
+ <para>
+Receive <function>XIM_AUTH_REQUIRED</function>
+-&gt; <emphasis remap='I'>client_check</emphasis>
+ </para>
+ <para>
+Receive &lt;other&gt; -&gt; <emphasis remap='I'>client_NG</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>client_check</emphasis>:</term>
+ <listitem>
+ <para>
+If no more auth needed, send <function>XIM_AUTH_REPLY</function>
+-&gt; <emphasis remap='I'>client_wait2</emphasis>
+ </para>
+ <para>
+If good auth data, send <function>XIM_AUTH_NEXT</function>
+-&gt; <emphasis remap='I'>client_wait1</emphasis>
+ </para>
+ <para>
+If bad auth data, send <function>XIM_AUTH_NG</function>
+-&gt; give up on this protocol
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>client_wait2</emphasis>:</term>
+ <listitem>
+ <para>
+Receive <function>XIM_CONNECT_REPLY</function>
+-&gt; connect Receive
+<function>XIM_AUTH_SETUP </function>
+-&gt; <emphasis remap='I'>client_more</emphasis>
+ </para>
+ <para>
+Receive <function>XIM_AUTH_NEXT</function>
+-&gt; <emphasis remap='I'>client_more</emphasis>
+ </para>
+ <para>
+Receive <function>XIM_AUTH_NG</function>
+-&gt; give up on this protocol
+ </para>
+ <para>
+Receive &lt;other&gt; -&gt; <emphasis remap='I'>client_NG</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>client_more</emphasis>:</term>
+ <listitem>
+ <para>
+Send <function>XIM_AUTH_REQUIRED</function>
+-&gt; <emphasis remap='I'>client_wait2</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>client_NG</emphasis>:</term>
+ <listitem>
+ <para>
+Send <function>XIM_AUTH_NG</function>
+-&gt; give up on this protocol
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+State transitions for the IM Server
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term><emphasis remap='I'>init_status</emphasis>:</term>
+ <listitem>
+ <para>
+Use authorization function -&gt; <emphasis remap='I'>server_ask</emphasis>
+ </para>
+ <para>
+Not use authorization function -&gt; <emphasis remap='I'>server_no_check</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>start</emphasis>:</term>
+ <listitem>
+ <para>
+Receive <function>XIM_CONNECT</function>
+ </para>
+ <para>
+-&gt; <emphasis remap='I'>start2</emphasis>
+Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>start2</emphasis>:</term>
+ <listitem>
+ <para>
+If <emphasis remap='I'>client_ask</emphasis>, send
+<function>XIM_AUTH_REQUIRED</function>
+-&gt; <emphasis remap='I'>server_wait1</emphasis>
+ </para>
+ <para>
+If <emphasis remap='I'>client_no_check</emphasis> and
+<emphasis remap='I'>server_ask</emphasis>, send
+<function>XIM_AUTH_SETUP</function>
+-&gt; <emphasis remap='I'>server_wait2</emphasis>
+ </para>
+ <para>
+If <emphasis remap='I'>client_no_check</emphasis> and
+<emphasis remap='I'>server_no_check</emphasis>, send
+<function>XIM_CONNECT_REPLY</function>
+-&gt; connect
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server_wait1</emphasis>:</term>
+ <listitem>
+ <para>
+Receive
+<function>XIM_AUTH_REPLY</function>
+-&gt; <emphasis remap='I'>server2</emphasis>
+ </para>
+ <para>
+Receive
+<function>XIM_AUTH_NEXT</function>
+-&gt; <emphasis remap='I'>server_more</emphasis>
+ </para>
+ <para>
+Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server_more</emphasis></term>
+ <listitem>
+ <para>
+Send
+<function>XIM_AUTH_REQUIRED</function>
+-&gt; <emphasis remap='I'>server_wait1</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server2</emphasis></term>
+ <listitem>
+ <para>
+If <emphasis remap='I'>server_ask</emphasis>, send
+<function>XIM_AUTH_SETUP</function>
+-&gt; <emphasis remap='I'>server_wait2</emphasis>
+ </para>
+ <para>
+If <emphasis remap='I'>server_no_check</emphasis>, send
+<function>XIM_CONNECT_REPLY </function>
+-&gt; connect
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server_wait2</emphasis></term>
+ <listitem>
+ <para>
+Receive
+<function>XIM_AUTH_REQUIRED</function>
+-&gt; <emphasis remap='I'>server_check</emphasis>
+ </para>
+ <para>
+Receive &lt;other&gt; -&gt; <emphasis remap='I'>server_NG</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server_check</emphasis></term>
+ <listitem>
+ <para>
+If no more auth data, send
+<function>XIM_CONNECT_REPLY</function>
+-&gt; connect
+ </para>
+ <para>
+If bad auth data, send
+<function>XIM_AUTH_NG</function>
+-&gt; give up on this protocol
+ </para>
+ <para>
+If good auth data, send
+<function>XIM_AUTH_NEXT</function>
+-&gt; <emphasis remap='I'>server_wait2</emphasis>
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term><emphasis remap='I'>server_NG</emphasis></term>
+ <listitem>
+ <para>
+Send
+<function>XIM_AUTH_NG</function>
+-&gt; give up on this protocol
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+<function>XIM_DISCONNECT </function>
+message requests to shutdown the connection over a mutually-understood
+virtual stream.
+</para>
+
+<para>
+XIM_DISCONNECT (IM library -&gt; IM Server)
+</para>
+
+<para>
+<function>XIM_DISCONNECT</function>
+is a synchronous request. The IM library should wait until it receives
+either an
+<function>XIM_DISCONNECT_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<para>
+XIM_DISCONNECT_REPLY (IM Server -&gt; IM library)
+</para>
+
+<para>
+<function>XIM_OPEN</function>
+requests to establish a logical connection between the IM library and the IM
+Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_OPEN (IM library -&gt; IM Server)
+ n STR locale name
+ p unused, p = Pad(n)
+</literallayout>
+
+<para>
+<function>XIM_OPEN</function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_OPEN_REPLY</function>
+packet or an <function>XIM_ERROR </function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_OPEN_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 n byte length of IM attributes supported
+ n LISTofXIMATTR IM attributes supported
+ 2 m byte length of IC attributes supported
+ 2 CARD16 unused
+ m LISTofXICATTR IC attributes supported
+</literallayout>
+
+<para>
+<function>XIM_OPEN_REPLY</function>
+message returns all supported IM and IC attributes in LISTofXIMATTR and
+LISTofXICATTR. These IM and IC attribute IDs are used to reduce the amount
+of data which must be transferred via the network. In addition, this
+indicates to the IM library what kinds of IM/IC attributes can be used
+in this session, and what types of data will be exchanged. This allows
+the IM Server provider and application writer to support IM system
+enhancements with new IM/IC attributes, without modifying Xlib.
+The IC value for the separator of NestedList must be included in the
+LISTofXICATTR.
+</para>
+
+<para>
+<function>XIM_CLOSE </function>
+message requests to shutdown the logical connection between the IM library
+and the IM Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_CLOSE (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 unused
+</literallayout>
+
+<para>
+<function>XIM_CLOSE</function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_CLOSE_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_CLOSE_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 unused
+</literallayout>
+
+</sect2>
+
+<sect2 id="event_flow_control_2">
+<title>Event Flow Control</title>
+<!-- .XS -->
+<!-- (SN Event Flow Control -->
+<!-- .XE -->
+<para>
+<!-- .LP -->
+An IM Server must send
+<function>XIM_SET_EVENT_MASK </function>
+message to the IM library in order for events to be forwarded to the IM
+Server, since the IM library initially doesn't forward any events to the
+IM Server. In the protocol, the IM Server will specify masks of X events
+to be forwarded and which need to be synchronized by the IM library.
+</para>
+
+<literallayout class="monospaced">
+XIM_SET_EVENT_MASK (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 EVENTMASK forward-event-mask (*1)
+ 4 EVENTMASK synchronous-event-mask (*2)
+
+(*1) Specify all the events to be forwarded to the IM Server by the IM library.
+(*2) Specify the events to be forwarded with synchronous flag on by the IM library.
+</literallayout>
+
+<para>
+<function>XIM_SET_EVENT_MASK </function>
+is an asynchronous request. The event masks are valid immediately after
+they are set until changed by another
+<function>XIM_SET_EVENT_MASK</function>
+message. If input-context-ID is set to zero, the default value of the
+input-method-ID will be changed to the event masks specified in the request.
+That value will be used for the IC's which have no individual values.
+</para>
+
+<para>
+Using the Dynamic Event Flow model, an IM Server sends
+<function>XIM_REGISTER_TRIGGERKEYS </function>
+message to the IM library before sending
+<function>XIM_OPEN_REPLY</function>
+message.
+Or the IM library may suppose that the IM Server uses the Static Event Flow
+model.
+</para>
+
+<literallayout class="monospaced">
+XIM_REGISTER_TRIGGERKEYS (IM Server -&gt; IM library)
+<!-- .sp 6p -->
+ 2 CARD16 input-method-ID
+ 2 unused
+ 4 n byte length of on-keys
+ n LISTofXIMTRIGGERKEY on-keys list
+ 4 m byte length of off-keys
+ m LISTofXIMTRIGGERKEY off-keys list
+</literallayout>
+
+<para>
+<function>XIM_REGISTER_TRIGGERKEYS</function>
+is an asynchronous request.
+The IM Server notifys the IM library of on-keys and off-keys lists with
+this message.
+</para>
+
+<para>
+The IM library notifys the IM Server with
+<function>XIM_TRIGGER_NOTIFY </function>
+message that a key event matching either on-keys or off-keys has been occurred.
+</para>
+
+<literallayout class="monospaced">
+XIM_TRIGGER_NOTIFY (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 CARD32 flag
+ #0 on-keys list
+ #1 off-keys list
+ 4 CARD32 index of keys list
+ 4 EVENTMASK client-select-event-mask (*1)
+
+(*1) Specify the events currently selected by the IM library with XSelectInput.
+
+</literallayout>
+
+<para>
+<function>XIM_TRIGGER_NOTIFY </function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_TRIGGER_NOTIFY_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_TRIGGER_NOTIFY_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect2>
+
+<sect2 id="Encoding_Negotiation">
+<title>Encoding Negotiation</title>
+<para>
+<function>XIM_ENCODING_NEGOTIATION</function>
+message requests to decide which encoding to be sent across the wire.
+When the negotiation fails, the fallback default encoding is Portable
+Character Encoding.
+</para>
+
+<literallayout class="monospaced">
+XIM_ENCODING_NEGOTIATION (IM library -&gt; IM Server).sp 6p
+ 2 CARD16 input-method-ID
+ 2 n byte length of encodings listed by name
+ n LISTofSTR list of encodings supported in the IM library.
+ p unused, p = Pad(n)
+ 2 m byte length of encodings listed by detailed data
+ 2 unused
+ m LISTofENCODINGINFO list of encordings supported in the IM library
+</literallayout>
+
+<para>
+The IM Server must choose one encoding from the list sent by the IM library.
+If index of the encording determined is -1 to indicate that the negotiation
+is failed, the fallback default encoding is used.
+The message must be issued after sending
+<function>XIM_OPEN</function> message via XOpenIM().
+The name of encoding may be registered with X Consortium.
+</para>
+
+<para>
+<function>XIM_ENCODING_NEGOTIATION</function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_ENCODING_NEGOTIATION_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_ENCODING_NEGOTIATION_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 category of the encoding determined.
+ #0 name
+ #1 detailed data
+ 2 INT16 index of the encoding determinated.
+ 2 unused
+</literallayout>
+
+</sect2>
+
+<sect2 id="Query_the_supported_extension_protocol_list">
+<title>Query the supported extension protocol list</title>
+<para>
+<function>XIM_QUERY_EXTENSION</function>
+message requests to query the IM extensions supported by the IM Server to
+which the client is being connected.
+</para>
+
+<literallayout class="monospaced">
+XIM_QUERY_EXTENSION (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 n byte length of extensions supported by the IM library
+ n LISTofSTR extensions supported by the IM library
+ p unused, p = Pad(n)
+</literallayout>
+
+<para>
+An example of a supported extension is FrontEnd.
+The message must be issued after sending
+<function>XIM_OPEN </function> message via XOpenIM().
+</para>
+
+<para>
+If n is 0, the IM library queries the IM Server for all extensions.
+</para>
+
+<para>
+If n is not 0, the IM library queries whether the IM Server supports the
+contents specified in the list.
+</para>
+
+<para>
+If a client uses an extension request without previously having issued a
+<function>XIM_QUERY_EXTENSION</function>
+message for that extension, the IM Server responds with a
+<function>BadProtocol</function>
+error. If the IM Server encounters a request with an unknown MAJOR-OPCODE
+or MINOR-OPCODE, it responds with a
+<function>BadProtocol</function> error.
+</para>
+
+<para>
+<function>XIM_QUERY_EXTENSION</function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_QUERY_EXTENSION_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_QUERY_EXTENSION_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 n byte length of extensions supported by both the IM library and the IM Server
+ n LISTofEXT list of extensions supported by both the IM library and the IM Server
+
+</literallayout>
+
+<para>
+<function>XIM_QUERY_EXTENSION_REPLY</function>
+message returns the list of extensions supported by both the IM library and
+the IM Server. If the list passed in
+<function>XIM_QUERY_EXTENSION</function>
+message is NULL, the IM Server returns the full list of extensions supported
+by the IM Server. If the list is not NULL, the IM Server returns the
+extensions in the list that are supported by the IM Server.
+</para>
+
+<para>
+<!-- .LP -->
+A zero-length string is not a valid extension name. The IM library should
+disregard any zero-length strings that are returned in the extension list.
+The IM library does not use the requests which are not supported by the IM
+Server.
+</para>
+
+</sect2>
+
+<sect2 id="Setting_IM_Values">
+<title>Setting IM Values</title>
+<para>
+<function>XIM_SET_IM_VALUES </function>
+requests to set attributes to the IM.
+</para>
+
+<literallayout class="monospaced">
+XIM_SET_IM_VALUES (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 n byte length of im-attribute
+ n LISTofXIMATTRIBUTE im-attributes
+</literallayout>
+
+<para>
+The im-attributes in
+<function>XIM_SET_IM_VALUES</function>
+message are specified as a LISTofXIMATTRIBUTE, specifying the attributes
+to be set. Attributes other than the ones returned by
+<function>XIM_OPEN_REPLY</function>
+message should not be specified.
+</para>
+
+<para>
+<function>XIM_SET_IM_VALUES </function>
+is a synchronous request. The IM library should wait until receiving
+either an
+<function>XIM_SET_IM_VALUES_REPLY</function>
+packet or an
+<function>XIM_ERROR</function>
+packet, because it must receive the error attribute if
+<function>XIM_ERROR</function> message is returned.
+</para>
+
+<literallayout class="monospaced">
+XIM_SET_IM_VALUES_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 unused
+</literallayout>
+
+<para>
+<function>XIM_SET_IM_VALUES_REPLY</function>
+message returns the input-method-ID to distinguish replies from multiple IMs.
+</para>
+
+</sect2>
+<sect2 id="Getting_IM_Values">
+<title>Getting IM Values</title>
+<para>
+<function>XIM_GET_IM_VALUES </function>
+requests to query IM values supported by the IM Server currently being
+connected.
+</para>
+
+<literallayout class="monospaced">
+XIM_GET_IM_VALUES (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 n byte length of im-attribute-id
+ n LISTofCARD16 im-attribute-id
+ p unused, p=Pad(n)
+</literallayout>
+
+<para>
+<function>XIM_GET_IM_VALUES</function>
+is a synchronous request. The IM library should wait until it receives
+either an
+<function>XIM_GET_IM_VALUES_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_GET_IM_VALUES_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 n byte length of im-attributes returned
+ n LISTofXIMATTRIBUTE im-attributes returned
+</literallayout>
+
+<para>
+The IM Server returns IM values with
+<function>XIM_GET_IM_VALUES_REPLY</function>
+message. The order of the returned im-attribute values corresponds directly
+to that of the list passed with the
+<function>XIM_GET_IM_VALUES</function> message.
+</para>
+
+</sect2>
+<sect2 id="Creating_an_IC">
+<title>Creating an IC</title>
+<para>
+<function>XIM_CREATE_IC</function> message requests to create an IC.
+</para>
+
+<literallayout class="monospaced">
+XIM_CREATE_IC (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 n byte length of ic-attributes
+ n LISTofXICATTRIBUTE ic-attributes
+</literallayout>
+
+<para>
+The input-context-id is specified by the IM Server to identify the client
+(IC). (It is not specified by the client in
+<function>XIM_CREATE_IC</function>
+message.), and it should not be set to zero.
+</para>
+
+<para>
+<function>XIM_CREATE_IC</function>
+is a synchronous request which returns the input-context-ID.
+The IM library should wait until it receives either an
+<function>XIM_CREATE_IC_REPLY</function>
+packet or an
+<function>XIM_ERROR</function>
+packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_CREATE_IC_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect2>
+<sect2 id="Destroying_the_IC">
+<title>Destroying the IC</title>
+<para>
+<function>XIM_DESTROY_IC</function>
+message requests to destroy the IC.
+</para>
+
+<literallayout class="monospaced">
+XIM_DESTROY_IC (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+<function>XIM_DESTROY_IC </function>
+is a synchronous request. The IM library should not free its resources
+until it receives an
+<function>XIM_DESTROY_IC_REPLY</function>
+message because <function>XIM_DESTROY_IC</function>
+message may result in Callback packets such as
+<function>XIM_PREEDIT_DRAW</function>
+and <function>XIM_PREEDIT_DONE.</function>
+</para>
+
+<literallayout class="monospaced">
+XIM_DESTROY_IC_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect2>
+
+<sect2 id="Setting_IC_Values">
+<title>Setting IC Values</title>
+<para>
+<function>XIM_SET_IC_VALUES</function>
+messages requests to set attributes to the IC.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_SET_IC_VALUES (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 n byte length of ic-attributes
+ 2 unused
+ n LISTofXICATTRIBUTE ic-attributes
+</literallayout>
+
+<para>
+The ic-attributes in
+<function>XIM_SET_IC_VALUES</function>
+message are specified as a LISTofXICATTRIBUTE, specifying the attributes
+to be set. Attributes other than the ones returned by
+<function>XIM_OPEN_REPLY</function> message should not be specified.
+</para>
+
+<para>
+<function>XIM_SET_IC_VALUES </function>
+is a synchronous request. The IM library should wait until receiving
+either an <function>XIM_SET_IC_VALUES_REPLY </function>
+packet or an <function>XIM_ERROR</function>
+packet, because it must receive the error attribute if
+<function>XIM_ERROR</function> message is returned.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_SET_IC_VALUES_REPLY (IM Server -&gt; IM library)
+<!-- .sp 6p -->
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect2>
+<sect2 id="Getting_IC_Values">
+<title>Getting IC Values</title>
+<para>
+<function>XIM_GET_IC_VALUES</function>
+message requests to query IC values supported by the IM Server currently
+being connected.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_GET_IC_VALUES (IM library -&gt; IM Server)
+<!-- .sp 6p -->
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 n byte length of ic-attribute-id
+ n LISTofCARD16 ic-attribute-id
+ p unused, p=Pad(2+n)
+</literallayout>
+
+<para>
+In LISTofCARD16, the appearance of the ic-attribute-id for the separator
+of NestedList shows the end of the heading nested list.
+</para>
+
+<para>
+<function>XIM_GET_IC_VALUES</function>
+is a synchronous request and returns each attribute with its values to
+show the correspondence. The IM library should wait until receiving
+either an <function>XIM_GET_IC_VALUES_REPLY</function>
+packet or an <function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_GET_IC_VALUES_REPLY (IM Server -&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 n byte length of ic-attribute
+ 2 unused
+ n LISTofXICATTRIBUTE ic-attribute
+</literallayout>
+
+</sect2>
+<sect2 id="Setting_IC_Focus">
+<title>Setting IC Focus</title>
+<para>
+<function>XIM_SET_IC_FOCUS</function>
+message requests to set the focus to the IC.
+</para>
+
+<literallayout class="monospaced">
+XIM_SET_IC_FOCUS (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+<function>XIM_SET_IC_FOCUS</function> is an asynchronous request.
+</para>
+
+</sect2>
+<sect2 id="Unsetting_IC_Focus">
+<title>Unsetting IC Focus</title>
+<para>
+<function>XIM_UNSET_IC_FOCUS</function>
+message requests to unset the focus to the focused IC.
+</para>
+
+<literallayout class="monospaced">
+XIM_UNSET_IC_FOCUS (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+<function>XIM_UNSET_IC_FOCUS</function>
+is an asynchronous request.
+</para>
+
+</sect2>
+
+<sect2 id="filtering_events">
+<title>Filtering Events</title>
+<para>
+Event filtering is mainly provided for BackEnd method to allow input method
+to capture X events transparently to clients.
+</para>
+
+<para>
+X Events are forwarded by
+<function>XIM_FORWARD_EVENT</function> message.
+This message can be operated both synchronously and asynchronously.
+If the requester sets the synchronous flag, the receiver must send
+<function>XIM_SYNC_REPLY</function>
+message back to the requester when all the data processing is done.
+</para>
+<para>
+Protocol flow of BackEnd model
+</para>
+
+<para>
+With BackEnd method, the protocol flow can be classified into two
+methods in terms of synchronization, depending on the synchronous-eventmask
+of <function>XIM_SET_EVENT_MASK</function>
+message. One can be called on-demand-synchronous method and another
+can be called as full-synchronous method.
+</para>
+
+<para>
+In on-demand-synchronous method, the IM library always receives
+<function>XIM_FORWARD_EVENT</function>
+or
+<function>XIM_COMMIT</function>
+message as a synchronous request. Also, the IM Server needs to synchronously
+process the correspondent reply from the IM library and the following
+<function>XIM_FORWARD_EVENT</function>
+message sent from the IM library when any of the event causes the IM Server
+to send
+<function>XIM_FORWARD_EVENT</function>
+or
+<function>XIM_COMMIT</function>
+message to the IM library, so that the input service is consistent. If the
+IM library gets the control back from the application after receiving the
+synchronous request, the IM library replies for the synchronous request before
+processing any of the events. In this time, the IM Server blocks
+<function>XIM_FORWARD_EVENT</function>
+message which is sent by the IM library, and handles it after receiving the
+reply. However, the IM Server handles the other protocols at any time.
+</para>
+
+<para>
+In full-synchronous method, the IM library always sends
+<function>XIM_FORWARD_EVENT</function>
+message to the IM Server as a synchronous request. Therefore, the reply to it
+from the IM Server will be put between the
+<function>XIM_FORWARD_EVENT</function> message and its
+<function>XIM_SYNC_REPLY</function> message. In case of sending
+<function>XIM_FORWARD_EVENT</function> or
+<function>XIM_COMMIT</function>
+message, the IM Server should set the synchronous flag off. Because the
+synchronization can be done by the following
+<function>XIM_SYNC_REPLY</function> message.
+</para>
+
+<para>
+Following chart shows one of the simplest protocol flow which only
+deals with keyevents for preediting operation.
+</para>
+
+<mediaobject id="sampleprotocolflow">
+ <imageobject>
+ <imagedata format="SVG" fileref="sampleprotocolflow1.svg"/>
+ </imageobject>
+ <caption>Sample Protocol Flow</caption>
+</mediaobject>
+
+
+<para>
+Following chart shows one of the complex protocol flow, which deals
+with multiple focus windows and button press event as well as keyevent,
+and the focus is moved by the application triggered by both of keyevent
+and button press event.
+</para>
+<mediaobject id="sampleprotocolflow2">
+ <imageobject>
+ <imagedata format="SVG" fileref="sampleprotocolflow2.svg"/>
+ </imageobject>
+ <caption>Sample Protocol Flow 2</caption>
+</mediaobject>
+
+<literallayout class="monospaced">
+XIM_FORWARD_EVENT (IM library &lt;--&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 BITMASK16 flag
+ #0001 synchronous
+ #0002 request filtering (*1)
+ #0004 request lookupstring (*2)
+ 2 CARD16 serial number
+ XEVENT X event
+
+(*1) Indicate the receiver should filter events and possible preedit may be invoked.
+
+(*2) Indicate the receiver should only do lookup string. The IM Server is expected
+to just do a conversion of the key event to the best candidate. This bit may
+affect the state of the preedit state (e.g. compose of dead key sequences).
+</literallayout>
+
+<para>
+XEVENT format is same as the X Protocol event format(xEvent).
+As the value of xEvent's sequenceNumber is the bottom of 16 bit of XEvent's
+xany.serial, the top of 16 bit is sent by serial number(INT16).
+</para>
+
+<para>
+<function>XIM_FORWARD_EVENT</function>
+message is used for forwarding the events from the IM library to the IM Server
+in order for IM to be able to filter the event. On the other hand, this
+message is also used for forwarding the events from the IM Server to the IM
+library if the event forwarded from the IM library is not filtered.
+The IM Server, which receives
+<function>XIM_FORWARD_EVENT</function>
+message without synchronous bit, should set synchronous bit.
+If both "request event filtering" and "request lookupstring" flag are
+set, then both filtering and lookup should be done for the same event.
+</para>
+
+</sect2>
+
+<sect2 id="Synchronizing_with_the_IM_Server">
+<title>Synchronizing with the IM Server</title>
+
+<para>
+<function>XIM_SYNC</function>
+message requests to synchronize the IM library and the IM Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_SYNC (IM library &lt;--&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+This synchronization can be started either on the IM library side or on the
+IM Server side. The side which receives
+<function>XIM_SYNC</function>
+message should process all XIM requests before replying. The input-context-ID
+is necessary to distinguish the IC with which the IM library and the IM
+Server are synchronized.
+</para>
+
+<literallayout class="monospaced">
+XIM_SYNC_REPLY (IM Server &lt;--&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+
+
+<para>
+The side which receives
+<function>XIM_FORWARD_EVENT, </function>
+<function>XIM_COMMIT</function>
+or any other message with synchronous bit, should process all XIM request
+before replying, and send
+<function>XIM_SYNC_REPLY</function>
+message as the reply to the previous message.
+</para>
+
+</sect2>
+
+<sect2 id="Sending_a_committed_string">
+<title>Sending a committed string</title>
+<para>
+When the IM Server commits a string, the IM Server sends either the committed
+string or list of KeySym, or both, by
+<function>XIM_COMMIT</function>
+message.
+</para>
+
+<literallayout class="monospaced">
+XIM_COMMIT (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 BITMASK16 flag
+ #0001 synchronous
+ #0002 XLookupChars
+ #0004 XLookupKeySym
+ #0006 XLookupBoth = XLookupChars | XLookupKeySym
+</literallayout>
+
+<para>
+If flag is XLookupKeySym, the arguments continue as follows:
+</para>
+
+<literallayout class="monospaced">
+ 2 unused
+ 4 KEYSYM KeySym
+</literallayout>
+
+<para>
+If flag is XLookupChars, the arguments continue as follows
+</para>
+
+<literallayout class="monospaced">
+ 2 m byte length of committed string
+ m LISTofBYTE committed string
+ p unused, p = Pad(m)
+</literallayout>
+
+<para>
+If flag is XLookupBoth, the arguments continue as follows
+</para>
+
+<literallayout class="monospaced">
+ 2 unused
+ 4 KEYSYM KeySym
+ 2 n byte length of committed string
+ n LISTofBYTE committed string
+ p unused, p = Pad(2+n)
+</literallayout>
+
+<para>
+The IM Server which receives
+<function>XIM_COMMIT</function>
+message without synchronous bit should set synchronous bit.
+</para>
+
+</sect2>
+
+<sect2 id="Reset_IC">
+<title>Reset IC</title>
+<para>
+<function>XIM_RESET_IC</function>
+message requests to reset the status of IC in the IM Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_RESET_IC (IM library -&gt; IM Server)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+
+<para>
+<function>XIM_RESET_IC</function>
+is a synchronous request. The IM library should wait until receiving either an
+<function>XIM_RESET_IC_REPLY</function> packet or an
+<function>XIM_ERROR</function> packet.
+</para>
+
+<literallayout class="monospaced">
+XIM_RESET_IC_REPLY (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 n byte length of preedit string
+ n LISTofBYTE preedit string
+ p unused, p = Pad(2+n)
+</literallayout>
+
+<para>
+<function>XIM_RESET_IC_REPLY </function>
+message returns the input-context-ID to distinguish replies from multiple ICs.
+</para>
+
+</sect2>
+<sect2 id="Callbacks">
+<title>Callbacks</title>
+<para>
+If XIMStyle has XIMPreeditArea or XIMStatusArea set, XIMGeometryCallback
+may be used, and if XIMPreeditCallback and/or XIMStatusCallback are set,
+corresponding callbacks may be used.
+</para>
+
+<para>
+Any callback request may be sent from an IM Server to an IM client
+asynchronously in response to any request previously sent by the IM client
+to the IM Server.
+</para>
+
+<para>
+When an IM Server needs to send a callback request synchronously with
+the request previously sent by an IM client, the IM Server sends it
+before replying to the previous request.
+</para>
+
+<sect3 id="Negotiating_geometry">
+<title>Negotiating geometry</title>
+<para>
+The IM Server sends
+<function>XIM_GEOMETRY </function>
+message to start geometry negotiation, if XIMStyle has XIMPreeditArea or
+XIMStatusArea set.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_GEOMETRY (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+There is always a single Focus Window, even if some input fields have only
+one IC.
+</para>
+
+</sect3>
+
+<sect3 id="Converting_a_string">
+<title>Converting a string</title>
+
+<literallayout class="monospaced">
+XIM_STR_CONVERSION (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 CARD16 XIMStringConversionPosition
+ 2 unused
+ 4 CARD32 XIMCaretDirection
+ #0 XIMForwardChar
+ #1 XIMBackwardChar
+ #2 XIMForwardWord
+ #3 XIMBackwardWord
+ #4 XIMCaretUp
+ #5 XIMCaretDown
+ #6 XIMNextLine
+ #7 XIMCPreviousLine
+ #8 XIMLineStart
+ #9 XIMLineEnd
+ #10 XIMAbsolutePosition
+ #11 XIMDontChange
+ 2 CARD16 factor
+ 2 CARD16 XIMStringConversionOperation
+ #0001 XIMStringConversionSubstitution
+ #0002 XIMStringConversionRetrieval
+ 2 INT16 byte length to multiply the XIMStringConversionType
+</literallayout>
+
+<para>
+<function>XIM_STR_CONVERSION </function>
+message may be used to start the string conversion from the IM Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_STR_CONVERSION_REPLY (IM library -&gt; IM Server)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 CARD32 XIMStringConversionFeedback
+ XIMSTRCONVTEXT XIMStringConversionText
+</literallayout>
+
+<para>
+<function>XIM_STR_CONVERSION_REPLY </function>
+message returns the string to be converted and the feedback information array.
+</para>
+</sect3>
+
+<sect3 id="Preedit_Callbacks">
+<title>Preedit Callbacks</title>
+
+<para>
+The IM Server sends
+<function>XIM_PREEDIT_START </function>
+message to call the XIMPreeditStartCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_START (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+The reply to this message must be sent synchronously. The reply forwards
+the return value from the callback function to the IM Server.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_START_REPLY (IM library -&gt; IM Server)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 INT32 return value
+</literallayout>
+
+<para>
+<function>XIM_PREEDIT_START_REPLY</function>
+message returns the input-context-ID to distinguish replies from multiple
+IC's. The return value contains the return value of the function
+XIMPreeditStartCallback.
+</para>
+
+<para>
+The IM Server sends
+<function>XIM_PREEDIT_DRAW </function>
+message to call the XIMPreeditDrawCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_DRAW (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 INT32 caret
+ 4 INT32 chg_first
+ 4 INT32 chg_length
+ 4 BITMASK32 status
+ #x0000001 no string
+ #x0000002 no feedback
+ 2 n length of preedit string
+ n STRING8 preedit string
+ p unused, p = Pad(2+n)
+ 2 m byte length of feedback array
+ 2 unused
+ m LISTofXIMFEEDBACK feedback array
+</literallayout>
+
+<para>
+The fields "caret", "chg_first" and "chg_length" correspond to the
+fields of XIMPreeditDrawCallbackStruct.
+When the "no string" bit of the status field is set, the text field of
+XIMPreeditDrawCallbackStruct is NULL.
+When the "no feedback" bit of the status field is set, the text feedback
+field of XIMPreeditDrawCallbackStruct is NULL.
+When the above bits are not set, "preedit string" contains the preedit
+string to be displayed, and the feedback array contains feedback information.
+</para>
+
+<para>
+The IM Server sends
+<function>XIM_PREEDIT_CARET</function>
+message to call the PreeditCaretCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_CARET (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 INT32 position
+ 4 CARD32 direction
+ #0 XIMForwardChar
+ #1 XIMBackwardChar
+ #2 XIMForwardWord
+ #3 XIMBackwardWord
+ #4 XIMCaretUp
+ #5 XIMCaretDown
+ #6 XIMNextLine
+ #7 XIMCPreviousLine
+ #8 XIMLineStart
+ #9 XIMLineEnd
+ #10 XIMAbsolutePosition
+ #11 XIMDontChange
+ 4 CARD32 style
+ #0 XIMInvisible
+ #1 XIMCPrimary
+ #2 XIMSecondary
+</literallayout>
+
+<para>
+Each entry corresponds to a field of XIMPreeditCaretCallbackStruct.
+Since this callback sets the caret position, its reply must be sent
+synchronously.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_CARET_REPLY (IM library -&gt; IM Server)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 CARD32 position
+</literallayout>
+
+<para>
+The position is the value returned by the callback function after it
+has been called.
+</para>
+
+<para>
+The IM Server sends
+<function>XIM_PREEDIT_DONE </function>
+message to call the XIMPreeditDoneCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_PREEDIT_DONE (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect3>
+
+<sect3 id="Preedit_state_notify">
+<title>Preedit state notify</title>
+
+<literallayout class="monospaced">
+XIM_PREEDITSTATE (IM Server -&gt; IM Library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 BITMASK32 XIMPreeditState
+ #x0000000 XIMPreeditUnknown
+ #x0000001 XIMPreeditEnable
+ #x0000002 XIMPreeditDisable
+</literallayout>
+
+<para>
+<function>XIM_PREEDITSTATE</function>
+message is used to call the XIMPreeditStateNotifyCallback function.
+</para>
+
+</sect3>
+
+<sect3 id="Status_Callbacks">
+<title>Status Callbacks</title>
+
+<para>
+The IM Server sends
+<function>XIM_STATUS_START </function>
+message to call the XIMStatusStartCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_STATUS_START (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+<para>
+The IM Server sends
+<function>XIM_STATUS_DRAW </function>
+message to call the XIMStatusDrawCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_STATUS_DRAW (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 CARD32 type
+ #0 XIMTextType
+ #1 XIMBitmapType
+</literallayout>
+
+<para>
+If type is XIMTextType, the arguments continue as follows.
+</para>
+
+<literallayout class="monospaced">
+ 4 BITMASK32 status
+ #x0000001 no string
+ #x0000002 no feedback
+ 2 n length of status string
+ n STRING8 status string
+ p unused, p = Pad(2+n)
+ 2 m byte length of feedback array
+ 2 unused
+ m LISTofXIMFEEDBACK feedback array
+</literallayout>
+
+<para>
+If type is XIMBitmapType, the arguments continue as follows.
+</para>
+
+<literallayout class="monospaced">
+ 4 PIXMAP pixmap data
+</literallayout>
+
+<para>
+The field "type" corresponds to the field in XIMStatusDrawCallbackStruct.
+</para>
+
+<para>
+The IM Server sends
+<function>XIM_STATUS_DONE </function>
+message to call the XIMStatusDoneCallback function.
+</para>
+
+<literallayout class="monospaced">
+XIM_STATUS_DONE (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+</literallayout>
+
+</sect3>
+</sect2>
+</sect1>
+
+<sect1 id="Acknowledgements">
+<title>Acknowledgements</title>
+<para>
+This document represents the culmination of several years of debate and
+experiments done under the auspices of the MIT X Consortium i18n working
+group. Although this was a group effort, the author remains responsible
+for any errors or omissions.
+</para>
+
+<para>
+We would like to thank to all members of this group.
+And we would like to make special thanks to the following people
+(in alphabetical order) for their participation in the IM Protocol
+design,
+Hector Chan, Takashi Fujiwara, Yoshio Horiuchi, Makoto Inada,
+Hiromu Inukai, Mickael Kung, Seiji Kuwari, Franky Ling, Hiroyuki Machida,
+Hiroyuki Miyamoto, Frank Rojas, Bob Scheifler, Makiko Shimamura,
+Shoji Sugiyama, Hidetoshi Tajima, Masaki Takeuchi, Makoto Wakamatsu,
+Masaki Wakao, Nobuyuki Tanaka, Shigeru Yamada, Katsuhisa Yano, Jinsoo Yoon.
+</para>
+
+</sect1>
+
+<bibliography>
+<title>References</title>
+<biblioentry>
+ <title>X Window System Protocol Version 11</title>
+ <author><firstname>Robert W.</firstname><surname>Scheifler</surname></author>
+</biblioentry>
+
+<biblioentry>
+ <title>Xlib - C Language X Interface"</title>
+ <author><firstname>Robert W.</firstname><surname>Scheifler</surname></author>
+</biblioentry>
+</bibliography>
+
+<appendix id="common_extensions">
+<title>Common Extensions</title>
+<para>
+Extension opcodes and packet names (e.g.
+<function>XIM_EXT_SET_EVENT_MASK</function>
+) for additional extensions may be registered with X Consortium.
+The following is a commonly well-known extended packet.
+</para>
+
+<para>
+(1) Extension to manipulate the event handling\fP
+</para>
+
+<para>
+<!-- .LP -->
+<function>XIM_EXT_SET_EVENT_MASK </function>
+message specifies the set of event masks that the IM library should manipulate.
+</para>
+
+<literallayout class="monospaced">
+XIM_EXT_SET_EVENT_MASK (IM Server -&gt; IM library)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 4 EVENTMASK filter-event-mask (*1)
+ 4 EVENTMASK intercept-event-mask (*2)
+ 4 EVENTMASK select-event-mask (*3)
+ 4 EVENTMASK forward-event-mask (*4)
+ 4 EVENTMASK synchronous-event-mask (*5)
+
+ (*1) Specify the events to be neglected by the IM library via XFilterEvent.
+ (*2) Specify the events to be deselected by the IM library with XSelectInput.
+ (*3) Specify the events to be selected by the IM library with XSelectInput.
+ (*4) Specify all the events to be forwarded to the IM Server by the IM library.
+ (*5) Specify the events to be forwarded with synchronous flag on by the IM library.
+</literallayout>
+
+<para>
+<!-- .LP -->
+The IM library must reply
+<function>XIM_SYNC_REPLY</function>
+message to the IM Server. This request is valid after the ic is created.
+</para>
+
+<para>
+(2) Extension for improvement of performance.
+</para>
+<para>
+The following requests may be used for improvement of performance.
+</para>
+
+<para>
+<function>XIM_EXT_FORWARD_KEYEVENT</function>
+message may be used instead of
+<function>XIM_FORWARD_EVENT</function>
+message.
+</para>
+
+<literallayout class="monospaced">
+XIM_EXT_FORWARD_KEYEVENT (IM Server &lt;--&gt; IM library)
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 BITMASK16 flag
+ #0001 synchronous
+ 2 CARD16 sequence number
+ 1 BYTE xEvent.u.u.type
+ 1 BYTE keycode
+ 2 CARD16 state
+ 4 CARD32 time
+ 4 CARD32 window
+</literallayout>
+
+<para>
+<function>XIM_EXT_MOVE</function>
+message may be used to change the spot location instead of
+<function></function>
+XIM_SET_IC_VALUES
+message.
+It is effective only if the client specified XIMPreeditPosition.
+</para>
+
+
+<literallayout class="monospaced">
+XIM_EXT_MOVE (IM library -&gt; IM Server)
+
+ 2 CARD16 input-method-ID
+ 2 CARD16 input-context-ID
+ 2 INT16 X
+ 2 INT16 Y
+</literallayout>
+
+<para>
+<function>XIM_EXT_MOVE</function>
+message is a asynchronous request.
+</para>
+
+</appendix>
+<appendix id="transport_list">
+<title>Transport List</title>
+
+<para>
+The list of transport specific IM Server address format registered
+</para>
+
+<para>
+The following format represents the ATOM contained in
+<function>XIM_SERVERS</function>
+property and the string returned from the request converting
+selection target LOCALES and TRANSPORT.
+</para>
+<literallayout class="monospaced">
+ "{<emphasis remap='I'>category</emphasis>=[<emphasis remap='I'>value</emphasis>,...]}..."
+</literallayout>
+<para>
+The following categories are currently registered.
+</para>
+
+<literallayout class="monospaced">
+<function>server</function>;: IM Server name (used for XIM_SERVERS)
+<function>locale</function>;: XPG4 locale name (LOCALES)
+<function>transport</function>;: transport-specific name (TRANSPORT)
+</literallayout>
+
+<para>
+The preregistered formats for transport-specific names are as follows:
+</para>
+
+<para>
+<function>TCP/IP Names</function>
+</para>
+
+<para>
+The following syntax should be used for system internal domain names:
+</para>
+<literallayout class="monospaced">
+&lt;<emphasis remap='I'>local name</emphasis>&gt; ::= "local/"&lt;<emphasis remap='I'>hostname</emphasis>&gt;":"&lt;<emphasis remap='I'>pathname</emphasis>&gt;
+</literallayout>
+<para>
+Where &lt;<emphasis remap='I'>pathname</emphasis>&gt; is a path name of socket address.
+</para>
+
+<para>
+IM Server's name should be set to &lt;<emphasis remap='I'>pathname</emphasis>&gt; to run multiple IM Server
+at the same time
+</para>
+
+<para>
+The following syntax should be used for Internet domain names:
+</para>
+<literallayout class="monospaced">
+&lt;<emphasis remap='I'>TCP name</emphasis>&gt; ::= "tcp/"&lt;<emphasis remap='I'>hostname</emphasis>&gt;":"&lt;<emphasis remap='I'>ipportnumber</emphasis>&gt;
+</literallayout>
+<para>
+where &lt;<emphasis remap='I'>hostname</emphasis>&gt; is either symbolic (such as expo.lcs.mit.edu) or
+numeric decimal (such as 18.30.0.212). The &lt;<emphasis remap='I'>ipportnumber</emphasis>&gt; is the
+port on which the IM Server is listening for connections.
+For example:
+</para>
+<literallayout class="monospaced">
+tcp/expo.lcs.mit.edu:8012
+tcp/18.30.0.212:7890
+</literallayout>
+
+<para>
+<function>DECnet Names</function>
+</para>
+
+<para>
+The following syntax should be used for DECnet names:
+</para>
+<literallayout class="monospaced">
+&lt;<emphasis remap='I'>DECnet name</emphasis>&gt; ::= "decnet/"&lt;<emphasis remap='I'>nodename</emphasis>&gt;"::IMSERVER$"&lt;<emphasis remap='I'>objname</emphasis>&gt;
+</literallayout>
+<para>
+where &lt;<emphasis remap='I'>nodename</emphasis>&gt; is either
+symbolic (such as SRVNOD) or the numeric
+decimal form of the DECnet address (such as 44.70).
+The &lt;<emphasis remap='I'>objname</emphasis>&gt;
+is normal, case-insensitive DECnet object name. For example:
+</para>
+
+<literallayout class="monospaced">
+DECNET/SRVNOD::IMSERVER$DEFAULT
+decnet/44.70::IMSERVER$other
+</literallayout>
+
+<para>
+<function>X Names</function>
+</para>
+
+<para>
+The following syntax should be used for X names:
+</para>
+<literallayout class="monospaced">
+&lt;<emphasis remap='I'>X name</emphasis>&gt; ::= "X/"
+</literallayout>
+
+<para>
+If a given category has multiple values, the value is evaluated in order of
+setting.
+</para>
+
+</appendix>
+<appendix id="protocol_number">
+<title>Protocol Number</title>
+
+<para>
+<function>Major Protocol number</function>
+</para>
+
+<literallayout class="monospaced">
+XIM_CONNECT #001
+XIM_CONNECT_REPLY #002
+XIM_DISCONNECT #003
+XIM_DISCONNECT_REPLY #004
+
+XIM_AUTH_REQUIRED #010
+XIM_AUTH_REPLY #011
+XIM_AUTH_NEXT #012
+XIM_AUTH_SETUP #013
+XIM_AUTH_NG #014
+
+XIM_ERROR #020
+
+XIM_OPEN #030
+XIM_OPEN_REPLY #031
+XIM_CLOSE #032
+XIM_CLOSE_REPLY #033
+XIM_REGISTER_TRIGGERKEYS #034
+XIM_TRIGGER_NOTIFY #035
+XIM_TRIGGER_NOTIFY_REPLY #036
+XIM_SET_EVENT_MASK #037
+XIM_ENCODING_NEGOTIATION #038
+XIM_ENCODING_NEGOTIATION_REPLY #039
+XIM_QUERY_EXTENSION #040
+XIM_QUERY_EXTENSION_REPLY #041
+XIM_SET_IM_VALUES #042
+XIM_SET_IM_VALUES_REPLY #043
+XIM_GET_IM_VALUES #044
+XIM_GET_IM_VALUES_REPLY #045
+
+XIM_CREATE_IC #050
+XIM_CREATE_IC_REPLY #051
+XIM_DESTROY_IC #052
+XIM_DESTROY_IC_REPLY #053
+XIM_SET_IC_VALUES #054
+XIM_SET_IC_VALUES_REPLY #055
+XIM_GET_IC_VALUES #056
+XIM_GET_IC_VALUES_REPLY #057
+XIM_SET_IC_FOCUS #058
+XIM_UNSET_IC_FOCUS #059
+XIM_FORWARD_EVENT #060
+XIM_SYNC #061
+XIM_SYNC_REPLY #062
+XIM_COMMIT #063
+XIM_RESET_IC #064
+XIM_RESET_IC_REPLY #065
+
+XIM_GEOMETRY #070
+XIM_STR_CONVERSION #071
+XIM_STR_CONVERSION_REPLY #072
+XIM_PREEDIT_START #073
+XIM_PREEDIT_START_REPLY #074
+XIM_PREEDIT_DRAW #075
+XIM_PREEDIT_CARET #076
+XIM_PREEDIT_CARET_REPLY #077
+XIM_PREEDIT_DONE #078
+XIM_STATUS_START #079
+XIM_STATUS_DRAW #080
+XIM_STATUS_DONE #081
+XIM_PREEDITSTATE #082
+
+(*) The IM Server's extension protocol number should be more than #128.
+</literallayout>
+</appendix>
+
+<appendix id="implementation_tips">
+
+<title>Implementation Tips</title>
+<para>
+(1) FrontEnd Method
+</para>
+
+<para>
+FrontEnd method is recognized as a performance acceleration by the
+trade off of the variety of the reliability.
+</para>
+
+<para>
+In order to use the FrontEnd method, the IM library must query the IM
+Server to see if the FrontEnd extension is available. The query is
+made by using the
+<function>XIM_QUERY_EXTENSION</function>
+message. The IM Server may send
+<function>XIM_EXT_SET_EVENT_MASK</function>
+message with intercept-event-mask, forward-event-mask, and
+synchronous-event-mask values set after replying
+<function>XIM_QUERY_EXTENSION_REPLY</function>
+message.
+</para>
+
+<para>
+FrontEnd method can be implemented in a couple of ways depending on
+how the IM Server utilize
+<function>XIM_EXT_SET_EVENT_MASK</function>
+message.
+</para>
+
+<para>
+One approach is to update both of the input mask and the filter-event-mask
+depending on the preeidting state. The sample protocol sequence using the
+static event flow is as follows:
+</para>
+
+<mediaobject id="staticflow">
+ <imageobject>
+ <imagedata scale="75" format="SVG" fileref="staticflow.svg"/>
+ </imageobject>
+ <caption>The flow of events</caption>
+</mediaobject>
+
+<para>
+To pursuit a maximum performance regardless of the preediting mode,
+the IM Server may use the dynamic event flow with the following
+sample protocol sequence.
+</para>
+
+<mediaobject id="dynamicflow">
+ <imageobject>
+ <imagedata scale="75" format="SVG" fileref="dynamicflow.svg"/>
+ </imageobject>
+ <caption>The flow of events</caption>
+</mediaobject>
+
+<para>
+This method can reduce the XIM protocol traffic dramatically
+by updating intercept-event-mask and select-event-mask accordingly.
+The tradeoff of this performance improvement is that the key
+events may be lost or disordered in some particular situation, such as
+when the user types the keyboard in following sequence really fast:
+</para>
+
+<para>
+&lt;preediting on key&gt;"some strings"&lt;preediting off
+key&gt;"another string"
+</para>
+
+<para>
+Since this method requires the input mask updates to the both the IM Server
+and Xlib when turning on and off the preediting, and there is a time lag
+till the requests take effect when two client issues the input mask updates
+simultaneously.
+</para>
+
+<para>
+Another approach of the FrontEnd method is to update the filter-event-mask
+depending on the preediting state and not to update the input mask.
+The IM Server must register both of the preediting on key list and off key
+list by
+<function>XIM_REGISTER_TRIGGERKEYS</function>
+message.
+In this method, Both the IM Server and the IM client select the same
+events on the same client's window, so that the events are delivered
+to both of the IM Server and the client. The preediting on and off
+states are expressed by whether the key events are filtered or not.
+The sample protocol sequence are as follows:
+</para>
+
+<para>
+&lt;&lt;Using static event flow&gt;&gt;
+</para>
+
+<mediaobject id="staticflowsampleseq">
+ <imageobject>
+ <imagedata scale="75" format="SVG" fileref="staticflowsampleseq.svg"/>
+ </imageobject>
+ <caption>The flow of events</caption>
+</mediaobject>
+
+<para>
+&lt;&lt;Using the dynamic event flow&gt;&gt;
+</para>
+
+<mediaobject id="dynamicflowsampleseq">
+ <imageobject>
+ <imagedata scale="75" format="SVG" fileref="dynamicflowsampleseq.svg"/>
+ </imageobject>
+ <caption>The flow of events</caption>
+</mediaobject>
+
+<para>
+This method does not have the problem of the time lag when going across
+the preediting on and off mode, however, the amount of the performance
+acceleration is not as good as the method described above.
+</para>
+
+<para>
+In general, the FrontEnd method requires some synchronization to some
+of the X protocols, such as the ChangeWindowAttribute protocol for the
+event mask change or the GrabKey protocol, since it relies on the X's
+principal event dispatching mechanism. Any X protocol bindings do not
+consider the synchronization might cause some mis-synchronization
+between the IM clients and the IM Server.
+</para>
+
+<para>
+(2) Transport Layer
+</para>
+
+<para>
+The Xlib XIM implementation is layered into three functions, a protocol
+layer, an interface layer and a transport layer. The purpose of this
+layering is to make the protocol independent of transport implementation.
+Each function of these layers are:
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term>The protocol layer</term>
+ <listitem>
+ <para>
+implements overall function of XIM and calls the interface layer
+functions when it needs to communicate to IM Server.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>The interface layer</term>
+ <listitem>
+ <para>
+separates the implementation of the transport layer from the protocol
+layer, in other words, it provides implementation independent hook for
+the transport layer functions.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>The transport layer</term>
+ <listitem>
+ <para>
+handles actual data communication with IM Server. It is done by a set
+of several functions named transporters.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+The interface layer and the transport layer make various communication
+channels usable such as X Protocol, TCP/IP, DECnet or STREAM.
+The following is a sample implementation for the transporter using
+the X connection.
+Refer to "xtrans" for the transporter using Socket Transport. <!-- xref ?-->
+</para>
+
+<para>
+At the beginning of the X Transport connection for the XIM transport
+mechanism, two different windows must be created either in an Xlib XIM
+or in an IM Server, with which the Xlib and the IM Server exchange the
+XIM transports by using the ClientMessage events and Window Properties.
+In the following, the window created by the Xlib is referred as the
+"client communication window", and on the other hand, the window created
+by the IM Server is referred as the "IMS communication window".
+</para>
+
+<para>
+Connection
+</para>
+
+<para>
+In order to establish a connection, a communication window is created.
+A ClientMessage in the following event's format is sent to the owner
+window of XIM_SERVER selection, which the IM Server has created.
+</para>
+
+<para>
+Refer to "The Input Method Protocol" for the XIM_SERVER atom. <!-- xref -->
+</para>
+
+<table frame="none" id="clientmessage_sent_to_the_ims_window">
+<title>The ClientMessage sent to the IMS window.</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Structure Member</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>IMS Window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_XCONNECT", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>32</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[0]</entry>
+ <entry>client communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[1]</entry>
+ <entry>client-major-transport-version (*1)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[2]</entry>
+ <entry>client-major-transport-version (*1)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+In order to establish the connection (to notify the IM Server communication
+window), the IM Server sends a ClientMessage in the following event's
+format to the client communication window.
+</para>
+
+<table frame="none" id="clientmessage_sent_by_the_im_server">
+<title>The ClientMessage sent by the IM Server.</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Structure Member</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>client communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_XCONNECT", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>32</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[0]</entry>
+ <entry>IMS communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[1]</entry>
+ <entry>server-major-transport-version (*1)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[2]</entry>
+ <entry>server-minor-transport-version (*1)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[3]</entry>
+ <entry>dividing size between ClientMessage and Property (*2)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+(*1) major/minor-transport-version
+</para>
+<para>
+The read/write method is decided by the combination of
+major/minor-transport-version, as follows:
+</para>
+
+
+<table frame="all" id="readwrite_method_and_the_majorminor_transport_version">
+<title>The read/write method and the major/minor-transport-version</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="1"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3*" colsep="1"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Transport-version</entry>
+ <entry>read/write</entry>
+ </row>
+ <row>
+ <entry>major</entry>
+ <entry>minor</entry>
+ <entry></entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry morerows="2">0</entry>
+ <entry>0</entry>
+ <entry>only-CM &amp; Property-with-CM</entry>
+ </row>
+ <row rowsep="0">
+ <entry>1</entry>
+ <entry>only-CM &amp; multi-CM</entry>
+ </row>
+ <row rowsep="1">
+ <entry>2</entry>
+ <entry>only-CM &amp; multi-CM &amp; Property-with-CM</entry>
+ </row>
+ <row rowsep="1">
+ <entry>1</entry>
+ <entry>0</entry>
+ <entry>PropertyNotify</entry>
+ </row>
+ <row rowsep="0">
+ <entry morerows="1">2</entry>
+ <entry>0</entry>
+ <entry>only-CM &amp; PropertyNotify</entry>
+ </row>
+ <row>
+ <entry>1</entry>
+ <entry>only-CM &amp; multi-CM &amp; PropertyNotify</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<literallayout class="monospaced">
+only-CM : data is sent via a ClientMessage
+multi-CM : data is sent via multiple ClientMessages
+Property-with-CM : data is written in Property, and its Atom
+ is send via ClientMessage
+PropertyNotify : data is written in Property, and its Atom
+ is send via PropertyNotify
+
+</literallayout>
+
+<para>
+The method to decide major/minor-transport-version is as follows:
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+The client sends 0 as major/minor-transport-version to the IM Server.
+The client must support all methods in Table D-3.
+The client may send another number as major/minor-transport-version to
+use other method than the above in the future.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+The IM Server sends its major/minor-transport-version number to
+the client. The client sends data using the method specified by the
+IM Server.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If major/minor-transport-version number is not available, it is regarded
+as 0.
+<!-- .RE -->
+ </para>
+ </listitem>
+</itemizedlist>
+
+<para>
+(*2) dividing size between ClientMessage and Property
+</para>
+
+<para>
+If data is sent via both of multi-CM and Property, specify the dividing
+size between ClientMessage and Property. The data, which is smaller than
+this size, is sent via multi-CM (or only-CM), and the data, which is
+lager than this size, is sent via Property.
+</para>
+
+<para>
+<emphasis role="bold">read/write</emphasis>
+</para>
+
+<para>
+The data is transferred via either ClientMessage or Window Property in
+the X Window System.
+</para>
+
+<para>
+Format for the data from the Client to the IM Server
+</para>
+
+<para>
+ClientMessage
+</para>
+
+<para>
+If data is sent via ClientMessage event, the format is as follows:
+</para>
+
+
+<table frame="none" id="clientmessage_events_format_first_or_middle">
+<title>The ClientMessage event's format (first or middle)</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Structure Member</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>IMS communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_MOREDATA", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>char</entry>
+ <entry>data.b[20]</entry>
+ <entry>(read/write DATA : 20 byte)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<table frame="none" id="clientmessage_events_format_only_or_last">
+<title>The ClientMessage event's format (only or last)</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Structure Member</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>IMS communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>char</entry>
+ <entry>data.b[20]</entry>
+ <entry>(read/write DATA : MAX 20 byte) (*1)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+(*1) If the data is smaller than 20 byte, all data other than available data
+must be 0.
+</para>
+
+<para>
+Property
+</para>
+
+<para>
+In the case of large data, data will be sent via the Window Property
+for the efficiency. There are the following two methods to notify
+Property, and transport-version is decided which method is used.
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+The XChangeProperty function is used to store data in the client
+communication window, and Atom of the stored data is notified to the
+IM Server via ClientMessage event.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+The XChangeProperty function is used to store data in the client
+communication window, and Atom of the stored data is notified to the
+IM Server via PropertyNotify event.
+ </para>
+ </listitem>
+</itemizedlist>
+
+<para>
+The arguments of the XChangeProperty are as follows:
+</para>
+
+<table frame="none" id="xchangeproperty_events_format">
+<title>The XChangeProperty event's format</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Argument</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>IMS communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>property</entry>
+ <entry>read/write property Atom (*1)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>type</entry>
+ <entry>XA_STRING </entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>mode</entry>
+ <entry>PropModeAppend</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_char</entry>
+ <entry>*data</entry>
+ <entry>read/write DATA</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>nelements</entry>
+ <entry>length of DATA</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+The read/write property ATOM allocates the following strings by
+<function>XInternAtom</function>.
+</para>
+
+<para>
+"_clientXXX"
+</para>
+
+<para>
+The client changes the property with the mode of PropModeAppend and
+the IM Server will read it with the delete mode i.e. (delete = True).
+</para>
+
+<para>
+If Atom is notified via ClientMessage event, the format of the ClientMessage
+is as follows:
+</para>
+
+<table frame="none" id="clientmessage_events_format_to_send_atom_of_property">
+<title>The ClientMessage event's format to send Atom of property</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry spanname="span-horiz">Structure Members</entry>
+ <entry>Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>IMS communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>32</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[0]</entry>
+ <entry>length of read/write property Atom</entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[1]</entry>
+ <entry>read/write property Atom</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+Format for the data from the IM Server to the Client
+</para>
+
+<para>
+<!-- .LP -->
+<!-- .RS -->
+<!-- .B -->
+ClientMessage
+</para>
+<para>
+<!-- .LP -->
+The format of the ClientMessage is as follows:
+</para>
+
+
+
+<table frame="none" id="clientmessage_events_format_for_first_or_middle">
+<title>The ClientMessage event's format (first or middle)</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry align="left" spanname="span-horiz">Structure Members</entry>
+ <entry align="left">Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event </entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>client communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_MOREDATA", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>char</entry>
+ <entry>data.b[20]</entry>
+ <entry>(read/write DATA : 20 byte)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+
+<table frame="none" id="clientmessage_events_format_for_only_or_last">
+<title>The ClientMessage event's format (only or last)</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry align="left" spanname="span-horiz">Structure Members</entry>
+ <entry align="left">Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event </entry>
+ <entry>Set by the X Window System</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>client communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>char</entry>
+ <entry>data.b[20]</entry>
+ <entry>(read/write DATA : MAX 20 byte) (*1)</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+(*1) If the data size is smaller than 20 bytes, all data other than available
+data must be 0.
+</para>
+
+<para>
+Property
+</para>
+
+<para>
+In the case of large data, data will be sent via the Window Property
+for the efficiency. There are the following two methods to notify
+Property, and transport-version is decided which method is used.
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+The XChangeProperty function is used to store data in the IMS
+communication window, and Atom of the property is sent via the
+ClientMessage event.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+The XChangeProperty function is used to store data in the IMS
+communication window, and Atom of the property is sent via
+PropertyNotify event.
+ </para>
+ </listitem>
+</itemizedlist>
+
+<para>
+The arguments of the XChangeProperty are as follows:
+</para>
+
+<table frame="none" id="xchangeproperty_events_format_2">
+<title>The XChangeProperty event's format</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*" colsep="1"/>
+ <colspec colname="col3" colwidth="3.5*" colsep="0"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry align="left" spanname="span-horiz">Argument</entry>
+ <entry align="left">Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display which to connects</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>client communication window ID</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>property</entry>
+ <entry>read/write property Atom (*1)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>type</entry>
+ <entry>XA_STRING</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>8</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>mode</entry>
+ <entry>PropModeAppend</entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_char</entry>
+ <entry>*data</entry>
+ <entry>read/write DATA</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>nelements</entry>
+ <entry>length of DATA</entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+(*1) The read/write property ATOM allocates some strings, which are not
+allocated by the client, by <function>XInternAtom</function>.
+</para>
+
+<para>
+The IM Server changes the property with the mode of PropModeAppend and
+the client reads it with the delete mode, i.e. (delete = True).
+</para>
+
+<para>
+If Atom is notified via ClientMessage event, the format of the ClientMessage
+is as follows:
+</para>
+
+
+<table frame="none" id="clientmessage_events_format_to_send_atom_of_property_2">
+<title>The ClientMessage event's format to send Atom of property</title>
+ <tgroup cols="3">
+ <colspec colname="col1" colwidth="1*" colsep="0"/>
+ <colspec colname="col2" colwidth="1*"/>
+ <colspec colname="col3" colwidth="3.5*"/>
+ <spanspec namest="col1" nameend="col2" spanname="span-horiz" align="center"/>
+ <thead>
+ <row>
+ <entry align="left" spanname="span-horiz">Structure Member</entry>
+ <entry align="left">Contents</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>type</entry>
+ <entry>ClientMessage </entry>
+ </row>
+ <row rowsep="0">
+ <entry>u_long</entry>
+ <entry>serial</entry>
+ <entry>Set by the X Window System </entry>
+ </row>
+ <row rowsep="0">
+ <entry>Bool</entry>
+ <entry>send_event</entry>
+ <entry>Set by the X Window System </entry>
+ </row>
+ <row rowsep="0">
+ <entry>Display</entry>
+ <entry>*display</entry>
+ <entry>The display to which connects </entry>
+ </row>
+ <row rowsep="0">
+ <entry>Window</entry>
+ <entry>window</entry>
+ <entry>client communication window ID </entry>
+ </row>
+ <row rowsep="0">
+ <entry>Atom</entry>
+ <entry>message_type</entry>
+ <entry>XInternAtom(display, "_XIM_PROTOCOL", False)</entry>
+ </row>
+ <row rowsep="0">
+ <entry>int</entry>
+ <entry>format</entry>
+ <entry>32 </entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[0]</entry>
+ <entry>length of read/write property ATOM </entry>
+ </row>
+ <row rowsep="0">
+ <entry>long</entry>
+ <entry>data.l[1]</entry>
+ <entry>read/write property ATOM </entry>
+ </row>
+ </tbody>
+ </tgroup>
+</table>
+
+<para>
+Closing Connection
+</para>
+
+<para>
+If the client disconnect with the IM Server, shutdown function should
+free the communication window properties and etc..
+</para>
+</appendix>
+</article>
diff --git a/libX11/specs/XKB/Makefile.am b/libX11/specs/XKB/Makefile.am
new file mode 100644
index 000000000..90771cc0d
--- /dev/null
+++ b/libX11/specs/XKB/Makefile.am
@@ -0,0 +1,61 @@
+
+if ENABLE_SPECS
+
+# Main DocBook/XML files (DOCTYPE book)
+docbook = xkblib.xml
+
+# Included chapters, appendix, images
+chapters = \
+ acknowledgement.xml \
+ ch01.xml \
+ ch02.xml \
+ ch03.xml \
+ ch04.xml \
+ ch05.xml \
+ ch06.xml \
+ ch07.xml \
+ ch08.xml \
+ ch09.xml \
+ ch10.xml \
+ ch11.xml \
+ ch12.xml \
+ ch13.xml \
+ ch14.xml \
+ ch15.xml \
+ ch16.xml \
+ ch17.xml \
+ ch18.xml \
+ ch19.xml \
+ ch20.xml \
+ ch21.xml \
+ ch22.xml \
+ glossary.xml \
+ XKBlib-1.svg \
+ XKBlib-2.svg \
+ XKBlib-3.svg \
+ XKBlib-4.svg \
+ XKBlib-5.svg \
+ XKBlib-6.svg \
+ XKBlib-7.svg \
+ XKBlib-8.svg \
+ XKBlib-9.svg \
+ XKBlib-10.svg \
+ XKBlib-11.svg \
+ XKBlib-12.svg \
+ XKBlib-13.svg \
+ XKBlib-14.svg \
+ XKBlib-15.svg \
+ XKBlib-16.svg \
+ XKBlib-17.svg \
+ XKBlib-18.svg \
+ XKBlib-19.svg \
+ XKBlib-20.svg \
+ XKBlib-21.svg
+
+# The location where the DocBook/XML files and their generated formats are installed
+shelfdir = $(docdir)/XKB
+
+# Generate DocBook/XML output formats with or without stylesheets
+include $(top_srcdir)/docbook.am
+
+endif ENABLE_SPECS
diff --git a/libX11/specs/XKB/XKBlib-1.svg b/libX11/specs/XKB/XKBlib-1.svg
new file mode 100644
index 000000000..4b89e8bbb
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-1.svg
@@ -0,0 +1,767 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="620"
+ height="420"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ style="enable-background:new"
+ sodipodi:docname="XKBlib-1.svg">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4572"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart"
+ style="overflow:visible">
+ <path
+ id="path4569"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Mstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Mstart"
+ style="overflow:visible">
+ <path
+ id="path4575"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="scale(0.6,0.6)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-7"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-91"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-95"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-1"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-43"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-27"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-39"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-44"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-49"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-38"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4569-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-95"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.91250447"
+ inkscape:cx="310"
+ inkscape:cy="210"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ transform="translate(0,-632.36218)">
+ <g
+ id="g3260">
+ <rect
+ y="680.99249"
+ x="19.174116"
+ height="60.714287"
+ width="82.85714"
+ id="rect3507"
+ style="fill:#ffffff;stroke:#000000;stroke-opacity:1" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057"
+ y="699.66016"
+ x="61.07143"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="699.66016"
+ x="61.07143"
+ id="tspan3061"
+ sodipodi:role="line">Xkb-aware</tspan><tspan
+ y="714.66016"
+ x="61.07143"
+ id="tspan3063"
+ sodipodi:role="line">User</tspan><tspan
+ y="729.66016"
+ x="61.07143"
+ id="tspan3065"
+ sodipodi:role="line">Application</tspan></text>
+ </g>
+ <g
+ id="g3267">
+ <rect
+ y="680.99249"
+ x="111.55135"
+ height="60.714287"
+ width="82.85714"
+ id="rect3507-0"
+ style="fill:#ffffff;stroke:#000000;stroke-opacity:1" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5"
+ y="699.66016"
+ x="153.12054"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="699.66016"
+ x="153.12054"
+ id="tspan3094"
+ sodipodi:role="line">Xkb-capable</tspan><tspan
+ y="714.66016"
+ x="153.12054"
+ id="tspan3096"
+ sodipodi:role="line">User</tspan><tspan
+ y="729.66016"
+ x="153.12054"
+ id="tspan3098"
+ sodipodi:role="line">Application</tspan></text>
+ </g>
+ <g
+ id="g3274">
+ <rect
+ y="680.99249"
+ x="203.92857"
+ height="60.714287"
+ width="82.85714"
+ id="rect3507-0-1"
+ style="fill:#ffffff;stroke:#000000;stroke-opacity:1" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8"
+ y="699.66016"
+ x="245.49776"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="699.66016"
+ x="245.49776"
+ id="tspan3127"
+ sodipodi:role="line">Xkb-unaware</tspan><tspan
+ y="714.66016"
+ x="245.49776"
+ id="tspan3129"
+ sodipodi:role="line">User</tspan><tspan
+ y="729.66016"
+ x="245.49776"
+ id="tspan3131"
+ sodipodi:role="line">Application</tspan></text>
+ </g>
+ <g
+ id="g3281">
+ <rect
+ y="697.30304"
+ x="411.78571"
+ height="37.857143"
+ width="123.57143"
+ id="rect4334"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4"
+ y="719.54211"
+ x="473.52747"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="719.54211"
+ x="473.52747"
+ id="tspan3160"
+ sodipodi:role="line">Keyboard</tspan></text>
+ </g>
+ <g
+ id="g3321">
+ <rect
+ y="787.92566"
+ x="206.3934"
+ height="45.714287"
+ width="76.428574"
+ id="rect4341"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8"
+ y="815.25641"
+ x="244.59891"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="815.25641"
+ x="244.59891"
+ id="tspan3183"
+ sodipodi:role="line">Core Xlib</tspan></text>
+ </g>
+ <g
+ id="g3315">
+ <rect
+ y="981.43201"
+ x="386.42856"
+ height="62.142857"
+ width="174.28572"
+ id="rect4348"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-38"
+ y="1008.314"
+ x="473.27844"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="1008.314"
+ x="473.27844"
+ id="tspan3413"
+ sodipodi:role="line">Server Database of</tspan><tspan
+ y="1023.314"
+ x="473.27844"
+ id="tspan3415"
+ sodipodi:role="line">Keyboard Components</tspan></text>
+ </g>
+ <g
+ id="g3286">
+ <rect
+ y="788.23157"
+ x="336.78571"
+ height="144.28572"
+ width="274.28571"
+ id="rect4356"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0"
+ y="814.84808"
+ x="473.75571"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="814.84808"
+ x="473.75571"
+ id="tspan3206"
+ sodipodi:role="line">X Server</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-9"
+ y="851.45685"
+ x="474.26547"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="851.45685"
+ x="474.26547"
+ id="tspan3229"
+ sodipodi:role="line">Xkb Server Extension</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-0"
+ y="883.685"
+ x="371.61285"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="883.685"
+ x="371.61285"
+ id="tspan3252"
+ sodipodi:role="line">Client Map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-0-4"
+ y="883.57953"
+ x="448.63406"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="883.57953"
+ x="448.63406"
+ id="tspan3275"
+ sodipodi:role="line">Server Map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-0-4-0"
+ y="883.685"
+ x="550.14691"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="883.685"
+ x="550.14691"
+ id="tspan3298"
+ sodipodi:role="line">Compatibility Map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-2"
+ y="918.8595"
+ x="366.32715"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="918.8595"
+ x="366.32715"
+ id="tspan3321"
+ sodipodi:role="line">Controls</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-0-0"
+ y="917.69641"
+ x="443.49121"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="917.69641"
+ x="443.49121"
+ id="tspan3344"
+ sodipodi:role="line">Indicator Map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-3"
+ y="918.67493"
+ x="517.61279"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="918.67493"
+ x="517.61279"
+ id="tspan3367"
+ sodipodi:role="line">Names</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-3-0"
+ y="917.59094"
+ x="575.20703"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="917.59094"
+ x="575.20703"
+ id="tspan3390"
+ sodipodi:role="line">Geometry</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4356-7"
+ d="m 611.07143,830.37443 -274.2857,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4356-7-9"
+ d="m 610.35713,863.51729 -274.2857,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4356-7-9-1"
+ d="m 610.35713,897.51729 -274.2857,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4413"
+ d="m 397.07142,930.54013 0,-32.30857"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4413-0"
+ d="m 490.64285,930.54013 0,-32.30857"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4413-3"
+ d="m 542.64286,930.54013 0,-32.30857"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4413-5"
+ d="m 407.5,896.52872 0,-32.30857"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4413-5-9"
+ d="m 488.64285,896.52872 0,-32.30857"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g3326">
+ <rect
+ y="846.80304"
+ x="8.9285755"
+ height="89.285713"
+ width="194.28572"
+ id="rect4506"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-38-3"
+ y="900.4707"
+ x="141.49275"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="900.4707"
+ x="141.49275"
+ id="tspan3441"
+ sodipodi:role="line">Xkb Modifications</tspan><tspan
+ y="915.4707"
+ x="141.49275"
+ id="tspan3443"
+ sodipodi:role="line">to Core Xlib</tspan><tspan
+ y="930.4707"
+ x="141.49275"
+ id="tspan3445"
+ sodipodi:role="line">functions</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-38-3-0"
+ y="865.21344"
+ x="46.18861"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="865.21344"
+ x="46.18861"
+ id="tspan3474"
+ sodipodi:role="line">Xkb</tspan><tspan
+ y="880.21344"
+ x="46.18861"
+ id="tspan3476"
+ sodipodi:role="line">Additions</tspan><tspan
+ y="895.21344"
+ x="46.18861"
+ id="tspan3478"
+ sodipodi:role="line">to Xlib</tspan><tspan
+ y="910.21344"
+ x="46.18861"
+ id="tspan3480"
+ sodipodi:role="line">(Xkb*</tspan><tspan
+ y="925.21344"
+ x="46.18861"
+ id="tspan3482"
+ sodipodi:role="line">functions)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3057-5-8-4-8-0-1"
+ y="871.1712"
+ x="141.36678"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="871.1712"
+ x="141.36678"
+ id="tspan3505"
+ sodipodi:role="line">Core Xlib</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4508"
+ d="m 81.428565,935.71524 0,-89.26936"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4508-4"
+ d="m 202.66106,883.94586 -120.518205,0"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:2.99999982, 2.99999982;stroke-dashoffset:0" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 51.785715,743.94009 0.71429,100.03368"
+ id="path4546"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 153.57142,743.92902 0.71429,100.03368"
+ id="path4546-2"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 473.21428,738.01121 0.71429,48.38656"
+ id="path4546-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 334.35827,805.73157 -49.73226,0.71429"
+ id="path4546-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 246.42858,786.08138 -0.71429,-42.00166"
+ id="path4546-9-0"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="M 334.71531,820.81601 206.49673,871.36143"
+ id="path4546-9-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="M 108.32334,843.06647 75.971115,744.00572"
+ id="path4546-9-3"
+ inkscape:connector-curvature="0"
+ inkscape:transform-center-x="-16.307885"
+ inkscape:transform-center-y="52.415789" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:none;marker-end:url(#Arrow2Lend-2)"
+ d="m 474.14314,982.08954 -0.71429,-47.66418"
+ id="path4546-9-0-4"
+ inkscape:connector-curvature="0" />
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="315.02905"
+ y="649.76666"
+ id="text3057-5-8-4-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan7448"
+ x="315.02905"
+ y="649.76666">Xkb Extension</tspan></text>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-10.svg b/libX11/specs/XKB/XKBlib-10.svg
new file mode 100644
index 000000000..13bb7a23e
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-10.svg
@@ -0,0 +1,1441 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="500"
+ height="600"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-10.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-10.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965"
+ style="display:inline">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Mend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Mend"
+ style="overflow:visible">
+ <path
+ id="path4466"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="scale(-0.6,-0.6)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4460"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-1"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-65"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-65-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-6-7"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-52"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-44"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-65-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-6-78"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-8"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-14"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-89"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-65-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-6-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-50"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4460-48"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.012534"
+ inkscape:cx="138.55871"
+ inkscape:cy="259.33367"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <g
+ id="g6721">
+ <rect
+ y="18.687113"
+ x="33.045399"
+ height="185.07834"
+ width="82.191376"
+ id="rect3260"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051"
+ y="50.78091"
+ x="73.581512"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="50.78091"
+ x="73.581512"
+ id="tspan3053"
+ sodipodi:role="line">label_color</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7"
+ y="67.231613"
+ x="73.60202"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="67.231613"
+ x="73.60202"
+ id="tspan3076"
+ sodipodi:role="line">base_color</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5"
+ y="107.93592"
+ x="73.892059"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="107.93592"
+ x="73.892059"
+ id="tspan3099"
+ sodipodi:role="line">properties</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1"
+ y="126.88952"
+ x="74.105927"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="126.88952"
+ x="74.105927"
+ id="tspan3122"
+ sodipodi:role="line">colors</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3"
+ y="143.7081"
+ x="74.111786"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="143.7081"
+ x="74.111786"
+ id="tspan3145"
+ sodipodi:role="line">shapes</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0"
+ y="162.89717"
+ x="74.111786"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="162.89717"
+ x="74.111786"
+ id="tspan3168"
+ sodipodi:role="line">sections</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5"
+ y="181.28131"
+ x="74.105927"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="181.28131"
+ x="74.105927"
+ id="tspan3191"
+ sodipodi:role="line">doodads</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2"
+ y="197.71959"
+ x="73.892059"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="197.71959"
+ x="73.892059"
+ id="tspan3214"
+ sodipodi:role="line">key_aliases</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-9"
+ y="86.801003"
+ x="74.149872"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="86.801003"
+ x="74.149872"
+ id="tspan3237"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-9-9"
+ y="31.955656"
+ x="74.149872"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="31.955656"
+ x="74.149872"
+ id="tspan3237-4"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9"
+ d="m 33.045395,37.473711 82.191385,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8"
+ d="m 33.045396,55.488687 82.191384,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-1"
+ d="m 33.045398,73.645882 82.191382,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-6"
+ d="m 33.045397,95.644022 82.191383,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-3"
+ d="m 33.045399,113.45204 82.191371,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-9"
+ d="m 33.045393,131.60923 82.191387,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-33"
+ d="m 33.045398,149.59184 82.191382,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-4"
+ d="m 33.045397,167.39986 82.191383,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3260-9-8-61"
+ d="m 33.045392,185.55706 82.191388,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2"
+ y="220.6503"
+ x="75.038658"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="220.6503"
+ x="75.038658"
+ id="tspan4286"
+ sodipodi:role="line">XkbGeometryRec</tspan></text>
+ </g>
+ <g
+ id="g6788">
+ <rect
+ y="249.631"
+ x="45.392994"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="253.58833"
+ x="41.784836"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="257.54568"
+ x="38.17667"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="261.50302"
+ x="34.568512"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-7"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9"
+ y="293.44604"
+ x="76.285805"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="293.44604"
+ x="76.285805"
+ id="tspan4409"
+ sodipodi:role="line">XkbKeyAliasRec(s)</tspan><tspan
+ y="304.69604"
+ x="76.285805"
+ id="tspan4411"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6759">
+ <rect
+ y="74.598343"
+ x="158.09758"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-86"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="78.555679"
+ x="154.48943"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-3"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="82.513031"
+ x="150.88126"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-77"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="86.470367"
+ x="147.2731"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-7-2"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-3"
+ y="114.84941"
+ x="189.09557"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="114.84941"
+ x="189.09557"
+ id="tspan4963"
+ sodipodi:role="line">XkbColorRec(s)</tspan><tspan
+ y="126.09941"
+ x="189.09557"
+ id="tspan4965"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6772">
+ <rect
+ y="12.539931"
+ x="161.24017"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-8"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="16.497267"
+ x="157.63202"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-12"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="20.454618"
+ x="154.02385"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-4"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="24.411955"
+ x="150.4157"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-7-7"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-3-5"
+ y="52.092648"
+ x="192.93651"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="52.092648"
+ x="192.93651"
+ id="tspan4991"
+ sodipodi:role="line">XkbPropertyRec(s)</tspan><tspan
+ y="63.342648"
+ x="192.93651"
+ id="tspan4993"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6843">
+ <rect
+ y="462.62888"
+ x="43.297932"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="468.21573"
+ x="38.060284"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="473.80255"
+ x="32.822628"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0"
+ d="m 32.822614,490.56304 81.009036,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0"
+ d="m 32.822613,509.51363 81.009037,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0-3"
+ d="m 32.822612,527.67083 81.009038,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9"
+ y="501.388"
+ x="72.883667"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="501.388"
+ x="72.883667"
+ id="tspan5433"
+ sodipodi:role="line">(See Figure 13.6)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3"
+ y="557.29443"
+ x="72.630981"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan5596"
+ sodipodi:role="line"
+ x="72.630981"
+ y="557.29443">overlays(s)</tspan><tspan
+ id="tspan5598"
+ sodipodi:role="line"
+ x="72.630981"
+ y="568.54443">(array)</tspan></text>
+ </g>
+ <g
+ id="g6011"
+ transform="translate(-0.28926354,0.20454307)">
+ <rect
+ y="333.22891"
+ x="45.043816"
+ height="87.992561"
+ width="80.310669"
+ id="rect4161-6-1-7-6"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="338.46655"
+ x="39.456993"
+ height="87.992561"
+ width="80.310669"
+ id="rect4161-6-1-7-6-8"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="344.40256"
+ x="33.870163"
+ height="87.992561"
+ width="80.310669"
+ id="rect4161-6-1-7-6-8-1"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-36"
+ y="354.52917"
+ x="74.032089"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="354.52917"
+ x="74.032089"
+ id="tspan5149"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-36-3"
+ y="373.98206"
+ x="73.83873"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="373.98206"
+ x="73.83873"
+ id="tspan5172"
+ sodipodi:role="line">rows</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-36-3-8"
+ y="392.43518"
+ x="73.99913"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="392.43518"
+ x="73.99913"
+ id="tspan5195"
+ sodipodi:role="line">doodads</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-36-3-8-0"
+ y="409.98962"
+ x="73.83873"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="409.98962"
+ x="73.83873"
+ id="tspan5218"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-36-3-8-0-9"
+ y="426.67175"
+ x="73.99913"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="426.67175"
+ x="73.99913"
+ id="tspan5241"
+ sodipodi:role="line">overlays</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-2"
+ d="m 114.18084,362.74829 -80.31068,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-4"
+ d="m 114.18084,380.30274 -80.31068,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-9"
+ d="m 114.18084,397.85717 -80.31068,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-0"
+ d="m 114.18084,415.41162 -80.31068,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-7"
+ y="443.91846"
+ x="74.166107"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="443.91846"
+ x="74.166107"
+ id="tspan5498"
+ sodipodi:role="line">XkbSectionRec(s)</tspan><tspan
+ y="455.16846"
+ x="74.166107"
+ id="tspan5500"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6902">
+ <rect
+ y="434.34552"
+ x="165.16064"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="439.93237"
+ x="159.923"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-1-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="445.5192"
+ x="154.68535"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-2-03"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-1"
+ d="m 154.68533,462.27972 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0-8"
+ d="m 154.68533,481.23031 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0-3-0"
+ d="m 154.68533,499.38751 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-1"
+ y="473.10464"
+ x="194.74638"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan5552"
+ sodipodi:role="line"
+ x="194.74638"
+ y="473.10464">(See Figure 13.5)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9"
+ y="528.97302"
+ x="194.98129"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="528.97302"
+ x="194.98129"
+ id="tspan5592"
+ sodipodi:role="line">doodads(s)</tspan><tspan
+ y="540.22302"
+ x="194.98129"
+ id="tspan5594"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g5975"
+ transform="translate(0.34918083,0.20454306)">
+ <rect
+ y="556.00372"
+ x="154.33617"
+ height="17.458841"
+ width="81.707375"
+ id="rect5600"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5"
+ y="587.08093"
+ x="196.37801"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="587.08093"
+ x="196.37801"
+ id="tspan5644"
+ sodipodi:role="line">XkbBoundsRec</tspan></text>
+ </g>
+ <g
+ id="g6919">
+ <rect
+ y="466.46982"
+ x="277.59558"
+ height="17.458841"
+ width="81.707375"
+ id="rect5600-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4"
+ y="497.20932"
+ x="319.63742"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="497.20932"
+ x="319.63742"
+ id="tspan5644-6"
+ sodipodi:role="line">XkbBoundsRec</tspan></text>
+ </g>
+ <g
+ id="g5939"
+ transform="translate(2.4442418,1.6012504)">
+ <rect
+ y="333.22891"
+ x="164.11311"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="338.11737"
+ x="159.22464"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="343.00586"
+ x="153.6378"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-90"
+ d="m 234.29765,362.55975 -80.31067,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-3"
+ d="m 234.29765,381.4153 -80.31067,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0"
+ y="354.52921"
+ x="194.14891"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="354.52921"
+ x="194.14891"
+ id="tspan5746"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7"
+ y="373.59317"
+ x="193.95555"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="373.59317"
+ x="193.95555"
+ id="tspan5769"
+ sodipodi:role="line">keys</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7-4"
+ y="395.77023"
+ x="193.95555"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="395.77023"
+ x="193.95555"
+ id="tspan5792"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7-4-9"
+ y="413.40305"
+ x="198.84402"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="413.40305"
+ x="198.84402"
+ id="tspan5839"
+ sodipodi:role="line">XkbRowRec(s)</tspan><tspan
+ y="424.65305"
+ x="198.84402"
+ id="tspan5841"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g5923"
+ transform="translate(-1.3967033,-0.49381059)">
+ <rect
+ y="347.89435"
+ x="289.46759"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670-94"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="352.78281"
+ x="284.57913"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670-9-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="357.6713"
+ x="278.99228"
+ height="58.661709"
+ width="81.009026"
+ id="rect5670-2-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-90-6"
+ d="m 359.65213,377.22517 -80.31067,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4161-6-1-7-6-8-0-3-5"
+ d="m 359.65213,396.08072 -80.31067,0"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-9"
+ y="369.19464"
+ x="319.50339"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="369.19464"
+ x="319.50339"
+ id="tspan5746-5"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7-6"
+ y="388.25861"
+ x="319.31003"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="388.25861"
+ x="319.31003"
+ id="tspan5891"
+ sodipodi:role="line">shape_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7-4-1"
+ y="410.43567"
+ x="319.31003"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="410.43567"
+ x="319.31003"
+ id="tspan5893"
+ sodipodi:role="line">color_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-0-7-4-9-3"
+ y="429.25302"
+ x="319.40253"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="429.25302"
+ x="319.40253"
+ id="tspan5919"
+ sodipodi:role="line">XkbKeyRec(s)</tspan><tspan
+ y="440.50302"
+ x="319.40253"
+ id="tspan5921"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6944">
+ <rect
+ y="280.7402"
+ x="396.90216"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-0-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="286.32706"
+ x="391.66452"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-1-5-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="291.91388"
+ x="386.42685"
+ height="69.835365"
+ width="81.009026"
+ id="rect5320-2-03-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-1-4"
+ d="m 386.42684,308.67438 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0-8-4"
+ d="m 386.42684,327.62497 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5320-2-0-0-3-0-4"
+ d="m 386.42684,345.78217 81.00904,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-1-9"
+ y="319.49933"
+ x="426.48788"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan5552-9"
+ sodipodi:role="line"
+ x="426.48788"
+ y="319.49933">(See Figure 13.5)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-3"
+ y="375.36771"
+ x="426.72281"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="375.36771"
+ x="426.72281"
+ id="tspan5592-8"
+ sodipodi:role="line">doodads(s)</tspan><tspan
+ y="386.61771"
+ x="426.72281"
+ id="tspan5594-3"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6474"
+ transform="translate(-1.3967033,-0.49381059)">
+ <rect
+ y="221.14313"
+ x="392.12558"
+ height="17.458841"
+ width="81.707375"
+ id="rect5600-3-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="220.80542"
+ x="392.12558"
+ height="17.458841"
+ width="81.707375"
+ id="rect5600-8-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4"
+ y="251.88263"
+ x="434.16742"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="251.88263"
+ x="434.16742"
+ id="tspan5644-6-3"
+ sodipodi:role="line">XkbBoundsRec</tspan></text>
+ </g>
+ <g
+ id="g6176"
+ transform="translate(-1.3967033,-0.49381059)">
+ <rect
+ y="154.16595"
+ x="401.0296"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-4"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="158.12329"
+ x="397.42145"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-9"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="162.08064"
+ x="393.81326"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-5"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="166.03798"
+ x="390.20511"
+ height="16.760489"
+ width="80.310669"
+ id="rect4161-6-1-7-5"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-7"
+ y="195.18759"
+ x="431.92242"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="195.18759"
+ x="431.92242"
+ id="tspan6172"
+ sodipodi:role="line">XkbOutlineRec(s)</tspan><tspan
+ y="206.43759"
+ x="431.92242"
+ id="tspan6174"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g6993">
+ <rect
+ y="119.73722"
+ x="280.03983"
+ height="89.389267"
+ width="81.009026"
+ id="rect6185-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="124.62569"
+ x="275.15134"
+ height="89.389267"
+ width="81.009026"
+ id="rect6185-1-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="129.51418"
+ x="269.56451"
+ height="89.389267"
+ width="81.009026"
+ id="rect6185"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-0"
+ y="159.23502"
+ x="310.04266"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="159.23502"
+ x="310.04266"
+ id="tspan6245"
+ sodipodi:role="line">outlines</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-2"
+ y="175.44571"
+ x="309.94598"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="175.44571"
+ x="309.94598"
+ id="tspan6247"
+ sodipodi:role="line">approx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-9"
+ y="194.3261"
+ x="309.79437"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="194.3261"
+ x="309.79437"
+ id="tspan6249"
+ sodipodi:role="line">primary</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-5"
+ y="213.18007"
+ x="309.88226"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="213.18007"
+ x="309.88226"
+ id="tspan6251"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-0-1"
+ y="138.45622"
+ x="310.07562"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="138.45622"
+ x="310.07562"
+ id="tspan6274"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect6185-9"
+ d="m 269.56451,146.88894 81.00903,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect6185-9-3"
+ d="m 269.56451,164.87065 81.00903,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect6185-9-6"
+ d="m 269.56451,182.85233 81.00903,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect6185-9-2"
+ d="m 269.56451,200.83401 81.00903,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-0-5-2-2-9-9-3-9-5-4-4-3"
+ y="234.13068"
+ x="310.21848"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="234.13068"
+ x="310.21848"
+ id="tspan6480"
+ sodipodi:role="line">XkbShapeRec(s)</tspan><tspan
+ y="245.38068"
+ x="310.21848"
+ id="tspan6482"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 113.38742,424.37848 16.27725,10e-6 0.22911,57.80429 -13.54036,0"
+ id="path6544"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="M 116.62506,102.7722 149.0985,42.364609"
+ id="path3375"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 115.92671,47.253085 13.61789,-0.349177 0,40.155335 16.1572,0"
+ id="path4341"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 116.42258,124.94888 28.98168,-23.39485"
+ id="path3375-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 116.17235,141.33425 151.89193,-0.34918"
+ id="path3375-7-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65)"
+ d="m 116.27589,196.70077 23.0146,0.34917 0.34918,71.93043 -15.01461,0"
+ id="path4599"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65)"
+ d="m 116.37068,158.55727 27.6033,-0.0585 0.44442,196.49648 -29.10951,0"
+ id="path4599-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 114.29059,370.58387 36.76113,-0.34918"
+ id="path3375-7-9-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 236.89802,370.51687 39.04305,-0.34918"
+ id="path3375-7-9-4-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65-0)"
+ d="m 114.53,388.39884 26.53744,0 13.26872,55.16994"
+ id="path4887"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65-0)"
+ d="m 113.83165,407.95275 21.64896,0 -0.69836,157.12957 18.85555,0.69835"
+ id="path5087"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65-0)"
+ d="M 237.44024,391.89062 277.2464,464.5194"
+ id="path5287"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-65-0)"
+ d="m 115.92671,176.09933 73.32713,0 0,122.91025 196.33244,0"
+ id="path5487"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 351.61868,210.71052 37.18768,20.48161"
+ id="path3375-7-9-4-3-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 351.82439,157.04065 35.90045,9.42777"
+ id="path3375-7-9-4-3-4-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 351.82439,193.76132 35.90046,-10.82448"
+ id="path3375-7-9-4-3-4-6"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 351.794,174.16074 35.90046,-0.34918"
+ id="path3375-7-9-4-3-4-6-6"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-89)"
+ d="m 276.64311,404.46098 -23.93415,0 0.69835,-306.577255 -18.95061,0"
+ id="path5783"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-65)"
+ d="m 277.00697,388.06251 -19.96656,0.24124 -0.2857,-238.03065 12.28468,0"
+ id="path4599-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 3;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 116.29058,66.952039 7.61789,-0.349177 0,30.155338 21.20473,0"
+ id="path4341-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-11.svg b/libX11/specs/XKB/XKBlib-11.svg
new file mode 100644
index 000000000..31dfaea69
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-11.svg
@@ -0,0 +1,920 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="480"
+ height="650"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-11.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-11.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4729"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-49"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-57"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-27"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-90"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4729-6-1"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.83384615"
+ inkscape:cx="188.36275"
+ inkscape:cy="337.04736"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="293.21954"
+ y="49.769375"
+ id="text3051"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3055"
+ x="293.21954"
+ y="49.769375">XkbGeometryRec,</tspan><tspan
+ sodipodi:role="line"
+ id="tspan3057"
+ x="293.21954"
+ y="61.019375">XkbColorRec, and</tspan><tspan
+ sodipodi:role="line"
+ id="tspan3059"
+ x="293.21954"
+ y="72.269379">XkbShapeRec</tspan><tspan
+ sodipodi:role="line"
+ id="tspan3061"
+ x="293.21954"
+ y="83.519379">repeated from</tspan><tspan
+ sodipodi:role="line"
+ id="tspan3063"
+ x="293.21954"
+ y="94.769379">Figure 16.4</tspan></text>
+ <g
+ id="g6009">
+ <rect
+ y="14.419287"
+ x="98.197311"
+ height="183.16936"
+ width="81.4086"
+ id="rect3065"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4"
+ d="m 98.368732,34.325261 81.408598,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-6"
+ d="m 98.368734,52.535068 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-1"
+ d="m 98.368732,70.744831 81.408598,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-5"
+ d="m 98.368734,88.95465 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-61"
+ d="m 98.368734,107.16448 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-7"
+ d="m 98.368734,125.37425 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-2"
+ d="m 98.368734,143.58406 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-29"
+ d="m 98.368732,161.79387 81.408598,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3065-4-28"
+ d="m 98.368724,180.00367 81.408616,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1"
+ y="25.778435"
+ x="131.74512"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="25.778435"
+ x="131.74512"
+ id="tspan3954"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3"
+ y="45.787781"
+ x="114.26807"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="45.787781"
+ x="114.26807"
+ id="tspan3954-7"
+ sodipodi:role="line">label_color</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-7"
+ y="63.997597"
+ x="114.43286"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="63.997597"
+ x="114.43286"
+ id="tspan3954-7-2"
+ sodipodi:role="line">base_color</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-3"
+ y="100.5425"
+ x="115.74023"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="100.5425"
+ x="115.74023"
+ id="tspan3954-7-7"
+ sodipodi:role="line">properties</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-2"
+ y="119.62462"
+ x="125.44556"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="119.62462"
+ x="125.44556"
+ id="tspan3954-7-5"
+ sodipodi:role="line">colors</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-37"
+ y="136.9621"
+ x="122.94507"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="136.9621"
+ x="122.94507"
+ id="tspan3954-7-6"
+ sodipodi:role="line">shapes</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-8"
+ y="156.04422"
+ x="120.31713"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="156.04422"
+ x="120.31713"
+ id="tspan3954-7-1"
+ sodipodi:role="line">sections</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-36"
+ y="174.25398"
+ x="119.6975"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="174.25398"
+ x="119.6975"
+ id="tspan3954-7-4"
+ sodipodi:role="line">doodads</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-0"
+ y="191.46625"
+ x="113.10352"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="191.46625"
+ x="113.10352"
+ id="tspan3954-7-3"
+ sodipodi:role="line">key_aliases</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-3-0-5"
+ y="213.93842"
+ x="99.878174"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="213.93842"
+ x="99.878174"
+ id="tspan3954-7-3-8"
+ sodipodi:role="line">XkbGeometryRec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-1-5"
+ y="80.407837"
+ x="131.74512"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="80.407837"
+ x="131.74512"
+ id="tspan3954-0"
+ sodipodi:role="line">. . .</tspan></text>
+ </g>
+ <g
+ id="g6043">
+ <rect
+ y="243.80499"
+ x="98.792732"
+ height="54.272404"
+ width="81.4086"
+ id="rect4194"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9"
+ d="m 98.792734,262.53876 81.408596,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9-9"
+ d="m 98.792736,280.29513 81.408594,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8"
+ y="273.7746"
+ x="117.68697"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="273.7746"
+ x="117.68697"
+ id="tspan3063-0"
+ sodipodi:role="line">color_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1"
+ y="291.53098"
+ x="115.18649"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="291.53098"
+ x="115.18649"
+ id="tspan3063-0-2"
+ sodipodi:role="line">shape_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-0"
+ y="254.2187"
+ x="132.34055"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="254.2187"
+ x="132.34055"
+ id="tspan3063-0-2-0"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6"
+ y="313.15515"
+ x="85.628868"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="313.15515"
+ x="85.628868"
+ id="tspan3063-0-2-3"
+ sodipodi:role="line">XkbShapeDoodadRec(s)</tspan></text>
+ </g>
+ <g
+ id="g6056">
+ <rect
+ y="342.17371"
+ x="99.216736"
+ height="36.888275"
+ width="81.4086"
+ id="rect4367"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9-90"
+ d="m 99.216739,361.25386 81.408591,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-0-8"
+ y="353.33191"
+ x="132.76454"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="353.33191"
+ x="132.76454"
+ id="tspan3063-0-2-0-3"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-8"
+ y="372.51556"
+ x="118.11098"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="372.51556"
+ x="118.11098"
+ id="tspan3063-0-7"
+ sodipodi:role="line">color_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-3"
+ y="394.26498"
+ x="91.045059"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="394.26498"
+ x="91.045059"
+ id="tspan3063-0-2-3-1"
+ sodipodi:role="line">XkbTextDoodadRec(s)</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="21.180391"
+ y="424.79321"
+ id="text3051-8-1-6-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan4481"
+ x="21.180391"
+ y="424.79321">doodads array</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4483"
+ x="21.180391"
+ y="436.04321">may contain</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4485"
+ x="21.180391"
+ y="447.29321">any of these</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4487"
+ x="21.180391"
+ y="458.54321">doodad types</tspan></text>
+ <g
+ id="g6066">
+ <rect
+ y="425.49033"
+ x="98.792725"
+ height="73.352547"
+ width="81.4086"
+ id="rect4367-9"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9-90-1"
+ d="m 98.792733,444.14645 81.408587,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9-90-1-0"
+ d="m 98.792735,462.3786 81.408575,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4194-9-90-1-3"
+ d="m 98.792733,480.61073 81.408587,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-5"
+ y="455.62021"
+ x="115.18648"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="455.62021"
+ x="115.18648"
+ id="tspan3063-0-2-03"
+ sodipodi:role="line">shape_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-18"
+ y="473.85233"
+ x="109.82954"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="473.85233"
+ x="109.82954"
+ id="tspan3063-0-0"
+ sodipodi:role="line">on_color_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-18-1"
+ y="492.08447"
+ x="109.58345"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="492.08447"
+ x="109.58345"
+ id="tspan3063-0-0-7"
+ sodipodi:role="line">off_color_ndx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-0-8-5"
+ y="435.5885"
+ x="132.34053"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="435.5885"
+ x="132.34053"
+ id="tspan3063-0-2-0-3-9"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-3-4"
+ y="511.20865"
+ x="79.828079"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="511.20865"
+ x="79.828079"
+ id="tspan3063-0-2-3-1-8"
+ sodipodi:role="line">XkbIndicatorDoodadRec(s)</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 44.096327,469.37466 -0.02345,162.03678 38.976015,0"
+ id="path4699"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 46.171587,410.44742 0,-170.29521 39.575646,0"
+ id="path4701"
+ inkscape:connector-curvature="0" />
+ <g
+ id="g6082">
+ <g
+ id="g5369">
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;fill-opacity:1"
+ id="rect4194-90"
+ width="81.4086"
+ height="54.272404"
+ x="99.609352"
+ y="549.87872" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 99.609355,568.61251 81.408595,0"
+ id="rect4194-9-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 99.609357,586.36888 81.408593,0"
+ id="rect4194-9-9-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="118.50359"
+ y="579.84833"
+ id="text3051-8-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3063-0-3"
+ x="118.50359"
+ y="579.84833">color_ndx</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="116.00311"
+ y="597.60474"
+ id="text3051-8-1-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3063-0-2-9"
+ x="116.00311"
+ y="597.60474">shape_ndx</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="133.15717"
+ y="560.29248"
+ id="text3051-8-1-0-4"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3063-0-2-0-9"
+ x="133.15717"
+ y="560.29248">. . .</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="89.758965"
+ y="619.22888"
+ id="text3051-8-1-6-9"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3063-0-2-3-19"
+ x="89.758965"
+ y="619.22888">XkbLogoDoodadRec(s)</tspan></text>
+ </g>
+ </g>
+ <g
+ id="g5507">
+ <rect
+ y="418.24261"
+ x="343.58856"
+ height="89.345016"
+ width="80.350555"
+ id="rect5248-3-9"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="423.03967"
+ x="338.19189"
+ height="89.345016"
+ width="80.350555"
+ id="rect5248-3"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="427.5369"
+ x="333.39484"
+ height="89.345016"
+ width="80.350555"
+ id="rect5248"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5248-4"
+ d="m 333.39482,445.09097 80.35056,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5248-4-2"
+ d="m 333.39482,462.61227 80.35056,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5248-4-0"
+ d="m 333.39482,480.13358 80.35056,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5248-4-6"
+ d="m 333.39482,497.65487 80.35056,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-5"
+ y="457.20685"
+ x="355.70193"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="457.20685"
+ x="355.70193"
+ id="tspan3063-0-2-3-19-9"
+ sodipodi:role="line">outlines</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-56"
+ y="472.95715"
+ x="357.94315"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="472.95715"
+ x="357.94315"
+ id="tspan3063-0-2-3-19-1"
+ sodipodi:role="line">approx</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-1"
+ y="491.37714"
+ x="355.67337"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="491.37714"
+ x="355.67337"
+ id="tspan3063-0-2-3-19-4"
+ sodipodi:role="line">primary</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-3"
+ y="509.77075"
+ x="356.85989"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="509.77075"
+ x="356.85989"
+ id="tspan3063-0-2-3-19-7"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-2"
+ y="532.5567"
+ x="373.82498"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="532.5567"
+ x="373.82498"
+ id="tspan3063-0-2-3-19-73"
+ sodipodi:role="line">XkbShapeRec(s)</tspan><tspan
+ id="tspan5382"
+ y="543.8067"
+ x="373.82498"
+ sodipodi:role="line">(array)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-5-2"
+ y="436.88843"
+ x="366.4136"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="436.88843"
+ x="366.4136"
+ id="tspan3063-0-2-3-19-9-4"
+ sodipodi:role="line">. . .</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 179.29278,136.54219 270.44257,0 0,296.22976 -33.92025,-0.14844"
+ id="path4703-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <g
+ id="g5563">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-8-1-6-9-2-4"
+ y="332.24759"
+ x="374.22568"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="332.24759"
+ x="374.22568"
+ id="tspan3063-0-2-3-19-73-4"
+ sodipodi:role="line">XkbColorRec(s)</tspan><tspan
+ id="tspan5382-9"
+ y="343.49759"
+ x="374.22568"
+ sodipodi:role="line">(array)</tspan></text>
+ <rect
+ y="289.59732"
+ x="344.71457"
+ height="19.928148"
+ width="80.984604"
+ id="rect5529"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="293.48401"
+ x="341.11053"
+ height="19.928148"
+ width="80.984604"
+ id="rect5529-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="297.37073"
+ x="337.50653"
+ height="19.928148"
+ width="80.984604"
+ id="rect5529-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="301.25742"
+ x="333.9025"
+ height="19.928148"
+ width="80.984604"
+ id="rect5529-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 179.77733,116.60405 188.2574,0 0,178.08132"
+ id="path4703"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 181.37488,593.18358 329.02644,444.78248"
+ id="path5572"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 180.83605,576.02521 335.13058,332.50192"
+ id="path5572-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 180.83604,453.06429 330.08515,437.80018"
+ id="path5572-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 180.63968,287.83051 330.31279,430.93157"
+ id="path5572-3-5"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 180.83605,490.37657 331.2418,325.36659"
+ id="path5572-90"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 180.86945,471.32681 328.02867,316.24454"
+ id="path5572-90-2"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="M 181.06854,370.40281 328.43976,307.47472"
+ id="path5572-90-2-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="m 180.69326,271.38659 149.95161,29.32896"
+ id="path5572-90-2-0-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-12.svg b/libX11/specs/XKB/XKBlib-12.svg
new file mode 100644
index 000000000..5bffae5de
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-12.svg
@@ -0,0 +1,687 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="640"
+ height="540"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="New document 1">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4984"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4984-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4984-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4984-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4984-3-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4984-3-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.0037037"
+ inkscape:cx="198.77003"
+ inkscape:cy="262.24458"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <g
+ id="g5803"
+ transform="translate(-1.9926199,-0.99630996)">
+ <rect
+ y="36.038216"
+ x="49.153389"
+ height="124.53874"
+ width="112.58302"
+ id="rect3162-9-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="42.780323"
+ x="41.737083"
+ height="124.53874"
+ width="112.58302"
+ id="rect3162-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0"
+ y="190.21021"
+ x="91.096054"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="190.21021"
+ x="91.096054"
+ id="tspan3053-0-1-0-4"
+ sodipodi:role="line">XkbSelectionRec(s)</tspan><tspan
+ id="tspan3160"
+ y="205.21021"
+ x="91.096054"
+ sodipodi:role="line">(array)</tspan></text>
+ <rect
+ y="49.408875"
+ x="34.464703"
+ height="124.53874"
+ width="112.58302"
+ id="rect3162"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051"
+ y="88.833115"
+ x="76.456406"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="88.833115"
+ x="76.456406"
+ id="tspan3053"
+ sodipodi:role="line">rows</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7"
+ y="114.5687"
+ x="65.150742"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="114.5687"
+ x="65.150742"
+ id="tspan3053-0"
+ sodipodi:role="line">doodads</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5"
+ y="139.10606"
+ x="68.475937"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="139.10606"
+ x="68.475937"
+ id="tspan3053-0-1"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1"
+ y="162.4803"
+ x="65.314804"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="162.4803"
+ x="65.314804"
+ id="tspan3053-0-1-0"
+ sodipodi:role="line">overlays</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3"
+ y="63.764496"
+ x="79.784004"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="63.764496"
+ x="79.784004"
+ id="tspan3053-0-1-0-0"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5"
+ d="m 147.04772,73.289015 -112.58302,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-4"
+ d="m 147.04772,97.82637 -112.58302,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-2"
+ d="m 147.04773,122.36373 -112.583033,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-49"
+ d="m 147.04773,146.9011 -112.583033,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g4121"
+ transform="translate(-0.40614801,0.58968744)">
+ <rect
+ y="215.03053"
+ x="267.66156"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-4"
+ y="258.34854"
+ x="323.82025"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="258.34854"
+ x="323.82025"
+ id="tspan4119"
+ sodipodi:role="line">XkbBoundsRec</tspan></text>
+ </g>
+ <g
+ id="g4427"
+ transform="translate(-0.40614801,0.58968744)">
+ <rect
+ y="262.71423"
+ x="48.139145"
+ height="101.40266"
+ width="112.58302"
+ id="rect3162-9-9-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="268.15759"
+ x="40.794804"
+ height="101.40266"
+ width="112.58302"
+ id="rect3162-9-4"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="273.60098"
+ x="33.450462"
+ height="101.40266"
+ width="112.58302"
+ id="rect3162-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-1"
+ y="288.58939"
+ x="80.199982"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="288.58939"
+ x="80.199982"
+ id="tspan3053-0-1-0-0-5"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-6"
+ d="m 146.03348,300.34318 -112.583008,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-1"
+ d="m 146.03348,325.33904 -112.583018,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-7"
+ d="m 146.03348,350.33489 -112.583018,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2"
+ y="341.11234"
+ x="75.442169"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="341.11234"
+ x="75.442169"
+ id="tspan3053-2"
+ sodipodi:role="line">rows</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-9"
+ y="367.30643"
+ x="67.4617"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="367.30643"
+ x="67.4617"
+ id="tspan3053-28"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2-1"
+ y="315.98465"
+ x="47.2117"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="315.98465"
+ x="47.2117"
+ id="tspan3053-2-2"
+ sodipodi:role="line">section_under</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-3"
+ y="394.22635"
+ x="90.009842"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="394.22635"
+ x="90.009842"
+ id="tspan3053-0-1-0-4-7"
+ sodipodi:role="line">XkbOverlayRec(s)</tspan><tspan
+ id="tspan3160-7"
+ y="409.22635"
+ x="90.009842"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ transform="translate(-0.79825864,249.71697)"
+ id="g4121-2">
+ <rect
+ y="215.03053"
+ x="267.66156"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-4-7"
+ y="258.34854"
+ x="323.82025"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="258.34854"
+ x="323.82025"
+ id="tspan4119-2"
+ sodipodi:role="line">XkbBoundsRec</tspan></text>
+ </g>
+ <g
+ id="g4510"
+ transform="translate(-0.40614801,0.58968744)">
+ <rect
+ y="360.0163"
+ x="490.64758"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073-3-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-4-7-7"
+ y="418.0802"
+ x="530.71991"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="418.0802"
+ x="530.71991"
+ id="tspan4119-2-6"
+ sodipodi:role="line">XkbOverlayKeyRec(s)</tspan><tspan
+ id="tspan4476"
+ y="433.0802"
+ x="530.71991"
+ sodipodi:role="line">(array)</tspan></text>
+ <rect
+ y="365.4707"
+ x="484.94928"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073-3-3-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="370.92514"
+ x="479.25107"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073-3-3-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="376.37955"
+ x="473.5528"
+ height="25.619999"
+ width="111.91895"
+ id="rect4073-3-3-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g4665"
+ transform="translate(-0.40614801,0.58968744)">
+ <rect
+ y="314.26517"
+ x="278.14392"
+ height="71.910835"
+ width="112.58302"
+ id="rect3162-9-9-3-4"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="319.70853"
+ x="270.79956"
+ height="74.591911"
+ width="112.58302"
+ id="rect3162-9-4-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="325.15192"
+ x="263.45526"
+ height="75.932442"
+ width="112.58302"
+ id="rect3162-6-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-1-5"
+ y="340.14032"
+ x="310.20477"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="340.14032"
+ x="310.20477"
+ id="tspan3053-0-1-0-0-5-8"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-6-5"
+ d="m 376.03828,351.89412 -112.58301,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-1-0"
+ d="m 376.03828,376.88998 -112.58302,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2-9"
+ y="392.66327"
+ x="305.44696"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="392.66327"
+ x="305.44696"
+ id="tspan3053-2-8"
+ sodipodi:role="line">keys</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2-1-4"
+ y="367.53558"
+ x="287.69598"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="367.53558"
+ x="287.69598"
+ id="tspan3053-2-2-9"
+ sodipodi:role="line">row_under</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-3-0"
+ y="423.00977"
+ x="321.35516"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="423.00977"
+ x="321.35516"
+ id="tspan3053-0-1-0-4-7-1"
+ sodipodi:role="line">XkbOverlayRowRec(s)</tspan><tspan
+ id="tspan3160-7-2"
+ y="438.00977"
+ x="321.35516"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4843"
+ transform="translate(3.5790918,-1.4029325)">
+ <rect
+ y="61.563065"
+ x="277.7085"
+ height="71.910835"
+ width="112.58302"
+ id="rect3162-9-9-3-4-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="67.006432"
+ x="270.36414"
+ height="74.591911"
+ width="112.58302"
+ id="rect3162-9-4-0-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="72.449821"
+ x="263.01984"
+ height="75.932442"
+ width="112.58302"
+ id="rect3162-6-3-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-3-1-5-9"
+ y="87.438217"
+ x="309.76935"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="87.438217"
+ x="309.76935"
+ id="tspan3053-0-1-0-0-5-8-0"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-6-5-8"
+ d="m 375.60286,99.192017 -112.58301,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3162-5-1-0-3"
+ d="m 375.60286,124.18788 -112.58302,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2-9-8"
+ y="139.96117"
+ x="297.03107"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="139.96117"
+ x="297.03107"
+ id="tspan4757"
+ sodipodi:role="line">bounds</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-2-1-4-3"
+ y="114.83348"
+ x="305.42169"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="114.83348"
+ x="305.42169"
+ id="tspan4755"
+ sodipodi:role="line">keys</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-0-3-0-0"
+ y="166.30766"
+ x="320.91974"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="166.30766"
+ x="320.91974"
+ id="tspan3053-0-1-0-4-7-1-0"
+ sodipodi:role="line">XkbRowRec(s)</tspan><tspan
+ id="tspan3160-7-2-5"
+ y="181.30766"
+ x="320.91974"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="493.92169"
+ y="100.05532"
+ id="text3051-7-5-1-0-3-0-0-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan4859"
+ x="493.92169"
+ y="100.05532">XkbSectionRec and</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4861"
+ x="493.92169"
+ y="115.05532">XkbRowRec</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4863"
+ x="493.92169"
+ y="130.05533">repeated from</tspan><tspan
+ sodipodi:role="line"
+ id="tspan4865"
+ x="493.92169"
+ y="145.05533">Figure 16.4</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 145.46125,362.65683 119.5572,113.57933"
+ id="path4958"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 145.60912,338.53209 115.94557,-10e-6"
+ id="path4958-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="M 145.5454,87.692901 264.67217,87.340642"
+ id="path4958-1-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 375.45797,390.57851 96.04348,-10e-6"
+ id="path4958-1-1-5"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 145.83487,315.83026 48.44557,0 -0.99631,-255.040592 -46.88701,0"
+ id="path5476"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 375.34503,362.86422 67.01661,-0.24908 -1.2869,-281.955712 -61.19742,0"
+ id="path5476-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 378.59041,134.56566 26.90775,0 -0.51891,94.05478 -23.86993,0"
+ id="path5476-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-13.svg b/libX11/specs/XKB/XKBlib-13.svg
new file mode 100644
index 000000000..673071cd6
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-13.svg
@@ -0,0 +1,186 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="600"
+ height="170"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-13.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-13.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4" />
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.69768357"
+ inkscape:cx="459.30887"
+ inkscape:cy="62.403188"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3070"
+ width="82.804947"
+ height="50.751419"
+ x="150.47351"
+ y="23.978369" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3070-6"
+ width="82.804947"
+ height="50.751419"
+ x="478.577"
+ y="23.978369" />
+ <path
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 290.69704,24.854788 0,20.9375 -31.15625,0 0,28.9375 82.8125,0 0,-49.875 -51.65625,0 z"
+ id="rect3070-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 67.675844,41.992274 c 0,4.439414 -4.421479,6.925014 -9.354161,6.925014 -21.438677,0.373651 -23.427512,-1.630571 -23.15625,16.9375 0,4.93268 3.973568,8.875 8.90625,8.875 l 64.093757,0 c 4.93268,0 8.90625,-3.94232 8.90625,-8.875 l 0,-29.40625 c 0,-4.932682 -3.97357,-8.90625 -8.90625,-8.90625 -35.468805,-0.598929 -41.158603,-1.77138 -40.489596,14.449986 z"
+ id="rect3116"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccsssscc" />
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="75.926125"
+ y="97.879562"
+ id="text3141"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3145"
+ x="75.926125"
+ y="97.879562">actual key</tspan><tspan
+ sodipodi:role="line"
+ id="tspan3147"
+ x="75.926125"
+ y="112.87956">surface</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="191.83496"
+ y="97.879562"
+ id="text3141-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3147-3"
+ x="191.83496"
+ y="97.879562">approximate</tspan><tspan
+ sodipodi:role="line"
+ x="191.83496"
+ y="112.87956"
+ id="tspan3175">outline</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="300.58084"
+ y="97.879562"
+ id="text3141-1-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="300.58084"
+ y="97.879562"
+ id="tspan3175-4">primary</tspan><tspan
+ sodipodi:role="line"
+ x="300.58084"
+ y="112.87956"
+ id="tspan3203">outline</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="410.9874"
+ y="97.879562"
+ id="text3141-1-0-5"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="410.9874"
+ y="97.879562"
+ id="tspan3203-2">detailed</tspan><tspan
+ sodipodi:role="line"
+ x="410.9874"
+ y="112.87956"
+ id="tspan3231">outline</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="519.97949"
+ y="97.879562"
+ id="text3141-1-0-5-4"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="519.97949"
+ y="97.879562"
+ id="tspan3231-9">bounding</tspan><tspan
+ sodipodi:role="line"
+ x="519.97949"
+ y="112.87956"
+ id="tspan3259">box</tspan></text>
+ <path
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 402.3416,41.992274 c 0,4.439414 -4.42148,6.925014 -9.35416,6.925014 -21.43868,0.373651 -23.42751,-1.630571 -23.15625,16.9375 0,4.93268 3.97357,8.875 8.90625,8.875 l 64.09376,0 c 4.93268,0 8.90625,-3.94232 8.90625,-8.875 l 0,-29.40625 c 0,-4.932682 -3.97357,-8.90625 -8.90625,-8.90625 -35.46881,-0.598929 -41.15861,-1.77138 -40.4896,14.449986 z"
+ id="rect3116-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccsssscc" />
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="296.95737"
+ y="145.26933"
+ id="text3141-1-0-5-4-4"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="296.95737"
+ y="145.26933"
+ id="tspan3259-8">outline array</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 141.53981,130.22552 0,11.46652 102.48199,0"
+ id="path3307"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 451.85241,130.22552 0,11.46652 -102.48199,0"
+ id="path3307-1"
+ inkscape:connector-curvature="0" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-14.svg b/libX11/specs/XKB/XKBlib-14.svg
new file mode 100644
index 000000000..0ac948c9a
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-14.svg
@@ -0,0 +1,557 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="550"
+ height="150"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-14.svg"
+ style="display:inline"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-14.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Mend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Mend"
+ style="overflow:visible">
+ <path
+ id="path4715"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="scale(-0.6,-0.6)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Mend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Mend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4715-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="scale(-0.6,-0.6)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.7327273"
+ inkscape:cx="288.60377"
+ inkscape:cy="28.83001"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <g
+ id="g3161">
+ <rect
+ ry="0"
+ rx="8.6568727"
+ y="48.426022"
+ x="281.63693"
+ height="24.81637"
+ width="100.41972"
+ id="rect4240"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3086-4-1"
+ y="120.41444"
+ x="287.22552"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="120.41444"
+ x="287.22552"
+ id="tspan3134"
+ sodipodi:role="line">Core Symbols</tspan></text>
+ <g
+ transform="matrix(1.163736,0,0,1.163736,55.863634,-154.12909)"
+ id="text3086-4-1-7-4"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3234-7"
+ d="m 268.03934,181.84424 -1.5,3.57422 2.20898,0 0,-3.57422 -0.70898,0 m -1.5586,-1.5 8.34961,0 0,1.70508 -3.82617,0 0,1.6289 3.59766,0 0,1.70508 -3.59766,0 0,2.00391 3.96094,0 0,1.70508 -6.2168,0 0,-2.05079 -2.89453,0 -0.86133,2.05079 -2.17383,0 3.66211,-8.74805" />
+ </g>
+ <g
+ transform="translate(199.4078,-128.3859)"
+ id="text3086-4-1-7-2-3"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3267-7"
+ d="m 148.543,188.37929 c -1e-5,-0.46484 -0.13673,-0.83854 -0.41016,-1.1211 -0.26889,-0.2871 -0.62208,-0.43065 -1.05957,-0.43066 -0.46941,1e-5 -0.84994,0.13445 -1.1416,0.40332 -0.29167,0.26433 -0.47397,0.64714 -0.54687,1.14844 l 3.1582,0 m -6.87012,1.21679 c -0.51042,1e-5 -0.89551,0.0866 -1.15527,0.25977 -0.25521,0.17318 -0.38282,0.42839 -0.38281,0.76563 -1e-5,0.30989 0.10253,0.55371 0.30761,0.73144 0.20964,0.17318 0.49902,0.25977 0.86817,0.25977 0.46028,0 0.84765,-0.16406 1.16211,-0.49219 0.31444,-0.33268 0.47167,-0.74739 0.47168,-1.24414 l 0,-0.28028 -1.27149,0 m -3.33594,-4.00585 c 0.54232,-0.1276 1.06641,-0.2233 1.57227,-0.28711 0.51041,-0.0684 0.98665,-0.10254 1.42871,-0.10254 0.68359,0 1.27148,0.0889 1.76367,0.2666 0.49674,0.17318 0.9069,0.43978 1.23047,0.7998 0.35091,-0.3509 0.75878,-0.61522 1.22363,-0.79297 0.46484,-0.18228 0.97526,-0.27343 1.53125,-0.27343 1.20768,0 2.17154,0.36231 2.89161,1.08691 0.72459,0.72462 1.0869,1.69304 1.08691,2.90527 l 0,0.69727 -5.72852,0 c 0.0638,0.57422 0.27115,1.00488 0.62207,1.29199 0.35546,0.28711 0.85449,0.43067 1.49708,0.43067 0.51496,0 1.04132,-0.0752 1.5791,-0.22559 0.5423,-0.15495 1.09829,-0.38737 1.66797,-0.69727 l 0,1.88672 c -0.57879,0.21875 -1.15985,0.38282 -1.74317,0.49219 -0.57879,0.11393 -1.15528,0.1709 -1.72949,0.1709 -0.81577,0 -1.5267,-0.12077 -2.13281,-0.36231 -0.60157,-0.24609 -1.06642,-0.597 -1.39453,-1.05273 -0.4603,0.48763 -0.94565,0.84538 -1.45606,1.07324 -0.50586,0.22787 -1.07552,0.3418 -1.70898,0.3418 -0.88412,0 -1.58366,-0.22331 -2.09864,-0.66992 -0.51497,-0.45117 -0.77246,-1.05957 -0.77246,-1.8252 0,-0.89778 0.30762,-1.55631 0.92285,-1.97558 0.61979,-0.41927 1.5905,-0.62891 2.91211,-0.62891 l 1.44239,0 0,-0.19141 c -1e-5,-0.38736 -0.15268,-0.66991 -0.45801,-0.84765 -0.30535,-0.18229 -0.78158,-0.27343 -1.42871,-0.27344 -0.52409,1e-5 -1.01172,0.0524 -1.46289,0.15723 -0.45118,0.10482 -0.87045,0.26205 -1.25782,0.47168 l 0,-1.86621" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-9-87"
+ y="65.937233"
+ x="313.34781"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="65.937233"
+ x="313.34781"
+ id="tspan3378-31"
+ sodipodi:role="line">A</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-3"
+ y="64.655495"
+ x="289.28244"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="64.655495"
+ x="289.28244"
+ id="tspan3355-1"
+ sodipodi:role="line">a</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4240-7"
+ d="m 306.26094,73.242392 0,-24.81637"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4240-7-9"
+ d="m 331.26965,73.242392 0,-24.81637"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4240-7-1"
+ d="m 356.2784,73.242392 0,-24.81637"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325"
+ y="44.38615"
+ x="286.25394"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="44.38615"
+ x="286.25394"
+ id="tspan4327"
+ sodipodi:role="line">L1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-5"
+ y="44.465252"
+ x="312.53479"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="44.465252"
+ x="312.53479"
+ id="tspan4350"
+ sodipodi:role="line">L2</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-9"
+ y="44.38615"
+ x="336.77405"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="44.38615"
+ x="336.77405"
+ id="tspan4327-1"
+ sodipodi:role="line">L1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-5-8"
+ y="44.465252"
+ x="361.06015"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan4350-8"
+ sodipodi:role="line"
+ x="361.06015"
+ y="44.465252">L2</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79"
+ y="86.273293"
+ x="298.10666"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="86.273293"
+ x="298.10666"
+ id="tspan4457"
+ sodipodi:role="line">G1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-6"
+ y="86.273293"
+ x="347.8331"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="86.273293"
+ x="347.8331"
+ id="tspan4480"
+ sodipodi:role="line">G2</tspan></text>
+ </g>
+ <g
+ id="g3138">
+ <rect
+ rx="0"
+ y="44.38615"
+ x="459.39139"
+ height="48.478489"
+ width="48.478489"
+ id="rect4286"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3086-4-1-6"
+ y="120.41443"
+ x="431.91623"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="120.41443"
+ x="431.91623"
+ id="tspan3157"
+ sodipodi:role="line">Xkb Symbols</tspan></text>
+ <g
+ transform="matrix(1.163736,0,0,1.163736,182.83109,-133.64116)"
+ id="text3086-4-1-7-8"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3234-6"
+ d="m 268.03934,181.84424 -1.5,3.57422 2.20898,0 0,-3.57422 -0.70898,0 m -1.5586,-1.5 8.34961,0 0,1.70508 -3.82617,0 0,1.6289 3.59766,0 0,1.70508 -3.59766,0 0,2.00391 3.96094,0 0,1.70508 -6.2168,0 0,-2.05079 -2.89453,0 -0.86133,2.05079 -2.17383,0 3.66211,-8.74805" />
+ </g>
+ <g
+ transform="translate(327.14478,-106.82729)"
+ id="text3086-4-1-7-2-3-7"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3267-7-2"
+ d="m 148.543,188.37929 c -1e-5,-0.46484 -0.13673,-0.83854 -0.41016,-1.1211 -0.26889,-0.2871 -0.62208,-0.43065 -1.05957,-0.43066 -0.46941,1e-5 -0.84994,0.13445 -1.1416,0.40332 -0.29167,0.26433 -0.47397,0.64714 -0.54687,1.14844 l 3.1582,0 m -6.87012,1.21679 c -0.51042,1e-5 -0.89551,0.0866 -1.15527,0.25977 -0.25521,0.17318 -0.38282,0.42839 -0.38281,0.76563 -1e-5,0.30989 0.10253,0.55371 0.30761,0.73144 0.20964,0.17318 0.49902,0.25977 0.86817,0.25977 0.46028,0 0.84765,-0.16406 1.16211,-0.49219 0.31444,-0.33268 0.47167,-0.74739 0.47168,-1.24414 l 0,-0.28028 -1.27149,0 m -3.33594,-4.00585 c 0.54232,-0.1276 1.06641,-0.2233 1.57227,-0.28711 0.51041,-0.0684 0.98665,-0.10254 1.42871,-0.10254 0.68359,0 1.27148,0.0889 1.76367,0.2666 0.49674,0.17318 0.9069,0.43978 1.23047,0.7998 0.35091,-0.3509 0.75878,-0.61522 1.22363,-0.79297 0.46484,-0.18228 0.97526,-0.27343 1.53125,-0.27343 1.20768,0 2.17154,0.36231 2.89161,1.08691 0.72459,0.72462 1.0869,1.69304 1.08691,2.90527 l 0,0.69727 -5.72852,0 c 0.0638,0.57422 0.27115,1.00488 0.62207,1.29199 0.35546,0.28711 0.85449,0.43067 1.49708,0.43067 0.51496,0 1.04132,-0.0752 1.5791,-0.22559 0.5423,-0.15495 1.09829,-0.38737 1.66797,-0.69727 l 0,1.88672 c -0.57879,0.21875 -1.15985,0.38282 -1.74317,0.49219 -0.57879,0.11393 -1.15528,0.1709 -1.72949,0.1709 -0.81577,0 -1.5267,-0.12077 -2.13281,-0.36231 -0.60157,-0.24609 -1.06642,-0.597 -1.39453,-1.05273 -0.4603,0.48763 -0.94565,0.84538 -1.45606,1.07324 -0.50586,0.22787 -1.07552,0.3418 -1.70898,0.3418 -0.88412,0 -1.58366,-0.22331 -2.09864,-0.66992 -0.51497,-0.45117 -0.77246,-1.05957 -0.77246,-1.8252 0,-0.89778 0.30762,-1.55631 0.92285,-1.97558 0.61979,-0.41927 1.5905,-0.62891 2.91211,-0.62891 l 1.44239,0 0,-0.19141 c -1e-5,-0.38736 -0.15268,-0.66991 -0.45801,-0.84765 -0.30535,-0.18229 -0.78158,-0.27343 -1.42871,-0.27344 -0.52409,1e-5 -1.01172,0.0524 -1.46289,0.15723 -0.45118,0.10482 -0.87045,0.26205 -1.25782,0.47168 l 0,-1.86621" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-9-0"
+ y="61.608799"
+ x="490.33276"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="61.608799"
+ x="490.33276"
+ id="tspan3378-0"
+ sodipodi:role="line">A</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-8"
+ y="61.410557"
+ x="464.72839"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="61.410557"
+ x="464.72839"
+ id="tspan3355-01"
+ sodipodi:role="line">a</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4286-0"
+ d="m 508.447,68.625395 -48.47849,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4286-0-3"
+ d="m 483.63063,92.287513 0,-48.47849"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-7"
+ y="40.103302"
+ x="463.74152"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="40.103302"
+ x="463.74152"
+ id="tspan4327-0"
+ sodipodi:role="line">L1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-5-5"
+ y="39.605278"
+ x="487.4505"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan4350-2"
+ sodipodi:role="line"
+ x="487.4505"
+ y="39.605278">L2</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-68"
+ y="61.957432"
+ x="439.01883"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="61.957432"
+ x="439.01883"
+ id="tspan4457-4"
+ sodipodi:role="line">G1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-6-6"
+ y="86.760986"
+ x="439.0657"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="86.760986"
+ x="439.0657"
+ id="tspan4480-6"
+ sodipodi:role="line">G2</tspan></text>
+ </g>
+ <g
+ id="g4663">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3086-4"
+ y="120.99155"
+ x="176.48442"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="120.99155"
+ x="176.48442"
+ id="tspan3111"
+ sodipodi:role="line">Symbols</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-5"
+ y="39.859066"
+ x="221.81828"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="39.859066"
+ x="221.81828"
+ id="tspan3355-0"
+ sodipodi:role="line">a</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-7"
+ y="40.405941"
+ x="173.5414"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="40.405941"
+ x="173.5414"
+ id="tspan4457-2"
+ sodipodi:role="line">G1L1 =</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-9-8"
+ y="58.23595"
+ x="222.35149"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="58.23595"
+ x="222.35149"
+ id="tspan3378-3"
+ sodipodi:role="line">A</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-74"
+ y="57.501087"
+ x="173.5414"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="57.501087"
+ x="173.5414"
+ id="tspan4457-1"
+ sodipodi:role="line">G1L2 =</tspan></text>
+ <g
+ transform="translate(84.752833,-118.99205)"
+ id="text3086-4-1-7-2"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3267"
+ d="m 148.543,188.37929 c -1e-5,-0.46484 -0.13673,-0.83854 -0.41016,-1.1211 -0.26889,-0.2871 -0.62208,-0.43065 -1.05957,-0.43066 -0.46941,1e-5 -0.84994,0.13445 -1.1416,0.40332 -0.29167,0.26433 -0.47397,0.64714 -0.54687,1.14844 l 3.1582,0 m -6.87012,1.21679 c -0.51042,1e-5 -0.89551,0.0866 -1.15527,0.25977 -0.25521,0.17318 -0.38282,0.42839 -0.38281,0.76563 -1e-5,0.30989 0.10253,0.55371 0.30761,0.73144 0.20964,0.17318 0.49902,0.25977 0.86817,0.25977 0.46028,0 0.84765,-0.16406 1.16211,-0.49219 0.31444,-0.33268 0.47167,-0.74739 0.47168,-1.24414 l 0,-0.28028 -1.27149,0 m -3.33594,-4.00585 c 0.54232,-0.1276 1.06641,-0.2233 1.57227,-0.28711 0.51041,-0.0684 0.98665,-0.10254 1.42871,-0.10254 0.68359,0 1.27148,0.0889 1.76367,0.2666 0.49674,0.17318 0.9069,0.43978 1.23047,0.7998 0.35091,-0.3509 0.75878,-0.61522 1.22363,-0.79297 0.46484,-0.18228 0.97526,-0.27343 1.53125,-0.27343 1.20768,0 2.17154,0.36231 2.89161,1.08691 0.72459,0.72462 1.0869,1.69304 1.08691,2.90527 l 0,0.69727 -5.72852,0 c 0.0638,0.57422 0.27115,1.00488 0.62207,1.29199 0.35546,0.28711 0.85449,0.43067 1.49708,0.43067 0.51496,0 1.04132,-0.0752 1.5791,-0.22559 0.5423,-0.15495 1.09829,-0.38737 1.66797,-0.69727 l 0,1.88672 c -0.57879,0.21875 -1.15985,0.38282 -1.74317,0.49219 -0.57879,0.11393 -1.15528,0.1709 -1.72949,0.1709 -0.81577,0 -1.5267,-0.12077 -2.13281,-0.36231 -0.60157,-0.24609 -1.06642,-0.597 -1.39453,-1.05273 -0.4603,0.48763 -0.94565,0.84538 -1.45606,1.07324 -0.50586,0.22787 -1.07552,0.3418 -1.70898,0.3418 -0.88412,0 -1.58366,-0.22331 -2.09864,-0.66992 -0.51497,-0.45117 -0.77246,-1.05957 -0.77246,-1.8252 0,-0.89778 0.30762,-1.55631 0.92285,-1.97558 0.61979,-0.41927 1.5905,-0.62891 2.91211,-0.62891 l 1.44239,0 0,-0.19141 c -1e-5,-0.38736 -0.15268,-0.66991 -0.45801,-0.84765 -0.30535,-0.18229 -0.78158,-0.27343 -1.42871,-0.27344 -0.52409,1e-5 -1.01172,0.0524 -1.46289,0.15723 -0.45118,0.10482 -0.87045,0.26205 -1.25782,0.47168 l 0,-1.86621" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-0"
+ y="74.59623"
+ x="173.5414"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="74.59623"
+ x="173.5414"
+ id="tspan4457-0"
+ sodipodi:role="line">G2L1 =</tspan></text>
+ <g
+ transform="matrix(1.163736,0,0,1.163736,-83.431648,-127.64009)"
+ id="text3086-4-1-7"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3234"
+ d="m 268.03934,181.84424 -1.5,3.57422 2.20898,0 0,-3.57422 -0.70898,0 m -1.5586,-1.5 8.34961,0 0,1.70508 -3.82617,0 0,1.6289 3.59766,0 0,1.70508 -3.59766,0 0,2.00391 3.96094,0 0,1.70508 -6.2168,0 0,-2.05079 -2.89453,0 -0.86133,2.05079 -2.17383,0 3.66211,-8.74805" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text4325-79-64"
+ y="91.691368"
+ x="173.5414"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="91.691368"
+ x="173.5414"
+ id="tspan4457-43"
+ sodipodi:role="line">G2L2 =</tspan></text>
+ </g>
+ <g
+ id="g3189">
+ <rect
+ rx="8.6568727"
+ ry="8.6568727"
+ y="19.569786"
+ x="57.712486"
+ height="73.871986"
+ width="63.483734"
+ id="rect3458"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="8.6568727"
+ rx="8.6568727"
+ y="24.186779"
+ x="64.06086"
+ height="50.786987"
+ width="50.786987"
+ id="rect3460"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3086"
+ y="119.98951"
+ x="40.975864"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="119.98951"
+ x="40.975864"
+ id="tspan3088"
+ sodipodi:role="line">Physical Key</tspan></text>
+ <text
+ transform="matrix(0,-1,1,0,0,0)"
+ sodipodi:linespacing="125%"
+ id="text3086-2"
+ y="53.643921"
+ x="-92.862938"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="53.643921"
+ x="-92.862938"
+ id="tspan3210"
+ sodipodi:role="line">Shift Level</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3086-2-1"
+ y="105.41803"
+ x="62.852604"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="105.41803"
+ x="62.852604"
+ id="tspan3210-2"
+ sodipodi:role="line">Group</tspan></text>
+ <g
+ transform="translate(-45.888592,-129.55559)"
+ id="text3086-4-1-7-2-3-3"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#999999;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ style="fill:#999999"
+ inkscape:connector-curvature="0"
+ id="path3267-7-7"
+ d="m 148.543,188.37929 c -1e-5,-0.46484 -0.13673,-0.83854 -0.41016,-1.1211 -0.26889,-0.2871 -0.62208,-0.43065 -1.05957,-0.43066 -0.46941,1e-5 -0.84994,0.13445 -1.1416,0.40332 -0.29167,0.26433 -0.47397,0.64714 -0.54687,1.14844 l 3.1582,0 m -6.87012,1.21679 c -0.51042,1e-5 -0.89551,0.0866 -1.15527,0.25977 -0.25521,0.17318 -0.38282,0.42839 -0.38281,0.76563 -1e-5,0.30989 0.10253,0.55371 0.30761,0.73144 0.20964,0.17318 0.49902,0.25977 0.86817,0.25977 0.46028,0 0.84765,-0.16406 1.16211,-0.49219 0.31444,-0.33268 0.47167,-0.74739 0.47168,-1.24414 l 0,-0.28028 -1.27149,0 m -3.33594,-4.00585 c 0.54232,-0.1276 1.06641,-0.2233 1.57227,-0.28711 0.51041,-0.0684 0.98665,-0.10254 1.42871,-0.10254 0.68359,0 1.27148,0.0889 1.76367,0.2666 0.49674,0.17318 0.9069,0.43978 1.23047,0.7998 0.35091,-0.3509 0.75878,-0.61522 1.22363,-0.79297 0.46484,-0.18228 0.97526,-0.27343 1.53125,-0.27343 1.20768,0 2.17154,0.36231 2.89161,1.08691 0.72459,0.72462 1.0869,1.69304 1.08691,2.90527 l 0,0.69727 -5.72852,0 c 0.0638,0.57422 0.27115,1.00488 0.62207,1.29199 0.35546,0.28711 0.85449,0.43067 1.49708,0.43067 0.51496,0 1.04132,-0.0752 1.5791,-0.22559 0.5423,-0.15495 1.09829,-0.38737 1.66797,-0.69727 l 0,1.88672 c -0.57879,0.21875 -1.15985,0.38282 -1.74317,0.49219 -0.57879,0.11393 -1.15528,0.1709 -1.72949,0.1709 -0.81577,0 -1.5267,-0.12077 -2.13281,-0.36231 -0.60157,-0.24609 -1.06642,-0.597 -1.39453,-1.05273 -0.4603,0.48763 -0.94565,0.84538 -1.45606,1.07324 -0.50586,0.22787 -1.07552,0.3418 -1.70898,0.3418 -0.88412,0 -1.58366,-0.22331 -2.09864,-0.66992 -0.51497,-0.45117 -0.77246,-1.05957 -0.77246,-1.8252 0,-0.89778 0.30762,-1.55631 0.92285,-1.97558 0.61979,-0.41927 1.5905,-0.62891 2.91211,-0.62891 l 1.44239,0 0,-0.19141 c -1e-5,-0.38736 -0.15268,-0.66991 -0.45801,-0.84765 -0.30535,-0.18229 -0.78158,-0.27343 -1.42871,-0.27344 -0.52409,1e-5 -1.01172,0.0524 -1.46289,0.15723 -0.45118,0.10482 -0.87045,0.26205 -1.25782,0.47168 l 0,-1.86621" />
+ </g>
+ <g
+ transform="matrix(1.163736,0,0,1.163736,-214.44151,-178.38377)"
+ id="text3086-4-1-7-25"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3234-3"
+ d="m 268.03934,181.84424 -1.5,3.57422 2.20898,0 0,-3.57422 -0.70898,0 m -1.5586,-1.5 8.34961,0 0,1.70508 -3.82617,0 0,1.6289 3.59766,0 0,1.70508 -3.59766,0 0,2.00391 3.96094,0 0,1.70508 -6.2168,0 0,-2.05079 -2.89453,0 -0.86133,2.05079 -2.17383,0 3.66211,-8.74805" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353"
+ y="63.485809"
+ x="74.238411"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#999999;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="63.485809"
+ x="74.238411"
+ id="tspan3355"
+ sodipodi:role="line">a</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3353-9"
+ y="41.682552"
+ x="73.295052"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans Bold"
+ xml:space="preserve"><tspan
+ y="41.682552"
+ x="73.295052"
+ id="tspan3378"
+ sodipodi:role="line">A</tspan></text>
+ <path
+ inkscape:connector-curvature="0"
+ id="path4683"
+ d="m 105.03673,101.52151 11.54249,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Mend)" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path4683-4"
+ d="m 51.950847,27.215961 0,-11.54249"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Mend)" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-15.svg b/libX11/specs/XKB/XKBlib-15.svg
new file mode 100644
index 000000000..43d3e71da
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-15.svg
@@ -0,0 +1,885 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="500"
+ height="520"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-15.svg"
+ style="display:inline"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-15.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4736"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4736-44"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.4740457"
+ inkscape:cx="211.44949"
+ inkscape:cy="268.6145"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <g
+ id="g5523">
+ <rect
+ rx="0"
+ y="14.391144"
+ x="29.261993"
+ height="149.18819"
+ width="82.509224"
+ id="rect3070"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840"
+ y="181.32841"
+ x="31.405277"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="181.32841"
+ x="31.405277"
+ id="tspan3842"
+ sodipodi:role="line">XkbClientMapRec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-7"
+ y="27.427563"
+ x="47.115726"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="27.427563"
+ x="47.115726"
+ id="tspan3842-0"
+ sodipodi:role="line">size_types</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-5"
+ y="45.751293"
+ x="45.579838"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="45.751293"
+ x="45.579838"
+ id="tspan3842-1"
+ sodipodi:role="line">num_types</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-1"
+ y="64.459572"
+ x="58.216312"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="64.459572"
+ x="58.216312"
+ id="tspan3842-03"
+ sodipodi:role="line">types</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-0"
+ y="83.176636"
+ x="47.774906"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="83.176636"
+ x="47.774906"
+ id="tspan3842-04"
+ sodipodi:role="line">size_syms</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-54"
+ y="100.86098"
+ x="46.239017"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="100.86098"
+ x="46.239017"
+ id="tspan3842-2"
+ sodipodi:role="line">num_syms</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-4"
+ y="119.56923"
+ x="58.752445"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="119.56923"
+ x="58.752445"
+ id="tspan3842-9"
+ sodipodi:role="line">syms</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-9"
+ y="138.9257"
+ x="38.572758"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="138.9257"
+ x="38.572758"
+ id="tspan3842-94"
+ sodipodi:role="line">key_sym_map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-98"
+ y="157.50873"
+ x="48.108891"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="157.50873"
+ x="48.108891"
+ id="tspan3842-16"
+ sodipodi:role="line">mod_map</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3"
+ d="m 28.782286,34.361408 82.509224,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-9"
+ d="m 28.94096,52.704586 82.50923,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-3"
+ d="m 29.741698,71.527456 82.509222,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-34"
+ d="m 29.741698,90.110465 82.509222,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-6"
+ d="m 29.261993,108.69349 82.509227,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-1"
+ d="m 29.741698,127.27653 82.509232,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3070-3-5"
+ d="m 29.741698,145.85954 82.509232,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g4147">
+ <g
+ id="g4034">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000"
+ width="80.730202"
+ height="18.99534"
+ x="166.88763"
+ y="452.83789" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-6"
+ width="80.730202"
+ height="18.99534"
+ x="162.70413"
+ y="456.90833" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-7"
+ width="80.730202"
+ height="18.99534"
+ x="158.52063"
+ y="460.97876" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-1"
+ width="80.730202"
+ height="18.99534"
+ x="154.33713"
+ y="465.04919" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-2"
+ y="497.38193"
+ x="197.65204"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="497.38193"
+ x="197.65204"
+ id="tspan3842-5"
+ sodipodi:role="line">unsigned char</tspan><tspan
+ id="tspan4121"
+ y="508.63193"
+ x="197.65204"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4199">
+ <g
+ id="g4034-2"
+ transform="translate(175.5373,-228.62249)">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-2"
+ width="80.730202"
+ height="18.99534"
+ x="166.88763"
+ y="452.83789" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-6-9"
+ width="80.730202"
+ height="18.99534"
+ x="162.70413"
+ y="456.90833" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-7-2"
+ width="80.730202"
+ height="18.99534"
+ x="158.52063"
+ y="460.97876" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-1-8"
+ width="80.730202"
+ height="18.99534"
+ x="154.33713"
+ y="465.04919" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-2-3"
+ y="269.91846"
+ x="370.70963"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="269.91846"
+ x="370.70963"
+ id="tspan3842-5-7"
+ sodipodi:role="line">KeySym(s)</tspan><tspan
+ id="tspan4121-6"
+ y="281.16846"
+ x="370.70963"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4251">
+ <g
+ id="g4034-1"
+ transform="translate(175.5373,-306.63907)">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-24"
+ width="80.730202"
+ height="18.99534"
+ x="166.88763"
+ y="452.83789" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-6-7"
+ width="80.730202"
+ height="18.99534"
+ x="162.70413"
+ y="456.90833" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-7-8"
+ width="80.730202"
+ height="18.99534"
+ x="158.52063"
+ y="460.97876" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-1-6"
+ width="80.730202"
+ height="18.99534"
+ x="154.33713"
+ y="465.04919" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-2-3-8"
+ y="191.2191"
+ x="371.03482"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="191.2191"
+ x="371.03482"
+ id="tspan3842-5-7-1"
+ sodipodi:role="line">Atom(s)</tspan><tspan
+ id="tspan4121-6-3"
+ y="202.4691"
+ x="371.03482"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4261">
+ <g
+ id="g4034-3"
+ transform="translate(175.5373,-385.33405)">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-77"
+ width="80.730202"
+ height="18.99534"
+ x="166.88763"
+ y="452.83789" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-6-2"
+ width="80.730202"
+ height="18.99534"
+ x="162.70413"
+ y="456.90833" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-7-3"
+ width="80.730202"
+ height="18.99534"
+ x="158.52063"
+ y="460.97876" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4000-1-7"
+ width="80.730202"
+ height="18.99534"
+ x="154.33713"
+ y="465.04919" />
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-2-3-8-6"
+ y="112.52413"
+ x="376.19012"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="112.52413"
+ x="376.19012"
+ id="tspan3842-5-7-1-4"
+ sodipodi:role="line">XkbKTMapEntryRec(s)</tspan><tspan
+ id="tspan4121-6-3-0"
+ y="123.77413"
+ x="376.19012"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4476">
+ <rect
+ y="259.76013"
+ x="161.90036"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350-0-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="263.59778"
+ x="157.10332"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="267.19556"
+ x="152.54613"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-3"
+ y="279.27258"
+ x="167.74013"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan4346"
+ y="279.27258"
+ x="167.74013"
+ sodipodi:role="line">kt_index[0]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-50"
+ y="297.34863"
+ x="167.74013"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="297.34863"
+ x="167.74013"
+ id="tspan3842-99"
+ sodipodi:role="line">kt_index[1]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-8"
+ y="315.42468"
+ x="167.74013"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="315.42468"
+ x="167.74013"
+ id="tspan3842-02"
+ sodipodi:role="line">kt_index[2]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-49"
+ y="333.50073"
+ x="167.74013"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="333.50073"
+ x="167.74013"
+ id="tspan3842-01"
+ sodipodi:role="line">kt_index[3]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-20"
+ y="351.57678"
+ x="169.31117"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="351.57678"
+ x="169.31117"
+ id="tspan3842-06"
+ sodipodi:role="line">group_info</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-39"
+ y="370.65039"
+ x="180.86879"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="370.65039"
+ x="180.86879"
+ id="tspan3842-08"
+ sodipodi:role="line">width</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-38"
+ y="388.72644"
+ x="180.20741"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="388.72644"
+ x="180.20741"
+ id="tspan3842-7"
+ sodipodi:role="line">offset</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3"
+ d="m 233.61625,285.95295 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-1"
+ d="m 233.61625,304.02899 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-0"
+ d="m 233.61625,322.10505 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-05"
+ d="m 233.61625,340.1811 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-03"
+ d="m 233.61625,358.25715 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-18"
+ d="m 233.61625,376.33319 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-38-7"
+ y="413.50281"
+ x="193.39928"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="413.50281"
+ x="193.39928"
+ id="tspan3842-7-9"
+ sodipodi:role="line">XkbSymMapRec(s)</tspan><tspan
+ id="tspan4474"
+ y="424.75281"
+ x="193.39928"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <g
+ id="g4680">
+ <rect
+ y="41.061157"
+ x="204.18091"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350-0-1-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="44.898811"
+ x="199.38387"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350-0-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="48.496574"
+ x="194.82668"
+ height="127.12177"
+ width="81.070114"
+ id="rect4350-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-3-9"
+ y="60.573608"
+ x="222.83511"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan4346-4"
+ y="60.573608"
+ x="222.83511"
+ sodipodi:role="line">mods</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-50-8"
+ y="78.649658"
+ x="209.78336"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="78.649658"
+ x="209.78336"
+ id="tspan3842-99-4"
+ sodipodi:role="line">num_levels</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-8-6"
+ y="96.725708"
+ x="210.10196"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="96.725708"
+ x="210.10196"
+ id="tspan3842-02-9"
+ sodipodi:role="line">map_count</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-49-2"
+ y="114.80177"
+ x="225.19717"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="114.80177"
+ x="225.19717"
+ id="tspan3842-01-9"
+ sodipodi:role="line">map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-20-0"
+ y="132.87781"
+ x="215.40836"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="132.87781"
+ x="215.40836"
+ id="tspan3842-06-3"
+ sodipodi:role="line">preserve</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-39-0"
+ y="151.95142"
+ x="222.42203"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="151.95142"
+ x="222.42203"
+ id="tspan3842-08-3"
+ sodipodi:role="line">name</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-38-3"
+ y="170.02747"
+ x="207.0961"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="170.02747"
+ x="207.0961"
+ id="tspan3842-7-7"
+ sodipodi:role="line">level_names</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-9"
+ d="m 275.89681,67.25398 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-1-4"
+ d="m 275.89681,85.33002 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-0-9"
+ d="m 275.89681,103.40608 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-05-9"
+ d="m 275.89681,121.48213 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-03-1"
+ d="m 275.89681,139.55818 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4350-3-18-9"
+ d="m 275.89681,157.63422 -81.07012,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3840-38-7-4"
+ y="190.80383"
+ x="235.61661"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="190.80383"
+ x="235.61661"
+ id="tspan3842-7-9-2"
+ sodipodi:role="line">XkbKeyTypeRec(s)</tspan><tspan
+ id="tspan4474-0"
+ y="202.05383"
+ x="235.61661"
+ sodipodi:role="line">(array)</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 275.76001,113.66094 24.29534,0.0291 0,-25.66421 28.78229,0"
+ id="path4708"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 275.25121,164.89 53.82628,0.12845"
+ id="path4710"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 112.07676,118.31742 40.46494,0.4797 0,127.66421 174.78229,0"
+ id="path4708-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 111.41912,59.398358 82.50469,-0.04116"
+ id="path4710-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 111.90702,136.53246 20.37057,-0.23986 -0.23985,138.26384 18.13168,0"
+ id="path4708-9-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 112.01383,154.91808 12.6529,0.0289 0,317.12774 28.14401,0"
+ id="path4708-9-3-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 233.67487,382.63489 42.39451,-0.1405 0,-147.66421 50.78229,0"
+ id="path4708-92"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)"
+ d="m 233.47105,277.65703 34.55934,-0.1405 0,-59.8321 -96,0.16789 -0.46529,-176 22.24319,0.232472"
+ id="path4708-92-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="m 95.461255,261.91882 55.003685,0"
+ id="path5300"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-4)"
+ d="m 108.89299,261.91882 -0.47971,198.59779 44.05166,0"
+ id="path5302"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;display:inline;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="49.759731"
+ y="264.01059"
+ id="text3840-93"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="49.759731"
+ y="264.01059"
+ id="tspan5519">Key Code</tspan></text>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-16.svg b/libX11/specs/XKB/XKBlib-16.svg
new file mode 100644
index 000000000..231c572b7
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-16.svg
@@ -0,0 +1,643 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="500"
+ height="380"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-16.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-16.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4426"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-6-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-6-8"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-31"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-6-00"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-31-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-6-00-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-03"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4426-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.0085576"
+ inkscape:cx="334.50885"
+ inkscape:cy="182.60923"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <g
+ id="g5627">
+ <g
+ id="g4129">
+ <g
+ transform="translate(2.103321,82.9059)"
+ id="g3912-44">
+ <rect
+ y="151.43912"
+ x="199.81549"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="155.29521"
+ x="195.25829"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="159.15129"
+ x="190.7011"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-7"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="163.00739"
+ x="186.14391"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-5-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="235.40326"
+ y="280.44281"
+ id="text3993"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3995"
+ x="235.40326"
+ y="280.44281">unsigned char(s)</tspan><tspan
+ sodipodi:role="line"
+ x="235.40326"
+ y="291.69281"
+ id="tspan3997">(array)</tspan></text>
+ </g>
+ <g
+ id="g4119">
+ <g
+ id="g3912"
+ transform="translate(2.103321,0)">
+ <rect
+ y="151.43912"
+ x="199.81549"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="155.29521"
+ x="195.25829"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="159.15129"
+ x="190.7011"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="163.00739"
+ x="186.14391"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="235.40326"
+ y="195.97231"
+ id="text3993-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3995-5"
+ x="235.40326"
+ y="195.97231">unsigned short(s)</tspan><tspan
+ sodipodi:role="line"
+ x="235.40326"
+ y="207.22231"
+ id="tspan3997-6">(array)</tspan></text>
+ </g>
+ <g
+ id="g4181">
+ <g
+ transform="translate(2.103321,162.13099)"
+ id="g3912-6">
+ <rect
+ y="151.43912"
+ x="199.81549"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="155.29521"
+ x="195.25829"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="159.15129"
+ x="190.7011"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-4"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="163.00739"
+ x="186.14391"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-5-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="235.40326"
+ y="357.22693"
+ id="text3993-1-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3995-5-7"
+ x="235.40326"
+ y="357.22693">unsigned short(s)</tspan><tspan
+ sodipodi:role="line"
+ x="235.40326"
+ y="368.47693"
+ id="tspan3997-6-2">(array)</tspan></text>
+ </g>
+ <g
+ id="g4109">
+ <g
+ transform="translate(2.103321,-71.337643)"
+ id="g3912-4">
+ <rect
+ y="151.43912"
+ x="199.81549"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-7"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="155.29521"
+ x="195.25829"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="159.15129"
+ x="190.7011"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-56"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="163.00739"
+ x="186.14391"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-5-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="235.65155"
+ y="123.90276"
+ id="text3993-1-2"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="235.65155"
+ y="123.90276"
+ id="tspan3997-6-28">XkbBehaviors(s)</tspan><tspan
+ sodipodi:role="line"
+ x="235.65155"
+ y="135.15277"
+ id="tspan4073">(array)</tspan></text>
+ </g>
+ <g
+ id="g4099">
+ <g
+ transform="translate(168.44097,-95.876388)"
+ id="g3912-3">
+ <rect
+ y="151.43912"
+ x="199.81549"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-74"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="155.29521"
+ x="195.25829"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-52"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="159.15129"
+ x="190.7011"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-54"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="163.00739"
+ x="186.14391"
+ height="18.92989"
+ width="80.627304"
+ id="rect3070-1-5-5-7"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="401.9892"
+ y="99.219536"
+ id="text3993-1-2-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="401.9892"
+ y="99.219536"
+ id="tspan3997-6-28-2">XkbActions(s)</tspan><tspan
+ sodipodi:role="line"
+ x="401.9892"
+ y="110.46954"
+ id="tspan4073-4">(array)</tspan></text>
+ </g>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3993-1-1-7"
+ y="275.8985"
+ x="63.106224"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3997-6-2-6"
+ y="275.8985"
+ x="63.106224"
+ sodipodi:role="line">KeyCode</tspan></text>
+ <g
+ id="g5599">
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.609657"
+ y="189.7818"
+ id="text3993-1-1-7-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.609657"
+ y="189.7818"
+ id="tspan3997-6-2-6-7">XkbServerMapRec</tspan></text>
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4214"
+ width="80.627304"
+ height="144.42804"
+ x="30.147602"
+ y="29.446495" />
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.27449"
+ y="41.147118"
+ id="text3993-1-1-7-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.27449"
+ y="41.147118"
+ id="tspan3997-6-2-6-2">num_acts</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.439285"
+ y="59.450569"
+ id="text3993-1-1-7-37"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.439285"
+ y="59.450569"
+ id="tspan3997-6-2-6-25">size_acts</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.412918"
+ y="78.233025"
+ id="text3993-1-1-7-376"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.412918"
+ y="78.233025"
+ id="tspan3997-6-2-6-8">acts</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.27449"
+ y="96.536484"
+ id="text3993-1-1-7-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.27449"
+ y="96.536484"
+ id="tspan3997-6-2-6-3">behaviors</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.27449"
+ y="113.58308"
+ id="text3993-1-1-7-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.27449"
+ y="113.58308"
+ id="tspan3997-6-2-6-4">key_acts</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.32283"
+ y="131.7525"
+ id="text3993-1-1-7-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.32283"
+ y="131.7525"
+ id="tspan3997-6-2-6-35">explicit</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.716141"
+ y="150.13945"
+ id="text3993-1-1-7-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.716141"
+ y="150.13945"
+ id="tspan3997-6-2-6-5">vmods[16]</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="70.573318"
+ y="167.84085"
+ id="text3993-1-1-7-09"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="70.573318"
+ y="167.84085"
+ id="tspan3997-6-2-6-9">vmodmap</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147601,48.070809 80.627309,0"
+ id="rect4214-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147602,66.114999 80.627308,0"
+ id="rect4214-8-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147602,84.15916 80.627308,0"
+ id="rect4214-8-2"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147603,102.20332 80.627307,0"
+ id="rect4214-8-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147603,120.2475 80.627307,0"
+ id="rect4214-8-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147603,138.29169 80.627307,0"
+ id="rect4214-8-01"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 30.147602,156.33585 80.627308,0"
+ id="rect4214-8-20"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ </g>
+ <path
+ inkscape:connector-curvature="0"
+ id="path4400"
+ d="m 110.77491,72.915129 242.58302,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path4400-3"
+ d="m 111.76312,93.264848 74.19101,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)" />
+ <path
+ sodipodi:nodetypes="cccc"
+ inkscape:connector-curvature="0"
+ id="path4870"
+ d="m 110.0738,110.77491 54.33579,0 -0.35055,58.19188 22.43542,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ <path
+ sodipodi:nodetypes="cccc"
+ inkscape:connector-curvature="0"
+ id="path4870-8"
+ d="m 111.41256,128.80552 42.50018,0 -0.27419,125.86808 33.54846,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ <path
+ sodipodi:nodetypes="cccc"
+ inkscape:connector-curvature="0"
+ id="path4870-8-7"
+ d="m 111.73566,163.67589 29.27471,0 -0.18887,168.70974 45.10864,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ <path
+ sodipodi:nodetypes="cccc"
+ inkscape:connector-curvature="0"
+ id="path4870-8-5"
+ d="m 283.50688,164.44217 35.10948,0 -0.22651,-102.576846 35.71444,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-0)" />
+ <path
+ sodipodi:nodetypes="cccc"
+ inkscape:connector-curvature="0"
+ id="path5128"
+ d="m 91.143911,271.32841 35.055349,10e-6 0,49.07748 58.89299,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-0-31)" />
+ <path
+ sodipodi:nodetypes="ccc"
+ inkscape:connector-curvature="0"
+ id="path5128-1"
+ d="m 126.31108,271.35131 0.17527,-189.514763 58.89299,0.04059"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-0-31)" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path4400-3-1"
+ d="m 126.54953,157.7667 60.31481,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3.00000003, 1.00000001;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path4400-3-1-9"
+ d="m 127.85888,244.00286 57.55016,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:3, 1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend)" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-17.svg b/libX11/specs/XKB/XKBlib-17.svg
new file mode 100644
index 000000000..20dfef22e
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-17.svg
@@ -0,0 +1,626 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="470"
+ height="370"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-17.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-17.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4534"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4534-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4534-0-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.2977842"
+ inkscape:cx="286.92862"
+ inkscape:cy="201.7286"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="59.887028"
+ y="98.028496"
+ id="text3051-7-2-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-5-7"
+ x="59.887028"
+ y="98.028496">Define real</tspan><tspan
+ sodipodi:role="line"
+ x="59.887028"
+ y="109.2785"
+ id="tspan3367">modifiers bound</tspan><tspan
+ sodipodi:role="line"
+ x="59.887028"
+ y="120.5285"
+ id="tspan3369">to virtual</tspan><tspan
+ sodipodi:role="line"
+ x="59.887028"
+ y="131.7785"
+ id="tspan3371">modifier</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="300.95572"
+ y="150.90459"
+ id="text3051-7-2-3-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="300.95572"
+ y="150.90459"
+ id="tspan3371-6">Define virtual modifiers</tspan><tspan
+ sodipodi:role="line"
+ x="300.95572"
+ y="162.15459"
+ id="tspan3410">for each key</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="239.39282"
+ y="24.846851"
+ id="text3051-7-2-3-6-4"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="239.39282"
+ y="24.846851"
+ id="tspan3410-3">KeyCode</tspan></text>
+ <g
+ id="g5711">
+ <g
+ id="g4366">
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3438"
+ width="81.918816"
+ height="92.158669"
+ x="11.455757"
+ y="156.32841" />
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.564579"
+ y="261.45755"
+ id="text3051"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053"
+ x="52.564579"
+ y="261.45755">XkbDescRec</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.421757"
+ y="168.49168"
+ id="text3051-7-5-3-42-9-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-1-00-4-9-3"
+ x="52.421757"
+ y="168.49168">. . .</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.421757"
+ y="204.33118"
+ id="text3051-7-5-3-42-9-93"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-1-00-4-9-34"
+ x="52.421757"
+ y="204.33118">. . .</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.421757"
+ y="240.17065"
+ id="text3051-7-5-3-42-9-61"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-1-00-4-9-5"
+ x="52.421757"
+ y="240.17065">. . .</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.175663"
+ y="188.30986"
+ id="text3051-7-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-7"
+ x="52.175663"
+ y="188.30986">server</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="52.228397"
+ y="224.14935"
+ id="text3051-7-2"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3053-0-5"
+ x="52.228397"
+ y="224.14935">names</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 11.455757,176.89345 81.918815,0"
+ id="rect3438-5"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 11.455757,194.81319 81.918815,0"
+ id="rect3438-5-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 11.455757,212.73293 81.918815,0"
+ id="rect3438-5-5"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ d="m 11.455757,230.65268 81.918816,0"
+ id="rect3438-5-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ </g>
+ </g>
+ <g
+ id="g5661">
+ <rect
+ y="210.94096"
+ x="380.73615"
+ height="129.7048"
+ width="82.601479"
+ id="rect4343"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42-9-617"
+ y="221.73892"
+ x="422.04349"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="221.73892"
+ x="422.04349"
+ id="tspan3053-0-1-00-4-9-2"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42-9-2"
+ y="295.46585"
+ x="422.04349"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="295.46585"
+ x="422.04349"
+ id="tspan3053-0-1-00-4-9-9"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42-9-28"
+ y="332.32932"
+ x="422.04349"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="332.32932"
+ x="422.04349"
+ id="tspan3053-0-1-00-4-9-12"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-4"
+ y="242.43823"
+ x="422.29178"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="242.43823"
+ x="422.29178"
+ id="tspan3053-0-1-7"
+ sodipodi:role="line">vmods[0]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1-8"
+ y="260.86996"
+ x="422.29178"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="260.86996"
+ x="422.29178"
+ id="tspan3053-0-1-0-6"
+ sodipodi:role="line">vmods[1]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-3"
+ y="279.3017"
+ x="422.29178"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="279.3017"
+ x="422.29178"
+ id="tspan3053-0-1-00-7"
+ sodipodi:role="line">vmods[2]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-4-7"
+ y="316.16516"
+ x="422.29178"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="316.16516"
+ x="422.29178"
+ id="tspan3053-0-1-00-5-2"
+ sodipodi:role="line">vmods[15]</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-2"
+ d="m 381.07749,230.39668 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-00"
+ d="m 381.07749,248.82842 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-6"
+ d="m 381.07749,267.26015 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-3"
+ d="m 381.07749,285.69188 81.91882,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-908"
+ d="m 381.07749,304.12361 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-38"
+ d="m 381.07749,322.55534 81.91882,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-7"
+ y="354.05115"
+ x="422.18631"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="354.05115"
+ x="422.18631"
+ id="tspan3053-0-3"
+ sodipodi:role="line">XkbNamesRec</tspan></text>
+ </g>
+ <g
+ id="g5686">
+ <rect
+ y="51.199261"
+ x="144.08856"
+ height="130.38745"
+ width="83.284134"
+ id="rect4385"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7"
+ y="195.18179"
+ x="185.88004"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="195.18179"
+ x="185.88004"
+ id="tspan3053-0"
+ sodipodi:role="line">XkbServerMapRec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5"
+ y="82.785614"
+ x="185.9855"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="82.785614"
+ x="185.9855"
+ id="tspan3053-0-1"
+ sodipodi:role="line">vmods[0]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-1"
+ y="101.25849"
+ x="185.9855"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="101.25849"
+ x="185.9855"
+ id="tspan3053-0-1-0"
+ sodipodi:role="line">vmods[1]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3"
+ y="119.73138"
+ x="185.9855"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="119.73138"
+ x="185.9855"
+ id="tspan3053-0-1-00"
+ sodipodi:role="line">vmods[2]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-4"
+ y="156.67712"
+ x="185.9855"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="156.67712"
+ x="185.9855"
+ id="tspan3053-0-1-00-5"
+ sodipodi:role="line">vmods[15]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42"
+ y="174.80724"
+ x="185.84268"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="174.80724"
+ x="185.84268"
+ id="tspan3053-0-1-00-4"
+ sodipodi:role="line">vmodmap</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42-9-9"
+ y="62.045181"
+ x="185.73721"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="62.045181"
+ x="185.73721"
+ id="tspan3053-0-1-00-4-9-4"
+ sodipodi:role="line">. . .</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-5-3-42-9-98"
+ y="135.93668"
+ x="185.73721"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="135.93668"
+ x="185.73721"
+ id="tspan3053-0-1-00-4-9-1"
+ sodipodi:role="line">. . .</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-9"
+ d="m 144.77121,163.08788 81.91882,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-98"
+ d="m 144.77122,144.61501 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-02"
+ d="m 144.77122,126.14213 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-4"
+ d="m 144.77122,107.66925 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-90"
+ d="m 144.77122,89.196369 81.91881,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3438-5-1"
+ d="m 144.77121,70.723491 81.91882,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g3091">
+ <rect
+ y="79.87085"
+ x="270.33209"
+ height="17.749077"
+ width="80.553505"
+ id="rect4437"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="83.739235"
+ x="266.00861"
+ height="17.749077"
+ width="80.553505"
+ id="rect4437-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="87.607635"
+ x="261.68512"
+ height="17.749077"
+ width="80.553505"
+ id="rect4437-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="91.476013"
+ x="257.36163"
+ height="17.749077"
+ width="80.553505"
+ id="rect4437-05"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3051-7-2-3-6-0"
+ y="120.4188"
+ x="298.78397"
+ style="font-size:9px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3410-1"
+ y="120.4188"
+ x="298.78397"
+ sodipodi:role="line">unsigned short</tspan><tspan
+ id="tspan4497"
+ y="131.66879"
+ x="298.78397"
+ sodipodi:role="line">(one per key)</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 93.523985,184.26937 20.575645,0 0.68266,-122.734315 27.89299,0"
+ id="path4508"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 228.27602,169.5608 10.4914,0 0.34699,-70.50743 18.14441,0"
+ id="path4508-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-8)"
+ d="m 237.56458,31.402214 0.68265,55.97786 17.74908,0"
+ id="path4978"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-8)"
+ d="m 352.17824,88.109945 9.21586,0 0.34133,167.983395 17.74908,0"
+ id="path4978-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-8-7)"
+ d="m 93.523985,220.49816 285.350555,0"
+ id="path5188"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:4, 2;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-8-7)"
+ d="m 361.80812,204.11439 -238.2952,0.68266 0.68265,-106.494467 19.16236,0"
+ id="path5376"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <g
+ style="font-size:40px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans"
+ id="text5564" />
+ <g
+ id="g5610">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5571"
+ d="m 104.794,161.57984 0,-90.563275"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5571-0"
+ d="m 101.28881,70.717253 7.01038,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5571-0-3"
+ d="m 101.28881,161.87945 7.01038,0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-18.svg b/libX11/specs/XKB/XKBlib-18.svg
new file mode 100644
index 000000000..7da870bb3
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-18.svg
@@ -0,0 +1,907 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="660"
+ height="420"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-18.svg"
+ style="display:inline"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-18.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4554"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-8"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-31"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-00"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-90"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-03"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-37"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-99"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-94"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0-1"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4554-3-43"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.6452381"
+ inkscape:cx="328.96405"
+ inkscape:cy="167.7834"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <g
+ id="g5558">
+ <rect
+ y="315.38745"
+ x="254.94466"
+ height="74.391144"
+ width="148.00739"
+ id="rect3680"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7"
+ y="333.39355"
+ x="329.09778"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="333.39355"
+ x="329.09778"
+ id="tspan3074-0"
+ sodipodi:role="line">Xkb-capable</tspan><tspan
+ y="348.39355"
+ x="329.09778"
+ id="tspan3076-5"
+ sodipodi:role="line">Client</tspan><tspan
+ y="363.39355"
+ x="329.09778"
+ id="tspan3078-1"
+ sodipodi:role="line">Xkb-aware Xlib</tspan><tspan
+ y="378.39355"
+ x="329.09778"
+ id="tspan3080-1"
+ sodipodi:role="line">Xkb-unaware App</tspan></text>
+ </g>
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3499"
+ width="27.896679"
+ height="26.346863"
+ x="286.71588"
+ y="239.44649" />
+ <g
+ id="g5566">
+ <rect
+ y="313.83765"
+ x="22.472324"
+ height="74.391144"
+ width="149.55719"
+ id="rect3678"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070"
+ y="331.84375"
+ x="97.40033"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="331.84375"
+ x="97.40033"
+ id="tspan3074"
+ sodipodi:role="line">Xkb-unaware</tspan><tspan
+ y="346.84375"
+ x="97.40033"
+ id="tspan3076"
+ sodipodi:role="line">Client</tspan><tspan
+ y="361.84375"
+ x="97.40033"
+ id="tspan3078"
+ sodipodi:role="line">Core kb Xlib</tspan><tspan
+ y="376.84375"
+ x="97.40033"
+ id="tspan3080"
+ sodipodi:role="line">Xkb-unaware App</tspan></text>
+ </g>
+ <g
+ id="g5550">
+ <rect
+ y="316.16235"
+ x="488.57935"
+ height="74.391144"
+ width="148.00739"
+ id="rect3680-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7-0"
+ y="334.16846"
+ x="562.73242"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="334.16846"
+ x="562.73242"
+ id="tspan3074-0-3"
+ sodipodi:role="line">Xkb-aware</tspan><tspan
+ y="349.16846"
+ x="562.73242"
+ id="tspan3076-5-0"
+ sodipodi:role="line">Client</tspan><tspan
+ y="364.16846"
+ x="562.73242"
+ id="tspan3078-1-0"
+ sodipodi:role="line">Xkb-aware Xlib</tspan><tspan
+ y="379.16846"
+ x="562.73242"
+ id="tspan3080-1-4"
+ sodipodi:role="line">Xkb-aware App</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="278.96094"
+ y="279.99509"
+ id="text3070-5-9"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3080-9-9"
+ x="278.96094"
+ y="279.99509">state</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="572.65094"
+ y="264.49692"
+ id="text3070-5-9-4-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3080-9-9-9-1"
+ x="572.65094"
+ y="264.49692">config</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="266.56824"
+ y="193.41203"
+ id="text3070-5-9-4-8-9-4-1-6-2"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3080-9-9-9-1-33-6-5-1-2"
+ x="266.56824"
+ y="193.41203">kb</tspan><tspan
+ sodipodi:role="line"
+ x="266.56824"
+ y="208.41203"
+ id="tspan3316-7-9">mapping</tspan></text>
+ <g
+ id="g5644">
+ <rect
+ y="32.546127"
+ x="206.12546"
+ height="79.040588"
+ width="245.64575"
+ id="rect3575"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-2"
+ y="52.876968"
+ x="328.93661"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="52.876968"
+ x="328.93661"
+ id="tspan3074-8"
+ sodipodi:role="line">Xkb-aware</tspan><tspan
+ y="67.876968"
+ x="328.93661"
+ id="tspan3080-4"
+ sodipodi:role="line">Server</tspan><tspan
+ id="tspan3403"
+ y="82.876968"
+ x="328.93661"
+ sodipodi:role="line">Maintains Xkb State and Mapping,</tspan><tspan
+ id="tspan3407"
+ y="97.876968"
+ x="328.93661"
+ sodipodi:role="line">core kb mapping, but not core kb state</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="300.81363"
+ y="257.09357"
+ id="text3070-5-7-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3080-9-8-3"
+ x="300.81363"
+ y="257.09357">Xkb</tspan></text>
+ <g
+ id="g5594">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070-5-3-9"
+ d="m 417.4437,206.30568 30.99631,30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ <rect
+ y="184.42804"
+ x="395.20297"
+ height="26.346863"
+ width="27.896679"
+ id="rect3499-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4-8-9-4-1-6"
+ y="223.63342"
+ x="408.3764"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="223.63342"
+ x="408.3764"
+ id="tspan3080-9-9-9-1-33-6-5-1"
+ sodipodi:role="line">kb</tspan><tspan
+ id="tspan3316-7"
+ y="238.63342"
+ x="408.3764"
+ sodipodi:role="line">mapping</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-7-6-7"
+ y="202.0751"
+ x="409.30072"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="202.0751"
+ x="409.30072"
+ id="tspan3080-9-8-3-7"
+ sodipodi:role="line">Xkb</tspan></text>
+ </g>
+ <g
+ id="g5586">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070-5-3"
+ d="m 479.44862,277.58458 30.99631,30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4"
+ y="300.1427"
+ x="467.26352"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="300.1427"
+ x="467.26352"
+ id="tspan3080-9-9-9"
+ sodipodi:role="line">state</tspan></text>
+ <rect
+ y="254.16974"
+ x="454.87085"
+ height="26.346863"
+ width="27.896679"
+ id="rect3499-1-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-7-6-72"
+ y="272.59171"
+ x="468.9686"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="272.59171"
+ x="468.9686"
+ id="tspan3080-9-8-3-5"
+ sodipodi:role="line">Xkb</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="155.71251"
+ y="66.852989"
+ id="text3070-5-6-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3080-9-4-3"
+ x="155.71251"
+ y="66.852989">Keycode</tspan></text>
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path3577-8"
+ sodipodi:cx="160.01845"
+ sodipodi:cy="217.74908"
+ sodipodi:rx="8.9114389"
+ sodipodi:ry="9.298893"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ transform="matrix(0.95383025,0,0,0.91408731,112.38801,-30.111786)" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path3577-0"
+ sodipodi:cx="160.01845"
+ sodipodi:cy="217.74908"
+ sodipodi:rx="8.9114389"
+ sodipodi:ry="9.298893"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ transform="matrix(0.95383025,0,0,0.91408731,416.15185,86.899284)" />
+ <g
+ id="g5616"
+ transform="translate(14,-32)">
+ <rect
+ y="117.01107"
+ x="496.71588"
+ height="26.346863"
+ width="27.896679"
+ id="rect3499-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-7-6-3"
+ y="134.65814"
+ x="510.81363"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="134.65814"
+ x="510.81363"
+ id="tspan3080-9-8-3-76"
+ sodipodi:role="line">Xkb</tspan></text>
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,363.48212,-101.4033)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577-98"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-0"
+ y="100.94892"
+ x="572.651"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="100.94892"
+ x="572.651"
+ id="tspan3080-9-9-0"
+ sodipodi:role="line">Core protocol</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-0-6"
+ y="133.49506"
+ x="571.32965"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="133.49506"
+ x="571.32965"
+ id="tspan3080-9-9-0-3"
+ sodipodi:role="line">Xkb protocol</tspan></text>
+ </g>
+ <g
+ id="g5638">
+ <rect
+ y="68.191879"
+ x="39.132847"
+ height="20.922508"
+ width="80.590401"
+ id="rect3678-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-6"
+ y="81.963684"
+ x="79.384102"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="81.963684"
+ x="79.384102"
+ id="tspan3080-9-4"
+ sodipodi:role="line">Keyboard</tspan></text>
+ <path
+ inkscape:connector-curvature="0"
+ id="path3760"
+ d="m 120.1107,76.715867 84.46495,0"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 322.34401,110.78525 0,202.6734"
+ id="path3760-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 333.96762,316.01593 0,-201.90494"
+ id="path3760-8-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 301.4215,266.71471 0,30.84761"
+ id="path3760-8-5"
+ inkscape:connector-curvature="0" />
+ <g
+ id="g5610">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4-8-6"
+ y="270.65372"
+ x="375.2692"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="270.65372"
+ x="375.2692"
+ id="tspan3080-9-9-9-1-3"
+ sodipodi:role="line">config</tspan></text>
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,195.30314,86.899285)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577-2"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path3760-8-5-1"
+ d="m 348.69087,279.30644 0,-37.10951"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)" />
+ </g>
+ <g
+ id="g5580">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4-8-9"
+ y="200.13712"
+ x="156.74524"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="200.13712"
+ x="156.74524"
+ id="tspan3080-9-9-9-1-33"
+ sodipodi:role="line">config</tspan></text>
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,9.3012966,19.506304)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070"
+ d="m 168.15498,212.32472 30.99631,-30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="M 88.120201,312.89513 288.0464,112.19402"
+ id="path5070-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="M 302.81384,112.15982 102.88764,312.86093"
+ id="path5070-1-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <g
+ id="g5574">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5"
+ y="280.69983"
+ x="186.90219"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="280.69983"
+ x="186.90219"
+ id="tspan3080-9"
+ sodipodi:role="line">state</tspan></text>
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,34.897239,54.353159)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577-5"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070-5"
+ d="m 180.77278,259.01201 -30.99631,30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 259.03847,175.29676 -30.99631,30.2214"
+ id="path5070-5-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <g
+ id="g5634">
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,150.35849,-28.56197)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577-50"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <path
+ inkscape:connector-curvature="0"
+ id="path3760-8-5-9"
+ d="m 302.97132,175.5644 0,30.84761"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)" />
+ </g>
+ <g
+ id="g5603">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4-8-9-4-1"
+ y="167.59099"
+ x="363.64563"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="167.59099"
+ x="363.64563"
+ id="tspan3080-9-9-9-1-33-6-5"
+ sodipodi:role="line">kb</tspan><tspan
+ id="tspan3316"
+ y="182.59099"
+ x="363.64563"
+ sodipodi:role="line">mapping</tspan></text>
+ <path
+ transform="matrix(0.95383025,0,0,0.91408731,210.8013,-58.008465)"
+ d="m 168.92989,217.74908 a 8.9114389,9.298893 0 1 1 -17.82288,0 8.9114389,9.298893 0 1 1 17.82288,0 z"
+ sodipodi:ry="9.298893"
+ sodipodi:rx="8.9114389"
+ sodipodi:cy="217.74908"
+ sodipodi:cx="160.01845"
+ id="path3577-9"
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.07095349;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ sodipodi:type="arc" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070-5-3-9-1"
+ d="m 361.65034,139.66361 30.99631,30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 354.69537,113.29733 199.9262,200.70112"
+ id="path5070-1-1-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="M 568.21975,314.45174 368.29356,113.75063"
+ id="path5070-1-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <g
+ id="g5626">
+ <rect
+ y="188.30258"
+ x="488.19189"
+ height="26.346863"
+ width="27.896679"
+ id="rect3499-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-9-4-8-9-4"
+ y="169.91573"
+ x="497.70465"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="169.91573"
+ x="497.70465"
+ id="tspan3080-9-9-9-1-33-6"
+ sodipodi:role="line">config</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-5-7-6-2"
+ y="205.94965"
+ x="502.28964"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="205.94965"
+ x="502.28964"
+ id="tspan3080-9-8-3-3"
+ sodipodi:role="line">Xkb</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="path5070-5-3-9-1-1"
+ d="m 487.62396,188.12237 -30.99631,-30.2214"
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-0)"
+ d="m 565.13933,282.66111 -30.99631,-30.2214"
+ id="path5070-5-3-9-1-1-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-19.svg b/libX11/specs/XKB/XKBlib-19.svg
new file mode 100644
index 000000000..8db8f933a
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-19.svg
@@ -0,0 +1,582 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="680"
+ height="350"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-19.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-19.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM"
+ style="overflow:visible">
+ <path
+ id="path4045"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4001"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4001-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4001-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4001-61"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4001-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-90"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4001-1"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.86464091"
+ inkscape:cx="488.14518"
+ inkscape:cy="169.64249"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3202"
+ width="640.38818"
+ height="199.79013"
+ x="22.119621"
+ y="18.919203" />
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="313.95593"
+ y="40.325287"
+ id="text3070"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072"
+ x="313.95593"
+ y="40.325287">Xkb State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="37.754189"
+ y="61.350868"
+ id="text3070-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0"
+ x="37.754189"
+ y="61.350868">Base Modifiers and Group</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="31.390907"
+ y="76.329384"
+ id="text3070-7-5"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-1"
+ x="31.390907"
+ y="76.329384">Locked Modifiers and Group</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="28.379189"
+ y="91.307884"
+ id="text3070-7-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-0"
+ x="28.379189"
+ y="91.307884">Latched Modifiers and Group</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="38.618446"
+ y="107.4495"
+ id="text3070-7-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-00"
+ x="38.618446"
+ y="107.4495">Core Pointer Button State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="45.005165"
+ y="130.56387"
+ id="text3070-7-4"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-5"
+ x="45.005165"
+ y="130.56387">ServerInternalModifiers</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="51.737587"
+ y="144.8963"
+ id="text3070-7-42"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-4"
+ x="51.737587"
+ y="144.8963">IgnoreLocksModifiers</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="63.711224"
+ y="160.3918"
+ id="text3070-7-9"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-9"
+ x="63.711224"
+ y="160.3918">IgnoreGroupLock</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 203.35783,129.51732 12.13011,0 0,27.82791 m 0,0 -12.13011,0"
+ id="rect3972-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 323.35791,79.764955 8.43652,0 0,45.827905 m 0,0 -128.43652,0"
+ id="rect3972-1-6"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 322.69115,75.207772 14.81148,0 0,67.947528 m 0,0 -134.14481,0"
+ id="rect3972-1-6-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 322.81789,70.311424 164.61179,0"
+ id="path3975-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM);marker-end:url(#Arrow2Lend)"
+ d="m 331.79831,108.92523 30.13474,0"
+ id="path3975-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM);marker-end:url(#Arrow2Lend)"
+ d="m 337.5929,126.72036 25.27356,0"
+ id="path3975-1-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 203.35783,56.023084 12.13011,0 0,37.103876 m 0,0 -12.13011,0"
+ id="rect3972"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 204.07135,73.147954 42.81218,0"
+ id="path3975"
+ inkscape:connector-curvature="0" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-2"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,-128.39843,-58.763441)" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-29"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,108.18711,-61.103875)" />
+ <g
+ id="g5352">
+ <rect
+ y="229.41238"
+ x="27.114376"
+ height="37.817417"
+ width="245.45645"
+ id="rect4921"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7-94"
+ y="244.18338"
+ x="98.737946"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="244.18338"
+ x="98.737946"
+ id="tspan3072-0-98"
+ sodipodi:role="line">Compatibility Map</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7-94-2"
+ y="259.61893"
+ x="73.434669"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="259.61893"
+ x="73.434669"
+ id="tspan3072-0-98-8"
+ sodipodi:role="line">Explicit Override Controls</tspan></text>
+ </g>
+ <g
+ id="g5359">
+ <rect
+ y="286.13849"
+ x="132.71773"
+ height="37.817417"
+ width="141.9937"
+ id="rect4921-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7-94-1"
+ y="309.06448"
+ x="148.10753"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="309.06448"
+ x="148.10753"
+ id="tspan3072-0-98-2"
+ sodipodi:role="line">Xkb Keyboard Map</tspan></text>
+ </g>
+ <g
+ id="g5364">
+ <rect
+ y="285.42499"
+ x="399.93707"
+ height="37.817417"
+ width="122.72822"
+ id="rect4921-3-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-7-94-4"
+ y="309.06445"
+ x="402.39886"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="309.06445"
+ x="402.39886"
+ id="tspan3072-0-98-7"
+ sodipodi:role="line">Core Keyboard Map</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="518.42633"
+ y="73.964088"
+ id="text3070-7-94-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-6"
+ x="518.42633"
+ y="73.964088">Compatibility State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="495.03571"
+ y="89.586823"
+ id="text3070-7-94-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-77"
+ x="495.03571"
+ y="89.586823">Compatibility Lookup State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="501.90289"
+ y="105.20957"
+ id="text3070-7-94-23"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-72"
+ x="501.90289"
+ y="105.20957">Compatibility Grab State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="367.08063"
+ y="113.30049"
+ id="text3070-7-94-5"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-3"
+ x="367.08063"
+ y="113.30049">LookupState</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="372.12604"
+ y="131.46417"
+ id="text3070-7-94-5-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-3-6"
+ x="372.12604"
+ y="131.46417">Grab State</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="282.40521"
+ y="64.864059"
+ id="text3070-7-94-5-7-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0-98-3-6-1"
+ x="282.40521"
+ y="64.864059">Effective</tspan><tspan
+ sodipodi:role="line"
+ x="282.40521"
+ y="79.864059"
+ id="tspan4917">Modifiers</tspan><tspan
+ sodipodi:role="line"
+ x="282.40521"
+ y="94.864059"
+ id="tspan4919">and Group</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 451.66839,70.89192 0,161.50987 -178.95697,0"
+ id="rect4959"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 455.52257,121.447 0,114.08816 -183.23819,0"
+ id="rect4959-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-0"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,111.68486,-9.8141784)" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 459.80379,109.27491 0,130.08816 -186.80588,0"
+ id="rect4959-4-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-5"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,115.94629,-22.992956)" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-5)"
+ d="m 447.3872,122.38195 18.55194,0 -0.35677,-21.40608 21.04932,0"
+ id="path5034"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-5)"
+ d="m 447.32214,109.18152 12.55194,0 -0.35677,-23.406071 27.04932,0"
+ id="path5034-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-50"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,-25.292448,174.91967)" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-9"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,3.7841522,167.96268)" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="path4739-98"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,-25.292448,127.29113)" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 275.36774,300.07008 123.31192,0"
+ id="path3975-4"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 398.74561,306.4919 -121.91192,0"
+ id="path3975-2"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 272.9276,259.3809 45.66631,0"
+ id="path5314"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 347.84172,298.27848 0,-55.27363 -74.6607,0"
+ id="rect4959-4-3-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
+ d="m 318.66101,307.37642 0,-60.76724 -45.74696,0"
+ id="rect4959-4-3-0-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="ccc" />
+ <path
+ sodipodi:type="arc"
+ style="fill:#000000;stroke:#000000;stroke-width:0.9747206;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;display:inline"
+ id="path4739-2-6"
+ sodipodi:cx="337.39114"
+ sodipodi:cy="127.91186"
+ sodipodi:rx="1.7169465"
+ sodipodi:ry="1.6946485"
+ d="m 339.10809,127.91186 a 1.7169465,1.6946485 0 1 1 -3.43389,0 1.7169465,1.6946485 0 1 1 3.43389,0 z"
+ transform="matrix(1.0192513,0,0,1.0326625,-128.33445,11.032432)" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-2.svg b/libX11/specs/XKB/XKBlib-2.svg
new file mode 100644
index 000000000..5adc805c5
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-2.svg
@@ -0,0 +1,761 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="670"
+ height="520"
+ id="svg7561"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-2.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-2.png"
+ inkscape:export-xdpi="90"
+ inkscape:export-ydpi="90">
+ <defs
+ id="defs7563">
+ <marker
+ inkscape:stockid="DotL"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotL"
+ style="overflow:visible">
+ <path
+ id="path4613"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.8,0,0,0.8,5.92,0.8)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM"
+ style="overflow:visible">
+ <path
+ id="path4616"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4572"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-6"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-4"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-0-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-4-1"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-4-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-0-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-4-9"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6-23"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-4-1"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-0-7"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-4-4"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-6-1"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4572-4-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-5"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-01"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-2"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4616-8"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.73702284"
+ inkscape:cx="197.10787"
+ inkscape:cy="273.02994"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer3"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7566">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer3"
+ inkscape:label="Vetorial">
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="335.14062"
+ y="33.25592"
+ id="text8147-3-1-6-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan8527"
+ x="335.14062"
+ y="33.25592">Xkb State</tspan></text>
+ <g
+ id="g3253">
+ <rect
+ y="35.498142"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147"
+ y="58.680264"
+ x="88.456139"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="58.680264"
+ x="88.456139"
+ id="tspan8149"
+ sodipodi:role="line">Base Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3258">
+ <rect
+ y="82.349304"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-7"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3"
+ y="104.26287"
+ x="88.488365"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="104.26287"
+ x="88.488365"
+ id="tspan8172"
+ sodipodi:role="line">Base Group</tspan></text>
+ </g>
+ <g
+ id="g3263">
+ <rect
+ y="129.20047"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-9"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-1"
+ y="152.38258"
+ x="88.456139"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="152.38258"
+ x="88.456139"
+ id="tspan8195"
+ sodipodi:role="line">Locked Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3268">
+ <rect
+ y="176.05164"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-5"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8"
+ y="198.07066"
+ x="88.488365"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="198.07066"
+ x="88.488365"
+ id="tspan8206"
+ sodipodi:role="line">Locked Group</tspan></text>
+ </g>
+ <g
+ id="g3273">
+ <rect
+ y="222.90282"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-6"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0"
+ y="246.08493"
+ x="88.456139"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="246.08493"
+ x="88.456139"
+ id="tspan8229"
+ sodipodi:role="line">Latched Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3278">
+ <rect
+ y="269.754"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-8"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0-2"
+ y="291.77304"
+ x="88.488365"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="291.77304"
+ x="88.488365"
+ id="tspan8252"
+ sodipodi:role="line">Latched Group</tspan></text>
+ </g>
+ <g
+ id="g3283">
+ <rect
+ y="316.60516"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-95"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0-2-9"
+ y="339.78729"
+ x="88.708092"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="339.78729"
+ x="88.708092"
+ id="tspan8275"
+ sodipodi:role="line">Core Pointer Buttons</tspan></text>
+ </g>
+ <g
+ id="g3288">
+ <rect
+ y="363.45633"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-52"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0-2-9-9"
+ y="386.63846"
+ x="88.649498"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="386.63846"
+ x="88.649498"
+ id="tspan8298"
+ sodipodi:role="line">Server Internal Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3293">
+ <rect
+ y="410.3075"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-1"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0-2-9-9-3"
+ y="432.32654"
+ x="88.456139"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="432.32654"
+ x="88.456139"
+ id="tspan8321"
+ sodipodi:role="line">IgnoreLock Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3298">
+ <rect
+ y="457.15866"
+ x="9.1180973"
+ height="37.416973"
+ width="159.26201"
+ id="rect7637-59"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-8-0-2-9-9-3-8"
+ y="479.1777"
+ x="88.183678"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="479.1777"
+ x="88.183678"
+ id="tspan8344"
+ sodipodi:role="line">IgnoreGroupLock</tspan></text>
+ </g>
+ <g
+ id="g3303">
+ <rect
+ y="450.44281"
+ x="198.12178"
+ height="37.416973"
+ width="244.64946"
+ id="rect7637-91"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-0-3"
+ y="472.46185"
+ x="320.43774"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="472.46185"
+ x="320.43774"
+ id="tspan8504"
+ sodipodi:role="line">Compatibility Map</tspan></text>
+ </g>
+ <g
+ id="g3318">
+ <rect
+ y="168.37637"
+ x="212.03322"
+ height="37.416973"
+ width="116.08858"
+ id="rect7637-62"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7"
+ y="190.3954"
+ x="269.81677"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="190.3954"
+ x="269.81677"
+ id="tspan8390"
+ sodipodi:role="line">Effective Group</tspan></text>
+ </g>
+ <g
+ id="g3323">
+ <rect
+ y="122.32473"
+ x="211.07381"
+ height="37.416973"
+ width="118.00739"
+ id="rect7637-10"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-1-6"
+ y="145.50685"
+ x="269.78455"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="145.50685"
+ x="269.78455"
+ id="tspan8367"
+ sodipodi:role="line">Effective Modifiers</tspan></text>
+ </g>
+ <g
+ id="g3338">
+ <rect
+ y="61.881924"
+ x="490.10699"
+ height="37.416973"
+ width="170.77492"
+ id="rect7637-53"
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-7"
+ y="83.900955"
+ x="575.47687"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="83.900955"
+ x="575.47687"
+ id="tspan8431"
+ sodipodi:role="line">Compatibility State</tspan></text>
+ </g>
+ <g
+ id="g3333">
+ <rect
+ y="108.89301"
+ x="490.10699"
+ height="37.416973"
+ width="170.77492"
+ id="rect7637-53-2"
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-1"
+ y="130.91203"
+ x="575.47687"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="130.91203"
+ x="575.47687"
+ id="tspan8433"
+ sodipodi:role="line">Compatibility Lookup State</tspan></text>
+ </g>
+ <g
+ id="g3328">
+ <rect
+ y="155.90405"
+ x="490.10699"
+ height="37.416973"
+ width="170.77492"
+ id="rect7637-53-1"
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-0"
+ y="177.92308"
+ x="575.47687"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="177.92308"
+ x="575.47687"
+ id="tspan8435"
+ sodipodi:role="line">Compatibility Grab State</tspan></text>
+ </g>
+ <g
+ id="g3313">
+ <rect
+ y="244.16975"
+ x="356.03424"
+ height="37.416973"
+ width="87.306282"
+ id="rect7637-53-9"
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-1-4"
+ y="266.18878"
+ x="399.41785"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="266.18878"
+ x="399.41785"
+ id="tspan8458"
+ sodipodi:role="line">Lookup State</tspan></text>
+ </g>
+ <g
+ id="g3308">
+ <rect
+ y="291.18082"
+ x="355.55453"
+ height="37.416973"
+ width="88.265694"
+ id="rect7637-53-7"
+ style="fill:#ffffff;stroke:#000000;stroke-width:0.99999994000000003;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text8147-3-7-1-4-3"
+ y="314.36295"
+ x="399.6698"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="314.36295"
+ x="399.6698"
+ id="tspan8481"
+ sodipodi:role="line">Grab State</tspan></text>
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 185.64946,427.89668 149.6679,-0.95941 0,-282.06642 -6.02113,0"
+ id="path8799"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 168.38009,381.84502 17.26937,0 0,94.02214 -18.22878,0"
+ id="path8801"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 442.77123,480.66421 28.96581,0 -1.15863,-305.09225 18.53812,0"
+ id="path8803"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 442.60077,472.07926 21.09747,0 -1.12543,-345.82442 27.04511,0"
+ id="path8803-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 442.60076,463.2001 12.40003,0 -0.99261,-378.9797 34.29711,0"
+ id="path8803-0-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 330.52031,133.35793 123.75066,0"
+ id="path9037"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 443.32127,265.75646 19.58768,0"
+ id="path9037-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 443.97231,310.84871 26.83692,0"
+ id="path9037-9-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM-0);marker-end:url(#Arrow2Lend-6)"
+ d="m 335.46528,261.91882 19.26786,0"
+ id="path9659"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM-0);marker-end:url(#Arrow2Lend-6)"
+ d="m 335.46656,309.90691 19.59605,0"
+ id="path9659-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 170.00386,100.73801 20.59313,0 0,188.04428 -21.7372,0"
+ id="path8801-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 170.5868,53.72694 9.22388,0 0,188.04428 -11.99149,0"
+ id="path8801-3-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM-0);marker-end:url(#Arrow2Lend-6)"
+ d="m 180.03866,141.05082 30.28757,0"
+ id="path9659-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#DotM-0);marker-end:url(#Arrow2Lend-6)"
+ d="m 190.69638,187.10249 19.46647,0"
+ id="path9659-8-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 168.45721,198.59779 22.01747,0"
+ id="path9037-9-5"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 168.24737,152.54612 11.49327,0"
+ id="path9037-9-5-6"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#DotM)"
+ d="m 168.48723,427.89668 17.30607,0"
+ id="path9037-9-5-5"
+ inkscape:connector-curvature="0" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-20.svg b/libX11/specs/XKB/XKBlib-20.svg
new file mode 100644
index 000000000..40747dc6e
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-20.svg
@@ -0,0 +1,379 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="560"
+ height="310"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-20.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-20.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4369"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4369-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.86479129"
+ inkscape:cx="287.7858"
+ inkscape:cy="104.53005"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <g
+ id="g4861">
+ <rect
+ y="25.453703"
+ x="27.800501"
+ height="125.91991"
+ width="112.83733"
+ id="rect3248"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070"
+ y="170.17986"
+ x="84.418381"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="170.17986"
+ x="84.418381"
+ id="tspan3072"
+ sodipodi:role="line">XkbDescRec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6"
+ y="56.627865"
+ x="84.034592"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="56.627865"
+ x="84.034592"
+ id="tspan3072-6-5-1"
+ sodipodi:role="line">compat</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3248-2"
+ d="m 27.8005,40.171618 112.83734,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3248-2-3"
+ d="m 27.800501,67.154453 112.837329,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g4829">
+ <rect
+ y="74.513405"
+ x="175.79729"
+ height="172.52664"
+ width="111.202"
+ id="rect4080"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4"
+ y="263.77859"
+ x="231.5975"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="263.77859"
+ x="231.5975"
+ id="tspan3072-6"
+ sodipodi:role="line">XkbCompMapRec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7"
+ y="88.925514"
+ x="231.21957"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="88.925514"
+ x="231.21957"
+ id="tspan3072-6-5-1-2"
+ sodipodi:role="line">sym_interpret</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2"
+ y="114.14958"
+ x="231.58578"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="114.14958"
+ x="231.58578"
+ id="tspan3072-6-5-1-2-9"
+ sodipodi:role="line">groups[0]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-2"
+ y="139.20667"
+ x="231.58578"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="139.20667"
+ x="231.58578"
+ id="tspan3072-6-5-1-2-9-8"
+ sodipodi:role="line">groups[1]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-1"
+ y="164.26375"
+ x="231.58578"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="164.26375"
+ x="231.58578"
+ id="tspan3072-6-5-1-2-9-2"
+ sodipodi:role="line">groups[2]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-4"
+ y="189.32083"
+ x="231.58578"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="189.32083"
+ x="231.58578"
+ id="tspan3072-6-5-1-2-9-7"
+ sodipodi:role="line">groups[3]</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-8"
+ y="214.21092"
+ x="231.41293"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="214.21092"
+ x="231.41293"
+ id="tspan3072-6-5-1-2-9-6"
+ sodipodi:role="line">num_si</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-3"
+ y="239.26801"
+ x="231.63266"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="239.26801"
+ x="231.63266"
+ id="tspan3072-6-5-1-2-9-77"
+ sodipodi:role="line">size_si</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7"
+ d="m 175.79729,98.310491 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7-2"
+ d="m 175.79729,123.36758 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7-5"
+ d="m 175.79729,148.42466 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7-3"
+ d="m 175.79729,173.48174 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7-7"
+ d="m 175.79729,198.53883 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4080-7-6"
+ d="m 175.79729,223.59591 111.202,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g4813">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1"
+ y="279.78644"
+ x="467.63354"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="279.78644"
+ x="467.63354"
+ id="tspan3072-6-5"
+ sodipodi:role="line">XkbSymInterpretRec(s)</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-8-8"
+ y="211.75349"
+ x="372.86844"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="211.75349"
+ x="372.86844"
+ id="tspan3072-6-5-1-2-9-6-1"
+ sodipodi:role="line">num_si - 1</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-3-3"
+ y="258.3602"
+ x="374.69656"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="258.3602"
+ x="374.69656"
+ id="tspan3072-6-5-1-2-9-77-6"
+ sodipodi:role="line">size_si - 1</tspan></text>
+ <rect
+ y="112.94351"
+ x="411.28387"
+ height="147.99678"
+ width="112.01966"
+ id="rect4237"
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4237-4"
+ d="m 411.28387,137.06454 112.01967,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4237-4-0"
+ d="m 411.28387,162.10543 112.01967,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4237-4-3"
+ d="m 411.28387,187.14632 112.01967,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4237-4-5"
+ d="m 411.28387,212.18721 112.01967,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect4237-4-8"
+ d="m 411.28387,237.2281 112.01967,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-1-6-7-2-8-8-5"
+ y="137.34628"
+ x="399.84833"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="137.34628"
+ x="399.84833"
+ id="tspan3072-6-5-1-2-9-6-1-0"
+ sodipodi:role="line">0</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="338.51785"
+ y="122.21764"
+ id="text3070-4-1-6-7-2-8-8-5-9"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-6-5-1-2-9-6-1-0-9"
+ x="338.51785"
+ y="122.21764">Group</tspan><tspan
+ sodipodi:role="line"
+ x="338.51785"
+ y="137.21765"
+ id="tspan4339">compatibility</tspan><tspan
+ sodipodi:role="line"
+ x="338.51785"
+ y="152.21765"
+ id="tspan4341">maps</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 140.63783,49.165893 85.85448,0 0,23.712192"
+ id="path4343"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 287.89255,86.773157 173.41715,0 0,23.712193"
+ id="path4343-2"
+ inkscape:connector-curvature="0" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-21.svg b/libX11/specs/XKB/XKBlib-21.svg
new file mode 100644
index 000000000..e7a31962d
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-21.svg
@@ -0,0 +1,976 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="600"
+ height="650"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-21.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-21.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="DotM"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="DotM"
+ style="overflow:visible">
+ <path
+ id="path4666"
+ d="m -2.5,-1 c 0,2.76 -2.24,5 -5,5 -2.76,0 -5,-2.24 -5,-5 0,-2.76 2.24,-5 5,-5 2.76,0 5,2.24 5,5 z"
+ style="fill-rule:evenodd;stroke:#000000;stroke-width:1pt;marker-start:none;marker-end:none"
+ transform="matrix(0.4,0,0,0.4,2.96,0.4)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart"
+ style="overflow:visible">
+ <path
+ id="path4619"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4622"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-6"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-95"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-61"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-3"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-7"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-44"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-49"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-38"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-32"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-43"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4619-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-55"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-73"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lstart"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lstart-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4619-7"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(1.1,0,0,1.1,1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-27"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-05"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1-6"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1-6-2"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79-2-5"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1-6-9"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79-2-1"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1-6-8"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79-2-7"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-1-6-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4622-79-2-2"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.58961827"
+ inkscape:cx="294.74298"
+ inkscape:cy="309.49556"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <g
+ id="g4480"
+ transform="translate(-2.1200027,0)">
+ <rect
+ y="13.571282"
+ x="220.05763"
+ height="79.712593"
+ width="146.70508"
+ id="rect3623-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070"
+ y="26.553555"
+ x="293.30469"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="26.553555"
+ x="293.30469"
+ id="tspan3072"
+ sodipodi:role="line">Augment names to</tspan><tspan
+ id="tspan3074"
+ y="41.553555"
+ x="293.30469"
+ sodipodi:role="line">supply component</tspan><tspan
+ id="tspan3076"
+ y="56.553555"
+ x="293.30469"
+ sodipodi:role="line">names required by</tspan><tspan
+ id="tspan3078"
+ y="71.553558"
+ x="293.30469"
+ sodipodi:role="line">want and need but not</tspan><tspan
+ id="tspan3080"
+ y="86.553558"
+ x="293.30469"
+ sodipodi:role="line">supplied in request</tspan></text>
+ </g>
+ <g
+ id="g4491"
+ transform="translate(7.6293945e-6,0)">
+ <rect
+ y="187.83658"
+ x="216.24161"
+ height="71.232536"
+ width="150.09711"
+ id="rect4489"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4"
+ y="204.07883"
+ x="291.04114"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="204.07883"
+ x="291.04114"
+ id="tspan3072-6"
+ sodipodi:role="line">Augment names to</tspan><tspan
+ id="tspan3080-1"
+ y="219.07883"
+ x="291.04114"
+ sodipodi:role="line">supply required com-</tspan><tspan
+ id="tspan3128"
+ y="234.07883"
+ x="291.04114"
+ sodipodi:role="line">ponent names not sup-</tspan><tspan
+ id="tspan3126"
+ y="249.07883"
+ x="291.04114"
+ sodipodi:role="line">plied in request</tspan></text>
+ </g>
+ <g
+ id="g4501">
+ <rect
+ y="197.16464"
+ x="463.01144"
+ height="58.512432"
+ width="79.712593"
+ id="rect4499"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7"
+ y="215.89449"
+ x="502.67731"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3126-2"
+ y="215.89449"
+ x="502.67731"
+ sodipodi:role="line">Keyboard</tspan><tspan
+ id="tspan3171"
+ y="230.89449"
+ x="502.67731"
+ sodipodi:role="line">Component</tspan><tspan
+ id="tspan3173"
+ y="245.89449"
+ x="502.67731"
+ sodipodi:role="line">Database</tspan></text>
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="351.73218"
+ y="128.97385"
+ id="text3070-4-7-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="351.73218"
+ y="128.97385"
+ id="tspan3173-4">False</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="310.94876"
+ y="172.80606"
+ id="text3070-4-7-8-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="310.94876"
+ y="172.80606"
+ id="tspan3173-4-8">True</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="311.55521"
+ y="440.59149"
+ id="text3070-4-7-8-7-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="311.55521"
+ y="440.59149"
+ id="tspan3173-4-8-3">True</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="231.23619"
+ y="392.4397"
+ id="text3070-4-7-8-77"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ x="231.23619"
+ y="392.4397"
+ id="tspan3173-4-2">False</tspan></text>
+ <g
+ id="g4519"
+ transform="translate(0.84801102,0)">
+ <rect
+ y="290.44534"
+ x="229.80971"
+ height="67.8405"
+ width="121.2649"
+ id="rect4517"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-7-6-3"
+ y="306.33923"
+ x="290.62381"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-8-3-7"
+ y="306.33923"
+ x="290.62381"
+ sodipodi:role="line">Build keyboard</tspan><tspan
+ id="tspan3303"
+ y="321.33923"
+ x="290.62381"
+ sodipodi:role="line">description from</tspan><tspan
+ id="tspan3305"
+ y="336.33923"
+ x="290.62381"
+ sodipodi:role="line">expressions in</tspan><tspan
+ id="tspan3307"
+ y="351.33923"
+ x="290.62381"
+ sodipodi:role="line">names</tspan></text>
+ </g>
+ <g
+ id="g4510">
+ <rect
+ y="294.68536"
+ x="454.53137"
+ height="56.816422"
+ width="97.520721"
+ id="rect4508"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-7-6-3-2"
+ y="311.40411"
+ x="503.2478"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3307-6"
+ y="311.40411"
+ x="503.2478"
+ sodipodi:role="line">New Keyboard</tspan><tspan
+ id="tspan3348"
+ y="326.40411"
+ x="503.2478"
+ sodipodi:role="line">Description</tspan><tspan
+ id="tspan3350"
+ y="341.40411"
+ x="503.2478"
+ sodipodi:role="line">(Temporary)</tspan></text>
+ </g>
+ <g
+ id="g4586"
+ transform="translate(-1.1798446,0)">
+ <rect
+ transform="matrix(0.86355474,-0.5042551,0.86355474,0.5042551,0,0)"
+ y="286.01212"
+ x="12.546584"
+ height="40.122799"
+ width="40.122799"
+ id="rect4566"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.07155609;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8"
+ y="142.37003"
+ x="292.44949"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-1"
+ y="142.37003"
+ x="292.44949"
+ sodipodi:role="line">load</tspan></text>
+ </g>
+ <g
+ id="g4591"
+ transform="translate(-1.2719908,0)">
+ <rect
+ transform="matrix(0.86355474,-0.5042551,0.86355474,0.5042551,0,0)"
+ y="551.6828"
+ x="-253.0174"
+ height="40.122799"
+ width="40.122799"
+ id="rect4566-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1.07155609;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8-3"
+ y="410.2478"
+ x="292.54166"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-1-6"
+ y="410.2478"
+ x="292.54166"
+ sodipodi:role="line">load</tspan></text>
+ </g>
+ <g
+ id="g4529">
+ <rect
+ y="456.65457"
+ x="437.57126"
+ height="42.400314"
+ width="136.52901"
+ id="rect4527"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8-3-4"
+ y="473.49829"
+ x="505.76251"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-1-6-0"
+ y="473.49829"
+ x="505.76251"
+ sodipodi:role="line">Keyboard Description</tspan><tspan
+ id="tspan3415"
+ y="488.49829"
+ x="505.76251"
+ sodipodi:role="line">for device_spec</tspan></text>
+ </g>
+ <g
+ id="g4537">
+ <rect
+ y="555.02332"
+ x="468.09946"
+ height="71.232529"
+ width="79.712593"
+ id="rect4535"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8-3-4-3"
+ y="572.61322"
+ x="507.87958"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-1-6-0-5"
+ y="572.61322"
+ x="507.87958"
+ sodipodi:role="line">Keyboard</tspan><tspan
+ id="tspan3441"
+ y="587.61322"
+ x="507.87958"
+ sodipodi:role="line">Description</tspan><tspan
+ id="tspan3415-8"
+ y="602.61322"
+ x="507.87958"
+ sodipodi:role="line">returned to</tspan><tspan
+ id="tspan3443"
+ y="617.61322"
+ x="507.87958"
+ sodipodi:role="line">Client</tspan></text>
+ </g>
+ <g
+ id="g4547"
+ transform="translate(0,6)">
+ <rect
+ y="546.54321"
+ x="217.08961"
+ height="80.5606"
+ width="148.40111"
+ id="rect4545"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8-3-4-3-5"
+ y="561.29712"
+ x="291.27551"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3443-8"
+ y="561.29712"
+ x="291.27551"
+ sodipodi:role="line">Build keyboard</tspan><tspan
+ id="tspan3484"
+ y="576.29712"
+ x="291.27551"
+ sodipodi:role="line">description for client</tspan><tspan
+ id="tspan3486"
+ y="591.29712"
+ x="291.27551"
+ sodipodi:role="line">by extracting struc-</tspan><tspan
+ id="tspan3488"
+ y="606.29712"
+ x="291.27551"
+ sodipodi:role="line">tures specified in want</tspan><tspan
+ id="tspan3490"
+ y="621.29712"
+ x="291.27551"
+ sodipodi:role="line">and need</tspan></text>
+ </g>
+ <g
+ id="g4558"
+ transform="translate(0.84801483,0)">
+ <rect
+ y="453.26254"
+ x="215.3936"
+ height="69.536514"
+ width="150.09711"
+ id="rect4556"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-8-3-4-3-5-0"
+ y="468.84134"
+ x="290.28979"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3490-1"
+ y="468.84134"
+ x="290.28979"
+ sodipodi:role="line">Replace device_spec</tspan><tspan
+ id="tspan3539"
+ y="483.84134"
+ x="290.28979"
+ sodipodi:role="line">active keyboard</tspan><tspan
+ id="tspan3541"
+ y="498.84134"
+ x="290.28979"
+ sodipodi:role="line">description with newly</tspan><tspan
+ id="tspan3543"
+ y="513.84131"
+ x="290.28979"
+ sodipodi:role="line">built description</tspan></text>
+ </g>
+ <g
+ id="g5219">
+ <rect
+ y="173.42047"
+ x="22.048164"
+ height="97.520721"
+ width="97.520721"
+ id="rect3623"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2"
+ y="188.07018"
+ x="70.925713"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0"
+ y="188.07018"
+ x="70.925713"
+ sodipodi:role="line">Initial Request:</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2-0"
+ y="203.38049"
+ x="70.8554"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0-6"
+ y="203.38049"
+ x="70.8554"
+ sodipodi:role="line">device_spec</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2-3"
+ y="218.98961"
+ x="70.559502"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0-9"
+ y="218.98961"
+ x="70.559502"
+ sodipodi:role="line">names</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2-08"
+ y="235.3194"
+ x="70.703056"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0-3"
+ y="235.3194"
+ x="70.703056"
+ sodipodi:role="line">want</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2-8"
+ y="251.14238"
+ x="70.808525"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0-7"
+ y="251.14238"
+ x="70.808525"
+ sodipodi:role="line">need</tspan></text>
+ <text
+ sodipodi:linespacing="125%"
+ id="text3070-4-7-8-2-31"
+ y="266.61966"
+ x="70.788017"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ id="tspan3173-4-0-0"
+ y="266.61966"
+ x="70.788017"
+ sodipodi:role="line">load</tspan></text>
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3623-0"
+ d="m 22.048165,192.49828 97.520725,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3623-0-5"
+ d="m 22.048163,207.97556 97.520727,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3623-0-5-0"
+ d="m 22.048163,223.45283 97.520727,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3623-0-5-3"
+ d="m 22.048165,238.9301 97.520725,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect3623-0-5-1"
+ d="m 22.048164,254.4074 97.520726,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 291.26298,93.8148 0,23.09757"
+ id="path4596"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 291.25314,158.03258 0,27.7286"
+ id="path4596-2"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 290.00054,259.8264 0,28.82818"
+ id="path4596-5"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 291.69655,357.34714 0,27.33761"
+ id="path4596-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 291.27254,426.03561 0,26.3722"
+ id="path4596-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 366.67199,321.83919 79.19142,0"
+ id="path4596-1-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 372.96935,478.72034 56.53217,0"
+ id="path4596-1-3-2"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 373.27487,571.15303 84.94818,0"
+ id="path4596-1-3-2-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 291.69655,523.61506 0,26.3722"
+ id="path4596-7-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="m 121.18964,215.11041 90.94563,0"
+ id="path4596-1-3-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-start:url(#Arrow2Lstart);marker-end:url(#Arrow2Lend)"
+ d="M 120.73642,210.73275 214.22607,97.947914"
+ id="path4596-1-3-9-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 119.41547,218.80642 106.32762,70.80852"
+ id="path4596-1-3-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-1)"
+ d="m 255.4428,405.01124 -70.75645,0 0,126.89959 104.75645,0"
+ id="rect5774"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0;marker-end:url(#Arrow2Lend-1)"
+ d="m 327.42324,137.27454 70.75645,0 0,130.89959 -104.75645,0"
+ id="rect5774-1"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-1-6)"
+ d="M 459.69356,256.35107 356.79809,290.5477"
+ id="path6017"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-1-6)"
+ d="m 449.84239,354.00854 -76.838,95.35899"
+ id="path6017-3"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-1-6)"
+ d="M 456.8343,359.38127 370.07592,546.46615"
+ id="path6017-3-8"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-1-6);display:inline"
+ d="M 100.49427,230.62118 214.64454,548.15782"
+ id="path6017-3-0"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend-1-6);display:inline"
+ d="M 95.536492,246.63398 209.68676,569.25866"
+ id="path6017-3-0-7"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-3.svg b/libX11/specs/XKB/XKBlib-3.svg
new file mode 100644
index 000000000..757c68280
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-3.svg
@@ -0,0 +1,1133 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="400"
+ height="40"
+ viewBox="0 0 320 32"
+ version="1.1"
+ id="svg2"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-3.svg">
+ <metadata
+ id="metadata380">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <sodipodi:namedview
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ id="namedview378"
+ showgrid="false"
+ inkscape:zoom="1.7633957"
+ inkscape:cx="203.08637"
+ inkscape:cy="-25.169771"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1"
+ inkscape:current-layer="svg2" />
+ <defs
+ id="defs4">
+ <g
+ id="g6">
+ <symbol
+ overflow="visible"
+ id="glyph0-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 5.140625,-6.8125 c 0,0 0,-0.109375 -0.125,-0.109375 -0.15625,0 -1.09375,0.09375 -1.265625,0.109375 -0.078125,0.015625 -0.140625,0.0625 -0.140625,0.1875 0,0.125 0.09375,0.125 0.234375,0.125 0.484375,0 0.5,0.0625 0.5,0.171875 L 4.3125,-6.125 3.71875,-3.765625 C 3.53125,-4.140625 3.25,-4.40625 2.796875,-4.40625 c -1.15625,0 -2.390625,1.46875 -2.390625,2.921875 0,0.9375 0.546875,1.59375 1.3125,1.59375 0.203125,0 0.703125,-0.046875 1.296875,-0.75 0.078125,0.421875 0.4375,0.75 0.90625,0.75 0.359375,0 0.578125,-0.234375 0.75,-0.546875 0.15625,-0.359375 0.296875,-0.96875 0.296875,-0.984375 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.171875,0.640625 -0.34375,1.234375 -0.75,1.234375 -0.28125,0 -0.296875,-0.265625 -0.296875,-0.453125 0,-0.25 0.015625,-0.3125 0.046875,-0.484375 z m -2.0625,5.625 C 3.015625,-1 3.015625,-0.984375 2.875,-0.8125 2.4375,-0.265625 2.03125,-0.109375 1.75,-0.109375 c -0.5,0 -0.640625,-0.546875 -0.640625,-0.9375 0,-0.5 0.3125,-1.71875 0.546875,-2.1875 0.3125,-0.578125 0.75,-0.953125 1.15625,-0.953125 0.640625,0 0.78125,0.8125 0.78125,0.875 0,0.0625 -0.015625,0.125 -0.03125,0.171875 z m 0,0"
+ id="path9"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.890625,-3.734375 C 3.625,-3.71875 3.421875,-3.5 3.421875,-3.28125 c 0,0.140625 0.09375,0.296875 0.3125,0.296875 0.21875,0 0.453125,-0.171875 0.453125,-0.5625 C 4.1875,-4 3.765625,-4.40625 3,-4.40625 c -1.3125,0 -1.6875,1.015625 -1.6875,1.453125 0,0.78125 0.734375,0.921875 1.03125,0.984375 0.515625,0.109375 1.03125,0.21875 1.03125,0.765625 0,0.25 -0.21875,1.09375 -1.421875,1.09375 -0.140625,0 -0.90625,0 -1.140625,-0.53125 0.390625,0.046875 0.640625,-0.25 0.640625,-0.53125 0,-0.21875 -0.171875,-0.34375 -0.375,-0.34375 -0.265625,0 -0.5625,0.203125 -0.5625,0.65625 0,0.5625 0.578125,0.96875 1.421875,0.96875 1.625,0 2.015625,-1.203125 2.015625,-1.65625 0,-0.359375 -0.1875,-0.609375 -0.3125,-0.71875 -0.265625,-0.28125 -0.5625,-0.34375 -1,-0.421875 -0.359375,-0.078125 -0.75,-0.15625 -0.75,-0.609375 C 1.890625,-3.578125 2.125,-4.1875 3,-4.1875 c 0.25,0 0.75,0.078125 0.890625,0.453125 z m 0,0"
+ id="path12"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.046875,-3.984375 0.9375,0 c 0.203125,0 0.3125,0 0.3125,-0.203125 0,-0.109375 -0.109375,-0.109375 -0.28125,-0.109375 l -0.875,0 C 2.5,-5.71875 2.546875,-5.90625 2.546875,-5.96875 c 0,-0.171875 -0.125,-0.265625 -0.296875,-0.265625 -0.03125,0 -0.3125,0 -0.390625,0.359375 l -0.390625,1.578125 -0.9375,0 c -0.203125,0 -0.296875,0 -0.296875,0.1875 0,0.125 0.078125,0.125 0.28125,0.125 l 0.875,0 C 0.671875,-1.15625 0.625,-0.984375 0.625,-0.8125 0.625,-0.265625 1,0.109375 1.546875,0.109375 2.5625,0.109375 3.125,-1.34375 3.125,-1.421875 3.125,-1.53125 3.046875,-1.53125 3.015625,-1.53125 2.921875,-1.53125 2.90625,-1.5 2.859375,-1.390625 2.4375,-0.34375 1.90625,-0.109375 1.5625,-0.109375 c -0.203125,0 -0.3125,-0.125 -0.3125,-0.453125 0,-0.25 0.03125,-0.3125 0.0625,-0.484375 z m 0,0"
+ id="path15"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.859375,-2.296875 c 0.296875,0 1.03125,-0.03125 1.53125,-0.234375 0.703125,-0.296875 0.75,-0.890625 0.75,-1.03125 0,-0.4375 -0.375,-0.84375 -1.0625,-0.84375 -1.109375,0 -2.625,0.96875 -2.625,2.71875 0,1.015625 0.59375,1.796875 1.578125,1.796875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.78125,0 -0.875,-0.84375 -0.875,-1.15625 0,-0.125 0.015625,-0.421875 0.15625,-1.03125 z m -0.46875,-0.21875 C 1.78125,-4.03125 2.8125,-4.1875 3.078125,-4.1875 c 0.453125,0 0.734375,0.296875 0.734375,0.625 0,1.046875 -1.59375,1.046875 -2.015625,1.046875 z m 0,0"
+ id="path18"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-4"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 0.453125,1.21875 C 0.375,1.5625 0.34375,1.625 -0.09375,1.625 c -0.109375,0 -0.21875,0 -0.21875,0.1875 0,0.078125 0.046875,0.125 0.125,0.125 0.265625,0 0.5625,-0.03125 0.828125,-0.03125 0.34375,0 0.671875,0.03125 1,0.03125 0.046875,0 0.171875,0 0.171875,-0.203125 C 1.8125,1.625 1.71875,1.625 1.578125,1.625 c -0.5,0 -0.5,-0.0625 -0.5,-0.15625 0,-0.125 0.421875,-1.75 0.484375,-2 0.125,0.296875 0.40625,0.640625 0.921875,0.640625 1.15625,0 2.40625,-1.453125 2.40625,-2.921875 0,-0.9375 -0.578125,-1.59375 -1.328125,-1.59375 -0.5,0 -0.984375,0.359375 -1.3125,0.75 -0.09375,-0.546875 -0.53125,-0.75 -0.890625,-0.75 -0.46875,0 -0.65625,0.390625 -0.734375,0.5625 C 0.4375,-3.5 0.3125,-2.90625 0.3125,-2.875 c 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.171875,0 0.3125,0.078125 0.3125,0.453125 0,0.234375 -0.03125,0.34375 -0.078125,0.515625 z m 1.75,-4.328125 C 2.265625,-3.375 2.546875,-3.65625 2.71875,-3.8125 c 0.359375,-0.296875 0.640625,-0.375 0.8125,-0.375 0.390625,0 0.640625,0.34375 0.640625,0.9375 0,0.59375 -0.328125,1.734375 -0.515625,2.109375 -0.34375,0.703125 -0.8125,1.03125 -1.1875,1.03125 C 1.8125,-0.109375 1.6875,-0.9375 1.6875,-1 c 0,-0.015625 0,-0.03125 0.03125,-0.15625 z m 0,0"
+ id="path21"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-5"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.71875,-3.765625 C 3.53125,-4.140625 3.25,-4.40625 2.796875,-4.40625 c -1.15625,0 -2.390625,1.46875 -2.390625,2.921875 0,0.9375 0.546875,1.59375 1.3125,1.59375 0.203125,0 0.703125,-0.046875 1.296875,-0.75 0.078125,0.421875 0.4375,0.75 0.90625,0.75 0.359375,0 0.578125,-0.234375 0.75,-0.546875 0.15625,-0.359375 0.296875,-0.96875 0.296875,-0.984375 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.171875,0.640625 -0.34375,1.234375 -0.75,1.234375 -0.28125,0 -0.296875,-0.265625 -0.296875,-0.453125 0,-0.21875 0.015625,-0.3125 0.125,-0.75 C 3.890625,-1.71875 3.90625,-1.828125 4,-2.203125 L 4.359375,-3.59375 c 0.0625,-0.28125 0.0625,-0.296875 0.0625,-0.34375 0,-0.171875 -0.109375,-0.265625 -0.28125,-0.265625 -0.25,0 -0.390625,0.21875 -0.421875,0.4375 z M 3.078125,-1.1875 C 3.015625,-1 3.015625,-0.984375 2.875,-0.8125 2.4375,-0.265625 2.03125,-0.109375 1.75,-0.109375 c -0.5,0 -0.640625,-0.546875 -0.640625,-0.9375 0,-0.5 0.3125,-1.71875 0.546875,-2.1875 0.3125,-0.578125 0.75,-0.953125 1.15625,-0.953125 0.640625,0 0.78125,0.8125 0.78125,0.875 0,0.0625 -0.015625,0.125 -0.03125,0.171875 z m 0,0"
+ id="path24"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-6"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.953125,-3.78125 c -0.171875,0 -0.296875,0 -0.4375,0.125 -0.171875,0.15625 -0.1875,0.328125 -0.1875,0.390625 0,0.25 0.1875,0.359375 0.375,0.359375 0.28125,0 0.546875,-0.25 0.546875,-0.640625 0,-0.484375 -0.46875,-0.859375 -1.171875,-0.859375 -1.34375,0 -2.671875,1.421875 -2.671875,2.828125 0,0.90625 0.578125,1.6875 1.625,1.6875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.625,0 -0.90625,-0.484375 -0.90625,-1.09375 0,-0.40625 0.203125,-1.375 0.546875,-1.984375 0.3125,-0.578125 0.859375,-1 1.40625,-1 0.328125,0 0.71875,0.125 0.859375,0.40625 z m 0,0"
+ id="path27"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-7"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.828125,-6.234375 c 0,-0.203125 -0.140625,-0.359375 -0.359375,-0.359375 -0.28125,0 -0.546875,0.265625 -0.546875,0.53125 0,0.1875 0.140625,0.359375 0.375,0.359375 0.234375,0 0.53125,-0.234375 0.53125,-0.53125 z m -0.75,3.75 c 0.109375,-0.28125 0.109375,-0.3125 0.21875,-0.578125 0.078125,-0.203125 0.125,-0.34375 0.125,-0.53125 0,-0.4375 -0.3125,-0.8125 -0.8125,-0.8125 -0.9375,0 -1.3125,1.453125 -1.3125,1.53125 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.03125 0.15625,-0.1875 0.28125,-0.9375 0.671875,-1.234375 1.015625,-1.234375 0.078125,0 0.25,0 0.25,0.3125 0,0.21875 -0.078125,0.421875 -0.109375,0.53125 -0.078125,0.25 -0.53125,1.40625 -0.6875,1.84375 -0.109375,0.25 -0.234375,0.578125 -0.234375,0.796875 0,0.46875 0.34375,0.8125 0.8125,0.8125 0.9375,0 1.3125,-1.4375 1.3125,-1.53125 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.09375,0.03125 -0.140625,0.1875 -0.1875,0.625 -0.515625,1.234375 -1.015625,1.234375 -0.171875,0 -0.25,-0.09375 -0.25,-0.328125 0,-0.25 0.0625,-0.390625 0.296875,-1 z m 0,0"
+ id="path30"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-8"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.671875,-2.71875 c 0,-1.046875 -0.6875,-1.6875 -1.59375,-1.6875 -1.328125,0 -2.671875,1.421875 -2.671875,2.828125 0,0.984375 0.671875,1.6875 1.59375,1.6875 1.328125,0 2.671875,-1.375 2.671875,-2.828125 z m -2.65625,2.609375 c -0.4375,0 -0.875,-0.3125 -0.875,-1.09375 0,-0.484375 0.265625,-1.5625 0.578125,-2.0625 0.5,-0.765625 1.078125,-0.921875 1.359375,-0.921875 0.578125,0 0.875,0.484375 0.875,1.078125 0,0.390625 -0.203125,1.4375 -0.578125,2.078125 -0.359375,0.578125 -0.90625,0.921875 -1.359375,0.921875 z m 0,0"
+ id="path33"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-9"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 0.875,-0.59375 c -0.03125,0.15625 -0.09375,0.390625 -0.09375,0.4375 0,0.171875 0.140625,0.265625 0.296875,0.265625 0.125,0 0.296875,-0.078125 0.375,-0.28125 0,-0.015625 0.125,-0.484375 0.1875,-0.734375 l 0.21875,-0.890625 C 1.90625,-2.03125 1.96875,-2.25 2.03125,-2.46875 c 0.03125,-0.171875 0.109375,-0.46875 0.125,-0.5 0.140625,-0.3125 0.671875,-1.21875 1.625,-1.21875 0.453125,0 0.53125,0.375 0.53125,0.703125 0,0.609375 -0.484375,1.890625 -0.640625,2.3125 C 3.578125,-0.9375 3.5625,-0.8125 3.5625,-0.703125 c 0,0.46875 0.359375,0.8125 0.828125,0.8125 0.9375,0 1.296875,-1.453125 1.296875,-1.53125 0,-0.109375 -0.078125,-0.109375 -0.109375,-0.109375 -0.109375,0 -0.109375,0.03125 -0.15625,0.1875 -0.203125,0.671875 -0.53125,1.234375 -1.015625,1.234375 -0.171875,0 -0.234375,-0.09375 -0.234375,-0.328125 0,-0.25 0.078125,-0.484375 0.171875,-0.703125 0.1875,-0.53125 0.609375,-1.625 0.609375,-2.203125 0,-0.65625 -0.421875,-1.0625 -1.140625,-1.0625 -0.90625,0 -1.390625,0.640625 -1.5625,0.875 -0.046875,-0.5625 -0.453125,-0.875 -0.921875,-0.875 -0.453125,0 -0.640625,0.390625 -0.734375,0.5625 C 0.421875,-3.5 0.296875,-2.90625 0.296875,-2.875 c 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.1875,0 0.296875,0.125 0.296875,0.453125 0,0.21875 -0.03125,0.328125 -0.15625,0.84375 z m 0,0"
+ id="path36"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-10"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.578125,-6.8125 c 0,0 0,-0.109375 -0.140625,-0.109375 -0.21875,0 -0.953125,0.078125 -1.21875,0.109375 -0.078125,0 -0.1875,0.015625 -0.1875,0.203125 0,0.109375 0.109375,0.109375 0.25,0.109375 0.484375,0 0.5,0.09375 0.5,0.171875 L 1.75,-6.125 0.484375,-1.140625 C 0.453125,-1.03125 0.4375,-0.96875 0.4375,-0.8125 c 0,0.578125 0.4375,0.921875 0.90625,0.921875 0.328125,0 0.578125,-0.203125 0.75,-0.5625 0.171875,-0.375 0.296875,-0.953125 0.296875,-0.96875 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.125,0.1875 C 1.96875,-0.703125 1.78125,-0.109375 1.375,-0.109375 c -0.296875,0 -0.296875,-0.3125 -0.296875,-0.453125 0,-0.25 0.015625,-0.296875 0.0625,-0.484375 z m 0,0"
+ id="path39"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-11"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 0.875,-0.59375 c -0.03125,0.15625 -0.09375,0.390625 -0.09375,0.4375 0,0.171875 0.140625,0.265625 0.296875,0.265625 0.125,0 0.296875,-0.078125 0.375,-0.28125 0,-0.015625 0.125,-0.484375 0.1875,-0.734375 l 0.21875,-0.890625 C 1.90625,-2.03125 1.96875,-2.25 2.03125,-2.46875 c 0.03125,-0.171875 0.109375,-0.46875 0.125,-0.5 0.140625,-0.3125 0.671875,-1.21875 1.625,-1.21875 0.453125,0 0.53125,0.375 0.53125,0.703125 0,0.25 -0.0625,0.53125 -0.140625,0.828125 L 3.890625,-1.5 3.6875,-0.75 c -0.03125,0.203125 -0.125,0.546875 -0.125,0.59375 0,0.171875 0.140625,0.265625 0.28125,0.265625 0.3125,0 0.375,-0.25 0.453125,-0.5625 0.140625,-0.5625 0.515625,-2.015625 0.59375,-2.40625 0.03125,-0.125 0.5625,-1.328125 1.65625,-1.328125 0.421875,0 0.53125,0.34375 0.53125,0.703125 0,0.5625 -0.421875,1.703125 -0.625,2.234375 -0.078125,0.234375 -0.125,0.34375 -0.125,0.546875 0,0.46875 0.34375,0.8125 0.8125,0.8125 0.9375,0 1.3125,-1.453125 1.3125,-1.53125 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.09375,0.03125 -0.140625,0.1875 -0.15625,0.53125 -0.46875,1.234375 -1.015625,1.234375 -0.171875,0 -0.25,-0.09375 -0.25,-0.328125 0,-0.25 0.09375,-0.484375 0.1875,-0.703125 0.1875,-0.53125 0.609375,-1.625 0.609375,-2.203125 0,-0.640625 -0.40625,-1.0625 -1.15625,-1.0625 -0.734375,0 -1.25,0.4375 -1.625,0.96875 0,-0.125 -0.03125,-0.46875 -0.3125,-0.703125 -0.25,-0.21875 -0.5625,-0.265625 -0.8125,-0.265625 -0.90625,0 -1.390625,0.640625 -1.5625,0.875 -0.046875,-0.578125 -0.46875,-0.875 -0.921875,-0.875 -0.453125,0 -0.640625,0.390625 -0.734375,0.5625 -0.171875,0.359375 -0.296875,0.9375 -0.296875,0.96875 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.15625,0 0.296875,0.078125 0.296875,0.453125 0,0.21875 -0.03125,0.328125 -0.15625,0.84375 z m 0,0"
+ id="path42"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-12"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.328125,-3.015625 C 3.390625,-3.265625 3.625,-4.1875 4.3125,-4.1875 c 0.046875,0 0.296875,0 0.5,0.125 C 4.53125,-4 4.34375,-3.765625 4.34375,-3.515625 c 0,0.15625 0.109375,0.34375 0.375,0.34375 0.21875,0 0.53125,-0.171875 0.53125,-0.578125 0,-0.515625 -0.578125,-0.65625 -0.921875,-0.65625 -0.578125,0 -0.921875,0.53125 -1.046875,0.75 -0.25,-0.65625 -0.78125,-0.75 -1.078125,-0.75 -1.03125,0 -1.609375,1.28125 -1.609375,1.53125 0,0.109375 0.109375,0.109375 0.125,0.109375 0.078125,0 0.109375,-0.03125 0.125,-0.109375 0.34375,-1.0625 1,-1.3125 1.34375,-1.3125 0.1875,0 0.53125,0.09375 0.53125,0.671875 0,0.3125 -0.171875,0.96875 -0.53125,2.375 -0.15625,0.609375 -0.515625,1.03125 -0.953125,1.03125 -0.0625,0 -0.28125,0 -0.5,-0.125 0.25,-0.0625 0.46875,-0.265625 0.46875,-0.546875 0,-0.265625 -0.21875,-0.34375 -0.359375,-0.34375 -0.3125,0 -0.546875,0.25 -0.546875,0.578125 0,0.453125 0.484375,0.65625 0.921875,0.65625 0.671875,0 1.03125,-0.703125 1.046875,-0.75 0.125,0.359375 0.484375,0.75 1.078125,0.75 1.03125,0 1.59375,-1.28125 1.59375,-1.53125 0,-0.109375 -0.078125,-0.109375 -0.109375,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.109375 -0.328125,1.078125 -1,1.3125 -1.3125,1.3125 -0.390625,0 -0.546875,-0.3125 -0.546875,-0.65625 0,-0.21875 0.046875,-0.4375 0.15625,-0.875 z m 0,0"
+ id="path45"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.296875,2.390625 c 0,-0.03125 0,-0.046875 -0.171875,-0.21875 C 1.890625,0.921875 1.5625,-0.96875 1.5625,-2.5 c 0,-1.734375 0.375,-3.46875 1.609375,-4.703125 0.125,-0.125 0.125,-0.140625 0.125,-0.171875 0,-0.078125 -0.03125,-0.109375 -0.09375,-0.109375 -0.109375,0 -1,0.6875 -1.59375,1.953125 -0.5,1.09375 -0.625,2.203125 -0.625,3.03125 0,0.78125 0.109375,1.984375 0.65625,3.125 C 2.25,1.84375 3.09375,2.5 3.203125,2.5 c 0.0625,0 0.09375,-0.03125 0.09375,-0.109375 z m 0,0"
+ id="path48"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.875,-2.5 c 0,-0.765625 -0.109375,-1.96875 -0.65625,-3.109375 -0.59375,-1.21875 -1.453125,-1.875 -1.546875,-1.875 -0.0625,0 -0.109375,0.046875 -0.109375,0.109375 0,0.03125 0,0.046875 0.1875,0.234375 0.984375,0.984375 1.546875,2.5625 1.546875,4.640625 0,1.71875 -0.359375,3.46875 -1.59375,4.71875 C 0.5625,2.34375 0.5625,2.359375 0.5625,2.390625 0.5625,2.453125 0.609375,2.5 0.671875,2.5 0.765625,2.5 1.671875,1.8125 2.25,0.546875 2.765625,-0.546875 2.875,-1.65625 2.875,-2.5 z m 0,0"
+ id="path51"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 6.84375,-3.265625 c 0.15625,0 0.34375,0 0.34375,-0.1875 C 7.1875,-3.65625 7,-3.65625 6.859375,-3.65625 l -5.96875,0 c -0.140625,0 -0.328125,0 -0.328125,0.203125 0,0.1875 0.1875,0.1875 0.328125,0.1875 z m 0.015625,1.9375 c 0.140625,0 0.328125,0 0.328125,-0.203125 0,-0.1875 -0.1875,-0.1875 -0.34375,-0.1875 l -5.953125,0 c -0.140625,0 -0.328125,0 -0.328125,0.1875 0,0.203125 0.1875,0.203125 0.328125,0.203125 z m 0,0"
+ id="path54"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.9375,-6.375 c 0,-0.25 0,-0.265625 -0.234375,-0.265625 C 2.078125,-6 1.203125,-6 0.890625,-6 l 0,0.3125 c 0.203125,0 0.78125,0 1.296875,-0.265625 l 0,5.171875 c 0,0.359375 -0.03125,0.46875 -0.921875,0.46875 l -0.3125,0 0,0.3125 c 0.34375,-0.03125 1.203125,-0.03125 1.609375,-0.03125 0.390625,0 1.265625,0 1.609375,0.03125 l 0,-0.3125 -0.3125,0 c -0.90625,0 -0.921875,-0.109375 -0.921875,-0.46875 z m 0,0"
+ id="path57"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph2-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.875,-2.765625 1.890625,-4.75 C 1.765625,-4.875 1.75,-4.890625 1.671875,-4.890625 1.5625,-4.890625 1.46875,-4.8125 1.46875,-4.6875 c 0,0.0625 0.015625,0.078125 0.125,0.1875 l 2,2 -2,2.015625 c -0.109375,0.109375 -0.125,0.125 -0.125,0.1875 0,0.125 0.09375,0.203125 0.203125,0.203125 0.078125,0 0.09375,-0.015625 0.21875,-0.140625 L 3.875,-2.21875 l 2.0625,2.0625 c 0.015625,0.015625 0.078125,0.0625 0.140625,0.0625 0.125,0 0.203125,-0.078125 0.203125,-0.203125 0,-0.015625 0,-0.046875 -0.03125,-0.109375 C 6.234375,-0.421875 4.65625,-1.984375 4.15625,-2.5 l 1.828125,-1.8125 c 0.046875,-0.0625 0.203125,-0.1875 0.25,-0.25 0,-0.015625 0.046875,-0.0625 0.046875,-0.125 0,-0.125 -0.078125,-0.203125 -0.203125,-0.203125 C 6,-4.890625 5.96875,-4.859375 5.859375,-4.75 z m 0,0"
+ id="path60"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph3-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 6.984375,23.421875 c 0,-0.04687 -0.03125,-0.0625 -0.046875,-0.09375 -0.375,-0.375 -1.03125,-1.03125 -1.703125,-2.109375 C 3.625,18.640625 2.90625,15.40625 2.90625,11.5625 c 0,-2.6875 0.359375,-6.140625 2,-9.109375 C 5.6875,1.03125 6.515625,0.21875 6.953125,-0.21875 c 0.03125,-0.03125 0.03125,-0.046875 0.03125,-0.078125 0,-0.109375 -0.078125,-0.109375 -0.21875,-0.109375 -0.140625,0 -0.15625,0 -0.3125,0.15625 -3.328125,3.046875 -4.375,7.609375 -4.375,11.796875 0,3.921875 0.890625,7.875 3.421875,10.859375 0.203125,0.21875 0.578125,0.625 0.984375,0.984375 0.125,0.125 0.140625,0.125 0.28125,0.125 0.140625,0 0.21875,0 0.21875,-0.09375 z m 0,0"
+ id="path63"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph3-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 5.25,11.5625 C 5.25,7.640625 4.359375,3.703125 1.828125,0.71875 1.625,0.484375 1.25,0.078125 0.84375,-0.28125 c -0.125,-0.125 -0.140625,-0.125 -0.28125,-0.125 -0.125,0 -0.21875,0 -0.21875,0.109375 0,0.03125 0.046875,0.078125 0.0625,0.09375 0.34375,0.359375 1.015625,1.03125 1.6875,2.109375 1.609375,2.5625 2.328125,5.8125 2.328125,9.640625 0,2.6875 -0.359375,6.140625 -2,9.125 -0.78125,1.40625 -1.609375,2.234375 -2.03125,2.65625 -0.015625,0.03125 -0.046875,0.0625 -0.046875,0.09375 0,0.09375 0.09375,0.09375 0.21875,0.09375 0.140625,0 0.15625,0 0.3125,-0.15625 C 4.203125,20.328125 5.25,15.765625 5.25,11.5625 z m 0,0"
+ id="path66"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.046875,-2.671875 c -0.25,0.046875 -0.34375,0.234375 -0.34375,0.390625 0,0.1875 0.140625,0.265625 0.265625,0.265625 0.15625,0 0.390625,-0.109375 0.390625,-0.453125 0,-0.46875 -0.53125,-0.609375 -0.90625,-0.609375 -1.046875,0 -2.015625,0.96875 -2.015625,1.9375 0,0.59375 0.40625,1.203125 1.28125,1.203125 1.1875,0 1.734375,-0.6875 1.734375,-0.78125 0,-0.046875 -0.0625,-0.125 -0.125,-0.125 -0.03125,0 -0.046875,0.015625 -0.109375,0.078125 C 2.671875,-0.125 1.859375,-0.125 1.734375,-0.125 c -0.5,0 -0.71875,-0.34375 -0.71875,-0.78125 0,-0.1875 0.09375,-0.953125 0.453125,-1.4375 0.265625,-0.34375 0.625,-0.53125 0.984375,-0.53125 0.09375,0 0.421875,0.015625 0.59375,0.203125 z m 0,0"
+ id="path69"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 2.953125,-1.125 C 2.90625,-0.984375 2.84375,-0.71875 2.84375,-0.71875 2.703125,-0.5 2.421875,-0.125 2,-0.125 c -0.484375,0 -0.484375,-0.453125 -0.484375,-0.578125 0,-0.40625 0.1875,-0.90625 0.390625,-1.421875 C 1.953125,-2.265625 2,-2.359375 2,-2.46875 2,-2.84375 1.6875,-3.078125 1.34375,-3.078125 0.640625,-3.078125 0.328125,-2.125 0.328125,-2 c 0,0.078125 0.09375,0.078125 0.125,0.078125 0.09375,0 0.09375,-0.03125 0.125,-0.109375 0.15625,-0.5625 0.46875,-0.84375 0.734375,-0.84375 0.125,0 0.171875,0.078125 0.171875,0.234375 0,0.171875 -0.046875,0.3125 -0.125,0.46875 -0.375,0.96875 -0.375,1.171875 -0.375,1.359375 0,0.109375 0,0.4375 0.265625,0.65625 0.203125,0.171875 0.46875,0.21875 0.71875,0.21875 0.4375,0 0.671875,-0.234375 0.90625,-0.453125 C 3.03125,0.0625 3.484375,0.0625 3.578125,0.0625 3.8125,0.0625 4,-0.0625 4.125,-0.296875 4.28125,-0.578125 4.375,-0.96875 4.375,-1 c 0,-0.09375 -0.09375,-0.09375 -0.109375,-0.09375 -0.109375,0 -0.109375,0.03125 -0.15625,0.21875 -0.09375,0.328125 -0.21875,0.75 -0.515625,0.75 -0.171875,0 -0.234375,-0.15625 -0.234375,-0.34375 0,-0.109375 0.0625,-0.375 0.109375,-0.546875 0.046875,-0.1875 0.125,-0.46875 0.15625,-0.625 l 0.15625,-0.625 C 3.828125,-2.4375 3.90625,-2.75 3.90625,-2.78125 3.90625,-2.921875 3.796875,-3 3.671875,-3 c -0.25,0 -0.3125,0.203125 -0.359375,0.421875 z m 0,0"
+ id="path72"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.640625,-1.40625 c 0,-0.046875 0.171875,-0.671875 0.171875,-0.703125 0.015625,-0.0625 0.21875,-0.40625 0.453125,-0.578125 0.0625,-0.046875 0.25,-0.1875 0.5625,-0.1875 0.0625,0 0.234375,0 0.375,0.09375 -0.21875,0.0625 -0.296875,0.265625 -0.296875,0.390625 0,0.140625 0.109375,0.25 0.265625,0.25 0.171875,0 0.390625,-0.125 0.390625,-0.421875 0,-0.359375 -0.375,-0.515625 -0.734375,-0.515625 -0.359375,0 -0.671875,0.15625 -0.984375,0.5 -0.125,-0.421875 -0.546875,-0.5 -0.71875,-0.5 -0.25,0 -0.421875,0.171875 -0.546875,0.359375 -0.15625,0.265625 -0.25,0.671875 -0.25,0.71875 0,0.078125 0.09375,0.078125 0.125,0.078125 0.09375,0 0.09375,-0.015625 0.140625,-0.203125 0.109375,-0.421875 0.25,-0.75 0.515625,-0.75 0.1875,0 0.234375,0.15625 0.234375,0.34375 0,0.125 -0.0625,0.390625 -0.125,0.578125 -0.046875,0.1875 -0.109375,0.46875 -0.140625,0.625 L 0.84375,-0.4375 C 0.828125,-0.34375 0.78125,-0.171875 0.78125,-0.15625 0.78125,0 0.90625,0.0625 1.015625,0.0625 1.125,0.0625 1.265625,0 1.3125,-0.125 1.328125,-0.171875 1.40625,-0.484375 1.453125,-0.65625 z m 0,0"
+ id="path75"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.71875,-2.53125 c 0,-0.546875 -0.328125,-0.546875 -0.34375,-0.546875 -0.1875,0 -0.375,0.1875 -0.375,0.375 0,0.109375 0.0625,0.171875 0.109375,0.203125 0.125,0.109375 0.265625,0.28125 0.265625,0.5625 0,0.3125 -0.46875,1.8125 -1.296875,1.8125 -0.5625,0 -0.5625,-0.5 -0.5625,-0.625 0,-0.3125 0.125,-0.703125 0.390625,-1.359375 C 1.953125,-2.25 2,-2.359375 2,-2.46875 2,-2.84375 1.6875,-3.078125 1.34375,-3.078125 0.640625,-3.078125 0.328125,-2.125 0.328125,-2 c 0,0.078125 0.09375,0.078125 0.125,0.078125 0.09375,0 0.09375,-0.03125 0.125,-0.109375 C 0.734375,-2.59375 1.03125,-2.875 1.3125,-2.875 c 0.125,0 0.171875,0.078125 0.171875,0.234375 0,0.171875 -0.046875,0.3125 -0.125,0.46875 -0.296875,0.78125 -0.375,1.078125 -0.375,1.328125 0,0.6875 0.546875,0.90625 1.078125,0.90625 1.171875,0 1.65625,-2.015625 1.65625,-2.59375 z m 0,0"
+ id="path78"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-4"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.5625,-1.59375 c 0.1875,0 0.75,-0.015625 1.125,-0.140625 0.515625,-0.1875 0.609375,-0.515625 0.609375,-0.71875 0,-0.390625 -0.390625,-0.625 -0.859375,-0.625 -0.84375,0 -1.96875,0.640625 -1.96875,1.84375 0,0.703125 0.4375,1.296875 1.25,1.296875 1.1875,0 1.734375,-0.6875 1.734375,-0.78125 0,-0.046875 -0.0625,-0.125 -0.125,-0.125 -0.03125,0 -0.046875,0.015625 -0.109375,0.078125 C 2.671875,-0.125 1.859375,-0.125 1.734375,-0.125 1.3125,-0.125 1.03125,-0.40625 1.03125,-0.96875 c 0,-0.09375 0,-0.234375 0.09375,-0.625 z M 1.171875,-1.78125 C 1.46875,-2.796875 2.234375,-2.875 2.4375,-2.875 2.734375,-2.875 3,-2.71875 3,-2.453125 3,-1.78125 1.8125,-1.78125 1.515625,-1.78125 z m 0,0"
+ id="path81"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-5"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.390625,-2.25 0.734375,0 c 0.53125,0 0.625,0.09375 0.625,0.3125 0,0.109375 0,0.125 -0.046875,0.328125 -0.015625,0.03125 -0.03125,0.0625 -0.03125,0.078125 0,0.0625 0.0625,0.109375 0.125,0.109375 0.09375,0 0.09375,-0.046875 0.140625,-0.171875 l 0.375,-1.46875 c 0,-0.03125 0.015625,-0.125 0.015625,-0.140625 0,-0.078125 -0.046875,-0.109375 -0.109375,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.171875 C 3.9375,-2.59375 3.734375,-2.5 3.140625,-2.5 l -0.6875,0 0.4375,-1.75 c 0.046875,-0.203125 0.0625,-0.234375 0.34375,-0.234375 l 1.078125,0 c 0.921875,0 1.09375,0.21875 1.09375,0.8125 0,0.21875 -0.03125,0.375 -0.03125,0.421875 0,0.0625 0.03125,0.125 0.125,0.125 0.109375,0 0.109375,-0.0625 0.125,-0.1875 L 5.75,-4.515625 c 0.015625,-0.21875 -0.03125,-0.21875 -0.203125,-0.21875 l -3.71875,0 c -0.140625,0 -0.21875,0 -0.21875,0.15625 0,0.09375 0.078125,0.09375 0.21875,0.09375 0,0 0.140625,0 0.265625,0.015625 C 2.234375,-4.453125 2.25,-4.4375 2.25,-4.375 c 0,0.046875 -0.015625,0.125 -0.03125,0.15625 L 1.3125,-0.578125 C 1.234375,-0.296875 1.234375,-0.25 0.6875,-0.25 c -0.109375,0 -0.203125,0 -0.203125,0.140625 C 0.484375,-0.03125 0.53125,0 0.59375,0 0.796875,0 1.3125,-0.03125 1.515625,-0.03125 l 0.53125,0.015625 C 2.234375,-0.015625 2.421875,0 2.59375,0 2.640625,0 2.75,0 2.75,-0.15625 2.75,-0.25 2.671875,-0.25 2.515625,-0.25 c -0.015625,0 -0.1875,0 -0.375,-0.015625 C 2,-0.28125 1.9375,-0.28125 1.9375,-0.390625 c 0,-0.015625 0,-0.046875 0.015625,-0.125 z m 0,0"
+ id="path84"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-6"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.9375,-2.65625 c -0.140625,-0.234375 -0.375,-0.421875 -0.71875,-0.421875 -0.890625,0 -1.796875,0.984375 -1.796875,1.984375 0,0.6875 0.453125,1.15625 1.0625,1.15625 0.375,0 0.703125,-0.203125 0.984375,-0.484375 C 2.59375,0 3,0.0625 3.1875,0.0625 c 0.25,0 0.421875,-0.140625 0.546875,-0.359375 0.15625,-0.28125 0.25,-0.671875 0.25,-0.703125 0,-0.09375 -0.09375,-0.09375 -0.109375,-0.09375 -0.109375,0 -0.109375,0.03125 -0.15625,0.21875 C 3.625,-0.53125 3.5,-0.125 3.203125,-0.125 3.03125,-0.125 2.96875,-0.28125 2.96875,-0.46875 c 0,-0.109375 0.0625,-0.375 0.109375,-0.546875 0.046875,-0.1875 0.125,-0.46875 0.15625,-0.625 L 3.375,-2.171875 C 3.421875,-2.359375 3.5,-2.6875 3.5,-2.71875 3.5,-2.875 3.375,-2.9375 3.265625,-2.9375 c -0.125,0 -0.28125,0.078125 -0.328125,0.28125 z M 2.5,-0.875 C 2.453125,-0.671875 2.296875,-0.53125 2.140625,-0.40625 2.078125,-0.34375 1.796875,-0.125 1.5,-0.125 c -0.265625,0 -0.515625,-0.1875 -0.515625,-0.671875 0,-0.375 0.203125,-1.140625 0.375,-1.421875 0.3125,-0.5625 0.671875,-0.65625 0.859375,-0.65625 0.484375,0 0.625,0.53125 0.625,0.609375 0,0.015625 -0.015625,0.078125 -0.015625,0.09375 z m 0,0"
+ id="path87"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-7"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.71875,-2.75 0.703125,0 c 0.140625,0 0.21875,0 0.21875,-0.15625 C 2.640625,-3 2.5625,-3 2.4375,-3 l -0.65625,0 0.25,-1.03125 C 2.046875,-4.0625 2.0625,-4.109375 2.0625,-4.125 c 0,-0.140625 -0.109375,-0.234375 -0.25,-0.234375 -0.171875,0 -0.265625,0.125 -0.328125,0.296875 C 1.4375,-3.875 1.53125,-4.21875 1.21875,-3 l -0.703125,0 c -0.125,0 -0.21875,0 -0.21875,0.15625 C 0.296875,-2.75 0.375,-2.75 0.5,-2.75 l 0.65625,0 L 0.75,-1.109375 C 0.703125,-0.9375 0.640625,-0.6875 0.640625,-0.59375 c 0,0.40625 0.359375,0.65625 0.75,0.65625 0.78125,0 1.21875,-0.96875 1.21875,-1.0625 0,-0.09375 -0.09375,-0.09375 -0.109375,-0.09375 -0.09375,0 -0.09375,0.015625 -0.15625,0.140625 -0.1875,0.4375 -0.546875,0.828125 -0.921875,0.828125 -0.15625,0 -0.25,-0.09375 -0.25,-0.34375 0,-0.0625 0.03125,-0.21875 0.046875,-0.28125 z m 0,0"
+ id="path90"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph4-8"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.703125,-1.859375 c 0,-0.765625 -0.578125,-1.21875 -1.265625,-1.21875 -1.03125,0 -2,0.96875 -2,1.921875 0,0.703125 0.5,1.21875 1.265625,1.21875 1,0 2,-0.90625 2,-1.921875 z m -2,1.734375 c -0.34375,0 -0.6875,-0.21875 -0.6875,-0.78125 0,-0.28125 0.125,-0.96875 0.40625,-1.359375 C 1.71875,-2.703125 2.125,-2.875 2.4375,-2.875 c 0.375,0 0.6875,0.25 0.6875,0.765625 C 3.125,-1.9375 3.046875,-1.25 2.734375,-0.765625 2.46875,-0.34375 2.0625,-0.125 1.703125,-0.125 z m 0,0"
+ id="path93"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ </g>
+ </defs>
+ <g
+ id="g3498"
+ transform="translate(-146.26423,-141.81494)">
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g96">
+ <use
+ xlink:href="#glyph0-0"
+ x="153"
+ y="160.3"
+ id="use98"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g100">
+ <use
+ xlink:href="#glyph1-0"
+ x="158.16016"
+ y="160.3"
+ id="use102"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g104">
+ <use
+ xlink:href="#glyph0-1"
+ x="162"
+ y="160.3"
+ id="use106"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g108">
+ <use
+ xlink:href="#glyph0-2"
+ x="166.68001"
+ y="160.3"
+ id="use110"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g112">
+ <use
+ xlink:href="#glyph0-3"
+ x="170.28001"
+ y="160.3"
+ id="use114"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g116">
+ <use
+ xlink:href="#glyph0-4"
+ x="174.96001"
+ y="160.3"
+ id="use118"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g120">
+ <use
+ xlink:href="#glyph1-1"
+ x="180"
+ y="160.3"
+ id="use122"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g124">
+ <use
+ xlink:href="#glyph1-2"
+ x="186.60001"
+ y="160.3"
+ id="use126"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g128">
+ <use
+ xlink:href="#glyph0-5"
+ x="197.03979"
+ y="160.3"
+ id="use130"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g132">
+ <use
+ xlink:href="#glyph0-6"
+ x="202.31979"
+ y="160.3"
+ id="use134"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g136">
+ <use
+ xlink:href="#glyph0-2"
+ x="206.6398"
+ y="160.3"
+ id="use138"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g140">
+ <use
+ xlink:href="#glyph0-7"
+ x="210.23981"
+ y="160.3"
+ id="use142"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g144">
+ <use
+ xlink:href="#glyph0-8"
+ x="213.7198"
+ y="160.3"
+ id="use146"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g148">
+ <use
+ xlink:href="#glyph0-9"
+ x="218.51981"
+ y="160.3"
+ id="use150"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 225.10937,159.83203 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path152"
+ inkscape:connector-curvature="0" />
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g154">
+ <use
+ xlink:href="#glyph0-0"
+ x="228.12"
+ y="160.3"
+ id="use156"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g158">
+ <use
+ xlink:href="#glyph0-3"
+ x="233.28001"
+ y="160.3"
+ id="use160"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g162">
+ <use
+ xlink:href="#glyph0-10"
+ x="237.96001"
+ y="160.3"
+ id="use164"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g166">
+ <use
+ xlink:href="#glyph0-2"
+ x="241.20009"
+ y="160.3"
+ id="use168"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g170">
+ <use
+ xlink:href="#glyph0-5"
+ x="244.80009"
+ y="160.3"
+ id="use172"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g174">
+ <use
+ xlink:href="#glyph2-0"
+ x="252.12"
+ y="160.3"
+ id="use176"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g178">
+ <use
+ xlink:href="#glyph3-0"
+ x="262.08017"
+ y="146.26019"
+ id="use180"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g182">
+ <use
+ xlink:href="#glyph0-11"
+ x="299.88016"
+ y="153.58012"
+ id="use184"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g186">
+ <use
+ xlink:href="#glyph0-5"
+ x="308.64017"
+ y="153.58012"
+ id="use188"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g190">
+ <use
+ xlink:href="#glyph0-12"
+ x="313.92017"
+ y="153.58012"
+ id="use192"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 320.14844,153.11328 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path194"
+ inkscape:connector-curvature="0" />
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g196">
+ <use
+ xlink:href="#glyph0-5"
+ x="323.16"
+ y="153.58"
+ id="use198"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g200">
+ <use
+ xlink:href="#glyph0-6"
+ x="328.44"
+ y="153.58"
+ id="use202"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g204">
+ <use
+ xlink:href="#glyph0-6"
+ x="332.76001"
+ y="153.58"
+ id="use206"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g208">
+ <use
+ xlink:href="#glyph0-3"
+ x="337.07999"
+ y="153.58"
+ id="use210"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g212">
+ <use
+ xlink:href="#glyph0-10"
+ x="341.76001"
+ y="153.58"
+ id="use214"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 270.58984,157.55078 103.5586,0 0,0.48047 -103.5586,0 z m 0,0"
+ id="path216"
+ inkscape:connector-curvature="0" />
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g218">
+ <use
+ xlink:href="#glyph0-1"
+ x="270.60001"
+ y="167.14"
+ id="use220"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g222">
+ <use
+ xlink:href="#glyph0-2"
+ x="275.28"
+ y="167.14"
+ id="use224"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g226">
+ <use
+ xlink:href="#glyph0-3"
+ x="278.88"
+ y="167.14"
+ id="use228"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g230">
+ <use
+ xlink:href="#glyph0-4"
+ x="283.56003"
+ y="167.14"
+ id="use232"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g234">
+ <use
+ xlink:href="#glyph0-1"
+ x="288.60001"
+ y="167.14"
+ id="use236"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 293.86719,166.67187 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path238"
+ inkscape:connector-curvature="0" />
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g240">
+ <use
+ xlink:href="#glyph0-2"
+ x="296.88"
+ y="167.14"
+ id="use242"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g244">
+ <use
+ xlink:href="#glyph0-8"
+ x="300.48001"
+ y="167.14"
+ id="use246"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 305.86719,166.67187 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path248"
+ inkscape:connector-curvature="0" />
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g250">
+ <use
+ xlink:href="#glyph0-11"
+ x="308.88"
+ y="167.14"
+ id="use252"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g254">
+ <use
+ xlink:href="#glyph0-5"
+ x="317.64001"
+ y="167.14"
+ id="use256"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g258">
+ <use
+ xlink:href="#glyph0-12"
+ x="322.91998"
+ y="167.14"
+ id="use260"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g262">
+ <use
+ xlink:href="#glyph4-0"
+ x="328.56009"
+ y="164.26031"
+ id="use264"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g266">
+ <use
+ xlink:href="#glyph4-1"
+ x="332.1601"
+ y="164.26031"
+ id="use268"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g270">
+ <use
+ xlink:href="#glyph4-2"
+ x="336.84009"
+ y="164.26031"
+ id="use272"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g274">
+ <use
+ xlink:href="#glyph4-3"
+ x="340.79993"
+ y="164.26031"
+ id="use276"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g278">
+ <use
+ xlink:href="#glyph4-4"
+ x="344.99994"
+ y="164.26031"
+ id="use280"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g282">
+ <use
+ xlink:href="#glyph4-5"
+ x="348.71994"
+ y="164.26031"
+ id="use284"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g286">
+ <use
+ xlink:href="#glyph4-6"
+ x="354.83978"
+ y="164.26031"
+ id="use288"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g290">
+ <use
+ xlink:href="#glyph4-0"
+ x="359.15979"
+ y="164.26031"
+ id="use292"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g294">
+ <use
+ xlink:href="#glyph4-7"
+ x="362.75977"
+ y="164.26031"
+ id="use296"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g298">
+ <use
+ xlink:href="#glyph4-8"
+ x="365.75977"
+ y="164.26031"
+ id="use300"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g302">
+ <use
+ xlink:href="#glyph4-2"
+ x="369.71979"
+ y="164.26031"
+ id="use304"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g306">
+ <use
+ xlink:href="#glyph3-1"
+ x="375.36011"
+ y="146.26031"
+ id="use308"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g310">
+ <use
+ xlink:href="#glyph2-0"
+ x="384.83978"
+ y="160.30011"
+ id="use312"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g314">
+ <use
+ xlink:href="#glyph0-1"
+ x="394.79996"
+ y="160.30011"
+ id="use316"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g318">
+ <use
+ xlink:href="#glyph0-2"
+ x="399.47995"
+ y="160.30011"
+ id="use320"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g322">
+ <use
+ xlink:href="#glyph0-3"
+ x="403.07996"
+ y="160.30011"
+ id="use324"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ style="fill:#000000;fill-opacity:1"
+ id="g326">
+ <use
+ xlink:href="#glyph0-4"
+ x="407.75998"
+ y="160.30011"
+ id="use328"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g330">
+ <use
+ xlink:href="#glyph4-0"
+ x="412.79996"
+ y="156.10011"
+ id="use332"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g334">
+ <use
+ xlink:href="#glyph4-1"
+ x="416.39996"
+ y="156.10011"
+ id="use336"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g338">
+ <use
+ xlink:href="#glyph4-2"
+ x="421.07999"
+ y="156.10011"
+ id="use340"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g342">
+ <use
+ xlink:href="#glyph4-3"
+ x="425.03983"
+ y="156.10011"
+ id="use344"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g346">
+ <use
+ xlink:href="#glyph4-4"
+ x="429.23984"
+ y="156.10011"
+ id="use348"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g350">
+ <use
+ xlink:href="#glyph4-5"
+ x="432.95984"
+ y="156.10011"
+ id="use352"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g354">
+ <use
+ xlink:href="#glyph4-6"
+ x="439.07965"
+ y="156.10011"
+ id="use356"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g358">
+ <use
+ xlink:href="#glyph4-0"
+ x="443.39969"
+ y="156.10011"
+ id="use360"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g362">
+ <use
+ xlink:href="#glyph4-7"
+ x="446.99973"
+ y="156.10011"
+ id="use364"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g366">
+ <use
+ xlink:href="#glyph4-8"
+ x="449.99973"
+ y="156.10011"
+ id="use368"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(1.6,0)"
+ style="fill:#000000;fill-opacity:1"
+ id="g370">
+ <use
+ xlink:href="#glyph4-2"
+ x="453.95972"
+ y="156.10011"
+ id="use372"
+ width="595"
+ height="842" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-4.svg b/libX11/specs/XKB/XKBlib-4.svg
new file mode 100644
index 000000000..fbe85e769
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-4.svg
@@ -0,0 +1,574 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="220"
+ height="30"
+ viewBox="0 0 176 24"
+ version="1.1"
+ id="svg2"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-4.svg">
+ <metadata
+ id="metadata182">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <sodipodi:namedview
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ id="namedview180"
+ showgrid="false"
+ inkscape:zoom="3.2545455"
+ inkscape:cx="146.41061"
+ inkscape:cy="15"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1"
+ inkscape:current-layer="svg2" />
+ <defs
+ id="defs4">
+ <g
+ id="g6">
+ <symbol
+ overflow="visible"
+ id="glyph0-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.953125,-3.78125 c -0.171875,0 -0.296875,0 -0.4375,0.125 -0.171875,0.15625 -0.1875,0.328125 -0.1875,0.390625 0,0.25 0.1875,0.359375 0.375,0.359375 0.28125,0 0.546875,-0.25 0.546875,-0.640625 0,-0.484375 -0.46875,-0.859375 -1.171875,-0.859375 -1.34375,0 -2.671875,1.421875 -2.671875,2.828125 0,0.90625 0.578125,1.6875 1.625,1.6875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.625,0 -0.90625,-0.484375 -0.90625,-1.09375 0,-0.40625 0.203125,-1.375 0.546875,-1.984375 0.3125,-0.578125 0.859375,-1 1.40625,-1 0.328125,0 0.71875,0.125 0.859375,0.40625 z m 0,0"
+ id="path9"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.484375,-0.5625 C 3.59375,-0.15625 3.953125,0.109375 4.375,0.109375 4.71875,0.109375 4.953125,-0.125 5.109375,-0.4375 5.28125,-0.796875 5.40625,-1.40625 5.40625,-1.421875 c 0,-0.109375 -0.078125,-0.109375 -0.109375,-0.109375 -0.109375,0 -0.109375,0.046875 -0.140625,0.1875 -0.140625,0.5625 -0.328125,1.234375 -0.75,1.234375 -0.203125,0 -0.3125,-0.125 -0.3125,-0.453125 0,-0.21875 0.125,-0.6875 0.203125,-1.046875 L 4.578125,-2.6875 C 4.609375,-2.828125 4.703125,-3.203125 4.75,-3.359375 4.796875,-3.59375 4.890625,-3.96875 4.890625,-4.03125 c 0,-0.171875 -0.140625,-0.265625 -0.28125,-0.265625 -0.046875,0 -0.3125,0.015625 -0.390625,0.34375 -0.1875,0.734375 -0.625,2.484375 -0.75,3 -0.015625,0.046875 -0.40625,0.84375 -1.140625,0.84375 -0.515625,0 -0.609375,-0.453125 -0.609375,-0.8125 0,-0.5625 0.28125,-1.34375 0.53125,-2.03125 0.125,-0.3125 0.171875,-0.453125 0.171875,-0.640625 0,-0.4375 -0.3125,-0.8125 -0.8125,-0.8125 -0.953125,0 -1.3125,1.453125 -1.3125,1.53125 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.03125 0.15625,-0.1875 0.25,-0.859375 0.640625,-1.234375 1.015625,-1.234375 0.09375,0 0.25,0.015625 0.25,0.328125 0,0.234375 -0.109375,0.53125 -0.171875,0.671875 -0.375,1 -0.578125,1.609375 -0.578125,2.09375 0,0.953125 0.6875,1.203125 1.21875,1.203125 0.65625,0 1.015625,-0.453125 1.1875,-0.671875 z m 0,0"
+ id="path12"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 0.875,-0.59375 c -0.03125,0.15625 -0.09375,0.390625 -0.09375,0.4375 0,0.171875 0.140625,0.265625 0.296875,0.265625 0.125,0 0.296875,-0.078125 0.375,-0.28125 C 1.46875,-0.203125 1.796875,-1.5625 1.84375,-1.75 c 0.078125,-0.328125 0.265625,-1.015625 0.3125,-1.296875 0.046875,-0.125 0.328125,-0.59375 0.5625,-0.8125 0.078125,-0.0625 0.375,-0.328125 0.796875,-0.328125 0.265625,0 0.40625,0.125 0.421875,0.125 -0.296875,0.046875 -0.515625,0.28125 -0.515625,0.546875 0,0.15625 0.109375,0.34375 0.375,0.34375 0.265625,0 0.546875,-0.234375 0.546875,-0.59375 0,-0.34375 -0.3125,-0.640625 -0.828125,-0.640625 C 2.875,-4.40625 2.4375,-3.921875 2.25,-3.640625 2.15625,-4.09375 1.796875,-4.40625 1.328125,-4.40625 0.875,-4.40625 0.6875,-4.015625 0.59375,-3.84375 0.421875,-3.5 0.296875,-2.90625 0.296875,-2.875 c 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.15625,0 0.296875,0.078125 0.296875,0.453125 0,0.21875 -0.03125,0.328125 -0.15625,0.84375 z m 0,0"
+ id="path15"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.671875,-3.703125 c 0,-0.546875 -0.265625,-0.703125 -0.4375,-0.703125 -0.25,0 -0.5,0.265625 -0.5,0.484375 0,0.125 0.046875,0.1875 0.15625,0.296875 0.21875,0.203125 0.34375,0.453125 0.34375,0.8125 0,0.421875 -0.609375,2.703125 -1.765625,2.703125 -0.515625,0 -0.75,-0.34375 -0.75,-0.875 0,-0.546875 0.28125,-1.28125 0.578125,-2.109375 0.078125,-0.171875 0.125,-0.3125 0.125,-0.5 0,-0.4375 -0.3125,-0.8125 -0.8125,-0.8125 -0.9375,0 -1.3125,1.453125 -1.3125,1.53125 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.03125 0.15625,-0.1875 0.296875,-1 0.71875,-1.234375 1.015625,-1.234375 0.078125,0 0.25,0 0.25,0.3125 0,0.25 -0.109375,0.53125 -0.171875,0.703125 -0.4375,1.15625 -0.5625,1.609375 -0.5625,2.046875 0,1.078125 0.875,1.234375 1.328125,1.234375 1.671875,0 2.25,-3.296875 2.25,-3.8125 z m 0,0"
+ id="path18"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-4"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.859375,-2.296875 c 0.296875,0 1.03125,-0.03125 1.53125,-0.234375 0.703125,-0.296875 0.75,-0.890625 0.75,-1.03125 0,-0.4375 -0.375,-0.84375 -1.0625,-0.84375 -1.109375,0 -2.625,0.96875 -2.625,2.71875 0,1.015625 0.59375,1.796875 1.578125,1.796875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.78125,0 -0.875,-0.84375 -0.875,-1.15625 0,-0.125 0.015625,-0.421875 0.15625,-1.03125 z m -0.46875,-0.21875 C 1.78125,-4.03125 2.8125,-4.1875 3.078125,-4.1875 c 0.453125,0 0.734375,0.296875 0.734375,0.625 0,1.046875 -1.59375,1.046875 -2.015625,1.046875 z m 0,0"
+ id="path21"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-5"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.015625,-3.234375 0.96875,0 c 0.75,0 0.828125,0.15625 0.828125,0.4375 0,0.078125 0,0.1875 -0.0625,0.5 C 4.71875,-2.25 4.71875,-2.21875 4.71875,-2.1875 c 0,0.078125 0.0625,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.03125 0.15625,-0.203125 L 5.53125,-4.453125 C 5.5625,-4.5625 5.5625,-4.578125 5.5625,-4.609375 5.5625,-4.625 5.546875,-4.71875 5.4375,-4.71875 5.34375,-4.71875 5.328125,-4.671875 5.296875,-4.5 5.078125,-3.734375 4.859375,-3.546875 4,-3.546875 l -0.90625,0 0.640625,-2.53125 C 3.828125,-6.4375 3.84375,-6.46875 4.28125,-6.46875 l 1.3125,0 c 1.21875,0 1.453125,0.328125 1.453125,1.09375 0,0.234375 0,0.265625 -0.03125,0.546875 C 7,-4.703125 7,-4.6875 7,-4.65625 c 0,0.046875 0.03125,0.125 0.125,0.125 0.109375,0 0.109375,-0.0625 0.125,-0.25 L 7.453125,-6.515625 C 7.484375,-6.78125 7.4375,-6.78125 7.1875,-6.78125 l -4.890625,0 c -0.1875,0 -0.296875,0 -0.296875,0.203125 0,0.109375 0.09375,0.109375 0.28125,0.109375 0.375,0 0.65625,0 0.65625,0.171875 0,0.046875 0,0.0625 -0.0625,0.25 L 1.5625,-0.78125 c -0.09375,0.390625 -0.109375,0.46875 -0.90625,0.46875 -0.171875,0 -0.28125,0 -0.28125,0.1875 C 0.375,0 0.5,0 0.53125,0 0.8125,0 1.5625,-0.03125 1.84375,-0.03125 2.171875,-0.03125 3,0 3.328125,0 3.421875,0 3.53125,0 3.53125,-0.1875 3.53125,-0.265625 3.484375,-0.296875 3.484375,-0.296875 3.453125,-0.3125 3.421875,-0.3125 3.203125,-0.3125 c -0.21875,0 -0.265625,0 -0.515625,-0.015625 -0.296875,-0.03125 -0.328125,-0.078125 -0.328125,-0.203125 0,-0.015625 0,-0.078125 0.046875,-0.21875 z m 0,0"
+ id="path24"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-6"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.71875,-3.765625 C 3.53125,-4.140625 3.25,-4.40625 2.796875,-4.40625 c -1.15625,0 -2.390625,1.46875 -2.390625,2.921875 0,0.9375 0.546875,1.59375 1.3125,1.59375 0.203125,0 0.703125,-0.046875 1.296875,-0.75 0.078125,0.421875 0.4375,0.75 0.90625,0.75 0.359375,0 0.578125,-0.234375 0.75,-0.546875 0.15625,-0.359375 0.296875,-0.96875 0.296875,-0.984375 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.171875,0.640625 -0.34375,1.234375 -0.75,1.234375 -0.28125,0 -0.296875,-0.265625 -0.296875,-0.453125 0,-0.21875 0.015625,-0.3125 0.125,-0.75 C 3.890625,-1.71875 3.90625,-1.828125 4,-2.203125 L 4.359375,-3.59375 c 0.0625,-0.28125 0.0625,-0.296875 0.0625,-0.34375 0,-0.171875 -0.109375,-0.265625 -0.28125,-0.265625 -0.25,0 -0.390625,0.21875 -0.421875,0.4375 z M 3.078125,-1.1875 C 3.015625,-1 3.015625,-0.984375 2.875,-0.8125 2.4375,-0.265625 2.03125,-0.109375 1.75,-0.109375 c -0.5,0 -0.640625,-0.546875 -0.640625,-0.9375 0,-0.5 0.3125,-1.71875 0.546875,-2.1875 0.3125,-0.578125 0.75,-0.953125 1.15625,-0.953125 0.640625,0 0.78125,0.8125 0.78125,0.875 0,0.0625 -0.015625,0.125 -0.03125,0.171875 z m 0,0"
+ id="path27"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-7"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.046875,-3.984375 0.9375,0 c 0.203125,0 0.3125,0 0.3125,-0.203125 0,-0.109375 -0.109375,-0.109375 -0.28125,-0.109375 l -0.875,0 C 2.5,-5.71875 2.546875,-5.90625 2.546875,-5.96875 c 0,-0.171875 -0.125,-0.265625 -0.296875,-0.265625 -0.03125,0 -0.3125,0 -0.390625,0.359375 l -0.390625,1.578125 -0.9375,0 c -0.203125,0 -0.296875,0 -0.296875,0.1875 0,0.125 0.078125,0.125 0.28125,0.125 l 0.875,0 C 0.671875,-1.15625 0.625,-0.984375 0.625,-0.8125 0.625,-0.265625 1,0.109375 1.546875,0.109375 2.5625,0.109375 3.125,-1.34375 3.125,-1.421875 3.125,-1.53125 3.046875,-1.53125 3.015625,-1.53125 2.921875,-1.53125 2.90625,-1.5 2.859375,-1.390625 2.4375,-0.34375 1.90625,-0.109375 1.5625,-0.109375 c -0.203125,0 -0.3125,-0.125 -0.3125,-0.453125 0,-0.25 0.03125,-0.3125 0.0625,-0.484375 z m 0,0"
+ id="path30"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-8"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.671875,-2.71875 c 0,-1.046875 -0.6875,-1.6875 -1.59375,-1.6875 -1.328125,0 -2.671875,1.421875 -2.671875,2.828125 0,0.984375 0.671875,1.6875 1.59375,1.6875 1.328125,0 2.671875,-1.375 2.671875,-2.828125 z m -2.65625,2.609375 c -0.4375,0 -0.875,-0.3125 -0.875,-1.09375 0,-0.484375 0.265625,-1.5625 0.578125,-2.0625 0.5,-0.765625 1.078125,-0.921875 1.359375,-0.921875 0.578125,0 0.875,0.484375 0.875,1.078125 0,0.390625 -0.203125,1.4375 -0.578125,2.078125 -0.359375,0.578125 -0.90625,0.921875 -1.359375,0.921875 z m 0,0"
+ id="path33"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.296875,2.390625 c 0,-0.03125 0,-0.046875 -0.171875,-0.21875 C 1.890625,0.921875 1.5625,-0.96875 1.5625,-2.5 c 0,-1.734375 0.375,-3.46875 1.609375,-4.703125 0.125,-0.125 0.125,-0.140625 0.125,-0.171875 0,-0.078125 -0.03125,-0.109375 -0.09375,-0.109375 -0.109375,0 -1,0.6875 -1.59375,1.953125 -0.5,1.09375 -0.625,2.203125 -0.625,3.03125 0,0.78125 0.109375,1.984375 0.65625,3.125 C 2.25,1.84375 3.09375,2.5 3.203125,2.5 c 0.0625,0 0.09375,-0.03125 0.09375,-0.109375 z m 0,0"
+ id="path36"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.875,-2.5 c 0,-0.765625 -0.109375,-1.96875 -0.65625,-3.109375 -0.59375,-1.21875 -1.453125,-1.875 -1.546875,-1.875 -0.0625,0 -0.109375,0.046875 -0.109375,0.109375 0,0.03125 0,0.046875 0.1875,0.234375 0.984375,0.984375 1.546875,2.5625 1.546875,4.640625 0,1.71875 -0.359375,3.46875 -1.59375,4.71875 C 0.5625,2.34375 0.5625,2.359375 0.5625,2.390625 0.5625,2.453125 0.609375,2.5 0.671875,2.5 0.765625,2.5 1.671875,1.8125 2.25,0.546875 2.765625,-0.546875 2.875,-1.65625 2.875,-2.5 z m 0,0"
+ id="path39"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 6.84375,-3.265625 c 0.15625,0 0.34375,0 0.34375,-0.1875 C 7.1875,-3.65625 7,-3.65625 6.859375,-3.65625 l -5.96875,0 c -0.140625,0 -0.328125,0 -0.328125,0.203125 0,0.1875 0.1875,0.1875 0.328125,0.1875 z m 0.015625,1.9375 c 0.140625,0 0.328125,0 0.328125,-0.203125 0,-0.1875 -0.1875,-0.1875 -0.34375,-0.1875 l -5.953125,0 c -0.140625,0 -0.328125,0 -0.328125,0.1875 0,0.203125 0.1875,0.203125 0.328125,0.203125 z m 0,0"
+ id="path42"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.9375,-6.375 c 0,-0.25 0,-0.265625 -0.234375,-0.265625 C 2.078125,-6 1.203125,-6 0.890625,-6 l 0,0.3125 c 0.203125,0 0.78125,0 1.296875,-0.265625 l 0,5.171875 c 0,0.359375 -0.03125,0.46875 -0.921875,0.46875 l -0.3125,0 0,0.3125 c 0.34375,-0.03125 1.203125,-0.03125 1.609375,-0.03125 0.390625,0 1.265625,0 1.609375,0.03125 l 0,-0.3125 -0.3125,0 c -0.90625,0 -0.921875,-0.109375 -0.921875,-0.46875 z m 0,0"
+ id="path45"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-4"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.078125,-2.296875 2.78125,0 C 7,-2.296875 7.1875,-2.296875 7.1875,-2.5 7.1875,-2.6875 7,-2.6875 6.859375,-2.6875 l -2.78125,0 0,-2.796875 c 0,-0.140625 0,-0.328125 -0.203125,-0.328125 -0.203125,0 -0.203125,0.1875 -0.203125,0.328125 l 0,2.796875 -2.78125,0 c -0.140625,0 -0.328125,0 -0.328125,0.1875 0,0.203125 0.1875,0.203125 0.328125,0.203125 l 2.78125,0 0,2.796875 c 0,0.140625 0,0.328125 0.203125,0.328125 0.203125,0 0.203125,-0.1875 0.203125,-0.328125 z m 0,0"
+ id="path48"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-5"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.578125,-3.1875 c 0,-0.796875 -0.046875,-1.59375 -0.390625,-2.328125 -0.453125,-0.96875 -1.28125,-1.125 -1.6875,-1.125 -0.609375,0 -1.328125,0.265625 -1.75,1.1875 -0.3125,0.6875 -0.359375,1.46875 -0.359375,2.265625 0,0.75 0.03125,1.640625 0.453125,2.40625 0.421875,0.796875 1.15625,1 1.640625,1 0.53125,0 1.296875,-0.203125 1.734375,-1.15625 0.3125,-0.6875 0.359375,-1.46875 0.359375,-2.25 z M 2.484375,0 C 2.09375,0 1.5,-0.25 1.328125,-1.203125 1.21875,-1.796875 1.21875,-2.71875 1.21875,-3.3125 c 0,-0.640625 0,-1.296875 0.078125,-1.828125 0.1875,-1.1875 0.9375,-1.28125 1.1875,-1.28125 0.328125,0 0.984375,0.1875 1.171875,1.171875 0.109375,0.5625 0.109375,1.3125 0.109375,1.9375 0,0.75 0,1.421875 -0.109375,2.0625 C 3.5,-0.296875 2.9375,0 2.484375,0 z m 0,0"
+ id="path51"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ </g>
+ </defs>
+ <g
+ id="g3346"
+ transform="translate(-0.79999683,3.8305664e-6)">
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g54">
+ <use
+ xlink:href="#glyph0-0"
+ x="233.16"
+ y="146.86"
+ id="use56"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g58">
+ <use
+ xlink:href="#glyph0-1"
+ x="237.48"
+ y="146.86"
+ id="use60"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g62">
+ <use
+ xlink:href="#glyph0-2"
+ x="243.24001"
+ y="146.86"
+ id="use64"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g66">
+ <use
+ xlink:href="#glyph0-3"
+ x="247.92017"
+ y="146.86"
+ id="use68"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g70">
+ <use
+ xlink:href="#glyph0-4"
+ x="253.08032"
+ y="146.86"
+ id="use72"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-215.6968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g74">
+ <use
+ xlink:href="#glyph0-5"
+ x="257.76035"
+ y="146.86"
+ id="use76"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g78">
+ <use
+ xlink:href="#glyph0-6"
+ x="265.56039"
+ y="146.86"
+ id="use80"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g82">
+ <use
+ xlink:href="#glyph0-0"
+ x="270.84039"
+ y="146.86"
+ id="use84"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g86">
+ <use
+ xlink:href="#glyph0-7"
+ x="275.1604"
+ y="146.86"
+ id="use88"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g90">
+ <use
+ xlink:href="#glyph0-8"
+ x="278.76041"
+ y="146.86"
+ id="use92"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g94">
+ <use
+ xlink:href="#glyph0-2"
+ x="283.56039"
+ y="146.86"
+ id="use96"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g98">
+ <use
+ xlink:href="#glyph1-0"
+ x="288.24051"
+ y="146.86"
+ id="use100"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g102">
+ <use
+ xlink:href="#glyph0-0"
+ x="292.08035"
+ y="146.86"
+ id="use104"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g106">
+ <use
+ xlink:href="#glyph0-1"
+ x="296.40033"
+ y="146.86"
+ id="use108"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g110">
+ <use
+ xlink:href="#glyph0-2"
+ x="302.16034"
+ y="146.86"
+ id="use112"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g114">
+ <use
+ xlink:href="#glyph0-3"
+ x="306.84052"
+ y="146.86"
+ id="use116"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g118">
+ <use
+ xlink:href="#glyph0-4"
+ x="312.00067"
+ y="146.86"
+ id="use120"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g122">
+ <use
+ xlink:href="#glyph1-1"
+ x="316.68073"
+ y="146.86"
+ id="use124"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g126">
+ <use
+ xlink:href="#glyph1-2"
+ x="323.40067"
+ y="146.86"
+ id="use128"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g130">
+ <use
+ xlink:href="#glyph1-3"
+ x="333.96082"
+ y="146.86"
+ id="use132"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g134">
+ <use
+ xlink:href="#glyph1-4"
+ x="341.16083"
+ y="146.86"
+ id="use136"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g138">
+ <use
+ xlink:href="#glyph0-0"
+ x="352.31985"
+ y="140.01978"
+ id="use140"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g142">
+ <use
+ xlink:href="#glyph0-1"
+ x="356.63983"
+ y="140.01978"
+ id="use144"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g146">
+ <use
+ xlink:href="#glyph0-2"
+ x="362.39984"
+ y="140.01978"
+ id="use148"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g150">
+ <use
+ xlink:href="#glyph0-3"
+ x="367.08002"
+ y="140.01978"
+ id="use152"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g154">
+ <use
+ xlink:href="#glyph0-4"
+ x="372.24014"
+ y="140.01978"
+ id="use156"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 135.01179,11.34714 24.71875,0 0,0.48047 -24.71875,0 z m 0,0"
+ id="path158"
+ inkscape:connector-curvature="0" />
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g160">
+ <use
+ xlink:href="#glyph1-3"
+ x="354.60001"
+ y="153.7"
+ id="use162"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g164">
+ <use
+ xlink:href="#glyph1-5"
+ x="359.63998"
+ y="153.7"
+ id="use166"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g168">
+ <use
+ xlink:href="#glyph1-5"
+ x="364.67999"
+ y="153.7"
+ id="use170"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(-217.2968,-132.76614)"
+ style="fill:#000000;fill-opacity:1"
+ id="g172">
+ <use
+ xlink:href="#glyph1-5"
+ x="369.71997"
+ y="153.7"
+ id="use174"
+ width="595"
+ height="842" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-5.svg b/libX11/specs/XKB/XKBlib-5.svg
new file mode 100644
index 000000000..b8dd1c95b
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-5.svg
@@ -0,0 +1,542 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="200"
+ height="25"
+ viewBox="0 0 160 20"
+ version="1.1"
+ id="svg2"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-5.svg">
+ <metadata
+ id="metadata171">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <sodipodi:namedview
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1"
+ objecttolerance="10"
+ gridtolerance="10"
+ guidetolerance="10"
+ inkscape:pageopacity="0"
+ inkscape:pageshadow="2"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ id="namedview169"
+ showgrid="false"
+ inkscape:zoom="3.58"
+ inkscape:cx="133.10056"
+ inkscape:cy="12.5"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1"
+ inkscape:current-layer="svg2" />
+ <defs
+ id="defs4">
+ <g
+ id="g6">
+ <symbol
+ overflow="visible"
+ id="glyph0-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.296875,2.390625 c 0,-0.03125 0,-0.046875 -0.171875,-0.21875 C 1.890625,0.921875 1.5625,-0.96875 1.5625,-2.5 c 0,-1.734375 0.375,-3.46875 1.609375,-4.703125 0.125,-0.125 0.125,-0.140625 0.125,-0.171875 0,-0.078125 -0.03125,-0.109375 -0.09375,-0.109375 -0.109375,0 -1,0.6875 -1.59375,1.953125 -0.5,1.09375 -0.625,2.203125 -0.625,3.03125 0,0.78125 0.109375,1.984375 0.65625,3.125 C 2.25,1.84375 3.09375,2.5 3.203125,2.5 c 0.0625,0 0.09375,-0.03125 0.09375,-0.109375 z m 0,0"
+ id="path9"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.875,-2.5 c 0,-0.765625 -0.109375,-1.96875 -0.65625,-3.109375 -0.59375,-1.21875 -1.453125,-1.875 -1.546875,-1.875 -0.0625,0 -0.109375,0.046875 -0.109375,0.109375 0,0.03125 0,0.046875 0.1875,0.234375 0.984375,0.984375 1.546875,2.5625 1.546875,4.640625 0,1.71875 -0.359375,3.46875 -1.59375,4.71875 C 0.5625,2.34375 0.5625,2.359375 0.5625,2.390625 0.5625,2.453125 0.609375,2.5 0.671875,2.5 0.765625,2.5 1.671875,1.8125 2.25,0.546875 2.765625,-0.546875 2.875,-1.65625 2.875,-2.5 z m 0,0"
+ id="path12"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph0-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.9375,-6.375 c 0,-0.25 0,-0.265625 -0.234375,-0.265625 C 2.078125,-6 1.203125,-6 0.890625,-6 l 0,0.3125 c 0.203125,0 0.78125,0 1.296875,-0.265625 l 0,5.171875 c 0,0.359375 -0.03125,0.46875 -0.921875,0.46875 l -0.3125,0 0,0.3125 c 0.34375,-0.03125 1.203125,-0.03125 1.609375,-0.03125 0.390625,0 1.265625,0 1.609375,0.03125 l 0,-0.3125 -0.3125,0 c -0.90625,0 -0.921875,-0.109375 -0.921875,-0.46875 z m 0,0"
+ id="path15"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 0.875,-0.59375 c -0.03125,0.15625 -0.09375,0.390625 -0.09375,0.4375 0,0.171875 0.140625,0.265625 0.296875,0.265625 0.125,0 0.296875,-0.078125 0.375,-0.28125 0,-0.015625 0.125,-0.484375 0.1875,-0.734375 l 0.21875,-0.890625 C 1.90625,-2.03125 1.96875,-2.25 2.03125,-2.46875 c 0.03125,-0.171875 0.109375,-0.46875 0.125,-0.5 0.140625,-0.3125 0.671875,-1.21875 1.625,-1.21875 0.453125,0 0.53125,0.375 0.53125,0.703125 0,0.25 -0.0625,0.53125 -0.140625,0.828125 L 3.890625,-1.5 3.6875,-0.75 c -0.03125,0.203125 -0.125,0.546875 -0.125,0.59375 0,0.171875 0.140625,0.265625 0.28125,0.265625 0.3125,0 0.375,-0.25 0.453125,-0.5625 0.140625,-0.5625 0.515625,-2.015625 0.59375,-2.40625 0.03125,-0.125 0.5625,-1.328125 1.65625,-1.328125 0.421875,0 0.53125,0.34375 0.53125,0.703125 0,0.5625 -0.421875,1.703125 -0.625,2.234375 -0.078125,0.234375 -0.125,0.34375 -0.125,0.546875 0,0.46875 0.34375,0.8125 0.8125,0.8125 0.9375,0 1.3125,-1.453125 1.3125,-1.53125 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.09375,0.03125 -0.140625,0.1875 -0.15625,0.53125 -0.46875,1.234375 -1.015625,1.234375 -0.171875,0 -0.25,-0.09375 -0.25,-0.328125 0,-0.25 0.09375,-0.484375 0.1875,-0.703125 0.1875,-0.53125 0.609375,-1.625 0.609375,-2.203125 0,-0.640625 -0.40625,-1.0625 -1.15625,-1.0625 -0.734375,0 -1.25,0.4375 -1.625,0.96875 0,-0.125 -0.03125,-0.46875 -0.3125,-0.703125 -0.25,-0.21875 -0.5625,-0.265625 -0.8125,-0.265625 -0.90625,0 -1.390625,0.640625 -1.5625,0.875 -0.046875,-0.578125 -0.46875,-0.875 -0.921875,-0.875 -0.453125,0 -0.640625,0.390625 -0.734375,0.5625 -0.171875,0.359375 -0.296875,0.9375 -0.296875,0.96875 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.15625,0 0.296875,0.078125 0.296875,0.453125 0,0.21875 -0.03125,0.328125 -0.15625,0.84375 z m 0,0"
+ id="path18"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-1"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.859375,-6.8125 c 0,0 0,-0.109375 -0.125,-0.109375 -0.234375,0 -0.953125,0.078125 -1.21875,0.109375 -0.078125,0 -0.1875,0.015625 -0.1875,0.1875 0,0.125 0.09375,0.125 0.234375,0.125 0.484375,0 0.5,0.0625 0.5,0.171875 L 2.03125,-6.125 0.59375,-0.390625 c -0.046875,0.140625 -0.046875,0.15625 -0.046875,0.21875 0,0.234375 0.203125,0.28125 0.296875,0.28125 0.125,0 0.265625,-0.09375 0.328125,-0.203125 0.046875,-0.09375 0.5,-1.9375 0.5625,-2.1875 0.34375,0.03125 1.15625,0.1875 1.15625,0.84375 0,0.078125 0,0.109375 -0.03125,0.21875 -0.015625,0.109375 -0.03125,0.234375 -0.03125,0.34375 0,0.578125 0.390625,0.984375 0.90625,0.984375 0.296875,0 0.578125,-0.15625 0.796875,-0.53125 0.25,-0.4375 0.359375,-0.984375 0.359375,-1 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.203125,0.71875 -0.421875,1.234375 -0.859375,1.234375 -0.203125,0 -0.328125,-0.109375 -0.328125,-0.46875 0,-0.171875 0.046875,-0.40625 0.078125,-0.5625 C 3.5625,-1.3125 3.5625,-1.34375 3.5625,-1.453125 3.5625,-2.09375 2.9375,-2.375 2.078125,-2.5 2.390625,-2.671875 2.71875,-2.984375 2.9375,-3.234375 3.421875,-3.765625 3.875,-4.1875 4.359375,-4.1875 c 0.0625,0 0.078125,0 0.09375,0.015625 0.125,0.015625 0.125,0.015625 0.21875,0.078125 0.015625,0 0.015625,0.015625 0.03125,0.03125 -0.46875,0.03125 -0.5625,0.421875 -0.5625,0.546875 0,0.15625 0.109375,0.34375 0.375,0.34375 0.265625,0 0.546875,-0.21875 0.546875,-0.609375 0,-0.296875 -0.234375,-0.625 -0.671875,-0.625 -0.28125,0 -0.734375,0.078125 -1.453125,0.875 -0.34375,0.375 -0.734375,0.78125 -1.109375,0.921875 z m 0,0"
+ id="path21"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-2"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.71875,-3.765625 C 3.53125,-4.140625 3.25,-4.40625 2.796875,-4.40625 c -1.15625,0 -2.390625,1.46875 -2.390625,2.921875 0,0.9375 0.546875,1.59375 1.3125,1.59375 0.203125,0 0.703125,-0.046875 1.296875,-0.75 0.078125,0.421875 0.4375,0.75 0.90625,0.75 0.359375,0 0.578125,-0.234375 0.75,-0.546875 0.15625,-0.359375 0.296875,-0.96875 0.296875,-0.984375 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.171875,0.640625 -0.34375,1.234375 -0.75,1.234375 -0.28125,0 -0.296875,-0.265625 -0.296875,-0.453125 0,-0.21875 0.015625,-0.3125 0.125,-0.75 C 3.890625,-1.71875 3.90625,-1.828125 4,-2.203125 L 4.359375,-3.59375 c 0.0625,-0.28125 0.0625,-0.296875 0.0625,-0.34375 0,-0.171875 -0.109375,-0.265625 -0.28125,-0.265625 -0.25,0 -0.390625,0.21875 -0.421875,0.4375 z M 3.078125,-1.1875 C 3.015625,-1 3.015625,-0.984375 2.875,-0.8125 2.4375,-0.265625 2.03125,-0.109375 1.75,-0.109375 c -0.5,0 -0.640625,-0.546875 -0.640625,-0.9375 0,-0.5 0.3125,-1.71875 0.546875,-2.1875 0.3125,-0.578125 0.75,-0.953125 1.15625,-0.953125 0.640625,0 0.78125,0.8125 0.78125,0.875 0,0.0625 -0.015625,0.125 -0.03125,0.171875 z m 0,0"
+ id="path24"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-3"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.328125,-3.015625 C 3.390625,-3.265625 3.625,-4.1875 4.3125,-4.1875 c 0.046875,0 0.296875,0 0.5,0.125 C 4.53125,-4 4.34375,-3.765625 4.34375,-3.515625 c 0,0.15625 0.109375,0.34375 0.375,0.34375 0.21875,0 0.53125,-0.171875 0.53125,-0.578125 0,-0.515625 -0.578125,-0.65625 -0.921875,-0.65625 -0.578125,0 -0.921875,0.53125 -1.046875,0.75 -0.25,-0.65625 -0.78125,-0.75 -1.078125,-0.75 -1.03125,0 -1.609375,1.28125 -1.609375,1.53125 0,0.109375 0.109375,0.109375 0.125,0.109375 0.078125,0 0.109375,-0.03125 0.125,-0.109375 0.34375,-1.0625 1,-1.3125 1.34375,-1.3125 0.1875,0 0.53125,0.09375 0.53125,0.671875 0,0.3125 -0.171875,0.96875 -0.53125,2.375 -0.15625,0.609375 -0.515625,1.03125 -0.953125,1.03125 -0.0625,0 -0.28125,0 -0.5,-0.125 0.25,-0.0625 0.46875,-0.265625 0.46875,-0.546875 0,-0.265625 -0.21875,-0.34375 -0.359375,-0.34375 -0.3125,0 -0.546875,0.25 -0.546875,0.578125 0,0.453125 0.484375,0.65625 0.921875,0.65625 0.671875,0 1.03125,-0.703125 1.046875,-0.75 0.125,0.359375 0.484375,0.75 1.078125,0.75 1.03125,0 1.59375,-1.28125 1.59375,-1.53125 0,-0.109375 -0.078125,-0.109375 -0.109375,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.109375 -0.328125,1.078125 -1,1.3125 -1.3125,1.3125 -0.390625,0 -0.546875,-0.3125 -0.546875,-0.65625 0,-0.21875 0.046875,-0.4375 0.15625,-0.875 z m 0,0"
+ id="path27"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-4"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.890625,-3.734375 C 3.625,-3.71875 3.421875,-3.5 3.421875,-3.28125 c 0,0.140625 0.09375,0.296875 0.3125,0.296875 0.21875,0 0.453125,-0.171875 0.453125,-0.5625 C 4.1875,-4 3.765625,-4.40625 3,-4.40625 c -1.3125,0 -1.6875,1.015625 -1.6875,1.453125 0,0.78125 0.734375,0.921875 1.03125,0.984375 0.515625,0.109375 1.03125,0.21875 1.03125,0.765625 0,0.25 -0.21875,1.09375 -1.421875,1.09375 -0.140625,0 -0.90625,0 -1.140625,-0.53125 0.390625,0.046875 0.640625,-0.25 0.640625,-0.53125 0,-0.21875 -0.171875,-0.34375 -0.375,-0.34375 -0.265625,0 -0.5625,0.203125 -0.5625,0.65625 0,0.5625 0.578125,0.96875 1.421875,0.96875 1.625,0 2.015625,-1.203125 2.015625,-1.65625 0,-0.359375 -0.1875,-0.609375 -0.3125,-0.71875 -0.265625,-0.28125 -0.5625,-0.34375 -1,-0.421875 -0.359375,-0.078125 -0.75,-0.15625 -0.75,-0.609375 C 1.890625,-3.578125 2.125,-4.1875 3,-4.1875 c 0.25,0 0.75,0.078125 0.890625,0.453125 z m 0,0"
+ id="path30"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-5"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 0.453125,1.21875 C 0.375,1.5625 0.34375,1.625 -0.09375,1.625 c -0.109375,0 -0.21875,0 -0.21875,0.1875 0,0.078125 0.046875,0.125 0.125,0.125 0.265625,0 0.5625,-0.03125 0.828125,-0.03125 0.34375,0 0.671875,0.03125 1,0.03125 0.046875,0 0.171875,0 0.171875,-0.203125 C 1.8125,1.625 1.71875,1.625 1.578125,1.625 c -0.5,0 -0.5,-0.0625 -0.5,-0.15625 0,-0.125 0.421875,-1.75 0.484375,-2 0.125,0.296875 0.40625,0.640625 0.921875,0.640625 1.15625,0 2.40625,-1.453125 2.40625,-2.921875 0,-0.9375 -0.578125,-1.59375 -1.328125,-1.59375 -0.5,0 -0.984375,0.359375 -1.3125,0.75 -0.09375,-0.546875 -0.53125,-0.75 -0.890625,-0.75 -0.46875,0 -0.65625,0.390625 -0.734375,0.5625 C 0.4375,-3.5 0.3125,-2.90625 0.3125,-2.875 c 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.171875,0 0.3125,0.078125 0.3125,0.453125 0,0.234375 -0.03125,0.34375 -0.078125,0.515625 z m 1.75,-4.328125 C 2.265625,-3.375 2.546875,-3.65625 2.71875,-3.8125 c 0.359375,-0.296875 0.640625,-0.375 0.8125,-0.375 0.390625,0 0.640625,0.34375 0.640625,0.9375 0,0.59375 -0.328125,1.734375 -0.515625,2.109375 -0.34375,0.703125 -0.8125,1.03125 -1.1875,1.03125 C 1.8125,-0.109375 1.6875,-0.9375 1.6875,-1 c 0,-0.015625 0,-0.03125 0.03125,-0.15625 z m 0,0"
+ id="path33"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-6"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 1.859375,-2.296875 c 0.296875,0 1.03125,-0.03125 1.53125,-0.234375 0.703125,-0.296875 0.75,-0.890625 0.75,-1.03125 0,-0.4375 -0.375,-0.84375 -1.0625,-0.84375 -1.109375,0 -2.625,0.96875 -2.625,2.71875 0,1.015625 0.59375,1.796875 1.578125,1.796875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.78125,0 -0.875,-0.84375 -0.875,-1.15625 0,-0.125 0.015625,-0.421875 0.15625,-1.03125 z m -0.46875,-0.21875 C 1.78125,-4.03125 2.8125,-4.1875 3.078125,-4.1875 c 0.453125,0 0.734375,0.296875 0.734375,0.625 0,1.046875 -1.59375,1.046875 -2.015625,1.046875 z m 0,0"
+ id="path36"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-7"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 5.140625,-6.8125 c 0,0 0,-0.109375 -0.125,-0.109375 -0.15625,0 -1.09375,0.09375 -1.265625,0.109375 -0.078125,0.015625 -0.140625,0.0625 -0.140625,0.1875 0,0.125 0.09375,0.125 0.234375,0.125 0.484375,0 0.5,0.0625 0.5,0.171875 L 4.3125,-6.125 3.71875,-3.765625 C 3.53125,-4.140625 3.25,-4.40625 2.796875,-4.40625 c -1.15625,0 -2.390625,1.46875 -2.390625,2.921875 0,0.9375 0.546875,1.59375 1.3125,1.59375 0.203125,0 0.703125,-0.046875 1.296875,-0.75 0.078125,0.421875 0.4375,0.75 0.90625,0.75 0.359375,0 0.578125,-0.234375 0.75,-0.546875 0.15625,-0.359375 0.296875,-0.96875 0.296875,-0.984375 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.140625,0.1875 -0.171875,0.640625 -0.34375,1.234375 -0.75,1.234375 -0.28125,0 -0.296875,-0.265625 -0.296875,-0.453125 0,-0.25 0.015625,-0.3125 0.046875,-0.484375 z m -2.0625,5.625 C 3.015625,-1 3.015625,-0.984375 2.875,-0.8125 2.4375,-0.265625 2.03125,-0.109375 1.75,-0.109375 c -0.5,0 -0.640625,-0.546875 -0.640625,-0.9375 0,-0.5 0.3125,-1.71875 0.546875,-2.1875 0.3125,-0.578125 0.75,-0.953125 1.15625,-0.953125 0.640625,0 0.78125,0.8125 0.78125,0.875 0,0.0625 -0.015625,0.125 -0.03125,0.171875 z m 0,0"
+ id="path39"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-8"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 3.953125,-3.78125 c -0.171875,0 -0.296875,0 -0.4375,0.125 -0.171875,0.15625 -0.1875,0.328125 -0.1875,0.390625 0,0.25 0.1875,0.359375 0.375,0.359375 0.28125,0 0.546875,-0.25 0.546875,-0.640625 0,-0.484375 -0.46875,-0.859375 -1.171875,-0.859375 -1.34375,0 -2.671875,1.421875 -2.671875,2.828125 0,0.90625 0.578125,1.6875 1.625,1.6875 1.421875,0 2.25,-1.0625 2.25,-1.171875 0,-0.0625 -0.046875,-0.140625 -0.109375,-0.140625 -0.0625,0 -0.078125,0.03125 -0.140625,0.109375 -0.78125,0.984375 -1.875,0.984375 -1.984375,0.984375 -0.625,0 -0.90625,-0.484375 -0.90625,-1.09375 0,-0.40625 0.203125,-1.375 0.546875,-1.984375 0.3125,-0.578125 0.859375,-1 1.40625,-1 0.328125,0 0.71875,0.125 0.859375,0.40625 z m 0,0"
+ id="path42"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-9"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.046875,-3.984375 0.9375,0 c 0.203125,0 0.3125,0 0.3125,-0.203125 0,-0.109375 -0.109375,-0.109375 -0.28125,-0.109375 l -0.875,0 C 2.5,-5.71875 2.546875,-5.90625 2.546875,-5.96875 c 0,-0.171875 -0.125,-0.265625 -0.296875,-0.265625 -0.03125,0 -0.3125,0 -0.390625,0.359375 l -0.390625,1.578125 -0.9375,0 c -0.203125,0 -0.296875,0 -0.296875,0.1875 0,0.125 0.078125,0.125 0.28125,0.125 l 0.875,0 C 0.671875,-1.15625 0.625,-0.984375 0.625,-0.8125 0.625,-0.265625 1,0.109375 1.546875,0.109375 2.5625,0.109375 3.125,-1.34375 3.125,-1.421875 3.125,-1.53125 3.046875,-1.53125 3.015625,-1.53125 2.921875,-1.53125 2.90625,-1.5 2.859375,-1.390625 2.4375,-0.34375 1.90625,-0.109375 1.5625,-0.109375 c -0.203125,0 -0.3125,-0.125 -0.3125,-0.453125 0,-0.25 0.03125,-0.3125 0.0625,-0.484375 z m 0,0"
+ id="path45"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-10"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.828125,-6.234375 c 0,-0.203125 -0.140625,-0.359375 -0.359375,-0.359375 -0.28125,0 -0.546875,0.265625 -0.546875,0.53125 0,0.1875 0.140625,0.359375 0.375,0.359375 0.234375,0 0.53125,-0.234375 0.53125,-0.53125 z m -0.75,3.75 c 0.109375,-0.28125 0.109375,-0.3125 0.21875,-0.578125 0.078125,-0.203125 0.125,-0.34375 0.125,-0.53125 0,-0.4375 -0.3125,-0.8125 -0.8125,-0.8125 -0.9375,0 -1.3125,1.453125 -1.3125,1.53125 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.03125 0.15625,-0.1875 0.28125,-0.9375 0.671875,-1.234375 1.015625,-1.234375 0.078125,0 0.25,0 0.25,0.3125 0,0.21875 -0.078125,0.421875 -0.109375,0.53125 -0.078125,0.25 -0.53125,1.40625 -0.6875,1.84375 -0.109375,0.25 -0.234375,0.578125 -0.234375,0.796875 0,0.46875 0.34375,0.8125 0.8125,0.8125 0.9375,0 1.3125,-1.4375 1.3125,-1.53125 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.09375,0.03125 -0.140625,0.1875 -0.1875,0.625 -0.515625,1.234375 -1.015625,1.234375 -0.171875,0 -0.25,-0.09375 -0.25,-0.328125 0,-0.25 0.0625,-0.390625 0.296875,-1 z m 0,0"
+ id="path48"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-11"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 4.671875,-2.71875 c 0,-1.046875 -0.6875,-1.6875 -1.59375,-1.6875 -1.328125,0 -2.671875,1.421875 -2.671875,2.828125 0,0.984375 0.671875,1.6875 1.59375,1.6875 1.328125,0 2.671875,-1.375 2.671875,-2.828125 z m -2.65625,2.609375 c -0.4375,0 -0.875,-0.3125 -0.875,-1.09375 0,-0.484375 0.265625,-1.5625 0.578125,-2.0625 0.5,-0.765625 1.078125,-0.921875 1.359375,-0.921875 0.578125,0 0.875,0.484375 0.875,1.078125 0,0.390625 -0.203125,1.4375 -0.578125,2.078125 -0.359375,0.578125 -0.90625,0.921875 -1.359375,0.921875 z m 0,0"
+ id="path51"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-12"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 0.875,-0.59375 c -0.03125,0.15625 -0.09375,0.390625 -0.09375,0.4375 0,0.171875 0.140625,0.265625 0.296875,0.265625 0.125,0 0.296875,-0.078125 0.375,-0.28125 0,-0.015625 0.125,-0.484375 0.1875,-0.734375 l 0.21875,-0.890625 C 1.90625,-2.03125 1.96875,-2.25 2.03125,-2.46875 c 0.03125,-0.171875 0.109375,-0.46875 0.125,-0.5 0.140625,-0.3125 0.671875,-1.21875 1.625,-1.21875 0.453125,0 0.53125,0.375 0.53125,0.703125 0,0.609375 -0.484375,1.890625 -0.640625,2.3125 C 3.578125,-0.9375 3.5625,-0.8125 3.5625,-0.703125 c 0,0.46875 0.359375,0.8125 0.828125,0.8125 0.9375,0 1.296875,-1.453125 1.296875,-1.53125 0,-0.109375 -0.078125,-0.109375 -0.109375,-0.109375 -0.109375,0 -0.109375,0.03125 -0.15625,0.1875 -0.203125,0.671875 -0.53125,1.234375 -1.015625,1.234375 -0.171875,0 -0.234375,-0.09375 -0.234375,-0.328125 0,-0.25 0.078125,-0.484375 0.171875,-0.703125 0.1875,-0.53125 0.609375,-1.625 0.609375,-2.203125 0,-0.65625 -0.421875,-1.0625 -1.140625,-1.0625 -0.90625,0 -1.390625,0.640625 -1.5625,0.875 -0.046875,-0.5625 -0.453125,-0.875 -0.921875,-0.875 -0.453125,0 -0.640625,0.390625 -0.734375,0.5625 C 0.421875,-3.5 0.296875,-2.90625 0.296875,-2.875 c 0,0.109375 0.09375,0.109375 0.109375,0.109375 0.109375,0 0.109375,-0.015625 0.171875,-0.234375 0.171875,-0.703125 0.375,-1.1875 0.734375,-1.1875 0.1875,0 0.296875,0.125 0.296875,0.453125 0,0.21875 -0.03125,0.328125 -0.15625,0.84375 z m 0,0"
+ id="path54"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph1-13"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="m 2.578125,-6.8125 c 0,0 0,-0.109375 -0.140625,-0.109375 -0.21875,0 -0.953125,0.078125 -1.21875,0.109375 -0.078125,0 -0.1875,0.015625 -0.1875,0.203125 0,0.109375 0.109375,0.109375 0.25,0.109375 0.484375,0 0.5,0.09375 0.5,0.171875 L 1.75,-6.125 0.484375,-1.140625 C 0.453125,-1.03125 0.4375,-0.96875 0.4375,-0.8125 c 0,0.578125 0.4375,0.921875 0.90625,0.921875 0.328125,0 0.578125,-0.203125 0.75,-0.5625 0.171875,-0.375 0.296875,-0.953125 0.296875,-0.96875 0,-0.109375 -0.09375,-0.109375 -0.125,-0.109375 -0.09375,0 -0.109375,0.046875 -0.125,0.1875 C 1.96875,-0.703125 1.78125,-0.109375 1.375,-0.109375 c -0.296875,0 -0.296875,-0.3125 -0.296875,-0.453125 0,-0.25 0.015625,-0.296875 0.0625,-0.484375 z m 0,0"
+ id="path57"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ <symbol
+ overflow="visible"
+ id="glyph2-0"
+ style="overflow:visible">
+ <path
+ style="stroke:none"
+ d="M 3.875,-2.765625 1.890625,-4.75 C 1.765625,-4.875 1.75,-4.890625 1.671875,-4.890625 1.5625,-4.890625 1.46875,-4.8125 1.46875,-4.6875 c 0,0.0625 0.015625,0.078125 0.125,0.1875 l 2,2 -2,2.015625 c -0.109375,0.109375 -0.125,0.125 -0.125,0.1875 0,0.125 0.09375,0.203125 0.203125,0.203125 0.078125,0 0.09375,-0.015625 0.21875,-0.140625 L 3.875,-2.21875 l 2.0625,2.0625 c 0.015625,0.015625 0.078125,0.0625 0.140625,0.0625 0.125,0 0.203125,-0.078125 0.203125,-0.203125 0,-0.015625 0,-0.046875 -0.03125,-0.109375 C 6.234375,-0.421875 4.65625,-1.984375 4.15625,-2.5 l 1.828125,-1.8125 c 0.046875,-0.0625 0.203125,-0.1875 0.25,-0.25 0,-0.015625 0.046875,-0.0625 0.046875,-0.125 0,-0.125 -0.078125,-0.203125 -0.203125,-0.203125 C 6,-4.890625 5.96875,-4.859375 5.859375,-4.75 z m 0,0"
+ id="path60"
+ inkscape:connector-curvature="0" />
+ </symbol>
+ </g>
+ </defs>
+ <g
+ id="g3201"
+ transform="translate(-225.70979,687.63219)">
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g63">
+ <use
+ xlink:href="#glyph0-0"
+ x="236.64"
+ y="146.86"
+ id="use65"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g67">
+ <use
+ xlink:href="#glyph1-0"
+ x="240.47984"
+ y="146.86"
+ id="use69"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g71">
+ <use
+ xlink:href="#glyph1-1"
+ x="249.23985"
+ y="146.86"
+ id="use73"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 255.34766,-675.60938 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path75"
+ inkscape:connector-curvature="0" />
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g77">
+ <use
+ xlink:href="#glyph1-0"
+ x="258.35999"
+ y="146.86"
+ id="use79"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g81">
+ <use
+ xlink:href="#glyph1-2"
+ x="267.12003"
+ y="146.86"
+ id="use83"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g85">
+ <use
+ xlink:href="#glyph1-3"
+ x="272.39999"
+ y="146.86"
+ id="use87"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 278.62891,-675.60938 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path89"
+ inkscape:connector-curvature="0" />
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g91">
+ <use
+ xlink:href="#glyph1-4"
+ x="281.64001"
+ y="146.86"
+ id="use93"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g95">
+ <use
+ xlink:href="#glyph1-5"
+ x="286.32001"
+ y="146.86"
+ id="use97"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g99">
+ <use
+ xlink:href="#glyph1-6"
+ x="291.35999"
+ y="146.86"
+ id="use101"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g103">
+ <use
+ xlink:href="#glyph1-6"
+ x="296.04001"
+ y="146.86"
+ id="use105"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g107">
+ <use
+ xlink:href="#glyph1-7"
+ x="300.72003"
+ y="146.86"
+ id="use109"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g111">
+ <use
+ xlink:href="#glyph2-0"
+ x="307.9201"
+ y="146.86"
+ id="use113"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g115">
+ <use
+ xlink:href="#glyph1-2"
+ x="317.88025"
+ y="146.86"
+ id="use117"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g119">
+ <use
+ xlink:href="#glyph1-8"
+ x="323.16025"
+ y="146.86"
+ id="use121"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g123">
+ <use
+ xlink:href="#glyph1-9"
+ x="327.48026"
+ y="146.86"
+ id="use125"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g127">
+ <use
+ xlink:href="#glyph1-10"
+ x="331.08026"
+ y="146.86"
+ id="use129"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g131">
+ <use
+ xlink:href="#glyph1-11"
+ x="334.56027"
+ y="146.86"
+ id="use133"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g135">
+ <use
+ xlink:href="#glyph1-12"
+ x="339.36026"
+ y="146.86"
+ id="use137"
+ width="595"
+ height="842" />
+ </g>
+ <path
+ style="fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none"
+ d="m 345.94922,-675.60938 3,0 0,0.48047 -3,0 z m 0,0"
+ id="path139"
+ inkscape:connector-curvature="0" />
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g141">
+ <use
+ xlink:href="#glyph1-7"
+ x="348.95999"
+ y="146.86"
+ id="use143"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g145">
+ <use
+ xlink:href="#glyph1-6"
+ x="354.12003"
+ y="146.86"
+ id="use147"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g149">
+ <use
+ xlink:href="#glyph1-13"
+ x="358.80002"
+ y="146.86"
+ id="use151"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g153">
+ <use
+ xlink:href="#glyph1-9"
+ x="362.0401"
+ y="146.86"
+ id="use155"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g157">
+ <use
+ xlink:href="#glyph1-2"
+ x="365.64011"
+ y="146.86"
+ id="use159"
+ width="595"
+ height="842" />
+ </g>
+ <g
+ transform="translate(0,-822)"
+ style="fill:#000000;fill-opacity:1"
+ id="g161">
+ <use
+ xlink:href="#glyph0-1"
+ x="370.9202"
+ y="146.86"
+ id="use163"
+ width="595"
+ height="842" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-6.svg b/libX11/specs/XKB/XKBlib-6.svg
new file mode 100644
index 000000000..e2b3ce2a1
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-6.svg
@@ -0,0 +1,551 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:osb="http://www.openswatchbook.org/uri/2009/osb"
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="620"
+ height="500"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-6.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-6.png"
+ inkscape:export-xdpi="90"
+ inkscape:export-ydpi="90">
+ <defs
+ id="defs4">
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1"
+ id="pattern5283"
+ patternTransform="matrix(4.2694661,1.6585694,-0.04730474,4.1989521,235.77322,-493.33209)" />
+ <linearGradient
+ id="linearGradient5257"
+ osb:paint="solid">
+ <stop
+ style="stop-color:#000000;stop-opacity:1;"
+ offset="0"
+ id="stop5259" />
+ </linearGradient>
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1"
+ id="pattern5216"
+ patternTransform="matrix(4.3336724,0.9160461,-0.01361022,4.3170979,-342.26379,-264.52219)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1"
+ patternTransform="matrix(4.3538899,0.81455497,0.0872474,4.3162378,-405.75021,-33.331093)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4473"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <clipPath
+ clipPathUnits="userSpaceOnUse"
+ id="clipPath5190">
+ <rect
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1.00031233;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect5192"
+ width="168.27927"
+ height="227.56186"
+ x="131.25783"
+ y="85.852882"
+ transform="matrix(-0.77646499,0.6301604,-0.6572021,-0.7537144,0,0)" />
+ </clipPath>
+ <clipPath
+ clipPathUnits="userSpaceOnUse"
+ id="clipPath5220">
+ <rect
+ style="fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect5222"
+ width="185.42435"
+ height="203.87454"
+ x="146.67897"
+ y="74.723244"
+ transform="matrix(0.70264554,-0.71154006,0.71154006,0.70264554,0,0)" />
+ </clipPath>
+ <clipPath
+ clipPathUnits="userSpaceOnUse"
+ id="clipPath5287">
+ <rect
+ style="fill:#ececec;fill-opacity:1;stroke:none"
+ id="rect5289"
+ width="170.46823"
+ height="217.43936"
+ x="136.7207"
+ y="82.408524"
+ transform="matrix(0.73371932,-0.67945269,0.6862034,0.72740971,0,0)" />
+ </clipPath>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="2.168"
+ inkscape:cx="250.79265"
+ inkscape:cy="200.44473"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <rect
+ style="fill:#c8c8c8;fill-opacity:1;stroke:none"
+ id="rect5778"
+ width="180.81181"
+ height="204.79704"
+ x="146.67897"
+ y="72.878227" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 89.483395,325.64575 0.922509,-50.738 55.350556,0 184.50184,-200.184503 113.46864,-0.92251"
+ id="path5291"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="M 145.75646,273.06273 C 152.82903,140.2214 244.77245,73.800739 328.41328,74.723247"
+ id="path5293"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 90.405904,44.280443 0,281.365317 357.933576,0"
+ id="path5304"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 320.80258,425.50738 55.81181,0"
+ id="path5306"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 320.80258,443.18431 55.81181,0"
+ id="path5306-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#c8c8c8;stroke-width:7;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 320.80258,460.86124 55.81181,0"
+ id="path5306-4-6"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="383.55975"
+ y="428.65094"
+ id="text5344"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5346"
+ x="383.55975"
+ y="428.65094">mk_curve = 0</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="383.55975"
+ y="446.32785"
+ id="text5344-6"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5378"
+ x="383.55975"
+ y="446.32785">mk_curve &lt; 0</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="383.55975"
+ y="464.00479"
+ id="text5344-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5380"
+ x="383.55975"
+ y="464.00479">mk_curve &gt; 0</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="370.94604"
+ y="204.84198"
+ id="text5344-64"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5434"
+ x="370.94604"
+ y="204.84198">mk_max_speed * Action delta</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:tb-rl;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="62.077717"
+ y="135.23929"
+ id="text5344-64-3"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5457"
+ x="135.23929"
+ y="62.077717">distance</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="120.78584"
+ y="306.17062"
+ id="text5344-64-8"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5480"
+ x="120.78584"
+ y="306.17062">Action delta</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="117.53692"
+ y="384.06982"
+ id="text5344-64-8-0"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5503"
+ x="117.53692"
+ y="384.06982">mk_delay</tspan><tspan
+ sodipodi:role="line"
+ id="tspan5505"
+ x="117.53692"
+ y="399.06982">(msec)</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="238.41812"
+ y="384.06982"
+ id="text5344-64-8-0-9"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5531"
+ x="238.41812"
+ y="384.06982">mk_time_to_max</tspan><tspan
+ sodipodi:role="line"
+ id="tspan5533"
+ x="238.41812"
+ y="399.06982">(count)</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="370.16321"
+ y="384.06982"
+ id="text5344-64-8-0-2"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan5559"
+ x="370.16321"
+ y="384.06982">mk_interval</tspan><tspan
+ sodipodi:role="line"
+ id="tspan5561"
+ x="370.16321"
+ y="399.06982">(msec)</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 90.019129,276.90912 -11.741626,0"
+ id="path5563"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 90.01913,227.65952 -11.741626,0"
+ id="path5563-0"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 90.019129,178.73608 -11.741626,0"
+ id="path5563-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 89.692973,128.83417 -11.741626,0"
+ id="path5563-2"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 90.019129,79.584575 -11.741626,0"
+ id="path5563-00"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 160.79504,337.90033 0,-11.74162"
+ id="path5563-6"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 172.2105,337.90033 0,-11.74162"
+ id="path5563-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 182.8106,337.90033 0,-11.74162"
+ id="path5563-6-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 194.22606,337.90033 0,-11.74162"
+ id="path5563-3-0"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 205.3969,337.90033 0,-11.74162"
+ id="path5563-6-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 216.81236,337.90033 0,-11.74162"
+ id="path5563-3-3"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 227.41246,337.90033 0,-11.74162"
+ id="path5563-6-9-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 238.82792,337.90033 0,-11.74162"
+ id="path5563-3-0-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 249.72895,337.90033 0,-11.74162"
+ id="path5563-6-5"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 261.14441,337.90033 0,-11.74162"
+ id="path5563-3-03"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 271.74451,337.90033 0,-11.74162"
+ id="path5563-6-9-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 283.15997,337.90033 0,-11.74162"
+ id="path5563-3-0-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 294.33081,337.90033 0,-11.74162"
+ id="path5563-6-8-0"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 305.74627,337.90033 0,-11.74162"
+ id="path5563-3-3-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 316.34637,337.90033 0,-11.74162"
+ id="path5563-6-9-8-7"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:4;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 327.76183,341.12911 0,-14.9704"
+ id="path5563-3-0-7-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 341.51862,337.90033 0,-11.74162"
+ id="path5563-6-1"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 352.93408,337.90033 0,-11.74162"
+ id="path5563-3-035"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 363.53418,337.90033 0,-11.74162"
+ id="path5563-6-9-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 374.94964,337.90033 0,-11.74162"
+ id="path5563-3-0-4"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 386.12048,337.90033 0,-11.74162"
+ id="path5563-6-8-8"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 397.53594,337.90033 0,-11.74162"
+ id="path5563-3-3-4"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 408.13604,337.90033 0,-11.74162"
+ id="path5563-6-9-8-6"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 419.5515,337.90033 0,-11.74162"
+ id="path5563-3-0-7-92"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 429.8716,337.90033 0,-11.74162"
+ id="path5563-6-9-8-6-9"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+ d="m 441.74831,337.90033 0,-11.74162"
+ id="path5563-3-0-7-92-0"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:4;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
+ d="m 149.90774,341.12911 0,-14.9704"
+ id="path5563-6-3"
+ inkscape:connector-curvature="0" />
+ <g
+ id="g6013"
+ transform="matrix(0.52011301,0,0,2.4705278,492.60784,-679.42599)">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2"
+ d="m -297.45452,308.54628 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:0.88217813;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-0"
+ d="m -286.82434,309.22012 0,95.23763"
+ style="fill:none;stroke:#000000;stroke-width:0.88217813;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-6"
+ d="m -297.45452,404.76236 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:0.88217813;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g3848">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-9"
+ d="m 375.22095,345.65772 0,11.05779"
+ style="fill:none;stroke:#000000;stroke-width:1.00000012;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-0-2"
+ d="m 375.1499,351.18662 -10.04159,0"
+ style="fill:none;stroke:#000000;stroke-width:1.00000012;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-6-4"
+ d="m 365.07619,345.65772 0,11.05779"
+ style="fill:none;stroke:#000000;stroke-width:1.00000012;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g3853">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-9-4"
+ d="m 324.67319,345.65772 0,11.05779"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-0-2-9"
+ d="m 323.46992,351.18662 -170.06566,0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-6-4-9"
+ d="m 152.86032,345.65772 0,11.05779"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g6013-3-4-3"
+ transform="matrix(0,0.52011301,-0.59595607,0,330.45344,500.36769)">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-9-4-8"
+ d="m -297.45452,308.54628 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:1.79615593;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-0-2-9-3"
+ d="m -286.82434,309.22012 0,95.23763"
+ style="fill:none;stroke:#000000;stroke-width:1.79615593;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-6-4-9-2"
+ d="m -297.45452,404.76236 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:1.79615593;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g6013-3-4-3-9"
+ transform="matrix(-0.52011301,0,0,-0.41065669,-44.015024,448.41191)">
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-9-4-8-5"
+ d="m -297.45452,308.54628 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:2.16377306;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-0-2-9-3-4"
+ d="m -286.82434,309.22012 0,95.23763"
+ style="fill:none;stroke:#000000;stroke-width:2.16377306;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ <path
+ sodipodi:nodetypes="cc"
+ inkscape:connector-curvature="0"
+ id="rect5938-4-2-6-4-9-2-3"
+ d="m -297.45452,404.76236 21.26036,0"
+ style="fill:none;stroke:#000000;stroke-width:2.16377306;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-7.svg b/libX11/specs/XKB/XKBlib-7.svg
new file mode 100644
index 000000000..b09f43c15
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-7.svg
@@ -0,0 +1,352 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="350"
+ height="220"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-7.svg"
+ inkscape:export-filename="/home/fcarrijo/Desktop/XKBlib-7.png"
+ inkscape:export-xdpi="90"
+ inkscape:export-ydpi="90">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path4077"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-3"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path4077-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.2318182"
+ inkscape:cx="175"
+ inkscape:cy="110"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect3277"
+ width="296.30997"
+ height="125.01845"
+ x="27.601477"
+ y="29.225092" />
+ <g
+ id="g3257">
+ <rect
+ y="40.504219"
+ x="133.75017"
+ height="15"
+ width="17"
+ id="rect3070"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="40.504219"
+ x="154.26093"
+ height="15"
+ width="17"
+ id="rect3070-6"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="40.504219"
+ x="174.77168"
+ height="15"
+ width="17"
+ id="rect3070-1"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="40.504219"
+ x="195.28244"
+ height="15"
+ width="17"
+ id="rect3070-5"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="60.332516"
+ x="133.75017"
+ height="15"
+ width="17"
+ id="rect3070-69"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="60.380718"
+ x="154.26093"
+ height="15"
+ width="17"
+ id="rect3070-6-3"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="60.380718"
+ x="174.77168"
+ height="15"
+ width="17"
+ id="rect3070-1-7"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="80.16082"
+ x="133.75017"
+ height="15"
+ width="17"
+ id="rect3070-4"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="79.897911"
+ x="154.26093"
+ height="15"
+ width="17"
+ id="rect3070-6-5"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="79.897911"
+ x="174.77168"
+ height="15"
+ width="17"
+ id="rect3070-1-2"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="99.989136"
+ x="133.75017"
+ height="15"
+ width="17"
+ id="rect3070-54"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="99.989136"
+ x="154.26093"
+ height="15"
+ width="17"
+ id="rect3070-6-7"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="99.989136"
+ x="174.77168"
+ height="15"
+ width="17"
+ id="rect3070-1-4"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="119.50632"
+ x="174.77168"
+ height="15"
+ width="17"
+ id="rect3070-1-4-4"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="119.50633"
+ x="133.86069"
+ height="15"
+ width="36.517193"
+ id="rect3070-1-4-4-3"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-211.28244"
+ x="61.102837"
+ height="15"
+ width="34.221054"
+ id="rect3070-1-4-4-3-0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-211.28244"
+ x="99.563164"
+ height="15"
+ width="34.221054"
+ id="rect3070-1-4-4-3-0-7"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="35.734756"
+ x="128.58385"
+ height="104.47437"
+ width="88.40139"
+ id="rect3255"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <text
+ xml:space="preserve"
+ style="font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="123.39483"
+ y="186.71587"
+ id="text3279"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3281"
+ x="123.39483"
+ y="186.71587">Rotated Sections</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 232.17712,166.35116 19.4834,-33.28413"
+ id="path3283"
+ inkscape:connector-curvature="0" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="M 115.35461,166.34226 95.871207,133.05813"
+ id="path3283-3"
+ inkscape:connector-curvature="0" />
+ <g
+ transform="matrix(0.59836807,0.80122135,-0.80122135,0.59836807,444.08473,35.424173)"
+ id="g4606-2">
+ <rect
+ y="136.86716"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="160.75369"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-3-4-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="184.64023"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-3-6-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="136.86716"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-6-8"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="160.75369"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-3-4-1-1"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="184.64023"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-3-6-7-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="133.13654"
+ x="-86.863472"
+ height="74.686348"
+ width="49.520294"
+ id="rect4604-4"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ transform="matrix(-0.59836807,0.80122135,0.80122135,0.59836807,-98.254471,35.424172)"
+ id="g4606-2-7">
+ <rect
+ y="136.86716"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-2-8"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="160.75369"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-3-4-9-6"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="184.64023"
+ x="-83.616234"
+ height="19"
+ width="19"
+ id="rect4521-3-6-2-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="136.86716"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-6-8-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="160.75369"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-3-4-1-1-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="184.64023"
+ x="-60.643909"
+ height="19"
+ width="19"
+ id="rect4521-3-6-7-2-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="133.13654"
+ x="-86.863472"
+ height="74.686348"
+ width="49.520294"
+ id="rect4604-4-3"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-8.svg b/libX11/specs/XKB/XKBlib-8.svg
new file mode 100644
index 000000000..040a710e4
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-8.svg
@@ -0,0 +1,1143 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="650"
+ height="260"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ sodipodi:docname="XKBlib-8.svg">
+ <defs
+ id="defs4">
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend"
+ style="overflow:visible">
+ <path
+ id="path3907"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)"
+ inkscape:connector-curvature="0" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-0"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3907-0"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-5"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3907-4"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ <marker
+ inkscape:stockid="Arrow2Lend"
+ orient="auto"
+ refY="0"
+ refX="0"
+ id="Arrow2Lend-4"
+ style="overflow:visible">
+ <path
+ inkscape:connector-curvature="0"
+ id="path3907-9"
+ style="font-size:12px;fill-rule:evenodd;stroke-width:0.625;stroke-linejoin:round"
+ d="M 8.7185878,4.0337352 -2.2072895,0.01601326 8.7185884,-4.0017078 c -1.7454984,2.3720609 -1.7354408,5.6174519 -6e-7,8.035443 z"
+ transform="matrix(-1.1,0,0,-1.1,-1.1,0)" />
+ </marker>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="0.73307692"
+ inkscape:cx="167.44491"
+ inkscape:cy="102.71773"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial"
+ style="display:inline">
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect5422"
+ width="88.667366"
+ height="105.71878"
+ x="532.68628"
+ y="100.39874" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect5269"
+ width="70.251839"
+ height="148.0063"
+ x="458.34207"
+ y="58.793285" />
+ <rect
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect5267"
+ width="316.4743"
+ height="109.12907"
+ x="137.09338"
+ y="97.670517" />
+ <text
+ xml:space="preserve"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="23.189924"
+ y="75.162643"
+ id="text3070"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072"
+ x="23.189924"
+ y="75.162643">Editing</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="22.620016"
+ y="113.80984"
+ id="text3070-7"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-0"
+ x="22.620016"
+ y="113.80984">Function</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="24.666185"
+ y="157.46146"
+ id="text3070-5"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-1"
+ x="24.666185"
+ y="157.46146">Alpha</tspan></text>
+ <text
+ xml:space="preserve"
+ style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ x="23.984129"
+ y="197.02075"
+ id="text3070-1"
+ sodipodi:linespacing="125%"><tspan
+ sodipodi:role="line"
+ id="tspan3072-03"
+ x="23.984129"
+ y="197.02075">Keypad</tspan></text>
+ <path
+ style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 53.541448,207.48164 0,23.87198 524.160542,0 0,-22.50787"
+ id="path3113"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 53.807196,53.677857 0,-23.87198 445.631804,0 0,22.50787"
+ id="path3113-4"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 69.4945,153.25814 58.40936,0"
+ id="path3113-2"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cc" />
+ <path
+ style="fill:none;stroke:#000000;stroke-width:0.99999994px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend)"
+ d="m 87.012997,108.26001 18.817483,0 0,-33.761803 23.4072,0"
+ id="path3113-2-9"
+ inkscape:connector-curvature="0"
+ sodipodi:nodetypes="cccc" />
+ <rect
+ style="fill:#ffffff;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399"
+ width="315.79224"
+ height="23.871983"
+ x="137.77544"
+ y="59.475342"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9"
+ width="17.733475"
+ height="16.36936"
+ x="142.20882"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-4"
+ width="17.733475"
+ height="16.36936"
+ x="184.88353"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-9"
+ width="17.733475"
+ height="16.36936"
+ x="206.23926"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-8"
+ width="17.733475"
+ height="16.36936"
+ x="227.59499"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-1"
+ width="17.733475"
+ height="16.36936"
+ x="248.95071"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-4-2"
+ width="17.733475"
+ height="16.36936"
+ x="278.98425"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-9-9"
+ width="17.733475"
+ height="16.36936"
+ x="300.33997"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-8-2"
+ width="17.733475"
+ height="16.36936"
+ x="321.69571"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-1-8"
+ width="17.733475"
+ height="16.36936"
+ x="343.05142"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-4-1"
+ width="17.733475"
+ height="16.36936"
+ x="368.33368"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-9-2"
+ width="17.733475"
+ height="16.36936"
+ x="389.68939"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-8-4"
+ width="17.733475"
+ height="16.36936"
+ x="411.04514"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-1-7"
+ width="17.733475"
+ height="16.36936"
+ x="432.40085"
+ y="63.226654"
+ rx="0"
+ ry="0" />
+ <g
+ id="g5207"
+ transform="translate(1.7051201,1.7051363)">
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="162.85414"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="183.8405"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="204.82686"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-72"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="225.81322"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-37"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="246.79958"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="267.78595"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-5"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="288.77231"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-376"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="309.75867"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-81"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="330.74503"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-36"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="351.73138"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-40"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="372.71774"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-35"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="393.7041"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-85"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="414.69046"
+ height="16.36936"
+ width="30.692553"
+ id="rect4399-9-0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="102.44492"
+ x="141.86778"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="141.86778"
+ height="16.36936"
+ width="25.918154"
+ id="rect4399-9-3-9-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="170.72403"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-8"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="191.3956"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="212.06717"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="232.73874"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-4"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="253.41031"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-90"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="274.08185"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-1"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="294.75342"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-20"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="315.42499"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-06"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="336.09656"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="356.76813"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-908"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="377.4397"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-38"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="398.11127"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="122.22455"
+ x="418.78284"
+ height="16.36936"
+ width="26.600212"
+ id="rect4399-9-3-9-31"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="141.86778"
+ height="16.36936"
+ width="27.964327"
+ id="rect4399-9-0-0"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="173.64026"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-0"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="195.18188"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="216.72351"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-03"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="238.26514"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-1"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="259.80673"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-8"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="281.34836"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-01"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="302.88998"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="324.43161"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="345.97324"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-10"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="367.51486"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="389.05649"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="142.0042"
+ x="410.59811"
+ height="16.36936"
+ width="34.784893"
+ id="rect4399-9-3-9-0-4"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="141.86778"
+ height="16.36936"
+ width="34.102837"
+ id="rect4399-9-0-0-8"
+ style="fill:none;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="179.38089"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="200.52464"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-6"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="221.6684"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="242.81215"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="263.9559"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-90"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="285.09967"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="306.24344"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-0"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="327.38721"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-33"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="348.53098"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="369.67474"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-5-4-94"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="161.78384"
+ x="390.81851"
+ height="16.36936"
+ width="54.564533"
+ id="rect4399-9-3-9-0-5-4-99"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="182.24554"
+ x="141.86778"
+ height="16.36936"
+ width="25.918154"
+ id="rect4399-9-3-9-9-1"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="182.24554"
+ x="191.65791"
+ height="16.36936"
+ width="25.918154"
+ id="rect4399-9-3-9-9-1-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="182.24554"
+ x="221.32738"
+ height="16.36936"
+ width="150.73453"
+ id="rect4399-9-3-9-9-1-9-4"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="182.24554"
+ x="375.81323"
+ height="16.36936"
+ width="25.918154"
+ id="rect4399-9-3-9-9-1-9-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="182.24554"
+ x="419.46487"
+ height="16.36936"
+ width="25.918154"
+ id="rect4399-9-3-9-9-1-9-0"
+ style="fill:none;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ id="g5149"
+ transform="translate(-0.34100723,0)">
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="463.79852"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-6"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="484.94226"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-5"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="506.086"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56"
+ width="17.733475"
+ height="16.36936"
+ x="484.60126"
+ y="164.14764"
+ rx="0"
+ ry="0" />
+ <g
+ transform="translate(-0.34100723,39.559283)"
+ id="g5149-1">
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="463.79852"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-6-1"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="484.94226"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-5-4"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="506.086"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-9-3"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ transform="translate(-0.34100723,60.020983)"
+ id="g5149-7">
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="463.79852"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-6-2"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="484.94226"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-5-7"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="506.086"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-9-33"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <g
+ transform="translate(-0.34100723,120.383)"
+ id="g5149-9">
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="463.79852"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-6-24"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="484.94226"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-5-44"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ ry="0"
+ rx="0"
+ y="63.567684"
+ x="506.086"
+ height="16.36936"
+ width="17.733475"
+ id="rect4399-9-3-9-0-59-9-9"
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-6-1-3"
+ width="17.733475"
+ height="16.36936"
+ x="536.77863"
+ y="104.44491"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-5-4-8"
+ width="17.733475"
+ height="16.36936"
+ x="557.92236"
+ y="104.44491"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-9-3-3"
+ width="17.733475"
+ height="16.36936"
+ x="579.0661"
+ y="104.4449"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-6-2-9"
+ width="17.733475"
+ height="16.36936"
+ x="536.77863"
+ y="124.4519"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-5-7-5"
+ width="17.733475"
+ height="16.36936"
+ x="557.92236"
+ y="124.4519"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-9-33-4"
+ width="17.733475"
+ height="16.36936"
+ x="579.0661"
+ y="124.22455"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-6-1-9"
+ width="17.733475"
+ height="16.36936"
+ x="536.77863"
+ y="144.45891"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-5-4-4"
+ width="17.733475"
+ height="16.36936"
+ x="557.92236"
+ y="144.45889"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-9-3-9"
+ width="17.733475"
+ height="16.36936"
+ x="579.0661"
+ y="144.0042"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-6-2-5"
+ width="17.733475"
+ height="16.36936"
+ x="536.77863"
+ y="164.4659"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-5-7-7"
+ width="17.733475"
+ height="16.36936"
+ x="557.92236"
+ y="164.4659"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-9-33-3"
+ width="17.733475"
+ height="16.36936"
+ x="579.0661"
+ y="163.78384"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999982;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56-9"
+ width="38.195171"
+ height="16.36936"
+ x="537.46069"
+ y="183.56349"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999982;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56-9-0"
+ width="17.733471"
+ height="16.36936"
+ x="579.0661"
+ y="183.56349"
+ rx="0"
+ ry="0" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999982;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56-9-7"
+ width="35.466946"
+ height="16.36936"
+ x="164.46588"
+ y="-617.26129"
+ rx="0"
+ ry="0"
+ transform="matrix(0,1,-1,0,0,0)" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999982;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56-9-7-2"
+ width="35.466946"
+ height="16.36936"
+ x="124.73609"
+ y="-617.26129"
+ rx="0"
+ ry="0"
+ transform="matrix(0,1,-1,0,0,0)" />
+ <rect
+ style="fill:none;stroke:#000000;stroke-width:0.99999976;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+ id="rect4399-9-3-9-0-59-56-9-7-7"
+ width="15.687304"
+ height="16.36936"
+ x="104.78593"
+ y="-616.57916"
+ rx="0"
+ ry="0"
+ transform="matrix(0,1,-1,0,0,0)" />
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/XKBlib-9.svg b/libX11/specs/XKB/XKBlib-9.svg
new file mode 100644
index 000000000..155fa33fc
--- /dev/null
+++ b/libX11/specs/XKB/XKBlib-9.svg
@@ -0,0 +1,2075 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:xlink="http://www.w3.org/1999/xlink"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="610"
+ height="200"
+ id="svg2"
+ version="1.1"
+ inkscape:version="0.48.0 r9654"
+ inkscape:export-filename="/home/fcarrijo/Desktop/teste.png"
+ inkscape:export-xdpi="156.71965"
+ inkscape:export-ydpi="156.71965"
+ style="display:inline"
+ sodipodi:docname="New document 1">
+ <defs
+ id="defs4">
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6833"
+ id="pattern7008"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5492"
+ id="pattern7005"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-4"
+ id="pattern7002"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-7"
+ id="pattern6999"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-3"
+ id="pattern6996"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-40"
+ id="pattern6993"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-9"
+ id="pattern6990"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-90"
+ id="pattern6987"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-908"
+ id="pattern6984"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5521-0"
+ id="pattern6981"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83886)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5703"
+ id="pattern6978"
+ patternTransform="matrix(2.2179025,0,0,2.4345374,229.96546,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5827"
+ id="pattern6975"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern5827-4"
+ id="pattern6972"
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6835"
+ id="pattern6967"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6837"
+ id="pattern6964"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6839"
+ id="pattern6961"
+ patternTransform="translate(197.1723,91.062099)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6841"
+ id="pattern6958"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6843"
+ id="pattern6955"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6845"
+ id="pattern6952"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6847"
+ id="pattern6949"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6849"
+ id="pattern6946"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6851"
+ id="pattern6943"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6853"
+ id="pattern6940"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6855"
+ id="pattern6937"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6857"
+ id="pattern6934"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6859"
+ id="pattern6931"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6861"
+ id="pattern6928"
+ patternTransform="translate(197.17229,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6188"
+ id="pattern6906"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6204"
+ id="pattern6903"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236"
+ id="pattern6900"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-7"
+ id="pattern6897"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-6"
+ id="pattern6894"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-4"
+ id="pattern6891"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-3"
+ id="pattern6888"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-79"
+ id="pattern6885"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-9"
+ id="pattern6882"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-32"
+ id="pattern6879"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-64"
+ id="pattern6876"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-2"
+ id="pattern6873"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-74"
+ id="pattern6870"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-48"
+ id="pattern6867"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6236-31"
+ id="pattern6864"
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03292)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-28"
+ id="pattern6861"
+ patternTransform="translate(197.17229,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-2"
+ id="pattern6859"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-38"
+ id="pattern6857"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-9"
+ id="pattern6855"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-74"
+ id="pattern6853"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-6"
+ id="pattern6851"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-3"
+ id="pattern6849"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-0"
+ id="pattern6847"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-4"
+ id="pattern6845"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607-7"
+ id="pattern6843"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6607"
+ id="pattern6841"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6575"
+ id="pattern6839"
+ patternTransform="translate(197.1723,91.542505)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6544"
+ id="pattern6837"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6521"
+ id="pattern6835"
+ patternTransform="translate(197.1723,91.542504)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1"
+ id="pattern6833"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,231.13681,-129.83887)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510"
+ id="pattern6521"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1"
+ id="pattern6188"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5492"
+ xlink:href="#Strips1_1-3"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-4"
+ xlink:href="#pattern5492-7"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-7"
+ xlink:href="#Strips1_1-3-8"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-8"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-63"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-7"
+ xlink:href="#pattern5492-2"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-2"
+ xlink:href="#Strips1_1-3-3"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-3"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-72"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-3"
+ xlink:href="#pattern5492-76"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-76"
+ xlink:href="#Strips1_1-3-81"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-81"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-3"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-40"
+ xlink:href="#pattern5492-35"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-35"
+ xlink:href="#Strips1_1-3-85"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-85"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-0"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-9"
+ xlink:href="#pattern5492-8"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-8"
+ xlink:href="#Strips1_1-3-0"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-0"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-2"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-90"
+ xlink:href="#pattern5492-1"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-1"
+ xlink:href="#Strips1_1-3-20"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-20"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-06"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5521-908"
+ xlink:href="#pattern5492-38"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-38"
+ xlink:href="#Strips1_1-3-7"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-7"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-31"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83886)"
+ id="pattern5521-0"
+ xlink:href="#pattern5492-5"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-5"
+ xlink:href="#Strips1_1-3-03"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-03"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-1"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179025,0,0,2.4345374,231.13683,-129.83887)"
+ id="pattern5703"
+ xlink:href="#pattern5521-4-0"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5521-4-0"
+ xlink:href="#pattern5492-7-1"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-7-1"
+ xlink:href="#Strips1_1-3-8-7"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-8-7"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-63-9"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5827"
+ xlink:href="#pattern5521-4-5"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5521-4-5"
+ xlink:href="#pattern5492-7-9"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-7-9"
+ xlink:href="#Strips1_1-3-8-5"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-8-5"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-63-6"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,231.13682,-129.83887)"
+ id="pattern5827-4"
+ xlink:href="#pattern5521-4-3"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5521-4-3"
+ xlink:href="#pattern5492-7-7"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(2.2179023,0,0,2.4345375,229.96545,-129.83887)"
+ id="pattern5492-7-7"
+ xlink:href="#Strips1_1-3-8-2"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-3-8-2"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-9-63-7"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204"
+ xlink:href="#pattern6188-5"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39"
+ id="pattern6188-5"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236"
+ xlink:href="#pattern6204-8"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-8"
+ xlink:href="#pattern6188-5-7"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-0"
+ id="pattern6188-5-7"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-0"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-5"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-7"
+ xlink:href="#pattern6204-9"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-9"
+ xlink:href="#pattern6188-5-1"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-9"
+ id="pattern6188-5-1"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-9"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-6"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-6"
+ xlink:href="#pattern6204-84"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-84"
+ xlink:href="#pattern6188-5-6"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-6"
+ id="pattern6188-5-6"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-6"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-7"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-4"
+ xlink:href="#pattern6204-1"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-1"
+ xlink:href="#pattern6188-5-0"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-06"
+ id="pattern6188-5-0"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-06"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-4"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-3"
+ xlink:href="#pattern6204-7"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-7"
+ xlink:href="#pattern6188-5-3"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-4"
+ id="pattern6188-5-3"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-4"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-72"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-79"
+ xlink:href="#pattern6204-5"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-5"
+ xlink:href="#pattern6188-5-68"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-95"
+ id="pattern6188-5-68"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-95"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-52"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-9"
+ xlink:href="#pattern6204-91"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-91"
+ xlink:href="#pattern6188-5-62"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-1"
+ id="pattern6188-5-62"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-1"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-0"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-32"
+ xlink:href="#pattern6204-19"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-19"
+ xlink:href="#pattern6188-5-76"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-8"
+ id="pattern6188-5-76"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-8"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-2"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-64"
+ xlink:href="#pattern6204-3"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-3"
+ xlink:href="#pattern6188-5-36"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-90"
+ id="pattern6188-5-36"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-90"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-48"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-2"
+ xlink:href="#pattern6204-97"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-97"
+ xlink:href="#pattern6188-5-38"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-09"
+ id="pattern6188-5-38"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-09"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-23"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-74"
+ xlink:href="#pattern6204-16"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-16"
+ xlink:href="#pattern6188-5-385"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-5"
+ id="pattern6188-5-385"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-5"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-01"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6236-48"
+ xlink:href="#pattern6204-56"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-56"
+ xlink:href="#pattern6188-5-2"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-52"
+ id="pattern6188-5-2"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-52"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-69"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03292)"
+ id="pattern6236-31"
+ xlink:href="#pattern6204-52"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="matrix(1.5682937,1.5682937,-1.7214781,1.721478,589.69469,-269.03293)"
+ id="pattern6204-52"
+ xlink:href="#pattern6188-5-69"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#Strips1_1-39-44"
+ id="pattern6188-5-69"
+ patternTransform="matrix(1.5682937,1.5682937,-1.721478,1.721478,589.69467,-269.03293)" />
+ <pattern
+ inkscape:stockid="Stripes 1:1"
+ id="Strips1_1-39-44"
+ patternTransform="matrix(2.2179022,0,0,2.4345375,229.96544,-129.83887)"
+ height="1"
+ width="2"
+ patternUnits="userSpaceOnUse"
+ inkscape:collect="always">
+ <rect
+ id="rect4756-1-60"
+ height="2"
+ width="1"
+ y="-0.5"
+ x="0"
+ style="fill:black;stroke:none" />
+ </pattern>
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6544"
+ xlink:href="#pattern6521-7"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-9"
+ id="pattern6521-7"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-9">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575"
+ xlink:href="#pattern6521-2"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2"
+ id="pattern6521-2"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607"
+ xlink:href="#pattern6575-0"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-0"
+ xlink:href="#pattern6521-2-3"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-5"
+ id="pattern6521-2-3"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-5">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-7"
+ xlink:href="#pattern6575-1"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-1"
+ xlink:href="#pattern6521-2-7"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-0"
+ id="pattern6521-2-7"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-0">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-4"
+ xlink:href="#pattern6575-13"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-13"
+ xlink:href="#pattern6521-2-0"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-2"
+ id="pattern6521-2-0"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-2">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-0"
+ xlink:href="#pattern6575-9"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-9"
+ xlink:href="#pattern6521-2-35"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-4"
+ id="pattern6521-2-35"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-4">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-3"
+ xlink:href="#pattern6575-19"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-19"
+ xlink:href="#pattern6521-2-1"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-09"
+ id="pattern6521-2-1"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-09">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-4"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-6"
+ xlink:href="#pattern6575-2"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-2"
+ xlink:href="#pattern6521-2-5"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-9"
+ id="pattern6521-2-5"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-9">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-74"
+ xlink:href="#pattern6575-11"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-11"
+ xlink:href="#pattern6521-2-9"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-1"
+ id="pattern6521-2-9"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-1">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-38"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-9"
+ xlink:href="#pattern6575-3"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-3"
+ xlink:href="#pattern6521-2-13"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-8"
+ id="pattern6521-2-13"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-8">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-7"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-38"
+ xlink:href="#pattern6575-8"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-8"
+ xlink:href="#pattern6521-2-4"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-00"
+ id="pattern6521-2-4"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-00">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-8"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.1723,91.062098)"
+ id="pattern6607-2"
+ xlink:href="#pattern6575-38"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-38"
+ xlink:href="#pattern6521-2-50"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-59"
+ id="pattern6521-2-50"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-59">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ <pattern
+ patternTransform="translate(197.17229,91.062098)"
+ id="pattern6607-28"
+ xlink:href="#pattern6575-36"
+ inkscape:collect="always" />
+ <pattern
+ patternTransform="translate(197.1723,91.062099)"
+ id="pattern6575-36"
+ xlink:href="#pattern6521-2-78"
+ inkscape:collect="always" />
+ <pattern
+ inkscape:collect="always"
+ xlink:href="#pattern6510-2-7"
+ id="pattern6521-2-78"
+ patternTransform="translate(197.1723,91.062098)" />
+ <pattern
+ patternUnits="userSpaceOnUse"
+ width="9.8994949"
+ height="9.8994949"
+ patternTransform="translate(197.17231,91.062095)"
+ id="pattern6510-2-7">
+ <rect
+ transform="matrix(0.70710678,-0.70710678,0.70710678,0.70710678,0,0)"
+ y="3.9870605"
+ x="-3.0051956"
+ height="6"
+ width="6"
+ id="rect6508-6-26"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </pattern>
+ </defs>
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1.1047094"
+ inkscape:cx="215.00586"
+ inkscape:cy="94.431542"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer2"
+ showgrid="false"
+ inkscape:window-width="1016"
+ inkscape:window-height="718"
+ inkscape:window-x="0"
+ inkscape:window-y="0"
+ inkscape:window-maximized="1" />
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title></dc:title>
+ </cc:Work>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:groupmode="layer"
+ id="layer2"
+ inkscape:label="Vetorial">
+ <g
+ id="g7020">
+ <text
+ sodipodi:linespacing="125%"
+ id="text3050-1-0"
+ y="159.69649"
+ x="72.986145"
+ style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="159.69649"
+ x="72.986145"
+ id="tspan3160"
+ sodipodi:role="line">Row 5</tspan></text>
+ <rect
+ y="143.61836"
+ x="35.192387"
+ height="15"
+ width="17"
+ id="rect3162"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="141.80794"
+ x="183.40567"
+ height="18.620861"
+ width="29.673016"
+ id="rect3162-4"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="141.80794"
+ x="244.96031"
+ height="18.620861"
+ width="29.673016"
+ id="rect3162-4-9"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="141.80794"
+ x="282.07419"
+ height="18.620861"
+ width="183.55963"
+ id="rect3162-4-4"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="141.80794"
+ x="473.07458"
+ height="18.620861"
+ width="29.673016"
+ id="rect3162-4-98"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="141.80794"
+ x="533.724"
+ height="18.620861"
+ width="29.673016"
+ id="rect3162-4-1"
+ style="fill:#cccccc;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3050-1"
+ y="133.72653"
+ x="72.611145"
+ style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="133.72653"
+ x="72.611145"
+ id="tspan3097"
+ sodipodi:role="line">Row 4</tspan></text>
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-52.192387"
+ x="117.64841"
+ height="17"
+ width="15"
+ id="rect3162-6"
+ style="fill:url(#pattern7008);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-227.33467"
+ x="115.38536"
+ height="44.834232"
+ width="19.526077"
+ id="rect3162-6-3"
+ style="fill:url(#pattern7005);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-331.94257"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-7"
+ style="fill:url(#pattern7002);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-358.49057"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-5"
+ style="fill:url(#pattern6999);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-385.03857"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-6"
+ style="fill:url(#pattern6996);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-411.58658"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-9"
+ style="fill:url(#pattern6993);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-438.13458"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-4"
+ style="fill:url(#pattern6990);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-464.68259"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-3"
+ style="fill:url(#pattern6987);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-491.23059"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-0"
+ style="fill:url(#pattern6984);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-562.58673"
+ x="115.38536"
+ height="67.239456"
+ width="19.526077"
+ id="rect3162-6-3-8"
+ style="fill:url(#pattern6981);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-252.29855"
+ x="115.27222"
+ height="20.847166"
+ width="19.752378"
+ id="rect3162-6-3-7-1"
+ style="fill:url(#pattern6978);fill-opacity:1;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-278.84656"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-7-11"
+ style="fill:url(#pattern6975);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-305.39456"
+ x="115.38536"
+ height="22.431293"
+ width="19.526077"
+ id="rect3162-6-3-7-3"
+ style="fill:url(#pattern6972);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3050-7"
+ y="82.969315"
+ x="73.138489"
+ style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="82.969315"
+ x="73.138489"
+ id="tspan3093"
+ sodipodi:role="line">Row 2</tspan></text>
+ <rect
+ y="66.732986"
+ x="35.192387"
+ height="15"
+ width="17"
+ id="rect3162-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="184.31088"
+ height="16.810431"
+ width="30.578232"
+ id="rect3162-3-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="221.77287"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="245.46707"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-7"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="269.16125"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-2"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="298.85544"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-72"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="326.54962"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-9"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="351.2438"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-0"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="375.93799"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-5"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="403.63217"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-04"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="433.32635"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-1"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="457.52054"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-79"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="481.71475"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-3"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="505.90897"
+ height="16.810431"
+ width="18.810432"
+ id="rect3162-3-9-0-6"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="65.827774"
+ x="530.10321"
+ height="16.810431"
+ width="32.388664"
+ id="rect3162-3-9-0-21"
+ style="fill:#ffffff;fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3050"
+ y="58.028015"
+ x="73.044739"
+ style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="58.028015"
+ x="73.044739"
+ id="tspan3052"
+ sodipodi:role="line">Row 1</tspan></text>
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-52.192387"
+ x="41.94989"
+ height="17"
+ width="15"
+ id="rect3162-3-2"
+ style="fill:url(#pattern6906);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-204.02654"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8"
+ style="fill:url(#pattern6903);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-228.91995"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-2"
+ style="fill:url(#pattern6900);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-253.81337"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-3"
+ style="fill:url(#pattern6897);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-278.70679"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-27"
+ style="fill:url(#pattern6894);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-306.31586"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-4"
+ style="fill:url(#pattern6891);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-335.50906"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-1"
+ style="fill:url(#pattern6888);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-360.06302"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-15"
+ style="fill:url(#pattern6885);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-384.61697"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-5"
+ style="fill:url(#pattern6882);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-412.22607"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-0"
+ style="fill:url(#pattern6879);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-438.16376"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-51"
+ style="fill:url(#pattern6876);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-464.10144"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-18"
+ style="fill:url(#pattern6873);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-490.03912"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-26"
+ style="fill:url(#pattern6870);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-515.97681"
+ x="40.026306"
+ height="20.620861"
+ width="18.847166"
+ id="rect3162-3-2-8-13"
+ style="fill:url(#pattern6867);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ inkscape:export-ydpi="3240"
+ inkscape:export-xdpi="3240"
+ transform="matrix(0,1,-1,0,0,0)"
+ y="-562.77502"
+ x="40.026306"
+ height="40.535599"
+ width="18.847166"
+ id="rect3162-3-2-8-7"
+ style="fill:url(#pattern6864);fill-opacity:1;stroke:#000000;stroke-width:0.99999988;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <text
+ sodipodi:linespacing="125%"
+ id="text3050-5"
+ y="107.77702"
+ x="72.898254"
+ style="font-size:24px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:DejaVu Sans;-inkscape-font-specification:DejaVu Sans"
+ xml:space="preserve"><tspan
+ y="107.77702"
+ x="72.898254"
+ id="tspan3095"
+ sodipodi:role="line">Row 3</tspan></text>
+ <rect
+ y="89.592499"
+ x="182.74036"
+ height="18.896372"
+ width="35.86916"
+ id="rect6515"
+ style="fill:url(#pattern6967);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="91.540688"
+ x="35.192387"
+ height="15"
+ width="17"
+ id="rect6515-0"
+ style="fill:url(#pattern6964);fill-opacity:1;stroke:#000000;stroke-width:0.99999994;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="223.49092"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9"
+ style="fill:url(#pattern6961);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="250.15965"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-8"
+ style="fill:url(#pattern6958);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="276.82837"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-0"
+ style="fill:url(#pattern6955);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="303.4971"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-6"
+ style="fill:url(#pattern6952);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="330.16583"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-64"
+ style="fill:url(#pattern6949);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="356.83456"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-5"
+ style="fill:url(#pattern6946);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="383.5033"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-7"
+ style="fill:url(#pattern6943);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="410.17203"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-74"
+ style="fill:url(#pattern6940);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="436.84076"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-9"
+ style="fill:url(#pattern6937);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="463.50949"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-68"
+ style="fill:url(#pattern6934);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="490.17822"
+ height="18.896372"
+ width="21.787313"
+ id="rect6515-9-685"
+ style="fill:url(#pattern6931);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ <rect
+ y="89.592499"
+ x="516.84692"
+ height="18.896372"
+ width="46.22813"
+ id="rect6515-9-62"
+ style="fill:url(#pattern6928);fill-opacity:1;stroke:#000000;stroke-width:1;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
+ </g>
+ </g>
+</svg>
diff --git a/libX11/specs/XKB/acknowledgement.xml b/libX11/specs/XKB/acknowledgement.xml
new file mode 100644
index 000000000..2977999c4
--- /dev/null
+++ b/libX11/specs/XKB/acknowledgement.xml
@@ -0,0 +1,35 @@
+<preface id='acknowledgement'>
+<title>Acknowledgement</title>
+<para>
+This document is the result of a great deal of hard work by a great
+many people. Without Erik Fortune’s work as Architect of the X
+Keyboard Extension and the longtime support of Silicon Graphics
+Inc. there would not be a keyboard extension.
+</para>
+<para>
+We gratefully thank Will Walker and George Sachs for their help and
+expertise in providing some of the content for this document, and
+Digital Equipment Corporation and Hewlett-Packard for allowing them
+to participate in this project, and we are deeply indebted to IBM for
+providing the funding to complete this library specification.
+</para>
+<para>
+Most of all, we thank Gary Aitken and Amber J. Benson for their long
+hours and late nights as ultimate authors of this specification, and
+for serving as authors, document editors, and XKB protocol and
+implementation reviewers. Their commitment to accuracy and completeness,
+their attention to detail, their keen insight, and their good natures
+when working under tremendous pressure are in some measure responsible
+not only for the quality of this document, but for the quality of the
+Keyboard extension itself.
+</para>
+<para>
+Matt Landau
+</para>
+<para>
+Manager, X Window System
+</para>
+<para>
+X Consortium Inc.
+</para>
+</preface>
diff --git a/libX11/specs/XKB/ch01.xml b/libX11/specs/XKB/ch01.xml
new file mode 100644
index 000000000..5079a411a
--- /dev/null
+++ b/libX11/specs/XKB/ch01.xml
@@ -0,0 +1,404 @@
+<chapter id='overview'>
+<title>Overview</title>
+
+<para>
+The X Keyboard Extension provides capabilities that are lacking or are
+cumbersome in the core X protocol.
+</para>
+
+<sect1 id='core_x_protocol_support_for_keyboards'>
+<title>Core X Protocol Support for Keyboards</title>
+
+<para>
+The core X protocol specifies the ways that the
+<emphasis>Shift</emphasis>,
+<emphasis>Control</emphasis>, and
+<emphasis>Lock</emphasis>
+modifiers and the modifiers bound to the
+<emphasis>Mode_switch</emphasis> or
+<emphasis>Num_Lock</emphasis>
+keysyms interact to generate keysyms and characters. The core protocol also
+allows users to specify that a key affects one or more modifiers. This behavior
+is simple and fairly flexible, but it has a number of limitations that make it
+difficult or impossible to properly support many common varieties of keyboard
+behavior. The limitations of core protocol support for keyboards include:
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+Use of a single, uniform, four-symbol mapping for all keyboard keys makes it
+difficult to properly support keyboard overlays, PC-style break keys, or
+keyboards that comply with ISO9995, or a host of other national and
+international standards.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A second keyboard group may be specified using a modifier, but this has side
+effects that wreak havoc with client grabs and X toolkit translations.
+Furthermore, this approach limits the number of keyboard groups to two.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Poorly specified locking key behavior requires X servers to look for a few
+"magic" keysyms to determine that keys should lock when pressed. This leads to
+incompatibilities between X servers with no way for clients to detect
+implementation differences.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Poorly specified capitalization and control behavior requires modifications to
+X library source code to support new character sets or locales and can lead to
+incompatibilities between system wide and X library capitalization behavior.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Limited interactions between modifiers specified by the core protocol make many
+common keyboard behaviors difficult or impossible to implement. For example,
+there is no reliable way to indicate whether or not the shift modifier should
+"cancel" the lock modifier.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+The lack of any explicit descriptions for indicators, most modifiers, and other
+aspects of the keyboard appearance requires clients that wish to clearly
+describe the keyboard to a user to resort to a mish-mash of prior knowledge and
+heuristics.
+ </para>
+ </listitem>
+</itemizedlist>
+
+</sect1>
+<sect1 id='xkb_keyboard_extension_support_for_keyboards'>
+<title>Xkb Keyboard Extension Support for Keyboards</title>
+
+<para>
+The X Keyboard Extension makes it possible to clearly and explicitly specify
+most aspects of keyboard behavior on a per-key basis. It adds the notion of a
+keyboard group to the global keyboard state and provides mechanisms to more
+closely track the logical and physical state of the keyboard. For
+keyboard-control clients, Xkb provides descriptions and symbolic names for many
+aspects of keyboard appearance and behavior.
+</para>
+
+<para>
+In addition, the X Keyboard Extension includes additional keyboard controls
+designed to make keyboards more accessible to people with movement impairments.
+</para>
+
+</sect1>
+
+<sect1 id='xkb_extension_components'>
+<title>Xkb Extension Components</title>
+
+<para>
+The Xkb extension is composed of two parts: a server extension, and a
+client-side X library extension. These consist of a loadable module that may be
+activated when an X server is started and a modified version of Xlib. Both
+server and Xlib versions must be at least X11 R6.
+</para>
+
+
+<para>
+Figure 1.1 shows the overall structure of the Xkb extension:
+</para>
+
+<mediaobject>
+ <imageobject>
+ <imagedata format="SVG" fileref="XKBlib-1.svg"/>
+ </imageobject>
+ <caption>Overall Xkb Structure</caption>
+</mediaobject>
+
+
+<para>
+The server portion of the Xkb extension encompasses a database of named
+keyboard components, in unspecified format, that may be used to configure a
+keyboard. Internally, the server maintains a <emphasis>
+keyboard description</emphasis>
+ that includes the keyboard state and configuration (mapping). By "keyboard" we
+mean the logical keyboard device, which includes not only the physical keys,
+but also potentially a set of up to 32 indicators (usually LEDs) and bells.
+</para>
+
+
+<para>
+The keyboard description is a composite of several different data structures,
+each of which may be manipulated separately. When manipulating the server
+components, the design allows partial components to be transmitted between the
+server and a client. The individual components are shown in Figure 1.1.
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term>Client Map</term>
+ <listitem>
+ <para>
+The key mapping information needed to convert arbitrary keycodes to symbols.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Server Map</term>
+ <listitem>
+ <para>
+The key mapping information categorizing keys by functionality (which keys are
+modifiers, how keys behave, and so on).
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Controls</term>
+ <listitem>
+ <para>
+Client configurable quantities effecting how the keyboard behaves, such as
+repeat behavior and modifications for people with movement impairments.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Indicators</term>
+ <listitem>
+ <para>
+The mapping of behavior to indicators.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Geometry</term>
+ <listitem>
+ <para>
+A complete description of the physical keyboard layout, sufficient to draw a
+representation of the keyboard.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Names</term>
+ <listitem>
+ <para>
+A mapping of names to various aspects of the keyboard such as individual
+virtual modifiers, indicators, and bells.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Compatibility Map</term>
+ <listitem>
+ <para>
+The definition of how to map core protocol keyboard state to Xkb keyboard state.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+A client application interrogates and manipulates the keyboard by reading and
+writing portions of the server description for the keyboard. In a typical
+sequence a client would fetch the current information it is interested in,
+modify it, and write it back. If a client wishes to track some portion of the
+keyboard state, it typically maintains a local copy of the portion of the
+server keyboard description dealing with the items of interest and updates this
+local copy from events describing state transitions that are sent by the server.
+</para>
+
+<para>
+A client may request the server to reconfigure the keyboard either by sending
+explicit reconfiguration instructions to it, or by telling it to load a new
+configuration from its database of named components. Partial reconfiguration
+and incremental reconfiguration are both supported.
+</para>
+
+<sect2 id='groups_and_shift_levels'>
+<title>Groups and Shift Levels</title>
+
+<para>
+The graphic characters or control functions that may be accessed by one key are
+logically arranged in groups and levels. See section 14.1for a complete
+description of groups and levels.
+</para>
+
+
+</sect2>
+<sect2 id='radio_groups'>
+<title>Radio Groups</title>
+
+<para>
+A radio group is a set of keys whose behavior simulates a set of radio buttons.
+Once a key in a radio group is pressed, it stays logically depressed until
+another key in the group is pressed, at which point the previously depressed
+key is logically released. Consequently, at most one key in a radio group can
+be logically depressed at one time. A radio group is defined by a radio group
+index, an optional name, and by assigning each key in the radio group <emphasis>
+XkbKB_RadioGroup</emphasis>
+ behavior and the radio group index.
+</para>
+
+</sect2>
+</sect1>
+
+<sect1 id='client_types'>
+<title>Client Types</title>
+
+<para>
+This specification differentiates between three different classes of client
+applications:
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+Xkb-aware applications
+ </para>
+ <para>
+These applications make specific use of Xkb functionality and APIs not present
+in the core protocol.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Xkb-capable applications
+ </para>
+ <para>
+These applications make no use of Xkb extended functionality and Application
+Programming Interfaces (APIs) directly. However, they are linked with a version
+of Xlib that includes Xkb and indirectly benefit from some of Xkb’s
+features.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Xkb-unaware applications
+ </para>
+ <para>
+These applications make no use of Xkb extended functionality or APIs and
+require Xkb’s functionality to be mapped to core Xlib functionality to
+operate properly.
+ </para>
+ </listitem>
+</itemizedlist>
+
+</sect1>
+
+<sect1 id='compatibility_with_the_core_protocol'>
+<title>Compatibility With the Core Protocol</title>
+
+<para>
+Because the Xkb extension allows a keyboard to be configured in ways not
+foreseen by the core protocol, and because Xkb-unaware clients are allowed to
+connect to a server using the Xkb extension, there must be a means of
+converting between the Xkb domain and the core protocol. The Xkb server
+extension maintains a compatibility map as part of its keyboard description;
+this map controls the conversion of Xkb generated events to core protocol
+events and the results of core protocol requests to appropriate Xkb state and
+configuration.
+</para>
+
+
+</sect1>
+<sect1 id='additional_protocol_errors'>
+<title>Additional Protocol Errors</title>
+
+<para>
+The Xkb extension adds a single protocol error, <emphasis>
+BadKeyboard</emphasis>
+, to the core protocol error set. See section 2.6 for a discussion of the <!-- xref -->
+<emphasis>
+BadKeyboard</emphasis>
+ protocol error.
+</para>
+
+
+</sect1>
+<sect1 id='extension_library_functions'>
+<title>Extension Library Functions</title>
+
+<para>
+The X Keyboard Extension replaces the core protocol definition of a keyboard
+with a more comprehensive one. The X Keyboard Extension library interfaces are
+included in Xlib.<footnote><para>
+X11R6.1 is the first release by the X Consortium, Inc.,that includes the X
+Keyboard Extension in Xlib. X11R6 included work in progress on this extension
+as nonstandard additions to the library.
+</para>
+</footnote>
+</para>
+
+<para>
+Xlib detects the presence of the X Keyboard server extension and uses Xkb
+protocol to replace some standard X library functions related to the keyboard.
+If an application uses only standard X library functions to examine the
+keyboard or process key events, it should not need to be modified when linked
+with an X library containing the X keyboard extension. All of the
+keyboard-related X library functions have been modified to automatically use
+Xkb protocol when the server extension is present.
+</para>
+
+<para>
+The Xkb extension adds library interfaces to allow a client application to
+directly manipulate the new capabilities.
+</para>
+
+
+<sect2 id='error_indications'>
+<title>Error Indications</title>
+
+<para>
+Xkb functions that communicate with the X server check to be sure the Xkb
+extension has been properly initialized prior to doing any other operations. If
+the extension has not been properly initialized or the application, library,
+and server versions are incompatible, these functions return an error
+indication as shown in Table 1.1. Because of this test, <emphasis>
+BadAccess</emphasis>
+ and <emphasis>
+BadMatch</emphasis>
+ (due to incompatible versions) protocol errors should normally not be
+generated.
+</para>
+
+<table frame='none'>
+<!-- <caption>Function Error Returns Due to Extension Problems</caption> -->
+<title>Function Error Returns Due to Extension Problems</title>
+<tgroup cols='2'>
+<colspec align="left" colsep="0"/>
+<colspec align="left" colsep="0"/>
+<thead>
+ <row>
+ <entry>Functions return type</entry>
+ <entry>Return value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>pointer to a structure</entry>
+ <entry>NULL</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Bool</entry>
+ <entry>False</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Status</entry>
+ <entry>BadAccess</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Many Xkb functions do not actually communicate with the X server; they only
+require processing in the client-side portion of the library. Furthermore, some
+applications may never actually need to communicate with the server; they
+simply use the Xkb library capabilities. The functions that do not communicate
+with the server return either a pointer to a structure, a Bool, or a Status.
+These functions check that the application has queried the Xkb library version
+and return the values shown in Table 1.1 if it has not.
+</para>
+</sect2>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch02.xml b/libX11/specs/XKB/ch02.xml
new file mode 100644
index 000000000..55f15a322
--- /dev/null
+++ b/libX11/specs/XKB/ch02.xml
@@ -0,0 +1,818 @@
+<chapter id='initialization_and_general_programming_information'>
+<title>Initialization and General Programming Information</title>
+<sect1 id='extension_header_files'>
+<title>Extension Header Files</title>
+<para>
+The following include files are part of the Xkb standard:
+</para>
+<itemizedlist>
+ <listitem>
+ <para>
+<emphasis>&lt;X11/XKBlib.h&gt;</emphasis>
+ </para>
+ <para><emphasis>XKBlib.h</emphasis>
+is the main header file for Xkb; it declares constants, types, and
+functions.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>&lt;X11/extensions/XKBstr.h&gt;</emphasis>
+ </para>
+ <para>
+<emphasis>XKBstr.h</emphasis> declares types and
+constants for Xkb. It is included automatically from
+<emphasis>&lt;X11/XKBlib.h&gt;</emphasis>
+; you should never need to reference it directly in your application code.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>&lt;X11/extensions/XKB.h&gt;</emphasis>
+ </para>
+ <para>
+<emphasis>XKB.h</emphasis>
+defines constants for Xkb. It is included automatically from <emphasis>
+&lt;X11/XKBstr.h&gt;</emphasis>
+; you should never need to reference it directly in your application code.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>&lt;X11/extensions/XKBgeom.h&gt;</emphasis>
+ </para>
+ <para><emphasis>XKBgeom.h</emphasis>
+declares types, symbolic constants, and functions for manipulating
+keyboard geometry descriptions.
+ </para>
+ </listitem>
+</itemizedlist>
+</sect1>
+<sect1 id='extension_name'>
+<title>Extension Name</title>
+<para>
+The name of the Xkb extension is given in <emphasis>
+&lt;X11/extensions/Xkb.h&gt;:</emphasis>
+</para>
+
+<para>
+<emphasis>
+#define XkbName "XKEYBOARD"</emphasis>
+</para>
+
+<para>
+Most extensions to the X protocol are initialized by calling <emphasis>
+XInitExtension</emphasis>
+ and passing the extension name. However, as explained in section 2.4, Xkb
+requires a more complex initialization sequence, and a client program should
+not call <emphasis>
+XInitExtension</emphasis>
+ directly.
+</para>
+</sect1>
+<sect1 id='determining_library_compatibility'>
+<title>Determining Library Compatibility</title>
+<para>
+If an application is dynamically linked, both the X server and the client-side
+X library must contain the Xkb extension in order for the client to use the Xkb
+extension capabilities. Therefore a dynamically linked application must check
+both the library and the server for compatibility before using Xkb function
+calls. A properly written program must check for compatibility between the
+version of the Xkb library that is dynamically loaded and the one used when the
+application was built. It must then check the server version for compatibility
+with the version of Xkb in the library.
+</para>
+<para>
+If your application is statically linked, you must still check for server
+compatibility and may check library compatibility. (It is possible to compile
+against one set of header files and link against a different, incompatible,
+version of the library, although this should not normally occur.)
+</para>
+<para>
+To determine the compatibility of a library at runtime, call <emphasis>
+XkbLibraryVersion</emphasis>.
+</para>
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbLibraryVersion</emphasis>
+(<emphasis>
+lib_major_in_out</emphasis>
+, <emphasis>
+lib_minor_in_out</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+lib_major_in_out;</emphasis>
+ /* specifies and returns the major Xkb library version. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+lib_minor_in_out;</emphasis>
+ /* specifies and returns the minor Xkb library version. */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+Pass the symbolic value <emphasis>
+XkbMajorVersion</emphasis>
+ in <emphasis>
+lib_major_in_out</emphasis>
+ and <emphasis>
+XkbMinorVersion</emphasis>
+ in <emphasis>
+lib_minor_in_out</emphasis>
+. These arguments represent the version of the library used at compile time.
+The <emphasis>
+XkbLibraryVersion </emphasis>
+function backfills the major and minor version numbers of the library used at
+run time in <emphasis>
+lib_major_in_out</emphasis>
+ and <emphasis>
+lib_minor_in_out</emphasis>
+. If the versions of the compile time and run time libraries are compatible,
+<emphasis>
+XkbLibraryVersion </emphasis>
+returns <emphasis>
+True</emphasis>
+, otherwise, it returns <emphasis>
+False.</emphasis>
+</para>
+
+<para>
+In addition, in order to use the Xkb extension, you must ensure that the
+extension is present in the server and that the server supports the version of
+the extension expected by the client. Use <emphasis>
+XkbQueryExtension</emphasis>
+ to do this, as described in the next section.
+</para>
+
+</sect1>
+<sect1 id='initializing_the_keyboard_extension'>
+<title>Initializing the Keyboard Extension</title>
+<para>
+Call <emphasis>
+XkbQueryExtension</emphasis>
+ to check for the presence and compatibility of the extension in the server and
+to initialize the extension. Because of potential version mismatches, you
+cannot use the generic extension mechanism functions (<emphasis>
+XQueryExtension </emphasis>
+and<emphasis>
+ XInitExtension</emphasis>
+) for checking for the presence of, and initializing the Xkb extension.
+</para>
+
+<para>
+You must call <emphasis>
+XkbQueryExtension</emphasis>
+ or <emphasis>
+XkbOpenDisplay</emphasis>
+ before using any other Xkb library interfaces, unless such usage is explicitly
+allowed in the interface description in this document. The exceptions are:
+<emphasis>
+XkbIgnoreExtension</emphasis>
+, <emphasis>
+XkbLibraryVersion</emphasis>
+, and a handful of audible-bell functions. You should not use any other Xkb
+functions if the extension is not present or is uninitialized. In general,
+calls to Xkb library functions made prior to initializing the Xkb extension
+cause <emphasis>
+BadAccess</emphasis>
+ protocol errors.
+</para>
+
+<para>
+<emphasis>
+XkbQueryExtension</emphasis>
+ both determines whether a compatible Xkb extension is present in the X server
+and initializes the extension when it is present.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbQueryExtension</emphasis>
+(<emphasis>
+dpy, opcode_rtrn, event_rtrn, error_rtrn, major_in_out, minor_in_out</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy; </emphasis>
+ /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+opcode_rtrn</emphasis>
+; /* backfilled with the major extension opcode */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+event_rtrn</emphasis>
+; /* backfilled with the extension base event code */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+error_rtrn</emphasis>
+; /* backfilled with the extension base error code */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+major_in_out</emphasis>
+; /* compile time lib major version in, server major version out */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+minor_in_out; </emphasis>
+ /* compile time lib min version in, server minor version out */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+XkbQueryExtension</emphasis>
+ function determines whether a compatible version of the X Keyboard Extension
+is present in the server. If a compatible extension is present, <emphasis>
+XkbQueryExtension</emphasis>
+ returns <emphasis>
+True</emphasis>
+; otherwise, it returns <emphasis>
+False</emphasis>
+.
+</para>
+
+<para>
+If a compatible version of Xkb is present, <emphasis>
+XkbQueryExtension</emphasis>
+ initializes the extension. It backfills the major opcode for the keyboard
+extension in <emphasis>
+opcode_rtrn</emphasis>
+, the base event code in <emphasis>
+event_rtrn</emphasis>
+<emphasis>
+, the base error code</emphasis>
+ in <emphasis>
+error_rtrn</emphasis>
+, and the major and minor version numbers of the extension in <emphasis>
+major_in_out</emphasis>
+ and <emphasis>
+minor_in_out</emphasis>
+. The major opcode is reported in the <emphasis>
+req_major</emphasis>
+ fields of some Xkb events. For a discussion of the base event code, see
+section 4.1. <!-- xref -->
+</para>
+
+<para>
+As a convenience, you can use the function <emphasis>
+XkbOpenDisplay</emphasis>
+ to perform these three tasks at once: open a connection to an X server, check
+for a compatible version of the Xkb extension in both the library and the
+server, and initialize the extension for use.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Display *<emphasis>
+XkbOpenDisplay</emphasis>
+(<emphasis>
+display_name, event_rtrn, error_rtrn, major_in_out, minor_in_out,
+reason_rtrn)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+display_name</emphasis>
+; /* hardware display name, which determines the display and
+communications domain to be used */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+event_rtrn</emphasis>
+; /* backfilled with the extension base event code */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+error_rtrn</emphasis>
+; /* backfilled with the extension base error code */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+major_in_out</emphasis>
+; /* compile time lib major version in, server major version out */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+minor_in_out</emphasis>
+; /* compile time lib minor version in, server minor version out */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+reason_rtrn</emphasis>
+; /* backfilled with a status code */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbOpenDisplay </emphasis>
+is a convenience function that opens an X display connection and initializes
+the X keyboard extension. In all cases, upon return <emphasis>
+reason_rtrn</emphasis>
+ contains a status value indicating success or the type of failure. If
+<emphasis>
+major_in_out</emphasis>
+ and <emphasis>
+minor_in_out</emphasis>
+ are not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbOpenDisplay</emphasis>
+ first calls <emphasis>
+XkbLibraryVersion</emphasis>
+ to determine whether the client library is compatible, passing it the values
+pointed to by <emphasis>
+major_in_out</emphasis>
+ and <emphasis>
+minor_in_out</emphasis>
+. If the library is incompatible, <emphasis>
+XkbOpenDisplay</emphasis>
+ backfills <emphasis>
+major_in_out</emphasis>
+ and <emphasis>
+minor_in_out</emphasis>
+ with the major and minor extension versions of the library being used and
+returns <emphasis>
+NULL</emphasis>
+. If the library is compatible,<emphasis>
+ XkbOpenDisplay </emphasis>
+next calls <emphasis>
+XOpenDisplay</emphasis>
+ with the <emphasis>
+display_name</emphasis>
+. If this fails, the function returns <emphasis>
+NULL</emphasis>
+. If successful, <emphasis>
+XkbOpenDisplay </emphasis>
+calls <emphasis>
+XkbQueryExtension</emphasis>
+ and<emphasis>
+ </emphasis>
+backfills the major and minor Xkb server extension version numbers in <emphasis>
+major_in_out</emphasis>
+ and <emphasis>
+minor_in_out</emphasis>
+.<emphasis>
+ </emphasis>
+If the server extension version is not compatible with the library extension
+version or if the server extension is not present, <emphasis>
+XkbOpenDisplay </emphasis>
+closes the display and returns <emphasis>
+NULL</emphasis>
+. When successful, the function returns the display connection<emphasis>
+.</emphasis>
+</para>
+
+<para>
+The possible values for <emphasis>
+reason_rtrn</emphasis> are:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+<emphasis>
+XkbOD_BadLibraryVersion</emphasis>
+ indicates <emphasis>
+XkbLibraryVersion </emphasis>
+returned <emphasis>
+False</emphasis>.
+ </para>
+</listitem>
+<listitem>
+ <para>
+<emphasis>
+XkbOD_ConnectionRefused</emphasis>
+ indicates the display could not be opened.
+ </para>
+</listitem>
+<listitem>
+ <para>
+<emphasis>
+XkbOD_BadServerVersion</emphasis>
+ indicates the library and the server have incompatible extension versions.
+ </para>
+</listitem>
+<listitem>
+ <para>
+<emphasis>
+XkbOD_NonXkbServer</emphasis>
+ indicates the extension is not present in the X server.
+ </para>
+</listitem>
+<listitem>
+ <para>
+<emphasis>
+XkbOD_Success</emphasis>
+ indicates that the function succeeded.
+ </para>
+</listitem>
+</itemizedlist>
+</sect1>
+
+<sect1 id='disabling_the_keyboard_extension'>
+<title>Disabling the Keyboard Extension</title>
+<para>
+If a server supports the Xkb extension, the X library normally implements
+preXkb keyboard functions using the Xkb keyboard description and state. The
+server Xkb keyboard state may differ from the preXkb keyboard state. This
+difference does not affect most clients, but there are exceptions. To allow
+these clients to work properly, you may instruct the extension not to use Xkb
+functionality.
+</para>
+
+<para>
+Call <emphasis>
+XkbIgnoreExtension</emphasis>
+ to prevent core X library keyboard functions from using the X Keyboard
+Extension. You must call <emphasis>
+XkbIgnoreExtension</emphasis>
+ before you open a server connection; Xkb does not provide a way to enable or
+disable use of the extension once a connection is established.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool<emphasis>
+ XkbIgnoreExtension</emphasis>
+(<emphasis>
+ignore</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ignore</emphasis>
+; /* <emphasis>
+True</emphasis>
+ means ignore the extension */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbIgnoreExtension</emphasis>
+ tells the X library whether to use the X Keyboard Extension on any
+subsequently opened X display connections. If ignore is <emphasis>
+True</emphasis>
+, the library does not initialize the Xkb extension when it opens a new
+display. This forces the X server to use compatibility mode and communicate
+with the client using only core protocol requests and events. If ignore is
+<emphasis>
+False</emphasis>
+, the library treats subsequent calls to <emphasis>
+XOpenDisplay</emphasis>
+ normally and uses Xkb extension requests, events, and state. Do not explicitly
+use Xkb on a connection for which it is disabled.<emphasis>
+ XkbIgnoreExtension</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if it was unable to apply the ignore request.
+</para>
+
+</sect1>
+<sect1 id='protocol_errors'>
+<title>Protocol Errors</title>
+<para>
+Many of the Xkb extension library functions described in this document can
+cause the X server to report an error, referred to in this document as a
+<emphasis>
+BadXxx</emphasis>
+ protocol error, where <emphasis>
+Xxx</emphasis>
+ is some name. These errors are fielded in the normal manner, by the default
+Xlib error handler or one replacing it. Note that X protocol errors are not
+necessarily reported immediately because of the buffering of X protocol
+requests in Xlib and the server.
+</para>
+
+<para>
+Table 2.1 lists the protocol errors that can be generated, and their causes. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>Xkb Protocol Errors</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='1'>
+ <entry>Error</entry>
+ <entry>Cause</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>BadAccess</entry>
+ <entry>
+<para>
+The Xkb extension has not been properly initialized
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadKeyboard</entry>
+ <entry>
+<para>
+The device specified was not a valid core or input extension device
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadImplementation</entry>
+ <entry>
+<para>
+Invalid reply from server
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadAlloc</entry>
+ <entry>
+<para>
+Unable to allocate storage
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadMatch</entry>
+ <entry>
+<para>
+A compatible version of Xkb was not available in the server or an argument has
+correct type and range, but is otherwise invalid
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadValue</entry>
+ <entry>
+<para>
+An argument is out of range
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadAtom</entry>
+ <entry>
+<para>
+A name is neither a valid Atom or <emphasis>
+None</emphasis>
+</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BadDevice</entry>
+ <entry>
+<para>
+Device, Feedback Class, or Feedback ID invalid
+</para>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The Xkb extension adds a single protocol error, <emphasis>
+BadKeyboard</emphasis>
+, to the core protocol error set. This error code will be reported as the
+<emphasis>
+error_rtrn</emphasis>
+ when <emphasis>
+XkbQueryExtension</emphasis>
+ is called. When a <emphasis>
+BadKeyboard</emphasis>
+ error is reported in an <emphasis>
+XErrorEvent</emphasis>
+, additional information is reported in the <emphasis>
+resource_id</emphasis>
+ field. The most significant byte of the <emphasis>
+resource_id</emphasis>
+ is a further refinement of the error cause, as defined in Table 2.2. The least
+significant byte will contain the device, class, or feedback ID as indicated in
+the table.
+</para>
+
+<table frame='none'>
+<title>BadKeyboard Protocol Error resource_id Values</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='0'>
+ <entry>high-order byte</entry>
+ <entry>value</entry>
+ <entry>meaning</entry>
+ <entry>low-order byte</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbErr_BadDevice</entry>
+ <entry>0xff</entry>
+ <entry>
+<para>
+device not found
+</para>
+ </entry>
+ <entry>device ID</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbErr_BadClass</entry>
+ <entry>0xfe</entry>
+ <entry>
+<para>
+device found, but it is of the wrong class
+</para>
+ </entry>
+ <entry>class ID</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbErr_BadId</entry>
+ <entry>0xfd</entry>
+ <entry>
+<para>
+device found, class ok, but device does not contain a feedback with the
+indicated ID
+</para>
+ </entry>
+ <entry>feedback ID</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+</sect1>
+
+<sect1 id='display_and_device_specifications_in_function_calls'>
+<title>Display and Device Specifications in Function Calls</title>
+<para>
+Where a connection to the server is passed as an argument (Display*) and an
+<emphasis>
+XkbDescPtr</emphasis>
+ is also passed as an argument, the Display* argument must match the <emphasis>
+dpy</emphasis>
+ field of the <emphasis>
+XkbDescRec</emphasis>
+ pointed to by the <emphasis>
+XkbDescPtr</emphasis>
+ argument, or else the <emphasis>
+dpy</emphasis>
+ field of the <emphasis>
+XkbDescRec</emphasis>
+ must be <emphasis>
+NULL</emphasis>
+. If they don’t match or the <emphasis>
+dpy</emphasis>
+ field is not <emphasis>
+NULL</emphasis>
+, a <emphasis>
+BadMatch</emphasis>
+ error is returned (either in the return value or a backfilled <emphasis>
+Status</emphasis>
+ variable). Upon successful return, the <emphasis>
+dpy</emphasis>
+ field of the <emphasis>
+XkbDescRec</emphasis>
+ always contains the Display* value passed in.
+</para>
+
+<para>
+The Xkb extension can communicate with the X input extension if it is present.
+Consequently, there can potentially be more than one input device connected to
+the server. Most Xkb library calls that require communicating with the server
+involve both a server connection (Display * <emphasis>
+dpy</emphasis>
+) and a device identifier (unsigned int <emphasis>
+device_spec</emphasis>
+). In some cases, the device identifier is implicit and is taken as the
+<emphasis>
+device_spec</emphasis>
+ field of an <emphasis>
+XkbDescRec</emphasis>
+ structure passed as an argument.
+</para>
+
+<para>
+The device identifier can specify any X input extension device with a <emphasis>
+KeyClass</emphasis>
+ component, or it can specify the constant, <emphasis>
+XkbUseCoreKbd</emphasis>
+. The use of <emphasis>
+XkbUseCoreKbd</emphasis>
+ allows applications to indicate the core keyboard without having to determine
+its device identifier.
+</para>
+
+<para>
+Where an Xkb device identifier is passed as an argument and an <emphasis>
+XkbDescPtr</emphasis>
+ is also passed as an argument, if either the argument or the <emphasis>
+XkbDescRec</emphasis>
+ <emphasis>
+device_spec</emphasis>
+ field is <emphasis>
+XkbUseCoreKbd</emphasis>
+, and if the function returns successfully, the <emphasis>
+XkbDescPtr</emphasis>
+ <emphasis>
+device_spec</emphasis>
+ field will have been converted from <emphasis>
+XkbUseCoreKbd</emphasis>
+ to a real Xkb device ID. If the function does not complete successfully, the
+<emphasis>
+device_spec</emphasis>
+ field remains unchanged. Subsequently, the device id argument must match the
+<emphasis>
+device_spec</emphasis>
+ field of the <emphasis>
+XkbDescPtr</emphasis>
+ argument. If they don’t match, a <emphasis>
+BadMatch</emphasis>
+ error is returned (either in the return value or a backfilled <emphasis>
+Status</emphasis>
+ variable).
+</para>
+
+<para>
+When the Xkb extension in the server hands an application a device identifier
+to use for the keyboard, that ID is the input extension identifier for the
+device if the server supports the X Input Extension. If the server does not
+support the input extension, the meaning of the identifier is undefined — the
+only guarantee is that when you use <emphasis>
+XkbUseCoreKbd</emphasis>
+, <emphasis>
+XkbUseCoreKbd</emphasis>
+ will work and the identifier returned by the server will refer to the core
+keyboard device.
+</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch03.xml b/libX11/specs/XKB/ch03.xml
new file mode 100644
index 000000000..5ea411c4e
--- /dev/null
+++ b/libX11/specs/XKB/ch03.xml
@@ -0,0 +1,247 @@
+<chapter id='data_structures'>
+<title>Data Structures</title>
+
+<para>
+An Xkb keyboard description consists of a variety of data structures, each of
+which describes some aspect of the keyboard. Although each data structure has
+its own peculiarities, there are a number of features common to nearly all Xkb
+structures. This chapter describes these common features and techniques for
+manipulating them.
+</para>
+
+
+<para>
+Many Xkb data structures are interdependent; changing a field in one might
+require changes to others. As an additional complication, some Xkb library
+functions allocate related components as a group to reduce fragmentation and
+allocator overhead. In these cases, simply allocating and freeing fields of Xkb
+structures might corrupt program memory. Creating and destroying such
+structures or keeping them properly synchronized during editing is complicated
+and error prone.
+</para>
+
+
+<para>
+Xkb provides functions and macros to allocate and free all major data
+structures. You should use them instead of allocating and freeing the
+structures yourself.
+</para>
+
+<sect1 id='allocating_xkb_data_structures'>
+<title>Allocating Xkb Data Structures</title>
+
+<para>
+Xkb provides functions, known as allocators, to create and initialize Xkb data
+structures. In most situations, the Xkb functions that read a keyboard
+description from the server call these allocators automatically. As a result,
+you will seldom have to directly allocate or initialize Xkb data structures.
+</para>
+
+
+<para>
+However, if you need to enlarge an existing structure or construct a keyboard
+definition from scratch, you may need to allocate and initialize Xkb data
+structures directly. Each major Xkb data structure has its own unique
+allocator. The allocator functions share common features: allocator functions
+for structures with optional components take as an input argument a mask of
+subcomponents to be allocated. Allocators for data structures containing
+variable-length data take an argument specifying the initial length of the data.
+</para>
+
+
+<para>
+You may call an allocator to change the size of the space allocated for
+variable-length data. When you call an allocator with an existing data
+structure as a parameter, the allocator does not change the data in any of the
+fields, with one exception: variable-length data might be moved. The allocator
+resizes the allocated memory if the current size is too small. This normally
+involves allocating new memory, copying existing data to the newly allocated
+memory, and freeing the original memory. This possible reallocation is
+important to note because local variables pointing into Xkb data structures
+might be invalidated by calls to allocator functions.
+</para>
+
+</sect1>
+<sect1 id='adding_data_and_editing_data_structures'>
+<title>Adding Data and Editing Data Structures</title>
+
+<para>
+You should edit most data structures via the Xkb-supplied helper functions and
+macros, although a few data structures can be edited directly. The helper
+functions and macros make sure everything is initialized and interdependent
+values are properly updated for those Xkb structures that have
+interdependencies. As a general rule, if there is a helper function or macro to
+edit the data structure, use it. For example, increasing the width of a type
+requires you to resize every key that uses that type. This is complicated and
+ugly, which is why there’s an <emphasis>
+XkbResizeKeyType</emphasis>
+ function.
+</para>
+
+
+<para>
+Many Xkb data structures have arrays whose size is reported by two fields. The
+first field, whose name is usually prefixed by <emphasis>
+sz_</emphasis>
+, represents the total number of elements that can be stored in the array. The
+second field, whose name is usually prefixed by <emphasis>
+num_</emphasis>
+, specifies the number of elements currently stored there. These arrays
+typically represent data whose total size cannot always be determined when the
+array is created. In these instances, the usual way to allocate space and add
+data is as follows:
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+Call the allocator function with some arbitrary size, as a hint.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+For those arrays that have an <emphasis>
+Xkb...Add...</emphasis>
+ function, call it each time you want to add new data to the array. The
+function expands the array if necessary.
+ </para>
+ </listitem>
+</itemizedlist>
+
+<para>
+For example, call:
+</para>
+
+<para>
+XkbAllocGeomShapes(geom,4)
+</para>
+
+<para>
+to say "I’ll need space for four new shapes in this geometry." This makes
+sure that <emphasis>
+sz_shapes</emphasis>
+ - <emphasis>
+num_shapes</emphasis>
+ &gt;= 4, and resizes the shapes array if it isn’t. If this function
+succeeds, you are guaranteed to have space for the number of shapes you need.
+</para>
+
+
+<para>
+When you call an editing function for a structure, you do not need to check for
+space, because the function automatically checks the <emphasis>
+sz_</emphasis>
+ and <emphasis>
+num_</emphasis>
+ fields of the array, resizes the array if necessary, adds the entry to the
+array, and then updates the <emphasis>
+num_</emphasis>
+ field.
+</para>
+
+
+</sect1>
+<sect1 id='making_changes_to_the_servers_keyboard_description'>
+<title>Making Changes to the Server’s Keyboard Description</title>
+
+<para>
+In Xkb, as in the core protocol, the client and server have independent copies
+of the data structures that describe the keyboard. The recommended way to
+change some aspect of the keyboard mapping in the X server is to edit a local
+copy of the Xkb keyboard description and then send only the changes to the X
+server. This method helps eliminate the need to transfer the entire keyboard
+description or even an entire data structure for only minor changes.
+</para>
+
+
+<para>
+To help you keep track of the changes you make to a local copy of the keyboard
+description, Xkb provides separate special <emphasis>
+changes</emphasis>
+ data structures for each major Xkb data structure. These data structures do
+not contain the actual changed values: they only indicate the changes that have
+been made to the structures that actually describe the keyboard.
+</para>
+
+
+<para>
+When you wish to change the keyboard description in the server, you first
+modify a local copy of the keyboard description and then flag the modifications
+in an appropriate changes data structure. When you finish editing the local
+copy of the keyboard description, you pass your modified version of the
+keyboard description and the modified changes data structure to an Xkb
+function. This function uses the modified keyboard description and changes
+structure to pass only the changed information to the server. Note that
+modifying the keyboard description but not setting the appropriate flags in the
+changes data structure causes indeterminate behavior.
+</para>
+
+
+</sect1>
+<sect1 id='tracking_keyboard_changes_in_the_server'>
+<title>Tracking Keyboard Changes in the Server</title>
+
+<para>
+The server reports all changes in its keyboard description to any interested
+clients via special Xkb events. Just as clients use special changes data
+structures to change the keyboard description in the server, the server uses
+special changes data structures to tell a client what changed in the server’s
+keyboard description.
+</para>
+
+
+<para>
+Unlike clients, however, the server does not always pass the new values when it
+reports changes to its copy of the keyboard description. Instead, the server
+only passes a changes data structure when it reports changes to its keyboard
+description. This is done for efficiency reasons — some clients do not always
+need to update their copy of the keyboard description with every report from
+the server.
+</para>
+
+
+<para>
+When your client application receives a report from the server indicating the
+keyboard description has changed, you can determine the set of changes by
+passing the event to an Xkb function that "notes" event information in the
+corresponding changes data structure. These "note changes" functions are
+defined for all major Xkb components, and their names have the form <emphasis>
+XkbNote{Component}Changes</emphasis>
+, where <emphasis>
+Component</emphasis>
+ is the name of a major Xkb component such as <emphasis>
+Map</emphasis>
+ or <emphasis>
+Names</emphasis>
+. When you want to copy these changes from the server into a local copy of the
+keyboard description, use the corresponding <emphasis>
+XkbGet{Component}Changes</emphasis>
+ function<emphasis>
+, </emphasis>
+passing it the changes structure. The function then retrieves only the changed
+structures from the server and copies the modified pieces into the local
+keyboard description.
+</para>
+
+</sect1>
+<sect1 id='freeing_data_structures'>
+<title>Freeing Data Structures</title>
+
+<para>
+For the same reasons you should not directly use <emphasis>
+malloc</emphasis>
+ to allocate Xkb data structures, you should not free Xkb data structures or
+components directly using <emphasis>
+free</emphasis>
+ or <emphasis>
+Xfree</emphasis>
+. Xkb provides functions to free the various data structures and their
+components. Always use the free functions supplied by Xkb. There is no
+guarantee that any particular field can be safely freed by <emphasis>
+free</emphasis>
+ or <emphasis>
+Xfree</emphasis>
+.
+</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch04.xml b/libX11/specs/XKB/ch04.xml
new file mode 100644
index 000000000..dc9065d79
--- /dev/null
+++ b/libX11/specs/XKB/ch04.xml
@@ -0,0 +1,825 @@
+<chapter id='xkb_events'>
+<title>Xkb Events</title>
+
+<para>
+The primary way the X server communicates with clients is by sending X events
+to them. Some events are sent to all clients, while others are sent only to
+clients that have requested them. Some of the events that can be requested are
+associated with a particular window and are only sent to those clients who have
+both requested the event and specified the window in which the event occurred.
+</para>
+
+
+<para>
+The Xkb extension uses events to communicate the keyboard status to interested
+clients. These events are not associated with a particular window. Instead, all
+Xkb keyboard status events are reported to all interested clients, regardless
+of which window currently has the keyboard focus and regardless of the grab
+state of the keyboard.<footnote><para>The one exception to this rule is the
+XkbExtensionDeviceNotify event report that is sent when a client attempts to
+use an unsupported feature of an X Input Extension device (see section 21.4).
+</para></footnote> <!-- xref -->
+</para>
+
+
+<para>
+The X server reports the events defined by the Xkb extension to your client
+application only if you have requested them. You may request Xkb events by
+calling either <emphasis>
+XkbSelectEvents</emphasis>
+ or <emphasis>
+XkbSelectEventDetails</emphasis>
+. <emphasis>
+XkbSelectEvents</emphasis>
+ requests Xkb events by their event type and causes them to be reported to your
+client application under all circumstances. You can specify a finer granularity
+for event reporting by using <emphasis>
+XkbSelectEventDetails</emphasis>
+; in this case events are reported only when the specific detail conditions you
+specify have been met.
+</para>
+
+<sect1 id='xkb_event_types'>
+<title>Xkb Event Types</title>
+
+<para>
+The Xkb Extension adds new event types to the X protocol definition. An Xkb
+event type is defined by two fields in the X event data structure. One is the
+<emphasis>
+type</emphasis>
+ field, containing the <emphasis>
+base event code.</emphasis>
+ This base event code is a value the X server assigns to each X extension at
+runtime and thatidentifies the extension that generated the event; thus, the
+event code in the <emphasis>
+type</emphasis>
+ field identifies the event as an Xkb extension event, rather than an event
+from another extension or a core X protocol event. You can obtain the base
+event code via a call to <emphasis>
+XkbQueryExtension</emphasis>
+ or <emphasis>
+XkbOpenDisplay</emphasis>
+. The second field is the Xkb event type, which contains a value uniquely
+identifying each different Xkb event type. Possible values are defined by
+constants declared in the header file &lt;X11/extensions/Xkb.h&gt;.
+</para>
+
+
+<para>
+Table 4.1 lists the categories of events defined by Xkb and their associated
+event types, as defined in <emphasis>
+Xkb.h</emphasis>
+. Each event is described in more detail in the section referenced for that
+event.
+</para>
+
+<table frame='none'>
+<title>Xkb Event Types</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Event Type</entry>
+ <entry>Conditions Generating Event</entry>
+ <entry>Section</entry>
+ <entry>Page</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbNewKeyboardNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard geometry; keycode range change</para>
+ </entry>
+ <entry>
+ <para>19</para>
+ </entry>
+ <entry>
+ <para>187</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para>
+ <emphasis>XkbMapNotify</emphasis>
+ </para>
+ </entry>
+ <entry>
+ <para>Keyboard mapping change</para>
+ </entry>
+ <entry>
+ <para>14.4</para>
+ </entry>
+ <entry>
+ <para>122</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbStateNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard state change</para>
+ </entry>
+ <entry>
+ <para>5.4</para>
+ </entry>
+ <entry>
+ <para>25</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbControlsNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard controls state change</para>
+ </entry>
+ <entry>
+ <para>10.11</para>
+ </entry>
+ <entry>
+ <para>79</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbIndicatorStateNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard indicators state change</para>
+ </entry>
+ <entry>
+ <para>8.5</para>
+ </entry>
+ <entry>
+ <para>45</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbIndicatorMapNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard indicators map change</para>
+ </entry>
+ <entry>
+ <para>8.5</para>
+ </entry>
+ <entry>
+ <para>45</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbNamesNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard name change</para>
+ </entry>
+ <entry>
+ <para>18.5</para>
+ </entry>
+ <entry>
+ <para>185</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbCompatMapNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard compatibility map change</para>
+ </entry>
+ <entry>
+ <para>17.5</para>
+ </entry>
+ <entry>
+ <para>178</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbBellNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard bell generated</para>
+ </entry>
+ <entry>
+ <para>9.4</para>
+ </entry>
+ <entry>
+ <para>52</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbActionMessage</emphasis></para>
+ </entry>
+ <entry>
+ <para>Keyboard action message</para>
+ </entry>
+ <entry>
+ <para>16.1.11</para>
+ </entry>
+ <entry>
+ <para>155</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbAccessXNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>AccessX state change</para>
+ </entry>
+ <entry>
+ <para>10.6.4</para>
+ </entry>
+ <entry>
+ <para>65</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>
+ <para><emphasis>XkbExtensionDeviceNotify</emphasis></para>
+ </entry>
+ <entry>
+ <para>Extension device change</para>
+ </entry>
+ <entry>
+ <para>21.6</para>
+ </entry>
+ <entry>
+ <para>207</para>
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='xkb_event_data_structures'>
+<title>Xkb Event Data Structures</title>
+
+<para>
+Xkb reports each event it generates in a unique structure holding the data
+values needed to describe the conditions the event is reporting. However, all
+Xkb events have certain things in common. These common features are contained
+in the same fields at the beginning of all Xkb event structures and are
+described in the <emphasis>
+XkbAnyEvent</emphasis>
+ structure:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event
+generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* Xkb minor event code */
+ unsigned int device; /* Xkb device ID, will not be
+ <emphasis>XkbUseCoreKbd</emphasis> */
+} <emphasis>XkbAnyEvent</emphasis>
+;
+</programlisting></para>
+
+<para>
+For any Xkb event, the <emphasis>
+type</emphasis>
+ field is set to the base event code for the Xkb extension, assigned by the
+server to all Xkb extension events. The <emphasis>
+serial</emphasis>
+, <emphasis>
+send_event</emphasis>
+, and <emphasis>
+display</emphasis>
+ fields are as described for all X11 events. The <emphasis>
+time</emphasis>
+ field is set to the time when the event was generated and is expressed in
+milliseconds. The <emphasis>
+xkb_type</emphasis>
+ field contains the minor extension event code, which is the extension event
+type, and is one of the values listed in Table 4.1. The <emphasis>
+device</emphasis>
+ field contains the keyboard device identifier associated with the event. This
+is never <emphasis>
+XkbUseCoreKbd</emphasis>
+, even if the request that generated the event specified a device of <emphasis>
+XkbUseCoreKbd</emphasis>
+. If the request that generated the event specified <emphasis>
+XkbUseCoreKbd</emphasis>
+, <emphasis>
+device</emphasis>
+ contains a value assigned by the server to specify the core keyboard. If the
+request that generated the event specified an X input extension device,
+<emphasis>
+device</emphasis>
+ contains that same identifier.
+</para>
+
+
+<para>
+Other data fields specific to individual Xkb events are described in subsequent
+chapters where the events are described.
+</para>
+
+
+</sect1>
+<sect1 id='selecting_xkb_events'>
+<title>Selecting Xkb Events</title>
+
+<para>
+Xkb events are selected using an event mask, much the same as normal core X
+events are selected. However, unlike selecting core X events, where you must
+specify the selection status (on or off) for all possible event types whenever
+you wish to change the selection criteria for any one event, Xkb allows you to
+restrict the specification to only the event types you wish to change. This
+means that you do not need to remember the event selection values for all
+possible types each time you want to change one of them.
+</para>
+
+
+<para>
+Many Xkb event types are generated under several different circumstances. When
+selecting to receive an Xkb event, you may specify either that you want it
+delivered under all circumstances, or that you want it delivered only for a
+subset of the possible circumstances.
+</para>
+
+<para>
+You can also deselect an event type that was previously selected for, using the
+same granularity.
+</para>
+
+<para>
+Xkb provides two functions to select and deselect delivery of Xkb events.
+<emphasis>
+XkbSelectEvents</emphasis>
+ allows you to select or deselect delivery of more than one Xkb event type at
+once. Events selected using <emphasis>
+XkbSelectEvents</emphasis>
+ are delivered to your program under all circumstances that generate the
+events. To restrict delivery of an event to a subset of the conditions under
+which it occurs, use <emphasis>
+XkbSelectEventDetails</emphasis>
+. <emphasis>
+XkbSelectEventDetails</emphasis>
+ only allows you to change the selection conditions for a single event at a
+time, but it provides a means of fine-tuning the conditions under which the
+event is delivered.
+</para>
+
+
+<para>
+To select and / or deselect for delivery of one or more Xkb events and have
+them delivered under all conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSelectEvents</emphasis>
+(<emphasis>
+display, device_spec, bits_to_change, values_for_bits</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long int <emphasis>
+bits_to_change; </emphasis>
+/* determines events to be selected / deselected */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long int <emphasis>
+values_for_bits</emphasis>
+; /* 1=&gt;select, 0-&gt;deselect; for events in <emphasis>
+bits_to_change</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+This request changes the Xkb event selection mask for the keyboard specified by
+<emphasis>
+device_spec</emphasis>
+.
+</para>
+
+
+<para>
+Each Xkb event that can be selected is represented by a bit in the <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ masks. Only the event selection bits specified by the <emphasis>
+bits_to_change</emphasis>
+ parameter are affected; any unspecified bits are left unchanged. To turn on
+event selection for an event, set the bit for the event in the <emphasis>
+bits_to_change</emphasis>
+ parameter and set the corresponding bit in the <emphasis>
+values_for_bits</emphasis>
+ parameter. To turn off event selection for an event, set the bit for the event
+in the <emphasis>
+bits_to_change</emphasis>
+ parameter and do not set the corresponding bit in the <emphasis>
+values_for_bits</emphasis>
+ parameter. The valid values for both of these parameters are an inclusive
+bitwise OR of the masks shown in Table 4.2. There is no interface to return
+your client’s current event selection mask. Clients cannot set other
+clients’ event selection masks.
+</para>
+
+
+<para>
+If a bit is not set in the <emphasis>
+bits_to_change</emphasis>
+ parameter, but the corresponding bit is set in the <emphasis>
+values_for_bits</emphasis>
+ parameter, a <emphasis>
+BadMatch</emphasis>
+ protocol error results. If an undefined bit is set in either the <emphasis>
+bits_to_change</emphasis>
+ or the <emphasis>
+values_for_bits</emphasis>
+ parameter, a <emphasis>
+BadValue</emphasis>
+ protocol error results.
+</para>
+
+
+<para>
+All event selection bits are initially zero for clients using the Xkb
+extension. Once you set some bits, they remain set for your client until you
+clear them via another call to <emphasis>
+XkbSelectEvents</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbSelectEvents</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if the Xkb extension has not been initilialized and <emphasis>
+True</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To select or deselect for a specific Xkb event and optionally place conditions
+on when events of that type are reported to your client, use <emphasis>
+XkbSelectEventDetails</emphasis>
+. This allows you to exercise a finer granularity of control over delivery of
+Xkb events with <emphasis>
+XkbSelectEvents</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSelectEventDetails</emphasis>
+(<emphasis>
+display, device_spec, event_type, bits_to_change</emphasis>
+, <emphasis>
+values_for_bits</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+event_type</emphasis>
+; /* Xkb event type of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long int <emphasis>
+bits_to_change</emphasis>
+; /* event selection details */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long int <emphasis>
+values_for_bits</emphasis>
+; /* values for bits selected by <emphasis>
+bits_to_change</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+While <emphasis>
+XkbSelectEvents</emphasis>
+ allows multiple events to be selected, <emphasis>
+XkbSelectEventDetails</emphasis>
+ changes the selection criteria for a single type of Xkb event. The
+interpretation of the <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ masks depends on the event type in question.
+</para>
+
+
+<para>
+<emphasis>
+XkbSelectEventDetails</emphasis>
+ changes the Xkb event selection mask for the keyboard specified by <emphasis>
+device_spec</emphasis>
+ and the Xkb event specified by <emphasis>
+event_type</emphasis>
+. To turn on event selection for an event detail, set the bit for the detail in
+the <emphasis>
+bits_to_change</emphasis>
+ parameter and set the corresponding bit in the <emphasis>
+values_for_bits</emphasis>
+ parameter. To turn off event detail selection for a detail, set the bit for
+the detail in the <emphasis>
+bits_to_change</emphasis>
+ parameter and do not set the corresponding bit in the <emphasis>
+values_for_bits</emphasis>
+ parameter.
+</para>
+
+
+<para>
+If an invalid event type is specified, a <emphasis>
+BadValue</emphasis>
+ protocol error results. If a bit is not set in the <emphasis>
+bits_to_change</emphasis>
+ parameter, but the corresponding bit is set in the <emphasis>
+values_for_bits</emphasis>
+ parameter, a <emphasis>
+BadMatch</emphasis>
+ protocol error results. If an undefined bit is set in either the <emphasis>
+bits_to_change</emphasis>
+ or the <emphasis>
+values_for_bits</emphasis>
+ parameter, a <emphasis>
+BadValue</emphasis>
+ protocol error results.
+</para>
+
+
+<para>
+For each type of Xkb event, the legal event details that you can specify in the
+<emphasis>
+XkbSelectEventDetails</emphasis>
+ request are listed in the chapters that describe each event in detail.
+</para>
+
+
+<sect2 id='event_masks'>
+<title>Event Masks</title>
+
+<para>
+The X server reports the events defined by Xkb to your client application only
+if you have requested them via a call to <emphasis>
+XkbSelectEvents</emphasis>
+ or <emphasis>
+XkbSelectEventDetails</emphasis>
+. Specify the event types in which you are interested in a mask, as described
+in section 4.3.
+</para>
+
+
+<para>
+Table 4.2 lists the event mask constants that can be specified with the <!-- xref -->
+<emphasis>
+XkbSelectEvents</emphasis>
+ request and the circumstances in which the mask should be specified.
+</para>
+
+<table frame='none'>
+<title>XkbSelectEvents Mask Constants</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Event Mask</entry>
+ <entry>Value</entry>
+ <entry>Notification Wanted</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbNewKeyboardNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;0)</entry>
+ <entry>Keyboard geometry change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+ <emphasis>XkbMapNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;1)</entry>
+ <entry>Keyboard mapping change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbStateNotifyMask</emphasis></para>
+ </entry>
+ <entry>(1L&lt;&lt;2)</entry>
+ <entry><para>Keyboard state change</para></entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbControlsNotifyMask</emphasis></para>
+ </entry>
+ <entry>(1L&lt;&lt;3)</entry>
+ <entry>Keyboard control change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbIndicatorStateNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;4)</entry>
+ <entry>Keyboard indicator state change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbIndicatorMapNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;5)</entry>
+ <entry>Keyboard indicator map change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbNamesNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;6)</entry>
+ <entry>Keyboard name change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbCompatMapNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;7)</entry>
+ <entry>Keyboard compat map change</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbBellNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;8)</entry>
+ <entry>Bell</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbActionMessageMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;9)</entry>
+ <entry>Action message</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbAccessXNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;10)</entry>
+ <entry>AccessX features</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbExtensionDeviceNotifyMask</emphasis>
+ </entry>
+ <entry>(1L&lt;&lt;11)</entry>
+ <entry>Extension device</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<emphasis>XkbAllEventsMask</emphasis>
+ </entry>
+ <entry>(0xFFF)</entry>
+ <entry>All Xkb events</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect2>
+</sect1>
+<sect1 id='unified_xkb_event_type'>
+<title>Unified Xkb Event Type</title>
+
+<para>
+The <emphasis>
+XkbEvent</emphasis>
+ structure is a union of the individual structures declared for each Xkb event
+type and for the core protocol <emphasis>
+XEvent</emphasis>
+ type. Given an <emphasis>
+XkbEvent</emphasis>
+ structure, you may use the <emphasis>
+type</emphasis>
+ field to determine if the event is an Xkb event (<emphasis>
+type</emphasis>
+ equals the Xkb base event code; see section 2.4). If the event is an Xkb
+event, you may then use the <emphasis>
+any.xkb_type</emphasis>
+ field to determine the type of Xkb event and thereafter access the
+event-dependent components using the union member corresponding to the
+particular Xkb event type.
+</para>
+
+<para><programlisting>
+typedef union _XkbEvent {
+ int type;
+ XkbAnyEvent any;
+ XkbStateNotifyEvent state;
+ XkbMapNotifyEvent map;
+ XkbControlsNotifyEvent ctrls;
+ XkbIndicatorNotifyEvent indicators;
+ XkbBellNotifyEvent bell;
+ XkbAccessXNotifyEvent accessx;
+ XkbNamesNotifyEvent names;
+ XkbCompatMapNotifyEvent compat;
+ XkbActionMessageEvent message;
+ XkbExtensionDeviceNotifyEvent device;
+ XkbNewKeyboardNotifyEvent new_kbd;
+ XEvent core;
+} <emphasis>XkbEvent</emphasis>;
+</programlisting></para>
+
+<para>
+This unified Xkb event type includes a normal <emphasis>
+XEvent</emphasis>
+ as used by the core protocol, so it is straightforward for applications that
+use Xkb events to call the X library event functions without having to cast
+every reference. For example, to get the next event, you can simply declare a
+variable of type <emphasis>
+XkbEvent</emphasis>
+ and call:
+</para>
+
+<para>XNextEvent(dpy,&amp;xkbev.core);</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch05.xml b/libX11/specs/XKB/ch05.xml
new file mode 100644
index 000000000..3785c44d7
--- /dev/null
+++ b/libX11/specs/XKB/ch05.xml
@@ -0,0 +1,977 @@
+<chapter id='keyboard_state'>
+<title>Keyboard State</title>
+
+<para>
+Keyboard state encompasses all of the transitory information necessary to map a physical key press or release to an appropriate event. The Xkb keyboard state consists of primitive components and additional derived components that are maintained for efficiency reasons. Figure 5.1 shows the components of Xkb keyboard state and their relationships.
+</para>
+
+<mediaobject>
+<!-- <title>Keyboard State Description</title> -->
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-2.svg"/>
+ </imageobject>
+<caption>Xkb State</caption>
+</mediaobject>
+
+
+<sect1 id='keyboard_state_description'>
+<title>Keyboard State Description</title>
+<para>
+The Xkb keyboard state is comprised of the state of all keyboard modifiers, the keyboard group, and the state of the pointer buttons. These are grouped into the following components:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The locked group and locked modifiers
+ </para>
+</listitem>
+<listitem>
+ <para>
+The latched group and latched modifiers
+ </para>
+</listitem>
+<listitem>
+ <para>
+The base group and base modifiers
+ </para>
+</listitem>
+<listitem>
+ <para>
+The effective group and effective modifiers
+ </para>
+</listitem>
+<listitem>
+ <para>
+The state of the core pointer buttons
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The <emphasis>
+modifiers</emphasis>
+ are <emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, <emphasis>
+Control</emphasis>
+, and <emphasis>
+Mod1</emphasis>
+-<emphasis>
+Mod5</emphasis>
+, as defined by the core protocol. A modifier can be thought of as a toggle that is either set or unset. All modifiers are initially unset. When a modifier is locked, it is set and remains set for all future key events, until it is explicitly unset. A latched modifier is set, but automatically unsets after the next key event that does not change the keyboard state. Locked and latched modifier state can be changed by keyboard activity or via Xkb extension library functions.
+</para>
+
+
+<para>
+The Xkb extension provides support for <emphasis>
+keysym</emphasis>
+ <emphasis>
+groups</emphasis>
+, as defined by ISO9995:
+</para>
+
+
+<variablelist>
+ <varlistentry>
+ <term>Group</term>
+ <listitem>
+ <para>
+A logical state of a keyboard providing access to a collection of characters.
+A group usually contains a set of characters that logically belong together
+and that may be arranged on several shift levels within that group.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+
+
+<para>
+The Xkb extension supports up to four keysym groups. Groups are named beginning with one and indexed beginning with zero. All group states are indicated using the group index. At any point in time, there is zero or one locked group, zero or one latched group, and one base group. When a group is locked, it supersedes any previous locked group and remains the locked group for all future key events, until a new group is locked. A latched group applies only to the next key event that does not change the keyboard state. The locked and latched group can be changed by keyboard activity or via Xkb extension library functions.
+</para>
+
+
+<para>
+Changing to a different group changes the keyboard state to produce characters from a different group. Groups are typically used to switch between keysyms of different languages and locales.
+</para>
+
+
+<para>
+The <emphasis>
+pointer buttons</emphasis>
+ are <emphasis>
+Button1</emphasis>
+ - <emphasis>
+Button5</emphasis>
+, as defined by the core protocol.
+</para>
+
+
+<para>
+The <emphasis>
+base group</emphasis>
+ and <emphasis>
+base modifiers</emphasis>
+ represent keys that are physically or logically down. These
+and the pointer buttons can be changed by keyboard activity and
+not by Xkb requests. It is possible for a key to be logically
+down, but not physically down, and neither latched nor locked.
+<footnote><para>
+Keys may be logically down when they are physically up because
+of their electrical properties or because of the keyboard extension
+in the X server having filtered the key release, for esoteric reasons.
+</para></footnote>
+
+</para>
+
+
+<para>
+The <emphasis>
+effective modifiers</emphasis>
+ are the bitwise union of the locked, latched, and the base modifiers.
+</para>
+
+
+<para>
+The <emphasis>
+effective group</emphasis>
+ is the arithmetic sum of the group indices of the latched group, locked group, and base group, which is then normalized by some function. The result is a meaningful group index.
+</para>
+
+<simplelist type='vert' columns='1'>
+<member>
+n = number of keyboard groups, 1&lt;= n &lt;= 4
+</member>
+
+<member>
+0 &lt;= any of locked, latched, or base group &lt; n
+</member>
+
+<member>
+effective group = f(locked group + latched group + base group)
+</member>
+</simplelist>
+
+<para>
+The function f ensures that the effective group is within range. The precise function is specified for the keyboard and can be retrieved through the keyboard description. It may wrap around, clamp down, or default. Few applications will actually examine the effective group, and far fewer still will examine the locked, latched, and base groups.
+</para>
+
+
+<para>
+There are two circumstances under which groups are normalized:
+</para>
+
+<orderedlist>
+ <listitem><para>
+The global locked or effective group changes. In this case, the changed group is normalized into range according to the settings of the <emphasis>
+groups_wrap</emphasis>
+ field of the <emphasis>
+XkbControlsRec</emphasis>
+ structure for the keyboard (see section 10.7.1). <!-- xref -->
+ </para></listitem>
+ <listitem><para>
+
+The Xkb library is interpreting an event with an effective group that is legal for the keyboard as a whole, but not for the key in question. In this case, the group to use for this event only is determined using the <emphasis>
+group_info</emphasis>
+ field of the key symbol mapping (<emphasis>
+XkbSymMapRec</emphasis>
+) for the event key.
+ </para></listitem>
+</orderedlist>
+
+<para>
+Each nonmodifier key on a keyboard has zero or more symbols, or keysyms, associated with it. These are the logical symbols that the key can generate when it is pressed. The set of all possible keysyms for a keyboard is divided into groups. Each key is associated with zero or more groups; each group contains one or more symbols. When a key is pressed, the determination of which symbol for the key is selected is based on the effective group and the shift level, which is determined by which modifiers are set.
+</para>
+
+
+<para>
+A client that does not explicitly call Xkb functions, but that otherwise makes use of an X library containing the Xkb extension, will have keyboard state represented in bits 0 - 14 of the state field of events that report modifier and button state. Such a client is said to be <emphasis>
+Xkb-capable</emphasis>
+. A client that does explicitly call Xkb functions is an <emphasis>
+Xkb-aware</emphasis>
+ client. The Xkb keyboard state includes information derived from the effective state and from two server parameters that can be set through the keyboard extension. The following components of keyboard state pertain to Xkb-capable and Xkb-aware clients:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+lookup state: lookup group and lookup modifiers
+ </para>
+</listitem>
+<listitem>
+ <para>
+grab state: grab group and grab modifiers
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The <emphasis>
+lookup modifiers</emphasis>
+ and <emphasis>
+lookup group</emphasis>
+ are represented in the state field of core X events. The modifier state and keycode of a key event are used to determine the symbols associated with the event. For <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events, the lookup modifiers are computed as:
+</para>
+
+<literallayout>
+ ((base | latched | locked) &amp; ~<emphasis> server_internal_modifiers</emphasis>)
+</literallayout>
+
+<para>
+Otherwise the lookup modifiers are computed as:
+</para>
+
+<literallayout>
+(((base | latched | (locked &amp; ~<emphasis> ignore_locks</emphasis>)) &amp; ~<emphasis> server_internal_modifiers</emphasis>)
+</literallayout>
+
+<para>
+The lookup group is the same as the effective group.
+</para>
+
+
+<para>
+When an Xkb-capable or Xkb-aware client wishes to map a keycode to a keysym, it should use the <emphasis>
+lookup state</emphasis>
+ — the lookup group and the lookup modifiers.
+</para>
+
+
+<para>
+The <emphasis>
+grab state</emphasis>
+ is the state used when matching events to passive grabs. If the event activates a grab, the <emphasis>
+grab modifiers</emphasis>
+ and <emphasis>
+grab group</emphasis>
+ are represented in the state field of core X events; otherwise, the lookup state is used. The grab modifiers are computed as:
+</para>
+
+<literallayout>
+(((base | latched | (locked &amp; ~ignore_locks)) &amp; ~server_internal_modifiers)
+</literallayout>
+
+<para>
+If the server’s <emphasis>
+IgnoreGroupLock</emphasis>
+ control (see section 10.7.3) is not set, the grab group is the same as the effective group. Otherwise, the grab group is computed from the base group and latched group, ignoring the locked group.
+</para>
+
+
+<para>
+The final three components of Xkb state are applicable to clients that are not linked with an Xlib containing the X keyboard extension library and therefore are not aware of the keyboard extension (<emphasis>
+Xkb-unaware </emphasis>
+clients):
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The compatibility modifier state
+ </para>
+</listitem>
+<listitem>
+ <para>
+The compatibility lookup modifier state
+ </para>
+</listitem>
+<listitem>
+ <para>
+The compatibility grab modifier state
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The X11 protocol interpretation of modifiers does not include direct support for multiple groups. When an Xkb-extended X server connects to an Xkb-unaware client, the compatibility states remap the keyboard group into a core modifier whenever possible. The compatibility state corresponds to the effective modifier and effective group state, with the group remapped to a modifier. The compatibility lookup and grab states correspond to the lookup and grab states, respectively, with the group remapped to a modifier. The compatibility lookup state is reported in events that do not trigger passive grabs; otherwise, the compatibility grab state is reported.
+</para>
+
+
+</sect1>
+<sect1 id='changing_the_keyboard_state'>
+<title>Changing the Keyboard State</title>
+
+<sect2 id='changing_modifiers'>
+<title>Changing Modifiers</title>
+
+<para>
+The functions in this section that change the use of modifiers use a mask in the parameter <emphasis>
+affect</emphasis>
+. It is a bitwise inclusive OR of the legal modifier masks:
+</para>
+
+<table frame='none'>
+<title>Real Modifier Masks</title>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='1'>
+ <entry>Mask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>ShiftMask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>LockMask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>ControlMask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Mod1Mask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Mod2Mask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Mod3Mask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Mod4Mask</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Mod5Mask</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+To lock and unlock any of the eight real keyboard modifiers, use <emphasis>
+XkbLockModifiers:</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis> XkbLockModifiers</emphasis>
+(<emphasis>
+display, device_spec, affect, values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect</emphasis>
+; /* mask of real modifiers whose lock state is to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+values</emphasis>
+; /* 1 =&gt; lock, 0 =&gt; unlock; only for modifiers selected by <emphasis>
+affect</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbLockModifiers</emphasis>
+ sends a request to the server to lock the real modifiers selected by both <emphasis>
+affect</emphasis>
+ and <emphasis>
+values</emphasis>
+ and to unlock the real modifiers selected by <emphasis>
+affect</emphasis>
+ but not selected by <emphasis>
+values</emphasis>
+. <emphasis>
+XkbLockModifiers</emphasis>
+ does not wait for a reply from the server. It returns <emphasis>
+True</emphasis>
+ if the request was sent, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To latch and unlatch any of the eight real keyboard modifiers, use <emphasis>
+XkbLatchModifiers:</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbLatchModifiers</emphasis>
+(d<emphasis>
+isplay, device_spec, affect, values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect</emphasis>
+; /* mask of modifiers whose latch state is to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>values</emphasis>;
+/* 1 =&gt; latch, 0 =&gt; unlatch; only for mods selected by <emphasis>
+affect</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbLatchModifiers</emphasis>
+ sends a request to the server to latch the real modifiers selected by both <emphasis>
+affect</emphasis>
+ and <emphasis>
+values</emphasis>
+ and to unlatch the real modifiers selected by <emphasis>
+affect</emphasis>
+ but not selected by <emphasis>
+values</emphasis>
+. <emphasis>
+XkbLatchModifiers</emphasis>
+ does not wait for a reply from the server. It returns <emphasis>
+True</emphasis>
+ if the request was sent, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+</sect2>
+<sect2 id='changing_groups'>
+<title>Changing Groups</title>
+
+<para>
+Reference the keysym group indices with these symbolic constants:
+</para>
+
+<table frame='none'>
+<title>Symbolic Group Names</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry>Symbolic Name</entry>
+ <entry>Value</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup1Index</entry>
+ <entry>0</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup2Index</entry>
+ <entry>1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup3Index</entry>
+ <entry>2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup4Index</entry>
+ <entry>3</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+To lock the keysym group, use <emphasis>
+XkbLockGroup. </emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbLockGroup</emphasis>
+(<emphasis>
+display, device_spec, group</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+group</emphasis>
+; /* index of the keysym group to lock */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbLockGroup</emphasis>
+ sends a request to the server to lock the specified <emphasis>
+group </emphasis>
+and does not wait for a reply. It returns <emphasis>
+True</emphasis>
+ if the request was sent and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To latch the keysym group, use <emphasis>
+XkbLatchGroup.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbLatchGroup</emphasis>
+(<emphasis>
+display, device_spec, group</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ group</emphasis>
+; /* index of the keysym group to latch */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbLatchGroup</emphasis>
+ sends a request to the server to latch the specified group and does not wait for a reply. It returns <emphasis>
+True</emphasis>
+ if the request was sent and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='determining_keyboard_state'>
+<title>Determining Keyboard State</title>
+
+<para>
+Xkb keyboard state may be represented in an <emphasis>
+XkbStateRec</emphasis>
+ structure:
+</para>
+
+<para><programlisting>
+typedef struct {
+ unsigned char group; /* effective group index */
+ unsigned char base_group; /* base group index */
+ unsigned char latched_group; /* latched group index */
+ unsigned char locked_group; /* locked group index */
+ unsigned char mods; /* effective modifiers */
+ unsigned char base_mods; /* base modifiers */
+ unsigned char latched_mods; /* latched modifiers */
+ unsigned char locked_mods; /* locked modifiers */
+ unsigned char compat_state; /* effective group =&gt; modifiers */
+ unsigned char grab_mods; /* modifiers used for grabs */
+ unsigned char compat_grab_mods; /* mods used for compatibility mode grabs */
+ unsigned char lookup_mods; /* modifiers used to lookup symbols */
+ unsigned char compat_lookup_mods; /* mods used for compatibility lookup */
+ unsigned short ptr_buttons; /* 1 bit =&gt; corresponding pointer btn is down */
+} <emphasis>
+XkbStateRec</emphasis>
+,*XkbStatePtr;
+</programlisting></para>
+
+<para>
+To obtain the keyboard state, use <emphasis>
+XkbGetState.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetState</emphasis>
+(<emphasis>
+display</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+state_return</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbStatePtr <emphasis>
+state_return</emphasis>
+; /* backfilled with Xkb state */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+XkbGetState </emphasis>
+function queries the server for the current keyboard state, waits for a reply, and then backfills <emphasis>
+state_return</emphasis>
+ with the results.
+</para>
+
+
+<para>
+All group values are expressed as group indices in the range [0..3]. Modifiers and the compatibility modifier state values are expressed as the bitwise union of the core X11 modifier masks. The pointer button state is reported as in the core X11 protocol.
+</para>
+
+
+</sect1>
+<sect1 id='tracking_keyboard_state'>
+<title>Tracking Keyboard State</title>
+
+<para>
+The Xkb extension reports <emphasis>
+XkbStateNotify </emphasis>
+events to clients wanting notification whenever the Xkb state changes. The changes reported include changes to any aspect of the keyboard state: when a modifier is set or unset, when the current group changes, or when a pointer button is pressed or released. As with all Xkb events, <emphasis>
+XkbStateNotify</emphasis>
+ events are reported to all interested clients without regard to the current keyboard input focus or grab state.
+</para>
+
+
+<para>
+There are many different types of Xkb state changes. Xkb defines an event detail mask corresponding to each type of change. The event detail masks are listed in Table 5.3.
+</para>
+
+<table frame='none'>
+<title>XkbStateNotify Event Detail Masks</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbModifierStateMask</entry>
+ <entry>(1L &lt;&lt; 0)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbModifierBaseMask</entry>
+ <entry>(1L &lt;&lt; 1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbModifierLatchMask</entry>
+ <entry>(1L &lt;&lt; 2)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbModifierLockMask</entry>
+ <entry>(1L &lt;&lt; 3)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroupStateMask</entry>
+ <entry>(1L &lt;&lt; 4)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroupBaseMask</entry>
+ <entry>(1L &lt;&lt; 5)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroupLatchMask</entry>
+ <entry>(1L &lt;&lt; 6)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroupLockMask</entry>
+ <entry>(1L &lt;&lt; 7)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbCompatStateMask</entry>
+ <entry>(1L &lt;&lt; 8)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGrabModsMask</entry>
+ <entry>(1L &lt;&lt; 9)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbCompatGrabModsMask</entry>
+ <entry>(1L &lt;&lt; 10)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLookupModsMask</entry>
+ <entry>(1L &lt;&lt; 11)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbCompatLookupModsMask</entry>
+ <entry>(1L &lt;&lt; 12)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbPointerButtonMask</entry>
+ <entry>(1L &lt;&lt; 13)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAllStateComponentsMask</entry>
+ <entry>(0x3fff)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+To track changes in the keyboard state for a particular device, select to receive <emphasis>
+XkbStateNotify</emphasis>
+ events by calling either <emphasis>
+XkbSelectEvents</emphasis>
+ or <emphasis>
+XkbSelectEventDetails</emphasis>
+ (see section 4.3). <!-- xref -->
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbStateNotify</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ and pass <emphasis>
+XkbStateNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbStateNotify</emphasis>
+ events only under certain conditions, use <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbStateNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying the desired state changes in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ using mask bits from Table 5.3. <!-- xref -->
+</para>
+
+
+<para>
+The structure for <emphasis>
+XkbStateNotify</emphasis>
+ events is:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis> XkbStateNotify</emphasis> */
+ int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ unsigned int changed; /* bits indicating what has changed */
+ int group; /* group index of effective group */
+ int base_group; /* group index of base group */
+ int latched_group; /* group index of latched group */
+ int locked_group; /* group index of locked group */
+ unsigned int mods; /* effective modifiers */
+ unsigned int base_mods; /* base modifiers */
+ unsigned int latched_mods; /* latched modifiers */
+ unsigned int locked_mods; /* locked modifiers */
+ int compat_state; /* computed compatibility state */
+ unsigned char grab_mods; /* modifiers used for grabs */
+ unsigned char compat_grab_mods; /* modifiers used for compatibility grabs */
+ unsigned char lookup_mods; /* modifiers used to lookup symbols */
+ unsigned char compat_lookup_mods; /* mods used for compatibility look up */
+ int ptr_buttons; /* core pointer buttons */
+ KeyCode keycode; /* keycode causing event, 0 if programmatic */
+ char event_type; /* core event if <emphasis> req_major</emphasis> or
+ <emphasis> req_minor</emphasis> non zero */
+ char req_major; /* major request code if program trigger, else 0 */
+ char req_minor; /* minor request code if program trigger, else 0 */
+} <emphasis>XkbStateNotifyEvent</emphasis>
+;
+</programlisting></para>
+
+<para>
+When you receive an <emphasis>
+XkbStateNotify</emphasis>
+ event, the <emphasis>
+changed</emphasis>
+ field indicates which elements of keyboard state have changed.
+This will be the bitwise inclusive OR of one or more of the <emphasis>
+XkbStateNotify</emphasis>
+ event detail masks shown in Table 5.3. All fields reported in <!-- xref -->
+the event are valid, but only those indicated in <emphasis>
+changed</emphasis>
+ have changed values.
+</para>
+
+
+<para>
+The <emphasis>
+group</emphasis>
+ field is the group index of the effective keysym group. The <emphasis>
+base_group</emphasis>
+, <emphasis>
+latched_group</emphasis>
+, and <emphasis>
+locked_group</emphasis>
+ fields are set to a group index value representing the base group,
+the latched group, and the locked group, respectively. The X
+server can set the modifier and compatibility state fields to
+a union of the core modifier mask bits; this union represents the
+corresponding modifier states. The <emphasis>ptr_button</emphasis>
+ field gives the state of the core pointer buttons as a
+mask composed of an inclusive OR of zero or more of the
+core pointer button masks.
+</para>
+
+
+<para>
+Xkb state changes can occur either in response to keyboard
+activity or under application control. If a key event
+caused the state change, the <emphasis>
+keycode</emphasis>
+ field gives the keycode of the key event, and the <emphasis>
+event_type</emphasis>
+ field is set to either <emphasis>KeyPress</emphasis>
+ or <emphasis>
+KeyRelease</emphasis>
+. If a pointer button event caused the state change, the <emphasis>
+keycode</emphasis>
+ field is zero, and the <emphasis>event_type</emphasis>
+ field is set to either <emphasis>ButtonPress</emphasis>
+ or <emphasis>ButtonRelease</emphasis>
+. Otherwise, the major and minor codes of the request that caused the
+state change are given in the <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ fields, and the <emphasis>
+keycode</emphasis>
+ field is zero. The <emphasis>
+req_major</emphasis>
+ value is the same as the major extension opcode.
+</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch06.xml b/libX11/specs/XKB/ch06.xml
new file mode 100644
index 000000000..3bd77fab2
--- /dev/null
+++ b/libX11/specs/XKB/ch06.xml
@@ -0,0 +1,413 @@
+<chapter id='complete_keyboard_description'>
+<title>Complete Keyboard Description</title>
+
+<para>
+The complete Xkb description for a keyboard device is accessed using a single
+structure containing pointers to major Xkb components. This chapter describes
+this single structure and provides references to other sections of this
+document that discuss the major Xkb components in detail.
+</para>
+
+<sect1 id='the_xkbdescrec_structure'>
+<title>The XkbDescRec Structure</title>
+
+<para>
+The complete description of an Xkb keyboard is given by an <emphasis>
+XkbDescRec</emphasis>
+. The component structures in the <emphasis>
+XkbDescRec</emphasis>
+ represent the major Xkb components outlined in Figure 1.1. <!-- xref -->
+</para>
+
+<para><programlisting>
+typedef struct {
+ struct _XDisplay * display; /* connection to
+X server */
+ unsigned short flags; /* private to Xkb, do
+not modify */
+ unsigned short device_spec; /* device of
+interest */
+ KeyCode min_key_code; /* minimum keycode for
+device */
+ KeyCode max_key_code; /* maximum keycode for
+device */
+ XkbControlsPtr ctrls; /* controls */
+ XkbServerMapPtr server; /* server keymap */
+ XkbClientMapPtr map; /* client keymap */
+ XkbIndicatorPtr indicators; /* indicator map
+*/
+ XkbNamesPtr names; /* names for all
+components */
+ XkbCompatMapPtr compat; /* compatibility map
+*/
+ XkbGeometryPtr geom; /* physical geometry of
+keyboard */
+} <emphasis>
+XkbDescRec</emphasis>
+, *XkbDescPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+display</emphasis>
+ field points to an X display structure. The <emphasis>
+flags</emphasis>
+ field is private to the library: modifying <emphasis>
+flags</emphasis>
+ may yield unpredictable results. The <emphasis>
+device_spec</emphasis>
+ field specifies the device identifier of the keyboard input device, or
+<emphasis>
+XkbUseCoreKeyboard</emphasis>
+, which specifies the core keyboard device. The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields specify the least and greatest keycode that can be returned by the
+keyboard.
+</para>
+
+
+<para>
+The other fields specify structure components of the keyboard description and
+are described in detail in other sections of this document. Table 6.1
+identifies the subsequent sections of this document that discuss the individual
+components of the <emphasis>
+XkbDescRec</emphasis>
+.
+</para>
+
+<table frame='none'>
+<title>XkbDescRec Component References</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>XkbDescRec Field</entry>
+ <entry>For more info</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>ctrls</entry>
+ <entry>Chapter 10</entry>
+</row>
+<row rowsep='0'>
+ <entry>server</entry>
+ <entry>Chapter 16</entry>
+</row>
+<row rowsep='0'>
+ <entry>map</entry>
+ <entry>Chapter 15</entry>
+</row>
+<row rowsep='0'>
+ <entry>indicators</entry>
+ <entry>Chapter 8</entry>
+</row>
+<row rowsep='0'>
+ <entry>names</entry>
+ <entry>Chapter 18</entry>
+</row>
+<row rowsep='0'>
+ <entry>compat</entry>
+ <entry>Chapter 17</entry>
+</row>
+<row rowsep='0'>
+ <entry>geom</entry>
+ <entry>Chapter 13</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Each structure component has a corresponding mask bit that is used in function
+calls to indicate that the structure should be manipulated in some manner, such
+as allocating it or freeing it. These masks and their relationships to the
+fields in the <emphasis>
+XkbDescRec</emphasis>
+ are shown in Table 6.2. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>Mask Bits for XkbDescRec</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask Bit</entry>
+ <entry>XkbDescRec Field</entry>
+ <entry>Value</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbControlsMask</entry>
+ <entry>ctrls</entry>
+ <entry>(1L&lt;&lt;0)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbServerMapMask</entry>
+ <entry>server</entry>
+ <entry>(1L&lt;&lt;1)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbIClientMapMask</entry>
+ <entry>map</entry>
+ <entry>(1L&lt;&lt;2)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbIndicatorMapMask</entry>
+ <entry>indicators</entry>
+ <entry>(1L&lt;&lt;3)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbNamesMask</entry>
+ <entry>names</entry>
+ <entry>(1L&lt;&lt;4)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbCompatMapMask</entry>
+ <entry>compat</entry>
+ <entry>(1L&lt;&lt;5)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbGeometryMask</entry>
+ <entry>geom</entry>
+ <entry>(1L&lt;&lt;6)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAllComponentsMask</entry>
+ <entry>All Fields</entry>
+ <entry>(0x7f)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='obtaining_a_keyboard_description_from_the_server'>
+<title>Obtaining a Keyboard Description from the Server</title>
+
+<para>
+To retrieve one or more components of a keyboard device description, use
+<emphasis>
+XkbGetKeyboard</emphasis>
+ (see also <emphasis>
+XkbGetKeyboardbyName</emphasis>
+).
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDescPtr <emphasis>
+XkbGetKeyboard</emphasis>
+(<emphasis>
+display, which, device_spec</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask indicating components to return */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ device_spec</emphasis>
+; /* device for which to fetch description, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyboard </emphasis>
+allocates and returns a pointer to a keyboard description. It queries the
+server for those components specified in the <emphasis>
+which</emphasis>
+ parameter for device <emphasis>
+device_spec</emphasis>
+ and copies the results to the <emphasis>
+XkbDescRec</emphasis>
+ it allocated. The remaining fields in the keyboard description are set to
+<emphasis>
+NULL</emphasis>
+. The valid masks for <emphasis>
+which</emphasis>
+ are those listed in Table 6.2. <!-- xref -->
+</para>
+
+
+<para>
+<emphasis>
+XkbGetKeyboard</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+ protocol errors.
+</para>
+
+
+<para>
+To free the returned keyboard description, use <emphasis>
+XkbFreeKeyboard</emphasis>
+ (see section 6.4). <!-- xref -->
+</para>
+
+
+</sect1>
+<sect1 id='tracking_changes_to_the_keyboard_description_in_the_server'>
+<title>Tracking Changes to the Keyboard Description in the Server</title>
+
+<para>
+The server can generate events whenever its copy of the keyboard description
+for a device changes. Refer to section 14.4 for detailed information on <!-- xref -->
+tracking changes to the keyboard description.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_a_keyboard_description'>
+<title>Allocating and Freeing a Keyboard Description</title>
+
+<para>
+Applications seldom need to directly allocate a keyboard description; calling
+<emphasis>
+XkbGetKeyboard</emphasis>
+ usually suffices. In the event you need to create a keyboard description from
+scratch, however, use <emphasis>
+XkbAllocKeyboard</emphasis>
+ rather than directly calling <emphasis>
+malloc </emphasis>
+or <emphasis>
+Xmalloc</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDescRec * <emphasis>
+XkbAllocKeyboard</emphasis>
+(void)
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If <emphasis>
+XkbAllocKeyboard</emphasis>
+ fails to allocate the keyboard description, it returns <emphasis>
+NULL</emphasis>
+. Otherwise, it returns a pointer to an empty keyboard description structure.
+The <emphasis>
+device_spec</emphasis>
+ field will have been initialized to <emphasis>
+XkbUseCoreKbd</emphasis>
+. You may then either fill in the structure components or use Xkb functions to
+obtain values for the structure components from a keyboard device.
+</para>
+
+
+<para>
+To destroy either an entire an <emphasis>
+XkbDescRec</emphasis>
+ or just some of its members, use <emphasis>
+XkbFreeKeyboard.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeKeyboard</emphasis>
+<emphasis>
+(xkb, which, free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description with components to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ which</emphasis>
+; /* mask selecting components to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free all components and <emphasis>
+xkb</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbFreeKeyboard</emphasis>
+ frees the components of <emphasis>
+xkb</emphasis>
+ specified by <emphasis>
+which</emphasis>
+ and sets the corresponding values to <emphasis>
+NULL</emphasis>
+. If <emphasis>
+free_all</emphasis>
+ is <emphasis>
+True</emphasis>
+, <emphasis>
+XkbFreeKeyboard</emphasis>
+ frees every non-<emphasis>
+NULL</emphasis>
+ component of <emphasis>
+xkb</emphasis>
+ and then frees the <emphasis>
+xkb</emphasis>
+ structure itself.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch07.xml b/libX11/specs/XKB/ch07.xml
new file mode 100644
index 000000000..cd1b7dbd0
--- /dev/null
+++ b/libX11/specs/XKB/ch07.xml
@@ -0,0 +1,446 @@
+<chapter id='virtual_modifiers'>
+<title>Virtual Modifiers</title>
+
+<para>
+The core protocol specifies that certain keysyms, when bound to modifiers,
+affect the rules of keycode to keysym interpretation for all keys; for example,
+when the <emphasis>
+Num_Lock</emphasis>
+ keysym is bound to some modifier, that modifier is used to select between
+shifted and unshifted state for the numeric keypad keys. The core protocol does
+not provide a convenient way to determine the mapping of modifier bits (in
+particular <emphasis>
+Mod1</emphasis>
+ through <emphasis>
+Mod5</emphasis>
+) to keysyms such as <emphasis>
+Num_Lock</emphasis>
+ and <emphasis>
+Mode_switch</emphasis>
+. Using the core protocol only, a client application must retrieve and search
+the modifier map to determine the keycodes bound to each modifier, and then
+retrieve and search the keyboard mapping to determine the keysyms bound to the
+keycodes. It must repeat this process for all modifiers whenever any part of
+the modifier mapping is changed.
+</para>
+
+
+<para>
+Xkb alleviates these problems by defining virtual modifiers. In addition to the
+eight core modifiers, referred to as the <emphasis>
+real modifiers</emphasis>
+, Xkb provides a set of sixteen named <emphasis>
+virtual modifiers</emphasis>
+. Each virtual modifier can be bound to any set of the real modifiers
+(<emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, <emphasis>
+Control,</emphasis>
+ and <emphasis>
+Mod1</emphasis>
+-<emphasis>
+Mod5</emphasis>
+).
+</para>
+
+
+<para>
+The separation of function from physical modifier bindings makes it easier to
+specify more clearly the intent of a binding. X servers do not all assign
+modifiers the same way — for example, <emphasis>
+Num_Lock</emphasis>
+ might be bound to <emphasis>
+Mod2</emphasis>
+ for one vendor and to <emphasis>
+Mod4</emphasis>
+ for another. This makes it cumbersome to automatically remap the keyboard to a
+desired configuration without some kind of prior knowledge about the keyboard
+layout and bindings. With XKB, applications can use virtual modifiers to
+specify the desired behavior, without regard for the actual physical bindings
+in effect.
+</para>
+
+<sect1 id='virtual_modifier_names_and_masks'>
+<title>Virtual Modifier Names and Masks</title>
+
+<para>
+Virtual modifiers are named by converting their string name to an X <emphasis>
+Atom</emphasis>
+ and storing the Atom in the <emphasis>
+names.vmods</emphasis>
+ array in an <emphasis>
+XkbDescRec</emphasis>
+ structure (see section 6.1). The position of a name Atom in the <emphasis>
+names.vmods</emphasis>
+ array defines the bit position used to represent the virtual modifier and also
+the index used when accessing virtual modifier information in arrays: the name
+in the i-th (0 relative) entry of <emphasis>
+names.vmods</emphasis>
+ is the i-th virtual modifier, represented by the mask (1&lt;&lt;i). Throughout
+Xkb, various functions have a parameter that is a mask representing virtual
+modifier choices. In each case, the i-th bit (0 relative) of the mask
+represents the i-th virtual modifier.
+</para>
+
+
+<para>
+To set the name of a virtual modifier, use <emphasis>
+XkbSetNames</emphasis>
+, using <emphasis>
+XkbVirtualModNamesMask</emphasis>
+ in <emphasis>
+which</emphasis>
+ and the name in the <emphasis>
+xkb</emphasis>
+ argument; to retrieve indicator names, use <emphasis>
+XkbGetNames</emphasis>
+. These functions are discussed in Chapter 18.
+</para>
+
+
+</sect1>
+<sect1 id='modifier_definitions'>
+<title>Modifier Definitions</title>
+
+<para>
+An Xkb<emphasis>
+ modifier definition</emphasis>
+ enumerates a collection of real and virtual modifiers but does not in itself
+bind those modifiers to any particular key or to each other. Modifier
+definitions are included in a number of structures in the keyboard description
+to define the collection of modifiers that affect or are affected by some other
+entity. A modifier definition is relevant only in the context of some other
+entity such as an indicator map, a control, or a key type. (See sections 8.2.2,
+10.8, and 15.2.) <!-- xref -->
+</para>
+
+<para><programlisting>
+typedef struct _XkbMods {
+ unsigned char mask; /* real_mods | vmods mapped to
+real modifiers */
+ unsigned char real_mods; /* real modifier bits */
+ unsigned short vmods; /* virtual modifier bits */
+} <emphasis>
+XkbModsRec</emphasis>
+,*XkbModsPtr;
+</programlisting></para>
+
+<para>
+An Xkb modifier definition consists of a set of bit masks corresponding to the
+eight real modifiers (<emphasis>
+real_mods</emphasis>
+); a similar set of bitmasks corresponding to the 16 named virtual modifiers
+(<emphasis>
+vmods</emphasis>
+); and an effective mask (<emphasis>
+mask</emphasis>
+). The effective mask represents the set of all real modifiers that can
+logically be set either by setting any of the real modifiers or by setting any
+of the virtual modifiers in the definition. <emphasis>
+mask</emphasis>
+ is derived from the real and virtual modifiers and should never be explicitly
+changed — it contains all of the real modifiers specified in the definition
+(<emphasis>
+real_mods</emphasis>
+)<emphasis>
+ plus</emphasis>
+ any real modifiers that are bound to the virtual modifiers specified in the
+definition (<emphasis>
+vmods</emphasis>
+). The binding of the virtual modifiers to real modifiers is exterior to the
+modifier definition. Xkb automatically recomputes the mask field of modifier
+definitions as necessary. Whenever you access a modifier definition that has
+been retrieved using an Xkb library function, the mask field will be correct
+for the keyboard mapping of interest.
+</para>
+
+
+</sect1>
+<sect1 id='binding_virtual_modifiers_to_real_modifiers'>
+<title>Binding Virtual Modifiers to Real Modifiers</title>
+
+<para>
+The binding of virtual modifiers to real modifiers is defined by the <emphasis>
+server.vmods</emphasis>
+ array in an <emphasis>
+XkbDescRec</emphasis>
+ structure. Each entry contains the real modifier bits that are bound to the
+virtual modifier corresponding to the entry. The overall relationship of fields
+dealing with virtual modifiers in the server keyboard description are shown in
+Figure 16.2. <!-- xref -->
+</para>
+
+
+</sect1>
+<sect1 id='virtual_modifier_key_mapping'>
+<title>Virtual Modifier Key Mapping</title>
+
+<para>
+Xkb maintains a <emphasis>
+virtual modifier mapping</emphasis>
+, which lists the virtual modifiers associated with, or bound to, each key. The
+real modifiers bound to a virtual modifier always include all of the modifiers
+bound to any of the keys that specify that virtual modifier in their virtual
+modifier mapping. The <emphasis>
+server.vmodmap</emphasis>
+ array indicates which virtual modifiers are bound to each key; each entry is a
+bitmask for the virtual modifier bits. The <emphasis>
+server.vmodmap</emphasis>
+ array is indexed by keycode.
+</para>
+
+
+<para>
+The <emphasis>
+vmodmap</emphasis>
+ and <emphasis>
+vmods</emphasis>
+ members of the server map are the "master" virtual modifier definitions. Xkb
+automatically propagates any changes to these fields to all other fields that
+use virtual modifier mappings (see section 16.4).
+</para>
+
+
+<para>
+For example, if <emphasis>
+Mod3</emphasis>
+ is bound to the <emphasis>
+Num_Lock</emphasis>
+ key by the core protocol modifier mapping, and the <emphasis>
+NumLock</emphasis>
+ virtual modifier is bound to they <emphasis>
+Num_Lock</emphasis>
+ key by the virtual modifier mapping, <emphasis>
+Mod3</emphasis>
+ is added to the set of modifiers associated with <emphasis>
+NumLock</emphasis>
+.
+</para>
+
+
+<para>
+The virtual modifier mapping is normally updated whenever actions are
+automatically applied to symbols (see section 16.4 for details), and few
+applications should need to change the virtual modifier mapping explicitly.
+</para>
+
+
+<para>
+Use <emphasis>
+XkbGetMap </emphasis>
+(see section 14.2) to get the virtual modifiers from the server or use <!-- xref -->
+<emphasis>
+XkbGetVirtualMods</emphasis>
+ (see section 16.4.1) to update a local copy of the virtual modifiers bindings <!-- xref -->
+from the server. To set the binding of a virtual modifier to a real modifier,
+use <emphasis>
+XkbSetMap</emphasis>
+ (see<emphasis>
+ </emphasis>
+section 14.3<emphasis> <!-- xref -->
+).</emphasis>
+</para>
+
+
+<para>
+To determine the mapping of virtual modifiers to core X protocol modifiers, use
+<emphasis>
+XkbVirtualModsToReal</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbVirtualModsToReal</emphasis>
+(<emphasis>
+xkb, virtual_mask, mask_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description for input device */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ virtual_mask</emphasis>
+; /* virtual modifier mask to translate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+mask_rtrn</emphasis>
+; /* backfilled with real modifiers */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If the keyboard description defined by <emphasis>
+xkb</emphasis>
+ includes bindings for virtual modifiers, <emphasis>
+XkbVirtualModsToReal</emphasis>
+ uses those bindings to determine the set of real modifiers that correspond to
+the set of virtual modifiers specified in <emphasis>
+virtual_mask</emphasis>
+. The <emphasis>
+virtual_mask</emphasis>
+ parameter is a mask specifying the virtual modifiers to translate; the i-th
+bit (0 relative) of the mask represents the i-th virtual modifier. If <emphasis>
+mask_rtrn</emphasis>
+ is non-<emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbVirtualModsToReal</emphasis>
+ backfills it with the resulting real modifier mask. If the keyboard
+description in <emphasis>
+xkb</emphasis>
+ does not include virtual modifier bindings, <emphasis>
+XkbVirtualModsToReal</emphasis>
+ returns <emphasis>
+False</emphasis>
+; otherwise, it returns <emphasis>
+True</emphasis>
+.
+</para>
+
+<note><para>It is possible for a local (client-side) keyboard description (the
+<emphasis>
+xkb</emphasis>
+ parameter) to not contain any virtual modifier information (simply because the
+client has not requested it) while the server’s corresponding definition may
+contain virtual modifier information. </para></note>
+
+
+<sect2 id='inactive_modifier_sets'>
+<title>Inactive Modifier Sets</title>
+
+<para>
+An unbound virtual modifier is one that is not bound to any real modifier
+(<emphasis>
+server</emphasis>
+-&gt;<emphasis>
+vmods</emphasis>
+[virtual_modifier_index] is zero).
+</para>
+
+
+<para>
+Some Xkb operations ignore modifier definitions in which the virtual modifiers
+are unbound. Consider this example:
+</para>
+
+<literallayout>
+if (state matches {Shift}) Do OneThing;
+if (state matches {Shift+NumLock}) Do Another;
+</literallayout>
+
+<para>
+If the <emphasis>
+NumLock</emphasis>
+ virtual modifier is not bound to any real modifiers, the effective masks for
+these two cases are identical (that is, contain only <emphasis>
+Shift</emphasis>
+). When it is essential to distinguish between <emphasis>
+OneThing</emphasis>
+ and Another, Xkb considers only those modifier definitions for which all
+virtual modifiers are bound.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='conventions'>
+<title>Conventions</title>
+
+<para>
+The Xkb extension does not require any specific virtual modifier names.
+However, everyone benefits if the same names are used for common modifiers. The
+following names are suggested:
+</para>
+
+<literallayout class='monospaced'>
+ <emphasis>
+ NumLock
+ ScrollLock
+ Alt
+ Meta
+ AltGr
+ LevelThree</emphasis>
+</literallayout>
+
+</sect1>
+<sect1 id='example'>
+<title>Example</title>
+
+<para>
+If the second (0-relative) entry in <emphasis>
+names.vmods</emphasis>
+ contains the Atom for "NumLock", then 0x4 (1&lt;&lt;2) is the virtual modifier
+bit for the <emphasis>
+NumLock</emphasis>
+ virtual modifier. If <emphasis>
+server.vmods</emphasis>
+[2] contains <emphasis>
+Mod3Mask</emphasis>
+, then the <emphasis>
+NumLock</emphasis>
+ virtual modifier is bound to the <emphasis>
+Mod3</emphasis>
+ real modifier.
+</para>
+
+
+<para>
+A virtual modifier definition for this example would have:
+</para>
+
+<literallayout class='monospaced'>
+ real_mods = 0
+ vmods = 0x4 (NumLock named virtual modifier)
+ mask = 0x20 (Mod3Mask)
+</literallayout>
+
+<para>
+Continuing the example, if the keyboard has a <emphasis>
+Num_Lock</emphasis>
+ keysym bound to the key with keycode 14, and the <emphasis>
+NumLock</emphasis>
+ virtual modifier is bound to this key, <emphasis>
+server.vmodmap</emphasis>
+[14] contains 0x4.
+</para>
+
+
+<para>
+Finally, if the keyboard also used the real <emphasis>
+Mod1</emphasis>
+ modifier for numeric lock operations, the modifier definition below would
+represent the situation where either the key bound to <emphasis>
+Mod1</emphasis>
+ or the <emphasis>
+NumLock</emphasis>
+ virtual modifier could be used for this purpose:
+</para>
+
+<literallayout class='monospaced'>
+ real_mods = 0x8 (Mod1Mask)
+ vmods = 0x4 (NumLock named virtual modifier)
+ mask = 0x28 (Mod1Mask | Mod3Mask)
+</literallayout>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch08.xml b/libX11/specs/XKB/ch08.xml
new file mode 100644
index 000000000..0d19a3d7a
--- /dev/null
+++ b/libX11/specs/XKB/ch08.xml
@@ -0,0 +1,2087 @@
+<chapter id='indicators'>
+<title>Indicators</title>
+
+<para>
+Although the core X implementation supports up to 32 LEDs on an input device,
+it does not provide any linkage between the state of the LEDs and the logical
+state of the input device. For example, most keyboards have a <emphasis>
+CapsLock</emphasis>
+ LED, but X does not provide a mechanism to make the LED automatically follow
+the logical state of the <emphasis>
+CapsLock</emphasis>
+ key.
+</para>
+
+
+<para>
+Furthermore, the core X implementation does not provide clients with the
+ability to determine what bits in the <emphasis>
+led_mask</emphasis>
+ field of the <emphasis>
+XKeyboardState</emphasis>
+ map to the particular LEDs on the keyboard. For example, X does not provide a
+method for a client to determine what bit to set in the <emphasis>
+led_mask</emphasis>
+ field to turn on the <emphasis>
+Scroll Lock </emphasis>
+LED or whether the keyboard even has a <emphasis>
+Scroll Lock</emphasis>
+ LED.
+</para>
+
+
+<para>
+Xkb provides indicator names and programmable indicators to help solve these
+problems. Using Xkb, clients can determine the names of the various indicators,
+determine and control the way that the individual indicators should be updated
+to reflect keyboard changes, and determine which of the 32 keyboard indicators
+reported by the protocol are actually present on the keyboard. Clients may also
+request immediate notification of changes to the state of any subset of the
+keyboard indicators, which makes it straightforward to provide an on-screen
+"virtual" LED panel. This chapter describes Xkb indicators and the functions
+used for manipulating them.
+</para>
+
+<sect1 id='indicator_names'>
+<title>Indicator Names</title>
+
+<para>
+Xkb provides the capability of symbolically naming indicators. Xkb itself
+doesn’t use these symbolic names for anything; they are there only to help
+make the keyboard description comprehensible to humans. To set the names of
+specific indicators, use <emphasis>
+XkbSetNames</emphasis>
+ as discussed in Chapter 18. Then set the map using <emphasis> <!-- xref -->
+XkbSetMap</emphasis>
+ (see section 14.3) or <emphasis> <!-- xref -->
+XkbSetNamedIndicator</emphasis>
+ (below). To retrieve indicator names, use <emphasis>
+XkbGetNames</emphasis>
+ (Chapter 18). <!-- xref -->
+</para>
+
+
+</sect1>
+<sect1 id='indicator_data_structures'>
+<title>Indicator Data Structures</title>
+
+<para>
+Use the indicator description record, <emphasis>
+XkbIndicatorRec</emphasis>
+, and its indicator map, <emphasis>
+XkbIndicatorMapRec</emphasis>
+, to inquire about and control most indicator properties and behaviors.
+</para>
+
+
+<sect2 id='xkbindicatorrec'>
+<title>XkbIndicatorRec</title>
+
+<para>
+The description for all the Xkb indicators is held in the <emphasis>
+indicators</emphasis>
+ field of the complete keyboard description (see Chapter 6), which is defined <!-- xref -->
+as follows:
+</para>
+
+<para><programlisting>
+#define XkbNumIndicators 32
+</programlisting></para>
+<para><programlisting>
+typedef struct {
+ unsigned long phys_indicators; /* LEDs existence */
+ XkbIndicatorMapRec maps[XkbNumIndicators]; /* indicator maps */
+} <emphasis>XkbIndicatorRec</emphasis>,*XkbIndicatorPtr;
+</programlisting></para>
+
+<para>
+This structure contains the <emphasis>
+phys_indicators</emphasis>
+ field, which relates some information about the correspondence between
+indicators and physical LEDs on the keyboard, and an array of indicator
+<emphasis>
+maps</emphasis>
+, one map per indicator.
+</para>
+
+<para>
+The <emphasis>
+phys_indicators</emphasis>
+ field indicates which indicators are bound to physical LEDs on the keyboard;
+if a bit is set in <emphasis>
+phys_indicators</emphasis>
+, then the associated indicator has a physical LED associated with it. This
+field is necessary because some indicators may not have corresponding physical
+LEDs on the keyboard. For example, most keyboards have an LED for indicating
+the state of <emphasis>
+CapsLock</emphasis>
+, but most keyboards do not have an LED that indicates the current group.
+Because <emphasis>
+phys_indicators</emphasis>
+ describes a physical characteristic of the keyboard, you cannot directly
+change it under program control. However, if a client program loads a
+completely new keyboard description via <emphasis>
+XkbGetKeyboardByName</emphasis>
+, or if a new keyboard is attached and the X implementation notices, <emphasis>
+phys_indicators</emphasis>
+ changes if the indicators for the new keyboard are different.
+</para>
+
+
+</sect2>
+<sect2 id='xkbindicatormaprec'>
+<title>XkbIndicatorMapRec</title>
+
+<para>
+Each indicator has its own set of attributes that specify whether clients can
+explicitly set its state and whether it tracks the keyboard state. The
+attributes of each indicator are held in the <emphasis>
+maps</emphasis>
+ array, which is an array of <emphasis>
+XkbIndicatorRec</emphasis>
+ structures:
+</para>
+
+<para><programlisting>
+typedef struct {
+ unsigned char flags; /* how the indicator can be changed */
+ unsigned char which_groups; /* match criteria for groups */
+ unsigned char groups; /* which keyboard groups the indicator watches */
+ unsigned char which_mods; /* match criteria for modifiers */
+ XkbModsRec mods; /* which modifiers the indicator watches */
+ unsigned int ctrls; /* which controls the indicator watches */
+} <emphasis>XkbIndicatorMapRec</emphasis>, *XkbIndicatorMapPtr;
+</programlisting></para>
+
+<para>
+This indicator map specifies for each indicator:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The conditions under which the keyboard modifier state affects the indicator
+ </para>
+</listitem>
+<listitem>
+ <para>
+The conditions under which the keyboard group state affects the indicator
+ </para>
+</listitem>
+<listitem>
+ <para>
+The conditions under which the state of the boolean controls affects the
+indicator
+ </para>
+</listitem>
+<listitem>
+ <para>
+The effect (if any) of attempts to explicitly change the state of the indicator
+using the functions <emphasis>
+XkbSetControls</emphasis>
+ or <emphasis>
+XChangeKeyboardControl</emphasis>
+
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+For more information on the effects of explicit changes to indicators and the
+relationship to the indicator map, see section 8.4.1. <!-- xref -->
+</para>
+
+<sect3 id='xkbindicatormaprec_flags_field'>
+<title>XkbIndicatorMapRec flags field</title>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field specifies the conditions under which the indicator can be changed and
+the effects of changing the indicator. The valid values for <emphasis>
+flags</emphasis>
+ and their effects are shown in Table 8.1. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>XkbIndicatorMapRec flags Field</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Value</entry>
+ <entry></entry>
+ <entry>Effect</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbIM_NoExplicit</entry>
+ <entry>(1L&lt;&lt;7)</entry>
+ <entry>Client applications cannot change the state of the indicator.</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_NoAutomatic</entry>
+ <entry>(1L&lt;&lt;6)</entry>
+ <entry>Xkb does not automatically change the value of the indicator based
+upon a change in the keyboard state, regardless of the values for the other
+fields of the indicator map.</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_LEDDrivesKB</entry>
+ <entry>(1L&lt;&lt;5)</entry>
+ <entry>A client application changing the state of the indicator causes the
+state of the keyboard to change.</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Note that if <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ is not set, by default the indicator follows the keyboard state.
+</para>
+
+
+<para>
+If <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set and <emphasis>
+XkbIM_NoExplicit</emphasis>
+ is not, and if you call a function which updates the server’s image of the
+indicator map (such as <emphasis>
+XkbSetIndicatorMap</emphasis>
+ or <emphasis>
+XkbSetNamedIndicator</emphasis>
+), Xkb changes the keyboard state and controls to reflect the other fields of
+the indicator map, as described in the remainder of this section. If you
+attempt to explicitly change the value of an indicator for which <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is absent or for which <emphasis>
+XkbIM_NoExplicit</emphasis>
+ is present, keyboard state or controls are unaffected.
+</para>
+
+
+<para>
+For example, a keyboard designer may want to make the <emphasis>
+CapsLock</emphasis>
+ LED controllable only by the server, but allow the <emphasis>
+Scroll Lock</emphasis>
+ LED to be controlled by client applications. To do so, the keyboard designer
+could set the <emphasis>
+XkbIM_NoExplicit</emphasis>
+ flag for the <emphasis>
+CapsLock</emphasis>
+<emphasis>
+ </emphasis>
+LED, but not set it for the <emphasis>
+Scroll Lock</emphasis>
+ LED. Or the keyboard designer may wish to allow the <emphasis>
+CapsLock</emphasis>
+ LED to be controlled by both the server and client applications and also have
+the server to automatically change the <emphasis>
+CapsLock</emphasis>
+<emphasis>
+ </emphasis>
+modifier state whenever a client application changes the <emphasis>
+CapsLock</emphasis>
+ LED. To do so, the keyboard designer would not set the <emphasis>
+XkbIM_NoExplicit</emphasis>
+ flag, but would instead set the <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ flag.
+</para>
+
+<para>
+The remaining fields in the indicator map specify the conditions under which
+Xkb automatically turns an indicator on or off (only if <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ is not set). If these conditions match the keyboard state, Xkb turns the
+indicator on. If the conditions do not match, Xkb turns the indicator off.
+</para>
+
+</sect3>
+
+<sect3 id='xkbindicatormaprec_which_groups_and_groups_fields'>
+<title>XkbIndicatorMapRec which_groups and groups fields</title>
+
+<para>
+The <emphasis>
+which_groups</emphasis>
+ and the <emphasis>
+groups</emphasis>
+ fields of an indicator map determine how the keyboard group state affects the
+corresponding indicator. The <emphasis>
+which_groups</emphasis>
+ field controls the interpretation of <emphasis>
+groups</emphasis>
+ and may contain any one of the following values:
+</para>
+
+<para><programlisting>
+#define XkbIM_UseNone 0
+#define XkbIM_UseBase (1L &lt;&lt; 0)
+#define XkbIM_UseLatched (1L &lt;&lt; 1)
+#define XkbIM_UseLocked (1L &lt;&lt; 2)
+#define XkbIM_UseEffective (1L &lt;&lt; 3)
+#define XkbIM_UseAnyGroup XkbIM_UseLatched | XkbIM_UseLocked |
+ XkbIM_UseEffective
+</programlisting></para>
+
+<para>
+The <emphasis>
+groups </emphasis>
+field specifies what keyboard groups an indicator watches and is the bitwise
+inclusive OR of the following valid values:
+</para>
+
+<para><programlisting>
+#define XkbGroup1Mask (1&lt;&lt;0)
+#define XkbGroup2Mask (1&lt;&lt;1)
+#define XkbGroup3Mask (1&lt;&lt;2)
+#define XkbGroup4Mask (1&lt;&lt;3)
+#define XkbAnyGroupMask (1&lt;&lt;7)
+#define XkbAllGroupsMask (0xf)
+</programlisting></para>
+
+<para>
+If <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ is not set (the keyboard drives the indicator), the effect of <emphasis>
+which_groups</emphasis>
+ and <emphasis>
+groups</emphasis>
+ is shown in Table 8.2. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>XkbIndicatorMapRec which_groups and groups, Keyboard Drives
+Indicator</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>which_groups</entry>
+ <entry>Effect</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbIM_UseNone</entry>
+ <entry>
+The <emphasis>
+groups</emphasis>
+ field and the current keyboard group state are ignored.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseBase</entry>
+ <entry>
+If <emphasis>
+groups</emphasis>
+ is nonzero, the indicator is lit whenever the base keyboard group is nonzero.
+If <emphasis>
+groups</emphasis>
+ is zero, the indicator is lit whenever the base keyboard group is zero.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>
+If <emphasis>
+groups</emphasis>
+ is nonzero, the indicator is lit whenever the latched keyboard group is
+nonzero. If <emphasis>
+groups</emphasis>
+ is zero, the indicator is lit whenever the latched keyboard group is zero.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked</entry>
+ <entry>
+The <emphasis>
+groups</emphasis>
+ field is interpreted as a mask. The indicator is lit when the current locked
+keyboard group matches one of the bits that are set in <emphasis>
+groups</emphasis>.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseEffective</entry>
+ <entry>
+The <emphasis>
+groups</emphasis>
+ field is interpreted as a mask. The indicator is lit when the current
+effective keyboard group matches one of the bits that are set in <emphasis>
+groups</emphasis>
+.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The effect of <emphasis>
+which_groups</emphasis>
+ and <emphasis>
+groups</emphasis>
+ when you change an indicator for which <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set (the indicator drives the keyboard) is shown in Table 8.3. The "New
+State" column refers to the new state to which you set the indicator.
+</para>
+
+<table frame='none'>
+<title>XkbIndicatorMapRec which_groups and groups, Indicator Drives
+Keyboard</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>which_groups</entry>
+ <entry>New State</entry>
+ <entry>Effect on Keyboard Group State</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbIM_UseNone </entry>
+ <entry>On or Off</entry>
+ <entry>No effect</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseBase</entry>
+ <entry>On or Off</entry>
+ <entry>No effect</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>On</entry>
+ <entry>
+The <emphasis>
+groups</emphasis>
+ field is treated as a group mask. The keyboard group latch is changed to the
+lowest numbered group specified in <emphasis>
+groups</emphasis>
+; if <emphasis>
+groups</emphasis>
+ is empty, the keyboard group latch is changed to zero.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>Off</entry>
+ <entry>
+The <emphasis>
+groups</emphasis>
+ field is treated as a group mask. If the indicator is explicitly extinguished,
+keyboard group latch is changed to the lowest numbered group not specified in
+<emphasis>
+groups</emphasis>
+; if <emphasis>
+groups</emphasis>
+ is zero, the keyboard group latch is set to the index of the highest legal
+keyboard group.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked or XkbIM_UseEffective</entry>
+ <entry>On</entry>
+ <entry>
+If the <emphasis>
+groups</emphasis>
+ mask is empty, group is not changed; otherwise, the locked keyboard group is
+changed to the lowest numbered group specified in <emphasis>
+groups</emphasis>.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked or XkbIM_UseEffective</entry>
+ <entry>Off</entry>
+ <entry>
+Locked keyboard group is changed to the lowest numbered group that is not
+specified in the <emphasis>
+groups</emphasis>
+ mask, or to <emphasis>
+Group1</emphasis>
+ if the <emphasis>
+groups</emphasis>
+ mask contains all keyboard groups.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect3>
+<sect3 id='xkbindicatormaprec_which_mods_and_mods_fields'>
+<title>XkbIndicatorMapRec which_mods and mods fields</title>
+
+<para>
+The <emphasis>
+mods </emphasis>
+field specifies what modifiers an indicator watches. The <emphasis>
+mods</emphasis>
+ field is an Xkb modifier definition, <emphasis>
+XkbModsRec</emphasis>
+, as described in section 7.2, which can specify both real and virtual <!-- xref -->
+modifiers. The <emphasis>
+mods</emphasis>
+ field takes effect even if some or all of the virtual indicators specified in
+<emphasis>
+mods</emphasis>
+ are unbound. To specify the mods field, in general, assign the modifiers of
+interest to <emphasis>
+mods.real_mods</emphasis>
+ and the virtual modifiers of interest to <emphasis>
+mods.vmods</emphasis>
+. You can disregard the <emphasis>
+mods.mask</emphasis>
+ field unless your application needs to interpret the indicator map directly
+(that is, to simulate automatic indicator behavior on its own). Relatively few
+applications need to do so, but if you find it necessary, you can either read
+the indicator map back from the server after you update it (the server
+automatically updates the mask field whenever any of the real or virtual
+modifiers are changed in the modifier definition) or you can use <emphasis>
+XkbVirtualModsToReal</emphasis>
+ to determine the proper contents for the mask field, assuming that the
+<emphasis>
+XkbDescRec</emphasis>
+ contains the virtual modifier definitions.
+</para>
+
+<para>
+<emphasis>
+which_mods</emphasis>
+ specifies what criteria Xkb uses to determine a match with the corresponding
+<emphasis>
+mods</emphasis>
+ field by specifying one or more components of the Xkb keyboard state. If
+<emphasis>
+XkbIM_NoAutomatic</emphasis>
+ is not set (the keyboard drives the indicator), the indicator is lit whenever
+any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of the<emphasis>
+ mods</emphasis>
+ modifier definition are also set in any of the current keyboard state
+components specified by <emphasis>
+which_mods</emphasis>
+. Remember that the <emphasis>
+mask</emphasis>
+ field is comprised of all of the real modifiers specified in the definition
+plus any real modifiers that are bound to the virtual modifiers specified in
+the definition. (See Chapter 5 for more information on the keyboard state and <!-- xref -->
+Chapter 7 for more information on virtual modifiers.) Use a bitwise inclusive
+OR of the following values to compose a value for <emphasis>
+which_mods</emphasis>:
+</para>
+
+<para><programlisting>
+#define XkbIM_UseNone 0
+#define XkbIM_UseBase (1L &lt;&lt; 0)
+#define XkbIM_UseLatched (1L &lt;&lt; 1)
+#define XkbIM_UseLocked (1L &lt;&lt; 2)
+#define XkbIM_UseEffective (1L &lt;&lt; 3)
+#define XkbIM_UseCompat (1L &lt;&lt; 4)
+#define XkbIM_UseAnyMods XkbIM_UseBase | XkbIM_UseLatched |
+ XkbIM_UseLocked | XkbIM_UseEffective |
+ XkbIM_UseCompat
+</programlisting></para>
+
+<para>
+If <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ is not set (the keyboard drives the indicator), the effect of <emphasis>
+which_mods</emphasis>
+ and <emphasis>
+mods</emphasis>
+ is shown in Table 8.4 <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>XkbIndicatorMapRec which_mods and mods, Keyboard Drives Indicator</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>which_mods</entry>
+ <entry>Effect on Keyboard Modifiers</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbIM_UseNone</entry>
+ <entry>The mods field and the current keyboard modifier state are
+ignored.</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseBase</entry>
+ <entry>
+The indicator is lit when any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are on in the keyboard base state. If both <emphasis>
+mods.real_mods</emphasis>
+ and <emphasis>
+mods.vmods</emphasis>
+ are zero, the indicator is lit when the base keyboard state contains no
+modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>
+The indicator is lit when any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are latched. If both <emphasis>
+mods.real_mods</emphasis>
+ and <emphasis>
+mods.vmods</emphasis>
+ are zero, the indicator is lit when none of the modifier keys are latched.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked</entry>
+ <entry>
+The indicator is lit when any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are locked. If both <emphasis>
+mods.real_mods</emphasis>
+ and <emphasis>
+mods.vmods</emphasis>
+ are zero, the indicator is lit when none of the modifier keys are locked.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseEffective</entry>
+ <entry>
+The indicator is lit when any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are in the effective keyboard state. If both <emphasis>
+mods.real_mods</emphasis>
+ and <emphasis>
+mods.vmods</emphasis>
+ are zero, the indicator is lit when the effective keyboard state contains no
+modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseCompat</entry>
+ <entry>
+The indicator is lit when any of the modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are in the keyboard compatibility state. If both <emphasis>
+mods.real_mods</emphasis>
+ and <emphasis>
+mods.vmods</emphasis>
+ are zero, the indicator is lit when the keyboard compatibility state contains
+no modifiers.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The effect on the keyboard modifiers of <emphasis>
+which_mods</emphasis>
+ and <emphasis>
+mods</emphasis>
+ when you change an indicator for which <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set (the indicator drives the keyboard) is shown in Table 8.5. The "New
+State" column refers to the new state to which you set the indicator.
+</para> <!-- xref -->
+
+<table frame='none'>
+<title>XkbIndicatorMapRec which_mods and mods, Indicator Drives Keyboard</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>which_mods</entry>
+ <entry>New State</entry>
+ <entry>Effect on Keyboard Modifiers</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbIM_UseNone or XkbIM_UseBase</entry>
+ <entry>On or Off</entry>
+ <entry>No Effect</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>On</entry>
+ <entry>
+Any modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are added to the latched modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLatched</entry>
+ <entry>Off</entry>
+ <entry>
+Any modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are removed from the latched modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked, XkbIM_UseCompat, or XkbIM_UseEffective</entry>
+ <entry>On</entry>
+ <entry>
+Any modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are added to the locked modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseLocked</entry>
+ <entry>Off</entry>
+ <entry>
+Any modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are removed from the locked modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIM_UseCompat or XkbIM_UseEffective</entry>
+ <entry>Off</entry>
+ <entry>
+Any modifiers specified in the <emphasis>
+mask</emphasis>
+ field of <emphasis>
+mods</emphasis>
+ are removed from both the locked and latched modifiers.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect3>
+<sect3 id='xkbindicatormaprec_ctrls_field'>
+<title>XkbIndicatorMapRec ctrls field</title>
+
+<para>
+The <emphasis>
+ctrls</emphasis>
+ field specifies what controls (see Chapter 10) the indicator watches and is
+composed using the bitwise inclusive OR of the following values:
+</para> <!-- xref -->
+
+<para><programlisting>
+#define XkbRepeatKeysMask (1L &lt;&lt; 0)
+#define XkbSlowKeysMask (1L &lt;&lt; 1)
+#define XkbBounceKeysMask (1L &lt;&lt; 2)
+#define XkbStickyKeysMask (1L &lt;&lt; 3)
+#define XkbMouseKeysMask (1L &lt;&lt; 4)
+#define XkbMouseKeysAccelMask (1L &lt;&lt; 5)
+#define XkbAccessXKeysMask (1L &lt;&lt; 6)
+#define XkbAccessXTimeoutMask (1L &lt;&lt; 7)
+#define XkbAccessXFeedbackMask (1L &lt;&lt; 8)
+#define XkbAudibleBellMask (1L &lt;&lt; 9)
+#define XkbOverlay1Mask (1L &lt;&lt; 10)
+#define XkbOverlay2Mask (1L &lt;&lt; 11)
+#define XkbAllBooleanCtrlsMask (0x00001FFF)
+</programlisting></para>
+
+<para>
+Xkb lights the indicator whenever any of the boolean controls specified in
+<emphasis>
+ctrls</emphasis>
+ is enabled.
+</para>
+
+
+</sect3>
+</sect2>
+</sect1>
+<sect1 id='getting_information_about_indicators'>
+<title>Getting Information About Indicators</title>
+
+<para>
+Xkb allows applications to obtain information about indicators using two
+different methods. The first method, which is similar to the core X
+implementation, uses a mask to specify the indicators. The second method, which
+is more suitable for applications concerned with interoperability, uses
+indicator names. The correspondence between the indicator name and the bit
+position in masks is as follows: one of the parameters returned from <emphasis>
+XkbGetNamedIndicators</emphasis>
+ is an index that is the bit position to use in any function call that requires
+a mask of indicator bits, as well as the indicator’s index into the <emphasis>
+XkbIndicatorRec</emphasis>
+ array of indicator maps.
+</para>
+
+
+<sect2 id='getting_indicator_state'>
+<title>Getting Indicator State</title>
+
+<para>
+Because the state of the indicators is relatively volatile, the keyboard
+description does not hold the current state of the indicators. To obtain the
+current state of the keyboard indicators, use <emphasis>
+XkbGetIndicatorState</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetIndicatorState</emphasis>
+(<emphasis>
+display</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+state_return</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+state_return</emphasis>
+; /* backfilled with a mask of the indicator state */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetIndicatorState</emphasis>
+ queries the <emphasis>
+display</emphasis>
+ for the state of the indicators on the device specified by the <emphasis>
+device_spec</emphasis>
+. For each indicator that is "turned on" on the device, the associated bit is
+set in <emphasis>
+state_return</emphasis>
+. If a compatible version of the Xkb extension is not available in the server,
+<emphasis>
+XkbGetIndicatorState</emphasis>
+ returns a <emphasis>
+BadMatch</emphasis>
+ error. Otherwise, it sends the request to the X server, places the state of
+the indicators into <emphasis>
+state_return,</emphasis>
+ and returns <emphasis>
+Success</emphasis>
+. Thus the value reported by <emphasis>
+XkbGetIndicatorState</emphasis>
+ is identical to the value reported by the core protocol.
+</para>
+
+
+</sect2>
+<sect2 id='getting_indicator_information_by_index'>
+<title>Getting Indicator Information by Index</title>
+
+<para>
+To get the map for one or more indicators, using a mask to specify the
+indicators, use <emphasis>
+XkbGetIndicatorMap</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetIndicatorMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ which</emphasis>
+,<emphasis>
+ desc</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of indicators for which maps should be returned */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+desc</emphasis>
+; /* keyboard description to be updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetIndicatorMap</emphasis>
+ obtains the maps from the server for only those indicators specified by the
+<emphasis>
+which</emphasis>
+ mask and copies the values into the keyboard description specified by
+<emphasis>
+desc</emphasis>
+. If the <emphasis>
+indicators</emphasis>
+ field of the <emphasis>
+desc</emphasis>
+ parameter is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetIndicatorMap</emphasis>
+ allocates and initializes it.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetIndicatorMap</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadLength</emphasis>
+, <emphasis>
+BadMatch</emphasis>
+, and <emphasis>
+BadImplementation</emphasis>
+ errors.
+</para>
+
+
+<para>
+To free the indicator maps, use <emphasis>
+XkbFreeIndicatorMaps</emphasis>
+ (see section 8.6).
+</para>
+
+
+</sect2>
+<sect2 id='getting_indicator_information_by_name'>
+<title>Getting Indicator Information by Name</title>
+
+<para>
+Xkb also allows applications to refer to indicators by name. Use <emphasis>
+XkbGetNames</emphasis>
+ to get the indicator names (see Chapter 18). Using names eliminates the need
+for hard-coding bitmask values for particular keyboards. For example, instead
+of using vendor-specific constants such as <emphasis>
+WSKBLed_ScrollLock</emphasis>
+ mask on Digital workstations or <emphasis>
+XLED_SCROLL_LOCK</emphasis>
+ on Sun workstations, you can instead use <emphasis>
+XkbGetNamedIndicator</emphasis>
+ to look up information on the indicator named "Scroll Lock."
+</para>
+
+<para>
+Use <emphasis>
+XkbGetNamedIndicator</emphasis>
+ to look up the indicator map and other information for an indicator by name.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetNamedIndicator</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ dev_spec</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ ndx_rtrn</emphasis>
+,<emphasis>
+ state_rtrn</emphasis>
+,<emphasis>
+ map_rtrn</emphasis>
+, <emphasis>
+real_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ device_spec</emphasis>
+; /* keyboard device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the indicator to be retrieved */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+ndx_rtrn</emphasis>
+; /* backfilled with the index of the retrieved indicator */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool * <emphasis>
+state_rtrn</emphasis>
+; /* backfilled with the current state of the retrieved indicator */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorMapPtr <emphasis>
+ map_rtrn</emphasis>
+; /* backfilled with the mapping for the retrieved indicator */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool * <emphasis>
+real_rtrn</emphasis>
+; /* backfilled with <emphasis>
+True</emphasis>
+ if the named indicator is real (physical) */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If the device specified by <emphasis>
+device_spec</emphasis>
+ has an indicator named <emphasis>
+name</emphasis>
+,<emphasis>
+ XkbGetNamedIndicator</emphasis>
+ returns <emphasis>
+True</emphasis>
+ and populates the rest of the parameters with information about the indicator.
+Otherwise, <emphasis>
+XkbGetNamedIndicator</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+ndx_rtrn</emphasis>
+ field returns the zero-based index of the named indicator. This index is the
+bit position to use in any function call that requires a mask of indicator
+bits, as well as the indicator’s index into the <emphasis>
+XkbIndicatorRec</emphasis>
+ array of indicator maps. <emphasis>
+state_rtrn</emphasis>
+ returns the current state of the named indicator (<emphasis>
+True</emphasis>
+ = on, <emphasis>
+False</emphasis>
+ = off). <emphasis>
+map_rtrn</emphasis>
+ returns the indicator map for the named indicator. In addition, if the
+indicator is mapped to a physical LED, the <emphasis>
+real_rtrn</emphasis>
+ parameter is set to <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+Each of the "<emphasis>
+_rtrn</emphasis>
+" arguments is optional; you can pass <emphasis>
+NULL</emphasis>
+ for any unneeded "<emphasis>
+_rtrn</emphasis>
+" arguments.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetNamedIndicator</emphasis>
+ can generate <emphasis>
+BadAtom</emphasis>
+ and <emphasis>
+BadImplementation</emphasis>
+ errors.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='changing_indicator_maps_and_state'>
+<title>Changing Indicator Maps and State</title>
+
+<para>
+Just as you can get the indicator map using a mask or using an indicator name,
+so you can change it using a mask or a name.
+</para>
+
+<note><para>You cannot change the <emphasis>
+phys_indicators</emphasis>
+ field of the indicators structure. The only way to change the <emphasis>
+phys_indicators</emphasis>
+ field is to change the keyboard map.</para></note>
+
+<para>
+There are two ways to make changes to indicator maps and state: either change a
+local copy of the indicator maps and use <emphasis>
+XkbSetIndicatorMap</emphasis>
+ or <emphasis>
+XkbSetNamedIndicator</emphasis>
+, or, to reduce network traffic, use an<emphasis>
+ XkbIndicatorChangesRec</emphasis>
+ structure and use <emphasis>
+XkbChangeIndicators</emphasis>.
+</para>
+
+
+<sect2 id='effects_of_explicit_changes_on_indicators'>
+<title>Effects of Explicit Changes on Indicators</title>
+
+<para>
+This section discusses the effects of explicitly changing indicators depending
+upon different settings in the indicator map. See Tables 8.3 and Table 8.5 for
+information on the effects of the indicator map fields when explicit changes
+are made.
+</para>
+
+
+<para>
+If <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set and <emphasis>
+XkbIM_NoExplicit</emphasis>
+ is not, and if you call a function that updates the server’s image of the
+indicator map (such as <emphasis>
+XkbSetIndicatorMap</emphasis>
+ or <emphasis>
+XkbSetNamedIndicator</emphasis>
+), Xkb changes the keyboard state and controls to reflect the other fields of
+the indicator map. If you attempt to explicitly change the value of an
+indicator for which <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is absent or for which <emphasis>
+XkbIM_NoExplicit</emphasis>
+ is present, keyboard state or controls are unaffected.
+</para>
+
+
+<para>
+If neither <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ nor <emphasis>
+XkbIM_NoExplicit</emphasis>
+ is set in an indicator map, Xkb honors any request to change the state of the
+indicator, but the new state might be immediately superseded by automatic
+changes to the indicator state if the keyboard state or controls change.
+</para>
+
+
+<para>
+The effects of changing an indicator that drives the keyboard are cumulative;
+it is possible for a single change to affect keyboard group, modifiers, and
+controls simultaneously.
+</para>
+
+
+<para>
+If you change an indicator for which both the <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ and <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ flags are specified, Xkb applies the keyboard changes specified in the other
+indicator map fields and changes the indicator to reflect the state that was
+explicitly requested. The indicator remains in the new state until it is
+explicitly changed again.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbIM_NoAutomatic</emphasis>
+ flag is not set and <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set, Xkb applies the changes specified in the other indicator map fields
+and sets the state of the indicator to the values specified by the indicator
+map. Note that it is possible in this case for the indicator to end up in a
+different state than the one that was explicitly requested. For example, Xkb
+does not extinguish an indicator with <emphasis>
+which_mods</emphasis>
+ of <emphasis>
+XkbIM_UseBase</emphasis>
+ and <emphasis>
+mods</emphasis>
+ of <emphasis>
+Shift</emphasis>
+ if, at the time Xkb processes the request to extinguish the indicator, one of
+the <emphasis>
+Shift</emphasis>
+ keys is physically depressed.
+</para>
+
+
+<para>
+If you explicitly light an indicator for which <emphasis>
+XkbIM_LEDDrivesKB</emphasis>
+ is set, Xkb enables all of the boolean controls specified in the <emphasis>
+ctrls</emphasis>
+ field of its indicator map. Explicitly extinguishing such an indicator causes
+Xkb to disable all of the boolean controls specified in <emphasis>
+ctrls</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='changing_indicator_maps_by_index'>
+<title>Changing Indicator Maps by Index</title>
+
+<para>
+To update the maps for one or more indicators, first modify a local copy of the
+keyboard description, then use <emphasis>
+XkbSetIndicatorMap</emphasis>
+ to download the changes to the server:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool<emphasis>
+ XkbSetIndicatorMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ which</emphasis>
+,<emphasis>
+ desc</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of indicators to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+desc</emphasis>
+; /* keyboard description from which the maps are taken */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+For each<emphasis>
+ </emphasis>
+bit set in the <emphasis>
+which </emphasis>
+parameter,<emphasis>
+ XkbSetIndicatorMap</emphasis>
+ sends the corresponding indicator map from the <emphasis>
+desc</emphasis>
+ parameter to the server.
+</para>
+
+
+</sect2>
+<sect2 id='changing_indicator_maps_by_name'>
+<title>Changing Indicator Maps by Name</title>
+
+<para>
+<emphasis>
+XkbSetNamedIndicator</emphasis>
+ can do several related things:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Name an indicator if it is not already named
+ </para>
+</listitem>
+<listitem>
+ <para>
+Toggle the state of the indicator
+ </para>
+</listitem>
+<listitem>
+ <para>
+Set the indicator to a specified state
+ </para>
+</listitem>
+<listitem>
+ <para>
+Set the indicator map for the indicator
+ </para>
+</listitem>
+</itemizedlist>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool<emphasis>
+ XkbSetNamedIndicator</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ change_state, state</emphasis>
+,<emphasis>
+ create_new</emphasis>
+,<emphasis>
+ map</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the indicator to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ change_state</emphasis>
+; /* whether to change the indicator state or not */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ state</emphasis>
+; /* desired new state for the indicator */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+create_new</emphasis>
+; /* whether a new indicator with the specified name should be
+created when necessary */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorMapPtr <emphasis>
+map</emphasis>
+; /* new map for the indicator */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible version of the Xkb extension is not available in the server,
+<emphasis>
+XkbSetNamedIndicator</emphasis>
+ returns <emphasis>
+False</emphasis>
+. Otherwise, it sends a request to the X server to change the indicator
+specified by <emphasis>
+name</emphasis>
+ and returns <emphasis>
+True</emphasis>.
+</para>
+
+
+<para>
+If <emphasis>
+change_state</emphasis>
+ is <emphasis>
+True</emphasis>
+, and the optional parameter, <emphasis>
+state</emphasis>
+, is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbSetNamedIndicator</emphasis>
+ tells the server to change the state of the named indicator to the value
+specified by <emphasis>
+state</emphasis>.
+</para>
+
+
+<para>
+If an indicator with the name specified by <emphasis>
+name</emphasis>
+ does not already exist, the <emphasis>
+create_new</emphasis>
+ parameter tells the server whether it should create a new named indicator. If
+<emphasis>
+create_new</emphasis>
+ is <emphasis>
+True</emphasis>
+, the server finds the first indicator that doesn’t have a name and gives it
+the name specified by <emphasis>
+name</emphasis>.
+</para>
+
+
+<para>
+If the optional parameter, <emphasis>
+map</emphasis>
+, is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbSetNamedIndicator</emphasis>
+ tells the server to change the indicator’s map to the values specified
+in <emphasis>map</emphasis>.
+</para>
+
+<para>
+<emphasis>
+XkbSetNamedIndicator</emphasis>
+ can generate <emphasis>
+BadAtom</emphasis>
+ and <emphasis>
+BadImplementation</emphasis>
+ errors. In addition, it can also generate <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ (see section 8.5), <emphasis> <!-- xref -->
+XkbIndicatorMapNotify</emphasis>
+, and <emphasis>
+XkbNamesNotify</emphasis>
+ events (see section 18.5). <!-- xref -->
+</para>
+
+
+</sect2>
+<sect2 id='the_xkbindicatorchangesrec_structure'>
+<title>The XkbIndicatorChangesRec Structure</title>
+
+<para>
+The <emphasis>
+XkbIndicatorChangesRec</emphasis>
+ identifies small modifications to the indicator map. Use it with the function
+<emphasis>
+XkbChangeIndicators</emphasis>
+ to reduce the amount of traffic sent to the server.
+</para>
+
+<para><programlisting>
+typedef struct _XkbIndicatorChanges {
+ unsigned int state_changes;
+ unsigned int map_changes;
+}<emphasis>
+XkbIndicatorChangesRec</emphasis>,*XkbIndicatorChangesPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+state_changes</emphasis>
+ field is a mask that specifies the indicators that have changed state, and
+<emphasis>
+map_changes</emphasis>
+ is a mask that specifies the indicators whose maps have changed.
+</para>
+
+
+<para>
+To change indicator maps or state without passing the entire keyboard
+description, use <emphasis>
+XkbChangeIndicators</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeIndicators</emphasis>
+(<emphasis>
+dpy, xkb, changes, state</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description from which names are to be
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+ taken. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorChangesPtr <emphasis>
+changes</emphasis>
+; /* indicators to be updated on the server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+state</emphasis>
+; /* new state of indicators listed in
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+<emphasis>
+ changes</emphasis>
+-&gt;<emphasis>
+state_changes</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeIndicators</emphasis>
+ copies any maps specified by <emphasis>
+changes</emphasis>
+ from the keyboard description, <emphasis>
+xkb</emphasis>
+, to the server specified by <emphasis>
+dpy</emphasis>
+. If any bits are set in the <emphasis>
+state_changes</emphasis>
+ field of <emphasis>
+changes</emphasis>
+, <emphasis>
+XkbChangeIndicators</emphasis>
+ also sets the state of those indicators to the values specified in the
+<emphasis>
+state</emphasis>
+ mask. A 1 bit in <emphasis>
+state</emphasis>
+ turns the corresponding indicator on, a 0 bit turns it off.
+</para>
+
+
+<para>
+<emphasis>
+XkbChangeIndicator</emphasis>
+s can generate <emphasis>
+BadAtom</emphasis>
+ and <emphasis>
+BadImplementation</emphasis>
+ errors. In addition, it can also generate <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ and <emphasis>
+XkbIndicatorMapNotify</emphasis>
+ events (see section 8.5). <!-- xref -->
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='tracking_changes_to_indicator_state_or_map'>
+<title>Tracking Changes to Indicator State or Map</title>
+
+<para>
+Whenever an indicator changes state, the server sends <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ events to all interested clients. Similarly, whenever an indicator’s map
+changes, the server sends <emphasis>
+XkbIndicatorMapNotify</emphasis>
+ events to all interested clients.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ events, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) with both the <emphasis> <!-- xref -->
+bits_to_change </emphasis>
+and<emphasis>
+ values_for_bits</emphasis>
+ parameters containing <emphasis>
+XkbIndicatorStateNotifyMask</emphasis>
+. To receive <emphasis>
+XkbIndicatorMapNotify</emphasis>
+ events, use <emphasis>
+XkbSelectEvents</emphasis>
+ with <emphasis>
+XkbIndicatorMapNotifyMask</emphasis>
+.
+</para>
+
+
+<para>
+To receive events for only specific indicators, use <emphasis>
+XkbSelectEventDetails</emphasis>
+. Set the <emphasis>
+event_type</emphasis>
+ parameter<emphasis>
+ to XkbIndicatorStateNotify</emphasis>
+ or <emphasis>
+XkbIndicatorMapNotify</emphasis>
+, and set both the <emphasis>
+bits_to_change </emphasis>
+and<emphasis>
+ values_for_bits</emphasis>
+ detail parameters to a mask where each bit specifies one indicator, turning on
+those bits that specify the indicators for which you want to receive events.
+</para>
+
+
+<para>
+Both types of indicator events use the same structure:
+</para>
+
+<para><programlisting>
+typedef struct _XkbIndicatorNotify {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* specifies state or map notify */
+ int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ unsigned int changed; /* mask of indicators with new state or map */
+ unsigned int state; /* current state of all indicators */
+} <emphasis>XkbIndicatorNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+<emphasis>
+xkb_type</emphasis>
+ is either <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ or <emphasis>
+XkbIndicatorMapNotify</emphasis>
+, depending on whether the event is a <emphasis>
+kbIndicatorStateNotify</emphasis>
+ event or <emphasis>
+kbIndicatorMapNotify</emphasis>
+ event.
+</para>
+
+<para>
+The <emphasis>
+changed</emphasis>
+ parameter is a mask that is the bitwise inclusive OR of the indicators that
+have changed. If the event is of type <emphasis>
+XkbIndicatorMapNotify</emphasis>
+, <emphasis>
+changed</emphasis>
+ reports the maps that changed. If the event is of type <emphasis>
+XkbIndicatorStateNotify</emphasis>
+, <emphasis>
+changed</emphasis>
+ reports the indicators that have changed state. <emphasis>
+state</emphasis>
+ is a mask that specifies the current state of all indicators, whether they
+have changed or not, for both <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ and <emphasis>IndicatorMapNotify</emphasis> events.
+</para>
+
+<para>
+When your client application receives either a <emphasis>
+XkbIndicatorStateNotify</emphasis>
+ event or <emphasis>
+XkbIndicatorMapNotify</emphasis>
+ event, you can note the changes in a changes structure by calling <emphasis>
+XkbNoteIndicatorChanges</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbNoteIndicatorChanges</emphasis>
+(<emphasis>
+old</emphasis>
+,<emphasis>
+ new</emphasis>
+,<emphasis>
+ wanted</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorChangesPtr <emphasis>
+ old</emphasis>
+; /* XkbIndicatorChanges structure to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorNotifyEvent * <emphasis>
+new</emphasis>
+; /* event from which changes are to be copied */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ wanted</emphasis>
+; /* which changes are to be noted */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+wanted</emphasis>
+ parameter is the bitwise inclusive OR of <emphasis>
+XkbIndicatorMapMask</emphasis>
+ and <emphasis>
+XkbIndicatorStateMask</emphasis>
+. <emphasis>
+XkbNoteIndicatorChanges</emphasis>
+ copies any changes reported in <emphasis>
+new</emphasis>
+ and specified in <emphasis>
+wanted</emphasis>
+ into the changes record specified by <emphasis>
+old</emphasis>.
+</para>
+
+
+<para>
+To update a local copy of the keyboard description with the actual values, pass
+the results of one or more calls to <emphasis>
+XkbNoteIndicatorChanges</emphasis>
+ to <emphasis>
+XkbGetIndicatorChanges</emphasis>:
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetIndicatorChanges</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+,<emphasis>
+ changes</emphasis>
+,<emphasis>
+ state</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description to hold the new values */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbIndicatorChangesPtr <emphasis>
+changes</emphasis>
+; /* indicator maps/state to be obtained from the server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+state</emphasis>
+; /* backfilled with the state of the indicators */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetIndicatorChanges</emphasis>
+ examines the <emphasis>
+changes</emphasis>
+ parameter, pulls over the necessary information from the server, and copies
+the results into the <emphasis>
+xkb</emphasis>
+ keyboard description. If any bits are set in the <emphasis>
+state_changes</emphasis>
+ field of <emphasis>
+changes</emphasis>
+, <emphasis>
+XkbGetIndicatorChanges</emphasis>
+ also places the state of those indicators in <emphasis>
+state</emphasis>
+. If the <emphasis>
+indicators</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetIndicatorChanges</emphasis>
+ allocates and initializes it. To free the <emphasis>
+indicators</emphasis>
+ field, use <emphasis>
+XkbFreeIndicators</emphasis>
+ (see section 8.6). <!-- xref -->
+</para>
+
+
+<para>
+<emphasis>
+XkbGetIndicatorChanges</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadImplementation,</emphasis>
+ and <emphasis>
+BadMatch</emphasis>
+ errors.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_indicator_maps'>
+<title>Allocating and Freeing Indicator Maps</title>
+
+<para>
+Most applications do not need to directly allocate the <emphasis>
+indicators</emphasis>
+ member of the keyboard description record (the keyboard description record is
+described in Chapter 6). If the need arises, however, use <emphasis>
+XkbAllocIndicatorMaps.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocIndicatorMaps</emphasis>
+(<emphasis>
+xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description structure */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+xkb</emphasis>
+ parameter must point to a valid keyboard description. If it doesn’t,
+<emphasis>
+XkbAllocIndicatorMaps</emphasis>
+ returns a <emphasis>
+BadMatch</emphasis>
+ error. Otherwise, <emphasis>
+XkbAllocIndicatorMaps</emphasis>
+ allocates and initializes the <emphasis>
+indicators</emphasis>
+ member of the keyboard description record and returns <emphasis>
+Success</emphasis>
+. If <emphasis>
+XkbAllocIndicatorMaps</emphasis>
+ was unable to allocate the indicators record, it reports a Bad<emphasis>
+Alloc</emphasis>
+ error.
+</para>
+
+<para>
+To free memory used by the <emphasis>
+indicators</emphasis>
+ member of an <emphasis>
+XkbDescRec</emphasis>
+ structure, use <emphasis>
+XkbFreeIndicatorMaps.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeIndicatorMaps</emphasis>
+(<emphasis>
+xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description structure */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If the <emphasis>indicators</emphasis>
+ member of the keyboard description record
+pointed to by <emphasis>xkb</emphasis>
+is not <emphasis>NULL</emphasis>
+, <emphasis>XkbFreeIndicatorMaps</emphasis>
+frees the memory associated with
+the <emphasis>indicators</emphasis>
+member of <emphasis>xkb</emphasis>.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch09.xml b/libX11/specs/XKB/ch09.xml
new file mode 100644
index 000000000..d04669a12
--- /dev/null
+++ b/libX11/specs/XKB/ch09.xml
@@ -0,0 +1,1060 @@
+<chapter id='bells'>
+<title>Bells</title>
+
+<para>
+The core X protocol allows only applications to explicitly sound the system
+bell with a given duration, pitch, and volume. Xkb extends this capability by
+allowing clients to attach symbolic names to bells, disable audible bells, and
+receive an event whenever the keyboard bell is rung. For the purposes of this
+document, the <emphasis>
+audible</emphasis>
+ bell is defined to be the system bell, or the default keyboard bell, as
+opposed to any other audible sound generated elsewhere in the system.
+</para>
+
+
+<para>
+You can ask to receive <emphasis>
+XkbBellNotify</emphasis>
+ events (see section 9.4) when any client rings any one of the following: <!-- xref -->
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The default bell
+ </para>
+</listitem>
+<listitem>
+ <para>
+Any bell on an input device that can be specified by a <emphasis>
+bell_class</emphasis>
+ and <emphasis>
+bell_id</emphasis>
+ pair
+ </para>
+</listitem>
+<listitem>
+ <para>
+Any bell specified only by an arbitrary name. (This is, from the server’s
+point of view, merely a name, and not connected with any physical
+sound-generating device. Some client application must generate the sound, or
+visual feedback, if any, that is associated with the name.)
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+You can also ask to receive <emphasis>
+XkbBellNotify</emphasis>
+ events when the server rings the default bell or if any client has requested
+events only (without the bell sounding) for any of the bell types previously
+listed.
+</para>
+
+<para>
+You can disable audible bells on a global basis (to set the <emphasis>
+AudibleBell</emphasis>
+ control, see Chapter 10). For example, a client that replaces the keyboard
+bell with some other audible cue might want to turn off the <emphasis>
+AudibleBell</emphasis>
+ control to prevent the server from also generating a sound and avoid
+cacophony. If you disable audible bells and request to receive <emphasis>
+XkbBellNotify</emphasis>
+ events, you can generate feedback different from the default bell.
+</para>
+
+
+<para>
+You can, however, override the <emphasis>
+AudibleBell</emphasis>
+ control by calling one of the functions that force the ringing of a bell in
+spite of the setting of the <emphasis>
+AudibleBell</emphasis>
+ control — <emphasis>
+XkbForceDeviceBell</emphasis>
+ or <emphasis>
+XkbForceBell</emphasis>
+ (see section 9.3.3). In this case the server does not generate a bell event. <!-- xref -->
+</para>
+
+
+<para>
+Just as some keyboards can produce keyclicks to indicate when a key is pressed
+or repeating, Xkb can provide feedback for the controls by using special beep
+codes. The <emphasis>
+AccessXFeedback</emphasis>
+ control is used to configure the specific types of operations that generate
+feedback. See section 10.6.3 for a discussion on <emphasis> <!-- xref -->
+AccessXFeedback</emphasis>
+ control.
+</para>
+
+<para>
+This chapter describes bell names, the functions used to generate named bells,
+and the events the server generates for bells.
+</para>
+
+<sect1 id='bell_names'>
+<title>Bell Names</title>
+
+<para>
+You can associate a name to an act of ringing a bell by converting the name to
+an Atom and then using this name when you call the functions listed in this
+chapter. If an event is generated as a result, the name is then passed to all
+other clients interested in receiving <emphasis>
+XkbBellNotify</emphasis>
+ events. Note that these are arbitrary names and that there is no binding to
+any sounds. Any sounds or other effects (such as visual bells on the screen)
+must be generated by a client application upon receipt of the bell event
+containing the name. There is no default name for the default keyboard bell.
+The server does generate some predefined bells for the AccessX controls (see
+section 10.6.3). These named bells are shown in Table 9.1; the name is included
+in any bell event sent to clients that have requested to receive <emphasis>
+XkbBellNotify</emphasis>
+ events.
+</para>
+
+<table frame='none'>
+<title>Predefined Bells</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Action</entry>
+ <entry>Named Bell</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>Indicator turned on</entry>
+ <entry>AX_IndicatorOn</entry>
+</row>
+<row rowsep='0'>
+ <entry>Indicator turned off</entry>
+ <entry>AX_IndicatorOff</entry>
+</row>
+<row rowsep='0'>
+ <entry>More than one indicator changed state</entry>
+ <entry>AX_IndicatorChange</entry>
+</row>
+<row rowsep='0'>
+ <entry>Control turned on</entry>
+ <entry>AX_FeatureOn</entry>
+</row>
+<row rowsep='0'>
+ <entry>Control turned off</entry>
+ <entry>AX_FeatureOff</entry>
+</row>
+<row rowsep='0'>
+ <entry>More than one control changed state</entry>
+ <entry>AX_FeatureChange</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys and BounceKeys about to be turned on or off</entry>
+ <entry>AX_SlowKeysWarning</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key pressed</entry>
+ <entry>AX_SlowKeyPress</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key accepted</entry>
+ <entry>AX_SlowKeyAccept</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key rejected</entry>
+ <entry>AX_SlowKeyReject</entry>
+</row>
+<row rowsep='0'>
+ <entry>Accepted SlowKeys key released</entry>
+ <entry>AX_SlowKeyRelease</entry>
+</row>
+<row rowsep='0'>
+ <entry>BounceKeys key rejected</entry>
+ <entry>AX_BounceKeyReject</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key latched</entry>
+ <entry>AX_StickyLatch</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key locked</entry>
+ <entry>AX_StickyLock</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key unlocked</entry>
+ <entry>AX_StickyUnlock</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='audible_bells'>
+<title>Audible Bells</title>
+
+<para>
+Using Xkb you can generate bell events that do not necessarily ring the system
+bell. This is useful if you need to use an audio server instead of the system
+beep. For example, when an audio client starts, it could disable the audible
+bell (the system bell) and then listen for <emphasis>
+XkbBellNotify</emphasis>
+ events (see section 9.4). When it receives a <emphasis> <!-- xref -->
+XkbBellNotify</emphasis>
+ event, the audio client could then send a request to an audio server to play a
+sound.
+</para>
+
+
+<para>
+You can control the audible bells feature by passing the <emphasis>
+XkbAudibleBellMask</emphasis>
+ to <emphasis>
+XkbChangeEnabledControls</emphasis>
+ (see section 10.1.1). If you set <emphasis> <!-- xref -->
+XkbAudibleBellMask</emphasis>
+ on, the server rings the system bell when a bell event occurs. This is the
+default. If you set <emphasis>
+XkbAudibleBellMask</emphasis>
+ off and a bell event occurs, the server does not ring the system bell unless
+you call <emphasis>
+XkbForceDeviceBell</emphasis>
+ or <emphasis>
+XkbForceBell</emphasis>
+ (see section 9.3.3). <!-- xref -->
+</para>
+
+<para>
+Audible bells are also part of the per-client auto-reset controls. For more
+information on auto-reset controls, see section 10.1.2. <!-- xref -->
+</para>
+
+</sect1>
+<sect1 id='bell_functions'>
+<title>Bell Functions</title>
+
+<para>
+Use the functions described in this section to ring bells and to generate bell
+events.
+</para>
+
+<para>
+The input extension has two types of feedbacks that can generate bells — bell
+feedback and keyboard feedback. Some of the functions in this section have
+<emphasis>
+bell_class</emphasis>
+ and <emphasis>
+bell_id</emphasis>
+ parameters; set them as follows: Set <emphasis>
+bell_class</emphasis>
+ to <emphasis>
+BellFeedbackClass</emphasis>
+ or <emphasis>
+KbdFeedbackClass</emphasis>
+. A device can have more than one feedback of each type; set <emphasis>
+bell_id</emphasis>
+ to the particular bell feedback of <emphasis>
+bell_class</emphasis>
+ type.
+</para>
+
+<para>
+Table 9.2 shows the conditions that cause a bell to sound or an <emphasis> <!-- xref -->
+XkbBellNotifyEvent</emphasis>
+ to be generated when a bell function is called.
+</para>
+
+<table frame='none'>
+<title>Bell Sounding and Bell Event Generating</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='0'>
+ <entry>Function called</entry>
+ <entry>AudibleBell</entry>
+ <entry>Server sounds a bell</entry>
+ <entry>Server sends an XkbBellNotifyEvent</entry>
+ </row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbDeviceBell</entry>
+ <entry>On</entry>
+ <entry>Yes</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbDeviceBell</entry>
+ <entry>Off</entry>
+ <entry>No</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbBell</entry>
+ <entry>On</entry>
+ <entry>Yes</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbBell</entry>
+ <entry>Off</entry>
+ <entry>No</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbDeviceBellEvent</entry>
+ <entry>On or Off</entry>
+ <entry>No</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbBellEvent</entry>
+ <entry>On or Off</entry>
+ <entry>No</entry>
+ <entry>Yes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbDeviceForceBell</entry>
+ <entry>On or Off</entry>
+ <entry>Yes</entry>
+ <entry>No</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbForceBell</entry>
+ <entry>On or Off</entry>
+ <entry>Yes</entry>
+ <entry>No</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<sect2 id='generating_named_bells'>
+<title>Generating Named Bells</title>
+
+<para>
+To ring the bell on an X input extension device or the default keyboard, use
+<emphasis>
+XkbDeviceBell.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbDeviceBell</emphasis>
+(<emphasis>
+display, window, device_id, bell_class, bell_id, percent, name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Window<emphasis>
+ window</emphasis>
+; /* window for which the bell is generated, or None */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_class</emphasis>
+; /* X input extension bell class of the bell to be rung */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_id</emphasis>
+; /* X input extension bell ID of the bell to be rung */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+percent</emphasis>
+; /* bell volume, from -100 to 100 inclusive */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+name</emphasis>
+; /* a name for the bell, or <emphasis>
+NULL</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+Set <emphasis>
+percent</emphasis>
+ to be the volume relative to the base volume for the keyboard as described for
+<emphasis>
+XBell</emphasis>.
+</para>
+
+<para>
+Note that <emphasis>
+bell_class</emphasis>
+ and <emphasis>
+bell_id</emphasis>
+ indicate the bell to physically ring. <emphasis>
+name</emphasis>
+ is simply an arbitrary moniker for the client application’s use.
+</para>
+
+<para>
+To determine the current feedback settings of an extension input device, use
+<emphasis>
+XGetFeedbackControl</emphasis>
+. See the X input extension documentation for more information on <emphasis>
+XGetFeedbackControl</emphasis>
+ and related data structures.
+</para>
+
+<para>
+If a compatible keyboard extension is not present in the X server, <emphasis>
+XkbDeviceBell</emphasis>
+ immediately returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbDeviceBell </emphasis>
+rings the bell as specified for the display and keyboard device and returns
+<emphasis>
+True</emphasis>
+. If you have disabled the audible bell, the server does not ring the system
+bell, although it does generate a <emphasis>
+XkbBellNotify</emphasis>
+ event.
+</para>
+
+<para>
+You can call <emphasis>
+XkbDeviceBell</emphasis>
+ without first initializing the keyboard extension.
+</para>
+
+<para>
+As a convenience function, Xkb provides a function to ring the bell on the
+default keyboard: <emphasis>
+XkbBell.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbBell</emphasis>
+(<emphasis>
+display, window, percent, name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Window<emphasis>
+ window</emphasis>
+; /* event window, or None*/
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int<emphasis>
+ percent</emphasis>
+; /* relative volume, which can range from -100 to 100 inclusive */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom<emphasis>
+ name</emphasis>
+; /* a bell name, or <emphasis>
+NULL</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible keyboard extension isn’t present in the X server, <emphasis>
+XkbBell</emphasis>
+ calls <emphasis>
+XBell </emphasis>
+with the specified <emphasis>
+display</emphasis>
+ and <emphasis>
+percent</emphasis>
+, and returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbBell </emphasis>
+calls <emphasis>
+XkbDeviceBell</emphasis>
+ with the specified <emphasis>
+display, window, percent, </emphasis>
+and <emphasis>
+name</emphasis>
+, a <emphasis>
+device_spec</emphasis>
+ of <emphasis>
+XkbUseCoreKbd</emphasis>
+, a <emphasis>
+bell_class </emphasis>
+of <emphasis>
+XkbDfltXIClass</emphasis>
+, and a <emphasis>
+bell_id </emphasis>
+of <emphasis>
+XkbDfltXIId,</emphasis>
+ and returns <emphasis>
+True</emphasis>.
+</para>
+
+<para>
+If you have disabled the audible bell, the server does not ring the system
+bell, although it does generate a <emphasis>
+XkbBellNotify</emphasis>
+ event.
+</para>
+
+<para>
+You can call <emphasis>
+XkbBell</emphasis>
+ without first initializing the keyboard extension.
+</para>
+
+</sect2>
+<sect2 id='generating_named_bell_events'>
+<title>Generating Named Bell Events</title>
+
+<para>
+Using Xkb, you can also generate a named bell event that does not ring any
+bell. This allows you to do things such as generate events when your
+application starts.
+</para>
+
+<para>
+For example, if an audio client listens for these types of bells, it can
+produce a "whoosh" sound when it receives a named bell event to indicate a
+client just started. In this manner, applications can generate start-up
+feedback and not worry about producing annoying beeps if an audio server is not
+running.
+</para>
+
+
+<para>
+To cause a bell event for an X input extension device or for the keyboard,
+without ringing the corresponding bell, use <emphasis>
+XkbDeviceBellEvent.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbDeviceBellEvent</emphasis>
+(<emphasis>
+display, window, device_spec, bell_class, bell_id, percent, name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Window <emphasis>
+window</emphasis>
+; /* event window, or None*/
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_class;</emphasis>
+ /* input extension bell class for the event */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_id</emphasis>
+; /* input extension bell ID for the event */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+percent</emphasis>
+; /* volume for the bell, which can range from -100 to 100 inclusive */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+name</emphasis>
+; /* a bell name, or <emphasis>
+NULL</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible keyboard extension isn’t present in the X server, <emphasis>
+XkbDeviceBellEvent</emphasis>
+ immediately returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbDeviceBellEvent</emphasis>
+ causes an <emphasis>
+XkbBellNotify</emphasis>
+ event to be sent to all interested clients and returns <emphasis>
+True</emphasis>
+. Set <emphasis>
+percent</emphasis>
+ to be the volume relative to the base volume for the keyboard as described for
+<emphasis>XBell</emphasis>.
+</para>
+
+
+<para>
+In addition, <emphasis>
+XkbDeviceBellEvent</emphasis>
+ may generate <emphasis>
+Atom</emphasis>
+ protocol errors as well as <emphasis>
+XkbBellNotify</emphasis>
+ events. You can call <emphasis>
+XkbBell</emphasis>
+ without first initializing the keyboard extension.
+</para>
+
+
+<para>
+As a convenience function, Xkb provides a function to cause a bell event for
+the keyboard without ringing the bell: <emphasis>
+XkbBellEvent.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbBellEvent</emphasis>
+(<emphasis>
+display, window, percent, name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Window <emphasis>
+window</emphasis>
+; /* the event window, or None */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+percent</emphasis>
+; /* relative volume, which can range from -100 to 100 inclusive */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+name</emphasis>
+; /* a bell name, or <emphasis>
+NULL</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible keyboard extension isn’t present in the X server, <emphasis>
+XkbBellEvent</emphasis>
+ immediately returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbBellEvent </emphasis>
+calls<emphasis>
+ XkbDeviceBellEvent</emphasis>
+ with the specified <emphasis>
+display, window, percent, </emphasis>
+and <emphasis>
+name</emphasis>
+, a <emphasis>
+device_spec</emphasis>
+ of <emphasis>
+XkbUseCoreKbd</emphasis>
+, a <emphasis>
+bell_class </emphasis>
+of <emphasis>
+XkbDfltXIClass</emphasis>
+, and a <emphasis>
+bell_id </emphasis>
+of <emphasis>
+XkbDfltXIId,</emphasis>
+ and returns what <emphasis>
+XkbDeviceBellEvent</emphasis>
+ returns.
+</para>
+
+<para>
+<emphasis>XkbBellEvent</emphasis>
+generates a <emphasis>XkbBellNotify</emphasis>
+event.
+</para>
+
+
+<para>
+You can call <emphasis>
+XkbBellEvent</emphasis>
+without first initializing the keyboard extension.
+</para>
+
+</sect2>
+<sect2 id='forcing_a_server_generated_bell'>
+<title>Forcing a Server-Generated Bell</title>
+
+<para>
+To ring the bell on any keyboard, overriding user preference settings for
+audible bells, use <emphasis>XkbForceDeviceBell</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbForceDeviceBell</emphasis>
+(<emphasis>
+display, window, device_spec, bell_class, bell_id, percent</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Window <emphasis>
+window</emphasis>
+; /* event window, or None */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_class</emphasis>
+; /* input extension class of the bell to be rung */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+bell_id</emphasis>
+; /* input extension ID of the bell to be rung */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+percent</emphasis>
+; /* relative volume, which can range from -100 to 100 inclusive */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible keyboard extension isn’t present in the X server, <emphasis>
+XkbForceDeviceBell</emphasis>
+ immediately returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbForceDeviceBell </emphasis>
+rings the bell as specified for the display and keyboard device and returns
+<emphasis>
+True</emphasis>
+. Set <emphasis>
+percent</emphasis>
+ to be the volume relative to the base volume for the keyboard as described for
+<emphasis>
+XBell</emphasis>
+. There is no <emphasis>
+name</emphasis>
+ parameter because <emphasis>
+XkbForceDeviceBell </emphasis>
+does not cause an <emphasis>
+XkbBellNotify</emphasis>
+ event.
+</para>
+
+<para>
+You can call <emphasis>
+XkbBell</emphasis>
+ without first initializing the keyboard extension.
+</para>
+
+<para>
+To ring the bell on the default keyboard, overriding user preference settings
+for audible bells, use <emphasis>
+XkbForceBell</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbForceBell</emphasis>
+(<emphasis>
+display, percent)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+percent</emphasis>
+; /* volume for the bell, which can range from -100 to 100 inclusive */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If a compatible keyboard extension isn’t present in the X server, <emphasis>
+XkbForceBell</emphasis>
+ calls <emphasis>
+XBell </emphasis>
+with the specified <emphasis>
+display</emphasis>
+ and <emphasis>
+percent</emphasis>
+ and returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbForceBell </emphasis>
+calls <emphasis>
+XkbForceDeviceBell</emphasis>
+ with the specified <emphasis>
+display </emphasis>
+and<emphasis>
+ percent</emphasis>
+, <emphasis>
+device_spec</emphasis>
+ =<emphasis>
+XkbUseCoreKbd</emphasis>
+, <emphasis>
+bell_class </emphasis>
+= <emphasis>
+XkbDfltXIClass</emphasis>
+, <emphasis>
+bell_id </emphasis>
+= <emphasis>
+XkbDfltXIId,</emphasis>
+ <emphasis>
+window</emphasis>
+ = None, and <emphasis>
+name</emphasis>
+ = <emphasis>
+NULL</emphasis>
+, and returns what<emphasis>
+ XkbForceDeviceBell</emphasis>
+ returns.
+</para>
+
+<para>
+<emphasis>
+XkbForceBell </emphasis>
+does not cause an <emphasis>
+XkbBellNotify</emphasis>
+ event.
+</para>
+
+<para>
+You can call <emphasis>
+XkbBell</emphasis>
+ without first initializing the keyboard extension.
+</para>
+
+</sect2>
+</sect1>
+<sect1 id='detecting_bells'>
+<title>Detecting Bells</title>
+
+<para>
+Xkb generates <emphasis>
+XkbBellNotify</emphasis>
+ events for all bells except for those resulting from calls to <emphasis>
+XkbForceDeviceBell</emphasis>
+ and <emphasis>
+XkbForceBell</emphasis>
+. To receive <emphasis>
+XkbBellNotify</emphasis>
+ events under all possible conditions, pass <emphasis>
+XkbBellNotifyMask</emphasis>
+ in both the <emphasis>
+bits_to_change </emphasis>
+and<emphasis>
+ values_for_bits</emphasis>
+ parameters to <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3). <!-- xref -->
+</para>
+
+<para>
+The <emphasis>
+XkbBellNotify</emphasis>
+ event has no event details. It is either selected or it is not. However, you
+can call <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbBellNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying <emphasis>
+XkbAllBellNotifyMask</emphasis>
+ in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits.</emphasis>
+ This has the same effect as a call to <emphasis>
+XkbSelectEvents</emphasis>.
+</para>
+
+<para>
+The structure for the <emphasis>
+XkbBellNotify</emphasis>
+ event type contains:
+</para>
+
+<para><programlisting>
+typedef struct _XkbBellNotify {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis> XkbBellNotify</emphasis> */
+ unsigned int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ int percent; /* requested volume as % of max */
+ int pitch; /* requested pitch in Hz */
+ int duration; /* requested duration in microseconds */
+ unsigned int bell_class; /* X input extension feedback class */
+ unsigned int bell_id; /* X input extension feedback ID */
+ Atom name; /* "name" of requested bell */
+ Window window; /* window associated with event */
+ Bool event_only; /* <emphasis> False</emphasis> -&gt; the server did not produce a beep */
+} <emphasis>XkbBellNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+If your application needs to generate visual bell feedback on the screen when
+it receives a bell event, use the window ID in the <emphasis>
+XkbBellNotifyEvent</emphasis>
+, if present.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch10.xml b/libX11/specs/XKB/ch10.xml
new file mode 100644
index 000000000..76acd032f
--- /dev/null
+++ b/libX11/specs/XKB/ch10.xml
@@ -0,0 +1,5347 @@
+<chapter id='keyboard_controls'>
+<title>Keyboard Controls</title>
+
+<para>
+The Xkb extension is composed of two parts: a server extension, and a
+client-side X library extension. This chapter discusses functions used to
+modify controls effecting the behavior of the server portion of the Xkb
+extension. Chapter 11 discusses functions used to modify controls that affect
+only the behavior of the client portion of the extension; those controls are
+known as Library Controls.
+</para>
+
+
+<para>
+Xkb contains control features that affect the entire keyboard, known as global
+keyboard controls. Some of the controls may be selectively enabled and
+disabled; these controls are known as the <emphasis>
+Boolean Controls</emphasis>
+. Boolean Controls can be turned on or off under program control and can also
+be automatically set to an on or off condition when a client program exits. The
+remaining controls, known as the <emphasis>
+Non-Boolean Controls</emphasis>
+, are always active. The<emphasis>
+ XkbControlsRec</emphasis>
+ structure describes the current state of most of the global controls and the
+attributes effecting the behavior of each of these Xkb features. This chapter
+describes the Xkb controls and how to manipulate them.
+</para>
+
+
+<para>
+There are two possible components for each of the Boolean Controls: attributes
+describing how the control should work, and a state describing whether the
+behavior as a whole is enabled or disabled. The attributes and state for most
+of these controls are held in the <emphasis>
+XkbControlsRec</emphasis>
+ structure (see section 10.8).
+</para>
+
+
+<para>
+You can manipulate the Xkb controls individually, via convenience functions, or
+as a whole. To treat them as a group, modify an <emphasis>
+XkbControlsRec</emphasis>
+ structure to describe all of the changes to be made, and then pass that
+structure and appropriate flags to an Xkb library function, or use a <emphasis>
+XkbControlsChangesRec</emphasis>
+ (see section 10.10.1) to reduce network traffic. When using a convenience
+function to manipulate one control individually, you do not use an <emphasis>
+XkbControlsRec</emphasis>
+ structure directly.
+</para>
+
+
+<para>
+The Xkb controls are grouped as shown in Table 10.1. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>Xkb Keyboard Controls</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type of Control</entry>
+ <entry>Control Name</entry>
+ <entry>Boolean Control?</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>Controls for enabling and disabling other controls</entry>
+ <entry>EnabledControls</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>AutoReset</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Control for bell behavior</entry>
+ <entry>AudibleBell</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Controls for repeat key behavior</entry>
+ <entry>PerKeyRepeat</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>RepeatKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>DetectableAutorepeat</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Controls for keyboard overlays</entry>
+ <entry>Overlay1</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>Overlay2</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Controls for using the mouse from the keyboard</entry>
+ <entry>MouseKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>MouseKeysAccel</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Controls for better keyboard access by </entry>
+ <entry>AccessXFeedback</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>physically impaired persons</entry>
+ <entry>AccessXKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>AccessXTimeout</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>BounceKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>SlowKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>StickyKeys</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Controls for general keyboard mapping</entry>
+ <entry>GroupsWrap</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>IgnoreGroupLock</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>IgnoreLockMods</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>InternalMods</entry>
+ <entry>No</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Miscellaneous per-client controls</entry>
+ <entry>GrabsUseXKBState</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>LookupStateWhenGrabbed</entry>
+ <entry>Boolean</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>SendEventUsesXKBState</entry>
+ <entry>Boolean</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The individual categories and controls are described first, together with
+functions for manipulating them. A description of the <emphasis>
+XkbControlsRec</emphasis>
+ structure and the general functions for dealing with all of the controls at
+once follow at the end of the chapter.
+</para>
+
+<sect1 id='controls_that_enable_and_disable_other_controls'>
+<title>Controls that Enable and Disable Other Controls</title>
+
+<para>
+Enable and disable the boolean controls under program control by using the
+<emphasis>
+EnabledControls</emphasis>
+ control; enable and disable them upon program exit by configuring the
+<emphasis>
+AutoReset</emphasis>
+ control.
+</para>
+
+
+<sect2 id='the_enabledcontrols_control'>
+<title>The EnabledControls Control</title>
+
+<para>
+The <emphasis>
+EnabledControls</emphasis>
+ control is a bit mask where each bit that is turned on means the corresponding
+control is enabled, and when turned off, disabled. It corresponds to the
+<emphasis>
+enabled_ctrls</emphasis>
+ field of an <emphasis>
+XkbControlsRec</emphasis>
+ structure (see section 10.8). The bits describing which controls are turned on
+or off are defined in Table 10.7. <!-- xref -->
+</para>
+
+
+<para>
+Use <emphasis>
+XkbChangeEnabledControls</emphasis>
+ to manipulate the <emphasis>
+EnabledControls</emphasis>
+ control.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeEnabledControls</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+mask</emphasis>
+,<emphasis>
+ values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* keyboard device to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+mask</emphasis>
+; /* 1 bit -&gt; controls to enable / disable */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+values</emphasis>
+; /* 1 bit =&gt; enable, 0 bit =&gt; disable */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+mask</emphasis>
+ parameter specifies the boolean controls to be enabled or disabled, and the
+<emphasis>
+values</emphasis>
+ mask specifies the new state for those controls. Valid values for both of
+these masks are composed of a bitwise inclusive OR of bits taken from the set
+of mask bits in Table 10.7, using only those masks with "ok" in the <emphasis>
+enabled_ctrls</emphasis>
+ column.
+</para>
+
+
+<para>
+If the X server does not support a compatible version of Xkb or the Xkb
+extension has not been properly initialized, <emphasis>
+XkbChangeEnabledControls</emphasis>
+ returns <emphasis>
+False</emphasis>
+; otherwise, it sends the request to the X server and returns <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+Note that the <emphasis>
+EnabledControls</emphasis>
+ control only enables and disables controls; it does not configure them. Some
+controls, such as the <emphasis>
+AudibleBell</emphasis>
+ control, have no configuration attributes and are therefore manipulated solely
+by enabling and disabling them. Others, however, have additional attributes to
+configure their behavior. For example, the <emphasis>
+RepeatControl</emphasis>
+ control uses <emphasis>
+repeat_delay</emphasis>
+ and <emphasis>
+repeat_interval</emphasis>
+ fields to describe the timing behavior of keys that repeat. The <emphasis>
+RepeatControl</emphasis>
+ behavior is turned on or off depending on the value of the <emphasis>
+XkbRepeatKeysMask</emphasis>
+ bit, but you must use other means, as described in this chapter, to configure
+its behavior in detail.
+</para>
+
+
+</sect2>
+<sect2 id='the_autoreset_control'>
+<title>The AutoReset Control</title>
+
+<para>
+You can configure the boolean controls to automatically be enabled or disabled
+when a program exits. This capability is controlled via two masks maintained in
+the X server on a per-client basis. There is no client-side Xkb data structure
+corresponding to these masks. Whenever the client exits for any reason, any
+boolean controls specified in the <emphasis>
+auto-reset mask</emphasis>
+ are set to the corresponding value from the <emphasis>
+auto-reset values</emphasis>
+ mask. This makes it possible for clients to "clean up after themselves"
+automatically, even if abnormally terminated. The bits used in the masks
+correspond to the <emphasis>
+EnabledControls</emphasis>
+ control bits.
+</para>
+
+
+<para>
+For example, a client that replaces the keyboard bell with some other audible
+cue might want to turn off the <emphasis>
+AudibleBell</emphasis>
+ control to prevent the server from also generating a sound and avoid
+cacophony. If the client were to exit without resetting the <emphasis>
+AudibleBell </emphasis>
+control, the user would be left without any feedback at all. Setting <emphasis>
+AudibleBell</emphasis>
+ in both the auto-reset mask and auto-reset values guarantees that the audible
+bell will be turned back on when the client exits.
+</para>
+
+
+<para>
+To get the current values of the auto-reset controls, use <emphasis>
+XkbGetAutoResetControls</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetAutoResetControls</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+auto_ctrls</emphasis>
+, <emphasis>
+auto_values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+auto_ctrls</emphasis>
+; /* specifies which bits in <emphasis>
+auto_values</emphasis>
+ are relevant */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+auto_values</emphasis>
+; /* 1 bit =&gt; corresponding control has auto-reset on */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetAutoResetControls</emphasis>
+ backfills <emphasis>
+auto_ctrls</emphasis>
+ and <emphasis>
+auto_values</emphasis>
+ with the <emphasis>
+AutoReset</emphasis>
+ control attributes for this particular client. It returns <emphasis>
+True</emphasis>
+ if successful, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To change the current values of the <emphasis>
+AutoReset</emphasis>
+ control attributes, use <emphasis>
+XkbSetAutoResetControls.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetAutoResetControls</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+changes</emphasis>
+,<emphasis>
+ auto_ctrls</emphasis>
+, <emphasis>
+auto_values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+changes</emphasis>
+; /* controls for which to change auto-reset values */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+auto_ctrls</emphasis>
+; /* controls from changes that should auto reset */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+auto_values</emphasis>
+; /* 1 bit =&gt; auto-reset on */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetAutoResetControls changes the auto-reset status and associated auto-reset
+values for the controls selected by </emphasis>
+<emphasis>
+changes</emphasis>
+<emphasis>
+. For any control selected by </emphasis>
+<emphasis>
+changes</emphasis>
+<emphasis>
+, if the corresponding bit is set in </emphasis>
+<emphasis>
+auto_ctrls</emphasis>
+<emphasis>
+, the control is configured to auto-reset when the client exits. If the
+corresponding bit in </emphasis>
+<emphasis>
+auto_values</emphasis>
+<emphasis>
+ is on, the control is turned on when the client exits; if zero, the control is
+turned off when the client exits.</emphasis>
+ For any control selected by <emphasis>
+changes</emphasis>
+, if the corresponding bit is not set in <emphasis>
+auto_ctrls</emphasis>
+, the control is configured to not reset when the client exits. For example:
+</para>
+
+
+<para>
+<emphasis>
+To leave the auto-reset controls for </emphasis>
+<emphasis>
+StickyKeys</emphasis>
+<emphasis>
+ the way they are:</emphasis>
+</para>
+
+<para><programlisting>
+ok = XkbSetAutoResetControls(dpy, 0, 0, 0);
+</programlisting></para>
+
+<para>
+<emphasis>
+To change the auto-reset controls so that </emphasis>
+<emphasis>
+StickyKeys</emphasis>
+<emphasis>
+ are unaffected when the client exits:</emphasis>
+</para>
+
+<para><programlisting>
+ok = XkbSetAutoResetControls(dpy, XkbStickyKeysMask, 0, 0);
+</programlisting></para>
+
+<para>
+<emphasis>
+To change the auto-reset controls so that </emphasis>
+<emphasis>
+StickyKeys</emphasis>
+<emphasis>
+ are turned off when the client exits:</emphasis>
+</para>
+
+<para><programlisting>
+ok = XkbSetAutoResetControls(dpy, XkbStickyKeysMask, XkbStickyKeysMask, 0);
+</programlisting></para>
+
+<para>
+<emphasis>
+To change the auto-reset controls so that </emphasis>
+<emphasis>
+StickyKeys</emphasis>
+<emphasis>
+ are turned on when the client exits:</emphasis>
+</para>
+
+<para><programlisting>
+ok = XkbSetAutoResetControls(dpy, XkbStickyKeysMask, XkbStickyKeysMask,
+XkbStickyKeysMask);
+</programlisting></para>
+
+<para>
+<emphasis>
+XkbSetAutoResetControls</emphasis>
+ backfills <emphasis>
+auto_ctrls</emphasis>
+ and <emphasis>
+auto_values</emphasis>
+ with the auto-reset controls for this particular client. Note that all of the
+bits are valid in the returned values, not just the ones selected in the
+<emphasis>
+changes</emphasis>
+ mask.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='control_for_bell_behavior'>
+<title>Control for Bell Behavior</title>
+
+<para>
+The X server’s generation of sounds is controlled by the <emphasis>
+AudibleBell</emphasis>
+ control. Configuration of different bell sounds is discussed in Chapter 9.
+</para>
+
+
+<sect2 id='the_audiblebell_control'>
+<title>The AudibleBell Control</title>
+
+<para>
+The <emphasis>
+AudibleBell</emphasis>
+ control is a boolean control that has no attributes. As such, you may enable
+and disable it using either the <emphasis>
+EnabledControls</emphasis>
+ control or the <emphasis>
+AutoReset</emphasis>
+ control discussed in section 10.1.1. When enabled, protocol requests to <!-- xref -->
+generate a sound result in the X server actually producing a real sound; when
+disabled, requests to the server to generate a sound are ignored unless the
+sound is forced. See section 9.2. <!-- xref -->
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='controls_for_repeat_key_behavior'>
+<title>Controls for Repeat Key Behavior</title>
+
+<para>
+The repeating behavior of keyboard keys is governed by three controls, the
+<emphasis>
+PerKeyRepeat</emphasis>
+ control, which is always active, and the <emphasis>
+RepeatKeys</emphasis>
+ and <emphasis>
+DetectableAutorepeat</emphasis>
+ controls, which are boolean controls that may be enabled and disabled.
+<emphasis>
+PerKeyRepeat</emphasis>
+ determines which keys are allowed to repeat. <emphasis>
+RepeatKeys</emphasis>
+ governs the behavior of an individual key when it is repeating. <emphasis>
+DetectableAutorepeat</emphasis>
+ allows a client to detect when a key is repeating as a result of being held
+down.
+</para>
+
+
+<sect2 id='the_perkeyrepeat_control'>
+<title>The PerKeyRepeat Control</title>
+
+<para>
+The <emphasis>
+PerKeyRepeat</emphasis>
+ control is a bitmask long enough to contain a bit for each key on the device;
+it determines which individual keys are allowed to repeat. The Xkb <emphasis>
+PerKeyRepeat</emphasis>
+ control provides no functionality different from that available via the core X
+protocol. There are no convenience functions in Xkb for manipulating this
+control. The <emphasis>
+PerKeyRepeat</emphasis>
+ control settings are carried in the <emphasis>
+per_key_repeat</emphasis>
+ field of an <emphasis>
+XkbControlsRec</emphasis>
+ structure, discussed in section 10.8. <!-- xref -->
+</para>
+
+
+</sect2>
+<sect2 id='the_repeatkeys_control'>
+<title>The RepeatKeys Control</title>
+
+<para>
+The core protocol allows only control over whether or not the entire keyboard
+or individual keys should auto-repeat when held down. <emphasis>
+RepeatKeys</emphasis>
+ is a boolean control that extends this capability by adding control over the
+delay until a key begins to repeat and the rate at which it repeats. <emphasis>
+RepeatKeys</emphasis>
+ is coupled with the core auto-repeat control: when <emphasis>
+RepeatKeys</emphasis>
+ is enabled or disabled, the core auto-repeat is enabled or disabled and vice
+versa.
+</para>
+
+
+<para>
+Auto-repeating keys are controlled by two attributes. The first, <emphasis>
+timeout</emphasis>
+, is the delay after the initial press of an auto-repeating key and the first
+generated repeat event. The second, <emphasis>
+interval</emphasis>
+, is the delay between all subsequent generated repeat events. As with all
+boolean controls, configuring the attributes that determine how the control
+operates does not automatically enable the control as a whole; see section 10.1.
+</para>
+
+
+<para>
+To get the current attributes of the <emphasis>
+RepeatKeys</emphasis>
+ control for a keyboard device, use <emphasis>
+XkbGetAutoRepeatRate</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetAutoRepeatRate</emphasis>
+(<emphasis>
+display, device_spec, timeout_rtrn, interval_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ device_spec</emphasis>
+; /* desired device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+* timeout_rtrn</emphasis>
+; /* backfilled with initial repeat delay, ms */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+* interval_rtrn</emphasis>
+; /* backfilled with subsequent repeat delay, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetAutoRepeatRate</emphasis>
+ queries the server for the current values of the <emphasis>
+RepeatControls</emphasis>
+ control attributes, backfills <emphasis>
+timeout_rtrn</emphasis>
+ and <emphasis>
+interval_rtrn</emphasis>
+ with them, and returns <emphasis>
+True</emphasis>
+. If a compatible version of the Xkb extension is not available in the server
+<emphasis>
+XkbGetAutoRepeatRate</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+To set the attributes of the RepeatKeys control for a keyboard device, use
+<emphasis>
+XkbSetAutoRepeatRate</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetAutoRepeatRate</emphasis>
+(<emphasis>
+display, device_spec, timeout, interval</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device to configure, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ timeout</emphasis>
+; /* initial delay, ms */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ interval</emphasis>
+; /* delay between repeats, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetAutoRepeatRate</emphasis>
+ sends a request to the X server to configure the <emphasis>
+AutoRepeat</emphasis>
+ control attributes to the values specified in <emphasis>
+timeout</emphasis>
+ and <emphasis>
+interval</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbSetAutoRepeatRate</emphasis>
+ does not wait for a reply; it normally returns <emphasis>
+True</emphasis>
+. Specifying a zero value for either <emphasis>
+timeout</emphasis>
+ or <emphasis>
+interval</emphasis>
+ causes the server to generate a <emphasis>
+BadValue</emphasis>
+ protocol error. If a compatible version of the Xkb extension is not available
+in the server, <emphasis>
+XkbSetAutoRepeatRate</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='the_detectableautorepeat_control'>
+<title>The DetectableAutorepeat Control</title>
+
+<para>
+Auto-repeat is the generation of multiple key events by a keyboard when the
+user presses a key and holds it down. Keyboard hardware and device-dependent X
+server software often implement auto-repeat by generating multiple <emphasis>
+KeyPress</emphasis>
+ events with no intervening <emphasis>
+KeyRelease</emphasis>
+ event. The standard behavior of the X server is to generate a <emphasis>
+KeyRelease</emphasis>
+ event for every <emphasis>
+KeyPress</emphasis>
+ event. If the keyboard hardware and device-dependent software of the X server
+implement auto-repeat by generating multiple <emphasis>
+KeyPress</emphasis>
+ events, the device-independent part of the X server by default synthetically
+generates a <emphasis>
+KeyRelease</emphasis>
+ event after each <emphasis>
+KeyPress</emphasis>
+ event. This provides predictable behavior for X clients, but does not allow
+those clients to detect the fact that a key is auto-repeating.
+</para>
+
+
+<para>
+Xkb allows clients to request <emphasis>
+detectable auto-repeat</emphasis>
+. If a client requests and the server supports <emphasis>
+DetectableAutorepeat</emphasis>
+, Xkb generates <emphasis>
+KeyRelease</emphasis>
+ events only when the key is physically released. If <emphasis>
+DetectableAutorepeat</emphasis>
+ is not supported or has not been requested, the server synthesizes a <emphasis>
+KeyRelease</emphasis>
+ event for each repeating <emphasis>
+KeyPress</emphasis>
+ event it generates.
+</para>
+
+
+<para>
+<emphasis>
+DetectableAutorepeat</emphasis>
+, unlike the other controls in this chapter, is not contained in the <emphasis>
+XkbControlsRec</emphasis>
+ structure, nor can it be enabled or disabled via the <emphasis>
+EnabledControls</emphasis>
+ control. Instead, query and set <emphasis>
+DetectableAutorepeat</emphasis>
+ using <emphasis>
+XkbGetDetectableAutorepeat</emphasis>
+ and <emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+DetectableAutorepeat</emphasis>
+ is a condition that applies to all keyboard devices for a client’s
+connection to a given X server; it cannot be selectively set for some devices
+and not for others. For this reason, none of the Xkb library functions
+involving <emphasis>
+DetectableAutorepeat</emphasis>
+ involve a device specifier.
+</para>
+
+
+<para>
+To determine whether or not the server supports <emphasis>
+DetectableAutorepeat</emphasis>
+, use <emphasis>
+XkbGetDetectableAutorepeat</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetDetectableAutorepeat</emphasis>
+(<emphasis>
+display, supported_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool *<emphasis>
+ supported_rtrn</emphasis>
+; /* backfilled <emphasis>
+True</emphasis>
+ if <emphasis>
+DetectableAutorepeat</emphasis>
+ supported */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetDetectableAutorepeat</emphasis>
+ queries the server for the current state of <emphasis>
+DetectableAutorepeat</emphasis>
+ and waits for a reply. If <emphasis>
+supported_rtrn</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+, it backfills supported_rtrn with <emphasis>
+True</emphasis>
+ if the server supports <emphasis>
+DetectableAutorepeat</emphasis>
+, and <emphasis>
+False</emphasis>
+ otherwise. <emphasis>
+XkbGetDetectableAutorepeat</emphasis>
+ returns the current state of <emphasis>
+DetectableAutorepeat</emphasis>
+ for the requesting client: <emphasis>
+True</emphasis>
+ if <emphasis>
+DetectableAutorepeat</emphasis>
+ is set, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To set <emphasis>
+DetectableAutorepeat</emphasis>
+, use <emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+. This request affects all keyboard activity for the requesting client only;
+other clients still see the expected nondetectable auto-repeat behavior, unless
+they have requested otherwise.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+(<emphasis>
+display, detectable, supported_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool<emphasis>
+ detectable</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; set <emphasis>
+DetectableAutorepeat</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool *<emphasis>
+ supported_rtrn</emphasis>
+; /* backfilled <emphasis>
+True</emphasis>
+ if <emphasis>
+DetectableAutorepeat</emphasis>
+ supported */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+ sends a request to the server to set <emphasis>
+DetectableAutorepeat</emphasis>
+ on for the current client if <emphasis>
+detectable</emphasis>
+ is <emphasis>
+True</emphasis>
+, and off it <emphasis>
+detectable</emphasis>
+ is <emphasis>
+False</emphasis>
+; it then waits for a reply. If <emphasis>
+supported_rtrn</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+ backfills <emphasis>
+supported_rtrn</emphasis>
+ with <emphasis>
+True</emphasis>
+ if the server supports <emphasis>
+DetectableAutorepeat</emphasis>
+, and <emphasis>
+False</emphasis>
+ if it does not. <emphasis>
+XkbSetDetectableAutorepeat</emphasis>
+ returns the current state of <emphasis>
+DetectableAutorepeat</emphasis>
+ for the requesting client: <emphasis>
+True</emphasis>
+ if <emphasis>
+DetectableAutorepeat</emphasis>
+ is set, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='controls_for_keyboard_overlays_overlay1_and_overlay2_controls'>
+<title>Controls for Keyboard Overlays (Overlay1 and Overlay2 Controls)</title>
+
+<para>
+A keyboard overlay allows some subset of the keyboard to report alternate
+keycodes when the overlay is enabled. For example, a keyboard overlay can be
+used to simulate a numeric or editing keypad on a keyboard that does not
+actually have one by reusing some portion of the keyboard as an overlay. This
+technique is very common on portable computers and embedded systems with small
+keyboards.
+</para>
+
+
+<para>
+Xkb includes direct support for two keyboard overlays, using the <emphasis>
+Overlay1</emphasis>
+ and <emphasis>
+Overlay2</emphasis>
+ controls. When <emphasis>
+Overlay1</emphasis>
+ is enabled, all of the keys that are members of the first keyboard overlay
+generate an alternate keycode. When <emphasis>
+Overlay2</emphasis>
+ is enabled, all of the keys that are members of the second keyboard overlay
+generate an alternate keycode. The two overlays are mutually exclusive; any
+particular key may be in at most one overlay. <emphasis>
+Overlay1</emphasis>
+ and <emphasis>
+Overlay2</emphasis>
+ are boolean controls. As such, you may enable and disable them using either
+the <emphasis>
+EnabledControls</emphasis>
+ control or the <emphasis>
+AutoReset</emphasis>
+ control discussed in section 10.1.1. <!-- xref -->
+</para>
+
+
+<para>
+To specify the overlay to which a key belongs and the alternate keycode it
+should generate when that overlay is enabled, assign it either the <emphasis>
+XkbKB_Overlay1</emphasis>
+ or <emphasis>
+XkbKB_Overlay2</emphasis>
+ key behaviors, as described in section 16.2. <!-- xref -->
+</para>
+
+
+</sect1>
+<sect1 id='controls_for_using_the_mouse_from_the_keyboard'>
+<title>Controls for Using the Mouse from the Keyboard</title>
+
+<para>
+Using Xkb, it is possible to configure the keyboard to allow simulation of the
+X pointer device. This simulation includes both movement of the pointer itself
+and press and release events associated with the buttons on the pointer. Two
+controls affect this behavior: the <emphasis>
+MouseKeys</emphasis>
+ control determines whether or not simulation of the pointer device is active,
+as well as configuring the default button; the <emphasis>
+MouseKeysAccel</emphasis>
+ control determines the movement characteristics of the pointer when simulated
+via the keyboard. Both of them are boolean controls; as such, you may enable
+and disable them using either the <emphasis>
+EnabledControls</emphasis>
+ control or the <emphasis>
+AutoReset</emphasis>
+ control discussed in section 10.1.1. The individual keys that simulate <!-- xref -->
+different aspects of the pointer device are determined by the keyboard mapping,
+discussed in Chapter 16. <!-- xref -->
+</para>
+
+
+<sect2 id='the_mousekeys_control'>
+<title>The MouseKeys Control</title>
+
+<para>
+The <emphasis>
+MouseKeys</emphasis>
+ control allows a user to control all the mouse functions from the keyboard.
+When <emphasis>
+MouseKeys</emphasis>
+ are enabled, all keys with <emphasis>
+MouseKeys</emphasis>
+ actions bound to them generate core pointer events instead of normal <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events.
+</para>
+
+
+<para>
+The <emphasis>
+MouseKeys</emphasis>
+ control has a single attribute, <emphasis>
+mk_dflt_btn</emphasis>
+ that specifies the core button number to be used by mouse keys actions that do
+not explicitly specify a button. There is no convenience function for getting
+or setting the attribute; instead use <emphasis>
+XkbGetControls</emphasis>
+ and <emphasis>
+XkbSetControls</emphasis>
+ (see sections 10.9 and 10.10). <!-- xref -->
+</para>
+
+<note><para><emphasis>
+MouseKeys</emphasis>
+ can also be turned on and off by pressing the key combination necessary to
+produce an <emphasis>
+XK_Pointer_EnableKeys</emphasis>
+ keysym. The de facto default standard for this is <emphasis>
+Shift+Alt+NumLock</emphasis>
+, but this may vary depending on the keymap.</para></note>
+
+</sect2>
+<sect2 id='the_mousekeysaccel_control'>
+<title>The MouseKeysAccel Control</title>
+
+<para>
+When the <emphasis>
+MouseKeysAccel</emphasis>
+ control is enabled, the effect of a key-activated pointer motion action
+changes as a key is held down. If the control is disabled, pressing a
+mouse-pointer key yields one mouse event. When <emphasis>
+MouseKeysAccel</emphasis>
+ is enabled, mouse movement is defined by an initial distance specified in the
+<emphasis>
+XkbSA_MovePtr</emphasis>
+ action and the following fields in the <emphasis>
+XkbControlsRec</emphasis>
+ structure (see section 10.8). <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>MouseKeysAccel Fields</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Field</entry>
+ <entry>Function</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>mk_delay</entry>
+ <entry>Time (ms) between the initial key press and the first repeated
+motion event</entry>
+</row>
+<row rowsep='0'>
+ <entry>mk_interval</entry>
+ <entry>Time (ms) between repeated motion events</entry>
+</row>
+<row rowsep='0'>
+ <entry>mk_time_to_max</entry>
+ <entry>Number of events (count) before the pointer reaches maximum
+speed</entry>
+</row>
+<row rowsep='0'>
+ <entry>mk_max_speed</entry>
+ <entry>The maximum speed (in pixels per event) the pointer reaches</entry>
+</row>
+<row rowsep='0'>
+ <entry>mk_curve</entry>
+ <entry>The ramp used to reach maximum pointer speed</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+There are no convenience functions to query or change the attributes of the
+<emphasis>
+MouseKeysAccel</emphasis>
+ control; instead use <emphasis>
+XkbGetControls</emphasis>
+ and <emphasis>
+XkbSetControls</emphasis>
+ (see sections 10.9 and 10.10). <!-- xref -->
+</para>
+
+
+<para>
+The effects of the attributes of the <emphasis>
+MouseKeysAccel</emphasis>
+ control depend on whether the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action (see section 16.1) specifies relative or absolute pointer motion. <!-- xref -->
+</para>
+
+<sect3 id='absolute_pointer_motion'>
+<title>Absolute Pointer Motion</title>
+
+<para>
+If an <emphasis>
+XkbSA_MovePtr</emphasis>
+ action specifies an absolute position for one of the coordinates but still
+allows acceleration, all repeated events contain any absolute coordinates
+specified in the action. For example, if the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action specifies an absolute position for the X direction, but a relative
+motion for the Y direction, the pointer accelerates in the Y direction, but
+stays at the same X position.
+</para>
+
+
+</sect3>
+<sect3 id='relative_pointer_motion'>
+<title>Relative Pointer Motion</title>
+
+<para>
+If the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action specifies relative motion, the initial event always moves the cursor
+the distance specified in the action. After <emphasis>
+mk_delay</emphasis>
+ milliseconds, a second motion event is generated, and another occurs every
+<emphasis>
+mk_interval</emphasis>
+ milliseconds until the user releases the key.
+</para>
+
+
+<para>
+Between the time of the second motion event and <emphasis>
+mk_time_to_max</emphasis>
+ intervals, the change in pointer distance per interval increases with each
+interval. After <emphasis>
+mk_time_to_max</emphasis>
+ intervals have elapsed, the change in pointer distance per interval remains
+the same and is calculated by multiplying the original distance specified in
+the action by <emphasis>
+mk_max_speed</emphasis>
+.
+</para>
+
+
+<para>
+For example, if the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action specifies a relative motion in the X direction of 5, <emphasis>
+mk_delay</emphasis>
+=160, <emphasis>
+mk_interval</emphasis>
+=40, <emphasis>
+mk_time_to_max</emphasis>
+=30, and <emphasis>
+mk_max_speed</emphasis>
+=30, the following happens when the user presses the key:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The pointer immediately moves 5 pixels in the X direction when the key is
+pressed.
+ </para>
+</listitem>
+<listitem>
+ <para>
+After 160 milliseconds (<emphasis>
+mk_delay</emphasis>
+), and every 40 milliseconds thereafter (<emphasis>
+mk_interval</emphasis>
+), the pointer moves in the X direction.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The distance in the X direction increases with each interval until 30 intervals
+(<emphasis>
+mk_time_to_max</emphasis>
+) have elapsed.
+ </para>
+</listitem>
+<listitem>
+ <para>
+After 30 intervals, the pointer stops accelerating, and moves 150 pixels
+(<emphasis>
+mk_max_speed</emphasis>
+ * the original distance) every interval thereafter, until the key is released.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The increase in pointer difference for each interval is a function of<emphasis>
+ mk_curve.</emphasis>
+ Events after the first but before maximum acceleration has been achieved are
+accelerated according to the formula:
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-3.svg"/>
+ </imageobject>
+ </mediaobject>
+
+
+<para>
+Where <emphasis>
+action_delta</emphasis>
+ is the relative motion specified by the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action, <emphasis>
+mk_max_speed </emphasis>
+and <emphasis>
+mk_time_to_max</emphasis>
+ are parameters to the <emphasis>
+MouseKeysAccel</emphasis>
+ control, and the curveFactor is computed using the <emphasis>
+MouseKeysAccel</emphasis>
+ <emphasis>
+mk_curve</emphasis>
+ parameter as follows:
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-4.svg"/>
+ </imageobject>
+ </mediaobject>
+
+
+<para>
+With the result that a <emphasis>
+mk_curve</emphasis>
+ of zero causes the distance moved to increase linearly from <emphasis>
+action_delta</emphasis>
+ to <mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-5.svg"/>
+ </imageobject>
+ </mediaobject>
+
+. A negative <emphasis>
+mk_curve</emphasis>
+ causes an initial sharp increase in acceleration that tapers off, and a
+positive curve yields a slower initial increase in acceleration followed by a
+sharp increase as the number of pointer events generated by the action
+approaches <emphasis>
+mk_time_to_max</emphasis>
+. The legal values for <emphasis>
+mk_curve</emphasis>
+ are between -1000 and 1000.
+</para>
+
+
+<para>
+A distance vs. time graph of the pointer motion is shown in Figure 10.1. <!-- xref -->
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-6.svg"/>
+ </imageobject>
+<caption>MouseKeys Acceleration</caption>
+ </mediaobject>
+
+<!--
+<H5 CLASS="Figure">
+MouseKeys Acceleration</H5>
+-->
+</sect3>
+</sect2>
+</sect1>
+<sect1 id='controls_for_better_keyboard_access_by_physically_impaired_persons'>
+<title>Controls for Better Keyboard Access by Physically Impaired
+Persons</title>
+
+<para>
+The Xkb extension includes several controls specifically aimed at making
+keyboard use more effective for physically impaired people. All of these
+controls are boolean controls and may be individually enabled and disabled, as
+well as configured to tune their specific behavior. The behavior of these
+controls is based on the AccessDOS package
+<footnote><para>
+AccessDOS provides access to the DOS operating system for people with physical
+impairments and was developed by the Trace R&amp;D Center at the University of
+Wisconsin. For more information on AccessDOS, contact the Trace R&amp;D Center,
+Waisman Center and Department of Industrial Engineering, University of
+Wisconsin-Madison WI 53705-2280. Phone: 608-262-6966. e-mail: info@trace.wisc.edu.
+</para></footnote>.
+</para>
+
+<sect2 id='the_accessxkeys_control'>
+<title>The AccessXKeys Control</title>
+
+<para>
+Enabling or disabling the keyboard controls through a graphical user interface
+may be impossible for people who need to use the controls. For example, a user
+who needs <emphasis>
+SlowKeys</emphasis>
+ (see section 10.6.6) may not even be able to start the graphical application, <!-- xref -->
+let alone use it, if <emphasis>
+SlowKeys</emphasis>
+ is not enabled. To allow easier access to some of the controls, the <emphasis>
+AccessXKeys</emphasis>
+ control provides a set of special key sequences similar to those available in
+AccessDOS.
+</para>
+
+
+<para>
+When the <emphasis>
+AccessXKeys</emphasis>
+ control is enabled, the user can turn controls on or off from the keyboard by
+entering the following standard key sequences:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Holding down a shift key by itself for eight seconds toggles the <emphasis>
+SlowKeys</emphasis>
+ control.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Pressing and releasing the left or right <emphasis>
+Shift</emphasis>
+ key five times in a row, without any intervening key events and with less than
+30 seconds delay between consecutive presses, toggles the state of the
+<emphasis>
+StickyKeys</emphasis>
+ control.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Simultaneously operating two or more modifier keys deactivates the <emphasis>
+StickyKeys</emphasis>
+ control.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+When the <emphasis>
+AccessXKeys</emphasis>
+ control is disabled, Xkb does not look for the above special key sequences.
+</para>
+
+
+<para>
+Some of these key sequences optionally generate audible feedback of the change
+in state, as described in section 10.6.3, or <!-- xref -->
+<emphasis>XkbControlsNotify</emphasis>
+ events, described in section 10.11. <!-- xref -->
+</para>
+
+</sect2>
+<sect2 id='the_accessxtimeout_control'>
+<title>The AccessXTimeout Control</title>
+
+<para>
+In environments where computers are shared, features such as <emphasis>
+SlowKeys</emphasis>
+ present a problem: if <emphasis>
+SlowKeys</emphasis>
+ is on, the keyboard can appear to be unresponsive because keys are not
+accepted until they are held for a certain period of time. To help solve this
+problem, Xkb provides an <emphasis>
+AccessXTimeout</emphasis>
+ control to automatically change the enabled/disabled state of any boolean
+controls and to change the value of the <emphasis>
+AccessXKeys</emphasis>
+ and <emphasis>
+AccessXFeedback</emphasis>
+ control attributes if the keyboard is idle for a specified period of time.
+</para>
+
+
+<para>
+When a timeout as specified by <emphasis>
+AccessXTimeout</emphasis>
+ occurs and a control is consequently modified, Xkb generates an <emphasis>
+XkbControlsNotify</emphasis>
+ event. For more information on <emphasis>
+XkbControlsNotify</emphasis>
+ events, refer to section 10.11. <!-- xref -->
+</para>
+
+
+<para>
+Use <emphasis>
+XkbGetAccessXTimeout</emphasis>
+ to query the current <emphasis>
+AccessXTimeout</emphasis>
+ options for a keyboard device.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetAccessXTimeout</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ timeout_rtrn</emphasis>
+,<emphasis>
+ ctrls_mask_rtrn</emphasis>
+,<emphasis>
+ ctrls_values_rtrn</emphasis>
+,<emphasis>
+ options_mask_rtrn, options_values_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device to query, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short * <emphasis>
+timeout_rtrn</emphasis>
+; /* delay until AccessXTimeout, seconds */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int *<emphasis>
+ ctrls_mask_rtrn</emphasis>
+; /* backfilled with controls to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+ctrls_values_rtrn</emphasis>
+; /* backfilled with on/off status for controls */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short * <emphasis>
+opts_mask_rtrn</emphasis>
+; /* backfilled with <emphasis>
+ax_options</emphasis>
+ to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short * <emphasis>
+opts_values_rtrn</emphasis>
+; /* backfilled with values for <emphasis>
+ax_options</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetAccessXTimeout</emphasis>
+ sends a request to the X server to obtain the current values for the <emphasis>
+AccessXTimeout</emphasis>
+ attributes, waits for a reply, and backfills the values into the appropriate
+arguments.<emphasis>
+ </emphasis>
+The parameters <emphasis>
+opts_mask_rtrn</emphasis>
+ and <emphasis>
+opts_values_rtrn</emphasis>
+ are backfilled with the options to modify and the values for <emphasis>
+ax_options</emphasis>
+, which is a field in the
+<emphasis>XkbControlsRec</emphasis>
+ structure (see section 10.8). <!-- xref -->
+<emphasis>
+XkbGetAccessXTimeout </emphasis>
+returns<emphasis>
+ </emphasis>
+<emphasis>
+True</emphasis>
+ if successful; if a compatible version of the Xkb extension is not available
+in the server, <emphasis>
+XkbGetAccessXTimeout</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+To configure the <emphasis>
+AccessXTimeout</emphasis>
+ options for a keyboard device, use <emphasis>
+XkbSetAccessXTimeout</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetAccessXTimeout</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec, timeout, ctrls_mask, ctrls_values, opts_mask,
+opts_values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ device_spec</emphasis>
+; /* device to configure, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short <emphasis>
+timeout</emphasis>
+; /* seconds idle until AccessXTimeout occurs */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ ctrls_mask</emphasis>
+; /* boolean controls to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ ctrls_values</emphasis>
+; /* new bits for controls selected by <emphasis>
+ctrls_mask</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short <emphasis>
+opts_mask</emphasis>
+; /* <emphasis>
+ax_options</emphasis>
+ to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short <emphasis>
+opts_values</emphasis>
+; /* new bits for <emphasis>
+ax_options</emphasis>
+ selected by <emphasis>
+opts_mask</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+timeout</emphasis>
+ specifies the number of seconds the keyboard must be idle before the controls
+are modified. <emphasis>
+ctrls_mask</emphasis>
+ specifies what controls are to be enabled or disabled, and <emphasis>
+ctrls_values</emphasis>
+ specifies whether those controls are to be enabled or disabled. The bit values
+correspond to those for enabling and disabling boolean controls (see section
+10.1.1). The <emphasis>
+opts_mask</emphasis>
+ field specifies which attributes of the <emphasis>
+AccessXKeys</emphasis>
+ and <emphasis>
+AccessXFeedback</emphasis>
+ controls are to be changed, and <emphasis>
+opts_values</emphasis>
+ specifies the new values for those options. The bit values correspond to those
+for the <emphasis>
+ax_options</emphasis>
+ field of an <emphasis>
+XkbDescRec</emphasis>
+ (see section 10.8). <!-- xref -->
+</para>
+
+
+<para>
+<emphasis>
+XkbSetAccessXTimeout</emphasis>
+ sends a request to configure the <emphasis>
+AccessXTimeout</emphasis>
+ control to the server.<emphasis>
+ </emphasis>
+It does not wait for a reply, and normally returns <emphasis>
+True</emphasis>
+. If a compatible version of the Xkb extension is not available in the server,
+<emphasis>
+XkbSetAccessXTimeout</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='the_accessxfeedback_control'>
+<title>The AccessXFeedback Control</title>
+
+<para>
+Just as some keyboards can produce keyclicks to indicate when a key is pressed
+or repeating, Xkb can provide feedback for the controls by using special beep
+codes. Use the <emphasis>
+AccessXFeedback</emphasis>
+ control to configure the specific types of operations that generate feedback.
+</para>
+
+
+<para>
+There is no convenience function for modifying the <emphasis>
+AccessXFeedback</emphasis>
+ control, although the feedback as a whole can be enabled or disabled just as
+other boolean controls are (see section 10.1). Individual beep codes are turned
+on or off by modifying the following bits in the <emphasis>
+ax_options</emphasis>
+ field of an <emphasis>
+XkbControlsRec</emphasis>
+ structure and using <emphasis>
+XkbSetControls</emphasis>
+ (see section 10.10): <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>AccessXFeedback Masks</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Action</entry>
+ <entry>Beep Code</entry>
+ <entry>ax_options bit</entry>
+ </row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>LED turned on</entry>
+ <entry>High-pitched beep</entry>
+ <entry>XkbAX_IndicatorFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>LED turned off</entry>
+ <entry>Low-pitched beep</entry>
+ <entry>XkbAX_IndicatorFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>More than one LED changed state</entry>
+ <entry>Two high-pitched beeps</entry>
+ <entry>XkbAX_IndicatorFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>Control turned on</entry>
+ <entry>Rising tone</entry>
+ <entry>XkbAX_FeatureFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>Control turned off</entry>
+ <entry>Falling tone</entry>
+ <entry>XkbAX_FeatureFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>More than one control changed state</entry>
+ <entry>Two high-pitched beeps</entry>
+ <entry>XkbAX_FeatureFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys and BounceKeys about to be turned on or off</entry>
+ <entry>Three high-pitched beeps</entry>
+ <entry>XkbAX_SlowWarnFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key pressed</entry>
+ <entry>Medium-pitched beep</entry>
+ <entry>XkbAX_SKPressFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key accepted</entry>
+ <entry>Medium-pitched beep</entry>
+ <entry>XkbAX_SKAcceptFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>SlowKeys key rejected</entry>
+ <entry>Low-pitched beep</entry>
+ <entry>XkbAX_SKRejectFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>Accepted SlowKeys key released</entry>
+ <entry>Medium-pitched beep</entry>
+ <entry>XkbAX_SKReleaseFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>BounceKeys key rejected</entry>
+ <entry>Low-pitched beep</entry>
+ <entry>XkbAX_BKRejectFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key latched</entry>
+ <entry>Low-pitched beep followed by high-pitched beep</entry>
+ <entry>XkbAX_StickyKeysFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key locked</entry>
+ <entry>High-pitched beep</entry>
+ <entry>XkbAX_StickyKeysFBMask</entry>
+</row>
+<row rowsep='0'>
+ <entry>StickyKeys key unlocked</entry>
+ <entry>Low-pitched beep</entry>
+ <entry>XkbAX_StickyKeysFBMask</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Implementations that cannot generate continuous tones may generate multiple
+beeps instead of falling and rising tones; for example, they can generate a
+high-pitched beep followed by a low-pitched beep instead of a continuous
+falling tone. Other implementations can only ring the bell with one fixed
+pitch. In these cases, use the <emphasis>
+XkbAX_DumbBellFBMask</emphasis>
+ bit of <emphasis>
+ax_options</emphasis>
+ to indicate that the bell can only ring with a fixed pitch.
+</para>
+
+
+<para>
+When any of the above feedbacks occur, Xkb may generate a <emphasis>
+XkbBellNotify</emphasis>
+ event (see section 9.4). <!-- xref -->
+</para>
+
+
+</sect2>
+<sect2 id='accessxnotify_events'>
+<title>AccessXNotify Events</title>
+
+<para>
+The server can generate <emphasis>
+XkbAccessXNotify</emphasis>
+ events for some of the global keyboard controls. The structure for the
+<emphasis>
+XkbAccessXNotify</emphasis>
+ event type is as follows:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis> XkbAccessXNotify</emphasis> */
+ int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ int detail; /* XkbAXN_* */
+ KeyCode keycode; /* key of event */
+ int slowKeysDelay; /* current SlowKeys delay */
+ int debounceDelay; /* current debounce delay */
+} <emphasis>XkbAccessXNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+detail</emphasis>
+ field describes what AccessX event just occurred and can be any of the values
+in Table 10.4. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>AccessXNotify Events</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>detail</entry>
+ <entry>Reason</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbAXN_SKPress</entry>
+ <entry>A key was pressed when SlowKeys was enabled.</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_SKAccept</entry>
+ <entry>A key was accepted (held longer than the SlowKeys delay).</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_SKRelease</entry>
+ <entry>An accepted SlowKeys key was released.</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_SKReject</entry>
+ <entry>A key was rejected (released before the SlowKeys delay
+expired).</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_BKAccept</entry>
+ <entry>A key was accepted by BounceKeys.</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_BKReject</entry>
+ <entry>A key was rejected (pressed before the BounceKeys delay
+expired).</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAXN_AXKWarning</entry>
+ <entry>AccessXKeys is about to turn on/off StickyKeys or BounceKeys.</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+keycode</emphasis>
+ field reports the keycode of the key for which the event occurred. If the
+action is related to <emphasis>
+SlowKeys</emphasis>
+, the <emphasis>
+slowKeysDelay</emphasis>
+ field contains the current <emphasis>
+SlowKeys</emphasis>
+ acceptance delay. If the action is related to <emphasis>
+BounceKeys</emphasis>
+, the <emphasis>
+debounceDelay</emphasis>
+ field contains the current <emphasis>
+BounceKeys</emphasis>
+ debounce delay.
+</para>
+
+<sect3 id='selecting_for_accessx_events'>
+<title>Selecting for AccessX Events</title>
+
+<para>
+To receive <emphasis>
+XkbAccessXNotify</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) and pass <emphasis> <!-- xref -->
+XkbAccesXNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbStateNotify</emphasis>
+ events only under certain conditions, use <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbAccessXNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying the desired state changes in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ using mask bits from Table 10.5. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>AccessXNotify Event Details</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>XkbAccessXNotify Event Details</entry>
+ <entry>Value</entry>
+ <entry>Circumstances</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbAXN_SKPressMask</entry>
+ <entry>(1&lt;&lt;0)</entry>
+ <entry>Slow key press notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_SKAcceptMask</entry>
+ <entry>(1&lt;&lt;1)</entry>
+ <entry>Slow key accept notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_SKRejectMask</entry>
+ <entry>(1&lt;&lt;2)</entry>
+ <entry>Slow key reject notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_SKReleaseMask</entry>
+ <entry>(1&lt;&lt;3)</entry>
+ <entry>Slow key release notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_BKAcceptMask</entry>
+ <entry>(1&lt;&lt;4)</entry>
+ <entry>Bounce key accept notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_BKRejectMask</entry>
+ <entry>(1&lt;&lt;5)</entry>
+ <entry>Bounce key reject notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_AXKWarningMask</entry>
+ <entry>(1&lt;&lt;6)</entry>
+ <entry>AccessX warning notification wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAXN_AllEventsMask</entry>
+ <entry>(0x7f)</entry>
+ <entry>All AccessX features notifications wanted</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect3>
+</sect2>
+<sect2 id='stickykeys_repeatkeys_and_mousekeys_events'>
+<title>StickyKeys, RepeatKeys, and MouseKeys Events</title>
+
+<para>
+The <emphasis>
+StickyKeys</emphasis>
+, <emphasis>
+RepeatKeys</emphasis>
+, and <emphasis>
+MouseKeys</emphasis>
+ controls do not generate specific events. Instead, the latching, unlatching,
+locking, or unlocking of modifiers using <emphasis>
+StickyKeys</emphasis>
+ generates <emphasis>
+XkbStateNotify</emphasis>
+ events as described in section 5.4. Repeating keys generate normal <emphasis> <!-- xref -->
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events, though the auto-repeat can be detected using <emphasis>
+DetectableAutorepeat</emphasis>
+ (see section 10.3.3). Finally, <emphasis> <!-- xref -->
+MouseKeys</emphasis>
+ generates pointer events identical to those of the core pointer device.
+</para>
+
+
+</sect2>
+<sect2 id='the_slowkeys_control'>
+<title>The SlowKeys Control</title>
+
+<para>
+Some users may accidentally bump keys while moving a hand or typing stick
+toward the key they want. Usually, the keys that are accidentally bumped are
+just hit for a very short period of time. The <emphasis>
+SlowKeys</emphasis>
+ control helps filter these accidental bumps by telling the server to wait a
+specified period, called the <emphasis>
+SlowKeys acceptance delay</emphasis>
+, before delivering key events. If the key is released before this period
+elapses, no key events are generated. Users can then bump any number of keys on
+their way to the one they want without accidentally getting those characters.
+Once they have reached the key they want, they can then hold the desired key
+long enough for the computer to accept it. <emphasis>
+SlowKeys</emphasis>
+ is a boolean control with one configurable attribute.
+</para>
+
+<para>
+When the <emphasis>
+SlowKeys</emphasis>
+ control is active, the server reports the initial key press, subsequent
+acceptance or rejection, and release of any key to interested clients by
+sending an appropriate <emphasis>
+AccessXNotify</emphasis>
+ event (see section 10.6.4). <!-- xref -->
+</para>
+
+<para>
+To get the <emphasis>
+SlowKeys</emphasis>
+ acceptance delay for a keyboard device, use <emphasis>
+XkbGetSlowKeysDelay</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetSlowKeysDelay</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ delay_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+delay_rtrn</emphasis>
+; /* backfilled with <emphasis>
+SlowKeys</emphasis>
+ delay, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetSlowKeysDelay </emphasis>
+requests the attributes of the <emphasis>
+SlowKeys</emphasis>
+ control from the server, waits for a reply and backfills <emphasis>
+delay_rtrn </emphasis>
+with the <emphasis>
+SlowKeys</emphasis>
+ delay attribute. <emphasis>
+XkbGetSlowKeysDelay </emphasis>
+returns <emphasis>
+True</emphasis>
+ if successful; if a compatible version of the Xkb extension is not available
+in the server, <emphasis>
+XkbGetSlowKeysDelay</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+To set the <emphasis>
+SlowKeys</emphasis>
+ acceptance delay for a keyboard device, use <emphasis>
+XkbSetSlowKeysDelay</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetSlowKeysDelay</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ delay</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device to configure, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+delay</emphasis>
+; /* <emphasis>
+SlowKeys</emphasis>
+ delay, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetSlowKeysDelay</emphasis>
+ sends a request to configure the <emphasis>
+SlowKeys</emphasis>
+ control to the server.<emphasis>
+ </emphasis>
+It does not wait for a reply, and normally returns <emphasis>
+True</emphasis>
+. Specifying a value of <emphasis>
+0</emphasis>
+ for the <emphasis>
+delay </emphasis>
+parameter causes <emphasis>
+XkbSetSlowKeys</emphasis>
+ to generate a <emphasis>
+BadValue</emphasis>
+ protocol error. If a compatible version of the Xkb extension is not available
+in the server <emphasis>
+XkbSetSlowKeysDelay</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='the_bouncekeys_control'>
+<title>The BounceKeys Control</title>
+
+<para>
+Some users may accidentally "bounce" on a key when they release it. They press
+it once, then accidentally press it again after they release it. The <emphasis>
+BounceKeys</emphasis>
+ control temporarily disables a key after it has been pressed, effectively
+"debouncing" the keyboard. The period of time the key is disabled after it is
+released is known as the <emphasis>
+BounceKeys delay</emphasis>
+. <emphasis>
+BounceKeys</emphasis>
+ is a boolean control.
+</para>
+
+
+<para>
+When the <emphasis>
+BounceKeys</emphasis>
+ control is active, the server reports acceptance or rejection of any key to
+interested clients by sending an appropriate <emphasis>
+AccessXNotify</emphasis>
+ event (see section 10.6.4). <!-- xref -->
+</para>
+
+
+<para>
+Use <emphasis>
+XkbGetBounceKeysDelay</emphasis>
+ to query the current <emphasis>
+BounceKeys</emphasis>
+ delay for a keyboard device.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetBounceKeysDelay</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ delay_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+delay_rtrn</emphasis>
+; /* backfilled with bounce keys delay, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetBounceKeysDelay </emphasis>
+requests the attributes of the <emphasis>
+BounceKeys</emphasis>
+ control from the server, waits for a reply, and backfills <emphasis>
+delay_rtrn </emphasis>
+with the <emphasis>
+BounceKeys</emphasis>
+ delay attribute. <emphasis>
+XkbGetBounceKeysDelay </emphasis>
+returns<emphasis>
+ </emphasis>
+<emphasis>
+True</emphasis>
+ if successful; if a compatible version of the Xkb extension is not available
+in the server <emphasis>
+XkbGetSlowKeysDelay</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+To set the <emphasis>
+BounceKeys</emphasis>
+ delay for a keyboard device, use <emphasis>
+XkbSetBounceKeysDelay</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetBounceKeysDelay</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ delay</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ device_spec</emphasis>
+; /* device to configure, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+delay</emphasis>
+; /* bounce keys delay, ms */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetBounceKeysDelay</emphasis>
+ sends a request to configure the <emphasis>
+BounceKeys</emphasis>
+ control to the server.<emphasis>
+ </emphasis>
+It does not wait for a reply and normally returns <emphasis>
+True</emphasis>
+. Specifying a value of <emphasis>
+zero </emphasis>
+for the <emphasis>
+delay </emphasis>
+parameter causes <emphasis>
+XkbSetBounceKeysDelay</emphasis>
+ to generate a <emphasis>
+BadValue</emphasis>
+ protocol error. If a compatible version of the Xkb extension is not available
+in the server, <emphasis>
+XkbSetBounceKeysDelay</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+</sect2>
+<sect2 id='the_stickykeys_control'>
+<title>The StickyKeys Control</title>
+
+<para>
+Some people find it difficult or even impossible to press two keys at once. For
+example, a one-fingered typist or someone using a mouth stick cannot press the
+<emphasis>
+Shift</emphasis>
+ and <emphasis>
+1</emphasis>
+ keys at the same time. The <emphasis>
+StickyKeys</emphasis>
+ control solves this problem by changing the behavior of the modifier keys.
+With <emphasis>
+StickyKeys</emphasis>
+, the user can first press a modifier, release it, then press another key. For
+example, to get an exclamation point on a PC-style keyboard, the user can press
+the <emphasis>
+Shift</emphasis>
+ key, release it, and then press the <emphasis>
+1</emphasis>
+ key.
+</para>
+
+
+<para>
+<emphasis>
+StickyKeys</emphasis>
+ also allows users to lock modifier keys without requiring special locking
+keys. When <emphasis>
+StickyKeys</emphasis>
+ is enabled, a modifier is latched when the user presses it just once. The user
+can press a modifier twice in a row to lock it, and then unlock it by pressing
+it one more time.
+</para>
+
+
+<para>
+When a modifier is latched, it becomes unlatched when the user presses a
+nonmodifier key or a pointer button. For instance, to enter the sequence
+<emphasis>
+Shift</emphasis>
++<emphasis>
+Control</emphasis>
++<emphasis>
+Z</emphasis>
+ the user could press and release the <emphasis>
+Shift</emphasis>
+ key to latch it, then press and release the <emphasis>
+Control</emphasis>
+ key to latch it, and finally press and release the Z key. Because the
+<emphasis>
+Control</emphasis>
+ key is a modifier key, pressing it does not unlatch the <emphasis>
+Shift</emphasis>
+ key. Thus, after the user presses the <emphasis>
+Control</emphasis>
+ key, both the <emphasis>
+Shift</emphasis>
+ and <emphasis>
+Control</emphasis>
+ modifiers are latched. When the user presses the <emphasis>
+Z</emphasis>
+ key, the effect is as though the user had pressed <emphasis>
+Shift</emphasis>
++<emphasis>
+Control</emphasis>
++<emphasis>
+Z</emphasis>
+. In addition, because the <emphasis>
+Z</emphasis>
+ key is not a modifier key, the <emphasis>
+Shift</emphasis>
+ and <emphasis>
+Control</emphasis>
+ modifiers are unlatched.
+</para>
+
+
+<para>
+Locking a modifier key means that the modifier affects any key or pointer
+button the user presses until the user unlocks it or it is unlocked
+programmatically. For example, to enter the sequence ("XKB") on a keyboard
+where ‘(’ is a shifted ‘9’, ‘)’ is a shifted ‘0’, and ‘"’
+is a shifted single quote, the user could press and release the <emphasis>
+Shift</emphasis>
+ key twice to lock the <emphasis>
+Shift</emphasis>
+ modifier. Then, when the user presses the <emphasis>
+9</emphasis>
+, <emphasis>
+‘</emphasis>
+, <emphasis>
+x</emphasis>
+, <emphasis>
+k</emphasis>
+, <emphasis>
+b</emphasis>
+, <emphasis>
+‘</emphasis>
+, and <emphasis>
+0</emphasis>
+ keys in sequence, it generates ("XKB"). To unlock the <emphasis>
+Shift</emphasis>
+ modifier, the user can press and release the <emphasis>
+Shift</emphasis>
+ key.
+</para>
+
+
+<para>
+<emphasis>StickyKeys</emphasis>
+ is a boolean control with two separate attributes that may be individually
+configured: one to automatically disable it, and one to control the latching
+behavior of modifier keys.
+</para>
+
+<sect3 id='stickykeys_options'>
+<title>StickyKeys Options</title>
+
+<para>
+The <emphasis>
+StickyKeys</emphasis>
+ control has two options that can be accessed via the <emphasis>
+ax_options</emphasis>
+ of an <emphasis>
+XkbControlsRec</emphasis>
+ structure (see section 10.8). The first option, <emphasis>
+TwoKeys</emphasis>
+, specifies whether <emphasis>
+StickyKeys</emphasis>
+ should automatically turn off when two keys are pressed at the same time. This
+feature is useful for shared computers so people who do not want them do not
+need to turn <emphasis>
+StickyKeys</emphasis>
+ off if a previous user left <emphasis>
+StickyKeys</emphasis>
+ on. The second option, <emphasis>
+LatchToLock</emphasis>
+, specifies whether or not <emphasis>
+StickyKeys</emphasis>
+ locks a modifier when pressed twice in a row.
+</para>
+
+
+<para>
+Use <emphasis>
+XkbGetStickyKeysOptions</emphasis>
+ to query the current <emphasis>
+StickyKeys</emphasis>
+ attributes for a keyboard device.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetStickyKeysOptions</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec</emphasis>
+,<emphasis>
+ options_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+options_rtrn</emphasis>
+; /* backfilled with StickyKeys option mask */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetStickyKeysOptions </emphasis>
+requests the attributes of the <emphasis>
+StickyKeys</emphasis>
+ control from the server, waits for a reply, and backfills <emphasis>
+options_rtrn </emphasis>
+with a mask indicating whether the individual <emphasis>
+StickyKeys</emphasis>
+ options are on or off. Valid bits in <emphasis>
+options_rtrn</emphasis>
+ are:
+</para>
+
+<para>
+<programlisting>
+ <emphasis>XkbAX_TwoKeysMask</emphasis>
+ <emphasis>XkbAX_LatchToLockMask</emphasis>
+</programlisting>
+</para>
+
+<para>
+<emphasis>
+XkbGetStickyKeysOptions </emphasis>
+returns <emphasis>
+True</emphasis>
+ if successful; if a compatible version of the Xkb extension is not available
+in the server <emphasis>
+XkbGetStickyKeysOptions</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+To set the <emphasis>
+StickyKeys</emphasis>
+ attributes for a keyboard device, use <emphasis>
+XkbSetStickyKeysOptions</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetStickyKeysOptions</emphasis>
+(<emphasis>
+display</emphasis>
+,<emphasis>
+ device_spec, mask, values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device to configure, or XkbUseCoreKbd */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+mask</emphasis>
+; /* selects StickyKeys attributes to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+values;</emphasis>
+ /* values for selected attributes */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetStickyKeysOptions</emphasis>
+ sends a request to configure the <emphasis>
+StickyKeys</emphasis>
+ control to the server.<emphasis>
+ </emphasis>
+It does not wait for a reply and normally returns <emphasis>
+True</emphasis>
+. The valid bits to use for both the <emphasis>
+mask</emphasis>
+ and <emphasis>
+values</emphasis>
+ parameters are:
+</para>
+
+<para>
+<programlisting>
+ <emphasis>XkbAX_TwoKeysMask</emphasis>
+ <emphasis>XkbAX_LatchToLockMask</emphasis>
+</programlisting>
+</para>
+
+<para>
+ If a compatible version of the Xkb extension is not available in the server,
+<emphasis>
+XkbSetStickyKeysOptions</emphasis>
+ returns <emphasis>
+False</emphasis>
+.
+</para>
+
+</sect3>
+</sect2>
+</sect1>
+<sect1 id='controls_for_general_keyboard_mapping'>
+<title>Controls for General Keyboard Mapping</title>
+
+<para>
+There are several controls that apply to the keyboard mapping in general. They
+control handling of out-of-range group indices and how modifiers are processed
+and consumed in the server. These are:
+</para>
+
+<para>
+<programlisting>
+ <emphasis>GroupsWrap</emphasis>
+ <emphasis>IgnoreGroupLock</emphasis>
+ <emphasis>IgnoreLockMods</emphasis>
+ <emphasis>InternalMods </emphasis>
+</programlisting>
+</para>
+
+<para>
+<emphasis>
+IgnoreGroupLock</emphasis>
+ is a boolean control; the rest are always active.
+</para>
+
+
+<para>
+Without the modifier processing options provided by Xkb, passive grabs set via
+translations in a client (for example, <emphasis>
+Alt&lt;KeyPress&gt;space</emphasis>
+) do not trigger if any modifiers other than those specified by the translation
+are set. This results in problems in the user interface when either <emphasis>
+NumLock</emphasis>
+ or a secondary keyboard group is active. The <emphasis>
+IgnoreLockMods</emphasis>
+ and <emphasis>
+IgnoreGroupLock</emphasis>
+ controls make it possible to avoid this behavior without exhaustively
+specifying a grab for every possible modifier combination.
+</para>
+
+<sect2 id='the_groupswrap_control'>
+<title>The GroupsWrap Control</title>
+
+<para>
+The <emphasis>
+GroupsWrap</emphasis>
+ control determines how illegal groups are handled on a global basis. There are
+a number of valid keyboard sequences that can cause the effective group number
+to go out of range. When this happens, the group must be normalized back to a
+valid number. The <emphasis>
+GroupsWrap</emphasis>
+ control specifies how this is done.
+</para>
+
+
+<para>
+When dealing with group numbers, all computations are done using the group
+index, which is the group number minus one. There are three different
+algorithms; the <emphasis>
+GroupsWrap</emphasis>
+ control specifies which one is used:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>XkbRedirectIntoRange</para>
+ <para>
+All invalid group numbers are converted to a valid group number by taking the
+last four bits of the <emphasis>
+GroupsWrap</emphasis>
+ control and using them as the group index. If the result is still out of
+range, Group one is used.
+ </para>
+</listitem>
+<listitem>
+ <para>
+XkbClampIntoRange
+ </para>
+ <para>
+All invalid group numbers are converted to the nearest valid group number.
+Group numbers larger than the highest supported group number are mapped to the
+highest supported group; those less than one are mapped to group one.
+ </para>
+</listitem>
+<listitem>
+ <para>XkbWrapIntoRange</para>
+ <para>
+All invalid group numbers are converted to a valid group number using integer
+modulus applied to the group index.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+There are no convenience functions for manipulating the <emphasis>
+GroupsWrap</emphasis>
+ control. Manipulate the <emphasis>
+GroupsWrap</emphasis>
+ control via the <emphasis>
+groups_wrap</emphasis>
+ field in the <emphasis>
+XkbControlsRec</emphasis>
+ structure, then use <emphasis>
+XkbSetControls</emphasis>
+ and <emphasis>
+XkbGetControls</emphasis>
+ (see section 10.9 and section 10.10) to query and change this control. <!-- xref -->
+</para>
+
+<note><para>See also section 15.3.2 or a discussion of the related field, <!-- xref -->
+<emphasis>
+group_info</emphasis>
+, which also normalizes a group under certain circumstances.</para></note>
+
+</sect2>
+<sect2 id='the_ignorelockmods_control'>
+<title>The IgnoreLockMods Control</title>
+
+<para>
+The core protocol does not provide a way to exclude specific modifiers from
+grab calculations, with the result that locking modifiers sometimes have
+unanticipated side effects.
+</para>
+
+
+<para>
+The <emphasis>
+IgnoreLockMods</emphasis>
+ control specifies modifiers that should be excluded from grab calculations.
+These modifiers are also not reported in any core events except <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events that do not activate a passive grab and that do not occur while a grab
+is active.
+</para>
+
+
+<para>
+Manipulate the <emphasis>
+IgnoreLockMods</emphasis>
+ control via the <emphasis>
+ignore_lock</emphasis>
+ field in the <emphasis>
+XkbControlsRec</emphasis>
+ structure, then use <emphasis>
+XkbSetControls</emphasis>
+ and <emphasis>
+XkbGetControls</emphasis>
+ (see sections 10.9 and 10.10) to query and change this control. Alternatively, <!-- xref -->
+use <emphasis>
+XkbSetIgnoreLockMods</emphasis>
+.
+</para>
+
+
+<para>
+To set the modifiers that, if locked, are not to be reported in matching events
+to passive grabs, use <emphasis>
+XkbSetIgnoreLockMods.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetIgnoreLockMods</emphasis>
+(<emphasis>
+display, device_spec, affect_real, real_values, affect_virtual,
+virtual_values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect_real</emphasis>
+; /* mask of real modifiers affected by this call */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ real_values</emphasis>
+; /* values for affected real modifiers (1=&gt;set, 0=&gt;unset) */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect_virtual</emphasis>
+; /* mask of virtual modifiers affected by this call */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ virtual_values</emphasis>
+; /* values for affected virtual modifiers (1=&gt;set, 0=&gt;unset)
+*/
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetIgnoreLockMods</emphasis>
+ sends a request to the server to change the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control. <emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ are masks of real modifier bits indicating which real modifiers are to be
+added and removed from the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control. Modifiers selected by both <emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ are added to the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control; those selected by <emphasis>
+affect_real</emphasis>
+ but not by <emphasis>
+real_values</emphasis>
+ are removed from the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control. Valid values for <emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ consist of any combination of the eight core modifier bits: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+ - <emphasis>
+Mod5Mask</emphasis>
+. <emphasis>
+affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+ are masks of virtual modifier bits indicating which virtual modifiers are to
+be added and removed from the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control. Modifiers selected by both <emphasis>
+affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+ are added to the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control; those selected by <emphasis>
+affect_virtual</emphasis>
+ but not by <emphasis>
+virtual_values</emphasis>
+ are removed from the server’s <emphasis>
+IgnoreLockMods</emphasis>
+ control.<emphasis>
+ </emphasis>
+See section 7.1 for a discussion of virtual modifier masks to use in <emphasis> <!-- xref -->
+affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+. <emphasis>
+XkbSetIgnoreLockMods</emphasis>
+ does not wait for a reply from the server. It returns <emphasis>
+True</emphasis>
+ if the request was sent, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+</sect2>
+<sect2 id='the_ignoregrouplock_control'>
+<title>The IgnoreGroupLock Control</title>
+
+<para>
+The <emphasis>
+IgnoreGroupLock</emphasis>
+ control is a boolean control with no attributes. If enabled, it specifies that
+the locked state of the keyboard group should not be considered when activating
+passive grabs.
+</para>
+
+<para>
+Because <emphasis>
+IgnoreGroupLock</emphasis>
+ is a boolean control with no attributes, use the general boolean controls
+functions (see section 10.1) to change its state. <!-- xref -->
+</para>
+
+
+</sect2>
+<sect2 id='the_internalmods_control'>
+<title>The InternalMods Control</title>
+
+<para>
+The core protocol does not provide any means to prevent a modifier from being
+reported in events sent to clients; Xkb, however makes this possible via the
+<emphasis>
+InternalMods</emphasis>
+ control. It specifies modifiers that should be consumed by the server and not
+reported to clients. When a key is pressed and a modifier that has its bit set
+in the <emphasis>
+InternalMods</emphasis>
+ control is reported to the server, the server uses the modifier when
+determining the actions to apply for the key. The server then clears the bit,
+so it is not actually reported to the client. In addition, modifiers specified
+in the <emphasis>
+InternalMods</emphasis>
+ control are not used to determine grabs and are not used to calculate core
+protocol compatibility state.
+</para>
+
+
+<para>
+Manipulate the <emphasis>
+InternalMods</emphasis>
+ control via the <emphasis>
+internal</emphasis>
+ field in the <emphasis>
+XkbControlsRec</emphasis>
+ structure, using <emphasis>
+XkbSetControls</emphasis>
+ and <emphasis>
+XkbGetControls</emphasis>
+ (see sections10.9 and 10.10). Alternatively, use <emphasis> <!-- xref -->
+XkbSetServerInternalMods</emphasis>
+.
+</para>
+
+
+<para>
+To set the modifiers that are consumed by the server before events are
+delivered to the client, use <emphasis>
+XkbSetServerInternalMods.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetServerInternalMods</emphasis>
+(<emphasis>
+display, device_spec, affect_real, real_values, affect_virtual,
+virtual_values</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+display</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+;‘ /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect_real</emphasis>
+; /* mask of real modifiers affected by this call */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ real_values</emphasis>
+; /* values for affected real modifiers (1=&gt;set, 0=&gt;unset) */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ affect_virtual</emphasis>
+; /* mask of virtual modifiers affected by this call */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ virtual_values</emphasis>
+; /* values for affected virtual modifiers (1=&gt;set, 0=&gt;unset)
+*/
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetServerInternalMods</emphasis>
+ sends a request to the server to change the internal modifiers consumed by the
+server. <emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ are masks of real modifier bits indicating which real modifiers are to be
+added and removed from the server’s internal modifiers control. Modifiers
+selected by both <emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ are added to the server’s internal modifiers control; those selected by
+<emphasis>
+affect_real</emphasis>
+ but not by <emphasis>
+real_values</emphasis>
+ are removed from the server’s internal modifiers mask. Valid values for
+<emphasis>
+affect_real</emphasis>
+ and <emphasis>
+real_values</emphasis>
+ consist of any combination of the eight core modifier bits: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+ - <emphasis>
+Mod5Mask</emphasis>
+.<emphasis>
+ affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+ are masks of virtual modifier bits indicating which virtual modifiers are to
+be added and removed from the server’s internal modifiers control. Modifiers
+selected by both <emphasis>
+affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+ are added to the server’s internal modifiers control; those selected by
+<emphasis>
+affect_virtual</emphasis>
+ but not by <emphasis>
+virtual_values</emphasis>
+ are removed from the server’s internal modifiers control.<emphasis>
+ </emphasis>
+See section 7.1 for a discussion of virtual modifier masks to use in <emphasis> <!-- xref -->
+affect_virtual</emphasis>
+ and <emphasis>
+virtual_values</emphasis>
+.<emphasis>
+ XkbSetServerInternalMods</emphasis>
+ does not wait for a reply from the server. It returns <emphasis>
+True</emphasis>
+ if the request was sent and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='the_xkbcontrolsrec_structure'>
+<title>The XkbControlsRec Structure</title>
+
+<para>
+Many of the individual controls described in sections 10.1 through 10.7 may be
+manipulated via convenience functions discussed in those sections. Some of
+them, however, have no convenience functions. The <emphasis>
+XkbControlsRec</emphasis>
+ structure allows the manipulation of one or more of the controls in a single
+operation and to track changes to any of them in conjunction with the <emphasis>
+XkbGetControls</emphasis>
+ and <emphasis>
+XkbSetControls</emphasis>
+ functions. This is the only way to manipulate those controls that have no
+convenience functions.
+</para>
+
+
+<para>
+The <emphasis>
+XkbControlsRec</emphasis>
+ structure is defined as follows:
+</para>
+
+<para>
+<programlisting>
+#define XkbMaxLegalKeyCode 255
+#define XkbPerKeyBitArraySize ((XkbMaxLegalKeyCode+1)/8)
+</programlisting>
+</para>
+<para>
+<programlisting>
+typedef struct {
+ unsigned char mk_dflt_btn; /* default button for keyboard driven mouse */
+ unsigned char num_groups; /* number of keyboard groups */
+ unsigned char groups_wrap; /* how to wrap out-of-bounds groups */
+ XkbModsRec internal; /* defines server internal modifiers */
+ XkbModsRec ignore_lock; /* modifiers to ignore when checking for grab */
+ unsigned int enabled_ctrls; /* 1 bit =&gt; corresponding boolean control enabled */
+ unsigned short repeat_delay; /* ms delay until first repeat */
+ unsigned short repeat_interval; /* ms delay between repeats */
+ unsigned short slow_keys_delay; /* ms minimum time key must be down to be ok */
+ unsigned short debounce_delay; /* ms delay before key reactivated */
+ unsigned short mk_delay; /* ms delay to second mouse motion event */
+ unsigned short mk_interval; /* ms delay between repeat mouse events */
+ unsigned short mk_time_to_max; /* # intervals until constant mouse move */
+ unsigned short mk_max_speed; /* multiplier for maximum mouse speed */
+ short mk_curve; /* determines mouse move curve type */
+ unsigned short ax_options; /* 1 bit =&gt; Access X option enabled */
+ unsigned short ax_timeout; /* seconds until Access X disabled */
+ unsigned short axt_opts_mask; /* 1 bit =&gt; options to reset on Access X timeout */
+ unsigned short axt_opts_values; /* 1 bit =&gt; turn option on, 0=&gt; off */
+ unsigned int axt_ctrls_mask; /* which bits in <emphasis> enabled_ctrls</emphasis> to modify */
+ unsigned int axt_ctrls_values; /* values for new bits in <emphasis> enabled_ctrls</emphasis> */
+ unsigned char per_key_repeat[XkbPerKeyBitArraySize]; /* per key auto repeat */
+} <emphasis>XkbControlsRec</emphasis>, *XkbControlsPtr;
+</programlisting>
+</para>
+
+<para>
+The general-purpose functions that work with the <emphasis>
+XkbControlsRec</emphasis>
+ structure use a mask to specify which controls are to be manipulated. Table
+10.6 lists these controls, the masks used to select them in the general
+function calls (<emphasis>
+which</emphasis>
+ parameter), and the data fields in the <emphasis>
+XkbControlsRec</emphasis>
+ structure that comprise each of the individual controls. Also listed are the
+bit used to turn boolean controls on and off and the section where each control
+is described in more detail.
+</para>
+
+<table frame='none'>
+<title>Xkb Controls</title>
+<tgroup cols='5'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Control</entry>
+ <entry>Control Selection Mask (which parameter)</entry>
+ <entry>Relevant XkbControlsRec Data Fields</entry>
+ <entry>Boolean Control enabled_ctrls bit</entry>
+ <entry>Section</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>AccessXFeedback</entry>
+ <entry>XkbAccessXFeedbackMask</entry>
+ <entry>ax_options: XkbAX_*FBMask</entry>
+ <entry>XkbAccessXFeedbackMask</entry>
+ <entry>10.6.3</entry> <!-- xref -->
+ </row>
+ <row rowsep='0'>
+ <entry>AccessXKeys</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>XkbAccessXKeysMask</entry>
+ <entry>10.6.1</entry> <!-- xref -->
+ </row>
+ <row rowsep='0'>
+ <entry>AccessXTimeout</entry>
+ <entry>XkbAccessXTimeoutMask</entry>
+ <entry>
+ <para>ax_timeout</para>
+ <para>axt_opts_mask</para>
+ <para>axt_opts_values</para>
+ <para>axt_ctrls_mask</para>
+ <para>axt_ctrls_values</para>
+ </entry>
+ <entry>XkbAccessXTimeoutMask</entry>
+ <entry>10.6.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>AudibleBell</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>XkbAudibleBellMask</entry>
+ <entry>9.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>AutoReset</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>10.1.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>BounceKeys</entry>
+ <entry>XkbBounceKeysMask</entry>
+ <entry>debounce_delay</entry>
+ <entry>XkbBounceKeysMask</entry>
+ <entry>10.6.7</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Detectable-Autorepeat</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>10.3.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>EnabledControls</entry>
+ <entry>XkbControlsEnabledMask</entry>
+ <entry>enabled_ctrls</entry>
+ <entry><emphasis>Non-Boolean Control</emphasis></entry>
+ <entry>10.1.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>GroupsWrap</entry>
+ <entry>XkbGroupsWrapMask</entry>
+ <entry>groups_wrap</entry>
+ <entry><emphasis>Non-Boolean Control</emphasis></entry>
+ <entry>10.7.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>IgnoreGroupLock</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>XkbIgnoreGroupLockMask</entry>
+ <entry>10.7.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>IgnoreLockMods</entry>
+ <entry>XkbIgnoreLockModsMask</entry>
+ <entry>ignore_lock</entry>
+ <entry><emphasis>Non-Boolean Control</emphasis></entry>
+ <entry>5.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>InternalMods</entry>
+ <entry>XkbInternalModsMask</entry>
+ <entry>internal</entry>
+ <entry><emphasis>Non-Boolean Control</emphasis></entry>
+ <entry>5.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>MouseKeys</entry>
+ <entry>XkbMouseKeysMask</entry>
+ <entry>mk_dflt_btn</entry>
+ <entry>XkbMouseKeysMask</entry>
+ <entry>10.5.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>MouseKeysAccel</entry>
+ <entry>XkbMouseKeysAccelMask</entry>
+ <entry>
+ <para>mk_delay</para>
+ <para>mk_interval</para>
+ <para>mk_time_to_max</para>
+ <para>mk_max_speed</para>
+ <para>mk_curve</para>
+ </entry>
+ <entry>XkbMouseKeysAccelMask</entry>
+ <entry>10.5.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Overlay1</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>XkbOverlay1Mask</entry>
+ <entry>10.4</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Overlay2</entry>
+ <entry></entry>
+ <entry></entry>
+ <entry>XkbOverlay2Mask</entry>
+ <entry>10.4</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>PerKeyRepeat</entry>
+ <entry>XkbPerKeyRepeatMask</entry>
+ <entry>per_key_repeat</entry>
+ <entry><emphasis>Non-Boolean Control</emphasis></entry>
+ <entry>10.3.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>RepeatKeys</entry>
+ <entry>XkbRepeatKeysMask</entry>
+ <entry>
+ <para>repeat_delay</para>
+ <para>repeat_interval</para>
+ </entry>
+ <entry>XkbRepeatKeysMask</entry>
+ <entry>10.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>SlowKeys</entry>
+ <entry>XkbSlowKeysMask</entry>
+ <entry>slow_keys_delay</entry>
+ <entry>XkbSlowKeysMask</entry>
+ <entry>10.6.6</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>StickyKeys</entry>
+ <entry>XkbStickyKeysMask</entry>
+ <entry>
+ <para>ax_options:</para>
+ <para>XkbAX_TwoKeysMask</para>
+ <para>XkbAX_LatchToLockMask</para>
+ </entry>
+ <entry>XkbStickyKeysMask</entry>
+ <entry>10.6.8</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Table 10.7 shows the actual values for the individual mask bits used to select <!-- xref -->
+controls for modification and to enable and disable the control. Note that the
+same mask bit is used to specify general modifications to the parameters used
+to configure the control (<emphasis>
+which</emphasis>
+), and to enable and disable the control (<emphasis>
+enabled_ctrls</emphasis>
+). The anomalies in the table (no "ok" in column) are for controls that have no
+configurable attributes; and for controls that are not boolean controls and
+therefore cannot be enabled or disabled.
+</para>
+
+<table frame='none'>
+<title>Controls Mask Bits</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask Bit</entry>
+ <entry>which or changed_ctrls</entry>
+ <entry>enabled_ctrls</entry>
+ <entry>Value</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbRepeatKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;0)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbSlowKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbBounceKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;2)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbStickyKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;3)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbMouseKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;4)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbMouseKeysAccelMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;5)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAccessXKeysMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;6)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAccessXTimeoutMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;7)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAccessXFeedbackMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;8)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAudibleBellMask</entry>
+ <entry></entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;9)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbOverlay1Mask</entry>
+ <entry></entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;10)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbOverlay2Mask</entry>
+ <entry></entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;11)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbIgnoreGroupLockMask</entry>
+ <entry></entry>
+ <entry>ok</entry>
+ <entry>(1L&lt;&lt;12)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbGroupsWrapMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(1L&lt;&lt;27)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbInternalModsMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(1L&lt;&lt;28)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbIgnoreLockModsMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(1L&lt;&lt;29)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbPerKeyRepeatMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(1L&lt;&lt;30)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbControlsEnabledMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(1L&lt;&lt;31)</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAccessXOptionsMask</entry>
+ <entry>ok</entry>
+ <entry>ok</entry>
+ <entry>(XkbStickyKeysMask | XkbAccessXFeedbackMask)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAllBooleanCtrlsMask</entry>
+ <entry></entry>
+ <entry>ok</entry>
+ <entry>(0x00001FFF) </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbAllControlsMask</entry>
+ <entry>ok</entry>
+ <entry></entry>
+ <entry>(0xF8001FFF)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The individual fields of the <emphasis>
+XkbControlsRec</emphasis>
+ structure are defined as follows.
+</para>
+
+<sect2>
+<title/>
+<sect3 id='mk_dflt_btn'>
+<title>mk_dflt_btn</title>
+
+<para>
+<emphasis>
+mk_dflt_btn is an attribute of the </emphasis>
+<emphasis>
+MouseKeys</emphasis>
+<emphasis>
+ control</emphasis>
+ (see section 10.5<emphasis> <!-- xref -->
+). It</emphasis>
+ specifies the mouse button number to use for keyboard simulated mouse button
+operations. Its value should be one of the core symbols <emphasis>
+Button1</emphasis>
+ - <emphasis>
+Button5</emphasis>
+.
+</para>
+
+
+</sect3>
+<sect3 id='num_groups'>
+<title>num_groups</title>
+
+<para>
+<emphasis>
+num_groups</emphasis>
+ is not a part of any control, but is reported in the <emphasis>
+XkbControlsRec</emphasis>
+ structure whenever any of its components are fetched from the server. It
+reports the number of groups the particular keyboard configuration uses and is
+computed automatically by the server whenever the keyboard mapping changes.
+</para>
+
+
+</sect3>
+<sect3 id='groups_wrap'>
+<title>groups_wrap</title>
+
+<para>
+<emphasis>
+groups_wrap</emphasis>
+ is an attribute of the <emphasis>
+GroupsWrap</emphasis>
+ control (see section 10.7.1). It specifies the handling of illegal groups on a <!-- xref -->
+global basis. Valid values for <emphasis>
+groups_wrap</emphasis>
+ are shown in Table 10.8.
+</para>
+
+<table frame='none'>
+<title>GroupsWrap options (groups_wrap field)</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>groups_wrap symbolic name</entry>
+ <entry>value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbWrapIntoRange</entry>
+ <entry>(0x00)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbClampIntoRange</entry>
+ <entry>(0x40)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbRedirectIntoRange</entry>
+ <entry>(0x80)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+When <emphasis>
+groups_wrap</emphasis>
+ is set to <emphasis>
+XkbRedirectIntoRange</emphasis>
+, its four low-order bits specify the index of the group to use.
+</para>
+
+
+</sect3>
+<sect3 id='internal'>
+<title>internal</title>
+
+<para>
+<emphasis>
+internal</emphasis>
+ is an attribute of the <emphasis>
+InternalMods</emphasis>
+ control (see section 10.7.4). It specifies modifiers to be consumed in the <!-- xref -->
+server and not passed on to clients when events are reported. Valid values
+consist of any combination of the eight core modifier bits: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+ - <emphasis>
+Mod5Mask</emphasis>
+.
+</para>
+
+
+</sect3>
+<sect3 id='ignore_lock'>
+<title>ignore_lock</title>
+
+<para>
+<emphasis>
+ignore_lock</emphasis>
+ is an attribute of the <emphasis>
+IgnoreLockMods</emphasis>
+ control (see section 10.7.2). It specifies modifiers to be ignored in grab <!-- xref -->
+calculations. Valid values consist of any combination of the eight core
+modifier bits: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+ - <emphasis>
+Mod5Mask</emphasis>
+.
+</para>
+
+
+</sect3>
+<sect3 id='enabled_ctrls'>
+<title>enabled_ctrls</title>
+
+<para>
+<emphasis>
+enabled_ctrls</emphasis>
+ is an attribute of the <emphasis>
+EnabledControls</emphasis>
+ control (see section 10.1.1). It contains one bit per boolean control. Each <!-- xref -->
+bit determines whether the corresponding control is enabled or disabled; a one
+bit means the control is enabled. The mask bits used to enable these controls
+are listed in Table 10.7, using only those masks with "ok" in the <emphasis>
+enabled_ctrls</emphasis>
+ column.
+</para>
+
+
+</sect3>
+<sect3 id='repeat_delay_and_repeat_interval'>
+<title>repeat_delay and repeat_interval</title>
+
+<para>
+<emphasis>
+repeat_delay</emphasis>
+ and <emphasis>
+repeat_interval</emphasis>
+ are attributes of the <emphasis>
+RepeatKeys</emphasis>
+ control (see section 10.3.2). <emphasis> <!-- xref -->
+repeat_delay</emphasis>
+ is the initial delay before a key begins repeating, in milliseconds; <emphasis>
+repeat_interval</emphasis>
+ is the delay between subsequent key events, in milliseconds.
+</para>
+
+
+</sect3>
+<sect3 id='slow_keys_delay'>
+<title>slow_keys_delay</title>
+
+<para>
+<emphasis>
+slow_keys_delay</emphasis>
+ is an attribute of the <emphasis>
+SlowKeys</emphasis>
+ control (see section 10.6.6). Its value specifies the <emphasis> <!-- xref -->
+SlowKeys</emphasis>
+ acceptance delay period in milliseconds before a key press is accepted by the
+server.
+</para>
+
+
+</sect3>
+<sect3 id='debounce_delay'>
+<title>debounce_delay</title>
+
+<para>
+<emphasis>
+debounce_delay</emphasis>
+ is an attribute of the <emphasis>
+BounceKeys</emphasis>
+ control (see section 10.6.7). Its value specifies the <emphasis> <!-- xref -->
+BounceKeys</emphasis>
+ delay period in milliseconds for which the key is disabled after having been
+pressed before another press of the same key is accepted by the server.
+</para>
+
+
+</sect3>
+<sect3 id='mk_delay_mk_interval_mk_time_to_max_mk_max_speed_and_mk_curve'>
+<title>mk_delay, mk_interval, mk_time_to_max, mk_max_speed, and mk_curve</title>
+
+<para>
+<emphasis>
+mk_delay</emphasis>
+, <emphasis>
+mk_interval</emphasis>
+, <emphasis>
+mk_time_to_max</emphasis>
+, <emphasis>
+mk_max_speed</emphasis>
+, and <emphasis>
+mk_curve</emphasis>
+ are attributes of the <emphasis>
+MouseKeysAccel</emphasis>
+ control. Refer to section 10.5.2 for a description of these fields and the <!-- xref -->
+units involved.
+</para>
+
+
+</sect3>
+<sect3 id='ax_options'>
+<title>ax_options</title>
+
+<para>
+The <emphasis>
+ax_options</emphasis>
+ field contains attributes used to configure two different controls, the
+<emphasis>
+StickyKeys</emphasis>
+ control (see section 10.6.8) and the <emphasis> <!-- xref -->
+AccessXFeedback</emphasis>
+ control (see section 10.6.3). The <emphasis> <!-- xref -->
+ax_options</emphasis>
+ field is a bitmask and may include any combination of the bits defined in
+Table 10.9. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>Access X Enable/Disable Bits (ax_options field)</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Access X Control</entry>
+ <entry>ax_options bit</entry>
+ <entry>value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>AccessXFeedback</entry>
+ <entry>XkbAX_SKPressFBMask</entry>
+ <entry>(1L&lt;&lt;0)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_SKAcceptFBMask</entry>
+ <entry>(1L &lt;&lt; 1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_FeatureFBMask</entry>
+ <entry>(1L &lt;&lt; 2)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_SlowWarnFBMask</entry>
+ <entry>(1L &lt;&lt; 3)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_IndicatorFBMask</entry>
+ <entry>(1L &lt;&lt; 4)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_StickyKeysFBMask</entry>
+ <entry>(1L &lt;&lt; 5)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_SKReleaseFBMask</entry>
+ <entry>(1L &lt;&lt; 8)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_SKRejectFBMask</entry>
+ <entry>(1L &lt;&lt; 9)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_BKRejectFBMask</entry>
+ <entry>(1L &lt;&lt; 10)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_DumbBellFBMask</entry>
+ <entry>(1L &lt;&lt; 11)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>StickyKeys</entry>
+ <entry>XkbAX_TwoKeysMask</entry>
+ <entry>(1L &lt;&lt; 6)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_LatchToLockMask</entry>
+ <entry>(1L &lt;&lt; 7)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry></entry>
+ <entry>XkbAX_AllOptionsMask</entry>
+ <entry>(0xFFF)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The fields pertaining to each control are relevant only when the control is
+enabled (<emphasis>
+XkbAccessXFeedbackMask</emphasis>
+ or <emphasis>
+XkbStickyKeysMask</emphasis>
+ bit is turned on in the <emphasis>
+enabled_cntrls</emphasis>
+ field).
+</para>
+
+
+<para>
+Xkb provides a set of convenience macros for working with the <emphasis>
+ax_options</emphasis>
+ field of an <emphasis>
+XkbControlsRec</emphasis>
+ structure:
+</para>
+
+<para><programlisting>
+#define <emphasis>XkbAX_NeedOption</emphasis>
+(c,w) ((c)-&gt;ax_options&amp;(w))
+</programlisting></para>
+
+<para>
+The <emphasis>
+XkbAX_NeedOption</emphasis>
+ macro is useful for determining whether a particular AccessX option is enabled
+or not. It accepts a pointer to an <emphasis>
+XkbControlsRec</emphasis>
+ structure and a valid mask bit from Table 10.9. If the specified mask bit in
+the <emphasis>
+ax_options</emphasis>
+ field of the controls structure is set, the macro returns the mask bit.
+Otherwise, it returns zero. Thus,
+</para>
+
+
+<para>
+XkbAX_NeedOption(ctlrec, XkbAX_LatchToLockMask)
+</para>
+
+
+<para>
+is nonzero if the latch to lock transition for latching keys is enabled, and
+zero if it is disabled. Note that <emphasis>
+XkbAX_NeedOption</emphasis>
+ only determines whether or not the particular capability is configured to
+operate; the <emphasis>
+XkbAccessXFeedbackMask</emphasis>
+ bit must also be turned on in <emphasis>
+enabled_ctrls</emphasis>
+ for the capability to actually be functioning.
+</para>
+
+<para><programlisting>
+#define <emphasis>XkbAX_AnyFeedback</emphasis>
+(c) ((c)-&gt;enabled_ctrls&amp;XkbAccessXFeedbackMask)
+</programlisting></para>
+
+<para>
+The <emphasis>
+XkbAX_AnyFeeback</emphasis>
+ macro accepts a pointer to an <emphasis>
+XkbControlsRec</emphasis>
+ structure and tells whether the <emphasis>
+AccessXFeedback</emphasis>
+ control is enabled or not. If the <emphasis>
+AccessXFeedback</emphasis>
+ control is enabled, the macro returns <emphasis>
+XkbAccessXFeedbackMask</emphasis>
+. Otherwise, it returns zero.
+</para>
+
+<para><programlisting>
+#define <emphasis>XkbAX_NeedFeedback</emphasis>
+(c,w) (XkbAX_AnyFeedback(c)&amp;&amp;XkbAX_NeedOption(c,w))
+</programlisting></para>
+
+<para>
+The <emphasis>
+XkbAX_NeedFeedback</emphasis>
+ macro is useful for determining if both the <emphasis>
+AccessXFeedback</emphasis>
+ control and a particular AccessX feedback option are enabled. The macro
+accepts a pointer to an <emphasis>
+XkbControlsRec</emphasis>
+ structure and a feedback option from the table above. If both the <emphasis>
+AccessXFeedback</emphasis>
+ control and the specified feedback option are enabled, the macro returns
+<emphasis>
+True</emphasis>
+. Otherwise it returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+</sect3>
+<sect3
+id='ax_timeout_axt_opts_mask_axt_opts_values_axt_ctrls_mask_and_axt_ctrls_values'>
+<title>ax_timeout, axt_opts_mask, axt_opts_values, axt_ctrls_mask, and axt_ctrls_values</title>
+
+<para>
+<emphasis>
+ax_timeout</emphasis>
+, <emphasis>
+act_opts_mask</emphasis>
+, <emphasis>
+axt_opts_values</emphasis>
+, <emphasis>
+axt_ctrls_mask</emphasis>
+, and <emphasis>
+axt_ctrls_values</emphasis>
+ are attributes of the <emphasis>
+AccessXTimeout</emphasis>
+ control. Refer to section 10.6.2 for a description of these fields and the <!-- xref -->
+units involved.
+</para>
+
+
+</sect3>
+<sect3 id='per_key_repeat'>
+<title>per_key_repeat</title>
+
+<para>
+The <emphasis>
+per_key_repeat</emphasis>
+ field mirrors the <emphasis>
+auto_repeats</emphasis>
+ field of the core protocol <emphasis>
+XKeyboardState</emphasis>
+ structure: changing the <emphasis>
+auto_repeats</emphasis>
+ field automatically changes <emphasis>
+per_key_repeat</emphasis>
+ and vice versa. It is provided for convenience and to reduce protocol traffic.
+For example, to obtain the individual repeat key behavior as well as the repeat
+delay and rate, use <emphasis>
+XkbGetControls</emphasis>
+. If the <emphasis>
+per_key_repeat</emphasis>
+ were not in this structure, you would have to call both <emphasis>
+XGetKeyboardControl</emphasis>
+ and <emphasis>
+XkbGetControls</emphasis>
+ to get this information. The bits correspond to keycodes. The first seven keys
+(keycodes 1-7) are indicated in <emphasis>
+per_key_repeat</emphasis>
+[0], with bit position 0 (low order) corresponding to the fictitious keycode 0.
+Following array elements correspond to 8 keycodes per element. A 1 bit
+indicates that the key is a repeating key.
+</para>
+
+
+</sect3>
+</sect2>
+</sect1>
+<sect1 id='querying_controls'>
+<title>Querying Controls</title>
+
+<para>
+Use <emphasis>
+XkbGetControls</emphasis>
+ to find the current state of Xkb server controls.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetControls</emphasis>
+(<emphasis>
+display, which, xkb)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long<emphasis>
+ which</emphasis>
+; /* mask of controls requested */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr<emphasis>
+ xkb</emphasis>
+; /* keyboard description for controls information*/
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetControls</emphasis>
+ queries the server for the requested control information, waits for a reply,
+and then copies the server’s values for the requested information into the
+<emphasis>
+ctrls</emphasis>
+ structure of the <emphasis>
+xkb</emphasis>
+ argument. Only those components specified by the <emphasis>
+which</emphasis>
+ parameter are copied. Valid values for <emphasis>
+which</emphasis>
+ are any combination of the masks listed in Table 10.7 that have "ok" in the
+<emphasis>
+which</emphasis>
+ column.
+</para>
+
+
+<para>
+If <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls </emphasis>
+is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetControls</emphasis>
+ allocates and initializes it before obtaining the values specified by
+<emphasis>
+which</emphasis>
+. If <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetControls</emphasis>
+ modifies only those portions of <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+ corresponding to the values specified by <emphasis>
+which</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetControls</emphasis>
+ returns <emphasis>
+Success</emphasis>
+ if successful; otherwise, it returns <emphasis>
+BadAlloc</emphasis>
+ if it cannot obtain sufficient storage, <emphasis>
+BadMatch</emphasis>
+ if <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+ or <emphasis>
+which</emphasis>
+ is empty, or <emphasis>
+BadImplementation</emphasis>
+.
+</para>
+
+
+<para>
+To free the <emphasis>
+ctrls</emphasis>
+ member of a keyboard description, use <emphasis>
+XkbFreeControls</emphasis>
+ (see section 10.12)
+</para>
+
+
+<para>
+The <emphasis>
+num_groups</emphasis>
+ field in the <emphasis>
+ctrls</emphasis>
+ structure is always filled in by <emphasis>
+XkbGetControls</emphasis>
+, regardless of which bits are selected by <emphasis>
+which</emphasis>
+.
+</para>
+
+
+</sect1>
+<sect1 id='changing_controls'>
+<title>Changing Controls</title>
+
+<para>
+There are two ways to make changes to controls: either change a local copy
+keyboard description and call <emphasis>
+XkbSetControls</emphasis>
+, or, to reduce network traffic, use an<emphasis>
+ XkbControlsChangesRec</emphasis>
+ structure and call <emphasis>
+XkbChangeControls</emphasis>
+.
+</para>
+
+
+<para>
+To change the state of one or more controls, first modify the <emphasis>
+ctrls</emphasis>
+ structure in a local copy of the keyboard description and then use <emphasis>
+XkbSetControls</emphasis>
+ to copy those changes to the X server.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetControls</emphasis>
+(<emphasis>
+display, which, xkb)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long <emphasis>
+ which </emphasis>
+; /* mask of controls to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* <emphasis>
+ctrls</emphasis>
+ field contains new values to be set */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+For each bit that is set in the <emphasis>
+which</emphasis>
+ parameter, <emphasis>
+XkbSetControls</emphasis>
+ sends the corresponding values from the <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+ field to the server. Valid values for <emphasis>
+which</emphasis>
+ are any combination of the masks listed in Table 10.7 that have "ok" in the
+<emphasis>
+which</emphasis>
+ column.
+</para>
+
+
+<para>
+If <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, the server does not support a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbSetControls</emphasis>
+ returns <emphasis>
+False</emphasis>
+. Otherwise, it sends the request to the X server and returns <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+Note that changes to attributes of controls in the <emphasis>
+XkbControlsRec</emphasis>
+ structure are apparent only when the associated control is enabled, although
+the corresponding values are still updated in the X server. For example, the
+<emphasis>
+repeat_delay</emphasis>
+ and <emphasis>
+repeat_interval</emphasis>
+ fields are ignored unless the <emphasis>
+RepeatKeys</emphasis>
+ control is enabled (that is, the X server’s equivalent of <emphasis>
+xkb-&gt;ctrls</emphasis>
+ has <emphasis>
+XkbRepeatKeyMask</emphasis>
+ set in <emphasis>
+enabled_ctrls</emphasis>
+). It is permissible to modify the attributes of a control in one call to
+XkbSetControls and enable the control in a subsequent call. See section 10.1.1 <!-- xref -->
+for more information on enabling and disabling controls.
+</para>
+
+
+<para>
+Note that the <emphasis>
+enabled_ctrls</emphasis>
+ field is itself a control — the <emphasis>
+EnabledControls</emphasis>
+ control. As such, to set a specific configuration of enabled and disabled
+boolean controls, you must set <emphasis>
+enabled_ctrls</emphasis>
+ to the appropriate bits to enable only the controls you want and disable all
+others, then specify the <emphasis>
+XkbControlsEnabledMask</emphasis>
+ in a call to <emphasis>
+XkbSetControls</emphasis>
+. Because this is somewhat awkward if all you want to do is enable and disable
+controls, and not modify any of their attributes, a convenience function is
+also provided for this purpose (<emphasis>
+XkbChangeEnabledControls</emphasis>
+, section 10.1.1). <!-- xref -->
+</para>
+
+
+<sect2 id='the_xkbcontrolschangesrec_structure'>
+<title>The XkbControlsChangesRec Structure</title>
+
+<para>
+The <emphasis>
+XkbControlsChangesRec</emphasis>
+ structure allows applications to track modifications to an <emphasis>
+XkbControlsRec</emphasis>
+ structure and thereby reduce the amount of traffic sent to the server. The
+same <emphasis>
+XkbControlsChangesRec</emphasis>
+ structure may be used in several successive modifications to the same
+<emphasis>
+XkbControlsRec</emphasis>
+ structure, then subsequently used to cause all of the changes, and only the
+changes, to be propagated to the server. The <emphasis>
+XkbControlsChangesRec</emphasis>
+ structure is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct _XkbControlsChanges {
+ unsigned int changed_ctrls; /* bits indicating changed control data */
+ unsigned int enabled_ctrls_changes; /* bits indicating enabled/disabled controls */
+ Bool num_groups_changed; /* <emphasis> True</emphasis> if
+ number of keyboard groups changed */
+} <emphasis>XkbControlsChangesRec</emphasis>,*XkbControlsChangesPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed_ctrls</emphasis>
+ field is a mask specifying which logical sets of data in the controls
+structure have been modified. In this context, modified means <emphasis>
+set</emphasis>
+, that is, if a value is set to the same value it previously contained, it has
+still been modified, and is noted as changed. Valid values for <emphasis>
+changed_ctrls</emphasis>
+ are any combination of the masks listed in Table 10.7 that have "ok" in the
+<emphasis>
+changed_ctrls</emphasis>
+ column. Setting a bit implies the corresponding data fields from the "Relevant
+XkbControlsRec Data Fields" column in Table 10.6 have been modified. The
+<emphasis>
+enabled_ctrls_changes</emphasis>
+ field specifies which bits in the <emphasis>
+enabled_ctrls</emphasis>
+ field have changed. If the number of keyboard groups has changed, the
+<emphasis>num_groups_changed</emphasis>
+ field is set to <emphasis>True</emphasis>.
+</para>
+
+
+<para>
+If you have an Xkb description with controls that have been modified and an
+<emphasis>
+XkbControlsChangesRec</emphasis>
+ that describes the changes that have been made, the <emphasis>
+XkbChangeControls</emphasis>
+ function provides a flexible method for updating the controls in a server to
+match those in the changed keyboard description.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeControls</emphasis>
+(<emphasis>
+dpy, xkb, changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description with changed <emphasis>
+xkb-&gt;ctrls</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbControlsChangesPtr <emphasis>
+changes</emphasis>
+; /* which parts of <emphasis>
+xkb-&gt;ctrls</emphasis>
+ have changed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeControls</emphasis>
+ copies any controls fields specified by <emphasis>
+changes</emphasis>
+ from the keyboard description controls structure, <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+, to the server specified by <emphasis>
+dpy</emphasis>
+.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='tracking_changes_to_keyboard_controls'>
+<title>Tracking Changes to Keyboard Controls</title>
+
+<para>
+Whenever a field in the controls structure changes in the server’s keyboard
+description, the server sends an <emphasis>
+XkbControlsNotify</emphasis>
+ event to all interested clients.To receive <emphasis>
+XkbControlsNotify</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) and pass <emphasis>
+XkbControlsNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbControlsNotify</emphasis>
+ events only under certain conditions, use <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbControlsNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying the desired state changes in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ using mask bits from Table 10.7. <!-- xref -->
+</para>
+
+
+<para>
+The structure for the <emphasis>
+XkbControlsNotify</emphasis>
+ event is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis> True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis> XkbCompatMapNotify</emphasis> */
+ int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ unsigned int changed_ctrls; /* bits indicating which controls data have changed*/
+ unsigned int enabled_ctrls; /* controls currently enabled in server */
+ unsigned int enabled_ctrl_changes; /* bits indicating enabled/disabled controls */
+ int num_groups; /* current number of keyboard groups */
+ KeyCode keycode; /* != 0 =&gt; keycode of key causing change */
+ char event_type; /* Type of event causing change */
+ char req_major; /* major event code of event causing change */
+ char req_minor; /* minor event code of event causing change */
+} <emphasis>XkbControlsNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed_ctrls</emphasis>
+ field specifies the controls components that have changed and consists of bits
+taken from the masks defined in Table 10.7 with "ok" in the <emphasis>
+changed_ctrls</emphasis>
+ column.
+</para>
+
+
+<para>
+The controls currently enabled in the server are reported in the <emphasis>
+enabled_ctrls</emphasis>
+ field. If any controls were just enabled or disabled (that is, the contents of
+the <emphasis>
+enabled_ctrls</emphasis>
+ field changed), they are flagged in the <emphasis>
+enabled_ctrl_changes</emphasis>
+ field. The valid bits for these fields are the masks listed in Table 10.7 with
+"ok" in the <emphasis>
+enabled_ctrls</emphasis>
+ column. The <emphasis>
+num_groups</emphasis>
+ field reports the number of groups bound to the key belonging to the most
+number of groups and is automatically updated when the keyboard mapping changes.
+</para>
+
+
+<para>
+If the change was caused by a request from a client, the <emphasis>
+keycode</emphasis>
+ and <emphasis>
+event_type</emphasis>
+ fields are set to <emphasis>
+zero </emphasis>
+and the <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ fields identify the request. The <emphasis>
+req_major</emphasis>
+ value is the same as the major extension opcode. Otherwise, <emphasis>
+event_type</emphasis>
+ is set to the type of event that caused the change (one of <emphasis>
+KeyPress</emphasis>
+, <emphasis>
+KeyRelease</emphasis>
+, <emphasis>
+DeviceKeyPress</emphasis>
+, <emphasis>
+DeviceKeyRelease</emphasis>
+, <emphasis>
+ButtonPress</emphasis>
+ or <emphasis>
+ButtonRelease</emphasis>
+), and <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ are undefined. If <emphasis>
+event_type</emphasis>
+ is <emphasis>
+KeyPress</emphasis>
+, <emphasis>
+KeyRelease</emphasis>
+, <emphasis>
+DeviceKeyPress</emphasis>
+, or <emphasis>
+DeviceKeyRelease</emphasis>
+, the <emphasis>
+keycode</emphasis>
+ field is set to the key that caused the change. If <emphasis>
+event_type</emphasis>
+ is <emphasis>
+ButtonPress</emphasis>
+ or <emphasis>
+ButtonRelease</emphasis>
+, <emphasis>
+keycode</emphasis>
+ contains the button number.
+</para>
+
+
+<para>
+When a client receives an <emphasis>
+XkbControlsNotify</emphasis>
+ event, it can note the changes in a changes structure using <emphasis>
+XkbNoteControlsChanges</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbNoteControlsChanges</emphasis>
+(<emphasis>
+changes</emphasis>
+,<emphasis>
+ new</emphasis>
+,<emphasis>
+ wanted</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbControlsChangesPtr <emphasis>
+ changes</emphasis>
+; /* records changes indicated by new */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbControlsNotifyEvent * <emphasis>
+ new</emphasis>
+; /* tells which things have changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ wanted</emphasis>
+; /* tells which parts of new to record in changes */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+wanted</emphasis>
+ parameter is a bitwise inclusive OR of bits taken from the set of masks
+specified in Table 10.7 with "ok" in the <emphasis>
+changed_ctrls</emphasis>
+ column. <emphasis>
+XkbNoteControlsChanges</emphasis>
+ copies any changes reported in <emphasis>
+new</emphasis>
+ and specified in <emphasis>
+wanted</emphasis>
+ into the changes record specified by <emphasis>
+old</emphasis>
+.
+</para>
+
+
+<para>
+Use <emphasis>
+XkbGetControlsChanges</emphasis>
+ to update a local copy of a keyboard description with the changes previously
+noted by one or more calls to <emphasis>
+XkbNoteControlsChanges.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetControlsChanges</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+,<emphasis>
+ changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* <emphasis>
+xkb-&gt;ctrls</emphasis>
+ will be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbNameChangesPtr <emphasis>
+changes</emphasis>
+; /* indicates which parts of <emphasis>
+xkb-&gt;ctrls</emphasis>
+ to update */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetControlsChanges</emphasis>
+ examines the <emphasis>
+changes</emphasis>
+ parameter, queries the server for the necessary information, and copies the
+results into the <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+ctrls</emphasis>
+ keyboard description. If the <emphasis>
+ctrls</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetControlsChanges</emphasis>
+ allocates and initializes it. To free the <emphasis>
+ctrls</emphasis>
+ field, use <emphasis>
+XkbFreeControls</emphasis>
+ (see section 10.12). <!-- xref -->
+</para>
+
+
+<para>
+<emphasis>
+XkbGetControlsChanges</emphasis>
+ returns <emphasis>
+Success</emphasis>
+ if successful and can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadImplementation,</emphasis>
+ and <emphasis>
+BadMatch</emphasis>
+ errors.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_an_xkbcontrolsrec'>
+<title>Allocating and Freeing an XkbControlsRec</title>
+
+<para>
+The need to allocate an <emphasis>
+XkbControlsRec</emphasis>
+ structure seldom arises; Xkb creates one when an application calls <emphasis>
+XkbGetControls</emphasis>
+ or a related function. For those situations where there is not an <emphasis>
+XkbControlsRec</emphasis>
+ structure allocated in the <emphasis>
+XkbDescRec</emphasis>
+, allocate one by calling <emphasis>
+XkbAllocControls</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocControls</emphasis>
+(<emphasis>
+xkb, which</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* Xkb description in which to allocate ctrls rec */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of components of <emphasis>
+ctrls</emphasis>
+ to allocate */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocControls</emphasis>
+ allocates the <emphasis>
+ctrls</emphasis>
+ field of the <emphasis>
+xkb</emphasis>
+ parameter, initializes all fields to zero, and returns <emphasis>
+Success</emphasis>
+. If the <emphasis>
+ctrls</emphasis>
+ field is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbAllocControls</emphasis>
+ simply returns <emphasis>
+Success</emphasis>
+. If <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbAllocControls</emphasis>
+ reports a <emphasis>
+BadMatch</emphasis>
+ error. If the <emphasis>
+ctrls</emphasis>
+ field could not be allocated, it reports a <emphasis>
+BadAlloc</emphasis>
+ error.
+</para>
+
+
+<para>
+The <emphasis>
+which</emphasis>
+ mask specifies the individual fields of the <emphasis>
+ctrls</emphasis>
+ structure to be allocated and can contain any of the valid masks defined in
+Table 10.7. Because none of the currently existing controls have any structures
+associated with them, which is currently of little practical value in this call.
+</para>
+
+
+<para>
+To free memory used by the <emphasis>
+ctrls</emphasis>
+ member of an <emphasis>
+XkbDescRec </emphasis>
+structure, use <emphasis>
+XkbFreeControls:</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeControls</emphasis>
+(<emphasis>
+xkb, which, free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr<emphasis>
+ xkb</emphasis>
+; /* Xkb description in which to free controls components */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of components of <emphasis>
+ctrls</emphasis>
+ to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+free_all</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free everything + ctrls itself */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbFreeControls</emphasis>
+ frees the specified components of the <emphasis>
+ctrls</emphasis>
+ field in the <emphasis>
+xkb</emphasis>
+ keyboard description and sets the corresponding structure component values to
+<emphasis>
+NULL</emphasis>
+ or <emphasis>
+zero</emphasis>
+. The <emphasis>
+which</emphasis>
+ mask specifies the fields of <emphasis>
+ctrls</emphasis>
+ to be freed and can contain any of the controls components specified in Table
+10.7.
+</para>
+
+
+<para>
+If <emphasis>
+free_all</emphasis>
+ is <emphasis>
+True</emphasis>
+, <emphasis>
+XkbFreeControls</emphasis>
+ frees every non-<emphasis>
+NULL</emphasis>
+ structure component in the controls, frees the <emphasis>
+XkbControlsRec</emphasis>
+ structure referenced by the <emphasis>
+ctrls</emphasis>
+ member of <emphasis>
+xkb</emphasis>
+, and sets <emphasis>
+ctrls</emphasis>
+ to <emphasis>
+NULL.</emphasis>
+</para>
+
+</sect1>
+<sect1 id='the_miscellaneous_per_client_controls'>
+<title>The Miscellaneous Per-client Controls</title>
+
+<para>
+You can configure the boolean per-client controls which affect the state
+reported in button and key events. See section 12.1.1, 12.3, 12.5, and 16.3.11 <!-- xref -->
+of the XKB Protocol specification for more details.
+</para>
+
+
+<para>
+To get the current values of the <emphasis>
+per-client</emphasis>
+ controls, use <emphasis>
+XkbGetPerClientControls</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbGetPerClientControls</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+ctrls</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+ctrls</emphasis>
+; /* 1 bit =&gt; corresponding control is on */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetPerClientControls</emphasis>
+ backfills <emphasis>
+ctrls</emphasis>
+ with the <emphasis>
+per-client </emphasis>
+control attributes for this particular client. It returns <emphasis>
+True</emphasis>
+ if successful, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+
+<para>
+To change the current values of the <emphasis>
+per-client</emphasis>
+ control attributes, use <emphasis>
+XkbSetPerClientControls.</emphasis>
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetPerClientControls</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+ctrls</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+change</emphasis>
+; /* 1 bit =&gt; change control */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+value</emphasis>
+; /* 1 bit =&gt; control on */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetPerClientControls changes the per-client values for the controls selected
+by </emphasis>
+<emphasis>
+change to the corresponding value in value. Legal values for change and value
+are: XkbPCF_GrabsUseXKBStateMask, XkbPCF_LookupStateWhenGrabbed, and
+XkbPCF_SendEventUsesXKBState. More than one control may be changed at one time
+by OR-ing the values together. XkbSetPerClientControls backfills value with the
+</emphasis>
+<emphasis>
+per-client </emphasis>
+<emphasis>
+control attributes for this particular client. </emphasis>
+It returns <emphasis>
+True</emphasis>
+ if successful, and <emphasis>
+False</emphasis>
+ otherwise.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch11.xml b/libX11/specs/XKB/ch11.xml
new file mode 100644
index 000000000..fe05e9cb2
--- /dev/null
+++ b/libX11/specs/XKB/ch11.xml
@@ -0,0 +1,572 @@
+<chapter id='x_library_controls'>
+<title>X Library Controls</title>
+
+<para>
+The Xkb extension is composed of two parts: a server extension, and a
+client-side X library extension. Chapter 10 discusses functions used to modify
+controls affecting the behavior of the server portion of the Xkb extension.
+This chapter discusses functions used to modify controls that affect only the
+behavior of the client portion of the extension; these controls are known as
+Library Controls.
+</para>
+
+
+<para>
+All of the Library Controls are boolean flags that may be enabled and disabled.
+The controls can be divided into several categories:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Controls affecting general string lookups
+ </para>
+</listitem>
+<listitem>
+ <para>
+Controls affecting compose processing
+ </para>
+</listitem>
+<listitem>
+ <para>
+Controls affecting event delivery
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+There are two types of string lookups performed by <emphasis>
+XLookupString</emphasis>
+. The first type involves translating a single keycode into a string; the
+controls in the first category affect this type of lookup. The second type
+involves translating a series of keysyms into a string; the controls in the
+second category affect this type of lookup.
+</para>
+
+
+<para>
+An Xkb implementation is required to support the programming interface for all
+of the controls. However, an implementation may choose not to support the
+semantics associated with the controls that deal with compose processing. In
+this case, a program that accesses these controls should still function
+normally; however, the feedback that would normally occur with the controls
+enabled may be missing.
+</para>
+
+<sect1 id='controls_affecting_keycode_to_string_translation'>
+<title>Controls Affecting Keycode-to-String Translation</title>
+
+<para>
+The first type of string lookups, which are here called <emphasis>
+simple string lookups</emphasis>
+, involves translating a single keycode into a string. Because these simple
+lookups involve only a single keycode, all of the information needed to do the
+translation is contained in the keyboard state in a single event. The controls
+affecting simple string lookups are:
+</para>
+
+<para><programlisting>
+ <emphasis>ForceLatin1Lookup</emphasis>
+ <emphasis>ConsumeLookupMods</emphasis>
+ <emphasis>LevelOneUsesShiftAndLock</emphasis>
+</programlisting></para>
+
+<sect2 id='forcelatin1lookup'>
+<title>ForceLatin1Lookup</title>
+
+<para>
+If the <emphasis>
+ForceLatin1Lookup</emphasis>
+ control is enabled, <emphasis>
+XLookupString</emphasis>
+ only returns strings using the Latin1 character set. If <emphasis>
+ForceLatin1Lookup</emphasis>
+ is not enabled, <emphasis>
+XLookupString</emphasis>
+ can return characters that are not in the Latin1 set. By default, this control
+is disabled, allowing characters outside of the Latin1 set to be returned.
+</para>
+
+
+</sect2>
+<sect2 id='consumelookupmods'>
+<title>ConsumeLookupMods</title>
+
+<para>
+Simple string lookups in <emphasis>
+XLookupString</emphasis>
+ involve two different translation phases. The first phase translates raw
+device keycodes to individual keysyms. The second phase attempts to map the
+resulting keysym into a string of one or more characters. In the first phase,
+some of the modifiers are normally used to determine the appropriate shift
+level for a key.
+</para>
+
+
+<para>
+The <emphasis>
+ConsumeLookupMods</emphasis>
+ control determines whether or not <emphasis>
+XLookupString</emphasis>
+ <emphasis>
+consumes</emphasis>
+ the modifiers it uses during the first phase of processing (mapping a keycode
+to a keysym). When a modifier is consumed, it is effectively removed from the
+working copy of the keyboard state information <emphasis>
+XLookupString</emphasis>
+ is using and appears to be unset for the remainder of the processing.
+</para>
+
+
+<para>
+If the <emphasis>
+ConsumeLookupMods</emphasis>
+ control is enabled, <emphasis>
+XLookupString</emphasis>
+ does not use the modifiers used to translate the keycode of the event to a
+keysym when it is determining the string associated with a keysym. For example,
+assume the keymap for the ‘A’ key only contains the shift modifier and the
+<emphasis>
+ConsumeLookupMods</emphasis>
+ control is enabled. If a user presses the <emphasis>
+Shift</emphasis>
+ key and the <emphasis>
+A</emphasis>
+ key while the <emphasis>
+Num_Lock</emphasis>
+ key is locked, <emphasis>
+XLookupString</emphasis>
+ uses the <emphasis>
+Shift</emphasis>
+ modifier when mapping the keycode for the ‘a’ key to the keysym for
+‘A’; subsequently, it only uses the <emphasis>
+NumLock</emphasis>
+ modifier when determining the string associated with the keysym ‘A’.
+</para>
+
+
+<para>
+If the <emphasis>
+ConsumeLookupMods</emphasis>
+ control is not enabled, <emphasis>
+XLookupString</emphasis>
+ uses all of the event modifiers to determine the string associated with a
+keysym. This behavior mirrors the behavior of <emphasis>
+XLookupString</emphasis>
+ in the core implementation.
+</para>
+
+
+<para>
+The <emphasis>
+ConsumeLookupMods</emphasis>
+ control is unset by default. For more information on modifier consumption,
+refer to Chapter 12.
+</para>
+
+
+</sect2>
+<sect2 id='alwaysconsumeshiftandlock'>
+<title>AlwaysConsumeShiftAndLock</title>
+
+<para>
+The <emphasis>
+AlwaysConsumeShiftAndLock</emphasis>
+ control, if enabled, forces <emphasis>
+XLookupString</emphasis>
+ to consume the <emphasis>
+Shift</emphasis>
+ and <emphasis>
+Lock</emphasis>
+ modifiers when processing all keys, even if the definition for the key type
+does not specify these modifiers. The <emphasis>
+AlwaysConsumeShiftAndLock</emphasis>
+ control is unset by default. See section 15.2 for a discussion of key types.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='controls_affecting_compose_processing'>
+<title>Controls Affecting Compose Processing</title>
+
+<para>
+The second type of string lookup performed by <emphasis>
+XLookupString</emphasis>
+ involves translating a series of keysyms into a string. Because these lookups
+can involve more than one key event, they require <emphasis>
+XLookupString</emphasis>
+ to retain some state information between successive calls. The process of
+mapping a series of keysyms to a string is known as <emphasis>
+compose processing</emphasis>
+. The controls affecting compose processing are:
+</para>
+
+<para><programlisting>
+<emphasis>ConsumeKeysOnComposeFail</emphasis>
+<emphasis>ComposeLED</emphasis>
+<emphasis>BeepOnComposeFail</emphasis>
+</programlisting></para>
+
+<para>
+Because different vendors have historically used different algorithms to
+implement compose processing, and these algorithms may be incompatible with the
+semantics required by the Xkb compose processing controls, implementation of
+the compose processing controls is optional in an Xkb implementation.
+</para>
+
+
+<sect2 id='consumekeysoncomposefail'>
+<title>ConsumeKeysOnComposeFail</title>
+
+<para>
+Some compose processing algorithms signal the start of a compose sequence by a
+key event meaning "start compose".
+<footnote><para>
+Another possibility is to have the compose processing simply be the result of a finite state acceptor; a compose sequence would never fail for a properly written finite state acceptor.
+</para></footnote>
+The subsequent key events should normally result in a valid composition yielding a
+valid translation to a string. If the subsequent key events do not have a valid
+translation, some decision must be made about what to do with the key events
+that were processed while attempting the compose. The <emphasis>
+ConsumeKeysOnComposeFail</emphasis>
+ control allows a client to specify what happens with the key events <emphasis>
+XLookupString</emphasis>
+ has been considering when it reaches a dead end in a compose sequence.
+</para>
+
+
+<para>
+If the <emphasis>
+ConsumeKeysOnComposeFail</emphasis>
+ control is set, all keys associated with a failed compose sequence should be
+consumed (discarded). If the <emphasis>
+ConsumeKeysOnComposeFail</emphasis>
+ control is not set, the key events associated with a failed compose sequence
+should be processed as a normal sequence of key events.
+</para>
+
+
+<para>
+The <emphasis>
+ConsumeKeysOnComposeFail</emphasis>
+ control is disabled by default.
+</para>
+
+
+</sect2>
+<sect2 id='composeled'>
+<title>ComposeLED</title>
+
+<para>
+The <emphasis>
+ComposeLED</emphasis>
+ control allows a client to specify whether or not an indicator should be set
+and cleared to provide feedback when compose processing is in progress. The
+control does not specify which indicator should be used; the mapping for this
+is up to the individual implementation. If the <emphasis>
+ComposeLED</emphasis>
+ control is enabled, it specifies that an indicator should be set when a
+compose sequence is in progress and cleared when one is not in progress. The
+<emphasis>
+ComposeLED</emphasis>
+ control is disabled by default.
+</para>
+
+
+<para>
+While the Xkb extension does not specify the type of type of indicator to be
+used when the <emphasis>
+ComposeLED</emphasis>
+ control is implemented, a consistent convention between implementations is to
+everyone’s benefit. If a named indicator is used for this purpose, the
+recommended name is "<emphasis>
+Compose</emphasis>
+". Note that some implementations may use an unnamed, custom hardware LED for
+this purpose.
+</para>
+
+
+</sect2>
+<sect2 id='beeponcomposefail'>
+<title>BeepOnComposeFail</title>
+
+<para>
+The <emphasis>
+BeepOnComposeFail</emphasis>
+ control allows a client to specify whether or not a bell should be activated
+to provide feedback when a compose sequence fails. The control does not specify
+the type of bell that should be used; the mapping for this is up to the
+individual implementation. If the <emphasis>
+BeepOnComposeFail</emphasis>
+ control is enabled, it specifies that a bell should be activated when a
+compose sequence fails. The <emphasis>
+BeepOnComposeFail</emphasis>
+ control is disabled by default. If implemented, the bell should be activated
+using <emphasis>
+XkbBell</emphasis>
+ or <emphasis>
+XkbDeviceBell</emphasis>
+.
+</para>
+
+
+<para>
+While the Xkb extension does not specify the type of bell to be used when the
+<emphasis>
+BeepOnComposeFail</emphasis>
+ control is implemented, a consistent convention between implementations is to
+everyone’s benefit. If a named bell is used for this purpose, the recommended
+name is "<emphasis>
+ComposeFail</emphasis>
+".
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='controls_effecting_event_delivery'>
+<title>Controls Effecting Event Delivery</title>
+
+<sect2 id='ignorenewkeyboards'>
+<title>IgnoreNewKeyboards</title>
+
+<para>
+When Xkb is initialized, it implicitly forces requests for <emphasis>
+NewKeyboardNotify</emphasis>
+ events. These events may be used by the Xkb library extension internally; they
+are normally translated into core protocol <emphasis>
+MappingNotify</emphasis>
+ events before being passed to the client. While delivering the event to the
+client is appropriate in most cases, it is not appropriate for some clients
+that maintain per-key data structures. This is because once the server has sent
+a <emphasis>
+NewKeyboardNotify</emphasis>
+ event, it is free to send the client events for all keys in the new range and
+that range may be outside of the per-key data structures the client is
+maintaining.
+</para>
+
+
+<para>
+The <emphasis>
+IgnoreNewKeyboards</emphasis>
+ control, if enabled, prevents Xkb from mapping <emphasis>
+NewKeyboardNotify</emphasis>
+ events to core <emphasis>
+MappingNotify</emphasis>
+ events and passing them to the client. The control is initially disabled.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='manipulating_the_library_controls'>
+<title>Manipulating the Library Controls</title>
+
+<para>
+The Library Controls are manipulated using functions that deal with bitmasks to
+indicate which controls to manipulate. The controls are identified by the masks
+defined in Table 11.1. <!-- xref -->
+</para>
+
+<table frame='none'>
+<title>Library Control Masks</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Library Control Mask</entry>
+ <entry>Value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbLC_ForceLatin1Lookup</entry>
+ <entry>(1 &lt;&lt; 0)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_ConsumeLookupMods</entry>
+ <entry>(1 &lt;&lt; 1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_AlwaysConsumeShiftAndLock</entry>
+ <entry>(1 &lt;&lt; 2)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_IgnoreNewKeyboards</entry>
+ <entry>(1 &lt;&lt; 3)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_ConsumeKeysOnComposeFail</entry>
+ <entry>(1 &lt;&lt; 29)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_ComposeLED</entry>
+ <entry>(1 &lt;&lt; 30)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_BeepOnComposeFail</entry>
+ <entry>(1 &lt;&lt; 31)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbLC_AllControls</entry>
+ <entry>(0xc0000007)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<sect2 id='determining_which_library_controls_are_implemented'>
+<title>Determining Which Library Controls are Implemented</title>
+
+<para>
+To determine which Library Controls are actually
+implemented, use <emphasis>XkbXlibControlsImplemented</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned int <emphasis>
+XkbXlibControlsImplemented</emphasis>
+(<emphasis>
+display</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbXlibControlsImplemented</emphasis>
+ returns a bitmask indicating the controls actually implemented in the Xkb
+library and is composed of an inclusive OR of bits from Table 11.1.
+</para>
+
+
+</sect2>
+<sect2 id='determining_the_state_of_the_library_controls'>
+<title>Determining the State of the Library Controls</title>
+
+<para>
+To determine the current state of the Library Controls, use <emphasis>
+XkbGetXlibControls</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned int <emphasis>
+XkbGetXlibControls</emphasis>
+(<emphasis>
+display</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetXlibControls</emphasis>
+ returns the current state of the Library Controls as a bit mask that is an
+inclusive OR of the control masks from Table 11.1 for the controls that are
+enabled. For the optional compose processing controls, the fact that a control
+is enabled does not imply that it is actually implemented.
+</para>
+
+</sect2>
+<sect2 id='changing_the_state_of_the_library_controls'>
+<title>Changing the State of the Library Controls</title>
+
+<para>
+To change the state of the Library Controls, use
+<emphasis>XkbSetXlibControls</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetXlibControls</emphasis>
+(<emphasis>
+display, bits_to_change, values_for_bits</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long <emphasis>
+bits_to_change</emphasis>
+; /* selects controls to be modified */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned long <emphasis>
+values_for_bits</emphasis>
+; /* turns selected controls on (1) or off (0) */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetXlibControls</emphasis>
+ modifies the state of the controls selected by <emphasis>
+bits_to_change</emphasis>
+; only the controls selected by <emphasis>
+bits_to_change</emphasis>
+ are modified. If the bit corresponding to a control is on in <emphasis>
+bits_to_change</emphasis>
+ and also on in values_for_bits, the control is enabled. If the bit
+corresponding to a control is on in <emphasis>
+bits_to_change</emphasis>
+ but off in <emphasis>
+values_for_bits</emphasis>
+, the control is disabled. <emphasis>
+bits_to_change</emphasis>
+ should be an inclusive OR of bits from Table 11.1.
+</para>
+
+</sect2>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch12.xml b/libX11/specs/XKB/ch12.xml
new file mode 100644
index 000000000..1f10261c7
--- /dev/null
+++ b/libX11/specs/XKB/ch12.xml
@@ -0,0 +1,841 @@
+<chapter id='interpreting_key_events'>
+<title>Interpreting Key Events</title>
+
+<para>
+Xkb provides functions to help developers interpret key events without having
+to directly interpret Xkb data structures. Xkb also modifies the behavior of
+several core X library functions.
+</para>
+
+<sect1 id='effects_of_xkb_on_the_core_x_library'>
+<title>Effects of Xkb on the Core X Library</title>
+
+<para>
+When support for Xkb is built into the X library, the <emphasis>
+XOpenDisplay</emphasis>
+ function looks for a compatible version of Xkb on the server. If it finds a
+compatible version, it initializes the extension and enables <emphasis>
+implicit support</emphasis>
+ for Xkb in a number of X library functions. This makes it possible for clients
+to take advantage of nearly all Xkb features without having to be rewritten or
+even recompiled, if they are built with shared libraries. This implicit support
+is invisible to most clients, but it can have side effects, so the extension
+includes ways to control or disable it.
+</para>
+
+
+<sect2 id='effects_of_xkb_on_event_state'>
+<title>Effects of Xkb on Event State</title>
+
+<para>
+Because <emphasis>
+XOpenDisplay</emphasis>
+ initializes Xkb, some events contain an Xkb description of the keyboard state
+instead of that normally used by the core protocol. See section 17.1.1 for more
+information about the differences between Xkb keyboard state and that reported
+by the core protocol.
+</para>
+
+
+</sect2>
+<sect2 id='effects_of_xkb_on_mappingnotify_events'>
+<title>Effects of Xkb on MappingNotify Events</title>
+
+<para>
+When Xkb is missing or disabled, the X library tracks changes to the keyboard
+mapping using <emphasis>
+MappingNotify</emphasis>
+ events. Whenever the keyboard mapping is changed, the server sends all clients
+a <emphasis>
+MappingNotify</emphasis>
+ event to report the change. When a client receives a <emphasis>
+MappingNotify</emphasis>
+ event, it is supposed to call <emphasis>
+XRefreshKeyboardMapping</emphasis>
+ to update the keyboard description used internally by the X library.
+</para>
+
+
+<para>
+The X Keyboard Extension uses <emphasis>
+XkbMapNotify</emphasis>
+ and <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events to track changes to the keyboard mapping. When an Xkb-aware client
+receives either event, it should call <emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+ to update the keyboard description used internally by the X library. To avoid
+duplicate events, the X server does not send core protocol <emphasis>
+MappingNotify</emphasis>
+ events to a client that has selected for <emphasis>
+XkbMapNotify</emphasis>
+ events.
+</para>
+
+
+<para>
+The implicit support for Xkb selects for <emphasis>
+XkbMapNotify</emphasis>
+ events. This means that clients that do not explicitly use Xkb but that are
+using a version of the X library that has implicit support for Xkb do not
+receive <emphasis>
+MappingNotify</emphasis>
+ events over the wire. Clients that were not written with Xkb in mind do not
+recognize or properly handle the new Xkb events, so the implicit support
+converts them to <emphasis>
+MappingNotify</emphasis>
+ events that report approximately the same information, unless the client has
+explicitly selected for the Xkb version of the event.
+</para>
+
+
+<para>
+An Xkb-capable X server does not send events from keys that fall outside the
+legal range of keycodes expected by that client. Once the server sends a client
+an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event, it reports events from all keys because it assumes that any client that
+has receieved an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event expects key events from the new range of keycodes. The implicit support
+for Xkb asks for <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events, so the range of keycodes reported to the client might vary without the
+client’s knowledge. Most clients don’t really care about the range of legal
+keycodes, but some clients maintain information about each key and might have
+problems with events that come from unexpected keys. Such clients can set the
+<emphasis>
+XkbLC_IgnoreNewKeyboards</emphasis>
+ library control (see section 11.3.1) to prevent the implicit support from
+requesting notification of changes to the legal range of keycodes.
+</para>
+
+
+</sect2>
+<sect2 id='x_library_functions_affected_by_xkb'>
+<title>X Library Functions Affected by Xkb</title>
+
+<para>
+The following X library functions are modified by Xkb:
+</para>
+
+<para><programlisting>
+ <emphasis>XKeycodeToKeysym</emphasis>
+ <emphasis>XKeysymToKeycode</emphasis>
+ <emphasis>XLookupKeysym</emphasis>
+ <emphasis>XLookupString</emphasis>
+ <emphasis>XRefreshKeyboardMapping</emphasis>
+ <emphasis>XRebindKeysym</emphasis>
+</programlisting></para>
+
+<para>
+The implicit support for Xkb replaces a number of X library functions with
+versions that understand and use the X Keyboard Extension. In most cases, the
+semantics of the new versions are identical to those of the old, but there are
+occasional visible differences. This section lists all of the functions that
+are affected and the differences in behavior, if any, that are visible to
+clients.
+</para>
+
+
+<para>
+The <emphasis>
+XKeycodeToKeysym</emphasis>
+ function reports the keysym associated with a particular index for a single
+key. The index specifies a column of symbols in the core keyboard mapping (that
+is, as reported by the core protocol <emphasis>
+GetKeyboardMapping</emphasis>
+ request). The order of the symbols in the core mapping does not necessarily
+correspond to the order of the symbols used by Xkb; section 17.1.3 describes
+the differences.
+</para>
+
+
+<para>
+The <emphasis>
+XKeysymToKeycode</emphasis>
+ function reports a keycode to which a particular keysym is bound. When Xkb is
+missing or disabled, this function looks in each column of the core keyboard
+mapping in turn and returns the lowest numbered key that matches in the lowest
+numbered group. When Xkb is present, this function uses the Xkb ordering for
+symbols instead.
+</para>
+
+
+<para>
+The <emphasis>
+XLookupKeysym</emphasis>
+ function reports the symbol in a specific column of the key associated with an
+event. Whether or not Xkb is present, the column specifies an index into the
+core symbol mapping.
+</para>
+
+
+<para>
+The <emphasis>
+XLookupString</emphasis>
+ function reports the symbol and string associated with a key event, taking
+into account the keycode and keyboard state as reported in the event. When Xkb
+is disabled or missing, <emphasis>
+XLookupString</emphasis>
+ uses the rules specified by the core protocol and reports only ISO Latin-1
+characters. When Xkb is present, <emphasis>
+XLookupString</emphasis>
+ uses the explicit keyboard group, key types, and rules specified by Xkb. When
+Xkb is present, <emphasis>
+XLookupString</emphasis>
+ is allowed, but not required, to return strings in character sets other than
+ISO Latin-1, depending on the current locale. If any key bindings are defined,
+<emphasis>
+XLookupString</emphasis>
+ does not use any consumed modifiers (see sections 11.1.2 and 15.2) to
+determine matching bindings.
+</para>
+
+
+<para>
+The <emphasis>
+XRefreshKeyboardMapping</emphasis>
+ function updates the X library’s internal representation of the keyboard to
+reflect changes reported via <emphasis>
+MappingNotify</emphasis>
+ events. When Xkb is missing or disabled, this function reloads the entire
+modifier map or keyboard mapping. When Xkb is present, the implicit Xkb support
+keeps track of the changed components reported by each <emphasis>
+XkbMapNotify</emphasis>
+ event and updates only those pieces of the keyboard description that have
+changed. If the implicit support has not noted any keyboard mapping changes,
+<emphasis>
+XRefreshKeyboardMapping</emphasis>
+ updates the entire keyboard description.
+</para>
+
+
+<para>
+The <emphasis>
+XRebindKeysym</emphasis>
+ function associates a string with a keysym and a set of modifiers. Xkb does
+not directly change this function, but it does affect the way that the state
+reported in the event is compared to the state specified to <emphasis>
+XRebindKeysym</emphasis>
+. When Xkb is missing or disabled, <emphasis>
+XLookupString</emphasis>
+ returns the specified string if the modifiers in the event exactly match the
+modifiers from this call. When Xkb is present, any modifiers used to determine
+the keysym are consumed and are not used to look up the string.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='xkb_event_and_keymap_functions'>
+<title>Xkb Event and Keymap Functions</title>
+
+<para>
+To find the keysym bound to a particular key at a specified group and shift
+level, use <emphasis>XkbKeycodeToKeysym</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+KeySym <emphasis>
+XkbKeycodeToKeysym</emphasis>
+(<emphasis>
+dpy, kc, group, level</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * dpy; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode kc; /* key of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int group; /* group of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int level; /* shift level of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeycodeToKeysym</emphasis>
+ returns the keysym bound to a particular group and shift level for a
+particular key on the core keyboard. If <emphasis>
+kc</emphasis>
+ is not a legal keycode for the core keyboard, or if <emphasis>
+group</emphasis>
+ or <emphasis>
+level</emphasis>
+ are out of range for the specified key, <emphasis>
+XkbKeycodeToKeysym</emphasis>
+ returns <emphasis>
+NoSymbol</emphasis>
+.
+</para>
+
+
+<para>
+To find the set of modifiers bound to a particular keysym on the core keyboard,
+use <emphasis>
+XkbKeysymToModifiers</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned<emphasis>
+ </emphasis>
+int <emphasis>
+XkbKeysymToModifiers</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ ks</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym <emphasis>
+ ks</emphasis>
+; /* keysym of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeysymToModifiers</emphasis>
+ finds the set of modifiers currently bound to the keysym <emphasis>
+ks</emphasis>
+ on the core keyboard. The value returned is the mask of modifiers bound to the
+keysym <emphasis>
+ks</emphasis>
+. If no modifiers are bound to the keysym, <emphasis>
+XkbKeysymToModifiers</emphasis>
+ returns zero; otherwise, it returns the inclusive OR of zero or more of the
+following: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+, <emphasis>
+Mod2Mask</emphasis>
+, <emphasis>
+Mod3Mask</emphasis>
+, <emphasis>
+Mod4Mask,</emphasis>
+ and <emphasis>
+Mod5Mask</emphasis>
+.
+</para>
+
+
+<para>
+Use <emphasis>
+XkbLookupKeySym</emphasis>
+ to find the symbol associated with a key for a particular state.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbLookupKeySym</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ key</emphasis>
+,<emphasis>
+ state</emphasis>
+,<emphasis>
+ mods_rtrn</emphasis>
+,<emphasis>
+ sym_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+ key</emphasis>
+; /* key for which symbols are to be found */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ state</emphasis>
+; /* state for which symbol should be found */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+ mods_rtrn</emphasis>
+; /* backfilled with unconsumed modifiers */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym *<emphasis>
+ sym_rtrn</emphasis>
+; /* backfilled with symbol associated with key + state */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbLookupKeySym</emphasis>
+ is the equivalent of the core <emphasis>
+XLookupKeySym</emphasis>
+ function. For the core keyboard, given a keycode <emphasis>
+key</emphasis>
+ and an Xkb state <emphasis>
+state</emphasis>
+, <emphasis>
+XkbLookupKeySym</emphasis>
+ returns the symbol associated with the key in <emphasis>
+sym_rtrn</emphasis>
+ and the list of modifiers that should still be applied in <emphasis>
+mods_rtrn</emphasis>
+. The <emphasis>
+state</emphasis>
+ parameter is the state from a <emphasis>
+KeyPress</emphasis>
+ or <emphasis>
+KeyRelease</emphasis>
+ event. <emphasis>
+XkbLookupKeySym</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if it succeeds.
+</para>
+
+
+<para>
+Use <emphasis>
+XkbLookupKeyBinding</emphasis>
+ to find the string bound to a key by <emphasis>
+XRebindKeySym</emphasis>
+. <emphasis>
+XkbLookupKeyBinding</emphasis>
+ is the equivalent of the core <emphasis>
+XLookupString</emphasis>
+ function.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbLookupKeyBinding</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ sym</emphasis>
+,<emphasis>
+ state</emphasis>
+,<emphasis>
+ buf</emphasis>
+,<emphasis>
+ nbytes</emphasis>
+,<emphasis>
+ extra_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym<emphasis>
+ sym</emphasis>
+; /* symbol to be looked up */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+state</emphasis>
+; /* state for which string is to be looked up */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ buf</emphasis>
+; /* buffer into which returned string is written */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ nbytes</emphasis>
+; /* size of buffer in bytes */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+ extra_rtrn</emphasis>
+; /* backfilled with number bytes overflow */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XRebindKeysym</emphasis>
+ binds an ASCII string to a specified keysym, so that the string and keysym are
+returned when the key is pressed and a specified list of modifiers are also
+being held down. <emphasis>
+XkbLookupKeyBinding</emphasis>
+ returns in <emphasis>
+buf</emphasis>
+ the string associated with the keysym <emphasis>
+sym</emphasis>
+ and modifier state <emphasis>
+state</emphasis>
+. <emphasis>
+buf</emphasis>
+ is <emphasis>
+NULL</emphasis>
+ terminated unless there’s an overflow. If the string returned is larger than
+<emphasis>
+nbytes</emphasis>
+, a count of bytes that does not fit into the buffer is returned in extra_rtrn.
+<emphasis>
+XkbTranslateKeySym</emphasis>
+ returns the number of bytes that it placed into <emphasis>
+buf</emphasis>
+.
+</para>
+
+
+<para>
+To find the string and symbol associated with a keysym for a given keyboard
+state, use <emphasis>
+XkbTranslateKeySym</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbTranslateKeySym</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ sym_inout</emphasis>
+,<emphasis>
+ mods</emphasis>
+,<emphasis>
+ buf</emphasis>
+,<emphasis>
+ nbytes</emphasis>
+, <emphasis>
+extra_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym * <emphasis>
+ sym_inout</emphasis>
+; /* symbol to be translated; result of translation */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ mods</emphasis>
+; /* modifiers to apply to <emphasis>
+sym_inout</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ buf</emphasis>
+; /* buffer into which returned string is written */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ nbytes</emphasis>
+; /* size of buffer in bytes */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int *<emphasis>
+ extra_rtrn</emphasis>
+; /* number of bytes overflow*/
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbTranslateKeySym</emphasis>
+ applies the transformations specified in <emphasis>
+mods</emphasis>
+ to the symbol specified by <emphasis>
+sym_inout</emphasis>
+. It returns in <emphasis>
+buf</emphasis>
+ the string, if any, associated with the keysym for the current locale. If the
+transformations in <emphasis>
+mods</emphasis>
+ changes the keysym, <emphasis>
+sym_inout</emphasis>
+ is updated accordingly. If the string returned is larger than <emphasis>
+nbytes</emphasis>
+, a count of bytes that does not fit into the buffer is returned in extra_rtrn.
+<emphasis>
+XkbTranslateKeySym</emphasis>
+ returns the number of bytes it placed into <emphasis>
+buf</emphasis>
+.
+</para>
+
+
+<para>
+To update the keyboard description that is internal to the X library, use
+<emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+(<emphasis>
+event)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbMapNotifyEvent * <emphasis>
+ event</emphasis>
+; /* event initiating remapping */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+ is the Xkb equivalent of the core <emphasis>
+XRefreshKeyboardMapping</emphasis>
+ function. It requests that the X server send the current key mapping
+information to this client. A client usually invokes <emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+ after receiving an <emphasis>
+XkbMapNotify</emphasis>
+ event. <emphasis>
+XkbRefreshKeyboardMapping</emphasis>
+ returns <emphasis>
+Success</emphasis>
+ if it succeeds and <emphasis>
+BadMatch</emphasis>
+ if the event is not an Xkb event.
+</para>
+
+
+<para>
+The <emphasis>
+XkbMapNotify</emphasis>
+ event can be generated when some client calls <emphasis>
+XkbSetMap</emphasis>
+, <emphasis>
+XkbChangeMap</emphasis>
+, <emphasis>
+XkbGetKeyboardByName</emphasis>
+, or any of the standard X library functions that change the keyboard mapping
+or modifier mapping.
+</para>
+
+
+<para>
+To translate a keycode to a key symbol and modifiers, use <emphasis>
+XkbTranslateKeyCode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Booll <emphasis>
+XkbTranslateKeyCode</emphasis>
+(<emphasis>
+xkb, key, mods, mods_rtrn, keysym_rtrn)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description to use for translation */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+key</emphasis>
+; /* keycode to translate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+mods</emphasis>
+; /* modifiers to apply when translating <emphasis>
+key</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+mods_rtrn</emphasis>
+; /* backfilled with unconsumed modifiers */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym * <emphasis>
+keysym_rtrn</emphasis>
+; /* keysym resulting from translation */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+mods_rtrn</emphasis>
+ is backfilled with the modifiers consumed by the translation process.
+<emphasis>
+mods</emphasis>
+ is a bitwise inclusive OR of the legal modifier masks: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+, <emphasis>
+Mod2Mask</emphasis>
+, <emphasis>
+Mod3Mask</emphasis>
+, <emphasis>
+Mod4Mask</emphasis>
+, <emphasis>
+Mod5Mask</emphasis>
+.The <emphasis>
+AlwaysConsumeShiftAndLock</emphasis>
+ library control (see section 11.1.3), if enabled, causes <emphasis>
+XkbTranslateKeyCode</emphasis>
+ to consume shift and lock.<emphasis>
+ XkbTranslateKeyCode</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if the translation resulted in a keysym, and <emphasis>
+False</emphasis>
+ if it resulted in <emphasis>
+NoSymbol</emphasis>
+.
+</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch13.xml b/libX11/specs/XKB/ch13.xml
new file mode 100644
index 000000000..6f8fce033
--- /dev/null
+++ b/libX11/specs/XKB/ch13.xml
@@ -0,0 +1,4146 @@
+<chapter id='keyboard_geometry'>
+<title>Keyboard Geometry</title>
+
+<para>
+The Xkb description of a keyboard includes an optional keyboard geometry that
+describes the physical appearance of the keyboard. Keyboard geometry describes
+the shape, location, and color of all keyboard keys or other visible keyboard
+components such as indicators. The information contained in a keyboard geometry
+is sufficient to allow a client program to draw an accurate two-dimensional
+image of the keyboard.
+</para>
+
+
+<para>
+You can retrieve a keyboard geometry from an X server that supports Xkb, or you
+can allocate it from scratch and initialize it in a client program. The
+keyboard geometry need not have any correspondence with the physical keyboard
+that is connected to the X server.
+</para>
+
+
+<para>
+Geometry measurements are specified in mm/10 units. The origin (0,0) is in the
+top left corner of the keyboard image. A component’s own origin is also its
+upper left corner. In some cases a component needs to be drawn rotated. For
+example, a special keyboard may have a section of keys arranged in rows in a
+rectangular area, but the entire rectangle may not be in alignment with the
+rest of the keyboard, and instead, it is rotated from horizontal by 30<emphasis>
+o</emphasis>
+. Rotation for a geometry object is specified in 1/10 o increments about its
+origin. An example of a keyboard with rotated sections is shown in Figure 13.1.
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-7.svg"/>
+ </imageobject>
+<caption>Rotated Keyboard Sections</caption>
+</mediaobject>
+
+
+<!-- <H5 CLASS="Figure">
+Rotated Keyboard Sections</H5>
+-->
+
+<para>
+Some geometry components include a <emphasis>
+priority</emphasis>
+, which indicates the order in which overlapping objects should be drawn.
+Objects should be drawn in order from highest priority (0) to lowest (255).
+</para>
+
+
+<para>
+The keyboard geometry’s top-level description is stored in a <emphasis>
+XkbGeometryRec</emphasis>
+ structure. This structure contains three types of information:
+</para>
+
+<orderedlist>
+ <listitem>
+ <para>
+Lists of items, not used to draw the basic keyboard, but indexed by the
+geometry descriptions that comprise the entire keyboard geometry (colors,
+geometry properties, key aliases, shapes)
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A number of singleton items that describe the keyboard as a whole (keyboard
+name, width and height, a color for the keyboard as a whole, and a color for
+keyboard key labels)
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A list of the keyboard’s sections and nonkey doodads
+ </para>
+ </listitem>
+</orderedlist>
+
+<para>
+The top-level geometry is described in more detail in the following.
+</para>
+
+
+<para>
+The lists of items used by components of the keyboard geometry description is
+as follows:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The top-level keyboard geometry description includes a list of up to <emphasis>
+MaxColors</emphasis>
+ (32) <emphasis>
+color names</emphasis>
+. A color name is a string whose interpretation is not specified by Xkb. The
+<emphasis>
+XkbColorRec</emphasis>
+ structure provides a field for this name as well as a pixel field. The pixel
+field is a convenient place for an application to store a pixel value or color
+definition, if it needs to. All other geometry data structures refer to colors
+using their indices in this global list.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The top-level keyboard geometry description includes a list of <emphasis>
+geometry properties</emphasis>
+. A geometry property associates an arbitrary string with an equally arbitrary
+name. Geometry properties can be used to provide hints to programs that display
+images of keyboards, but they are not interpreted by Xkb. No other geometry
+structures refer to geometry properties. As an example of a possible use of
+<emphasis>
+properties</emphasis>
+, consider the pause/break key on most PC keyboards: the "break" symbol is
+usually on the front of the key and is often a different color. A program might
+set a property to:
+ </para>
+ <para>
+LBL_PAUS = "{Pause/top/black,Break/front/red}"
+ </para>
+ <para>
+and use the property information to draw the key with a front label as well as
+a top label.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The top-level keyboard geometry description includes a list of <emphasis>
+key aliases</emphasis>
+ (see Chapter 18). Key aliases allow the keyboard layout designer to assign
+multiple key names to a single key.
+ </para>
+<note><para>Key aliases defined in the geometry component of a keyboard mapping
+override those defined in the keycodes component of the server database, which
+are stored in the <emphasis>
+XkbNamesRec</emphasis>
+ (<emphasis>
+xkb-&gt;names</emphasis>
+). Therefore, consider the key aliases defined by the geometry before
+considering key aliases supplied by the keycodes.</para></note>
+</listitem>
+<listitem>
+ <para>
+The top-level keyboard geometry description includes a list of <emphasis>
+shapes</emphasis>
+; other keyboard components refer to shapes by their index in this list. A
+shape consists of an arbitrary name of type Atom and one or more closed-polygon
+<emphasis>
+outlines</emphasis>
+. All points in an outline are specified relative to the origin of its
+enclosing shape, that is, whichever shape that contains this outline in its
+list of outlines. One outline is the primary outline. The primary outline is by
+default the first outline, or it can be optionally specified by the <emphasis>
+primary</emphasis>
+ field in the <emphasis>
+XkbShapeRec</emphasis>
+ structure. A keyboard display application can generate a simpler but still
+accurate keyboard image by displaying only the primary outlines for each shape.
+Nonrectangular keys must include a rectangular <emphasis>
+approximation</emphasis>
+ as one of the outlines associated with the shape. The approximation is not
+normally displayed but can be used by very simple keyboard display applications
+to generate a recognizable but degraded image of the keyboard.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The <emphasis>
+XkbGeometryRec</emphasis>
+ top-level geometry description contains the following information that
+pertains to the keyboard as a whole:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+A <emphasis>
+keyboard symbolic name</emphasis>
+ of type Atom to help users identify the keyboard.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The <emphasis>
+width</emphasis>
+ and <emphasis>
+height</emphasis>
+ of the keyboard, in mm/10. For nonrectangular keyboards, the width and height
+describe the smallest bounding box that encloses the outline of the keyboard.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The<emphasis>
+ base color</emphasis>
+ of the keyboard is the predominant color on the keyboard and is used as the
+default color for any components whose color is not explicitly specified.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The <emphasis>
+label color</emphasis>
+ is the color used to draw the labels on most of the keyboard keys.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The <emphasis>
+label font</emphasis>
+ is a string that describes the font used to draw labels on most keys; label
+fonts are arbitrary strings, because Xkb does not specify the format or name
+space for font names.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The keyboard is subdivided into named <emphasis>
+sections</emphasis>
+ of related keys and doodads. The sections and doodads on the keyboard are
+listed in the <emphasis>
+XkbGeometryRec</emphasis>
+ top-level keyboard geometry description. A section is composed of keys that
+are physically together and logically related. Figure 13.2 shows a keyboard
+that is divided into four sections. A <emphasis>
+doodad</emphasis>
+ describes some visible aspect of the keyboard that is not a key and is not a
+section.
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-8.svg"/>
+ </imageobject>
+<caption>Keyboard with Four Sections</caption>
+</mediaobject>
+
+<!--
+<H5 CLASS="Figure">
+Keyboard with Four Sections</H5>
+-->
+
+<sect1 id='shapes_and_outlines'>
+<title>Shapes and Outlines</title>
+
+<para>
+A <emphasis>
+shape</emphasis>
+, used to draw keyboard components and stored in a <emphasis>
+XkbShapeRec</emphasis>
+ structure, has:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+An arbitrary name of type Atom.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Bounds (two x and y coordinates) that describe the corners of a rectangle
+containing the shape’s top surface outline.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A list of one or more outlines (described below).
+ </para>
+</listitem>
+<listitem>
+ <para>
+Optional pointers to a primary and an approximation outline (described below).
+If either of these pointers is <emphasis>
+NULL</emphasis>
+, the default primary/approximation outline is the first one in the list of
+outlines for the shape.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+An <emphasis>
+outline</emphasis>
+, stored in a <emphasis>
+XkbOutlineRec</emphasis>
+ structure, is a list of one or more points that describes a single
+closed-polygon, as follows:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+A list with a single point describes a rectangle with one corner at the origin
+of the shape (0,0) and the opposite corner at the specified point.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A list of two points describes a rectangle with one corner at the position
+specified by the first point and the opposite corner at the position specified
+by the second point.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A list of three or more points describes an arbitrary polygon. If necessary,
+the polygon is automatically closed by connecting the last point in the list
+with the first.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A nonzero value for the <emphasis>
+corner_radius</emphasis>
+ field specifies that the corners of the polygon should be drawn as circles
+with the specified radius.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+All points in an outline are specified relative to the origin of the enclosing
+shape. Points in an outline may have negative values for the X and Y coordinate.
+</para>
+
+
+<para>
+One outline is the primary outline; a keyboard display application can generate
+a simple but still accurate keyboard image by displaying only the primary
+outlines for each shape. The default primary outline is the first in a
+shape’s list of outlines. If the <emphasis>
+primary</emphasis>
+ field of the <emphasis>
+XkbShapeRec</emphasis>
+ structure is not <emphasis>
+NULL</emphasis>
+, it points to the primary outline. A rectangular <emphasis>
+approximation</emphasis>
+ must be included for nonrectangular keys as one of the outlines associated
+with the shape; the approximation is not normally displayed but can be used by
+very simple keyboard display applications to generate a recognizable but
+degraded image of the keyboard.
+</para>
+
+</sect1>
+<sect1 id='sections'>
+<title>Sections</title>
+
+<para>
+As previously noted, a keyboard is subdivided into <emphasis>
+sections</emphasis>
+ of related keys. Each section has its own coordinate system — if a section
+is rotated, the coordinates of any components within the section are
+interpreted relative to the edges that were on the top and left before
+rotation. The components that make up a section, stored in a <emphasis>
+XkbSectionRec</emphasis>
+, include:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+An arbitrary name of type Atom.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A priority, to indicate drawing order. 0 is the highest priority, 255 the
+lowest.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Origin of the section, relative to the origin of the keyboard.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The width and height and the angle of rotation.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A list of <emphasis>
+rows</emphasis>
+. A row is a list of horizontally or vertically adjacent keys. Horizontal rows
+parallel the (prerotation) top of the section, and vertical rows parallel the
+(prerotation) left of the section. All keys in a horizontal row share a common
+top coordinate; all keys in a vertical row share a left coordinate. Figure 13.3
+shows the alpha section from the keyboard shown in Figure 13.2, divided into
+rows. Rows and keys are defined below.
+ </para>
+</listitem>
+</itemizedlist>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-9.svg"/>
+ </imageobject>
+ <caption>Rows in a Section</caption>
+</mediaobject>
+
+
+
+<!--
+<H5 CLASS="Figure">
+Rows in a Section</H5>
+-->
+<itemizedlist>
+<listitem>
+ <para>
+An optional list of <emphasis>
+doodads</emphasis>
+; any type of doodad can be enclosed within a section. Position and angle of
+rotation are relative to the origin and angle of rotation of the sections that
+contain them. Priority for doodads in a section is relative to the other
+components of the section, not to the keyboard as a whole.
+ </para>
+</listitem>
+<listitem>
+ <para>
+An optional <emphasis>
+overlay</emphasis>
+ with a name of type Atom and a list of overlay rows (described below).
+ </para>
+</listitem>
+<listitem>
+ <para>
+Bounds (two x and y coordinates) that describe the corners of a rectangle
+containing the entire section.
+ </para>
+</listitem>
+</itemizedlist>
+</sect1>
+<sect1 id='rows_and_keys'>
+<title>Rows and Keys</title>
+
+<para>
+A row description (<emphasis>
+XkbRowRec</emphasis>
+) consists of the coordinates of its origin relative to its enclosing section,
+a flag indicating whether the row is horizontal or vertical, and a list of keys
+in the row.
+</para>
+
+
+<para>
+A key description (<emphasis>
+XkbKeyRec</emphasis>
+) consists of a key name, a shape, a key color, and a gap. The key name should
+correspond to one of the keys named in the keyboard names description, the
+shape specifies the appearance of the key, and the key color specifies the
+color of the key (not the label on the key; the label color is stored in the
+<emphasis>
+XkbGeometryRec</emphasis>
+). Keys are normally drawn immediately adjacent to one another from left to
+right (or top to bottom) within a row. The gap field specifies the distance
+between a key and its predecessor.
+</para>
+
+
+</sect1>
+<sect1 id='doodads'>
+<title>Doodads</title>
+
+<para>
+Doodads can be global to the keyboard or part of a section. Doodads have
+symbolic names of arbitrary length. The only doodad name whose interpretation
+is specified by Xkb is "Edges", which, if present, describes the outline of the
+entire keyboard.
+</para>
+
+
+<para>
+Each doodad’s origin is stored in fields named <emphasis>
+left</emphasis>
+ and <emphasis>
+top</emphasis>
+, which are the coordinates of the doodad’s origin relative to its enclosing
+object, whether it be a section or the top-level keyboard. The priority for
+doodads that are listed in the top-level geometry is relative to the other
+doodads listed in the top-level geometry and the sections listed in the
+top-level geometry. The priority for doodads listed in a section are relative
+to the other components of the section. Each doodad is stored in a structure
+with a <emphasis>
+type</emphasis>
+ field, which specifies the type of doodad.
+</para>
+
+<para>
+Xkb supports five types of doodads:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+An <emphasis>
+indicator doodad</emphasis>
+ describes one of the physical keyboard indicators. Indicator doodads specify
+the shape of the indicator, the indicator color when it is lit (<emphasis>
+on_color</emphasis>
+) and the indicator color when it is dark (<emphasis>
+off_color</emphasis>
+).
+ </para>
+</listitem>
+<listitem>
+ <para>
+An <emphasis>
+outline doodad</emphasis>
+ describes some aspect of the keyboard to be drawn as one or more hollow,
+closed polygons. Outline doodads specify the shape, color, and angle of
+rotation about the doodad origin at which they should be drawn.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A <emphasis>
+solid doodad</emphasis>
+ describes some aspect of the keyboard to be drawn as one or more filled
+polygons. Solid doodads specify the shape, color, and angle of rotation about
+the doodad origin at which they should be drawn.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A <emphasis>
+text doodad</emphasis>
+ describes a text label somewhere on the keyboard. Text doodads specify the
+label string, the font and color to use when drawing the label, and the angle
+of rotation of the doodad about its origin.
+ </para>
+</listitem>
+<listitem>
+ <para>
+A <emphasis>
+logo doodad </emphasis>
+is a catch-all, which describes some other visible element of the keyboard. A
+logo doodad is essentially an outline doodad with an additional symbolic name
+that describes the element to be drawn. If a keyboard display program
+recognizes the symbolic name, it can draw something appropriate within the
+bounding region of the shape specified in the doodad. If the symbolic name does
+not describe a recognizable image, it should draw an outline using the
+specified shape, outline, and angle of rotation. The Xkb extension does not
+specify the interpretation of logo names.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+The structures these doodads are stored in and the values of the <emphasis>
+type</emphasis>
+ fields are shown in Table 13.1.
+</para>
+
+<table frame='none'>
+<title>Doodad Types</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Doodad</entry>
+ <entry>Structure</entry>
+ <entry>Type</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>
+indicator doodad</emphasis>
+</entry>
+ <entry><emphasis>
+XkbIndicatorDoodadRec</emphasis>
+</entry>
+ <entry><emphasis>
+XkbIndicatorDoodad</emphasis>
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>
+outline doodad</emphasis>
+</entry>
+ <entry><emphasis>
+XkbShapeDoodadRec</emphasis>
+</entry>
+ <entry><emphasis>
+XkbOutlineDoodad</emphasis>
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>
+solid doodad</emphasis>
+</entry>
+ <entry><emphasis>
+XkbShapeDoodadRec</emphasis>
+</entry>
+ <entry><emphasis>
+XkbSolidDoodad</emphasis>
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>
+text doodad</emphasis>
+</entry>
+ <entry><emphasis>
+XkbTextDoodadRec</emphasis>
+</entry>
+ <entry><emphasis>
+XkbTextDoodad</emphasis>
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>
+logo doodad</emphasis>
+</entry>
+ <entry><emphasis>
+XkbLogoDoodadRec</emphasis>
+</entry>
+ <entry><emphasis>
+XkbLogoDoodad</emphasis>
+</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='overlay_rows_and_overlay_keys'>
+<title>Overlay Rows and Overlay Keys</title>
+
+<para>
+An <emphasis>
+overlay row</emphasis>
+ (<emphasis>
+XkbOverlayRowRec</emphasis>
+) contains a pointer to the row it overlays and a list of <emphasis>
+overlay keys</emphasis>
+.
+</para>
+
+
+<para>
+Each overlay key definition (<emphasis>
+XkbOverlayKeyRec</emphasis>
+) indicates a key that can yield multiple keycodes and consists of a field
+named <emphasis>
+under</emphasis>
+, which specifies the primary name of the key and a field named <emphasis>
+over</emphasis>
+, which specifies the name for the key when the overlay keycode is selected.
+The key specified in <emphasis>
+under</emphasis>
+ must be a member of the section that contains the overlay key definition,
+while the key specified in over must not be.
+</para>
+
+
+</sect1>
+<sect1 id='drawing_a_keyboard_representation'>
+<title>Drawing a Keyboard Representation</title>
+
+<para>
+To draw a representation of the keyboard, draw in the following order:
+</para>
+
+<para><programlisting>
+ Draw the top-level keyboard as a rectangle, using its width and height.
+ For each component (section or doodad) of the top-level geometry, in priority order:
+ If component is a section
+ For each row, in the order it appears in the section
+ Draw keys in the order they appear in the row
+ Draw doodads within the section in priority order.
+ Else draw doodad
+</programlisting></para>
+
+</sect1>
+<sect1 id='geometry_data_structures'>
+<title>Geometry Data Structures</title>
+
+<para>
+In the following figures, a solid arrow denotes a pointer to an array of
+structures or a singleton structure. A dotted arrow denotes an index or a
+pointer into the array.
+</para>
+
+<!--
+<MAP NAME="XKBlib-10">
+</MAP>
+-->
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-10.svg"/>
+ </imageobject>
+<caption>Xkb Geometry Data Structures</caption>
+</mediaobject>
+
+<!--
+<H5 CLASS="Figure">
+Xkb Geometry Data Structures</H5>
+<P CLASS="SmallBody">
+&nbsp;</P>
+<MAP NAME="XKBlib-11">
+</MAP>
+-->
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-11.svg"/>
+ </imageobject>
+<caption>Xkb Geometry Data Structures (Doodads)</caption>
+</mediaobject>
+
+<!--
+<H5 CLASS="Figure">
+Xkb Geometry Data Structures (Doodads)</H5>
+-->
+
+<!--
+<MAP NAME="XKBlib-12">
+</MAP>
+-->
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-12.svg"/>
+ </imageobject>
+<caption>Xkb Geometry Data Structures (Overlays)</caption>
+</mediaobject>
+
+<!--
+<H5 CLASS="Figure">
+Xkb Geometry Data Structures (Overlays)</H5>
+-->
+<para><programlisting>
+typedef struct _XkbGeometry { /* top-level keyboard geometry structure */
+ Atom name; /* keyboard name */
+ unsigned short width_mm; /* keyboard width in <emphasis> mm</emphasis> /<emphasis> 10</emphasis> */
+ unsigned short height_mm; /* keyboard height in <emphasis> mm</emphasis> /<emphasis> 10</emphasis> */
+ char * label_font; /* font for key labels */
+ XkbColorPtr label_color; /* color for key labels - pointer into colors array */
+ XkbColorPtr base_color; /* color for basic keyboard - pointer into colors array */
+ unsigned short sz_properties; /* size of properties array */
+ unsigned short sz_colors; /* size of colors array */
+ unsigned short sz_shapes; /* size of shapes array */
+ unsigned short sz_sections; /* size of sections array */
+ unsigned short sz_doodads; /* size of doodads array */
+ unsigned short sz_key_aliases; /* size of key aliases array */
+ unsigned short num_properties; /* number of properties in the properties array */
+ unsigned short num_colors; /* number of colors in the colors array */
+ unsigned short num_shapes; /* number of shapes in the shapes array */
+ unsigned short num_sections; /* number of sections in the sections array */
+ unsigned short num_doodads; /* number of doodads in the doodads array */
+ unsigned short num_key_aliases; /* number of key aliases in the key */
+ XkbPropertyPtr properties; /* properties array */
+ XkbColorPtr colors; /* colors array */
+ XkbShapePtr shapes; /* shapes array */
+ XkbSectionPtr sections; /* sections array */
+ XkbDoodadPtr doodads; /* doodads array */
+ XkbKeyAliasPtr key_aliases; /* key aliases array */
+} <emphasis>XkbGeometryRec</emphasis>*XkbGeometryPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+doodads</emphasis>
+ array is only for doodads not contained in any of the <emphasis>
+sections</emphasis>
+ that has its own <emphasis>
+doodads</emphasis>
+. The key aliases contained in the <emphasis>
+key_aliases</emphasis>
+ array take precedence over any defined in the keycodes component of the
+keyboard description.
+</para>
+
+<para><programlisting>
+typedef struct _XkbProperty {
+ char * name; /* property name */
+ char * value; /* property value */
+} <emphasis>XkbPropertyRec</emphasis>,*XkbPropertyPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbColor {
+ unsigned int pixel; /* color */
+ char * spec; /* color name */
+} <emphasis>XkbColorRec</emphasis>,*XkbColorPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbKeyAliasRec {
+ char real[XkbKeyNameLength]; /* real name of the key */
+ char alias[XkbKeyNameLength]; /* alias for the key */
+} <emphasis>XkbKeyAliasRec</emphasis>,*XkbKeyAliasPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbPoint { /* x,y coordinates */
+ short x;
+ short y;
+} <emphasis>XkbPointRec</emphasis>, *XkbPointPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbOutline {
+ unsigned short num_points; /* number of points in the outline */
+ unsigned short sz_points; /* size of the points array */
+ unsigned short corner_radius; /* draw corners as circles with this radius */
+ XkbPointPtr points; /* array of points defining the outline */
+} <emphasis>XkbOutlineRec</emphasis>, *XkbOutlinePtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbBounds {
+ short x1,y1; /* upper left corner of the bounds,
+ in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short x2,y2; /* lower right corner of the bounds, in
+ <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+} <emphasis>XkbBoundsRec</emphasis>, *XkbBoundsPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbShape {
+ Atom name; /* shape’s name */
+ unsigned short num_outlines; /* number of outlines for the shape */
+ unsigned short sz_outlines; /* size of the outlines array */
+ XkbOutlinePtr outlines; /* array of outlines for the shape */
+ XkbOutlinePtr approx; /* pointer into the array to the approximating outline */
+ XkbOutlinePtr primary; /* pointer into the array to the primary outline */
+ XkbBoundsRec bounds; /* bounding box for the shape; encompasses all outlines */
+} <emphasis>XkbShapeRec</emphasis>, *XkbShapePtr;
+</programlisting></para>
+
+<para>
+If <emphasis>
+approx</emphasis>
+ and/or <emphasis>
+primary</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, the default value is used. The default primary outline is the first element
+in the outlines array, as is the default approximating outline.
+</para>
+
+<para><programlisting>
+typedef struct _XkbKey { /* key in a row */
+ XkbKeyNameRec name; /* key name */
+ short gap; /* gap in <emphasis>mm</emphasis>/<emphasis>10</emphasis> from previous key in row */
+ unsigned char shape_ndx; /* index of shape for key */
+ unsigned char color_ndx; /* index of color for key body */
+} <emphasis>XkbKeyRec</emphasis>, *XkbKeyPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbRow { /* row in a section */
+ short top; /* top coordinate of row origin, relative to section’s origin */
+ short left; /* left coordinate of row origin, relative to section’s origin */
+ unsigned short num_keys; /* number of keys in the keys array */
+ unsigned short sz_keys; /* size of the keys array */
+ int vertical; /* <emphasis>True</emphasis> =&gt;vertical row,
+ <emphasis> False</emphasis> =&gt;horizontal row */
+ XkbKeyPtr keys; /* array of keys in the row*/
+ XkbBoundsRec bounds; /* bounding box for the row */
+} <emphasis>XkbRowRec</emphasis>, *XkbRowPtr;
+</programlisting></para>
+
+<para>
+<emphasis>
+top</emphasis>
+ and <emphasis>
+left</emphasis>
+ are in <emphasis>
+mm</emphasis>
+/<emphasis>
+10</emphasis>
+.
+</para>
+
+<para><programlisting>
+typedef struct _XkbOverlayRec {
+ Atom name; /* overlay name */
+ XkbSectionPtr section_under; /* the section under this overlay */
+ unsigned short num_rows; /* number of rows in the rows array */
+ unsigned short sz_rows; /* size of the rows array */
+ XkbOverlayRowPtr rows; /* array of rows in the overlay */
+ XkbBoundsPtr bounds; /* bounding box for the overlay */
+} <emphasis>XkbOverlayRec</emphasis>,*XkbOverlayPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbOverlayRow {
+ unsigned short row_under; /* index into the row under this overlay row */
+ unsigned short num_keys; /* number of keys in the keys array */
+ unsigned short sz_keys; /* size of the keys array */
+ XkbOverlayKeyPtr keys; /* array of keys in the overlay row */
+} <emphasis>XkbOverlayRowRec</emphasis>,*XkbOverlayRowPtr;
+</programlisting></para>
+
+<para>
+<emphasis>
+row_under</emphasis>
+ is an index into the array of <emphasis>
+rows</emphasis>
+ in the section under this overlay. The section under this overlay row is the
+one pointed to by <emphasis>
+section_under</emphasis>
+ in this overlay row’s <emphasis>
+XkbOverlayRec</emphasis>
+.
+</para>
+
+<para><programlisting>
+typedef struct _XkbOverlayKey {
+ XkbKeyNameRec over; /* name of this overlay key */
+ XkbKeyNameRec under; /* name of the key under this overlay key */
+} <emphasis>XkbOverlayKeyRec</emphasis>,*XkbOverlayKeyPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbSection {
+ Atom name; /* section name */
+ unsigned char priority; /* drawing priority, 0=&gt;highest, 255=&gt;lowest */
+ short top; /* top coordinate of section origin */
+ short left; /* left coordinate of row origin */
+ unsigned short width; /* section width, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ unsigned short height; /* section height, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short angle; /* angle of section rotation, counterclockwise */
+ unsigned short num_rows; /* number of rows in the rows array */
+ unsigned short num_doodads; /* number of doodads in the doodads array */
+ unsigned short num_overlays; /* number of overlays in the overlays array */
+ unsigned short sz_rows; /* size of the rows array */
+ unsigned short sz_doodads; /* size of the doodads array */
+ unsigned short sz_overlays; /* size of the overlays array */
+ XkbRowPtr rows; /* section rows array */
+ XkbDoodadPtr doodads; /* section doodads array */
+ XkbBoundsRec bounds; /* bounding box for the section, before rotation*/
+ XkbOverlayPtr overlays; /* section overlays array */
+} <emphasis>XkbSectionRec</emphasis>, *XkbSectionPtr;
+</programlisting></para>
+
+<para>
+<emphasis>
+top</emphasis>
+ and <emphasis>
+left</emphasis>
+ are the origin of the section, relative to the origin of the keyboard, in
+<emphasis>
+mm</emphasis>
+/<emphasis>
+10</emphasis>
+. <emphasis>
+angle</emphasis>
+ is in <emphasis>
+1</emphasis>
+/<emphasis>
+10</emphasis>
+ degrees.
+</para>
+
+<sect2 id='doodadrec_structures'>
+<title>DoodadRec Structures</title>
+
+<para>
+The doodad arrays in the <emphasis>
+XkbGeometryRec</emphasis>
+ and the <emphasis>
+XkbSectionRec</emphasis>
+ may contain any of the doodad structures and types shown in Table 13.1.
+</para>
+
+
+<para>
+The doodad structures form a union:
+</para>
+
+<para><programlisting>
+typedef union _XkbDoodad {
+ XkbAnyDoodadRec any;
+ XkbShapeDoodadRec shape;
+ XkbTextDoodadRec text;
+ XkbIndicatorDoodadRec indicator;
+ XkbLogoDoodadRec logo;
+} <emphasis>XkbDoodadRec</emphasis>, *XkbDoodadPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+top</emphasis>
+ and <emphasis>
+left</emphasis>
+ coordinates of each doodad are the coordinates of the origin of the doodad
+relative to the keyboard’s origin if the doodad is in the <emphasis>
+XkbGeometryRec</emphasis>
+ doodad array, and with respect to the section’s origin if the doodad is in a
+<emphasis>
+XkbSectionRec</emphasis>
+ doodad array. The <emphasis>
+color_ndx</emphasis>
+ or <emphasis>
+on_color_ndx</emphasis>
+ and <emphasis>
+off_color_ndx</emphasis>
+ fields are color indices into the <emphasis>
+XkbGeometryRec</emphasis>
+’s color array and are the colors to draw the doodads with. Similarly, the
+<emphasis>
+shape_ndx</emphasis>
+ fields are indices into the <emphasis>
+XkbGeometryRec</emphasis>
+’s shape array.
+</para>
+
+<para><programlisting>
+typedef struct _XkbShapeDoodad {
+ Atom name; /* doodad name */
+ unsigned char type; /* <emphasis>XkbOutlineDoodad</emphasis>
+ or <emphasis>XkbSolidDoodad</emphasis> */
+ unsigned char priority; /* drawing priority,
+ 0=&gt;highest, 255=&gt;lowest */
+ short top; /* top coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short left; /* left coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short angle; /* angle of rotation, clockwise, in <emphasis>1</emphasis>/<emphasis>10</emphasis> degrees */
+ unsigned short color_ndx; /* doodad color */
+ unsigned short shape_ndx; /* doodad shape */
+} <emphasis>XkbShapeDoodadRec</emphasis>, *XkbShapeDoodadPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbTextDoodad {
+ Atom name; /* doodad name */
+ unsigned char type; /* <emphasis> XkbTextDoodad</emphasis> */
+ unsigned char priority; /* drawing priority,
+ 0=&gt;highest, 255=&gt;lowest */
+ short top; /* top coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short left; /* left coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short angle; /* angle of rotation, clockwise, in <emphasis>1</emphasis>/<emphasis>10</emphasis> degrees */
+ short width; /* width in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short height; /* height in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ unsigned short color_ndx; /* doodad color */
+ char * text; /* doodad text */
+ char * font; /* arbitrary font name for doodad text */
+} <emphasis>XkbTextDoodadRec</emphasis>, *XkbTextDoodadPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbIndicatorDoodad {
+ Atom name; /* doodad name */
+ unsigned char type; /* <emphasis>XkbIndicatorDoodad</emphasis> */
+ unsigned char priority; /* drawing priority, 0=&gt;highest, 255=&gt;lowest */
+ short top; /* top coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short left; /* left coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short angle; /* angle of rotation, clockwise, in <emphasis>1</emphasis>/<emphasis>10</emphasis> degrees */
+ unsigned short shape_ndx; /* doodad shape */
+ unsigned short on_color_ndx; /* color for doodad if indicator is on */
+ unsigned short off_color_ndx; /* color for doodad if indicator is off */
+} <emphasis>XkbIndicatorDoodadRec</emphasis>, *XkbIndicatorDoodadPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbLogoDoodad {
+ Atom name; /* doodad name */
+ unsigned char type; /* <emphasis> XkbLogoDoodad</emphasis> */
+ unsigned char priority; /* drawing priority, 0=&gt;highest, 255=&gt;lowest */
+ short top; /* top coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short left; /* left coordinate, in <emphasis>mm</emphasis>/<emphasis>10</emphasis> */
+ short angle; /* angle of rotation, clockwise, in <emphasis>1</emphasis>/<emphasis>10</emphasis> degrees */
+ unsigned short color_ndx; /* doodad color */
+ unsigned short shape_ndx; /* doodad shape */
+ char * logo_name; /* text for logo */
+} <emphasis>XkbLogoDoodadRec</emphasis>, *XkbLogoDoodadPtr
+</programlisting></para>
+
+</sect2>
+</sect1>
+<sect1 id='getting_keyboard_geometry_from_the_server'>
+<title>Getting Keyboard Geometry From the Server</title>
+
+<para>
+You can load a keyboard geometry as part of the keyboard description returned
+by <emphasis>
+XkbGetKeyboard</emphasis>
+. However, if a keyboard description has been previously loaded, you can
+instead obtain the geometry by calling the <emphasis>
+XkbGetGeometry</emphasis>
+. In this case, the geometry returned is the one associated with the keyboard
+whose device ID is contained in the keyboard description.
+</para>
+
+<para>
+To load a keyboard geometry if you already have the keyboard description, use
+<emphasis>XkbGetGeometry</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetGeometry</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description that contains the ID for the keyboard and into
+which the geometry should be loaded */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetGeometry</emphasis>
+ can return <emphasis>
+BadValue</emphasis>
+, <emphasis>
+BadImplementation</emphasis>
+, <emphasis>
+BadName</emphasis>
+, <emphasis>
+BadAlloc,</emphasis>
+ or <emphasis>
+BadLength</emphasis>
+ errors or <emphasis>
+Success</emphasis>
+ if it succeeds.
+</para>
+
+<para>
+It is also possible to load a keyboard geometry by name. The X server maintains
+a database of keyboard components (see Chapter 20). To load a keyboard geometry
+description from this database by name, use <emphasis>
+XkbGetNamedGeometry</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetNamedGeometry</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+,<emphasis>
+ name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description into which the geometry should be loaded */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+name</emphasis>
+; /* name of the geometry to be loaded */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetNamedGeometry</emphasis>
+ can return <emphasis>
+BadName</emphasis>
+ if the <emphasis>
+name</emphasis>
+ cannot be found.
+</para>
+
+</sect1>
+<sect1 id='using_keyboard_geometry'>
+<title>Using Keyboard Geometry</title>
+
+<para>
+Xkb provides a number of convenience functions to help use a keyboard geometry.
+These include functions to return the bounding box of a shape’s top surface
+and to update the bounding box of a shape row or section.
+</para>
+
+<para>
+A shape is made up of a number of outlines. Each outline is a polygon made up
+of a number of points. The bounding box of a shape is a rectangle that contains
+all the outlines of that shape.
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-13.svg"/>
+ </imageobject>
+<caption>Key Surface, Shape Outlines, and Bounding Box</caption>
+ </mediaobject>
+
+
+<!--
+<H5 CLASS="Figure">
+Key Surface, Shape Outlines, and Bounding Box</H5>
+-->
+
+<para>
+To determine the bounding box of the top surface of a shape, use <emphasis>
+XkbComputeShapeTop</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbComputeShapeTop</emphasis>
+(<emphasis>
+shape</emphasis>
+,<emphasis>
+ bounds_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbShapePtr <emphasis>
+ shape</emphasis>
+; /* shape to be examined */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbBoundsPtr <emphasis>
+ bounds_rtrn</emphasis>
+ /* backfilled with the bounding box for the shape */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbComputeShapeTop</emphasis>
+ returns a <emphasis>
+BoundsRec</emphasis>
+ that contains two x and y coordinates. These coordinates describe the corners
+of a rectangle that contains the outline that describes the top surface of the
+shape. The top surface is defined to be the approximating outline if the
+<emphasis>
+approx</emphasis>
+ field of <emphasis>
+shape</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+. If <emphasis>
+approx</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, the top surface is defined as the last outline in the <emphasis>
+shape</emphasis>
+’s array of outlines. <emphasis>
+XkbComputeShapeTop</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if <emphasis>
+shape</emphasis>
+ is <emphasis>
+NULL</emphasis>
+ or if there are no outlines for the shape; otherwise, it returns
+<emphasis>True</emphasis>.
+</para>
+
+
+<para>
+A <emphasis>
+ShapeRec</emphasis>
+ contains a <emphasis>
+BoundsRec</emphasis>
+ that describes the bounds of the shape. If you add or delete an outline to or
+from a shape, the bounding box must be updated. To update the bounding box of a
+shape, use <emphasis>XkbComputeShapeBounds</emphasis>.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbComputeShapeBounds</emphasis>
+(<emphasis>
+shape</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbShapePtr <emphasis>
+ shape</emphasis>
+; /* shape to be examined */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbComputeShapeBounds</emphasis>
+ updates the <emphasis>
+BoundsRec</emphasis>
+ contained in the <emphasis>
+shape</emphasis>
+ by examining all the outlines of the shape and setting the <emphasis>
+BoundsRec</emphasis>
+ to the minimum x and minimum y, and maximum x and maximum y values found in
+those outlines. <emphasis>
+XkbComputeShapeBounds</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if <emphasis>
+shape</emphasis>
+ is <emphasis>
+NULL</emphasis>
+ or if there are no outlines for the shape; otherwise, it returns <emphasis>
+True</emphasis>
+.
+</para>
+
+<para>
+ If you add or delete a key to or from a row, or if you update the shape of one
+of the keys in that row, you may need to update the bounding box of that row.
+To update the bounding box of a row, use <emphasis>XkbComputeRowBounds</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbComputeRowBounds</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ section</emphasis>
+,<emphasis>
+ row</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry that contains the <emphasis>
+section</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section that contains the row */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+row</emphasis>
+; /* row to be examined and updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbComputeRowBounds</emphasis>
+ checks the bounds of all keys in the <emphasis>
+row </emphasis>
+and updates the bounding box of the row if necessary. <emphasis>
+XkbComputeRowBounds</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if any of the arguments is <emphasis>
+NULL</emphasis>
+; otherwise, it returns <emphasis>
+True</emphasis>
+.
+</para>
+
+<para>
+ If you add or delete a row to or from a section, or if you change the geometry
+of any of the rows in that section, you may need to update the bounding box for
+that section. To update the bounding box of a section, use
+<emphasis>XkbComputeSectionBounds</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbComputeSectionBounds</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ section</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry that contains the <emphasis>
+section</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section to be examined and updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbComputeSectionBounds</emphasis>
+ examines all the rows of the <emphasis>
+section</emphasis>
+ and updates the bounding box of that section so that it contains all rows.
+<emphasis>
+XkbComputeSectionBounds</emphasis>
+ returns <emphasis>
+False</emphasis>
+ if any of the arguments is <emphasis>
+NULL</emphasis>
+; otherwise, it returns <emphasis>
+True</emphasis>
+.
+</para>
+
+<para>
+Keys that can generate multiple keycodes may be associated with multiple names.
+Such keys have a primary name and an alternate name. To find the alternate name
+by using the primary name for a key that is part of an overlay, use <emphasis>
+XkbFindOverlayForKey</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+char * <emphasis>
+XkbFindOverlayForKey</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ section</emphasis>
+,<emphasis>
+ under</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry that contains the <emphasis>
+section</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section to be searched for matching keys */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ under</emphasis>
+. /* primary name of the key to be considered */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbFindOverlayForKey</emphasis>
+ uses the primary name of the key, <emphasis>
+under</emphasis>
+, to look up the alternate name, which it returns.
+</para>
+
+
+</sect1>
+<sect1 id='adding_elements_to_a_keyboard_geometry'>
+<title>Adding Elements to a Keyboard Geometry</title>
+
+<para>
+Xkb provides functions to add a single new element to the top-level keyboard
+geometry. In each case the <emphasis>
+num_ </emphasis>
+<emphasis>
+*</emphasis>
+ fields of the corresponding structure is incremented by 1. These functions do
+not change <emphasis>
+sz_</emphasis>
+<emphasis>
+*</emphasis>
+ unless there is no more room in the array. Some of these functions fill in the
+values of the element’s structure from the arguments. For other functions,
+you must explicitly write code to fill the structure’s elements.
+</para>
+
+
+<para>
+The top-level geometry description includes a list of <emphasis>
+geometry properties</emphasis>
+. A geometry property associates an arbitrary string with an equally arbitrary
+name. Programs that display images of keyboards can use geometry properties as
+hints, but they are not interpreted by Xkb. No other geometry structures refer
+to geometry properties.
+</para>
+
+
+<para>
+To add one property to an existing keyboard geometry description, use <emphasis>
+XkbAddGeomProperty</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbPropertyPtr <emphasis>
+XkbAddGeomProperty</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ value</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ name</emphasis>
+; /* name of the new property */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ value</emphasis>
+; /* value for the new property */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomProperty</emphasis>
+ adds one property with the specified <emphasis>
+name</emphasis>
+ and <emphasis>
+value</emphasis>
+ to the keyboard geometry specified by geom.<emphasis>
+ </emphasis>
+<emphasis>
+XkbAddGeomProperty</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the property. To allocate space for an arbitrary number of properties, use the
+XkbAllocGeomProps function.
+</para>
+
+
+<para>
+To add one key alias to an existing keyboard geometry description, use
+<emphasis>
+XkbAddGeomKeyAlias</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbKeyAliasPtr <emphasis>
+XkbAddGeomKeyAlias</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ alias, real</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ alias</emphasis>
+; /* alias to be added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ real</emphasis>
+; /* real name to be bound to the new alias */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomKeyAlias</emphasis>
+ adds one key alias with the value alias to the geometry geom, and associates
+it with the key whose real name is real. <emphasis>
+XkbAddGeomKeyAlias</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the alias. To allocate space for an arbitrary number of aliases, use the
+XkbAllocGeomKeyAliases function.
+</para>
+
+
+<para>
+To add one color name to an existing keyboard geometry description, use
+<emphasis>
+XkbAddGeomColor</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbColorPtr <emphasis>
+XkbAddGeomColor</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ spec</emphasis>
+,<emphasis>
+ pixel</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ spec</emphasis>
+; /* color to be added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ pixel</emphasis>
+; /* color to be added */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomColor</emphasis>
+ adds the specified color <emphasis>
+name</emphasis>
+ and <emphasis>
+pixel</emphasis>
+ to the specified geometry <emphasis>
+geom</emphasis>
+. The top-level geometry description includes a list of up to <emphasis>
+MaxColors</emphasis>
+ (32) <emphasis>
+color names</emphasis>
+. A color <emphasis>
+name</emphasis>
+ is a string whose interpretation is not specified by Xkb and neither is the
+<emphasis>
+pixel</emphasis>
+ value’s interpretation. All other geometry data structures refer to colors
+using their indices in this global list or pointers to colors in this list.
+<emphasis>
+XkbAddGeomColor</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the color. To allocate space for an arbitrary number of colors to a geometry,
+use the <emphasis>
+XkbAllocGeomColors</emphasis>
+ function.
+</para>
+
+<para>
+To add one outline to an existing shape, use <emphasis>
+XkbAddGeomOutline</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbOutlinePtr <emphasis>
+XkbAddGeomOutline</emphasis>
+(<emphasis>
+shape</emphasis>
+,<emphasis>
+ sz_points</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbShapePtr <emphasis>
+ shape</emphasis>
+; /* shape to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_points</emphasis>
+; /* number of points to be reserved */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+An outline consists of an arbitrary number of points. <emphasis>
+XkbAddGeomOutline</emphasis>
+ adds an outline to the specified <emphasis>
+shape</emphasis>
+ by reserving <emphasis>
+sz_points</emphasis>
+ points for it. The new outline is allocated and zeroed. <emphasis>
+XkbAddGeomOutline</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space. To
+allocate space for an arbitrary number of outlines to a shape, use
+XkbAllocGeomOutlines.
+</para>
+
+
+<para>
+To add a shape to a keyboard geometry, use <emphasis>
+XkbAddGeomShape</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbShapePtr <emphasis>
+XkbAddGeomShape</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ sz_outlines</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the new shape */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_outlines</emphasis>
+; /* number of outlines to be reserved */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+A geometry contains an arbitrary number of shapes, each of which is made up of
+an arbitrary number of outlines. <emphasis>
+XkbAddGeomShape</emphasis>
+ adds a shape to a geometry <emphasis>
+geom</emphasis>
+ by allocating space for <emphasis>
+sz_outlines</emphasis>
+ outlines for it and giving it the name specified by name. If a shape with name
+<emphasis>
+name</emphasis>
+ already exists in the geometry, a pointer to the existing shape is returned.
+<emphasis>
+XkbAddGeomShape</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space. To
+allocate space for an arbitrary number of geometry shapes, use <emphasis>
+XkbAllocGeomShapes</emphasis>
+.
+</para>
+
+
+<para>
+To add one key at the end of an existing row of keys, use <emphasis>
+XkbAddGeomKey</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbKeyPtr <emphasis>
+XkbAddGeomKey</emphasis>
+(<emphasis>
+row</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row</emphasis>
+; /* row to be updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+Keys are grouped into rows. <emphasis>
+XkbAddGeomKey</emphasis>
+ adds one key to the end of the specified <emphasis>
+row</emphasis>
+. The key is allocated and zeroed. <emphasis>
+XkbAddGeomKey</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if <emphasis>
+row</emphasis>
+ is empty or if it was not able to allocate space for the key. To allocate
+space for an arbitrary number of keys to a row, use XkbAllocGeomKeys.
+</para>
+
+
+<para>
+To add one section to an existing keyboard geometry, use <emphasis>
+XkbAddGeomSection</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbSectionPtr <emphasis>
+XkbAddGeomSection</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ sz_rows</emphasis>
+,<emphasis>
+ sz_doodads</emphasis>
+,<emphasis>
+ sz_overlays</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the new section */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_rows</emphasis>
+; /* number of rows to reserve in the section */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_doodads</emphasis>
+; /* number of doodads to reserve in the section */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_overlays</emphasis>
+; /* number of overlays to reserve in the section */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+A keyboard geometry contains an arbitrary number of sections. <emphasis>
+XkbAddGeomSection</emphasis>
+ adds one section to an existing keyboard geometry <emphasis>
+geom</emphasis>
+. The new section contains space for the number of rows, doodads, and overlays
+specified by <emphasis>
+sz_rows</emphasis>
+, <emphasis>
+sz_doodads</emphasis>
+, and <emphasis>
+sz_overlays</emphasis>
+. The new section is allocated and zeroed and given the name specified by
+<emphasis>
+name</emphasis>
+. If a section with name <emphasis>
+name</emphasis>
+ already exists in the geometry, a pointer to the existing section is
+returned.<emphasis>
+ XkbAddGeomSection</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the section. To allocate space for an arbitrary number of sections to a
+geometry, use XkbAllocGeomSections.
+</para>
+
+
+<para>
+To add a row to a section, use <emphasis>
+XkbAddGeomRow</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbRowPtr <emphasis>
+XkbAddGeomRow</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ sz_keys</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+sz_keys</emphasis>
+; /* number of keys to be reserved */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+One of the components of a keyboard geometry section is one or more rows of
+keys. <emphasis>
+XkbAddGeomRow</emphasis>
+ adds one row to the specified <emphasis>
+section</emphasis>
+. The newly created row contains space for the number of keys specified in
+<emphasis>
+sz_keys</emphasis>
+. They are allocated and zeroed, but otherwise uninitialized. <emphasis>
+XkbAddGeomRow</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the row. To allocate space for an arbitrary number of rows to a section, use
+the XkbAllocGeomRows function.
+</para>
+
+
+<para>
+To add one doodad to a section of a keyboard geometry or to the top-level
+geometry, use <emphasis>
+XkbAddGeomDoodad</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDoodadPtr <emphasis>
+XkbAddGeomDoodad</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ section</emphasis>
+,<emphasis>
+ name</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to which the doodad is added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section, if any, to which the doodad is added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the new doodad */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+A <emphasis>
+doodad</emphasis>
+ describes some visible aspect of the keyboard that is not a key and is not a
+section. <emphasis>
+XkbAddGeomDoodad</emphasis>
+ adds a doodad with name specified by name to the geometry <emphasis>
+geom</emphasis>
+ if section is <emphasis>
+NULL</emphasis>
+ or to the section of the geometry specified by section if <emphasis>
+section</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+. <emphasis>
+XkbAddGeomDoodad</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the doodad. If there is already a doodad with the name <emphasis>
+name</emphasis>
+ in the doodad array for the geometry (if <emphasis>
+section</emphasis>
+ is <emphasis>
+NULL</emphasis>
+) or the section (if <emphasis>
+section</emphasis>
+ is non-<emphasis>
+NULL</emphasis>
+), a pointer to that doodad is returned. To allocate space for an arbitrary
+number of doodads to a section, use the XkbAllocGeomSectionDoodads function. To
+allocate space for an arbitrary number of doodads to a keyboard geometry, use
+the XkbAllocGeomDoodads function.
+</para>
+
+
+<para>
+To add one overlay to a section, use <emphasis>
+XkbAddGeomOverlay</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbOverlayPtr <emphasis>
+XkbAddGeomOverlay</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ name</emphasis>
+,<emphasis>
+ sz_rows</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section to which an overlay will be added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Atom <emphasis>
+ name</emphasis>
+; /* name of the overlay */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_rows</emphasis>
+; /* number of rows to reserve in the overlay */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomOverlay</emphasis>
+ adds an overlay with the specified name to the specified <emphasis>
+section</emphasis>
+. The new overlay is created with space allocated for sz_rows rows. If an
+overlay with name <emphasis>
+name</emphasis>
+ already exists in the section, a pointer to the existing overlay is
+returned.<emphasis>
+ XkbAddGeomOverlay</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the overlay. To allocate space for an arbitrary number of overlays to a
+section, use the XkbAllocGeomOverlay function.
+</para>
+
+
+<para>
+To add a row to an existing overlay, use <emphasis>
+XkbAddGeomOverlayRow</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbOverlayRowPtr <emphasis>
+XkbAddGeomOverlayRow</emphasis>
+(<emphasis>
+overlay</emphasis>
+,<emphasis>
+ row_under, sz_keys</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbOverlayPtr <emphasis>
+ overlay</emphasis>
+; /* overlay to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row_under</emphasis>
+; /* row to be overlayed in the section <emphasis>
+overlay</emphasis>
+ overlays */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ sz_keys</emphasis>
+; /* number of keys to reserve in the row */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomOverlayRow</emphasis>
+ adds one row to the <emphasis>
+overlay</emphasis>
+. The new row contains space for <emphasis>
+sz_keys</emphasis>
+ keys. If <emphasis>
+row_under</emphasis>
+ specifies a row that doesn’t exist on the underlying section, <emphasis>
+XkbAddGeomOverlayRow</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ and doesn’t change the overlay.<emphasis>
+ XkbAddGeomOverlayRow</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+ if any of the parameters is empty or if it was not able to allocate space for
+the overlay.
+</para>
+
+
+<para>
+To add a key to an existing overlay row, use <emphasis>
+XkbAddGeomOverlayKey</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbOverlayKeyPtr <emphasis>
+XkbAddGeomOverlayKey</emphasis>
+(<emphasis>
+overlay</emphasis>
+,<emphasis>
+ row, under</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbOverlayPtr <emphasis>
+ overlay</emphasis>
+; /* overlay to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row</emphasis>
+; /* row in overlay to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ under</emphasis>
+; /* primary name of the key to be considered */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddGeomOverlayKey</emphasis>
+ adds one key to the <emphasis>
+row</emphasis>
+ in the <emphasis>
+overlay</emphasis>
+. If there is no key named <emphasis>
+under</emphasis>
+ in the row of the underlying section, <emphasis>
+XkbAddGeomOverlayKey</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_geometry_components'>
+<title>Allocating and Freeing Geometry Components</title>
+
+<para>
+Xkb provides a number of functions to allocate and free subcomponents of a
+keyboard geometry. Use these functions to create or modify keyboard geometries.
+Note that these functions merely allocate space for the new element(s), and it
+is up to you to fill in the values explicitly in your code. These allocation
+functions increase <emphasis>
+sz_</emphasis>
+<emphasis>
+*</emphasis>
+ but never touch <emphasis>
+num_</emphasis>
+<emphasis>
+*</emphasis>
+ (unless there is an allocation failure, in which case they reset both
+<emphasis>
+sz_</emphasis>
+<emphasis>
+*</emphasis>
+ and <emphasis>
+num_</emphasis>
+<emphasis>
+*</emphasis>
+ to zero). These functions return <emphasis>
+Success</emphasis>
+ if they succeed, <emphasis>
+BadAlloc</emphasis>
+ if they are not able to allocate space, or <emphasis>
+BadValue</emphasis>
+ if a parameter is not as expected.
+</para>
+
+
+<para>
+To allocate space for an arbitrary number of outlines to a shape, use
+XkbAllocGeomOutlines.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomOutlines</emphasis>
+(<emphasis>
+shape</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbShapePtr <emphasis>
+shape</emphasis>
+; /* shape for which outlines should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new outlines required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomOutlines</emphasis>
+ allocates space for <emphasis>
+num_needed</emphasis>
+ outlines in the specified <emphasis>
+shape</emphasis>
+. The outlines are not initialized.
+</para>
+
+
+<para>
+To free geometry outlines, use <emphasis>
+XkbFreeGeomOutlines</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomOutlines</emphasis>
+(<emphasis>
+shape</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbShapePtr <emphasis>
+ shape</emphasis>
+; /* shape in which outlines should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first outline to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of outlines to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all outlines are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all outlines are freed regardless of the value of first or count. Otherwise,
+count outlines are freed beginning with the one specified by first.
+</para>
+
+
+<para>
+To allocate space for an arbitrary number of keys to a row, use
+XkbAllocGeomKeys.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomKeys</emphasis>
+(<emphasis>
+row</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row</emphasis>
+; /* row to which keys should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new keys required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomKeys</emphasis>
+ allocates num_needed keys and adds them to the row. No initialization of the
+keys is done.
+</para>
+
+
+<para>
+To free geometry keys, use <emphasis>
+XkbFreeGeomKeys</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomKeys</emphasis>
+(<emphasis>
+row</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row</emphasis>
+; /* row in which keys should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first key to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of keys to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all keys are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all keys are freed regardless of the value of first or count. Otherwise,
+count keys are freed beginning with the one specified by first.
+</para>
+
+
+<para>
+To allocate geometry properties, use <emphasis>
+XkbAllocGeomProps</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomProps</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry for which properties should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new properties required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomProps</emphasis>
+ allocates space for num_needed properties and adds them to the specified
+geometry <emphasis>
+geom</emphasis>
+. No initialization of the properties is done. A geometry property associates
+an arbitrary string with an equally arbitrary name. Geometry properties can be
+used to provide hints to programs that display images of keyboards, but they
+are not interpreted by Xkb. No other geometry structures refer to geometry
+properties.
+</para>
+
+
+<para>
+To free geometry properties, use <emphasis>
+XkbFreeGeomProperties</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomProperties</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry in which properties should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first property to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of properties to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all properties are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all properties are freed regardless of the value of first or count.
+Otherwise, count properties are freed beginning with the one specified by first.
+</para>
+
+
+<para>
+To allocate geometry key aliases, use <emphasis>
+XkbAllocGeomKeyAliases</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomKeyAliases</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry for which key aliases should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new key aliases required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomKeyAliases</emphasis>
+ allocates space for num_needed key aliases and adds them to the specified
+geometry <emphasis>
+geom</emphasis>
+. A key alias is a pair of strings that associates an alternate name for a key
+with the real name for that key.
+</para>
+
+
+<para>
+To free geometry key aliases, use <emphasis>
+XkbFreeGeomKeyAliases</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomKeyAliases</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ first</emphasis>
+, <emphasis>
+count</emphasis>
+, <emphasis>
+free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry in which key aliases should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first key alias to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of key aliases to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all key aliases are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all aliases in the top level of the specified geometry <emphasis>
+geom</emphasis>
+ are freed regardless of the value of first or count. Otherwise, count aliases
+in <emphasis>
+geom</emphasis>
+ are freed beginning with the one specified by first.
+</para>
+
+
+<para>
+To allocate geometry colors, use <emphasis>
+XkbAllocGeomColors</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomColors</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry for which colors should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new colors required. */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomColors</emphasis>
+ allocates space for num_needed colors and adds them to the specified geometry
+<emphasis>
+geom</emphasis>
+. A color name is a string whose interpretation is not specified by Xkb. All
+other geometry data structures refer to colors using their indices in this
+global list or pointers to colors in this list.
+</para>
+
+
+<para>
+To free geometry colors, use <emphasis>
+XkbFreeGeomColors</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomColors</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry in which colors should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first color to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of colors to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all colors are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all colors are freed regardless of the value of first or count. Otherwise,
+count colors are freed beginning with the one specified by first.
+</para>
+
+
+<para>
+To allocate points in an outline, use <emphasis>
+XkbAllocGeomPoints</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomPoints</emphasis>
+(<emphasis>
+outline</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbOutlinePtr <emphasis>
+ outline</emphasis>
+; /* outline for which points should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new points required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomPoints</emphasis>
+ allocates space for <emphasis>
+num_needed</emphasis>
+ points in the specified <emphasis>
+outline</emphasis>
+. The points are not initialized.
+</para>
+
+
+<para>
+To free points in a outline, use <emphasis>
+XkbFreeGeomPoints</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomPoints</emphasis>
+(<emphasis>
+outline</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbOutlinePtr <emphasis>
+ outline</emphasis>
+; /* outline in which points should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first point to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of points to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all points are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all points are freed regardless of the value of first and count. Otherwise,
+the number of points specified by count are freed, beginning with the point
+specified by first in the specified outline.
+</para>
+
+
+<para>
+To allocate space for an arbitrary number of geometry shapes, use <emphasis>
+XkbAllocGeomShapes</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomShapes</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry for which shapes should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new shapes required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomShapes</emphasis>
+ allocates space for <emphasis>
+num_needed</emphasis>
+ shapes in the specified geometry <emphasis>
+geom</emphasis>
+. The shapes are not initialized.
+</para>
+
+
+<para>
+To free geometry shapes, use <emphasis>
+XkbFreeGeomShapes</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomShapes</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ f ree_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry in which shapes should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first shape to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of shapes to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all shapes are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all shapes in the geometry are freed regardless of the values of first and
+count. Otherwise, count shapes are freed, beginning with the shape specified by
+first.
+</para>
+
+
+<para>
+To allocate geometry sections, use <emphasis>
+XkbAllocGeomSections</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomSections</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /*geometry for which sections should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new sections required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomSections</emphasis>
+ allocates num_needed sections and adds them to the geometry geom. No
+initialization of the sections is done.
+</para>
+
+
+<para>
+To free geometry sections, use <emphasis>
+XkbFreeGeomSections</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomSections</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry in which sections should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first section to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of sections to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all sections are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all sections are freed regardless of the value of first and count. Otherwise,
+the number of sections specified by count are freed, beginning with the section
+specified by first in the specified geometry.
+</para>
+
+
+<para>
+To allocate rows in a section, use <emphasis>
+XkbAllocGeomRows</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomRows</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+section</emphasis>
+; /* section for which rows should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new rows required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomRows</emphasis>
+ allocates num_needed rows and adds them to the section. No initialization of
+the rows is done.
+</para>
+
+
+<para>
+To free rows in a section, use <emphasis>
+XkbFreeGeomRows</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomRows</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section in which rows should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first row to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of rows to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all rows are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all rows are freed regardless of the value of first and count. Otherwise, the
+number of rows specified by count are freed, beginning with the row specified
+by first in the specified section.
+</para>
+
+
+<para>
+To allocate overlays in a section, use <emphasis>
+XkbAllocGeomOverlays</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomOverlays</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+section</emphasis>
+; /* section for which overlays should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new overlays required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomRows</emphasis>
+ allocates num_needed overlays and adds them to the section. No initialization
+of the overlays is done.
+</para>
+
+
+<para>
+To free rows in an section, use <emphasis>
+XkbFreeGeomOverlays</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomOverlays</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section in which overlays should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first overlay to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of overlays to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all overlays are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all overlays are freed regardless of the value of first and count. Otherwise,
+the number of overlays specified by count are freed, beginning with the overlay
+specified by first in the specified section.
+</para>
+
+
+<para>
+To allocate rows in a overlay, use <emphasis>
+XkbAllocGeomOverlayRows</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomOverlayRows</emphasis>
+(<emphasis>
+overlay</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+overlay</emphasis>
+; /* section for which rows should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new rows required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomOverlayRows</emphasis>
+ allocates num_needed rows and adds them to the overlay. No initialization of
+the rows is done.
+</para>
+
+
+<para>
+To free rows in an overlay, use <emphasis>
+XkbFreeGeomOverlayRows</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomOverlayRows</emphasis>
+(<emphasis>
+overlay</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ overlay</emphasis>
+; /* section in which rows should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first row to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of rows to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all rows are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all rows are freed regardless of the value of first and count. Otherwise, the
+number of rows specified by count are freed, beginning with the row specified
+by first in the specified overlay.
+</para>
+
+
+<para>
+To allocate keys in an overlay row, use <emphasis>
+XkbAllocGeomOverlayKeys</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomOverlayKeys</emphasis>
+(<emphasis>
+row</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+row</emphasis>
+; /* section for which rows should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new rows required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomOverlayKeys</emphasis>
+ allocates num_needed keys and adds them to the row. No initialization of the
+keys is done.
+</para>
+
+
+<para>
+To free keys in an overlay row, use <emphasis>
+XkbFreeGeomOverlayKeys</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomOverlayKeys</emphasis>
+(<emphasis>
+row</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRowPtr <emphasis>
+ row</emphasis>
+; /* row in which keys should be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ first</emphasis>
+; /* first key to be freed. */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of keys to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all keys are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, all keys are freed regardless of the value of first and count. Otherwise, the
+number of keys specified by count are freed, beginning with the key specified
+by first in the specified row.
+</para>
+
+
+<para>
+To allocate doodads that are global to a keyboard geometry, use <emphasis>
+XkbAllocGeomDoodads</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomDoodads</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry for which doodads should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new doodads required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomDoodads</emphasis>
+ allocates num_needed doodads and adds them to the specified geometry <emphasis>
+geom</emphasis>
+. No initialization of the doodads is done.
+</para>
+
+
+<para>
+To allocate doodads that are specific to a section, use <emphasis>
+XkbAllocGeomSectionDoodads</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeomSectionDoodads</emphasis>
+(<emphasis>
+section</emphasis>
+,<emphasis>
+ num_needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSectionPtr <emphasis>
+ section</emphasis>
+; /* section for which doodads should be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_needed</emphasis>
+; /* number of new doodads required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeomSectionDoodads</emphasis>
+ allocates num_needed doodads and adds them to the specified <emphasis>
+section</emphasis>
+. No initialization of the doodads is done.
+</para>
+
+
+<para>
+To free geometry doodads, use <emphasis>
+XkbFreeGeomDoodads</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeomDoodads</emphasis>
+(<emphasis>
+doodads</emphasis>
+,<emphasis>
+ count</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDoodadPtr <emphasis>
+ doodads</emphasis>
+; /* doodads to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ count</emphasis>
+; /* number of doodads to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; all doodads are freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If <emphasis>
+free_all</emphasis>
+ is <emphasis>
+True</emphasis>
+, all doodads in the array are freed, regardless of the value of count.
+Otherwise, count doodads are freed.
+</para>
+
+
+<para>
+To allocate an entire geometry, use <emphasis>
+XkbAllocGeometry</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocGeometry</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ sizes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description for which geometry is to be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometrySizesPtr<emphasis>
+ sizes</emphasis>
+; /* initial sizes for all geometry components */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocGeometry</emphasis>
+ allocates a keyboard geometry and adds it to the keyboard description
+specified by xkb. The keyboard description should be obtained via the
+XkbGetKeyboard or XkbAllockeyboard functions. The sizes parameter specifies the
+number of elements to be reserved for the subcomponents of the keyboard
+geometry and can be zero or more. These subcomponents include the properties,
+colors, shapes, sections, and doodads.
+</para>
+
+
+<para>
+To free an entire geometry, use <emphasis>
+XkbFreeGeometry</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeGeometry</emphasis>
+(<emphasis>
+geom</emphasis>
+,<emphasis>
+ which</emphasis>
+,<emphasis>
+ free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbGeometryPtr <emphasis>
+ geom</emphasis>
+; /* geometry to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ which</emphasis>
+; /* mask of geometry components to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all;</emphasis>
+ /* <emphasis>
+True</emphasis>
+ =&gt; the entire geometry is freed. */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The values of which and free_all determine how much of the specified geometry
+is freed. The valid values for which are:
+</para>
+
+<para><programlisting>
+#define XkbGeomPropertiesMask (1&lt;&lt;0)
+#define XkbGeomColorsMask (1&lt;&lt;1)
+#define XkbGeomShapesMask (1&lt;&lt;2)
+#define XkbGeomSectionsMask (1&lt;&lt;3)
+#define XkbGeomDoodadsMask (1&lt;&lt;4)
+#define XkbGeomAllMask (0x1f)
+</programlisting></para>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, the entire geometry is freed regardless of the value of which. Otherwise, the
+portions of the geometry specified by which are freed.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch14.xml b/libX11/specs/XKB/ch14.xml
new file mode 100644
index 000000000..cc376dba4
--- /dev/null
+++ b/libX11/specs/XKB/ch14.xml
@@ -0,0 +1,1637 @@
+<chapter id='xkb_keyboard_mapping'>
+<title>Xkb Keyboard Mapping</title>
+
+<para>
+The Xkb keyboard mapping contains all the information the server and clients
+need to interpret key events. This chapter provides an overview of the
+terminology used to describe an Xkb keyboard mapping and introduces common
+utilities for manipulating the keyboard mapping.
+</para>
+
+
+<para>
+The mapping consists of two components, a server map and a client map. The
+<emphasis>
+client</emphasis>
+ map is the collection of information a client needs to interpret key events
+from the keyboard. It contains a global list of key types and an array of key
+symbol maps, each of which describes the symbols bound to a key and the rules
+to be used to interpret those symbols. The <emphasis>
+server</emphasis>
+ map contains the information the server needs to interpret key events. This
+includes actions and behaviors for each key, explicit components for a key, and
+the virtual modifiers and the per-key virtual modifier mapping.
+</para>
+
+
+<para>
+For detailed information on particular components of the keyboard map, refer to
+Chapter 15, "Xkb Client Keyboard Mapping" and Chapter 16, "Xkb Server Keyboard
+Mapping."
+</para>
+
+<sect1 id='notation_and_terminology'>
+<title>Notation and Terminology</title>
+
+<para>
+The graphic characters or control functions that may be accessed by one key are
+logically arranged in groups and levels, where <emphasis>
+group</emphasis>
+ and <emphasis>
+level</emphasis>
+ are defined as in the ISO9995 standard:
+</para>
+
+<variablelist>
+ <varlistentry>
+ <term>Group:</term>
+ <listitem>
+ <para>
+A logical state of a keyboard providing access to a collection of
+graphic characters. Usually these graphic characters logically belong together
+and may be arranged on several levels within a group.
+ </para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>Level:</term>
+ <listitem>
+ <para>
+One of several states (normally 2 or 3) governing which graphic
+character is produced when a graphic key is actuated. In certain cases the
+level may also affect function keys.
+ </para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+
+<para>
+These definitions, taken from the ISO standard, refer to graphic keys and
+characters. In the context of Xkb, Group and Level are not constrained to
+graphic keys and characters; they may be used with any key to access any
+character the key is capable of generating.
+</para>
+
+
+<para>
+Level is often referred to as "Shift Level". Levels are numbered sequentially
+starting at one.
+</para>
+
+<note><para>Shift level is derived from the modifier state, but not necessarily
+in the same way for all keys. For example, the <emphasis>
+Shift</emphasis>
+ modifier selects shift level 2 on most keys, but for keypad keys the modifier
+bound to <emphasis>
+Num_Lock</emphasis>
+ (that is, the <emphasis>
+NumLock</emphasis>
+ virtual modifier) also selects shift level 2.</para></note>
+
+<para>
+For example, consider the following key (the gray characters indicate symbols
+that are implied or expected but are not actually engraved on the key):
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-14.svg"/>
+ </imageobject>
+<caption>Shift Levels and Groups</caption>
+ </mediaobject>
+
+
+<!--
+<H5 CLASS="Figure">
+Shift Levels and Groups</H5>
+-->
+
+<para>
+This key has two groups, indicated by the columns, and each group has two shift
+levels. For the first group (Group1), the symbol shift level one is <emphasis>
+a</emphasis>
+, and the symbol for shift level two is <emphasis>
+A</emphasis>
+. For the second group, the symbol for shift level one is <emphasis>
+æ</emphasis>
+, and the symbol for shift level two is <emphasis>
+Æ</emphasis>
+.
+</para>
+
+<sect2 id='core_implementation'>
+<title>Core Implementation</title>
+
+<para>
+The standard interpretation rules for the core X keymap only allow clients to
+access keys such as the one shown in Figure 14.1. That is, clients using the
+standard interpretation rules can only access one of four keysyms for any given
+<emphasis>
+KeyPress</emphasis>
+ event — two different symbols in two different groups.
+</para>
+
+
+<para>
+In general, the <emphasis>
+Shift</emphasis>
+ modifier, the <emphasis>
+Lock</emphasis>
+ modifier, and the modifier bound to the <emphasis>
+Num_Lock</emphasis>
+ key are used to change between shift level 1 and shift level 2. To switch
+between groups, the core implementation uses the modifier bound to the
+<emphasis>
+Mode_switch</emphasis>
+ key. When the <emphasis>
+Mode_switch</emphasis>
+ modifier is set, the keyboard is logically in Group 2. When the <emphasis>
+Mode_switch</emphasis>
+ modifier is not set, the keyboard is logically in Group 1.
+</para>
+
+
+<para>
+The core implementation does not clearly specify the behavior of keys. For
+example, the locking behavior of the <emphasis>
+CapsLock</emphasis>
+ and <emphasis>
+Num_Lock</emphasis>
+ keys depends on the vendor.
+</para>
+
+
+</sect2>
+<sect2 id='xkb_implementation'>
+<title>Xkb Implementation</title>
+
+<para>
+Xkb extends the core implementation by providing access to up to four keyboard
+groups with up to 63 shift levels per key
+<footnote><para>
+The core implementation restricts the number of symbols per key to 255.
+With four groups, this allows for up to 63 symbols (or shift levels) per
+group. Most keys will only have a few shift levels.
+</para></footnote>. In
+addition, Xkb provides precise specifications regarding the behavior of keys.
+In Xkb, modifier state and the current group are independent (with the
+exception of compatibility mapping, discussed in Chapter 17).
+</para>
+
+
+<para>
+Xkb handles switching between groups via key actions, independent of any
+modifier state information. Key actions are in the server map component and are
+described in detail in section 16.1.4.
+</para>
+
+
+<para>
+Xkb handles shift levels by associating a key type with each group on each key.
+Each key type defines the shift levels available for the groups on keys of its
+type and specifies the modifier combinations necessary to access each level.
+</para>
+
+
+<para>
+For example, Xkb allows key types where the <emphasis>
+Control</emphasis>
+ modifier can be used to access the shift level two of a key. Key types are in
+the client map component and are described in detail in section 15.2. <!-- xref -->
+</para>
+
+
+<para>
+Xkb provides precise specification of the behavior of a key using key
+behaviors. Key behaviors are in the server map component and are described in
+detail in section 16.2. <!-- xref -->
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='getting_map_components_from_the_server'>
+<title>Getting Map Components from the Server</title>
+
+<para>
+Xkb provides two functions to obtain the keyboard mapping components from the
+server. The first function, <emphasis>
+XkbGetMap</emphasis>
+, allocates an <emphasis>
+XkbDescRec</emphasis>
+ structure, retrieves mapping components from the server, and stores them in
+the <emphasis>
+XkbDescRec</emphasis>
+ structure it just allocated. The second function, <emphasis>
+XkbGetUpdatedMap</emphasis>
+, retrieves mapping components from the server and stores them in an <emphasis>
+XkbDescRec</emphasis>
+ structure that has previously been allocated.
+</para>
+
+
+<para>
+To allocate an <emphasis>
+XkbDescRec</emphasis>
+ structure and populate it with the server’s keyboard client map and server
+map, use <emphasis>
+XkbGetMap. XkbGetMap </emphasis>
+is similar to <emphasis>
+XkbGetKeyboard</emphasis>
+ (see section 6.2), but is used only for obtaining the address of an <emphasis>
+XkbDescRec</emphasis>
+ structure that is populated with keyboard mapping components. It allows finer
+control over which substructures of the keyboard mapping components are to be
+populated. <emphasis>
+XkbGetKeyboard</emphasis>
+ always returns fully populated components, while <emphasis>
+XkbGetMap</emphasis>
+ can be instructed to return a partially populated component.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDescPtr <emphasis>
+XkbGetMap</emphasis>
+(<emphasis>
+display, which, device_spec</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ which</emphasis>
+; /* mask selecting subcomponents to populate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ device_spec</emphasis>
+; /* device_id, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+which</emphasis>
+ mask is a bitwise inclusive OR of the masks defined in Table 14.1. Only those
+portions of the keyboard server map and the keyboard client maps that are
+specified in <emphasis>
+which</emphasis>
+ are allocated and populated.
+</para>
+
+
+<para>
+In addition to allocating and obtaining the server map and the client map,
+<emphasis>
+XkbGetMap</emphasis>
+ also sets the <emphasis>
+device_spec</emphasis>
+, the <emphasis>
+min_key_code</emphasis>
+<emphasis>
+, </emphasis>
+and <emphasis>
+max_key_code</emphasis>
+ fields of the keyboard description.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetMap</emphasis>
+ is synchronous; it queries the server for the desired information, waits for a
+reply, and then returns. If successful<emphasis>
+, XkbGetMap</emphasis>
+ returns a pointer to the <emphasis>
+XkbDescRec</emphasis>
+ structure it allocated. If unsuccessful, <emphasis>
+XkbGetMap</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+. When unsuccessful, one of the following protocol errors is also generated:
+<emphasis>
+BadAlloc</emphasis>
+ (unable to allocate the <emphasis>
+XkbDescRec</emphasis>
+ structure), <emphasis>
+BadValue</emphasis>
+ (some mask bits in <emphasis>
+which</emphasis>
+ are undefined)<emphasis>
+,</emphasis>
+ or <emphasis>
+BadImplementation</emphasis>
+ (a compatible version of the Xkb extension is not available in the server). To
+free the returned data, use <emphasis>
+XkbFreeClientMap</emphasis>
+.
+</para>
+
+
+<para>
+Xkb also provides convenience functions to get partial component definitions
+from the server. These functions are specified in the "convenience functions"
+column in Table 14.1. Refer to the sections listed in the table for more
+information on these functions.
+</para>
+
+<table frame='none'>
+<title>Xkb Mapping Component Masks and Convenience Functions</title>
+<tgroup cols='6'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Value</entry>
+ <entry>Map</entry>
+ <entry>Fields</entry>
+ <entry>Convenience Functions</entry>
+ <entry>Section</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyTypesMask</emphasis></entry>
+ <entry>(1&lt;&lt;0)</entry>
+ <entry>client</entry>
+ <entry>
+ <para><emphasis>types</emphasis></para>
+ <para><emphasis>size_types</emphasis></para>
+ <para><emphasis>num_types</emphasis></para>
+ </entry>
+ <entry>
+ <para><emphasis>XkbGetKeyTypes</emphasis></para>
+ <para><emphasis>XkbResizeKeyType</emphasis></para>
+ <para><emphasis>XkbCopyKeyType</emphasis></para>
+ <para><emphasis>XkbCopyKeyTypes</emphasis></para>
+ </entry>
+ <entry>15.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeySymsMask</emphasis></entry>
+ <entry>(1&lt;&lt;1)</entry>
+ <entry>client</entry>
+ <entry>
+ <para><emphasis>syms</emphasis></para>
+ <para><emphasis>size_syms</emphasis></para>
+ <para><emphasis>num_syms</emphasis></para>
+ <para><emphasis>key_sym_map</emphasis></para>
+ </entry>
+ <entry>
+ <para><emphasis>XkbGetKeySyms</emphasis></para>
+ <para><emphasis>XkbResizeKeySyms</emphasis></para>
+ <para><emphasis>XkbChangeTypesOfKey</emphasis></para>
+ </entry>
+ <entry>15.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbModifierMapMask</emphasis></entry>
+ <entry>(1&lt;&lt;2)</entry>
+ <entry>client</entry>
+ <entry><emphasis>modmap</emphasis></entry>
+ <entry><emphasis>XkbGetKeyModifierMap</emphasis></entry>
+ <entry>15.4</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbExplicitComponentsMask</emphasis></entry>
+ <entry>(1&lt;&lt;3)</entry>
+ <entry>server</entry>
+ <entry><emphasis>explicit</emphasis></entry>
+ <entry><emphasis>XkbGetKeyExplicitComponents</emphasis></entry>
+ <entry>16.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyActionsMask</emphasis></entry>
+ <entry>(1&lt;&lt;4)</entry>
+ <entry>server</entry>
+ <entry>
+ <para><emphasis>key_acts</emphasis></para>
+ <para><emphasis>acts</emphasis></para>
+ <para><emphasis>num_acts</emphasis></para>
+ <para><emphasis>size_acts</emphasis></para>
+ </entry>
+ <entry>
+ <para><emphasis>XkbGetKeyActions</emphasis></para>
+ <para><emphasis>XkbResizeKeyActions</emphasis></para>
+ </entry>
+ <entry>16.1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyBehaviorsMask</emphasis></entry>
+ <entry>(1&lt;&lt;5)</entry>
+ <entry>server</entry>
+ <entry><emphasis>behaviors</emphasis></entry>
+ <entry><emphasis>XkbGetKeyBehaviors</emphasis></entry>
+ <entry>16.2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbVirtualModsMask</emphasis></entry>
+ <entry>(1&lt;&lt;6)</entry>
+ <entry>server</entry>
+ <entry><emphasis>vmods</emphasis></entry>
+ <entry><emphasis>XkbGetVirtualMods</emphasis></entry>
+ <entry>16.4</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbVirtualModMapMask</emphasis></entry>
+ <entry>(1&lt;&lt;7)</entry>
+ <entry>server</entry>
+ <entry><emphasis>vmodmap</emphasis></entry>
+ <entry><emphasis>XkbGetVirtualModMap</emphasis></entry>
+ <entry>16.4</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Xkb defines combinations of these masks for convenience:
+</para>
+
+<para><programlisting>
+#define XkbResizableInfoMask (XkbKeyTypesMask)
+#define XkbAllClientInfoMask (XkbKeyTypesMask | XkbKeySymsMask |
+ XkbModifierMapMask)
+#define XkbAllServerInfoMask (XkbExplicitComponentsMask |
+ XkbKeyActionsMask| XkbKeyBehaviorsMask |
+ XkbVirtualModsMask | XkbVirtualModMapMask)
+#define XkbAllMapComponentsMask (XkbAllClientInfoMask|XkbAllServerInfoMask)
+</programlisting></para>
+
+<para>
+Key types, symbol maps, and actions are all interrelated: changes in one
+require changes in the others. The convenience functions make it easier to edit
+these components and handle the interdependencies.
+</para>
+
+
+<para>
+To update the client or server map information in an existing keyboard
+description, use <emphasis>XkbGetUpdatedMap</emphasis>.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetUpdatedMap</emphasis>
+(<emphasis>
+display, which, xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask selecting subcomponents to populate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description to be updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+which</emphasis>
+ parameter is a bitwise inclusive OR of the masks in Table 14.1. If the needed
+components of the <emphasis>
+xkb</emphasis>
+ structure are not already allocated, <emphasis>
+XkbGetUpdatedMap</emphasis>
+ allocates them. <emphasis>
+XkbGetUpdatedMap</emphasis>
+ fetches the requested information for the device specified in the <emphasis>
+XkbDescRec</emphasis>
+ passed in the <emphasis>
+xkb</emphasis>
+ parameter.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetUpdatedMap</emphasis>
+ is synchronous; it queries the server for the desired information, waits for a
+reply, and then returns. If successful<emphasis>
+, XkbGetUpdatedMap</emphasis>
+ returns <emphasis>
+Success</emphasis>
+. If unsuccessful, <emphasis>
+XkbGetUpdatedMap</emphasis>
+ returns one of the following: <emphasis>
+BadAlloc</emphasis>
+ (unable to allocate a component in the <emphasis>
+XkbDescRec</emphasis>
+ structure), <emphasis>
+BadValue</emphasis>
+ (some mask bits in <emphasis>
+which</emphasis>
+ are undefined), <emphasis>
+BadImplementation</emphasis>
+ (a compatible version of the Xkb extension is not available in the server or
+the reply from the server was invalid).
+</para>
+
+</sect1>
+<sect1 id='changing_map_components_in_the_server'>
+<title>Changing Map Components in the Server</title>
+
+<para>
+There are two ways to make changes to map components: either change a local
+copy of the keyboard map and call <emphasis>
+XkbSetMap</emphasis>
+ to send the modified map to the server, or, to reduce network traffic, use
+an<emphasis>
+ XkbMapChangesRec</emphasis>
+ structure and call <emphasis>XkbChangeMap</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ which</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask selecting subcomponents to update */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* description from which new values are taken */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+Use <emphasis>
+XkbSetMap</emphasis>
+ to send a complete new set of values for entire components (for example, all
+symbols, all actions, and so on) to the server. The <emphasis>
+which</emphasis>
+ parameter specifies the components to be sent to the server, and is a bitwise
+inclusive OR of the masks listed in Table 14.1. The <emphasis>
+xkb</emphasis>
+ parameter is a pointer to an <emphasis>
+XkbDescRec</emphasis>
+ structure and contains the information to be copied to the server. For each
+bit set in the <emphasis>
+which</emphasis>
+ parameter, <emphasis>
+XkbSetMap</emphasis>
+ takes the corresponding structure values from the <emphasis>
+xkb</emphasis>
+ parameter and sends it to the server specified by <emphasis>
+dpy</emphasis>.
+</para>
+
+<para>
+If any components specified by <emphasis>
+which</emphasis>
+ are not present in the <emphasis>
+xkb</emphasis>
+ parameter, <emphasis>
+XkbSetMap</emphasis>
+ returns <emphasis>
+False</emphasis>
+. Otherwise, it sends the update request to the server and returns <emphasis>
+True</emphasis>
+. <emphasis>
+XkbSetMap</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadLength</emphasis>
+, and <emphasis>
+BadValue</emphasis>
+ protocol errors.
+</para>
+
+
+<para>
+Key types, symbol maps, and actions are all interrelated; changes in one
+require changes in the others. Xkb provides functions to make it easier to edit
+these components and handle the interdependencies. Table 14.1 lists these
+helper functions and provides a pointer to where they are defined.
+</para>
+
+
+<sect2 id='the_xkbmapchangesrec_structure'>
+<title>The XkbMapChangesRec Structure</title>
+
+<para>
+Use the <emphasis>
+XkbMapChangesRec</emphasis>
+ structure to identify and track partial modifications to the mapping
+components and to reduce the amount of traffic between the server and clients.
+</para>
+
+<para><programlisting>
+typedef struct _XkbMapChanges {
+ unsigned short changed; /* identifies valid components
+ in structure */
+ KeyCode min_key_code; /* lowest numbered keycode for
+ device */
+ KeyCode max_key_code; /* highest numbered keycode for
+ device */
+ unsigned char first_type; /* index of first key <emphasis>type</emphasis>
+ modified */
+ unsigned char num_types; /* # types modified */
+ KeyCode first_key_sym; /* first key whose <emphasis>key_sym_map</emphasis>
+ changed */
+ unsigned char num_key_syms; /* # <emphasis>key_sym_map</emphasis>
+ entries changed */
+ KeyCode first_key_act; /* first key whose <emphasis>key_acts</emphasis>
+ entry changed */
+ unsigned char num_key_acts; /* # <emphasis>key_acts</emphasis>
+ entries changed */
+ KeyCode first_key_behavior; /* first key whose <emphasis>behaviors</emphasis>
+ changed */
+ unsigned char num_key_behaviors; /* # <emphasis>behaviors</emphasis>
+ entries changed */
+ KeyCode first_key_explicit; /* first key whose <emphasis>explicit</emphasis>
+ entry changed */
+ unsigned char num_key_explicit; /* # <emphasis> explicit</emphasis>
+ entries changed */
+ KeyCode first_modmap_key; /* first key whose <emphasis>modmap</emphasis>
+ entry changed */
+ unsigned char num_modmap_keys; /* # <emphasis>modmap</emphasis>
+ entries changed */
+ KeyCode first_vmodmap_key; /* first key whose <emphasis>vmodmap</emphasis>
+ changed */
+ unsigned char num_vmodmap_keys; /* # <emphasis> vmodmap</emphasis>
+ entries changed */
+ unsigned char pad1; /* reserved */
+ unsigned short vmods; /* mask indicating which <emphasis>vmods</emphasis>
+ changed */
+} <emphasis>XkbMapChangesRec</emphasis>,*XkbMapChangesPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed</emphasis>
+ field identifies the map components that have changed in an <emphasis>
+XkbDescRec</emphasis>
+ structure and may contain any of the bits in Table 14.1, which are also shown
+in Table 14.2. Every 1 bit in <emphasis>
+changed</emphasis>
+ also identifies which other fields in the <emphasis>
+XkbMapChangesRec</emphasis>
+ structure contain valid values, as indicated in Table 14.2. The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields are for reference only; they are ignored on any requests sent to the
+server and are always updated by the server whenever it returns the data for an
+<emphasis>
+XkbMapChangesRec</emphasis>
+.
+</para>
+
+<table frame='none'>
+<title>XkbMapChangesRec Masks</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Valid XkbMapChangesRec Fields</entry>
+ <entry>XkbDescRec Field Containing Changed Data</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyTypesMask</emphasis></entry>
+ <entry>
+<para>first_type</para>,
+<para>num_types</para>
+ </entry>
+ <entry>
+<para>map-&gt;type[first_type] ..</para>
+<para>map-&gt;type[first_type + num_types - 1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeySymsMask</emphasis></entry>
+ <entry>
+<para>first_key_sym</para>,
+<para>num_key_syms</para>
+ </entry>
+ <entry>
+<para>map-&gt;key_sym_map[first_key_sym] ..</para>
+<para>map-&gt;key_sym_map[first_key_sym + num_key_syms - 1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbModifierMapMask</emphasis></entry>
+ <entry>
+<para>first_modmap_key</para>,
+<para>num_modmap_keys</para>
+ </entry>
+ <entry>
+<para>map-&gt;modmap[first_modmap_key] ..</para>
+<para>map-&gt;modmap[first_modmap_key + num_modmap_keys-1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbExplicitComponentsMask</emphasis></entry>
+ <entry>
+<para>first_key_explicit</para>,
+<para>num_key_explicit</para>
+ </entry>
+ <entry>
+<para>server-&gt;explicit[first_key_explicit] ..</para>
+<para>server-&gt;explicit[first_key_explicit + num_key_explicit - 1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyActionsMask</emphasis></entry>
+ <entry>
+<para>first_key_act,</para>
+<para>num_key_acts</para>
+ </entry>
+ <entry>
+<para>server-&gt;key_acts[first_key_act] ..</para>
+<para>server-&gt;key_acts[first_key_act + num_key_acts - 1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKeyBehaviorsMask</emphasis></entry>
+ <entry>
+<para>first_key_behavior,</para>
+<para>num_key_behaviors</para>
+ </entry>
+ <entry>
+<para>server-&gt;behaviors[first_key_behavior] ..</para>
+<para>server-&gt;behaviors[first_key_behavior + num_key_behaviors - 1]</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbVirtuawModsMask</emphasis></entry>
+ <entry>vmods</entry>
+ <entry>server-&gt;vmods[*]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbVirtualModMapMask</emphasis></entry>
+ <entry>
+<para>first_vmodmap_key,</para>
+<para>num_vmodmap_keys</para>
+ </entry>
+ <entry>
+<para>server-&gt;vmodmap[first_vmodmap_key] ..</para>
+<para>server-&gt;vmodmap[first_vmodmap_key + num_vmodmap_keys - 1]</para>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+To update only partial components of a keyboard description, modify the
+appropriate fields in the server and map components of a local copy of the
+keyboard description, then call <emphasis>
+XkbChangeMap</emphasis>
+ with an <emphasis>
+XkbMapChangesRec</emphasis>
+ structure indicating which components have changed.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+,<emphasis>
+ changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* description from which new values are taken */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbMapChangesPtr <emphasis>
+ changes</emphasis>
+; /*identifies component parts to update */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeMap</emphasis>
+ copies any components specified by the <emphasis>
+changes</emphasis>
+ structure from the keyboard description, <emphasis>
+xkb</emphasis>
+, to the X server specified by <emphasis>
+dpy</emphasis>
+.
+</para>
+
+
+<para>
+If any components specified by <emphasis>
+changes</emphasis>
+ are not present in the <emphasis>
+xkb</emphasis>
+ parameter, <emphasis>
+XkbChangeMap</emphasis>
+ returns <emphasis>
+False</emphasis>
+. Otherwise, it sends a request to the server and returns <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbChangeMap</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadLength</emphasis>
+, and <emphasis>
+BadValue</emphasis>
+ protocol errors.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='tracking_changes_to_map_components'>
+<title>Tracking Changes to Map Components</title>
+
+<para>
+The Xkb extension reports <emphasis>
+XkbMapNotify</emphasis>
+ events to clients wanting notification whenever a map component of the Xkb
+description for a device changes. There are many different types of Xkb
+keyboard map changes. Xkb uses an event detail mask to identify each type of
+change. The event detail masks are identical to the masks listed in Table 14.1.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbMapNotify</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) and pass <emphasis>
+XkbMapNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbMapNotify</emphasis>
+ events only under certain conditions, use <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbMapNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying the desired map changes in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ using mask bits from Table 14.1.
+</para>
+
+
+<para>
+The structure for <emphasis>
+XkbMapNotify</emphasis>
+ events is:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis>True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis> XkbMapNotify</emphasis> */
+ int device; /* Xkb device ID, will not be <emphasis>XkbUseCoreKbd</emphasis> */
+ unsigned int changed; /* identifies valid fields in rest of event */
+ unsigned int resized; /* reserved */
+ int first_type; /* index of first key <emphasis> type</emphasis> modified */
+ int num_types /* # types modified */
+ KeyCode min_key_code; /* minimum keycode for device */
+ KeyCode max_key_code; /* maximum keycode for device */
+ KeyCode first_key_sym; /* first key whose <emphasis>key_sym_map</emphasis> changed */
+ KeyCode first_key_act; /* first key whose <emphasis> key_acts</emphasis> entry changed */
+ KeyCode first_key_behavior; /* first key whose <emphasis> behaviors</emphasis> changed */
+ KeyCode first_key_explicit; /* first key whose <emphasis> explicit </emphasis> entry changed */
+ KeyCode first_modmap_key; /* first key whose <emphasis> modmap</emphasis> entry changed */
+ KeyCode first_vmodmap_key; /* # <emphasis> modmap</emphasis> entries changed */
+ int num_key_syms; /* # <emphasis>key_sym_map</emphasis> entries changed */
+ int num_key_acts; /* # <emphasis> key_acts</emphasis> entries changed */
+ int num_key_behaviors; /* # <emphasis> behaviors</emphasis> entries changed */
+ int num_key_explicit; /* # <emphasis> explicit</emphasis> entries changed */
+ int num_modmap_keys; /* # <emphasis> modmap</emphasis> entries changed */
+ int num_vmodmap_keys; /* # <emphasis> vmodmap</emphasis> entries changed */
+ unsigned in t vmods; /* mask indicating which <emphasis> vmods</emphasis> changed */
+} <emphasis>XkbMapNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed</emphasis>
+ field specifies the map components that have changed and is the bitwise
+inclusive OR of the mask bits defined in Table 14.1. The other fields in this
+event are interpreted as the like-named fields in an <emphasis>
+XkbMapChangesRec</emphasis>
+ (see section 14.3.1). The <emphasis>
+XkbMapNotifyEvent</emphasis>
+ structure also has an additional <emphasis>
+resized</emphasis>
+ field that is reserved for future use.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_client_and_server_maps'>
+<title>Allocating and Freeing Client and Server Maps</title>
+
+<para>
+Calling <emphasis>
+XkbGetMap</emphasis>
+ (see section 14.2) should be sufficient for most applications to get client
+and server maps. As a result, most applications do not need to directly
+allocate client and server maps.
+</para>
+
+
+<para>
+If you change the number of key types or construct map components without
+loading the necessary components from the X server, do not allocate any map
+components directly using <emphasis>
+malloc</emphasis>
+ or <emphasis>
+Xmalloc</emphasis>
+. Instead, use the Xkb allocators, <emphasis>
+XkbAllocClientMap,</emphasis>
+ and <emphasis>
+XkbAllocServerMap</emphasis>
+.
+</para>
+
+
+<para>
+Similarly, use the Xkb destructors, <emphasis>
+XkbFreeClientMap,</emphasis>
+ and <emphasis>
+XkbFreeServerMap</emphasis>
+ instead of <emphasis>
+free</emphasis>
+ or <emphasis>
+Xfree</emphasis>
+.
+</para>
+
+
+<sect2 id='allocating_an_empty_client_map'>
+<title>Allocating an Empty Client Map</title>
+
+<para>
+To allocate and initialize an empty client map description record, use
+<emphasis>
+XkbAllocClientMap.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocClientMap</emphasis>
+(<emphasis>
+xkb, which, type_count</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description in which to allocate client map */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask selecting map components to allocate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ type_count</emphasis>
+; /* value of <emphasis>
+num_types</emphasis>
+ field in map to be allocated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocClientMap</emphasis>
+ allocates and initializes an empty client map in the <emphasis>
+map</emphasis>
+ field of the keyboard description specified by <emphasis>
+xkb</emphasis>
+. The <emphasis>
+which</emphasis>
+ parameter specifies the particular components of the client map structure to
+allocate and is a mask composed by a bitwise inclusive OR of one or more of the
+masks shown in Table 14.3.
+</para>
+
+<table frame='none'>
+<title>XkbAllocClientMap Masks</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Effect</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbKeyTypesMask</entry>
+ <entry>
+The <emphasis>
+type_count </emphasis>
+field specifies the number of entries to preallocate for the <emphasis>
+types</emphasis>
+ field of the client map. If the <emphasis>
+type_count </emphasis>
+field is less than <emphasis>
+XkbNumRequiredTypes</emphasis>
+ (see section 15.2.1), returns <emphasis>
+BadValue</emphasis>.
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbKeySymsMask</entry>
+<entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter are used to allocate the <emphasis>
+syms</emphasis>
+ and <emphasis>
+key_sym_map</emphasis>
+ fields of the client map. The fields are allocated to contain the maximum
+number of entries necessary for <emphasis>
+max_key_code</emphasis>
+ - <emphasis>
+min_key_code</emphasis>
+ + 1 keys.
+</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbModifierMapMask</entry>
+<entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter are used to allocate the <emphasis>
+modmap</emphasis>
+ field of the client map. The field is allocated to contain the maximum number
+of entries necessary for <emphasis>
+max_key_code</emphasis>
+ - <emphasis>
+min_key_code</emphasis>
+ + 1 keys.
+</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<note><para>The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter must be legal values if the <emphasis>
+XkbKeySymsMask</emphasis>
+ or <emphasis>
+XkbModifierMapMask</emphasis>
+ masks are set in the <emphasis>
+which</emphasis>
+ parameter. If they are not valid, <emphasis>
+XkbAllocClientMap</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. </para></note>
+
+<para>
+If the client map of the keyboard description is not <emphasis>
+NULL</emphasis>
+, and any fields are already allocated in the client map, <emphasis>
+XkbAllocClientMap</emphasis>
+ does not overwrite the existing values; it simply ignores that part of the
+request. The only exception is the <emphasis>
+types</emphasis>
+ array. If <emphasis>
+type_count</emphasis>
+ is greater than the current <emphasis>
+num_types</emphasis>
+ field of the client map, <emphasis>
+XkbAllocClientMap</emphasis>
+ resizes the <emphasis>
+types</emphasis>
+ array and resets the <emphasis>
+num_types</emphasis>
+ field accordingly.
+</para>
+
+
+<para>
+If <emphasis>
+XkbAllocClientMap</emphasis>
+ is successful, it returns <emphasis>
+Success</emphasis>
+. Otherwise, it can return either <emphasis>
+BadMatch</emphasis>
+, <emphasis>
+BadAlloc</emphasis>
+, or <emphasis>
+BadValue</emphasis>
+ errors.
+</para>
+
+
+</sect2>
+<sect2 id='freeing_a_client_map'>
+<title>Freeing a Client Map</title>
+
+<para>
+To free memory used by the client map member of an <emphasis>
+XkbDescRec</emphasis>
+ structure, use <emphasis>
+XkbFreeClientMap.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeClientMap</emphasis>
+(<emphasis>
+xkb, which, free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description containing client map to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask identifying components of map to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free all client components and map itself */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbFreeClientMap</emphasis>
+ frees the components of client map specified by <emphasis>
+which</emphasis>
+ in the <emphasis>
+XkbDescRec</emphasis>
+ structure specified by the <emphasis>
+xkb</emphasis>
+ parameter and sets the corresponding structure component values to <emphasis>
+NULL</emphasis>
+. The <emphasis>
+which</emphasis>
+ parameter specifies a combination of the client map masks shown in Table 14.3.
+</para>
+
+
+<para>
+If <emphasis>
+free_all</emphasis>
+ is <emphasis>
+True</emphasis>
+, <emphasis>
+which</emphasis>
+ is ignored; <emphasis>
+XkbFreeClientMap</emphasis>
+ frees every non-<emphasis>
+NULL</emphasis>
+ structure component in the client map, frees the <emphasis>
+XkbClientMapRec</emphasis>
+ structure referenced by the <emphasis>
+map</emphasis>
+ member of the <emphasis>
+xkb</emphasis>
+ parameter, and sets the <emphasis>
+map</emphasis>
+ member to <emphasis>
+NULL.</emphasis>
+</para>
+
+
+</sect2>
+<sect2 id='allocating_an_empty_server_map'>
+<title>Allocating an Empty Server Map</title>
+
+<para>
+To allocate and initialize an empty server map description record, use
+<emphasis>
+XkbAllocServerMap.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocServerMap</emphasis>
+(<emphasis>
+xkb, which, count_acts</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description in which to allocate server map */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask selecting map components to allocate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ count_acts</emphasis>
+; /* value of <emphasis>
+num_acts</emphasis>
+ field in map to be allocated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocServerMap</emphasis>
+ allocates and initializes an empty server map in the <emphasis>
+server</emphasis>
+ field of the keyboard description specified by <emphasis>
+xkb</emphasis>
+. The <emphasis>
+which</emphasis>
+ parameter specifies the particular components of the server map structure to
+allocate, as specified in Table 14.4.
+</para>
+
+<table frame='none'>
+<title>XkbAllocServerMap Masks</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Effect</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbExplicitComponentsMask</entry>
+ <entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter are used to allocate the <emphasis>
+explicit </emphasis>
+field of the server map.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbKeyActionsMask</entry>
+ <entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter are used to allocate the <emphasis>
+key_acts </emphasis>
+field of the server map. The <emphasis>
+count_acts</emphasis>
+ parameter is used to allocate the <emphasis>
+acts</emphasis>
+ field of the server map.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbKeyBehaviorsMask</entry>
+ <entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter are used to allocate the <emphasis>
+behaviors </emphasis>
+field of the server map.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbVirtualModMapMask</entry>
+ <entry>
+The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb </emphasis>
+parameter are used to allocate the <emphasis>
+vmodmap </emphasis>
+field of the server map.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<note><para>The <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ fields of the <emphasis>
+xkb</emphasis>
+ parameter must be legal values. If they are not valid, <emphasis>
+XkbAllocServerMap</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. </para></note>
+
+<para>
+If the server map of the keyboard description is not <emphasis>
+NULL</emphasis>
+ and any fields are already allocated in the server map, <emphasis>
+XkbAllocServerMap</emphasis>
+ does not overwrite the existing values. The only exception is with the
+<emphasis>
+acts </emphasis>
+array. If the <emphasis>
+count_acts </emphasis>
+parameter is greater than the current <emphasis>
+num_acts </emphasis>
+field of the server map, <emphasis>
+XkbAllocServerMap</emphasis>
+ resizes the <emphasis>
+acts </emphasis>
+array and resets the <emphasis>
+num_acts </emphasis>
+field accordingly.
+</para>
+
+
+<para>
+If <emphasis>
+XkbAllocServerMap</emphasis>
+ is successful, it returns <emphasis>
+Success</emphasis>
+. Otherwise, it can return either <emphasis>
+BadMatch</emphasis>
+ or <emphasis>
+BadAlloc</emphasis>
+ errors.
+</para>
+
+
+</sect2>
+<sect2 id='freeing_a_server_map'>
+<title>Freeing a Server Map</title>
+
+<para>
+To free memory used by the server member of an <emphasis>
+XkbDescRec</emphasis>
+ structure, use <emphasis>
+XkbFreeServerMap.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeServerMap</emphasis>
+(<emphasis>
+xkb, which, free_all</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description containing server map to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask identifying components of map to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_all</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free all server map components and server itself */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+XkbFreeServerMap</emphasis>
+ function frees the specified components of server map in the <emphasis>
+XkbDescRec</emphasis>
+ structure specified by the <emphasis>
+xkb</emphasis>
+ parameter and sets the corresponding structure component values to <emphasis>
+NULL</emphasis>
+. The <emphasis>
+which</emphasis>
+ parameter specifies a combination of the server map masks and is a bitwise
+inclusive OR of the masks listed in Table 14.4. If <emphasis>
+free_all</emphasis>
+ is <emphasis>
+True</emphasis>
+, <emphasis>
+which</emphasis>
+ is ignored and <emphasis>
+XkbFreeServerMap</emphasis>
+ frees every non-<emphasis>
+NULL</emphasis>
+ structure component in the server map, frees the <emphasis>
+XkbServerMapRec</emphasis>
+ structure referenced by the <emphasis>
+server</emphasis>
+ member of the <emphasis>
+xkb</emphasis>
+ parameter, and sets the <emphasis>
+server</emphasis>
+ member to <emphasis>
+NULL.</emphasis>
+</para>
+
+</sect2>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch15.xml b/libX11/specs/XKB/ch15.xml
new file mode 100644
index 000000000..25ee61f5f
--- /dev/null
+++ b/libX11/specs/XKB/ch15.xml
@@ -0,0 +1,2600 @@
+<chapter id='xkb_client_keyboard_mapping'>
+<title>Xkb Client Keyboard Mapping</title>
+
+<para>
+The Xkb client map for a keyboard is the collection of information a client
+needs to interpret key events from the keyboard. It contains a global list of
+key types and an array of key symbol maps, each of which describes the symbols
+bound to a key and the rules to be used to interpret those symbols.
+</para>
+
+
+<para>
+Figure 15.1 shows the relationships between elements in the client map:
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-15.svg"/>
+ </imageobject>
+<caption>Xkb Client Map</caption>
+ </mediaobject>
+
+
+<!--
+<H5 CLASS="Figure">
+Xkb Client Map</H5>
+-->
+
+<sect1 id='the_xkbclientmaprec_structure'>
+<title>The XkbClientMapRec Structure</title>
+
+<para>
+The <emphasis>
+map </emphasis>
+field of the complete Xkb keyboard description (see section 6.1) is a pointer
+to the Xkb client map, which is of type <emphasis>
+XkbClientMapRec</emphasis>
+:
+</para>
+
+<para><programlisting>
+typedef struct { /* Client Map */
+ unsigned char size_types; /* # occupied entries in <emphasis> types</emphasis> */
+ unsigned char num_types; /* # entries in <emphasis>types</emphasis> */
+ XkbKeyTypePtr types; /* vector of key types used by this keymap */
+ unsigned short size_syms; /* length of the <emphasis>syms</emphasis> array */
+ unsigned short num_syms; /* # entries in <emphasis>syms</emphasis> */
+ KeySym * syms; /* linear 2d tables of keysyms, 1 per key */
+ XkbSymMapPtr key_sym_map; /* 1 per keycode, maps keycode to <emphasis>syms</emphasis> */
+ unsigned char * modmap; /* 1 per keycode, real mods bound to key */
+} <emphasis>XkbClientMapRec</emphasis>, *XkbClientMapPtr;
+</programlisting></para>
+
+<para>
+The following sections describe each of the elements of the <emphasis>
+XkbClientMapRec</emphasis>
+ structure in more detail.
+</para>
+
+
+</sect1>
+<sect1 id='key_types'>
+<title>Key Types</title>
+
+<para>
+Key types are used to determine the shift level of a key given the current
+state of the keyboard. The set of all possible key types for the Xkb keyboard
+description are held in the <emphasis>
+types</emphasis>
+ field of the client map, whose total size is stored in <emphasis>
+size_types</emphasis>
+, and whose total number of valid entries is stored in <emphasis>
+num_types</emphasis>
+. Key types are defined using the following structures:
+</para>
+
+<para><programlisting>
+typedef struct { /* Key Type */
+ XkbModsRec mods; /* modifiers used to compute shift
+ level */
+ unsigned char num_levels; /* total # shift levels, do not
+ modify directly */
+ unsigned char map_count; /* # entries in <emphasis>map</emphasis>,
+ <emphasis> preserve</emphasis>
+ (if non-<emphasis> NULL</emphasis>) */
+ XkbKTMapEntryPtr map; /* vector of modifiers for each
+ shift level */
+ XkbModsPtr preserve; /* mods to preserve for corresponding
+ <emphasis>map</emphasis> entry */
+ Atom name; /* name of key type */
+ Atom * level_names; /* array of names of each shift level */
+} <emphasis>XkbKeyTypeRec</emphasis>, *XkbKeyTypePtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct { /* Modifiers for a key type */
+ Bool active; /* <emphasis> True</emphasis> =&gt; entry
+ active when determining shift level */
+ unsigned char level; /* shift level if modifiers match <emphasis> mods</emphasis> */
+ XkbModsRec mods; /* mods needed for this level to be
+ selected */
+} <emphasis>XkbKTMapEntryRec</emphasis>,*XkbKTMapEntryPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+mods</emphasis>
+ field of a key type is an <emphasis>
+XkbModsRec</emphasis>
+ (see section 7.2) specifying the modifiers the key type uses when calculating
+the shift level, and can be composed of both the core modifiers and virtual
+modifiers. To set the modifiers associated with a key type, modify the
+<emphasis>
+real_mods</emphasis>
+ and <emphasis>
+vmods</emphasis>
+ fields of the <emphasis>
+mods</emphasis>
+ <emphasis>
+XkbModsRec</emphasis>
+ accordingly. The <emphasis>
+mask</emphasis>
+ field of the <emphasis>
+XkbModsRec</emphasis>
+ is reserved for use by Xkb and is calculated from the <emphasis>
+real_mods</emphasis>
+ and <emphasis>
+vmods</emphasis>
+ fields.
+</para>
+
+
+<para>
+The <emphasis>
+num_levels</emphasis>
+ field holds the total number of shift levels for the key type. Xkb uses
+<emphasis>
+num_levels</emphasis>
+ to ensure the array of symbols bound to a key is large enough. Do not modify
+<emphasis>
+num_levels</emphasis>
+ directly to change the number if shift levels for a key type. Instead, use
+<emphasis>
+XkbResizeKeyType</emphasis>
+ (see section 15.2.3).
+</para>
+
+
+<para>
+The <emphasis>
+map</emphasis>
+ field is a vector of <emphasis>
+XkbKTMapEntryRec</emphasis>
+ structures, with <emphasis>
+map_count</emphasis>
+ entries, that specify the modifier combinations for each possible shift level.
+Each map entry contains an <emphasis>
+active</emphasis>
+ field, a <emphasis>
+mods</emphasis>
+ field, and a <emphasis>
+level</emphasis>
+ field. The <emphasis>
+active</emphasis>
+ field determines whether the modifier combination listed in the <emphasis>
+mods</emphasis>
+ field should be considered when determining shift level. If <emphasis>
+active</emphasis>
+ is <emphasis>
+False</emphasis>
+, this <emphasis>
+map</emphasis>
+ entry is ignored. If <emphasis>
+active</emphasis>
+ is <emphasis>
+True</emphasis>
+, the <emphasis>
+level</emphasis>
+ field of the <emphasis>
+map </emphasis>
+entry specifies the shift level to use when the current modifier combination
+matches the combination specified in the <emphasis>
+mods</emphasis>
+ field of the <emphasis>
+map</emphasis>
+ entry.
+</para>
+
+
+<para>
+Any combination of modifiers not explicitly listed somewhere in the <emphasis>
+map</emphasis>
+ yields shift level one. In addition, <emphasis>
+map</emphasis>
+ entries specifying unbound virtual modifiers are not considered.
+</para>
+
+
+<para>
+Any modifiers specified in <emphasis>
+mods</emphasis>
+ are normally <emphasis>
+consumed</emphasis>
+ by <emphasis>
+XkbTranslateKeyCode</emphasis>
+ (see section 12.1.3). For those rare occasions a modifier <emphasis>
+should</emphasis>
+ be considered despite having been used to look up a symbol, key types include
+an optional <emphasis>
+preserve</emphasis>
+ field. If a <emphasis>
+preserve</emphasis>
+ member of a key type is not <emphasis>
+NULL</emphasis>
+, it represents a list of modifiers where each entry corresponds directly to
+one of the key type’s <emphasis>
+map</emphasis>
+. Each entry lists the modifiers that should <emphasis>
+not</emphasis>
+ be consumed if the matching map entry is used to determine shift level.
+</para>
+
+
+<para>
+Each shift level has a name and these names are held in the <emphasis>
+level_names</emphasis>
+ array, whose length is <emphasis>
+num_levels</emphasis>
+. The type itself also has a name, which is held in the <emphasis>
+name</emphasis>
+ field.
+</para>
+
+
+<para>
+For example, consider how the server handles the following possible symbolic
+description of a possible key type (note that the format used to specify
+keyboard mappings in the server database is not specified by the Xkb extension,
+although this format is one possible example):
+</para>
+
+<table frame='none'>
+<title>Example Key Type</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Symbolic Description</entry>
+ <entry>Key Type Data Structure</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>type "ALPHATHREE" {</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].name</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>modifiers = Shift+Lock+LevelThree;</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].mods</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>map[None]= Level1;</emphasis></entry>
+ <entry>Xkb-&gt;map-&gt;types[i].map[0]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>map[Lock]= Level1;</emphasis></entry>
+ <entry>Xkb-&gt;map-&gt;types[i].map[1]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>map[Shift]= Level2;</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].map[2]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>map[LevelThree]= Level3;</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].map[3]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>map[Shift+LevelThree]= Level3;</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].map[4]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>preserve[None]= None;</emphasis></entry>
+ <entry>Xkb-&gt;map-&gt;types[i].perserve[0]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>preserve[Lock]= Lock;</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].preserve[1]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>preserve[Shift]= None;</emphasis></entry>
+ <entry>Xkb-&gt;map-&gt;types[i].preserve[2]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>preserve[LevelThree]= None;</emphasis></entry>
+ <entry>Xkb-&gt;map-&gt;types[i].preserve[3]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>preserve[Shift+Level3]= None;</emphasis> </entry>
+ <entry>Xkb-&gt;map-&gt;types[i].preserve[4]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>level_name[Level1]= "Base";</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].level_names[0]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>level_name[Level2]= "Caps";</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].level_names[1]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>level_name[Level3]= "Level3";</entry>
+ <entry>Xkb-&gt;map-&gt;types[i].level_names[2]</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>};</entry>
+ <entry></entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+name</emphasis>
+ of the example key type is "ALPHATHREE," and the modifiers it pays attention
+to are <emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, and the virtual modifier <emphasis>
+LevelThree</emphasis>
+. There are three shift levels. The name of shift level one is "Base," the name
+of shift level two is "Caps," and the name of shift level three is "Level3."
+</para>
+
+
+<para>
+Given the combination of the <emphasis>
+map</emphasis>
+ and <emphasis>
+preserve</emphasis>
+ specifications, there are five <emphasis>
+map</emphasis>
+ entries. The first map entry specifies that shift level one is to be used if
+no modifiers are set. The second entry specifies the <emphasis>
+Lock</emphasis>
+ modifier alone also yields shift level one. The third entry specifies the
+<emphasis>
+Shift</emphasis>
+ modifier alone yields shift level two. The fourth and fifth entries specify
+that the virtual <emphasis>
+LevelThree</emphasis>
+ modifier alone, or in combination with the <emphasis>
+Shift</emphasis>
+ modifier, yields shift level three.
+</para>
+
+<note><para>Shift level three can be reached only if the virtual modifier
+<emphasis>
+LevelThree</emphasis>
+ is bound to a real modifier (see section 16.4). If <emphasis>
+LevelThree</emphasis>
+ is not bound to a real modifier, the <emphasis>
+map</emphasis>
+ entries associated with it are ignored.</para></note>
+
+<para>
+Because the <emphasis>
+Lock</emphasis>
+ modifier is to be preserved for further event processing, the <emphasis>
+preserve</emphasis>
+ list is not <emphasis>
+NULL</emphasis>
+ and parallels the <emphasis>
+map</emphasis>
+ list. All <emphasis>
+preserve</emphasis>
+ entries, except for the one corresponding to the <emphasis>
+map</emphasis>
+ entry that specifies the <emphasis>
+Lock </emphasis>
+modifier, do not list any modifiers. For the <emphasis>
+map</emphasis>
+ entry that specifies the <emphasis>
+Lock</emphasis>
+ modifier, the corresponding <emphasis>
+preserve</emphasis>
+ list entry lists the <emphasis>
+Lock</emphasis>
+ modifier, meaning do not consume the <emphasis>
+Lock</emphasis>
+ modifier. In this particular case, the preserved modifier is passed to Xlib
+translation functions and causes them to notice that the <emphasis>
+Lock</emphasis>
+ modifier is set; consequently, the Xlib functions apply the appropriate
+capitalization rules to the symbol. Because this preserve entry is set only for
+a modifier that yields shift level one, the capitalization occurs only for
+level-one symbols.
+</para>
+
+
+<sect2 id='the_canonical_key_types'>
+<title>The Canonical Key Types</title>
+
+<para>
+Xkb allows up to <emphasis>
+XkbMaxKeyTypes</emphasis>
+ (255) key types to be defined, but requires at least <emphasis>
+XkbNumRequiredTypes</emphasis>
+ (4) predefined types to be in a key map. These predefined key types are
+referred to as the canonical key types and describe the types of keys available
+on most keyboards. The definitions for the canonical key types are held in the
+first <emphasis>
+XkbNumRequiredTypes</emphasis>
+ entries of the <emphasis>
+types</emphasis>
+ field of the client map and are indexed using the following constants:
+</para>
+
+<para><programlisting>
+ <emphasis>XkbOneLevelIndex</emphasis>
+ <emphasis>XkbTwoLevelIndex</emphasis>
+ <emphasis>XkbAlphabeticIndex</emphasis>
+ <emphasis>XkbKeypadIndex</emphasis>
+</programlisting></para>
+
+<sect3 id='one_level'>
+<title>ONE_LEVEL</title>
+
+<para>
+The ONE_LEVEL key type describes groups that have only one symbol. The default
+ONE_LEVEL key type has no map entries and does not pay attention to any
+modifiers. A symbolic representation of this key type could look like the
+following:
+</para>
+
+<literallayout>
+type "ONE_LEVEL" {
+ modifiers = None;
+ map[None]= Level1;
+ level_name[Level1]= "Any";
+};
+</literallayout>
+
+<para>
+The description of the ONE_LEVEL key type is stored in the <emphasis>
+types</emphasis>
+[<emphasis>
+XkbOneLevelIndex</emphasis>
+] entry of the client key map.
+</para>
+
+
+</sect3>
+<sect3 id='two_level'>
+<title>TWO_LEVEL</title>
+
+<para>
+The TWO_LEVEL key type describes groups that consist of two symbols but are
+neither alphabetic nor numeric keypad keys. The default TWO_LEVEL type uses
+only the <emphasis>
+Shift</emphasis>
+ modifier. It returns shift level two if <emphasis>
+Shift</emphasis>
+ is set, and level one if it is not. A symbolic representation of this key type
+could look like the following:
+</para>
+
+<literallayout>
+type "TWO_LEVEL" {
+ modifiers = Shift;
+ map[Shift]= Level2;
+ level_name[Level1]= "Base";
+ level_name[Level2]= "Shift";
+};
+</literallayout>
+
+<para>
+The description of the TWO_LEVEL key type is stored in the <emphasis>
+types</emphasis>
+[<emphasis>
+XkbTwoLevelIndex</emphasis>
+] entry of the client key map.
+</para>
+
+
+</sect3>
+<sect3 id='alphabetic'>
+<title>ALPHABETIC</title>
+
+<para>
+The ALPHABETIC key type describes groups consisting of two symbols: the
+lowercase form of a symbol followed by the uppercase form of the same symbol.
+The default ALPHABETIC type implements locale-sensitive "Shift cancels
+CapsLock" behavior using both the <emphasis>
+Shift</emphasis>
+ and <emphasis>
+Lock</emphasis>
+ modifiers as follows:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+If <emphasis>
+Shift</emphasis>
+ and <emphasis>
+Lock</emphasis>
+ are both set, the default ALPHABETIC type yields level one.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If <emphasis>
+Shift</emphasis>
+ alone is set, it yields level two.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If <emphasis>
+Lock</emphasis>
+ alone is set, it yields level one, but preserves the <emphasis>
+Lock</emphasis>
+ modifier so Xlib notices and applies the appropriate capitalization rules. The
+Xlib functions are locale-sensitive and apply different capitalization rules
+for different locales.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If neither <emphasis>
+Shift</emphasis>
+ nor <emphasis>
+Lock</emphasis>
+ is set, it yields level one.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+A symbolic representation of this key type could look like the following:
+</para>
+
+<literallayout>
+type "ALPHABETIC" {
+ modifiers = Shift+Lock;
+ map[Shift]= Level2;
+ preserve[Lock]= Lock;
+ level_name[Level1]= "Base";
+ level_name[Level2]= "Caps";
+};
+</literallayout>
+
+<para>
+The description of the ALPHABETIC key type is stored in the <emphasis>
+types</emphasis>
+[<emphasis>
+XkbAlphabeticIndex</emphasis>
+] entry of the client key map.
+</para>
+
+
+</sect3>
+<sect3 id='keypad'>
+<title>KEYPAD</title>
+
+<para>
+The KEYPAD key type describes groups that consist of two symbols, at least one
+of which is a numeric keypad symbol. The numeric keypad symbol is assumed to
+reside at level two. The default KEYPAD key type implements "Shift cancels
+NumLock" behavior using the Shift modifier and the real modifier bound to the
+virtual modifier named "NumLock," known as the <emphasis>
+NumLock</emphasis>
+ modifier, as follows:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+If <emphasis>
+Shift</emphasis>
+ and <emphasis>
+NumLock</emphasis>
+ are both set, the default KEYPAD type yields level one.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If <emphasis>
+Shift</emphasis>
+ alone is set, it yields level two.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If <emphasis>
+NumLock</emphasis>
+ alone is set, it yields level two.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If neither <emphasis>
+Shift</emphasis>
+ nor <emphasis>
+NumLock</emphasis>
+ is set, it yields level one.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+A symbolic representation of this key type could look like the following:
+</para>
+
+<literallayout>
+type "KEYPAD" {
+ modifiers = Shift+NumLock;
+ map[None]= Level1;
+ map[Shift]= Level2;
+ map[NumLock]= Level2;
+ map[Shift+NumLock]= Level1;
+ level_name[Level1]= "Base";
+ level_name[Level2]= "Caps";
+};
+</literallayout>
+
+<para>
+The description of the KEYPAD key type is stored in the <emphasis>
+types</emphasis>
+[<emphasis>
+XkbKeypadIndex</emphasis>
+] entry of the client key map.
+</para>
+
+
+</sect3>
+<sect3 id='initializing_the_canonical_key_types_in_a_new_client_map'>
+<title>Initializing the Canonical Key Types in a New Client Map</title>
+
+<para>
+To set the definitions of the canonical key types in a client map to their
+default values, use <emphasis>
+XkbInitCanonicalKeyTypes.</emphasis>
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbInitCanonicalKeyTypes</emphasis>
+(<emphasis>
+xkb, which, keypadVMod</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description containing client map to initialize */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of types to initialize */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+keypadVMod</emphasis>
+; /* index of NumLock virtual modifier */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbInitCanonicalKeyTypes</emphasis>
+ initializes the first <emphasis>
+XkbNumRequiredTypes</emphasis>
+ key types of the keyboard specified by the <emphasis>
+xkb</emphasis>
+ parameter to their default values. The <emphasis>
+which</emphasis>
+ parameter specifies what canonical key types to initialize and is a bitwise
+inclusive OR of the following masks: <emphasis>
+XkbOneLevelMask</emphasis>
+, <emphasis>
+XkbTwoLevelMask</emphasis>
+, <emphasis>
+XkbAlphabeticMask</emphasis>
+, and <emphasis>
+XkbKeypadMask</emphasis>
+. Only those canonical types specified by the <emphasis>
+which</emphasis>
+ mask are initialized.
+</para>
+
+
+<para>
+If <emphasis>
+XkbKeypadMask</emphasis>
+ is set in the <emphasis>
+which</emphasis>
+ parameter, <emphasis>
+XkbInitCanonicalKeyTypes</emphasis>
+ looks up the <emphasis>
+NumLock</emphasis>
+ named virtual modifier to determine which virtual modifier to use when
+initializing the KEYPAD key type. If the <emphasis>
+NumLock</emphasis>
+ virtual modifier does not exist, <emphasis>
+XkbInitCanonicalKeyTypes</emphasis>
+ creates it.
+</para>
+
+
+<para>
+<emphasis>
+XkbInitCanonicalKeyTypes</emphasis>
+ normally returns Success. It returns <emphasis>
+BadAccess</emphasis>
+ if the Xkb extension has not been properly initialized, and <emphasis>
+BadAccess</emphasis>
+ if the <emphasis>
+xkb</emphasis>
+ parameter is not valid.
+</para>
+
+
+
+</sect3>
+</sect2>
+<sect2 id='getting_key_types_from_the_server'>
+<title>Getting Key Types from the Server</title>
+
+<para>
+To obtain the list of available key types in the server’s keyboard mapping,
+use <emphasis>
+XkbGetKeyTypes</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyTypes</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ first</emphasis>
+; /* index to first type to get, 0 =&gt; 1st type */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* number of key types to be returned */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description containing client map to update */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+<note><para><emphasis>
+XkbGetKeyTypes</emphasis>
+ is used to obtain descriptions of the key types themselves, not the key types
+bound to individual keys. To obtain the key types bound to an individual key,
+refer to the <emphasis>
+key_sym_map</emphasis>
+ field of the client map (see section 15.3.1).</para></note>
+
+<para>
+<emphasis>
+XkbGetKeyTypes</emphasis>
+ queries the server for the desired types, waits for a reply, and returns the
+desired types in the <emphasis>
+xkb-&gt;map-&gt;types</emphasis>
+. If successful, it returns Success.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetKeyTypes</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+ if the Xkb extension has not been properly initialized and <emphasis>
+BadValue</emphasis>
+ if the combination of <emphasis>
+first</emphasis>
+ and <emphasis>
+num</emphasis>
+ results in numbers out of valid range.
+</para>
+
+
+</sect2>
+<sect2 id='changing_the_number_of_levels_in_a_key_type'>
+<title>Changing the Number of Levels in a Key Type</title>
+
+<para>
+To change the number of levels in a key type, use <emphasis>
+XkbResizeKeyType</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbResizeKeyType</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ type_ndx</emphasis>
+,<emphasis>
+ map_count</emphasis>
+,<emphasis>
+ want_preserve</emphasis>
+,<emphasis>
+ new_num_lvls</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr<emphasis>
+ xkb</emphasis>
+; /* keyboard description containing client map to update */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ type_ndx</emphasis>
+; /* index in xkb-&gt;map-&gt;types of type to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+map_count</emphasis>
+; /* total # of map entries needed for the type */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+want_preserve</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; list of preserved modifiers is necessary */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ new_num_lvls</emphasis>
+; /* new max # of levels for type */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbResizeKeyType</emphasis>
+ changes the type specified by <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+map-&gt;types</emphasis>
+[<emphasis>
+type_ndx</emphasis>
+], and reallocates the symbols and actions bound to all keys that use the type,
+if necessary. <emphasis>
+XkbResizeKeyType</emphasis>
+ updates only the local copy of the types in <emphasis>
+xkb</emphasis>
+; to update the server’s copy for the physical device, use <emphasis>
+XkbSetMap</emphasis>
+ or <emphasis>
+XkbChangeMap</emphasis>
+ after calling <emphasis>
+XkbResizeKeyType</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+map_count</emphasis>
+ parameter specifies the total number of map entries needed for the type, and
+can be zero or greater. If <emphasis>
+map_count</emphasis>
+ is zero, <emphasis>
+XkbResizeKeyType</emphasis>
+ frees the existing <emphasis>
+map</emphasis>
+ and <emphasis>
+preserve</emphasis>
+ entries for the type if they exist and sets them to <emphasis>
+NULL</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+want_preserve</emphasis>
+ parameter specifies whether a <emphasis>
+preserve</emphasis>
+ list for the key should be created. If <emphasis>
+want_preserve</emphasis>
+ is <emphasis>
+True</emphasis>
+, the <emphasis>
+preserve</emphasis>
+ list with <emphasis>
+map_count</emphasis>
+ entries is allocated or reallocated if it already exists. Otherwise, if
+<emphasis>
+want_preserve</emphasis>
+ is <emphasis>
+False</emphasis>
+, the <emphasis>
+preserve</emphasis>
+ field is freed if necessary and set to <emphasis>
+NULL</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+new_num_lvls</emphasis>
+ parameter specifies the new maximum number of shift levels for the type and is
+used to calculate and resize the symbols and actions bound to all keys that use
+the type.
+</para>
+
+
+<para>
+If <emphasis>
+type_ndx</emphasis>
+ does not specify a legal type, <emphasis>
+new_num_lvls</emphasis>
+ is less than 1, or the <emphasis>
+map_count</emphasis>
+ is less than zero, <emphasis>
+XkbResizeKeyType</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If <emphasis>
+XkbResizeKeyType</emphasis>
+ encounters any problems with allocation, it returns <emphasis>
+BadAlloc</emphasis>
+. Otherwise, it returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='copying_key_types'>
+<title>Copying Key Types</title>
+
+<para>
+Use <emphasis>
+XkbCopyKeyType</emphasis>
+ and <emphasis>
+XkbCopyKeyTypes</emphasis>
+ to copy one or more <emphasis>
+XkbKeyTypeRec</emphasis>
+ structures.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbCopyKeyType</emphasis>
+(<emphasis>
+from</emphasis>
+,<emphasis>
+ into</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbKeyTypePtr <emphasis>
+ from</emphasis>
+; /* pointer to XkbKeyTypeRec to be copied */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbKeyTypePtr <emphasis>
+ into</emphasis>
+; /* pointer to XkbKeyTypeRec to be changed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbCopyKeyType</emphasis>
+ copies the key type specified by <emphasis>
+from</emphasis>
+ to the key type specified by <emphasis>
+into</emphasis>
+. Both must point to legal <emphasis>
+XkbKeyTypeRec</emphasis>
+ structures. Xkb assumes <emphasis>
+from</emphasis>
+ and <emphasis>
+into</emphasis>
+ point to different places. As a result, overlaps can be fatal. <emphasis>
+XkbCopyKeyType</emphasis>
+ frees any existing <emphasis>
+map</emphasis>
+, <emphasis>
+preserve</emphasis>
+, and <emphasis>
+level_names</emphasis>
+ in <emphasis>
+into</emphasis>
+ prior to copying. If any allocation errors occur while copying <emphasis>
+from</emphasis>
+ to <emphasis>
+into</emphasis>
+, <emphasis>
+XkbCopyKeyType</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+. Otherwise, <emphasis>
+XkbCopyKeyType</emphasis>
+ copies <emphasis>
+from</emphasis>
+ to <emphasis>
+into</emphasis>
+ and returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbCopyKeyTypes</emphasis>
+(<emphasis>
+from</emphasis>
+,<emphasis>
+ into</emphasis>
+, <emphasis>
+num_types</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbKeyTypePtr <emphasis>
+ from</emphasis>
+; /* pointer to array of XkbKeyTypeRecs to copy */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbKeyTypePtr <emphasis>
+ into</emphasis>
+; /* pointer to array of XkbKeyTypeRecs to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_types</emphasis>
+; /* number of types to copy */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbCopyKeyTypes</emphasis>
+ copies <emphasis>
+num_types</emphasis>
+ <emphasis>
+XkbKeyTypeRec</emphasis>
+ structures from the array specified by <emphasis>
+from</emphasis>
+ into the array specified by <emphasis>
+into</emphasis>
+. It is intended for copying between, rather than within, keyboard
+descriptions, so it doesn’t check for overlaps. The same rules that apply to
+the <emphasis>
+from</emphasis>
+ and <emphasis>
+into</emphasis>
+ parameters in <emphasis>
+XkbCopyKeyType</emphasis>
+ apply to each entry of the <emphasis>
+from</emphasis>
+ and <emphasis>
+into</emphasis>
+ arrays of <emphasis>
+XkbCopyKeyTypes</emphasis>
+. If any allocation errors occur while copying <emphasis>
+from</emphasis>
+ to <emphasis>
+into</emphasis>
+, <emphasis>
+XkbCopyKeyTypes</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+. Otherwise, <emphasis>
+XkbCopyKeyTypes</emphasis>
+ copies <emphasis>
+from</emphasis>
+ to <emphasis>
+into</emphasis>
+ and returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='key_symbol_map'>
+<title>Key Symbol Map</title>
+
+<para>
+The entire list of key symbols for the keyboard mapping is held in the
+<emphasis>
+syms</emphasis>
+ field of the client map. Whereas the core keyboard mapping is a
+two-dimensional array of <emphasis>
+KeySyms</emphasis>
+ whose rows are indexed by keycode, the <emphasis>
+syms</emphasis>
+ field of Xkb is a linear list of <emphasis>
+KeySyms</emphasis>
+ that needs to be indexed uniquely for each key. This section describes the key
+symbol map and the methods for determining the symbols bound to a key.
+</para>
+
+
+<para>
+The reason the <emphasis>
+syms</emphasis>
+ field is a linear list of <emphasis>
+KeySyms</emphasis>
+ is to reduce the memory consumption associated with a keymap; because Xkb
+allows individual keys to have multiple shift levels and a different number of
+groups per key, a single two-dimensional array of <emphasis>
+KeySyms</emphasis>
+ would potentially be very large and sparse. Instead, Xkb provides a small
+two-dimensional array of <emphasis>
+KeySyms</emphasis>
+ for each key. To store all of these individual arrays, Xkb concatenates each
+array together in the <emphasis>
+syms</emphasis>
+ field of the client map.
+</para>
+
+
+<para>
+In order to determine which <emphasis>
+KeySyms</emphasis>
+ in the <emphasis>
+syms</emphasis>
+ field are associated with each keycode, the client map contains an array of
+key symbol mappings, held in the <emphasis>
+key_sym_map</emphasis>
+ field. The <emphasis>
+key_sym_map</emphasis>
+ field is an array of <emphasis>
+XkbSymMapRec</emphasis>
+ structures indexed by keycode. The <emphasis>
+key_sym_map</emphasis>
+ array has <emphasis>
+min_key_code</emphasis>
+ unused entries at the start to allow direct indexing using a keycode. All
+keycodes falling between the minimum and maximum legal keycodes, inclusive,
+have <emphasis>
+key_sym_map</emphasis>
+ arrays, whether or not any key actually yields that code. The <emphasis>
+KeySymMapRec</emphasis>
+ structure is defined as follows:
+</para>
+
+<para><programlisting>
+#define XkbNumKbdGroups 4
+#define XkbMaxKbdGroup (XkbNumKbdGroups-1)
+</programlisting></para>
+
+<para><programlisting>
+typedef struct { /* map to keysyms for a single keycode */
+ unsigned char kt_index[XkbNumKbdGroups]; /* key type index for each group */
+ unsigned char group_info; /* # of groups and out of range group handling */
+ unsigned char width; /* max # of shift levels for key */
+ unsigned short offset; /* index to keysym table in <emphasis> syms</emphasis> array */
+} <emphasis>XkbSymMapRec</emphasis>, *XkbSymMapPtr;
+</programlisting></para>
+
+<para>
+These fields are described in detail in the following sections.
+</para>
+
+
+<sect2 id='per_key_key_type_indices'>
+<title>Per-Key Key Type Indices</title>
+
+<para>
+The <emphasis>
+kt_index</emphasis>
+ array of the <emphasis>
+XkbSymMapRec</emphasis>
+ structure contains the indices of the key types (see section 15.2) for each
+possible group of symbols associated with the key. To obtain the index of a key
+type or the pointer to a key type, Xkb provides the following macros, to access
+the key types:
+</para>
+
+<note><para>The array of key types is of fixed width and is large enough to
+hold key types for the maximum legal number of groups (<emphasis>
+XkbNumKbdGroups</emphasis>
+, currently four); if a key has fewer than <emphasis>
+XkbNumKbdGroups</emphasis>
+ groups, the extra key types are reported but ignored.</para></note>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyTypeIndex</emphasis>
+(<emphasis>
+xkb, keycode, group</emphasis>
+) /* macro*/
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+group</emphasis>
+; /* group index */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyTypeIndex</emphasis>
+ computes an index into the <emphasis>
+types</emphasis>
+ vector of the client map in <emphasis>
+xkb</emphasis>
+ from the given <emphasis>
+keycode</emphasis>
+ and <emphasis>
+group</emphasis>
+ index.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbKeyTypePtr <emphasis>
+XkbKeyType</emphasis>
+(<emphasis>
+xkb, keycode, group</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+group</emphasis>
+; /* group index */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyType</emphasis>
+ returns a pointer to the key type in the <emphasis>
+types</emphasis>
+ vector of the client map in <emphasis>
+xkb</emphasis>
+ corresponding to the given <emphasis>
+keycode</emphasis>
+ and <emphasis>
+group</emphasis>
+ index.
+</para>
+
+
+</sect2>
+<sect2 id='per_key_group_information'>
+<title>Per-Key Group Information</title>
+
+<para>
+The <emphasis>
+group_info</emphasis>
+ field of an <emphasis>
+XkbSymMapRec</emphasis>
+ is an encoded value containing the number of groups of symbols bound to the
+key as well as the specification of the treatment of out-of-range groups. It is
+legal for a key to have zero groups, in which case it also has zero symbols and
+all events from that key yield <emphasis>
+NoSymbol</emphasis>
+. To obtain the number of groups of symbols bound to the key, use <emphasis>
+XkbKeyNumGroups</emphasis>
+. To change the number of groups bound to a key, use <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ (see section 15.3.6). To obtain a mask that determines the treatment of
+out-of-range groups, use <emphasis>
+XkbKeyGroupInfo</emphasis>
+ and <emphasis>
+XkbOutOfRangeGroupInfo</emphasis>
+.
+</para>
+
+
+<para>
+The keyboard controls (see Chapter 10) contain a <emphasis>
+groups_wrap</emphasis>
+ field specifying the handling of illegal groups on a global basis. That is,
+when the user performs an action causing the effective group to go out of the
+legal range, the <emphasis>
+groups_wrap</emphasis>
+ field specifies how to normalize the effective keyboard group to a group that
+is legal for the keyboard as a whole, but there is no guarantee that the
+normalized group will be within the range of legal groups for any individual
+key. The per-key <emphasis>
+group_info</emphasis>
+ field specifies how a key treats a legal effective group if the key does not
+have a type specified for the group of concern. For example, the <emphasis>
+Enter</emphasis>
+ key usually has just one group defined. If the user performs an action causing
+the global keyboard group to change to <emphasis>
+Group2</emphasis>
+, the <emphasis>
+group_info</emphasis>
+ field for the <emphasis>
+Enter</emphasis>
+ key describes how to handle this situation.
+</para>
+
+
+<para>
+Out-of-range groups for individual keys are mapped to a legal group using the
+same options as are used for the overall keyboard group. The particular type of
+mapping used is controlled by the bits set in the <emphasis>
+group_info</emphasis>
+ flag, as shown in Table 15.2. See section 10.7.1 for more details on the
+normalization methods in this table.
+</para>
+
+<table frame='none'>
+<title>group_info Range Normalization</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Bits set in group_info</entry>
+ <entry>Normalization method</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbRedirectIntoRange</entry>
+ <entry>XkbRedirectIntoRange</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbClampIntoRange</entry>
+ <entry>XkbClampIntoRange</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>none of the above</entry>
+ <entry>XkbWrapIntoRange</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Xkb provides the following macros to access group information:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyNumGroups</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyNumGroups</emphasis>
+ returns the number of groups of symbols bound to the key corresponding to
+<emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned char <emphasis>
+XkbKeyGroupInfo</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /*macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyGroupInfo</emphasis>
+ returns the <emphasis>
+group_info</emphasis>
+ field from the <emphasis>
+XkbSymMapRec</emphasis>
+ structure associated with the key corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned char <emphasis>
+XkbOutOfRangeGroupInfo</emphasis>
+(<emphasis>
+grp_inf</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned char <emphasis>
+grp_inf</emphasis>
+; /* group_info field of <emphasis>
+XkbSymMapRec</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbOutOfRangeGroupInfo</emphasis>
+ returns only the out-of-range processing information from the <emphasis>
+group_info</emphasis>
+ field of an <emphasis>
+XkbSymMapRec</emphasis>
+ structure.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned char <emphasis>
+XkbOutOfRangeGroupNumber</emphasis>
+(<emphasis>
+grp_inf</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned char <emphasis>
+grp_inf</emphasis>
+; /* group_info field of <emphasis>
+XkbSymMapRec</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbOutOfRangeGroupNumber</emphasis>
+ returns the out-of-range group number, represented as a group index, from the
+<emphasis>
+group_info</emphasis>
+ field of an <emphasis>
+XkbSymMapRec</emphasis>
+ structure.
+</para>
+
+
+</sect2>
+<sect2 id='key_width'>
+<title>Key Width</title>
+
+<para>
+The maximum number of shift levels for a type is also referred to as the width
+of a key type. The <emphasis>
+width</emphasis>
+ field of the <emphasis>
+key_sym_map</emphasis>
+ entry for a key contains the width of the widest type associated with the key.
+The <emphasis>
+width </emphasis>
+field cannot be explicitly changed; it is updated automatically whenever the
+symbols or set of types bound to a key are changed.
+</para>
+
+
+</sect2>
+<sect2 id='offset_in_to_the_symbol_map'>
+<title>Offset in to the Symbol Map</title>
+
+<para>
+The key width and number of groups associated with a key are used to form a
+small two-dimensional array of <emphasis>
+KeySyms</emphasis>
+ for a key. This array may be different sizes for different keys. The array for
+a single key is stored as a linear list, in row-major order. The arrays for all
+of the keys are stored in the <emphasis>
+syms</emphasis>
+ field of the client map. There is one row for each group associated with a key
+and one column for each level. The index corresponding to a given group and
+shift level is computed as:
+</para>
+
+<literallayout>
+ idx = group_index * key_width + shift_level
+</literallayout>
+
+<para>
+The <emphasis>
+offset</emphasis>
+ field of the <emphasis>
+key_sym_map</emphasis>
+ entry for a key is used to access the beginning of the array.
+</para>
+
+
+<para>
+Xkb provides the following macros for accessing the <emphasis>
+width</emphasis>
+ and <emphasis>
+offset</emphasis>
+ for individual keys, as well as macros for accessing the two-dimensional array
+of symbols bound to the key:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyGroupsWidth</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyGroupsWidth</emphasis>
+ computes the maximum width associated with the key corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyGroupWidth</emphasis>
+(<emphasis>
+xkb, keycode, grp</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+grp</emphasis>
+; /* group of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyGroupWidth</emphasis>
+ computes the width of the type associated with the group <emphasis>
+grp</emphasis>
+ for the key corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeySymsOffset</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeySymsOffset</emphasis>
+ returns the offset of the two-dimensional array of keysyms for the key
+corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyNumSyms</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyNumSyms</emphasis>
+ returns the total number of keysyms for the key corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+KeySym * <emphasis>
+XkbKeySymsPtr</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeySymsPtr</emphasis>
+ returns the pointer to the two-dimensional array of keysyms for the key
+corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+KeySym <emphasis>
+XkbKeySymEntry</emphasis>
+(<emphasis>
+xkb, keycode, shift, grp</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+shift</emphasis>
+; /* shift level of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+grp</emphasis>
+; /* group of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeySymEntry</emphasis>
+ returns the <emphasis>
+keysym</emphasis>
+ corresponding to shift level <emphasis>
+shift</emphasis>
+ and group <emphasis>
+grp</emphasis>
+ from the two-dimensional array of keysyms for the key corresponding to
+<emphasis>
+keycode</emphasis>
+</para>
+
+
+</sect2>
+<sect2 id='getting_the_symbol_map_for_keys_from_the_server'>
+<title>Getting the Symbol Map for Keys from the Server</title>
+
+<para>
+To obtain the symbols for a subset of the keys in a keyboard description, use
+<emphasis>
+XkbGetKeySyms</emphasis>
+:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeySyms</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+, <emphasis>
+num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ first</emphasis>
+; /* keycode of first key to get */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ num</emphasis>
+; /* number of keycodes for which syms desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description to be updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeySyms</emphasis>
+ sends a request to the server to obtain the set of keysyms bound to <emphasis>
+num</emphasis>
+ keys starting with the key whose keycode is <emphasis>
+first</emphasis>
+. It waits for a reply and returns the keysyms in the <emphasis>
+map.syms</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+. If successful, <emphasis>
+XkbGetKeySyms</emphasis>
+ returns <emphasis>
+Success</emphasis>
+. The <emphasis>
+xkb</emphasis>
+ parameter must be a pointer to a valid Xkb keyboard description.
+</para>
+
+
+<para>
+If the client <emphasis>
+map</emphasis>
+ in the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeySyms</emphasis>
+ allocates and initializes it before obtaining the symbols.
+</para>
+
+
+<para>
+If a compatible version of Xkb is not available in the server or the Xkb
+extension has not been properly initialized, <emphasis>
+XkbGetKeySyms</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If <emphasis>
+num</emphasis>
+ is less than 1 or greater than <emphasis>
+XkbMaxKeyCount</emphasis>
+, <emphasis>
+XkbGetKeySyms</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If any allocation errors occur, <emphasis>
+XkbGetKeySyms</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='changing_the_number_of_groups_and_types_bound_to_a_key'>
+<title>Changing the Number of Groups and Types Bound to a Key</title>
+
+<para>
+To change the number of groups and the types bound to a key, use <emphasis>
+XkbChangeTypesOfKey</emphasis>
+.
+</para>
+
+
+<para>
+Status <emphasis>
+XkbChangeTypesOfKey</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ key</emphasis>
+,<emphasis>
+ n_groups</emphasis>
+,<emphasis>
+ groups</emphasis>
+,<emphasis>
+ new_types_in</emphasis>
+,<emphasis>
+ p_changes</emphasis>
+)
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description to be changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ key</emphasis>
+; /* keycode for key of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ n_groups</emphasis>
+; /* new number of groups for key */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+groups</emphasis>
+; /* mask indicating groups to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+new_types_in</emphasis>
+; /* indices for new groups specified in <emphasis>
+groups</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbMapChangesPtr <emphasis>
+p_changes</emphasis>
+; /* notes changes made to <emphasis>
+xkb</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeTypesOfKey</emphasis>
+ reallocates the symbols and actions bound to the key, if necessary, and
+initializes any new symbols or actions to <emphasis>
+NoSymbol</emphasis>
+ or <emphasis>
+NoAction</emphasis>
+, as appropriate. If the <emphasis>
+p_changes</emphasis>
+ parameter is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ adds the <emphasis>
+XkbKeySymsMask</emphasis>
+ to the <emphasis>
+changes</emphasis>
+ field of <emphasis>
+p_changes</emphasis>
+ and modifies the <emphasis>
+first_key_sym</emphasis>
+ and <emphasis>
+num_key_syms</emphasis>
+ fields of <emphasis>
+p_changes</emphasis>
+ to include the <emphasis>
+key</emphasis>
+ that was changed. See section 14.3.1 for more information on the <emphasis>
+XkbMapChangesPtr</emphasis>
+ structure. If successful, <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+n_groups</emphasis>
+ parameter specifies the new number of groups for the key. The <emphasis>
+groups</emphasis>
+ parameter is a mask specifying the groups for which new types are supplied and
+is a bitwise inclusive OR of the following masks: <emphasis>
+XkbGroup1Mask</emphasis>
+, <emphasis>
+XkbGroup2Mask</emphasis>
+, <emphasis>
+XkbGroup3Mask</emphasis>
+, and <emphasis>
+XkbGroup4Mask</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+new_types_in</emphasis>
+ parameter is an integer array of length <emphasis>
+n_groups</emphasis>
+. Each entry represents the type to use for the associated group and is an
+index into <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+map-&gt;types</emphasis>
+. The <emphasis>
+new_types_in</emphasis>
+ array is indexed by group index; if <emphasis>
+n_groups</emphasis>
+ is four and <emphasis>
+groups</emphasis>
+ only has <emphasis>
+Group1Mask</emphasis>
+ and <emphasis>
+Group3Mask</emphasis>
+ set, <emphasis>
+new_types_in</emphasis>
+ looks like this:
+</para>
+
+<literallayout>
+ new_types_in[0] = type for Group1
+ new_types_in[1] = ignored
+ new_types_in[2] = type for Group3
+ new_types_in[3] = ignored
+</literallayout>
+
+<para>
+For convenience, Xkb provides the following constants to use as indices to the
+groups:
+</para>
+
+<table frame='none'>
+<title>Group Index Constants</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Constant Name</entry>
+ <entry>Value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbGroup1Index</entry>
+ <entry>0</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup2Index</entry>
+ <entry>1</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup3Index</entry>
+ <entry>2</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGroup4Index</entry>
+ <entry>3</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+If the Xkb extension has not been properly initialized, <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If the <emphasis>
+xkb</emphasis>
+ parameter it not valid (that is, it is <emphasis>
+NULL</emphasis>
+ or it does not contain a valid client map), <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ returns <emphasis>
+Bad</emphasis>
+Match. If the <emphasis>
+key</emphasis>
+ is not a valid keycode, <emphasis>
+n_groups</emphasis>
+ is greater than <emphasis>
+XkbNumKbdGroups</emphasis>
+, or the <emphasis>
+groups</emphasis>
+ mask does not contain any of the valid group mask bits, <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If it is necessary to resize the key symbols or key actions arrays and any
+allocation errors occur, <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='changing_the_number_of_symbols_bound_to_a_key'>
+<title>Changing the Number of Symbols Bound to a Key</title>
+
+<para>
+To change the number of symbols bound to a key, use <emphasis>
+XkbResizeKeySyms</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+KeySym *<emphasis>
+XkbResizeKeySyms</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ key</emphasis>
+,<emphasis>
+ needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescRec *<emphasis>
+ xkb</emphasis>
+; /* keyboard description to be changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ key</emphasis>
+; /* keycode for key to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ needed</emphasis>
+; /* new number of keysyms required for key */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbResizeKeySyms</emphasis>
+ reserves the space needed for <emphasis>
+needed</emphasis>
+ keysyms and returns a pointer to the beginning of the new array that holds the
+keysyms. It adjusts the <emphasis>
+offset</emphasis>
+ field of the <emphasis>
+key_sym_map</emphasis>
+ entry for the key if necessary and can also change the <emphasis>
+syms</emphasis>
+, <emphasis>
+num_syms</emphasis>
+, and <emphasis>
+size_syms</emphasis>
+ fields of <emphasis>
+xkb</emphasis>
+-<emphasis>
+&gt;map</emphasis>
+ if it is necessary to reallocate the <emphasis>
+syms</emphasis>
+ array. <emphasis>
+XkbResizeKeySyms</emphasis>
+ does not modify either the width or number of groups associated with the key.
+</para>
+
+
+<para>
+If <emphasis>
+needed</emphasis>
+ is greater than the current number of keysyms for the key, <emphasis>
+XkbResizeKeySyms</emphasis>
+ initializes all new keysyms in the array to <emphasis>
+NoSymbol</emphasis>
+.
+</para>
+
+
+<para>
+Because the number of symbols needed by a key is normally computed as width *
+number of groups, and <emphasis>
+XkbResizeKeySyms</emphasis>
+ does not modify either the width or number of groups for the key, a
+discrepancy exists upon return from <emphasis>
+XkbResizeKeySyms</emphasis>
+ between the space allocated for the keysyms and the number required. The
+unused entries in the list of symbols returned by <emphasis>
+XkbResizeKeySyms</emphasis>
+ are not preserved across future calls to any of the map editing functions, so
+you must update the key symbol mapping (which updates the width and number of
+groups for the key) before calling another allocator function. A call to
+<emphasis>
+XkbChangeTypesOfKey</emphasis>
+ will update the mapping.
+</para>
+
+
+<para>
+If any allocation errors occur while resizing the number of symbols bound to
+the key, <emphasis>
+XkbResizeKeySyms</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+.
+</para>
+
+<note><para>A change to the number of symbols bound to a key should be
+accompanied by a change in the number of actions bound to a key. Refer to
+section 16.1.16 for more information on changing the number of actions bound to
+a key.</para></note>
+
+
+</sect2>
+</sect1>
+<sect1 id='the_per_key_modifier_map'>
+<title>The Per-Key Modifier Map</title>
+
+<para>
+The <emphasis>
+modmap</emphasis>
+ entry of the client map is an array, indexed by keycode, specifying the real
+modifiers bound to a key. Each entry is a mask composed of a bitwise inclusive
+OR of the legal real modifiers: <emphasis>
+ShiftMask</emphasis>
+, <emphasis>
+LockMask</emphasis>
+, <emphasis>
+ControlMask</emphasis>
+, <emphasis>
+Mod1Mask</emphasis>
+, <emphasis>
+Mod2Mask</emphasis>
+, <emphasis>
+Mod3Mask</emphasis>
+, <emphasis>
+Mod4Mask</emphasis>
+, and <emphasis>
+Mod5Mask</emphasis>
+. If a bit is set in a <emphasis>
+modmap</emphasis>
+ entry, the corresponding key is bound to that modifier.
+</para>
+
+
+<para>
+Pressing or releasing the key bound to a modifier changes the modifier set and
+unset state. The particular manner in which the modifier set and unset state
+changes is determined by the behavior and actions assigned to the key (see
+Chapter 16).
+</para>
+
+
+<sect2 id='getting_the_per_key_modifier_map_from_the_server'>
+<title>Getting the Per-Key Modifier Map from the Server</title>
+
+<para>
+To update the modifier map for one or more of the keys in a keyboard
+description, use <emphasis>
+XkbGetKeyModifierMap</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyModifierMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first</emphasis>
+; /* keycode of first key to get */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* number of keys for which information is desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description to update */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyModifierMap</emphasis>
+ sends a request to the server for the modifier mappings for <emphasis>
+num</emphasis>
+ keys starting with the key whose keycode is <emphasis>
+first</emphasis>
+. It waits for a reply and places the results in the <emphasis>
+xkb</emphasis>
+-&gt;map-&gt;modmap array. If successful, <emphasis>
+XkbGetKeyModifier</emphasis>
+ returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<para>
+If the map component of the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeyModifierMap</emphasis>
+ allocates and initializes it.
+</para>
+
+
+<para>
+If a compatible version of Xkb is not available in the server or the Xkb
+extension has not been properly initialized, <emphasis>
+XkbGetKeySyms</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If any allocation errors occur while obtaining the modifier map, <emphasis>
+XkbGetKeyModifierMap</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+</sect2>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch16.xml b/libX11/specs/XKB/ch16.xml
new file mode 100644
index 000000000..515323f7b
--- /dev/null
+++ b/libX11/specs/XKB/ch16.xml
@@ -0,0 +1,4794 @@
+<chapter id='xkb_server_keyboard_mapping'>
+<title>Xkb Server Keyboard Mapping</title>
+
+<para>
+The <emphasis>
+server</emphasis>
+ field of the complete Xkb keyboard description (see section 6.1) is a pointer
+to the Xkb server map.
+</para>
+
+
+<para>
+Figure 16.1 shows the relationships between elements in the server map:
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-16.svg"/>
+ </imageobject>
+<caption>Server Map Relationships</caption>
+ </mediaobject>
+
+
+<!--
+<H5 CLASS="Figure">
+Server Map Relationships</H5>
+-->
+
+<para>
+The Xkb server map contains the information the server needs to interpret key
+events and is of type <emphasis>
+XkbServerMapRec</emphasis>
+:
+</para>
+
+<para><programlisting>
+#define XkbNumVirtualMods 16
+</programlisting></para>
+
+<para><programlisting>
+typedef struct { /* Server Map */
+ unsigned short num_acts; /* # of occupied entries in <emphasis> acts</emphasis> */
+ unsigned short size_acts; /* # of entries in <emphasis> acts</emphasis> */
+ XkbAction * acts; /* linear 2d tables of key actions, 1 per keycode */
+ XkbBehavior * behaviors; /* key behaviors,1 per keycode */
+ unsigned short * key_acts; /* index into <emphasis> acts</emphasis> , 1 per keycode */
+ unsigned char * explicit; /* explicit overrides of core remapping, 1 per key */
+ unsigned char vmods[XkbNumVirtualMods]; /* real mods bound to virtual mods */
+ unsigned short * vmodmap; /* virtual mods bound to key, 1 per keycode*/
+} <emphasis>XkbServerMapRec</emphasis>, *XkbServerMapPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+num_acts</emphasis>
+, <emphasis>
+size_acts</emphasis>
+, <emphasis>
+acts</emphasis>
+, and <emphasis>
+key_acts</emphasis>
+ fields specify the key actions, defined in section 16.1. The <emphasis>
+behaviors</emphasis>
+ field describes the behavior for each key and is defined in section 16.2. The
+<emphasis>
+explicit</emphasis>
+ field describes the explicit components for a key and is defined in section
+16.3. The <emphasis>
+vmods</emphasis>
+ and the <emphasis>
+vmodmap</emphasis>
+ fields describe the virtual modifiers and the per-key virtual modifier mapping
+and are defined in section 16.4.
+</para>
+
+<sect1 id='key_actions'>
+<title>Key Actions</title>
+
+<para>
+A key action defines the effect key presses and releases have on the internal
+state of the server. For example, the expected key action associated with
+pressing the <emphasis>
+Shift</emphasis>
+ key is to set the <emphasis>
+Shift</emphasis>
+ modifier. There is zero or one key action associated with each keysym bound to
+each key.
+</para>
+
+
+<para>
+Just as the entire list of key symbols for the keyboard mapping is held in the
+<emphasis>
+syms</emphasis>
+ field of the client map, the entire list of key actions for the keyboard
+mapping is held in the <emphasis>
+acts</emphasis>
+ array of the server map. The total size of <emphasis>
+acts</emphasis>
+ is specified by <emphasis>
+size_acts</emphasis>
+, and the number of entries is specified by <emphasis>
+num_acts</emphasis>.
+</para>
+
+
+<para>
+The <emphasis>
+key_acts</emphasis>
+ array, indexed by keycode, describes the actions associated with a key. The
+<emphasis>
+key_acts</emphasis>
+ array has <emphasis>
+min_key_code</emphasis>
+ unused entries at the start to allow direct indexing using a keycode. If a
+<emphasis>
+key_acts</emphasis>
+ entry is <emphasis>
+zero</emphasis>
+, it means the key does not have any actions associated with it. If an entry is
+not <emphasis>
+zero</emphasis>
+, the entry represents an index into the <emphasis>
+acts</emphasis>
+ field of the server map, much as the <emphasis>
+offset</emphasis>
+ field of a <emphasis>
+KeySymMapRec</emphasis>
+ structure is an index into the <emphasis>
+syms</emphasis>
+ field of the client map.
+</para>
+
+<para>
+The reason the <emphasis>
+acts</emphasis>
+ field is a linear list of <emphasis>
+XkbAction</emphasis>
+s is to reduce the memory consumption associated with a keymap. Because Xkb
+allows individual keys to have multiple shift levels and a different number of
+groups per key, a single two-dimensional array of <emphasis>
+KeySyms</emphasis>
+ would potentially be very large and sparse. Instead, Xkb provides a small
+two-dimensional array of <emphasis>
+XkbAction</emphasis>
+s for each key. To store all of these individual arrays, Xkb concatenates each
+array together in the <emphasis>
+acts</emphasis>
+ field of the server map.
+</para>
+
+
+<para>
+The key action structures consist only of fields of type char or unsigned char.
+This is done to optimize data transfer when the server sends bytes over the
+wire. If the fields are anything but bytes, the server has to sift through all
+of the actions and swap any nonbyte fields. Because they consist of nothing but
+bytes, it can just copy them out.
+</para>
+
+
+<para>
+Xkb provides the following macros, to simplify accessing information pertaining
+to key actions:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbKeyHasActions</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyHasActions</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if the key corresponding to <emphasis>
+keycode</emphasis>
+ has any actions associated with it; otherwise, it returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyNumActions</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyNumActions</emphasis>
+ computes the number of actions associated with the key corresponding to
+<emphasis>
+keycode</emphasis>
+. This should be the same value as the result of <emphasis>
+XkbKeyNumSyms</emphasis>
+ (see section 15.3.3).
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbKeyActionPtr <emphasis>
+XkbKeyActionsPtr</emphasis>
+(<emphasis>
+xkb, keycode</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyActionsPtr</emphasis>
+ returns a pointer to the two-dimensional array of key actions associated with
+the key corresponding to <emphasis>
+keycode</emphasis>
+. Use<emphasis>
+ XkbKeyActionsPtr</emphasis>
+ only if the key actually has some actions associated with it, that is,
+<emphasis>
+XkbKeyNumActions</emphasis>
+(xkb, keycode) returns something greater than zero.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbAction <emphasis>
+XkbKeyAction</emphasis>
+(<emphasis>
+xkb, keycode, idx</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+idx</emphasis>
+; /* index for group and shift level */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyAction</emphasis>
+ returns the key action indexed by <emphasis>
+idx</emphasis>
+ in the two-dimensional array of key actions associated with the key
+corresponding to <emphasis>
+keycode</emphasis>
+. <emphasis>
+idx</emphasis>
+ may be computed from the group and shift level of interest as follows:
+</para>
+
+<literallayout>
+ idx = group_index * key_width + shift_level
+</literallayout>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbAction <emphasis>
+XkbKeyActionEntry</emphasis>
+(<emphasis>
+xkb, keycode, shift, grp</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+keycode</emphasis>
+; /* keycode of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+shift</emphasis>
+; /* shift level within group */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+grp</emphasis>
+; /* group index for group of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyActionEntry</emphasis>
+ returns the key action corresponding to group <emphasis>
+grp</emphasis>
+ and shift level <emphasis>
+lvl</emphasis>
+ from the two-dimensional table of key actions associated with the key
+corresponding to <emphasis>
+keycode</emphasis>
+.
+</para>
+
+
+<sect2 id='the_xkbaction_structure'>
+<title>The XkbAction Structure</title>
+
+<para>
+The description for an action is held in an <emphasis>
+XkbAction</emphasis>
+ structure, which is a union of all possible Xkb action types:
+</para>
+
+<para><programlisting>
+typedef union _XkbAction {
+ XkbAnyAction any;
+ XkbModAction mods;
+ XkbGroupAction group;
+ XkbISOAction iso;
+ XkbPtrAction ptr;
+ XkbPtrBtnAction btn;
+ XkbPtrDfltAction dflt;
+ XkbSwitchScreenAction screen;
+ XkbCtrlsAction ctrls;
+ XkbMessageAction msg;
+ XkbRedirectKeyAction redirect;
+ XkbDeviceBtnAction devbtn;
+ XkbDeviceValuatorAction devval;
+ unsigned char type;
+} <emphasis>XkbAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field is provided for convenience and is the same as the type field in the
+individual structures. The following sections describe the individual
+structures for each action in detail.
+</para>
+
+
+</sect2>
+<sect2 id='the_xkbanyaction_structure'>
+<title>The XkbAnyAction Structure</title>
+
+<para>
+The <emphasis>
+XkbAnyAction</emphasis>
+ structure is a convenience structure that refers to any of the actions:
+</para>
+
+<para><programlisting>
+#define XkbAnyActionDataSize 7
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbAnyAction {
+ unsigned char type; /* type of action; determines interpretation for data */
+ unsigned char data[XkbAnyActionDataSize];
+} <emphasis>XkbAnyAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+data</emphasis>
+ field represents a structure for an action, and its interpretation depends on
+the <emphasis>
+type</emphasis>
+ field. The valid values for the <emphasis>
+type</emphasis>
+ field, and the data structures associated with them are shown in Table 16.1:
+</para>
+
+<table frame='none'>
+<title>Action Types</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Structure for Data</entry>
+ <entry>XkbAction Union Member</entry>
+ <entry>Section</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_NoAction</emphasis></entry>
+ <entry>
+<emphasis>XkbSA_NoAction</emphasis>
+ means the server does not perform an action for the key; this action does not
+have an associated data structure.
+ </entry>
+ <entry>any</entry>
+ <entry></entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbSA_SetMods</emphasis></para>
+<para><emphasis>XkbSA_LatchMods</emphasis></para>
+<para><emphasis>XkbSA_LockMods</emphasis></para>
+ </entry>
+ <entry><para><emphasis>XkbModAction</emphasis></para></entry>
+ <entry>mods</entry>
+ <entry>16.1.3</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbSA_SetGroup</emphasis></para>
+<para><emphasis>XkbSA_LatchGroup</emphasis></para>
+<para><emphasis>XkbSA_LockGroup</emphasis></para>
+ </entry>
+ <entry><emphasis>XkbGroupAction</emphasis></entry>
+ <entry>group</entry>
+ <entry>16.1.4</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MovePtr</emphasis></entry>
+ <entry><emphasis>XkbPtrAction</emphasis></entry>
+ <entry>ptr</entry>
+ <entry>16.1.5</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XKbSA_PtrBtn</emphasis></para>
+<para><emphasis>XkbSA_LockPtrBtn</emphasis></para>
+ </entry>
+ <entry><emphasis>XkbPtrBtnAction</emphasis></entry><entry>btn</entry>
+ <entry>16.1.6</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetPtrDflt</emphasis></entry>
+ <entry><emphasis>XkbPtrDfltAction</emphasis></entry>
+ <entry>dflt</entry>
+ <entry>16.1.7</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISOLock</emphasis></entry>
+ <entry><emphasis>XkbISOAction</emphasis></entry>
+ <entry>iso</entry>
+ <entry>16.1.8</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SwitchScreen</emphasis></entry>
+ <entry><emphasis>XkbSwitchScreenAction</emphasis></entry>
+ <entry>screen</entry>
+ <entry>16.1.9</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbSA_SetControls</emphasis></para>
+<para><emphasis>XkbSA_LockControls</emphasis></para>
+ </entry>
+ <entry><emphasis>XkbCtrlsAction</emphasis></entry>
+ <entry>ctrls</entry>
+ <entry>16.1.10</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ActionMessage</emphasis></entry>
+ <entry><emphasis>XkbMessgeAction</emphasis></entry>
+ <entry>msg</entry>
+ <entry>16.1.11</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_RedirectKey</emphasis></entry>
+ <entry><emphasis>XkbRedirectKeyAction</emphasis></entry>
+ <entry>redirect</entry>
+ <entry>16.1.12</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>
+<para><emphasis>XkbSA_DeviceBtn</emphasis></para>
+<para><emphasis>XKbSA_LockDeviceBtn</emphasis></para>
+ </entry>
+ <entry><emphasis>XkbDeviceBtnAction</emphasis></entry>
+ <entry>devbtn</entry>
+ <entry>16.1.13</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_DeviceValuator</emphasis></entry>
+ <entry><emphasis>XkbDeviceValuatorAction</emphasis></entry>
+ <entry>devval</entry>
+ <entry>16.1.14</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect2>
+<sect2 id='actions_for_changing_modifiers_state'>
+<title>Actions for Changing Modifiers’ State</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbModAction</emphasis>
+ structure change the state of the modifiers when keys are pressed and released
+(see Chapter 7 for a discussion of modifiers):
+</para>
+
+<para><programlisting>
+typedef struct _XkbModAction {
+ unsigned char type; /* <emphasis> XkbSA_{Set|Latch|Lock}Mods</emphasis> */
+ unsigned char flags; /* with <emphasis> type</emphasis> , controls the effect on modifiers */
+ unsigned char mask; /* same as <emphasis> mask</emphasis> field of a modifier description */
+ unsigned char real_mods; /* same as <emphasis> real_mods</emphasis> field of a modifier description */
+ unsigned char vmods1; /* derived from <emphasis> vmods</emphasis> field of a modifier description */
+ unsigned char vmods2; /* derived from <emphasis> vmods</emphasis> field of a modifier description */
+} <emphasis>XkbModAction</emphasis>;
+</programlisting></para>
+
+<para>
+In the following description, the term <emphasis>
+action modifiers</emphasis>
+ means the real modifier bits associated with this action. Depending on the
+value of <emphasis>
+flags</emphasis>
+ (see Table 16.3), these are designated either in the <emphasis>
+mask</emphasis>
+ field of the <emphasis>
+XkbModAction</emphasis>
+ structure itself or the real modifiers bound to the key for which the action
+is being used. In the latter case, this is the client <emphasis>
+map</emphasis>
+-&gt;<emphasis>
+modmap</emphasis>
+[<emphasis>
+keycode</emphasis>
+] field.
+</para>
+
+
+<para>
+The <emphasis>
+type</emphasis>
+ field can have any of the values shown in Table 16.2.
+</para>
+
+<table frame='none'>
+<title>Modifier Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetMods</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+A key press adds any action modifiers to the keyboard’s base modifiers.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A key release clears any action modifiers in the keyboard’s base modifiers,
+provided no other key affecting the same modifiers is logically down.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If no other keys are physically depressed when this key is released, and
+<emphasis>
+XkbSA_ClearLocks</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, the key release unlocks any action modifiers.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LatchMods</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+Key press and key release events have the same effect as for <emphasis>
+XkbSA_SetMods</emphasis>
+; if no keys are physically depressed when this key is released, key release
+events have the following additional effects:
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Modifiers unlocked due to <emphasis>
+XkbSA_ClearLocks</emphasis>
+ have no further effect.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If <emphasis>
+XkbSA_LatchToLock</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, a key release locks and then unlatches any remaining action modifiers
+that are already latched.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A key release latches any action modifiers not used by the <emphasis>
+XkbSA_ClearLocks</emphasis>
+ and <emphasis>
+XkbSA_LatchToLock</emphasis>
+ flags.
+ </para>
+ </listitem>
+ </itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockMods</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+A key press sets the base state of any action modifiers. If <emphasis>
+XkbSA_LockNoLock</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, a key press also sets the locked state of any action modifiers.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A key release clears any action modifiers in the keyboard’s base modifiers,
+provided no other key that affects the same modifiers is down. If <emphasis>
+XkbSA_LockNoUnlock</emphasis>
+ is not set in the <emphasis>
+flags</emphasis>
+ field, and any of the action modifiers were locked before the corresponding
+key press occurred, a key release unlocks them.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.3. A general meaning is given in the table, but the exact meaning depends on
+the action <emphasis>type</emphasis>.
+</para>
+
+<table frame='none'>
+<title>Modifier Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_UseModMapMods</emphasis></entry>
+ <entry>
+If set, the action modifiers are determined by the modifiers bound by the
+modifier mapping of the key. Otherwise, the action modifiers are set to the
+modifiers specified by the <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmod1</emphasis>
+, and <emphasis>
+vmod2</emphasis>
+ fields.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ClearLocks</emphasis></entry>
+ <entry>
+If set and no keys are physically depressed when this key transition
+occurs, the server unlocks any action modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LatchToLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LatchMods</emphasis>
+, the server locks the action modifiers if they are already latched.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockMods</emphasis>
+, the server only unlocks the action modifiers.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoUnlock</emphasis></entry>
+ <entry>
+If set, and the action is <emphasis>
+XkbSA_LockMods</emphasis>
+, the server only locks the action modifiers.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+If <emphasis>
+XkbSA_UseModMapMods</emphasis>
+ is not set in the <emphasis>
+flags</emphasis>
+ field, the <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmods1</emphasis>
+, and <emphasis>
+vmods2 </emphasis>
+fields are used to determine the action modifiers. Otherwise they are ignored
+and the modifiers bound to the key (client <emphasis>
+map</emphasis>
+-&gt;<emphasis>
+modmap</emphasis>
+[<emphasis>
+keycode</emphasis>
+]) are used instead.
+</para>
+
+
+<para>
+The <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmods1</emphasis>
+, and <emphasis>
+vmods2</emphasis>
+ fields represent the components of an Xkb modifier description (see section
+7.2). While the <emphasis>
+mask</emphasis>
+ and <emphasis>
+real_mods</emphasis>
+ fields correspond directly to the <emphasis>
+mask</emphasis>
+ and <emphasis>
+real_mods</emphasis>
+ fields of an Xkb modifier description, the <emphasis>
+vmods1</emphasis>
+ and <emphasis>
+vmods2</emphasis>
+ fields are combined to correspond to the <emphasis>
+vmods</emphasis>
+ field of an Xkb modifier description. Xkb provides the following macros, to
+convert between the two formats:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned short <emphasis>
+XkbModActionVMods</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbAction <emphasis>
+act</emphasis>
+; /* action from which to extract virtual mods */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbModActionVMods</emphasis>
+ returns the <emphasis>
+vmods1</emphasis>
+ and <emphasis>
+vmods2</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ converted to the <emphasis>
+vmods</emphasis>
+ format of an Xkb modifier description.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSetModActionVMods</emphasis>
+(<emphasis>
+act, vmods</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbAction <emphasis>
+act</emphasis>
+; /* action in which to set vmods */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned short <emphasis>
+vmods</emphasis>
+; /* virtual mods to set */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetModActionVMods</emphasis>
+ sets the <emphasis>
+vmods1</emphasis>
+ and <emphasis>
+vmods2</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ using the <emphasis>
+vmods</emphasis>
+ format of an Xkb modifier description.
+</para>
+
+<note><para>Despite the fact that the first parameter of these two macros is of
+type XkbAction, these macros may be used only with Actions of type <emphasis>
+XkbModAction</emphasis>
+ and <emphasis>
+XkbISOAction</emphasis>
+.</para></note>
+
+
+</sect2>
+<sect2 id='actions_for_changing_group_state'>
+<title>Actions for Changing Group State</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbGroupAction</emphasis>
+ structure change the current group state when keys are pressed and released
+(see Chapter 5 for a description of groups and keyboard state):
+</para>
+
+<para><programlisting>
+typedef struct _XkbGroupAction {
+ unsigned char type; /* <emphasis> XkbSA_{Set|Latch|Lock}Group</emphasis> */
+ unsigned char flags; /* with <emphasis> type</emphasis> , controls the effect on groups */
+ char group_XXX; /* represents a group index or delta */
+} <emphasis>XkbGroupAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field can have any of the following values:
+</para>
+
+<table frame='none'>
+<title>Group Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetGroup</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_GroupAbsolute</emphasis>
+ bit is set in the <emphasis>
+flags</emphasis>
+ field, key press events change the base keyboard group to the group specified
+by the <emphasis>
+group_XXX</emphasis>
+ field. Otherwise, key press events change the base keyboard group by adding
+the <emphasis>
+group_XXX</emphasis>
+ field to the base keyboard group. In either case, the resulting effective
+keyboard group is brought back into range depending on the value of the
+<emphasis>
+groups_wrap</emphasis>
+ field of the controls structure (see section 10.7.1).
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If a key with an <emphasis>
+XkbSA_ISOLock</emphasis>
+ action (see section 16.1.8) is pressed while this key is down, the key release
+of this key has no effect. Otherwise, the key release cancels the effects of
+the key press.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_ClearLocks</emphasis>
+ bit is set in the flags field, and no keys are physically depressed when this
+key is released, the key release also sets the locked keyboard group to
+<emphasis>
+Group1</emphasis>
+.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LatchGroup</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+Key press and key release events have the same effect as for <emphasis>
+XkbSA_SetGroup</emphasis>
+; if no keys are physically depressed when this key is released, key release
+events have the following additional effects.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_LatchToLock</emphasis>
+ bit is set in the <emphasis>
+flags</emphasis>
+ field and the latched keyboard group index is nonzero, the key release adds
+the delta applied by the corresponding key press to the locked keyboard group
+and subtracts it from the latched keyboard group. The locked and effective
+keyboard group are brought back into range according to the value of the
+<emphasis>
+groups_wrap</emphasis>
+ field of the controls structure.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Otherwise, the key press adds the key press delta to the latched keyboard group.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockGroup</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_GroupAbsolute</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, key press events set the locked keyboard group to the group specified
+by the <emphasis>
+group_XXX</emphasis>
+ field. Otherwise, key press events add the group specified by the <emphasis>
+group_XXX</emphasis>
+ field to the locked keyboard group. In either case, the resulting locked and
+effective keyboard groups are brought back into range depending on the value of
+the <emphasis>
+groups_wrap</emphasis>
+ field of the controls structure.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A key release has no effect.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.5. A general meaning is given in the table, but the exact meaning depends on
+the action <emphasis>
+type</emphasis>
+.
+</para>
+
+<table frame='none'>
+<title>Group Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ClearLocks</emphasis></entry>
+ <entry>
+If set and no keys are physically depressed when this key transition occurs,
+the server sets the locked keyboard group to <emphasis>
+Group1</emphasis>
+ on a key release.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LatchToLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+SA_LatchGroup</emphasis>
+, the server locks the action group if it is already latched.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_GroupAbsolute</emphasis></entry>
+ <entry>
+If set, the <emphasis>
+group_XXX</emphasis>
+ field represents an absolute group number. Otherwise, it represents a group
+delta to be added to the current group to determine the new group number.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+group_XXX</emphasis>
+ field represents a signed character. Xkb provides the following macros to
+convert between a signed integer value and a signed character:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbSAGroup</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbAction <emphasis>
+act</emphasis>
+; /* action from which to extract group */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSAGroup</emphasis>
+ returns the <emphasis>
+group_XXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ converted to a signed int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSASetGroup</emphasis>
+(<emphasis>
+act, grp</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbAction <emphasis>
+act</emphasis>
+; /* action from which to set group */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+grp</emphasis>
+; /* group index to set in <emphasis>
+group_XXX</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSASetGroup</emphasis>
+ sets the <emphasis>
+group_XXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ from the group index <emphasis>
+grp</emphasis>
+.
+</para>
+
+<note><para>Despite the fact that the first parameter of these two macros is of
+type XkbAction, these macros may only be used with Actions of type <emphasis>
+XkbGroupAction</emphasis>
+ and <emphasis>
+XkbISOAction</emphasis>
+.</para></note>
+
+
+</sect2>
+<sect2 id='actions_for_moving_the_pointer'>
+<title>Actions for Moving the Pointer</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbPtrAction</emphasis>
+ structure move the pointer when keys are pressed and released:
+</para>
+
+<para><programlisting>
+typedef struct _XkbPtrAction {
+ unsigned char type; /* <emphasis> XkbSA_MovePtr</emphasis> */
+ unsigned char flags; /* determines type of pointer motion */
+ unsigned char high_XXX; /* x coordinate, high bits*/
+ unsigned char low_XXX; /* y coordinate, low bits */
+ unsigned char high_YYY; /* x coordinate, high bits */
+ unsigned char low_YYY; /* y coordinate, low bits */
+} <emphasis>XkbPtrAction</emphasis>;
+</programlisting></para>
+
+<para>
+If the <emphasis>
+MouseKeys</emphasis>
+ control is not enabled (see section 10.5.1), <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events are treated as though the action is <emphasis>
+XkbSA_NoAction</emphasis>.
+</para>
+
+<para>
+If the <emphasis>
+MouseKeys</emphasis>
+ control is enabled, a server action of type <emphasis>
+XkbSA_MovePtr</emphasis>
+ instructs the server to generate core pointer <emphasis>
+MotionNotify</emphasis>
+ events rather than the usual <emphasis>
+KeyPress</emphasis>
+ event, and the corresponding <emphasis>
+KeyRelease</emphasis>
+ event disables any mouse keys timers that were created as a result of handling
+the <emphasis>
+XkbSA_MovePtr</emphasis>
+ action.
+</para>
+
+
+<para>
+The <emphasis>
+type</emphasis>
+ field of the <emphasis>
+XkbPtrAction</emphasis>
+ structure is always <emphasis>
+XkbSA_MovePtr</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is a bitwise inclusive OR of the masks shown in Table 16.6.
+</para>
+
+<table frame='none'>
+<title>Pointer Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Action Type</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_NoAcceleration</emphasis></entry>
+ <entry>
+If not set, and the <emphasis>
+MouseKeysAccel</emphasis>
+ control is enabled (see section 10.5.2), the <emphasis>
+KeyPress</emphasis>
+ initiates a mouse keys timer for this key; every time the timer expires, the
+cursor moves.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MoveAbsoluteX</emphasis></entry>
+ <entry>If set, the X portion of the structure specifies the new pointer X
+coordinate. Otherwise, the X portion is added to the current pointer X
+coordinate to determine the new pointer X coordinate.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MoveAbsoluteY</emphasis></entry>
+ <entry>
+If set, the Y portion of the structure specifies the new
+pointer Y coordinate. Otherwise, the Y portion is added
+to the current pointer Y coordinate to determine the new pointer Y coordinate.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Each of the X and Y coordinantes of the <emphasis>
+XkbPtrAction</emphasis>
+ structure is composed of two signed 16-bit values, that is, the X coordinate
+is composed of <emphasis>
+high_XXX</emphasis>
+ and <emphasis>
+low_XXX</emphasis>
+, and similarly for the Y coordinate. Xkb provides the following macros, to
+convert between a signed integer and two signed 16-bit values in <emphasis>
+XkbPtrAction</emphasis>
+ structures:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbPtrActionX</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbPtrAction <emphasis>
+act</emphasis>
+; /* action from which to extract X */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbPtrActionX</emphasis>
+ returns the <emphasis>
+high_XXX</emphasis>
+ and <emphasis>
+low_XXX</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ converted to a signed int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbPtrActionY</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbPtrAction <emphasis>
+act</emphasis>
+; /* action from which to extract Y */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbPtrActionY</emphasis>
+ returns the <emphasis>
+high_YYY</emphasis>
+ and <emphasis>
+low_YYY</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ converted to a signed int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSetPtrActionX</emphasis>
+(<emphasis>
+act</emphasis>
+, <emphasis>
+x</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbPtrAction <emphasis>
+act</emphasis>
+; /* action in which to set X */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+x; </emphasis>
+ /* new value to set */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetPtrActionX</emphasis>
+ sets the <emphasis>
+high_XXX</emphasis>
+ and <emphasis>
+low_XXX</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ from the signed integer value <emphasis>
+x</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSetPtrActionY</emphasis>
+(<emphasis>
+act, y</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbPtrAction <emphasis>
+act</emphasis>
+; /* action in which to set Y */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+y</emphasis>
+; /* new value to set */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetPtrActionX</emphasis>
+ sets the <emphasis>
+high_YYY</emphasis>
+ and <emphasis>
+low_YYY</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ from the signed integer value <emphasis>
+y</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='actions_for_simulating_pointer_button_press_and_release'>
+<title>Actions for Simulating Pointer Button Press and Release</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbPtrBtnAction</emphasis>
+ structure simulate the press and release of pointer buttons when keys are
+pressed and released:
+</para>
+
+<para><programlisting>
+typedef struct _XkbPtrBtnAction {
+ unsigned char type; /*<emphasis> XkbSA_PtrBtn, XkbSA_LockPtrBtn</emphasis> */
+ unsigned char flags; /* with <emphasis> type</emphasis> , controls the effect on pointer buttons*/
+ unsigned char count; /* controls number of ButtonPress and ButtonRelease events */
+ unsigned char button; /* pointer button to simulate */
+} <emphasis>XkbPtrBtnAction</emphasis>;
+</programlisting></para>
+
+<para>
+If the <emphasis>
+MouseKeys</emphasis>
+ (see section 10.5.1) control is not enabled, <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events are treated as though the action is <emphasis>
+XkbSA_NoAction</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+type</emphasis>
+ field can have any one of the values shown in Table 16.7.
+</para>
+
+<table frame='none'>
+<title>Pointer Button Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_PtrBtn</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If<emphasis>
+ XkbSA_UseDfltButton</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, the event is generated for the pointer button specified by the
+<emphasis>
+mk_dflt_btn</emphasis>
+ attribute of the <emphasis>
+MouseKeys</emphasis>
+ control (see section 10.5.1). Otherwise, the event is generated for the button
+specified by the <emphasis>
+button</emphasis>
+ field.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the mouse button specified for this action is logically down, the key press
+and corresponding key release are ignored and have no effect. Otherwise, a key
+press causes one or more core pointer button events instead of the usual
+<emphasis>
+KeyPress</emphasis>
+ event. If <emphasis>
+count</emphasis>
+ is <emphasis>
+zero</emphasis>
+, a key press generates a single <emphasis>
+ButtonPress</emphasis>
+ event; if <emphasis>
+count</emphasis>
+ is greater than <emphasis>
+zero</emphasis>
+, a key press generates <emphasis>
+count</emphasis>
+ pairs of <emphasis>
+ButtonPress</emphasis>
+ and <emphasis>
+ButtonRelease</emphasis>
+ events.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If <emphasis>
+count</emphasis>
+ is <emphasis>
+zero</emphasis>
+, a key release generates a core pointer <emphasis>
+ButtonRelease</emphasis>
+ that matches the event generated by the corresponding <emphasis>
+KeyPress</emphasis>
+; if <emphasis>
+count</emphasis>
+ is nonzero, a key release does not cause a <emphasis>
+ButtonRelease</emphasis>
+ event. A key release never generates a key <emphasis>
+KeyRelease</emphasis>
+ event.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockPtrBtn</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the button specified by the <emphasis>
+MouseKeys</emphasis>
+ default button<emphasis>
+ </emphasis>
+or <emphasis>
+button</emphasis>
+ is not locked, a key press causes a <emphasis>
+ButtonPress</emphasis>
+ event instead of a <emphasis>
+KeyPress</emphasis>
+ event and locks the button. If the button is already locked or if <emphasis>
+XkbSA_LockNoUnlock</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, a key press is ignored and has no effect.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the corresponding key press was ignored, and if <emphasis>
+XkbSA_LockNoLock</emphasis>
+ is not set in the <emphasis>
+flags</emphasis>
+ field, a key release generates a <emphasis>
+ButtonRelease</emphasis>
+ event instead of a <emphasis>
+KeyRelease</emphasis>
+ event and unlocks the specified button. If the corresponding key press locked
+a button, the key release is ignored and has no effect.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.8. A general meaning is given in the table, but the exact meaning depends on
+the action <emphasis>
+type.</emphasis>
+:
+</para>
+
+<table frame='none'>
+<title>Pointer Button Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_UseDfltButton</emphasis></entry>
+ <entry>
+If set, the action uses the pointer button specified by the <emphasis>
+mk_dflt_btn</emphasis>
+ attribute of the <emphasis>
+MouseKeys</emphasis>
+ control (see section 10.5.1). Otherwise, the action uses the pointer button
+specified by the<emphasis>
+ button </emphasis>
+field.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockPtrBtn</emphasis>
+, the server only unlocks the pointer button.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoUnlock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockPtrBtn</emphasis>
+, the server only locks the pointer button.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect2>
+<sect2 id='actions_for_changing_the_pointer_button_simulated'>
+<title>Actions for Changing the Pointer Button Simulated</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbPtrDfltAction</emphasis>
+ structure change the <emphasis>
+mk_dflt_btn</emphasis>
+ attribute of the <emphasis>
+MouseKeys</emphasis>
+ control (see section 10.5.1):
+</para>
+
+<para><programlisting>
+typedef struct _XkbPtrDfltAction {
+ unsigned char type; /* <emphasis> XkbSA_SetPtrDflt</emphasis> */
+ unsigned char flags; /* controls the pointer button number */
+ unsigned char affect; /* <emphasis> XkbSA_AffectDfltBtn</emphasis> */
+ char valueXXX; /* new default button member */
+} <emphasis>XkbPtrDfltAction</emphasis>;
+</programlisting></para>
+
+<para>
+If the <emphasis>
+MouseKeys</emphasis>
+ control is not enabled, <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events are treated as though the action is <emphasis>
+XkbSA_NoAction</emphasis>
+. Otherwise, this action changes the <emphasis>
+mk_dflt_btn</emphasis>
+ attribute of the <emphasis>
+MouseKeys</emphasis>
+ control.
+</para>
+
+
+<para>
+The <emphasis>
+type</emphasis>
+ field of the <emphasis>
+XkbPtrDfltAction</emphasis>
+ structure should always be <emphasis>
+XkbSA_SetPtrDflt</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the values shown in Table
+16.9 (currently there is only one value defined).
+</para>
+
+<table frame='none'>
+<title>Pointer Default Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_DfltBtnAbsolute</emphasis></entry>
+ <entry>
+If set, the <emphasis>
+value</emphasis>
+ field represents an absolute pointer button. Otherwise, the <emphasis>
+value</emphasis>
+ field represents the amount to be added to the current default button.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+affect</emphasis>
+ field specifies what changes as a result of this action. The only valid value
+for the <emphasis>
+affect</emphasis>
+ field is <emphasis>XkbSA_AffectDfltBtn</emphasis>.
+</para>
+
+<para>
+The <emphasis>
+valueXXX</emphasis>
+ field is a signed character that represents the new button value for the
+<emphasis>
+mk_dflt_btn</emphasis>
+ attribute of the <emphasis>
+MouseKeys</emphasis>
+ control (see section 10.5.1). If <emphasis>
+XkbSA_DfltBtnAbsolute</emphasis>
+ is set in <emphasis>
+flags</emphasis>
+, <emphasis>
+valueXXX</emphasis>
+ specifies the button to be used; otherwise, <emphasis>
+valueXXX</emphasis>
+ specifies the amount to be added to the current default button. In either
+case, illegal button choices are wrapped back around into range. Xkb provides
+the following macros, to convert between the integer and signed character
+values in <emphasis>
+XkbPtrDfltAction</emphasis>
+ structures:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbSAPtrDfltValue</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbAction <emphasis>
+act</emphasis>
+; /* action from which to extract group */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSAPtrDfltValue</emphasis>
+ returns the <emphasis>
+valueXXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ converted to a signed int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSASetPtrDfltValue</emphasis>
+(<emphasis>
+act, val</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbPtrDfltAction <emphasis>
+act</emphasis>
+; /* action in which to set <emphasis>
+valueXXX</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+val</emphasis>
+; /* value to set in <emphasis>
+valueXXX</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSASetPtrDfltValue</emphasis>
+ sets the <emphasis>
+valueXXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ from <emphasis>
+val</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='actions_for_locking_modifiers_and_group'>
+<title>Actions for Locking Modifiers and Group</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbISOAction</emphasis>
+ structure lock modifiers and the group according to the ISO9995 specification.
+</para>
+
+
+<para>
+Operated by itself, the <emphasis>
+XkbISOAction</emphasis>
+ is just a caps lock. Operated simultaneously with another modifier key, it
+transforms the other key into a locking key. For example, press <emphasis>
+ISO_Lock</emphasis>
+, press and release <emphasis>
+Control_L</emphasis>
+, release <emphasis>
+ISO_Lock</emphasis>
+ ends up locking the <emphasis>
+Control</emphasis>
+ modifier.
+</para>
+
+
+<para>
+The default behavior is to convert:
+</para>
+
+<literallayout>
+ {Set,Latch}Mods to: LockMods
+ {Set,Latch}Group to: LockGroup
+ SetPtrBtn to: LockPtrBtn
+ SetControls to: LockControls
+</literallayout>
+
+<para>
+The <emphasis>
+affects</emphasis>
+ field allows you to turn those effects on or off individually. Set <emphasis>
+XkbSA_ISONoAffectMods</emphasis>
+ to disable the first, <emphasis>
+XkbSA_ISONoAffectGroup</emphasis>
+ to disable the second, and so forth.
+</para>
+
+<para><programlisting>
+typedef struct _XkbISOAction {
+ unsigned char type; /* <emphasis>XkbSA_ISOLock</emphasis> */
+ unsigned char flags; /* controls changes to group or modifier state */
+ unsigned char mask; /* same as <emphasis>mask</emphasis> field of a modifier description */
+ unsigned char real_mods; /* same as <emphasis>real_mods</emphasis> field of a modifier description */
+ char group_XXX; /* group index or delta group */
+ unsigned char affect; /* specifies whether to affect mods, group, ptrbtn, or controls*/
+ unsigned char vmods1; /* derived from <emphasis>vmods</emphasis> field of a modifier description */
+ unsigned char vmods2; /* derived from <emphasis>vmods</emphasis> field of a modifier description */
+} <emphasis>XkbISOAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field of the <emphasis>
+XkbISOAction</emphasis>
+ structure should always be <emphasis>
+XkbSA_ISOLock</emphasis>
+.
+</para>
+
+
+<para>
+The interpretation of the <emphasis>
+flags</emphasis>
+ field depends on whether the <emphasis>
+XkbSA_ISODfltIsGroup</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field or not.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbSA_ISODfltIsGroup</emphasis>
+ is set in the <emphasis>
+flags</emphasis>
+ field, the action is used to change the group state. The remaining valid bits
+of the <emphasis>
+flags</emphasis>
+ field are composed of a bitwise inclusive OR using the masks shown in Table
+16.10.
+</para>
+
+<table frame='none'>
+<title>ISO Action Flags when XkbSA_ISODfltIsGroup is Set</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISODfltIsGroup</emphasis></entry>
+ <entry>
+ <para>
+If set, the action is used to change the base group state. Must be set for the
+remaining bits in this table to carry their interpretations.
+ </para>
+ <para>
+A key press sets the base group as specified by the <emphasis>
+group_XXX</emphasis>
+ field and the <emphasis>
+XkbSA_GroupAbsolute</emphasis>
+ bit of the <emphasis>
+flags</emphasis>
+ field (see section Note). If no other actions are transformed by the <emphasis>
+XkbISO_Lock</emphasis>
+ action, a key release locks the group. Otherwise, a key release clears group
+set by the key press.
+ </para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_GroupAbsolute</emphasis></entry>
+ <entry>
+If set, the <emphasis>
+group_XXX</emphasis>
+ field represents an absolute group number. Otherwise, it represents a group
+delta to be added to the current group to determine the new group number.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectMods</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetMods</emphasis>
+ or <emphasis>
+XkbSA_LatchMods</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockMod</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectGroup</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetGroup</emphasis>
+ or <emphasis>
+XkbSA_LatchGroup</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockGroup</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectPtr</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_PtrBtn</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockPtrBtn</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectCtrls</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetControls</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockControls</emphasis>
+ actions instead.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+If the <emphasis>
+XkbSA_ISODfltIsGroup</emphasis>
+ is not set in the <emphasis>
+flags</emphasis>
+ field, the action is used to change the modifier state and the remaining valid
+bits of the <emphasis>
+flags</emphasis>
+ field are composed of a bitwise inclusive OR using the masks shown in Table
+16.11.
+</para>
+
+<table frame='none'>
+<title>ISO Action Flags when XkbSA_ISODfltIsGroup is Not Set</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISODfltIsGroup</emphasis> </entry>
+ <entry>
+ <para>
+If not set, action is used to change the base modifier state. Must not be set
+for the remaining bits in this table to carry their interpretations.
+ </para>
+ <para>
+A key press sets the action modifiers in the keyboard’s base modifiers using
+the <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmods1</emphasis>
+, and <emphasis>
+vmods2 </emphasis>
+fields (see section 16.1.3). If no other actions are transformed by the
+<emphasis>
+XkbISO_Lock</emphasis>
+ action, a key release locks the action modifiers. Otherwise, a key release
+clears the base modifiers set by the key press.
+ </para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_UseModMapMods</emphasis></entry>
+ <entry>
+If set, the action modifiers are determined by the modifiers bound by the
+modifier mapping of the key. Otherwise, the action modifiers are set to the
+modifiers specified by the <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmod1</emphasis>
+, and <emphasis>
+vmod2</emphasis>
+ fields.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoLock</emphasis></entry>
+ <entry>If set, the server only unlocks the action modifiers.</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoUnlock</emphasis></entry>
+ <entry>If set, the server only locks the action modifiers. </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectMods</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetMods</emphasis>
+ or <emphasis>
+XkbSA_LatchMods</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockMod</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectGroup</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetGroup</emphasis>
+ or <emphasis>
+XkbSA_LatchGroup</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockGroup</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectPtr</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_PtrBtn</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockPtrBtn</emphasis>
+ actions instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectCtrls</emphasis></entry>
+ <entry>
+If not set, any <emphasis>
+XkbSA_SetControls</emphasis>
+ actions that occur simultaneously with the <emphasis>
+XkbSA_ISOLock</emphasis>
+ action are treated as <emphasis>
+XkbSA_LockControls</emphasis>
+ actions instead.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+group_XXX</emphasis>
+ field represents a signed character. Xkb provides macros to convert between a
+signed integer value and a signed character as shown in section Note.
+</para>
+
+
+<para>
+The <emphasis>
+mask</emphasis>
+, <emphasis>
+real_mods</emphasis>
+, <emphasis>
+vmods1</emphasis>
+, and <emphasis>
+vmods2</emphasis>
+ fields represent the components of an Xkb modifier description (see section
+7.2). While the <emphasis>
+mask</emphasis>
+ and <emphasis>
+real_mods</emphasis>
+ fields correspond directly to the <emphasis>
+mask</emphasis>
+ and <emphasis>
+real_mods</emphasis>
+ fields of an Xkb modifier description, the <emphasis>
+vmods1</emphasis>
+ and <emphasis>
+vmods2</emphasis>
+ fields are combined to correspond to the <emphasis>
+vmods</emphasis>
+ field of an Xkb modifier description. Xkb provides macros to convert between
+the two formats as shown in section 16.1.3.
+</para>
+
+
+<para>
+The <emphasis>
+affect</emphasis>
+ field is composed of a bitwise inclusive OR using the masks shown in Table
+16.11.
+</para>
+
+<table frame='none'>
+<title>ISO Action Affect Field Values</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Affect</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISODNoAffectMods</emphasis></entry>
+ <entry>
+If <emphasis>
+XkbSA_ISONoAffectMods</emphasis>
+ is not set, any <emphasis>
+SA_SetMods</emphasis>
+ or <emphasis>
+SA_LatchMods</emphasis>
+ actions occurring simultaneously with the <emphasis>
+XkbISOAction</emphasis>
+ are treated as <emphasis>
+SA_LockMods</emphasis>
+ instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectGroup</emphasis></entry>
+ <entry>
+If <emphasis>
+XkbSA_ISONoAffectGroup</emphasis>
+ is not set, any <emphasis>
+SA_SetGroup</emphasis>
+ or <emphasis>
+SA_LatchGroup</emphasis>
+ actions occurring simultaneously with the <emphasis>
+XkbISOAction</emphasis>
+ are treated as <emphasis>
+SA_LockGroup</emphasis>
+ instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectPtr</emphasis></entry>
+ <entry>
+If <emphasis>
+XkbSA_ISONoAffectPtr</emphasis>
+ is not set, any <emphasis>
+SA_PtrBtn</emphasis>
+ actions occurring simultaneously with the <emphasis>
+XkbISOAction</emphasis>
+ are treated as <emphasis>
+SA_LockPtrBtn</emphasis>
+ instead.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_ISONoAffectCtrls</emphasis></entry>
+ <entry>
+If <emphasis>
+XkbSA_ISONoAffectCtrls</emphasis>
+ is not set, any <emphasis>
+SA_SetControls</emphasis>
+ actions occurring simultaneously with the <emphasis>
+XkbISOAction</emphasis>
+ are treated as <emphasis>
+SA_LockControls</emphasis>
+ instead.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect2>
+<sect2 id='actions_for_changing_the_active_screen'>
+<title>Actions for Changing the Active Screen</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbSwitchScreen</emphasis>
+ action structure change the active screen on a multiscreen display:
+</para>
+
+<note><para>This action is optional. Servers are free to ignore the action or
+any of its flags if they do not support the requested behavior. If the action
+is ignored, it behaves like <emphasis>
+XkbSA_NoAction</emphasis>
+. Otherwise, key press and key release events do not generate an event.
+</para></note>
+
+<para><programlisting>
+typedef struct _XkbSwitchScreenAction {
+ unsigned char type; /* <emphasis> XkbSA_SwitchScreen</emphasis> */
+ unsigned char flags; /* controls screen switching */
+ char screenXXX; /* screen number or delta */
+} <emphasis>XkbSwitchScreenAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field of the <emphasis>
+XkbSwitchScreenAction</emphasis>
+ structure should always be <emphasis>
+XkbSA_SwitchScreen</emphasis>.
+</para>
+
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.13.
+</para>
+
+<table frame='none'>
+<title>Switch Screen Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SwitchAbsolute</emphasis></entry>
+ <entry>
+If set, the <emphasis>
+screenXXX</emphasis>
+ field represents the index of the new screen. Otherwise, it represents an
+offset from the current screen to the new screen.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SwitchApplication</emphasis></entry>
+ <entry>
+If not set, the action should switch to another screen on the same
+server. Otherwise, it should switch to another X server or application that
+shares the same physical display.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+screenXXX</emphasis>
+ field is a signed character value that represents either the relative or
+absolute screen index, depending on the state of the <emphasis>
+XkbSA_SwitchAbsolute</emphasis>
+ bit in the <emphasis>
+flags</emphasis>
+ field. Xkb provides the following macros to convert between the integer and
+signed character value for screen numbers in <emphasis>
+XkbSwitchScreenAction</emphasis>
+ structures:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbSAScreen</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSwitchScreenAction <emphasis>
+act</emphasis>
+; /* action from which to extract screen */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSAScreen</emphasis>
+ returns the <emphasis>
+screenXXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ converted to a signed int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSASetScreen</emphasis>
+(<emphasis>
+act, s</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSwitchScreenAction <emphasis>
+act</emphasis>
+; /* action in which to set <emphasis>
+screenXXX</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+s</emphasis>
+; /* value to set in <emphasis>
+screenXXX</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSASetScreen</emphasis>
+ sets the <emphasis>
+screenXXX</emphasis>
+ field of <emphasis>
+act</emphasis>
+ from <emphasis>
+s</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='actions_for_changing_boolean_controls_state'>
+<title>Actions for Changing Boolean Controls State</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbCtrlsAction</emphasis>
+ structure change the state of the boolean controls (see section 10.1):
+</para>
+
+<para><programlisting>
+typedef struct _XkbCtrlsAction {
+ unsigned char type; /* <emphasis> XkbSA_SetControls,
+ XkbSA_LockControls</emphasis> */
+ unsigned char flags; /* with <emphasis> type</emphasis>,
+ controls enabling and disabling of controls */
+ unsigned char ctrls3; /* <emphasis>ctrls0</emphasis> through
+ <emphasis> ctrls3</emphasis> represent the boolean controls */
+ unsigned char ctrls2; /* <emphasis>ctrls0</emphasis> through
+ <emphasis> ctrls3</emphasis> represent the boolean controls */
+ unsigned char ctrls1; /* <emphasis>ctrls0</emphasis> through
+ <emphasis> ctrls3</emphasis> represent the boolean controls */
+ unsigned char ctrls0; /* <emphasis>ctrls0</emphasis> through
+ <emphasis> ctrls3</emphasis> represent the boolean controls */
+} <emphasis>XkbCtrlsAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field can have any one of the values shown in Table 16.14.
+</para>
+
+<table frame='none'>
+<title>Controls Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetControls</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+A key press enables any boolean controls specified in the <emphasis>
+ctrls</emphasis>
+ fields that were not already enabled at the time of the key press.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+A key release disables any controls enabled by the key press.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+This action can cause <emphasis>
+XkbControlsNotify</emphasis>
+ events (see section 10.1).
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockControls</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_LockNoLock</emphasis>
+ bit is not set in the <emphasis>
+flags</emphasis>
+ field, a key press enables any controls specified in the <emphasis>
+ctrls</emphasis>
+ fields that were not already enabled at the time of the key press.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the <emphasis>
+XkbSA_LockNoUnlock</emphasis>
+ bit is not set in the <emphasis>
+flags</emphasis>
+ field, a key release disables any controls specified in the <emphasis>
+ctrls</emphasis>
+ fields that were not already disabled at the time of the key press.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+This action can cause <emphasis>
+XkbControlsNotify</emphasis>
+ events (see section 10.1).
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.15.
+</para>
+
+<table frame='none'>
+<title>Control Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockControls</emphasis>
+, the server only disables controls.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoUnlock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockControls</emphasis>
+, the server only enables controls.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+XkbSA_SetControls</emphasis>
+ action implements a key that enables a boolean control when pressed and
+disables it when released. The <emphasis>
+XkbSA_LockControls</emphasis>
+ action is used to implement a key that toggles the state of a boolean control
+each time it is pressed and released. The <emphasis>
+XkbSA_LockNoLock</emphasis>
+ and <emphasis>
+XkbSA_LockNoUnlock</emphasis>
+ flags allow modifying the toggling behavior to only unlock or only lock the
+boolean control.
+</para>
+
+
+<para>
+The <emphasis>
+ctrls0</emphasis>
+, <emphasis>
+ctrls1</emphasis>
+, <emphasis>
+ctrls2</emphasis>
+, and <emphasis>
+ctrls3</emphasis>
+ fields represent the boolean controls in the <emphasis>
+enabled_ctrls</emphasis>
+ field of the controls structure (see section 10.1). Xkb provides the following
+macros, to convert between the two formats:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned int <emphasis>
+XkbActionCtrls</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbCtrlsAction <emphasis>
+act</emphasis>
+; /* action from which to extract controls */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbActionCtrls</emphasis>
+ returns the <emphasis>
+ctrls</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ converted to an unsigned int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSAActionSetCtrls</emphasis>
+(<emphasis>
+act, ctrls</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbCtrlsAction <emphasis>
+act</emphasis>
+; /* action in which to set ctrls0-ctrls3 */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ctrls</emphasis>
+; /* value to set in ctrls0-ctrls3 */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSAActionSetCtrls</emphasis>
+ sets the <emphasis>
+ctrls0</emphasis>
+ through <emphasis>
+ctrls3</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ from <emphasis>
+ctrls</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='actions_for_generating_messages'>
+<title>Actions for Generating Messages</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbMessageAction</emphasis>
+ structure generate <emphasis>
+XkbActionMessage</emphasis>
+ events:
+</para>
+
+<para><programlisting>
+#define XkbActionMessageLength 6
+</programlisting></para>
+<para><programlisting>
+typedef struct _XkbMessageAction {
+ unsigned char type; /* <emphasis> XkbSA_ActionMessage</emphasis> */
+ unsigned char flags; /* controls event generation via key presses and releases */
+ unsigned char message[XkbActionMessageLength]; /* message */
+} <emphasis>XkbMessageAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field of the <emphasis>
+XkbMessageAction</emphasis>
+ structure should always be <emphasis>
+XkbSA_ActionMessage</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.16.
+</para>
+
+<table frame='none'>
+<title>Message Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MessageOnPress</emphasis></entry>
+ <entry>
+If set, key press events generate an <emphasis>
+XkbActionMessage</emphasis>
+ event that reports the keycode, event type, and contents of the <emphasis>
+message</emphasis>
+ field.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MessageOnRelease</emphasis></entry>
+ <entry>
+If set, key release events generate an <emphasis>
+XkbActionMessage</emphasis>
+ event that reports the keycode, event type, and contents of the <emphasis>
+message</emphasis>
+ field.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_MessageGenKeyEvent</emphasis></entry>
+ <entry>
+If set, key press and key release events generate <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events, regardless of whether they generate <emphasis>
+XkbActionMessage</emphasis>
+ events.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+message</emphasis>
+ field is an array of <emphasis>
+XkbActionMessageLength</emphasis>
+ unsigned characters and may be set to anything the keymap designer wishes.
+</para>
+
+<sect3 id='detecting_key_action_messages'>
+<title>Detecting Key Action Messages</title>
+
+<para>
+To receive <emphasis>
+XkbActionMessage</emphasis>
+ events by calling either <emphasis>
+XkbSelectEvents</emphasis>
+ or <emphasis>
+XkbSelectEventDetails</emphasis>
+ (see section 4.3).
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbActionMessage</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ and pass <emphasis>
+XkbActionMessageMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+XkbActionMessage</emphasis>
+ event has no event details. However, you can call <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbActionMessage</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying <emphasis>
+XkbAllActionMessageMask</emphasis>
+ in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits.</emphasis>
+ This has the same effect as a call to <emphasis>
+XkbSelectEvents</emphasis>.
+</para>
+
+
+<para>
+The structure for the <emphasis>
+XkbActionMessage</emphasis>
+ event is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct _XkbActionMessage {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis>True</emphasis> =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis>XkbActionMessage</emphasis> */
+ int device; /* Xkb device ID, will not be <emphasis> XkbUseCoreKbd</emphasis> */
+ KeyCode keycode; /* keycode of key triggering event */
+ Bool press; /* <emphasis>True</emphasis> =&gt; key press,
+ <emphasis>False</emphasis> =&gt; release */
+ Bool key_event_follows; /* <emphasis>True</emphasis> =&gt; KeyPress/KeyRelease follows */
+ char message[XkbActionMessageLength+1]; /* message text */
+} <emphasis>XkbActionMessageEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+keycode</emphasis>
+ is the keycode of the key that was pressed or released. The <emphasis>
+press</emphasis>
+ field specifies whether the event was the result of a key press or key
+release.
+</para>
+
+
+<para>
+The <emphasis>
+key_event_follows</emphasis>
+ specifies whether a <emphasis>
+KeyPress</emphasis>
+ (if <emphasis>
+press</emphasis>
+ is <emphasis>
+True</emphasis>
+) or <emphasis>
+KeyRelease</emphasis>
+ (if <emphasis>
+press</emphasis>
+ is <emphasis>
+False</emphasis>
+) event is also sent to the client. As with all other Xkb events, <emphasis>
+XkbActionMessageEvent</emphasis>
+s are delivered to all clients requesting them, regardless of the current
+keyboard focus. However, the <emphasis>
+KeyPress</emphasis>
+ or <emphasis>
+KeyRelease</emphasis>
+ event that conditionally follows an <emphasis>
+XkbActionMessageEvent</emphasis>
+ is sent only to the client selected by the current keyboard focus. <emphasis>
+key_event_follows</emphasis>
+ is <emphasis>
+True</emphasis>
+ only for the client that is actually sent the following <emphasis>
+KeyPress</emphasis>
+ or <emphasis>
+KeyRelease</emphasis>
+ event.
+</para>
+
+
+<para>
+The <emphasis>
+message</emphasis>
+ field is set to the message specified in the action and is guaranteed to be
+<emphasis>
+NULL</emphasis>
+-terminated; the Xkb extension forces a <emphasis>
+NULL</emphasis>
+ into <emphasis>
+message</emphasis>
+[<emphasis>
+XkbActionMessageLength</emphasis>
+].
+</para>
+
+
+</sect3>
+</sect2>
+<sect2 id='actions_for_generating_a_different_keycode'>
+<title>Actions for Generating a Different Keycode</title>
+
+<para>
+Actions associated with the <emphasis>
+XkbRedirectKeyAction</emphasis>
+ structure generate <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events containing a keycode different from the key that was pressed or
+released:
+</para>
+
+<para><programlisting>
+typedef struct _XkbRedirectKeyAction {
+ unsigned char type; /* <emphasis> XkbSA_RedirectKey</emphasis> */
+ unsigned char new_key; /* keycode to be put in event */
+ unsigned char mods_mask; /* mask of real mods to be reset */
+ unsigned char mods; /* mask of real mods to take values from */
+ unsigned char vmods_mask0; /* first half of mask of virtual mods to be reset */
+ unsigned char vmods_mask1; /* other half of mask of virtual mods to be reset */
+ unsigned char vmods0; /* first half of mask of virtual mods to take values from */
+ unsigned char vmods1; /* other half of mask of virtual mods to take values from */
+} <emphasis>XkbRedirectKeyAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field for the <emphasis>
+XkbRedirectKeyAction</emphasis>
+ structure should always be <emphasis>
+XkbSA_RedirectKey</emphasis>
+.
+</para>
+
+
+<para>
+Key presses cause a <emphasis>
+KeyPress</emphasis>
+ event for the key specified by the <emphasis>
+new_key</emphasis>
+ field instead of the actual key. The state reported in this event reports the
+current effective modifiers changed as follows: any real modifiers selected by
+the <emphasis>
+mods_mask</emphasis>
+ field are set to corresponding values from the <emphasis>
+mods</emphasis>
+ field. Any real modifiers bound to the virtual modifiers specified by the
+<emphasis>
+vmods_mask0</emphasis>
+ and <emphasis>
+vmods_mask1</emphasis>
+ fields are either set or cleared, depending on the corresponding values in the
+<emphasis>
+vmods0</emphasis>
+ and <emphasis>
+vmods1</emphasis>
+ fields. If the real and virtual modifier definitions specify conflicting
+values for a single modifier, the real modifier definition has priority.
+</para>
+
+
+<para>
+Key releases cause a <emphasis>
+KeyRelease</emphasis>
+ event for the key specified by the <emphasis>
+new_key</emphasis>
+ field instead of the actual key. The state for this event consists of the
+effective keyboard modifiers at the time of the release, changed as described
+previously.
+</para>
+
+
+<para>
+The <emphasis>
+XkbSA_RedirectKey</emphasis>
+ action normally redirects to another key on the same device as the key that
+caused the event, unless that device does not belong to the input extension
+<emphasis>
+KeyClass</emphasis>
+, in which case this action causes an event on the core keyboard device. (The
+input extension categorizes devices by breaking them into classes. Keyboards,
+and other input devices with keys, are classified as KeyClass devices by the
+input extension.)
+</para>
+
+
+<para>
+The <emphasis>
+vmods_mask0</emphasis>
+ and <emphasis>
+vmods_mask1</emphasis>
+ fields actually represent one <emphasis>
+vmods_mask</emphasis>
+ value, as described in Chapter 7. Xkb provides the following macros, to
+convert between the two formats:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned int <emphasis>
+XkbSARedirectVModsMask</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRedirectKeyAction <emphasis>
+act</emphasis>
+; /* action from which to extract vmods */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSARedirectVModsMask</emphasis>
+ returns the <emphasis>
+vmods_mask0</emphasis>
+ and <emphasis>
+vmods_mask1</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ converted to an unsigned int.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSARedirectSetVModsMask</emphasis>
+(<emphasis>
+act, vm</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRedirectKeyAction <emphasis>
+act</emphasis>
+; /* action in which to set vmods */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+vm</emphasis>
+; /* new value for virtual modifier mask */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSARedirectSetVModsMask</emphasis>
+ sets the <emphasis>
+vmods_mask0</emphasis>
+ and <emphasis>
+vmods_mask1</emphasis>
+ fields of <emphasis>
+act</emphasis>
+ from <emphasis>
+vm</emphasis>
+.
+</para>
+
+
+<para>
+Similarly, the <emphasis>
+vmods0</emphasis>
+ and <emphasis>
+vmods1</emphasis>
+ fields actually represent one <emphasis>
+vmods </emphasis>
+value, as described in Chapter 7. To convert between the two formats, Xkb
+provides the following convenience macros:
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+unsigned int <emphasis>
+XkbSARedirectVMods</emphasis>
+(<emphasis>
+act</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRedirectKeyAction <emphasis>
+act</emphasis>
+; /* action from which to extract vmods */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<literallayout>
+ <emphasis>XkbSARedirectVModsMask</emphasis> returns the <emphasis>vmods0</emphasis>
+ and <emphasis>vmods1</emphasis> fields of <emphasis>act</emphasis>
+ converted to an unsigned int.
+</literallayout>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbSARedirectSetVMods</emphasis>
+(<emphasis>
+act, vm</emphasis>
+) /* macro */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbRedirectKeyAction <emphasis>
+act</emphasis>
+; /* action in which to set vmods */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+v</emphasis>
+; /* new value for virtual modifiers */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+<literallayout>
+ <emphasis> XkbSARedirectSetVModsMask</emphasis> sets the <emphasis>vmods0</emphasis>
+ and <emphasis>vmods1</emphasis> of <emphasis>act</emphasis> from <emphasis>v</emphasis>.
+</literallayout>
+
+</sect2>
+<sect2 id='actions_for_generating_devicebuttonpress_and_devicebuttonrelease'>
+<title>Actions for Generating DeviceButtonPress and DeviceButtonRelease</title>
+
+<para>
+Actions associated with <emphasis>
+XkbDeviceBtnAction</emphasis>
+ structures generate <emphasis>
+DeviceButtonPress</emphasis>
+ and <emphasis>
+DeviceButtonRelease</emphasis>
+ events instead of normal <emphasis>
+KeyPress</emphasis>
+ and <emphasis>
+KeyRelease</emphasis>
+ events:
+</para>
+
+<para><programlisting>
+typedef struct _XkbDeviceBtnAction {
+ unsigned char type; /* <emphasis> XkbSA_DeviceBtn, XkbSA_LockDeviceBtn</emphasis> */
+ unsigned char flags; /* with <emphasis> type</emphasis> , specifies locking or unlocking */
+ unsigned char count; /* controls number of DeviceButtonPress and Release events */
+ unsigned char button; /* index of button on <emphasis> device</emphasis> */
+ unsigned char device; /* device ID of an X input extension device */
+} <emphasis>XkbDeviceBtnAction</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field can have any one of the values shown in Table 16.17.
+</para>
+
+<table frame='none'>
+<title>Device Button Action Types</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_DeviceBtn</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the button specified by this action is logically down, the key press and
+corresponding release are ignored and have no effect. If the device or button
+specified by this action are illegal, this action behaves like <emphasis>
+XkbSA_NoAction</emphasis>.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Otherwise, key presses cause one or more input extension device events instead
+of the usual key press event. If the <emphasis>
+count</emphasis>
+ field is zero, a key press generates a single <emphasis>
+DeviceButtonPress</emphasis>
+ event. If count is greater than zero, a key press event generates <emphasis>
+count</emphasis>
+ pairs of <emphasis>
+DeviceButtonPress</emphasis>
+ and <emphasis>
+DeviceButtonRelease</emphasis>
+ events.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If <emphasis>
+count</emphasis>
+ is zero, a key release generates an input extension <emphasis>
+DeviceButtonRelease</emphasis>
+ event that matches the event generated by the corresponding key press. If
+<emphasis>
+count</emphasis>
+ is nonzero, a key release does not cause a <emphasis>
+DeviceButtonRelease</emphasis>
+ event. Key releases never cause <emphasis>
+KeyRelease</emphasis>
+ events.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockDeviceBtn</emphasis></entry>
+ <entry>
+<itemizedlist>
+ <listitem>
+ <para>
+If the device or button specified by this action are illegal, this action
+behaves like <emphasis>XkbSA_NoAction</emphasis>.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Otherwise, if the specified button is not locked and the <emphasis>
+XkbSA_LockNoLock</emphasis>
+ bit is not set in the <emphasis>
+flags</emphasis>
+ field, a key press generates an input extension <emphasis>
+DeviceButtonPress</emphasis>
+ event instead of a <emphasis>
+KeyPress</emphasis>
+ event and locks the button. If the button is already locked or if <emphasis>
+XkbSA_LockNoLock</emphasis>
+ bit is set in the <emphasis>
+flags</emphasis>
+ field, the key press is ignored and has no effect.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If the corresponding key press was ignored, and if the <emphasis>
+XkbSA_LockNoUnlock</emphasis>
+ bit is not set in the <emphasis>
+flags</emphasis>
+ field, a key release generates an input extension <emphasis>
+DeviceButtonRelease</emphasis>
+ event instead of a <emphasis>
+KeyRelease</emphasis>
+ event and unlocks the button. If the corresponding key press locked a button,
+the key release is ignored and has no effect.
+ </para>
+ </listitem>
+</itemizedlist>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+flags</emphasis>
+ field is composed of the bitwise inclusive OR of the masks shown in Table
+16.18.
+</para>
+
+<table frame='none'>
+<title>Device Button Action Flags</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Flag</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoLock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockDeviceBtn</emphasis>
+, the server only unlocks the button.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_LockNoUnlock</emphasis></entry>
+ <entry>
+If set, and the action type is <emphasis>
+XkbSA_LockDeviceBtn</emphasis>
+, the server only locks the button.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect2>
+<sect2 id='actions_for_simulating_events_from_device_valuators'>
+<title>Actions for Simulating Events from Device Valuators</title>
+
+<para>
+A <emphasis>
+valuator</emphasis>
+ manipulates a range of values for some entity, like a mouse axis, a slider or
+a dial. Actions associated with <emphasis>
+XkbDeviceValuatorAction</emphasis>
+ structures are used to simulate events from one or two input extension device
+valuators.
+</para>
+
+<para><programlisting>
+typedef struct _XkbDeviceValuatorAction {
+ unsigned char type; /*<emphasis> XkbSA_DeviceValuator</emphasis> */
+ unsigned char device; /* device ID */
+ unsigned char v1_what; /* determines how valuator is to behave for valuator 1 */
+ unsigned char v1_ndx; /* specifies a real valuator */
+ unsigned char v1_value; /* the value for valuator 1 */
+ unsigned char v2_what; /* determines how valuator is to behave for valuator 2 */
+ unsigned char v2_ndx; /* specifies a real valuator */
+ unsigned char v2_value; /* the value for valuator 1 */
+} <emphasis>XkbDeviceValuatorAction</emphasis>;
+</programlisting></para>
+
+<para>
+If <emphasis>
+device</emphasis>
+ is illegal or if neither <emphasis>
+v1_ndx</emphasis>
+ nor <emphasis>
+v2_ndx</emphasis>
+ specifies a legal valuator, this action behaves like <emphasis>
+XkbSA_NoAction</emphasis>.
+</para>
+
+
+<para>
+The low four bits of <emphasis>
+v1_what</emphasis>
+ and <emphasis>
+v2_what</emphasis>
+ specify the corresponding scale value (denoted <emphasis>
+val&lt;n&gt;Scale</emphasis>
+ in Table 16.17), if needed. The high four bits of <emphasis>
+v1_what</emphasis>
+ and <emphasis>
+v2_what</emphasis>
+ specify the operation to perform to set the values. The high four bits of
+<emphasis>
+v1_what</emphasis>
+ and <emphasis>
+v2_what</emphasis>
+ can have the values shown in Table 16.17; the use of <emphasis>
+val&lt;n&gt;Scale</emphasis>
+ is shown in that table also.
+</para>
+
+<table frame='none'>
+<title>Device Valuator v&lt;n&gt;_what High Bits Values</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Value of high bits</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_IgnoreVal</emphasis></entry>
+ <entry>No action</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetValMin</emphasis></entry>
+ <entry>
+<emphasis>v&lt;n&gt;_value</emphasis> is set to its minimum legal value.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetValCenter</emphasis></entry>
+ <entry>
+<emphasis>v&lt;n&gt;_value</emphasis>is centered (to (max-min)/2).
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetValMax</emphasis></entry>
+ <entry>
+<emphasis>v&lt;n&gt;_value</emphasis> is set to its maximum legal value.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetValRelative</emphasis></entry>
+ <entry>
+<emphasis>v&lt;n&gt;_value</emphasis> * (2
+<emphasis>val&lt;n&gt;Scale</emphasis>) is added to
+<emphasis>v&lt;n&gt;_value</emphasis>.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSA_SetValAbsolute</emphasis></entry>
+ <entry>
+<emphasis>v&lt;n&gt;_value</emphasis>
+ is set to (2 <emphasis>val&lt;n&gt;Scale</emphasis>).
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Illegal values for <emphasis>
+XkbSA_SetValRelative</emphasis>
+ or <emphasis>
+XkbSA_SetValAbsolute</emphasis>
+ are clamped into range. Note that all of these possibilities are legal for
+absolute valuators. For relative valuators, only <emphasis>
+XkbSA_SetValRelative</emphasis>
+ is permitted. Part of the input extension description of a device is the range
+of legal values for all absolute valuators, whence the maximum and minimum
+legal values shown in Table 16.17.
+</para>
+
+
+<para>
+The following two masks are provided as a convenience to select either portion
+of <emphasis>
+v1_what</emphasis>
+ or <emphasis>
+v2_what</emphasis>
+:
+</para>
+
+<literallayout>
+ #define XkbSA_ValOpMask (0x70)
+ #define XkbSA_ValScaleMask (0x07)
+</literallayout>
+
+<para>
+<emphasis>
+v1_ndx</emphasis>
+ and <emphasis>
+v2_ndx</emphasis>
+ specify valuators that actually exists. For example, most mice have two
+valuators (x and y axes) so the only legal values for a mouse would be 0 and 1.
+For a dial box with eight dials, any value in the range 0..7 would be correct.
+</para>
+
+
+</sect2>
+<sect2 id='obtaining_key_actions_for_keys_from_the_server'>
+<title>Obtaining Key Actions for Keys from the Server</title>
+
+<para>
+To update the actions (the <emphasis>
+key_acts</emphasis>
+ array) for a subset of the keys in a keyboard description, use <emphasis>
+XkbGetKeyActions</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyActions</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+, <emphasis>
+num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first</emphasis>
+; /* keycode of first key of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* number of keys desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* pointer to keyboard description where result is stored */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyActions</emphasis>
+ sends a request to the server to obtain the actions for <emphasis>
+num</emphasis>
+ keys on the keyboard starting with key <emphasis>
+first</emphasis>
+. It waits for a reply and returns the actions in the <emphasis>
+server</emphasis>
+-&gt;<emphasis>
+key_acts</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+. If successful, <emphasis>
+XkbGetKeyActions</emphasis>
+ returns <emphasis>
+Success</emphasis>
+. The <emphasis>
+xkb</emphasis>
+ parameter must be a pointer to a valid Xkb keyboard description.
+</para>
+
+
+<para>
+If the <emphasis>
+server</emphasis>
+ map in the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeyActions</emphasis>
+ allocates and initializes it before obtaining the actions.
+</para>
+
+
+<para>
+If the server does not have a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbGetKeyActions</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If <emphasis>
+num</emphasis>
+ is less than 1 or greater than <emphasis>
+XkbMaxKeyCount</emphasis>
+, <emphasis>
+XkbGetKeyActions</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If any allocation errors occur, <emphasis>
+XkbGetKeyActions</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+
+</sect2>
+<sect2 id='changing_the_number_of_actions_bound_to_a_key'>
+<title>Changing the Number of Actions Bound to a Key</title>
+
+<para>
+To change the number of actions bound to a key, use <emphasis>
+XkbResizeKeyAction</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbAction *<emphasis>
+XkbResizeKeyActions</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ key</emphasis>
+,<emphasis>
+ needed</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescRec *<emphasis>
+ xkb</emphasis>
+; /* keyboard description to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ key</emphasis>
+; /* keycode of key to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ needed</emphasis>
+; /* new number of actions required */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+xkb</emphasis>
+ parameter points to the keyboard description containing the <emphasis>
+key</emphasis>
+ whose number of actions is to be changed. The <emphasis>
+key</emphasis>
+ parameter is the keycode of the key to change, and <emphasis>
+needed</emphasis>
+ specifies the new number of actions required for the key.
+</para>
+
+
+<para>
+<emphasis>
+XkbResizeKeyActions</emphasis>
+ reserves the space needed for the actions and returns a pointer to the
+beginning of the new array that holds the actions. It can change the <emphasis>
+acts</emphasis>
+, <emphasis>
+num_acts</emphasis>
+, and <emphasis>
+size_acts</emphasis>
+ fields of <emphasis>
+xkb</emphasis>
+-&gt;<emphasis>
+server</emphasis>
+ if it is necessary to reallocate the <emphasis>
+acts </emphasis>
+array.
+</para>
+
+
+<para>
+If <emphasis>
+needed</emphasis>
+ is greater than the current number of keysyms for the key, <emphasis>
+XkbResizeKeyActions</emphasis>
+ initializes all new actions in the array to <emphasis>
+NoAction</emphasis>
+.
+</para>
+
+
+<para>
+Because the number of actions needed by a key is normally computed as width *
+number of groups, and <emphasis>
+XkbResizeKeyActions</emphasis>
+ does not modify either the width or number of groups for the key, a
+discrepancy exists on return from <emphasis>
+XkbResizeKeyActions</emphasis>
+ between the space allocated for the actions and the number required. The
+unused entries in the list of actions returned by <emphasis>
+XkbResizeKeyActions</emphasis>
+ are not preserved across future calls to any of the map editing functions, so
+you must update the key actions (which updates the width and number of groups
+for the key) before calling another allocator function. A call to <emphasis>
+XkbChangeTypesOfKey</emphasis>
+ updates these.
+</para>
+
+
+<para>
+If any allocation errors occur while resizing the number of actions bound to
+the key, <emphasis>
+XkbResizeKeyActions</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+.
+</para>
+
+<note><para>A change to the number of actions bound to a key should be
+accompanied by a change in the number of symbols bound to a key. Refer to
+section 15.3.7 for more information on changing the number of symbols bound to
+a key.</para></note>
+
+
+</sect2>
+</sect1>
+<sect1 id='key_behavior'>
+<title>Key Behavior</title>
+
+<para>
+Key behavior refers to the demeanor of a key. For example, the expected
+behavior of the <emphasis>
+CapsLock</emphasis>
+ key is that it logically locks when pressed, and then logically unlocks when
+pressed again.
+</para>
+
+
+<sect2 id='radio_groups2'>
+<title>Radio Groups</title>
+
+<para>
+Keys that belong to the same radio group have the <emphasis>
+XkbKB_RadioGroup</emphasis>
+ type in the <emphasis>
+type</emphasis>
+ field and the radio group index specified in the <emphasis>
+data</emphasis>
+ field in the <emphasis>
+XkbBehavior</emphasis>
+ structure. If the radio group has a name in the <emphasis>
+XkbNamesRec</emphasis>
+ structure, the radio group index is the index into the <emphasis>
+radio_group</emphasis>
+ array in the <emphasis>
+XkbNamesRec</emphasis>
+ structure. A radio group key when pressed stays logically down until another
+key in the radio group is pressed, when the first key becomes logically up and
+the new key becomes logically down. Setting the <emphasis>
+XkbKB_RGAllowNone</emphasis>
+ bit in the behavior for all of the keys of the radio group means that pressing
+the logically down member of the radio group causes it to logically release, in
+which case none of the keys of the radio group would be logically down. If
+<emphasis>
+XkbKB_RGAllowNone</emphasis>
+ is not set, there is no way to release the logically down member of the group.
+</para>
+
+
+<para>
+The low five bits of the <emphasis>
+data</emphasis>
+ field of the <emphasis>
+XkbBehavior</emphasis>
+ structure are the group number, the high three bits are flags. The only flag
+currently defined is:
+</para>
+
+<para><programlisting>
+#define XkbRG_AllowNone 0x80
+</programlisting></para>
+
+</sect2>
+<sect2 id='the_xkbbehavior_structure'>
+<title>The XkbBehavior Structure</title>
+
+<para>
+The <emphasis>
+behaviors</emphasis>
+ field of the server map is an array of <emphasis>
+XkbBehavior</emphasis>
+ structures, indexed by keycode, and contains the behavior for each key. The
+<emphasis>
+XkbBehavior</emphasis>
+ structure is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct _XkbBehavior {
+ unsigned char type; /* behavior type + optional
+ <emphasis> XkbKB_Permanent</emphasis> bit */
+ unsigned char data;
+} <emphasis>XkbBehavior</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field specifies the Xkb behavior, and the value of the <emphasis>
+data</emphasis>
+ field depends on the <emphasis>
+type</emphasis>
+. Xkb supports the key behaviors shown in Table 16.20.
+</para>
+
+<table frame='none'>
+<title>Key Behaviors</title>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Type</entry>
+ <entry>Effect</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKB_Default</emphasis></entry>
+ <entry>
+Press and release events are processed normally. The <emphasis>
+data</emphasis>
+ field is unused.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKB_Lock</emphasis></entry>
+ <entry>
+If a key is logically up (that is, the corresponding bit of the core key map is
+cleared) when it is pressed, the key press is processed normally and the
+corresponding release is ignored. If the key is logically down when pressed,
+the key press is ignored but the corresponding release is processed normally.
+The <emphasis>
+data</emphasis>
+ field is unused.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKB_RadioGroup</emphasis></entry>
+ <entry>
+ <para>
+If another member of the radio group is logically down (all members of the
+radio group have the same index, specified in <emphasis>
+data</emphasis>
+) when a key is pressed, the server synthesizes a key release for the member
+that is logically down and then processes the new key press event normally.
+ </para>
+ <para>
+If the key itself is logically down when pressed, the key press event is
+ignored, but the processing of the corresponding key release depends on the
+value of the <emphasis>
+Xkb_RGAllowNone</emphasis>
+ bit in <emphasis>
+flags</emphasis>
+. If it is set, the key release is processed normally; otherwise, the key
+release is also ignored.
+ </para>
+ <para>
+All other key release events are ignored.
+ </para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKB_Overlay1</emphasis></entry>
+ <entry>
+If the <emphasis>
+Overlay1</emphasis>
+ control is enabled (see section 10.4), <emphasis>
+data</emphasis>
+ is interpreted as a keycode, and events from this key are reported as if they
+came from <emphasis>
+data</emphasis>
+’s keycode. Otherwise, press and release events are processed normally.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbKB_Overlay2</emphasis></entry>
+ <entry>
+If the <emphasis>
+Overlay2</emphasis>
+ control is enabled (see section 10.4), <emphasis>
+data</emphasis>
+ is interpreted as a keycode, and events from this key are reported as if they
+came from <emphasis>
+data</emphasis>
+’s keycode. Otherwise, press and release events are processed normally.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+Xkb also provides the mask, <emphasis>
+XkbKB_Permanent</emphasis>
+ to specify whether the key behavior type should be simulated by Xkb or whether
+the key behavior describes an unalterable physical, electrical, or software
+aspect of the keyboard. If the <emphasis>
+XkbKB_Permanent</emphasis>
+ bit is not set in the <emphasis>
+type</emphasis>
+ field, Xkb simulates the behavior in software. Otherwise, Xkb relies upon the
+keyboard to implement the behavior.
+</para>
+
+
+</sect2>
+<sect2 id='obtaining_key_behaviors_for_keys_from_the_server'>
+<title>Obtaining Key Behaviors for Keys from the Server</title>
+
+<para>
+To obtain the behaviors (the <emphasis>
+behaviors</emphasis>
+ array) for a subset of the keys in a keyboard description from the server, use
+<emphasis>
+XkbGetKeyBehaviors</emphasis>
+:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyBehaviors</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first</emphasis>
+; /* keycode of first key to get */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* number of keys for which behaviors are desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description to contain the result */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyBehaviors</emphasis>
+ sends a request to the server to obtain the behaviors for <emphasis>
+num</emphasis>
+ keys on the keyboard starting with the key whose keycode is <emphasis>
+first</emphasis>
+. It waits for a reply and returns the behaviors in the <emphasis>
+server</emphasis>
+-&gt;<emphasis>
+behaviors</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+. If successful, <emphasis>
+XkbGetKeyBehaviors</emphasis>
+ returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<para>
+If the <emphasis>
+server</emphasis>
+ map in the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeyBehaviors</emphasis>
+ allocates and initializes it before obtaining the actions.
+</para>
+
+
+<para>
+If the server does not have a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbGetKeyBehaviors</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If <emphasis>
+num</emphasis>
+ is less than 1 or greater than <emphasis>
+XkbMaxKeyCount</emphasis>
+, <emphasis>
+XkbGetKeyBehaviors</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If any allocation errors occur, <emphasis>
+XkbGetKeyBehaviors</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='explicit_components_avoiding_automatic_remapping_by_the_server'>
+<title>Explicit Components—Avoiding Automatic Remapping by the Server</title>
+
+<para>
+Whenever a client remaps the keyboard using core protocol requests, Xkb
+examines the map to determine likely default values for the components that
+cannot be specified using the core protocol (see section 17.1.2 for more
+information on how Xkb chooses the default values).
+</para>
+
+
+<para>
+This automatic remapping might replace definitions explicitly requested by an
+application, so the Xkb keyboard description defines an explicit components
+mask for each key. Any aspects of the automatic remapping listed in the
+explicit components mask for a key are not changed by the automatic keyboard
+mapping.
+</para>
+
+
+<para>
+The explicit components masks are held in the <emphasis>
+explicit</emphasis>
+ field of the server map, which is an array indexed by keycode. Each entry in
+this array is a mask that is a bitwise inclusive OR of the values shown in
+Table 16.21.
+</para>
+
+<table frame='none'>
+<title>Explicit Component Masks</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Bit in Explicit Mask</entry>
+ <entry>Value</entry>
+ <entry>Protects Against</entry>
+</row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitKeyType1</emphasis></entry>
+ <entry>(1&lt;&lt;0)</entry>
+ <entry>
+Automatic determination of the key type associated with <emphasis>
+Group1.</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitKeyType2</emphasis></entry>
+ <entry>(1&lt;&lt;1)</entry>
+ <entry>
+Automatic determination of the key type associated with <emphasis>
+Group2.</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitKeyType3</emphasis></entry>
+ <entry>(1&lt;&lt;2)</entry>
+ <entry>
+Automatic determination of the key type associated with <emphasis>
+Group3.</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitKeyType4</emphasis></entry>
+ <entry>(1&lt;&lt;3)</entry>
+ <entry>
+Automatic determination of the key type associated with <emphasis>
+Group4.</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitInterpret</emphasis></entry>
+ <entry>(1&lt;&lt;4)</entry>
+ <entry>
+Application of any of the fields of a symbol interpretation to the
+key in question.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitAutoRepeat</emphasis></entry>
+ <entry>(1&lt;&lt;5)</entry>
+ <entry>Automatic determination of auto-repeat status for the key, as
+specified in a symbol interpretation.</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitBehavior</emphasis></entry>
+ <entry>(1&lt;&lt;6)</entry>
+ <entry>
+Automatic assignment of the <emphasis>
+XkbKB_Lock</emphasis>
+ behavior to the key, if the <emphasis>
+XkbSI_LockingKey</emphasis>
+ flag is set in a symbol interpretation.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>ExplicitVModMap</emphasis></entry>
+ <entry>(1&lt;&lt;7)</entry>
+ <entry>
+Automatic determination of the virtual modifier map for the key
+based on the actions assigned to the key and the symbol interpretations that
+match the key.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<sect2 id='obtaining_explicit_components_for_keys_from_the_server'>
+<title>Obtaining Explicit Components for Keys from the Server</title>
+
+<para>
+To obtain the explicit components (the <emphasis>
+explicit</emphasis>
+ array) for a subset of the keys in a keyboard description, use <emphasis>
+XkbGetKeyExplicitComponents</emphasis>.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first</emphasis>
+; /* keycode of first key to fetch */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* number of keys for which to get explicit info */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description in which to put results */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ sends a request to the server to obtain the explicit components for <emphasis>
+num</emphasis>
+ keys on the keyboard starting with key <emphasis>
+first</emphasis>
+. It waits for a reply and returns the explicit components in the <emphasis>
+server</emphasis>
+-&gt;<emphasis>
+explicit</emphasis>
+ array of <emphasis>
+xkb</emphasis>
+. If successful, <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ returns <emphasis>
+Success</emphasis>
+. The <emphasis>
+xkb</emphasis>
+ parameter must be a pointer to a valid Xkb keyboard description.
+</para>
+
+
+<para>
+If the <emphasis>
+server</emphasis>
+ map in the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ allocates and initializes it before obtaining the actions.
+</para>
+
+
+<para>
+If the server does not have a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ returns <emphasis>
+BadMatch</emphasis>
+. If <emphasis>
+num</emphasis>
+ is less than 1 or greater than <emphasis>
+XkbMaxKeyCount</emphasis>
+, <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If any allocation errors occur, <emphasis>
+XkbGetKeyExplicitComponents</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='virtual_modifier_mapping'>
+<title>Virtual Modifier Mapping</title>
+
+<para>
+The <emphasis>
+vmods</emphasis>
+ member of the server map is a fixed-length array containing <emphasis>
+XkbNumVirtualMods</emphasis>
+ entries. Each entry corresponds to a virtual modifier and provides the binding
+of the virtual modifier to the real modifier bits. Each entry in the <emphasis>
+vmods</emphasis>
+ array is a bitwise inclusive OR of the legal modifier masks:
+</para>
+
+<literallayout>
+ <emphasis>ShiftMask</emphasis>
+ <emphasis>LockMask</emphasis>
+ <emphasis>ControlMask</emphasis>
+ <emphasis>Mod1Mask</emphasis>
+ <emphasis>Mod2Mask</emphasis>
+ <emphasis>Mod3Mask</emphasis>
+ <emphasis>Mod4Mask</emphasis>
+ <emphasis>Mod5Mask</emphasis>
+</literallayout>
+
+<para>
+The <emphasis>
+vmodmap</emphasis>
+ member of the server map is similar to the <emphasis>
+modmap</emphasis>
+ array of the client map (see section 15.4), but is used to define the virtual
+modifier mapping for each key. Like the <emphasis>
+modmap</emphasis>
+ member, it is indexed by keycode, and each entry is a mask representing the
+virtual modifiers bound to the corresponding key:
+</para>
+
+<itemizedlist>
+ <listitem>
+ <para>
+Each of the bits in a <emphasis>
+vmodmap</emphasis>
+ entry represents an index into the <emphasis>
+vmods</emphasis>
+ member. That is, bit 0 of a <emphasis>
+vmodmap</emphasis>
+ entry refers to index 0 of the <emphasis>
+vmods</emphasis>
+ array, bit 1 refers to index 1, and so on.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+If a bit is set in the <emphasis>
+vmodmap</emphasis>
+ entry for a key, that key is bound to the corresponding virtual modifier in
+the <emphasis>
+vmods</emphasis>
+ array.
+ </para>
+ </listitem>
+</itemizedlist>
+
+<para>
+The <emphasis>
+vmodmap</emphasis>
+ and <emphasis>
+vmods</emphasis>
+ members of the server map are the "master" virtual modifier definitions. Xkb
+automatically propagates any changes to these fields to all other fields that
+use virtual modifier mappings.
+</para>
+
+
+<para>
+The overall relationship of fields dealing with virtual modifiers in an Xkb
+keyboard description are shown in Figure 16.2.
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-17.svg"/>
+ </imageobject>
+<caption>Virtual Modifier Relationships</caption>
+</mediaobject>
+
+
+
+<!--
+<H5 CLASS="Figure">
+Virtual Modifier Relationships</H5>
+-->
+
+<sect2 id='obtaining_virtual_modifier_bindings_from_the_server'>
+<title>Obtaining Virtual Modifier Bindings from the Server</title>
+
+<para>
+To obtain a subset of the virtual modifier bindings (the <emphasis>
+vmods</emphasis>
+ array) in a keyboard description, use <emphasis>
+XkbGetVirtualMods</emphasis>
+:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetVirtualMods</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ which</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask indicating virtual modifier bindings to get */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description where results will be placed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetVirtualMods</emphasis>
+ sends a request to the server to obtain the <emphasis>
+vmods</emphasis>
+ entries for the virtual modifiers specified in the mask, <emphasis>
+which</emphasis>
+, and waits for a reply. See section 7.1 for a description of how to determine
+the virtual modifier mask. For each bit set in <emphasis>
+which</emphasis>
+, <emphasis>
+XkbGetVirtualMods</emphasis>
+ updates the corresponding virtual modifier definition in the <emphasis>
+server-&gt;vmods</emphasis>
+ array of <emphasis>
+xkb</emphasis>
+. The <emphasis>
+xkb</emphasis>
+ parameter must be a pointer to a valid Xkb keyboard description. If
+successful, <emphasis>
+XkbGetVirtualMods</emphasis>
+ returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<para>
+If the <emphasis>
+server</emphasis>
+ map has not been allocated in the <emphasis>
+xkb</emphasis>
+ parameter, <emphasis>
+XkbGetVirtualMods</emphasis>
+ allocates and initializes it before obtaining the virtual modifier bindings.
+</para>
+
+
+<para>
+If the server does not have a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbGetVirtualMods</emphasis>
+ returns <emphasis>
+BadMatch</emphasis>
+. Any errors in allocation cause <emphasis>
+XkbGetVirtualMods </emphasis>
+to return <emphasis>
+BadAlloc</emphasis>.
+</para>
+
+
+</sect2>
+<sect2 id='obtaining_per_key_virtual_modifier_mappings_from_the_server'>
+<title>Obtaining Per-Key Virtual Modifier Mappings from the Server</title>
+
+<para>
+To obtain the virtual modifier map (the <emphasis>
+vmodmap</emphasis>
+ array) for a subset of the keys in a keyboard description, use <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ first</emphasis>
+,<emphasis>
+ num</emphasis>
+,<emphasis>
+ xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display *<emphasis>
+ dpy</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first</emphasis>
+; /* keycode of first key to fetch */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num</emphasis>
+; /* # keys for which virtual mod maps are desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* Xkb description where results will be placed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyVirutalModmap </emphasis>
+sends a request to the server to obtain the virtual modifier mappings for
+<emphasis>
+num</emphasis>
+ keys on the keyboard starting with key <emphasis>
+first</emphasis>
+. It waits for a reply and returns the virtual modifier mappings in the
+<emphasis>
+server</emphasis>
+-&gt;<emphasis>
+vmodmap</emphasis>
+ array of <emphasis>
+xkb</emphasis>
+. If successful, <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+ returns <emphasis>
+Success</emphasis>
+. The <emphasis>
+xkb</emphasis>
+ parameter must be a pointer to a valid Xkb keyboard description
+</para>
+
+
+<para>
+If the <emphasis>
+server</emphasis>
+ map in the <emphasis>
+xkb</emphasis>
+ parameter has not been allocated, <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+ allocates and initializes it before obtaining the virtual modifier mappings.
+</para>
+
+
+<para>
+If the server does not have a compatible version of Xkb, or the Xkb extension
+has not been properly initialized, <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+ returns <emphasis>
+BadMatch</emphasis>
+. If <emphasis>
+num</emphasis>
+ is less than 1 or greater than <emphasis>
+XkbMaxKeyCount</emphasis>
+, <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+ returns <emphasis>
+BadValue</emphasis>
+. If any allocation errors occur, <emphasis>
+XkbGetKeyVirtualModMap</emphasis>
+ returns <emphasis>
+BadAlloc</emphasis>
+.
+</para>
+
+</sect2>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch17.xml b/libX11/specs/XKB/ch17.xml
new file mode 100644
index 000000000..3c44da5c1
--- /dev/null
+++ b/libX11/specs/XKB/ch17.xml
@@ -0,0 +1,1789 @@
+<chapter id='the_xkb_compatibility_map'>
+<title>The Xkb Compatibility Map</title>
+
+<para>
+As shown in Figure 17.1, the X server is normally dealing with more than one
+client, each of which may be receiving events from the keyboard, and each of
+which may issue requests to modify the keyboard in some manner. Each client may
+be either Xkb-unaware, Xkb-capable, or Xkb-aware. The server itself may be
+either Xkb-aware or Xkb-unaware. If the server is Xkb-unaware, Xkb state and
+keyboard mappings are not involved in any manner, and Xkb-aware clients may not
+issue Xkb requests to the server. If the server is Xkb-aware, the server must
+be able to deliver events and accept requests in which the keyboard state and
+mapping are compatible with the mode in which the client is operating.
+Consequently, for some situations, conversions must be made between Xkb state /
+keyboard mappings and core protocol state / keyboard mappings, and vice versa.
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-18.svg"/>
+ </imageobject>
+ <caption>Server Interaction with Types of Clients</caption>
+</mediaobject>
+
+
+
+<para>
+In addition to these situations involving a single server, there are cases
+where a client that deals with multiple servers may need to configure keyboards
+on different servers to be similar and the different servers may not all be
+Xkb-aware. Finally, a client may be dealing with descriptions of keyboards
+(files, and so on) that are based on core protocol and therefore may need to be
+able to map these descriptions to Xkb descriptions.
+</para>
+
+
+<para>
+An Xkb-aware server maintains keyboard state and mapping as an Xkb keyboard
+state and an Xkb keyboard mapping plus a compatibility map used to convert from
+Xkb components to core components and vice versa. In addition, the server also
+maintains a core keyboard mapping that approximates the Xkb keyboard mapping.
+The core keyboard mapping may be updated piecemeal, on a per-key basis. When
+the server receives a core protocol <emphasis>
+ChangeKeyboardMapping</emphasis>
+ or <emphasis>
+SetModifierMapping</emphasis>
+ request, it updates its core keyboard mapping, then uses the compatibility map
+to update its Xkb keyboard mapping. When the server receives an <emphasis>
+XkbSetMap</emphasis>
+ request, it updates those portions of its Xkb keyboard mapping specified by
+the request, then uses its compatibility map to update the corresponding parts
+of its core keyboard map. Consequently, the server’s Xkb keyboard map and
+also its core keyboard map may contain components that were set directly and
+others that were computed. Figure 17.2 illustrates these relationships.
+</para>
+
+<note><para>The core keyboard map is contained only in the server, not in any
+client-side data structures.</para></note>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-19.svg"/>
+ </imageobject>
+ <caption>Server Derivation of State and Keyboard Mapping Components</caption>
+</mediaobject>
+
+
+
+<para>
+There are three kinds of compatibility transformations made by the server:
+</para>
+
+<orderedlist>
+ <listitem>
+ <para><emphasis role='bold'>Xkb State to Core State</emphasis></para>
+ <para>
+Keyboard state information reported to a client in the state field of various
+core events may be translated from the Xkb keyboard state maintained by the
+server, which includes a group number, to core protocol state, which does
+not.
+ </para>
+ <para>
+In addition, whenever the Xkb state is retrieved, the <emphasis>
+compat_state</emphasis>
+, <emphasis>
+compat_grab_mods</emphasis>
+, and <emphasis>
+compat_lookup_mods</emphasis>
+ fields of the <emphasis>
+XkbStateRec</emphasis>
+ returned indicate the result of applying the compatibility map to the current
+Xkb state in the server.
+ </para>
+ </listitem>
+ <listitem>
+ <para><emphasis role='bold'>Core Keyboard Mapping to Xkb Keyboard Mapping</emphasis></para>
+ <para>
+After core protocol requests received by the server to change the keyboard
+mapping (<emphasis>
+ChangeKeyboardMapping</emphasis>
+ and <emphasis>
+SetModifierMapping</emphasis>
+) have been applied to the server’s core keyboard map, the results must be
+transformed to achieve an equivalent change of the Xkb keyboard mapping
+maintained by the server.
+ </para>
+ </listitem>
+ <listitem>
+ <para><emphasis role='bold'>Xkb Keyboard Mapping to Core Keyboard Mapping</emphasis></para>
+ <para>
+After Xkb protocol requests received by the server to change the keyboard
+mapping (<emphasis>
+XkbSetMap</emphasis>
+) have been applied to the server’s Xkb keyboard map, the results are
+transformed to achieve an approximately equivalent change to the core keyboard
+mapping maintained by the server.
+ </para>
+ </listitem>
+</orderedlist>
+
+<para>
+This chapter discusses how a client may modify the compatibility map so that
+subsequent transformations have a particular result.
+</para>
+
+
+<sect1 id='the_xkbcompatmap_structure'>
+<title>The XkbCompatMap Structure</title>
+
+<para>
+All configurable aspects of mapping Xkb state and configuration to and from
+core protocol state and configuration are defined by a compatibility map,
+contained in an <emphasis>
+XkbCompatMap</emphasis>
+ structure; plus a set of explicit override controls used to prevent particular
+components of type 2 (core-to-Xkb keyboard mapping) transformations from
+automatically occurring. These explicit override controls are maintained in a
+separate data structure discussed in section 16.3. <!-- xref -->
+</para>
+
+
+<para>
+The <emphasis>
+compat</emphasis>
+ member of an Xkb keyboard description (<emphasis>
+XkbDescRec</emphasis>
+) points to the<emphasis>
+ XkbCompatMap</emphasis>
+ structure:
+</para>
+
+<para><programlisting>
+typedef struct _XkbCompatMapRec {
+ XkbSymInterpretPtr sym_interpret; /* symbol based key semantics*/
+ XkbModsRec groups[XkbNumKbdGroups]; /* group =&gt; modifier map */
+ unsigned short num_si; /* # structures used in
+ <emphasis>sym_interpret</emphasis> */
+ unsigned short size_si; /* # structures allocated in
+ <emphasis>sym_interpret</emphasis> */
+} <emphasis>XkbCompatMapRec</emphasis>, *XkbCompatMapPtr;
+</programlisting></para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-20.svg"/>
+ </imageobject>
+ <caption>Xkb Compatibility Data Structures</caption>
+</mediaobject>
+
+
+<para>
+The subsections that follow discuss how the compatibility map and explicit
+override controls are used in each of the three cases where compatibility
+transformations are made.
+</para>
+
+<sect2 id='xkb_state_to_core_protocol_state_transformation'>
+<title>Xkb State to Core Protocol State Transformation</title>
+
+<para>
+As shown in Figure 17.3, there are four <emphasis>
+group compatibility maps</emphasis>
+ (contained in <emphasis>
+groups</emphasis>
+ [0..3]) in the <emphasis>
+XkbCompatMapRec</emphasis>
+ structure, one per possible Xkb group. Each group compatibility map is a
+modifier definition (see section 7.2 for a description of modifier
+definitions). The <emphasis>
+mask</emphasis>
+ component of the definition specifies which real modifiers should be set in
+the core protocol state field when the corresponding group is active. Because
+only one group is active at any one time, only one of the four possible
+transformations is ever applied at any one point in time. If the device
+described by the <emphasis>
+XkbDescRec</emphasis>
+ does not support four groups, the extra groups fields are present, but
+undefined.
+</para>
+
+<para>
+Normally, the Xkb-aware server reports keyboard state in the <emphasis>
+state</emphasis>
+ member of events such as a <emphasis>
+KeyPress</emphasis>
+ event and <emphasis>
+ButtonPress</emphasis>
+ event, encoded as follows:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='0'>
+ <entry>bits</entry>
+ <entry>meaning</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>15</entry>
+ <entry>0</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>13-14</entry>
+ <entry>Group index</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>8-12</entry>
+ <entry>Pointer Buttons</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>0-7</entry>
+ <entry>Modifiers</entry>
+ </row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+For Xkb-unaware clients, only core protocol keyboard information may be
+reported. Because core protocol does not define the group index, the group
+index is mapped to modifier bits as specified by the <emphasis>
+groups</emphasis>
+[group index] field of the compatibility map (the bits set in the compatibility
+map are ORed into bits 0-7 of the state), and bits 13-14 are reported in the
+event as zero.
+</para>
+
+</sect2>
+<sect2 id='core_keyboard_mapping_to_xkb_keyboard_mapping_transformation'>
+<title>Core Keyboard Mapping to Xkb Keyboard Mapping Transformation</title>
+
+<para>
+When a core protocol keyboard mapping request is received by the server, the
+server’s core keyboard map is updated, and then the Xkb map maintained by the
+server is updated. Because a client may have explicitly configured some of the
+Xkb keyboard mapping in the server, this automatic regeneration of the Xkb
+keyboard mapping from the core protocol keyboard mapping should not modify any
+components of the Xkb keyboard mapping that were explicitly set by a client.
+The client must set explicit override controls to prevent this from happening
+(see section 16.3). The core-to-Xkb mapping is done as follows:
+</para>
+
+<orderedlist>
+ <listitem>
+ <para>
+Map the symbols from the keys in the core keyboard map to groups and symbols on
+keys in the Xkb keyboard map. The core keyboard mapping is of fixed width, so
+each key in the core mapping has the same number of symbols associated with it.
+The Xkb mapping allows a different number of symbols to be associated with each
+key; those symbols may be divided into a different number of groups (1-4) for
+each key. For each key, this process therefore involves partitioning the fixed
+number of symbols from the core mapping into a set of variable-length groups
+with a variable number of symbols in each group. For example, if the core
+protocol map is of width five, the partition for one key might result in one
+group with two symbols and another with three symbols. A different key might
+result in two groups with two symbols plus a third group with one symbol. The
+core protocol map requires at least two symbols in each of the first two
+groups.
+ </para>
+ <orderedlist>
+ <listitem>
+ <para>
+For each changed key, determine the number of groups represented in the new
+core keyboard map. This results in a tentative group count for each key in the
+Xkb map.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+For each changed key, determine the number of symbols in each of the groups
+found in step 1a. There is one explicit override control associated with each
+of the four possible groups for each Xkb key, <emphasis>
+ExplicitKeyType1</emphasis>
+ through <emphasis>
+ExplicitKeyType4</emphasis>
+. If no explicit override control is set for a group, the number of symbols
+used for that group from the core map is two. If the explicit override control
+is set for a group on the key, the number of symbols used for that Xkb group
+from the core map is the width of the Xkb group with one exception: because of
+the core protocol requirement for at least two symbols in each of groups one
+and two, the number of symbols used for groups one and two is the maximum of 2
+or the width of the Xkb group.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+For each changed key, assign the symbols in the core map to the appropriate
+group on the key. If the total number of symbols required by the Xkb map for a
+particular key needs more symbols than the core protocol map contains, the
+additional symbols are taken to be <emphasis>
+NoSymbol</emphasis>
+ keysyms appended to the end of the core set. If the core map contains more
+symbols than are needed by the Xkb map, trailing symbols in the core map are
+discarded. In the absence of an explicit override for group one or two, symbols
+are assigned in order by group; the first symbols in the core map are assigned
+to group one, in order, followed by group two, and so on. For example, if the
+core map contained eight symbols per key, and a particular Xkb map contained 2
+symbols for G1 and G2 and three for G3, the symbols would be assigned as (G is
+group, L is shift level):
+ </para>
+<literallayout>
+ G1L1 G1L2 G2L1 G2L2 G3L1 G3L2 G3L3
+</literallayout>
+ <para>
+If an explicit override control is set for group one or two, the symbols are
+taken from the core set in a somewhat different order. The first four symbols
+from the core set are assigned to G1L1, G1L2, G2L1, G2L2, respectively. If
+group one requires more symbols, they are taken next, and then any additional
+symbols needed by group two. Group three and four symbols are taken in complete
+sequence after group two. For example, a key with four groups and three symbols
+in each group would take symbols from the core set in the following order:
+ </para>
+<literallayout>
+G1L1 G1L2 G2L1 G2L2 G1L3 G2L3 G3L1 G3L2 G3L3 G4L1 G4L2 G4L3
+</literallayout>
+ <para>
+As previously noted, the core protocol map requires at lease two symbols in
+groups one and two. Because of this, if an explicit override control for an Xkb
+key is set and group one and / or group two is of width one, it is not possible
+to generate the symbols taken from the core protocol set and assigned to
+position G1L2 and / or G2L2.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+For each group on each changed key, assign a key type appropriate for the
+symbols in the group.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+For each changed key, remove any empty or redundant groups.
+ </para>
+ </listitem>
+ </orderedlist>
+ </listitem>
+ <listitem>
+ <para>
+At this point, the groups and their associated symbols have been assigned to
+the corresponding key definitions in the Xkb map.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Apply symbol interpretations to modify key operation. This phase is completely
+skipped if the <emphasis>
+ExplicitInterpret</emphasis>
+ override control bit is set in the explicit controls mask for the Xkb key (see
+section 16.3).
+ </para>
+ <orderedlist>
+ <listitem>
+ <para>
+For each symbol on each changed key, attempt to match the symbol and modifiers
+from the Xkb map to a symbol interpretation describing how to generate the
+symbol.
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+When a match is found in step 2a, apply the symbol interpretation to change the
+semantics associated with the symbol in the Xkb key map. If no match is found,
+apply a default interpretation.
+ </para>
+ </listitem>
+ </orderedlist>
+ </listitem>
+</orderedlist>
+
+<para>
+The symbol interpretations used in step 2 are configurable and may be specified
+using <emphasis>
+XkbSymInterpretRec</emphasis>
+ structures referenced by the <emphasis>
+sym_interpret</emphasis>
+ field of an <emphasis>
+XkbCompatMapRec</emphasis>
+ (see Figure 17.3).
+</para>
+
+<sect3 id='symbol_interpretations_the_xkbsyminterpretrec_structure'>
+<title>Symbol Interpretations — the XkbSymInterpretRec Structure</title>
+
+<para>
+Symbol interpretations are used to guide the X server when it modifies the Xkb
+keymap in step 2. An initial set of symbol interpretations is loaded by the
+server when it starts. A client may add new ones using <emphasis>
+XkbSetCompatMap</emphasis>
+ (see section 17.4).
+</para>
+
+
+<para>
+Symbol interpretations result in key semantics being set. When a symbol
+interpretation is applied, the following components of server key event
+processing may be modified for the particular key involved:
+</para>
+
+<literallayout>
+ Virtual modifier map
+ Auto repeat
+ Key behavior (may be set to <emphasis>XkbKB_Lock</emphasis>)
+ Key action (see section 16.1)
+</literallayout>
+
+<para>
+The <emphasis>XkbSymInterpretRec</emphasis>
+structure specifies a symbol interpretation:
+</para>
+
+<para><programlisting>
+typedef struct {
+ KeySym sym; /* keysym of interest or <emphasis>NULL</emphasis> */
+ unsigned char flags; /* <emphasis>XkbSI_AutoRepeat, XkbSI_LockingKey</emphasis> */
+ unsigned char match; /* specifies how mods is interpreted */
+ unsigned char mods; /* modifier bits, correspond to eight real modifiers */
+ unsigned char virtual_mod; /* 1 modifier to add to key virtual mod map */
+ XkbAnyAction act; /* action to bind to symbol position on key */
+} <emphasis>XkbSymInterpretRec</emphasis>,*XkbSymInterpretPtr;
+</programlisting></para>
+
+<para>
+If <emphasis>
+sym</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+, it limits the symbol interpretation to keys on which that particular keysym
+is selected by the modifiers matching the criteria specified by <emphasis>
+mods</emphasis>
+ and <emphasis>
+match</emphasis>
+. If <emphasis>
+sym</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, the interpretation may be applied to any symbol selected on a key when the
+modifiers match the criteria specified by <emphasis>
+mods</emphasis>
+ and <emphasis>
+match</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>match</emphasis>
+must be one of the values shown in Table 17.1 and specifies how the real
+modifiers specified in <emphasis>mods</emphasis>
+are to be interpreted.
+</para>
+
+<table frame='none'>
+<title>Symbol Interpretation Match Criteria</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='1'>
+ <entry>Match Criteria</entry>
+ <entry>Value</entry>
+ <entry>Effect</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='1'>
+ <entry><emphasis>XkbSI_NoneOf</emphasis></entry>
+ <entry>(0)</entry>
+ <entry>
+None of the bits that are on in <emphasis>mods</emphasis>
+ can be set, but other bits can be.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSI_AnyOfOrNone</emphasis></entry>
+ <entry>(1)</entry>
+ <entry>
+Zero or more of the bits that are on in <emphasis>
+mods</emphasis>
+ can be set, as well as others.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSI_AnyOf</emphasis></entry>
+ <entry>(2)</entry>
+ <entry>
+One or more of the bits that are on in <emphasis>
+mods</emphasis>
+ can be set, as well as any others.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSI_AllOf</emphasis></entry>
+ <entry>(3)</entry>
+ <entry>
+All of the bits that are on in <emphasis>
+mods</emphasis>
+ must be set, but others may be set as well.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSI_Exactly</emphasis></entry>
+ <entry>(4)</entry>
+ <entry>
+All of the bits that are on in <emphasis>
+mods</emphasis>
+ must be set, and no other bits may be set.
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+In addition to the above bits, <emphasis>
+match</emphasis>
+ may contain the <emphasis>
+XkbSI_LevelOneOnly</emphasis>
+ bit, in which case the modifier match criteria specified by <emphasis>
+mods</emphasis>
+ and <emphasis>
+match</emphasis>
+ applies only if <emphasis>
+sym</emphasis>
+ is in level one of its group; otherwise, <emphasis>
+mods</emphasis>
+ and <emphasis>
+match</emphasis>
+ are ignored and the symbol matches a condition where no modifiers are set.
+</para>
+
+<para><programlisting>
+#define XkbSI_LevelOneOnly (0x80)
+/* use mods + match only if sym is level 1 */
+</programlisting></para>
+
+<para>
+If no matching symbol interpretation is found, the server uses a default
+interpretation where:
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='2'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>sym</emphasis> =</entry>
+ <entry>0</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>flags</emphasis> =</entry>
+ <entry><emphasis>XkbSI_AutoRepeat</emphasis></entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>match</emphasis> =</entry>
+ <entry><emphasis>XkbSI_AnyOfOrNone</emphasis></entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>mods</emphasis> =</entry>
+ <entry>0</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>virtual_mod</emphasis> =</entry>
+ <entry><emphasis>XkbNoModifier</emphasis></entry>
+ </row>
+ <row rowsep='0'>
+
+ <entry><emphasis>act</emphasis> =</entry>
+ <entry><emphasis>SA_NoAction</emphasis></entry>
+ </row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+When a matching symbol interpretation is found in step 2a, the interpretation
+is applied to modify the Xkb map as follows.
+</para>
+
+<para>
+The <emphasis>
+act</emphasis>
+ field specifies a single action to be bound to the symbol position; any key
+event that selects the symbol causes the action to be taken. Valid actions are
+defined in section 16.1.
+</para>
+
+
+<para>
+If the Xkb keyboard map for the key does not have its <emphasis>
+ExplicitVModMap</emphasis>
+ control set, the <emphasis>
+XkbSI_LevelOneOnly</emphasis>
+ bit and symbol position are examined. If the <emphasis>
+XkbSI_LevelOneOnly</emphasis>
+ bit is not set in <emphasis>
+match</emphasis>
+ or the symbol is in position G1L1, the <emphasis>
+virtual_mod</emphasis>
+ field is examined. If <emphasis>
+virtual_mod</emphasis>
+ is not <emphasis>
+XkbNoModifier</emphasis>
+, <emphasis>
+virtual_mod</emphasis>
+ specifies a single virtual modifier to be added to the virtual modifier map
+for the key.<emphasis>
+ virtual_mod</emphasis>
+ is specified as an index in the range [0..15].
+</para>
+
+
+<para>
+If the matching symbol is in position G1L1 of the key, two bits in the flags
+field potentially specify additional behavior modifications:
+</para>
+
+<para><programlisting>
+#define XkbSI_AutoRepeat (1&lt;&lt;0)
+ /* key repeats if sym is in position G1L1 */
+#define XkbSI_LockingKey (1&lt;&lt;1)
+ /* set <emphasis> KB_Lock</emphasis>
+ behavior if sym is in psn G1L1 */
+</programlisting></para>
+
+<para>
+If the Xkb keyboard map for the key does not have its <emphasis>
+ExplicitAutoRepeat</emphasis>
+ control set, its auto repeat behavior is set based on the value of the
+<emphasis>
+XkbSI_AutoRepeat</emphasis>
+ bit. If the <emphasis>
+XkbSI_AutoRepeat</emphasis>
+ bit is set, the auto-repeat behavior of the key is turned on; otherwise, it is
+turned off.
+</para>
+
+
+<para>
+If the Xkb keyboard map for the key does not have its <emphasis>
+ExplicitBehavior</emphasis>
+ control set, its locking behavior is set based on the value of the <emphasis>
+XkbSI_LockingKey</emphasis>
+ bit. If <emphasis>
+XkbSI_LockingKey</emphasis>
+ is set, the key behavior is set to <emphasis>
+KB_Lock</emphasis>
+; otherwise, it is turned off (see section 16.3).
+</para>
+
+
+</sect3>
+</sect2>
+<sect2 id='xkb_keyboard_mapping_to_core_keyboard_mapping_transformations'>
+<title>Xkb Keyboard Mapping to Core Keyboard Mapping Transformations</title>
+
+<para>
+Whenever the server processes Xkb requests to change the keyboard mapping, it
+discards the affected portion of its core keyboard mapping and regenerates it
+based on the new Xkb mapping.
+</para>
+
+
+<para>
+When the Xkb mapping for a key is transformed to a core protocol mapping, the
+symbols for the core map are taken in the following order from the Xkb map:
+</para>
+
+
+<para>
+G1L1 G1L2 G2L1 G2L2 G1L3-n G2L3-n G3L1-n G4L1-n
+</para>
+
+
+<para>
+If group one is of width one in the Xkb map, G1L2 is taken to be NoSymbol;
+similarly, if group two is of width one in the Xkb map, G2L2 is taken to be
+NoSymbol.
+</para>
+
+
+<para>
+If the Xkb key map for a particular key has fewer groups than the core
+keyboard, the symbols for group one are repeated to fill in the missing core
+components. For example, an Xkb key with a single width-three group would be
+mapped to a core mapping counting three groups as:
+</para>
+
+
+<para>
+G1L1 G1L2 G1L1 G1L2 G1L3 G1L3 G1L1 G1L2 G1L3
+</para>
+
+
+<para>
+When a core keyboard map entry is generated from an Xkb keyboard map entry, a
+modifier mapping is generated as well. The modifier mapping contains all of the
+modifiers affected by any of the actions associated with the key combined with
+all of the real modifiers associated with any of the virtual modifiers bound to
+the key. In addition, if any of the actions associated with the key affect any
+component of the keyboard group, all of the modifiers in the <emphasis>
+mask</emphasis>
+ field of all of the group compatibility maps are added to the modifier mapping
+as well. While an <emphasis>
+XkbSA_ISOLock</emphasis>
+ action can theoretically affect any modifier, if the Xkb mapping for a key
+specifies an <emphasis>
+XkbSA_ISOLock</emphasis>
+ action, only the modifiers or group that are set by default are added to the
+modifier mapping.
+</para>
+
+
+</sect2>
+</sect1>
+<sect1 id='getting_compatibility_map_components_from_the_server'>
+<title>Getting Compatibility Map Components From the Server</title>
+
+<para>
+Use <emphasis>
+XkbGetCompatMap</emphasis>
+ to fetch any combination of the current compatibility map components from the
+server. When another client modifies the compatibility map, you are notified if
+you have selected for <emphasis>
+XkbCompatMapNotify</emphasis>
+ events (see section 17.5). <emphasis>
+XkbGetCompatMap</emphasis>
+ is particularly useful when you receive an event of this type, as it allows
+you to update your program’s version of the compatibility map to match the
+modified version now in the server. If your program is dealing with multiple
+servers and needs to configure them all in a similar manner, the updated
+compatibility map may be used to reconfigure other servers.
+</para>
+
+<note><para>To make a complete matching configuration you must also update the
+explicit override components of the server state.</para></note>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetCompatMap</emphasis>
+(<emphasis>
+display, which, xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of compatibility map components to fetch */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescRec * <emphasis>
+ xkb</emphasis>
+; /* keyboard description where results placed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetCompatMap</emphasis>
+ fetches the components of the compatibility map specified in <emphasis>
+which</emphasis>
+ from the server specified by <emphasis>
+display</emphasis>
+ and places them in the <emphasis>
+compat</emphasis>
+ structure of the keyboard description <emphasis>
+xkb</emphasis>
+. Valid values for <emphasis>
+which</emphasis>
+ are an inclusive OR of the values shown in Table 17.2.
+</para>
+
+<table frame='none'>
+<title>Compatibility Map Component Masks</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Value</entry>
+ <entry>Affecting</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry><emphasis>XkbSymInterpMask</emphasis></entry>
+ <entry>(1&lt;&lt;0)</entry>
+ <entry>Symbol interpretations</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbGroupCompatMask</emphasis></entry>
+ <entry>(1&lt;&lt;1)</entry>
+ <entry>Group maps</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbAllCompatMask</emphasis></entry>
+ <entry>(0x3)</entry>
+ <entry>All compatibility map components</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+If no compatibility map structure is allocated in <emphasis>
+xkb</emphasis>
+ upon entry, <emphasis>
+XkbGetCompatMap</emphasis>
+ allocates one. If one already exists, its contents are overwritten with the
+returned results.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetCompatMap</emphasis>
+ fetches compatibility map information for the device specified by the
+<emphasis>
+device_spec</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+. Unless you have specifically modified this field, it is the default keyboard
+device. <emphasis>
+XkbGetCompatMap</emphasis>
+ returns <emphasis>
+Success</emphasis>
+ if successful, <emphasis>
+BadAlloc</emphasis>
+ if it is unable to obtain necessary storage for either the return values or
+work space, <emphasis>
+BadMatch</emphasis>
+ if the <emphasis>
+dpy</emphasis>
+ field of the <emphasis>
+xkb</emphasis>
+ argument is non-<emphasis>
+NULL</emphasis>
+ and does not match the <emphasis>
+display</emphasis>
+ argument, and <emphasis>
+BadLength</emphasis>
+ under certain conditions caused by server or Xkb implementation errors.
+</para>
+
+
+</sect1>
+<sect1 id='using_the_compatibility_map'>
+<title>Using the Compatibility Map</title>
+
+<para>
+Xkb provides several functions that make it easier to apply the compatibility
+map to configure a client-side Xkb keyboard mapping, given a core protocol
+representation of part or all of a keyboard mapping. Obtain a core protocol
+representation of a keyboard mapping from an actual server (by using <emphasis>
+XGetKeyboardMapping</emphasis>
+, for example), a data file, or some other source.
+</para>
+
+<para>
+To update a local Xkb keyboard map to reflect the mapping expressed by a core
+format mapping by calling the function <emphasis>
+XkbUpdateMapFromCore</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbUpdateMapFromCore</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ first_key</emphasis>
+,<emphasis>
+ num_keys</emphasis>
+,<emphasis>
+ map_width</emphasis>
+,<emphasis>
+ core_keysyms</emphasis>
+,<emphasis>
+ changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description to update */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeyCode <emphasis>
+ first_key</emphasis>
+; /* keycode of first key description to update */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ num_keys</emphasis>
+; /* number of key descriptions to update */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+ map_width</emphasis>
+; /* width of core protocol keymap */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym *<emphasis>
+ core_keysyms</emphasis>
+; /* symbols in core protocol keymap */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbChangesPtr <emphasis>
+ changes</emphasis>
+; /* backfilled with changes made to Xkb */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbUpdateMapFromCore</emphasis>
+ interprets input argument information representing a keyboard map in core
+format to update the Xkb keyboard description passed in <emphasis>
+xkb</emphasis>
+. Only a portion of the Xkb map is updated — the portion corresponding to
+keys with keycodes in the range <emphasis>
+first_key</emphasis>
+ through <emphasis>
+first_key</emphasis>
+ + <emphasis>
+num_keys</emphasis>
+ - 1. If <emphasis>
+XkbUpdateMapFromCore</emphasis>
+ is being called in response to a<emphasis>
+ </emphasis>
+<emphasis>
+MappingNotify</emphasis>
+<emphasis>
+ </emphasis>
+event<emphasis>
+, first_key</emphasis>
+ and <emphasis>
+num_keys</emphasis>
+ are reported in the <emphasis>
+MappingNotify</emphasis>
+ event. <emphasis>
+core_keysyms</emphasis>
+ contains the keysyms corresponding to the keycode range being updated, in core
+keyboard description order. <emphasis>
+map_width</emphasis>
+ is the number of keysyms per key in <emphasis>
+core_keysyms</emphasis>
+. Thus, the first <emphasis>
+map_width</emphasis>
+ entries in <emphasis>
+core_keysyms</emphasis>
+ are for the key with keycode <emphasis>
+first_key</emphasis>
+, the next <emphasis>
+map_width</emphasis>
+ entries are for key <emphasis>
+first_key</emphasis>
+ + 1, and so on.
+</para>
+
+
+<para>
+In addition to modifying the Xkb keyboard mapping in <emphasis>
+xkb</emphasis>
+, <emphasis>
+XkbUpdateMapFromCore</emphasis>
+ backfills the changes structure whose address is passed in <emphasis>
+changes</emphasis>
+ to indicate the modifications that were made. You may then use <emphasis>
+changes</emphasis>
+ in subsequent calls such as <emphasis>
+XkbSetMap</emphasis>
+, to propagate the local modifications to a server.
+</para>
+
+
+<para>
+When dealing with core keyboard mappings or descriptions, it is sometimes
+necessary to determine the Xkb key types appropriate for the symbols bound to a
+key in a core keyboard mapping. Use <emphasis>
+XkbKeyTypesForCoreSymbols</emphasis>
+ for this purpose:
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+int <emphasis>
+XkbKeyTypesForCoreSymbols</emphasis>
+(<emphasis>
+map_width</emphasis>
+,<emphasis>
+ core_syms</emphasis>
+,<emphasis>
+ protected, types_inout, xkb_syms_rtrn</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr<emphasis>
+ xkb</emphasis>
+; /* keyboard description in which to place symbols*/
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int<emphasis>
+ map_width</emphasis>
+; /* width of core protocol keymap in <emphasis>
+xkb_syms_rtrn</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym *<emphasis>
+ core_syms</emphasis>
+; /* core protocol format array of KeySyms */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+protected</emphasis>
+; /* explicit key types */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int *<emphasis>
+ types_inout;</emphasis>
+ /* backfilled with the canonical types bound to groups one and two
+for the key */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+KeySym * <emphasis>
+xkb_syms_rtrn</emphasis>
+ ; /* backfilled with symbols bound to the key in the Xkb mapping */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbKeyTypesForCoreSymbols</emphasis>
+ expands the symbols in <emphasis>
+core_syms</emphasis>
+ and types in <emphasis>
+types_inout</emphasis>
+ according to the rules specified in section 12 of the core protocol, then
+chooses canonical key types (canonical key types are defined in section 15.2.1)
+for groups 1 and 2 using the rules specified by the Xkb protocol and places
+them in <emphasis>
+xkb_syms_rtrn</emphasis>
+, which will be non-<emphasis>
+NULL</emphasis>
+.
+</para>
+
+
+<para>
+A core keymap is a two-dimensional array of keysyms. It has <emphasis>
+map_width</emphasis>
+ columns and <emphasis>
+max_key_code</emphasis>
+ rows. <emphasis>
+XkbKeyTypesForCoreSymbols</emphasis>
+ takes a single row from a core keymap, determines the number of groups
+associated with it, the type of each group, and the symbols bound to each
+group. The return value is the number of groups, <emphasis>
+types_inout</emphasis>
+ has the types for each group, and <emphasis>
+xkb_syms_rtrn</emphasis>
+ has the symbols in Xkb order (that is, groups are contiguous, regardless of
+size).
+</para>
+
+
+<para>
+<emphasis>
+protected</emphasis>
+ contains the explicitly protected key types. There is one explicit override
+control associated with each of the four possible groups for each Xkb key,
+<emphasis>
+ExplicitKeyType1</emphasis>
+ through <emphasis>
+ExplicitKeyType4</emphasis>
+<emphasis>
+; protected </emphasis>
+is an inclusive OR of these controls. <emphasis>
+map_width</emphasis>
+ is the width of the core keymap and is not dependent on any Xkb definitions.
+<emphasis>
+types_inout</emphasis>
+ is an array of four type indices. On input, <emphasis>
+types_inout</emphasis>
+ contains the indices of any types already assigned to the key, in case they
+are explicitly protected from change.
+</para>
+
+
+<para>
+Upon return, <emphasis>
+types_inout</emphasis>
+ contains any automatically selected (that is, canonical) types plus any
+protected types. Canonical types are assigned to all four groups if there are
+enough symbols to do so. The four entries in <emphasis>
+types_inout</emphasis>
+ correspond to the four groups for the key in question.
+</para>
+
+
+<para>
+If the groups mapping does not change, but the symbols assigned to an Xkb
+keyboard compatibility map do change, the semantics of the key may be modified.
+To apply the new compatibility mapping to an individual key to get its
+semantics updated, use <emphasis>
+XkbApplyCompatMapToKey</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbApplyCompatMapToKey</emphasis>
+(<emphasis>
+xkb</emphasis>
+,<emphasis>
+ key</emphasis>
+,<emphasis>
+ changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+ XkbDescPtr<emphasis>
+ xkb; </emphasis>
+/* keyboard description to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+ KeyCode<emphasis>
+ key</emphasis>
+; /* key to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+ XkbChangesPtr<emphasis>
+ changes</emphasis>
+; /* notes changes to the Xkb keyboard description */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbApplyCompatMapToKey</emphasis>
+ essentially performs the operation described in section 17.1.2 to a specific
+key. This updates the behavior, actions, repeat status, and virtual modifier
+bindings of the key.
+</para>
+
+
+</sect1>
+<sect1 id='changing_the_servers_compatibility_map'>
+<title>Changing the Server’s Compatibility Map</title>
+
+<para>
+To modify the server’s compatibility map, first modify a local copy of the
+Xkb compatibility map, then call <emphasis>
+XkbSetCompatMap</emphasis>
+. You may allocate a new compatibility map for this purpose using <emphasis>
+XkbAllocCompatMap</emphasis>
+ (see section 17.6). You may also use a compatibility map from another server,
+although you need to adjust the <emphasis>
+device_spec</emphasis>
+ field in the <emphasis>
+XkbDescRec</emphasis>
+ accordingly. Note that symbol interpretations in a compatibility map
+(<emphasis>
+sym_interpret</emphasis>
+, the vector of <emphasis>
+XkbSymInterpretRec</emphasis>
+ structures) are also allocated using this same function.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetCompatMap</emphasis>
+(<emphasis>
+display, which, xkb, update_actions</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of compat map components to set */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* source for compat map components */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ update_actions</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; apply to server’s keyboard map */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetCompatMap</emphasis>
+ copies compatibility map information from the keyboard description in
+<emphasis>
+xkb</emphasis>
+ to the server specified in <emphasis>
+display</emphasis>
+’s compatibility map for the device specified by the <emphasis>
+device_spec</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+. Unless you have specifically modified this field, it is the default keyboard
+device.<emphasis>
+ which</emphasis>
+ specifies the compatibility map components to be set, and is an inclusive OR
+of the bits shown in Table 17.2.
+</para>
+
+
+<para>
+After updating its compatibility map for the specified device, if <emphasis>
+update_actions</emphasis>
+ is <emphasis>
+True,</emphasis>
+ the server applies the new compatibility map to its entire keyboard for the
+device to generate a new set of key semantics, compatibility state, and a new
+core keyboard map. If <emphasis>
+update_actions</emphasis>
+ is <emphasis>
+False</emphasis>
+, the new compatibility map is not used to generate any modifications to the
+current device semantics, state, or core keyboard map. One reason for not
+applying the compatibility map immediately would be if one server was being
+configured to match another on a piecemeal basis; the map should not be applied
+until everything is updated. To force an update at a later time, use <emphasis>
+XkbSetCompatMap</emphasis>
+ specifying <emphasis>
+which</emphasis>
+ as zero and <emphasis>
+update_actions</emphasis>
+ as <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbSetCompatMap</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if successful and <emphasis>
+False</emphasis>
+ if unsuccessful. The server may report problems it encounters when processing
+the request subsequently via protocol errors.
+</para>
+
+
+<para>
+To add a symbol interpretation to the list of symbol interpretations in an
+<emphasis>
+XkbCompatRec</emphasis>
+, use <emphasis>
+XkbAddSymInterpret</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbSymInterpretPtr <emphasis>
+XkbAddSymInterpret</emphasis>
+(<emphasis>
+xkb, si, updateMap, changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr<emphasis>
+ xkb</emphasis>
+; /* keyboard description to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbSymInterpretPtr<emphasis>
+ si</emphasis>
+; /* symbol interpretation to be added */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool<emphasis>
+ updateMap</emphasis>
+; /* <emphasis>
+True</emphasis>
+=&gt;apply compatibility map to keys */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbChangesPtr<emphasis>
+ changes</emphasis>
+; /* changes are put here */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddSymInterpret</emphasis>
+ adds <emphasis>
+si</emphasis>
+ to the list of symbol interpretations in <emphasis>
+xkb</emphasis>
+. If <emphasis>
+updateMap</emphasis>
+ is <emphasis>
+True</emphasis>
+, it (re)applies the compatibility map to all of the keys on the keyboard. If
+<emphasis>
+changes</emphasis>
+ is non-<emphasis>
+NULL</emphasis>
+, it reports the parts of the keyboard that were affected (unless <emphasis>
+updateMap</emphasis>
+ is <emphasis>
+True</emphasis>
+, not much changes). <emphasis>
+XkbAddSymInterpret</emphasis>
+ returns a pointer to the actual new symbol interpretation in the list or
+<emphasis>
+NULL</emphasis>
+ if it failed.
+</para>
+
+
+</sect1>
+<sect1 id='tracking_changes_to_the_compatibility_map'>
+<title>Tracking Changes to the Compatibility Map</title>
+
+<para>
+The server automatically generates <emphasis>
+MappingNotify</emphasis>
+ events when the keyboard mapping changes. If you wish to be notified of
+changes to the compatibility map, you should select for <emphasis>
+XkbCompatMapNotify</emphasis>
+ events. If you select for <emphasis>
+XkbMapNotify</emphasis>
+ events, you no longer receive the automatically generated <emphasis>
+MappingNotify</emphasis>
+ events. If you subsequently deselect <emphasis>
+XkbMapNotifyEvent</emphasis>
+ delivery, you again receive <emphasis>
+MappingNotify</emphasis>
+ events.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbCompatMapNotify</emphasis>
+ events under all possible conditions, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) and pass <emphasis>
+XkbCompatMapNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbCompatMapNotify</emphasis>
+ events only under certain conditions, use <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbCompatMapNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying the desired map changes in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ using mask bits from Table 17.2.
+</para>
+
+
+<para>
+Note that you are notified of changes you make yourself, as well as changes
+made by other clients.
+</para>
+
+
+<para>
+The structure for the <emphasis>
+XkbCompatMapNotifyEvent</emphasis>
+ is:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis>True</emphasis> =&gt;
+ synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis>XkbCompatMapNotify</emphasis> */
+ int device; /* Xkb device ID, will not be
+ <emphasis>XkbUseCoreKbd</emphasis> */
+ unsigned int changed_groups;/* number of group maps changed */
+ int first_si; /* index to 1st changed symbol
+ interpretation */
+ int num_si; /* number of changed symbol
+ interpretations */
+ int num_total_si; /* total number of valid symbol
+ interpretations */
+} <emphasis>XkbCompatMapNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+<emphasis>
+changed_groups</emphasis>
+ is the number of group compatibility maps that have changed. If you are
+maintaining a corresponding copy of the compatibility map, or get a fresh copy
+from the server using <emphasis>
+XkbGetCompatMap</emphasis>
+, <emphasis>
+changed_groups</emphasis>
+ references <emphasis>
+groups</emphasis>
+[0..<emphasis>
+changed_groups</emphasis>
+-1] in the <emphasis>
+XkbCompatMapRec</emphasis>
+ structure.
+</para>
+
+
+<para>
+<emphasis>
+first_si</emphasis>
+ is the index of the first changed symbol interpretation, <emphasis>
+num_si</emphasis>
+ is the number of changed symbol interpretations, and <emphasis>
+num_total_si</emphasis>
+ is the total number of valid symbol interpretations. If you are maintaining a
+corresponding copy of the compatibility map, or get a fresh copy from the
+server using <emphasis>
+XkbGetCompatMap</emphasis>
+, <emphasis>
+first_si</emphasis>
+, <emphasis>
+num_si</emphasis>
+, and <emphasis>
+num_total_si</emphasis>
+ are appropriate for use with the <emphasis>
+compat.sym_interpret</emphasis>
+ vector in this structure.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_the_compatibility_map'>
+<title>Allocating and Freeing the Compatibility Map</title>
+
+<para>
+If you are modifying the compatibility map, you need to allocate a new
+compatibility map if you do not already have one available. To do so, use
+<emphasis>
+XkbAllocCompatMap</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocCompatMap</emphasis>
+(<emphasis>
+xkb, which, num_si</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description in which to allocate compat map */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of compatibility map components to allocate */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ num_si</emphasis>
+; /* number of symbol interpretations to allocate */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+xkb</emphasis>
+ specifies the keyboard description for which compatibility maps are to be
+allocated. The compatibility map is the <emphasis>
+compat</emphasis>
+ field in this structure.
+</para>
+
+
+<para>
+<emphasis>
+which</emphasis>
+ specifies the compatibility map components to be allocated (see <emphasis>
+XkbGetCompatMap</emphasis>
+, in section 17.2). <emphasis>
+which</emphasis>
+ is an inclusive OR of the bits shown in Table 17.2.
+</para>
+
+
+<para>
+<emphasis>
+num_si</emphasis>
+ specifies the total number of entries to allocate in the symbol interpretation
+vector (<emphasis>
+xkb.compat.sym_interpret</emphasis>
+).
+</para>
+
+
+<para>
+Note that symbol interpretations in a compatibility map (the <emphasis>
+sym_interpret</emphasis>
+ vector of <emphasis>
+XkbSymInterpretRec</emphasis>
+ structures) are also allocated using this same function. To ensure that there
+is sufficient space in the symbol interpretation vector for entries to be
+added, use <emphasis>
+XkbAllocCompatMap</emphasis>
+ specifying <emphasis>
+which</emphasis>
+ as <emphasis>
+XkbSymInterpretMask</emphasis>
+ and the number of free symbol interpretations needed in <emphasis>
+num_si</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbAllocCompatMap</emphasis>
+ returns <emphasis>
+Success</emphasis>
+ if successful, <emphasis>
+BadMatch</emphasis>
+ if <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, or <emphasis>
+BadAlloc</emphasis>
+ if errors are encountered when attempting to allocate storage.
+</para>
+
+
+<para>
+To free an entire compatibility map or selected portions of one, use <emphasis>
+XkbFreeCompatMap</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeCompatMap</emphasis>
+(<emphasis>
+xkb, which, free_map</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* Xkb description in which to free compatibility map */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of compatibility map components to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+ free_map</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free <emphasis>
+XkbCompatMap</emphasis>
+ structure itself */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+which</emphasis>
+ specifies the compatibility map components to be freed (see <emphasis>
+XkbGetCompatMap</emphasis>
+, in section 17.2). <emphasis>
+which</emphasis>
+ is an inclusive OR of the bits shown in Table 17.2
+</para>
+
+
+<para>
+<emphasis>
+free_map</emphasis>
+ indicates whether the <emphasis>
+XkbCompatMap</emphasis>
+ structure itself should be freed. If <emphasis>
+free_map</emphasis>
+ is <emphasis>
+True</emphasis>
+, <emphasis>
+which</emphasis>
+ is ignored, all non-<emphasis>
+NULL</emphasis>
+ compatibility map components are freed, and the <emphasis>
+compat</emphasis>
+ field in the <emphasis>
+XkbDescRec</emphasis>
+ referenced by <emphasis>
+xkb</emphasis>
+ is set to <emphasis>
+NULL</emphasis>
+.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch18.xml b/libX11/specs/XKB/ch18.xml
new file mode 100644
index 000000000..025d777f9
--- /dev/null
+++ b/libX11/specs/XKB/ch18.xml
@@ -0,0 +1,1182 @@
+<chapter id='symbolic_names'>
+<title>Symbolic Names</title>
+
+<para>
+The core protocol does not provide any information to clients other than that
+actually used to interpret events. This makes it difficult to write an
+application that presents the keyboard to a user in an easy-to-understand way.
+Such applications have to examine the vendor string and keycodes to determine
+the type of keyboard connected to the server and then examine keysyms and
+modifier mappings to determine the effects of most modifiers (the <emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+ and <emphasis>
+Control</emphasis>
+ modifiers are defined by the core protocol but no semantics are implied for
+any other modifiers).
+</para>
+
+
+<para>
+To make it easier for applications to present a keyboard to the user, Xkb
+supports symbolic names for most components of the keyboard extension. Most of
+these symbolic names are grouped into the <emphasis>
+names</emphasis>
+ component of the keyboard description.
+</para>
+
+<sect1 id='the_xkbnamesrec_structure'>
+<title>The XkbNamesRec Structure</title>
+
+<para>
+The names component of the keyboard description is defined as follows:
+</para>
+
+<para><programlisting>
+#define XkbKeyNameLength 4
+#define XkbKeyNumVirtualMods 16
+#define XkbKeyNumIndicators 32
+#define XkbKeyNumKbdGroups 4
+#define XkbMaxRadioGroups 32
+</programlisting></para>
+
+<para><programlisting>
+typedef struct {
+ char name[XkbKeyNameLength]; /* symbolic key names */
+} <emphasis>XkbKeyNameRec</emphasis>,*XkbKeyNamePtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct {
+ char real[XkbKeyNameLength];
+ /* this key name must be in the keys array */
+ char alias[XkbKeyNameLength];
+ /* symbolic key name as alias for the key */
+} <emphasis>XkbKeyAliasRec</emphasis>,*XkbKeyAliasPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbNamesRec {
+ Atom keycodes; /* identifies range and meaning of keycodes */
+ Atom geometry; /* identifies physical location, size, and shape of keys */
+ Atom symbols; /* identifies the symbols logically bound to the keys */
+ Atom types; /* identifies the set of key types */
+ Atom compat; /* identifies actions for keys using core protocol */
+ Atom vmods[XkbNumVirtualMods]; /* symbolic names for virtual modifiers */
+ Atom indicators[XkbNumIndicators]; /* symbolic names for indicators */
+ Atom groups[XkbNumKbdGroups]; /* symbolic names for keyboard groups */
+ XkbKeyNamePtr keys; /* symbolic key name array */
+ XkbKeyAliasPtr key_aliases; /* real/alias symbolic name pairs array */
+ Atom * radio_groups; /* radio group name array */
+ Atom phys_symbols; /* identifies the symbols engraved on the keyboard */
+ unsigned char num_keys; /* number of keys in the <emphasis> keys</emphasis> array */
+ unsigned char num_key_aliases; /* number of keys in the
+ <emphasis> key_aliases</emphasis> array */
+ unsigned short num_rg; /* number of radio groups */
+} <emphasis>XkbNamesRec</emphasis>,*XkbNamesPtr; /*
+</programlisting></para>
+
+<para>
+The <emphasis>
+keycodes</emphasis>
+ name identifies the range and meaning of the keycodes returned by the keyboard
+in question. The <emphasis>
+geometry</emphasis>
+ name, on the other hand, identifies the physical location, size and shape of
+the various keys on the keyboard. As an example to distinguish between these
+two names, consider function keys on PC-compatible keyboards. Function keys are
+sometimes above the main keyboard and sometimes to the left of the main
+keyboard, but the same keycode is used for the key that is logically F1
+regardless of physical position. Thus, all PC-compatible keyboards share a
+similar keycodes name but may have different geometry names.
+</para>
+
+<note><para>The keycodes name is intended to be a very general description of
+the keycodes returned by a keyboard; a single keycodes name might cover
+keyboards with differing numbers of keys provided all keys have the same
+semantics when present. For example, 101 and 102 key PC keyboards might use the
+same name. In these cases, applications can use the keyboard <emphasis>
+geometry</emphasis>
+ name to determine which subset of the named keycodes is in use.</para></note>
+
+<para>
+The <emphasis>
+symbols</emphasis>
+ name identifies the symbols logically bound to the keys. The symbols name is a
+human or application-readable description of the intended locale or usage of
+the keyboard with these symbols. The <emphasis>
+phys_symbols</emphasis>
+ name, on the other hand, identifies the symbols actually engraved on the
+keyboard. Given this, the <emphasis>
+symbols</emphasis>
+ name and <emphasis>
+phys_symbols</emphasis>
+ names might be different. For example, the description for a keyboard that has
+English US engravings, but that is using Swiss German symbols might have a
+<emphasis>
+phys_symbols</emphasis>
+ name of "en_US" and a <emphasis>
+symbols</emphasis>
+ name of "de_CH."
+</para>
+
+
+<para>
+The <emphasis>
+types</emphasis>
+ name provides some information about the set of key types (see section 15.2)
+that can be associated with the keyboard. In addition, each key type can have a
+name, and each shift level of a type can have a name. Although these names are
+stored in the map description with each of the types, they are accessed using
+the same methods as the other symbolic names.
+</para>
+
+
+<para>
+The <emphasis>
+compat</emphasis>
+ name provides some information about the rules used to bind actions to keys
+that are changed using core protocol requests.
+</para>
+
+
+<para>
+Xkb provides symbolic names for each of the 4 keyboard groups, 16 virtual
+modifiers, 32 keyboard indicators, and 4 keyboard groups. These names are held
+in the <emphasis>
+vmods</emphasis>
+, <emphasis>
+indicators</emphasis>
+, and <emphasis>
+groups</emphasis>
+ fixed-length arrays.
+</para>
+
+
+<para>
+Each key has a four-byte symbolic name. All of the symbolic key names are held
+in the <emphasis>
+keys</emphasis>
+ array, and <emphasis>
+num_keys</emphasis>
+ reports the number of entries that are in the keys array. For each key, the
+key name links keys with similar functions or in similar positions on keyboards
+that report different keycodes. For example, the <emphasis>
+F1</emphasis>
+ key may emit keycode 23 on one keyboard and keycode 86 on another. By naming
+this key "FK01" on both keyboards, the keyboard layout designer can reuse parts
+of keyboard descriptions for different keyboards.
+</para>
+
+
+<para>
+Key aliases allow the keyboard layout designer to assign multiple key names to
+a single key. This allows the keyboard layout designer to refer to keys using
+either their position or their "function." For example, a keyboard layout
+designer may wish to refer to the left arrow key on a PC keyboard using the
+ISO9995-5 positional specification of A31 or using the functional specification
+of LEFT. The <emphasis>
+key_aliases</emphasis>
+ field holds a variable-length array of real and alias key name pairs, and the
+total number of entries in the <emphasis>
+key_aliases</emphasis>
+ array is held in <emphasis>
+num_key_aliases</emphasis>
+. For each real and alias key name pair, the <emphasis>
+real</emphasis>
+ field refers to the a name in the keys array, and the <emphasis>
+alias</emphasis>
+ field refers to the alias for that key. Using the previous example, the
+keyboard designer may use the name A31 in the keys array, but also define the
+name LEFT as an alias for A31 in the <emphasis>
+key_aliases</emphasis>
+ array.
+</para>
+
+<note><para>Key aliases defined in the geometry component of a keyboard mapping
+(see Chapter 13) override those defined in the keycodes component of the server
+database, which are stored in the <emphasis>
+XkbNamesRec</emphasis>
+ (<emphasis>
+xkb-&gt;names</emphasis>
+). Therefore, consider the key aliases defined by the geometry before
+considering key aliases supplied by the <emphasis>
+XkbNamesRec</emphasis>
+.</para></note>
+
+<para>
+A radio group is a set of keys whose behavior simulates a set of radio buttons.
+Once a key in a radio group is pressed, it stays logically depressed until
+another key in the group is pressed, at which point the previously depressed
+key is logically released. Consequently, at most one key in a radio group can
+be logically depressed at one time.
+</para>
+
+
+<para>
+Each radio group in the keyboard description can have a name. These names are
+held in the variable-length array <emphasis>
+radio_groups</emphasis>
+, and <emphasis>
+num_rg</emphasis>
+ tells how many elements are in the <emphasis>
+radio_groups</emphasis>
+ array.
+</para>
+
+
+</sect1>
+<sect1 id='symbolic_names_masks'>
+<title>Symbolic Names Masks</title>
+
+<para>
+Xkb provides several functions that work with symbolic names. Each of these
+functions uses a mask to specify individual fields of the structures described
+above. These masks and their relationships to the fields in a keyboard
+description are shown in Table 18.1.
+</para>
+
+<table frame='none'>
+<title>Symbolic Names Masks</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask Bit</entry>
+ <entry>Value</entry>
+ <entry>Keyboard Component</entry>
+ <entry>Field</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbKeycodesNameMask</entry>
+ <entry>(1&lt;&lt;0)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>keycodes</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbGeometryNameMask</entry>
+ <entry>(1&lt;&lt;1)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>geometry</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbSymbolsNameMask</entry>
+ <entry>(1&lt;&lt;2)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>symbols</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbPhysSymbolsNameMask</entry>
+ <entry>(1&lt;&lt;3)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>phys_symbols</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbTypesNameMask</entry>
+ <entry>(1&lt;&lt;4)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>type</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbCompatNameMask</entry>
+ <entry>(1&lt;&lt;5)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>compat</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKeyTypeNamesMask</entry>
+ <entry>(1&lt;&lt;6)</entry>
+ <entry>Xkb-&gt;map</entry>
+ <entry>type[*].name</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKTLevelNamesMask</entry>
+ <entry>(1&lt;&lt;7)</entry>
+ <entry>Xkb-&gt;map</entry>
+ <entry>type[*].lvl_names[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbIndicatorNamesMask</entry>
+ <entry>(1&lt;&lt;8)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>indicators[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKeyNamesMask</entry>
+ <entry>(1&lt;&lt;9)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>keys[*], num_keys</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKeyAliasesMask</entry>
+ <entry>(1&lt;&lt;10)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>key_aliases[*], num_key_aliases</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbVirtualModNamesMask</entry>
+ <entry>(1&lt;&lt;11)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>vmods[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbGroupNamesMask</entry>
+ <entry>(1&lt;&lt;12)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>groups[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbRGNamesMask</entry>
+ <entry>(1&lt;&lt;13)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>radio_groups[*], num_rg</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbComponentNamesMask</entry>
+ <entry>(0x3f)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>
+<para>keycodes,</para>
+<para>geometry,</para>
+<para>symbols,</para>
+<para>physical symbols,</para>
+<para>types, and</para>
+<para>compatibility map</para>
+ </entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbAllNamesMask</entry>
+ <entry>(0x3fff)</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>all name components</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='getting_symbolic_names_from_the_server'>
+<title>Getting Symbolic Names From the Server</title>
+
+<para>
+To obtain symbolic names from the server, use <emphasis>
+XkbGetNames</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetNames</emphasis>
+(<emphasis>
+dpy, which, Xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of names or map components to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+ /* keyboard description to be updated */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetNames</emphasis>
+ retrieves symbolic names for the components of the keyboard extension from the
+X server. The <emphasis>
+which</emphasis>
+ parameter specifies the name components to be updated in the <emphasis>
+xkb</emphasis>
+ parameter, and is the bitwise inclusive OR of the valid names mask bits
+defined in Table 18.1.
+</para>
+
+
+<para>
+If the <emphasis>
+names</emphasis>
+ field of the keyboard description <emphasis>
+xkb</emphasis>
+ is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetNames</emphasis>
+ allocates and initializes the <emphasis>
+names</emphasis>
+ component of the keyboard description before obtaining the values specified by
+<emphasis>
+which</emphasis>
+. If the <emphasis>
+names</emphasis>
+ field of <emphasis>
+xkb</emphasis>
+ is not <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetNames</emphasis>
+ obtains the values specified by <emphasis>
+which</emphasis>
+ and copies them into the keyboard description <emphasis>
+Xkb</emphasis>
+.
+</para>
+
+
+<para>
+If the <emphasis>
+map</emphasis>
+ component of the <emphasis>
+xkb</emphasis>
+ parameter is <emphasis>
+NULL</emphasis>
+, <emphasis>
+XkbGetNames</emphasis>
+ does not retrieve type or shift level names, even if <emphasis>
+XkbKeyTypeNamesMask</emphasis>
+ or <emphasis>
+XkbKTLevelNamesMask</emphasis>
+ are set in <emphasis>
+which</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetNames</emphasis>
+ can return <emphasis>
+Success</emphasis>
+, or <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadLength</emphasis>
+, <emphasis>
+BadMatch</emphasis>
+, and <emphasis>
+BadImplementation</emphasis>
+ errors.
+</para>
+
+
+<para>
+To free symbolic names, use <emphasis>
+XkbFreeNames</emphasis>
+ (see section 18.6)
+</para>
+
+
+</sect1>
+<sect1 id='changing_symbolic_names_on_the_server'>
+<title>Changing Symbolic Names on the Server</title>
+
+<para>
+To change the symbolic names in the server, first modify a local copy of the
+keyboard description and then use either <emphasis>
+XkbSetNames,</emphasis>
+ or, to save network traffic, use a <emphasis>
+XkbNameChangesRec</emphasis>
+structure and call <emphasis>
+XkbChangeNames</emphasis>
+ to download the changes to the server. <emphasis>
+XkbSetNames</emphasis>
+ and <emphasis>
+XkbChangeNames</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadAtom</emphasis>
+, <emphasis>
+BadLength</emphasis>
+, <emphasis>
+BadMatch,</emphasis>
+ and <emphasis>
+BadImplementation</emphasis>
+ errors.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetNames</emphasis>
+(<emphasis>
+dpy, which, first_type, num_types, xkb</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of names or map components to be changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+first_type</emphasis>
+ ; /* first type whose name is to be changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+num_types</emphasis>
+; /* number of types for which names are to be changed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description from which names are to be taken */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+Use<emphasis>
+ XkbSetNames</emphasis>
+ to change many names at the same time. For each bit set in <emphasis>
+which</emphasis>
+, <emphasis>
+XkbSetNames</emphasis>
+ takes the corresponding value (or values in the case of arrays) from the
+keyboard description <emphasis>
+xkb</emphasis>
+ and sends it to the server.
+</para>
+
+
+<para>
+The <emphasis>
+first_type</emphasis>
+ and <emphasis>
+num_types</emphasis>
+ arguments are used only if <emphasis>
+XkbKeyTypeNamesMask</emphasis>
+ or <emphasis>
+XkbKTLevelNamesMask</emphasis>
+ is set in <emphasis>
+which</emphasis>
+ and specify a subset of the types for which the corresponding names are to be
+changed. If either or both of these mask bits are set but the specified types
+are illegal, <emphasis>
+XkbSetNames</emphasis>
+ returns <emphasis>
+False</emphasis>
+ and does not update any of the names specified in <emphasis>
+which</emphasis>
+. The specified types are illegal if <emphasis>
+xkb</emphasis>
+ does not include a map component or if <emphasis>
+first_type</emphasis>
+ and <emphasis>
+num_types</emphasis>
+ specify types that are not defined in the keyboard description.
+</para>
+
+
+<sect2>
+<title/>
+
+<sect3 id='the_xkbnamechangesrec_structure'>
+<title>The XkbNameChangesRec Structure</title>
+
+<para>
+The <emphasis>
+XkbNameChangesRec</emphasis>
+ allows applications to identify small modifications to the symbolic names and
+effectively reduces the amount of traffic sent to the server:
+</para>
+
+<para><programlisting>
+typedef struct _XkbNameChanges {
+ unsigned int changed; /* name components that have
+ changed */
+ unsigned char first_type; /* first key type with a new
+ name */
+ unsigned char num_types; /* number of types with new
+ names */
+ unsigned char first_lvl; /* first key type with new level
+ names */
+ unsigned char num_lvls; /* number of key types with new
+ level names */
+ unsigned char num_aliases; /* if key aliases changed,
+ total number of key aliases */
+ unsigned char num_rg; /* if radio groups changed, total
+ number of radio groups */
+ unsigned char first_key; /* first key with a new name */
+ unsigned char num_keys; /* number of keys with new names
+ */
+ unsigned short changed_vmods; /* mask of virtual
+ modifiers for which names have changed */
+ unsigned long changed_indicators; /* mask of indicators
+ for which names were changed */
+ unsigned char changed_groups; /* mask of groups for
+ which names were changed */
+} <emphasis>XkbNameChangesRec</emphasis>, *XkbNameChangesPtr
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed</emphasis>
+ field specifies the name components that have changed and is the bitwise
+inclusive OR of the valid names mask bits defined in Table 18.1. The rest of
+the fields in the structure specify the ranges that have changed for the
+various kinds of symbolic names, as shown in Table 18.2.
+</para>
+
+<table frame='none'>
+<title>XkbNameChanges Fields</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Mask</entry>
+ <entry>Fields</entry>
+ <entry>Component</entry>
+ <entry>Field</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbKeyTypeNamesMask</entry>
+ <entry>
+<para>first_type,</para>
+<para>num_types</para>
+ </entry>
+ <entry>Xkb-&gt;map</entry>
+ <entry>type[*].name</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKTLevelNamesMask</entry>
+ <entry>
+<para>first_lvl,</para>
+<para>num_lvls</para>
+ </entry>
+ <entry>Xkb-&gt;map</entry>
+ <entry>type[*].lvl_names[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKeyAliasesMask</entry>
+ <entry>num_aliases</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>key_aliases[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbRGNamesMask</entry>
+ <entry>num_rg</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>radio_groups[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbKeyNamesMask</entry>
+ <entry>
+<para>first_key,</para>
+<para>num_keys</para>
+ </entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>keys[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbVirtualModNamesMask</entry>
+ <entry>changed_vmods</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>vmods[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbIndicatorNamesMask</entry>
+ <entry>changed_indicators</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>indicators[*]</entry>
+</row>
+<row rowsep='0'>
+ <entry>XkbGroupNamesMask</entry>
+ <entry>changed_groups</entry>
+ <entry>Xkb-&gt;names</entry>
+ <entry>groups[*]</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+<emphasis>
+XkbChangeNames</emphasis>
+ provides a more flexible method for changing symbolic names than <emphasis>
+XkbSetNames</emphasis>
+ and requires the use of an <emphasis>
+XkbNameChangesRec</emphasis>
+ structure.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeNames</emphasis>
+(<emphasis>
+dpy, xkb, changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+ xkb</emphasis>
+; /* keyboard description from which names are to be taken */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbNameChangesPtr <emphasis>
+ changes</emphasis>
+; /* names map components to be updated on the server */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeNames</emphasis>
+ copies any names specified by <emphasis>
+changes</emphasis>
+ from the keyboard description, <emphasis>
+xkb</emphasis>
+, to the X server specified by <emphasis>
+dpy</emphasis>
+.<emphasis>
+ XkbChangeNames</emphasis>
+ aborts and returns <emphasis>
+False</emphasis>
+ if any illegal type names or type shift level names are specified by <emphasis>
+changes</emphasis>
+.
+</para>
+
+</sect3>
+</sect2>
+</sect1>
+<sect1 id='tracking_name_changes'>
+<title>Tracking Name Changes</title>
+
+<para>
+Whenever a symbolic name changes in the server’s keyboard description, the
+server sends a <emphasis>
+XkbNamesNotify</emphasis>
+ event to all interested clients. To receive name notify events, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) with <emphasis>
+XkbNamesNotifyMask</emphasis>
+ in both the <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ parameters.
+</para>
+
+
+<para>
+To receive events for only specific names, use <emphasis>
+XkbSelectEventDetails</emphasis>
+. Set the <emphasis>
+event_type</emphasis>
+ parameter to <emphasis>
+XkbNamesNotify</emphasis>
+, and set both the <emphasis>
+bits_to_change </emphasis>
+and<emphasis>
+ values_for_bits</emphasis>
+ detail parameter to a mask composed of a bitwise OR of masks in Table 18.1.
+</para>
+
+
+<para>
+The structure for the <emphasis>
+XkbNamesNotify</emphasis>
+ event is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for
+ event */
+ Bool send_event; /* <emphasis>True</emphasis>
+ =&gt; synthetically generated */
+ Display * display; /* server connection where event
+ generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis>XkbNamesNotify</emphasis> */
+ int device; /* Xkb device ID, will not be
+ <emphasis>XkbUseCoreKbd</emphasis> */
+ unsigned int changed; /* mask of name components
+that have changed */
+ int first_type; /* first key type with a new name */
+ int num_types; /* number of types with new names */
+ int first_lvl; /* first key type with new level names */
+ int num_lvls; /* number of key types with new level names */
+ int num_aliases; /* if key aliases changed, total number
+ of key aliases */
+ int num_radio_groups; /* if radio groups changed,
+ total number of radio groups */
+ unsigned int changed_vmods; /* mask of virtual modifiers for
+ which names have changed */
+ unsigned int changed_groups; /* mask of groups for
+ which names were changed */
+ unsigned int changed_indicators; /* mask of indicators for which
+ names were changed */
+ int first_key; /* first key with a new name */
+ int num_keys; /* number of keys with new names */
+} <emphasis>XkbNamesNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+changed</emphasis>
+ field specifies the name components that have changed and is the bitwise
+inclusive OR of the valid names mask bits defined in Table 18.1. The other
+fields in this event are interpreted as the like-named fields in an <emphasis>
+XkbNameChangesRec</emphasis> , as previously defined.
+</para>
+
+
+<para>
+When your application receives a X<emphasis>
+kbNamesNotify</emphasis>
+ event, you can note the changed names in a changes structure using <emphasis>
+XkbNoteNameChanges</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbNoteNameChanges</emphasis>
+(<emphasis>
+old</emphasis>
+,<emphasis>
+ new</emphasis>
+,<emphasis>
+ wanted</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbNameChangesPtr <emphasis>
+old</emphasis>
+; /* <emphasis>
+XkbNameChanges</emphasis>
+ structure to be updated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbNamesNotifyEvent * <emphasis>
+new</emphasis>
+; /* event from which changes are to be copied */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+wanted</emphasis>
+; /* types of names for which changes are to be noted */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+wanted</emphasis>
+ parameter is the bitwise inclusive OR of the valid names mask bits shown in
+Table 18.1. <emphasis>
+XkbNoteNameChanges</emphasis>
+ copies any changes that are reported in <emphasis>
+new</emphasis>
+ and specified in <emphasis>
+wanted</emphasis>
+ into the changes record specified by <emphasis>
+old</emphasis>
+.
+</para>
+
+
+<para>
+To update the local copy of the keyboard description with the actual values,
+pass to <emphasis>
+XkbGetNameChanges</emphasis>
+ the results of one or more calls to <emphasis>
+XkbNoteNameChanges</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetNameChanges</emphasis>
+(<emphasis>
+dpy</emphasis>
+,<emphasis>
+ xkb</emphasis>
+,<emphasis>
+ changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to the X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description to which names are copied */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbNameChangesPtr <emphasis>
+changes</emphasis>
+; /* names components to be obtained from the server */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetNameChanges</emphasis>
+ examines the <emphasis>
+changes</emphasis>
+ parameter, retrieves the necessary information from the server, and places the
+results into the <emphasis>
+xkb</emphasis>
+ keyboard description.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetNamesChanges</emphasis>
+ can generate <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadImplementation,</emphasis>
+ and <emphasis>
+BadMatch</emphasis>
+ errors.
+</para>
+
+
+</sect1>
+<sect1 id='allocating_and_freeing_symbolic_names'>
+<title>Allocating and Freeing Symbolic Names</title>
+
+<para>
+Most applications do not need to directly allocate symbolic names structures.
+Do not allocate a names structure directly using <emphasis>
+malloc</emphasis>
+ or <emphasis>
+Xmalloc</emphasis>
+ if your application changes the number of key aliases or radio groups or
+constructs a symbolic names structure without loading the necessary components
+from the X server. Instead use <emphasis>
+XkbAllocNames</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocNames</emphasis>
+(<emphasis>
+xkb, which, num_rg, num_key_aliases)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb;</emphasis>
+ /* keyboard description for which names are to be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which;</emphasis>
+ /* mask of names to be allocated */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+num_rg;</emphasis>
+ /* total number of radio group names needed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+num_key_aliases;</emphasis>
+ /* total number of key aliases needed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocNames</emphasis>
+ can return <emphasis>
+BadAlloc</emphasis>
+, <emphasis>
+BadMatch,</emphasis>
+ and <emphasis>
+BadValue</emphasis>
+ errors.<emphasis>
+ </emphasis>
+The <emphasis>
+which</emphasis>
+ parameter is the bitwise inclusive OR of the valid names mask bits defined in
+Table 18.1.
+</para>
+
+
+<para>
+Do not free symbolic names structures directly using <emphasis>
+free</emphasis>
+ or <emphasis>
+XFree</emphasis>
+. Use <emphasis>
+XkbFreeNames</emphasis>
+ instead.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeNames</emphasis>
+(<emphasis>
+xkb, which, free_map)</emphasis>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDescPtr <emphasis>
+xkb</emphasis>
+; /* keyboard description for which names are to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of names components to be freed */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+free_map</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; XkbNamesRec structure itself should be freed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The <emphasis>
+which</emphasis>
+ parameter is the bitwise inclusive OR of the valid names mask bits defined in
+Table 18.1.
+</para>
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch19.xml b/libX11/specs/XKB/ch19.xml
new file mode 100644
index 000000000..9e675b358
--- /dev/null
+++ b/libX11/specs/XKB/ch19.xml
@@ -0,0 +1,328 @@
+<chapter id='replacing_a_keyboard_on_the_fly'>
+<title>Replacing a Keyboard "On the Fly"</title>
+
+<para>
+Some operating system and X server implementations allow "hot plugging" of
+input devices. When using these implementations, input devices can be unplugged
+and new ones plugged in without restarting the software that is using those
+devices. There is no provision in the standard X server for notification of
+client programs if input devices are unplugged and/or new ones plugged in. In
+the case of the X keyboard, this could result in the X server having a keymap
+that does not match the new keyboard.
+</para>
+
+
+<para>
+If the X server implementation supports the X input device extension, a client
+program may also change the X keyboard programmatically. The
+XChangeKeyboardDevice input extension request allows a client to designate an
+input extension keyboard device as the X keyboard, in which case the old X
+keyboard device becomes inaccessible except via the input device extension. In
+this case, core protocol <emphasis>
+XMappingNotify</emphasis>
+ and input extension <emphasis>
+XChangeDeviceNotify</emphasis>
+ events are generated to notify all clients that a new keyboard with a new
+keymap has been designated.
+</para>
+
+
+<para>
+When a client opens a connection to the X server, the server reports the
+minimum and maximum keycodes. The server keeps track of the minimum and maximum
+keycodes last reported to each client. When delivering events to a particular
+client, the server filters out any events that fall outside of the valid range
+for the client.
+</para>
+
+
+<para>
+Xkb provides an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event that reports a change in keyboard geometry and/or the range of supported
+keycodes. The server can generate an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event when it detects a new keyboard or in response to an <emphasis>
+XkbGetKeyboardByName</emphasis>
+ request that loads a new keyboard description. Selecting for <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events allows Xkb-aware clients to be notified whenever a keyboard change
+occurs that may affect the keymap.
+</para>
+
+
+<para>
+When a client requests <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events, the server compares the range of keycodes for the current keyboard to
+the range of keycodes that are valid for the client. If they are not the same,
+the server immediately sends the client an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event. Even if the "new" keyboard is not new to the server, it is new to this
+particular client.
+</para>
+
+
+<para>
+When the server sends an <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event to a client to inform it of a new keycode range, it resets the stored
+range of legal keycodes for the client to the keycode range reported in the
+event; it does not reset this range for the client if it does not sent an
+<emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event to a client. Because Xkb-unaware clients and Xkb-aware clients that do
+not request <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events are never sent these events, the server’s notion of the legal keycode
+range never changes, and these clients never receive events from keys that fall
+outside of their notion of the legal keycode range.
+</para>
+
+
+<para>
+Clients that have not selected to receive <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events do, however, receive the <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event when a keyboard change occurs. Clients that have not selected to receive
+this event also receive numerous other events detailing the individual changes
+that occur when a keyboard change occurs.
+</para>
+
+
+<para>
+Clients wishing to track changes in <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ must watch for both <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ and <emphasis>
+XkbMapNotify</emphasis>
+ events, because a simple mapping change causes an <emphasis>
+XkbMapNotify</emphasis>
+ event and may change the range of valid keycodes, but does not cause an
+<emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event. If a client does not select for <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ events, the server restricts the range of keycodes reported to the client.
+</para>
+
+
+<para>
+In addition to filtering out-of-range key events, Xkb:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Adjusts core protocol <emphasis>
+MappingNotify</emphasis>
+ events to refer only to keys that match the stored legal range.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Reports keyboard mappings for keys that match the stored legal range to clients
+that issue a core protocol <emphasis>
+GetKeyboardMapping</emphasis>
+ request.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Reports modifier mappings only for keys that match the stored legal range to
+clients that issue a core protocol <emphasis>
+GetModifierMapping</emphasis>
+ request.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Restricts the core protocol <emphasis>
+ChangeKeyboardMapping</emphasis>
+ and <emphasis>
+SetModifierMapping</emphasis>
+ requests to keys that fall inside the stored legal range.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+In short, Xkb does everything possible to hide from Xkb-unaware clients the
+fact that the range of legal keycodes has changed, because such clients cannot
+be expected to deal with them. Xkb events and requests are not modified in this
+manner; all Xkb events report the full range of legal keycodes. No requested
+Xkb events are discarded, and no Xkb requests have their keycode range clamped.
+</para>
+
+
+<para>
+The structure for the <emphasis>
+XkbNewKeyboardNotify</emphasis>
+ event is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct _XkbNewKeyboardNotify {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event*/
+ Bool send_event; /* <emphasis>True</emphasis>
+ =&gt; synthetically generated */
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis>XkbNewKeyboardNotify</emphasis> */
+ int device; /* device ID of new keyboard */
+ int old_device; /* device ID of old keyboard */
+ int min_key_code; /* min keycode of new keyboard */
+ int max_key_code; /* max keycode of new keyboard */
+ int old_min_key_code; /* min keycode of old keyboard */
+ int old_max_key_code; /* max keycode of old keyboard */
+ unsigned int changed; /* changed aspects - see masks below */
+ char req_major; /* major request that caused change */
+ char req_minor; /* minor request that caused change */
+} <emphasis>XkbNewKeyboardNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+To receive name notify events, use <emphasis>
+XkbSelectEvents</emphasis>
+ (see section 4.3) with <emphasis>
+XkbNewKeyboardNotifyMask</emphasis>
+ in both the <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+ parameters. To receive events for only specific names, use <emphasis>
+XkbSelectEventDetails</emphasis>
+. Set the <emphasis>
+event_type</emphasis>
+ parameter to <emphasis>
+XkbNewKeyboardNotify</emphasis>
+, and set both the <emphasis>
+bits_to_change </emphasis>
+and<emphasis>
+ values_for_bits</emphasis>
+ detail parameter to a mask composed of a bitwise OR of masks in Table 19.1.
+</para>
+
+<table frame='none'>
+<title>XkbNewKeyboardNotifyEvent Details</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='1'>
+ <entry>XkbNewKeyboardNotify Event Details</entry>
+ <entry>Value</entry>
+ <entry>Circumstances</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='1'>
+ <entry><emphasis>XkbNKN_KeycodesMask</emphasis></entry>
+ <entry>(1L&lt;&lt;0)</entry>
+ <entry>Notification of keycode range changes wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbNKN_GeometryMask</emphasis></entry>
+ <entry>(1L&lt;&lt;1)</entry>
+ <entry>Notification of geometry changes wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbNKN_DeviceIDMask</entry>
+ <entry>(1L&lt;&lt;2)</entry>
+ <entry>Notification of device ID changes wanted</entry>
+ </row>
+ <row rowsep='0'>
+ <entry><emphasis>XkbNKN_AllChangesMask</emphasis></entry>
+ <entry>(0x7)</entry>
+ <entry>Includes all of the above masks</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ fields indicate what type of keyboard change has occurred.
+</para>
+
+
+<para>
+If <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ are zero, the device change was not caused by a software request to the server
+— a spontaneous change has occurred, such as hot-plugging a new device. In
+this case, <emphasis>
+device</emphasis>
+ is the device identifier for the new, current X keyboard device, but no
+implementation-independent guarantee can be made about <emphasis>
+old_device</emphasis>
+. <emphasis>
+old_device</emphasis>
+ may be identical to <emphasis>
+device</emphasis>
+ (an implementor is permitted to reuse the device specifier when the device
+changes); or it may be different. Note that <emphasis>
+req_major</emphasis>
+ and <emphasis>
+req_minor</emphasis>
+ being zero do not necessarily mean that the physical keyboard device has
+changed; rather, they only imply a spontaneous change outside of software
+control (some systems have keyboards that can change personality at the press
+of a key).
+</para>
+
+
+<para>
+If the keyboard change is the result of an X Input Extension <emphasis>
+ChangeKeyboardDevice</emphasis>
+ request, <emphasis>
+req_major</emphasis>
+ contains the input extension major opcode, and <emphasis>
+req_minor</emphasis>
+ contains the input extension request number for <emphasis>
+X_ChangeKeyboardDevice</emphasis>
+. In this case, <emphasis>
+device</emphasis>
+ and <emphasis>
+old_device</emphasis>
+ are different, with <emphasis>
+device</emphasis>
+ being the identifier for the new, current X keyboard device, and <emphasis>
+old_device</emphasis>
+ being the identifier for the former device.
+</para>
+
+
+<para>
+If the keyboard change is the result of an <emphasis>
+XkbGetKeyboardByName</emphasis>
+ function call, which generates an <emphasis>
+X_kbGetKbdByName</emphasis>
+ request, <emphasis>
+req_major</emphasis>
+ contains the Xkb extension base event code (see section 2.4), and <emphasis>
+req_minor</emphasis>
+ contains the event code for the Xkb extension request <emphasis>
+X_kbGetKbdByName</emphasis>
+. <emphasis>
+device</emphasis>
+ contains the device identifier for the new device, but nothing definitive can
+be said for <emphasis>
+old_device</emphasis>
+; it may be identical to <emphasis>
+device</emphasis>
+, or it may be different, depending on the implementation.
+</para>
+
+</chapter>
diff --git a/libX11/specs/XKB/ch20.xml b/libX11/specs/XKB/ch20.xml
new file mode 100644
index 000000000..e58686f35
--- /dev/null
+++ b/libX11/specs/XKB/ch20.xml
@@ -0,0 +1,1188 @@
+<chapter id='server_database_of_keyboard_components'>
+<title>Server Database of Keyboard Components</title>
+
+<para>
+The X server maintains a database of keyboard components, identified by
+component type. The database contains all the information necessary to build a
+complete keyboard description for a particular device, as well as to assemble
+partial descriptions. Table 20.1 identifies the component types and the type of
+information they contain.
+</para>
+
+<table frame='none'>
+<title>Server Database Keyboard Components</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Component Type</entry>
+ <entry>Component Primary Contents</entry>
+ <entry>May also contain</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>Keymap</entry>
+ <entry>
+<para>Complete keyboard description</para>
+<para>Normally assembled using a complete component from each of the other types</para>
+ </entry>
+ <entry></entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Keycodes</entry>
+ <entry>
+<para>Symbolic name for each key</para>
+<para>Minimum and maximum legal keycodes</para>
+ </entry>
+ <entry>
+<para>Aliases for some keys</para>
+<para>Symbolic names for indicators</para>
+<para>Description of indicators physically present</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Types</entry>
+ <entry>Key types</entry>
+ <entry>
+Real modifier bindings and symbolic names for some virtual modifiers
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Compatibility</entry>
+ <entry>Rules used to assign actions to keysyms</entry>
+ <entry>
+<para>Maps for some indicators</para>
+<para>Real modifier bindings and symbolic names for some virtual modifiers</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Symbols</entry>
+ <entry>
+<para>Symbol mapping for keyboard keys</para>
+<para>Modifier mapping</para>
+<para>Symbolic names for groups</para>
+ </entry>
+ <entry>
+<para>Explicit actions and behaviors for some keys</para>
+<para>Real modifier bindings and symbolic names for some virtual modifiers</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>Geometry</entry>
+ <entry>Layout of the keyboard</entry>
+ <entry>
+<para>Aliases for some keys; overrides keycodes component aliases</para>
+<para>Symbolic names for some indicators</para>
+<para>Description of indicators physically present</para>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+While a keymap is a database entry for a complete keyboard description, and
+therefore logically different from the individual component database entries,
+the rules for processing keymap entries are identical to those for the
+individual components. In the discussion that follows, the term component is
+used to refer to either individual components or a keymap.
+</para>
+
+<para>
+There may be multiple entries for each of the component types. An entry may be
+either <emphasis>
+complete</emphasis>
+ or <emphasis>
+partial</emphasis>
+. Partial entries describe only a piece of the corresponding keyboard component
+and are designed to be combined with other entries of the same type to form a
+complete entry.
+</para>
+
+<para>
+For example, a partial symbols map might describe the differences between a
+common ASCII keyboard and some national layout. Such a partial map is not
+useful on its own because it does not include those symbols that are the same
+on both the ASCII and national layouts (such as function keys). On the other
+hand, this partial map can be used to configure <emphasis>
+any</emphasis>
+ ASCII keyboard to use a national layout.
+</para>
+
+<para>
+When a keyboard description is built, the components are processed in the order
+in which they appear in Table 20.1; later definitions override earlier ones.
+</para>
+
+<sect1 id='component_names'>
+<title>Component Names</title>
+
+<para>
+Component names have the form "<emphasis>
+class(member)</emphasis>
+" where <emphasis>
+class</emphasis>
+ describes a subset of the available components for a particular type and the
+optional <emphasis>
+member</emphasis>
+ identifies a specific component from that subset. For example, the name
+"atlantis(acme)" for a symbols component might specify the symbols used for the
+atlantis national keyboard layout by the vendor "acme." Each class has an
+optional <emphasis>
+default</emphasis>
+ member — references that specify a class but not a member refer to the
+default member of the class, if one exists. Xkb places no constraints on the
+interpretation of the class and member names used in component names.
+</para>
+
+<para>
+The <emphasis>
+class</emphasis>
+ and <emphasis>
+member</emphasis>
+ names are both specified using characters from the Latin-1 character set. Xkb
+implementations must accept all alphanumeric characters, minus (‘-’) and
+underscore (‘_’) in class or member names, and must not accept parentheses,
+plus, vertical bar, percent sign, asterisk, question mark, or white space. The
+use of other characters is implementation-dependent.
+</para>
+
+</sect1>
+<sect1 id='listing_the_known_keyboard_components'>
+<title>Listing the Known Keyboard Components</title>
+
+<para>
+You may ask the server for a list of components for one or more component
+types. The request takes the form of a set of patterns, one pattern for each of
+the component types, including a pattern for the complete keyboard description.
+To obtain this list, use <emphasis>
+XkbListComponents</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbComponentListPtr<emphasis>
+ XkbListComponents</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+ptrns</emphasis>
+, <emphasis>
+max_inout</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbComponentNamesPtr <emphasis>
+ptrns</emphasis>
+; /* namelist for components of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int * <emphasis>
+max_inout</emphasis>
+; /* max # returned names, # left over */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbListComponents</emphasis>
+ queries the server for a list of component names matching the patterns
+specified in <emphasis>
+ptrns</emphasis>
+. It waits for a reply and returns the matching component names in an <emphasis>
+XkbComponentListRec</emphasis>
+ structure. When you are done using the structure, you should free it using
+<emphasis>
+XkbFreeComponentList</emphasis>
+. <emphasis>
+device_spec</emphasis>
+ indicates a particular device in which the caller is interested. A server is
+allowed (but not required) to restrict its reply to portions of the database
+that are relevant for that particular device.
+</para>
+
+
+<para>
+<emphasis>
+ptrns</emphasis>
+ is a pointer to an <emphasis>
+XkbComponentNamesRec</emphasis>
+, described below. Each of the fields in <emphasis>
+ptrns</emphasis>
+ contains a pattern naming the components of interest. Each of the patterns is
+composed of characters from the ISO <emphasis>
+Latin1</emphasis>
+ encoding, but can contain only parentheses, the wildcard characters
+‘<emphasis>
+?</emphasis>
+’ and ‘<emphasis>
+*</emphasis>
+’, and characters permitted in a component class or member name (see section
+20.1). A pattern may be <emphasis>
+NULL</emphasis>
+, in which case no components for that type is returned. Pattern matches with
+component names are case sensitive. The ‘<emphasis>
+?</emphasis>
+’ wildcard matches any single character, except a left or right parenthesis;
+the ‘<emphasis>
+*</emphasis>
+’ wildcard matches any number of characters, except a left or right
+parenthesis. If an implementation allows additional characters in a component
+class or member name other than those required by the Xkb extension (see
+section 20.1), the result of comparing one of the additional characters to
+either of the wildcard characters is implementation-dependent.
+</para>
+
+
+<para>
+If a pattern contains illegal characters, the illegal characters are ignored.
+The matching process is carried out as if the illegal characters were omitted
+from the pattern.
+</para>
+
+
+<para>
+<emphasis>
+max_inout</emphasis>
+ is used to throttle the amount of data passed to and from the server. On
+input, it specifies the maximum number of names to be returned (the total
+number of names in all component categories). Upon return from <emphasis>
+XkbListComponents</emphasis>
+, <emphasis>
+max_inout</emphasis>
+ contains the number of names that matched the request but were not returned
+because of the limit.
+</para>
+
+
+<para>
+The component name patterns used to describe the request are passed to
+<emphasis>
+XkbListComponents</emphasis>
+ using an <emphasis>
+XkbComponentNamesRec</emphasis>
+ structure. This structure has no special allocation constraints or
+interrelationships with other structures; allocate and free this structure
+using standard <emphasis>
+malloc</emphasis>
+ and <emphasis>
+free</emphasis>
+ calls or their equivalent:
+</para>
+
+<para><programlisting>
+typedef struct _XkbComponentNames {
+ char * keymap; /* keymap names */
+ char * keycodes; /* keycode names */
+ char * types; /* type names */
+ char * compat; /* compatibility map names */
+ char * symbols; /* symbol names */
+ char * geometry; /* geometry names */
+} <emphasis>XkbComponentNamesRec</emphasis>, *XkbComponentNamesPtr;
+</programlisting></para>
+
+<para>
+<emphasis>
+XkbListComponents</emphasis>
+ returns a pointer to an <emphasis>
+XkbComponentListRec</emphasis>
+:
+</para>
+
+<para><programlisting>
+typedef struct _XkbComponentList {
+ int num_keymaps; /* number of entries in keymap */
+ int num_keycodes; /* number of entries in keycodes */
+ int num_types; /* number of entries in types */
+ int num_compat; /* number of entries in compat */
+ int num_symbols; /* number of entries in symbols */
+ int num_geometry; /* number of entries in geometry;
+ XkbComponentNamePtr keymap; /* keymap names */
+ XkbComponentNamePtr keycodes; /* keycode names */
+ XkbComponentNamePtr types; /* type names */
+ XkbComponentNamePtr compat; /* compatibility map names */
+ XkbComponentNamePtr symbols; /* symbol names */
+ XkbComponentNamePtr geometry; /* geometry names */
+} <emphasis>XkbComponentListRec</emphasis>, *XkbComponentListPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbComponentName {
+ unsigned short flags; /* hints regarding component name */
+ char * name; /* name of component */
+} <emphasis>XkbComponentNameRec</emphasis>, *XkbComponentNamePtr;
+</programlisting></para>
+
+<para>
+Note that the structure used to specify patterns on input is an <emphasis>
+XkbComponentNamesRec</emphasis>
+, and that used to hold the individual component names upon return is an
+<emphasis>
+XkbComponentNameRec</emphasis>
+ (no trailing ‘s’ in Name).
+</para>
+
+
+<para>
+When you are done using the structure returned by <emphasis>
+XkbListComponents</emphasis>
+, free it using <emphasis>
+XkbFreeComponentList</emphasis>
+.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeComponentList</emphasis>
+(list)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbComponentListPtr list; /* pointer to <emphasis>
+XkbComponentListRec</emphasis>
+ to free */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+
+</sect1>
+<sect1 id='component_hints'>
+<title>Component Hints</title>
+
+<para>
+A set of flags is associated with each component; these flags provide
+additional hints about the component’s use. These hints are designated by bit
+masks in the flags field of the <emphasis>
+XkbComponentNameRec</emphasis>
+ structures contained in the <emphasis>
+XkbComponentListRec</emphasis>
+ returned from <emphasis>
+XkbListComponents</emphasis>
+. The least significant byte of the flags field has the same meaning for all
+types of keyboard components; the interpretation of the most significant byte
+is dependent on the type of component. The flags bits are defined in Table
+20.2. The symbols hints in Table 20.2 apply only to partial symbols components
+(those with <emphasis>
+XkbLC_Partial</emphasis>
+ also set); full symbols components are assumed to specify all of the pieces.
+</para>
+
+
+<para>
+The alphanumeric, modifier, keypad or function keys symbols hints should
+describe the primary intent of the component designer and should not be simply
+an exhaustive list of the kinds of keys that are affected. For example,
+national keyboard layouts affect primarily alphanumeric keys, but many affect a
+few modifier keys as well; such mappings should set only the <emphasis>
+XkbLC_AlphanumericKeys</emphasis>
+ hint. In general, symbols components should set only one of the four flags
+(<emphasis>
+XkbLC_AlternateGroup</emphasis>
+ may be combined with any of the other flags).
+</para>
+
+<table frame='none'>
+<title>XkbComponentNameRec Flags Bits</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Component Type</entry>
+ <entry>Component Hints (flags)</entry>
+ <entry>Meaning</entry>
+ <entry>Value</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>All Components</entry>
+ <entry><para><emphasis>XkbLC_Hidden</emphasis></para></entry>
+ <entry>Do not present to user</entry>
+ <entry>(1L&lt;&lt;0)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_Default</emphasis></entry>
+ <entry>Default member of class</entry>
+ <entry>(1L&lt;&lt;1)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_Partial</emphasis></entry>
+ <entry>Partial component</entry>
+ <entry>(1L&lt;&lt;2)</entry>
+</row>
+<row rowsep='0'>
+ <entry>Keymap</entry>
+ <entry>none</entry>
+ <entry></entry>
+ <entry></entry>
+</row>
+<row rowsep='0'>
+ <entry>Keycodes</entry>
+ <entry>none</entry>
+ <entry></entry>
+ <entry></entry>
+</row>
+<row rowsep='0'>
+ <entry>Types</entry>
+ <entry>none</entry>
+ <entry></entry>
+ <entry></entry>
+</row>
+<row rowsep='0'>
+ <entry>Compatibility</entry>
+ <entry>none</entry>
+ <entry></entry>
+ <entry></entry>
+</row>
+<row rowsep='0'>
+ <entry>Symbols</entry>
+ <entry><emphasis>XkbLC_AlphanumericKeys</emphasis></entry>
+ <entry>Bindings primarily for alphanumeric keyboard section</entry>
+ <entry>(1L&lt;&lt;8)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_ModifierKeys</emphasis></entry>
+ <entry>Bindings primarily for modifier keys</entry>
+ <entry>(1L&lt;&lt;9)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_KeypadKeys</emphasis></entry>
+ <entry>Bindings primarily for numeric keypad keys</entry>
+ <entry>(1L&lt;&lt;10)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_FunctionKeys</emphasis></entry>
+ <entry>Bindings primarily for function keys</entry>
+ <entry>(1L&lt;&lt;11)</entry>
+</row>
+<row rowsep='0'>
+ <entry></entry>
+ <entry><emphasis>XkbLC_AlternateGroup</emphasis></entry>
+ <entry>Bindings for an alternate group</entry>
+ <entry>(1L&lt;&lt;12)</entry>
+</row>
+<row rowsep='0'>
+ <entry>Geometry</entry>
+ <entry>none</entry>
+ <entry></entry>
+ <entry></entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+</sect1>
+<sect1 id='building_a_keyboard_description_using_the_server_database'>
+<title>Building a Keyboard Description Using the Server Database</title>
+
+<para>
+A client may request that the server fetch one or more components from its
+database and use those components to build a new server keyboard description.
+The new keyboard description may be built from scratch, or it may be built
+starting with the current keyboard description for a particular device. Once
+the keyboard description is built, all or part of it may be returned to the
+client. The parts returned to the client need not include all of the parts used
+to build the description. At the time it requests the server to build a new
+keyboard description, a client may also request that the server use the new
+description internally to replace the current keyboard description for a
+specific device, in which case the behavior of the device changes accordingly.
+</para>
+
+
+<para>
+To build a new keyboard description from a set of named components, and to
+optionally have the server use the resulting description to replace an active
+one, use <emphasis>
+XkbGetKeyboardByName</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDescPtr <emphasis>
+XkbGetKeyboardByName</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+names</emphasis>
+, <emphasis>
+want</emphasis>
+, <emphasis>
+need</emphasis>
+, <emphasis>
+load</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbComponentNamesPtr <emphasis>
+names</emphasis>
+; /* names of components to fetch */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+want</emphasis>
+; /* desired structures in returned record */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+need</emphasis>
+; /* mandatory structures in returned record */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+load</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; load into <emphasis>
+device_spec</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+names</emphasis>
+ contains a set of expressions describing the keyboard components the server
+should use to build the new keyboard description. <emphasis>
+want</emphasis>
+ and <emphasis>
+need</emphasis>
+ are bit fields describing the parts of the resulting keyboard description that
+should be present in the returned <emphasis>
+XkbDescRec</emphasis>
+.
+</para>
+
+
+<para>
+The individual fields in <emphasis>
+names</emphasis>
+ are <emphasis>
+component expressions</emphasis>
+ composed of keyboard component names (no wildcarding as may be used in
+<emphasis>
+XkbListComponents</emphasis>
+), the special component name symbol ‘%’, and the special operator
+characters ‘<emphasis>
++</emphasis>
+’ and ‘<emphasis>
+|</emphasis>
+’. A component expression is parsed left to right, as follows:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+The special component name "<emphasis>
+computed</emphasis>
+" may be used in <emphasis>
+keycodes</emphasis>
+ component expressions and refers to a component consisting of a set of
+keycodes computed automatically by the server as needed.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The special component name "<emphasis>
+canonical</emphasis>
+" may be used in <emphasis>
+types</emphasis>
+ component expressions and refers to a partial component defining the four
+standard key types: <emphasis>
+ALPHABETIC</emphasis>
+, <emphasis>
+ONE_LEVEL</emphasis>
+, <emphasis>
+TWO_LEVEL</emphasis>
+, and <emphasis>
+KEYPAD</emphasis>
+.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The special component name ‘<emphasis>
+%</emphasis>
+’ refers to the keyboard description for the device specified in <emphasis>
+device_spec</emphasis>
+ or the keymap names component. If a keymap names component is specified that
+does not begin with ‘+’ or ‘|’ and does not contain ‘<emphasis>
+%</emphasis>
+’, then ‘<emphasis>
+%</emphasis>
+’ refers to the description generated by the keymap names component.
+Otherwise, it refers to the keyboard description for <emphasis>
+device_spec</emphasis>
+.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The ‘<emphasis>
++</emphasis>
+’ operator specifies that the following component should <emphasis>
+override</emphasis>
+ the currently assembled description; any definitions that are present in both
+components are taken from the second.
+ </para>
+</listitem>
+<listitem>
+ <para>
+The ‘<emphasis>
+|</emphasis>
+’ operator specifies that the next specified component should <emphasis>
+augment</emphasis>
+ the currently assembled description; any definitions that are present in both
+components are taken from the first.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If the component expression begins with an operator, a leading ‘<emphasis>
+%</emphasis>
+’ is implied.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If any unknown or illegal characters appear anywhere in the expression, the
+entire expression is invalid and is ignored.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+For example, if <emphasis>
+names-&gt;symbols</emphasis>
+ contained the expression "+de", it specifies that the default member of the
+"de" class of symbols should be applied to the current keyboard mapping,
+overriding any existing definitions (it could also be written "+de(default)").
+</para>
+
+
+<para>
+Here is a slightly more involved example: the expression
+"acme(ascii)+de(basic)|iso9995-3" constructs a German (de) mapping for the
+ASCII keyboard supplied by the "acme" vendor. The new definition begins with
+the symbols for the ASCII keyboard for Acme (<emphasis>
+acme(ascii)</emphasis>
+), overrides them with definitions for the basic German keyboard (<emphasis>
+de(basic)</emphasis>
+), and then applies the definitions from the default iso9995-3 keyboard
+(<emphasis>
+iso9995-3</emphasis>
+) to any undefined keys or groups of keys (part three of the iso9995 standard
+defines a common set of bindings for the secondary group, but allows national
+layouts to override those definitions where necessary).
+</para>
+
+<note><para>The interpretation of the above expression components (acme, ascii,
+de, basic, iso9995-3) is not defined by Xkb; only the operations and their
+ordering are.</para></note>
+
+<para>
+Note that the presence of a keymap <emphasis>
+names</emphasis>
+ component that does not contain ‘<emphasis>
+%</emphasis>
+’ (either explicit or implied by virtue of an expression starting with an
+operator) indicates a description that is independent of the keyboard
+description for the device specified in <emphasis>
+device_spec</emphasis>
+. The same is true of requests in which the keymap names component is empty and
+all five other names components contain expressions void of references to
+‘<emphasis>
+%</emphasis>
+’. Requests of this form allow you to deal with keyboard definitions
+independent of any actual device.
+</para>
+
+
+<para>
+The server parses all non-<emphasis>
+NULL</emphasis>
+ fields in <emphasis>
+names</emphasis>
+ and uses them to build a keyboard description. However, before parsing the
+expressions in <emphasis>
+names</emphasis>
+, the server ORs the bits in <emphasis>
+want</emphasis>
+ and <emphasis>
+need</emphasis>
+ together and examines the result in relationship to the expressions in
+<emphasis>
+names</emphasis>
+. Table 20.3 identifies the components that are required for each of the
+possible bits in <emphasis>
+want</emphasis>
+ or <emphasis>
+need</emphasis>
+. If a required component has not been specified in the <emphasis>
+names</emphasis>
+ structure (the corresponding field is <emphasis>
+NULL</emphasis>
+), the server substitutes the expression "<emphasis>
+%</emphasis>
+", resulting in the component values being taken from <emphasis>
+device_spec</emphasis>
+. In addition, if <emphasis>
+load</emphasis>
+ is <emphasis>
+True</emphasis>
+, the server modifies <emphasis>
+names</emphasis>
+ if necessary (again using a "<emphasis>
+%</emphasis>
+" entry) to ensure all of the following fields are non-<emphasis>
+NULL</emphasis>
+: <emphasis>
+types</emphasis>
+, <emphasis>
+keycodes</emphasis>
+, <emphasis>
+symbols</emphasis>
+, and <emphasis>
+compat</emphasis>
+.<emphasis>
+</emphasis>
+</para>
+
+<table frame='none'>
+<title>Want and Need Mask Bits and Required Names Components</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>want or need mask bit</entry>
+ <entry>Required names Components</entry>
+ <entry>value</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbGBN_TypesMask</entry>
+ <entry>Types</entry>
+ <entry>(1L&lt;&lt;0)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_CompatMapMask</entry>
+ <entry>Compat</entry>
+ <entry>(1L&lt;&lt;1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_ClientSymbolsMask</entry>
+ <entry>Types + Symbols + Keycodes</entry>
+ <entry>(1L&lt;&lt;2)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_ServerSymbolsMask</entry>
+ <entry>Types + Symbols + Keycodes</entry>
+ <entry>(1L&lt;&lt;3)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_SymbolsMask</entry>
+ <entry>Symbols</entry>
+ <entry>(1L&lt;&lt;1)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_IndicatorMapMask</entry>
+ <entry>Compat</entry>
+ <entry>(1L&lt;&lt;4)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_KeyNamesMask</entry>
+ <entry>Keycodes</entry>
+ <entry>(1L&lt;&lt;5)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_GeometryMask</entry>
+ <entry>Geometry</entry>
+ <entry>(1L&lt;&lt;6)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_OtherNamesMask</entry>
+ <entry>Types + Symbols + Keycodes + Compat + Geometry</entry>
+ <entry>(1L&lt;&lt;7)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_AllComponentsMask</entry>
+ <entry></entry>
+ <entry>(0xff)</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+<emphasis>
+need</emphasis>
+ specifies a set of keyboard components that the server must be able to resolve
+in order for <emphasis>
+XkbGetKeyboardByName</emphasis>
+ to succeed; if any of the components specified in <emphasis>
+need</emphasis>
+ cannot be successfully resolved, <emphasis>
+XkbGetKeyboardByName</emphasis>
+ fails.
+</para>
+
+
+<para>
+<emphasis>
+want</emphasis>
+ specifies a set of keyboard components that the server should attempt to
+resolve, but that are not mandatory. If the server is unable to resolve any of
+these components, <emphasis>
+XkbGetKeyboardByName</emphasis>
+ still succeeds. Bits specified in <emphasis>
+want</emphasis>
+ that are also specified in <emphasis>
+need</emphasis>
+ have no effect in the context of <emphasis>
+want</emphasis>
+.
+</para>
+
+
+<para>
+If <emphasis>
+load</emphasis>
+ is <emphasis>
+True</emphasis>
+, the server updates its keyboard description for <emphasis>
+device_spec</emphasis>
+ to match the result of the keyboard description just built. If load is
+<emphasis>
+False</emphasis>
+, the server’s description for device <emphasis>
+device_spec</emphasis>
+ is not updated. In all cases, the parts specified by <emphasis>
+want</emphasis>
+ and <emphasis>
+need</emphasis>
+ from the just-built keyboard description are returned.
+</para>
+
+
+<para>
+The <emphasis>
+names</emphasis>
+ structure in an <emphasis>
+XkbDescRec</emphasis>
+ keyboard description record (see Chapter 18) contains one field for each of
+the five component types used to build a keyboard description. When a keyboard
+description is built from a set of database components, the corresponding
+fields in this <emphasis>
+names</emphasis>
+ structure are set to match the expressions used to build the component.
+</para>
+
+
+<para>
+The entire process of building a new keyboard description from the server
+database of components and returning all or part of it is diagrammed in Figure
+20.1:
+</para>
+
+<mediaobject>
+ <imageobject> <imagedata format="SVG" fileref="XKBlib-21.svg"/>
+ </imageobject>
+ <caption>Building a New Keyboard Description from the Server Database</caption>
+</mediaobject>
+
+<para>
+The information returned to the client in the <emphasis>
+XkbDescRec</emphasis>
+ is essentially the result of a series of calls to extract information from a
+fictitious device whose description matches the one just built. The calls
+corresponding to each of the mask bits are summarized in Table 20.4, together
+with the <emphasis>
+XkbDescRec</emphasis>
+ components that are filled in.
+</para>
+
+<table frame='none'>
+<title>XkbDescRec Components Returned for Values of Want &amp; Needs</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Request (want+need)</entry>
+ <entry>Fills in Xkb components</entry>
+ <entry>Equivalent Function Call</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbGBN_TypesMask</entry>
+ <entry>map.types</entry>
+ <entry>XkbGetUpdatedMap(dpy, XkbTypesMask, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_ServerSymbolsMask</entry>
+ <entry>server</entry>
+ <entry>XkbGetUpdatedMap(dpy, XkbAllClientInfoMask, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_ClientSymbolsMask</entry>
+ <entry>map, including map.types</entry>
+ <entry>XkbGetUpdatedMap(dpy, XkbAllServerInfoMask, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_IndicatorMaps</entry>
+ <entry>indicators</entry>
+ <entry>XkbGetIndicatorMap(dpy, XkbAllIndicators, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_CompatMapMask</entry>
+ <entry>compat</entry>
+ <entry>XkbGetCompatMap(dpy, XkbAllCompatMask, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_GeometryMask</entry>
+ <entry>geom</entry>
+ <entry>XkbGetGeometry(dpy, Xkb)</entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_KeyNamesMask</entry>
+ <entry>
+<para>names.keys</para>
+<para>names.key_aliases</para>
+ </entry>
+ <entry>
+XkbGetNames(dpy, XkbKeyNamesMask | XkbKeyAliasesMask, Xkb)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbGBN_OtherNamesMask</entry>
+ <entry>
+<para>names.keycodes</para>
+<para>names.geometry</para>
+<para>names.symbols</para>
+<para>names.types</para>
+<para>map.types[*].lvl_names[*]</para>
+<para>names.compat</para>
+<para>names.vmods</para>
+<para>names.indicators</para>
+<para>names.groups</para>
+<para>names.radio_groups</para>
+<para>names.phys_symbols</para>
+ </entry>
+ <entry>
+<para>XkbGetNames(dpy, XkbAllNamesMask &amp;</para>
+<para>~(XkbKeyNamesMask | XkbKeyAliasesMask),</para>
+<para>Xkb)</para>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+There is no way to determine which components specified in <emphasis>
+want</emphasis>
+ (but not in <emphasis>
+need</emphasis>
+) were actually fetched, other than breaking the call into successive calls to
+<emphasis>
+XkbGetKeyboardByName</emphasis>
+ and specifying individual components.
+</para>
+
+
+<para>
+<emphasis>
+XkbGetKeyboardByName</emphasis>
+ always sets <emphasis>
+min_key_code</emphasis>
+ and <emphasis>
+max_key_code</emphasis>
+ in the returned <emphasis>
+XkbDescRec</emphasis>
+ structure.
+</para>
+
+
+<para>
+<emphasis>XkbGetKeyboardByName</emphasis>
+is synchronous; it sends the request to the server to build a new keyboard
+description and waits for the reply. If successful, the return value is
+non-<emphasis>NULL</emphasis>.
+<emphasis>XkbGetKeyboardByName</emphasis>
+generates a <emphasis>BadMatch</emphasis>
+protocol error if errors are encountered when building the keyboard
+description.
+</para>
+
+
+<para>
+If you simply want to obtain information about the current keyboard device,
+rather than generating a new keyboard description from elements in the server
+database, use <emphasis>
+XkbGetKeyboard</emphasis>
+ (see section 6.2).
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDescPtr <emphasis>
+XkbGetKeyboard</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+which</emphasis>
+, <emphasis>
+device_spec</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int<emphasis>
+ which</emphasis>
+; /* mask of components of <emphasis>
+XkbDescRec</emphasis>
+ of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ device_spec</emphasis>
+; /* device ID */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetKeyboard</emphasis>
+ is used to read the current description for one or more components of a
+keyboard device. It calls <emphasis>
+XkbGetKeyboardByName</emphasis>
+ as follows:
+</para>
+
+
+<para>
+<emphasis>
+XkbGetKeyboardByName</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+device_spec</emphasis>
+, <emphasis>
+NULL</emphasis>
+, <emphasis>
+which</emphasis>
+, <emphasis>
+which</emphasis>
+, <emphasis>
+False</emphasis>
+).
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch21.xml b/libX11/specs/XKB/ch21.xml
new file mode 100644
index 000000000..aef8378fe
--- /dev/null
+++ b/libX11/specs/XKB/ch21.xml
@@ -0,0 +1,2043 @@
+<chapter id='attaching_xkb_actions_to_x_input_extension_devices'>
+<title>Attaching Xkb Actions to X Input Extension Devices</title>
+
+<para>
+The X input extension allows an X server to support multiple keyboards, as well
+as other input devices, in addition to the core X keyboard and pointer. The
+input extension categorizes devices by grouping them into classes. Keyboards
+and other input devices with keys are classified as KeyClass devices by the
+input extension. Other types of devices supported by the input extension
+include, but are not limited to: mice, tablets, touchscreens, barcode readers,
+button boxes, trackballs, identifier devices, data gloves, and eye trackers.
+Xkb provides additional control over all X input extension devices, whether
+they are <emphasis>KeyClass</emphasis>
+ devices or not, as well as the core keyboard and pointer.
+</para>
+
+
+<para>
+If an X server implements support for both the input extension and Xkb, the
+server implementor determines whether interaction between Xkb and the input
+extension is allowed. Implementors are free to restrict the effects of Xkb to
+only the core X keyboard device or allow interaction between Xkb and the input
+extension.
+</para>
+
+
+<para>
+Several types of interaction between Xkb and the input extension are defined by
+Xkb. Some or all may be allowed by the X server implementation.
+</para>
+
+
+<para>
+Regardless of whether the server allows interaction between Xkb and the input
+extension, the following access is provided:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Xkb functionality for the core X keyboard device and its mapping is accessed
+via the functions described in the other chapters of this specification.
+ </para>
+</listitem>
+<listitem>
+ <para>
+Xkb functionality for the core X pointer device is accessed via the
+XkbGetDeviceInfo and XkbSetDeviceInfo functions described in this chapter.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+If all types of interaction are allowed between Xkb and the input extension,
+the following additional access is provided:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+If allowed, Xkb functionality for additional <emphasis>
+KeyClass</emphasis>
+ devices supported by the input extension is accessed via those same functions.
+ </para>
+</listitem>
+<listitem>
+ <para>
+If allowed, Xkb functionality for non-<emphasis>
+KeyClass</emphasis>
+ devices supported by the input extension is also accessed via the
+XkbGetDeviceInfo and XkbSetDeviceInfo functions described in this chapter.
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+Each device has an X Input Extension device ID. Each device may have several
+classes of feedback. For example, there are two types of feedbacks that can
+generate bells: bell feedback and keyboard feedback (<emphasis>
+BellFeedbackClass</emphasis>
+ and <emphasis>
+KbdFeedbackClass</emphasis>
+). A device can have more than one feedback of each type; the feedback ID
+identifies the particular feedback within its class.
+</para>
+
+
+<para>
+A keyboard feedback has:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Auto-repeat status (global and per key)
+ </para>
+</listitem>
+<listitem>
+ <para>
+32 LEDs
+ </para>
+</listitem>
+<listitem>
+ <para>
+A bell
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+An indicator feedback has:
+</para>
+
+<itemizedlist>
+<listitem>
+ <para>
+Up to 32 LEDs
+ </para>
+</listitem>
+</itemizedlist>
+
+<para>
+If the input extension is present and the server allows interaction between the
+input extension and Xkb, then the core keyboard, the core keyboard indicators,
+and the core keyboard bells may each be addressed using an appropriate device
+spec, class, and ID. The constant <emphasis>
+XkbXIDfltID</emphasis>
+ may be used as the device ID to specify the core keyboard indicators for the
+core indicator feedback. The particular device ID corresponding to the core
+keyboard feedback and the core indicator feedback may be obtained by calling
+<emphasis>
+XkbGetDeviceInfo</emphasis>
+ and specifying <emphasis>
+XkbUseCoreKbd</emphasis>
+ as the <emphasis>
+device_spec</emphasis>
+; the values will be returned in <emphasis>
+dflt_kbd_id</emphasis>
+ and <emphasis>
+dflt_led_id</emphasis>
+.
+</para>
+
+
+<para>
+If the server does not allow Xkb access to input extension <emphasis>
+KeyClass</emphasis>
+ devices, attempts to use Xkb requests with those devices fail with a
+Bad<emphasis>
+Keyboard</emphasis>
+ error. Attempts to access non-<emphasis>
+KeyClass</emphasis>
+ input extension devices via XkbGetDeviceInfo and XkbSetDeviceInfo fail
+silently if Xkb access to those devices is not supported by the X server.
+</para>
+
+<sect1 id='xkbdeviceinforec'>
+<title>XkbDeviceInfoRec</title>
+
+<para>
+Information about X Input Extension devices is transferred between a client
+program and the Xkb extension in an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure:
+</para>
+
+<para><programlisting>
+typedef struct {
+ char * name; /* name for device */
+ Atom type; /* name for class of devices */
+ unsigned short device_spec; /* device of interest */
+ Bool has_own_state; /* <emphasis> True</emphasis> =&gt;this
+ device has its own state */
+ unsigned short supported; /* bits indicating supported capabilities */
+ unsigned short unsupported; /* bits indicating unsupported capabilities */
+ unsigned short num_btns; /* number of entries in <emphasis> btn_acts</emphasis> */
+ XkbAction * btn_acts; /* button actions */
+ unsigned short sz_leds; /* total number of entries in LEDs vector */
+ unsigned short num_leds; /* number of valid entries in LEDs vector */
+ unsigned short dflt_kbd_fb; /* input extension ID of default (core kbd) indicator */
+ unsigned short dflt_led_fb; /* input extension ID of default indicator feedback */
+ XkbDeviceLedInfoPtr leds; /* LED descriptions */
+} <emphasis>XkbDeviceInfoRec</emphasis>, *XkbDeviceInfoPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct {
+ unsigned short led_class; /* class for this LED device*/
+ unsigned short led_id; /* ID for this LED device */
+ unsigned int phys_indicators; /* bits for which LEDs physically
+ present */
+ unsigned int maps_present; /* bits for which LEDs have maps in
+ <emphasis>maps</emphasis> */
+ unsigned int names_present; /* bits for which LEDs are in
+ <emphasis> names</emphasis> */
+ unsigned int state; /* 1 bit =&gt; corresponding LED is on */
+ Atom names[XkbNumIndicators]; /* names for LEDs */
+ XkbIndicatorMapRec maps; /* indicator maps for each LED */
+} <emphasis>XkbDeviceLedInfoRec</emphasis>, *XkbDeviceLedInfoPtr;
+</programlisting></para>
+
+<para>
+The <emphasis>
+type</emphasis>
+ field is a registered symbolic name for a class of devices (for example,
+"TABLET"). If a device is a keyboard (that is, is a member of <emphasis>
+KeyClass</emphasis>
+), it has its own state, and <emphasis>
+has_own_state</emphasis>
+ is <emphasis>
+True</emphasis>
+. If <emphasis>
+has_own_state</emphasis>
+ is <emphasis>
+False</emphasis>
+, the state of the core keyboard is used. The <emphasis>
+supported</emphasis>
+ and <emphasis>
+unsupported</emphasis>
+ fields are masks where each bit indicates a capability. The meaning of the
+mask bits is listed in Table 21.1, together with the fields in the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure that are associated with the capability represented by each bit. The
+same bits are used to indicate the specific information desired in many of the
+functions described subsequently in this section.
+</para>
+
+<table frame='none'>
+<title>XkbDeviceInfoRec Mask Bits</title>
+<tgroup cols='4'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+ <row rowsep='0'>
+ <entry>Name</entry>
+ <entry>XkbDeviceInfoRec Fields Effected</entry>
+ <entry>Value</entry>
+ <entry>Capability If Set</entry>
+ </row>
+</thead>
+<tbody>
+ <row rowsep='0'>
+ <entry>XkbXI_KeyboardsMask</entry>
+ <entry></entry>
+ <entry>(1L &lt;&lt; 0)</entry>
+ <entry>
+Clients can use all Xkb requests and events with
+<emphasis>KeyClass</emphasis>
+devices supported by the input device extension.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_ButtonActionsMask</entry>
+ <entry>
+<para>num_btns</para>
+<para>btn_acts</para>
+ </entry>
+ <entry>(1L &lt;&lt;1)</entry>
+ <entry>
+Clients can assign key actions to buttons on non-<emphasis>
+KeyClass</emphasis>
+input extension devices.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_IndicatorNamesMask</entry>
+ <entry>leds-&gt;names</entry>
+ <entry>(1L &lt;&lt;2)</entry>
+ <entry>
+Clients can assign names to indicators on non-<emphasis>
+KeyClass</emphasis>
+ input extension devices.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_IndicatorMapsMask</entry>
+ <entry>leds-&gt;maps</entry>
+ <entry>(1L &lt;&lt;3)</entry>
+ <entry>
+Clients can assign indicator maps to indicators on non-<emphasis>
+KeyClass</emphasis>
+ input extension devices.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_IndicatorStateMask</entry>
+ <entry>leds-&gt;state</entry>
+ <entry>(1L &lt;&lt;4)</entry>
+ <entry>
+Clients can request the status of indicators on non-<emphasis>
+KeyClass</emphasis>
+ input extension devices.
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_IndicatorsMask</entry>
+ <entry>
+<para>sz_leds</para>
+<para>num_leds</para>
+<para>leds-&gt;*</para>
+ </entry>
+ <entry>(0x1c)</entry>
+ <entry>
+<para>XkbXI_IndicatorNamesMask |</para>
+<para>XkbXI_IndicatorMapsMask |</para>
+<para>XkbXI_IndicatorStateMask</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_UnsupportedFeaturesMask</entry>
+ <entry>unsupported</entry>
+ <entry>(1L &lt;&lt;15)</entry>
+ <entry></entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_AllDeviceFeaturesMask</entry>
+ <entry>Those selected by Value column masks</entry>
+ <entry>(0x1e)</entry>
+ <entry>
+<para>XkbXI_IndicatorsMask | </para>
+<para>XkbSI_ButtonActionsMask</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_AllFeaturesMask</entry>
+ <entry>Those selected by Value column masks</entry>
+ <entry>(0x1f)</entry>
+ <entry>
+<para>XkbSI_AllDeviceFeaturesMask |</para>
+<para>XkbSI_KeyboardsMask</para>
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry>XkbXI_AllDetailsMask</entry>
+ <entry>Those selected by Value column masks</entry>
+ <entry>(0x801f)</entry>
+ <entry>
+<para>XkbXI_AllFeaturesMask | </para>
+<para>XkbXI_UnsupportedFeaturesMask</para>
+ </entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+The <emphasis>
+name</emphasis>
+, <emphasis>
+type</emphasis>
+, <emphasis>
+has_own_state</emphasis>
+, <emphasis>
+supported</emphasis>
+, and <emphasis>
+unsupported</emphasis>
+ fields are always filled in when a valid reply is returned from the server
+involving an <emphasis>
+XkbDeviceInfoRec</emphasis>
+. All of the other fields are modified only if the particular function asks for
+them.
+</para>
+
+</sect1>
+<sect1 id='querying_xkb_features_for_non_keyclass_input_extension_devices'>
+<title>Querying Xkb Features for Non-KeyClass Input Extension Devices</title>
+
+<para>
+To determine whether the X server allows Xkb access to particular capabilities
+of input devices other than the core X keyboard, or to determine the status of
+indicator maps, indicator names or button actions on a non-<emphasis>
+KeyClass</emphasis>
+ extension device, use XkbGetDeviceInfo.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDeviceInfoPtr <emphasis>
+XkbGetDeviceInfo</emphasis>
+(<emphasis>
+dpy</emphasis>
+, which, device_spec, ind_class, ind_id)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int which; /* mask indicating information to
+return */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+device_spec</emphasis>
+; /* device ID, or <emphasis>
+XkbUseCoreKbd</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ind_class</emphasis>
+; /* feedback class for indicator requests */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ind_id</emphasis>
+; /* feedback ID for indicator requests */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetDeviceInfo</emphasis>
+ returns information about the input device specified by <emphasis>
+device_spec</emphasis>
+. Unlike the <emphasis>
+device_spec</emphasis>
+ parameter of most Xkb functions, <emphasis>
+device_spec</emphasis>
+ does not need to be a keyboard device. It must, however, indicate either the
+core keyboard or a valid X Input Extension device.
+</para>
+
+
+<para>
+The <emphasis>
+which </emphasis>
+parameter<emphasis>
+ </emphasis>
+is a mask specifying optional information to be returned. It is an inclusive OR
+of one or more of the values from Table 21.1 and causes the returned <emphasis>
+XkbDeviceInfoRec</emphasis>
+ to contain values for the corresponding fields specified in the table.
+</para>
+
+
+<para>
+The <emphasis>
+XkbDeviceInfoRec</emphasis>
+ returned by <emphasis>
+XkbGetDeviceInfo</emphasis>
+ always has values for <emphasis>
+name</emphasis>
+ (may be a null string, ""), <emphasis>
+type</emphasis>
+, <emphasis>
+supported</emphasis>
+, <emphasis>
+unsupported</emphasis>
+, <emphasis>
+has_own_state</emphasis>
+, <emphasis>
+dflt_kbd_fd</emphasis>
+, and <emphasis>
+dflt_kbd_fb</emphasis>
+. Other fields are filled in as specified by <emphasis>
+which</emphasis>
+.
+</para>
+
+
+<para>
+Upon return, the <emphasis>
+supported</emphasis>
+ field will be set to the inclusive OR of zero or more bits from Table 21.1;
+each bit set indicates an optional Xkb extension device feature supported by
+the server implementation, and a client may modify the associated behavior.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbButtonActionsMask</emphasis>
+ bit is set in <emphasis>
+which</emphasis>
+, the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ returned will have the button actions (<emphasis>
+btn_acts</emphasis>
+ field) filled in for all buttons.
+</para>
+
+
+<para>
+If <emphasis>
+which</emphasis>
+ includes one of the bits in XkbXI_IndicatorsMask, the feedback class of the
+indicators must be specified in ind_class, and the feedback ID of the
+indicators must be specified in ind_id. If the request does not include any of
+the bits in XkbXI_IndicatorsMask, the ind_class and ind_id parameters are
+ignored. The class and ID can be obtained via the input device extension
+XListInputDevices request.
+</para>
+
+
+<para>
+If any of the <emphasis>
+XkbXI_IndicatorsMask</emphasis>
+ bits are set in <emphasis>
+which</emphasis>
+, the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ returned will have filled in the portions of the <emphasis>
+leds</emphasis>
+ structure corresponding to the indicator feedback identified by <emphasis>
+ind_class</emphasis>
+ and <emphasis>
+ind_id</emphasis>
+. The <emphasis>
+leds</emphasis>
+ vector of the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ is allocated if necessary and <emphasis>
+sz_leds</emphasis>
+ and <emphasis>
+num_leds</emphasis>
+ filled in. The <emphasis>
+led_class</emphasis>
+, <emphasis>
+led_id</emphasis>
+ and <emphasis>
+phys_indicators</emphasis>
+ fields of the <emphasis>
+leds</emphasis>
+ entry corresponding to <emphasis>
+ind_class</emphasis>
+ and <emphasis>
+ind_id</emphasis>
+ are always filled in. If <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+, the <emphasis>
+names_present</emphasis>
+ and <emphasis>
+names</emphasis>
+ fields of the <emphasis>
+leds</emphasis>
+ structure corresponding to <emphasis>
+ind_class</emphasis>
+ and <emphasis>
+ind_id</emphasis>
+ are returned.<emphasis>
+ </emphasis>
+If <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorStateMask</emphasis>
+<emphasis>
+,</emphasis>
+ the corresponding <emphasis>
+state</emphasis>
+ field is updated. If <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorMapsMask</emphasis>
+, the <emphasis>
+maps_present</emphasis>
+ and <emphasis>
+maps</emphasis>
+ fields are updated.
+</para>
+
+
+<para>
+Xkb provides convenience functions to request subsets of the information
+available via <emphasis>
+XkbGetDeviceInfo</emphasis>
+. These convenience functions mirror some of the mask bits. The functions all
+take an <emphasis>
+XkbDeviceInfoPtr</emphasis>
+ as an input argument and operate on the X Input Extension device specified by
+the <emphasis>
+device_spec</emphasis>
+ field of the structure. Only the parts of the structure indicated in the
+function description are updated. The <emphasis>
+XkbDeviceInfo</emphasis>
+Rec structure used in the function call can be obtained by calling
+XkbGetDeviceInfo or can be allocated by calling XkbAllocDeviceInfo (see section
+21.3).
+</para>
+
+
+<para>
+These convenience functions are described as follows.
+</para>
+
+
+<para>
+To query the button actions associated with an X Input Extension device, use
+XkbGetDeviceButtonActions.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetDeviceButtonActions</emphasis>
+(<emphasis>
+dpy, device_info, all_buttons, first_button, num_buttons</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure to update with
+results */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+all_buttons</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; get information for all buttons */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int first_button; /* number of first button for
+which info is desired */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int num_buttons; /* number of buttons for which
+info is desired */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetDeviceButtonActions</emphasis>
+ queries the server for the desired button information for the device indicated
+by the <emphasis>
+device_spec</emphasis>
+ field of <emphasis>
+device_info</emphasis>
+ and waits for a reply. If successful,<emphasis>
+ XkbGetDeviceButtonActions</emphasis>
+ backfills the button actions (<emphasis>
+btn_acts</emphasis>
+ field of <emphasis>
+device_info</emphasis>
+) for only the requested buttons, updates the <emphasis>
+name</emphasis>
+, <emphasis>
+type</emphasis>
+, <emphasis>
+supported</emphasis>
+, and <emphasis>
+unsupported</emphasis>
+ fields, and returns <emphasis>
+Success</emphasis>
+.
+</para>
+
+
+<para>
+<emphasis>
+all_buttons</emphasis>
+, <emphasis>
+first_button</emphasis>
+ and <emphasis>
+num_buttons</emphasis>
+ specify the device buttons for which actions should be returned. Setting
+<emphasis>
+all_buttons</emphasis>
+ to <emphasis>
+True</emphasis>
+ requests actions for all device buttons; if <emphasis>
+all_buttons</emphasis>
+ is <emphasis>
+False</emphasis>
+, <emphasis>
+first_button</emphasis>
+ and <emphasis>
+num_buttons</emphasis>
+ specify a range of buttons for which actions are requested.
+</para>
+
+
+<para>
+If a compatible version of Xkb is not available in the server or the Xkb
+extension has not been properly initialized, XkbGetDeviceButtonActions returns
+<emphasis>
+BadAccess</emphasis>
+. If allocation errors occur, a <emphasis>
+BadAlloc</emphasis>
+ status is returned. If the specified device (<emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+device_spec</emphasis>
+) is invalid, a BadKeyboard status is returned. If the device has no buttons, a
+Bad<emphasis>
+Match</emphasis>
+ status is returned. If <emphasis>
+first_button</emphasis>
+ and <emphasis>
+num_buttons</emphasis>
+ specify illegal buttons, a Bad<emphasis>
+Value</emphasis>
+ status is returned.
+</para>
+
+
+<para>
+To query the indicator names, maps, and state associated with an LED feedback
+of an input extension device, use XkbGetDeviceLedInfo.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetDeviceLedInfo</emphasis>
+(<emphasis>
+dpy, device_i</emphasis>
+nfo, led_class, led_id, which)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure to update with
+results */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+led_class</emphasis>
+; /* LED feedback class assigned by input extension */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int led_id; /* LED feedback ID assigned by input
+extension */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int which; /* mask indicating desired
+information */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbGetDeviceLedInfo</emphasis>
+ queries the server for the desired LED information for the feedback specified
+by <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ for the X input extension device indicated by <emphasis>
+device_spec</emphasis>
+-&gt;<emphasis>
+device_info</emphasis>
+ and waits for a reply. If successful, <emphasis>
+XkbGetDeviceLedInfo</emphasis>
+ backfills the relevant fields of <emphasis>
+device_info</emphasis>
+ as determined by <emphasis>
+which</emphasis>
+ with the results and returns <emphasis>
+Success</emphasis>
+. Valid values for <emphasis>
+which</emphasis>
+ are the inclusive OR of any of <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+, <emphasis>
+XkbXI_IndicatorMapsMask</emphasis>
+, and <emphasis>
+XkbXI_IndicatorStateMask</emphasis>
+.
+</para>
+
+
+<para>
+The fields of <emphasis>
+device_info</emphasis>
+ that are filled in when this request succeeds are <emphasis>
+name, type, supported</emphasis>
+, and <emphasis>
+unsupported</emphasis>
+, and portions of the <emphasis>
+leds</emphasis>
+ structure corresponding to <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ as indicated by the bits set in <emphasis>
+which</emphasis>
+. The <emphasis>
+device_info-&gt;leds</emphasis>
+ vector is allocated if necessary and <emphasis>
+sz_leds</emphasis>
+ and <emphasis>
+num_leds</emphasis>
+ filled in. The <emphasis>
+led_class</emphasis>
+, <emphasis>
+led_id</emphasis>
+ and <emphasis>
+phys_indicators</emphasis>
+ fields of the <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ entry corresponding to <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ are always filled in.
+</para>
+
+
+<para>
+If <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+, the <emphasis>
+names_present</emphasis>
+ and <emphasis>
+names</emphasis>
+ fields of the <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ structure corresponding to <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ are updated, if <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorStateMask</emphasis>
+<emphasis>
+,</emphasis>
+ the corresponding <emphasis>
+state</emphasis>
+ field is updated, and if <emphasis>
+which</emphasis>
+ contains <emphasis>
+XkbXI_IndicatorMapsMask</emphasis>
+, the <emphasis>
+maps_present</emphasis>
+ and <emphasis>
+maps</emphasis>
+ fields are updated.
+</para>
+
+
+<para>
+If a compatible version of Xkb is not available in the server or the Xkb
+extension has not been properly initialized, <emphasis>
+XkbGetDeviceLedInfo</emphasis>
+ returns <emphasis>
+BadAccess</emphasis>
+. If allocation errors occur, a BadAlloc status is returned. If the device has
+no indicators, a BadMatch error is returned. If <emphasis>
+ledClass</emphasis>
+ or <emphasis>
+ledID</emphasis>
+ have illegal values, a Bad<emphasis>
+Value</emphasis>
+ error is returned. If they have legal values but do not specify a feedback
+that contains LEDs and is associated with the specified device, a Bad<emphasis>
+Match</emphasis>
+ error is returned.
+</para>
+
+
+</sect1>
+<sect1
+id='allocating_initializing_and_freeing_the_xkbdeviceinforec_structure'>
+<title>Allocating, Initializing, and Freeing the XkbDeviceInfoRec
+Structure</title>
+
+<para>
+To obtain an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure, use XkbGetDeviceInfo or XkbAllocDeviceInfo.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDeviceInfoPtr <emphasis>
+XkbAllocDeviceInfo</emphasis>
+(device_spec, n_buttons, sz_leds)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int device_spec; /* device ID with which
+structure will be used */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+n_buttons</emphasis>
+; /* number of button actions to allocate space for*/
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+sz_leds</emphasis>
+; /* number of LED feedbacks to allocate space for */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocDeviceInfo</emphasis>
+ allocates space for an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure and initializes that structure’s <emphasis>
+device_spec</emphasis>
+ field with the device ID specified by device_spec. If <emphasis>
+n_buttons</emphasis>
+ is nonzero, <emphasis>
+n_buttons</emphasis>
+ <emphasis>
+XkbActions</emphasis>
+ are linked into the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure and initialized to zero. If sz_leds is nonzero, <emphasis>
+sz_leds</emphasis>
+ <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structures are also allocated and linked into the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure. If you request <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structures be allocated using this request, you must initialize them
+explicitly.
+</para>
+
+
+<para>
+To obtain an <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structure, use XkbAllocDeviceLedInfo.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbAllocDeviceLedInfo</emphasis>
+(devi, num_needed)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr <emphasis>
+device_info</emphasis>
+; /* structure in which to allocate LED space */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+int <emphasis>
+num_needed</emphasis>
+; /* number of indicators to allocate space for */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAllocDeviceLedInfo</emphasis>
+ allocates space for an <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ and places it in <emphasis>
+device_info</emphasis>
+. If num_needed is nonzero, <emphasis>
+num_needed</emphasis>
+ <emphasis>
+XkbIndicatorMapRec</emphasis>
+ structures are also allocated and linked into the <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structure. If you request <emphasis>
+XkbIndicatorMapRec</emphasis>
+ structures be allocated using this request, you must initialize them
+explicitly. All other fields are initialized to zero.
+</para>
+
+
+<para>
+To initialize an <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structure, use XkbAddDeviceLedInfo.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+XkbDeviceLedInfoPtr <emphasis>
+XkbAddDeviceLedInfo</emphasis>
+(device_info, led_class, led_id)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure in which to
+add LED info */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+led_class</emphasis>
+; /* input extension class for LED device of interest */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+led_id</emphasis>
+; /* input extension ID for LED device of interest */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbAddDeviceLedInfo</emphasis>
+ first checks to see whether an entry matching <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ already exists in the <emphasis>
+device_info-&gt;leds</emphasis>
+ array. If it finds a matching entry, it returns a pointer to that entry.
+Otherwise, it checks to be sure there is at least one empty entry in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ and extends it if there is not enough room. It then increments <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_leds</emphasis>
+ and fills in the next available entry in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ with <emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+.
+</para>
+
+
+<para>
+If successful, <emphasis>
+XkbAddDeviceLedInfo</emphasis>
+ returns a pointer to the <emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structure that was initialized. If unable to allocate sufficient storage, or
+if <emphasis>
+device_info</emphasis>
+ points to an invalid <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure, or if <emphasis>
+led_class</emphasis>
+ or <emphasis>
+led_id</emphasis>
+ are inappropriate, <emphasis>
+XkbAddDeviceLedInfo</emphasis>
+ returns <emphasis>
+NULL</emphasis>
+.
+</para>
+
+
+<para>
+To allocate additional space for button actions in an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure, use XkbResizeDeviceButtonActions.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbResizeDeviceButtonActions</emphasis>
+(device_info, new_total)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure in which to
+allocate button actions */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+new_total</emphasis>
+; /* new total number of button actions needed */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbResizeDeviceButton</emphasis>
+ reallocates space, if necessary, to make sure there is room for a total of
+<emphasis>
+new_total</emphasis>
+ button actions in the <emphasis>
+device_info</emphasis>
+ structure. Any new entries allocated are zeroed. If successful, <emphasis>
+XkbResizeDeviceButton</emphasis>
+ returns Success. If new_total is zero, all button actions are deleted,
+<emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_btns</emphasis>
+ is set to zero, and <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+btn_acts</emphasis>
+ is set to <emphasis>
+NULL</emphasis>
+. If device_info is invalid or new_total is greater than 255, BadValue is
+returned. If a memory allocation failure occurs, a <emphasis>
+BadAlloc</emphasis>
+ is returned.
+</para>
+
+
+<para>
+To free an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure, use XkbFreeDeviceInfo.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbFreeDeviceInfo</emphasis>
+(device_info, which, free_all)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* pointer to <emphasis>
+XkbDeviceInfoRec</emphasis>
+ in which to free items */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask of components of <emphasis>
+device_info</emphasis>
+ to free */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Bool <emphasis>
+free_all</emphasis>
+; /* <emphasis>
+True</emphasis>
+ =&gt; free everything, including device_info */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+If free_all is <emphasis>
+True</emphasis>
+, the <emphasis>
+XkbFreeDeviceInfo</emphasis>
+ frees all components of <emphasis>
+device_info</emphasis>
+ and the <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure pointed to by <emphasis>
+device_info</emphasis>
+ itself. If free_all is <emphasis>
+False</emphasis>
+, the value of which determines which subcomponents are freed. <emphasis>
+which </emphasis>
+is an inclusive OR of one or more of the values from Table 21.1. If which
+contains XkbXI_ButtonActionsMask, all button actions associated with <emphasis>
+device_info</emphasis>
+ are freed, <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+btn_acts</emphasis>
+ is set to <emphasis>
+NULL</emphasis>
+, and <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_btns</emphasis>
+ is set to zero. If which contains all bits in XkbXI_IndicatorsMask, all
+<emphasis>
+XkbDeviceLedInfoRec</emphasis>
+ structures associated with <emphasis>
+device_info</emphasis>
+ are freed, <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ is set to <emphasis>
+NULL</emphasis>
+, and <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+sz_leds</emphasis>
+ and <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_leds</emphasis>
+ are set to zero. If which contains XkbXI_IndicatorMapsMask, all indicator maps
+associated with <emphasis>
+device_info</emphasis>
+ are cleared, but the number of LEDs and the leds structures themselves are
+preserved. If which contains XkbXI_IndicatorNamesMask, all indicator names
+associated with device_info are cleared, but the number of LEDs and the leds
+structures themselves are preserved. If which contains
+XkbXI_IndicatorStateMask, the indicator state associated with the <emphasis>
+device_info</emphasis>
+ leds are set to zeros but the number of LEDs and the leds structures
+themselves are preserved.
+</para>
+
+
+</sect1>
+<sect1 id='setting_xkb_features_for_non_keyclass_input_extension_devices_'>
+<title>Setting Xkb Features for Non-KeyClass Input Extension Devices </title>
+
+<para>
+The Xkb extension allows clients to assign any key action to either core
+pointer or input extension device buttons. This makes it possible to control
+the keyboard or generate keyboard key events from extension devices or from the
+core pointer.
+</para>
+
+
+<para>
+Key actions assigned to core X pointer buttons or input extension device
+buttons cause key events to be generated as if they had originated from the
+core X keyboard.
+</para>
+
+
+<para>
+Xkb implementations are required to support key actions for the buttons of the
+core pointer device, but support for actions on extension devices is optional.
+Implementations that do not support button actions for extension devices must
+not set the <emphasis>
+XkbXI_ButtonActionsMask</emphasis>
+ bit in the <emphasis>
+supported</emphasis>
+ field of an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure.
+</para>
+
+
+<para>
+If a client attempts to modify valid characteristics of a device using an
+implementation that does not support modification of those characteristics, no
+protocol error is generated. Instead, the server reports a failure for the
+request; it also sends an <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ event to the client that issued the request if the client has selected to
+receive these events.
+</para>
+
+
+<para>
+To change characteristics of an X Input Extension device in the server, first
+modify a local copy of the device structure and then use either <emphasis>
+XkbSetDeviceInfo,</emphasis>
+ or, to save network traffic, use an <emphasis>
+XkbDeviceChangesRec</emphasis>
+ structure (see section 21.6) and call <emphasis>
+XkbChangeDeviceInfo</emphasis>
+ to download the changes to the server.
+</para>
+
+
+<para>
+To modify some or all of the characteristics of an X Input Extension device,
+use XkbSetDeviceInfo.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetDeviceInfo</emphasis>
+(<emphasis>
+dpy</emphasis>
+, which, device_info)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+which</emphasis>
+; /* mask indicating characteristics to modify */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure defining the
+device and modifications */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetDeviceInfo</emphasis>
+ sends a request to the server to modify the characteristics of the device
+specified in the <emphasis>
+device_info</emphasis>
+ structure. The particular characteristics modified are identified by the bits
+set in <emphasis>
+which</emphasis>
+ and take their values from the relevant fields in <emphasis>
+device_info</emphasis>
+ (see Table 21.1). <emphasis>
+XkbSetDeviceInfo</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if the request was successfully sent to the server. If the X server
+implementation does not allow interaction between the X input extension and the
+Xkb Extension, the function does nothing and returns <emphasis>
+False</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+which</emphasis>
+ parameter specifies which aspects of the device should be changed and is a
+bitmask composed of an inclusive OR or one or more of the following bits:
+<emphasis>
+XkbXI_ButtonActionsMask</emphasis>
+, <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+, <emphasis>
+XkbXI_IndicatorMapsMask</emphasis>
+. If the features requested to be manipulated in <emphasis>
+which</emphasis>
+ are valid for the device, but the server does not support assignment of one or
+more of them, that particular portion of the request is ignored.
+</para>
+
+
+<para>
+If the device specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+device_spec</emphasis>
+ does not contain buttons and a request affecting buttons is made, or the
+device does not contain indicators and a request affecting indicators is made,
+a <emphasis>
+BadMatch</emphasis>
+ protocol error results.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbXI_ButtonActionsMask</emphasis>
+ bit is set in the supported mask returned by XkbGetDeviceInfo, the Xkb
+extension allows applications to assign key actions to buttons on input
+extension devices other than the core keyboard device. If the <emphasis>
+XkbXI_ButtonActionsMask</emphasis>
+ is set in <emphasis>
+which</emphasis>
+, the actions for all buttons specified in device_info are set to the <emphasis>
+XkbAction</emphasis>
+s specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+btn_acts</emphasis>
+. If the number of buttons requested to be updated is not valid for the device,
+<emphasis>
+XkbSetDeviceInfo</emphasis>
+ returns <emphasis>
+False</emphasis>
+ and a <emphasis>
+BadValue</emphasis>
+ protocol error results.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbXI_IndicatorMaps</emphasis>
+ and / or <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+ bit is set in the supported mask returned by XkbGetDeviceInfo, the Xkb
+extension allows applications to assign maps and / or names to the indicators
+of nonkeyboard extension devices. If supported, maps and / or names can be
+assigned to all extension device indicators, whether they are part of a
+keyboard feedback or part of an indicator feedback.
+</para>
+
+
+<para>
+If the <emphasis>
+XkbXI_IndicatorMapsMask</emphasis>
+ and / or <emphasis>
+XkbXI_IndicatorNamesMask</emphasis>
+ flag is set in <emphasis>
+which</emphasis>
+, the indicator maps and / or names for all <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_leds</emphasis>
+ indicator devices specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+ are set to the maps and / or names specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+. <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+-&gt;<emphasis>
+led_class</emphasis>
+ and <emphasis>
+led_id</emphasis>
+ specify the input extension class and device ID for each indicator device to
+modify; if they have invalid values, a <emphasis>
+BadValue</emphasis>
+ protocol error results and <emphasis>
+XkbSetDeviceInfo</emphasis>
+ returns <emphasis>
+False</emphasis>
+. If they have legal values but do not specify a keyboard or indicator class
+feedback for the device in question, a <emphasis>
+BadMatch</emphasis>
+ error results. If any of the values in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+leds</emphasis>
+<emphasis>
+-&gt;</emphasis>
+<emphasis>
+names</emphasis>
+ are not a valid Atom or <emphasis>
+None</emphasis>
+, a <emphasis>
+BadAtom</emphasis>
+ protocol error results.
+</para>
+
+
+<para>
+Xkb provides convenience functions to modify subsets of the information
+accessible via <emphasis>
+XkbSetDeviceInfo</emphasis>
+. Only the parts of the structure indicated in the function description are
+modified. These convenience functions are described as follows.
+</para>
+
+
+<para>
+To change only the button actions for an input extension device, use
+XkbSetDeviceButtonActions.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetDeviceButtonActions</emphasis>
+(<emphasis>
+dpy</emphasis>
+, device, first_button, num_buttons, actions)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure defining the
+device and modifications */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int first_button; /* number of first button to
+update, 0 relative */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int num_buttons; /* number of buttons to update
+*/
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetDeviceButtonActions</emphasis>
+ assigns actions to the buttons of the device specified in
+device_info-&gt;<emphasis>
+device_spec</emphasis>
+. Actions are assigned to <emphasis>
+num_buttons</emphasis>
+ buttons beginning with <emphasis>
+first_button</emphasis>
+ and are taken from the actions specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+btn_acts</emphasis>
+.
+</para>
+
+
+<para>
+If the server does not support assignment of Xkb actions to extension device
+buttons, <emphasis>
+XkbSetDeviceButtonActions</emphasis>
+ has no effect and returns <emphasis>
+False</emphasis>
+. If the device has no buttons or if <emphasis>
+first_button</emphasis>
+ or <emphasis>
+num_buttons</emphasis>
+ specify buttons outside of the valid range as determined by <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+num_btns</emphasis>
+, the function has no effect and returns <emphasis>
+False</emphasis>
+. Otherwise, <emphasis>
+XkbSetDeviceButtonActions</emphasis>
+ sends a request to the server to change the actions for the specified buttons
+and returns <emphasis>
+True</emphasis>
+.
+</para>
+
+
+<para>
+If the actual request sent to the server involved illegal button numbers, a
+<emphasis>
+BadValue</emphasis>
+ protocol error is generated. If an invalid device identifier is specified in
+device_info-&gt;<emphasis>
+device_spec</emphasis>
+, a BadKeyboard protocol error results. If the actual device specified in
+<emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+device_spec</emphasis>
+ does not contain buttons and a request affecting buttons is made, a <emphasis>
+BadMatch</emphasis>
+ protocol error is generated.
+</para>
+
+
+</sect1>
+<sect1 id='xkbextensiondevicenotify_event'>
+<title>XkbExtensionDeviceNotify Event</title>
+
+<para>
+The Xkb extension generates <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ events when the status of an input extension device changes or when an attempt
+is made to use an Xkb feature that is not supported by a particular device.
+</para>
+
+<note><para>Events indicating an attempt to use an unsupported feature are
+delivered only to the client requesting the event.</para></note>
+
+<para>
+To track changes to the status of input extension devices or attempts to use
+unsupported features of a device, select to receive <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ events by calling either <emphasis>
+XkbSelectEvents</emphasis>
+ or <emphasis>
+XkbSelectEventDetails</emphasis>
+ (see section 4.3).
+</para>
+
+
+<para>
+To receive <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ events under all possible conditions, call <emphasis>
+XkbSelectEvents</emphasis>
+ and pass <emphasis>
+XkbExtensionDeviceNotifyMask</emphasis>
+ in both <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits</emphasis>
+.
+</para>
+
+
+<para>
+The <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ event has no event details. However, you can call <emphasis>
+XkbSelectEventDetails</emphasis>
+ using <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ as the <emphasis>
+event_type</emphasis>
+ and specifying <emphasis>
+XkbAllExtensionDeviceMask</emphasis>
+ in <emphasis>
+bits_to_change</emphasis>
+ and <emphasis>
+values_for_bits.</emphasis>
+ This has the same effect as a call to <emphasis>
+XkbSelectEvents</emphasis>
+.
+</para>
+
+
+<para>
+The structure for <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ events is:
+</para>
+
+<para><programlisting>
+typedef struct {
+ int type; /* Xkb extension base event code */
+ unsigned long serial; /* X server serial number for event */
+ Bool send_event; /* <emphasis>True</emphasis>
+ =&gt; synthetically generated*/
+ Display * display; /* server connection where event generated */
+ Time time; /* server time when event generated */
+ int xkb_type; /* <emphasis>XkbExtensionDeviceNotifyEvent</emphasis> */
+ int device; /* Xkb device ID, will not be
+ <emphasis>XkbUseCoreKbd</emphasis> */
+ unsigned int reason; /* reason for the event */
+ unsigned int supported; /* mask of supported features */
+ unsigned int unsupported; /* unsupported features this client
+ attempted to use */
+ int first_btn; /* first button that changed */
+ int num_btns; /* number of buttons that changed */
+ unsigned int leds_defined; /* indicators with names or maps */
+ unsigned int led_state; /* current state of the indicators */
+ int led_class; /* feedback class for LED changes */
+ int led_id; /* feedback ID for LED changes */
+} <emphasis>XkbExtensionDeviceNotifyEvent</emphasis>;
+</programlisting></para>
+
+<para>
+The <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ event has fields enabling it to report changes in the state (on/off) of all of
+the buttons for a device, but only for one LED feedback associated with a
+device. You will get multiple events when more than one LED feedback changes
+state or configuration.
+</para>
+
+
+</sect1>
+<sect1 id='tracking_changes_to_extension_devices'>
+<title>Tracking Changes to Extension Devices</title>
+
+<para>
+Changes to an Xkb extension device may be tracked by listening to <emphasis>
+XkbDeviceExtensionNotify</emphasis>
+ events and accumulating the changes in an <emphasis>
+XkbDeviceChangesRec</emphasis>
+ structure. The changes noted in the structure may then be used in subsequent
+operations to update either a server configuration or a local copy of an Xkb
+extension device configuration. The changes structure is defined as follows:
+</para>
+
+<para><programlisting>
+typedef struct _XkbDeviceChanges {
+ unsigned int changed; /* bits indicating what has changed */
+ unsigned short first_btn; /* number of first button which changed,
+ if any */
+ unsigned short num_btns; /* number of buttons that have changed */
+ XkbDeviceLedChangesRec leds;
+} <emphasis>XkbDeviceChangesRec</emphasis>,*XkbDeviceChangesPtr;
+</programlisting></para>
+
+<para><programlisting>
+typedef struct _XkbDeviceLedChanges {
+ unsigned short led_class; /* class of this indicator feedback bundle */
+ unsigned short led_id; /* ID of this indicator feedback bundle */
+ unsigned int names; /* bits indicating which names have changed */
+ unsigned int maps; /* bits indicating which maps have changed */
+ struct _XkbDeviceLedChanges *next; /* link to indicator change record
+ for next set */
+} <emphasis>XkbDeviceLedChangesRec</emphasis>,*XkbDeviceLedChangesPtr;
+</programlisting></para>
+
+<para>
+A local description of the configuration and state of a device may be kept in
+an <emphasis>
+XkbDeviceInfoRec</emphasis>
+ structure. The actual state or configuration of the device may change because
+of XkbSetDeviceInfo and XkbSetButtonActions requests made by clients or by user
+interaction with the device. The X server sends an XkbExtensionDeviceNotify
+event to all interested clients when the state of any buttons or indicators or
+the configuration of the buttons or indicators on the core keyboard or any
+input extension device changes. The event reports the state of indicators for a
+single indicator feedback, and the state of up to 128 buttons. If more than 128
+buttons or more than one indicator feedback are changed, the additional buttons
+and indicator feedbacks are reported in subsequent events. Xkb provides
+functions with which you can track changes to input extension devices by noting
+the changes that were made and then requesting the changed information from the
+server.
+</para>
+
+
+<para>
+To note device changes reported in an <emphasis>
+XkbExtensionDeviceNotify</emphasis>
+ event, use XkbNoteDeviceChanges.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+void <emphasis>
+XkbNoteDeviceChanges</emphasis>
+ (<emphasis>
+old, new, wanted</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceChangesPtr <emphasis>
+old</emphasis>
+; /* structure tracking state changes */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbExtensionDeviceNotifyEvent * <emphasis>
+new</emphasis>
+; /* event indicating state changes */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+wanted</emphasis>
+; /* mask indicating changes to note */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The wanted field specifies the changes that should be noted in <emphasis>
+old</emphasis>
+, and is composed of the bitwise inclusive OR of one or more of the masks from
+Table 21.1<emphasis>
+.</emphasis>
+ The <emphasis>
+reason</emphasis>
+ field of the event in <emphasis>
+new</emphasis>
+ indicates the types of changes the event is reporting. <emphasis>
+XkbNoteDeviceChanges</emphasis>
+ updates the <emphasis>
+XkbDeviceChangesRec</emphasis>
+ specified by <emphasis>
+old</emphasis>
+ with the changes that are both specified in <emphasis>
+wanted</emphasis>
+ and contained in <emphasis>
+new</emphasis>
+-&gt;<emphasis>
+reason</emphasis>
+.
+</para>
+
+
+<para>
+To update a local copy of the state and configuration of an X input extension
+device with the changes previously noted in an <emphasis>
+XkbDeviceChangesRec</emphasis>
+ structure, use XkbGetDeviceInfoChanges.
+</para>
+
+
+<para>
+To query the changes that have occurred in the button actions or indicator
+names and indicator maps associated with an input extension device, use
+XkbGetDeviceInfoChanges.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Status <emphasis>
+XkbGetDeviceInfoChanges</emphasis>
+(<emphasis>
+dpy</emphasis>
+, <emphasis>
+device_info</emphasis>
+, changes)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr device_info; /* structure to update with
+results */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceChangesPtr <emphasis>
+changes</emphasis>
+; /* contains notes of changes that have occurred */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+The changes-&gt;changed field indicates which attributes of the device
+specified in <emphasis>
+changes</emphasis>
+-&gt;<emphasis>
+device</emphasis>
+ have changed. The parameters describing the changes are contained in the other
+fields of <emphasis>
+changes</emphasis>
+. <emphasis>
+XkbGetDeviceInfoChanges</emphasis>
+ uses that information to call XkbGetDeviceInfo to obtain the current status of
+those attributes that have changed. It then updates the local description of
+the device in <emphasis>
+device_info</emphasis>
+ with the new information.
+</para>
+
+
+<para>
+To update the server’s description of a device with the changes noted in an
+XkbDeviceChangesRec, use XkbChangeDeviceInfo.
+</para>
+
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbChangeDeviceInfo</emphasis>
+ (<emphasis>
+dpy, device_info, changes</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+dpy</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceInfoPtr <emphasis>
+device_info</emphasis>
+; /* local copy of device state and configuration */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+XkbDeviceChangesPtr <emphasis>
+changes</emphasis>
+; /* note specifying changes in <emphasis>
+device_info</emphasis>
+ */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbChangeDeviceInfo</emphasis>
+ updates the server’s description of the device specified in <emphasis>
+device_info</emphasis>
+-&gt;<emphasis>
+device_spec</emphasis>
+ with the changes specified in <emphasis>
+changes</emphasis>
+ and contained in <emphasis>
+device_info</emphasis>
+. The update is made by an XkbSetDeviceInfo request.
+</para>
+
+</sect1>
+</chapter>
diff --git a/libX11/specs/XKB/ch22.xml b/libX11/specs/XKB/ch22.xml
new file mode 100644
index 000000000..ba16bffbc
--- /dev/null
+++ b/libX11/specs/XKB/ch22.xml
@@ -0,0 +1,216 @@
+<chapter id='debugging_aids'>
+<title>Debugging Aids</title>
+
+<para>
+The debugging aids are intended for use primarily by Xkb implementors and are
+optional in any implementation.
+</para>
+
+
+<para>
+There are two bitmasks that may be used to control debugging. One bitmask
+controls the output of debugging information, and the other controls behavior.
+Both bitmasks are initially all zeros.
+</para>
+
+
+<para>
+To change the values of any of the debug controls, use <emphasis>
+XkbSetDebuggingFlags</emphasis>
+.
+</para>
+
+<informaltable frame='none'>
+<tgroup cols='1'>
+<colspec colsep='0'/>
+<tbody>
+ <row rowsep='0'>
+ <entry role='functiondecl'>
+Bool <emphasis>
+XkbSetDebuggingFlags</emphasis>
+(<emphasis>
+display, mask, flags, msg, ctrls_mask, ctrls, ret_flags, ret_ctrls</emphasis>
+)
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+Display * <emphasis>
+ display</emphasis>
+; /* connection to X server */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ mask</emphasis>
+; /* mask selecting debug output flags to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ flags</emphasis>
+; /* values for debug output flags selected by <emphasis>
+mask</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+char * <emphasis>
+ msg</emphasis>
+; /* message to print right now */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ctrls_mask</emphasis>
+; /* mask selecting debug controls to change */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int <emphasis>
+ctrls</emphasis>
+; /* values for debug controls selected by <emphasis>
+ctrls_mask</emphasis>
+ */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+ ret_flags</emphasis>
+; /* resulting state of all debug output flags */
+ </entry>
+ </row>
+ <row rowsep='0'>
+ <entry role='functionargdecl'>
+unsigned int * <emphasis>
+ret_ctrls</emphasis>
+; /* resulting state of all debug controls */
+ </entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
+
+<para>
+<emphasis>
+XkbSetDebuggingFlags</emphasis>
+ modifies the debug output flags as specified by <emphasis>
+mask</emphasis>
+ and <emphasis>
+flags</emphasis>
+, modifies the debug controls flags as specified by <emphasis>
+ctrls_mask</emphasis>
+ and <emphasis>
+ctrls</emphasis>
+, prints the message <emphasis>
+msg</emphasis>
+, and backfills <emphasis>
+ret_flags</emphasis>
+ and <emphasis>
+ret_ctrls</emphasis>
+ with the resulting debug output and debug controls flags.
+</para>
+
+
+<para>
+When bits are set in the debug output masks, <emphasis>
+mask</emphasis>
+ and <emphasis>
+flags</emphasis>
+, Xkb prints debug information corresponding to each bit at appropriate points
+during its processing. The device to which the output is written is
+implementation-dependent, but is normally the same device to which X server
+error messages are directed; thus the bits that can be set in <emphasis>
+mask</emphasis>
+ and <emphasis>
+flags</emphasis>
+ is implementation-specific. To turn on a debug output selection, set the bit
+for the output in the <emphasis>
+mask</emphasis>
+ parameter and set the corresponding bit in the <emphasis>
+flags</emphasis>
+ parameter. To turn off event selection for an event, set the bit for the
+output in the <emphasis>
+mask</emphasis>
+ parameter and do not set the corresponding bit in the <emphasis>
+flags</emphasis>
+ parameter.
+</para>
+
+
+<para>
+When bits are set in the debug controls masks, <emphasis>
+ctrls_mask</emphasis>
+ and <emphasis>
+ctrls</emphasis>
+, Xkb modifies its behavior according to each controls bit. <emphasis>
+ctrls_mask</emphasis>
+ and <emphasis>
+ctrls</emphasis>
+ are related in the same way that <emphasis>
+mask</emphasis>
+ and <emphasis>
+flags</emphasis>
+ are. The valid controls bits are defined in Table 22.1.
+</para>
+
+<table frame='none'>
+<title>Debug Control Masks</title>
+<tgroup cols='3'>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<colspec colsep='0'/>
+<thead>
+<row rowsep='0'>
+ <entry>Debug Control Mask</entry>
+ <entry>Value</entry>
+ <entry>Meaning</entry>
+</row>
+</thead>
+<tbody>
+<row rowsep='0'>
+ <entry>XkbDF_DisableLocks</entry>
+ <entry>(1 &lt;&lt; 0)</entry>
+ <entry>Disable actions that lock modifiers</entry>
+ </row>
+</tbody>
+</tgroup>
+</table>
+
+<para>
+<emphasis>
+XkbSetDebuggingFlags</emphasis>
+ returns <emphasis>
+True</emphasis>
+ if successful and <emphasis>
+False</emphasis>
+ otherwise. The only protocol error it may generate is <emphasis>
+BadAlloc</emphasis>
+, if for some reason it is unable to allocate storage.
+</para>
+
+
+<para>
+<emphasis>
+XkbSetDebuggingFlags</emphasis>
+ is intended for developer use and may be disabled in production X servers. If
+it is disabled, <emphasis>
+XkbSetDebuggingFlags</emphasis>
+ has no effect and does not generate any protocol errors.
+</para>
+
+
+<para>
+The message in <emphasis>
+msg</emphasis>
+ is written immediately. The device to which it is written is implementation
+dependent but is normally the same device where X server error messages are
+directed.
+</para>
+</chapter>
diff --git a/libX11/specs/XKB/glossary.xml b/libX11/specs/XKB/glossary.xml
new file mode 100644
index 000000000..0cccf0f8f
--- /dev/null
+++ b/libX11/specs/XKB/glossary.xml
@@ -0,0 +1,1016 @@
+<glossary id='glossary'>
+<title>Glossary</title>
+<glossentry>
+ <glossterm>Allocator</glossterm>
+ <glossdef>
+ <para>
+Xkb provides functions, known as allocators, to create and initialize Xkb data
+structures.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Audible Bell</glossterm>
+ <glossdef>
+ <para>
+An audible bell is the sound generated by whatever bell is associated with the
+keyboard or input extension device, as opposed to any other audible sound
+generated elsewhere in the system.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Autoreset Controls</glossterm>
+ <glossdef>
+ <para>
+The autoreset controls configure the boolean controls to automatically be
+enabled or disabled at the time a program exits.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Base Group</glossterm>
+ <glossdef>
+ <para>
+The group in effect as a result of all actions other than a previous lock or
+latch request; the base group is transient. For example, the user pressing and
+holding a group shift key that shifts to Group2 would result in the base group
+being group 2 at that point in time. Initially, base group is always Group1.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Base Modifiers</glossterm>
+ <glossdef>
+ <para>
+Modifiers that are turned on as a result of some actions other than previous
+lock or latch requests; base modifiers are transient. For example, the user
+pressing and holding a key bound to the Shift modifier would result in Shift
+being a base modifier at that point in time.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Base Event Code</glossterm>
+ <glossdef>
+ <para>
+A number assigned by the X server at run time that is assigned to the extension
+to identify events from that extension.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Base State</glossterm>
+ <glossdef>
+ <para>
+The base group and base modifiers represent keys that are physically or
+logically down; these constitute the base state.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Boolean Controls</glossterm>
+ <glossdef>
+ <para>
+Global keyboard controls that may be selectively enabled and disabled under
+program control and that may be automatically set to an on or off condition
+upon client program exit.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Canonical Key Types</glossterm>
+ <glossdef>
+ <para>
+The canonical key types are predefined key types that describe the types of
+keys available on most keyboards. The definitions for the canonical key types
+are held in the first <emphasis>
+XkbNumRequiredTypes</emphasis>
+ entries of the <emphasis>
+types</emphasis>
+ field of the client map and are indexed using the following constants:
+ </para>
+ <itemizedlist>
+ <listitem>
+ <para>
+<emphasis>XkbOneLevelIndex</emphasis>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>XkbTwoLevelIndex</emphasis>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>XkbAlphabeticIndex</emphasis>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+<emphasis>XkbKeypadIndex</emphasis>
+ </para>
+ </listitem>
+ </itemizedlist>
+ </glossdef>
+</glossentry>
+
+<glossentry>
+ <glossterm>Client Map</glossterm>
+ <glossdef>
+ <para>
+The key mapping information needed to convert arbitrary keycodes to symbols.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Compat Name</glossterm>
+ <glossdef>
+ <para>
+The <emphasis>
+compat</emphasis>
+ name is a string that provides some information about the rules used to bind
+actions to keys that are changed using core protocol requests.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Compatibility State</glossterm>
+ <glossdef>
+ <para>
+When an Xkb-extended X server connects to an Xkb-unaware client, the
+compatibility state remaps the keyboard group into a core modifier whenever
+possible.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Compatibility Grab State</glossterm>
+ <glossdef>
+ <para>
+The grab state that results from applying the compatibility map to the Xkb grab
+state.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Compatibility Map</glossterm>
+ <glossdef>
+ <para>
+The definition of how to map core protocol keyboard state to Xkb keyboard state.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Component Expression</glossterm>
+ <glossdef>
+ <para>
+An expression used to describe server keyboard database components to be
+loaded. It describes the order in which the components should be loaded and the
+rules by which duplicate attributes should be resolved.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Compose Processing</glossterm>
+ <glossdef>
+ <para>
+The process of mapping a series of keysyms to a string is known as compose
+processing.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Consumed Modifier</glossterm>
+ <glossdef>
+ <para>
+Xkb normally consumes modifiers in determining the appropriate symbol for an
+event, that is, the modifiers are not considered during any of the later stages
+of event processing. For those rare occasions when a modifier <emphasis>
+should</emphasis>
+ be considered despite having been used to look up a symbol, key types include
+an optional <emphasis>
+preserve</emphasis>
+ field.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Core Event</glossterm>
+ <glossdef>
+ <para>
+An event created from the core X server.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Detectable Auto-Repeat</glossterm>
+ <glossdef>
+ <para>
+Detectable auto-repeat allows a client to detect an auto-repeating key. If a
+client requests and the server supports detectable auto-repeat, Xkb generates
+<emphasis>
+KeyRelease</emphasis>
+ events only when the key is physically released. Thus the client receives a
+number of <emphasis>
+KeyPress</emphasis>
+ events for that key without intervening <emphasis>
+KeyRelease</emphasis>
+ events until the key is finally released, when a <emphasis>
+KeyRelease</emphasis>
+ event is received.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Effective Group</glossterm>
+ <glossdef>
+ <para>
+The effective group is the arithmetic sum of the locked, latched, and base
+groups. The effective keyboard group is always brought back into range
+depending on the value of the <emphasis>
+GroupsWrap</emphasis>
+ control for the keyboard. If an event occurs with an effective group that is
+legal for the keyboard as a whole, but not for the key in question, the group
+<emphasis>
+for that event only</emphasis>
+ is normalized using the algorithm specified by the <emphasis>
+group_info</emphasis>
+ member of the key symbol map (<emphasis>
+XkbSymMapRec</emphasis>
+).
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Effective Mask</glossterm>
+ <glossdef>
+ <para>
+An Xkb modifier definition consists of a set of bit masks corresponding to the
+eight real modifiers; a similar set of bitmasks corresponding to the 16 named
+virtual modifiers; and an effective mask. The effective mask represents the set
+of all real modifiers that can logically be set either by setting any of the
+real modifiers or by setting any of the virtual modifiers in the definition.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Effective Modifier</glossterm>
+ <glossdef>
+ <para>
+The effective modifiers are the bitwise union of the base, latched and locked
+modifiers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Extension Device</glossterm>
+ <glossdef>
+ <para>
+Any keyboard or other input device recognized by the X input extension.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Global Keyboard Controls</glossterm>
+ <glossdef>
+ <para>
+Controls that affect the way Xkb generates key events. The controls affect all
+keys, as opposed to per-key controls that are for a single key. Global controls
+include
+ </para>
+ <itemizedlist>
+ <listitem>
+ <para>RepeatKeys Control</para>
+ </listitem>
+ <listitem>
+ <para>DetectableAuto-repeat</para>
+ </listitem>
+ <listitem>
+ <para>SlowKeys</para>
+ </listitem>
+ <listitem>
+ <para>BounceKeys</para>
+ </listitem>
+ <listitem>
+ <para>StickyKeys</para>
+ </listitem>
+ <listitem>
+ <para>MouseKeys</para>
+ </listitem>
+ <listitem>
+ <para>MouseKeysAccel</para>
+ </listitem>
+ <listitem>
+ <para>AccessXKeys</para>
+ </listitem>
+ <listitem>
+ <para>AccessXTimeout</para>
+ </listitem>
+ <listitem>
+ <para>AccessXFeedback</para>
+ </listitem>
+ <listitem>
+ <para>Overlay1</para>
+ </listitem>
+ <listitem>
+ <para>Overlay2</para>
+ </listitem>
+ <listitem>
+ <para>EnabledControls</para>
+ </listitem>
+ </itemizedlist>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Grab State</glossterm>
+ <glossdef>
+ <para>
+The grab state is the state used when matching events to passive grabs. It
+consists of the grab group and the grab modifiers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Group</glossterm>
+ <glossdef>
+ <para>See Keysym Group</para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Group Index</glossterm>
+ <glossdef>
+ <para>
+A number used as the internal representation for a group number. Group1 through
+Group 4 have indices of 0 through 3.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Groups Wrap Control</glossterm>
+ <glossdef>
+ <para>
+If a group index exceeds the maximum number of groups permitted for the
+specified keyboard, it is wrapped or truncated back into range as specified by
+the global <emphasis>GroupsWrap</emphasis> control. <emphasis>
+GroupsWrap</emphasis> can have the following values:
+ </para>
+ <literallayout>
+ <emphasis>WrapIntoRange</emphasis>
+ <emphasis>ClampIntoRange</emphasis>
+ <emphasis>RedirectIntoRange</emphasis>
+ </literallayout>
+ </glossdef>
+</glossentry>
+
+<glossentry>
+ <glossterm>Key Type</glossterm>
+ <glossdef>
+ <para>
+An attribute of a key that identifies which modifiers affect the shift level of
+a key and the number of groups on the key.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Key Width</glossterm>
+ <glossdef>
+ <para>
+The maximum number of shift levels in any group for the key type associated
+with a key.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keysym Group</glossterm>
+ <glossdef>
+ <para>
+A keysym group is a logical state of the keyboard providing access to a
+collection of characters. A group usually contains a set of characters that
+logically belong together and that may be arranged on several shift levels
+within that group. For example, Group1 could be the English alphabet, and
+Group2 could be Greek. Xkb supports up to four different groups for an input
+device or keyboard. Groups are in the range 1-4 (Group1 - Group4), and are
+often referred to as G1 - G4 and indexed as 0 - 3.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Indicator</glossterm>
+ <glossdef>
+ <para>
+An indicator is a feedback mechanism such as an LED on an input device. Using
+Xkb, a client application can determine the names of the various indicators,
+determine and control the way that the individual indicators should be updated
+to reflect keyboard changes, and determine which of the 32 keyboard indicators
+reported by the protocol are actually present on the keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Indicator Feedback</glossterm>
+ <glossdef>
+ <para>
+An indicator feedback describes the state of a bank of up to 32 lights. It has
+a mask where each bit corresponds to a light and an associated value mask that
+specifies which lights are on or off.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Indicator Map</glossterm>
+ <glossdef>
+ <para>
+An indicator has its own set of attributes that specify whether clients can
+explicitly set its state and whether it tracks the keyboard state. The
+indicator map is the collection of these attributes for each indicator and is
+held in the <emphasis>
+maps</emphasis>
+ array, which is an array of <emphasis>
+XkbIndicatorRec</emphasis>
+ structures.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Input Extension</glossterm>
+ <glossdef>
+ <para>
+An extension to the core X protocol that allows an X server to support multiple
+keyboards, as well as other input devices, in addition to the core X keyboard
+and pointer. Other types of devices supported by the input extension include,
+but are not limited to: mice, tablets, touchscreens, barcode readers, button
+boxes, trackballs, identifier devices, data gloves, and eye trackers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Key Action</glossterm>
+ <glossdef>
+ <para>
+A key action consists of an operator and some optional data. Once the server
+has applied the global controls and per-key behavior and has decided to process
+a key event, it applies key actions to determine the effects of the key on the
+internal state of the server. Xkb supports actions that do the following:
+ </para>
+ <itemizedlist>
+ <listitem>
+ <para>
+Change base, latched, or locked modifiers or group
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Move the core pointer or simulate core pointer button events
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Change most aspects of keyboard behavior
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Terminate or suspend the server
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Send a message to interested clients
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+Simulate events on other keys
+ </para>
+ </listitem>
+ </itemizedlist>
+ </glossdef>
+</glossentry>
+
+<glossentry>
+ <glossterm>Key Alias</glossterm>
+ <glossdef>
+ <para>
+A key alias is a symbolic name for a specific physical key. Key aliases allow
+the keyboard layout designer to assign multiple key names to a single key. This
+allows the keyboard layout designer to refer to keys using either their
+position or their "function." Key aliases can be specified both in the symbolic
+names component and in the keyboard geometry. Both sets of aliases are always
+valid, but key alias definitions in the keyboard geometry have priority; if
+both symbolic names and geometry include aliases, you should consider the
+definitions from the geometry before considering the definitions from the
+symbolic names section.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Key Behavior</glossterm>
+ <glossdef>
+ <para>
+The <emphasis>
+behaviors</emphasis>
+ field of the server map is an array of <emphasis>
+XkbBehavior</emphasis>
+, indexed by keycode, and contains the behavior for each key. The X server uses
+key behavior to determine whether to process or filter out any given key event;
+key behavior is independent of keyboard modifier or group state. Each key has
+exactly one behavior.
+ </para>
+ <para>Key behaviors include:</para>
+ <itemizedlist>
+ <listitem>
+ <para>XkbKB_Default</para>
+ </listitem>
+ <listitem>
+ <para>XkbKB_Lock</para>
+ </listitem>
+ <listitem>
+ <para>XkbKB_RadioGroup</para>
+ </listitem>
+ <listitem>
+ <para>XkbKB_Overlay1</para>
+ </listitem>
+ <listitem>
+ <para>XkbKB_Overlay2</para>
+ </listitem>
+ </itemizedlist>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Key Symbol Map</glossterm>
+ <glossdef>
+ <para>
+A key symbol map describes the symbols bound to a key and the rules to be used
+to interpret those symbols. It is an array of <emphasis>
+XkbSymMapRec</emphasis>
+ structures indexed by keycode.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Key Type</glossterm>
+ <glossdef>
+ <para>
+Key types are used to determine the shift level of a key given the current
+state of the keyboard. There is one key type for each group for a key. Key
+types are defined using the <emphasis>
+XkbKeyTypeRec</emphasis>
+ and <emphasis>
+XkbKTMapEntryRec</emphasis>
+ structures. Xkb allows up to <emphasis>
+XkbMaxKeyTypes</emphasis>
+ (255) key types to be defined, but requires at least <emphasis>
+XkbNumRequiredTypes</emphasis>
+ (4) predefined types to be in a key map.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard Bells</glossterm>
+ <glossdef>
+ <para>
+The sound the default bell makes when rung is the system bell or the default
+keyboard bell. Some input devices may have more than one bell, identified by
+<emphasis>bell_class</emphasis> and <emphasis>bell_id</emphasis>.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard Components</glossterm>
+ <glossdef>
+ <para>
+There are five types of components stored in the X server database of keyboard
+components. They correspond to the <emphasis>
+symbols, geometry, keycodes, compat, </emphasis>
+and<emphasis>
+ types</emphasis>
+ symbolic names associated with a keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard Feedback</glossterm>
+ <glossdef>
+ <para>
+A keyboard feedback includes the following:
+ </para>
+<literallayout>
+ Keyclick volume
+ Bell volume
+ Bell pitch
+ Bell duration
+ Global auto-repeat
+ Per key auto-repeat
+ 32 LEDs
+</literallayout>
+ </glossdef>
+</glossentry>
+
+<glossentry>
+ <glossterm>Key Width, Key Type Width</glossterm>
+ <glossdef>
+ <para>
+The maximum number of shift levels for a type is referred to as the width of a
+key type.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard Geometry</glossterm>
+ <glossdef>
+ <para>
+Keyboard geometry describes the physical appearance of the keyboard, including
+the shape, location, and color of all keyboard keys or other visible keyboard
+components such as indicators and is stored in a <emphasis>
+XkbGeometryRec</emphasis>
+ structure. The information contained in a keyboard geometry is sufficient to
+allow a client program to draw an accurate two-dimensional image of the
+keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard Geometry Name</glossterm>
+ <glossdef>
+ <para>
+The keyboard geometry name describes the physical location, size, and shape of
+the various keys on the keyboard and is part of the <emphasis>
+XkbNamesRec</emphasis>
+ structure.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keyboard State</glossterm>
+ <glossdef>
+ <para>
+Keyboard state encompasses all of the transitory information necessary to map a
+physical key press or release to an appropriate event.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keycode</glossterm>
+ <glossdef>
+ <para>
+A numeric value returned to the X server when a key on a keyboard is pressed or
+released, indicating which key is being modulated. Keycode numbers are in the
+range 1 &lt;= keycode &lt;= max, where max is the number of physical keys on
+the device.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Keycode Name</glossterm>
+ <glossdef>
+ <para>
+The keycode name describes the range and meaning of the keycodes returned by
+the keyboard and is part of the <emphasis>
+XkbNamesRec</emphasis>
+ structure.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Latched Group</glossterm>
+ <glossdef>
+ <para>
+A latched group is a group index that is combined with the base and locked
+group to form the effective group. It applies only to the next key event that
+does not change the keyboard state. The latched group can be changed by
+keyboard activity or via Xkb extension library functions.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Latched Modifier</glossterm>
+ <glossdef>
+ <para>
+Latched modifiers are the set of modifiers that are combined with the base
+modifiers and the locked modifiers to form the effective modifiers. It applies
+only to the next key event that does not change the keyboard state.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>LED</glossterm>
+ <glossdef>
+ <para>
+A light emitting diode. However, for the purposes of the X keyboard extension
+specification, a LED is any form of visual two-state indicator that is either
+on or off.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Locked Group</glossterm>
+ <glossdef>
+ <para>
+A locked group is a group index that is combined with the base and latched
+group to form the effective group. When a group is locked, it supersedes any
+previous locked group and remains the locked group for all future key events,
+until a new group is locked. The locked group can be changed by keyboard
+activity or via Xkb extension library functions.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Locked Modifiers</glossterm>
+ <glossdef>
+ <para>
+Locked modifiers are the set of modifiers that are combined with the base
+modifiers and the latched modifiers to form the effective modifiers. A locked
+modifier applies to all future key events until it is explicitly unlocked.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Lookup State </glossterm>
+ <glossdef>
+ <para>
+The lookup state is composed of the lookup group and the lookup modifiers, and
+it is the state an Xkb-capable or Xkb-aware client should use to map a keycode
+to a keysym.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Modifier</glossterm>
+ <glossdef>
+ <para>
+A modifier is a logical condition that is either set or unset. The modifiers
+control the Shift Level selected when a key event occurs. Xkb supports the core
+protocol eight modifiers (<emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, <emphasis>
+Control</emphasis>
+, and <emphasis>
+Mod1</emphasis>
+ through <emphasis>
+Mod5</emphasis>
+), called the <emphasis>
+real</emphasis>
+ modifiers. In addition, Xkb extends modifier flexibility by providing a set of
+sixteen named virtual modifiers, each of which can be bound to any set of the
+eight real modifiers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Modifier Key</glossterm>
+ <glossdef>
+ <para>
+A modifier key is a key whose operation has no immediate effect, but that, for
+as long as it is held down, modifies the effect of other keys. A modifier key
+may be, for example, a shift key or a control key.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Modifier Definition</glossterm>
+ <glossdef>
+ <para>
+An Xkb modifier definition, held in an <emphasis>
+XkbModsRec</emphasis>
+, consists of a set of real modifiers, a set of virtual modifiers, and an
+effective mask. The mask is the union of the real modifiers and the set of real
+modifiers to which the virtual modifiers map; the mask cannot be explicitly
+changed.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Nonkeyboard Extension Device </glossterm>
+ <glossdef>
+ <para>
+An input extension device that is not a keyboard. Other types of devices
+supported by the input extension include, but are not limited to: mice,
+tablets, touchscreens, barcode readers, button boxes, trackballs, identifier
+devices, data gloves, and eye trackers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Outlines</glossterm>
+ <glossdef>
+ <para>
+An outline is a list of one or more points that describes a single closed
+polygon, used in the geometry specification for a keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Physical Indicator Mask</glossterm>
+ <glossdef>
+ <para>
+The physical indicator mask is a field in the <emphasis>
+XkbIndicatorRec</emphasis>
+ that indicates which indicators are bound to physical LEDs on the keyboard; if
+a bit is set in <emphasis>
+phys_indicators</emphasis>
+, then the associated indicator has a physical LED associated with it. This
+field is necessary because some indicators may not have corresponding physical
+LEDs on the keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Physical Symbol Keyboard Name</glossterm>
+ <glossdef>
+ <para>
+The <emphasis>
+symbols</emphasis>
+ keyboard name identifies the symbols logically bound to the keys. The symbols
+name is a human or application-readable description of the intended locale or
+usage of the keyboard with these symbols. The <emphasis>
+phys_symbols</emphasis>
+ keyboard name, on the other hand, identifies the symbols actually engraved on
+the keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Preserved Modifier</glossterm>
+ <glossdef>
+ <para>
+Xkb normally consumes modifiers in determining the appropriate symbol for an
+event, that is, the modifiers are not considered during any of the later stages
+of event processing. For those rare occasions when a modifier <emphasis>
+should</emphasis>
+ be considered despite having been used to look up a symbol, key types include
+an optional <emphasis>
+preserve</emphasis>
+ field. If a modifier is present in the <emphasis>
+preserve</emphasis>
+ list, it is a preserved modifier.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Radio Group</glossterm>
+ <glossdef>
+ <para>
+A radio group is a set of keys whose behavior simulates a set of radio buttons.
+Once a key in a radio group is pressed, it stays logically depressed until
+another key in the group is pressed, at which point the previously depressed
+key is logically released. Consequently, at most one key in a radio group can
+be logically depressed at one time.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Real Modifier</glossterm>
+ <glossdef>
+ <para>
+Xkb supports the eight core protocol modifiers (<emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, <emphasis>
+Control</emphasis>
+, and <emphasis>
+Mod1</emphasis>
+ through <emphasis>
+Mod5</emphasis>
+); these are called the <emphasis>
+real</emphasis>
+ modifiers, as opposed to the set of sixteen named virtual modifiers that can
+be bound to any set of the eight real modifiers.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Server Internal Modifiers</glossterm>
+ <glossdef>
+ <para>
+Modifiers that the server uses to determine the appropriate symbol for an
+event; internal modifiers are normally consumed by the server.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Shift Level</glossterm>
+ <glossdef>
+ <para>
+One of several states (normally 2 or 3) governing which graphic character is
+produced when a key is actuated.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Symbol Keyboard Name</glossterm>
+ <glossdef>
+ <para>
+The <emphasis>
+symbols</emphasis>
+ keyboard name identifies the symbols logically bound to the keys. The symbols
+name is a human or application-readable description of the intended locale or
+usage of the keyboard with these symbols. The <emphasis>
+phys_symbols</emphasis>
+ keyboard name, on the other hand, identifies the symbols actually engraved on
+the keyboard.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Symbolic Name</glossterm>
+ <glossdef>
+ <para>
+Xkb supports symbolic names for most components of the keyboard extension. Most
+of these symbolic names are grouped into the <emphasis>
+names</emphasis>
+ component of the keyboard description.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>State Field</glossterm>
+ <glossdef>
+ <para>
+The portion of a client-side core protocol event that holds the modifier,
+group, and button state information pertaining to the event.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Types Name</glossterm>
+ <glossdef>
+ <para>
+The <emphasis>
+types</emphasis>
+ name provides some information about the set of key types that can be
+associated with the keyboard. In addition, each key type can have a name, and
+each shift level of a type can have a name.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Valuator</glossterm>
+ <glossdef>
+ <para>
+A valuator reports a range of values for some entity, like a mouse axis, a
+slider, or a dial.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Virtual Modifier</glossterm>
+ <glossdef>
+ <para>
+Xkb provides a set of sixteen named virtual modifiers that can be bound to any
+set of the eight real modifiers. Each virtual modifier can be bound to any set
+of the real modifiers (<emphasis>
+Shift</emphasis>
+, <emphasis>
+Lock</emphasis>
+, <emphasis>
+Control,</emphasis>
+ and <emphasis>
+Mod1</emphasis>
+-<emphasis>
+Mod5</emphasis>
+).
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Virtual Modifier Mapping</glossterm>
+ <glossdef>
+ <para>
+Xkb maintains a virtual modifier mapping, which lists the virtual modifiers
+associated with each key.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Xkb-aware Client</glossterm>
+ <glossdef>
+ <para>
+A client application that initializes Xkb extension and is consequently bound
+to an Xlib that includes the Xkb extension.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Xkb-capable Client</glossterm>
+ <glossdef>
+ <para>
+A client application that makes no Xkb extension Xlib calls but is bound to an
+Xlib that includes the Xkb extension.
+ </para>
+ </glossdef>
+</glossentry>
+<glossentry>
+ <glossterm>Xkb-unaware Client</glossterm>
+ <glossdef>
+ <para>
+A client application that makes no Xkb extension Xlib calls and is bound to an
+Xlib that does not include the Xkb extension.
+ </para>
+ </glossdef>
+</glossentry>
+
+</glossary>
diff --git a/libX11/specs/XKB/xkblib.xml b/libX11/specs/XKB/xkblib.xml
new file mode 100644
index 000000000..3ed55285b
--- /dev/null
+++ b/libX11/specs/XKB/xkblib.xml
@@ -0,0 +1,106 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE book
+ PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+<!ENTITY % defs SYSTEM "defs.ent"> %defs;
+]>
+
+<book id="xkblib">
+
+<bookinfo>
+ <title>The X Keyboard Extension:</title>
+ <subtitle>Library Specification</subtitle>
+ <authorgroup>
+ <author>
+ <firstname>Amber</firstname>
+ <othername>J.</othername>
+ <surname>Benson</surname>
+ </author>
+ <author>
+ <firstname>Gary</firstname>
+ <surname>Aitken</surname>
+ </author>
+ <author>
+ <firstname>Erik</firstname>
+ <surname>Fortune</surname>
+ <affiliation><orgname>Silicon Graphics, Inc</orgname></affiliation>
+ </author>
+ <author>
+ <firstname>Donna</firstname>
+ <surname>Converse</surname>
+ <affiliation><orgname>X Consortium, Inc</orgname></affiliation>
+ </author>
+ <author>
+ <firstname>George</firstname>
+ <surname>Sachs</surname>
+ <affiliation><orgname>Hewlett-Packard Company</orgname></affiliation>
+ </author>
+ <author>
+ <firstname>Will</firstname>
+ <surname>Walker</surname>
+ <affiliation><orgname>Digital Equipment Corporation</orgname></affiliation>
+ </author>
+ </authorgroup>
+ <releaseinfo>X Version 11, Release &fullrelvers;</releaseinfo>
+
+<legalnotice>
+<para>Copyright © 1995, 1996 X Consortium Inc.</para>
+<para>Copyright © 1995, 1996 Silicon Graphics Inc.</para>
+<para>Copyright © 1995, 1996 Hewlett-Packard Company</para>
+<para>Copyright © 1995, 1996 Digital Equipment Corporation</para>
+<para>
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the “Software”),
+to deal in the Software without restriction, including without limitation
+the rights to use, copy, modify, merge, publish, distribute, sublicense,
+and/or sell copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following conditions:
+</para>
+<para>
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+</para>
+<para>
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
+IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+</para>
+<para>
+Except as contained in this notice, the names of the X Consortium, Silicon
+Graphics Inc., Hewlett-Packard Company, and Digital Equipment Corporation
+shall not be used in advertising or otherwise to promote the sale, use or
+other dealings in this Software without prior written authorization.
+</para>
+</legalnotice>
+
+</bookinfo>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="acknowledgement.xml"/>
+<!-- Document font conventions pg goes here -->
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch01.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch02.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch03.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch04.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch05.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch06.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch07.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch08.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch09.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch10.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch11.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch12.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch13.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch14.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch15.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch16.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch17.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch18.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch19.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch20.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch21.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="ch22.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="glossary.xml"/>
+</book>
diff --git a/libX11/specs/i18n/compose/Makefile.am b/libX11/specs/i18n/compose/Makefile.am
new file mode 100644
index 000000000..9e3a26dea
--- /dev/null
+++ b/libX11/specs/i18n/compose/Makefile.am
@@ -0,0 +1,20 @@
+if ENABLE_SPECS
+if HAVE_PERL
+
+# Main DocBook/XML files (DOCTYPE book)
+docbook = libX11-keys.xml
+
+# Included chapters, appendix, images
+chapters = $(locales:%=%.xml)
+
+# The location where the DocBook/XML generated formats are installed
+shelfdir = $(docdir)/i18n/compose
+
+# Generate DocBook/XML output formats with or without stylesheets
+# The XML source is generated and cleaned but not distributed
+include docbook-nl.am
+
+endif HAVE_PERL
+endif ENABLE_SPECS
+
+EXTRA_DIST = compose-chart.pl
diff --git a/libX11/specs/i18n/compose/compose-chart.pl b/libX11/specs/i18n/compose/compose-chart.pl
new file mode 100644
index 000000000..e2ac8509f
--- /dev/null
+++ b/libX11/specs/i18n/compose/compose-chart.pl
@@ -0,0 +1,388 @@
+#! /usr/bin/perl
+#
+# Copyright 2009, 2010, Oracle and/or its affiliates. All rights reserved.
+#
+# Permission is hereby granted, free of charge, to any person obtaining a
+# copy of this software and associated documentation files (the "Software"),
+# to deal in the Software without restriction, including without limitation
+# the rights to use, copy, modify, merge, publish, distribute, sublicense,
+# and/or sell copies of the Software, and to permit persons to whom the
+# Software is furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice (including the next
+# paragraph) shall be included in all copies or substantial portions of the
+# Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+# DEALINGS IN THE SOFTWARE.
+#
+
+#
+# Make a DocBook chart showing compose combinations for a locale
+#
+# See perldoc at end (or run with --help or --man options) for details
+# of command-line options.
+#
+
+# Compose file grammar is defined in modules/im/ximcp/imLcPrs.c
+
+use strict;
+use warnings;
+use Getopt::Long;
+use Pod::Usage;
+
+my $error_count = 0;
+
+my $charset;
+my $locale_name;
+my $output_filename = '-';
+my $man = 0;
+my $help = 0;
+my $make_index = 0;
+
+GetOptions ('charset:s' => \$charset,
+ 'locale=s' => \$locale_name,
+ 'output=s' => \$output_filename,
+ 'index' => \$make_index,
+ 'help|?' => \$help,
+ 'man' => \$man)
+ or pod2usage(2);
+pod2usage(1) if $help;
+pod2usage(-exitstatus => 0, -verbose => 2) if $man;
+
+if (!defined($charset) || ($charset eq "")) {
+ if (defined($locale_name)) {
+ my $guessed_charset = $locale_name;
+ $guessed_charset =~ s{^.*\.}{};
+ if ($guessed_charset =~ m{^(utf-8|gbk|gb18030)$}i) {
+ $charset = $1;
+ } elsif ($guessed_charset =~ m{iso8859-(\d+)}i) {
+ $charset = "iso-8859-$1";
+ } elsif ($guessed_charset =~ m{^microsoft-cp(125\d)$}) {
+ $charset = "windows-$1";
+ }
+ }
+ if (!defined($charset) || ($charset eq "")) {
+ $charset = "utf-8";
+ }
+}
+
+if ($make_index) {
+ # Print Docbook output
+ open my $OUTPUT, '>', $output_filename
+ or die "Could not create $output_filename: $!";
+
+ print $OUTPUT
+ join ("\n",
+ qq(<?xml version="1.0" encoding="$charset" ?>),
+ q(<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"),
+ q( "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">),
+ q(<article id="libX11-keys">),
+ q( <articleinfo>),
+ q( <title>Xlib Compose Key Charts</title>),
+ q( </articleinfo>),
+ ( map { qq( <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="$_.xml">\
+ <xi:fallback><section><title>$_</title><para></para></section></xi:fallback>\
+ </xi:include>) }
+ @ARGV ),
+ q(</article>),
+ "\n"
+ );
+
+ close $OUTPUT or die "Couldn't write $output_filename: $!";
+
+ exit(0);
+}
+
+foreach my $a (@ARGV) {
+ $error_count += make_compose_chart($a);
+}
+
+exit($error_count);
+
+sub make_compose_chart {
+ my ($filename) = @_;
+ my $errors = 0;
+
+ my @compose_table = ();
+ my @included_files = ();
+
+ my $line = 0;
+ my $pre_file = ($filename =~ m{\.pre$}) ? 1 : 0;
+ my $in_c_comment = 0;
+ my $in_comment = 0;
+ my $keyseq_count = 0;
+
+ open my $COMPOSE, '<', $filename or die "Could not open $filename: $!";
+
+ COMPOSE_LINE:
+ while (my $cl = <$COMPOSE>) {
+ $line++;
+ chomp($cl);
+ my $original_line = $cl;
+
+ # Special handling for changes cpp makes to .pre files
+ if ($pre_file == 1) {
+ if ($in_c_comment) { # Look for end of multi-line C comment
+ if ($cl =~ m{\*/(.*)$}) {
+ $cl = $1;
+ $in_c_comment = 0;
+ } else {
+ next;
+ }
+ }
+ $cl =~ s{/\*.\**/}{}; # Remove single line C comments
+ if ($cl =~ m{^(.*)/\*}) { # Start of a multi-line C comment
+ $cl = $1;
+ $in_c_comment = 1;
+ }
+ $cl =~ s{^\s*XCOMM}{#}; # Translate pre-processing comments
+ }
+
+ chomp($cl);
+
+ if ($cl =~ m{^\s*#\s*(.*)$}) { # Comment only lines
+ # Combine commment blocks
+ my $comment = $1;
+
+ if ($in_comment) {
+ my $prev_comment = pop @compose_table;
+ $comment = join(' ', $prev_comment->{-comment}, $comment);
+ } else {
+ $in_comment = 1;
+ }
+
+ push @compose_table, { -type => 'comment', -comment => $comment };
+ next COMPOSE_LINE;
+ }
+
+ $in_comment = 0;
+
+ if ($cl =~ m{^\s*$}) { # Skip blank lines
+ next COMPOSE_LINE;
+ }
+ elsif ($cl =~ m{^(STATE\s+|END_STATE)}) {
+ # Sun extension to compose file syntax
+ next COMPOSE_LINE;
+ }
+ elsif ($cl =~ m{^([^:]+)\s*:\s*(.+)$}) {
+ my ($seq, $action) = ($1, $2);
+ $seq =~ s{\s+$}{};
+
+ my @keys = grep { $_ !~ m/^\s*$/ } split /[\s\<\>]+/, $seq;
+
+ push @compose_table, {
+ -type => 'keyseq',
+ -keys => [ @keys ],
+ -action => $action
+ };
+ $keyseq_count++;
+ next COMPOSE_LINE;
+ } elsif ($cl =~ m{^(STATE_TYPE:|\@StartDeadKeyMap|\@EndDeadKeyMap)}) {
+ # ignore
+ next COMPOSE_LINE;
+ } elsif ($cl =~ m{^include "(.*)"}) {
+ my $incpath = $1;
+ $incpath =~ s{^X11_LOCALEDATADIR/(.*)/Compose}{the $1 compose table};
+
+ push @included_files, $incpath;
+ next COMPOSE_LINE;
+ } else {
+ print STDERR ('Unrecognized pattern in ', $filename,
+ ' on line #', $line, ":\n ", $cl, "\n");
+ }
+ }
+ close $COMPOSE;
+
+ if ($errors > 0) {
+ return $errors;
+ }
+
+ # Print Docbook output
+ open my $OUTPUT, '>', $output_filename
+ or die "Could not create $output_filename: $!";
+
+ print $OUTPUT
+ join ("\n",
+ qq(<?xml version="1.0" encoding="$charset" ?>),
+ q(<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"),
+ q( "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">),
+ qq(<section id="$locale_name">),
+ qq(<title>Xlib Compose Keys for $locale_name</title>),
+ q(<para>Applications using Xlib input handling should recognize),
+ q( these compose key sequences in locales using the),
+ qq( $locale_name compose table.</para>),
+ "\n"
+ );
+
+ if (@included_files) {
+ print $OUTPUT
+ q(<para>This compose table includes the non-conflicting),
+ q( entries from: ),
+ join(',', @included_files),
+ q(. Those entries are not shown here - see those charts for the),
+ q( included key sequences.</para>),
+ "\n";
+ }
+
+ my @pretable_comments = ();
+
+ if ($keyseq_count == 0) {
+ @pretable_comments = @compose_table;
+ } elsif ($compose_table[0]->{-type} eq 'comment') {
+ push @pretable_comments, shift @compose_table;
+ }
+
+ foreach my $comment_ref (@pretable_comments) {
+ print $OUTPUT
+ qq(<para>), xml_escape($comment_ref->{-comment}), qq(</para>\n);
+ }
+
+ if ($keyseq_count > 0) {
+ start_table($OUTPUT);
+ my $row_count = 0;
+
+ foreach my $cr (@compose_table) {
+
+ if ($row_count++ > 750) {
+ # Break tables every 750 rows to avoid overflowing
+ # xmlto/xsltproc limits on the largest tables
+ end_table($OUTPUT);
+ start_table($OUTPUT);
+ $row_count = 0;
+ }
+
+ if ($cr->{-type} eq 'comment') {
+ print $OUTPUT
+ qq(<row><entry namest='seq' nameend='action'>),
+ xml_escape($cr->{-comment}), qq(</entry></row>\n);
+ } elsif ($cr->{-type} eq 'keyseq') {
+ my $action = join(" ", xml_escape($cr->{-action}));
+ if ($action =~ m{^\s*"\\([0-7]+)"}) {
+ my $char = oct($1);
+ if ($char >= 32) {
+ $action =~ s{^\s*"\\[0-7]+"}{"&#$char;"};
+ }
+ }
+ $action =~ s{^\s*"(.+)"}{"$1"};
+
+ print $OUTPUT
+ qq(<row><entry>),
+ qq(<keycombo action='seq'>),
+ (map { qq(<keysym>$_</keysym>) } xml_escape(@{$cr->{-keys}})),
+ qq(</keycombo>),
+ qq(</entry><entry>),
+ $action,
+ qq(</entry></row>\n);
+ }
+ }
+
+ end_table($OUTPUT);
+ } else {
+ print $OUTPUT
+ qq(<para><emphasis>),
+ qq(This compose table defines no sequences of its own.),
+ qq(</emphasis></para>\n);
+ }
+ print $OUTPUT "</section>\n";
+
+ close $OUTPUT or die "Couldn't write $output_filename: $!";
+
+ return $errors;
+}
+
+sub xml_escape {
+ my @output;
+
+ foreach my $l (@_) {
+ $l =~ s{\&}{&amp;}g;
+ $l =~ s{\<}{&lt;}g;
+ $l =~ s{\>}{&gt;}g;
+ push @output, $l;
+ }
+ return @output;
+}
+
+sub start_table {
+ my ($OUTPUT) = @_;
+
+ print $OUTPUT
+ join("\n",
+ qq(<table><title>Compose Key Sequences for $locale_name</title>),
+ qq(<tgroup cols='2'>),
+ qq( <colspec colname='seq' /><colspec colname='action' />),
+ qq( <thead><row>),
+ qq( <entry>Key Sequence</entry><entry>Action</entry>),
+ qq( </row></thead>),
+ qq( <tbody>\n),
+ );
+}
+
+sub end_table {
+ my ($OUTPUT) = @_;
+
+ print $OUTPUT "</tbody>\n</tgroup>\n</table>\n";
+}
+
+__END__
+
+=head1 NAME
+
+compose-chart - Make DocBook/XML charts of compose table entries
+
+=head1 SYNOPSIS
+
+compose-chart [options] [file ...]
+
+ Options:
+ --charset[=<cset>] character set to specify in XML doctype
+ --locale=<locale> name of locale to display in chart
+ --output=<file> filename to output chart to
+ --index make index of charts instead of individual chart
+ --help brief help message
+ --man full documentation
+
+=head1 OPTIONS
+
+=over 8
+
+=item B<--charset>[=I<cset>]
+
+Specify a character set to list in the doctype declaration in the XML output.
+If not specified, attempts to guess from the locale name, else default to
+"utf-8".
+
+=item B<--locale>=I<locale>
+
+Specify the locale name to use in the chart titles and introductory text.
+
+=item B<--output>=I<file>
+
+Specify the output file to write the DocBook output to.
+
+=item B<--index>
+
+Generate an index of the listed locale charts instead of a chart for a
+specific locale.
+
+=item B<--help>
+
+Print a brief help message and exit.
+
+=item B<--man>
+
+Print the manual page and exit.
+
+=back
+
+=head1 DESCRIPTION
+
+This program will read the given compose table file(s) and generate
+DocBook/XML charts listing the available characters for end-user reference.
+
+=cut
diff --git a/libX11/specs/i18n/compose/docbook-nl.am b/libX11/specs/i18n/compose/docbook-nl.am
new file mode 100644
index 000000000..95860c297
--- /dev/null
+++ b/libX11/specs/i18n/compose/docbook-nl.am
@@ -0,0 +1,128 @@
+#
+# Generate output formats for a single DocBook/XML with/without chapters
+#
+# This version of docbook.am handles cases where XML source is generated
+# and the html to be produced must be in chunks, one per chapter.
+# The generated source must be cleaned, installed but not distributed
+#
+# Variables set by the calling Makefile:
+# shelfdir: the location where the docs/specs are installed. Typically $(docdir)
+# docbook: the main DocBook/XML file, no chapters, appendix or image files
+# chapters: all files pulled in by an XInclude statement and images.
+#
+
+#
+# This makefile is intended for Users Documentation and Functional Specifications.
+# Do not use for Developer Documentation which is not installed and does not require olink.
+# Refer to http://www.x.org/releases/X11R7.6/doc/xorg-docs/ReleaseNotes.html#id2584393
+# for an explanation on documents classification.
+#
+
+# DocBook/XML generated output formats to be installed
+shelf_DATA = $(chapters) $(docbook)
+
+# Generated DocBook/XML source files using a perl script
+%.xml: $(top_builddir)/nls/%/Compose
+ $(AM_V_GEN)$(PERL) $(srcdir)/compose-chart.pl \
+ --locale="$(@:.xml=)" --output="$@" $<
+
+libX11-keys.xml: $(locales:%=%.xml)
+ $(AM_V_GEN)$(PERL) $(srcdir)/compose-chart.pl \
+ --index --output="$@" $(locales)
+
+if HAVE_XMLTO
+if HAVE_STYLESHEETS
+
+XMLTO_SEARCHPATH_FLAGS = \
+ --searchpath "$(XORG_SGML_PATH)/X11" \
+ --searchpath "$(abs_top_builddir)"
+XMLTO_HTML_OLINK_FLAGS = \
+ --stringparam target.database.document=$(XORG_SGML_PATH)/X11/dbs/masterdb.html.xml \
+ --stringparam current.docid="$(<:.xml=)"
+XMLTO_HTML_STYLESHEET_FLAGS = -x $(STYLESHEET_SRCDIR)/xorg-chunk.xsl
+XMLTO_TXT_STYLESHEET_FLAGS = -x $(STYLESHEET_SRCDIR)/xorg-xhtml.xsl
+XMLTO_HTML_CHUNKING_FLAGS = \
+ --stringparam root.filename="$(<:.xml=)"
+XMLTO_HTML_FLAGS = \
+ $(XMLTO_SEARCHPATH_FLAGS) \
+ $(XMLTO_HTML_STYLESHEET_FLAGS) \
+ $(XMLTO_HTML_CHUNKING_FLAGS) \
+ $(XMLTO_HTML_OLINK_FLAGS)
+XMLTO_TXT_FLAGS = \
+ $(XMLTO_SEARCHPATH_FLAGS) \
+ $(XMLTO_TXT_STYLESHEET_FLAGS) \
+ $(XMLTO_HTML_OLINK_FLAGS)
+
+shelf_DATA += $(docbook:.xml=.html) $(chapters:.xml=.html)
+%.html: %.xml $(chapters)
+ $(AM_V_GEN)$(XMLTO) $(XMLTO_HTML_FLAGS) xhtml $<
+
+if HAVE_XMLTO_TEXT
+
+shelf_DATA += $(docbook:.xml=.txt)
+%.txt: %.xml $(chapters)
+ $(AM_V_GEN)$(XMLTO) $(XMLTO_TXT_FLAGS) txt $<
+endif HAVE_XMLTO_TEXT
+
+if HAVE_FOP
+XMLTO_FO_IMAGEPATH_FLAGS = --stringparam img.src.path=$(abs_builddir)/
+XMLTO_FO_STYLESHEET_FLAGS = -x $(STYLESHEET_SRCDIR)/xorg-fo.xsl
+XMLTO_PDF_OLINK_FLAGS = \
+ --stringparam target.database.document=$(XORG_SGML_PATH)/X11/dbs/masterdb.pdf.xml \
+ --stringparam current.docid="$(<:.xml=)"
+XMLTO_FO_FLAGS = \
+ $(XMLTO_SEARCHPATH_FLAGS) \
+ $(XMLTO_FO_STYLESHEET_FLAGS) \
+ $(XMLTO_FO_IMAGEPATH_FLAGS) \
+ $(XMLTO_PDF_OLINK_FLAGS)
+
+shelf_DATA += $(docbook:.xml=.pdf)
+%.pdf: %.xml $(chapters)
+ $(AM_V_GEN)$(XMLTO) $(XMLTO_FO_FLAGS) --with-fop pdf $<
+
+shelf_DATA += $(docbook:.xml=.ps)
+%.ps: %.xml $(chapters)
+ $(AM_V_GEN)$(XMLTO) $(XMLTO_FO_FLAGS) --with-fop ps $<
+endif HAVE_FOP
+
+# Generate documents cross-reference target databases
+if HAVE_XSLTPROC
+
+XSLT_SEARCHPATH_FLAGS = \
+ --path "$(XORG_SGML_PATH)/X11" \
+ --path "$(abs_top_builddir)"
+XSLT_OLINK_FLAGS = \
+ --stringparam targets.filename "$@" \
+ --stringparam collect.xref.targets "only"
+XSLT_FO_OLINK_FLAGS = \
+ --stringparam olink.base.uri "$(@:.db=)"
+XSLT_HTML_CHUNKING_FLAGS = \
+ --stringparam root.filename "$(<:.xml=)"
+
+XSLT_HTML_FLAGS = \
+ $(XSLT_SEARCHPATH_FLAGS) \
+ $(XSLT_HTML_CHUNKING_FLAGS) \
+ $(XSLT_OLINK_FLAGS) \
+ --nonet --xinclude \
+ $(STYLESHEET_SRCDIR)/xorg-chunk.xsl
+
+XSLT_PDF_FLAGS = \
+ $(XSLT_SEARCHPATH_FLAGS) \
+ $(XSLT_OLINK_FLAGS) \
+ $(XSLT_FO_OLINK_FLAGS) \
+ --nonet --xinclude \
+ $(STYLESHEET_SRCDIR)/xorg-fo.xsl
+
+shelf_DATA += $(docbook:.xml=.html.db)
+%.html.db: %.xml $(chapters)
+ $(AM_V_GEN)$(XSLTPROC) $(XSLT_HTML_FLAGS) $<
+
+shelf_DATA += $(docbook:.xml=.pdf.db)
+%.pdf.db: %.xml $(chapters)
+ $(AM_V_GEN)$(XSLTPROC) $(XSLT_PDF_FLAGS) $<
+
+endif HAVE_XSLTPROC
+endif HAVE_STYLESHEETS
+endif HAVE_XMLTO
+
+CLEANFILES = $(shelf_DATA)
diff --git a/libX11/specs/i18n/framework/framework.xml b/libX11/specs/i18n/framework/framework.xml
index 97a8264e9..4d87d4736 100644
--- a/libX11/specs/i18n/framework/framework.xml
+++ b/libX11/specs/i18n/framework/framework.xml
@@ -1,12 +1,15 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
- "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+<!ENTITY % defs SYSTEM "defs.ent"> %defs;
+]>
<book id="framework">
<bookinfo>
<title>X11R6 Sample Implementation Frame Work</title>
- <releaseinfo>X Version 11, Release 7</releaseinfo>
+ <releaseinfo>X Version 11, Release &fullrelvers;</releaseinfo>
<authorgroup>
<othercredit>
<firstname>Katsuhisa</firstname><surname>Yano</surname>
diff --git a/libX11/specs/i18n/trans/trans.xml b/libX11/specs/i18n/trans/trans.xml
index 61e2e7976..8e38e8963 100644
--- a/libX11/specs/i18n/trans/trans.xml
+++ b/libX11/specs/i18n/trans/trans.xml
@@ -1,13 +1,16 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
- "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+<!ENTITY % defs SYSTEM "defs.ent"> %defs;
+]>
<book id="trans">
<bookinfo>
<title>The XIM Transport Specification</title>
<subtitle>Revision 0.1</subtitle>
- <releaseinfo>X Version 11, Release 7</releaseinfo>
+ <releaseinfo>X Version 11, Release &fullrelvers;</releaseinfo>
<authorgroup>
<author>
<firstname>Takashi</firstname><surname>Fujiwara</surname>
@@ -17,7 +20,6 @@
<copyright><year>1994</year><holder>FUJITSU LIMITED</holder></copyright>
<copyright><year>1994</year><holder>X Consortium</holder></copyright>
- <productnumber>Revision 0.1</productnumber>
<abstract>
diff --git a/libX11/specs/libX11/libX11.xml b/libX11/specs/libX11/libX11.xml
index 50da9e620..30d73b8f0 100644
--- a/libX11/specs/libX11/libX11.xml
+++ b/libX11/specs/libX11/libX11.xml
@@ -1,147 +1,148 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
- "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd">
-
-<book id="libX11" lang="en">
-
-<bookinfo>
- <title>Xlib - C Language X Interface</title>
- <subtitle>X Window System Standard</subtitle>
- <releaseinfo>X Version 11, Release 7</releaseinfo>
- <authorgroup>
- <author>
- <firstname>James</firstname><surname>Gettys</surname>
- <affiliation>
- <orgname>Digital Equipment Corporation</orgname>
- <orgdiv>Cambridge Research Laboratory</orgdiv>
- </affiliation>
- </author>
- <author>
- <firstname>Robert</firstname><othername role='mi'>W.</othername> <surname>Scheifler</surname>
- <affiliation>
- <orgname>Massachusetts Institute of Technology</orgname>
- <orgdiv>Laboratory for Computer Science</orgdiv>
- </affiliation>
- </author>
- <othercredit>
- <firstname>Chuck</firstname><surname>Adams</surname>
- <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Vania</firstname><surname>Joloboff</surname>
- <affiliation><orgname>Open Software Foundation</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Hideki</firstname><surname>Hiura</surname>
- <affiliation><orgname>Sun Microsystems, Inc.</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Bill</firstname><surname>McMahon</surname>
- <affiliation><orgname>Hewlett-Packard Company</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Ron</firstname><surname>Newman</surname>
- <affiliation><orgname>Massachusetts Institute of Technology</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Al</firstname><surname>Tabayoyon</surname>
- <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Glenn</firstname><surname>Widener</surname>
- <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
- </othercredit>
- <othercredit>
- <firstname>Shigeru</firstname><surname>Yamada</surname>
- <affiliation><orgname>Fujitsu OSSI</orgname></affiliation>
- </othercredit>
- </authorgroup>
- <copyright><year>1985</year><year>1986</year><year>1987</year>
- <year>1988</year><year>1989</year><year>1991</year><year>1994</year>
- <year>1996</year><year>2002</year><holder>The Open Group</holder>
- </copyright>
- <copyright><year>1985</year><year>1986</year><year>1987</year>
- <year>1988</year><year>1989</year><year>1991</year>
- <holder>Digital Equipment Corporation</holder>
- </copyright>
-
- <affiliation><orgname>formerly MIT X Consortium</orgname></affiliation>
- <productnumber>X Version 11, Release 7</productnumber>
-
-<legalnotice>
-
-<para>
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files
-(the &ldquo;Software&rdquo;), to deal in the Software without restriction,
-including without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to permit
-persons to whom the Software is furnished to do so, subject to the following
-conditions:
-</para>
-
-<para>
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-</para>
-
-<para>
-THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
-</para>
-
-<para>
-Except as contained in this notice, the name of The Open Group shall not
-be used in advertising or otherwise to promote the sale, use or other dealings
-in this Software without prior written authorization from The Open Group.
-</para>
-
-<para>
-Permission to use, copy, modify and distribute this documentation for any
-purpose and without fee is hereby granted, provided that the above copyright
-notice appears in all copies and that both that copyright notice and this
-permission notice appear in supporting documentation, and that the names of
-Digital and Tetronix not be used in in advertising or publicity pertaining
-to distribution of the software without specific, written prior permission.
-Digital and Tetronix make no representations about the suitability of the
-software described herein for any purpose.
-It is provided "as is" without express or implied warranty.
-</para>
-
-
-<para>TekHVC is a trademark of Tektronix, Inc.</para>
-
-</legalnotice>
-</bookinfo>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="credits.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH01.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH02.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH03.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH04.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH05.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH06.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH07.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH08.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH09.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH10.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH11.xml"/>
-<!-- -->
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH12.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH13.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH14.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH15.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH16.xml"/>
-<!-- runs out of mem at here -->
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppA.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppB.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppC.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppD.xml"/>
-<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="glossary.xml"/>
-<index />
-</book>
-
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
+ "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd"
+[
+<!ENTITY % defs SYSTEM "defs.ent"> %defs;
+]>
+
+
+<book id="libX11" lang="en">
+
+<bookinfo>
+ <title>Xlib - C Language X Interface</title>
+ <subtitle>X Window System Standard</subtitle>
+ <releaseinfo>X Version 11, Release &fullrelvers;</releaseinfo>
+ <authorgroup>
+ <author>
+ <firstname>James</firstname><surname>Gettys</surname>
+ <affiliation>
+ <orgname>Digital Equipment Corporation</orgname>
+ <orgdiv>Cambridge Research Laboratory</orgdiv>
+ </affiliation>
+ </author>
+ <author>
+ <firstname>Robert</firstname><othername role='mi'>W.</othername> <surname>Scheifler</surname>
+ <affiliation>
+ <orgname>Massachusetts Institute of Technology</orgname>
+ <orgdiv>Laboratory for Computer Science</orgdiv>
+ </affiliation>
+ </author>
+ <othercredit>
+ <firstname>Chuck</firstname><surname>Adams</surname>
+ <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Vania</firstname><surname>Joloboff</surname>
+ <affiliation><orgname>Open Software Foundation</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Hideki</firstname><surname>Hiura</surname>
+ <affiliation><orgname>Sun Microsystems, Inc.</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Bill</firstname><surname>McMahon</surname>
+ <affiliation><orgname>Hewlett-Packard Company</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Ron</firstname><surname>Newman</surname>
+ <affiliation><orgname>Massachusetts Institute of Technology</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Al</firstname><surname>Tabayoyon</surname>
+ <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Glenn</firstname><surname>Widener</surname>
+ <affiliation><orgname>Tektronix, Inc.</orgname></affiliation>
+ </othercredit>
+ <othercredit>
+ <firstname>Shigeru</firstname><surname>Yamada</surname>
+ <affiliation><orgname>Fujitsu OSSI</orgname></affiliation>
+ </othercredit>
+ </authorgroup>
+ <copyright><year>1985</year><year>1986</year><year>1987</year>
+ <year>1988</year><year>1989</year><year>1991</year><year>1994</year>
+ <year>1996</year><year>2002</year><holder>The Open Group</holder>
+ </copyright>
+ <copyright><year>1985</year><year>1986</year><year>1987</year>
+ <year>1988</year><year>1989</year><year>1991</year>
+ <holder>Digital Equipment Corporation</holder>
+ </copyright>
+
+<legalnotice>
+
+<para>
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files
+(the &ldquo;Software&rdquo;), to deal in the Software without restriction,
+including without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to permit
+persons to whom the Software is furnished to do so, subject to the following
+conditions:
+</para>
+
+<para>
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+</para>
+
+<para>
+THE SOFTWARE IS PROVIDED &ldquo;AS IS&rdquo;, WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+</para>
+
+<para>
+Except as contained in this notice, the name of The Open Group shall not
+be used in advertising or otherwise to promote the sale, use or other dealings
+in this Software without prior written authorization from The Open Group.
+</para>
+
+<para>
+Permission to use, copy, modify and distribute this documentation for any
+purpose and without fee is hereby granted, provided that the above copyright
+notice appears in all copies and that both that copyright notice and this
+permission notice appear in supporting documentation, and that the names of
+Digital and Tetronix not be used in in advertising or publicity pertaining
+to distribution of the software without specific, written prior permission.
+Digital and Tetronix make no representations about the suitability of the
+software described herein for any purpose.
+It is provided "as is" without express or implied warranty.
+</para>
+
+
+<para>TekHVC is a trademark of Tektronix, Inc.</para>
+
+</legalnotice>
+</bookinfo>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="credits.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH01.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH02.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH03.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH04.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH05.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH06.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH07.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH08.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH09.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH10.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH11.xml"/>
+<!-- -->
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH12.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH13.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH14.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH15.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="CH16.xml"/>
+<!-- runs out of mem at here -->
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppA.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppB.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppC.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="AppD.xml"/>
+<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="glossary.xml"/>
+<index />
+</book>
+