9 years ago
When you’re using Linux with the GNOME UI, don’t you hate it when you have to go into the terminal or add the force quit button to the panel just so you can exit an unresponsive program? In this very quick tutorial, I’m going to show you how you can assign the force quit command to a key, so when a program stops working, you can close it with the press of a button and a click of the mouse.
First, open up your GNOME menu and go to System > Preferences> Keyboard Shortcuts.
Second, click “Add” and a window should come up with 2 text boxes, labeled “Name” and “Command.” In Name, type “Force Quit” and in the Command box, type “xkill” and press Apply.
Scroll down to Custom Shortcuts in the Keyboard Shortcuts window and you’ll see Force Quit on the left side and Disabled on the right side. Click on Disabled once, and press a combination of keys on your keyboard. I used the Super (Windows logo) key and Escape, but you can use whatever you want, just as long as it doesn’t conflict any of your other shortcuts. Now Disabled will be changed to whatever keys you pressed.
Close out of the Keyboard Shortcuts window and you’re done! When ever you press your key combination, your cursor will change to crosshairs, or a skull and bones, or at least something different than just the arrow. Whatever window you click on will be forced to close, killing all of it’s processes.
If you find yourself to have accidentally pressed your force quit keys, then just right click and it’ll close out of the force quit mode.
Works perfectly 6 years later in Mint Cinnamon 17.3
It’s the easiest way to call xkill in my eyes, hence it’s the most useful too.
I knew about xkill but never thought of using it this way great Idea!!!
good use the utility.
i have lisa but the force quit button doesn`t work. also if i press ALT+F2, not working. why?
@jkotesh, right click.
how to cancel the command once the combination is pressed, as this one is really useful but at times it annoys when entered the combinattion and there is nothing that i can exit,,,which irritates me, so i click on taskbar,, which comes back after restart,,, and doesn't hurt me,,
Useful tool, easy to follow directions. Well done!
Thanks. I had previously added hotkeys to the "Switch to workplace" options (8 workplaces) but I didn't know about xkill. Nice keyboard alternative to the "Force quit" button you can add to the panel.
Great tool. Many thanks.
Awesome! Thanks for that.
Nice, can be handy
thanks, alternative click right in panel -> click add to panel -> search & click "force quit" -> click add & close
A lot better than having to reboot.
A useful tip. - Thank you! 8~)
Thanks, user from Ubuntu.
ctrl + alt + esc should also work in KDE
xkill has a default keyboard shortcut in mint xfce: ctrl + alt + esc
I've been using gnome-do/Alt-F2 + xkill to do this for forever, but I like this way alot better.
Back in days when I used Mandrake 9.1, I used this feature. But in the last 4-5 years, it has disappeared! Thanks for the tutorial!
Nice tutorial. Thanks for that!
You cancel it by right clicking, like it says in the last line of the tutorial.
The only problem I see with this is the fact that when you press the combination, you can't cancel the command. You must to click in something to kill it; if you press ESC or the combination again, the system still asks for something to kill.
That doesnt means that this is bad or useless; I've already added it to the shortcuts (in my case with Super+K) in case of emergency.
Yes, but why even take up space on the panel with a force quit button?
You don't have to go into the terminal to add a force quit button to the panel. ;) Good tip.
I'm happy to help :)
Excellent. Thank you.
I've been using Gnome for a couple of years now and it never occurred to me that I could do this. Great tip, thanks.
Because I'm new to linux - this tutorial was helpful. Thank you.