this post was submitted on 05 Sep 2024
515 points (98.3% liked)

interestingasfuck

1330 readers
1 users here now

Please go to !interestingshare@lemmy.zip

founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] Zagorath@aussie.zone 2 points 2 months ago (2 children)

(e.g. $27 000)

Ok so they're winning $27, but I thought it was filmed in America, not Australia. Shouldn't that be $27 911?

/s, obviously.

But more seriously, yeah a space is brilliant. But you shouldn't use U+0020, the space you get when you press spacebar. It's awkwardly wide for this purpose, and more importantly it can break the number over two lines if it happens to line up that way.

The best alternative is U+202F, which is both narrower and non-breaking. Wikipedia claims that the official SI recommended character for thousands separation is U+2009, the thin but breaking space, but I read their source and did not see this supported. It seemed to just say space, without specifying which type of space. There is of course also U+00A0, the no-break normal-width space. Any of these would be better than U+0020.

The problem is them being difficult to type, which is probably why most people tend towards the comma instead. It's automatically non-breaking and doesn't have the awkward wideness of U+0020.

Incidentally, SI specifically allows for either the comma or the point to be used as the decimal separator. As long as the thousands separator is a space, this can introduce no ambiguity.

[–] Fiivemacs@lemmy.ca 2 points 2 months ago (1 children)

Why do you know various space characters..

[–] Zagorath@aussie.zone 2 points 2 months ago (1 children)

Why not?

I didn't have the specific Unicode codes memorised. Those I found on Wikipedia. But the knowledge that there exist spaces of different sizes and the non-breaking space just comes out of my general interest in computers across the board.

[–] Fiivemacs@lemmy.ca 1 points 2 months ago (1 children)

I assumed you had it all memorized like some kind of warez ASCII NFO creator.

I only have alt-255 whitespace memorized from my ultima7 cheating days

[–] Zagorath@aussie.zone 2 points 2 months ago

I have a few alt codes memorised, but not very many. 0151 and 0150 are — and – (em and en dash) respectively 8230 is ellipsis, except for some reason that doesn't work in all applications, including web browsers.

255 is apparently the non-breaking space, so same as U+00A0 mentioned above. It can also be written in some websites (including here) with  . Like this.

[–] warm@kbin.earth 1 points 2 months ago

Yeah, but aint nobody got time for that. Just hit the spacebar.