4 ms·
Spaces are significant, but now we have unicode, we can stop thinking about the number of spaces and start using the correct unicode character for the type of s
by perilunar 3y ago
Spaces are significant, but now we have unicode, we can stop thinking about the number of spaces and start using the correct unicode character for the type of space we want. Unicode has at least 16 different types of space character.
As an experiment, here is some text with differing spaces. I wonder if HN can handle it:
En space between sentences: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent eu ullamcorper mi, id dictum nibh. Pellentesque fermentum efficitur viverra. Ut tincidunt ut nunc non viverra. Nunc accumsan ultrices libero ut efficitur. Vestibulum a eros a urna vestibulum tempor. Ut vel sodales tellus. Aliquam enim velit, varius eget mi ut, blandit dictum nulla. Quisque non malesuada felis. Duis sit amet sapien at risus efficitur fermentum. Aenean posuere tempus elit, nec eleifend tellus bibendum a. Suspendisse potenti.
Em space between sentences: Pellentesque semper sed enim a rutrum. Suspendisse iaculis laoreet leo, a tristique lorem tincidunt id. Ut lacinia, sem a sodales fermentum, leo diam elementum elit, vitae egestas risus velit non magna. Curabitur nec ligula quis sem imperdiet rhoncus sit amet a lorem. Donec ut risus sapien. Aenean et nisl quam. Aenean nec interdum metus, quis vulputate enim. Interdum et malesuada fames ac ante ipsum primis in faucibus. Nunc pulvinar molestie imperdiet. Etiam non nisi id leo blandit placerat vel ac ligula. Duis in urna quis erat dignissim pellentesque hendrerit sed sapien. Pellentesque tempor magna eu lacus laoreet tempor. Fusce nec tortor sed urna placerat bibendum eu id mi.
[edit: no, it can't. They work in plain HTML, so I guess the HN form is converting them to plain spaces.]
[edit, the second: try html entities [removed] — doesn't work either.]
- deleted 3y ago[deleted]
- kortex 3y ago> start using the correct unicode character for the type of space we want. but why
- nutate 3y agofrom NASA: Space exploration helps to address fundamental questions about our place in the Universe and the history of our solar system.
- bluepod4 3y agoExplains the lack of emojis sews thread
- cwbrandsma 3y ago16 types of space characters...but I don't want to think that hard.
- jerf 3y agoThe good news is, you don't have to think that hard. A number of them are language specific, or very specific to a particular context. The bad news is, with European languages having the longest tradition of printed word, they also still have quite a few varieties. And in a 2023 where even today I can get oohs and aahs from multi-decade white-collar professionals when I show them that you can automatically generate a table of contents for a document if you just use the "Header 1" and "Header 2" formatting stuff correctly, I can't imagine a world where people are routinely entering multiple types of spaces typographically correctly. (Which type of space is the best to use when holding the space bar down to center something, anyhow?)
- nomel 3y agoI recommend that the space bar be broken up into at least three space buttons, to make this stance practical.
- jacobsenscott 3y agoI was going to say you need 5 space buttons to chord all possible spaces, but I guess you can use 3 space buttons in combination with ctrl, (alt|option), and (win|command).
- perilunar 3y agoWe could use [space], option+[space], and option+shift+[space] to give a regular space, an en space, and an em space respectively. This would be similar to hyphen-minus/en-dash/em-dash, so easy to remember. And it could be done in software.
- terom 3y ago>>> 1, 2 File "<stdin>", line 1 1, 2 ^ SyntaxError: invalid character in identifier The reason for `xbd_options nbsp:none`...
- yellowapple 3y agoWhy three? Only two kinds of space are necessary for the vast majority of English-language text: one to delimit words, and one to delimit sentences.
- throwaway73454 3y agoYou are probably joking, but there are typewriters with split space bars exactly for this reason.
- Terretta 3y agoThis made me curious whether HN collapses dashes as well. These all render the same in the text entry box: - hyphen – n dash [option -] or [Alt + 0150] — m dash [option-shift -] or [Alt + 0151] Also, these render as 3 spaces or single space wide in the text entry box: ... three periods … ellipsis [opt ;] or [Alt + 0133] EDIT: So the - – — work, and can visually suggest what should be happening in one's typography if you do not double space after sentence ending punctuation.
- throw0101a 3y ago> … ellipsis One slight annoyance I have on my Mac(s) is that if you have an ellipsis following by a period, you can tell the difference between the two. I would think it's more proper (?) that all the dots transparently flow together: ….
- mr_toad 3y agoThree shalt be the number thou shalt count, and the number of the counting shall be three...
- naikrovek 3y ago> but now we have unicode, we can stop thinking about the number of spaces and start using the correct unicode character for the type of space we want. my keyboards only have one spacebar, man. that means things I type get one type of space, though there can be multiple spacebar presses in a row.