123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193 |
- %
- % $Id$
- % This file is part of the FPC documentation.
- % Copyright (C) 1997, by Michael Van Canneyt
- %
- % The FPC documentation is free text; you can redistribute it and/or
- % modify it under the terms of the GNU Library General Public License as
- % published by the Free Software Foundation; either version 2 of the
- % License, or (at your option) any later version.
- %
- % The FPC Documentation is distributed in the hope that it will be useful,
- % but WITHOUT ANY WARRANTY; without even the implied warranty of
- % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- % Library General Public License for more details.
- %
- % You should have received a copy of the GNU Library General Public
- % License along with the FPC documentation; see the file COPYING.LIB. If not,
- % write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- % Boston, MA 02111-1307, USA.
- %
- \ProvidesPackage{fpc}[1996/12/09]
- \NeedsTeXFormat{LaTeX2e}
- \ExecuteOptions{titlepage}
- % First, all definitions for latex only.
- \newcommand{\docdescription}[1]{\def\@FPCDescription{#1}}
- \gdef\@FPCDescription{}%
- \newcommand{\docversion}[1]{\def\@FPCVersion{#1}}
- \gdef\@FPCVersion{}%
- % For backwards compatibility
- \newcommand{\unitdescription}[1]{\def\@FPCDescription{#1}}
- \newcommand{\unitversion}[1]{\def\@FPCVersion{#1}}
- \renewcommand\maketitle{\begin{titlepage}%
- \let\footnotesize\small
- \let\footnoterule\relax
- \null\vfil
- \vskip 4cm%
- {\noindent\raggedright\Large\@title\\}%
- \noindent \rule{\linewidth}{1.5mm}\\%
- {\raggedleft\large%
- \begin{tabular}[t]{r}%
- \@FPCDescription \\
- \@FPCVersion \\
- \@date
- \end{tabular}\par}%
- \vskip 5cm%
- {\noindent \large \textsf{\@author} \\%
- \rule{\linewidth}{0.5mm}}
- \@thanks
- \vfil\null
- \end{titlepage}%
- \setcounter{footnote}{0}%
- \let\thanks\relax\let\maketitle\relax
- \gdef\@thanks{}\gdef\@author{}\gdef\@title{}}
- % end of \maketitle
- % For the \procedure and \function commands, we don't want heading numbers.
- \setcounter{secnumdepth}{1}
- % redefine the subsection command to leave less space,
- %and to use sans serif
- \renewcommand\subsection{\@startsection%
- {subsection}%
- {2}%
- {\z@}%
- {-4.25ex\@plus -1ex \@minus -.2ex}%
- {1pt}%
- {\normalfont\large\sffamily\bfseries}}
- % Now, Let's define the \procedure and \function commands.
- \newcommand{\FPClabel}[1]{%
- \raggedleft\makebox[0pt][r]{\textsf{#1:}}
- }
- \newenvironment{FPCList}
- {\begin{list}{}{%
- \renewcommand{\makelabel}[1]{\FPClabel{##1}\hfil\relax}
- \setlength{\labelwidth}{0pt}%
- \setlength{\leftmargin}{0pt}}%
- \setlength{\labelsep}{0pt}%
- }
- {\end{list}}
- %
- % define a version of \procedure and \function
- % which allows you to give a label.
- %
- \newcommand{\functionl}[7]{
- \subsection{#1}
- \raisebox{1ex}{\rule{\linewidth}{0.5mm}}
- \label{fu:#2}
- \index{#1}
- \begin{FPCList}
- \item[Declaration]
- \texttt {Function #1 #3 : #4;}
- \item[Description]
- #5
- \item[Errors]
- #6
- \item[See also]
- #7
- \end{FPCList}
- }
- \newcommand{\procedurel}[6]{
- \subsection{#1}
- \raisebox{1ex}{\rule{\linewidth}{0.5mm}}
- \label{pro:#2}
- \index{#1}
- \begin{FPCList}
- \item[Declaration]
- \texttt {Procedure #1 #3;}
- \item[Description]
- #4
- \item[Errors]
- #5
- \item[See also]
- #6
- \end{FPCList}
- }
- % define a capital version,
- % for function/command which has no options passed to it.
- \newcommand{\Functionl}[6]{\functionl{#1}{#2}{}{#3}{#4}{#5}{#6}}
- \newcommand{\Procedurel}[5]{\procedurel{#1}{#2}{}{#3}{#4}{#5}}
- %
- % These versions take the function name as the label.
- %
- \newcommand{\function}[6]{\functionl{#1}{#1}{#2}{#3}{#4}{#5}{#6}}
- \newcommand{\procedure}[5]{\procedurel{#1}{#1}{#2}{#3}{#4}{#5}}
- % define a capital version,
- % for function/command which has no options passed to it.
- \newcommand{\Function}[5]{\function{#1}{}{#2}{#3}{#4}{#5}}
- \newcommand{\Procedure}[4]{\procedure{#1}{}{#2}{#3}{#4}}
- % Now the referencing commands.
- %
- % First, the ones with alternate label (second argument}
- %
- \newcommand{\seefl}[2]{
- \textsf{#1} (\pageref{fu:#2})}
- \newcommand{\seepl}[2]{
- \textsf{#1} (\pageref{pro:#2})}
- %
- % Now the ones with label.
- %
- \newcommand{\seef}[1]{\seefl{#1}{#1}}
- \newcommand{\seep}[1]{\seepl{#1}{#1}}
- %
- % man page references don't need labels.
- %
- \newcommand{\seem}[2]{\texttt{#1} (#2) }
- %
- % for easy typesetting of variables.
- %
- \newcommand{\var}[1]{\texttt {#1}}
- \newcommand{\file}[1]{\textsf {#1}}
- %
- % Useful references.
- %
- \newcommand{\progref}{\htmladdnormallink{Programmers' guide}{../prog/prog.html}\ }
- \newcommand{\refref}{\htmladdnormallink{Reference guide}{../ref/ref.html}\ }
- \newcommand{\userref}{\htmladdnormallink{Users' guide}{../user/user.html}\ }
- \newcommand{\unitsref}{\htmladdnormallink{Unit reference}{../units/units.html}\ }
- \newcommand{\seecrt}{\htmladdnormallink{CRT}{../crt/crt.html}}
- \newcommand{\seelinux}{\htmladdnormallink{Linux}{../linux/linux.html}}
- \newcommand{\seestrings}{\htmladdnormallink{strings}{../strings/strings.html}}
- \newcommand{\seedos}{\htmladdnormallink{DOS}{../dos/dos.html}}
- \newcommand{\seegetopts}{\htmladdnormallink{getopts}{../getopts/getopts.html}}
- \newcommand{\seeobjects}{\htmladdnormallink{objects}{../objects/objects.html}}
- \newcommand{\seegraph}{\htmladdnormallink{graph}{../graph/graph.html}}
- \newcommand{\seeprinter}{\htmladdnormallink{printer}{../printer/printer.html}}
- \newcommand{\seego}{\htmladdnormallink{GO32}{../go32/go32.html}}
- %
- % Nice environments
- %
- % For Code examples (complete programs only)
- \newenvironment{CodEx}{}{}
- % For Tables.
- \newenvironment{FPCtable}[2]{\begin{table}\caption{#2}\begin{center}\begin{tabular}{#1}}{\end{tabular}\end{center}\end{table}}
- % The same, but with label in third argument (tab:#3)
- \newenvironment{FPCltable}[3]{\begin{table}\caption{#2}\label{tab:#3}\begin{center}\begin{tabular}{#1}}{\end{tabular}\end{center}\end{table}}
- %
- % Commands to reference these things.
- %
- \newcommand{\seet}[1]{table (\ref{tab:#1}) }
- %
- % some OSes
- %
- \newcommand{\linux}{\textsc{linux}\ }
- \newcommand{\dos} {\textsc{dos}\ }
- \newcommand{\msdos}{\textsc{ms-dos}\ }
- \newcommand{\ostwo}{\textsc{os/2}\ }
- \newcommand{\windows}{\textsc{Windows}\ }
- \newcommand{\windowsnt}{\textsc{WindowsNT}\ }
- \newcommand{\fpc}{Free Pascal\ }
- \newcommand{\gnu}{\textsc{gnu}\ }
- %
- % Some versions
- %
- \newcommand{\fpcversion}{0.99.7}
- % end of fpc.sty
|