\documentclass[10pt,a4paper]{article} % Packages \usepackage{fancyhdr} % For header and footer \usepackage{multicol} % Allows multicols in tables \usepackage{tabularx} % Intelligent column widths \usepackage{tabulary} % Used in header and footer \usepackage{hhline} % Border under tables \usepackage{graphicx} % For images \usepackage{xcolor} % For hex colours %\usepackage[utf8x]{inputenc} % For unicode character support \usepackage[T1]{fontenc} % Without this we get weird character replacements \usepackage{colortbl} % For coloured tables \usepackage{setspace} % For line height \usepackage{lastpage} % Needed for total page number \usepackage{seqsplit} % Splits long words. %\usepackage{opensans} % Can't make this work so far. Shame. Would be lovely. \usepackage[normalem]{ulem} % For underlining links % Most of the following are not required for the majority % of cheat sheets but are needed for some symbol support. \usepackage{amsmath} % Symbols \usepackage{MnSymbol} % Symbols \usepackage{wasysym} % Symbols %\usepackage[english,german,french,spanish,italian]{babel} % Languages % Document Info \author{Karionis (Karionis)} \pdfinfo{ /Title (css2-1-deutsch.pdf) /Creator (Cheatography) /Author (Karionis (Karionis)) /Subject (CSS2.1 deutsch Cheat Sheet) } % Lengths and widths \addtolength{\textwidth}{6cm} \addtolength{\textheight}{-1cm} \addtolength{\hoffset}{-3cm} \addtolength{\voffset}{-2cm} \setlength{\tabcolsep}{0.2cm} % Space between columns \setlength{\headsep}{-12pt} % Reduce space between header and content \setlength{\headheight}{85pt} % If less, LaTeX automatically increases it \renewcommand{\footrulewidth}{0pt} % Remove footer line \renewcommand{\headrulewidth}{0pt} % Remove header line \renewcommand{\seqinsert}{\ifmmode\allowbreak\else\-\fi} % Hyphens in seqsplit % This two commands together give roughly % the right line height in the tables \renewcommand{\arraystretch}{1.3} \onehalfspacing % Commands \newcommand{\SetRowColor}[1]{\noalign{\gdef\RowColorName{#1}}\rowcolor{\RowColorName}} % Shortcut for row colour \newcommand{\mymulticolumn}[3]{\multicolumn{#1}{>{\columncolor{\RowColorName}}#2}{#3}} % For coloured multi-cols \newcolumntype{x}[1]{>{\raggedright}p{#1}} % New column types for ragged-right paragraph columns \newcommand{\tn}{\tabularnewline} % Required as custom column type in use % Font and Colours \definecolor{HeadBackground}{HTML}{333333} \definecolor{FootBackground}{HTML}{666666} \definecolor{TextColor}{HTML}{333333} \definecolor{DarkBackground}{HTML}{34546E} \definecolor{LightBackground}{HTML}{F2F4F5} \renewcommand{\familydefault}{\sfdefault} \color{TextColor} % Header and Footer \pagestyle{fancy} \fancyhead{} % Set header to blank \fancyfoot{} % Set footer to blank \fancyhead[L]{ \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{C} \SetRowColor{DarkBackground} \vspace{-7pt} {\parbox{\dimexpr\textwidth-2\fboxsep\relax}{\noindent \hspace*{-6pt}\includegraphics[width=5.8cm]{/web/www.cheatography.com/public/images/cheatography_logo.pdf}} } \end{tabulary} \columnbreak \begin{tabulary}{11cm}{L} \vspace{-2pt}\large{\bf{\textcolor{DarkBackground}{\textrm{CSS2.1 deutsch Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{Karionis (Karionis)} via \textcolor{DarkBackground}{\uline{cheatography.com/2670/cs/685/}}} \end{tabulary} \end{multicols}} \fancyfoot[L]{ \footnotesize \noindent \begin{multicols}{3} \begin{tabulary}{5.8cm}{LL} \SetRowColor{FootBackground} \mymulticolumn{2}{p{5.377cm}}{\bf\textcolor{white}{Cheatographer}} \\ \vspace{-2pt}Karionis (Karionis) \\ \uline{cheatography.com/karionis} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Published 29th November, 2012.\\ Updated 12th May, 2016.\\ Page {\thepage} of \pageref{LastPage}. \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Sponsor}} \\ \SetRowColor{white} \vspace{-5pt} %\includegraphics[width=48px,height=48px]{dave.jpeg} Measure your website readability!\\ www.readability-score.com \end{tabulary} \end{multicols}} \begin{document} \raggedright \raggedcolumns % Set font size to small. Switch to any value % from this page to resize cheat sheet text: % www.emerson.emory.edu/services/latex/latex_169.html \footnotesize % Small font. \begin{multicols*}{3} \begin{tabularx}{5.377cm}{x{1.51041 cm} x{1.41887 cm} x{1.64772 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Abmessungen}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{height}}: & auto; & H{\"o}he (Standard) \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & 100px; & \tn % Row Count 3 (+ 1) % Row 2 \SetRowColor{LightBackground} & 20\%; & \tn % Row Count 4 (+ 1) % Row 3 \SetRowColor{white} & 5.0em; & \tn % Row Count 5 (+ 1) % Row 4 \SetRowColor{LightBackground} {\bf{min-height}}: & (siehe height) & minimale H{\"o}he \tn % Row Count 7 (+ 2) % Row 5 \SetRowColor{white} {\bf{max-height}}: & (siehe height) & maximale H{\"o}he \tn % Row Count 9 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{width}}: & (siehe height) & Breite \tn % Row Count 11 (+ 2) % Row 7 \SetRowColor{white} {\bf{min-width}}: & (siehe height) & minimale Breite \tn % Row Count 13 (+ 2) % Row 8 \SetRowColor{LightBackground} {\bf{max-width}}: & (siehe height) & maximale Breite \tn % Row Count 15 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.00694 cm} p{0.68655 cm} x{2.88351 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Positionierung}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{position}}: & \seqsplit{static;} & Standard \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & \seqsplit{relative;} & relativ zur ursprünglichen Position \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} & \seqsplit{absolute;} & abh{\"a}ngig vom Elternelement \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} & \seqsplit{fixed;} & abh{\"a}ngig vom Browserfenster \tn % Row Count 8 (+ 2) % Row 4 \SetRowColor{LightBackground} {\bf{top}}: & auto; & Standard \tn % Row Count 9 (+ 1) % Row 5 \SetRowColor{white} {\bf{bottom}}: & \seqsplit{100px;} & \tn % Row Count 11 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{left}}: & 20\%; & \tn % Row Count 13 (+ 2) % Row 7 \SetRowColor{white} {\bf{right}}: & \seqsplit{-2.0em;} & \tn % Row Count 15 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \SetRowColor{LightBackground} \mymulticolumn{3}{x{5.377cm}}{{\emph{top}}, {\emph{bottom}}, {\emph{left}}, {\emph{right}} werden nur bei {\emph{position: relative}}, {\emph{absolute}} und {\emph{fixed}} beachtet.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{0.82386 cm} p{0.50347 cm} x{3.24967 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Floating}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{float}}: & none; & Standard \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & left; & Element steht links und wird rechts umflossen \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} & \seqsplit{right:} & Element steht rechts und wird links umflossen. \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} {\bf{clear}}: & none; & Standard \tn % Row Count 8 (+ 2) % Row 4 \SetRowColor{LightBackground} & left; & Aufheben des Umflie{\ss}ens links \tn % Row Count 10 (+ 2) % Row 5 \SetRowColor{white} & \seqsplit{right;} & Aufheben des Umflie{\ss}ens links \tn % Row Count 12 (+ 2) % Row 6 \SetRowColor{LightBackground} & both; & Aufheben beidseitigen Umflie{\ss}ens \tn % Row Count 14 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.55618 cm} x{0.96117 cm} x{2.05965 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Farbe}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{color}}: & red; & Vordergrundfarbe (Text) \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & \seqsplit{\#789ABC;} & hexadezimaler Farbwert \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} & rgb(0,25,50); & RGB-Farbwerte \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} {\bf{background-color}}: & (siehe color) & Hintergrundfarbe \tn % Row Count 8 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{Kommentar}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{5.377cm}}{/{\bf{{\emph{* Kommentartext }}}}*/} \tn % Row Count 1 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.05271 cm} x{1.51041 cm} x{2.01388 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Textformatierung}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{font-family}}: & "Times New Roman" & Schriftart (Times) \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & Arial, Helvetica, sans-serif; & serifenlose Schrift \tn % Row Count 5 (+ 3) % Row 2 \SetRowColor{LightBackground} {\bf{font-size}}: & 12pt; & Schriftgr{\"o}{\ss}e (Punkt) \tn % Row Count 7 (+ 2) % Row 3 \SetRowColor{white} & 10px; & Pixel \tn % Row Count 8 (+ 1) % Row 4 \SetRowColor{LightBackground} & 1.0em; & relativ zum Elternelement \tn % Row Count 10 (+ 2) % Row 5 \SetRowColor{white} & 120\%; & relativ zur Grundgr{\"o}{\ss}e \tn % Row Count 12 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{font-style}}: & normal; & Schriftstil (Standard) \tn % Row Count 14 (+ 2) % Row 7 \SetRowColor{white} & italic; & kursiv \tn % Row Count 15 (+ 1) % Row 8 \SetRowColor{LightBackground} & oblique; & schr{\"a}g \tn % Row Count 16 (+ 1) % Row 9 \SetRowColor{white} {\bf{font-weight}}: & lighter; & Schriftst{\"a}rke (dünn) \tn % Row Count 18 (+ 2) % Row 10 \SetRowColor{LightBackground} & normal; & Standard \tn % Row Count 19 (+ 1) % Row 11 \SetRowColor{white} & bold; & \tn % Row Count 20 (+ 1) % Row 12 \SetRowColor{LightBackground} & bolder; & \tn % Row Count 21 (+ 1) % Row 13 \SetRowColor{white} {\bf{line-height}}: & normal; & Zeilenh{\"o}he (Standard) \tn % Row Count 23 (+ 2) % Row 14 \SetRowColor{LightBackground} & 14pt & Punkt \tn % Row Count 24 (+ 1) % Row 15 \SetRowColor{white} & 20px & Pixel \tn % Row Count 25 (+ 1) % Row 16 \SetRowColor{LightBackground} & 120\% & relativ zur Schriftgr{\"o}{\ss}e \tn % Row Count 27 (+ 2) % Row 17 \SetRowColor{white} & 1.2em; & relativ zum Elternelement \tn % Row Count 29 (+ 2) % Row 18 \SetRowColor{LightBackground} {\bf{letter-spacing}}: & normal; & Zeichenabstand (Standard) \tn % Row Count 32 (+ 3) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{1.05271 cm} x{1.51041 cm} x{2.01388 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Textformatierung (cont)}} \tn % Row 19 \SetRowColor{LightBackground} & 0.05em; & relativ zum Elternelement \tn % Row Count 2 (+ 2) % Row 20 \SetRowColor{white} {\bf{text-align}}: & left; & Ausrichtung (Standard) \tn % Row Count 4 (+ 2) % Row 21 \SetRowColor{LightBackground} & right; & \tn % Row Count 5 (+ 1) % Row 22 \SetRowColor{white} & center; & zentriert \tn % Row Count 6 (+ 1) % Row 23 \SetRowColor{LightBackground} & justify; & Blocksatz \tn % Row Count 7 (+ 1) % Row 24 \SetRowColor{white} {\bf{text-decoration}}: & none; & \seqsplit{Schriftauszeichnung} (Standard) \tn % Row Count 10 (+ 3) % Row 25 \SetRowColor{LightBackground} & underline; & unterstrichen \tn % Row Count 11 (+ 1) % Row 26 \SetRowColor{white} & \seqsplit{line-through;} & durchgestrichen \tn % Row Count 13 (+ 2) % Row 27 \SetRowColor{LightBackground} {\bf{text-indent}}: & 1.0em; & Einrückung \tn % Row Count 15 (+ 2) % Row 28 \SetRowColor{white} & 10\%; & \tn % Row Count 16 (+ 1) % Row 29 \SetRowColor{LightBackground} {\bf{text-transform}}: & none; & Textauszeichnung (Standard) \tn % Row Count 19 (+ 3) % Row 30 \SetRowColor{white} & capitalize; & Kapit{\"a}lchen \tn % Row Count 20 (+ 1) % Row 31 \SetRowColor{LightBackground} & uppercase; & Gro{\ss}buchstaben \tn % Row Count 22 (+ 2) % Row 32 \SetRowColor{white} & lowercase; & \seqsplit{Kleinbuchststaben} \tn % Row Count 24 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.14425 cm} x{1.00694 cm} x{2.42581 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Innenabstand}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{padding}}: & 0; & keiner \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & 2px 4px; & 2 Pixel oben u. unten, 4 Pixel rechts u. links \tn % Row Count 5 (+ 3) % Row 2 \SetRowColor{LightBackground} & 1pt 2px 3\% 4.0em; & Abstand oben, rechts, unten, links \tn % Row Count 8 (+ 3) % Row 3 \SetRowColor{white} {\bf{padding-top}}: & 10px; & Abstand oben \tn % Row Count 10 (+ 2) % Row 4 \SetRowColor{LightBackground} {\bf{padding-bottom}}: & (s.o.) & Abstand unten \tn % Row Count 12 (+ 2) % Row 5 \SetRowColor{white} {\bf{padding-left}}: & (s.o.) & Abstand links \tn % Row Count 14 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{padding-right}}: & (s.o.) & Abstand rechts \tn % Row Count 16 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.64772 cm} x{1.64772 cm} x{1.28156 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Aussenabstand}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{margin}}: & 0; & keiner \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} & 10px 20px; & (s. padding) \tn % Row Count 3 (+ 2) % Row 2 \SetRowColor{LightBackground} & 1pt 2px 3\% -4.0em; & (s. padding) \tn % Row Count 5 (+ 2) % Row 3 \SetRowColor{white} {\bf{margin-top}}: & 10px; & Abstand oben \tn % Row Count 7 (+ 2) % Row 4 \SetRowColor{LightBackground} {\bf{margin-bottom}}: & (s. o.) & Abstand unten \tn % Row Count 9 (+ 2) % Row 5 \SetRowColor{white} {\bf{margin-left}}: & (s. o.) & Abstand links \tn % Row Count 11 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{margin-right}}: & (s. o.) & Abstand rechts \tn % Row Count 13 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}---} \SetRowColor{LightBackground} \mymulticolumn{3}{x{5.377cm}}{AußenabstÃ$\frac{3}{4}$nde dÃ$\frac{1}{4}$rfen auch negative Werte annehmen.} \tn \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.00694 cm} x{1.32733 cm} x{2.24273 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{5.377cm}}{\bf\textcolor{white}{Rahmen}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{border}}: & 1px solid; & Rahmen 1 Pixel St{\"a}rke \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} & thin dotted red; & dünner, roter und gepunkteter Rahmen \tn % Row Count 5 (+ 3) % Row 2 \SetRowColor{LightBackground} & 0.2em dashed \#D0D0D0; & gestrichelter grauer Rahmen \tn % Row Count 7 (+ 2) % Row 3 \SetRowColor{white} {\bf{border-top}}: & (s. o.) & oberer Rahmen \tn % Row Count 9 (+ 2) % Row 4 \SetRowColor{LightBackground} {\bf{border-bottom}}: & (s. o.) & unterer Rahmen \tn % Row Count 12 (+ 3) % Row 5 \SetRowColor{white} {\bf{border-left}}: & (s. o.) & linker Rahmen \tn % Row Count 14 (+ 2) % Row 6 \SetRowColor{LightBackground} {\bf{border-right}}: & (s. o.) & rechter Rahmen \tn % Row Count 17 (+ 3) % Row 7 \SetRowColor{white} {\bf{border-weight}}: & 1px 2px 3px 4px; & Rahmenst{\"a}rke \tn % Row Count 20 (+ 3) % Row 8 \SetRowColor{LightBackground} {\bf{border-style}}: & solid; & Rahmenstil \tn % Row Count 23 (+ 3) % Row 9 \SetRowColor{white} {\bf{border-color}}: & black gray silver white; & Rahmenfarbe \tn % Row Count 26 (+ 3) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}