\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{Rigotti} \pdfinfo{ /Title (delphi-shortcuts.pdf) /Creator (Cheatography) /Author (Rigotti) /Subject (Delphi Shortcuts 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}{29A32D} \definecolor{LightBackground}{HTML}{F1F9F1} \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{Delphi Shortcuts Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{Rigotti} via \textcolor{DarkBackground}{\uline{cheatography.com/20941/cs/3796/}}} \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}Rigotti \\ \uline{cheatography.com/rigotti} \\ \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 17th January, 2017.\\ 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{2.33919 cm} x{2.63781 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{-}} \tn % Row 0 \SetRowColor{LightBackground} Alt+G & Goto line number in editor \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} Ctrl+O+G & Goto line number in editor \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} Ctrl+Shift+R & Start/stop recording editor macro \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} Ctrl+Shift+P & Play editor macro \tn % Row Count 7 (+ 1) % Row 4 \SetRowColor{LightBackground} Ctrl+Spacebar & Invoke code completion \tn % Row Count 9 (+ 2) % Row 5 \SetRowColor{white} \seqsplit{Ctrl+Shift+Spacebar} & Invoke code parameter hints \tn % Row Count 11 (+ 2) % Row 6 \SetRowColor{LightBackground} Ctrl + Enter & Open file at cursor \tn % Row Count 12 (+ 1) % Row 7 \SetRowColor{white} Ctrl + Shift + Enter & Find all references \tn % Row Count 14 (+ 2) % Row 8 \SetRowColor{LightBackground} Ctrl + Shift + C & Invoke class completion for the class that currently contains the cursor \tn % Row Count 18 (+ 4) % Row 9 \SetRowColor{white} Ctrl + Shift + \{\{fa-arrow-up\}\} & Navigate to method \seqsplit{implementation/declaration} \tn % Row Count 21 (+ 3) % Row 10 \SetRowColor{LightBackground} Ctrl + Shift + \{\{fa-arrow-down\}\} & Navigate to method \seqsplit{implementation/declaration} \tn % Row Count 24 (+ 3) % Row 11 \SetRowColor{white} Ctrl + Shift + 1 - 9 & Set a bookmark at current row in the source \tn % Row Count 27 (+ 3) % Row 12 \SetRowColor{LightBackground} Ctrl + 1 - 9 & Go to a bookmark row in the source \tn % Row Count 29 (+ 2) % Row 13 \SetRowColor{white} Ctrl + Alt + F12 & Opens the drop-down on the top-right corner of the code editor, listing all open files \tn % Row Count 34 (+ 5) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{2.33919 cm} x{2.63781 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{- (cont)}} \tn % Row 14 \SetRowColor{LightBackground} \{\{nobreak\}\}Ctrl + Alt + Mouse Wheel & Navigate to previous or next method implementation in lexical order in this source unit, or within the class to which scope has been limited using Ctrl+Q+L \tn % Row Count 8 (+ 8) % Row 15 \SetRowColor{white} Ctrl + Alt + \{\{fa-arrow-up\}\} & Navigate to previous method implementation in lexical order in this source unit, or within the class to which scope has been limited using Ctrl+Q+L \tn % Row Count 15 (+ 7) % Row 16 \SetRowColor{LightBackground} Ctrl + Alt + \{\{fa-arrow-down\}\} & Navigate to next method implementation in lexical order in this source unit, or within the class to which scope has been limited using Ctrl+Q+L \tn % Row Count 22 (+ 7) % Row 17 \SetRowColor{white} Ctrl + Alt + Home & Navigate to the lexically first method implementation in this source unit, or within the class to which scope has been limited using Ctrl+Q+L \tn % Row Count 29 (+ 7) % Row 18 \SetRowColor{LightBackground} Ctrl + Alt + End & Navigate to the lexically last method implementation in this source unit, or within the class to which scope has been limited using Ctrl+Q+L \tn % Row Count 36 (+ 7) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{2.33919 cm} x{2.63781 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{- (cont)}} \tn % Row 19 \SetRowColor{LightBackground} Ctrl + Alt + P & Activate the Tool Palette in filtering mode (start typing, press Enter to drop component) \tn % Row Count 5 (+ 5) % Row 20 \SetRowColor{white} Ctrl + Alt + A & Adds current date to source code \tn % Row Count 7 (+ 2) % Row 21 \SetRowColor{LightBackground} Ctrl + / & Toggle comment per line or selected block and cursors goes down one line, Ctrl + \# on nordic (and perhaps other international ) keyboards \tn % Row Count 14 (+ 7) % Row 22 \SetRowColor{white} Ctrl + Shift + T & Add todo list item \tn % Row Count 15 (+ 1) % Row 23 \SetRowColor{LightBackground} Alt + F12 & Toggle between Form as text mode or design mode \tn % Row Count 18 (+ 3) % Row 24 \SetRowColor{white} Alt + F11 & Invoke Use unit dialog \tn % Row Count 20 (+ 2) % Row 25 \SetRowColor{LightBackground} Ctrl + F11 & Invoke Open Project Dialog \tn % Row Count 22 (+ 2) % Row 26 \SetRowColor{white} Ctrl + Alt + F11 & Invoke Project manager window \tn % Row Count 24 (+ 2) % Row 27 \SetRowColor{LightBackground} F11 & Invoke Object Inspector window \tn % Row Count 26 (+ 2) % Row 28 \SetRowColor{white} F12 & Toggle between code view and design view \tn % Row Count 28 (+ 2) % Row 29 \SetRowColor{LightBackground} Alt + 0 & Invoke Window list \tn % Row Count 29 (+ 1) % Row 30 \SetRowColor{white} Shift + Alt + F11 & Invoke Structure window \tn % Row Count 31 (+ 2) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{2.33919 cm} x{2.63781 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{- (cont)}} \tn % Row 31 \SetRowColor{LightBackground} Ctrl + Shift + B & Invoke Browser window \tn % Row Count 1 (+ 1) % Row 32 \SetRowColor{white} Ctrl + Alt + B & Invoke Breakpoint window \tn % Row Count 3 (+ 2) % Row 33 \SetRowColor{LightBackground} Ctrl + Alt + S & Invoke Call Stack window \tn % Row Count 5 (+ 2) % Row 34 \SetRowColor{white} Ctrl + Alt + W & Invoke Watches window \tn % Row Count 6 (+ 1) % Row 35 \SetRowColor{LightBackground} Ctrl + Alt + L & Invoke Local Variables window \tn % Row Count 8 (+ 2) % Row 36 \SetRowColor{white} Ctrl + Alt + T & Invoke Threads window \tn % Row Count 9 (+ 1) % Row 37 \SetRowColor{LightBackground} Ctrl + Alt + F & Invoke FPU window \tn % Row Count 10 (+ 1) % Row 38 \SetRowColor{white} Ctrl + Alt + C & Invoke CPU window \tn % Row Count 11 (+ 1) % Row 39 \SetRowColor{LightBackground} Ctrl + Alt + V & Invoke Event window \tn % Row Count 12 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.9908 cm} x{2.9862 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{-}} \tn % Row 0 \SetRowColor{LightBackground} \{\{nobreak\}\}Shift+Click & After selecting control in form designer, click on it with Shift again to select top most parent Form \tn % Row Count 5 (+ 5) % Row 1 \SetRowColor{white} Ctrl + J & Invoke code templates also called code snippets \tn % Row Count 7 (+ 2) % Row 2 \SetRowColor{LightBackground} Ctrl + T & Delete text from cursor position until end of word \tn % Row Count 10 (+ 3) % Row 3 \SetRowColor{white} Ctrl + E & Incremental search \tn % Row Count 11 (+ 1) % Row 4 \SetRowColor{LightBackground} Ctrl + Y & Delete current line \tn % Row Count 12 (+ 1) % Row 5 \SetRowColor{white} Ctrl + B & Invoke buffer window when focus is on editor. The buffer window shows a list of all different tabs. \tn % Row Count 17 (+ 5) % Row 6 \SetRowColor{LightBackground} \{\{nobreak\}\}Ctrl + Shift + G & Insert a new GUID at the cursor position \tn % Row Count 19 (+ 2) % Row 7 \SetRowColor{white} Ctrl + Shift + I & Indent the current selected block \tn % Row Count 21 (+ 2) % Row 8 \SetRowColor{LightBackground} Ctrl + Shift + U & Unindent the current selected block \tn % Row Count 23 (+ 2) % Row 9 \SetRowColor{white} Ctrl + K + I & Indent the current selected block or current line in case of no selection \tn % Row Count 27 (+ 4) % Row 10 \SetRowColor{LightBackground} Ctrl + K + U & Unindent the current selected block or current line in case of no selection \tn % Row Count 31 (+ 4) \end{tabularx} \par\addvspace{1.3em} \vfill \columnbreak \begin{tabularx}{5.377cm}{x{1.9908 cm} x{2.9862 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{- (cont)}} \tn % Row 11 \SetRowColor{LightBackground} Ctrl + Shift + J & Invoke SyncEdit \tn % Row Count 1 (+ 1) % Row 12 \SetRowColor{white} Ctrl + Shift + V & Automatically declare variable at cursor position \tn % Row Count 4 (+ 3) % Row 13 \SetRowColor{LightBackground} Ctrl + Shift + Y & Delete to the end of line \tn % Row Count 6 (+ 2) % Row 14 \SetRowColor{white} Alt + {[} & Match pair forward \tn % Row Count 7 (+ 1) % Row 15 \SetRowColor{LightBackground} Alt + {]} & Match pair backward \tn % Row Count 8 (+ 1) % Row 16 \SetRowColor{white} Alt + \{\{fa-arrow-right\}\} & Browse forward (hotlink history) \tn % Row Count 10 (+ 2) % Row 17 \SetRowColor{LightBackground} Alt +\{\{fa-arrow-left\}\} & Browse backward (hotlink history) \tn % Row Count 12 (+ 2) % Row 18 \SetRowColor{white} Alt + \{\{fa-arrow-up\}\} & Browse to symbol under editor cursor (invoke a hotlink and add it to the hotlink history) \tn % Row Count 16 (+ 4) % Row 19 \SetRowColor{LightBackground} F4 & Run program to current cursor position \tn % Row Count 18 (+ 2) % Row 20 \SetRowColor{white} F5 & Toggle breakpoint \tn % Row Count 19 (+ 1) % Row 21 \SetRowColor{LightBackground} F7 & Debugger step into \tn % Row Count 20 (+ 1) % Row 22 \SetRowColor{white} Shift - F7 & Trace into next source line \tn % Row Count 22 (+ 2) % Row 23 \SetRowColor{LightBackground} F8 & Debugger step over \tn % Row Count 23 (+ 1) % Row 24 \SetRowColor{white} Shift - F8 & Run until return \tn % Row Count 24 (+ 1) % Row 25 \SetRowColor{LightBackground} F9 & Run program under debugger \tn % Row Count 26 (+ 2) % Row 26 \SetRowColor{white} Ctrl + F2 & Program Reset \tn % Row Count 27 (+ 1) % Row 27 \SetRowColor{LightBackground} Ctrl + F7 & Evaluate/modify \tn % Row Count 28 (+ 1) % Row 28 \SetRowColor{white} Ctrl + F5 & Add Watch \tn % Row Count 29 (+ 1) % Row 29 \SetRowColor{LightBackground} Ctrl + F12 & View units \tn % Row Count 30 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.9908 cm} x{2.9862 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{dfdfgsdfg}} \tn % Row 0 \SetRowColor{LightBackground} sdfgsdfg & sdfgsdfgsdfg \tn % Row Count 1 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.68758 cm} p{2.28942 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{mais um bloco}} \tn % Row 0 \SetRowColor{LightBackground} teste & teste \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} teste23 & teste2 \tn % Row Count 2 (+ 1) % Row 2 \SetRowColor{LightBackground} teste4 & teste3 \tn % Row Count 3 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{1.9908 cm} x{2.9862 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{dfdfgsdfg (copy)}} \tn % Row 0 \SetRowColor{LightBackground} sdfgsdfg & sdfgsdfgsdfg \tn % Row Count 1 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{5.377cm}{x{2.33919 cm} x{2.63781 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{5.377cm}}{\bf\textcolor{white}{mais um teste}} \tn % Row 0 \SetRowColor{LightBackground} tesr & wetqwer \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} ewrtwer & wertwert \tn % Row Count 2 (+ 1) % Row 2 \SetRowColor{LightBackground} sdfgsdfg & sdbfgrh \tn % Row Count 3 (+ 1) % Row 3 \SetRowColor{white} 345 & 2345 \tn % Row Count 4 (+ 1) % Row 4 \SetRowColor{LightBackground} 11111 & 111111111 \tn % Row Count 5 (+ 1) % Row 5 \SetRowColor{white} 22222 & 3333334 \tn % Row Count 6 (+ 1) % Row 6 \SetRowColor{LightBackground} 44444 & 55555 \tn % Row Count 7 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} % That's all folks \end{multicols*} \end{document}