LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 10-20-2012, 05:19 PM   #1
NorthBridge
LQ Newbie
 
Registered: Oct 2012
Location: Somewhere after <?php
Distribution: Slackware-current
Posts: 15

Rep: Reputation: 1
Small problem with xorg.conf and setxkbmap


Good evening

First, I should say hello to everyone here, since I'm new to Slackware (coming from Arch Linux). It's a sweet distro, and I think it's just what I needed, so I hope I will continue using it for as long as possible.

Anyway, enough bla-bla, here's the problem:

Just after finishing the installation, and setting up X + E17 for a window manager, my next task was to add my second keyboard layout I usually use. Normally E17 (at least in Arch) has a keyboard module, which does the job, but in the version I installed on slack I couldn't find it. Nothing serious, I thought, since I remembered a little trick from the days of Kubuntu 8.04 - directly adding the layouts in xorg.conf. Here's what I currently have in the keyboard section in xorg.conf:
Code:
Section "InputDevice"
        Identifier  "Keyboard0"
        Driver      "kbd"
        Option      "XkbRules" "xorg"
        Option      "XkbModel" "pc105"
        Option      "XkbLayout" "us,bg"
        Option      "XkbVariant" ",phonetic"
        Option      "XkbOptions" "grp:alt_shift_toggle,grp_led:scroll"
EndSection
The problem is, even after restarting X, when I press alt+shift, the layout doesn't change at all - but if I write manually in a terminal
Code:
setxkbmap -model pc105 -layout us,bg -variant ,phonetic -option grp:alt_shift_toggle,grp_led:scroll
,everything works like a charm.

What am I missing, something really stupid, or some weird conflict between the WM and X?
 
Old 10-21-2012, 02:17 AM   #2
bathory
Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 10,905

Rep: Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326Reputation: 1326
Hi,

These options go into a .conf file under /etc/X11/xorg.conf.d
You can copy /usr/share/X11/xorg.conf.d/90-keyboard-layout.conf there and edit it to your likings.

Regards
 
3 members found this post helpful.
Old 10-21-2012, 07:23 AM   #3
lopid
Member
 
Registered: Jun 2008
Posts: 107

Rep: Reputation: Disabled
I found the same problem a year ago when I tried out Dvorak, and I ended up doing just as you did. I actually bound some keyboard shortcuts to switch to and from layouts dynamically, using similar setxkbmap commands, and had a little applet in the systray that showed the current language flag.
 
Old 10-21-2012, 08:20 AM   #4
NorthBridge
LQ Newbie
 
Registered: Oct 2012
Location: Somewhere after <?php
Distribution: Slackware-current
Posts: 15

Original Poster
Rep: Reputation: 1
Worked like a charm! Thanks a lot

Just a quick question. What is the keyboard section in xorg.conf's purpose, since it doesn't control the actual keyboard - kind of fallback in case of failure, or something else?
 
Old 10-21-2012, 08:32 AM   #5
lopid
Member
 
Registered: Jun 2008
Posts: 107

Rep: Reputation: Disabled
You'd probably be best off copying /usr/share/X11/xorg.conf.d/90-keyboard-layout.conf to /etc/X11/xorg.conf.d/90-keyboard-layout.conf, and editing the latter, because I see your code snippet is using 'InputDevice' instead of 'InputClass', and your Identifier and Driver are different to how they are in the former, which is probably why it's not controlling the keyboard for you.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
X starts without xorg.conf, however with aticonfig, resultant xorg.conf hangs linuxbird Linux - Desktop 3 08-23-2012 05:28 AM
[SOLVED] Multi_key, xorg.conf & setxkbmap jtwdyp Linux - General 2 04-13-2011 04:22 PM
My xorg.conf is replaced with a default xorg.conf after reboot rrrssssss Linux - Hardware 9 04-11-2010 04:45 PM
nvidia xorg.conf OR X windows xorg.conf? machines Slackware 3 04-06-2008 02:10 PM
Problems with monitor & unreadably small fonts / xorg.conf with SuSE 9.3 Pro mrbadi Suse/Novell 3 07-15-2005 10:00 AM


All times are GMT -5. The time now is 11:23 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration