[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Setting rectangle-preview face in init.
From: |
Stefan Monnier |
Subject: |
Re: Setting rectangle-preview face in init. |
Date: |
Fri, 11 Oct 2019 12:41:33 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
> I don't like to use Customize interfaces because:
I don't either, but for faces I've found its advantages are significant
compared to the various problems with set-face-attribute.
> 3) Some complex setups breaks it (like defining conditional faces
> depending of some if conditions (window-system, (display-graphic-p)).)
Given that Emacs can have GUI and tty frames within the same session, if
you want your config to work reliably, the
window-system/display-graphic-p/... tests need to be re-executed for
every frame created (rather than calling set-face-attribute such that it
applies to all frames).
Custom actually does let you deal with that by specifying different
attribute values depending on window-system/display-graphic-p/...
(the UI isn't great for that, so I typically edit the custom-set-faces
by hand to do that, which is of course not recommended either, ...).
> I won't ask for a change for anything of this,
FWIW, I think it'd be good to have Elisp-access to Custom's
face manipulation so you wouldn't have to choose between the two,
Stefan
Re: Setting rectangle-preview face in init., Eli Zaretskii, 2019/10/11