Skip to content

ecomaikgolf/tugraz-latex-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TUGraz Personal LaTeX Template

Twocols example Onecol example

Examples: twocols.pdf, onecol.pdf

Dependencies

  • LaTeX compiler: pdflatex or lualatex or xelatex... (Recommended lualatex)
  • Needed LaTeX packages, see config/tugraz-style.sty. (Recommended texlive-full)
  • texlogfilter, or remove | texlogfilter $(SUP) from makefile

How to use

  1. Clone repository or use template
git clone --depth 1 https://github.com/ecomaikgolf/tugraz-latex-template.git
cd tugraz-latex-template

or

image

  1. Edit document.tex, modify 'CHANGEME' values & write desired text after \begin{document}
  2. Compile document
make
  1. Open document.pdf

Advanced usage

I defined my own commands/enviroments with modifications, take it into consideration. For example, for code use code and not lstlisting.

  • Add new packages in 'User Packages' (document.tex)
  • Write the bibliography at 'Bibliography' (document.tex)
\AtEndDocument{
\if\docbibliography1
  \begin{thebibliography}{9}
    % \bibitem{key}
    % Text
    
    \bibitem{texbook}
    Donald E. Knuth (1986) \emph{The \TeX{} Book}, Addison-Wesley Professional.

    \bibitem{lamport94}
    Leslie Lamport (1994) \emph{\LaTeX: a document preparation system}, Addison Wesley, Massachusetts, 2nd ed.

  \end{thebibliography}
\fi
}
  • Insert a figure with \fig
\fig{example-figure}{30m}{The Figure Caption}{figurelabel}
  • Insert two figure with \figtwo
\figtwo{example-figure}{30m}{The Figure Caption 1}{figurelabel1}{example-figure}{30m}{The Figure Caption 2}{figurelabel2}{The General Caption}
  • Insert code listing
{
  \begin{code}[main.cpp]
int 
main() {
  return 0;
}
  \end{code}
  \captionof{lstlisting}{Main Example}
}
  • Insert terminal output listing
{
  \begin{terminal}[uptime]
18:00:21 up 45 min,  1 user,  load average: 0,29, 0,26, 0,27
  \end{terminal}
  \captionof{term}{Command Example}
}
  • Insert verbatim boxed enviroment
{
  \begin{verbox}
verbatimcontent
  \end{verbox}
}
  • Insert command
\begin{command}
yay -S texlive-full
\end{command}
  • Open two/three/four/ncols enviroment
\begin{twocols}
\end{twocols}
\begin{threecols}
\end{threecols}
\begin{fourcols}
\end{fourcols}
\begin{ncols}{5}
\end{ncols}
  • Reference labels
As seen in \autoref{label}
  • Insert code/text "number balls" (like No Starch Press)
begin{code}[title]
int a; ¡\cb{1}¡
\end{code}
In \tb{1} we create an int

Configure template

The template supports some 'tuning' parameters, such as accent/secondary colors, logo, font, twocols/onecol, twocols balancing, etc.

To change these options, go to 'Options' in document.tex and modify the default values.

Further configuration

Manually modify config/tugraz-style.sty

Comments

I am not a LaTeX expert, this template is intended for my personal use.

Borders have to be that thick to not cause line glitching problems in some renderers (chrome, firefox...), zathura handles them well but I have to support chrome due to it's popularity