On Friday, July 25th, 2025 at 11:20, Fraga, Eric <e.fr...@ucl.ac.uk> wrote:

> just as an example of a mode line that uses the
> mode-line-format-right-align.

Thanks!  This got me off to a good start.  I also watched Prot's video on mode 
lines¹ which was very helpful.  I settled on this:

(setq-default mode-line-format
              (list
               "%e" ;; Memory error. Do I need this? Everyone seems to include 
it.
               mode-line-front-space
               "%@ %+ " ;; Remote editing?  File modified or read-only?
               (propertize "%n " 'face 'warning) ;; Narrowed?
               (propertize "%b " 'face 'bold) "  " ;; Buffer name
               "%l (%p of %I)    " ;; Line number (percent into file of size)"
               '(:eval vc-mode )
               "    "
               mode-line-modes
               ;; RHS
               'mode-line-format-right-align
               mode-line-misc-info
               mode-line-end-spaces)
              )

And I use this to make the clock look like the rest of the mode line (without a 
bright background) but be slightly slanted.  I'm quite pleased with how it 
looks now.

  (set-face-attribute 'org-mode-line-clock nil :inherit nil :slant 'italic)

Cheers,

Bill

¹ https://protesilaos.com/codelog/2023-07-29-emacs-custom-modeline-tutorial/

--
William Denton
https://www.miskatonic.org/
Librarian, artist and licensed private investigator.
Toronto, Canada


Reply via email to