On Tuesday, June 5, 2012 1:14:28 PM UTC-5, glts wrote:
> No responses so far, perhaps I was a little long-winded. I'm reporting
> on what I think is a bug in Vim 7.3.
>
> Basically, the "|" (go to screen column) command is ignored when it is
> used from the command line with ":normal", and 'virtualedit' is set to
> "all", and Visual block mode is entered immediately afterwards.
>
> Steps to reproduce.
> - ":se ve=all"
> - on a line with the text "<Tab>hello" issue the command ":norm 3|^V"
>
> The "3|" (go to virtual column 3) is ignored. Instead, the Visual block
> starts on the cursor position. This does not happen in real normal mode.
> I would very much appreciate your comments on this behaviour. I'm not
> familiar with the Vim source but I can investigate given some pointers.
I can confirm, what's missing from the description is that it only happens if
the desired cursor position falls within the display space of the tab character.
I started Vim with gvim -N -u NONE -i NONE, set virtualedit=all, and entered
text:
<-this is a tab
this is some text
:normal! 6|^Vj
will highlight text starting at the current cursor position, with the other
corner in column 6 on the next line. It ought to select only column 6 in both
lines.
:normal! 10|^Vj
works as expected, selecting column 10 in both lines
Also using the first command in "real" normal mode works as expected.
If the tab is replaced by spaces:
<-these are spaces
this is some more text
then both commands behave as expected.
Looks like a bug to me.
VIM - Vi IMproved 7.3 (2010 Aug 15, compiled Apr 30 2012 14:21:53)
MS-Windows 32-bit GUI version with OLE support
Included patches: 1-514
Compiled by [email protected]
Huge version with GUI.
--
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