emacs-orgmode
[Top][All Lists]
Advanced

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

[O] Source Code Syntax Highlighting in Beamer slides


From: Alexander Baier
Subject: [O] Source Code Syntax Highlighting in Beamer slides
Date: Sun, 21 Apr 2013 21:25:55 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Hello,

I am trying to syntax-color the code in my source blocks that is
exported to LaTeX. As proposed in this thread [1] over a year ago I
followed this guide [2], but could not get the generated .tex file to
compile.

My org-version output:
  Org-mode version 8.0 (8.0-dist @ /usr/share/emacs/site-lisp/org/)

The test.org file i am trying to export is as follows:
-------------------------------------------------------------------------------
** Test
   :PROPERTIES:
   :EXPORT_FILE_NAME: /home/delexi/Dokumente/Uni/Tutor/SWT/Tut-Folien/Tut1.pdf
   :EXPORT_AUTHOR: Alex
   :EXPORT_LATEX_CLASS: beamer
   :EXPORT_LATEX_CLASS_OPTIONS: [presentation,smaller]
   :EXPORT_LATEX_HEADER: \usepackage{minted}
   :EXPORT_LATEX_HEADER: \usemintedstyle{emacs}
   :EXPORT_LATEX_HEADER: \newminted{common-lisp}{fontsize=\footnotesize}
   :END:
*** Java Example
    Some Code.
    #+name: Hello, World!
    #+begin_src java :exports code
      public class Test {
          public static void main(String[] args) {
              System.out.println("Hello!");
          }
      }
    #+end_src
-------------------------------------------------------------------------------

The customizations in minimal-org-setup.el taken from [2] are as follows:
-------------------------------------------------------------------------------
(require 'ox-latex)
(add-to-list 'org-latex-classes
               '("beamer"
                 "\\documentclass\[presentation\]\{beamer\}"
                 ("\\section\{%s\}" . "\\section*\{%s\}")
                 ("\\subsection\{%s\}" . "\\subsection*\{%s\}")
                 ("\\subsubsection\{%s\}" . "\\subsubsection*\{%s\}")))
(setq org-export-initial-scope 'subtree)

(setq org-export-latex-listings 'minted)
(setq org-export-latex-custom-lang-environments
      '(
        (emacs-lisp "common-lispcode")
        ))
(setq org-export-latex-minted-options
      '(("frame" "lines")
        ("fontsize" "\\scriptsize")
        ("linenos" "")))
(setq org-latex-to-pdf-process
  '("pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f"
    "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f"
    "pdflatex -shell-escape -interaction nonstopmode -output-directory %o %f"))
-------------------------------------------------------------------------------

I start my emacs with 'emacs -q -l minimal-org-setup.el test.org' put my
point at bob and press C-c C-e l O and i get "org-latex-compile: PDF
file /home/delexi/orgtest/output.pdf wasn't produced: [LaTeX error]
[package error]".
Attached is output.log.

Does anyone know where the error could be? Please note, this is my first
contact with latex and exporting in orgmode. If this is simply the
result of me not reading the appropriate docs, please feel free to point
me to any tutorial/manual/documentation/...
Also, i am glad to provide any additional information should that be
necessary.

Regards,

Alex


Attachment: output.log
Description: Log file


_________________________________________________________________________
[1] http://thread.gmane.org/gmane.emacs.orgmode/53318/focus=53320
[2] http://orgmode.org/worg/org-tutorials/org-latex-export.html#sec-12-3

reply via email to

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