2 %% Provides macros and other stuff for the bacula manual
4 %% Original Creation -- K. Cunningham 2005-01-09
8 %% New Commands Currently implemented:
10 %% \elink{target}{text}
11 %% Inserts the text indicated (highlighted) and provides
12 %% an external hyperlink to the target.
15 %% \ilink{target}{text}
16 %% Inserts the text indicated (highlighted) and provides
17 %% an internal hyperlink to the target. Target must be a
18 %% \label somewhere in the same document.
21 %% Inserts a less-than character (<).
24 %% Inserts a greater-than character (>).
27 %% Inserts the path to the images
31 \ProvidesPackage{bacula}[2008/10/03]
32 \usepackage{ltxtable,varioref}
33 \usepackage{babel,xr-hyper}
35 \input{external-references}
39 \newcolumntype{Y}{>{\centering\arraybackslash}X}
40 %% LaTeX GraphicPath directive is able to manage this.
41 %% manuals/_lang_/_manual_name/
42 \graphicspath{{../../../images/pdf/}{../../../images/png/}{../../../images/jpeg/}{../../../images/}{../../../images/eps/}{../../../images/hires/}}
43 %% In tex files: do _not_ put the filename extension
44 %% Below, define the precedence for filetypes
45 \include{graphicspolicy}
46 %% Some definition for external references.
47 \def\mbacula{Bacula Community}
48 \def\miscman{\mbacula{} Misc Manual}
49 \def\consoleman{\mbacula{} Console Manual}
50 \def\mainman{\mbacula{} Main Manual}
51 \def\devman{\mbacula{} Developers Manual}
52 \def\utilityman{\mbacula{} Utility programs}
53 \def\problemsman{\mbacula{} Problem Resolution Guide}
55 %% eXternal References macro: borgxrlink
56 %%% #1: Text to display
58 %%% #3: manual: main, console, misc, developers
59 %%% #4: text as reference level. will be displayed ``as is''
62 %%% \borgxrlink{Console Configuration}{ConsoleConfChapter}{main}{chapter}
64 %%% Console Configuration chapter (chapter 30 on page 269)
65 \newcommand*{\borgxrlink}[4]{%
66 \href{../#3/#3}{\textbf{#1}} #4 (#4 \vref{#3-#2})
69 %% Same for pointing to document.
70 %% \borgxrlinkdocument{Text}{label}{manual}{type-of-reference}
72 %% Text (chapter XX on page YY)
73 \newcommand*{\borgxrlinkdocument}[4]{%
74 \href{../#3/#3}{\textbf{#1}} (#4 \vref{#3-#2})
78 \def\arraystretch{1.5}
83 %%% Include a graphic, horizontally
85 %%% #1: image filename, witout extension
88 %%% A label is automatically added. The name
89 %%% bsysimg-image_filename
90 \newcommand*{\bsysimageN}[3]{
94 \caption{#2}\ifthenelse{\equal{#3}{}}{\label{bsysimg-#1}}{\label{#3}}
98 \newcommand*{\bsysimageH}[3]{
101 \includegraphics[width=0.95\linewidth]{#1}
102 \caption{#2}\ifthenelse{\equal{#3}{}}{\label{bsysimg-#1}}{\label{#3}}
107 %%% Include a graphic, vertically
109 %%% #1: image filename, witout extension
112 %%% A label is automatically added. The name
113 %%% bsysimg-image_filename
114 \newcommand*{\bsysimageV}[3]{
117 \includegraphics[height=0.95\linewidth]{#1}
118 \caption{#2}\ifthenelse{\equal{#3}{}}{\label{bsysimg-#1}}{\label{#3}}
129 \newcommand*{\elink}[2]{%
130 %\htmladdnormallink{#1}{#2}%
134 \newcommand*{\ilink}[2]{%
135 \htmlref{\textcolor{black}{#1}}{#2}%
136 % #1 (cf. \vref{#2})%\htmlref{#1}{#2}%
138 \newcommand*{\borgref}[1]{%
139 %% displays 'the_reference on page p'
143 \newcommand{\dq}{\verb+"+}
144 \newcommand{\vb}{$|$}
145 \newcommand{\lt}{$<$}
146 \newcommand{\gt}{$>$}
148 %% copied from /usr/share/texmf/tex/latex/base/book.cls, and
149 %% modified to suit. KEC 4-28-05
150 %% KEC: Removed the two-column arrangement, and added \newpage
151 \renewenvironment{theindex}
157 %% KEC: Switch to one column.
158 %% \columnseprule \z@
160 %% \twocolumn[\@makeschapterhead{\indexname}]%
161 \@mkboth{\MakeUppercase\indexname}%
162 {\MakeUppercase\indexname}%
164 \subsection*{\indexname}
165 \addcontentsline{toc}{subsection}{\indexname}
166 \thispagestyle{plain}\parindent\z@
167 \parskip\z@ \@plus .3\p@\relax
169 {\if@restonecol\onecolumn\else\clearpage\fi} %% Is this needed???