1 \documentclass[12pt,letterpaper,twoside]{memoir}
2 % for debugging, add 'draft' (without quotes) to the [] document class list.
3 % If draft is in the document class list, pix are just suggested
4 % by an outline, the pic does not appear as a picture.
6 \usepackage{url} % For color in letters. Links instead?
7 \usepackage{color} % For color in letters. Links instead?
8 \usepackage{ellipsis} % Provides ... as \dots
13 language={}, % choose the language of the code
14 basicstyle=\footnotesize, % the size of the fonts that are used for the code
15 numbers=left, % where to put the line-numbers
16 numberstyle=\footnotesize, % the size of the fonts that are used for the line-numbers
18 firstnumber=1, % first line number in each listing
19 stepnumber=5, % the step between two line-numbers. If it is 1 each line will be numbered
20 numbersep=10pt, % how far the line-numbers are from the code
21 backgroundcolor=\color{white}, % choose the background color. You must add \usepackage{color}
22 showspaces=false, % show spaces adding particular underscores
23 showstringspaces=false, % underline spaces within strings
24 showtabs=false, % show tabs within strings adding particular underscores
25 frame=single, % adds a frame around the code
26 tabsize=2, % sets default tabsize to 2 spaces
27 captionpos=b, % sets the caption-position to bottom
28 breaklines=true, % sets automatic line breaking
29 breakatwhitespace=false, % sets if automatic breaks should only happen at whitespace
30 escapeinside={\%*}{*)} % if you want to add a comment within your code
33 \usepackage{amsmath} % Provides \nobreakdash
34 \usepackage{graphicx} % For pictures
35 \usepackage{longtable} % For multipage tables
36 \usepackage{varioref} % defines \vref
37 % \textregistered is the trademark symbol
38 \usepackage[headheight=16pt,paper=letterpaper]{geometry}
39 \setlength{\headheight}{15pt} % avoids warning from latex
40 \usepackage{ifthen} % For conditional processing
41 \usepackage{changepage} % For odd/even page checks
42 \usepackage{epic} % For eepic package
43 \usepackage{eepic} % For the diagram of section relationships
44 \usepackage{makeidx} % For making an index
45 % hyperref must be the last package listed.
46 % The hyperref settings helps hypertext get right links in the
48 \usepackage[plainpages=false,pdfpagelabels,pagebackref]{hyperref} % Lets us generate colored active links inside a pdf.
49 \makeindex % This and the makeidx package allow \index to create index entries.
51 \newcommand{\docdate}{28 January 2013}
53 \newcommand{\dwf}{DWARF Debugging Information Format}
54 \newenvironment{myindentpara}[1]%
56 {\setlength{\leftmargin}{#1}}%
62 %\newcommand{\myindent1}[1]{\begin{myindentpara}{1cm}#1\end{myindentpara}}
64 \hypersetup{colorlinks=true,
66 pdfauthor={\dwf\ Committee},
67 pdftitle={\dwf\ Version 4.1}
70 % An environment to create a listing-like (boxed) presentation for DWARF examples
71 % Use like \begin{lstlisting}...\end{lstlisting}. Does not do line numbers (boo)
72 % but does full LaTex processing within its scope (unlike \verb).
74 \newenvironment{dwflisting}{\begin{lrbox}{\savedwf}
75 \begin{minipage}{\textwidth}\footnotesize}
76 {\end{minipage}\end{lrbox}\fbox{\usebox{\savedwf}}}
77 % A helper to annotate the parts of a multipage figure
78 \newcommand{\figurepart}[2]{\raggedleft{\textit{\tiny{part #1 of #2}}}}
80 % Generate a page ref.
81 % use like \refersec{chap:registerbasedaddressing}
82 %\newcommand{\refersec}[1]{\ref{#1} on page \pageref{#1}}
83 \newcommand{\refersec}[1]{\vref{#1}} % beware possible rerun loop
84 \newcommand{\referfol}[1]{\ref{#1} following}
86 % Generate a live link in the document
87 % use like \livelink{chap:DWOPdup}{DW\-\_OP\-\_dup}
88 \newcommand{\livelink}[2]{\hyperlink{#1}{#2}\index{#2}}
89 % use when the index is different from the text and target.
90 \newcommand{\livelinki}[3]{\hyperlink{#1}{#2}\index{#3}}
91 % livetarg is the declaration this is the target of livelinks.
92 % FIXME: we might want livetarg and livetargi #2 to be \textbf{#2}
93 \newcommand{\livetarg}[2]{\hypertarget{#1}{#2}\index{#2}}
94 % When we want the index entry to look different from the name.
95 \newcommand{\livetargi}[3]{\hypertarget{#1}{#2}\index{#3}}
97 \newcommand{\dash}{\nobreakdash-\hspace{0pt}} % So we handle dashes ok.
99 % The following two let us mark a word as 'do not link' or
100 % 'do not index' to indicate the word is used generically
101 % and has been considered so do not index or link it.
102 % There is no significant difference in the two commands, though
103 % \nolink would be more oriented to words such as flag or address
104 % that might be linked (and indexed) in some circumstances.
105 \newcommand{\nolink}[1]{#1}
106 \newcommand{\noindex}[1]{#1}
109 \newcommand{\addtoindex}[1]{#1\index{#1}}
110 \newcommand{\addtoindexi}[2]{#1\index{#2}}
111 \newcommand{\addtoindexx}[1]{\index{#1}}
113 % Quote commands that avoid need for inline UTF-8 in these sources
114 \newcommand{\doublequote}[1]{\textquotedblleft #1\textquotedblright}
115 \newcommand{\singlequote}[1]{\textquoteleft #1\textquoteright}
117 % Better naming for the lowest level section header
118 \newcommand{\subsubsubsection}[1]{\paragraph{#1}}
120 % Reduce vertical space at beginning of a list
121 \setlength{\topsep}{0in}
123 \newcommand{\emptypage}{
126 \begin{center} \textit{(empty page)} \end{center}
129 % A simple rule used in simple tables; default length is 2 inches
130 \newcommand{\simplerule}[1][2in]{\rule[4pt]{#1}{1pt}}
132 % A simple one column table of names; default width is 2 inches
133 \newcommand{\simplenametablerule}{\simplerule[2in]}
134 \newenvironment{simplenametable}[3][2in]
135 { \begin{table}[H] \caption{#2} \label{#3}
137 \renewcommand{\simplenametablerule}{\simplerule[#1]}
138 \simplenametablerule \\
140 \simplenametablerule \\
142 { \simplenametablerule \\
147 %--- Begin the document pages
151 \thispagestyle{empty}
154 \setlength{\parindent}{0pt}
155 \setlength{\headheight}{6cm}
156 \setlength{\uppermargin}{6cm}
165 \includegraphics[keepaspectratio=true,scale=1.0]{DWlogo}
169 \href{http://www.dwarfstd.org}{\dwf\ Committee}
171 \url{http://www.dwarfstd.org}
184 \setlength{\headheight}{15pt}
187 \makeevenhead{plain}{}{}{}
188 \makeoddhead{plain}{}{}{}
189 \makeevenfoot{plain}{}{}{}
190 \makeoddfoot{plain}{}{}{}
193 \setlength{\parindent}{0pt}
194 \settrims{0.5in}{0.5in}
195 \settypeblocksize{8.2in}{6.0in}
196 %\setlrmarginsandblock{0.6in}{0.6in}{*}
197 %\setheadfoot{15pt}{15pt}
198 %\setheaderspaces {*}{2\onelineskip}{*}
200 \makeevenhead{plain}{}{\rightmark}{}
201 \makeoddhead{plain}{}{\rightmark}{}
202 \makeevenfoot{plain}{\docdate}{}{Page \thepage}
203 \makeoddfoot{plain}{\docdate}{}{Page \thepage}
208 \setlength{\parindent}{0pt}
213 \include{foreword4.1}
226 \chapterstyle{section}
228 \setlength{\parindent}{0pt}
230 \makepagestyle{fragFirstChPage}
231 \makeevenhead{fragFirstChPage}{}{}{}
232 \makeoddhead{fragFirstChPage}{}{}{}
233 \makeoddfoot{fragFirstChPage}{\docdate}{}{Page \thepage}
234 \makeevenfoot{fragFirstChPage}{\docdate}{}{Page \thepage}
236 \aliaspagestyle{chapter}{fragFirstChPage}
238 % ----- Start the main part of the document -----
240 % Define the levels of sectionality that are numbered.
241 \setcounter{secnumdepth}{5}
242 \include{introduction}
243 \include{generaldescription} \emptypage
244 \include{programscope}
245 \include{dataobject} \emptypage
246 \include{typeentries} \emptypage
247 \include{otherdebugginginformation}
248 \include{datarepresentation} \emptypage
249 % The \appendix toggles us into appendix chapters
251 \include{attributesbytag}
252 \include{debugsectionrelationships}
253 \include{encodingdecoding} \emptypage
255 \include{compression}
256 \include{sectionversionnumbers}