- With Xorg 7.4 it's a pain if you don't have an US keyboard and don't
use KDE, GNOME, etc. so let's add a note on how to set the right keyboard layout. This will help a lot of people; - while writing this addition, I noted that one HAL key I used in my previous commit was said to be "deprecated", so let's use the "right" one.
This commit is contained in:
parent
f85be0331e
commit
d73a242bbc
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/head/; revision=34658
1 changed files with 50 additions and 1 deletions
|
@ -504,7 +504,7 @@ dbus_enable="YES"</programlisting>
|
|||
<deviceinfo version="0.2">
|
||||
<device>
|
||||
<match key="info.capabilities" contains="input.keyboard">
|
||||
<merge key="input.xkb.options" type="string">terminate:ctrl_alt_bksp</merge>
|
||||
<merge key="input.x11_options.XkbOptions" type="string">terminate:ctrl_alt_bksp</merge>
|
||||
</match>
|
||||
</device>
|
||||
</deviceinfo></programlisting>
|
||||
|
@ -528,6 +528,55 @@ dbus_enable="YES"</programlisting>
|
|||
along with any other options needed (e.g. keyboard layout
|
||||
switching).</para>
|
||||
|
||||
<note>
|
||||
<para>As previously explained since version 7.4, by default,
|
||||
the <application>hald</application> daemon will
|
||||
automatically detect your keyboard. There are chances that
|
||||
your keyboard layout or model will not be correct, desktop
|
||||
environments like <application>GNOME</application>,
|
||||
<application>KDE</application> or
|
||||
<application>Xfce</application> provide tools to configure
|
||||
the keyboard. However, it is possible to set the keyboard
|
||||
properties directly either with the help of the
|
||||
&man.setxkbmap.1; utility or with a
|
||||
<application>hald</application>'s configuration rule.</para>
|
||||
|
||||
<para>For example if one wants to use a PC 102 keys keyboard
|
||||
coming with a french layout, we have to create a keyboard
|
||||
configuration file for <application>hald</application>
|
||||
called <filename>x11-input.fdi</filename> and saved in the
|
||||
<filename
|
||||
class="directory">/usr/local/etc/hal/fdi/policy</filename>
|
||||
directory. This file should contain the following
|
||||
lines:</para>
|
||||
|
||||
<programlisting><?xml version="1.0" encoding="ISO-8859-1"?>
|
||||
<deviceinfo version="0.2">
|
||||
<device>
|
||||
<match key="info.capabilities" contains="input.keyboard">
|
||||
<merge key="input.x11_options.XkbModel" type="string">pc102</merge>
|
||||
<merge key="input.x11_options.XkbLayout" type="string">fr</merge>
|
||||
</match>
|
||||
</device>
|
||||
</deviceinfo></programlisting>
|
||||
|
||||
<para>If this file already exists, just copy and add to your
|
||||
file the lines regarding the keyboard configuration.</para>
|
||||
|
||||
<para>You will have to reboot your machine to force
|
||||
<application>hald</application> to read this file.</para>
|
||||
|
||||
<para>It is possible to do the same configuration from an X
|
||||
terminal or a script with this command line:</para>
|
||||
|
||||
<screen>&prompt.user; <userinput>setxkbmap -model pc102 -layout fr</userinput></screen>
|
||||
|
||||
<para>The
|
||||
<filename>/usr/local/share/X11/xkb/rules/base.lst</filename>
|
||||
file lists the various keyboard, layouts and options
|
||||
available.</para>
|
||||
</note>
|
||||
|
||||
<indexterm><primary>X11 tuning</primary></indexterm>
|
||||
|
||||
<para>Next, tune the <filename>xorg.conf.new</filename>
|
||||
|
|
Loading…
Reference in a new issue