From: "Sebastien Vauban" <wxhgmqzgwmuf-geNee64TY+gS+FvcfC7Uqw@public.gmane.org>
To: emacs-orgmode-mXXj517/zsQ@public.gmane.org
Subject: [latex] Problems with old exporter (for Beamer) and with new exporter
Date: Thu, 07 Jun 2012 22:56:09 +0200 [thread overview]
Message-ID: <80ipf2hmdy.fsf@somewhere.org> (raw)
Hello,
I want to write a document where I show:
- Org code to type in a buffer
- (sometimes) its LaTeX translation
- its effect in the output PDF
Though, I have big troubles outputting the Org code one is suppose to write in
the Org buffers. It often gets replaced or modified... See examples in the
following ECM.
With the old exporter (necessary for Beamer), all the below cases fail...
With the new exporter, most things work. What does not work:
- macro does not get executed (no string in orange color),
- the =\end{verbatim}= disappears from the LaTeX output
--8<---------------cut here---------------start------------->8---
#+TITLE: Org mode examples
#+OPTIONS: H:3 num:t toc:nil
#+LaTeX_HEADER: \lstdefinelanguage{org}{%
#+LaTeX_HEADER: morekeywords={:results, :session, :var, :noweb, :exports},
#+LaTeX_HEADER: sensitive=false,
#+LaTeX_HEADER: morestring=[b]",
#+LaTeX_HEADER: morecomment=[l]{\#},
#+LaTeX_HEADER: }
#+LaTeX_HEADER: \lstset{%
#+LaTeX_HEADER: extendedchars=false,
#+LaTeX_HEADER: inputencoding=utf8x,
#+LaTeX_HEADER: %
#+LaTeX_HEADER: mathescape=false,
#+LaTeX_HEADER: escapechar=`, % allow escaping to (La)TeX mode within `..`
#+LaTeX_HEADER: columns=flexible,
#+LaTeX_HEADER: keepspaces=true
#+LaTeX_HEADER: }
#+MACRO: key \textcolor{orange}{\texttt{$1}}
#+startup: beamer
#+LaTeX_CLASS: beamer
#+LaTeX_CLASS_OPTIONS: [presentation,t]
#+BEAMER_HEADER_EXTRA: \usetheme{Madrid}\usecolortheme{default}
#+BEAMER_FRAME_LEVEL: 1
* Macros
- With the following macro definition
#+begin_src org :exports code
,#+MACRO: key \textcolor{orange}{\texttt{$1}}
#+end_src
- Every time we write
#+begin_src org :exports code
,{{{key(C-c C-e)}}}
#+end_src
HERE ABOVE, WE SHOULD SEE THE MACRO NAME AND PARAMETER INSIDE CURLY
BRACKETS. INSTEAD, WE SEE THE LATEX REPLACEMENT CODE.
- We get {{{key(C-c C-e)}}}
* Listings informatiques
- To input a block of code in Org, type it like this:
#+begin_src org :exports code
,#+begin_src sql
,SELECT *
,FROM inventory
,WHERE product = 'ABC123'
,#+end_src
#+end_src
HERE, WE SHOULD SEE =#+begin_src sql=. INSTEAD, WE SEE =\begin{}sql=.
- And see the nice listing:
#+begin_src sql
SELECT *
FROM inventory
WHERE product = 'ABC123'
#+end_src
* Verbatim
- Same problem for verbatim... Here, the Org code
#+begin_src org :exports code
,#+begin_verbatim
,verbatim d i s p l a y s with spaces!
,#+end_verbatim
#+end_src
HERE, THE META LINE IS CONVERTED INTO ITS LATEX FORM.
- And its translation into LaTeX:
#+begin_src latex :exports code
\begin{verbatim}
verbatim d i s p l a y s with spaces!
\end{verbatim}
#+end_src
* Comment
It is also impossible to show how to type a comment block:
#+begin_src org :exports code
#+begin_comment
Paragraph which will not appear in resulting PDF.
#+end_comment
#+end_src
THE ABOVE NEVER IS SHOWN!
--8<---------------cut here---------------end--------------->8---
Best regards,
Seb
--
Sebastien Vauban
next reply other threads:[~2012-06-07 20:56 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-07 20:56 Sebastien Vauban [this message]
2012-06-09 20:18 ` [latex] Problems with old exporter (for Beamer) and with new exporter Nicolas Goaziou
2012-06-14 13:06 ` Sebastien Vauban
2012-06-14 18:06 ` Nicolas Goaziou
2012-06-15 9:09 ` Sebastien Vauban
2012-06-18 7:40 ` Eric S Fraga
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=80ipf2hmdy.fsf@somewhere.org \
--to=wxhgmqzgwmuf-genee64ty+gs+fvcfc7uqw@public.gmane.org \
--cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).