I've been digging through the Vim source and had trouble trying to
understand what win_lbr_chartabsize() is doing. About 112 lines from
the start of the function (in 7.1.94) there's a part that should take
the width of a tab into account when used in combination with
"showbreak". I couldn't work out how these parts were supposed to
interact from studying the code so I tried studying Vim's behaviour
instead. The results are a bit odd.

Create a file with a line containing a repeating pattern of four
letters and a tab (that is, "abcd<tab>abcd<tab>abcd<tab>...") to a
width of about 300 columns. Then set wrap, showbreak=>>> and tabstop
to something like 9 so there aren't a even number of tabs in your
screen width or your screen width less the width of the showbreak.

Now, starting from the beginning of the line, press w repeatedly
and watch where the cursor goes after each movement. On some of the
wrapped lines I see it settle three characters to the left of where it
should be when it moves to the first word on each wrapped screen line.
I've tried to fix it, but no matter what I change the cursor always
lands in the wrong place at some point. Does anyone else see this?

-- 
Matthew Winn

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui