4 ms·
You can put a thin space before and after the em dash. This space is narrower than a normal letter space. Example with a normal space: The quick brown fox jum
by open-source-ux 9y ago
You can put a thin space before and after the em dash. This space is narrower than a normal letter space.
Example with a normal space:
The quick brown fox jumps over — and, sometimes, under — the lazy dog.
Example with a thin space:
The quick brown fox jumps over — and, sometimes, under — the lazy dog.
This Smashing Magazine article discusses spaces in more detail. At the bottom of the article is a list of different spaces and their corresponding HTML entities:
https://www.smashingmagazine.com/2015/10/space-yourself/ https://www.smashingmagazine.com/2015/10/space-yourself/
- kps 9y agoIncidentally the author of that article, Marcin Wichary, (a) has many awesome photos of historical computing and typography, among other things, almost all CC-licensed¹, and (b) co-wrote the Pac-Man Google doodle². ¹ https://www.flickr.com/photos/mwichary/albums/page1 https://www.flickr.com/photos/mwichary/albums/page1 ² https://www.google.com/doodles/30th-anniversary-of-pac-man https://www.google.com/doodles/30th-anniversary-of-pac-man
- Udo_Schmitz 9y agoWhat font do you use to read hackernews? Because in Verdana those are exactly the same. Tried some other fonts in inspector but think your thin spaces could be even thinner :)
- dpwm 9y agoNot the commenter you're replying to, but on my system I see a difference between the two examples they post. This is because hackernews has font-family: Verdana, Geneva, sans-serif and I have neither of the named fonts installed. On my system, hackernews is rendered using Dejavu Sans. This is presumably a default for Firefox on linux which I never realised until today.
- open-source-ux 9y agoWhat font do you use to read hackernews? I'm using the default Verdana font. Here's a screenshot of what the post looks like on my computer (Firefox on Windows). https://imgur.com/a/QqmeC https://imgur.com/a/QqmeC I guess I should have added a disclaimer to say that the thin space may not always appear correctly depending on the browser/platform/setup etc. :-)