Questions tagged [xmodmap]

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.

Filter by
Sorted by
Tagged with
0
votes
0answers
21 views

Disable keyboard key Ubuntu 18

My laptop's Page Up was not working properly,it was getting pressed automatically hence causing problem[Even while booting].So I decided to disable it and found this code to disable a key: xmodmap -e '...
0
votes
0answers
24 views

Remap Capslock, but keep its function with Ctrl + Capslock

I want to remap my Capslock key to function as left mouse click, Alt+Capslock to function as right mouse click, and Ctrl+Capslock to function as Capslock. I've been using this in Windows with ...
0
votes
0answers
35 views

xmodmap: changing language reset caps/tab swapping

my tab key is broken and i want to swap/remap caps with tab. i follow instruction from How to swap/remap the CAPS LOCK key with Tab key? and write clear Lock keycode 66 = Tab ISO_Left_Tab Tab ...
1
vote
0answers
19 views

Xmodmap key mappings reverting periodically [duplicate]

Possible duplicate of this xmodmap reverting periodically, but since there is no life in there and the "answer field" is just for answers, I have to create a new question. Six years later on Ubuntu 18....
1
vote
0answers
58 views

Running xmodmap when new keyboard is plugged in

When I plug an external keyboard into my laptop (which runs Xubuntu 18.04), I have to run xmodmap ~/.Xmodmap to apply the changes to the second keyboard also. This bothers me. Here is my .Xmodmap: ! ...
2
votes
0answers
47 views

How to get a description of the meaning of the modifier keys (modN) of xmodmap?

I've read the documentation below on xmodmap (and man xmodmap): https://wiki.archlinux.org/index.php/xmodmap#Keymap_table The documentation decribes modifier keys, and how to display the modifier ...
0
votes
0answers
21 views

xmodmap Help with configuring Alt key to work in other programs with i3

I've modified xmodmap such that mod1 only contains Alt_L and Meta_L and I've added Alt_R to mod3. I want to use my right alt key in programs such as Google Chrome for shortcuts, however it doesn't ...
0
votes
0answers
119 views

Caps lock to Escape/Control and Control + hjkl for Arrow keys

I want the following: Pressing and releasing Caps lock should fire a Escape key event. Holding Caps lock and pressing some additional key should fire a Control + 'additional key' event. Additionally I ...
0
votes
0answers
19 views

make different xmodmap configuration for different (Physical) keyboard

my laptop (thinkpad x230) have an irritating layout (for example i hit the PageUp/PageDown key accidentally instead of Left/Right, and the PrintScreen key in the bottom). I have overcome partially ...
6
votes
2answers
1k views

File ~/.Xmodmap is not sourced on startup in 18.04

I have a custom key mapping in the file ~/.Xmodmap which can be activated by running xmodmap ~/.Xmodmap. However, I want this to happen automatically when I login. I have tried the following without ...
0
votes
0answers
97 views

Map key to a script in Ubuntu 18.04.1

I'm on Ubuntu 18.04.1 Bionic Beaver using an HP Pavilion laptop. My laptop has a key for toggling airplane mode. Using xev, I found out that it has keycode 255. I've saved the following code at /bin/...
1
vote
0answers
71 views

How to map caps + h,j,k,l to arrows with russian lang?

I have xmodmap config: keycode 66 = Mode_switch keysym h = h H Left keysym l = l L Right keysym k = k K Up keysym j = j J Down keysym u = u U Prior keysym i = i I Home keysym o = o O End keysym p = ...
1
vote
1answer
336 views

How to map a key to work like mouse button including its modifiers?

With xmodmap I can map F2 to work as left click: xmodmap -e "keycode 68 = Pointer_Button1" However, when I use shift+F2 to simulate shift left-click to select files on nautilus for example, it doesn'...
0
votes
2answers
400 views

Why does loading my own ~/.Xmodmap freeze my desktop on 18.04?

I created a modified Xmodmap file in my home directory. When I try to load it with. xmodmap ~/.Xmodmap or on startup, it freezes my desktop for several minutes. It wasn't the case on my Xenial ...
1
vote
1answer
131 views

set CapsLock as Esc, and Ctrl when pressed in combination

I would like to set CapsLock to Esc when pressed alone, but Ctrl when pressed in combination with another key. This is possible in karabiner-Elements for MacOS, but i cant find an easy way to do it ...
2
votes
0answers
224 views

upgrade to 18.04, xmodmap settings reverting periodically and video performance

I have a custom xmodmap config that is called on startup by running xmodmap ~/.xmodmap however it seems every hour or so these settings seem to be reverted to default. I then have to run that command ...
0
votes
1answer
130 views

How remap keyboard on “asciitilde layout mode”

I'm trying currently to use the xmodmap -e function in order to remap my keyboard. I want to replace the twosuperior key with greater and less depend of the asciitilde mode being activated. I talk ...
0
votes
1answer
184 views

How do I “shift” Caps Lock, Shift and Control?

Default key location is +-----------+ | Caps Lock | +-----------+ | L Shift | +-----------+ | L Control | +-----------+ I'd like to try moving the most usually useless key to the farthest position,...
1
vote
1answer
279 views

How to set Level3_Shift to Caps Lock AND Compose to Caps Lock+Ctrl in XFCE?

I switched from SUSE recently, which uses KDE as a default desktop environment. In KDE, it is possible to archieve such a setup with GUI options, but not in XFCE. I've tried set up the ~/.Xmodmap ...
0
votes
0answers
95 views

Change keyboard layout with xmodmap or xbidnkeys

I need to use Numlock to switch between keyboard layouts. Any way to achieve this with Xmodmap or Xbindkeys? I tried setxkbmap -layout but it doesn't seem to provide a "switch between" functionality....
2
votes
0answers
429 views

How can we make setxkbmap and xmodmap work together?

On Lubuntu 18.04, I found the following commands will cancel each other $ setxkbmap -option keypad:pointerkeys $ xmodmap ~/.Xmodmap I would like to be able to fully control my cursor using ...
3
votes
1answer
150 views

Using CapsLocks as backspace

I want to use CapsLock as Backspace. I tried commands below and it works. setxkbmap -option caps:backspace xmodmap -e "clear Lock" But after restarting the computer, I need to type that commands ...
0
votes
0answers
365 views

Why doesn't my substitution of the super key for the Alt_L key not work in all the cases?

On Thinkpad T400, my left Alt key has stopped working. Since I have never used the super key in LXDE in Ubuntu 16.04, I did the following to modify the super key as if it were the left Alt key. First ...
3
votes
1answer
916 views

How to map [Alt] + [hjkl] keys to arrow keys?

I know how to map [AltGr] + [h|j|k|l] keys to arrow keys, like: [AltGr]+[h] ... [Left] [AltGr]+[j] ... [Down] [AltGr]+[k] ... [Up] [AltGr]+[l] ... [Right] [AltGr]+[ö] ... [Home] [AltGr]+[...
1
vote
0answers
28 views

Remap right ctrl to behave like left ctrl? (currently typing stuff like æ ß ¶)

As explained in the title my right control key is behaving oddly. It types characters like æ ß ŋ. I'd like it to simply toggle the control mode, like the left one. I gave xmodmap a shot using the ...
2
votes
1answer
512 views

Remap keys via xmodmap no longer works

I recently switched to Ubuntu 17.10 from Ubuntu 16.04. So far I used xmodmap to remove Caps_Lock and replace it with the backslash-symbol. This doesn't seem to work under 17.10 (maybe because ...
1
vote
1answer
1k views

How to use Mode_switch and xmodmap in current Ubuntu versions?

For years I used the following ~/.Xmodmap file to get german umlauts quickly, e.g. when I press the ALT_R + a I get ä. A nice shortcut compared to using the compose key: keycode 108 = Mode_switch ...
0
votes
1answer
709 views

Disabling numlock in session startup does not work

I am trying to disable my numlock key using the following command numlockx off && xmodmap -e "keycode 77 = """ It works so I wanted to this command to be run automatically at the start of ...
5
votes
1answer
635 views

How to map caps lock to arrow keys?

I am trying to map Caps Lock to the Down arrow key and Caps Lock with a shift modifier to the up arrow key. I've tried using xmodmap with the following input file: remove Lock = Caps_Lock keycode 66 ...
1
vote
0answers
183 views

right way to change xmodmap

My ~/.Xmodmap: remove mod1 = Alt_R add mod1 = Alt_R my ~/.profile: if [ -n "$BASH_VERSION" ]; then # include .bashrc if it exists if [ -f "$HOME/.bashrc" ]; then . "$HOME/.bashrc" fi ...
0
votes
1answer
142 views

Remaping Keys in Ubuntu 17

Please help me solve the following problem: I have a USB pedal that I want to function as Control key for my work. So far system identifies that this pedal is working as F2 key (I am using Ubuntu 17) ...
0
votes
0answers
46 views

'Alt' key (left) doesn't act as 'Space' - but CapsLock does? (using 'xkb')

The Space key on my keyboard has given up soI want to change 'Alt' (left) to 'Space' and 'CapsLock' to 'Alt'. In /usr/share/X11/xkb/symbols/pc I have changed the lines //key <CAPS> { [ ...
1
vote
1answer
661 views

Problems with xmodmap

I'm using Ubuntu 17.04. My backspace key is not working, so i used xmodmap to use the key "Home" as BackSpace. The problem is: after i use xmodmap, the key "Home" works as backspace only in FireFox. ...
3
votes
1answer
246 views

Can a mouse button be simulated by the keyboard without enabling numpad mouse emulation?

I'd like to be able to send middle mouse clicks from a keyboard key, for example, the right control key (keycode 105 on my keyboard). I can remap it using xmodmap like so: xmodmap -e "keycode 105 = ...
2
votes
0answers
108 views

Spotify not receiving remapped XF86Audio signals

I have a external USB Thinkpad keyboard I'm using with my Macbook Pro running Ubuntu 16. I'm trying to remap my Fn+F7, Fn+F8, and Fn+F9 keys to send the XF86AudioPrev, XF86AudioPlay, and XF86AudioNext ...
2
votes
2answers
1k views

How do I remap right ctrl to right alt?

I've got right alt remapped to ctrl (via remap right alt to behave as right ctrl), now I need my ctrl to be an alt. thanks for help with this
4
votes
0answers
692 views

How do I remap my CAPS Lock key to Hyper?

I tried this guy's solution, but I got the following error: X Error of failed request: BadValue (integer parameter out of range for operation) Major opcode of failed request: 118 (...
0
votes
0answers
27 views

how can I map altgr to _

I would like to map AlgGr to _. How can I do that? I have tried: keysym keycode 135 = _ in my xmodmap config But it is not working.
2
votes
1answer
115 views

Custom keymapping is lost after rebooting

I've wanted to remap my print key on my Thinkpad T460p because Lenovo decided it would be more useful than the context menu ("Menu" which is basically the right mouse-) button. It tried a solution ...
0
votes
1answer
822 views

How to remap XF86Sleep key to space---xmodmap, xkbcomp & udev fail

I'm running Ubuntu 16.04.1 LTS. I have a remote similar to one here (though mine is just called a "Vista MCE Remote Control") which acts like a keyboard, along with a real keyboard. I'm trying to ...
0
votes
1answer
328 views

Symbols ñ and Ñ do not appear despite keymap being set

I would like to write symbols ñ (ntilde) and Ñ (Ntilde) on a British keyboard using AltGr + n and AltGr + Shift + N. I have modified the keymap with xmodmap: $ xmodmap -e "keysym n = n N ntilde ...
2
votes
1answer
542 views

Ubuntu16.04/Gnome: How to swap AltGr and Ctrl right at keyboard?

My keyboard key of AltGr does not work anymore. I want rebind the functionality of AltGr to Ctrl_R. What is the easiest way to rebind AltGr to Ctrl_R? OS: Ubuntu 16.04 Desktop: Gnome 3 I tried to ...
5
votes
2answers
899 views

key-mapping - Workaround for keyboard with missing keys (16.04) [duplicate]

My thinkpad has got a few of its keys damaged, and I have been trying a permanent workaround for it. I tried using xmodmap which could set the F9 key to the letter "L" (small/caps based on whether or ...
0
votes
1answer
270 views

Xmodmap problem blocks connection via x2go

I have a remote server with x2go, in the remote .profile I call xmodmap. The call of xmodmap throws a warning: xmodmap: unable to open display '' This was until the upgrade to ubuntu 16.04.1 no ...
11
votes
2answers
3k views

Remap a key combination to another combination, e. g. Super+Ctrl+Shift+J -> Ctrl+Shift+Left

I want to implement an addition key layer, so that I can access non-alphanumeric keys without having to move my wrists. I've been using Autokey for this purpose, but the experience was unsatisfactory:...
1
vote
0answers
472 views

How to get backslash working on Ubuntu 16.04

I've been using .Xmodmap to configure my custom keymap. I know that Ubuntu uses xkb, but xkb seems to be very complex (inheritance and lots of files to configure something). I've managed to get all ...
1
vote
1answer
235 views

Use xkb to change Caps Lock to Alt+Tab

I'm trying to find a way to use xkb settings to change the behavior of my Caps Lock key (when no modifier keys are pressed) and remap it to to the Alt+Tab key combination instead. I am also open to ...
1
vote
1answer
92 views

Key disabled using xmodmap!

I disabled my key using xmodmap. How do I enable it? The command I executed was: `xmodmap -e 'keycode 16='` Any help will be appreciated.
0
votes
1answer
94 views

Issue with multiple keymaps when wake from suspend

Trying to xmodmap this file .Xmodmap upon resume. Tried how to execute a command after resume from suspend? by adding multiple key mappings using xmodmap -e without success (each time it would only ...
5
votes
0answers
418 views

How to remap a key that's not captured by xev?

I have a mechanical keyboard (by Duck) that includes a Fn key used with F10 to trigger Win-lock (disables Windows key so it doesn't bother when playing) and N-Key rollover. As a programmer, I don't ...