Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I repeat a beamer frame with Org-mode?

With Beamer frames can be repeated by labeling the frame that should be repeated such as

\begin{frame}[label=framelabel]
...
\end{frame}

and then using \againframe{framelabel} at the place where that frame is to be repeated.

How can this method be used with Org-mode's Beamer export? The label can obviously be added by putting it in BEAMER_envargs such as:

* Org-mode section
:PROPERTIES:
:BEAMER_envargs: [label=questions]
:END:

But there are two problems in using \againframe via Org-mode:

  1. \againframe is placed badly both if it is placed under an Org-mode section and if it is put directly in an Org-mode section. The problem is that in the former case is that is is placed inside a frame when it should be placed between. The problem in the latter case is that it is placed inside \frametitle.
  2. \againframe is either swallowed by Org-mode sections or it is marked as one. Both are poor logical representations of its function.

So is there some effective way of using \againframe with Beamer or is there some other way to repeat frames with Org-mode that I have overlooked?

I have already looked at http://lists.gnu.org/archive/html/emacs-orgmode/2011-05/msg00954.html in trying to work this out.

I am running Org-mode 7.6 in Emacs 23.3.1 and I use Beamer 3.13.

like image 674
N.N. Avatar asked Mar 08 '12 16:03

N.N.


2 Answers

The current org-mode has support for againframe. Just create a frame and add the beamer option BEAMER_env = againframe to the corresponding section. Or use C-c C-b a to insert it if you initialized the beamer mode on org-startup.

More information can be found in the org-mode documentation.

An example is available in the original proposal of the syntax:

* section
** My frame title                     :B_frame:
:PROPERTIES:
:BEAMER_env: frame
:END:

Some text. Some text.  Some text. Some text.
Some text. Some text.  Some text. Some text.

** section                                         :B_againframe:
  :PROPERTIES:
  :BEAMER_env: againframe
  :BEAMER_act: 2
  :BEAMER_ref: *My frame title
  :END:

  This section will create "\againframe<2>{sec-1-2}".

** Following frame
etc.
like image 63
Keinstein Avatar answered Nov 09 '22 23:11

Keinstein


I don't think this is currently possible. The limitation lies in the tree structure of an org document. As far as I understood from your question, the \againframe{...} command basically repeats a slide as is. In org terms, that means the original tree used to generate the slide is repeated. Since the org document format doesn't let you have any content which is not part of a tree (other than the frontmatter/header at the top of a file), I believe this is not possible. This has been discussed on the mailing list a few times, from what I understood there are no plans to implement something like this.

like image 2
suvayu Avatar answered Nov 09 '22 22:11

suvayu