Desktop application developers are free to choose which keyboard shortcuts they want to support. On Windows the convention is pretty strong:
- Alt-F4 closes most applications
- Ctrl-F4 closes most major sub-windows
- Esc dismisses most dialogue boxes.
On Linux there hasn't been quite so much convergence, but the following are common:
- Ctrl-q closes most applications
- Ctrl-w closes most major sub-windows
- Esc dismisses most dialogue boxes.
Unfortunately many applications have chosen to go their own way, either by using the Windows convention or by just doing their own thing:
- Alt-F4 closes Chromium
- Ctrl-Shift-q closes GNOME Shell
- Alt-f x closes IDEA
To close sub-windows and dialogue boxes all bets are off. I've seen all of these in use:
- Esc
- Ctrl-F4
- Ctrl-w
Some applications don't even have shortcuts for closing some windows (or at least none that I have been able to find).
Window managers have the power to override any of these, and can therefore be very helpful for keyboard users. Awesome WM is very keyboard-friendly, but are there global shortcuts to close any window and/or application in Awesome WM, and if not, how do I set them up?