In the download file dialog, data sizes are reported using non SI standard notation. For instance, 5 kilobytes is represented as "5K". SI ("metric") would suggest this should be "5 kB". Common SI prefixes: m - mill (10^-3) k - kilo (10^3) M - mega (10^6) G - giga (10^9) Common computing notation (almost standard): b - bit B - byte Thus 5 kilobytes should be represented "5 kB". I believe this also appears in the page download status bar. According to bug 64179, this is also the case in the Mozilla installer <http://bugzilla.mozilla.org/show_bug.cgi?id=64179>.
I don't see a problem with K, although perhaps it should say KB.
It's a trivial bug and I think that could be corrected quickly.
UI design i think...
Assignee: asa → hangas
Status: UNCONFIRMED → NEW
Component: Browser-General → User Interface: Design Feedback
Ever confirmed: true
QA Contact: doronr → mpt
Chaning the qa contact on these bugs to me. MPT will be moving to the owner of this component shortly. I would like to thank him for all his hard work as he moves roles in mozilla.org...Yada, Yada, Yada...
QA Contact: mpt → zach
updating to new owner. sorry for the spam.
Assignee: hangas → mpt
*** Bug 76309 has been marked as a duplicate of this bug. ***
KiB and MiB are part of the *official* standard for binary multiples of bytes. See <URL:http://physics.nist.gov/cuu/Units/binary.html>.
Fixing this would require finding where these postfixes are defined in DTD and properties files, and changing them to be consistent and match SI standards. Gerv
Can anyone direct me to an occurence of "K" or "k" instead of KB in any part of Mozilla? Using a build from 20011015 on Win2K I consistently found KB in download dialog, proxy settings, Offline disk space, mail display (hardcoded in that case, bug 74714). "KB" is independently defined in am-offline.dtd, pref-cache.dtd, pref-diskcache.dtd, and pref-offline.dtd.
Huftis: see bug 106618 for KiB, etc.
This bug is invalid unless size of 1000 bytes is used. However, I believe size of 1024 bytes is meant, and SI explicitly states that it's prefixes should not be used to represent that. In this case binary prefixes should be used and bug 106618 addresses this issue.
> This bug is invalid unless size of 1000 bytes is used. 1000 bytes SHOULD be used. It's much easier to work with. If a user sees a file for download that's 1 megabyte, isn't it much nicer to know that it's 1,000,000 bytes, rather then 1,048,576 bytes? I think we should use multiples of 1000, not 1024. > Common computing notation (almost standard): > b - bit > B - byte "Almost standard"? More like, not standard now, never will be. Big B is 'bel', small b is something else, I believe. We should write out what we mean, to not add to the deception hard drive, video game, modem, and broadband companies perpetuate. "543 kbytes recieved at 12.3 kbytes/s". > KiB and MiB are part of the *official* standard for binary multiples of Mozilla's bug on this was WONTFIXed, as it should have been. That standard has been around a while and no one's adopted it. Mozilla would be quite an outcast if it used those units. Besides, the names are *stupid*. "kibibit"? sounds like a fruit. "mebibit"? I wouldn't pronounce that in public for anything. The referance page you point to does compare to what I propose, though: one gigabyte = 1 GB = 10^9 B = 1 000 000 000 B It seems to use 'bit' for 'bit' and 'B' for 'byte', which is still somewhat unsatisfactory to me, because of all the deception in the last 15 years by bluring the two.
For the sake of standards compliance, and for the sake of being *leaders* in the field of standards compliance, let us go where no american (and others) has gone before - SI units!!! Let's show some balls here. It's bad enough we use feet, inches, miles and gallons - blech; let's at least do the right thing with computer units. The users will thank us because the SI units are non-ambiguous. Maybe others will follow, but we will have been the first. That's a good thing. :)
Jeremy M. Dolan wrote: "1000 bytes SHOULD be used. It's much easier to work with. If a user sees a file for download that's 1 megabyte, isn't it much nicer to know that it's 1,000,000 bytes, rather then 1,048,576 bytes? I think we should use multiples of 1000, not 1024." You objection seems to be based on a misunderstanding: When a user sees a file for download that's 1 megabyte, it is usually assumed (incorrectly) that the file is 1 000 000 bytes, where it is more likely 1 048 576 bytes. KiB can not be misconstrued as 1 000 000 bytes, as it has one and only one meaning: 1 048 576 bytes. This will help to remove ambiguity. ""Almost standard"? More like, not standard now, never will be. Big B is 'bel', small b is something else, I believe..." Because B refers to an audible pressure (or something similar), it will not be confused with an electronics data unit. I'm sure that this is also specified somewhere, but while I try to find it... what would you propose as workable symbols for byte and bit? "We should write out what we mean, to not add to the deception hard drive, video game, modem, and broadband companies perpetuate. "543 kbytes recieved at 12.3 kbytes/s"." And does "543 kbytes" mean 543 x 1 000 bytes or 543 x 1 024 bytes? Also note that it is incorrect to mix symbols/abbreviations with full names, so it must be: kB or kilobytes, but not kbytes (sadly older versions of Netscape used this terminology).
I was unaware of the binary standard <URL:http://physics.nist.gov/cuu/Units/binary.html> as mentioned by firstname.lastname@example.org. I agree that this should be considered.
I've said this before and I'll say it again, this is a good candidate for a localization "en-SI" feel free to work on it.
*** Bug 124336 has been marked as a duplicate of this bug. ***
If I may make one suggestion for a change that should take place throughout Mozilla... All references to "KB" should be changed. "KB" is the unit for kelvin-bytes. A kilobyte, literally interpreted (accepting the historical confusion between a 1000 byte kilobyte and a 1024 byte kilobyte), should be labeled "kB." Bytes are represented by a capital B, bits are represented by a lowercase b, so we should also make sure all references to that are correct. 1024 bytes = 1 kB. NOT 1 kb or 1 KB, or worse yet, 1 Kb. I'm not expecting this to be fixed, but it really should.
timeless: I believe that the proposal/standard should in fact be the standard behavior in Mozilla, but I'm willing to work on a localization. From the brief bit of reading I've done of the l10n page, it seems that this would completely replace the en_US (or other) locale. Is there some way to just provide this as an extension to an existing locale, or do I need to distribute an entire locale file with all the other text strings included? I would like this work to be applicable to other English locales, or (better still) all locales. Also, I'm downloading the source over a dial-up modem line, so I'm not going to be able to download the source frequently. Is the 0.9.8 source an appropriate place to start? I guess many of these questions will be best answered when I untar the sources, but it'll take quite some time to download. Any help on these matters would be appreciated.
Status: NEW → ASSIGNED
thought I would've been added to CC list when accepting...
Created attachment 70059 [details] [diff] [review] premliminary diff with most occurences of "KB" changed to "KiB" This is a simple diff -ur performed between the contents of the original en-US.jar chrome file and a modified version with "KB" changed to "KiB" wherever I saw it. I have not changed megabytes, gigabytes, bits, or anything else, only KB to KiB. I have not tested using this. I'll try zipping the files up into an en-SI.jar a little later.
I notice that this string is supposed to be changeable with the /kb.label/ entity. I have concerns that there may be no equivalent options for megabyte, gigabyte, and so on, making it very difficult for us to provide consistent SI binary units (MiB, GiB, ...). This further reinforces that the default (hard-coded) strings should be changed to the (debateably) correct symbols. In the mean time, I'll raise a bug based on this assumption (to provide localized strings for megabyte and so on), or else we'll get nowhere.
The concept I had is that this behavior should be standard (default), and should be true for all locales as the standard is international. I have raised bug 126168 for the implementation of an SI-compliant (English-based at first) locale, as suggested in comment 16.
you should not accept on behalf of someone you do not know
Status: ASSIGNED → NEW
I just clicked "accept bug", and was rather surprised that it was somehow given to mpt. How come it wasn't assigned to me?
bugzilla has an odd ui behavior. for managers and delegates its behavior is ok, for everyone else you just have to remember to reassign it to yourself (or ask someone to reassign it to you). If you're going to make a patch for mozilla en-US please make it use kB. For any other unowned localization feel free to proposed the -SI units. As you noticed the correct thing to do is to factor it into the localization files so that *ideally* it is only hard coded on *one* line of *one* file (and that file is a .dtd or .properties file)
Assignee: mpt → michael
My wish is for this to be integrated into the standard distribution, but I agree that there is a current lack of support, and so am working on a new en-SI locale (bug 126168) as you suggested here (comment 26). The patch is more relevant to bug 126168 (at least in the sort term ;-), but that bug didn't exist when I uploaded the patch. I need to go to sleep now, but I'll transfer the patch to said bug when I get a chance, at that point I may need someone's help to delete the patch from here, if that's what you're suggesting. In particular, I'm keen that this bug stay open for a little while to encourage discussion, as I don't seem to be the only one who is requesting this behavior. I'm happy to do as you wish regarding creating a new locale, and what to, and what not to attach to this bug, provided you don't close it! :-) Sorry for any inconvenience. Hope this clears things up. Out of interest, are you suggesting there's an immediate need for patches "right here, right now"? (Your most recent comment seems to suggest you want patches to change "KB" to "kB", but I think this is probably a misunderstanding. I have no great interest in this change at present, however the SI locale would use kB rather than KB if 1000 bytes were intended.)
michael: It was decided in bug 106618 that "KiB" et al. would not be present in Mozilla. That would break tradition and create confusion over a paltry issue involving 24 bytes per kilobyte. (And for the most part, 1000-byte kilobytes are only referenced in casual conversation or by hard drive manufacturers.) However, there is a serious problem about confusion over the correct units. Most important is that bytes is a capital B and bits is a lowercase b. Also important is that we use the correct case for SI prefixes (mega-, giga-, and tera- are all uppercase, but kilo- is always a lowercase k). Even if the kelvin-bytes thing isn't ever likely to come up, if we're lax about how we form the k, we'll get lax about how we form the B later on--and end up creating much worse confusion over bits and bytes. Any changes that are made should be left as flexible as possible so anyone who decides they want to use KiB as the unit for 1024 bytes can do that without many hassles.
Skewer: I agree the difference between kB (1000 bytes) and KiB (1024 bytes) is minimal, but there is a difference. Have a think what happens when referring to larger units. | powers of 10 | powers of 2 | ratio | "kilo" | 1000 | 1024 | 1.03 | "mega" | 1000000 | 1048576 | 1.05 | "giga" | 1000000000 | 1073741824 | 1.07 | "tera" |1000000000000 |1099511627776 | 1.10 | There is definately a discrepancy, and it becomes quite noticeable with larger data sizes. It is quite clear that KB, MB, GB, and so on have come from SI prefixes, and SI specifies that these prefixes always mean multiples of powers of ten (10^3, 10^6, 10^9, and so on). To use these prefixes for anything else is incorrect, regardless of how "close" some perceive them to be. Some suggest that changing to "KiB", "MiB", and so on where appropriate is confusing. It is *the existing notation* that is confusing and incorrect. How do you think a physicist (or anybody else familiar with SI -- seemingly anybody that doesn't live in the US or UK) new to computing might interpret such incorrect prefixes? In case this point wasn't clear, 1024 bytes != 1 kilobyte. Would deliberately decide to talk about yards as being 35 inches in computing (they're normally 36 inches, right?), just because van Neumann (or some other prominent computing founder) had small feet? :-P I am not able to present this point well. If the argument to follow stanards is not self-evident, then I don't know what I can do to convince you.
I'm not proposing any dramatic changes. I'm suggesting we change our units from "kelvin-bytes" to "kilobytes." How big a kilobyte is will be up to the Mozilla team, however I guarantee that that's the unit we're going to use. If we report a kilobyte as 1000 bytes while the rest of the operating system reports a kilobyte as 1024 bytes, discrepancies will be introduced which create a much worse problem than a minor (and historically accepted) mistake with SI notation. So in other words, "KB" as the unit for kilobytes isn't okay, but calling a kilobyte 1024 bytes is. If that kind of thinking is too radical for Mozilla, my apologies.
Skewer, your logic baffles me. You do not mind overlooking that kilo is always exactly 1000 (except when computing hijacked the term), yet argue about the case of a letter that is dubious in any case (I wish they had standardized on all upper case for positive exponents, but we're not about to change that.) I have done a substantial amount of research into standards, and I believe your comments show a lack of familiarity with SI. These are some problems with your comments: 1. When units are multiplied, they should have a middle dot between them (to signify multiplication), so kelvin bytes should be K.B (pretend the period is a middle dot) 2. "kB" is not a unit. It is a symbol for kilobyte. kilobyte is the unit. 3. *all* unit names should be lowercase when written in full. this means that the correct case is "kelvin", not "Kelvin", regardless of its symbol. You can't choose to include the bits you like and leave out the bits you don't, full compliance with all parts of the standard *is what makes it a standard*. This bug is for the notation of data sizes *entirely* according to SI, not just the bits you want. (Admittedly, I was not fully aware of the SI binary standard when submitting this bug, but have since learned of the recently adopted standard, and now believe this is the correct behavior.) I agree that there is inconsistency between applications, however there are several different ways I have seen to denote a binary kilobyte: 1. "k" (this is from way back, and is completely wrong) 2. "K" (same as above) 3. "KB" (misapplied SI standard, tried to unify positive exponent prefixes) 4. "kB" (misapplied SI standard, actually means 1000 bytes) 5. "kb" (actually means kilobits, so is quite incorrect) 6. "KiB" (SI binary standard) 7. "kiB" (misapplied SI standard) 8. "KKB" (Knuth's proposal) Whilst I conceed that  is now the most commonly seen, all of 1 thru 5 can be frequently seen. The only one I have seen that has been approved as a standard (with support of several international bodies, including IEEE, I believe) is . In this light, other applications should also make sure they use the SI binary prefixes (and I have contacted several maintainers accordingly). Don't we both have other things we should be doing? Let me work on my en-SI locale, and if you really want 1024 bytes denoted as kB (which, as I have already explained is incorrect, and is also not the same notation as most applications and/or operating systems use -- one of your claimed reasons for the change), then please file a new bug.
Skewer: I am not Mozilla. Apparently my thinking (and presumably that of those who worked on previously mentioned SI binary data unit standard) is also too radical. :-( There is no need to apologize. ;-)
I'm not proposing any dramatic changes. I'm suggesting we change our units from "kelvin-bytes" to "kilobytes." By this logic, you could also suggest that "KB" is the symbol for kelvin bel. It is acknowledged that there are a finite number of readily-available alphabetic characters, and so overlap is permissible where the symbols are used conjointly in vastly different fields/areas, so that no reasonable confusion can exist. Surely you don't really look at "KB" and interpret that as kelvin byte without at least thinking: "I know what this is really meant to mean, but..."
I hate repeating myself for people who don't pay attention. "It was decided in bug 106618 that "KiB" et al. would not be present in Mozilla. ...I guarantee that [kilobytes are] the unit we're going to use." With that in mind, we are left with the decision of whether to mark kilobytes as "kB" or "KB", and whether those kilobytes are going to be 1024 bytes or 1000 bytes in size. Obviously we aren't going to start using 1000-byte kilobytes in Mozilla, the mere thought of that is ridiculous. My reasoning for being picky about how we form the k in kB was "[e]ven if the kelvin-bytes thing isn't ever likely to come up, if we're lax about how we form the k, we'll get lax about how we form the B later on--and end up creating much worse confusion over bits and bytes." It's a trivial issue, but we ought to at least be correct in this aspect. Two wrongs (1024-byte kilobytes and improperly capitalized "K" prefix) don't make a right, you know. And can you explain to me what purpose this bug serves, if it isn't to choose how to label kilobytes (short of changing the units to KiB, which was shot down in bug 106618)? It seems wasteful to file yet another new bug for this.
"And can you explain to me what purpose this bug serves, if it isn't to choose how to label kilobytes". You, also, are not paying attention. The "kilobytes" you are referring to are not regular decimal kilobytes, they are binary kilobytes (termed "kibibytes"). kilobyte (kB) = 10^3 bytes = 1000 byte kibibyte (KiB) = 2^10 bytes = 1024 byte It is quite clear that a true decimal kilobyte should have symbol "kB", however to label a 1024 byte entity "kB" goes against SI as huftis has pointed out. Again: the "kbytes" Mozilla is talking about are kibibytes, not kilobytes, so they should not be labeled as kilobytes. The issue is *full* compliance with SI standards, not just the bits you want. You can not change a long-standing standard (kilo as 1000 has been around long before computer science) just because it suits you. SI is not intended to be modified for every field to make it seem "right", it is intended as an arbitrary system that is international, simple, and precise; the numbers aren't always meant to look neat. Using SI prefixes in the way you suggest weakens the entire standard. If the majority of Americans were truely familiar with SI, I doubt we'd be having this discussion.
Comment #34: > And can you explain to me what purpose this bug serves, if it isn't to choose > how to label kilobytes (short of changing the units to KiB, which was shot down > in bug 106618)? Sure. The purpose of this bug is to have datasizes displayed in a standard and unambiguous way. Also, since the filesizes are currently being displayed as "binary prefix" numbers, the purpose of this bug is really not to "choose how to label kilobytes", but how to label the numbers we are currently displaying - namely Kibibytes. BTW. The other bug was (thankfully) not "shot down", it was wontfixed "for now"!
I propose two changes. The first change would add the ability for Mozilla to report sizes in 1024 byte or 1000 byte chunks. As an example, the GNU du command does with its --si option (although I am not proposing a command line option for Mozilla). The second change would allow the user to select between one of three display formats: 1) Convential. 1024 bytes reported as KB. 2) SI-1000. 1000 bytes reported as kB. 3) SI-1024. 1024 bytes reported as KiB.
Created attachment 105041 [details] 59.4 kB rounded is 59 kB, but this is 60 kB. Reality is that SI units are already in use, at least on Mac OS X.
*** Bug 222850 has been marked as a duplicate of this bug. ***
bug 106618 reopened.
*** Bug 268675 has been marked as a duplicate of this bug. ***
I would like to offer my support for changing the K to a k, in accordance with SI. Also, if the binary prefixes are not to be used, then the 1000-bytes-in-a-kilobyte definition should be used. See also bug 126173.
All units should use SI prefixes (powers of 10). Powers of 2 seem to be only useful for developers, but not for the average user. So please use kB for 1000 byte and MB for 1,000,000 byte.
A byte by itself is no metrics but a binary unit, and stands for 2³ binary digits, so powers of 10 are not logical in any way for dealing with bytes, only powers of 2 make any sense at all there. That would be different of course if the smallest unit decimal, but it's binary, actually. As a side note, there are SI prefixes for powers of 2, as far as I know, so comment #43 is even more inaccurate in that sense.
Mac OS X Snow Leopard has switched to using powers of tens for kilo, mega, etc. Firefox should change to powers of ten at least on Snow Leopard.
Ubuntu has adopted a similar policy, quoting https://wiki.ubuntu.com/UnitsPolicy --- 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) --- It optionally allows showing additional base-2 values with correct SI prefixes. (In reply to comment #44) > A byte by itself is no metrics but a binary unit, and stands for 2³ binary > digits, so powers of 10 are not logical in any way for dealing with bytes, only > powers of 2 make any sense at all there. This is a non-sequitur, the number of bits in a byte (POSIX mandates 8 bits per byte) has nothing to do with what is discussed here.
You need to log in before you can comment on or make changes to this bug.