Has anybody made an ACTUALLY monospaced font? Where stuff like emoji and weird Unicode letters ⓛⓘⓚⓔ 𝓣𝓗𝓔𝓢𝓔 are the same width as an i and an m?
@sil unless I'm mistaken, that would be against the unicode spec - is a full-width character so it should take two spaces, as are many asian characters (ex ឤ)
spec annex: https://www.unicode.org/reports/tr11/
this rust crate doc I've never used is helpful: https://docs.rs/unicode-width/latest/unicode_width/#rules-for-determining-width
(this is possibly me way not getting the joke, but I've been interested in calculating accurate unicode string width in a terminal)
@llimllib really? it's not meant to be possible at all??
OK, didn't know that. Also that's really annoying in my monospace text editor :)
@sil yeah, I think it's basically an encoding of how asian languages were supported pre-unicode-standard; some characters were "half-width" (which in the terminal means width 1) and others "full-width" (2 grid spaces)
@sil and basically every terminal emulator gets it wrong all the time!
@mitchellh wrote about it here, he had to implement a worse method to be compatible with other terminals: https://mitchellh.com/writing/grapheme-clusters-in-terminals
@llimllib @mitchellh nightmare.
I don't think I'd mind if I could make my text editor display extra-width characters as double width exactly. It's that they're fractions of a width, so if you're doing some sort of monospace grid and you want to use non-ASCII characters, nothing lines up at all, and it's really annoying!
@mitchellh @llimllib Sublime Text, 'cos I'm editing files which are grids for tile-based levels in a game and that's my text editor. Maybe I should look around for others...!
@sil @mitchellh Here's kitty+neovim nightly, ghostty+nvim, and textedit
Kitty displays entirely the wrong emoji
Also I've reposted because fonts affect character width! Monaco made the ④ a double-width, but iosevka has it as a single width. All these fonts in the screenshot are iosevka term slab
@mitchellh @sil That’s why I was surprised that in Monaco it was different
@sil Is the problem here that the non-Latin characters are being swapped in from a different font that has different metrics?
@mavit it is. I don't actually know a solution to this other than "make one font which has every character in it and they're all the same width", which is the thing I was vaguely hoping someone had already done :-)