I'm using gtk, and all the function names have many underscores. It gets annoying to type things like set_from_file
and on_button_clicked
, etc. Do you have any tips on how to type these more effectively?
-
7For the fastest underscore possible, you could swap the space bar and the underscore keys.– NosrednaAug 6, 2009 at 20:32
-
6Or remap shift+space to _ ?– sep332Aug 6, 2009 at 20:34
-
1This is a legitimate question people. I know vote to close is exciting but try to calm those itchy fingers. :P If this gets closed I'll vote to reopen.– Spencer RuportAug 6, 2009 at 20:41
-
3If only so much attention were spent on my more legit questions about GTK.– ClaudiuAug 6, 2009 at 20:46
-
1well it caused me to get an account here, anyway.– ClaudiuAug 6, 2009 at 21:08
13 Answers
Use an editor with auto-complete functionality?
-
1I agree. A decent editor will auto-complete for you.– Brian NealAug 6, 2009 at 20:43
-
most sane, probably. i'd first have to find a good one for python (IDLE works, but it is shoddy, and it only works if you run your code in it), and then get used to it. but could be worth it!– ClaudiuAug 6, 2009 at 20:45
-
Hmm, I think swapping the underscore and spacebar keys is more efficient. :) Aug 6, 2009 at 20:49
-
-
Using a programmable foot pedal could help you out a bit.
-
2You combine the chance to become a professional gtk programmer with the chance to become a death metal drummer. Aug 6, 2009 at 22:46
-
-
Not a proper answer, but it sure made me laugh :] There was a 'computer stupidity' rinkworks.com/stupid/cs_mice.shtml about mouse/foot pedal (beware, very addictive website). Aug 13, 2009 at 6:30
What's wrong with holding shift with your left hand and using your pinky from your right hand? That's what I do -- it's probably the fastest once you get used to touch typing it.
-
hmmmm... i'm using my ring finger to hit it, atm. i'll try adjusting to using a pinky and - starting now - I'll see - just = how_ ti_ goes_. i might like this.– ClaudiuAug 6, 2009 at 23:30
-
1You do have to pivot the hand a bit but you can pivot it right back __ _ __ __ __ weeeeee Aug 7, 2009 at 0:28
remap - key to _ so you don't have to relearn key location but can save time not hitting shift.
Remap a useless key to _
. The most useless keys on the keyboard are insert
and caps lock
. They are close to the useful keyfield, so you might actually gain speed once you've learned the position of your new _
key.
Backstory: I realized that I never used insert
or caps lock
. But every so often I would hit one by accident. These keys are toggles, which affect every subsequent keystroke. Whenever I realized that I hit insert
, I had to turn it off and then recover the text that I overtyped. Whenever I realized that I hit caps lock
, I had to turn it off and then retype the text that I entered in "oppositecase". I found this so unacceptably frustrating (unfuriating) that I pried insert
and caps lock
off every keyboard that I use. It's much better that way. (I can toggle either one, when rarely needed, by reaching into the hole with the back of a pen.) (If you remap one of these keys, you can remap some other combination to replace it, or use "Onscreen keyboard".)
Try using Autohotkey
Include a configuration like:
a::_
in this case, when you type "a", it will put a "_"
-
I'd give the example using another key...– samuelcarrijoAug 6, 2009 at 20:37
-
19Of course, it's your choice wh_t you want to repl_ce– mkatoAug 6, 2009 at 20:38
-
The ` is a good choice. I never use that thing. And it's pretty easy to hit. Makes your left pinky super-strong.– NosrednaAug 6, 2009 at 21:17
-
- Turn on capslock.
- Place something heavy on the shift key.
- Everything you type will be in lowercase, but if you type a - it will be a _
Alternate Method:
Use an autohotkey script
#IfWinActive ahk_class gtk ; or whatever the title for the window is
;Choose one of the below
-::Send _ ; replace -'s with _'s
+space::Send _ ; replace shift+space with _'s
f3::Send _ ; replace F3 with _'s. You get the idea
-
3
Hitting the underscore key isn't much harder than hitting any upper case letter, since it's just a key combined with Shift.
You can always copy it to the clipboard and type Control-V if your fingers have a problem hitting the numeric row consistently.
-
2i actually often CTRL+C annoying letters when i have to type them a lot in a particular section of code– ClaudiuAug 6, 2009 at 20:44
-
Except that it's keyboard position puts it out of reach of all but those with abnormally long and dextrous pinkies, which means your fingers have to leave the home keys. That significantly reduces typing speed. It makes a difference in any application of real size.– Russell SteenAug 6, 2009 at 20:44
Add a second keyboard. (You can have up to [at least 14] USB keyboards.) You could use the second keyboard directly -- but it merely types the same characters. You could tape down Shift
on the second keyboard -- but you still have to find its -
/_
key every time; no time saved. With more work, you can remap keys on the extra keyboard. For example: place the second keyboard above the first one and make its spacebar
type _
, hitting the other spacebar might actually be faster than typing Shift+-
/_
. (And you have ~94 more keys that you can relabel for other added functions.) Recoding the second keyboard has been done using LuaMacros: https://www.diyphotography.net/create-entire-new-keyboard-shortcodes-hack/
Change to hungarian keyboard layout. It will be easier to write underscore as the dash will be next to the shift key.
-
Your answer could be improved with additional supporting information. Please edit to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers in the help center.– Community BotMay 6, 2022 at 21:36
-
It seems easier to press two keys with one finger of the left and one finger of the right hand instead of two fingers of the left hand.– JuergenMar 7 at 12:16