-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Joshua
committed
Oct 29, 2019
1 parent
a55ffe0
commit e77f27f
Showing
4 changed files
with
200 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
.PHONY: clean | ||
cheatsheet: cheatsheet.tex | ||
latexmk -pdf | ||
|
||
clean: | ||
latexmk -C |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
\documentclass[10pt,landscape,a4paper]{article} | ||
\usepackage[utf8]{inputenc} | ||
\usepackage[ngerman]{babel} | ||
\usepackage[T1]{fontenc} | ||
%\usepackage[LY1,T1]{fontenc} | ||
%\usepackage{frutigernext} | ||
%\usepackage[lf,minionint]{MinionPro} | ||
\usepackage{tikz} | ||
\usetikzlibrary{shapes,positioning,arrows,fit,calc,graphs,graphs.standard} | ||
\usepackage[nosf]{kpfonts} | ||
\usepackage[t1]{sourcesanspro} | ||
\usepackage{multicol} | ||
\usepackage{wrapfig} | ||
\usepackage[top=0mm,bottom=1mm,left=0mm,right=1mm]{geometry} | ||
\usepackage[framemethod=tikz]{mdframed} | ||
\usepackage{microtype} | ||
\usepackage{pdfpages} | ||
|
||
\let\bar\overline | ||
|
||
\include{includes/def} | ||
|
||
\begin{document} | ||
%\footnotesize | ||
%Template from tim-st/latex-cheatsheet | ||
\small | ||
\begin{multicols*}{5} | ||
\section{Topic} | ||
\subsection{Thing you gotta remember} | ||
\end{multicols*} | ||
\end{document} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,160 @@ | ||
\definecolor{myblue}{cmyk}{1,.72,0,.38} | ||
|
||
\def\firstcircle{(0,0) circle (1.5cm)} | ||
\def\secondcircle{(0:2cm) circle (1.5cm)} | ||
|
||
\colorlet{circle edge}{myblue} | ||
\colorlet{circle area}{myblue!5} | ||
|
||
\tikzset{filled/.style={fill=circle area, draw=circle edge, thick}, | ||
outline/.style={draw=circle edge, thick}} | ||
|
||
\pgfdeclarelayer{background} | ||
\pgfsetlayers{background,main} | ||
|
||
\everymath\expandafter{\the\everymath \color{myblue}} | ||
\everydisplay\expandafter{\the\everydisplay \color{myblue}} | ||
|
||
\renewcommand{\baselinestretch}{.8} | ||
\pagestyle{empty} | ||
|
||
\global\mdfdefinestyle{header}{% | ||
linecolor=gray,linewidth=1pt,% | ||
leftmargin=0mm,rightmargin=0mm,skipbelow=0mm,skipabove=0mm, | ||
} | ||
|
||
\newcommand{\header}{ | ||
\begin{mdframed}[style=header] | ||
\footnotesize | ||
\sffamily | ||
Cheatsheet | ||
Joshua Hwang (44302650) | ||
\end{mdframed} | ||
} | ||
|
||
\makeatletter % Author: https://tex.stackexchange.com/questions/218587/how-to-set-one-header-for-each-page-using-multicols | ||
\renewcommand{\section}{\@startsection{section}{1}{0mm}% | ||
{.2ex}% | ||
{.2ex}%x | ||
{\color{myblue}\sffamily\small\bfseries}} | ||
\renewcommand{\subsection}{\@startsection{subsection}{1}{0mm}% | ||
{.2ex}% | ||
{.2ex}%x | ||
{\sffamily\bfseries}} | ||
|
||
|
||
|
||
\def\multi@column@out{% | ||
\ifnum\outputpenalty <-\@M | ||
\speci@ls \else | ||
\ifvoid\colbreak@box\else | ||
\mult@info\@ne{Re-adding forced | ||
break(s) for splitting}% | ||
\setbox\@cclv\vbox{% | ||
\unvbox\colbreak@box | ||
\penalty-\@Mv\unvbox\@cclv}% | ||
\fi | ||
\splittopskip\topskip | ||
\splitmaxdepth\maxdepth | ||
\dimen@\@colroom | ||
\divide\skip\footins\col@number | ||
\ifvoid\footins \else | ||
\leave@mult@footins | ||
\fi | ||
\let\ifshr@kingsaved\ifshr@king | ||
\ifvbox \@kludgeins | ||
\advance \dimen@ -\ht\@kludgeins | ||
\ifdim \wd\@kludgeins>\z@ | ||
\shr@nkingtrue | ||
\fi | ||
\fi | ||
\process@cols\mult@gfirstbox{% | ||
%%%%% START CHANGE | ||
\ifnum\count@=\numexpr\mult@rightbox+2\relax | ||
\setbox\count@\vsplit\@cclv to \dimexpr \dimen@-1cm\relax | ||
\setbox\count@\vbox to \dimen@{\vbox to 1cm{\header}\unvbox\count@\vss}% | ||
\else | ||
\setbox\count@\vsplit\@cclv to \dimen@ | ||
\fi | ||
%%%%% END CHANGE | ||
\set@keptmarks | ||
\setbox\count@ | ||
\vbox to\dimen@ | ||
{\unvbox\count@ | ||
\remove@discardable@items | ||
\ifshr@nking\vfill\fi}% | ||
}% | ||
\setbox\mult@rightbox | ||
\vsplit\@cclv to\dimen@ | ||
\set@keptmarks | ||
\setbox\mult@rightbox\vbox to\dimen@ | ||
{\unvbox\mult@rightbox | ||
\remove@discardable@items | ||
\ifshr@nking\vfill\fi}% | ||
\let\ifshr@king\ifshr@kingsaved | ||
\ifvoid\@cclv \else | ||
\unvbox\@cclv | ||
\ifnum\outputpenalty=\@M | ||
\else | ||
\penalty\outputpenalty | ||
\fi | ||
\ifvoid\footins\else | ||
\PackageWarning{multicol}% | ||
{I moved some lines to | ||
the next page.\MessageBreak | ||
Footnotes on page | ||
\thepage\space might be wrong}% | ||
\fi | ||
\ifnum \c@tracingmulticols>\thr@@ | ||
\hrule\allowbreak \fi | ||
\fi | ||
\ifx\@empty\kept@firstmark | ||
\let\firstmark\kept@topmark | ||
\let\botmark\kept@topmark | ||
\else | ||
\let\firstmark\kept@firstmark | ||
\let\botmark\kept@botmark | ||
\fi | ||
\let\topmark\kept@topmark | ||
\mult@info\tw@ | ||
{Use kept top mark:\MessageBreak | ||
\meaning\kept@topmark | ||
\MessageBreak | ||
Use kept first mark:\MessageBreak | ||
\meaning\kept@firstmark | ||
\MessageBreak | ||
Use kept bot mark:\MessageBreak | ||
\meaning\kept@botmark | ||
\MessageBreak | ||
Produce first mark:\MessageBreak | ||
\meaning\firstmark | ||
\MessageBreak | ||
Produce bot mark:\MessageBreak | ||
\meaning\botmark | ||
\@gobbletwo}% | ||
\setbox\@cclv\vbox{\unvbox\partial@page | ||
\page@sofar}% | ||
\@makecol\@outputpage | ||
\global\let\kept@topmark\botmark | ||
\global\let\kept@firstmark\@empty | ||
\global\let\kept@botmark\@empty | ||
\mult@info\tw@ | ||
{(Re)Init top mark:\MessageBreak | ||
\meaning\kept@topmark | ||
\@gobbletwo}% | ||
\global\@colroom\@colht | ||
\global \@mparbottom \z@ | ||
\process@deferreds | ||
\@whilesw\if@fcolmade\fi{\@outputpage | ||
\global\@colroom\@colht | ||
\process@deferreds}% | ||
\mult@info\@ne | ||
{Colroom:\MessageBreak | ||
\the\@colht\space | ||
after float space removed | ||
= \the\@colroom \@gobble}% | ||
\set@mult@vsize \global | ||
\fi} | ||
|
||
\makeatother | ||
\setlength{\parindent}{0pt} |