wincmd.ini: 'SetEncoding=äö.do.not.remove'
Moderators: Hacker, petermad, Stefan2, white
wincmd.ini: 'SetEncoding=äö.do.not.remove'
When I run the TC it appears in Wincmd.ini in the [Configuration]:
this entry: SetEncoding=äö.do.not.remove
If I delete it and re-run TC
again this entry appears.
What causes it?
this entry: SetEncoding=äö.do.not.remove
If I delete it and re-run TC
again this entry appears.
What causes it?
From HISTORY.TXT
Code: Select all
17.08.16 Fixed: Write SetEncoding=äö.do.not.remove to wincmd.ini [Configuration] on load, to prevent notepad from opening/saving the file as UTF-8 when it contains UTF-8 encoded parts (32/64)
- ghisler(Author)
- Site Admin
- Posts: 50861
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
This is done because the Windows ini file functions do not support UTF-8 Unicode. If notepad saves the file as UTF-8 by mistake, it will cause a lot of problems.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com
beb,
You're right, and it is because ANSI encoding is not a unique one, same bytes represent different characters in different codepages. But it doesn't matter here, the only reason of using these two bytes in this parameter is preventing opening and saving INI file in UTF-8 encoding (these two bytes represent invalid UTF-8 sequence) which is not a valid encoding for INI files.
You're right, and it is because ANSI encoding is not a unique one, same bytes represent different characters in different codepages. But it doesn't matter here, the only reason of using these two bytes in this parameter is preventing opening and saving INI file in UTF-8 encoding (these two bytes represent invalid UTF-8 sequence) which is not a valid encoding for INI files.
- ghisler(Author)
- Site Admin
- Posts: 50861
- Joined: 2003-02-04, 09:46 UTC
- Location: Switzerland
- Contact:
I chose these two bytes because they give valid character(s) in all encodings, including double byte encodings like Chinese, but NOT in UTF-8.
Author of Total Commander
https://www.ghisler.com
https://www.ghisler.com