Subject: bug#46476: Feature request: Right-aligning part of the modeline

From: Paweł Kraśnicki <[email-masked]>
Date: Fri, 12 Feb 2021 23:59:26 +0100

Many people who use Emacs with significant customization have their modeline
split into left and right aligned parts. I've also seen the Lisp code for this
in several packages. I think it would be useful to have this feature as a
%-construct so that the users who want it wouldn't have to install a package or
write custom Lisp that uses the `display' text property.

Everything after this construct would be aligned to the right. For example,
assuming the construct was %=, the mode-line-format

"l%=r"

would cause the modeline in a 20 character wide window to look like

l                  r

It could also be useful to generalize this to centering, though I've seen this
used less often. Then, the mode-line-format

"lllll%=c%=r"

would cause the modeline to look like

lllll     c        r