From 95eb1f22c560ec9fc1a344154f1d2d0426b22e8d Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Fri, 23 Jul 2010 21:38:42 +0200 Subject: [PATCH] docs: add reference card (by Zeus Panchenko) --- docs/Makefile | 5 ++- docs/refcard.tex | 107 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 docs/refcard.tex diff --git a/docs/Makefile b/docs/Makefile index 79e5019a..379f07d1 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -1,5 +1,5 @@ -all: hacking-howto.html debugging.html userguide.html ipc.html multi-monitor.html wsbar.html +all: hacking-howto.html debugging.html userguide.html ipc.html multi-monitor.html wsbar.html refcard.pdf hacking-howto.html: hacking-howto asciidoc -a toc -n $< @@ -19,6 +19,9 @@ multi-monitor.html: multi-monitor wsbar.html: wsbar asciidoc -a toc -n $< +refcard.pdf: refcard.tex + pdflatex refcard.tex && pdflatex refcard.tex + clean: rm -f */*.{aux,log,toc,bm,pdf,dvi} rm -f *.log *.html diff --git a/docs/refcard.tex b/docs/refcard.tex new file mode 100644 index 00000000..c945db5e --- /dev/null +++ b/docs/refcard.tex @@ -0,0 +1,107 @@ +\documentclass[10pt,a4,landscape]{article} + +% \usepackage[cam,a4,center,info,]{crop} % frame +\usepackage[height=20cm,width=25.7cm,noheadfoot,landscape]{geometry} % A4 - 210×297 mm + +\usepackage[T1]{fontenc} +\usepackage{multicol} +\usepackage{color} +\usepackage{url} +\usepackage{lastpage} + +\usepackage{hyperref} +\hypersetup{ + pdftitle={i3 Reference Card}, + pdfauthor={\textcopyright\ Zeus Panchenko}, + pdfkeywords={i3, refcard}, + pdfsubject={based on http://i3.zekjur.net/docs/userguide.html}, + pdfpagemode={FullScreen}} + +\definecolor{lightgray}{gray}{0.7} + +\pagestyle{empty} + +\setlength{\parindent}{0in} +\setlength{\columnseprule}{0.5pt} +\setlength{\columnsep}{20pt} + +\newcommand{\RefCardTitle}[2] +{\centering{\Large{\textbf{i3 Reference Card (#1/#2)\\ + {\scriptsize{\url{http://i3.zekjur.net/docs/userguide.html}}}}}} + \vspace{1mm}} + + +\newcommand{\RefCardSec}[1] {\vspace{2mm} \raggedright {\vspace{0.5mm} + \colorbox{lightgray} {\makebox[0.31\textwidth][l] + {\Large{\textsc{\textsf{\textbf{\color{black}#1}}}}}} + \vspace{0.5mm}}} + +\newcommand{\RefCardRow}[2] {\normalsize{\textbf{\texttt{#1}}} + \hspace{\stretch{1}} \raggedleft{\small{\textnormal{#2}}} \\} + +\begin{document} + +\centering + +\begin{multicols}{3} + \RefCardTitle{\thepage}{\pageref{LastPage}} + + \RefCardSec{Moving around} + + \RefCardRow{Mod1+Enter}{open new terminal} + \RefCardRow{Mod1+j}{focus (left)} + \RefCardRow{Mod1+k}{focus (down)} + \RefCardRow{Mod1+l}{focus (up)} + \RefCardRow{Mod1+;}{focus (right)} + \RefCardRow{Mod1+Shift+j}{move window (left)} + \RefCardRow{Mod1+Shift+k}{move window (down)} + \RefCardRow{Mod1+Shift+l}{move window (up)} + \RefCardRow{Mod1+Shift+;}{move window (right)} + \RefCardRow{Mod1+Control+j}{snap (left)} + \RefCardRow{Mod1+Control+k}{snap (down)} + \RefCardRow{Mod1+Control+l}{snap (up)} + \RefCardRow{Mod1+Control+;}{snap (right)} + \RefCardRow{Mod1+Shift+q}{kill a window} + \RefCardRow{Mod1+Shift+}{move a window to another workspace} + + + \RefCardSec{Changing container modes} + + \RefCardRow{Mod1+e}{default} + \RefCardRow{Mod1+h}{stacking} + \RefCardRow{Mod1+w}{tabbed} + \RefCardRow{Mod1+Shift+f}{global fullscreen} + \RefCardRow{Mod1+f}{toggle fullscreen} + \RefCardRow{Mod1+Shift+Space}{toggle floating} + \RefCardRow{Mod1+}{drag floating} + + \RefCardSec{Opening other applications} + + \RefCardRow{Mod1+v}{open application launcher (dmenu)} + + \RefCardSec{Using workspaces} + + \RefCardRow{Mod1+}{switch to another workspace} + + \RefCardSec{Restarting i3 inplace} + + \RefCardRow{Mod1+Shift+r}{restart i3 inplace} + + \RefCardSec{Exiting i3} + + \RefCardRow{Mod1+Shift+e}{exit i3} + + \vspace{1cm} + \tiny{ + \begin{center} + Copyright \copyright 2009, Michael Stapelberg \\ + All rights reserved. \\ + Designed by Zeus Panchenko + \end{center} + Permission is granted to copy, distribute and/or modify this + document provided the copyright notice and this permission + notice are preserved on all copies.} + +\end{multicols} + +\end{document}