Hacker News new | ask | show | jobs
by eadmund 935 days ago
>> Unicode defines a decimal separator key symbol (⎖ in hex U+2396, decimal 9110) which looks similar to the apostrophe. This symbol is from ISO/IEC 9995 and is intended for use on a keyboard to indicate a key that performs decimal separation.

Egad, settling the ./, issue by selecting ⎖ is like settling the debate between 0-based arrays and 1-based by numbering them from ½. Or between little- and big-endian by choosing middle-endian.

2 comments

Note the keyboard part. I think this is meant to be what they can physically print on the numpad section of an international-style keyboard. When you're typing numbers in a Euro locale you'd get `,` but in US English you would get a period. (At least, I hope that's what the decimal key on the numpad does when you set your locale to a certain locale. It would be obnoxious if when typing numbers in an English context, you had to go find the period key on the other side.)

I don't think we're meant to normally switch to actually putting that character in our numbers though. If so, clearly nobody has agreed to do it!

Huh, I don't see it that way. It's totally unambiguous, there would be no way for that character to have entered the number without it being the decimal separator.

Contrast that to choosing either a period or a comma and your setting yourself up for serious potential errors.

Obviously the user doesn't need to see that symbol, you can localize it however you want.