File: local.sty

package info (click to toggle)
tetex-src 3.0.dfsg.2-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 122,292 kB
  • ctags: 2,709
  • sloc: makefile: 2,323; perl: 1,820; sh: 1,378; lisp: 448; python: 335; xml: 175; sed: 138; ansic: 138; yacc: 52
file content (214 lines) | stat: -rw-r--r-- 7,342 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
% local.sty
% a set of useful common hacks by Sebastian Rahtz, 1988-1993
% add to these for your site
%------------------------------------
\def\filename{local.sty}
\def\filedate{25.2.93}
\ProvidesPackage{local}
%
% redefine bits of article to make it less aggressive
%
\setcounter{secnumdepth}{3}
\def\thepart{\Roman{part}} \def\thesection {\arabic{section}}
\def\@pnumwidth{1.55em}
\def\@tocrmarg {2.55em}
\def\@dotsep{4.5}
\setcounter{tocdepth}{3}
\renewcommand\section{\@startsection {section}{1}{\z@}%
                                   {-3ex \@plus -1ex \@minus -.2ex}%
                                   {2ex \@plus.2ex}%
                                   {\reset@font\Large\bfseries\sffamily}}
\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
                                     {-2.75ex\@plus -1ex \@minus- .2ex}%
                                     {1ex \@plus .2ex}%
                                     {\reset@font\large\sffamily}}
\renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
                                     {-2.75ex\@plus -1ex \@minus -.2ex}%
                                     {1ex \@plus .2ex}%
                                     {\reset@font\normalsize\sffamily}}
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
                                    {2.75ex \@plus1ex \@minus.2ex}%
                                    {-1em}%
                                    {\reset@font\normalsize\bfseries}}
\renewcommand\subparagraph{\@startsection{subparagraph}{5}{\parindent}%
                                       {2.75ex \@plus1ex \@minus .2ex}%
                                       {-1em}%
                                      {\reset@font\normalsize\bfseries}}

\def\l@section#1#2{\addpenalty{\@secpenalty} \addvspace{1.0em plus 1pt}
\@tempdima 1.5em \begingroup
 \parindent \z@ \rightskip \@pnumwidth 
 \parfillskip -\@pnumwidth 
 \bfseries \leavevmode #1\hfil \hbox to\@pnumwidth{\hss #2}\par
 \endgroup}
\def\l@subsection{\@dottedtocline{2}{1.5em}{2.3em}}
\def\l@subsubsection{\@dottedtocline{3}{3.8em}{3.2em}}
\def\l@paragraph{\@dottedtocline{4}{7.0em}{4.1em}}
\def\l@subparagraph{\@dottedtocline{5}{10em}{5em}}
\oddsidemargin=0.47in
\evensidemargin=0.47in
\headsep=14.5mm
\topmargin=-0.35in
\textheight 8.5 true in  % Height of text (including footnotes and figures)
\textwidth 5.35 true in
\def\address#1{\gdef\@address{#1}}
\address{}
\if@twoside
    \def\ps@headings{%
      \let\@oddfoot\@empty\let\@evenfoot\@empty
      \def\@evenhead{\thepage\hfil\scshape\leftmark}%
      \def\@oddhead{{\scshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\sectionmark##1{%
        \markboth {\lowercase{\ifnum \c@secnumdepth >\z@
            \thesection.\hskip 1em\relax\fi
            ##1}}{}}%
      \def\subsectionmark##1{%
        \markright {\ifnum \c@secnumdepth >\@ne
            \thesubsection\hskip 1em\relax \fi
            \lowercase{##1}}}}
\else
    \def\ps@headings{%
      \let\@oddfoot\@empty
      \def\@oddhead{{\scshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\sectionmark##1{%
        \markright {\lowercase{\ifnum \c@secnumdepth >\m@ne
            \thesection\hskip 1em\relax \fi
            ##1}}}}
\fi
\def\@listI{\setlength\leftmargin{\leftmargini}
            \setlength\parsep {2\p@ \@plus1\p@ \@minus1\p@}%
            \setlength\topsep {4\p@ \@plus1\p@ \@minus1\p@}%
            \setlength\itemsep{2\p@ \@plus1\p@ \@minus1\p@}}
\let\@listi\@listI
\@listi

\def\thebibliography#1{\section*{Bibliography\@mkboth
  {{\sc Bibliography}}{{\sc Bibliography}}}\list
  {\arabic{enumi}}{\settowidth\labelwidth{0}\leftmargin\labelwidth
    \advance\leftmargin\labelsep
    \usecounter{enumi}}
    \addcontentsline{toc}{section}{Bibliography}
    \def\newblock{\hskip .11em plus .33em minus -.07em}
    \sloppy
    \sfcode`\.=1000\relax}
%
% alltt, from Lamport
\def\docspecials{\do\ \do\$\do\&%
  \do\#\do\^\do\^^K\do\_\do\^^A\do\%\do\~}
\def\alltt{\trivlist \item[]\if@minipage\else\vskip\parskip\fi
\leftskip\@totalleftmargin\rightskip\z@
\parindent\z@\parfillskip\@flushglue\parskip\z@
\@tempswafalse \def\par{\if@tempswa\hbox{}\fi\@tempswatrue\@@par}
\obeylines \tt \catcode``=13 \@noligs \let\do\@makeother \docspecials
 \frenchspacing\@vobeyspaces}
\let\endalltt=\endtrivlist
%
% new list environments
%
% catalogue forces the first line to be on a line by itself
\newenvironment{catalogue}{\begin{list}{}%
{\def\makelabel##1{%
                         \hbox to \labelwidth{%
                                \vbox{%
                                    \hbox to 0pt{{\bf ##1}\hss}%
                                    \hbox to 0pt{\hfil}}%
                            \hfil}}}}%
{\end{list}}
%
% description list, with specified width
\newenvironment{tablist}[1]{\begin{list}{}%
{\labelwidth=#1
\leftmargin=#1
\let\makelabel\descriptionlabel}%
}{\end{list}}
%
% wider description list
\newenvironment{widedesc}{\begin{list}{}%
{\labelwidth=1in\leftmargin=1.1in\let\makelabel\descriptionlabel}%
}{\end{list}}

% Names for TeX products
% September 9, 1988:  modified by Ted Nieland, Systems Research Laboratories
%   Now includes definitions for PiCTeX and TeXsis.  Definitions now in /def
%   form rather than in /newcommand.
%
%
\font\mf=logo10
\hyphenchar\mf=-1
% Metafont from the METAFONT Documentation
\def\METAFONT{{\mf METAFONT}}
% BIBTeX from the BiBTeX Documentation
\def\BIBTeX{{\rm B\kern-.05em{\sc i\kern-.025em b}\kern-.08em
    T\kern-.1667em\lower.7ex\hbox{E}\kern-.125emX}}
% SliTeX from the SliTeX Documentation
\def\SLiTeX{S\kern-.065em L\kern-.18em\raise.32ex\hbox{i}\kern-.03em\TeX}
% AMSTeX from the AMSTeX Files 
\def\AmSTeX{{$\cal A$\kern-.1667em\lower.5ex\hbox{$\cal M$}\kern-.125em
     $\cal S$-\TeX}}
% PiCTeX Documentation from the PiCTeX Files
\def\PiC{P\kern-.12em\lower.5ex\hbox{I}\kern-.075emC}
\def\PiCTeX{\PiC\kern-.11em\TeX}
%
\def\pictex{\PiCTeX}
\def\AMSTeX{\AmSTeX}
\def\AMSTEX{\AmSTeX}
\def\amstex{\AmSTeX}
\def\BibTeX{\BIBTeX}
\def\BiBTeX{\BIBTeX}
\def\bibtex{\BIBTeX}
\def\SliTeX{\SLiTeX}
\def\slitex{\SLiTeX}
\def\Metafont{\METAFONT}
\def\metafont{\METAFONT}
\def\MF{\METAFONT}
\def\latex{\LaTeX}
% TeXsis from the TeXsis documentation 
\def\TeXsis{\TeX sis}
\def\PS{{\sc PostScript}}
\def\Unix{{\sc Unix}}
\def\unix{{\sc Unix}}
\def\WEB{{\mf WEB}}

% acronyms
\def\acronym#1#2{\expandafter\def\csname#1\endcsname%
{#2 (#1)\expandafter\def\csname#1\endcsname{#1}}}%

% new environment for a 'screen shot'
% set in cmtt & 'alltt', and inset by 0.5in and boxed
%
% spqr oct 2 88
%
\newcount\screenchars
\newlength\screenwidth
\newlength\letterwidth
\newbox\screenbox
\newenvironment{screen}{%
\sbox{\screenbox}{{\screenfont m}}
\screenwidth=\wd\screenbox
\letterwidth=\screenwidth
\multiply\screenwidth by \screenchars
\advance\screenwidth by 2\letterwidth
\vspace{\topsep}
\setbox\screenbox=\vtop\bgroup
\begin{alltt}\screenfont%
}{%
\end{alltt}
\egroup%
\hspace{\rightmargin}\framebox[\screenwidth][l]{\rule{\letterwidth}{0em}%
\usebox{\screenbox}}%
\vspace{\topsep}%
}
% defaults
\screenchars=80
\font\screenfont cmtt8
%
\newcommand{\Cmd}[1]{{\ttfamily\upshape\char'134#1}}
%
\def\arraybackslash{\let\\=\@arraycr}
%
\RequirePackage{array}
\newcolumntype{P}[1]{>{\raggedright\arraybackslash}p{#1}}
\newcolumntype{C}[1]{>{\centering\arraybackslash}p{#1}}
\endinput