From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rasmus Subject: ox and links to equation Date: Sun, 15 Feb 2015 01:27:10 +0100 Message-ID: <87zj8gaujl.fsf@gmx.us> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:38290) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YMn3Y-0001O5-1i for emacs-orgmode@gnu.org; Sat, 14 Feb 2015 19:27:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YMn3U-0001AQ-Sw for emacs-orgmode@gnu.org; Sat, 14 Feb 2015 19:27:27 -0500 Received: from plane.gmane.org ([80.91.229.3]:46698) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YMn3U-0001AH-Me for emacs-orgmode@gnu.org; Sat, 14 Feb 2015 19:27:24 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1YMn3R-0005lA-QP for emacs-orgmode@gnu.org; Sun, 15 Feb 2015 01:27:21 +0100 Received: from tsn109-201-154-182.dyn.nltelcom.net ([109.201.154.182]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 15 Feb 2015 01:27:21 +0100 Received: from rasmus by tsn109-201-154-182.dyn.nltelcom.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 15 Feb 2015 01:27:21 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org 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