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

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

Re: Customisation for Comments


From: goncholden
Subject: Re: Customisation for Comments
Date: Fri, 11 Feb 2022 22:59:32 +0000

------- Original Message -------
On Friday, February 11th, 2022 at 10:23 PM, Emanuel Berg via Users list for the 
GNU Emacs text editor <help-gnu-emacs@gnu.org> wrote:
> goncholden wrote:
>
> > I am relatively new to elisp planning and could do with
> > suggestions. The plan is to make this available to users,
> > and though minor-modes are the way to do things.

> Sounds to me like you just need one function to increase the
> contrast. Then maybe another function the decrease it, by
> sending a negative value, and perhaps a couple of more
> functions that are all just helper functions around the
> first one.

Eman, I have done all that and put things in a minor-mode.  What
I have a problem with is about whether or not to use a minor-mode,
major-mode, or a derived mode (derived from a major-mode).

To change comments to normal weight, I utilise set-face-attribute.

(set-face-attribute 'font-lock-comment-face nil :weight 'normal))

Perhaps using face-remap-add-relative has advantages.  What would you recommend?

(face-remap-add-relative 'font-lock-comment-face :weight 'normal))

I think that face-remap gives buffer-local changes.  Would this be appropriate?



reply via email to

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