• You are not logged in.

Programmers' frequent use of Shift

  • Started by Emph
  • 35 Replies:
  • Reputation: 0
  • Registered: 01-May-2009
  • Posts: 68
tomlu said:

I'm going to go out on a limb and say that Colemak wasn't designed specifically for high-quality keyboards. Your shift usage is hardly different between Colemak and QWERTY.

Is QWERTY's shift usage already optimal or did Colemak just not improve it much?  There are many things to optimize when it comes to shift usage.  For one thing, the left shift is way easier than the right.  Some letters are more likely to be capitalized than others and ideally you want to minimize using that same pinky again--a "hidden" same finger to look out for.  Ideally you don't want to even use the same hand that used the shift until hitting a couple keys from the other side.  For instance if you have to do a right side capital letter (left pinky) then the letter following it should be something on that same hand, but not awkward, not the same finger, etc.  Shift can be optimized a great deal but it's not that frequent so it's not really a priority.

Offline
  • 0
  • Reputation: 0
  • Registered: 03-Jul-2009
  • Posts: 189
trifthen said:

It uses scissor switches just like most laptop keyboards, so it might actually last quite a while.... I'm still surprised I like it more than my Unicomp, and due to the decreased key travel, I actually type 5-10wpm faster. That's just nutty.

I understand. I was fond of scissor switches keyboards too, and indeed they are way better than membrane based ones. And I'm faster on them than on a Model M, too. However I've just purchased a keyboard based on Cherry brown switches and I like it more than my laptop one, because keys have a longer travel, therefore I'm not hitting the bottom all the time, which is tiring. If you'd like to try out a cheap keyboard based on Cherry brown switches, look for an used Compaq MX11800.

Dvorak typist here.  Please take my comments with a grain of salt.

Offline
  • 0
  • Reputation: 0
  • Registered: 08-Mar-2008
  • Posts: 303

According to my statistics (which include a good deal of programming code), this is the frequency of punctuation:

, . \ " ' _ ( ) - ; = 0 $ : 1 / 2 > { } ? ! [ ] * 3 5 < 4 @ 9 | 8 6 7 + % # & ^

Most numbers are more common than most of the punctuation on the same keys. The only punctuation that's more common is the stuff that's closer to your fingers (except for a few anomalies like \ - = which are way more common than their position makes them look -- they are actually more common than JXQZ). I think that the positioning of numbers is fair; the main problem is those outlying keys. Here is a possible rearrangement.

This is what it looks like now:

1 2 3 4 5 6 7 8 9 0 - =      ! @ # $ % ^ & * ( ) _ +
q w f p g j l u y ; [ ] \    Q W F P G J L U Y : { } |
a r s t d h n e i o '        A R S T D H N E I O "
z x c v b k m , . /          Z X C V B K M < > ?

This is what it could look like:

8 6 4 2 0 1 3 5 7 9 = ?      | & # $ % @ * ^ < > + !
q w f p g j l u y " ; [ ]    Q W F P G J L U Y ' : { }
a r s t d h n e i o -        A R S T D H N E I O _
z x c v b k m , . \          Z X C V B K M ( ) /

It's not perfect, but it's more ergonomic than what we've got.

Offline
  • 0
  • Reputation: 0
  • Registered: 03-Jul-2009
  • Posts: 189
SpeedMorph said:

According to my statistics (which include a good deal of programming code)...

What languages have you considered?

SpeedMorph said:

This is what it could look like:

8 6 4 2 0 1 3 5 7 9 = ?      | & # $ % @ * ^ < > + !
q w f p g j l u y " ; [ ]    Q W F P G J L U Y ' : { }
a r s t d h n e i o -        A R S T D H N E I O _
z x c v b k m , . \          Z X C V B K M ( ) /

It's not perfect, but it's more ergonomic than what we've got.

Why have you favoured brackets over parens when the latter are more frequent?

Dvorak typist here.  Please take my comments with a grain of salt.

Offline
  • 0
  • Reputation: 0
  • Registered: 01-May-2009
  • Posts: 68

IMO a good programming layout would probably need to try to maximize doing two strokes on one hand then two on the other, _including_ shift and enter usage.  Having so much crap on the same hand as enter is not good.  Programmers probably wish enter was less far of a reach and probably not even on the pinky.

I feel like designing keyboards around programming languages is utterly perverse because many programming languages have intentionally taken seldom-used characters from the keyboard and made them prominent, rather than kept the task of programming similar to the task of writing.  It doesn't seem unreasonable to instead demand that programming languages, or specialized IDE's, bring the task of programming back to one that is modeled after "normal" keyboard use.

Offline
  • 0
  • Reputation: 0
  • Registered: 17-Mar-2008
  • Posts: 192

I use a programming specific layout (using dual pinky modifiers that are neither shift nor ctrl). The idea is to keep your hands on or around the home row as much as is possible. It's designed for python, curly brace languages and normal typing. Since switching back and forth between keys on alternating hands is expensive for shift-style keys, I try to maximise same-hand and rolls.

 ${}\ 1+[]
@*:/" 0=();
 ~|&# _-<>

For instance,

object->method();

sports a roll for -> and another for ();

Offline
  • 0
  • Reputation: 0
  • Registered: 03-Jul-2009
  • Posts: 189
klalkity said:

IMO a good programming layout would probably need to try to maximize doing two strokes on one hand then two on the other, _including_ shift and enter usage.  Having so much crap on the same hand as enter is not good.  Programmers probably wish enter was less far of a reach and probably not even on the pinky.

I agree.

Interestingly, Arensito is the only alternative layout which takes care of moving non-character frequent keys in comfortable positions, albeit under the pinkies.

klalkity said:

I feel like designing keyboards around programming languages is utterly perverse because many programming languages have intentionally taken seldom-used characters from the keyboard and made them prominent, rather than kept the task of programming similar to the task of writing.

I don't think so. IMO, the standard keyboard has been modeled after business and prose writing, therefore it's not comfortable for tasks involving different characters frequencies. Moreover, since most programming languages have born in the USA, they are modeled after its standard layout. I once tried writing code with a USA keyboard and it was way more comfortable.

klalkity said:

It doesn't seem unreasonable to instead demand that programming languages, or specialized IDE's, bring the task of programming back to one that is modeled after "normal" keyboard use.

Wouldn't it be better modeling keyboard layouts after prose usage, but leaving some keys to customize for each area? That's already been done for different languages layouts.

Last edited by spremino (19-Nov-2009 13:58:26)

Dvorak typist here.  Please take my comments with a grain of salt.

Offline
  • 0
  • Reputation: 0
  • Registered: 08-Mar-2008
  • Posts: 303
spremino said:
SpeedMorph said:

According to my statistics (which include a good deal of programming code)...

What languages have you considered?

Java, Perl, Ruby, and some C and PHP. I personally don't program in Perl or PHP, but I know that a lot of people do.

Why have you favoured brackets over parens when the latter are more frequent?

I haven't. I put parentheses in what I think is an easier-to-reach position.

Offline
  • 0
  • Reputation: 0
  • Registered: 03-Jul-2009
  • Posts: 189
SpeedMorph said:
spremino said:

Why have you favoured brackets over parens when the latter are more frequent?

I haven't. I put parentheses in what I think is an easier-to-reach position.

I understand. I saw they were "shifted" and thought they were less comfortable that way. Thanks!

Dvorak typist here.  Please take my comments with a grain of salt.

Offline
  • 0
  • Reputation: 0
  • From: Chicago Area
  • Registered: 04-Nov-2009
  • Posts: 21
, . \ " ' _ ( ) - ; = 0 $ : 1 / 2 > { } ? ! [ ] * 3 5 < 4 @ 9 | 8 6 7 + % # & ^

What the F are you escaping so often that backslash is near the top of your list? For anyone who goes anywhere near the command line on anything but Windows, moving the / key to being shifted is a huge minus. You'll pry my command-line forward-slash from my cold, dead hands.

I'll cut you, man!

Offline
  • 0
  • Reputation: 0
  • Registered: 22-Nov-2009
  • Posts: 58
trifthen said:

Actually for this, I've always longed for a foot switch. I mean, pianos have food pedals for common movements, so why can't we have a foot-switch for shift? That would be awesome.

Indeed, a foot switch seems a brilliant idea indeed ! I would like to have shift under one foot and Control, Alt under the other

Last edited by bmx007 (22-Nov-2009 17:41:45)
Offline
  • 0