From mboxrd@z Thu Jan 1 00:00:00 1970 From: Suvayu Ali Subject: Re: LaTeX export: images in margin Date: Fri, 16 Aug 2013 16:44:52 +0200 Message-ID: <20130816144452.GE10615@kuru.dyndns-at-home.com> References: <520E143E.3090007@mun.ca> <20130816124707.GC10615@kuru.dyndns-at-home.com> <20130816131559.GD10615@kuru.dyndns-at-home.com> <520E3159.1050300@mun.ca> <520E380E.8020601@mun.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:51250) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VALGs-00036Q-F7 for emacs-orgmode@gnu.org; Fri, 16 Aug 2013 10:45:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VALGr-0000W2-39 for emacs-orgmode@gnu.org; Fri, 16 Aug 2013 10:44:58 -0400 Received: from mail-ea0-x22e.google.com ([2a00:1450:4013:c01::22e]:55811) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VALGq-0000Vr-U5 for emacs-orgmode@gnu.org; Fri, 16 Aug 2013 10:44:57 -0400 Received: by mail-ea0-f174.google.com with SMTP id z15so1046034ead.19 for ; Fri, 16 Aug 2013 07:44:56 -0700 (PDT) Content-Disposition: inline In-Reply-To: <520E380E.8020601@mun.ca> 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 On Fri, Aug 16, 2013 at 12:02:46PM -0230, Roger Mason wrote: > > (replace-regexp-in-string "\\`\\\\includegraphics.+\\({.+}\\)" > "\\\\marginpar{\\\\includegraphics\1} " contents))) > > should be: > > (replace-regexp-in-string "\\`\\\\includegraphics.+\\({.+}\\)" > "\\\\marginpar{\\\\includegraphics\\1} " contents))) > > Note the double backslash before the '1' in the replacement text. That is a lisp gotcha, :-p. The regexp needs a backslash, however since it is the escape character in lisp strings, it needs to be escaped itself. Glad things worked out for you. Cheers, -- Suvayu Open source is the future. It sets us free.