auctex
[Top][All Lists]
Advanced

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

Re: [AUCTeX] RefTeX: Section and chapter numbers into label prefixes


From: Eugenio Piasini
Subject: Re: [AUCTeX] RefTeX: Section and chapter numbers into label prefixes
Date: Sun, 20 May 2007 16:07:28 +0200

2007/5/20, David Kastrup <address@hidden>:
Ralf Angeli <address@hidden> writes:

> * David Kastrup (2007-05-20) writes:
>
>> Ralf Angeli <address@hidden > writes:
>>
>>> * Eugenio Piasini (2007-05-20) writes:
>>>
>>>> Does anyone know about a simple way to obtain this result? I mean,
>>>> I'm a newbie and I don't know enough to write a custom function to
>>>> insert into "context-method"..
>>>
>>> Getting the numbers as in the typeset document will be very hard.
>>> You would probably have to parse output files.
>>
>> Actually, when using preview-latex (which is when the difference in
>> section numbering between RefTeX and LaTeX might be most noticeable)
>> with preview-preserve-counters, then the preview overlays will contain
>> the necessary information already.
>
> Hm, using such a feature would only make sense if it can be handled
> transparently without the user having to intervene manually.

Well, if reftex took the cues when they exist, there would be no
manual intervention involved.  One problem will be that there are no
guarantees that numbers are actually sequential or unique in the
RefTeX buffers.  But in the presence of previews, one could make sure
that their (recorded) numbering is consistent with that of RefTeX.

There are some more drawbacks:
a) we don't have the tocdepth/secnumdepth information available, so
when in doubt, RefTeX will exhibit more information than LaTeX.
b) we don't have the numbering style available, so the information
will be numeric.  In particular, Appendices A, B, C, D... would likely
be numbered 1, 2, 3, 4 inside of RefTeX.

Unless RefTeX picks up the "Appendix" angle on its own from the source
code.  Maybe it already does, but I am not sure of that.

--
David Kastrup, Kriemhildstr. 15, 44793 Bochum


Thank you for the advice.. it would really interest me to follow the way David has suggested. I'll try it as soon as I have time to learn some lisp.
By now I surrender to manual work, but if I come up with something I'll let you know, just in case there's someone else with the same need.

thank you again

            Eugenio



reply via email to

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