Wednesday, June 23, 2010

Re: gvimdiff can not hightlight correctly the difference in a line

On Jun 23, 3:15 pm, Gary Johnson <garyj...@spocom.com> wrote:
> On 2010-06-23, Peng Yu wrote:
>
> > Suppose that I have the following two lines in two files (each in one
> > file), gvimdiff highlight everything after '=' without knowing that
> > 'sdsafdasfa' is the same in both lines. Is there a way to make
> > gvimdiff be aware of the commonality flanked by two mismatches?
>
> > i =x.y 19 sdsafdasfa xx
> > i = 19 sdsafdasfa
>
> No.  See ":help :diffu" and scroll down a bit to where it says this.
>
>     |hl-DiffText|  DiffText   Changed text inside a Changed line.  Vim
>                               finds the first character that is different,
>                               and the last character that is different
>                               (searching from the end of the line).  The
>                               text in between is highlighted.  This means
>                               that parts in the middle that are still the
>                               same are highlighted anyway.  Only "iwhite" of
>                               'diffopt' is used here.

I'm wondering why this can not be improved. Is it because if the
computation of internal common text is time consuming? But if the text
line is bounded, the runtime will be bounded as well.

--
You received this message from the "vim_use" 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

No comments:

Post a Comment