* How to export results to latex?
@ 2013-01-18 15:32 Seweryn Kokot
2013-01-26 13:41 ` Bastien
0 siblings, 1 reply; 2+ messages in thread
From: Seweryn Kokot @ 2013-01-18 15:32 UTC (permalink / raw)
To: emacs-orgmode
Hello!
I have test1.org file (see below [1]) which I want to export to latex. However
when exporting to latex (both using org-export and org-export-dispatch), the
content of RESULTS is missing in the resulting test1.tex (see below [2]).
What is the reason for that?
One year ago when exporting the same file with ":results org replace" the output
was wrapped with "begin_org ... end_org" now it is wrapped with "begin_src org
..." then the export to latex gives verbatim or lstlisting environments... Any
hints what to do to get the previous behaviour?
test1.org contents:
#----------------------------------------------
#+title: Testing org export to latex
#+STARTUP: showall
#+OPTIONS: toc:nil creator:nil
* Headline
- first list item
foo bar
#+begin_src emacs-lisp :exports results :results drawer replace
(let ((t1 ""))
;;
(setq t1 (concat t1 (format "- foo \n\n$a = \\unit[%.3f]{m}$\n\n" 3.0)))
(setq t1 (concat t1 (format "- bar \n\n$b = \\unit[%.3f]{m}$\n\n" 6.0)))
(concat t1))
#+end_src
#+RESULTS:
:RESULTS:
- second list item
$a = \unit[3.000]{m}$
- third list item
$b = \unit[6.000]{m}$
:END:
#------------------------------------------------
[2] test1.tex:
--------------------------------
% Created 2013-01-18 Fri 16:21
\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[a4paper,left=1.8cm,right=1.8cm,top=1.8cm,bottom=1.8cm]{geometry}
\usepackage[dvips]{graphicx}
\usepackage{url}
\usepackage{xcolor}
\usepackage{units}
\usepackage[breaklinks=true]{hyperref}
\usepackage{amsmath}
\title{Testing org export to latex}
\hypersetup{
pdfkeywords={},
pdfsubject={},
pdfcreator={}}
\begin{document}
\maketitle
\section{Headline}
\label{sec-1}
\begin{itemize}
\item first list item
\end{itemize}
foo bar
\end{document}
----------------------------
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: How to export results to latex?
2013-01-18 15:32 How to export results to latex? Seweryn Kokot
@ 2013-01-26 13:41 ` Bastien
0 siblings, 0 replies; 2+ messages in thread
From: Bastien @ 2013-01-26 13:41 UTC (permalink / raw)
To: Seweryn Kokot; +Cc: emacs-orgmode
Hi Seweryn,
Seweryn Kokot <sewkokot@gmail.com> writes:
> I have test1.org file (see below [1]) which I want to export to latex. However
> when exporting to latex (both using org-export and org-export-dispatch), the
> content of RESULTS is missing in the resulting test1.tex (see below [2]).
> What is the reason for that?
That's because the default value for `org-export-with-drawers' is nil.
You need to use
(setq org-export-with-drawers t)
or
(setq org-export-with-drawers '("RESULTS"))
So that the drawer gets exported.
> One year ago when exporting the same file with ":results org replace" the output
> was wrapped with "begin_org ... end_org" now it is wrapped with "begin_src org
> ..." then the export to latex gives verbatim or lstlisting environments... Any
> hints what to do to get the previous behaviour?
:results raw
should be fine, no?
(#+begin_org was too confusing -- see the many discussions about this
on the list, so we are not supporting this anymore.)
Best,
--
Bastien
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-01-26 13:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-18 15:32 How to export results to latex? Seweryn Kokot
2013-01-26 13:41 ` Bastien
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.