On 11/13/06, Max Dyckhoff <[EMAIL PROTECTED]> wrote:
Do you have a CursorHold au command? Do this to find out::au CursorHold
Exactly; Thanks Max. It was &ut value too low. Raising the &ut value fixed it. Yakov
If you do then you are getting the same issue as I do in a lot of places. Apparently the CursorHold au will generate some input command which will override pending commands. If you have "showcmd" set then you can see the effect. 1. Move to a location (or leave insert mode by pressing escape) 2. Very quickly, press a key (like m, q, etc). 3. Watch the "showcmd" and see it display the m. 4. After 'updatetime' the command will be cancelled (often with a bell sound, if you have that turned on). So what is happening with you is that you aren't pressing "a" quickly enough after the "m", and hence the "m" is being cancelled and the "a" is putting you into insert mode. It's massively annoying! To get around it, there are a few things you can try: a. Remove your au command. b. Massively decrease the updatetime (I'd like to see you press "m" less than 10 milliseconds after "esc" :) c. Remember to wait a short time after moving to a location before doing a command. d. Complain to Bram and see if he can come up with a fix to it.
I think this was brought to Bram attention some months ago.
My suggested fix would be to block CursorHold and CursorHoldI au commands if there was a pending user command, but I have no idea if this is even possible. Hope that helps, Max > -----Original Message----- > From: Yakov Lerner [mailto:[EMAIL PROTECTED] > Sent: Monday, November 13, 2006 12:39 PM > To: Vim List > Subject: <esc>ma misbehaviour > > I often use ma to mark the 'a mark. But recently if I press ma > shortly after Esc, this puts vim into insert mode ! (and does > not set any 'a mark). > > I don't have any mapping for <Esc>ma or ma or <esc>m: > nmap <esc>m -> No mapping found > nmap <esc>ma -> No mapping found > nmap ma -> No mapping found > nmap m -> No mapping found > I looked into 'set termcap' for a key defined as ^[ma, nothing. > > How can I fix this or track down the reason ? > > Thanks > Yakov
