You are not logged in.

#1 2009-03-28 14:07:34

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

Vim, Dvorak and Escape

Since there seems to be a lot of Arch users who prefer Vim, and some who type in Dvorak, I decided to ask for advice here.

Problem
I'm relative new to Dvorak and "real" Vim:ing (i.e., more than <i><type some text><Escape><:wq>). I like the idea of effectiveness - after all, I spend a lot of time typing text - and therefore I want to learn good habits from the start.

Right now, I can't decide how I should return to normal mode. There are lot of tips on how to remap the Escape key etc., but I still can't make up my mind. One problem is that I switch between a regular and a Typematrix keyboard. I spend most time typing on the latter one, and you can find my layout here.

Solutions?
So, after a lot of searching and reading - here are the solutions I like the most:

1. Map jj to Escape
+ Easy to reach.
- Non-standard. Doesn't work in Vimperator(?).
- I find it slightly annoying when typing "j" in insert mode.

Comments: This is the first thing I tried. I like it pretty much, but if I were to use someone else's computer I would probably leave lots of 'jj' in the text. Also, I would like to decrease the delay before the 'j' is inputted.

2. Use Ctrl-C
+ Standard, no need to remap anything.
+ I don't have to move my hands.
- Requires both hands.
- Slightly different from Escape.

Comments: This is what I consider at the moment. It's standard, fast and quite easy to reach. On a Qwerty keyboard, I would remap Caps Lock to Ctrl. And if I get the new Typematrix (does anybody have it?), left Ctrl would be easier to reach as it's swapped position with the left Fn key.

3. Just use the Escape key, ffs
+ Standard.
+ Just one key to press.
- Quite far away.

Comments: On my Typematrix, the Escape key isn't that far away - I can reach it without completely leaving the home row. With some training, I can probably hit it pretty accurately. On a regular keyboard, I would map Caps Lock to Escape.

4. ??
Comments: Any other better ways? Please take a look at my keyboard layout before suggesting anything.

Which method do you think is the best, and why?

Offline

#2 2009-03-28 21:44:34

bernarcher
Forum Fellow
From: Germany
Registered: 2009-02-17
Posts: 2,281

Re: Vim, Dvorak and Escape

As the Esc key is not too far away I would stick to it rather than building up bad typing habits.

QWERTY is slightly worse, but I got used to the Esc key there as well. For some time I did remap the Caps Lock but this only led to problems when using other computers.

Last edited by bernarcher (2009-03-28 21:48:50)


To know or not to know ...
... the questions remain forever.

Offline

#3 2009-03-28 22:44:43

Vintendo
Member
From: Netherlands
Registered: 2008-04-21
Posts: 375
Website

Re: Vim, Dvorak and Escape

This is bothering me quite a lot as wel. Vim is designed to keep your fingers on the home row but they use the escape key quite a lot. I am thinking about mapping the escape key to caps lock. I never use caps lock and its very close to my pinky.

Offline

#4 2009-03-28 23:56:10

X/ax
Member
From: Oost vlaanderen, Belgium
Registered: 2008-01-13
Posts: 275
Website

Re: Vim, Dvorak and Escape

I just keep using the esc key. I'm using vim in dvorak too, and everything is standard mapped. It's a lot of getting used to, and hitting esc really takes more time. But remapping it makes one learn new things, and has the risk of not being capable of running on another vim... (without reconfiguring)
C-c is possible with one hand though... In dvorak it is. Not really fast/handy, but with some training might become a better alternative to esc.

In the end, I don't really know the best to use vim. I really like it, but for starters, I don't use the jkli keys for moving. Because they're so different in dvorak, and learning those `unlogic' keys is a hard deal. Remapping is - again - too annoying, and risks having problems on other vim instances.

I think keeping things standard is the best way to go after all. Of course, fine-tuning is super-good if you're only running vim on your own box. Without having a clear risk of having problems of incapability.


My coding blog (or an attempt at it)
Archer start page (or an attempt at it)

Offline

#5 2009-03-29 19:28:57

GGLucas
Member
Registered: 2008-03-13
Posts: 113

Re: Vim, Dvorak and Escape

Personally I've mapped caps lock to escape for most of the time I've been using vim, it works wonderfully.

Last edited by GGLucas (2022-06-24 08:15:54)

Offline

#6 2009-03-29 20:03:15

jumzi
Member
Registered: 2009-02-20
Posts: 69

Re: Vim, Dvorak and Escape

Hmm... Well altough remapping 3 buttons to get a deacent homerow can be annoying, i wouldn't wanna compare that with what i went trought learning dvorak. And if i'm really (probably not) will be in a long vim session on another computer then mine i have a remote server with me config files *flex*

anyway... remap caps with esc... seriously... That or AltGr, but if i understood it right... AltGr on typematrix sux... so go with caps.  Not only for vim... But every application in general, i for one never use caps, and when dialogs popups it's neat being able to close those fast with just an easy "esc on the caps-location klick"

To switch caps with esc in the X just fiddle with /usr/share/X11/xkb/keycodes/"keyboard" (default is xfree86), just swap the esc and caps numbers with eachother. Voila! Caps and esc are swapped with eachother in every app big_smile

Offline

#7 2009-03-29 21:29:37

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

Re: Vim, Dvorak and Escape

Thanks for all replies. Before, I was under the impression that almost everyone used an alternative to the Escape key. However, after asking around on IRC and seeing your comments, I think I'll just stick to Escape.

"In the end, I don't really know the best to use vim. I really like it, but for starters, I don't use the jkli keys for moving. Because they're so different in dvorak, and learning those `unlogic' keys is a hard deal. Remapping is - again - too annoying, and risks having problems on other vim instances."

Since I didn't know Vim very well before typing Dvorak, I've decided to learn Vim with the Dvorak layout. It isn't that bad - jk are next to each other on the left side while h (left) and l (right) are on the right side.

"That said, I see you don't have a caps lock key on your keyboard, that sucks, any particular reason why you use that keyboard ?"

1. Non-staggered keys.
2. Keys are better placed, e.g. Enter and Backspace in the middle.

The only disadvantage is that it doesn't have a useless key to the left which I can remap to escape.

"anyway... remap caps with esc... seriously... That or AltGr, but if i understood it right... AltGr on typematrix sux... so go with caps. "

If you look at my layout, you'll see that I don't have Caps Lock. AltGr in invaluable to me, so that's a no-no. The default placement is really stupid, but I've remapped it the "usual" position (under my right thumb) - the same as the new USB Typematrix, which I plan to buy soon.

Last edited by Mogger (2010-02-24 22:09:44)

Offline

#8 2009-03-30 11:26:03

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: Vim, Dvorak and Escape

Hello fellow keyboard efficiency purist.  I also use dvorak and vim.  And several applications that use ctrl/alt. I hate those keys.  see http://bbs.archlinux.org/viewtopic.php?id=68476

Basically imho it comes down to: one should keep his hands on the home row (or as closely to it) as much as possible.
Esc and ctrl (and maybe also alt but alt can be avoided) are 2 keys that are frequently used, yet are too far away.  swapping one of them with caps lock fixes half of the problems.  Too bad there doesn't seem to be a way to have a reasonable keyboard layout (dvorak, colemak,..) and have the common keys in easy reach (enter,esc,ctrl,tab,...)

I'm gonna check out those typematrix things.


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

#9 2009-03-30 11:45:14

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: Vim, Dvorak and Escape

After a bit of research to the typematrix thing, I think this:
1) non-staggered keys are probably good thing (I would like to try it once)

2) there is indeed some room in the middle on normal keyboards (index fingers are too close too each other). a good place to put some common keys. BUT I don't think 'enter' (newline) is that common to type. maybe if vim would have a shortcut like 'nl' or something that would be good. also i don't think backspace is that common, especially for vi users where you usually have more suited shortcuts.  the shift buttons seem needlessly big. Especially on the left side you loose a good place for an additional key. esc is still far away.

So if they would make 2 buttons on the left shift, one for ctrl and shift, and in the middle put buttons for esc and enter, it would be pretty much perfect I think.


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

#10 2009-03-30 12:14:08

Mogger
Member
From: Sweden
Registered: 2008-12-07
Posts: 153
Website

Re: Vim, Dvorak and Escape

@Dieter@be:

I've also been thinking about dividing the Shift keys into two keys. I think I only press the top part anyway (same row as the home row). On the other hand, it "feels" nice with larger keys - though that's probably just something I've become used to.

Personally I use Enter and Backspace a lot, so I wouldn't want to move those keys. I'm not sure about putting Escape in the middle either, but that's probably also only a matter of habit.

If you're interested in weird keyboards, I suggest that you take a look at kinesis contour. I haven't tried it myself, but I'm convinced that it's the most comfortable keyboard on the market. However, it's a little bit too weird even for me, so I'll stick with Typematrix for now.
Picture: http://www.kinesis-ergo.com/images/kb_a … 20x471.jpg
Thumb keys: http://lowendmac.com/misc/05/art0518/thumb.gif

Offline

#11 2009-04-01 20:14:09

kandrews
Member
Registered: 2007-04-21
Posts: 119

Re: Vim, Dvorak and Escape

I'm a QWERTY user but I have replaced the more conveniently located CAPS with CONTROL and then press ^[ to escape (which is escape sequence for escape in unix as far as I know AND it works in Vimperator). This also a good way to access all the insertion mode commands that vim has to offer.

Last edited by kandrews (2009-04-04 16:04:48)

Offline

#12 2009-04-02 02:32:18

elmer_42
Member
From: /na/usa/ca
Registered: 2008-10-11
Posts: 427

Re: Vim, Dvorak and Escape

Personally, I use caps lock, but whenever I'm messing around with stuff outside of Xorg I always freak myself out.


[ lamy + pilot ] [ arch64 | wmii ] [ ati + amd ]

Offline

#13 2009-04-04 13:29:22

jumzi
Member
Registered: 2009-02-20
Posts: 69

Re: Vim, Dvorak and Escape

@Mogger

Kinesis might look weird, but it's just really sweet, even compared to typematrix, would take about the same time to get used to as the typematrix. Altough typematrix works with laptops if you really can't use the default keyboard.

Altough if you really want the best comfort (and speed for that matter) And cba about how long time it will take to get used to it, look at something called "Datahand"

Offline

#14 2010-02-24 21:57:38

Dieter@be
Forum Fellow
From: Belgium
Registered: 2006-11-05
Posts: 2,001
Website

Re: Vim, Dvorak and Escape

kandrews wrote:

I'm a QWERTY user but I have replaced the more conveniently located CAPS with CONTROL and then press ^[ to escape (which is escape sequence for escape in unix as far as I know AND it works in Vimperator). This also a good way to access all the insertion mode commands that vim has to offer.

^[ is a great trick thanks. but what do you mean with a good way to access insertion mode commands? how?


< Daenyth> and he works prolifically
4 8 15 16 23 42

Offline

Board footer

Powered by FluxBB