emacs-orgmode
[Top][All Lists]
Advanced

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

[Orgmode] Re: Org-beamer problems


From: Bill Moran
Subject: [Orgmode] Re: Org-beamer problems
Date: Wed, 19 Jan 2011 21:34:13 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

HI Eric, John, Jeff and Birch 


Eric S Fraga <e.fraga <at> ucl.ac.uk> writes:

> 
> My immediate response would be to ask why you aren't using \maketitle
> given that the command is beamer-aware?  That is, \maketitle will create
> a title page whose format is defined by the beamer theme you have
> selected.  Otherwise, you could always customise
> =org-export-latex-title-command= to nothing and use direct latex code to
> do what you want:
> 
> --8<---------------cut here---------------start------------->8---
> #+begin_latex
> \begin{frame} \titlepage \end{frame}
> #+end_latex
> --8<---------------cut here---------------end--------------->8---
> 
> I've not tried this.
> 
> > 2. \alert command does not work - even with the additions to .emacs 
> > suggested here:
> >  http://www.mail-archive.com/emacs-orgmode <at> gnu.org/msg21507.html
> > (And there are no errors in running the .emacs file) 
> > Always the @ symbol appears in the latex created from org as @. 
> 
> Can you tell us exactly what you have done to customise the relevant
> variables and where you have done these customisations?  Difficult to
> help without this information unfortunately.  While we're at it, org and
> emacs version information is also helpful.
> 

>



Thanks for all of your responses and for taking the time to help me. I'll try to
answer your questions. As far as possible I  use the "stock" ubuntu (maverick -
10.10) repositories for emacs and its associated software. So I'm using emacs
23.1.1 and org-mode 6.36c. The version of beamer I'm using, as described in the
repositories, is latex-beamer 3.07-2ubuntu1. I am aware  that there are more
recent versions available  - particularly of org-mode - but was trying to keep
things simple. 

Let me also say that my aim was to arrive at an understanding of  how to use
org-mode for slide creation - since I do a lot of that - rather than to compose
a specific set of slides. I realise that I could use direct latex code to solve
the problems but that wasn't the point of the exercise. 

I've read more since I sent the email and now realise that the issues I brought
up have been discussed earlier and where I can I've tried to use the proposed
solutions. In particular I have this in my .emacs:

 
(setq org-emphasis-alist (quote (("*" bold "<b>" "</b>") 
                                 ("/" italic "<i>" "</i>")
                                 ("_" underline "<span 
style=\"text-decoration:underline;\">" "</span>")
                                 ("=" org-code "<code>" "</code>" verbatim)
                                 ("~" org-verbatim "<code>" "</code>" verbatim)
                                 ("+" (:strike-through t) "<del>" "</del>")
                                 ("@" org-warning "<b>" "</b>")))
      org-export-latex-emphasis-alist (quote 
                                       (("*" "\\textbf{%s}" nil)
                                        ("/" "\\emph{%s}" nil) 
                                        ("_" "\\underline{%s}" nil)
                                        ("+" "\\texttt{%s}" nil)
                                        ("=" "\\verb=%s=" nil)
                                        ("~" "\\verb~%s~" t)
                                        ("@" "\\alert{%s}" nil)))
      )

from a solution to the @ problem proposed by Eric somewhere. And I understand
that I can use \maketitle normally to produce a title page in beamer - just
tried on a hand-crafted (in emacs)  latex-beamer file using my set up.  

To keep this email as brief as possible, let's take this snippet (verbatim) of
an  example from Eric:

----------------------------------start-----------------------------------
#+TITLE:     Writing Beamer presentations in org-mode
#+AUTHOR:    Eric S Fraga
#+EMAIL:     address@hidden
#+DATE:      2010-03-30 Tue
#+DESCRIPTION: 
#+KEYWORDS: 
#+LANGUAGE:  en
#+OPTIONS:   H:3 num:t toc:t \n:nil @:t ::t |:t ^:t -:t f:t *:t <:t
#+OPTIONS:   TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:not-in-toc
#+INFOJS_OPT: view:nil toc:nil ltoc:t mouse:underline buttons:0
path:http://orgmode.org/org-info.js
#+EXPORT_SELECT_TAGS: export
#+EXPORT_EXCLUDE_TAGS: noexport
#+LINK_UP:   
#+LINK_HOME: 

#+startup: oddeven

#+startup: beamer
#+LaTeX_CLASS: beamer
#+LaTeX_CLASS_OPTIONS: [bigger]
#+latex_header: \mode<beamer>{\usetheme{Madrid}}
#+BEAMER_FRAME_LEVEL: 2

#+COLUMNS: %20ITEM %13BEAMER_env(Env) %6BEAMER_envargs(Args) %4BEAMER_col(Col)
%7BEAMER_extra(Extra)

* Methodology

** A simple slide
This slide consists of some text with a number of bullet points:
- the first, very @important@, point!
- the previous point shows the use of the special markup which
  translates to the Beamer specific /alert/ command for highlighting
  text.
The above list could be numbered or any other type of list and may
include sub-lists.
---------------------------end----------------------------------------

When I do "C-c C-e p" to create the pdf file I get 3 slides. The first is a
title page but has no title - only the date. The second is an outline (toc)
slide as expected and the third is again as expected except that @important@ is
not rendered as \alert{important}. 


The latex created  by "C-c C-e l" is

---------------------------start----------------------------------------
% Created 2011-01-20 Thu 08:18
\documentclass[bigger]{beamer}

      \mode<{{{beamermode}}}>

      \usetheme{{{{beamertheme}}}}

      \usecolortheme{{{{beamercolortheme}}}}

      \beamertemplateballitem

      \setbeameroption{show notes}
      \usepackage[utf8]{inputenc}

      \usepackage[T1]{fontenc}

      \usepackage{hyperref}

      \usepackage{color}
      \usepackage{listings}
      \lstset{numbers=none,language=[ISO]C++,tabsize=4,
  frame=single,
  basicstyle=\small,
  showspaces=false,showstringspaces=false,
  showtabs=false,
  keywordstyle=\color{blue}\bfseries,
  commentstyle=\color{red},
  }

      \usepackage{verbatim}

      \institute{{{{beamerinstitute}}}}
          
       \subject{{{{beamersubject}}}}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{fixltx2e}
\usepackage{graphicx}
\usepackage{longtable}
\usepackage{float}
\usepackage{wrapfig}
\usepackage{soul}
\usepackage{t1enc}
\usepackage{textcomp}
\usepackage{marvosym}
\usepackage{wasysym}
\usepackage{latexsym}
\usepackage{amssymb}
\usepackage{hyperref}
\tolerance=1000
\mode<beamer>{\usetheme{Madrid}}
\providecommand{\alert}[1]{\textbf{#1}}

\title{Writing Beamer presentations in org-mode}
\author{Eric S Fraga}
\date{2010-03-30 Tue}

\begin{document}

\maketitle

\begin{frame}
\frametitle{Outline}
\setcounter{tocdepth}{3}
\tableofcontents
\end{frame}




\section{Methodology}
\label{sec-1}
\begin{frame}[fragile]\frametitle{A simple slide}
\label{sec-1_1}

This slide consists of some text with a number of bullet points:
\begin{itemize}
\item the first, very @important@, point!
\item the previous point shows the use of the special markup which
  translates to the Beamer specific \emph{alert} command for highlighting
  text.
\end{itemize}

The above list could be numbered or any other type of list and may
include sub-lists.
\end{frame}

\end{document}
----------------------------------end-----------------------------------

and running pdflatex on this produces an identical result to "C-c C-e p" on the
org file - as it should. 



I'm not sure I've answered all of your questions but perhaps this is enough to
suggest a solution or refine the questions.

Many thanks for your time!

Bill










reply via email to

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