圣者
精华
|
战斗力 鹅
|
回帖 0
注册时间 2012-5-24
|
本帖最后由 shahito 于 2014-5-23 14:22 编辑
这贴天天在PC区浮着,凑巧看了下里面的内容,正是无语了……
蛋疼看了下KDE的Dolphin,写的是GiB,再顺便看了下Ubuntu的wiki
Ubuntu的wiki里面明确有一个条目叫UnitsPolicy,地址在https://wiki.ubuntu.com/UnitsPolicy
里面的内容是这样子的:
Rationale
There are two ways to represent big numbers: You could either display them in multiples of 1000 = 10 3 (base 10) or 1024 = 2 10 (base 2). If you divide by 1000, you probably use the SI prefix names, if you divide by 1024, you probably use the IEC prefix names. The problem starts with dividing by 1024. Many applications use the SI prefix names for it and some use the IEC prefix names. The current situation is a mess. If you see SI prefix names you do not know whether the number is divided by 1000 or 1024. There is already a Brainstorm idea for it: Fix file size confusion.
Policy
Applications must use IEC standard for base-2 units:
1 KiB = 1,024 bytes (Note: big k)
1 MiB = 1,024 KiB = 1,048,576 bytes
1 GiB = 1,024 MiB = 1,048,576 KiB = 1,073,741,824 bytes
1 TiB = 1,024 GiB = 1,048,576 MiB = 1,073,741,824 KiB = 1,099,511,627,776 bytes
Applications must use SI standard for base-10 units:
1 kB = 1,000 bytes (Note: small k)
1 MB = 1,000 kB = 1,000,000 bytes
1 GB = 1,000 MB = 1,000,000 kB = 1,000,000,000 bytes
1 TB = 1,000 GB = 1,000,000 MB = 1,000,000,000 kB = 1,000,000,000,000 bytes
It is not allowed to use the SI standard for base-2 units:
1 kB != 1,024 bytes
KB (with a big k) does not exist
Correct basis
Use base-10 for:
network bandwidth (for example, 6 Mbit/s or 50 kB/s)
disk sizes (for example, 500 GB hard drive or 4.7 GB DVD)
Use base-2 for:
RAM sizes (for example, 2 GiB RAM)
For file sizes there are two possibilities:
Show both, base-10 and base-2 (in this order). An example is the Linux kernel: "2930277168 512-byte hardware sectors: (1.50 TB/1.36 TiB)"
Only show base-10, or give the user the opportunity to decide between base-10 and base-2 (the default must be base-10).
如果谁还有疑问可以看下下面,这一切都是有历史缘由的。
http://en.wikipedia.org/wiki/Timeline_of_binary_prefixes
http://en.wikipedia.org/wiki/Binary_prefix
Windows下面实际指的的加i了的,而上面回帖的Ubuntu桌面指南是有偏差的(没事你也可以试试提交这个bug)。
|
|