How to insert and right-align text that is not of the default font size?
This doesn't work:
(let* ((text "abcd")
(len (length text)))
(insert
"\n"
(propertize " " 'display `((height 0.5) (space :align-to (- right (,len . width)))))
(propertize "12345" 'font-lock-face 'error 'display '(height 0.5))
"\n"))
12345
on the right side of the screen at you?