[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: change $$ to equations with automatic labels
From: |
Tassilo Horn |
Subject: |
Re: change $$ to equations with automatic labels |
Date: |
Thu, 13 Jan 2022 07:58:26 +0100 |
User-agent: |
mu4e 1.7.5; emacs 29.0.50 |
Uwe Brauer <oub@mat.ucm.es> writes:
>> That will also give you the chance to compose a custom TO-STRING
>> programmatically, e.g., something like
>
>> (concat "\\label{eqn:" my-num "}\n" (match-string 1))
>
>> where you'd have to increment my-num in every iteration.
>
> My hope was to use reftex-label which takes care of all that, but even
> with that while loop it might not be possible, or maybe it is hm, I
> give it a try later
Well, I guess you could insert the equation environment (which I've
forgotten in my code above), then set point after the \begin{equation},
insert \n, and then call `reftex-label' to insert the label
interactively. Worth a try.
Bye,
Tassilo