delete key on linux does not work
Considering that the output of showkey -s
is as expected, and yet xev
doesn't show any keypress, one possibility is that the key has been defined as a shortcut in your window manager/desktop environment.
Does the problem arise if you log in as a different user? If not, you've probably inadvertently defined Delete as a shortcut for something that doesn't have an obvious effect.
Related videos on Youtube
Gauthier
Updated on September 17, 2022Comments
-
Gauthier over 1 year
My delete key does not work in ubuntu, it does nothing. I understand that this is a common problem, but I could not solve it with the information I found elsewhere.
I ran xev. Pressing the 'a' key gives:
KeyRelease event, serial 30, synthetic NO, window 0x2c00001, root 0x1a6, subw 0x0, time 7255643, (-113,-107), root:(425,300), state 0x2010, keycode 38 (keysym 0x61, a), same_screen YES, XLookupString gives 1 bytes: (61) "a" XFilterEvent returns: False
Pressing 'Delete' gives:
FocusOut event, serial 30, synthetic NO, window 0x2c00001, mode NotifyGrab, detail NotifyAncestor FocusIn event, serial 30, synthetic NO, window 0x2c00001, mode NotifyUngrab, detail NotifyAncestor KeymapNotify event, serial 30, synthetic NO, window 0x0, keys: 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
From there I don't know what to do. Help?
--- Edit ---
More details: Ubuntu Hardy, studio edition.
The keyboard is a Logitech UltraX (967498), wireless. I couldn't find it on logitech's page, but here it is: UltraX
--- Edit 2 ---
Pressing Delete in a virtual terminal after
showkey -s
:0xe0 0x53 0xe0 0xd3
After
showkey -k
:0x6f 0xef
(First rows at press down, second row at release).
--- Edit 3 ---
gauthier@ubuntu:~$ xmodmap -pke | grep -i delete keycode 91 = KP_Delete KP_Decimal KP_Delete KP_Separator keycode 107 = Delete gauthier@ubuntu:~$ sudo dumpkeys | grep -i remove [sudo] password for gauthier: keycode 111 = Remove string Remove = "\033[3~" gauthier@ubuntu:~$
0x6f is 111, but I can't see any other relations with what I wrote earlier.
--- EDIT 4 ---
Interesting,
Ctrl-v
thendelete
makes the cursor flash once, then nothing is displayed. PressingEnter
after that gives^M
then nothing (not even a new prompt).Enter
once more yields: command not found
.I'm not sure about gnome, I'm on ubuntu studio, Hardy.
-
bbaja42 about 14 yearshow about more details? like keyboard type, linux distribution...
-
Dennis Williamson about 14 yearsWhat do
showkey -s
andshowkey -k
show when run from a virtual terminal? -
Dennis Williamson about 14 yearsWhat does
xmodmap -pke | grep -i delete
show when run from a terminal in the X window system (gnome-terminal, xterm, or equivalent)? -
mctylr about 14 yearsVerify that you have the correct keyboard layout selected. Go to
System -> Preferences -> Keyboard
, select theLayout
options tab. Also check to see if there is a Logitech Ultra-X Cordless / regular keyboard model available. They are listed in Ubuntu Karmic Koala (9.10). -
Gauthier about 14 years@mctylr: thanks, I had not my keyboard model selected. Selecting it did not solve the problem though (I don't think I need a restart for that to take effect, right?).
-
Dennis Williamson about 14 yearsAll the results are correct except for
xev
. If you pressCtrl-v
thenDelete
at a shell prompt does it show^[[3~
? Are you running Gnome? On my system,xev
shows similar results (to yours for Delete) when I press a multimedia key. Have a look in keyboard preferences and keyboard shortcuts to see if anything's not right. And I think you probably do need to do a restart (or at least a log out/in).
-
-
eugenevd over 7 yearsYep, in Ubuntu's "Keyboard-Shortcuts" setup, I had 'Delete' defined where it shouldn't be. My only guess could be that I had another key defined, and pressed 'delete' thinking it would remove the setting, but actually setting it to 'Delete', THANKS!