all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: tomas@tuxteam.de
To: Stefan Monnier <monnier@IRO.UMontreal.CA>
Cc: tomas@tuxteam.de, emacs-devel@gnu.org
Subject: Re: Format-alist vs. minor mode
Date: Sun, 3 Aug 2008 20:01:21 +0200	[thread overview]
Message-ID: <20080803180121.GA14451@tomas> (raw)
In-Reply-To: <jwv3almkn4g.fsf-monnier+emacs@gnu.org>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sun, Aug 03, 2008 at 01:47:16PM -0400, Stefan Monnier wrote:
> > I'm trying to switch on a minor mode via the format-alist feature, like

> > It works at first, when the regexp is recognized the mode function is
> > called... but then "fundamental-mode" sets in, kills all local variables

[...]

> If the minor mode depends on the file/buffer's contents, then it should
> survive a change in major-mode, right?  So you might want to make your
> minor mode permanent-local.

Thanks, Stefan. I figured that out thanks to the pointers provided by
Martin Rudalics. It was very surprising at the beginning :-)

I guess one wants to do that almost always when doing format
transformations à la format-alist, although those things are not very
related. This explains the misleading subject line.

Do you think a pointer in the doc is appropriate?

Regards
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFIlfJxBcgs9XrR2kYRAi34AJ9KqWJ09gXFN8x4um3K/MFnMfmTsgCfYcvj
kiTyi4a0tw+pkI4ywJTTkfg=
=UX68
-----END PGP SIGNATURE-----




  reply	other threads:[~2008-08-03 18:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-01 10:45 Format-alist vs. minor mode tomas
2008-08-01 12:26 ` martin rudalics
2008-08-01 13:17   ` tomas
2008-08-03 17:47 ` Stefan Monnier
2008-08-03 18:01   ` tomas [this message]
2008-08-04 19:02     ` Stefan Monnier

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=20080803180121.GA14451@tomas \
    --to=tomas@tuxteam.de \
    --cc=emacs-devel@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.
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.