From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: Disable links in Latex export Date: Wed, 11 Apr 2012 14:01:33 -0400 Message-ID: <7114.1334167293@alphaville> References: Reply-To: nicholas.dokos@hp.com Return-path: Received: from eggs.gnu.org ([208.118.235.92]:52152) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SI1rS-00034S-LG for emacs-orgmode@gnu.org; Wed, 11 Apr 2012 14:01:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SI1rM-0007bH-7C for emacs-orgmode@gnu.org; Wed, 11 Apr 2012 14:01:42 -0400 Received: from g6t0184.atlanta.hp.com ([15.193.32.61]:26814) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SI1rM-0007aq-1j for emacs-orgmode@gnu.org; Wed, 11 Apr 2012 14:01:36 -0400 In-Reply-To: Message from SW of "Wed, 11 Apr 2012 17:08:22 -0000." 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: SW Cc: emacs-orgmode@gnu.org SW wrote: > I'm exporting a structured document to Latex/PDF. The table of contents contains > hyperlinks for each section which I would like to disable. I tried setting > "org-export-latex-href" and "org-export-latex-hyperref" to empty strings, but > this did not help. Thanks. > > There are no such variables. There are variables org-export-latex-href-format and org-export-latex-hyperref-format but they are used for links in the document body. The TOC is under the control of latex and hyperref, so you cannot use either of these to influence it. The only way I know of to disable links completely is to not use hyperref at all. You can redefine the package list appropriately. Unfortunately, I think there is an unconditional \hypersetup inserted by the latex exporter that would then break things - there is even a FIXME: note: ,---- | ;; add some hyperref options | ;; FIXME: let's have a defcustom for this? | (format "\\hypersetup{\n pdfkeywords={%s},\n pdfsubject={%s},\n pdfcreator={%s}}\n" | (org-export-latex-fontify-headline keywords) | (org-export-latex-fontify-headline description) | (concat "Emacs Org-mode version " org-version)) `---- Given that the new latex exporter is where all the action is right now, I don't foresee that this is going to be fixed. If all you care about is the *appearance*, rather than the existence of links, however, you can use hyperref package options to influence that. For example \usepackage[pdfborder={0,0,0}]{hyperref} will get rid of the red boxes around the links in the TOC: they are still links, they are just not that obvious any more. You can do that by customizing the org-export-latex-default-packages-alist variable: just add the above option (without the square brackets) to the hyperref package entry. Nick