help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing colour of ruler-mode-current-column


From: Stefan Monnier
Subject: Re: Changing colour of ruler-mode-current-column
Date: Sun, 11 Sep 2022 10:15:50 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

>   (add-hook 'window-configuration-change-hook (lambda () (ruler-mode 1)))

A.k.a (add-hook 'window-configuration-change-hook #'ruler-mode)

But to tell you the truth, I have no idea why you'd want to re-enable
ruler-mode every time the window-config changes.

ruler-mode is a buffer-local minor mode, so you'd normally install it
into a major-mode hook so as to enable it in those buffers where you
need it.

>  (set-face-attribute 'ruler-mode-current-column nil :background "#ff4500" 
> :foreground "#ffffff") )

I'd stay away from a fiddly low-level function like `set-face-attribute`
and change face settings via Custom instead (or if you really want to
avoid Custom, use something like `face-spec-set`).


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]