Please check it: Loosing translation on standalone SynDir tool

English support forum

Moderators: white, Hacker, petermad, Stefan2

User avatar
AntonyD
Power Member
Power Member
Posts: 1249
Joined: 2006-11-04, 15:30 UTC
Location: Russian Federation

Please check it: Loosing translation on standalone SynDir tool

Post by *AntonyD »

Hi!
I have em_command:
button=wcmicons.dll,48
cmd=%COMMANDER_EXE%
param=/S=S:= %Z%X"%P" "%T"

for running standalone SyncDir tool.
And now on 11.02 Total it opens in a default English lang - not in my chosen RU for the whole Total.

Am I missing some bugs/changed behavior or something else?
#146217 personal license
User avatar
tuska
Power Member
Power Member
Posts: 3760
Joined: 2007-05-21, 12:17 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *tuska »

Hi,

Code: Select all

[em_AKTUELLE_Verz._synchronisieren]  ; Synchronise_CURRENT_DIR
button=TOTALCMD.EXE,32
cmd=%COMMANDER_EXE%
param=/S=S:= "%X%Z%P" "%T"
works here.

Language: German:
Configuration > Options... > Language: Deutsch (WCMD_DEU.LNG) > Main menu file: WCMD_DEU.mnu
- OR -
Language: English:
Configuration > Options... > Language: English (WCMD_ENG.LNG) > Main menu file: WCMD_ENG.mnu


Windows 11 Pro (x64) Version 23H2 (OS Build 22631.2715) | TC 11.02 x64/x86
User avatar
AntonyD
Power Member
Power Member
Posts: 1249
Joined: 2006-11-04, 15:30 UTC
Location: Russian Federation

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *AntonyD »

Good thing you don’t have a problem...
bad that I have it and reproduces 1000%
#146217 personal license
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

If I change languages with OPENLANGUAGEFILE "%COMMANDER_PATH%\LANGUAGE\WCMD_LNG.MNU", then the translation in the synchronization (em_SyncStandalone) and search (cm_SearchStandalone) windows have the language specified in the ini file (LanguageIni=Wcmd_lng.lng).

The reason is that the value of the Mainmenu key changes, but the LanguageIni value does not.
When English is selected, the Mainmenu and LanguageIni keys are deleted, so there is no problem with it.
Overquoting is evil! 👎
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *ghisler(Author) »

2AntonyD
Can you report the value of the line
LanguageIni=
in your wincmd.ini, please? Sounds like the standalone tools can't find the language file.

Here I only have
LanguageIni=wcmd_deu.lng
and it works fine.
Author of Total Commander
https://www.ghisler.com
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

2ghisler(Author)
Can you confirm what I wrote?
Start the English TC, and then switch to German. You will see that after launching the standalone tools, the language in them will not be changed, because the LanguageIni value remains the same.
Overquoting is evil! 👎
User avatar
Dalai
Power Member
Power Member
Posts: 9393
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Dalai »

2Fla$her
Using OPENLANGUAGEFILE as one is supposed to works as expected:

Code: Select all

OPENLANGUAGEFILE WCMD_LNG.LNG
and switches TC language (and menu) and saves both MainMenu and LanguageIni correctly.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

2Dalai
Check on TC x32 please.
I checked in several languages. It stays the same all the time, except for English.
Overquoting is evil! 👎
User avatar
Dalai
Power Member
Power Member
Posts: 9393
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Dalai »

I've made my tests on 32-bit TC. Just to make sure to name the relevant difference between our commands: mine doesn't contain a path and it references the language file instead of the menu file. The language file is also what's documented in totalcmd.inc.

When using a full path to a menu or language file (like the one you gave above), TC doesn't switch either the language or menu and writes invalid paths to wincmd.ini. When giving the menu file without a path, TC changes the menu and only writes the MainMenu key to wincmd.ini. But as I said, that's not how it's supposed to be used.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
User avatar
tuska
Power Member
Power Member
Posts: 3760
Joined: 2007-05-21, 12:17 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *tuska »

Just for the sake of completeness, I would like to add the following to the above post:
em_Menuefuehrung_DEUTSCH

Code: Select all

OPENLANGUAGEFILE WCMD_DEU.LNG
em_Menuefuehrung_ENGLISCH

Code: Select all

OPENLANGUAGEFILE WCMD_ENG.LNG
wincmd.ini - [Shortcuts]
A+D=em_Menuefuehrung_DEUTSCH
A+E=em_Menuefuehrung_ENGLISCH

These variants work in TC 11.02 x64 & x86.
 
Configuration > Language >  English > Main menu file: autom. removed, i.e. not available after switching from German to English.
wincmd.ini: LanguageIni= not available
Synchronize directories in separate task: OK

Configuration > Language >  Deutsch (WCMD_DEU.LNG) > Main menu file: WCMD_DEU.mnu -> removed by me(!)
1. Menu language: English -> as the menu file has been removed!
1.a Configuration > Options...: Language: Deutsch (= German)!
1.b Configuration > Button Bar...: Language: Deutsch (= German)!
2. wincmd.ini: LanguageIni=WCMD_DEU.LNG
3. Synchronize directories in separate task: OK, Language: Deutsch (= German)

I only get a mismatched menu view when I explicitly remove the WCMD_DEU.mnu file under 'Main menu file'.

When I use Language: Russian (Русский) (WCMD_RUS.LNG) and Menu file: WCMD_RUS.mnu
and then perform a synchronisation in a separate task, then this is possible in TC 11.02 x64 without any problems.

2AntonyD
I therefore assume that the file "WCMD_RUS.mnu" is not specified under 'Main menu file'.
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

Dalai wrote: 2023-11-28, 18:04 UTC When using a full path to a menu or language file (like the one you gave above), TC doesn't switch either the language or menu and writes invalid paths to wincmd.ini.
You may have made a mistake (for example, you didn't replace LNG with the language abbreviation) or didn't take the quotation mark path in the presence of spaces. Check it out.

Dalai wrote: 2023-11-28, 18:04 UTC When giving the menu file without a path, TC changes the menu and only writes the MainMenu key to wincmd.ini.
Before that, you wrote the opposite:
Dalai wrote: 2023-11-28, 18:04 UTC and saves ... LanguageIni correctly.
That's how it looks.
Overquoting is evil! 👎
User avatar
Dalai
Power Member
Power Member
Posts: 9393
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Dalai »

You seem to have missed some details - again.

OK, let me summarize my results:
  • Command:

    Code: Select all

    OPENLANGUAGEFILE "%COMMANDER_PATH%\LANGUAGE\WCMD_DEU.MNU"
    Results:

    Code: Select all

    Mainmenu=C:\$Recycle.BinOMMANDER_PATHLANGUAGE\WCMD_DEU.MNU
    The LanguageIni key is absent. Neither the language nor the menu is switched.
  • Command:

    Code: Select all

    OPENLANGUAGEFILE "%COMMANDER_PATH%\LANGUAGE\WCMD_DEU.LNG"
    Results:

    Code: Select all

    LanguageIni=C:\$Recycle.BinOMMANDER_PATHLANGUAGE\WCMD_DEU.LNG
    Mainmenu=C:\$Recycle.BinOMMANDER_PATHLANGUAGE\WCMD_DEU.mnu
    Neither the language nor the menu is switched.
  • Command:

    Code: Select all

    OPENLANGUAGEFILE WCMD_DEU.MNU
    Results:

    Code: Select all

    Mainmenu=WCMD_DEU.MNU
    The LanguageIni key is absent. The main menu is switched to German, but the language is not. This is congruent with what is saved to wincmd.ini.
  • Command:

    Code: Select all

    OPENLANGUAGEFILE WCMD_DEU.LNG
    Results:

    Code: Select all

    LanguageIni=WCMD_DEU.LNG
    Mainmenu=WCMD_DEU.mnu
    Both the language file and the menu file is switched and everything works just as expected.
In short: Use the LNG file without a path as the parameter to the OPENLANGUAGEFILE command (just as it is documented) and everything will work as expected.

Regards
Dalai
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

Dalai wrote: 2023-11-28, 23:39 UTC In short: Use the LNG file without a path as the parameter to the OPENLANGUAGEFILE command (just as it is documented) and everything will work as expected.
Did I waste my time on the screencast? In the tooltips, you can also see that only names without paths are specified :!:
Overquoting is evil! 👎
User avatar
Dalai
Power Member
Power Member
Posts: 9393
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Dalai »

You specify the MENU file while the LANGUAGE file is supposed to be used!
#101164 Personal licence
Ryzen 5 2600, 16 GiB RAM, ASUS Prime X370-A, Win7 x64

Plugins: Services2, Startups, CertificateInfo, SignatureInfo, LineBreakInfo - Download-Mirror
Fla$her
Power Member
Power Member
Posts: 2318
Joined: 2020-01-18, 04:03 UTC

Re: Please check it: Loosing translation on standalone SynDir tool

Post by *Fla$her »

Ah, here's the rub. I thought they were equivalent when used. Then that explains it all.
You should have marked the extensions in color, then I would immediately understand what you are leading to.
Dalai wrote: 2023-11-28, 23:39 UTC The LanguageIni key is absent. Neither the language nor the menu is switched.
...
Neither the language nor the menu is switched.
I can't confirm that. The menu changes in both cases. In the second case, the language also changes.
Overquoting is evil! 👎
Post Reply