LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   keyboard configuration in Xorg: deadkeys, hal, evdev, what? (https://www.linuxquestions.org/questions/slackware-14/keyboard-configuration-in-xorg-deadkeys-hal-evdev-what-851147/)

quiescere 12-18-2010 07:48 PM

keyboard configuration in Xorg: deadkeys, hal, evdev, what?
 
What is the modern way to set up a compose key and deadkeys in X? (Slack 13.1, standard US equipment)

First I tried xorg.conf:
Code:

Section "InputDevice"
    Identifier  "Keyboard1"
    Driver      "kbd"
    Option      "XkbRules"    "xorg"
    Option      "XkbModel"    "pc104"
    Option      "XkbLayout"  "us"
    Option      "XkbVariant"  "intl"
    Option      "XkbOptions"  "compose:ralt"
EndSection

Then further reading suggested hal is the new way, so I copied /usr/share/hal/fdi/policy/10osvendor/10-keymap.fdi to /etc/hal/fdi/policy and made some changes:
Code:

      <merge key="input.xkb.rules" type="string">base</merge>
      <merge key="input.xkb.model" type="string">evdev</merge>
      <merge key="input.xkb.layout" type="string">us</merge>
      <merge key="input.xkb.variant" type="string">intl</merge>
      <merge key="input.xkb.options" type="string">compose:ralt</merge>

That didn't work either. Now I've read more that says Xorg doesn't need hal any longer.

Does anyone have any recommendations for where to turn next? It seems like every three years or so I have to re-learn how to configure a keyboard because the infrastructure has fundamentally changed. This is frustrating.

Thanks----
quiescere

lumak 12-18-2010 07:58 PM

If you are just modifying a few keys of any particular map, I would use xmodmap. However, if you are completely changing a keyboard map (say qwerty to dvorak) I would use setxkbmap.

EDIT: the above mentioned file has the same note as the CHANGES_AND_HINTS.txt
You can try disabling hal for xinputs. But you will need a full xorg.conf file.
Option "AllowEmptyInput" "false"
Option "AutoAddDevices" "false"
Option "AutoEnableDevices" "false"

Being that you already tried the hal method, I would either give up and use setxkbmap but save hal for the other inputs and video card, or ditch hal and define a full xorg.conf file.

EDIT EDIT EDIT:

The solution might be simple...

Did you restart the hal service? It might not like your changes until it restarts and rereads the config file ;).. obviously also restart x.

Code:

su -c '/etc/rc.d/rc.hald restart'

quiescere 12-18-2010 09:07 PM

Quote:

Originally Posted by lumak (Post 4196374)
Being that you already tried the hal method, I would either give up and use setxkbmap but save hal for the other inputs and video card, or ditch hal and define a full xorg.conf file.

This may be what I have to do. The following command gives the behaviour I want, but it bugs me that I don't know the proper way to configure this as the default:
Code:

setxkbmap -model pc105 -layout us -variant intl -option "compose:ralt"
Quote:

Originally Posted by lumak (Post 4196374)
Did you restart the hal service? It might not like your changes until it restarts and rereads the config file ;).. obviously also restart x.

Code:

su -c '/etc/rc.d/rc.hald restart'

Good suggestion. I did restart both before my first posting, with no luck. I should have said so in my initial post.

Thanks for your quick reply.

quiescere


All times are GMT -5. The time now is 07:19 AM.