If you are a fan of versioning presentations and not convinced with versioning binary files then this article is for you, of course it makes you stand out among your friends since this is how geeks prepare presentations. Latex is a popular document preparation system which provides a document markup language to edit your documents which looks beautiful in paper.
I have used latex for preparing my project documentation back in college days which was very different and beautiful from the documents prepared by my friends in normal word processors. Recently, I started using latex for my presentation slides, which makes the audience curious, about the tools used to make the presentation. In this article I will walk you through the steps involved in preparing a simple presentation using latex beamer classes. You require 'latex-beamer', 'pdflatex' packages installed in your distribution.
The sample presentation will consist of four slides which illustrates basic concepts in preparing a presentation. In a new folder create a file sample_presentation.tex with the following content:
\documentclass{beamer}
\usetheme{Warsaw}
\title[About Version Control Systems]{Version Control Systems}
\author{Senthil Kumaran}
\institute{CollabNet}
\date{December 1, 2009}
\begin{document}
\begin{frame}
\titlepage
\end{frame}
\begin{frame}{Version Control Systems (VCS)}
\begin{block}{Time machine}
A Version control system is a time machine, which does not know
anything about your future, but remembers everything about your past!
\end{block}
\begin{itemize}
\item Centralized VCS
\item Distributed VCS (DVCS)
\end{itemize}
\end{frame}
\begin{frame}{Centralized VCS}
\begin{center}
\includegraphics[height=4cm]{central-vcs.jpg}
\end{center}
\end{frame}
\begin{frame}{Thank You}
\begin{center}
Thank You!\\
Questions please
\end{center}
\end{frame}
\end{document}
Following figure shows the complete presentation from the above file,

Let us have a detailed look at what is written in sample_presentation.tex file, most of which are self explanatory,
\documentclass{beamer}
\usetheme{Warsaw}
\title[About VCS]{Version Control Systems}
\author{Senthil Kumaran}
\institute{CollabNet}
\date{December 1, 2009}
The above lines give meta information about the presentation like theme, title, author, institute, date. All presentation are made from 'beamer' class of Latex which is given in the first line. We select a theme for the presentation using the \usetheme command. There are many themes available (see reference [1]) which you can choose from, here we use a theme named 'Warsaw'. In the title we have two parts, the first one 'About VCS' specified within [] appears in the footer of each slide. The second part 'Version Control Sytems' appear in the title page of the presentation. Depending upon the theme we have chose, the author, institute, date, title will appear on the footer of each slide and you can control the appearance of these parameters too.
The entire presentation is enclosed within these lines, (note a line starting with '%' indicates a comment in latex),
\begin{document}
%% presentation content here ...
\end{document}
Each slide is known as a frame in the presentation. For each slide we will have \begin{frame} and \end{frame} commands, which encloses the slide content like the following.
\begin{frame}
%% slide content ...
\end{frame}
Our first slide in the presentation is the title slide, which is generated with the meta information which we have given in the starting of the tex file. The following code is responsible for generating the title slide in figure 2,
\begin{frame}
\titlepage
\end{frame}
It is possible to have a block of text within a slide. You can specify a title for the block within curly braces like this '{Time machine}' immediately after the \begin{block} command, the content between the \begin{block} and \end{block} command forms the content enclosed within the block.
\begin{block}{Time machine}
A Version control system is a time machine, which does not know
anything about your future, but remembers everything about your past!
\end{block}
In order to list some points inside a slide you can use the \item command within the \begin{itemize} and \end{itemize} command as follows,

\begin{itemize}
\item Centralized VCS
\item Distributed VCS (DVCS)
\end{itemize}
Second slide uses the above and renders with a block, followed by some content as points, shown in figure 3,
All of us would like to insert pictures in our presentations to make it more attractive and easily explain some concepts to the audience, which is also possible using latex beamer. You can use the command \includegraphics{/path/to/picturefile.png} in order to insert a picture at specific points inside the slides. [height=4cm] or [width=3cm] can be used in order to specify image dimensions. Following is the code responsible for generating the slide along with picture in figure 4,

\begin{frame}{Centralized VCS}
\begin{center}
\includegraphics[height=4cm]{central-vcs.jpg}
\end{center}
\end{frame}
The fourth slide is our 'Thank You' slide' as seen in figure 5, which is generated with the following code. Here we have enclosed the content within \begin{center} and \end{center} command so that it appears center-aligned. Note the two backslashes which are used as line breaks similar to <br> tag in HTML.
\begin{frame}{Thank You}
\begin{center}
Thank You!\\
Questions please
\end{center}
\end{frame}

In order to generate pdf output of the presentation I used the following command,
$ pdflatex sample_presentation.tex
which will give lot of output and leave a file named sample_presentation.pdf, which is your presentation file in pdf format! The other files generated are not of interest and comes handy if you want to debug stuff.
You may ask, what is so cool about making presentation with latex beamer? The advantages are multiple,
1. Switch between various layouts and themes without editing each slide.
2. sample_presentation.tex is a normal text file which could be versioned easily and occupies less space in disk.
3. With simple diff command you can see the difference between presentations, unlike you need to open .odt/odp files to see the difference.
4. Use your favorite text editor (like emacs) to create your presentation.
Still you don't believe me? Here is an illustration (figure 6) of point 1) in the above listed advantages, just with a simple one line change ie., \usetheme{Warsaw} to \usetheme{CambridgeUS} we get a new presentation with a different look and feel! Isn't that cool?

But what about flashy animations? Of course, we can animate our presentation with latex beamer which will be too much for this beginner article, so I would like everyone to see reference [1] for advanced concepts in making presentation with latex beamer. In order to get files used in this article download it from reference [2].
References:
[1] http://www.ctan.org/tex-archive/macros/latex/contrib/beamer/doc/beamerus... [1.8 M]
[2] http://www.stylesen.org/files/misc/stylesen_sample_presentation.tar.gz [13 KB]
About the Author
Senthil Kumaran (stylesen) is working as Meego Developer OS & MW in Nokia India Pvt. Ltd. He is active in the Subversion - Version control System community and is the Second Indian Full Committer in the project.
He is a committer in "Apache Software Foundation" and a Free Software Enthusiast. He has actively contributed and still contributing to interesting Free Software projects. To know more visit http://www.stylesen.org/










