\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{social holic} \pdfinfo{ /Title (chinese-classic.pdf) /Creator (Cheatography) /Author (social holic) /Subject (Chinese Classic 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}{5239A3} \definecolor{LightBackground}{HTML}{F4F2F9} \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{Chinese Classic Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{social holic} via \textcolor{DarkBackground}{\uline{cheatography.com/19696/cs/2673/}}} \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}social holic \\ \uline{cheatography.com/social-holic} \\ \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Not Yet Published.\\ 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} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{1}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{1) 經은 \newline % Row Count 1 (+ 1) \textless{}주역 周易\textgreater{} \newline % Row Count 2 (+ 1) \textless{}서경 書經\textgreater{} \newline % Row Count 3 (+ 1) \textless{}시경 詩經\textgreater{} \newline % Row Count 4 (+ 1) \textless{}주례 周禮\textgreater{} \newline % Row Count 5 (+ 1) \textless{}예기 禮記\textgreater{} \newline % Row Count 6 (+ 1) \textless{}의례 儀禮\textgreater{} \newline % Row Count 7 (+ 1) \textless{}춘추좌씨전 春秋左氏傳\textgreater{} \newline % Row Count 8 (+ 1) \textless{}춘추공양전 春秋公羊傳\textgreater{} \newline % Row Count 9 (+ 1) \textless{}춘추곡량전 春秋穀梁傳\textgreater{} \newline % Row Count 10 (+ 1) \textless{}논어 論語\textgreater{} \newline % Row Count 11 (+ 1) \textless{}효경 孝經\textgreater{} \newline % Row Count 12 (+ 1) \textless{}이아 爾雅\textgreater{} \newline % Row Count 13 (+ 1) \textless{}맹자 孟子\textgreater{}까지 보통 13경(經)을 꼽음.% Row Count 14 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{2}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{2) 史는 25史: 사마천의 사기 \textasciitilde{} 청사고까지 25종의 역사서. \newline % Row Count 2 (+ 2) \textless{}사기 史記\textgreater{} \newline % Row Count 3 (+ 1) \textless{}한서 漢書\textgreater{} \newline % Row Count 4 (+ 1) \textless{}후한서 後漢書\textgreater{} \newline % Row Count 5 (+ 1) \textless{}삼국지 三國志\textgreater{} \newline % Row Count 6 (+ 1) \textless{}진서 晉書\textgreater{} \newline % Row Count 7 (+ 1) \textless{}송서 宋書\textgreater{} \newline % Row Count 8 (+ 1) \textless{}남제서 南齊書\textgreater{} \newline % Row Count 9 (+ 1) \textless{}양서 梁書\textgreater{} \newline % Row Count 10 (+ 1) \textless{}진서 陳書\textgreater{} \newline % Row Count 11 (+ 1) \textless{}위서 魏書\textgreater{} \newline % Row Count 12 (+ 1) \textless{}북제서 北齊書\textgreater{} \newline % Row Count 13 (+ 1) \textless{}주서 周書\textgreater{} \newline % Row Count 14 (+ 1) \textless{}남사 南史\textgreater{} \newline % Row Count 15 (+ 1) \textless{}북사 北史\textgreater{} \newline % Row Count 16 (+ 1) \textless{}수서 隋書\textgreater{} \newline % Row Count 17 (+ 1) \textless{}구당서 舊唐書\textgreater{} \newline % Row Count 18 (+ 1) \textless{}신당서 新唐書\textgreater{} \newline % Row Count 19 (+ 1) \textless{}구오대사 舊五代史\textgreater{} \newline % Row Count 20 (+ 1) \textless{}신오대사 新五代史\textgreater{} \newline % Row Count 21 (+ 1) \textless{}송사 宋史\textgreater{} \newline % Row Count 22 (+ 1) \textless{}요사 遼史\textgreater{} \newline % Row Count 23 (+ 1) \textless{}금사 金史\textgreater{} \newline % Row Count 24 (+ 1) \textless{}원사 元史\textgreater{} \newline % Row Count 25 (+ 1) \textless{}명사 明史\textgreater{}까지가 24사. \newline % Row Count 26 (+ 1) 여기에 \newline % Row Count 27 (+ 1) \textless{}청사고 淸史稿\textgreater{}를 더하면 25사, \newline % Row Count 28 (+ 1) \textless{}신원사 新元史\textgreater{}까지 합치면 26사라고 함.% Row Count 30 (+ 2) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{3}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{3) 子는 제자백가라고 불리는데, \newline % Row Count 1 (+ 1) 크게 \newline % Row Count 2 (+ 1) 유가(儒家) \newline % Row Count 3 (+ 1) 묵가(墨家) \newline % Row Count 4 (+ 1) 도가(道家) \newline % Row Count 5 (+ 1) 음양가(陰陽家) \newline % Row Count 6 (+ 1) 명가(名家) \newline % Row Count 7 (+ 1) 종횡가(縱橫家) \newline % Row Count 8 (+ 1) 법가(法家) \newline % Row Count 9 (+ 1) 잡가(雜家) \newline % Row Count 10 (+ 1) 농가(農家)의 구류(九流)로 나누고, \newline % Row Count 11 (+ 1) 소설가(小說家)를 합치면 십가(十家)라고 부름.% Row Count 13 (+ 2) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{5.377cm}}{\bf\textcolor{white}{4}} \tn \SetRowColor{white} \mymulticolumn{1}{x{5.377cm}}{4) 集은 시(詩)·부(賦) 등의 개인 문집. 문학책이 여기에 포함됨.% Row Count 2 (+ 2) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}