blob: da692cceb95d2beae8e7182d00ebb6a80b8bc7b8 (
plain)
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
|
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% anysize.sty --- version 1.0 --- Aug 13, 1994
% set the paper&margin sizes in \LaTeX2e
% This style is LaTeX2e-conformant
% and will not run under ANY older version of LaTeX!
% idea and first implementation: Michael Salzenberg
% further programming, documentation and maintainance:
% Thomas Esser (te@informatik.uni-hannover.de)
% Dirk Hillbrecht (hillbrec@informatik.uni-hannover.de)
% documentation: anysize.tex/dvi
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{anysize}[1994/08/13 setting margin sizes]
\typeout{document style option `anysize' loaded}
\typeout{Michael Salzenberg, Thomas Esser, Dirk Hillbrecht}
\typeout{Version 1.0, Aug 13, 1994}
%
\DeclareOption{a4paper}
{\setlength\paperheight {297mm}%
\setlength\paperwidth {210mm}}
\DeclareOption{a5paper}
{\setlength\paperheight {210mm}%
\setlength\paperwidth {148mm}}
\DeclareOption{b5paper}
{\setlength\paperheight {250mm}%
\setlength\paperwidth {176mm}}
\DeclareOption{letterpaper}
{\setlength\paperheight {11in}%
\setlength\paperwidth {8.5in}}
\DeclareOption{legalpaper}
{\setlength\paperheight {14in}%
\setlength\paperwidth {8.5in}}
\DeclareOption{executivepaper}
{\setlength\paperheight {10.5in}%
\setlength\paperwidth {7.25in}}
\DeclareOption{landscape}
{\setlength\@tempdima {\paperheight}%
\setlength\paperheight {\paperwidth}%
\setlength\paperwidth {\@tempdima}}
%
% change paragraphe indenting (as in lkurz.dvi)
\DeclareOption{germanpar}
{\setlength{\parindent}{0pt}%
\setlength{\parskip}{5pt plus 2pt minus 1pt}}
% A4 is default paper size, if there is nothing set in the documentclass-statement
\ExecuteOptions{a4paper}
\ProcessOptions
% standard settings (DIN A4)
\newdimen\@Leftmargin \@Leftmargin=3.0cm
\newdimen\@Rightmargin \@Rightmargin=2.0cm
\newdimen\@Topmargin \@Topmargin=2.0cm
\newdimen\@Bottommargin \@Bottommargin=2.0cm
%
\def\InitLayout{
\setlength{\textwidth}{\paperwidth}
\addtolength{\textwidth}{-\@Leftmargin}
\addtolength{\textwidth}{-\@Rightmargin}
\setlength{\textheight}{\paperheight}
\addtolength{\textheight}{-\@Topmargin}
\addtolength{\textheight}{-\@Bottommargin}
\addtolength{\textheight}{-\headheight}
\addtolength{\textheight}{-\headsep}
\addtolength{\textheight}{-\footskip}
\setlength{\oddsidemargin}{\@Leftmargin}
\addtolength{\oddsidemargin}{-1in}
\setlength{\evensidemargin}{\@Rightmargin}
\addtolength{\evensidemargin}{-1in}
\setlength{\topmargin}{\@Topmargin}
\addtolength{\topmargin}{-1in}
}
%
\InitLayout
%
\def\papersize#1#2{
\paperwidth=#2
\paperheight=#1
\InitLayout
}
%
\def\marginsize#1#2#3#4{
\@Leftmargin=#1
\@Rightmargin=#2
\@Topmargin=#3
\@Bottommargin=#4
\InitLayout
}
%
\endinput
|