Xmodmap is a tool found in the xll-xserver-utils-package and it enables keyboard maps and pointer button mappings to be configured according to the user's preference. It is often used to set up custom keys such as launcher or media buttons on a laptop.

learn more… | top users | synonyms

0
votes
0answers
10 views

How can I specify mouse button map for different applictions

I'm using a mouse having many buttons. There is a software in Windows named X-Mouse Button Control that can specify mouse button map for different applictions. But I can't specify appliction using ...
0
votes
0answers
7 views

Remap XF86ScrollUp to Different Key

I have been trying to change the page up key without any success. What might I be doing wrong? xmodmap -e "keycode 38 = XF86ScrollUp"
0
votes
0answers
24 views

xmodmap: How to set Mode_switch to Ctrl+Alt?

When using xmodmap, is it possible to map the Mode_switch to Ctrl+Alt? I am trying to map Alt+Ctrl+ u to ü and Alt+Ctrl+Shift+u to Ü. I have no AltGr on my keyboard (KBC Poker I). I have it down to ...
0
votes
0answers
33 views

Key arrangement for Macbook with Right Command?

I installed Ubuntu on my Macbook Air 5,1 a few weeks back, and it's been great, except that I couldn't figure out how to remap keys the way I want them. Most guides suggest swapping the command and ...
0
votes
1answer
30 views

Is it possible to run a script on keyboard input language change?

I'm interested in running a script whenever I manually change the input language. This is because my xmodmap is forgotten whenever I change input languages, so a solution to that would also be useful. ...
1
vote
1answer
50 views

Remap a key to the left mouse button

My problem is that I don't know keyname action for Mouse Click. For example I want to remap F1 which keycode is 67 with a mouse click 1 I have to type: xmodmap -e "keycode 67 = ??" What ...
0
votes
0answers
15 views

How would I remap right Alt to backspace?

I guess the title says it all; how would I use xmodmap (or something similar) to remap right Alt to Backspace?
0
votes
0answers
20 views

Low level keyboard mapping

I've got a keyboard that comes with some special key (keycode 94) at the place usually occupied by left alt. How do I map the special key to Alt properly? I tried to use xmodmap -e "keycode 94 = ...
1
vote
2answers
57 views

ibus override my xmodmap

I use xmodmap to swith Ctrl and Alt keys: ~ $> cat .Xmodmap ! ! based on: http://www.emacswiki.org/emacs/SwapControlAltAndCapsLock#toc8 ! ...
1
vote
1answer
83 views

Applying changes made with xmodmap

I'm trying to switch the Ctrl and Command keys using xmodmap, but even though the output of xmodmap -pke shows that the key codes were changed, the keys still perform the original function. This is ...
1
vote
0answers
32 views

Reverse Scrolling with xkb

Currently I'm using Xmodmap to reverse scrolling direction: pointer = 1 2 3 5 4 7 6 8 9 10 11 12 What is the equivalent way to do this with xkb? (or is this possible at all?) I'm evaluating KF5 and ...
7
votes
1answer
223 views

How can I remove a single temporary key mapping without resetting the entire keymap?

So I saw this question the other day. The user's K key was broken and they wanted to map it to Right-Shift. A good answer popped up and I thought I'd test it to see if it worked. I ran: xmodmap -e ...
0
votes
1answer
69 views

remapping k to the right shift button

I have been looking on askubuntu for help, but couldn't find the help I needed, so now I just ask. My k key doesn't work, when pressed, and since its a older laptop, i just wish to remap the k key ...
0
votes
0answers
68 views

Issues with xmodmap, alt+shift or alt+control viewed as hyper?

I have a file, .xmodmap, that looks like this : clear Control clear mod4 clear mod1 keycode 64 = Control_L keycode 37 = Control_L keycode 133 = Alt_L keycode 108 = Super_R keycode 134 = Alt_R add ...
2
votes
1answer
687 views

Xmodmap remapping modifiers not working?

I am using a new keyboard, and trying to set it up to mimic the keyboard on my laptop. I'm using xmodmap on Ubuntu 14.04, and can't get it to work. I cleared the modifier keys like so : xmodmap -e ...
2
votes
0answers
119 views

Howto to set AltGr key with xmodmap

I use a us-intl with "AltGr dead keys" layout and the option to switch Alt and Win key. Nice, but my AltGr does not work. The key I want to use for AltGr has keycode 134 (found out using xev). So I ...
0
votes
0answers
30 views

Xmodmap resets when chancing window

Allways when chancing active window, my xmodmap-bindings reset. I've removed keyboard layout switcher but it won't help. How can I make them stay? Using Ubuntu 13.10.
1
vote
2answers
655 views

Trying to map <Ctrl>+<hjkl> to <Left Down Up Right> globally (Vim-like arrow keys) with xmodmap

I am trying to map Ctrl+H,J,K,L to arrow keys Left,Down,Up,Right, respectively, on Ubuntu OS (globally, not inside Vim). I've attempted the solution posted here, but the modifier commands are not ...
2
votes
1answer
335 views

Using Xmodmap, my shift lock now acts as both a shift lock and a compose key. I just want it to work as a compose key. What can I do?

I have two Xmodmap files. First one: keycode 8 = keycode 9 = Escape NoSymbol Escape keycode 10 = ampersand 1 ampersand 1 bar exclamdown bar keycode 11 = eacute 2 eacute 2 at oneeighth at ...
4
votes
1answer
381 views

Using setxkbmap for a simple remap (similar to xmodmap)

I've faced some issues after remapping keyboard with xmodmap: settings get reset randomly after 2-20 minutes after applying. Googled it but no help: something resets them, but all mentions apply to ...
0
votes
1answer
250 views

xmodmap pointer setting doesn't affect all applications

I have a laptop designed for windows 8 and running ubuntu 14.04. Because it is designed for windows 8, the touchpad is backwards. The scroll bars on the side and top are reversed so that it feels like ...
0
votes
0answers
71 views

Xmodmap conflicting with Xubuntu shortcuts

In Xunbuntu 14.04, xfwm is responsible for window management shortcuts like Alt+F4, Alt+TAB, etc. Now, create a .Xmodmapfile in your home folder, containing for example keycode 77 = NoSymbol ...
0
votes
0answers
13 views

how to set Tab to produce four spaces in Ubuntu

I would like to be able to run a command which makes the Tab key produce four spaces and to be able to run another command to reinstate the previous behaviour. I am aware that keys can be remapped ...
1
vote
0answers
281 views

How to use SLEEP, WAKE and POWER keys as media keys (VolumeUp , Volume Down etc) in Ubuntu 14.04?

I have an usb keyboard with SLEEP, WAKE and POWER keys but no media keys. In Ubuntu 12.04 i used xmodmap to remap this keys as XF86AudioMute, XF86AudioLowerVolume and XF86AudioRaiseVolume. This is how ...
1
vote
3answers
377 views

How to map <modifier> + hjkl to arrow key functionality?

I've been getting so used to vim's hjkl for moving around recently, and find myself wanting to use them right after alt tabbing out of vim. What would be the best way to map fn + h/j/k/l to ...
1
vote
1answer
135 views

Left Alt combinations with xmodmap

How I can change Alt+symbol to some other ? For example, I changed semi-colon like this: keycode 47 = BackSpace colon semicolon colon semicolon colon But I want Alt+; to produce ;.
0
votes
2answers
4k views

How to run command at startup? [duplicate]

The Return key in my keyboard is broken, so I have chosen to make my PgDn key to act like the Return key. Now I learned how to do this using 'xmodmap'. The command I have to run is: xmodmap -e ...
0
votes
0answers
63 views

xmodmap Alt+h == Left key

I'm new to ubuntu, on win32 I use AutoHotKey to do the key map, how to do this on ubuntu? I tried the // ~/.xmodmap keysym Alt_L = Mode_switch keysym h = h H Left keysym j = j J Down keysym k = k K ...
1
vote
0answers
378 views

enable special keys in lubuntu 14.04

I've done a lot of reading and cannot find a simple answer to what seems like it should be a simple question. How do I define the functions of the extra keys such as the "my computer" and "web ...
5
votes
1answer
386 views

Unable to get xmodmap working after suspend

I am using Ubuntu 14.04. I have a custom Xmodmap keyboard layout. However, when I resume after suspend, the layout is gone. I have tried all things which were mentioned in the answers to this ...
1
vote
0answers
21 views

xmodmap loose custom settinfs in some cases

All. I'm remap Cmd key behaviour to act like a Ctrl with xmodmap. All works fine, but in some cases xmodmap loose my custom settings and return to defaults. I.e. when i'm pressing Ctrl-Space (change ...
3
votes
1answer
429 views

Assigning Print button to screenshot not working after upgrade from 13.10 to 14.04

When I pressed the Print button, nothing happened. Checked in System Settings, the button is assigned to screenshot. If I assign ANY other button except Print, it works normally. Is this a known ...
0
votes
0answers
17 views

Can I swap Control and Super keys using xmodmap? [duplicate]

I am trying to swap the function of CTRL left and Super Left so that I can summon lenses usng ctrl, and copy/paste using Super. I created a .xmodmap file with the following content: remove mod4 = ...
0
votes
0answers
45 views

How to xmodmap Super_L+TAB to Alt+TAB

I used xmodmap to use my Super+L key as a ctrl key, but I'd like to use Super+L+Tab as Alt+tab, as I don't like to switch in behaviour between my MacBook and Ubuntu Desktop. Is there any way of ...
1
vote
1answer
877 views

Left Alt key should work as right Alt key (Alt Gr)

I'm using a German Apple keyboard on my Ubuntu 12.04 machine. Under Mac OS X the left Alt key has the same behavior as the right Alt key (I think the right Alt key acts a Alt Gr). I don't know what I ...
0
votes
0answers
80 views

Remap Windows key

I have a hardware "Windows" button on the front of my Lenovo Ideapad Yoga 13 that maps to the "Windows" key. According to xev, the keycode passed by the "Windows" key is the same that is passed by the ...
0
votes
0answers
19 views

Problems remapping right shift in 12.10

When I use xmodmap -e "keycode 62 = Alt_L" the command succeeds, but the shift key remains a shift key. When I attempt to map Alt_L to other keys, the command succeeds and the key is successfully ...
0
votes
0answers
108 views

Enter key not working after xmodmap change

Mistook key number for another key, now i cant get it back to working. tried: xmodmap -e "keycode 36 = Return NoSymbol Return" xmodmap -e "keycode 36 = Return" xmodmap -e "keycode 36 = Enter NoSymbol ...
1
vote
0answers
360 views

Overload capslock with esc and ctrl using xcape

I want to: Turn off capslock when hitting the capslock key Escape when hitting the capslock key Behave like ctrl when pressing down the capslock key What I have in my ~/.Xmodmap: !Set Capslock to ...
1
vote
0answers
177 views

How do I create curly brackets using Shift + Alt

I'm used to writing curly brackets using Left Shift + Left Alt + 7 or 0. As of right now I can only do them using the Right Alt + 7 or 0. How do I configure my Left Alt + Left Shift to behave as ...
1
vote
0answers
137 views

Remapping Menu key to Delete on Xubuntu

I would like to bind my Menu key (the one that brings up the context menu at your cursor location) to my Delete key for convenience. Preferably, I'd like to do this through xkboptions in ...
4
votes
1answer
114 views

How to remap pgup and pgdown to home and end Thinkpad X1 Carbon Ubuntu 13.10 Gnome-shell

I have used the xmodmap technique, I even made a file called .Xmodmap and put it in the start up commands in the gnome tweak tool, but there are still occasions where the buttons don't perform what I ...
3
votes
0answers
303 views

How to remap key with shift and alt modifier using xmodmap?

I want to put have the following behaviour for key with code 94: 1) by default it is '<' 2) with shift it is '>' 3) with alt it is '|' I only managed to get the default and shift behaviour by ...
3
votes
0answers
150 views

Remap keyboard using xmodmap but when press to change keyboard layout all settings are reset to default

I tried to map key following this guide How do I remap certain keys?. It's work for me. but one problem that i found is when i change keyboard layout (alt+shift) all keys will be reset to default. ...
1
vote
0answers
211 views

Ubuntu 13.10 resets key map loaded with xmodmap when switching keyboard layout

I'm trying to switch left Ctrl key with CapsLock. I took theese lines from manual to xmodmap: remove Lock = Caps_Lock remove Control = Control_L keysym Control_L = Caps_Lock keysym Caps_Lock = ...
1
vote
1answer
141 views

How to reconfigure keyboard (W and P not functioning correctly) [duplicate]

I was reluctant in asking this question but everything I've researched has led me to a dead end. Shift + w and Shift + p aren't working correctly. So I'm unable to use W and P unless I use the caps ...
2
votes
0answers
69 views

Function keys on the apply keyboard with no root

There is a well-known method on how to make function keys work on Apple keyboards in Ubuntu: echo 2 | sudo tee /sys/module/hid_apple/parameters/fnmode However, is there a way to do that with no root? ...
5
votes
2answers
882 views

How do you enable tap-to-click via command line, with `xmodmap`?

You can use this to reverse scroll direction (natural scroll): xmodmap -e "pointer = 1 2 3 5 4 7 6 8 9 10 11 12" You can also set it back again with xmodmap -e "pointer = 1 2 3 4 5 7 6 8 9 10 11 ...
0
votes
1answer
179 views

Running Key Remap Script at Startup

I'm trying to re-map my left Alt key to the Alt Gr and Alt Gr to Left Alt. So far I've been able to do it in terminal, but it never runs it on start up. I've read multiple AskUbuntu questions, but ...
0
votes
2answers
828 views

How can I set a certain keycode to a key and bind it to the right action?

I have a laptop with Swedish keyboard layout, everything works well with the keyboard. Due to injuries I am using an external ergonomic USB keyboard, this is where I am experiencing difficulties. The ...