[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] ox and links to equation
From: |
Rasmus |
Subject: |
[O] ox and links to equation |
Date: |
Sun, 15 Feb 2015 01:27:10 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
Hi,
I have two issues with linking to equations.
Consider the following example:
\begin{alinged}
\Label{eq:1}
\min f(x)\\
\label{eq:2}
\st c(x)=0
\end{aligned}
Insightful comments on [[eq:1]] and [[eq:2]]
* Issue 1
If org-link-search-must-match-exact-headline is nil the links will work in
the buffer. However, they will be discarded on export. Eq:1 I can refer
to if I give the latex-environment a #+NAME, but I can't refer to eq:2. I
think it should be possible to put in a link for eq:2. I don't know if it
should depend on org-link-search-must-match-exact-headline or not,
probably not.
Any ideas how this could be solved and whether it's desirable solving?
* Issue 2 (ox-latex specific)
Since we now have amsmath in the org-default-package-alist I would like to
\eqref{·} to refer to equations. The main difference is that it takes
care of the parenthesis automatically. I.e. \ref{eq:2} → 2 and
\eqref(eq:2) → (2). Also, mathtools works with \eqref, but not \ref.
However, in old document it could lead to ((2)).
I have a simple patch that hard-coded equation to \eqref, but I don't know
if a more general approach should be taken. Or if it a filter issue.
—Rasmus
--
The second rule of Fight Club is: You do not talk about Fight Club
- [O] ox and links to equation,
Rasmus <=
- Re: [O] ox and links to equation, Nicolas Goaziou, 2015/02/15
- Re: [O] ox and links to equation, Rasmus, 2015/02/15
- Re: [O] ox and links to equation, Nicolas Goaziou, 2015/02/15
- Re: [O] ox and links to equation, Rasmus, 2015/02/15
- Re: [O] ox and links to equation, Nicolas Goaziou, 2015/02/15
- Re: [O] ox and links to equation, Rasmus, 2015/02/15
- Re: [O] ox and links to equation, Nicolas Goaziou, 2015/02/15
- Re: [O] ox and links to equation, Rasmus, 2015/02/15
- [O] [patch, ox-html] mathjax changes (was: ox and links to equation), Rasmus, 2015/02/15
- Re: [O] [patch, ox-html] mathjax changes, Rasmus, 2015/02/17