Changes between Initial Version and Version 2 of Ticket #12150


Ignore:
Timestamp:
Apr 10, 2023, 4:47:45 PM (21 months ago)
Author:
pulkomandy
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #12150

    • Property Owner changed from axeld to nobody
    • Property Status newassigned
    • Property Summary [BColumnListView] Fix BSizeColumn to use the si unit in DrawField[BColumnListView] Fix BSizeColumn to use the si unit in DrawField (easy)
  • Ticket #12150 – Description

    initial v2  
     1Currently, BColumnListView render sizes (in BSizeColumn, src/kits/interface/ColumnTypes.cpp) using "KB", "MB", etc suffixes.
     2
     3The sizes are acutally multiples of 1024, not 1000, and so the suffix should be KiB, MiB, etc.
     4
     5Ideally, the code would be adjusted to use string_for_size, which will not only do this, but also make sure to use the correct decimal separators depending on the user locale preferences. But, using string_for_size makes it more complicated to do "smart" string truncation (removing the least significant digits) to fit the text in the column when it is too small. See #13882 for an example of what happens when string_for_size is used without care.