Cheat Sheet for LATEX Firuza Karmali aka Aibara 1 of 2

1 Basics Page Breaks: \pagebreak OR \newpage Document Structure \documentclass[10pt|11pt|12pt] 2- Page: \documentclass[...,twocolumn]{...} {article||report} \title{Title of your Document} Multi Column: \usepackage{multicol} \{Name 1 \\ Name 2} \begin{multicols}{No. of cols} \date{\today} ...... \begin{document} \end{multicols} \ maketitle ... New column: \columnbreak \end{document} Multi-Column(Spacing): \setlength{\columnsep}{Xpt} Multi-Column(Rule): Level No. LevelName / Sections Article Report Book \setlength{\columnseprule}{Xpt} -1 \ part{Title} Footnotes: 0 \{Title} N ... \footnote{Text...} ... 1 \{Title} 3 Text Attributes 2 \subsection{Title} 3 \subsubsection{Title} Style Command Size 10pt 11pt 12pt 4 \{Title} Bold \textbf{...} tiny 5 6 6 5 \subparagraph{Title} Italics \textit{...} scriptsize 7 8 8 Blank cell denotes ‘Yes’ \emph{...} footnotesize 8 9 10 ToC (): \tableofcontents Underline \underline{...} small 9 10 10.95 Hide in ToC: LevelName*{...} E.g. \section*{...} Alternate Title in ToC (Display alias): \textsc{...} normalsize 10 10.95 12 E.g. \section[Alternative]{Actual Title} Roman \textrm{...} large 12 12 14.4 Sans \textsf{...} Large 14.4 14.4 17.28 Hyhen:- -:\textendash -dash:\textemdash Typewriter \texttt{...} LARGE 17.28 17.28 20.74 Special characters Superscript \textsuperscript{...} huge 20.74 20.74 24.88 !@*()-+=?[]/\$ \& \% \_ \{ \} \# Subscript \textsubscript{...} Huge 24.88 24.88 24.88 2 Formatting Pages Colors: https ://en.wikibooks.org/wiki/LaTeX/Colors Size: \usepackage[]{geometry} \usepackage{color} %Basic Colors : a0paper to a6paper, b0paper to b6paper, \usepackage[dvipsnames]{xcolor} %More colors legalpaper, executivepaper, etc. Single color: \textcolor{name}{...Text...} Mix with white: Margins (Single Side Document): \textcolor{name!Percentage}{Text} Mixture of 2: \textcolor{name!Percentage!name}{Text} \usepackage[=1in]{geometry} Page color: \pagecolor{name} \usepackage[top=1in,bottom=2in,left=1in,right=1in] { geometry } Text Alignment Two Sided Document Certain part: \begin{flushleft|flushright|center} \documentclass[twoside]{article|report} ... \documentclass{book} %book is 2sided \end{flushleft | flushright | center} Margins (Two Sided Document - Even and Odd): Larger part: \flushleft \flushright \centering Justify: \usepackage{ragged2e} \justify \usepackage[inner=2in,outer=1in]{geometry} Spacing Page Numbering(Entire Document): \pagestyle{