GNOME Bugzilla – Bug 623076
Diff offset by one line
Last modified: 2010-07-26 08:41:16 UTC
Created attachment 164845 [details] diff offset by one line Please see the attached screenshot because I don't know how to explain clearly the problem :). Note how the "int twx=gs->winx;" line is wrongly highlighted in blue in the right pane. It is the line below it that should be highlighted. Starting from this line, all highlighted lines are offset by one line. This happens in 1.3.1 and 1.3.2 (git ea260a6a0be128a1b95f5f9cc9bf82b153139dfd, Date: Sat Jun 26 18:23:20 2010 +0900). I tried to shorten the files being compared to produce a simpler test case, but it seemed to produce other comparison problems... I'll attach the files below.
Created attachment 164846 [details] file on the left pane of the previous screenshot
Created attachment 164847 [details] file on the right pane of the previous screenshot
So I can't reproduce this here. However, it looks like it might be the bug with CRLF in an unfortunate position, described here: http://mail.gnome.org/archives/meld-list/2010-June/msg00000.html Could you please test the patch there and see if it fixes your problem? If it does, I'd also like to know your setup (distribution, gtk+ and gtksourceview versions, etc.) since it's really odd that I can't reproduce it.
Yes, this patch fixes the problem! Thanks! As for my setup: - Arch Linux (i686) - glib2 2.24.1-1 - gtk2 2.20.1-2 - pygtk 2.17.0-1 - no gtksourceview installed. - python 2.6.5-3 - pycairo 1.8.8-1 - pygobject 2.21.3-1 - libglade 2.6.4-1 I have copied the git version of meld to my /home and run bin/meld from there, while 1.3.1 from the Arch repo is installed in /usr. The about box when I run it from home does state "1.3.2". I have "Leading whitespace" checked in the preferences, but I tried without it and the bug was still there.
I've just pushed the patch to Git HEAD, so this should be fixed now. Thank you for your bug report.