Re: [patch] Fixes wanted-column bug in cursorbind feature
- Gary Johnson wrote:
> There is a bug in Vim's tracking of the wanted cursor column in theThanks for the patch. I'll include it.
> cursorbind feature. I believe that the attached patch fixes it.
> Vim keeps track of the desired or wanted cursor column as well as
> the actual cursor column. When the user moves the cursor to a
> different line and the wanted cursor column value is not stale, Vim
> tries to move the cursor to that wanted column. When 'cursorbind'
> is set, that wanted cursor column information is not being copied
> from the active window to the other cursorbound windows, resulting
> in the cursor jumping to seemingly random columns when moving the
> cursor up or down following a jump to a different window.
> To demonstrate this, start vim as "vim -N -u NONE" and execute the
> :set cursorbind
> Now move the cursor to column 5 and move the cursor to the other
> The cursor will be at column 5 of the other window, as expected.
> Now move the cursor to column 6 and move back to the original
> The cursor will be at column 6, again as expected. Now move the
> cursor down a line.
> The cursor will move to row 2 but to column 5 instead of column 6.
God made the integers; all else is the work of Man.
/// Bram Moolenaar -- Bram@... -- 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