« Typesetting astrology with LaT... | Home | Fun with text analysis »

Disabling Ctrl-Shift-Underscore font resize in Konsole

Sat 23 Oct 2010 by mskala Tags used: , ,

Why is it that all my KDE-related postings seem to be about disabling annoying user interface misfeatures?

Today's has to do with the Ctrl-Shift-Underscore (Ctrl-Shift-_) key combination. This is used for "undo" in EMACS-derived text editors, including JOE. In recent KDE versions, Konsole has started trapping this key combination for "reduce font size." So you're merrily editing away, you try to use the undo command, and suddenly your font has become smaller. To make matters worse, it is a known bug that the key combination Ctrl-Shift-+, which is supposed to be "enlarge font size," doesn't work. So not only can you not undo editing changes anymore, but you can't undo the font size change either. Solution below.

It turns out there are at least three places KDE-related keyboard shortcuts can be configured. The one that's relevant here is on the Konsole menu bar, under "Settings"->"Configure Shortcuts..."; that gives a scrolling list, of which the relevant item is "Shrink Font." This dialog box uses a weird nonstandard widget; click on an item, and it expands to a multi-line pop-up thing that still seems to be part of the list; to disable a shortcut, choose the "Custom" radio button and make sure the button next to it reads "none." If it's already set to a non-"none" custom setting, you can clear it with the delete icon. There is no clear way to close the pop-up thing, but it seems to save its value when you leave the dialog or choose a different item.

I took the opportunity to delete all the other Konsole-specific hot keys; I don't think I've ever used any of them on purpose, and things like Ctrl-Arrows to switch between tabs have occasionally given me unpleasant surprises when I hit them accidentally. Disabling just Ctrl-Shift-Underscore, though, will make my use of Konsole a lot pleasanter.

For reference, the other two places I'm aware of where keyboard shortcuts are configured: first, in Konsole, under "Configured Current Profile"->"Input" (these are different because they adjust the terminal emulation: key combinations configured here expand to escape sequences sent to the underlying application); and second, in "System Settings"->"Common Appearance and Behaviour"->"Shortcuts and Gestures." The "Shortcuts and Gestures" seem to be global to KDE applications, but many KDE applications (such as Konsole) do not actually use them.


So what redeeming features do you see which makes you stick with KDE in the first place? They installed ("upgraded to") KDE4 on my office computer, and I retained it for about two days out of inertia before changing to some more workable configuration (a bare-bones window manager lots of xterms, in my case). During the whole time, me and my office mates just kept laughing at it. Even the parts that aren't buggy seem designed by someone with very strange tastes.
Vilhelm S - 2010-10-23 12:07
Good question. At this point I think I may simply be a boiled frog. Each annoyance by itself, especially if I can fix it with some work, isn't enough to push me away from KDE, especially not stacked up against all the work associated with a new install, new applications, recreating custom work, and fixing whatever annoyances come with the new system. On the other hand, there certainly comes a time when it's appropriate to cut the losses; and GNOME, which really sucked last time I looked at it (but that was years and years ago) may well be a lot better now.

The day will probably come when I switch away from KDE; it hasn't yet, but it seems to be getting closer.
Matt - 2010-10-23 13:05
Why is the alternative to KDE GNOME? I still use fvwm (and vanilla xterms); it does little enough to avoid getting in my way. (As an added bonus it astonishes some of the interns at work that I insist on using a window manager that was first released when they were still in diapers)

Also, what exactly is the motivation for consoles/terminals having multiple tabs, when screen not only multiplexes the terminal, but also has nice detach/reattach features? (Though I imagine that you're stuck with these fancy-pants terminals because they have better font support, and you need the unicode)
kiwano - 2010-10-24 10:47
GNOME came to mind because it's KDE's biggest competitor, but you're right, there are many other choices available. Tabs on terminals, I guess, comes down to taste. I generally prefer using the mouse to switch between sessions rather than the keyboard. Maybe if I used screen for a while I would come to like it better. By the same token, why use any GUI at all; why not just stay in console all the time?
Matt - 2010-10-24 11:22
By the same token, why use any GUI at all; why not just stay in console all the time?

Porn and webcomics.
kiwano - 2010-10-24 11:28
Drat, I used q instead of i to mark the quoted text and it got stripped :P
kiwano - 2010-10-24 11:30
One reason to use a GUI: Muliple terminal emulators.

One reason to use tabs: Screen real estate.

One reason to use something other than fvwm: Session management.
def0 - 2010-10-24 15:10
I think kiwano's point, though, is that screen provides at least some support for all of those things, without needing a GUI. You don't really need one for porn or Web comics, either - there are Web browsers that will run in the Linux console via SVGALib.
Matt - 2010-10-24 17:15
Not only does screen provide all those things, but it does so better (IMNERHO) than multiple terminals in a tabbed console with session management. In particular, it doesn't waste screen real estate on a row of tabs to show you all the terminals you have open. Instead (by default), there's a hotkey sequence that will furnish you with a lightbar-selectable list of them, as well as hotkeys for the first 10 consoles (beyond that, you can always add more hotkeys, they're just not there by default), another pair of hotkeys for going up and down in the list, and one more hotkey for returning to the last console you were at.

Instead of having a session that is "remembered" when you shut down, with screen you detach the session, and it keeps running as a background process until you reattach to it (most likely from an entirely different terminal--which is really handy if you're also running sshd on your machine and would like to pick up your work remotely). The detached session vs. a remembered session is also vastly more useful for e.g. idling on irc, or listening to music with a command-line media player (since you don't have to stop the music in order to detach and log out).
kiwano - 2010-10-24 20:36
It is true that screen provides something similar to session management, but that relies on the host running all the time. I will not dispute that it has its uses, but it is not the same thing.

My konsole doesn't waste screen real estate, btw, it has its tabs set invisible and the border turned off. I get higher resolution with X than in the framebuffer. Using a virtual console would be more of a waste of screen real estate by comparison. I also like to have a small notification area to the side.

Granted, KDE is overkill if all you need are mutt, links, slrn, irrssi and centerim, and I would have switched to lxde by now if it wasn't for kmail. (I like mutt, but I find kmail to be more convenient. Just my opinion, YMMV.) Since I have to have all of kdelibs loaded anyway, I might as well use them.

BTW, enlarge font size works for me, without the shift key. Same with scale down, it doesn't need a shift.
def0 - 2010-10-25 03:31
Both enlarge and shrink font work after you "Settings"->"Configure Shortcuts" and give new bindings by e.g. clicking on the crescent wrench for Shrink and Enlarge Font (which should be type face). The default Shrink, Ctrl Shift '_', collides with most people's undo in emacs and the default Enlarge, Ctrl Shift ' ', is unachievable on US keyboards. Pretty much any of the default shortcut bindings involving shift and an already shifted character are broken. For example, Split View, which default to Ctrl Shift '(' and Ctrl Shift ')', will work if you manually re-bind them to the obvious key sequence.
Eric Prud'hommeaux - 2011-02-04 13:24

(optional field)
(optional field)
Answer "bonobo" here to fight spam. ここに「bonobo」を答えてください。SPAMを退治しましょう!
I reserve the right to delete or edit comments in any way and for any reason. New comments are held for a period of time before being shown to other users.