Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: white, Hacker, petermad, Stefan2

Post Reply
Redglyph
Junior Member
Junior Member
Posts: 3
Joined: 2023-02-03, 11:14 UTC

Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *Redglyph »

Hello,

I've used Total Commander since... well, since it was called Windows Commander. But I had never noticed this, the prefix of the indicated storage size is wrong.

If I select a file of 16,383 bytes, it's shown as "15 k" at the bottom, and if it's 16,384 bytes, it's "16 k", which indicates it's displaying kibibytes (abbreviated KiB) and not kilobytes (normally abbreviated kB though some use KB).

As you can verify on the NIST website (or the dictionary, or even Wikipedia if you dare trust this website), kilo- is used for powers of 10, even with computer storage units. The binary storage units have been standardized in 1998 to avoid this confusing situation. See for example:

https://physics.nist.gov/cuu/Units/binary.html

To be fair, the Explorer makes the same mistake (I had to check since I'm never using it).

I know some of us used to consider powers of 2 instead of powers of 10 for those units but it's not been the case for more than 20 years. Perhaps an option to choose, or at least the proper prefix could be shown?

PS: This has actually caused a problem when I thought I had enough space to transfer a series of big files and looked at the bottom to see the number of MB they used. :)
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6429
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Re: Storage unit prefixes of selected files are incorrect

Post by *Horst.Epp »

This is not a new topic
and I guess many users prefer to have the same display in Explorer and a 3th party file manager.
If this would be changed there would be much more complains
compared to the theoretical discussion what the right units are.
Windows 11 Home x64 Version 23H2 (OS Build 22631.3296)
TC 11.03 x64 / x86
Everything 1.5.0.1371a (x64), Everything Toolbar 1.3.2, Listary Pro 6.3.0.69
QAP 11.6.3.2 x64
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *ghisler(Author) »

You can actually switch to 1k = 1000b instead of 1k=1024b if you prefer. However, it only affects locations within Total Commander, it doesn't affect dialogs which are part of Windows, like the properties dialog (Alt+Enter).

You need to add the following line to the file wincmd.ini, under the [Configuration] header:
SizeStyle1000=1

You can edit the wincmd.ini via menu Configuration - Change settings files directly.
Author of Total Commander
https://www.ghisler.com
joker
Junior Member
Junior Member
Posts: 26
Joined: 2006-04-05, 10:42 UTC

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *joker »

Redglyph wrote: 2023-02-03, 11:39 UTCThe binary storage units have been standardized in 1998 to avoid this confusing situation.
I guess most don't care, they still use 1024, and they are right imo.
User avatar
HolgerK
Power Member
Power Member
Posts: 5406
Joined: 2006-01-26, 22:15 UTC
Location: Europe, Aachen

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *HolgerK »

I don't care;-)
I'm using "Size display: bytes" and "Header/Footer: bytes"
;-)Holger
Make our planet great again
Galizza
Member
Member
Posts: 167
Joined: 2018-09-07, 05:21 UTC

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *Galizza »

 
Hi, so if i set this value  SizeCheck=1  for Tc there will be no difference between being configured with  SizeStyle1000=0  or  SizeStyle1000=1

And if i want Tc to use the same data size standard that hard drives manufacturers use, i should set  SizeStyle1000=1  on Wincmd.ini

Am i right?

Thank you :!: .
 
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *ghisler(Author) »

Yes, SizeCheck=1 only makes TC check if there is enough disk space on target before copying.
This function works independently from the value of SizeStyle1000, because SizeStyle1000 only determines how the sizes are displayed. SizeCheck compares the file size to the free space (both measured in bytes).
Author of Total Commander
https://www.ghisler.com
User avatar
petermad
Power Member
Power Member
Posts: 14700
Joined: 2003-02-05, 20:24 UTC
Location: Denmark
Contact:

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *petermad »

2ghisler(Author)
Does SizeCheck=1 take cluster size into the equation as the cm_GetFileSpace (Ctrl+L) command does?
Last edited by petermad on 2023-02-10, 12:44 UTC, edited 1 time in total.
License #524 (1994)
Danish Total Commander Translator
TC 11.03 32+64bit on Win XP 32bit & Win 7, 8.1 & 10 (22H2) 64bit, 'Everything' 1.5.0.1371a
TC 3.50b4 on Android 6 & 13
Try: TC Extended Menus | TC Languagebar | TC Dark Help | PHSM-Calendar
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48005
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *ghisler(Author) »

Yes it does!
Author of Total Commander
https://www.ghisler.com
Redglyph
Junior Member
Junior Member
Posts: 3
Joined: 2023-02-03, 11:14 UTC

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *Redglyph »

ghisler(Author) wrote: 2023-02-03, 16:01 UTC You can actually switch to 1k = 1000b instead of 1k=1024b if you prefer. However, it only affects locations within Total Commander, it doesn't affect dialogs which are part of Windows, like the properties dialog (Alt+Enter).

You need to add the following line to the file wincmd.ini, under the [Configuration] header:
SizeStyle1000=1

You can edit the wincmd.ini via menu Configuration - Change settings files directly.
Thanks, that's most helpful!
Redglyph
Junior Member
Junior Member
Posts: 3
Joined: 2023-02-03, 11:14 UTC

Re: Storage unit prefixes of selected files are incorrect (byte <> mebibyte)

Post by *Redglyph »

Horst.Epp wrote: 2023-02-03, 12:09 UTC This is not a new topic
and I guess many users prefer to have the same display in Explorer and a 3th party file manager.
If this would be changed there would be much more complains
compared to the theoretical discussion what the right units are.
I don't see why TC users would use Explorer, nor why there would be any complain. It's not a theoretical discussion, it's a real problem when comparing available space, as mentioned in the first post.
joker wrote: 2023-02-05, 10:20 UTC
Redglyph wrote: 2023-02-03, 11:39 UTCThe binary storage units have been standardized in 1998 to avoid this confusing situation.
I guess most don't care, they still use 1024, and they are right imo.
You're right, it's your opinion :D Why would they be right though?
Post Reply