LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 12-13-2006, 11:07 AM   #1
yae
LQ Newbie
 
Registered: Dec 2006
Location: France
Distribution: Ubuntu
Posts: 3

Rep: Reputation: 0
Keyboard customization in X environment


Hello,

I need to add extra meanings to keystrokes in the X environment.
I believe I did the right thing adding right control key to modifier Mod3 with xmodmap.

The environment is French Ubuntu Edgy 6.10 with Gnome, French 105 keys PC keyboard layout.

Here is what was the default modifier table as returned by xmodmap -pm

xmodmap: up to 3 keys per modifier, (keycodes in parentheses):

shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25), Control_R (0x6d)
mod1 Alt_L (0x40), Alt_L (0x7d), Meta_L (0x9c)
mod2 Num_Lock (0x4d)
mod3
mod4 Super_L (0x7f), Hyper_L (0x80)
mod5 Mode_switch (0x5d), ISO_Level3_Shift (0x71), ISO_Level3_Shift (0x7c)

After some reading about xmodmap, I issued the command :

xmodmap -e "remove control = Control_R" -e "add mod3 = Control_R"

The new modifier table became, as returned by xmodmap -pm

xmodmap: up to 3 keys per modifier, (keycodes in parentheses):

shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25)
mod1 Alt_L (0x40), Alt_L (0x7d), Meta_L (0x9c)
mod2 Num_Lock (0x4d)
mod3 Control_R (0x6d)
mod4 Super_L (0x7f), Hyper_L (0x80)
mod5 Mode_switch (0x5d), ISO_Level3_Shift (0x71), ISO_Level3_Shift (0x7c)

As a result Control_R c just displays c, while Control_L c still shows the usual Control c behaviour.

My question is : how can I assign a new symbol (for example D) to Control_R c for all future X Window sessions on the machine ? In other words, how do I set the mod3 meaning for keystrokes ?

Thanks very much for your help

Yves-Antoine Emmanuelli
France
 
Old 12-13-2006, 11:19 AM   #2
mrclisdue
Senior Member
 
Registered: Dec 2005
Distribution: Slackware -current, 14.1
Posts: 1,047

Rep: Reputation: 170Reputation: 170
keyTouch

Code:
keytouch.sf.net
may be of assistance to you as it allows you to 'permanently' modify your keyboard.

cheers,
 
Old 12-13-2006, 11:49 AM   #3
yae
LQ Newbie
 
Registered: Dec 2006
Location: France
Distribution: Ubuntu
Posts: 3

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by mrclisdue
keyTouch

Code:
keytouch.sf.net
may be of assistance to you as it allows you to 'permanently' modify your keyboard.

cheers,
Thanks for the hint, but my problem is not configuring extra function keys.
I need to configure an APL keyboard on top of a French layout. I found APL keymaps for US keyboards, using the mode switch key, but on a French keyboard the mode switch key is already used for characters such as backslah, arobas, brackets, which I do not want to override.

I have the feeling that an X configuration file has to be written and put somewhere (/etc/X11 ?) but I could not find anything really relevant.

Regards

Yves-Antoine
 
Old 12-17-2006, 09:55 AM   #4
yae
LQ Newbie
 
Registered: Dec 2006
Location: France
Distribution: Ubuntu
Posts: 3

Original Poster
Rep: Reputation: 0
Question

There might be another way to achieve what I need :
On my Ubuntu 6.10 system with a 105 keys French keyboard layout, xmodmap -pke outputs 6 keysyms per keycode, although the manual page states that only the 4 first are keyable (key, shitf key, AltGr key, AltGr shift key). On French keyboard layout, the right Alt key is labelled AltGr. So if the Debian/Ubuntu guys coded these 5th and 6th characters, they must be useable somehow. But I tried all sorts of key combinations without any success.

Here is the beginning of the xmodmap -pke output :

keycode 8 =
keycode 9 = Escape
keycode 10 = ampersand 1 onesuperior exclamdown onesuperior exclamdown
keycode 11 = eacute 2 asciitilde oneeighth asciitilde oneeighth
keycode 12 = quotedbl 3 numbersign sterling numbersign sterling
keycode 13 = apostrophe 4 braceleft dollar braceleft dollar

Any idea on how to activate the 5th and 6th characters ?

Thanks for you help !
--
Yves-Antoine
 
  


Reply

Tags
keyboard, xmodmap


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
New to Ubuntu - keyboard problems, help with customization, some other stuff Nakunatta Linux - Newbie 1 09-24-2006 03:58 PM
Customization Questions Arkas Linux - General 2 08-27-2006 05:17 PM
xterm customization Flexxy Linux - Software 9 02-06-2006 08:27 PM
Shell Customization rcallahan Linux - Newbie 5 01-27-2005 04:11 PM
Customization Jmcatch742 Linux - General 7 08-21-2004 09:55 PM


All times are GMT -5. The time now is 09:44 PM.

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