Bug in Compare By Content?

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: Hacker, petermad, Stefan2, white

Post Reply
Beats
Junior Member
Junior Member
Posts: 15
Joined: 2008-04-21, 23:16 UTC

Bug in Compare By Content?

Post by *Beats »

Sorry my English.

I don't sure it's a bug, but when I compare two files with, for example, the next content:
File1 -> abcdefghijklmndprst
File2 -> abczefghijklmnzprst
Only show "1 differences found", otherwise paint two letters in red.
In Total Commander same letters in different position is one difference?
User avatar
fenix_productions
Power Member
Power Member
Posts: 1979
Joined: 2005-08-07, 13:23 UTC
Location: Poland
Contact:

Post by *fenix_productions »

I think that "difference" is meant for lines. It is the most efficient mode IMHO. Imagine comparing two HTML files. If you seen "2 differences found" message it might be obvious that two lines differ. Other way you could end up with "300 differences found". The speed could be painful too.
"When we created the poke, we thought it would be cool to have a feature without any specific purpose." Facebook...

#128099
Beats
Junior Member
Junior Member
Posts: 15
Joined: 2008-04-21, 23:16 UTC

Post by *Beats »

If I test with next files yet TC shows "1 differences found".

file1 ->
abcdefghi
jklmndprst
file2 ->
abczefghz
jklmnzprst
User avatar
HolgerK
Power Member
Power Member
Posts: 5409
Joined: 2006-01-26, 22:15 UTC
Location: Europe, Aachen

Post by *HolgerK »

Beats wrote:file1 ->
abcdefghi
jklmnd
prst
file2 ->
abczefghz
jklmnz
prst
There is only one different block of characters!

HTH,
Holger
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50475
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Post by *ghisler(Author) »

Indeed TC shows the number of blocks of lines which are different. It's the number of times you need to press "Next difference" to jump from the beginning of the file (when no difference is selected) to the LAST difference.
Author of Total Commander
https://www.ghisler.com
Beats
Junior Member
Junior Member
Posts: 15
Joined: 2008-04-21, 23:16 UTC

Post by *Beats »

Thanks for yours answers.

isn't it behavior (show 1 difference found) a few confused, since on last text TC paints three letters in red?

Until when TC considers a text a block? In the page jump of the screen?
User avatar
Flint
Power Member
Power Member
Posts: 3501
Joined: 2003-10-27, 09:25 UTC
Location: Belgrade, Serbia
Contact:

Post by *Flint »

Beats wrote:Until when TC considers a text a block? In the page jump of the screen?
No, until it meets the first line without differences.
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 11.03 / Win10 x64
Beats
Junior Member
Junior Member
Posts: 15
Joined: 2008-04-21, 23:16 UTC

Post by *Beats »

Sorry, but i don't understand that declaration. What is a line? It isn't where is reached end line (0x0D 0x0A or 0x0A) because in last example text should show two differences.

Please explain, if isn't bother.
Beats
Junior Member
Junior Member
Posts: 15
Joined: 2008-04-21, 23:16 UTC

Post by *Beats »

I think I understood, "the first line without differences".
It text shows two differences:
text1 ->
abcdefghi
1234567890
jklmndprst
text2 ->
abczefghz
1234567890
jklmnzprst

Thanks.
User avatar
Flint
Power Member
Power Member
Posts: 3501
Joined: 2003-10-27, 09:25 UTC
Location: Belgrade, Serbia
Contact:

Post by *Flint »

Beats wrote:I think I understood, "the first line without differences".
Yes. Sequence of lines each containing some differences is treated like 1 difference (1 block).
Flint's Homepage: Full TC Russification Package, VirtualDisk, NTFS Links, NoClose Replacer, and other stuff!
 
Using TC 11.03 / Win10 x64
Post Reply