WinMerge / winmerge

WinMerge is an Open Source differencing and merging tool for Windows. WinMerge can compare both folders and files, presenting differences in a visual text format that is easy to understand and handle.
https://winmerge.org/
GNU General Public License v2.0
6.03k stars 768 forks source link

Word difference colors for deletions are also used for additions #2341

Open bobbyfox82 opened 1 month ago

bobbyfox82 commented 1 month ago

When performing a text diff with Line Difference Coloring enabled, the colors for Deleted Word Difference and Deleted Selected Word Diff are applied to the word additions. To reproduce, diff original.txt and modified.txt. See the images below for the diff options used and the diff results.

original.txt modified.txt

Options WordDifference SelectedWordDifference

sdottaka commented 1 month ago

This is confusing, but it's the expected coloring: if a word in either pane is deleted, the Word Difference (Deleted) color will be applied to the word in the other pane. This is because WinMerge doesn't essentially assume that the left pane is the old file and the right pane is the new file. There are some UI improvement requests for this:

Related issue: https://github.com/WinMerge/winmerge/issues/359