LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 02-23-2011, 01:51 PM   #1
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian Stretch
Posts: 1,082

Rep: Reputation: 83
How do I run setxkbmap at startup?


I have a problem with my keyboard on Kubuntu 10.10. The specifics of the problem are not really relevant right now. I can fix it by running 'setxkbmap br' on the command line. It's good for the entire session (KDE).

But I often forgot to do that, so I want to have that done automatically. I tried adding it to my .tcshrc file, it didn't work. I tried adding it to /etc/rc.local, it didn't work. Where can I insert that line and have it run automatically? Please note that my login shell is tcsh, not Bash.
 
Old 02-23-2011, 01:56 PM   #2
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
Quote:
Originally Posted by lucmove View Post
The specifics of the problem are not really relevant right now.
Actually it is. The more output you give us, the better we can help; What is the real problem with your keyboard?
 
0 members found this post helpful.
Old 02-23-2011, 02:05 PM   #3
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian Stretch
Posts: 1,082

Original Poster
Rep: Reputation: 83
Quote:
Originally Posted by corp769 View Post
Actually it is. The more output you give us, the better we can help; What is the real problem with your keyboard?
The first problem is explained HERE.

The second problem is I configured Yakuake to open a new tab/console/session with the Win+/ (Win and slash) key combination. It doesn't work on my ABNT2 keyboard. Yakuake wants Win+; (Win and semicolon). After the setxkbmap kludge, it works correctly.

Note that those keys are typed correctly in all other applications, including Yakuake, Konsole or Xterm. Just Wine causes me that problem, and Yakuake just doesn't understand the key combination properly, it types the individual characters correctly.

I never had any of these problems in Ubuntu 8.04 and 9.04, or even when I used Slackware 12 years ago. It started after I upgraded to Ubuntu 10.10.
 
Old 02-24-2011, 11:23 AM   #4
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian Stretch
Posts: 1,082

Original Poster
Rep: Reputation: 83
Quote:
The specifics of the problem are not really relevant right now.
Quote:
Originally Posted by corp769 View Post
Actually it is. The more output you give us, the better we can help; What is the real problem with your keyboard?
So, are you going to tell me how exactly the specifics of the problem were relevant? If you hadn't walked in just to say that, my question would still be featured in the Zero Reply Threads section, and I would probably stand a better chance of getting a useful reply.
 
Old 02-24-2011, 12:13 PM   #5
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
How about in /etc/csh.login?

And sorry for the late reply, I got really sick man.
 
1 members found this post helpful.
Old 02-24-2011, 12:41 PM   #6
DavidMcCann
LQ Veteran
 
Registered: Jul 2006
Location: London
Distribution: PCLinuxOS, Xubuntu
Posts: 5,741

Rep: Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115Reputation: 2115
Create a file containing the command — say $HOME/.brkbd
Look in the KDE menu (I can't say where, as I'm a Gnome/Xfce user) for the program to set which programs are run when starting a session, and add your file. Make sure you've set its permissions to enable it to run as a program.
 
1 members found this post helpful.
Old 02-24-2011, 12:47 PM   #7
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
Quote:
Originally Posted by DavidMcCann View Post
Create a file containing the command say $HOME/.brkbd
Look in the KDE menu (I can't say where, as I'm a Gnome/Xfce user) for the program to set which programs are run when starting a session, and add your file. Make sure you've set its permissions to enable it to run as a program.
That too. Good thinking man.
 
Old 02-25-2011, 05:08 PM   #8
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian Stretch
Posts: 1,082

Original Poster
Rep: Reputation: 83
/etc/csh.login did not work, but DavidMcCann's idea seems to have worked. Funny that the first two attempts at pressing the key shortcut failed, then it worked and seems to be working. I will test it over the weekend with a few reboots and mark the thread as SOLVED if I don't run into any problems. Thank you, you two!
 
Old 02-25-2011, 05:11 PM   #9
corp769
LQ Guru
 
Registered: Apr 2005
Location: /dev/null
Posts: 5,818

Rep: Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005Reputation: 1005
Oh cool, at least it's working now....
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Build SetXkbMap utility. ravi13jain Linux - Embedded & Single-board computer 0 08-11-2009 03:55 AM
I run Fedora 9 and I boot from USB, how I run at startup Firewall and antivirus? gginis Linux - Software 3 06-08-2008 03:19 AM
nr.2 setxkbmap ?? chstani Linux - Newbie 5 09-17-2005 10:54 PM
XFCE & setxkbmap spes_hominis Slackware 3 07-12-2005 03:55 PM
setxkbmap no accents bobbens Linux - Software 0 03-17-2005 12:17 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration