Open DivineDominion opened 1 year ago
Oh that would be great if you can fix it. I'm using the nerd font that guarantee glyhp to be one character wide but I noticed the problem with emojis. How do you get the string width in pixels though?
How do you get the string width in pixels though?
I have no clue, yet. :) Will be asking around!
https://www.gnu.org/software/emacs/manual/html_node/elisp/Size-of-Displayed-Text.html
This looks promising: https://github.com/emacs-mirror/emacs/blob/master/lisp/emacs-lisp/subr-x.el#L318
No time to try until later today, though.
@rougier Thank you for the wonderful theme!
@DivineDominion Did you manage to fix this?
I would have loved to do this, but I don't know how to go about doing this.
The proposed look and feel is great! 👍
I have display issues with the statuses, though: This depends on the font being used, I guess, but not all emoji are of the same width. Some take up 2 characters. This doesn't gel well with right-aligning, though, in some circumstances like this one:
I believe once we calculate the width of the string with the faces applied, we could use
:align-to (- right (??? . px)))
, i.e. specify the unit in pixels instead of characters: https://www.gnu.org/software/emacs/manual/html_node/elisp/Pixel-Specification.htmlI also found that
mastodon-alt-tl-show-status
is not used at all a.t.m. so I couldn't toggle the statuses off completely. I'm adding a PR in a second.