Ligatures in programming fonts
tinyletter.com
Ligatures in programming fonts
1–10 of 87 posts
Re: Ligatures in programming fonts
#2But in a monospace font? No. No. No. no. No.
Epicly bad plan to use something like that to display code
Re: Ligatures in programming fonts
#3I didn't even know those were a thing But in a monospace font? No. No. No. no. No. Epicly bad plan to use something like that to display code
Re: Ligatures in programming fonts
#4I didn't even know those were a thing But in a monospace font? No. No. No. no. No. Epicly bad plan to use something like that to display code
Re: Ligatures in programming fonts
#5I didn't even know those were a thing But in a monospace font? No. No. No. no. No. Epicly bad plan to use something like that to display code
Re: Ligatures in programming fonts
#6Re: Ligatures in programming fonts
#7"The existing ligatures exist basically for compatibility and round-tripping with non-Unicode character sets. Their use is discouraged. No more will be encoded in any circumstances.
"Ligaturing is a behavior encoded in fonts: if a modern font is asked to display “h” followed by “r”, and the font has an “hr” ligature in it, it can display the ligature. Some fonts have no ligatures, some (especially for non-Latin scripts) have hundreds. It does not make sense to assign Unicode code points to all these font-specific possibilities."
The second problem still stands, though, especially since these sequences of characters can be tokenized differently in different programming languages. IMO, if you're going to have character replacement like this, it should be a configurable editor feature like syntax highlighting.
Re: Ligatures in programming fonts
#8Re: Ligatures in programming fonts
#9But that's not new. C++ allows zero width spaces in identifiers. There's a guy on reddit who uses characters from Canadian Aboriginal Syllabics block to have angle braces in Go identifiers.
Yes, they are guaranteed to be wrong sometimes. The big one is the But it's incredibly obvious when they are wrong. So it's not an issue in practise.
The reality is that no one is making anyone use a ligature font, and some people like them. If it's causing a problem then you can spend ten seconds changing your font.
Re: Ligatures in programming fonts
#10I didn't even know those were a thing But in a monospace font? No. No. No. no. No. Epicly bad plan to use something like that to display code
What's bad about them? (I find the arguments in the link interesting, but not all that convincing)