auctex
[Top][All Lists]
Advanced

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

Re: [AUCTeX] reftex-label-alist for ctable package


From: Tassilo Horn
Subject: Re: [AUCTeX] reftex-label-alist for ctable package
Date: Fri, 03 Aug 2012 08:56:38 +0200
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.1.50 (gnu/linux)

Tassilo Horn <address@hidden> writes:

Hi again,

>> I'll look into that, but don't hold your breath.  I'm in holidays
>> from Friday on.
>
> Ok, here's another patch.  With that, at least C-c ) followed by l will
> show listing and minted environments.  However, it only works for
> environments but not for macros like \ctable or \endnote.  Not sure
> why...

I've fixed it!  It took me half an hour to edebug several reftex parsing
functions to eventually see that the label regex has to be written in a
way so that a forward search stops directly after the label.  :-)

Ok, if you want you can apply this mini-patch on top of the others and
then it'll also work for ctables.

--8<---------------cut here---------------start------------->8---
=== modified file 'lisp/textmodes/reftex.el'
--- lisp/textmodes/reftex.el    2012-07-27 17:58:58 +0000
+++ lisp/textmodes/reftex.el    2012-08-03 06:47:32 +0000
@@ -1291,7 +1291,7 @@
                             ;; keyvals [..., label = {foo}, ...]
                             ;; forms used by ctable, listings,
                             ;; minted, ...
-                            
"\\[[^]]*label[[:space:]]*=[[:space:]]*{?\\(?1:[^],}]+\\)}?[^[]*\\]"
+                            
"\\[[^]]*label[[:space:]]*=[[:space:]]*{?\\(?1:[^],}]+\\)}?"
                             "\\)"))
            (include-re (concat wbol
                                "\\\\\\("
--8<---------------cut here---------------end--------------->8---

Bye,
Tassilo




reply via email to

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