2
0

fpc-html.tex 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144
  1. %
  2. % $Id$
  3. %
  4. % This file is part of the FPC documentation.
  5. % Copyright (C) 1997, by Michael Van Canneyt
  6. %
  7. % The FPC documentation is free text; you can redistribute it and/or
  8. % modify it under the terms of the GNU Library General Public License as
  9. % published by the Free Software Foundation; either version 2 of the
  10. % License, or (at your option) any later version.
  11. %
  12. % The FPC Documentation is distributed in the hope that it will be useful,
  13. % but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  15. % Library General Public License for more details.
  16. %
  17. % You should have received a copy of the GNU Library General Public
  18. % License along with the FPC documentation; see the file COPYING.LIB. If not,
  19. % write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  20. % Boston, MA 02111-1307, USA.
  21. \usepackage{ifthen}
  22. \usepackage{xspace}
  23. \usepackage{multicol}
  24. %
  25. % FPC environments
  26. %
  27. % List
  28. \newenvironment{FPCList}{\begin{htmllist}}{\end{htmllist}}
  29. % For Tables.
  30. \newenvironment{FPCtable}[2]{\begin{table}\caption{#2}\begin{center}\begin{tabular}{#1}}{\end{tabular}\end{center}\end{table}}
  31. % The same, but with label in third argument (tab:#3)
  32. \newenvironment{FPCltable}[3]{\begin{table}\caption{#2}\label{tab:#3}\begin{center}\begin{tabular}{#1}}{\end{tabular}\end{center}\end{table}}
  33. %
  34. % Picture including with breaks before and after
  35. %
  36. \newcommand{\fpcaddimg}[1]{\htmlclear\htmlclear\htmladdimg{#1}\htmlclear\htmlclear}
  37. %
  38. % Html Refs
  39. %
  40. \newcommand{\seefl}[2]{\htmlref{#1}{fu:#2}}
  41. \newcommand{\seepl}[2]{\htmlref{#1}{pro:#2}}
  42. \newcommand{\seetyl}[1]{\htmlref{#1}{sec:types}}
  43. \newcommand{\seec}[1]{chapter \htmlref{#1}{ch:#1}}
  44. \newcommand{\sees}[1]{section \htmlref{#1}{se:#1}}
  45. \newcommand{\seeo}[1]{See \htmlref{#1}{option:#1}}
  46. \newcommand{\seet}[1]{table (\htmlref{#1}{tab:#1}) }
  47. %
  48. % Function list
  49. %
  50. \newenvironment{funclist}{\begin{list}}{\end{list}}
  51. \newcommand{\funcrefl}[3]{\item[\htmlref{#2}{fu:#2} #3]}
  52. \newcommand{\funcref}[2]{\item[\htmlref{#1}{fu:#1} #2]}
  53. \newcommand{\procrefl}[3]{\item[\htmlref{#2}{pro:#2} #3]}
  54. \newcommand{\procref}[2]{\item[\htmlref{#1}{pro:#1} #2]}
  55. %
  56. % Function/procedure environments
  57. %
  58. \newenvironment{functionl}[2]{\subsection{#1}\index{#1}\label{fu:#2}\begin{FPCList}}{\end{FPCList}}
  59. \newenvironment{procedurel}[2]{\subsection{#1}\index{#1}\label{pro:#2}\begin{FPCList}}{\end{FPCList}}
  60. \newenvironment{function}[1]{\begin{functionl}{#1}{#1}}{\end{functionl}}
  61. \newenvironment{procedure}[1]{\begin{procedurel}{#1}{#1}}{\end{procedurel}}
  62. \newenvironment{typel}[2]{\subsection{#1}\index{#1}\label{ty:#2}\begin{FPCList}}{\end{FPCList}}
  63. \newenvironment{type}[1]{\begin{typel}{#1}{#1}}{\end{typel}}
  64. \newcommand{\Declaration}{\item[Declaration]\ttfamily}
  65. \newcommand{\Description}{\item[Description]\rmfamily}
  66. \newcommand{\Errors}{\item[Errors]\rmfamily}
  67. \newcommand{\SeeAlso}{\item[See also]\rmfamily}
  68. %
  69. % Ref without labels
  70. %
  71. \newcommand{\seef}[1]{\seefl{#1}{#1}}
  72. \newcommand{\seep}[1]{\seepl{#1}{#1}}
  73. \newcommand{\seety}[1]{\seetyl{#1}{#1}}
  74. %
  75. % man page references don't need labels.
  76. %
  77. \newcommand{\seem}[2]{\texttt{#1} (#2) }
  78. %
  79. % for easy typesetting of variables.
  80. %
  81. \newcommand{\var}[1]{\texttt {#1}}
  82. \newcommand{\file}[1]{\textsf {#1}}
  83. %
  84. % Useful references.
  85. %
  86. \newcommand{\progref}{\htmladdnormallink{Programmers' guide}{../prog/prog.html}\xspace}
  87. \newcommand{\refref}{\htmladdnormallink{Reference guide}{../ref/ref.html}\xspace}
  88. \newcommand{\userref}{\htmladdnormallink{Users' guide}{../user/user.html}\xspace}
  89. \newcommand{\unitsref}{\htmladdnormallink{Unit reference}{../units/units.html}\xspace}
  90. \newcommand{\seecrt}{\htmladdnormallink{CRT}{../crt/crt.html}\xspace}
  91. \newcommand{\seelinux}{\htmladdnormallink{Linux}{../linux/linux.html}\xspace}
  92. \newcommand{\seestrings}{\htmladdnormallink{strings}{../strings/strings.html}\xspace}
  93. \newcommand{\seedos}{\htmladdnormallink{DOS}{../dos/dos.html}\xspace}
  94. \newcommand{\seegetopts}{\htmladdnormallink{getopts}{../getopts/getopts.html}\xspace}
  95. \newcommand{\seeobjects}{\htmladdnormallink{objects}{../objects/objects.html}\xspace}
  96. \newcommand{\seegraph}{\htmladdnormallink{graph}{../graph/graph.html}\xspace}
  97. \newcommand{\seeprinter}{\htmladdnormallink{printer}{../printer/printer.html}\xspace}
  98. \newcommand{\seego}{\htmladdnormallink{GO32}{../go32/go32.html}\xspace}
  99. %
  100. % Commands to reference these things.
  101. %
  102. \newenvironment{remark}{\par\makebox[0pt][r]{\bfseries{}Remark:\hspace{.25em}}}{\par}
  103. \newcommand{\olabel}[1]{\label{option:#1}}
  104. %
  105. % some OSes
  106. %
  107. \newcommand{\linux}{\textsc{linux}\xspace}
  108. \newcommand{\unix}{\textsc{unix}\xspace}
  109. \newcommand{\dos} {\textsc{dos}\xspace}
  110. \newcommand{\msdos}{\textsc{ms-dos}\xspace}
  111. \newcommand{\ostwo}{\textsc{os/2}\xspace}
  112. \newcommand{\windows}{\textsc{Windows}\xspace}
  113. \newcommand{\windowsnt}{\textsc{Windows NT}\xspace}
  114. \newcommand{\fpc}{Free Pascal\xspace}
  115. \newcommand{\gnu}{\textsc{gnu}\xspace}
  116. \newcommand{\atari}{\textsc{Atari}\xspace}
  117. \newcommand{\amiga}{\textsc{Amiga}\xspace}
  118. \newcommand{\win}{\textsc{Win32}\xspace}
  119. \newcommand{\freebsd}{\textsc{FreeBSD}\xspace}
  120. %
  121. % Some versions
  122. %
  123. \newcommand{\fpcversion}{1.0.6}
  124. %
  125. % PDF support
  126. %
  127. \latex{%
  128. \newif\ifpdf
  129. \ifx\pdfoutput\undefined
  130. \pdffalse
  131. \else
  132. \pdfoutput=1
  133. \pdftrue
  134. \fi
  135. }
  136. %
  137. % end of fpc-html.tex
  138. %