unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Stefan Monnier via Users list for the GNU Emacs text editor <help-gnu-emacs@gnu.org>
To: help-gnu-emacs@gnu.org
Subject: Re: What are the criteria for making a minor mode ?
Date: Mon, 26 Aug 2024 12:59:31 -0400	[thread overview]
Message-ID: <jwva5gz8bs7.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: 9rr0Dgg51MtYPbbebhRKrLwUYtK4qqWiZYFTC2bWnrp4MHlaysV_HVIr8k9t-nIy5DtPLuKVYnMHZSt-NSVpwVvcYwt_Bz756abanQFH_aU=@protonmail.com

> One can just add code to a file and require it.

Do remember that loading a file should not significantly change Emacs's
behavior (this is a convention on which Emacs relies occasionally to
"enthusiastically" load files without an explicit request to do so,
e.g. to try and generate a better docstring, or to try and find out what
functions that file defines).

> Ar make a minor mode.  What are the criteria for making a minor mode
> justified ?

You don't need any justification.  You can define as many minor modes as
makes you happy.  It's cheap, don't hold back.


        Stefan




  reply	other threads:[~2024-08-26 16:59 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-08-26 15:54 What are the criteria for making a minor mode ? Heime
2024-08-26 16:59 ` Stefan Monnier via Users list for the GNU Emacs text editor [this message]
2024-08-27 17:20   ` Heime
2024-08-27 21:08     ` Rudolf Adamkovič
2024-08-27 21:27       ` Heime
2024-08-29 10:50         ` Rudolf Adamkovič

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwva5gz8bs7.fsf-monnier+emacs@gnu.org \
    --to=help-gnu-emacs@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).