[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Format-alist vs. minor mode
From: |
tomas |
Subject: |
Format-alist vs. minor mode |
Date: |
Fri, 1 Aug 2008 12:45:47 +0200 |
User-agent: |
Mutt/1.5.15+20070412 (2007-04-11) |
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
I'm trying to switch on a minor mode via the format-alist feature, like
so:
(add-to-list 'format-alist
(list "ZEIT-k4c"
"ZEIT k4 cooked XML"
"^<\\?xml[^>]*>[^<]*<article>"
'am-parse-region
'am-unparse-region
t
'am-mode)
nil
(lambda (x y) (equal (car x) (car y))))
It works at first, when the regexp is recognized the mode function is
called... but then "fundamental-mode" sets in, kills all local variables
and reverts the minor mode settings.
What am I doing wrong? Do only major modes work with format-alist?
Thanks
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
iD8DBQFIkulbBcgs9XrR2kYRAgpvAJ9LsoGl/L1YyyKxrQhkL1HHkEAIlgCfR6tn
ivpezzABebPH9+j4I1+eTsU=
=7Gd0
-----END PGP SIGNATURE-----
- Format-alist vs. minor mode,
tomas <=