PrestoSoft Blog :: Home

Wednesday, March 16, 2011

ExamDiff Pro 5.5: Copy Adjacent Ignored Lines

Ignoring certain lines (with the Ignore options under View | Options | Compare) can be useful in only isolating the most significant differences, but there are situations where you want ignored lines that are immediately above or below a diff block to be copied as part of a Replace Block operation. The next version of ExamDiff Pro will add the option to copy these adjacent ignored lines as part of such an operation.

As an example, suppose that I'm comparing two files with blank lines ignored. As you can see, the selected difference has a blank line underneath it in the left pane but not in the right pane:


When I copy the selected difference from the left pane to the right pane (with the Replace Block in Second File from First command or by simply clicking the arrow button on the diff bar in the left pane), the blank line is not copied because it's ignored and thus not part of the diff block. As a result, the right file is missing a space in between two chunks of code after the copy operation, making it a little harder to read in a text editor:


To remedy this problem, I can go to View | Options | File Editing and check the Copy adjacent ignored lines when replacing diff blocks option:


Now when I copy the selected difference from the left pane to the right pane, the blank line underneath is copied as well, just as I wanted:

Labels: ,

2 Comments:

Blogger Unknown said...

This seems like a good feature! I have often noticed I end up with missing or extra blank lines when merging.
But maybe it should be turned on by default? Otherwise people may never realise...

11:27 AM  
Blogger Larry Ingram said...

It is on by default.

11:33 AM  

Post a Comment

<< Home