\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{Priyal kumar (pryl)} \pdfinfo{ /Title (micro-editor.pdf) /Creator (Cheatography) /Author (Priyal kumar (pryl)) /Subject (micro editor 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}{2F7A31} \definecolor{LightBackground}{HTML}{F2F6F2} \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{micro editor Cheat Sheet}}}} \\ \normalsize{by \textcolor{DarkBackground}{Priyal kumar (pryl)} via \textcolor{DarkBackground}{\uline{cheatography.com/66402/cs/16809/}}} \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}Priyal kumar (pryl) \\ \uline{cheatography.com/pryl} \\ \uline{\seqsplit{priyal-kumar}.blogspot.com/} \end{tabulary} \vfill \columnbreak \begin{tabulary}{5.8cm}{L} \SetRowColor{FootBackground} \mymulticolumn{1}{p{5.377cm}}{\bf\textcolor{white}{Cheat Sheet}} \\ \vspace{-2pt}Published 28th August, 2018.\\ Updated 28th August, 2018.\\ 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{tabularx}{17.67cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{17.67cm}}{\bf\textcolor{white}{micro editor}} \tn \SetRowColor{LightBackground} \mymulticolumn{1}{p{17.67cm}}{\vspace{1px}\centerline{\includegraphics[width=5.1cm]{/web/www.cheatography.com/public/uploads/pryl_1535470618_logo.png}}} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{17.67cm}}{\bf\textcolor{white}{micro editor}} \tn \SetRowColor{LightBackground} \mymulticolumn{1}{p{17.67cm}}{ Video: http://youtu.be/1E-XQEFWDmo} \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{17.67cm}}{\bf\textcolor{white}{Readme}} \tn \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{Official site: \seqsplit{https://micro-editor.github.io} \newline % Row Count 1 (+ 1) Installing under Windows: \newline % Row Count 2 (+ 1) scoop install micro \newline % Row Count 3 (+ 1) choco install micro \newline % Row Count 4 (+ 1) Plugins: \seqsplit{https://micro-editor.github.io/plugins.html} \newline % Row Count 6 (+ 2) Prebuilt binaries for different platforms: \newline % Row Count 7 (+ 1) \seqsplit{https://github.com/zyedidia/micro/releases}% Row Count 8 (+ 1) } \tn \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{17.67cm}}{\bf\textcolor{white}{Help}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{17.67cm}}{What is micro?} \tn \mymulticolumn{1}{x{17.67cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}It's a modern intuitive terminal text editor.} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{How to install it in mac?} \tn \mymulticolumn{1}{x{17.67cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}brew install micro} \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{17.67cm}}{How to install it in linux with snap?} \tn \mymulticolumn{1}{x{17.67cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}snap install micro -{}-classic} \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{How to install it in openBSD?} \tn \mymulticolumn{1}{x{17.67cm}}{\hspace*{6 px}\rule{2px}{6px}\hspace*{6 px}pkg\_add -v micro} \tn % Row Count 8 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{X} \SetRowColor{DarkBackground} \mymulticolumn{1}{x{17.67cm}}{\bf\textcolor{white}{Documentation}} \tn % Row 0 \SetRowColor{LightBackground} \mymulticolumn{1}{x{17.67cm}}{Main help: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/help.md}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{Keybindings: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/keybindings.md}} \tn % Row Count 4 (+ 2) % Row 2 \SetRowColor{LightBackground} \mymulticolumn{1}{x{17.67cm}}{Commands: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/commands.md}} \tn % Row Count 6 (+ 2) % Row 3 \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{Colors: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/colors.md}} \tn % Row Count 8 (+ 2) % Row 4 \SetRowColor{LightBackground} \mymulticolumn{1}{x{17.67cm}}{Options: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/options.md}} \tn % Row Count 10 (+ 2) % Row 5 \SetRowColor{white} \mymulticolumn{1}{x{17.67cm}}{Plugins: \seqsplit{https://github.com/zyedidia/micro/tree/master/runtime/help/plugins.md}} \tn % Row Count 12 (+ 2) \hhline{>{\arrayrulecolor{DarkBackground}}-} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{7.5988 cm} x{9.6712 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{17.67cm}}{\bf\textcolor{white}{Commands}} \tn % Row 0 \SetRowColor{LightBackground} quit & Quits micro \tn % Row Count 1 (+ 1) % Row 1 \SetRowColor{white} save {\emph{filename?}} & Saves the current buffer. If the filename is provided it will 'save as' the filename. \tn % Row Count 5 (+ 4) % Row 2 \SetRowColor{LightBackground} replace {\emph{"search" "value"}} flags & Replace search with value \tn % Row Count 7 (+ 2) % Row 3 \SetRowColor{white} replaceall {\emph{"search" "value"}} & This will replace search with value without user confirmation. \tn % Row Count 10 (+ 3) % Row 4 \SetRowColor{LightBackground} show option & shows the current value of the given option. \tn % Row Count 12 (+ 2) % Row 5 \SetRowColor{white} vsplit {\emph{filename}} & opens a vertical split with filename. If no filename is provided, a vertical split is opened with an empty buffer. \tn % Row Count 18 (+ 6) % Row 6 \SetRowColor{LightBackground} hsplit {\emph{filename}} & same as vsplit but opens a horizontal split instead of a vertical split. \tn % Row Count 22 (+ 4) % Row 7 \SetRowColor{white} tab {\emph{filename}} & opens the given file in a new tab. \tn % Row Count 24 (+ 2) % Row 8 \SetRowColor{LightBackground} tabswitch {\emph{tab}} & This command will switch to the specified tab. The tab can either be a tab number, or a name of a tab. \tn % Row Count 29 (+ 5) % Row 9 \SetRowColor{white} log & opens a log of all messages and debug statements. \tn % Row Count 32 (+ 3) \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{7.5988 cm} x{9.6712 cm} } \SetRowColor{DarkBackground} \mymulticolumn{2}{x{17.67cm}}{\bf\textcolor{white}{Commands (cont)}} \tn % Row 10 \SetRowColor{LightBackground} plugin install {\emph{pluginName}} & installs the given plugin. \tn % Row Count 2 (+ 2) % Row 11 \SetRowColor{white} plugin remove {\emph{pluginName}} & removes te given plugin \tn % Row Count 4 (+ 2) % Row 12 \SetRowColor{LightBackground} plugin list & lists all installed plugins. \tn % Row Count 6 (+ 2) % Row 13 \SetRowColor{white} plugin update & updates all installed plugins. \tn % Row Count 8 (+ 2) % Row 14 \SetRowColor{LightBackground} plugin available & list plugins available for download (this includes any plugins that may be already installed). \tn % Row Count 13 (+ 5) % Row 15 \SetRowColor{white} plugin search {\emph{pluginName}} & searches for the given plugin. Note that you can find a list of all available plugins at \seqsplit{github.com/micro-editor/plugin-channel.} \tn % Row Count 19 (+ 6) % Row 16 \SetRowColor{LightBackground} reload & reloads all runtime files. \tn % Row Count 21 (+ 2) % Row 17 \SetRowColor{white} retab & Replaces all leading tabs with spaces or leading spaces with tabs depending on the value of tabstospaces. \tn % Row Count 26 (+ 5) \hhline{>{\arrayrulecolor{DarkBackground}}--} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{2.5305 cm} x{7.0854 cm} x{7.2541 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{17.67cm}}{\bf\textcolor{white}{Options}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{Options}} & {\bf{Default Value}} & {\bf{Description}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \seqsplit{autoclose} & true & automatically close \{\} () {[}{]} "" ''. Provided by the autoclose plugin \tn % Row Count 6 (+ 4) % Row 2 \SetRowColor{LightBackground} \seqsplit{autoindent} & true & when creating a new line use the same indentation as the previous line. \tn % Row Count 11 (+ 5) % Row 3 \SetRowColor{white} \seqsplit{autosave} & false & micro will save the buffer every 8 seconds automatically. Micro also will automatically save and quit when you exit without asking. \tn % Row Count 19 (+ 8) % Row 4 \SetRowColor{LightBackground} \seqsplit{basename} & false & in the infobar, show only the basename of the file being edited rather than the full path. \tn % Row Count 25 (+ 6) % Row 5 \SetRowColor{white} \seqsplit{colorscheme} & default & loads the colorscheme stored in \seqsplit{\$(configDir)/colorschemes/option}.micro, This setting is global only. \tn % Row Count 31 (+ 6) \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{2.5305 cm} x{7.0854 cm} x{7.2541 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{17.67cm}}{\bf\textcolor{white}{Options (cont)}} \tn % Row 6 \SetRowColor{LightBackground} \seqsplit{cursorline} & true & highlight the line that the cursor is on in a different color (the color is defined by the colorscheme you are using). \tn % Row Count 7 (+ 7) % Row 7 \SetRowColor{white} \seqsplit{eofnewline} & false & micro will automatically add a newline to the file. \tn % Row Count 10 (+ 3) % Row 8 \SetRowColor{LightBackground} \seqsplit{fileformat} & unix & this determines what kind of line endings micro will use for the file. UNIX line endings are just \textbackslash{}n (lf) whereas dos line endings are \textbackslash{}r\textbackslash{}n (crlf). The two possible values for this option are unix and dos. \tn % Row Count 23 (+ 13) % Row 9 \SetRowColor{white} \seqsplit{ignorecase} & false & perform case-insensitive searches. \tn % Row Count 25 (+ 2) % Row 10 \SetRowColor{LightBackground} \seqsplit{indentchar} & & sets the indentation character. \tn % Row Count 27 (+ 2) % Row 11 \SetRowColor{white} \seqsplit{infobar} & true & enables the line at the bottom of the editor where messages are printed. This option is global only. \tn % Row Count 33 (+ 6) \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{2.5305 cm} x{7.0854 cm} x{7.2541 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{17.67cm}}{\bf\textcolor{white}{Options (cont)}} \tn % Row 12 \SetRowColor{LightBackground} \seqsplit{linter} & true & Automatically lint when the file is saved. Provided by the linter plugin. \tn % Row Count 5 (+ 5) % Row 13 \SetRowColor{white} \seqsplit{keymenu} & false & display the nano-style key menu at the bottom of the screen. \tn % Row Count 9 (+ 4) % Row 14 \SetRowColor{LightBackground} mouse & true & whether to enable mouse support \tn % Row Count 11 (+ 2) % Row 15 \SetRowColor{white} \seqsplit{pluginchannels} & \seqsplit{https://github.com/micro-editor/plugin-channel} & contains all the channels micro's plugin manager will search for plugins in. \tn % Row Count 16 (+ 5) % Row 16 \SetRowColor{LightBackground} \seqsplit{rmtrailingws} & false & micro will automatically trim trailing whitespaces at eol. \tn % Row Count 20 (+ 4) % Row 17 \SetRowColor{white} ruler & true & display line numbers. \tn % Row Count 22 (+ 2) % Row 18 \SetRowColor{LightBackground} \seqsplit{savecursor} & false & remember where the cursor was last time the file was opened and put it there when you open the file again. \tn % Row Count 29 (+ 7) % Row 19 \SetRowColor{white} \seqsplit{savehistory} & true & remember command history between closing and re-opening micro. \tn % Row Count 33 (+ 4) \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{2.5305 cm} x{7.0854 cm} x{7.2541 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{17.67cm}}{\bf\textcolor{white}{Options (cont)}} \tn % Row 20 \SetRowColor{LightBackground} \seqsplit{saveundo} & false & when this option is on, undo is saved even after you close a file so if you close and reopen a file, you can keep undoing. \tn % Row Count 8 (+ 8) % Row 21 \SetRowColor{white} \seqsplit{scrollbar} & false & display a scroll bar \tn % Row Count 10 (+ 2) % Row 22 \SetRowColor{LightBackground} \seqsplit{smartpaste} & true & should micro add leading whitespace when pasting multiple lines? This will attempt to preserve the current indentation level when pasting an unindented block. \tn % Row Count 20 (+ 10) % Row 23 \SetRowColor{white} \seqsplit{softwrap} & false & should micro wrap lines that are too long to fit on the screen. \tn % Row Count 24 (+ 4) % Row 24 \SetRowColor{LightBackground} \seqsplit{statusline} & true & display the status line at the bottom of the screen. \tn % Row Count 28 (+ 4) % Row 25 \SetRowColor{white} \seqsplit{matchbrace} & false & highlight matching braces for '()', '\{\}', '{[}{]}' \tn % Row Count 31 (+ 3) \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{2.5305 cm} x{7.0854 cm} x{7.2541 cm} } \SetRowColor{DarkBackground} \mymulticolumn{3}{x{17.67cm}}{\bf\textcolor{white}{Options (cont)}} \tn % Row 26 \SetRowColor{LightBackground} \seqsplit{syntax} & true & turns syntax on or off. \tn % Row Count 2 (+ 2) % Row 27 \SetRowColor{white} \seqsplit{tabsize} & 4 & sets the tab size to option \tn % Row Count 4 (+ 2) % Row 28 \SetRowColor{LightBackground} \seqsplit{tabstospaces} & false & use spaces instead of tabs \tn % Row Count 6 (+ 2) % Row 29 \SetRowColor{white} \seqsplit{termtitle} & false & defines whether or not your terminal's title will be set by micro when opened. \tn % Row Count 11 (+ 5) \hhline{>{\arrayrulecolor{DarkBackground}}---} \end{tabularx} \par\addvspace{1.3em} \begin{tabularx}{17.67cm}{x{3.9528 cm} x{4.6116 cm} x{3.9528 cm} x{3.9528 cm} } \SetRowColor{DarkBackground} \mymulticolumn{4}{x{17.67cm}}{\bf\textcolor{white}{Keybindings}} \tn % Row 0 \SetRowColor{LightBackground} {\bf{Bindings}} & {\bf{Command}} & {\bf{Bindings}} & {\bf{Command}} \tn % Row Count 2 (+ 2) % Row 1 \SetRowColor{white} \textasciicircum{}Q & Quit & F4, F10 & Quit \tn % Row Count 3 (+ 1) % Row 2 \SetRowColor{LightBackground} \textasciicircum{}G & toggle Help & F1 & toggle Help \tn % Row Count 5 (+ 2) % Row 3 \SetRowColor{white} \textasciicircum{}S & Save & F2 & Save \tn % Row Count 6 (+ 1) % Row 4 \SetRowColor{LightBackground} \textasciicircum{}Z & Undo & \textasciicircum{}Y & Redo \tn % Row Count 7 (+ 1) % Row 5 \SetRowColor{white} \textasciicircum{}F & Find & F3, F7 & Find \tn % Row Count 8 (+ 1) % Row 6 \SetRowColor{LightBackground} \textasciicircum{}N & FindNext & \textasciicircum{}P & \seqsplit{FindPrevious} \tn % Row Count 10 (+ 2) % Row 7 \SetRowColor{white} \seqsplit{MouseWheelUp} & ScrollUp & \seqsplit{MouseWheelDn} & \seqsplit{ScrollDown} \tn % Row Count 12 (+ 2) % Row 8 \SetRowColor{LightBackground} Esc & Escape & \seqsplit{MouseMiddle} & \seqsplit{PastePrimary} \tn % Row Count 14 (+ 2) % Row 9 \SetRowColor{white} Alt-a & Start of line & Alt-e & End of line \tn % Row Count 16 (+ 2) % Row 10 \SetRowColor{LightBackground} Alt-f & WordRight & Alt-b & WordLeft \tn % Row Count 17 (+ 1) \hhline{>{\arrayrulecolor{DarkBackground}}----} \end{tabularx} \par\addvspace{1.3em} \end{document}