From mboxrd@z Thu Jan 1 00:00:00 1970 From: John Kitchin Subject: Re: Splitting up inline LaTeX Date: Fri, 13 Dec 2013 09:27:20 -0500 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=047d7b6d95d087842a04ed6b42c4 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:35728) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VrTi8-0000dU-41 for emacs-orgmode@gnu.org; Fri, 13 Dec 2013 09:27:25 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VrTi6-00064B-EG for emacs-orgmode@gnu.org; Fri, 13 Dec 2013 09:27:24 -0500 Received: from mail-pd0-x22d.google.com ([2607:f8b0:400e:c02::22d]:55093) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VrTi6-000647-2N for emacs-orgmode@gnu.org; Fri, 13 Dec 2013 09:27:22 -0500 Received: by mail-pd0-f173.google.com with SMTP id p10so2559785pdj.32 for ; Fri, 13 Dec 2013 06:27:21 -0800 (PST) In-Reply-To: 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: Laurens Van Houtven <_@lvh.io> Cc: "emacs-orgmode@gnu.org" --047d7b6d95d087842a04ed6b42c4 Content-Type: text/plain; charset=ISO-8859-1 I would use links for this purpose, which org-mode would get right across lines. For instance, here is a cite link: https://github.com/jkitchin/jmax/blob/prelude/jorg-bib.el#L332 so you use cite:bibkey1,bibkey2 or [[cite:bibkey1, bibkey2]] instead of \cite{bibkey1,bibkey2}. At export time, the link is converted to the latex they way you need it. The code at the link above does a lot more than that and may not be directly suitable for what you are doing, e.g. when I click on the link, it opens my bibtex file at the entry I clicked on, etc... See this page: http://orgmode.org/manual/Adding-hyperlink-types.html for another example of making your own links. John ----------------------------------- John Kitchin Associate Professor Doherty Hall A207F Department of Chemical Engineering Carnegie Mellon University Pittsburgh, PA 15213 412-268-7803 http://kitchingroup.cheme.cmu.edu On Fri, Dec 13, 2013 at 8:01 AM, Laurens Van Houtven <_@lvh.io> wrote: > Hi! > > I'm using org-mode with the LaTeX export to write a book. I'm having > issues with inline LaTeX citations (\cite{some label}) and glossary > references (\gls{some label}). When the label (the thing in between the > curly braces) is split across lines, the org-mode LaTeX exporter escapes > the curly braces, so I get something like: > > the beginning of the line \cite\{the first part of the label > the latter part of the label\} the rest of the line > > The extra escaping of the curlies makes LaTeX very unhappy. I would like > to teach org-mode that stuff like that needs to be kept together, much like > $math mode stuff$. I tried reading the manual for advice, but those are > neither inline math (so not $$ delimited) nor an environment (\begin{} and > \end{} delimited), which are the two cases that the manual covers. > > thanks in advance > lvh > --047d7b6d95d087842a04ed6b42c4 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
I would use links for this purpose, which org-mode wo= uld get right across lines. For instance, here is a cite link: https://gith= ub.com/jkitchin/jmax/blob/prelude/jorg-bib.el#L332

so you use cite:bibkey1,bibkey2 or [[cite:bibkey1, bibkey2]] inst= ead of \cite{bibkey1,bibkey2}. At export time, the link is converted to the= latex they way you need it.

The code at the link above does a lot = more than that and may not be directly suitable for what you are doing, e.g= . when I click on the link, it opens my bibtex file at the entry I clicked = on, etc... See this page: http://orgmode.org/manual/Adding-hyperlink-types.html = for another example of making your own links.

John

-------= ----------------------------
John Kitchin
Associate Professor
Dohe= rty Hall A207F
Department of Chemical Engineering
Carnegie Mellon Uni= versity
Pittsburgh, PA 15213
412-268-7803
http://kitchingroup.cheme.cmu.edu

<= /div>

On Fri, Dec 13, 2013 at 8:01 AM, Laurens= Van Houtven <_@lvh.io> wrote:
Hi!

I'm using org-mode with the = LaTeX export to write a book. I'm having issues with inline LaTeX citat= ions (\cite{some label}) and glossary references (\gls{some label}). When t= he label (the thing in between the curly braces) is split across lines, the= org-mode LaTeX exporter escapes the curly braces, so I get something like:=

the beginning of the line \cite\{the first part of the labe= l
the latter part of the label\} the rest of the line

The e= xtra escaping of the curlies makes LaTeX very unhappy. I would like to teac= h org-mode that stuff like that needs to be kept together, much like $math = mode stuff$. I tried reading the manual for advice, but those are neither i= nline math (so not $$ delimited) nor an environment (\begin{} and \end{} de= limited), which are the two cases that the manual covers.

thanks in advance
lvh

--047d7b6d95d087842a04ed6b42c4--