Martin Arver | 3622c93 | 2006-03-29 18:48:52 +0000 | [diff] [blame] | 1 | \documentclass[a4paper,11pt]{scrreprt} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 2 | \usepackage[latin1]{inputenc} |
Martin Arver | 8bedb5c | 2006-03-22 23:26:30 +0000 | [diff] [blame] | 3 | \usepackage{palatino} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 4 | |
Martin Arver | ec60a05 | 2006-03-29 18:40:42 +0000 | [diff] [blame] | 5 | \usepackage{tabularx} |
Nils Wallménius | c687b30 | 2006-04-02 13:50:01 +0000 | [diff] [blame] | 6 | \usepackage{multirow} |
Dominik Riebeling | b074b22 | 2006-06-05 10:08:54 +0000 | [diff] [blame^] | 7 | \usepackage{multicol} |
Martin Arver | 0da41d8 | 2006-03-24 11:53:07 +0000 | [diff] [blame] | 8 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 9 | \usepackage{float} |
| 10 | \floatstyle{ruled} |
| 11 | |
Dominik Riebeling | c0068bb | 2006-04-08 21:00:22 +0000 | [diff] [blame] | 12 | \usepackage{hyperref} |
| 13 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 14 | \usepackage{optional} |
| 15 | |
| 16 | \input{platform/\platform.tex} |
| 17 | |
Martin Arver | 63c8bb2 | 2006-03-21 10:28:35 +0000 | [diff] [blame] | 18 | \newcommand{\playername}{\playerman\ \playertype} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 19 | |
Dominik Riebeling | c0068bb | 2006-04-08 21:00:22 +0000 | [diff] [blame] | 20 | \hypersetup{% add some values to the pdf properties |
| 21 | colorlinks = true, |
| 22 | pdfstartview = FitV, |
| 23 | linkcolor = blue, |
| 24 | citecolor = blue, |
| 25 | urlcolor = blue, |
| 26 | pdftitle = {Rockbox user manual}, |
| 27 | pdfauthor = {The Rockbox Team}, |
| 28 | pdfsubject = {Rockbox user manual for \playername} |
| 29 | } |
| 30 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 31 | \newcommand{\fname}[1]{\textbf{#1}} |
| 32 | \newcommand{\tabeltc}[1]{{\centering #1 \par}} |
| 33 | \newcommand{\tabelth}[1]{{\centering \textbf{\textit{#1}} \par}} |
| 34 | |
Martin Arver | a0cdee0 | 2006-03-31 12:25:22 +0000 | [diff] [blame] | 35 | \newcommand{\fixme}[1]{\textbf{\textcolor{red}{#1}}} |
| 36 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 37 | \usepackage{fancyhdr} |
| 38 | \usepackage{graphicx} |
| 39 | \usepackage{verbatim} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 40 | \usepackage{makeidx} |
| 41 | \usepackage{amsmath} |
| 42 | \usepackage{amssymb} |
| 43 | \usepackage{fancyvrb} |
| 44 | \usepackage{enumerate} |
| 45 | \usepackage{subfigure} |
| 46 | \usepackage{color} |
Martin Arver | a245e88 | 2006-03-08 15:04:36 +0000 | [diff] [blame] | 47 | \usepackage{booktabs} |
Martin Arver | d3d3e34 | 2006-03-15 10:56:14 +0000 | [diff] [blame] | 48 | \usepackage{longtable} |
Martin Arver | 7d6810c | 2006-03-31 11:50:33 +0000 | [diff] [blame] | 49 | \usepackage{url} |
| 50 | \urlstyle{sf} |
Martin Arver | 9be37f3 | 2006-03-31 13:29:27 +0000 | [diff] [blame] | 51 | \usepackage{marvosym} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 52 | |
Dominik Riebeling | 009aeab | 2006-04-03 21:29:47 +0000 | [diff] [blame] | 53 | % new \ifpdf to check if running in pdf mode. Helps for html generation. |
| 54 | \newif\ifpdf\ifx\pdfoutput\undefined\pdffalse\else\pdfoutput=1\pdftrue\fi |
| 55 | |
| 56 | % mark this ad draft version (only for pdflatex) -- comment this out at release |
| 57 | \ifpdf |
| 58 | \usepackage{pdfdraftcopy} |
| 59 | \draftstring{DRAFT VERSION} |
| 60 | % \draftangle{45} |
| 61 | \fi |
| 62 | |
Martin Arver | 6d5d734 | 2006-03-30 22:03:46 +0000 | [diff] [blame] | 63 | % fancy header style adjustments |
| 64 | %\renewcommand{\chaptermark}[1]{\markboth{#1}{}} |
| 65 | %\renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}} |
| 66 | \renewcommand{\rightmark}[1]{\thechapter\ } |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 67 | \fancyhead{} |
| 68 | \fancyfoot{} |
Martin Arver | 6d5d734 | 2006-03-30 22:03:46 +0000 | [diff] [blame] | 69 | \fancyhead[L]{{\textsc{\leftmark}}} |
| 70 | \fancyhead[R]{\iffloatpage{}{\thepage}} |
| 71 | \fancyfoot[L]{\textsc{Rockbox users manual}} |
| 72 | \fancyfoot[R]{\textsc{\playername}} |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 73 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 74 | \renewcommand{\headrulewidth}{\iffloatpage{0pt}{0.4pt}} |
| 75 | \renewcommand{\footrulewidth}{\iffloatpage{0pt}{0.4pt}} |
| 76 | \setlength{\headheight}{18.5pt} |
| 77 | \newcounter{example}[chapter] |
Martin Arver | 0da41d8 | 2006-03-24 11:53:07 +0000 | [diff] [blame] | 78 | |
Christi Scarborough | d68d7c0 | 2006-02-06 07:25:25 +0000 | [diff] [blame] | 79 | \newenvironment{example} |
| 80 | {\stepcounter{example}\paragraph{Example \theexample:}} |
| 81 | {\hfill$\Box$ |
| 82 | |
| 83 | \bigskip |
| 84 | \noindent} |
Martin Arver | 0da41d8 | 2006-03-24 11:53:07 +0000 | [diff] [blame] | 85 | |
Martin Arver | cbc5599 | 2006-03-30 15:54:47 +0000 | [diff] [blame] | 86 | % found on the internet, posting by Donald Arseneau |
| 87 | % I may as well include my robust expandable definions, which can be |
| 88 | % used in \edef or \write where the \def would not be executed: |
| 89 | % |
| 90 | % \if\blank --- checks if parameter is blank (Spaces count as blank) |
| 91 | % \if\given --- checks if parameter is not blank: like \if\blank{#1}\else |
| 92 | % \if\nil --- checks if parameter is null (spaces are NOT null) |
| 93 | % use \if\given{ } ... \else ... \fi etc. |
| 94 | % |
| 95 | {\catcode`\!=8 % funny catcode so ! will be a delimiter |
| 96 | \catcode`\Q=3 % funny catcode so Q will be a delimiter |
| 97 | \long\gdef\given#1{88\fi\Ifbl@nk#1QQQ\empty!} |
| 98 | \long\gdef\blank#1{88\fi\Ifbl@nk#1QQ..!}% if null or spaces |
| 99 | \long\gdef\nil#1{\IfN@Ught#1* {#1}!}% if null |
| 100 | \long\gdef\IfN@Ught#1 #2!{\blank{#2}} |
| 101 | \long\gdef\Ifbl@nk#1#2Q#3!{\ifx#3}% same as above |
| 102 | } |
| 103 | |
| 104 | % add screenshot image. |
| 105 | % Usage: \screenshot{filename}{caption}{label} |
Martin Arver | f6db368 | 2006-04-26 11:06:45 +0000 | [diff] [blame] | 106 | % By using the 'H' (HERE) placement, the screenshots are placed where |
| 107 | % we want them. |
Martin Arver | cbc5599 | 2006-03-30 15:54:47 +0000 | [diff] [blame] | 108 | % Note: use this only for screenshots! |
| 109 | % Note: leave caption empty to supress it. |
| 110 | \newcommand{\screenshot}[3]{ |
Martin Arver | f6db368 | 2006-04-26 11:06:45 +0000 | [diff] [blame] | 111 | \begin{figure}[H] |
Martin Arver | cbc5599 | 2006-03-30 15:54:47 +0000 | [diff] [blame] | 112 | \begin{center} |
Dominik Riebeling | 5be4509 | 2006-06-04 11:20:06 +0000 | [diff] [blame] | 113 | \IfFileExists{#1-\genericimg-\specimg.png} |
| 114 | {\includegraphics[width=4cm]{#1-\genericimg-\specimg.png} |
| 115 | \typeout{Note: device specific image used}} |
| 116 | {\IfFileExists{#1-\genericimg.png} |
| 117 | {\includegraphics[width=4cm]{#1-\genericimg.png}} |
| 118 | {\IfFileExists{#1} |
| 119 | {\includegraphics[width=4cm]{#1} |
| 120 | \typeout{Warning: deprecated plain image name used}}% |
| 121 | {\typeout{Missing image: #1 (\genericimg) (\specimg)}% |
| 122 | \color{red}{\textbf{WARNING!} Image not found}% |
| 123 | } |
Dominik Riebeling | 2cf5abb | 2006-04-02 17:29:44 +0000 | [diff] [blame] | 124 | } |
| 125 | } |
Dominik Riebeling | e5a2b69 | 2006-04-01 19:16:12 +0000 | [diff] [blame] | 126 | \if\blank{#3}\else{\label{#3}}\fi\if\blank{#2}\else{% |
Martin Arver | cbc5599 | 2006-03-30 15:54:47 +0000 | [diff] [blame] | 127 | \caption{#2}}\fi |
| 128 | \end{center} |
| 129 | \end{figure} |
| 130 | } |
Martin Arver | 0da41d8 | 2006-03-24 11:53:07 +0000 | [diff] [blame] | 131 | |
Martin Arver | 9be37f3 | 2006-03-31 13:29:27 +0000 | [diff] [blame] | 132 | % command to display a note. |
| 133 | % Usage: \note{text of your note} |
| 134 | % Note: do NOT use \textbf or similar to emphasize text, use \emph! |
| 135 | \newcommand{\note}[1]{ |
Dominik Riebeling | df91a9b | 2006-04-01 15:35:30 +0000 | [diff] [blame] | 136 | \ifinner\else\par\noindent\fi |
| 137 | \textbf{Note:}\ % |
| 138 | \ifinner#1\else\marginpar{\raisebox{-6pt}{\Huge\Writinghand}}#1\par\fi% |
Martin Arver | 9be37f3 | 2006-03-31 13:29:27 +0000 | [diff] [blame] | 139 | } |
| 140 | |
| 141 | % command to display a warning. |
| 142 | % Usage: \warn{text of your warning} |
| 143 | % Note: do NOT use \textbf or similar to emphasize text! |
| 144 | \newcommand{\warn}[1]{ |
Dominik Riebeling | df91a9b | 2006-04-01 15:35:30 +0000 | [diff] [blame] | 145 | \ifinner\else\par\noindent\fi |
| 146 | \textbf{Warning:\ }% |
| 147 | \ifinner#1\else\marginpar{\raisebox{-6pt}{\Huge\Stopsign}}#1\par\fi% |
| 148 | } |
| 149 | |
Martin Arver | f6db368 | 2006-04-26 11:06:45 +0000 | [diff] [blame] | 150 | % make table floats use "H" (as for screenshots) as default positioning |
| 151 | \makeatletter\renewcommand{\fps@table}{H}\makeatother |
Dominik Riebeling | 38385a5 | 2006-04-03 18:14:25 +0000 | [diff] [blame] | 152 | % change defaults for floats on a page as we have a lot of small images |
| 153 | \setcounter{topnumber}{3} % default: 2 |
| 154 | \setcounter{bottomnumber}{2} % default: 1 |
| 155 | \setcounter{totalnumber}{5} % default: 3 |
| 156 | |
Dominik Riebeling | 8c17722 | 2006-04-03 22:45:01 +0000 | [diff] [blame] | 157 | % command to set the default table heading for button lists |
| 158 | \newcommand{\btnhead}{\textbf{Key} & \textbf{Action} \\\midrule} |
| 159 | |
| 160 | % environment intended to be used with button maps |
| 161 | % usage: \begin{btnmap}{caption}{label} Button & ButtonAction \\ \end{btnmap} |
| 162 | % Note: this automatically sets the table lines. |
| 163 | % Note: you *need* to terminate the last line with a linebreak \\ |
| 164 | % Note: you still need to enclose this with \begin{table} / \end{table} |
| 165 | % Cheers for the usenet helping me building this up :) |
| 166 | \newenvironment{btnmap}[2]{% |
| 167 | \expandafter\let\expandafter\SavedEndTab\csname endtabular*\endcsname |
| 168 | \expandafter\renewcommand\expandafter*\csname endtabular*\endcsname{% |
| 169 | \bottomrule |
| 170 | \SavedEndTab% |
| 171 | \if\given{#1}\caption{#1}\fi% |
| 172 | \if\given{#2}\label{#2}\fi% |
| 173 | \endcenter% |
| 174 | } |
| 175 | \center |
| 176 | \tabularx{.75\textwidth}{lX}\toprule % here is the table width defined |
| 177 | \btnhead |
| 178 | }{% |
| 179 | \endtabularx |
| 180 | } |
| 181 | |
Dominik Riebeling | 36a3133 | 2006-04-09 21:22:42 +0000 | [diff] [blame] | 182 | % command to set the default table heading for button lists |
| 183 | \newcommand{\taghead}{\textbf{Tag} & \textbf{Description} \\\midrule} |
| 184 | |
| 185 | % environment intended to be used with tag maps (for wps) |
| 186 | % usage: \begin{tagmap}{caption}{label} Tag & Description \\ \end{btnmap} |
| 187 | % Note: this automatically sets the table lines. |
| 188 | % Note: you *need* to terminate the last line with a linebreak \\ |
| 189 | % Note: you still need to enclose this with \begin{table} / \end{table} |
| 190 | % Cheers for the usenet helping me building this up :) |
| 191 | \newenvironment{tagmap}[2]{% |
| 192 | \expandafter\let\expandafter\SavedEndTab\csname endtabular*\endcsname |
| 193 | \expandafter\renewcommand\expandafter*\csname endtabular*\endcsname{% |
| 194 | \bottomrule |
| 195 | \SavedEndTab% |
| 196 | \if\given{#1}\caption{#1}\fi% |
| 197 | \if\given{#2}\label{#2}\fi% |
| 198 | \endcenter% |
| 199 | } |
| 200 | \center |
| 201 | \tabularx{\textwidth}{lX}\toprule % here is the table width defined |
| 202 | \taghead |
| 203 | }{% |
| 204 | \endtabularx |
| 205 | } |
| 206 | |
Dominik Riebeling | 9c426e9 | 2006-04-27 18:52:16 +0000 | [diff] [blame] | 207 | \newcommand{\setting}[1]{\textsc{#1}} |
Dominik Riebeling | 36a3133 | 2006-04-09 21:22:42 +0000 | [diff] [blame] | 208 | |
Dominik Riebeling | 0f661ab | 2006-05-28 15:49:17 +0000 | [diff] [blame] | 209 | \newcommand{\config}[1]{\texttt{#1}} |
| 210 | |
| 211 | % set link to the wiki. |
| 212 | % Usage: \wikilink{WebHome} |
| 213 | % with "WebHome" being the wiki page name |
| 214 | \newcommand{\wikilink}[1]{\url{http://www.rockbox.org/twiki/bin/view/Main/#1}} |
| 215 | |