x.rst
changeset 2559 42551ca22ca3
parent 2228 837f1337c59b
equal deleted inserted replaced
2558:8ddc7e78cd41 2559:42551ca22ca3
    99 ``keysyms``
    99 ``keysyms``
   100   codes that specify the glyphs appearing on the keys. The X
   100   codes that specify the glyphs appearing on the keys. The X
   101   server also maintains a list of strings that describe the
   101   server also maintains a list of strings that describe the
   102   keysyms, such as ``a``, ``B``, and ``Control``.
   102   keysyms, such as ``a``, ``B``, and ``Control``.
   103 
   103 
   104 Find the keycode.
   104 Find keycodes
   105 =================
   105 =============
   106 
   106 
   107 ::
   107 From X server::
   108 
   108 
   109   $ xev
   109   xev
   110   $ xev | grep keysym --color
   110   xev | grep keysym --color
   111   $ cat /usr/include/X11/keysymdef.h
   111   cat /usr/include/X11/keysymdef.h
   112 
   112 
   113 Don't run under X::
   113 From a hardware terminal::
   114 
   114 
   115   $ showkey
   115   showkey
       
   116 
       
   117 Translated codes by PTY (including virtual)::
       
   118 
       
   119   showkey -a
   116 
   120 
   117 To do same under X::
   121 To do same under X::
   118 
   122 
   119   $ xev | sed -n 's=.*keycode \([0-9]*\).*=\1=p'
   123   $ xev | sed -n 's=.*keycode \([0-9]*\).*=\1=p'
   120 
   124 
   141 
   145 
   142 https://wiki.ubuntu.com/LaptopTesting/Keycodes
   146 https://wiki.ubuntu.com/LaptopTesting/Keycodes
   143   Ubuntu Keycodes howto.
   147   Ubuntu Keycodes howto.
   144 http://en.gentoo-wiki.com/wiki/Multimedia_Keys
   148 http://en.gentoo-wiki.com/wiki/Multimedia_Keys
   145   Gentoo Multimedia Keys howto.
   149   Gentoo Multimedia Keys howto.
       
   150 https://wiki.archlinux.org/title/Keyboard_input
       
   151   Keyboard input.
   146 
   152 
   147 List input devices.
   153 List input devices.
   148 ===================
   154 ===================
   149 ::
   155 ::
   150 
   156