-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgalois-proposal.cls
146 lines (124 loc) · 4.25 KB
/
galois-proposal.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
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This class file defines a style useful for writing white papers at Galois.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ProvidesClass{galois-whitepaper}
\DeclareOption*{%
\PassOptionsToClass{\CurrentOption}{article}%
}
\ProcessOptions\relax
\LoadClass{article}
% Useful packages:
\RequirePackage[table]{xcolor}
\RequirePackage{graphicx}
\RequirePackage[headheight=0.8in,headsep=0.1in,top=1in,left=1in,right=1in,bottom=1in]{geometry}
\RequirePackage{lastpage}
\RequirePackage{xspace}
% Define fonts
\RequirePackage[sc]{mathpazo}
\linespread{1.0}
\RequirePackage[scaled]{helvet}
\RequirePackage{sectsty}
\allsectionsfont{\sffamily}
\newcommand{\highlight}[2][yellow]{\colorbox{#1}{#2}}
% Misc defines
\newcommand{\@companyName}{\vspace*{.3cm} Galois, Inc.}
\newcommand{\@addressPhone}{
421 SW 6th Ave., Ste.\ 300\\
Portland, OR 97204
}
\newcommand{\@contact}{CONTACT}
\newcommand{\@subtitle}{SUBTITLE}
\newcommand{\contact}[1]{\renewcommand{\@contact}{{#1}}}
\renewcommand{\paragraph}[1]{\textbf{\sffamily{#1}}\quad}
\definecolor{galoislightgray}{gray}{0.6}
% Define header and footer
\RequirePackage{fancyhdr}
\pagestyle{fancy}
\fancyheadoffset[l]{1in}
\fancyheadoffset[r]{0in}
%\fancyheadoffset[r]{0.2in}
\fancyhead{}%clear
\fancyfoot{}%clear
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\footrulewidth}{1pt}
\setlength{\parskip}{11pt} % TODO!
% Define a special header style for the title page:
\newcommand{\ps@title}{%
\renewcommand{\@oddhead}{%
\sffamily\hspace{-0.25in}\includegraphics[width=1in]{figures/galois.png}}
}
% Set up the headers/footers for the rest of the document:
\lhead{\sffamily \hspace{0.75in}\includegraphics[width=1in]{figures/galois.png}}
\rhead{
\sffamily \vspace{.2in}
\textit{\@title{}}\\
\textit{MONTH XX, 2020{}}\\
\color{galoislightgray}
}
\lfoot{\sffamily\color{galoislightgray}\small\copyright{} 2022 Galois, Inc.}
\cfoot{\sffamily\color{galoislightgray}\small {} Proprietary}
\rfoot{
\sffamily \color{galoislightgray}\small
Page \thepage{}% of \pageref{LastPage}
}
% The title content definition:
\DeclareRobustCommand{\maketitle}{
\thispagestyle{title}
{\sffamily
{\large \textbf{}}\\
\textbf{\sffamily \large \@title}\\
{\color{galoislightgray} \textit{Dr.\ INSERT\footnotemark[1], Dr.\ INSERT\footnotemark[1]Dr.\ SUB INSERT\footnotemark[3]} }\\
{\color{galoislightgray} \textit{\footnotemark[1] Galois, Inc.}\\
\textit{\footnotemark[2] SUBCONTRACTOR}\\
\texttt{[email protected]} }\\
{\color{galoislightgray} \textit{MONTH XX, 2021} }\\
}
}
% Add a stop ``.'' after each section number:
\renewcommand*{\@seccntformat}[1]{%
\csname the#1\endcsname.\quad
}
% Redefine the bibliography environment to use \section{\bibname}
% instead of \section*{\bibname}
\makeatletter
\newcommand{\bibname}{References}
\renewenvironment{thebibliography}[1]
{\section*{\bibname}% <-- this line was changed from \chapter* to \section*
\@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}%
\list{\@biblabel{\@arabic\c@enumiv}}%
{\settowidth\labelwidth{\@biblabel{#1}}%
\leftmargin\labelwidth
\advance\leftmargin\labelsep
\@openbib@code
\usecounter{enumiv}%
\let\p@enumiv\@empty
\renewcommand\theenumiv{\@arabic\c@enumiv}}%
\sloppy
\clubpenalty4000
\@clubpenalty \clubpenalty
\widowpenalty4000%
\sfcode`\.\@m}
{\def\@noitemerr
{\@latex@warning{Empty `thebibliography' environment}}%
\endlist}
% Adjust spacing around headings:
\renewcommand\section{\@startsection {section}{1}{\z@}%
{-0ex \@plus -1ex \@minus -.2ex}%
% {0.2ex \@plus.1ex}%
{0.1ex \@plus .1ex \@minus -.1ex}%
{\raggedright\sffamily\large\bfseries}}
\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
{-0ex\@plus -1ex \@minus -.2ex}%
{0.1ex \@plus .1ex \@minus -.1ex}%
% {-1em}%
{\raggedright\sffamily\bfseries}}
\renewcommand\subsubsection{\@startsection{subsubsection}{3}{\z@}%
{-0ex \@plus -1ex \@minus -.2ex}%
{0.1ex \@plus .1ex \@minus -.1ex}%
% {-1em}%
{\sffamily\normalsize\bfseries}} %
\renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
{-0ex \@plus -1ex \@minus -.2ex}%
{-1em}%
{\normalsize\bfseries}} %
\makeatother