Jason Franklin wrote:
> I noticed after upgrading my Vim installation that messages from my plugins
> were appearing in odd places. I finally had the time to look into it and
> isolate the issue.
>
> Patch 7.4.1696 introduced the "clearmode()" function. The ":stopinsert"
> command invokes this function to clear the "-- INSERT --" indicator from the
> bottom of the screen.
>
> The "clearmode()" function will sometimes disturb the flow of Vim messages
> because it calls a function that changes the coordinates ("msg_col" and
> "msg_row") for message output. This effect is visible when the 'cmdheight'
> setting is higher than 1.
>
> Reproduce the issue as follows (using "vim -u NONE"):
>
> 1 :set cmdheight=2
> 2 :vnew
> 3 :autocmd BufEnter <buffer> stopinsert
> 4 :wincmd w | echo 'test'
> 5 :wincmd w | echo 'test'
>
> Note that on #4 'test' replaced the entered command, but not on #5. The
> behavior of #4 is what was seen in Vim prior to patch 7.4.1696.
>
> A simpler series of commands to observe the problem is:
>
> 1 :set cmdheight=2
> 2 :stopinsert | echo 'test'
>
> Note that 'test' should have overwritten the command.
>
> The patch that is attached to this email modifies "clearmode()" to save and
> restore the message output coordinates so that the flow of message output is
> not disturbed whenever the mode indicator is cleared from the screen.
>
> As usual, a test is included in the patch to ensure that this problem
> remains fixed in future versions of Vim.
Thanks, looks like a good patch, I'll include it.
--
A fool must search for a greater fool to find admiration.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.