-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsydeStyle.cls
executable file
·169 lines (149 loc) · 3.34 KB
/
sydeStyle.cls
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
% Systems Design Engineering Report Style
%
% Created by Matthew Zulak <mzulak@engmail> with assistance from
% Prof. G. Heppler <heppler@uwaterloo.ca>.
%
% Updated by Darcy Parks <dparks@engmail>
%
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{sydeStyle}
\LoadClass[12pt]{report}
\usepackage{textcase}
\usepackage{setspace}
\usepackage{scalefnt}
\usepackage{url}
\usepackage{graphicx}
\usepackage{lscape}
\newcommand{\degree}{\ensuremath{^\circ}}
\newif\if@workreport \@workreportfalse
\DeclareOption{workreport}{\@workreporttrue}
\ProcessOptions\relax
% Define new variables
\newcommand{\@authortwo} {}
\newcommand{\authortwo}[1]{
\renewcommand{\@authortwo}{#1}
}
\newcommand{\@authorthree} {}
\newcommand{\authorthree}[1]{
\renewcommand{\@authorthree}{#1}
}
\newcommand{\@authorfour} {}
\newcommand{\authorfour}[1]{
\renewcommand{\@authorfour}{#1}
}
\newcommand{\@authorfive} {}
\newcommand{\authorfive}[1]{
\renewcommand{\@authorfive}{#1}
}
\newcommand{\@authorsix} {}
\newcommand{\authorsix}[1]{
\renewcommand{\@authorsix}{#1}
}
\newcommand{\@coursecode} {}
\newcommand{\coursecode}[1]{
\renewcommand{\@coursecode}{#1}
}
\newcommand{\@prof} {}
\newcommand{\prof}[1]{
\renewcommand{\@prof}{#1}
}
\newcommand{\@company} {}
\newcommand{\company}[1]{
\renewcommand{\@company}{#1}
}
\newcommand{\@companyaddress} {}
\newcommand{\companyaddress}[1]{
\renewcommand{\@companyaddress}{#1}
}
\renewcommand{\chaptername}{}
\renewcommand{\baselinestretch}{1.5}
\renewcommand{\textfraction}{0.01}
\renewcommand{\topfraction}{0.99}
\renewcommand{\bottomfraction}{0.99}
\setlength{\oddsidemargin}{0.5in}
\setlength{\evensidemargin}{0.0in}
\setlength{\textwidth}{6in}
\setlength{\topmargin}{0in}
\setlength{\headheight}{0in}
\setlength{\headsep}{0in}
\setlength{\textheight}{9in}
\newcounter{figs}
\newcounter{eqns}
\newcounter{tabs}
\setcounter{secnumdepth}{1}
\bibliographystyle{IEEEtran}
% TODO
% 1. Fix the width of the title so the line breaks sooner
% 2. Allow multiple authors somehow
% 3. Make the vertical spacing look like the example.
% 4. Figure out mandatory/optional arguments for each type of report
% 5. Fix typeout messages
\newcommand{\worktitlepage}
{
\renewcommand{\maketitle}
{
\begin{titlepage}
\vspace*{2em}
\begin{center}
University of Waterloo\\
Faculty of Engineering\\
Department of Systems Design Engineering
\end{center}
\null\vfill
\begin{center}
\Huge\@title
\end{center}
\null\vfill
\begin{center}
\@company\\
\@companyaddress
\end{center}
\vspace{2em}
\begin{center}
\@author\\
\@date.
\end{center}
\end{titlepage}
}
}
\newcommand{\designtitlepage}
{
\renewcommand{\maketitle}
{
\begin{titlepage}
\vspace*{2em}
\begin{center}
{\Huge\@title}
\end{center}
\null\vfill
\begin{center}
{A Report Submitted in Partial Fulfillment\\
of the Requirements for SYDE \@coursecode}
\end{center}
\vspace{2em}
\begin{center}
\@author\par
\@authortwo\par
\@authorthree\par
\@authorfour\par
\end{center}
\vskip 2em
\begin{center}
{Faculty of Engineering\\
Department of Systems Design Engineering}
\end{center}
\vskip 2em
\begin{center}
{\@date.\\
Course Instructor: \@prof}
\end{center}
\end{titlepage}
}
}
\if@workreport
\worktitlepage
\typeout{SYDE: Creating work report}
\else
\designtitlepage
\typeout{SYDE: Creating design report}
\fi