Alessio Caiazza is sharing code with you

Bitbucket is a code hosting site. Unlimited public and private repositories. Free for small teams.

Don't show this again

nolith / ruby-beamer

My template for beamer slides with ruby code examples

Clone this repository (size: 534.4 KB): HTTPS / SSH
hg clone https://bitbucket.org/nolith/ruby-beamer
hg clone ssh://hg@bitbucket.org/nolith/ruby-beamer

ruby-beamer / introduzione.tex

\section{Introduzione a ruby}

\subsection{hello world}\label{sub:hello_world} % (fold)
\frame{\frametitle{Un ``hello world'' in stile ruby} 
        \begin{block}{Niente paura!} 
                Ecco un ``Hello World'' un po' fuori dal comune.\\
                Piů avanti capiremo bene ciň che accade.   
        \end{block}

        \begin{block}{Hello World.rb}   
                \rubysource{sources/snippets/hello_world}
                \rubyout{sources/snippets/hello_world}      
        \end{block}
}  
% subsection hello_world (end)
\subsection{Definire una funzione}\label{sub:definire_una_funzione} % (fold)
\frame{\frametitle{Definire una funzione}
\begin{block}{Le funzioni sono definite attraverso la parola chiave \texttt{def}}     
        \rubysource{sources/snippets/hello_method}
        \rubyout{sources/snippets/hello_method}    
\end{block}
}
% subsection definire_una_funzione (end)

\subsection{Orientato agli oggetti}
\vskip 11pt
\frame[t]{\frametitle{In ruby tutto č un oggetto}
\begin{block}{Tutto č un oggetto, vediamo alcune chiamate di metodi}
        \only<1>{\RubyXMP[0.43\textwidth]{}{sources/object}}
        \only<2>{\RubyXMP[0.43\textwidth]{}{sources/object2}}
\end{block}
}