On 9/4/07, Nick Treleaven nick.treleaven@btinternet.com wrote:
On 09/04/2007 12:57:45 AM, John Gabriele wrote:
[...] Geany is a powerful GUI programmer's editor. As such, we should be taking advantage of the key bindings available. This means using Ctrl-Alt ... as well as Shift-Alt.
I agree. I think you summed up everything well, thanks John.
:)
[...] Now, Geany is also using Alt keys to deal with gui elements (including the Alt-1 and Alt-0 combos), and the Shift key to deal with selecting text (holding it down while navigating). I propose then, that Shift-Alt be specifically used for commands that either have to do with the GUI, or else with selecting text. That is, continue to use Shift-Alt-{W,L,P} to select word, line, and paragraph, and add to this list:
- Shift-Alt-J to vertically center ("jump") the window view on the
current line (was Shift-Ctrl-L)
Or maybe Shift-Alt-V for View current line?
Yeah, that sounds good too. Either way.
- Shift-Alt-{Up,Down} to scroll the window up- and down-by-line.
I think we can use Alt-{Up,Down} for this. We can use both Alt-[^a-z] and Alt-Shift-{x} for GUI-related commands.
Oh, right you are.
[...]
Finally then, this leaves us with the Ctrl-Alt modifier. I propose
this be used for how Shift-Alt has previously been used: for special, possibly-less-used or advanced features. This would include:
- Ctrl-Alt-D to insert the date
I guess that's less common, so maybe we could use that even though it won't work by default on Gnome.
And possibly these, having to do with changing case:
- Ctrl-Alt-U (think "all *U*pper or lowercase") to toggle selection
between all upper and lowercase.
Not sure about that. It might be best to use ctrl-u for toggle case, unless there's something better to use ctrl-u for.
- Ctrl-Alt-C ('c' for "capitalize") to make the current word start
with a capital letter and then move the cursor to the end of that word
- Ctrl-Alt-L ('l' for "lowercase") to make the current word start
with a lowercase letter and then move the cursor to the end of that word
Maybe - but can you explain what situations would you use that?
I've used these occasionally while re-writing plain text ... breaking long sentences in two, or gluing short ones together, or just editing something that's not capitalized correctly. It's not used all that often, but once in a while. Emacs has similar bindings: Alt-C, Alt-L, and Alt-U, where Alt-L makes the whole remainder of the word (noting cursor position) lowercase, then moves the cursor to the end of the word. Alt-U does likewise, but uppercase. Alt-C capitalizes the letter below the cursor, even mid-word (or in front of the cursor, if on whitespace). I haven't yet needed these commands when dealing with code though.
I hesitate to suggest using Ctrl-U, just because changing case does not seem like something that's needed terribly often, and also because Ctrl-Alt-U could possibly be used along with the Ctrl-Alt-{C,L}, keeping things more consistent (that is, all key combos dealing with case would be Ctrl-Alt keys).
Also, those Ctrl-foo keys are pretty valuable keyboard real estate. :) I keep feeling like you're going to find something really useful and common that you're going to want to use them for. For example, after loading a tags file, personally, I'd expect to use Ctrl-< to go to tag definition, and use Ctrl-> to go back to where I previously was, but seeing as how Enrico seems to often prefer using letters, I could see him wanting to use Ctrl-J to *j*ump to tag definition, and possibly Ctrl-U to go back *u*p the tag stack ...
One last problem is possible key combo collisions with desktop managers. Geany cannot possibly sidestep collisions with all desktops.
I think it's worth trying (in theory), especially for the most common desktops. E.g. we don't use Alt-F-key combos to avoid window manager conflicts. But it's probably OK for less common bindings.
<grumble> It'd be nice if Gnome used the super (a.k.a 'Windows' key) for things like show/lock desktop, but maybe they don't want to due to portability reasons. </grumble>
Seems like the Gnome keyboard shortcuts are a bit of a hodge podge of mostly Ctrl-Alt-foo and Alt-F_keys, with some Shift-Ctrl-Alt-keys sprinkled in for finger calisthenics. ;)
---John