Changes between Initial Version and Version 1 of Ticket #3666, comment 113
- Timestamp:
- 11/07/16 12:44:20 (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #3666, comment 113
initial v1 20 20 21 21 In the very special case of {{{size_trunc_len()}}} and alike is that the passed {{{len}}} is given in bytes but the upper-level in {{{panel_fields[]}}} contains length in bytes but expects it to be columns. More than that, the scale logic in again byte/single byte char oriented and limited by length. If you pass a buffer with 64 byte and say length=64, it will never scale numbers down to KiB, MiB, etc. because there is enough space (given by length) to accomodate that. You'd always need calculate wether your Unicode points fit in the given length based on the UTF-8 encoding scheme. 22 It may be a limitation in mc existed ever since, as you mention it is 22 years old, but now reve iled simply by my changes. The caller does not know upfront how many bytes the characters will beconsume. That's the crux -- at least for me.22 It may be a limitation in mc existed ever since, as you mention it is 22 years old, but now revealed simply by my changes. The caller does not know upfront how many bytes the characters will consume. That's the crux -- at least for me.