From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mauro Rovezzi Subject: Re: LaTeX export: inline markup underscore problem Date: Mon, 11 Apr 2011 20:54:41 +0200 Message-ID: References: <1112.1302466080@alphaville.dokosmarshall.org> <63F0C433-3616-4517-A1CF-D758F3B88086@tsdye.com> <9082.1302486279@alphaville.dokosmarshall.org> <15EA52A3-0CA5-4219-A22E-A29B4B1D38A3@tsdye.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([140.186.70.92]:58437) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q9Sd1-0003lR-TR for emacs-orgmode@gnu.org; Mon, 11 Apr 2011 21:42:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q9MG2-00029H-Mq for emacs-orgmode@gnu.org; Mon, 11 Apr 2011 14:54:43 -0400 Received: from mail-iy0-f169.google.com ([209.85.210.169]:59330) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q9MG2-00029C-IN for emacs-orgmode@gnu.org; Mon, 11 Apr 2011 14:54:42 -0400 Received: by iyh42 with SMTP id 42so274829iyh.0 for ; Mon, 11 Apr 2011 11:54:42 -0700 (PDT) In-Reply-To: <15EA52A3-0CA5-4219-A22E-A29B4B1D38A3@tsdye.com> 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: "Thomas S. Dye" Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org Hello Thomas, On Mon, Apr 11, 2011 at 6:58 PM, Thomas S. Dye wrote: > Aloha Mauro, > On my system I define a citep link: > > #+source: define-citep-link > #+begin_src emacs-lisp :results silent > =A0=A0 =A0(org-add-link-type > =A0=A0 =A0 "citep" 'ebib > =A0=A0 =A0 (lambda (path desc format) > =A0=A0 =A0 =A0 (cond > =A0=A0 =A0 =A0 =A0((eq format 'html) > =A0=A0 =A0 =A0 =A0 (format "(%s)" path)) > =A0=A0 =A0 =A0 =A0((eq format 'latex) > =A0=A0 =A0 =A0 =A0 (if (or (not desc) (equal 0 (search "citep:" desc))) > =A0=A0 =A0 =A0 =A0 =A0 =A0 =A0 (format "\\citep{%s}" path) > =A0=A0 =A0 =A0 =A0 =A0 =A0 =A0 (format "\\citep[%s]{%s}" desc path) > =A0=A0))))) > #+end_src > > then=A0the=A0following=A0Org-mode=A0source: > > Hawaiian archaeology's response to the late Roger Green's call for an > investigation of diachronic settlement patterns > [[citep:green84:_settl_patter_studies_ocean]] has been slow and difficult= . > > exports=A0as: > > Hawaiian archaeology's response to the late Roger Green's call for an > investigation of diachronic settlement patterns > \citep{green84:_settl_patter_studies_ocean} has been slow and difficult. > > Perhaps=A0you=A0could=A0post=A0a=A0minimal=A0example=A0that=A0doesn't=A0w= ork=A0for=A0you? > Note that this solution doesn't depend on ebib. =A0It is perfectly OK to = enter > the bibliography key by hand if you prefer. Yes, I did the same but I get different behavior. If I put the same code in a .org file (the current file where the citation is or the #+SETUPFILE), the LaTeX export is \hyperref[citep:green84:_settl_patter_studies_ocean]{citep:green84:_settl_p= atter_studies_ocean}, while if I put the same in my .emacs, it is exported as \texttt{cite:green84:_settl_patter_studies_ocean}. This happens in Org version 6.21b (Ubuntu 10.10 version). while in the last version from Git it transforms to \hyperref[citep-green84-_settl_patter_studies_ocean]{citep:green84:_settl\_= patter\_studies\_ocean} Well, something is going weird... > On your other observation: > I=A0don't=A0use=A0underscores=A0in=A0headlines,=A0so=A0hadn't=A0run=A0acr= oss=A0the=A0limitation=A0in=A0the=A0cross=A0references=A0that=A0you=A0menti= on.=A0=A0I=A0don't=A0know=A0if=A0there=A0is=A0any=A0way=A0around=A0this. > =A0If you do find a way, please feel free to add the solution to the LaTe= X > export tutorial. OK, but for this is easier to just change the labels and remove underscores, so this is definitely a minor point. Anyway, thanks a lot for your help! M.