Lister: text wrapping in UTF-8 encoding

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
Fla$her
Power Member
Power Member
Posts: 2981
Joined: 2020-01-18, 04:03 UTC

Lister: text wrapping in UTF-8 encoding

Post by *Fla$her »

Wincmd.ini >

Code: Select all

[Lister]
Wrap=1
textwidth=76
binwidth=76
UTF-8.txt >

Code: Select all

№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№№
———————————————————————————————————————
000000000000000000000000000000000000000————————————————————
-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│-│
The last character of each line will be wrapped, although none of the lines contain 76 characters.
Overquoting is evil! 👎
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50390
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Lister: text wrapping in UTF-8 encoding

Post by *ghisler(Author) »

Line breaks occur at 76 bytes, not at characters in UTF-8. Unfortunately, there is no way to change this with the current functionality of the lister.

Moderator message from: ghisler(Author) » 2024-12-29, 09:38 UTC

Moved to will not be changed
Author of Total Commander
https://www.ghisler.com
User avatar
Dalai
Power Member
Power Member
Posts: 9943
Joined: 2005-01-28, 22:17 UTC
Location: Meiningen (Südthüringen)

Re: Lister: text wrapping in UTF-8 encoding

Post by *Dalai »

Well, then you should update the TC help which currently says:
TC help, section 4.b, part 3 wrote:TextWidth=81
Text width (in characters)
#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: 2981
Joined: 2020-01-18, 04:03 UTC

Re: Lister: text wrapping in UTF-8 encoding

Post by *Fla$her »

ghisler(Author) wrote: 2024-12-29, 09:38 UTC Line breaks occur at 76 bytes, not at characters in UTF-8.
Then why doesn't this happen with UTF-16?
Overquoting is evil! 👎
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50390
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Lister: text wrapping in UTF-8 encoding

Post by *ghisler(Author) »

It also happens with UTF-16 when you have dual word characters like some Chinese ideograms (e.g. CJK Unified Ideographs Extension B, Range: 20000–2A6DF), or Emoji (Range: 1F600–1F64F).
https://www.unicode.org/charts/
Author of Total Commander
https://www.ghisler.com
Post Reply