Skip to content
Snippets Groups Projects
Commit 0e980ec6 authored by Valentin Bruch's avatar Valentin Bruch
Browse files

latex makro: margin box

parent 4f4ef650
No related branches found
No related tags found
No related merge requests found
\documentclass[ngerman]{standalone}
\begin{document}
Hallo Welt!
\end{document}
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
\usepackage{dtk-logos} \usepackage{dtk-logos}
\usepackage{hyperref} \usepackage{hyperref}
\usepackage{tikz} \usepackage{tikz}
\usetikzlibrary{backgrounds, fit, matrix, calc}
\usepackage{listings} \usepackage{listings}
\usepackage{calc} \usepackage{calc}
\graphicspath{{figures/}{examples/}} \graphicspath{{figures/}{examples/}}
...@@ -25,6 +26,20 @@ ...@@ -25,6 +26,20 @@
und der Aachener Linux User Group und der Aachener Linux User Group
} }
\newcommand\marginbox[3][2pt]{
\begin{tikzpicture}[even odd rule, scale=1]
\node[anchor=north west] (text) {%
\begin{minipage}{#1}%
#2%
\end{minipage}%
};
\begin{pgfonlayer}{background}
\node[draw opacity=.5, draw=blue, line width=#1, inner sep=2pt, fit = (text)] {};
\end{pgfonlayer}
\end{tikzpicture}
}
\begin{document} \begin{document}
\begin{frame}{OSAK \LaTeX-Workshop}{Installation einer \TeX-Distribution} \begin{frame}{OSAK \LaTeX-Workshop}{Installation einer \TeX-Distribution}
...@@ -48,7 +63,7 @@ ...@@ -48,7 +63,7 @@
\begin{frame}{Aufbau eines \LaTeX-Dokuments} \begin{frame}{Aufbau eines \LaTeX-Dokuments}
\begin{columns}[T] \begin{columns}[T]
\begin{column}{.35\textwidth} \begin{column}{.35\textwidth}
\LaTeX übersetzt\\ {\LaTeX} übersetzt\\
Text in ein PDF Text in ein PDF
\begin{itemize} \begin{itemize}
\item Formatierung durch\\Befehle im Text \item Formatierung durch\\Befehle im Text
...@@ -76,8 +91,7 @@ ...@@ -76,8 +91,7 @@
(2pt,-15pt) rectangle (\textwidth-2pt, -.4\textwidth+2pt); (2pt,-15pt) rectangle (\textwidth-2pt, -.4\textwidth+2pt);
\node[anchor=north west] at (0pt, 0pt) {PDF viewer: HelloWorld.pdf}; \node[anchor=north west] at (0pt, 0pt) {PDF viewer: HelloWorld.pdf};
\node[anchor=north west] at (2pt, -15pt) {\parbox[t][.4\textwidth-27pt][c]{\textwidth-12pt}{% \node[anchor=north west] at (2pt, -15pt) {\parbox[t][.4\textwidth-27pt][c]{\textwidth-12pt}{%
\centering \hspace{.1\textwidth}Hallo Welt!
\includegraphics{examples/minimal_standalone.pdf}
}}; }};
\end{tikzpicture} \end{tikzpicture}
\end{column} \end{column}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment