Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Changing modes shouldn't move the text cursor IMO. Any setting to disable this?

share|improve this question
add comment

3 Answers

The cursor doesn't actually move. In command mode (what you refer to as escape mode) it is on the 3rd (for example) character, while when you go to insert mode, it is behind 3rd character.

It is only true it will move if while in insert mode, you go into replace mode (press "insert" button on your keyboard) :: then it will move to the right character of your current position (in this case, the 4th character).

share|improve this answer
    
There are several ways of going into I mode, from N mode (command mode, or normal mode). One is pressing "a" - appends text after the cursor, the other is "i" - before the cursor. I actually didn't understand what you were talking about at first, because I usually more often press "a" ... –  ldigas Dec 30 '09 at 21:39
    
The cursor does seem to move left one space when going back into command mode. If you continue to type i, esc, i, esc, ... you'll see the cursor slide left. I do like the suggestion of using append (via "a") which moves it over to the right one space. Thanks. –  AlexD Jan 1 '10 at 20:36
    
@AlexD - No problem. Btw, all the best in the New Year. –  ldigas Jan 1 '10 at 21:28
add comment

I have been using vi, vim, and now gvim for over a decade, and I never noticed the shifting. I use i to insert and a to append, and my typing goes where I want. This may be a minor interface quirk that you will simply stop noticing after a short time.

You may prefer the settings recommended here:

http://superuser.com/questions/10588/how-to-make-cut-copy-paste-in-gvim-on-ubuntu-work-with-ctrlx-ctrlc-ctrlv

I know I do. These settings don't really address your issue, but if your vim/gvim experience is more familiar, you may not care so much about character shifting behavior.

One additional alternative: You might try the cream settings (http://cream.sourceforge.net/features.html). If you are using Ubuntu or Debian, there is a package you can install with apt-get/aptitude/synaptic (the package is named cream).

share|improve this answer
1  
I think the trick is to train myself to use append. –  AlexD Jan 1 '10 at 20:47
add comment
imap <silent> <Esc> <C-O>:stopinsert<CR>

Seems to work just fine :)

Also, set virtualedit=onemore needs to be set for best behavior.

I know this question is old but i figure a few people might enjoy this.

share|improve this answer
    
This works but i stopped using it because the mode text didn't change back immediately when exiting insert mode. –  ggustafsson Feb 16 '12 at 11:07
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.