News for hackers. Stuff that matters.
Re:Monospaced Programming Fonts with Ligatures by mikewhy on Friday July 21, 2017 @02:46PM (#14822877)
HN is a web page, and HTML swallows multiple-spaces into a single space.
Re:Monospaced Programming Fonts with Ligatures by thanatropism on Friday July 21, 2017 @03:00PM (#14822990)
Let me test                 something.

Edit: crap, doesn't work

Re:Monospaced Programming Fonts with Ligatures by problems on Friday July 21, 2017 @04:19PM (#14823530)
Unicode has some wonky characters - I use zero-width space, probably the most ridiculous of them to bypass filters at times. For intentionally wide spaces you have a few options:

Test unicode non-breaking space.

Test                                                                    unicode  narrow no break space.

Test                            unicode figure space.

EDIT: So there you have it, if you want a non-breaking space on hackernews, use unicode's figure space or narrow non-breaking space. Apparently they already filter out the normal non-breaking space.

Re:Monospaced Programming Fonts with Ligatures by mkl on Friday July 21, 2017 @06:41PM (#14824267)
Please don't do this. It's unreadably broken on mobile Chrome (turns into a gigantically wide space).
Re:Monospaced Programming Fonts with Ligatures by arianon on Friday July 21, 2017 @03:44PM (#14823314)
I'm pretty sure that if HN allowed you to do what you just tried, it would be a XSS vulnerability. :P
Re:Monospaced Programming Fonts with Ligatures by Stratoscope on Friday July 21, 2017 @03:55PM (#14823380)
Nah, you can do it on Reddit because they use Markdown instead of HN's homegrown comment formatter. In case you ever need to post a proportional font code sample over there, the trick is to use   for all the leading spaces, and also add two regular spaces at the end of each line before the last one.