[TC 11.58rc2] Range in multi-rename does not work with unicode

Bug reports will be moved here when the described bug has been fixed

Moderators: Hacker, petermad, Stefan2, white

Post Reply
PascalT
Junior Member
Junior Member
Posts: 74
Joined: 2015-08-27, 08:00 UTC

[TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *PascalT »

in TC 11.58rc2 With windows XP 32 bit:

When multi-renaming a file containing unicode characters and selecting a Range in the name, the selection is wrong if you select characters after the unicode characters.
Example :
file : abc๐Ÿdef.txt
Multi-rename, then Range select "def"
You get "ef" selected

It seems that Range selects bytes and not characters.

The problem was still existing with TC 11.57 and Windows XP and Windows 10
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 53125
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *ghisler(Author) »

This only seems to affect the range picker. Entering the range manually seems to work fine.
For example, renaming
abc๐Ÿdef.txt
abc_def.txt
would pick def by manually entering [N5-7], although ๐Ÿ is two words, and _ is only one word wide.
Author of Total Commander
https://www.ghisler.com
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 53125
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *ghisler(Author) »

This should be fixed in Total Commander 11.58 RC3, please test it!
09.06.26 Fixed: Multi-rename tool: The range picker dialog didn't consider Unicode characters consisting of more than one 16-bit word, e.g. Emoji, or Chinese characters with codes >=0x20000 (32/64)
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 6940
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *white »

Two bugs still there:
1) It fails for first character. (try: ๐Ÿabcdef.txt, first character is still counted as 2 characters)
2) It fails on initial selection. (try: ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ๐Ÿ.txt, which shows 1-22 instead of 1-11)
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 53125
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *ghisler(Author) »

Confirmed.
1 is due to a bug in CharNextW. I will use my custom WAnsiNext function as I do in the actual rename function.
2 is because I don't call the converter when initially opening the dialog.
Author of Total Commander
https://www.ghisler.com
PascalT
Junior Member
Junior Member
Posts: 74
Joined: 2015-08-27, 08:00 UTC

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *PascalT »

The test I described in the first post with abc๐Ÿdef.txt is now OK with TC 11.58rc3 in Windows 10 64 bit.
But it's not working with Windows XP 32 bit.
The result of Range selecting "def" is still "ef".

In windows XP Range selecting only "๐Ÿ" selects in fact "๐Ÿd", whereas it's OK with Windows 10 64bit ( "๐Ÿ" selected).
So the behavior is not the same with XP and Windows 10 64 bit.

I'll just point out that with XP the font is not able to draw the unicode character ๐Ÿ and draws an empty square in place, but I don't think it matters, it's a normal behavior.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 53125
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *ghisler(Author) »

This should be fixed in Total Commander 11.58 RC4, please test!
11.06.26 Fixed: Multi-rename tool: The range picker dialog still didn't handle multi-word characters correctly at the start of the string, also when initially opening, and when measuring from the end (32/64)
Author of Total Commander
https://www.ghisler.com
User avatar
white
Power Member
Power Member
Posts: 6940
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *white »

Tested OK using TC 11.58rc4 32-bit and 64-bit.
PascalT
Junior Member
Junior Member
Posts: 74
Joined: 2015-08-27, 08:00 UTC

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *PascalT »

It's OK for me too, with 32 and 64 bit.
User avatar
white
Power Member
Power Member
Posts: 6940
Joined: 2003-11-19, 08:16 UTC
Location: Netherlands

Re: [TC 11.58rc2] Range in multi-rename does not work with unicode

Post by *white »

Moderator message from: white ยป 2026-06-17, 19:29 UTC

Moved topic
ยป from TC11.x bug reports (English) to TC Fixed bugs
Post Reply