emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Filter not working (org 8.0.3)


From: Roger Mason
Subject: Re: [O] Filter not working (org 8.0.3)
Date: Thu, 05 Sep 2013 16:34:55 -0230
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6

Hello,

On 09/05/2013 04:15 PM, Nicolas Goaziou wrote:
#+LATEX_HEADER: \usepackage[right=2in,left=0.5in]{geometry}
   #+LATEX_HEADER: \usepackage{parskip}

   * Setup                                                                 
:noexport:
   #+BEGIN_SRC emacs-lisp :exports both
   (defun margin-graphics (contents backend info)
       (when (eq backend 'latex)
         (replace-regexp-in-string "\\`\\\\includegraphics.*?\\({.+}\\)"
   "\\\\marginpar{\\\\includegraphics[width=0.9\\\\marginparwidth]\\1} "
   contents)))

   (add-to-list (make-local-variable 'org-export-filter-link-functions) 
'margin-graphics)
   #+END_SRC
That got rid of the verbatim output.  Thanks.

Unfortunately the replacement of \includegraphics... by \marginpar... still does not work:

#+CAPTION: Acicular
[[../images/acicular.eps]]

produces

\begin{figure}[htb]
\centering
\includegraphics[width=.9\linewidth]{../images/acicular.eps}
\caption{Acicular}
\end{figure}

I'm using org Emacs 24.3.1 (Org mode 8.0.3).

Please don't spend any more time on this on my account: I'll use ConTeXt instead.

Cheers,
Roger


This electronic communication is governed by the terms and conditions at
http://www.mun.ca/cc/policies/electronic_communications_disclaimer_2012.php



reply via email to

[Prev in Thread] Current Thread [Next in Thread]