Am 24.03.2011 02:00, schrieb Gary Johnson:
> 
> If you suppress the display of the missing lines by removing
> "filler" from 'diffopts', then the two diff windows will no longer
> track.
Of course that's true. I finally realized that diff'ing allows
synchronized scrolling "by timestamp" in terms of scrolling "by line" by
inserting lines.

> 
> You can do a number of things to suppress the coloring of
> those lines, though.
> 
> First off, I think you can use the 'highlight' option to change the
> way various diff elements are highlighted.  I've never used it, so
> I'll leave it to you to experiment with that if you like.
> 
> You can use the 'fillchars' option to change the hyphens used to
> indicate missing lines, e.g.,
> 
>     :set fillchars+=diff:\ 
> 
> will replace the hyphens with spaces, where that backslash is
> followed by a single space.
> 
> You could change the colors used by the highlight groups used to
> highlight the missing lines (DiffDelete group) and the changed lines
> (DiffChange and DiffText groups).  For example, if you are using a
> color terminal with a black background and you haven't specified a
> Normal highlight group, you could use
> 
>     :hi DiffDelete ctermfg=black ctermfg=black
> 
> Of course, if you used 'fillchars' to eliminate the hyphens, you
> won't need to set ctermfg, and vice versa.
> 
> Similarly, you can change the colors used by the DiffChange and
> DiffText groups to make those regions appear the same as your normal
> text, too.
> 

Thanks. I've added

" No highlighting of differences
highlight DiffAdd none
highlight DiffChange none
highlight DiffDelete none
highlight DiffText none
" fill missing lines with spaces
set fillchars+=diff:\

to my _vimrc and all highlighting is gone. Is there an easy way to reset
the highlight colors to their preset values, so I could assign switching
back and forth to a key combination?

As far as changing diff's strategy is concerned, I'm stuck. The only
promising option for the diff that came with my Windows installation of
vim is
  -H  Assume large files and many scattered small changes
But I still get

    000 0 gljjpqumLP

    001 0 bLUiouhx8L


    002 0 k6TKP7yHv1
    003 0 7eDtRBOi6U

    004 0 YLulNJm2dr
    005 0 sCSDdCyx2E

when I would like to get

    000 0 gljjpqumLP

    001 0 bLUiouhx8L

    002 0 k6TKP7yHv1

    003 0 7eDtRBOi6U

    004 0 YLulNJm2dr

    005 0 sCSDdCyx2E

when comparing vdt0 to vdt1 (which doubles each timestamp)

Malte

-- 
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

Reply via email to