8
1
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?
8
1
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?
14
Use an editor with auto-complete functionality?
probs best answer, still have to find a good one for python though – Claudiu – 2010-08-09T20:22:08.280
1I agree. A decent editor will auto-complete for you. – None – 2009-08-06T20:43:48.123
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! – None – 2009-08-06T20:45:07.903
Hmm, I think swapping the underscore and spacebar keys is more efficient. :) – Sasha Chedygov – 2009-08-06T20:49:48.163
best advice, vs code has a great extension that let's you change case based on most common styles easily https://github.com/wmaurer/vscode-change-case
– greg – 2018-08-21T22:45:51.747Komodo edit 7 is pretty good with python! – Claudiu – 2012-09-10T03:38:27.357
11
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. – Stefano Borini – 2009-08-06T22:46:07.667
haha. that'd be awesome. – Claudiu – 2009-08-06T23:28:26.660
Not a proper answer, but it sure made me laugh :] There was a 'computer stupidity' http://www.rinkworks.com/stupid/cs_mice.shtml about mouse/foot pedal (beware, very addictive website).
– Kirill Strizhak – 2009-08-13T06:30:12.2704
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. – Claudiu – 2009-08-06T23:30:29.197
1You do have to pivot the hand a bit but you can pivot it right back __ _ __ __ __ weeeeee – Joe Phillips – 2009-08-07T00:28:22.307
3
Use MSKLC .. I'd remap ' (dagger) to _ and _ to '.
2
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".)
2
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... – None – 2009-08-06T20:37:39.757
17Of course, it's your choice wh_t you want to repl_ce – None – 2009-08-06T20:38:36.183
The ` is a good choice. I never use that thing. And it's pretty easy to hit. Makes your left pinky super-strong. – Nosredna – 2009-08-06T21:17:03.603
@samuelcarrijo, e::_ – Grant – 2009-08-06T21:26:30.150
2
remap - key to _ so you don't have to relearn key location but can save time not hitting shift.
2
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+0.4 for creativity. Unfortunately we round down. – Joe Phillips – 2009-08-06T21:38:49.870
1
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 – None – 2009-08-06T20:44:11.040
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. – None – 2009-08-06T20:44:25.470
1
i can already type at like 140wpm; i don't know if that typing instructor is for me – Claudiu – 2009-08-06T23:29:06.267
2The best typing tutor is The Typing of The Dead – Dana Robinson – 2009-08-07T01:32:36.737
I learned from Mario Teaches Typing. If you got a good typing streak going, Mario blew though goombas like a samurai. – Grant – 2009-08-07T12:26:20.437
0
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/
0
Copy and paste a bunch of times.
Which keyboard layout are you using? On a standard UK/Irish keyboard, underscore is Shift+-, which isn't too tricky. – TRiG – 2016-07-13T15:18:34.743
7For the fastest underscore possible, you could swap the space bar and the underscore keys. – Nosredna – 2009-08-06T20:32:42.857
6Or remap shift+space to _ ? – None – 2009-08-06T20:34:16.100
@Nosredna - I was going to suggest that :) – None – 2009-08-06T20:39:10.410
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 Ruport – 2009-08-06T20:41:40.467
3If only so much attention were spent on my more legit questions about GTK. – None – 2009-08-06T20:46:01.207
I think it's a legitimate question, but I figured that with 4 votes already it was going to get closed one way or another, so I voted to migrate to SU. I'd rather see it wind up here than being the subject of open/close wars on SO. (And I guess it's not really programming-related...) – David Z – 2009-08-06T20:49:37.557
1well it caused me to get an account here, anyway. – Claudiu – 2009-08-06T21:08:46.870