On 14/02/11 4:12 PM, Yue Wu wrote:
On Sun, Feb 13, 2011 at 07:30:57PM -0800, Ben Fritz wrote:
On Feb 12, 6:10 pm, Yue Wu<[email protected]> wrote:
On Sat, Feb 12, 2011 at 09:42:42AM -0800, Ben Fritz wrote:
On Feb 12, 8:15 am, Yue Wu<[email protected]> wrote:
As the title, when setting wrap, long lines that extent outside the screen will
be showed as a folding, is it a bug or feature?
I've never seen this before. What's your 'foldmethod' setting? What
gets folded, just the single long line?
--
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, visithttp://www.vim.org/maillist.php
Hi Fritz, the reproduce way is:
Run vim, then run commands as follows:
:set foldmethod=expr
:set foldexpr=getline(v:lnum)[0]==\"\\t\"
:set nowrap
:set textwidth=0
Then input a very long line starts with a<tab> and is longer than your vim
screen.
Then start a new line. You can find that the first line can be folded using any
folding commands.
I'm confused. You specified a fold expression that would fold your
line, and are surprised that the line gets folded?
But that is a one screen line, not multiple screen lines come from a one
long line, why one screen line should get folded itself?
Why not? You told it to!
I admit it might seem a little strange. But if you don't want that
strangeness, you would need to change your fold expression, not expect
Vim to guess that you want something different.
I think this is definitely 'feature', not 'bug'. And it may be helpful
for people if the foldtext or highlighting has some meaning for them.
Ben.
--
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