all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Po Lu <luangruo@yahoo.com>
To: goncholden <goncholden@protonmail.com>
Cc: goncholden via Users list for the GNU Emacs text editor
	<help-gnu-emacs@gnu.org>
Subject: Re: Turning electric-indent-mode off, for a specific buffer
Date: Mon, 13 Jun 2022 20:15:03 +0800	[thread overview]
Message-ID: <87r13sbvzs.fsf@yahoo.com> (raw)
In-Reply-To: <ijGDosSV6chbrEV2xTHcGUGzLTecHwqYLFJEED5YXgFM3NIIfg5W3zUEjbbZHa_-nh-DdfLpsDmcpxt9R_o3Xzv3sqFB8weJB4sQV2UwuMM=@protonmail.com> (goncholden@protonmail.com's message of "Mon, 13 Jun 2022 12:01:48 +0000")

goncholden <goncholden@protonmail.com> writes:

> Then customizing electric-indent-mode does not customize the variable
> but the minor-mode?

Yes.

> If I remember correctly, when defining a minor-mode, a variable is
> also created automatically.  From your discussion, it seems that there
> would also exist a function with the same name.

Both a command that serves to switch a minor mode on or off and a
variable is created when defining a minor mode.

They share the same name, because Emacs Lisp, being a Lisp-2, has
separate cells for functions and variables.

All of this information is trivially available in the doc string of the
function `electric-indent-mode', that of the macro `define-minor-mode',
and the Emacs Lisp reference manual.  I suggest you read them.



      reply	other threads:[~2022-06-13 12:15 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-12 21:20 Turning electric-indent-mode off, for a specific buffer goncholden via Users list for the GNU Emacs text editor
2022-06-13  0:26 ` Po Lu
2022-06-13  1:31   ` goncholden
2022-06-13  2:25     ` Po Lu
2022-06-13  5:21       ` goncholden
2022-06-13  5:42         ` Po Lu
2022-06-13  6:07           ` goncholden
2022-06-13 10:53             ` goncholden
2022-06-13 11:39               ` Po Lu
2022-06-13 12:01                 ` goncholden
2022-06-13 12:15                   ` Po Lu [this message]

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

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

  git send-email \
    --in-reply-to=87r13sbvzs.fsf@yahoo.com \
    --to=luangruo@yahoo.com \
    --cc=goncholden@protonmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.