%%
%% This is file `diploma.cls',
%% generated with the docstrip utility.
%%
%% The original source files were:
%% 
%% Diploma.dtx 
%%
%% Original
%% http://www.cs.vsb.cz/dvorsky/Latex.html
%%
%% Pro PedF MU v Brne upravil Tomas Miler 2007
%% http://amper.ped.muni.cz/~miler/indi/diplomka/LaTeX/
%%
\def\fileversion{1.5}
\def\filedate{2005/05/05}
\def\docdate{5. kv\v{e}tna 2005}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{diploma}
  [\filedate\space v\fileversion\space diploma LaTeX document class]
\newtoks\Dipl@DiplomaTypeName
\Dipl@DiplomaTypeName={Chyb\'{\i} typ diplomov\'e pr\'ace}
\newtoks\Dipl@Department
\Dipl@Department={Katedra informatiky}
\newtoks\Dipl@Title
\Dipl@Title={Chyb\'{\i} n\'azev diplomov\'e pr\'ace}
\newtoks\Dipl@Author


\DeclareOption{dept448}
  {\Dipl@Department={Katedra fyziky}}
\DeclareOption{dept451}
  {\Dipl@Department={Katedra elektroenergetiky}}
\DeclareOption{dept456}
  {\Dipl@Department={Katedra informatiky}}
\DeclareOption{dept457}
  {\Dipl@Department={Katedra aplikovan\'e matematiky}}
\DeclareOption{vb}{\Dipl@DefaultLanguage={vb}}
\DeclareOption{ansic}{\Dipl@DefaultLanguage={ansic}}
\DeclareOption{cpp}{\Dipl@DefaultLanguage={cpp}}
\DeclareOption{csharp}{\Dipl@DefaultLanguage={csharp}}
\DeclareOption{delphi}{\Dipl@DefaultLanguage={delphi}}
\DeclareOption{html}{\Dipl@DefaultLanguage={html}}
\DeclareOption{idl}{\Dipl@DefaultLanguage={idl}}
\DeclareOption{corba}{\Dipl@DefaultLanguage={corba}}
\DeclareOption{java}{\Dipl@DefaultLanguage={java}}
\DeclareOption{lisp}{\Dipl@DefaultLanguage={lisp}}
\DeclareOption{make}{\Dipl@DefaultLanguage={make}}
\DeclareOption{pascal}{\Dipl@DefaultLanguage={pascal}}
\DeclareOption{perl}{\Dipl@DefaultLanguage={perl}}
\DeclareOption{php}{\Dipl@DefaultLanguage={php}}
\DeclareOption{sql}{\Dipl@DefaultLanguage={sql}}
\DeclareOption{latex}{\Dipl@DefaultLanguage={latex}}
\DeclareOption{plaintex}{\Dipl@DefaultLanguage={plaintex}}
\DeclareOption{vhdl}{\Dipl@DefaultLanguage={vhdl}}
\DeclareOption{xml}{\Dipl@DefaultLanguage={xml}}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{article}}
\ProcessOptions
\LoadClass[11pt]{article}
\RequirePackage{czech}
\RequirePackage{fancyhdr}
\RequirePackage[a4paper,includeheadfoot,marginparwidth=0mm,marginparsep=0mm,
left=28mm,right=32mm,top=25mm,bottom=38mm]{geometry}
\RequirePackage{graphicx}
\RequirePackage{ifthen}
\RequirePackage{palatino}
\RequirePackage[final]{listings}
\RequirePackage{supertabular}
\RequirePackage{theorem}
\RequirePackage{rotating}
\newcommand{\Title}[1]{\Dipl@Title={#1}}
\newcommand{\Author}[1]{\Dipl@Author={#1}}
\newcommand{\Thanks}[1]{\Dipl@Thanks={#1}}
\newcommand{\CzechAbstract}[1]{\Dipl@CzechAbstract={#1}}
\newcommand{\CzechKeywords}[1]{\Dipl@CzechKeywords={#1}}
\newcommand{\EnglishAbstract}[1]{\Dipl@EnglishAbstract={#1}}
\newcommand{\EnglishKeywords}[1]{\Dipl@EnglishKeywords={#1}}
\newcommand{\MakeTitlePages}
{
  
  \setcounter{page}{0}
}
\newcommand{\Dipl@TitlePage}
{
  \thispagestyle{empty}
  \begin{center}
    \vspace*{-23mm}
    \sffamily
    {Masarykova Univerzita\\
    Pedagogick\'{a} fakulta\\
    \the\Dipl@Department\\}
    \medskip
    \hrule
    \vspace{50mm}
    {\Huge\bfseries\the\Dipl@Title}\\
    \bigskip
    \bigskip
    {\large\bfseries\the\Dipl@DiplomaTypeName}\\
  \end{center}
    \vfill
    
  \clearpage
}
\newcommand{\Dipl@Declaration}
{
  \thispagestyle{empty}
  \mbox{}\vfill
  \noindent{}
  \noindent{}V Brn\v{e} \today\hfill\hbox to50mm{\dotfill}
  \clearpage
}


}
\newcommand{\Dipl@AddTokens}[2]
  {\expandafter \global#1\expandafter{\the#1#2}}
\newcommand{\AddAcronym}[2]
  {\Dipl@AddTokens{\Dipl@Acronyms}{#1&--&#2\\}}
\newcommand{\Dipl@WriteAcronyms}[0]
{
  \ifthenelse{\equal{\the\Dipl@Acronyms}{\empty}}
  {}
  {
    \clearpage
    \thispagestyle{empty}
    \vspace*{20mm}
    \noindent
    {\sffamily\large\bfseries{}Seznam pou\v{z}it\'ych zkratek a symbol\accent23u}
    \begin{flushleft}
      \begin{supertabular}{p{0.2\textwidth}cp{0.7\textwidth}}
        \the\Dipl@Acronyms
      \end{supertabular}
    \end{flushleft}
  }
}
\pagestyle{fancy}
\fancyhf{}
\renewcommand{\sectionmark}[1]
  {\markboth{\MakeUppercase{\sffamily\thesection\quad#1}}{}}
\lhead{\leftmark}
\rhead{\bfseries\sffamily\thepage}
\headheight=16pt
\renewcommand\section{\clearpage\@startsection {section}{1}{\z@}%
  {-3.5ex \@plus -1ex \@minus -.2ex}%
  {2.3ex \@plus.2ex}%
  {\normalfont\sffamily\Large\bfseries}}
\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
  {-3.25ex\@plus -1ex \@minus -.2ex}%
  {1.5ex \@plus .2ex}%
  {\normalfont\sffamily\large\bfseries}}
\renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
  {-3.25ex\@plus -1ex \@minus -.2ex}%
  {1.5ex \@plus .2ex}%
  {\normalfont\normalsize\sffamily\bfseries}}
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
  {3.25ex \@plus1ex \@minus.2ex}%
  {-1em}%
  {\normalfont\normalsize\sffamily\bfseries}}
\renewcommand\subparagraph{\@startsection{subparagraph}{5}{\z@}%
  {3.25ex \@plus1ex \@minus .2ex}%
  {-1em}%
  {\normalfont\normalsize\sffamily\bfseries}}
\renewcommand\contentsname{\sffamily{}Obsah}
\renewcommand\listfigurename{\sffamily{}Seznam obr\'azk\accent23u}
\renewcommand\listtablename{\sffamily{}Seznam tabulek}
{\theorembodyfont{\itshape}\newtheorem{definition}{Definice}[section]}
{\theorembodyfont{\itshape}\newtheorem{theorem}{V\v{e}ta}[section]}
\newenvironment{proof}
  {\par\noindent\textbf{D\accent23ukaz.}}
  {\hfill\hbox{\vrule height5pt depth0pt width5pt}\par\medskip}
{\theorembodyfont{\rmfamily}\newtheorem{remark}{Pozn\'amka}[section]}
{\theoremstyle{break}\theorembodyfont{\rmfamily}
  \newtheorem{Dipl@examplebody}{P\v{r}\'{\i}klad}[section]}
\newenvironment{example}
  {\begin{Dipl@examplebody}}
  {
    \nopagebreak\hfill\hbox{\vrule height5pt depth0pt width5pt}
    \end{Dipl@examplebody}
  }
\def\lstlistlistingname{\sffamily{}Seznam v\'ypis\accent23u zdrojov\'eho k\'odu}
\def\lstlistingname{V\'ypis}
\newcommand{\Dipl@SetDefaultLanguage}[0]
{
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{vb}}
    {\lstset{language=[Visual]Basic}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{ansic}}
    {\lstset{language=[ANSI]C}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{cpp}}
    {\lstset{language=C++}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{csharp}}
    {\lstset{language=[Sharp]C}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{delphi}}
    {\lstset{language=Delphi}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{html}}
    {\lstset{language=HTML}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{idl}}
    {\lstset{language=IDL}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{corba}}
    {\lstset{language=[CORBA]IDL}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{java}}
    {\lstset{language=Java}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{lisp}}
    {\lstset{language=Lisp}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{make}}
    {\lstset{language=make}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{pascal}}
    {\lstset{language=Pascal}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{perl}}
    {\lstset{language=Perl}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{php}}
    {\lstset{language=PHP}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{sql}}
    {\lstset{language=SQL}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{latex}}
    {\lstset{language=[LaTeX]TeX}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{plaintex}}
    {\lstset{language=[plain]TeX}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{vhdl}}
    {\lstset{language=VHDL}}{}
  \ifthenelse{\equal{\the\Dipl@DefaultLanguage}{xml}}
    {\lstset{language=XML}}{}
}
\lstset%
{
  extendedchars=true,
  basicstyle=\footnotesize\sffamily,
  commentstyle=\sffamily\slshape,
  breaklines=true,
  tabsize=3,
  xleftmargin=3em,
  columns=flexible,
  print=true,
  captionpos=b,
  frame=lines,
  framexleftmargin=3em,
}
\newcommand{\InlCode}[1]{\lstinline[basicstyle=\small\sffamily]$#1$}
\def\appname{P\v{r}\'{\i}lohy}
\def\appname{P\v{r}\'{\i}lohy}
\renewcommand\appendix{\par
  \setcounter{section}{0}%
  \setcounter{subsection}{0}%
  \gdef\thesection{\@Alph\c@section}
  \addcontentsline{toc}{section}{\appname}%
  }
\def\refname{Literatura}
\def\refname{Literatura}
\renewenvironment{thebibliography}[1]
     {\section{\refname}%
      \list{\@biblabel{\@arabic\c@enumiv}}%
           {\settowidth\labelwidth{\@biblabel{#1}}%
            \leftmargin\labelwidth
            \advance\leftmargin\labelsep
            \@openbib@code
            \usecounter{enumiv}%
            \let\p@enumiv\@empty
            \renewcommand\theenumiv{\@arabic\c@enumiv}}%
      \sloppy
      \clubpenalty4000
      \@clubpenalty \clubpenalty
      \widowpenalty4000%
      \sfcode`\.\@m}
     {\def\@noitemerr
       {\@latex@warning{Empty `thebibliography' environment}}%
      \endlist}
\newcommand{\InsertFigure}[4]
{
  \begin{figure}[ht]
    \begin{center}
      \includegraphics[width=#2]{#1}
      \caption{#3}
      \label{#4}
    \end{center}
  \end{figure}
}
\newcommand{\InsertSidewaysFigure}[4]
{
  \begin{sidewaysfigure}
    \centering
    \includegraphics[width=#2]{#1}
    \caption{#3}
    \label{#4}
  \end{sidewaysfigure}
}
\setcounter{tocdepth}{2}
\setcounter{secnumdepth}{5}
\widowpenalty=10000
\clubpenalty=10000
\AtBeginDocument{\Dipl@SetDefaultLanguage}
\endinput
%%
%% End of file `diploma.cls'.
