-
Notifications
You must be signed in to change notification settings - Fork 1
/
kyvernitis-resume.cls
191 lines (166 loc) · 4.92 KB
/
kyvernitis-resume.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
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
% Class Identifier and Version
\ProvidesClass{kyvernitis-resume}[2023/06/06 Kyvernitis class]
\NeedsTeXFormat{LaTeX2e}
% Set font size and paper type
\LoadClass[11pt,a4paper]{article}
% Enable custom and named colors
\RequirePackage[usenames,dvipsnames]{color}
% Remove paragraph indentation
\RequirePackage[parfill]{parskip}
% Set margin width
\RequirePackage[hmargin=1.25cm,vmargin=0.75cm]{geometry}
% Use cool fonts
\RequirePackage{fontspec}
% Using IBM Plex Sans
\RequirePackage[sfdefault,light]{plex-sans}
% Use hyperref
\RequirePackage[xetex]{hyperref}
% Use extended columns definitions
\RequirePackage{array}
% Make custom tables
\RequirePackage{tabularx}
% Use FontAwesome icons
\RequirePackage{fontawesome5}
% Adjust page width in the middle of the page
\RequirePackage{changepage}
% Adjust bullet size
\RequirePackage{scalerel}
% Remove page numbers
\pagestyle{empty}
% Define navy-blue color for later use. Color code is taken from Canva
\definecolor{navyblue}{RGB}{0, 83, 137}
\definecolor{links}{RGB}{3, 43, 198}
% Define new resizable bullet with default 0.7 size for later use
% Taken from https://tex.stackexchange.com/questions/534192/medium-sized-circle-as-a-bullet
\newcommand{\vbullet}[1][.7]{\mathbin{\ThisStyle{\vcenter{\hbox{%
\scalebox{#1}{$\SavedStyle\bullet$}}}}}%
}
% Setup Hyperlink style
\hypersetup{
colorlinks=true,
urlcolor=links
}
% Define some social accounts and contact information formats
\newcommand{\linkedin}[1]{
\href{https://linkedin.com/in/#1}{\textcolor{black}
{\faLinkedinIn}\hspace{0.5em}#1}
}
\newcommand{\email}[1]{
\href{mailto:#1}{\textcolor{black}
{\faEnvelope[regular]}\hspace{0.5em}#1}
}
\newcommand{\github}[1]{
\href{https://github.com/#1}{\textcolor{black}
{\faGithub}\hspace{0.5em}#1}
}
\newcommand{\twitter}[1]{
\href{https://twitter.com/#1}{\textcolor{black}
{\faTwitter}\hspace{0.5em}#1}
}
\newcommand{\facebook}[1]{
\href{https://www.facebook.com/#1}{\textcolor{black}
{\faFacebookF}\hspace{0.5em}#1}
}
\newcommand{\website}[1]{
\href{tel:#1}{\textcolor{black}
{\faGlobeAmericas}\hspace{0.5em}#1}
}
\newcommand{\phone}[1]{
\href{mailto:#1}{\textcolor{black}
{\faPhone*}\hspace{0.5em}#1}
}
\newcommand{\nationality}[1]{
\textcolor{black}{\faFlagUsa}\hspace{0.5em}#1
}
\newcommand{\address}[1]{
\textcolor{black}{\faMapMarker*}\hspace{0.5em}#1
}
% Define commands for fullname and job title
\def \fullname#1{\def\@name{#1}}
\def \@name {}
\def \jobtitle#1{\def\@title{#1}}
\def \@title {}
% Convenience commands
\newcommand{\italicitem}[1]{\item{\textit{#1}}}
\newcommand{\bolditem}[1]{\item{\textbf{#1}}}
\newcommand{\entry}[2]{#1 & #2 \tabularnewline}
% Define the resume header
\newcommand{\resumeheader}[6]{
% \phantomsection
% \addcontentsline{toc}{chapter}{\@name}
\begin{tabularx}{\textwidth}{Xr}{
\begin{tabular}[c]{l}
\fontsize{35}{45}\selectfont{\color{navyblue}{\textbf{\@name}}}
\ifx\empty\@title\empty\else
\\ \textit{\small\@title}
\fi
\end{tabular}
} & {
\begin{tabular}[c]{l@{\hspace{1em}}l}
\entry{\small#4}{\small#1}
\entry{\small#5}{\small#2}
\entry{\small#6}{\small#3}
\end{tabular}
}
\end{tabularx}
}
% Renew section command for resume section
\renewenvironment{section}[1]{
\phantomsection
\addcontentsline{toc}{section}{#1}
\medskip
{\color{navyblue}{\textbf{\textit{#1}}}}
\medskip
{\color{navyblue}\hrule}
\begin{list}{}{
\setlength{\leftmargin}{1.5em}
}
\item[]
}{
\end{list}
}
% Renew subsection command for resume subsections
% All arguments are compulsory
% #1: Name, #2: Description, #3: Time Period, #4: Location
\renewenvironment{subsection}[4]{
\phantomsection
\addcontentsline{toc}{subsection}{#1}
\textbf{#1} \hfill \textit{#3} \newline
\textit{#2} \hfill \textit{#4}
\smallskip
\begin{list}{$\vbullet$}{
\leftmargin=2em
}
\itemsep -0.5em \vspace{-0.5em}
}{
\end{list}
\vspace{0.5em}
}
% Define command for resume subsections with no bullets
% All arguments are compulsory
% #1: Name, #2: Description, #3: Time Period, #4: Location
\newenvironment{subsectionnobullet}[4]{
\phantomsection
\addcontentsline{toc}{subsection}{#1}
\textbf{#1} \hfill \textit{#3} \newline
\textit{#2} \hfill \textit{#4}
\smallskip
\begin{list}{}{
\leftmargin=0em \itemindent=0em \labelwidth=0em \labelsep=0em
}
\itemsep -0.7em \vspace{-0.7em}
}{
\end{list}
}
% Define new sectiontable command, which makes a section with a table
% All arguments are compulsory
% #1: Name of the section, #2: Body of the section
\newcommand{\sectiontable}[2]{
\begin{section}{#1}
\begin{adjustwidth}{0.0in}{0.1in}
\begin{tabularx}{\linewidth}{@{} >{\bfseries}l @{\hspace{5ex}} X @{}}
#2
\end{tabularx}
\end{adjustwidth}
\end{section}
}