-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhieudo-build.cls
96 lines (83 loc) · 4.06 KB
/
hieudo-build.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
% Intro Options
\ProvidesClass{hieudo-build}[2016/07/26 CV class]
\NeedsTeXFormat{LaTeX2e}
\DeclareOption{print}{\def\@cv@print{}}
\DeclareOption*{%
\PassOptionsToClass{\CurrentOption}{article}
}
\ProcessOptions\relax
\LoadClass{article}
% Package Imports
\usepackage[hmargin=1.4cm, vmargin=1.25cm]{geometry}
\usepackage[usenames,dvipsnames]{xcolor}
\usepackage[hidelinks]{hyperref}
\usepackage{titlesec}
\usepackage[absolute]{textpos}
\usepackage[UKenglish]{babel}
\usepackage[UKenglish]{isodate}
\usepackage{fontspec,xltxtra,xunicode}
\usepackage{fontawesome5}
\pagenumbering{gobble}
\usepackage{datetime2}
% Color definitions
\definecolor{date}{HTML}{000000}
\definecolor{primary}{HTML}{000000}
\definecolor{headings}{HTML}{0E0E0F}
\definecolor{subheadings}{HTML}{1A1C1E}
% Set main fonts
\defaultfontfeatures{Mapping=tex-text}
\setmainfont[Color=primary, Path = NiveauGrotesk/, Scale=1.02]{Niveau-Lig.otf}
\newcommand{\custombold}[1]
{\color{subheadings}\fontspec[Path = NiveauGrotesk/]{Niveau-ExtraLight.otf}\selectfont #1 \normalfont}
\linespread{1.1}
% Date format
\DTMnewdatestyle{mylastupdate}{%
\renewcommand*{\DTMdisplaydate}[4]{\DTMtwodigits{##2}.\DTMtwodigits{##3}.##1}\color{date}\fontspec[Path = NiveauGrotesk/]{Niveau-ExtraLight}\fontsize{10pt}{10pt}\selectfont%
\renewcommand*{\DTMDisplaydate}{\DTMdisplaydate}%
}
% Name command
\newcommand{\namesection}[3]{
\hspace{-1.7em}\raggedright{\parbox[c][3em][c]{25em}{\vspace{-1em}\fontspec[Path = NiveauGrotesk/]{Niveau-Bol}\fontsize{50pt}{0cm}\selectfont #1}}
\hfill
\hspace{-1.7em}\raggedleft{\parbox[c][3em][c]{12em}{\color{headings}\fontspec[Path = NiveauGrotesk/]{Niveau-Lig}\fontsize{11pt}{14pt}\selectfont #2}}
\hspace{0em}\raggedleft{\parbox[c][3em][c]{13em}{\color{headings}\fontspec[Path = NiveauGrotesk/]{Niveau-Lig}\fontsize{11pt}{14pt}\selectfont #3}}
\vspace{1.6em}
}
\titlespacing{\section}{0pt}{0pt}{5pt}
% Headings command
\titleformat{\section}{\color{headings}
\scshape\fontspec[Path = NiveauGrotesk/]{Niveau-Lig}\fontsize{22pt}{18pt}\selectfont \raggedright\uppercase}{} {0em}{}
% Subeadings command
\titleformat{\subsection}{\color{subheadings}
\fontspec[Path = NiveauGrotesk/]{Niveau-Bol}\fontsize{12pt}{12pt}\selectfont\bfseries}{}{0em}{}
\titlespacing{\subsection}{0pt}{\parskip}{-\parskip}
\titlespacing{\subsubsection}{0pt}{\parskip}{-\parskip}
\newcommand{\runsubsection}[1]{\color{subheadings}
\fontspec[Path = NiveauGrotesk/]{Niveau-Bol}\fontsize{12pt}{12pt}\selectfont\bfseries {#1} \normalfont}
\titlespacing{\section}{0pt}{0pt}{5pt}
% Jobtitle command
\newcommand{\workplace}[2]{
\color{subheadings}\raggedright
\fontspec[Path = NiveauGrotesk/]{Niveau-Bol}\fontsize{12pt}{12pt}\selectfont\bfseries {#1} \normalfont
\hfill
\color{subheadings}\raggedleft
\fontspec[Path = NiveauGrotesk/]{Niveau-Reg}\fontsize{12pt}{12pt}\selectfont\bfseries {#2} \normalfont
}
\titlespacing{\section}{0pt}{0pt}{5pt}
% Descriptors command
\newcommand{\descript}[1]{\color{subheadings}\raggedright\scshape\fontspec[Path = NiveauGrotesk/]{Niveau-Reg}\fontsize{11pt}{13pt}\selectfont {#1 \\} \normalfont}
\titlespacing{\section}{0pt}{0pt}{3pt}
\newcommand{\note}[1]{\color{subheadings}\raggedright\scshape\fontspec[Path = NiveauGrotesk/]{Niveau-LigIta}\fontsize{9pt}{10pt}\selectfont {#1 \\} \normalfont}
% Positions command
\newcommand{\position}[2]{ \color{subheadings}\raggedright\scshape\fontspec[Path = NiveauGrotesk/]{Niveau-Reg}\fontsize{11pt}{13pt}\selectfont {#1}\normalfont
\hfill
\color{subheadings}\raggedleft\scshape\fontspec[Path = NiveauGrotesk/]{Niveau-Reg}\fontsize{11pt}{13pt}\selectfont {#2\\}\normalfont}
\titlespacing{\section}{0pt}{0pt}{3pt}
% Location command
\newcommand{\location}[1]{\color{primary}\raggedright\fontspec[Path = NiveauGrotesk/]{Niveau-Reg}\fontsize{11pt}{13pt}\selectfont {#1\\} \normalfont}
\titlespacing{\section}{0pt}{0pt}{3pt}
% Section seperators command
\newcommand{\sectionsep}[0]{\vspace{10pt}}
\newcommand{\smallsectionsep}[0]{\vspace{3pt}}
% Bullet Lists with fewer gaps command
\newenvironment{tightemize}{\vspace{-\topsep}\begin{itemize}\itemsep1pt \parskip0pt \parsep0pt}{\end{itemize}\vspace{-\topsep}}