How to set a codepage for "Compare Contents" tool?

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
TestUser013
Junior Member
Junior Member
Posts: 2
Joined: 2024-11-11, 18:12 UTC

How to set a codepage for "Compare Contents" tool?

Post by *TestUser013 »

Hello Experts,

I have been using the old version of Total Commander 8.51a x64 for a long time. Recently, I downloaded version 11.03 x64 and faced a problem - the file encoding in the "Compare Contents" tool is incorrectly determined. Please tell me how and where to configure the code page to fix the encoding.

I'm using Windows 11.
A language for non-Unicode programs is set to Ukrainian in windows settings.
A reg key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Nls\CodePage 1252 is set to c_1252.nls and 1251 is set to c_1251.nls (I also tried to set 1252 to c_1251.nls but it didn't help)
Lister shows evething correct and it says that codepage 1251 is used.

Here are two screenshots of the same files on my laptop, captured using different TC versions
v11: https://imgur.com/LDeKbv9
v8: https://imgur.com/4GtVaVj
User avatar
beb
Power Member
Power Member
Posts: 579
Joined: 2009-09-20, 08:03 UTC
Location: Odesa, Ukraine

Re: How to set a codepage for "Compare Contents" tool?

Post by *beb »

2TestUser013
If your issue is concerned only with the Ukrainian .mnu files try the following:
1. in .lng change the second string from

Code: Select all

Ukrainian (Українська)
codepage=1251
to

Code: Select all

Ukrainian (Українська)
codepage=65001
2. Save both .mnu and .lng files as UTF-8 without BOM (65001).

And returning to the original question, try to compare the fonts set in each version of the TotalCommander.

Specifically, Compare by content tool font can be explicitly set here:
wincmd.ini:

Code: Select all

[AllResolutions]
CompFontName=Courier New
CompCharSet=204
Where some character set codes: Western=1; Greek=161; Turkish=162; Vietnamese=163; Hebrew=177; Arabic=178; Baltic=186; Cyrillic=204; Thai=222; Central European=238.
Last edited by beb on 2024-11-13, 18:21 UTC, edited 2 times in total.
#278521 User License
Total Commander [always the latest version, including betas] x86/x64 on Win10 x64/Android 10/15
Fla$her
Power Member
Power Member
Posts: 2982
Joined: 2020-01-18, 04:03 UTC

Re: How to set a codepage for "Compare Contents" tool?

Post by *Fla$her »

2beb
For codepage=65001, it will have to save almost all *.lng in UTF-8 in the \Plugins\wdx\ subfolders.
And as a result, in some dialog drop-down menus, the items may display incorrect information.
Overquoting is evil! 👎
TestUser013
Junior Member
Junior Member
Posts: 2
Joined: 2024-11-11, 18:12 UTC

Re: How to set a codepage for "Compare Contents" tool?

Post by *TestUser013 »

Thanks for the answers! The problem is not with the Ukrainian .mnu files. All ASCII files are affected.

I've changed CompCharSet to 204 an now everything works perfectly. Thank you beb so much!
User avatar
beb
Power Member
Power Member
Posts: 579
Joined: 2009-09-20, 08:03 UTC
Location: Odesa, Ukraine

Re: How to set a codepage for "Compare Contents" tool?

Post by *beb »

2TestUser013
You're very welcome.
#278521 User License
Total Commander [always the latest version, including betas] x86/x64 on Win10 x64/Android 10/15
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50390
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: How to set a codepage for "Compare Contents" tool?

Post by *ghisler(Author) »

CompCharSet is the character set chosen when picking a font in compare by content.
Author of Total Commander
https://www.ghisler.com
Post Reply