Debian Codegraph @

texmf-dist/source/latex/limecv/limecv.dtx

raw
1 % \iffalse meta-comment
2 %
3 % Copyright (C) 2017 - 2021 by Olivier Pieters
4 % --------------------------------------------------------------------------
5 % This work may be distributed and/or modified under the
6 % conditions of the LaTeX Project Public License, either version 1.3
7 % of this license or (at your option) any later version.
8 % The latest version of this license is in
9 % http://www.latex-project.org/lppl.txt
10 % and version 1.3c or later is part of all distributions of LaTeX
11 % version 2008-05-04 or later.
12 %
13 % This work has the LPPL maintenance status `maintained'.
14 %
15 % The Current Maintainer of this work is Olivier Pieters.
16 %
17 % This work consists of the files limecv.dtx and limecv.ins
18 % and the derived filebase limecv.cls.
19 %
20 % \fi
21 %
22 % \iffalse
23 %<*driver>
24 \ProvidesFile{limecv.dtx}
25 %</driver>
26 %<class>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
27 %<class>\ProvidesClass{limecv}
28 %<*class>
29 [2021/12/01 v0.1.12 limecv Document class for CVs.]
30 %</class>
31 %
32 %<*driver>
33 \documentclass{ltxdoc}
34 \usepackage{listings}
35 \usepackage{tikz}
36 \usepackage{hyperref}
37 \usepackage{cleveref}
38 \usepackage{xparse}
39 \usepackage[BoldFont,SlantFont]{xeCJK}
40
41 \NewDocumentCommand{\cvRequirement}{m}{\textbf{#1}}
42
43 \definecolor{cvGreen}{HTML}{357F2D}
44 \definecolor{cvGreenLight}{HTML}{b8e4b3}
45 \definecolor{cvRed}{HTML}{7f2d35}
46 \definecolor{cvDark}{HTML}{2F3142}
47 \definecolor{cvAccent}{HTML}{474A65}
48
49 \lstset{%
50 basicstyle=\ttfamily, % font style and size
51 breakatwhitespace=false,
52 breaklines=true,
53 numbers=left,
54 numberstyle=\tiny,
55 numbersep=5pt,
56 language=[LaTeX]{TeX},
57 keywordstyle=\color{blue},
58 commentstyle=\color{red}
59 }
60
61 \EnableCrossrefs
62 \CodelineIndex
63 \RecordChanges
64 \begin{document}
65 \DocInput{limecv.dtx}
66 \PrintChanges
67 \PrintIndex
68 \end{document}
69 %</driver>
70 % \fi
71 %
72 % \CheckSum{1697}
73 %
74 % \CharacterTable
75 % {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
76 % Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
77 % Digits \0\1\2\3\4\5\6\7\8\9
78 % Exclamation \! Double quote \" Hash (number) \#
79 % Dollar \$ Percent \% Ampersand \&
80 % Acute accent \' Left paren \( Right paren \)
81 % Asterisk \* Plus \+ Comma \,
82 % Minus \- Point \. Solidus \/
83 % Colon \: Semicolon \; Less than \<
84 % Equals \= Greater than \> Question mark \?
85 % Commercial at \@ Left bracket \[ Backslash \\
86 % Right bracket \] Circumflex \^ Underscore \_
87 % Grave accent \` Left brace \{ Vertical bar \|
88 % Right brace \} Tilde \~}
89 %
90 %
91 % \changes{v0.1}{2017/09/12}{Initial version.}
92 % \changes{v0.1.1}{2017/09/13}{Bug fixes and improved documentation.}
93 % \changes{v0.1.2}{2017/11/25}{Add internationalisation support. Support cover %
94 % letters spanning multiple pages.}
95 % \changes{v0.1.3}{2017/09/25}{Fix checksum issue.}
96 % \changes{v0.1.4}{2018/05/21}{Added support for Chinese.}
97 % \changes{v0.1.5}{2018/06/05}{Custom contact fields.}
98 % \changes{v0.1.6}{2018/06/17}{Added support for French.}
99 % \changes{v0.1.7}{2020/02/08}{Added support for Italian.}
100 % \changes{v0.1.8}{2020/03/15}{Upgrade to Font Awesome 5.}
101 % \changes{v0.1.9}{2021/01/21}{Added support for Spanish.}
102 % \changes{v0.1.10}{2021/12/01}{Bug fix in cover letter design for long names. %
103 % Fixes issue when counter environments were used multiple times.}
104 % \changes{v0.1.11}{2021/12/01}{Implement option to add email key to %
105 % references.}
106 % \changes{v0.1.12}{2021/12/01}{Fix alignment issue for cvMainContent* and %
107 % cvSidebar*.}
108 %
109 % \DoNotIndex{\NewDocumentCommand,\NewDocumentEnvironment}
110 %
111 % \providecommand*{\url}{\texttt}
112 %
113 % \def\fileversion{v0.1.12}
114 % \def\filedate{2021/12/01}
115 %
116 % \GetFileInfo{limecv.dtx}
117 % \title{The \textsf{limecv} document class\thanks{This document corresponds %
118 % to \textsf{limecv}~\fileversion, dated \filedate.}}
119 % \author{Olivier Pieters \\ \url{me (at) olivierpieters (dot) be}}
120 % \date{\fileversion~from \filedate}
121 %
122 % \maketitle
123 %
124 % \tableofcontents
125 %
126 % \section{Introduction}
127 %
128 % This document class is designed to facilitate easy development of
129 % curriculum vit\ae\ (CV). A set of predefined macros and environments are
130 % available for most common sections on a CV. These special elements have
131 % been designed to ease quick
132 % creation. This document class was co-designed with a business card, which
133 % can be found on GitHub: \url{https://github.com/opieters/business-card}.
134 %
135 % The design of this CV is split up in three parts, illustrated by
136 % \cref{design}. Each of these parts that make up this CV template
137 % will be detailed in the sections below.
138 %
139 % \begin{figure}[!ht]
140 % \centering
141 % \begin{tikzpicture}
142 % \draw (0,0) rectangle ++(4.20,5.94);
143 % \draw[fill=black!20] (0,0) rectangle ++(1.5,5.94);
144 % \draw (0.75,2.97) node {\LARGE 1};
145 % \draw (2.85,2.97) node {\LARGE 2};
146 % \end{tikzpicture}%
147 % \hspace{2cm}%
148 % \begin{tikzpicture}
149 % \draw (0,0) rectangle ++(-4.20,-5.94);
150 % \draw[fill=black!20] (0,0) rectangle ++(-4.2,-1.5);
151 % \end{tikzpicture}
152 % \caption{Illustation of a basic template. The image to the left depicts the
153 % actual CV: sidebar to the left (1) with main content on the right (2).
154 % The image to the right depicts the cover letter design.}
155 % \label{design}
156 % \end{figure}
157 %
158 % \section{Requirements}
159 %
160 % It is advised to use the \cvRequirement{XeLaTeX} engine. However, there is
161 % also support for \cvRequirement{LaTeX} and \cvRequirement{LuaLaTeX}. In
162 % these cases, fonts might be different than intended and side bearings will
163 % not be corrected, since only the XeLaTeX engine has access to these. In the
164 % subsequent sections, it will always be assumed that the XeLaTeX compiler is
165 % used (unless noted otherwise).
166 %
167 % Any font can be used, though by default the \cvRequirement{Fira}
168 % \footnote{\url{https://github.com/mozilla/Fira}} font is used. This should
169 % be installed and accessible by the typesetting system. If another font is
170 % desired, it can be overwritten using the |sansfont| document class options
171 % and |\cvMainFont| command. The mono spaced font can be changed by means of
172 % the |monofont| class option.
173 %
174 % \cvRequirement{FontAwesome5}\footnote{\url{http://fontawesome.io}} is the
175 % icon font used. This font should also be available and cannot be replaced by
176 % another icon font. Most modern TeX distributions ship with this font since
177 % they provide the |fontawesome5| package.
178 %
179 % \section{General Macros and Document Class Options}
180 %
181 % \DescribeMacro{\cvSetLanguage} The default language is English and can
182 % be modified using the |\cvSetLanguage| macro. Possible arguments are:
183 % |chinese|, |dutch|, |english|, |french|, |german|, |italian|, and
184 % |spanish|.
185 % If your language is not supported or you want to override a word in any
186 % supported language, you can modify the keys that hold the different
187 % section titles. These can be in the source code. The following snippet
188 % illustrates how this can be done for French:
189 %
190 % \iffalse
191 %<*example>
192 % \fi
193 \begin{lstlisting}
194 \pgfkeys{/@cv/names/education = Formations}
195 \pgfkeys{/@cv/names/skills = Comp\'etences}
196 \end{lstlisting}
197 % \iffalse
198 %</example>
199 % \fi
200 %
201 %
202 % \section{Sidebar}
203 %
204 % The sidebar should contain personal information such as your name, job title
205 % (or industry or similar), contact information, small bio, interests and
206 % language skills. Special environments and commands have been defined for
207 % each of these sections and will be described below.
208 %
209 % Everything that should be inside the sidebar should be placed in the
210 % |cvSidebar| environment. This environment is placed on the left side of the
211 % page by default. If it should be typeset on the right side, use the starred
212 % version (|cvSidebar*|)
213 %
214 % The following environments are available inside the sidebar environment:
215 % |cvProfile|, |cvContact|, |cvLanguages|, |cvInterests| and |cvProjects|.
216 %
217 % \DescribeMacro{\cvID}
218 % This command typesets a picture (in a circle) with name and position
219 % underneath it. The argument order is: |\cvID{|\meta{first name}|}{|%
220 % \meta{last name}|}{| \meta{picture location}|}{|\meta{job position}|}|.
221 % Empty fields are allowed for the third and fourth arguments. No picture and
222 % no job position will then be typeset. Example code:
223 %
224 % \iffalse
225 %<*example>
226 % \fi
227 \begin{lstlisting}
228 \cvID{John}{Doe}{profile_picture}{Broker}
229 \end{lstlisting}
230 % \iffalse
231 %</example>
232 % \fi
233 %
234 % \DescribeMacro{cvProfile}
235 % This environment contains a brief profile description or biography. No
236 % additional arguments are allowed. Example code:
237 % \iffalse
238 %<*example>
239 % \fi
240 \begin{lstlisting}
241 \begin{cvProfile}
242 A short biography goes here.
243 \end{cvProfile}
244 \end{lstlisting}
245 % \iffalse
246 %</example>
247 % \fi
248 %
249 % \DescribeMacro{cvContact}
250 % All the contact information goes here. Inside this environment, the
251 % following commands are available:
252 % \begin{itemize}
253 % \item \DescribeMacro{\cvContactAddress} |\cvContactAddress{|
254 % \meta{address}|}| typesets an address. How this address should be
255 % typeset exactly, is left to the user. The use of line breaks (|\\|) is
256 % allowed;
257 % \item \DescribeMacro{\cvContactEmail}
258 % |\cvContactEmail{|\meta{link}|}{|\meta{email address}|}| typesets an
259 % email address. The link variable should be a something like
260 % |mailto:[email protected]|. Clicking on the email address will then
261 % automatically open the default email client with this address as
262 % recipient. If the link argument is left empty, no
263 % link will be created.
264 % \item \DescribeMacro{\cvContactPhone}
265 % |\cvContactPhone{|\meta{mobile phone number}|}| typesets a mobile phone
266 % number.
267 % \item \DescribeMacro{\cvContactWebsite}
268 % |\cvContactWebsite{|\meta{link}|}{|\meta{website URL}|}| typesets a
269 % website. The link variable should be a something like
270 % |https://johndoe.tld|. Clicking on the website will then automatically
271 % open the default web browser. If the link argument is left empty, no
272 % action will be performed upon clicking on the website.
273 % \item \DescribeMacro{\cvContactGithub}
274 % |\cvContactGithub{|\meta{link}|}{|\meta{username}|}| typesets a GitHub
275 % profile. The link variable should be a valid link to the GitHub profile
276 % (for example |https://github.com/johndoe|). Clicking on the username
277 % will then automatically open the default web browser. If the link
278 % argument is left empty, no action will be performed upon clicking on the
279 % website.
280 % \item \DescribeMacro{\cvContactGitlab}
281 % |\cvContactGitlab{|\meta{link}|}{|\meta{username}|}| typesets a GitLab
282 % profile. Same considerations apply as in the |\cvContactGithub| command.
283 % \item \DescribeMacro{\cvContactLinkedin}
284 % |\cvContactLinkedin{|\meta{link}|}{|\meta{username}|}| typesets a
285 % LinkedIn profile. The link variable should be a link to your LinkedIn
286 % profile homepage (for example |https://www.linkedin.com/in/johndoe/|).
287 % Clicking on the username will then automatically open the default web
288 % browser. If the link argument is left empty, no action will be performed
289 % upon clicking on the website.
290 % \item \DescribeMacro{\cvContactTwitter}
291 % |\cvContactTwitter{|\meta{link}|}{|\meta{username}|}| typesets a Twitter
292 % profile. The link variable should direct to your Twitter profile. An
293 % example link looks as follows: |https://twitter.com/johndoe|. Clicking
294 % on the username will then automatically open the default web browser. If
295 % the link argument is left empty, no action will be performed upon
296 % clicking on the website. If the link argument is left empty, no link
297 % will be created.
298 % \item \DescribeMacro{\cvContactKeybase}
299 % |\cvContactKeybase{|\meta{link}|}{|\meta{fingerprint}|}| typesets a
300 % Keybase fingerprint (and account). The link variable should be a link to
301 % the KeyBase profile (e.g.\ |https://keybase.io/johndoe|). Clicking on
302 % the fingerprint will then automatically open the default web browser. If
303 % the link argument is left empty, no action will be performed upon
304 % clicking on the website.
305 % \end{itemize}
306 %
307 % A full example:
308 % \iffalse
309 %<*example>
310 % \fi
311 \begin{lstlisting}
312 \begin{cvContact}
313 \cvContactAddress{Some Street 78\\B-9000 Ghent\\Belgium}
314 \cvContactEmail{mailto:[email protected]}{[email protected]}
315 \cvContactPhone{+1 781 555 1212}
316 \cvContactWebsite{https://doe.tld}{doe.tld}
317 \cvContactGithub{https://github.com/johndoe}{johndoe}
318 \cvContactLinkedin{https://www.linkedin.com/in/johndoe/}{johndoe}
319 \cvContactTwitter{https://twitter.com/johndoe}{@johndoe}
320 \cvContactKeybase{https://keybase.io/johndoe}{\texttt{AAAA 5555 BBBB FFFF}}
321 \end{cvContact}
322 \end{lstlisting}
323 % \iffalse
324 %</example>
325 % \fi
326 %
327 % If you wish to add contact information that is not available by default, you
328 % can extend the command using two internal commands:
329 % |\cv@ContactTemplateLink| and |\cv@ContactTemplate|. See the source code for
330 % usage instructions.
331 %
332 % \DescribeMacro{cvLanguages}
333 % This environment is used to showcase language skills. The
334 % \DescribeMacro{\cvLanguage} |\cvLanguage{|\meta{language}|}{|
335 % \meta{skill level}|}| should be used inside this environment. The skill
336 % level is a real value with a maximum value of 5. If higher values are used,
337 % the result will not be typeset properly. An example is included below.
338 %
339 % \iffalse
340 %<*example>
341 % \fi
342 \begin{lstlisting}
343 \begin{cvLanguages}
344 \cvLanguage{English (native)}{5}
345 \cvLanguage{German (B1)}{3}
346 \cvLanguage{Spanish}{3}
347 \end{cvLanguages}
348 \end{lstlisting}
349 % \iffalse
350 %</example>
351 % \fi
352 %
353 % \DescribeMacro{cvInterests}
354 % Typeset interests (can be both professional and personal) using
355 % |cvInterests|. By default it just typesets a list of items in the long
356 % format (|long|). The short format can be activated by passing the |short|
357 % option to the environment. Inside this environment, three commands can be
358 % used: |\cvInterestsPersonal|, |\cvInterestsProfessional| and |\cvInterest|.
359 % \DescribeMacro{\cvInterestsPersonal} |\cvInterestsPersonal| and
360 % \DescribeMacro{\cvInterestsProfessional} |\cvInterestsProfessional| add
361 % optional sections inside this environment to differentiate between personal
362 % and professional interests respectively. Both macros have no options nor
363 % arguments. The \DescribeMacro{\cvInterest} |\cvInterest{|\meta{icon}|}{|
364 % \meta{interest}|}| command takes an icon and interest as arguments.
365 %
366 % Examples that illustrate the different options are depicted below:
367 %
368 % \iffalse
369 %<*example>
370 % \fi
371 \begin{lstlisting}
372 \begin{cvInterests}
373 \cvInterestsPersonal
374 \cvInterest{\faTrain}{model trains}
375 \cvInterest{\faFlask}{(applied) sciences}
376 \cvInterest{\faSuitcase}{travelling}
377 \cvInterestsProfessional
378 \cvInterest{\faGraduationCap}{machine learning}
379 \cvInterest{\faCogs}{robotics}
380 \end{cvInterests}
381 \end{lstlisting}
382 % \iffalse
383 %</example>
384 % \fi
385 %
386 % \iffalse
387 %<*example>
388 % \fi
389 \begin{lstlisting}
390 \begin{cvInterests}[short]
391 \cvInterestsPersonal
392 \cvInterest{\faTrain}{model trains}
393 \cvInterest{\faFlask}{(applied) sciences}
394 \cvInterest{\faSuitcase}{travelling}
395 \cvInterest{\faCamera}{photography}
396 \cvInterest{\faGamepad}{gaming}
397 \cvInterest{\faMusic}{music}
398 \end{cvInterests}
399 \end{lstlisting}
400 % \iffalse
401 %</example>
402 % \fi
403 %
404 % \DescribeMacro{cvProjects} If you have interesting (side) projects that are
405 % relevant for your CV, you can list them using the |cvProjects| environment.
406 % Inside this environment you can use the \DescribeMacro{\cvProject}
407 % |\cvProject[|\meta{options}|]{|\meta{name}|}{|\meta{description}|}|
408 % macro to list all your projects. The only options currently allowed in
409 % \meta{options} are an image (using |image|) and a URL (using |link|). This
410 % image must be an external file and the user must handle its size through
411 % |width| or |height|. Example usage:
412 %
413 % \iffalse
414 %<*example>
415 % \fi
416 \begin{lstlisting}
417 \begin{cvProjects}
418 \cvProject[image=clock,width=1cm]{yanic}{An IoT nixie clock.}
419 \cvProject{\texttt{limecv}}{A \LaTeX\ document class for curriculum vit\ae.}
420 \end{cvProjects}
421 \end{lstlisting}
422 % \iffalse
423 %</example>
424 % \fi
425 %
426 % It is currently not possible to extend the sidebar with additional
427 % environments. To add your own, look at the source code and create your own
428 % \LaTeX-style hack.
429 %
430 % \section{Main Content}
431 %
432 % The main content section includes details on your education, experience,
433 % skills, references and more. Several environments have been designed to suit
434 % specific needs. These will be discussed next.
435 %
436 % \DescribeMacro{cvMainContent}
437 % Everything in the main content section should be encapsulated in the
438 % |cvMainContent| environment. This environment defines four new environments:
439 % |cvEducation|, |cvExperience|, |cvSkills| and |cvReferences|. These four
440 % environments are self explanatory in terms of functionality. We will detail
441 % each of these environments.
442 %
443 % Note that |cvMainContent| also has a starred variant (|cvMainContent*|). The
444 % function is similar to |cvSidebar*|, in the sense that it places everything
445 % to the left instead of the default right location.
446 %
447 % \DescribeMacro{cvEducation}
448 % The education environment creates a timeline styled list of your education.
449 % Individual education items should be listed by means of the |\cvItem{|
450 % \meta{details}|}| macro which is available within this environment. Instead
451 % of forcing a specific layout structure, it was preferred to leave the actual
452 % mark-up to the end user. \emph{All} information concerning a single
453 % education should be passed to this single argument. However, the user is
454 % always welcome to create his own styling macro that takes multiple
455 % arguments. This is illustrated by the examples below.
456 %
457 % \iffalse
458 %<*example>
459 % \fi
460 \begin{lstlisting}[%
461 caption={\lstinline!cvEducation! \emph{without} special user mark-up
462 command.}
463 ]
464 \begin{cvEducation}
465 \cvItem{Evening class: Chinese\\
466 Some School, City. September 2015 -- June 2016\\
467 Achieved A2 language skill in Chinese (Mandarin).}
468 \cvItem{Bachelor of Science in Biochemistry and Biotechnology\\
469 University, City. September 2009 -- June 2012\\
470 General training in the basic sciences and the molecular life science.}
471 \cvItem{Master of Science in Biochemistry and Biotechnology\\
472 University, City. September 2012 -- June 2015\\
473 Acquisition of insight into and knowledge of possibilities for application in
474 the area of biochemistry and biotechnology, specific with applications in
475 biomedical application and due problem-solving reasoning skills.}
476 \end{cvEducation}
477 \end{lstlisting}
478 % \iffalse
479 %</example>
480 % \fi
481 %
482 % \iffalse
483 %<*example>
484 % \fi
485 \begin{lstlisting}[%
486 caption={\lstinline!cvEducation! \emph{with} special user mark-up
487 command.}
488 ]
489 % in preamble:
490 \newfontfamily\firaMedium{Fira Sans Medium}
491 \NewDocumentCommand{\cvEducation}{mmm}{{\firaMedium #1}\\ #2\\ \emph{#3}}
492 % in document:
493 \begin{cvEducation}
494 \cvItem{\cvEducation{Evening class: Chinese}%
495 {Some School, City. September 2015 -- June 2016}%
496 {Achieved A2 language skill in Chinese (Mandarin).}}
497 \cvItem{\cvEducation{Bachelor of Science in Biochemistry and Biotechnology}%
498 {University, City. September 2009 -- June 2012}%
499 {General training in the basic sciences and the molecular life
500 science.}}
501 \cvItem{\cvEducation{Master of Science in Biochemistry and Biotechnology}%
502 {University, City. September 2012 -- June 2015}%
503 {Acquisition of insight into and knowledge of possibilities for
504 application in the area of biochemistry and biotechnology, specific
505 with applications in biomedical application and due problem-solving
506 reasoning skills.}}
507 \end{cvEducation}
508 \end{lstlisting}
509 % \iffalse
510 %</example>
511 % \fi
512 %
513 % \DescribeMacro{cvExperience}
514 % |cvExperience| works very similar to |cvEducation|. If follows the exact
515 % same structure and has the same design philosophy where you should use
516 % |\cvItem| inside this environment to typeset the individual items in a
517 % timeline style. \Cref{cvExperience} illustrates this with an example.
518 %
519 % \iffalse
520 %<*example>
521 % \fi
522 \begin{lstlisting}[%
523 caption={\lstinline!cvExperience! code example.},
524 label=cvExperience
525 ]
526 \begin{cvExperience}
527 \cvItem{Student Job\\
528 \textsc{\selectfont Company X}, Location X. Summer 2010\\
529 Integer tincidunt dapibus consectetur. Nullam tristique aliquam luctus. Sed
530 ut ante velit. Nulla pharetra maximus lacus at elementum. Suspendisse
531 sodales consectetur metus, sit amet ultricies ipsum ultrices ut.};
532 \cvItem{Internship\\
533 \textsc{Company Y}, Location Y. June 2012 -- August 2012\\
534 Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dictum cursus
535 sapien, id eleifend mi pellentesque id. Etiam lobortis eu odio a sodales.
536 Phasellus ut dolor feugiat, lacinia lectus in, blandit metus. Fusce lacinia
537 dolor et metus gravida pulvinar sit amet et ex.};
538 \cvItem{Internship\\
539 \textsc{Company Z}, Location Z. August 2014 -- September 2014\\
540 Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi dictum cursus
541 sapien, id eleifend mi pellentesque id. Etiam lobortis eu odio a sodales.
542 Phasellus ut dolor feugiat, lacinia lectus in, blandit metus. Fusce lacinia
543 dolor et metus gravida pulvinar sit amet et ex. Suspendisse vestibulum, leo
544 malesuada molestie maximus, sem risus ornare elit, vitae sodales felis
545 elit in ipsum.};
546 \end{cvExperience}
547 \end{lstlisting}
548 % \iffalse
549 %</example>
550 % \fi
551 %
552 % \DescribeMacro{cvSkills}
553 % The skills section is contained within the |cvSkills| environment. This
554 % environment typesets your skills on a 5-level (discrete) scale. These are
555 % divided into two columns. To that end, two macros are available:
556 % |cvSkillOne| and |cvSkillTwo|. \DescribeMacro{cvSkillTwo} |cvSkillTwo{|
557 % \meta{skill level}|}{|\meta{skill}|}{|\meta{skill level}|}{|\meta{skill}|}|
558 % typesets a row of two skills. If you have an odd number of items,
559 % \DescribeMacro{cvSkillOne} |cvSkillOne{|\meta{skill level}|}{|
560 % \meta{skill}|}| should be used. An example of a skill-list can be found in
561 % \cref{cvSkills}.
562 %
563 % \iffalse
564 %<*example>
565 % \fi
566 \begin{lstlisting}[%
567 caption={Illustration of the \lstinline!cvSkills! environment.},
568 label=cvSkills
569 ]
570 \begin{cvSkills}
571 \cvSkillTwo{5}{MATLAB}{5}{\LaTeX}
572 \cvSkillTwo{4}{Python}{4}{VHDL}
573 \cvSkillTwo{4}{Microsoft Office}{4}{macOS}
574 \cvSkillOne{3}{C, C++}
575 \end{cvSkills}
576 \end{lstlisting}
577 % \iffalse
578 %</example>
579 % \fi
580 %
581 % \DescribeMacro{cvReferences}
582 % The final section is intended to list all your references. These go inside
583 % the |cvReferences| environment. The enumeration of the different items
584 % should be done using the \DescribeMacro{\cvAddReference} |\cvAddReference{|
585 % \meta{information}|}| macro. The following keys are available: |name|,
586 % |company|, |job|, |address line 1|, |address line 2|, |address line 3|,
587 % |mobile phone|, |work phone| and |email|. These are all optional arguments
588 % and will be typeset consistently between the two references per row. When
589 % adding two references, the left one should be specified first using
590 % |\cvAddReference*|. This will store the values and typeset them when adding
591 % the second reference through |\cvAddReference|. Note that |\cvAddReference|
592 % should be used if only one reference needs to be typese. \Cref{cvReferences}
593 % illustrates the usage of this environment.
594 %
595 % \emph{Important remark}: the comment after the usage of |\cvAddReference| is
596 % required! Otherwise, spacing will not be as intended.
597 %
598 % \iffalse
599 %<*example>
600 % \fi
601 \begin{lstlisting}[%
602 caption={\lstinline!cvReferences! code example.},
603 label=cvReferences]
604 \begin{cvReferences}
605 \cvAddReference{%
606 name=Jane Smith,
607 company=Company ABC Co.\ Ltd.,
608 job=Job title,
609 address line 1=Street lane 2,
610 address line 2=B-1150 Brussels,
611 mobile phone=+1 781 555 1212}% <<-- Important!!!
612 \end{cvReferences}
613 \end{lstlisting}
614 % \iffalse
615 %</example>
616 % \fi
617 %
618 % \DescribeMacro{cvList}
619 % If the above sections do not fit your needs, you can define a new section
620 % using
621 % |cvList{|\meta{environment name}|}{|\meta{storage key}|}{|\meta{icon}|}|.
622 % It is also used internally for |cvExperience| and |cvEducation|, e.g.:
623 %
624 % \iffalse
625 %<*example>
626 % \fi
627 \begin{lstlisting}[%
628 caption={\lstinline!cvList! code example.},
629 label=cvList]
630 \cvList{cvEducation}{education}{\faGraduationCap}
631 \end{lstlisting}
632 % \iffalse
633 %</example>
634 % \fi
635 %
636 % \section{Cover Letter}
637 %
638 % A final (optional) part of a CV is the cover letter. This is a fairly simple
639 % part to create design wise, but probably the hardest to write in an actual
640 % CV.
641 %
642 % \DescribeMacro{cvCoverLetter}
643 % The cover letter environment is |cvCoverLetter| and contains all the cover
644 % letter details. It will automatically add a header with your name and
645 % position based on the information filled in in |\cvID|.
646 %
647 % \DescribeMacro{\cvBeneficiary}
648 % The |\cvBeneficiary{|\meta{options}|}| macro offers a convenience wrapper to
649 % typeset the beneficiary. Possible options are |name|, |position|, |company|,
650 % |address line 1|, |address line 2| and |address line 3|. The remainder of
651 % the cover letter design is up to the user. An example design can be found in
652 % \cref{cvCoverLetter}.
653 %
654 % \DescribeMacro{\cvFullName}
655 % |\cvFullName| typeset the authors name based on the data provided in |cvID|.
656 %
657 % \iffalse
658 %<*example>
659 % \fi
660 \begin{lstlisting}[%
661 caption={\lstinline!cvCoverLetter! code example.},
662 label=cvCoverLetter]
663 \section{Cover Letter}
664
665 \begin{cvCoverLetter}
666
667 \cvBeneficiary{%
668 name=Jane Smith,
669 position=Position,
670 company=Company,
671 address line 1=Address line 1,
672 address line 2=Address line 2}
673
674 Dear Miss.\ Smith
675
676 \vspace{\baselineskip}
677 \lipsum[1-3]
678 \vspace{\margin}
679
680 \cvFullName
681
682 \end{cvCoverLetter}
683 \end{lstlisting}
684 % \iffalse
685 %</example>
686 % \fi
687 %
688 % \section{Change Style and Layout}
689 %
690 % To change the style, one can redefine the colours, lengths and TikZ styles
691 % used throughout the document class.
692 %
693 % By default the following colours are defined:
694 % \begin{itemize}
695 % \item |cvGreen| default dark green colour (hex value: {\color{cvGreen}
696 % |357F2D|})
697 % \item |cvGreenLight| light green colour, for larger shapes and backgrounds
698 % (hex value: {\color{cvGreenLight} |B8E4B3|})
699 % \item |cvDark| default text colour (hex value: {\color{cvDark} |2F3142|})
700 % \item |cvRed| currently not used (hex value: {\color{cvRed} |7F2D35|})
701 % \item |cvAccent| lighter grey shade for accented text (hex value:
702 % {\color{cvAccent} |474A65|})
703 % \end{itemize}
704 %
705 % To change these, use the code from \cref{cvColour} in the preamble:
706 %
707 % \iffalse
708 %<*example>
709 % \fi
710 \begin{lstlisting}[caption={Colour editing.},label=cvColour]
711 \definecolor{cvDark}{HTML}{000000}
712 \end{lstlisting}
713 % \iffalse
714 %</example>
715 % \fi
716 %
717 % By overwriting the following styles, one can change the appearance of
718 % multiple TikZ nodes. The following styles are available.
719 % \begin{itemize}
720 % \item |interesticon|
721 % \item |interesttext|
722 % \item |eventdottext|
723 % \item |invisibletimedot|
724 % \item |timedot|
725 % \item |eventdot|
726 % \item |contactIcon|
727 % \item |contactText|
728 % \item |headerIcon|
729 % \item |skillLevel|
730 % \item |languageText|
731 % \item |skillText|
732 % \item |progressArea|
733 % \item |progressBar|
734 % \item |sectionTitle|
735 % \item |sectionEduText|
736 % \end{itemize}
737 %
738 % Adding your own styles is easy with the code from \cref{cvTikZStyle}.
739 %
740 % \iffalse
741 %<*example>
742 % \fi
743 \begin{lstlisting}[caption={Change TikZ style.},label=cvTikZStyle]
744 \tikzset{
745 interesticon/.style = {},
746 }
747 \end{lstlisting}
748 % \iffalse
749 %</example>
750 % \fi
751
752 % Spacing used inside the document can also be modified by the user. The
753 % following lengths have been defined:
754 % \begin{itemize}
755 % \item |\cvColSep| Distance between columns of |cvSkills|.
756 % Default value: |1cm|.
757 % \item |\cvNodeSep| Not used currently.
758 % Default value: |0.75cm|.
759 % \item |\cvTimeDotDiameter| Size of the dots in a timeline.
760 % Default value: |3pt|.
761 % \item |\cvMargin| Margin around the entire page.
762 % Default value: |1cm|.
763 % \item |\cvSideWidth| Width of the sidebar.
764 % Default value: |0.3\paperwidth-\cvMargin|.
765 % \item |\cvMainWidth| Width of the main content section.
766 % Default value: |\paperwidth-4\cvMargin-\cvSideWidth|.
767 % \item |\cvTimeDotSep| Distance between timeline dot and text.
768 % Default value: |0.4cm|.
769 % \item |\cvStartEndSep| Not used.
770 % Default value: |0.3cm|.
771 % \item |\cvItemSep| Distance between |cvItem| entries.
772 % Default value: |0.4cm|.
773 % \item |\cvTableSepWidth| Distance between two columns of |cvReferences|
774 % environment. Default value: |0.3cm|.
775 % \item |\cvCoverLetterHeight| Height of the coloured bar at the top of the
776 % cover letter. Default value: |\cvSideWidth|.
777 % \item |\cvCoverLetterWidth| Width of the cover letter text. This can be used
778 % to improve the layout. Default value: |\cvMainWidth+3\cvMargin|.
779 % \item |\cvPictureWidth| Diameter of the profile picture.
780 % Default value: |4cm|.
781 % \item |\cvProgressAreaWidth| Length of a progress bar for the languages
782 % section. Default value: |5em|.
783 % \item |\cvProgressAreaHeight| Height of a progress bar for the languages
784 % section. Default value: |0.75em|.
785 % \item |\cvSectionSep| Distance between sections of the main content section.
786 % Default value: |0.6cm|.
787 % \item |\cvSectionSBSep| Distance between sections of the sidebar section.
788 % Default value: |4pt|.
789 % \item |\cvTitleLineWidth| Line width of horizontal line below section title.
790 % Default value: |2pt|.
791 % \item |\cvTitleLineSpacing| Distance from bottom of the titles of the main
792 % content section to the horizontal centre of line. Default value: |0.1cm|.
793 % \item |\cv@projectSep| Internal length.
794 % Automatically set to |\cvItemSep|.
795 % \item |\cvProjectDetailsSep| Internal spacing between details of a single
796 % project. Default value: |0.2cm|.
797 % \item |\cvInterestDetailsSep| Distance between items in case the |long|
798 % options is used for the |cvInterests| environment. Default value: |4pt|.
799 % \item |\cvContactItemSep| Distance between items in the |cvContact|
800 % environment. Default value: |5pt|.
801 % \item |\cvCoverLetterLineWidth| Line width of line below cover letter name.
802 % Default value: |3pt|.
803 % \item |\cvCoverLetterPositionSpacing| Distance between name and position in
804 % the cover letter. Default value: |10pt|.
805 % \item |\cvSBSectionLineWidth| Line width of left and right lines next to the
806 % titles of in the sidebar. Default value: |1pt|.
807 % \item |\cvCoverLetterLineSpacing| Distance between name and line below it in
808 % the cover letter. Default value: |0pt|.
809 % \item |\cvIDNameSep| Distance between first and last name.
810 % Default value: |0.1cm|.
811 % \item |\cvPositionSep| Distance before and after the position.
812 % Default value: |0.5cm|.
813 % \item |\cvSkillSep| Distance between skills.
814 % Default value: |1ex|.
815 % \item |\cvHeaderIconWidth| Automatically set, currently has no visible
816 % effect on document. Default value: |0pt|.
817 % \end{itemize}
818 %
819 % The fonts can also be changed, either by using the |sansfont| and |monofont|
820 % class options, or by using the default ways provided by \LaTeX, XeLaTeX and
821 % LuaLaTeX. Note that the |fontspec| package is already loaded by the class, so
822 % you can directly use |\setmainfont| in the preamble if you are using the
823 % XeLaTeX or LuaLaTeX engine.
824 %
825 % \section{Example}
826 %
827 % The source code of a typical CV document can be found in the examples
828 % folder. \Cref{example-cv,example-cover-letter} depict the resulting PDF
829 % documents.
830 %
831 % \begin{figure}[!ht]
832 % \IfFileExists{./mwe-xelatex.pdf}{%
833 % \includegraphics[
834 % width=\textwidth,
835 % page=1]%
836 % {mwe-xelatex.pdf}}%
837 % {No built examples found. Figure not included.}
838 % \caption{Example CV (scaled).}
839 % \label{example-cv}
840 % \end{figure}
841 %
842 % \begin{figure}[!ht]
843 % \IfFileExists{./mwe-xelatex.pdf}{%
844 % \includegraphics[
845 % width=\textwidth,
846 % page=2]%
847 % {mwe-xelatex.pdf}}%
848 % {No built examples found.}
849 % \caption{Example cover letter (scaled). Figure not included.}
850 % \label{example-cover-letter}
851 % \end{figure}
852 %
853 % \StopEventually{}
854 %
855 % \section{Implementation}
856 %
857 % \iffalse
858 %<*class>
859 % \fi
860 %
861 % \subsection{Licence}
862 %
863 % limecv.cls
864 %
865 % Copyright 2017 - 2021 by Olivier Pieters
866 %
867 % A (Xe/Lua)LaTeX document class
868 %
869 %
870 % This work may be distributed and/or modified under the
871 % conditions of the LaTeX Project Public License, either version 1.3c
872 % of this license or (at your option) any later version.
873 % The latest version of this license is in
874 % http://www.latex-project.org/lppl.txt
875 % and version 1.3c or later is part of all distributions of LaTeX
876 % version 2008-05-04 or later.
877 %
878 % This work has the LPPL maintenance status `maintained'.
879 %
880 % The Current Maintainer of this work is Olivier Pieters.
881 % Contact the maintainer at: me (at) olivierpieters (dot) be.
882 %
883 % \subsection{Intro}
884 % I have tried to create a logical structure for the source code such that
885 % related commands are grouped into a signle section. However, this was not
886 % always possible.
887 %
888 % \subsection{Package Info and Required Packages}
889 % Before starting the actual implementation, we first load all required
890 % packages and set their options.
891 %
892 % Process key-value class options using |kvoptions|:
893 % \begin{macrocode}
894 \RequirePackage{kvoptions}
895 % \end{macrocode}
896 %
897 % Define and process class options. |print| is an (unimplemened) option that
898 % should optimise the layout for printed CVs.
899 %
900 % \begin{macrocode}
901 \DeclareBoolOption[false]{print}
902 % \end{macrocode}
903 %
904 % Since the package already attempts to load the |fontspec| package, it is no
905 % longer possible to define a custom font path. This is again passible using
906 % this class option. Other options can also be set this way. However, if
907 % multiple arguments are desirale, use |\cvComma| to separate between them,
908 % since the class cannot differentiate between its own options and those it
909 % need to pass to |fontspec|.
910 %
911 % \begin{macrocode}
912 \newif\ifcv@fontPath
913 \cv@fontPathfalse
914 \DeclareStringOption{path}
915 \AddToKeyvalOption*{path}{\cv@fontPathtrue}
916 % \end{macrocode}
917 %
918 % By default, Fira fonts are used. This can be modifed using |sansfont| and
919 % |monofont|.
920 %
921 % \begin{macrocode}
922 \DeclareStringOption[Fira Sans]{sansfont}
923 \DeclareStringOption[Fira Mono]{monofont}
924 % \end{macrocode}
925 %
926 % Process the options.
927 %
928 % \begin{macrocode}
929 \ProcessKeyvalOptions*
930 % \end{macrocode}
931 %
932 % The article document class is used as a base template for this
933 % class. Options are automatically passed to the article class via this way.
934 %
935 % \begin{macrocode}
936 \DeclareOption*{%
937 \PassOptionsToClass{\CurrentOption}{article}%
938 }
939 \ProcessOptions\relax
940 \LoadClass{article}
941 % \end{macrocode}
942 %
943 % Include required packages. A short description is provided about the function
944 % of each package.
945 %
946 % Check if XeTeX is used.
947 % \begin{macrocode}
948 \RequirePackage{ifxetex}
949 % \end{macrocode}
950 % Check if LuaTeX is used.
951 % \begin{macrocode}
952 \RequirePackage{ifluatex}
953 % \end{macrocode}
954 % Advanced command definitions.
955 % \begin{macrocode}
956 \RequirePackage{xparse}
957 % \end{macrocode}
958 % Complex length calculations.
959 % \begin{macrocode}
960 \RequirePackage{calc}
961 % \end{macrocode}
962 % Colour options.
963 % \begin{macrocode}
964 \RequirePackage{xcolor}
965 % \end{macrocode}
966 % Advanced table options.
967 % \begin{macrocode}
968 \RequirePackage{tabularx}
969 % \end{macrocode}
970 % Links.
971 % \begin{macrocode}
972 \RequirePackage{hyperref}
973 \RequirePackage{url}
974 % \end{macrocode}
975 % Remove paragraph indents.
976 % \begin{macrocode}
977 \RequirePackage{parskip}
978 % \end{macrocode}
979 % String operations.
980 % \begin{macrocode}
981 \RequirePackage{xstring}
982 % \end{macrocode}
983 % Key-value parsing within document.
984 % \begin{macrocode}
985 \RequirePackage{xkeyval}
986 % \end{macrocode}
987 %
988 % \subsection{Colour Definitions}
989 %
990 % Define the custom colours used in this document.
991 %
992 % \begin{macrocode}
993 \definecolor{cvGreen}{HTML}{357F2D}
994 \definecolor{cvGreenLight}{HTML}{b8e4b3}
995 \definecolor{cvRed}{HTML}{7f2d35}
996 \definecolor{cvDark}{HTML}{2F3142}
997 \definecolor{cvAccent}{HTML}{474A65}
998 \definecolor{cvBackground}{HTML}{FFFFFF}
999 % \end{macrocode}
1000 %
1001 % \subsection{New Column Types}
1002 %
1003 % Define new table column types with fixed width.
1004 %
1005 % \begin{macrocode}
1006 \newcolumntype{L}[1]{>{\raggedright\let\newline\\%
1007 \arraybackslash\hspace{0pt}}m{#1}}
1008 \newcolumntype{C}[1]{>{\centering\let\newline\\%
1009 \arraybackslash\hspace{0pt}}m{#1}}
1010 \newcolumntype{R}[1]{>{\raggedleft\let\newline\\%
1011 \arraybackslash\hspace{0pt}}m{#1}}
1012 % \end{macrocode}
1013 %
1014 % \subsection{Helper commands}
1015 %
1016 % |\cvComma| escapes the parsing once and ca be useful to add a comma to the key
1017 % of a key-value structure.
1018 %
1019 % \begin{macro}{\cvComma}
1020 % \begin{macrocode}
1021 \NewDocumentCommand{\cvComma}{}{,}
1022 % \end{macrocode}
1023 % \end{macro}
1024 %
1025 % \begin{macro}{\@IfNoValueOrEmptyTF}
1026 % |\@IfNoValueOrEmptyTF{argument}{if empty}{if not empty}|
1027 % checks if an argument is empty.
1028 %
1029 % Based on: \url{http://tex.stackexchange.com/questions/63223}.
1030 %
1031 % \begin{macrocode}
1032 \ExplSyntaxOn
1033 \DeclareExpandableDocumentCommand{\@IfNoValueOrEmptyTF}%
1034 {mmm}{\IfNoValueTF{#1}{#2}{
1035 \tl_if_empty:nTF {#1} {#2} {#3}%
1036 }
1037 }
1038 \ExplSyntaxOff
1039 % \end{macrocode}
1040 % \end{macro}
1041 %
1042 % \begin{macro}{\ifnodedefined}
1043 %
1044 % Checks if node is defined.
1045 %
1046 % Based on: \url{https://tex.stackexchange.com/questions/37709}
1047 %
1048 % \begin{macrocode}
1049 \long\def\ifnodedefined#1#2#3{%
1050 \@ifundefined{pgf@sh@ns@#1}{#3}{#2}%
1051 }
1052 % \end{macrocode}
1053 % \end{macro}
1054 %
1055 % \subsection{Global Font Colour}
1056 %
1057 % \begin{macro}{\globalcolor}
1058 % Update global font colour.
1059 %
1060 % \begin{macrocode}
1061 \NewDocumentCommand{\globalcolor}{m}{%
1062 \color{#1}\global\let\default@color\current@color
1063 }
1064 % \end{macrocode}
1065 % \end{macro}
1066 %
1067 % Automatically set font colour.
1068 %
1069 % \begin{macrocode}
1070 \AtBeginDocument{\globalcolor{cvDark}}
1071 % \end{macrocode}
1072 %
1073 %
1074 % \subsection{TikZ Style Definitions}
1075 % TikZ is a very imporant package and forms the main reason this CV can have
1076 % the look that it does now.
1077 %
1078 % \begin{macrocode}
1079 \RequirePackage{tikz}
1080 % \end{macrocode}
1081 %
1082 % Needed to load the cover letter image in the sidebar.
1083
1084 % \begin{macrocode}
1085 \RequirePackage{graphicx}
1086 % \end{macrocode}
1087 %
1088 % A lot of additional TikZ libraries are also needed:
1089 %
1090 % \begin{macrocode}
1091 \usetikzlibrary{%
1092 calc,
1093 positioning,
1094 fit,
1095 arrows.meta,
1096 backgrounds,
1097 matrix}
1098 % \end{macrocode}
1099 %
1100 % Define all TikZ styles that are used throughout this document. All styles come
1101 % in pairs: one that the user can overwrite and one that is internally defined
1102 % and results into the default behaviour. Userdefined behaviour is always
1103 % included last, such that it can overwrite the default behaviour.
1104 %
1105 % \begin{macrocode}
1106 \tikzset{
1107 interesticon/.style = {},
1108 interesttext/.style = {},
1109 eventdottext/.style = {},
1110 invisibletimedot/.style = {},
1111 timedot/.style = {},
1112 contactIcon/.style={},
1113 contactText/.style={},
1114 headerIcon/.style={},
1115 skillLevel/.style={},
1116 languageText/.style={},
1117 skillText/.style={},
1118 progressArea/.style={},
1119 progressBar/.style={},
1120 sectionTitle/.style={},
1121 sectionEduText/.style={%
1122 },
1123 cv@interesticon/.style = {%
1124 minimum width=\cvHeaderIconWidth,
1125 interesticon
1126 },
1127 cv@interesttext/.style = {%
1128 interesttext,
1129 },
1130 cv@eventdottext/.style = {%
1131 text width=\cvMainWidth-\cvTimeDotSep,
1132 black,
1133 anchor=north west,
1134 eventdottext,
1135 },
1136 cv@invisibletimedot/.style = {%
1137 circle,
1138 minimum width=\cvTimeDotDiameter,
1139 anchor=center,
1140 invisibletimedot,
1141 },
1142 cv@timedot/.style = {%
1143 cv@invisibletimedot,
1144 draw,
1145 fill,
1146 black,
1147 timedot,
1148 },
1149 cv@contactIcon/.style={%
1150 minimum height=\baselineskip,
1151 contactIcon,
1152 },
1153 cv@contactText/.style={%
1154 minimum height=\baselineskip,
1155 text depth=0pt,
1156 contactText,
1157 },
1158 cv@headerIcon/.style={%
1159 minimum width=\cvHeaderIconWidth,
1160 anchor=center,
1161 headerIcon,
1162 },
1163 cv@skillLevel/.style={skillLevel,},
1164 cv@languageText/.style={languageText,},
1165 cv@skillText/.style={skillText,},
1166 cv@progressArea/.style={%
1167 minimum width=\cvProgressAreaWidth,
1168 minimum height=\cvProgressAreaHeight,
1169 rectangle,
1170 draw=cvBackground,
1171 cvGreen,
1172 progressArea
1173 },
1174 cv@progressBar/.style={%
1175 minimum height=\cvProgressAreaHeight,
1176 rectangle,
1177 draw,
1178 fill,
1179 cvGreen,
1180 anchor=west,
1181 progressBar
1182 },
1183 cv@sectionTitle/.style={%
1184 anchor=north west,
1185 align=left,
1186 sectionTitle,
1187 },
1188 cv@sectionEduText/.style={%
1189 cv@eventdottext,
1190 anchor=north west,
1191 sectionEduText,
1192 },
1193 }
1194 % \end{macrocode}
1195 %
1196 % \subsection{XeLaTeX/LuaLaTeX Specific Code}
1197 % The initial design features the Fira font and thus requires the |fontspec|
1198 % package. However, if the |pdflatex| compiler is used, it should still
1199 % compile. This is done in this part of the code. If needed, the relevant
1200 % packages are loaded and the options are set.
1201 %
1202 % \begin{macro}{\cv@loadFonts}
1203 % \begin{macrocode}
1204 \NewDocumentCommand{\cv@loadFonts}{}{
1205 \RequirePackage{fontspec}
1206 \RequirePackage{fontawesome5}
1207 % \end{macrocode}
1208 %
1209 % Load the fonts. By default Fira will be loaded, but this can be overwritten
1210 % by the user.
1211 %
1212 % \begin{macrocode}
1213 \setmainfont[Numbers={Monospaced}]{\limecv@sansfont}
1214 \setsansfont{\limecv@sansfont}
1215 \setmonofont{\limecv@monofont}
1216 % \end{macrocode}
1217 %
1218 % Sometimes fonts are not located in their default location, if this option is
1219 % passed, additional paths will be traversed.
1220 %
1221 % \begin{macrocode}
1222 \ifcv@fontPath
1223 \newfontfamily{\cv@FA}[Path=\limecv@path]%
1224 {Font Awesome 5 Free}
1225 \else
1226 \newfontfamily{\cv@FA}{Font Awesome 5 Free}
1227 \fi
1228 % \end{macrocode}
1229 %
1230 % The |fontawesome5| package does not feature all of the latest icons available,
1231 % so we define some of the manually since they are relevant for this CV.
1232 %
1233 % \begin{macro}{\faAddressCard}
1234 % \begin{macrocode}
1235 \ProvideDocumentCommand{\faAddressCard}{}{{\cv@FA%
1236 \symbol{"F2B9}}}
1237 % \end{macrocode}
1238 % \end{macro}
1239 % \begin{macro}{\faVcard}
1240 % \begin{macrocode}
1241 \ProvideDocumentCommand{\faVcard}{}{{\cv@FA%
1242 \symbol{"F2BB}}}
1243 % \end{macrocode}
1244 % \end{macro}
1245 % \begin{macro}{\faMicrochip}
1246 % \begin{macrocode}
1247 \ProvideDocumentCommand{\faMicrochip}{}{{\cv@FA%
1248 \symbol{"F2DB}}}
1249 % \end{macrocode}
1250 % \end{macro}
1251 %
1252 % In the future, the |fontawesome5| dependency can be dropped if a manually coded
1253 % icon is included, such as those defined in monderncv. Example:
1254 % \url{https://raw.githubusercontent.com/xdanaux/moderncv/%
1255 % master/moderncviconsmarvosym.sty}
1256 % \begin{macrocode}
1257 }
1258 % \end{macrocode}
1259 % \end{macro}
1260 %
1261 % Execute the above defined command if relevant. In the case of |pdflatex|, the
1262 % default font is set to a sans serif font.
1263 %
1264 % \begin{macrocode}
1265 \ifxetex
1266 \cv@loadFonts
1267 \else
1268 \ifluatex
1269 \cv@loadFonts
1270 \else
1271 \RequirePackage{fontawesome5}
1272 \RenewDocumentCommand{\familydefault}{}{\sfdefault}
1273 \fi
1274 \fi
1275 % \end{macrocode}
1276 %
1277 % If the XeLaTeX compiler is used and the font is compatible, it is possible to
1278 % remove the side bearing of certain characters. This is advantageous for
1279 % alignment of certain characters. However, in the case a non-compatible
1280 % compiler is used, these commands do not poerform anything.
1281 %
1282 % The code below is based on:
1283 % \url{https://tex.stackexchange.com/questions/274479} and
1284 % \url{https://tex.stackexchange.com/questions/34563}
1285 %
1286 % \begin{macrocode}
1287 \ifxetex
1288 % \end{macrocode}
1289 % \begin{macro}{\kright}
1290 % \begin{macrocode}
1291 \NewDocumentCommand{\kright}{m}{\leavevmode #1%
1292 \kern-\XeTeXglyphbounds3 \the\XeTeXcharglyph`#1 }
1293 % \end{macro}
1294 % \begin{macro}{\kleft}
1295 % \begin{macrocode}
1296 \NewDocumentCommand{\kleft}{m}{\leavevmode %
1297 \kern-\XeTeXglyphbounds1 \the\XeTeXcharglyph`#1 #1}
1298 % \end{macrocode}
1299 % \end{macro}
1300 % \begin{macrocode}
1301 \else
1302 % \end{macrocode}
1303 % \begin{macro}{\kright}
1304 % \begin{macrocode}
1305 \NewDocumentCommand{\kright}{m}{#1}
1306 % \end{macrocode}
1307 % \end{macro}
1308 % \begin{macro}{\kleft}
1309 % \begin{macrocode}
1310 \NewDocumentCommand{\kleft}{m}{#1}
1311 % \end{macrocode}
1312 % \end{macro}
1313 % \begin{macrocode}
1314 \fi
1315 % \end{macrocode}
1316 %
1317 % Extracts n-th charcter from a string
1318 % Argument order: string - character number
1319 % \begin{macrocode}
1320 \ExplSyntaxOn
1321 \cs_generate_variant:Nn\tl_item:nn {f}
1322 % \end{macrocode}
1323 % \begin{macro}{\extract}
1324 % \begin{macrocode}
1325 \DeclareExpandableDocumentCommand{\extract}{mm}{%
1326 \tl_item:fn{#1}{#2}%
1327 }
1328 % \end{macrocode}
1329 % \end{macro}
1330 % \begin{macrocode}
1331 \ExplSyntaxOff
1332 % \end{macrocode}
1333 %
1334 % Page layout
1335 %
1336 % remove page numbers
1337 % \begin{macrocode}
1338 %% \pagenumbering{gobble}
1339 % \end{macrocode}
1340 % remove all page styling
1341 % \begin{macrocode}
1342 \pagestyle{empty}
1343 % \end{macrocode}
1344 % not used
1345 % \begin{macrocode}
1346 \newlength\cvColSep
1347 \setlength\cvColSep{1cm} % 2 times column separation!
1348 % \end{macrocode}
1349 % not used
1350 % \begin{macrocode}
1351 \newlength\cvNodeSep
1352 \setlength\cvNodeSep{0.75cm}
1353 \newlength\cvTimeDotDiameter
1354 \setlength\cvTimeDotDiameter{3pt}
1355 \newlength\cvMargin
1356 \setlength\cvMargin{1cm}
1357 \newlength\cvSideWidth
1358 \setlength\cvSideWidth{0.3\paperwidth-\cvMargin}
1359 \newlength\cvMainWidth
1360 \setlength\cvMainWidth{\paperwidth-4\cvMargin-\cvSideWidth}
1361 \newlength\cvTimeDotSep
1362 \setlength\cvTimeDotSep{0.4cm}
1363 \newlength\cvStartEndSep
1364 \setlength\cvStartEndSep{0.3cm}
1365 \newlength\cvItemSep
1366 \setlength\cvItemSep{0.4cm}
1367 \newlength\cvTableSepWidth
1368 \setlength\cvTableSepWidth{0.3cm}
1369 \newlength\cvCoverLetterHeight
1370 \setlength\cvCoverLetterHeight{\cvSideWidth}
1371 \newlength\cvCoverLetterWidth
1372 \setlength\cvCoverLetterWidth{\cvMainWidth+3\cvMargin}
1373 \newlength\cvPictureWidth
1374 \setlength\cvPictureWidth{4cm}
1375 % \end{macrocode}
1376 % progress area size definition
1377 % \begin{macrocode}
1378 \newlength\cvProgressAreaWidth
1379 \setlength\cvProgressAreaWidth{5em}
1380 \newlength\cvProgressAreaHeight
1381 \setlength\cvProgressAreaHeight{0.75em}
1382 \newlength\cvSectionSep
1383 \setlength\cvSectionSep{0.6cm}
1384 \newlength\cvSectionSBSep
1385 \setlength\cvSectionSBSep{4pt}
1386 % \end{macrocode}
1387 % line width of horizontal line below section title
1388 % \begin{macrocode}
1389 \newlength\cvTitleLineWidth
1390 \setlength\cvTitleLineWidth{2pt}
1391 % \end{macrocode}
1392 % distance from bottom of text to centre of line
1393 % \begin{macrocode}
1394 \newlength\cvTitleLineSpacing
1395 \setlength\cvTitleLineSpacing{0.1cm}
1396 % \end{macrocode}
1397 % set to |\cvItemSep| by default (do not overwrite!)
1398 % \begin{macrocode}
1399 \newlength\cv@projectSep
1400 \setlength\cv@projectSep{0cm}
1401 % \end{macrocode}
1402 % internal spacing between details of a single project
1403 % \begin{macrocode}
1404 \newlength\cvProjectDetailsSep
1405 \setlength\cvProjectDetailsSep{0.2cm}
1406 \newlength\cvInterestDetailsSep
1407 \setlength\cvInterestDetailsSep{4pt}
1408 \newlength\cvContactItemSep
1409 \setlength\cvContactItemSep{5pt}
1410 % \end{macrocode}
1411 % line width of line below cover letter name
1412 % \begin{macrocode}
1413 \newlength\cvCoverLetterLineWidth
1414 \setlength\cvCoverLetterLineWidth{3pt}
1415 \newlength\cvCoverLetterPositionSpacing
1416 \setlength\cvCoverLetterPositionSpacing{10pt}
1417 \newlength\cvSBSectionLineWidth
1418 \setlength\cvSBSectionLineWidth{1pt}
1419 \newlength\cvCoverLetterLineSpacing
1420 \setlength\cvCoverLetterLineSpacing{0pt}
1421 \newlength\cvIDNameSep
1422 \setlength\cvIDNameSep{0.1cm}
1423 \newlength\cvPositionSep
1424 \setlength\cvPositionSep{0.5cm}
1425 \newlength\cvSkillSep
1426 \setlength\cvSkillSep{1ex}
1427 \newlength\cvHeaderIconWidth
1428 \setlength\cvHeaderIconWidth{10pt}
1429 % \end{macrocode}
1430 %
1431 %
1432 %------------------------------------------------------
1433 %
1434 % New styling commands
1435 %
1436 %
1437 % Style main section title
1438 % \begin{macrocode}
1439 \NewDocumentCommand{\cvSection}{m}{\Large\textbf{#1}}
1440 % \end{macrocode}
1441 % Typeset skill level
1442 % \begin{macrocode}
1443 \newcount\my@repeat@count
1444 \NewDocumentCommand{\cvSkill}{m}{%
1445 \begingroup
1446 \my@repeat@count=\z@
1447 \@whilenum\my@repeat@count<#1\do{\faCircle[solid]\advance%
1448 \my@repeat@count\@ne}%
1449 \my@repeat@count=\numexpr5-\z@\relax
1450 \@whilenum\my@repeat@count>#1\do{\faCircle[regular]\advance%
1451 \my@repeat@count\m@ne}%
1452 \endgroup
1453 }
1454 % \end{macrocode}
1455 % Create horizontal line from edge to edge for sidebar
1456 % section titles.
1457 %
1458 % Based on:
1459 % https://tex.stackexchange.com/questions/65731
1460 % Alternative:
1461 % https://tex.stackexchange.com/questions/15119
1462 % \begin{macrocode}
1463 \NewDocumentCommand{\cvhrulefill}{}{{\color{cvGreen}%
1464 \leavevmode\leaders\hrule height \cvSBSectionLineWidth\hfill\kern\z@}}
1465 \NewDocumentCommand{\ruleline}{m}{\par\noindent\raisebox{.6ex}{%
1466 \makebox[\linewidth]{\cvhrulefill\hspace{1ex}%
1467 \raisebox{-.6ex}{#1}\hspace{1ex}\cvhrulefill}}}
1468 % \end{macrocode}
1469 % Title counters
1470 % \begin{macrocode}
1471 \newcounter{cv@titlePrev}
1472 \setcounter{cv@titlePrev}{0}
1473 \newcounter{cv@titleNext}
1474 \setcounter{cv@titleNext}{1}
1475 % \end{macrocode}
1476 % Draw everything associated with main section title.
1477 % \begin{macrocode}
1478 \NewDocumentCommand{\cv@Title}{mm}{%
1479 \ifnodedefined{cv@last item \the\value{cv@lastItem}}{%
1480 \setlength\cvHeaderIconWidth\cvHeaderIconWidth%{%
1481 %\maxof{\cvHeaderIconWidth}{\widthof{\Large #2}}}%
1482 % \end{macrocode}
1483 %
1484 % \changes{v0.1.8}{2020/03/15}{For now, the |widthof| macro is not used
1485 % anymore since there is an issue with the latest version of Font Awesome 5
1486 % (5.7.0).}
1487 %
1488 % \begin{macrocode}
1489 \protected@write\@auxout{}{\global\cvHeaderIconWidth=\the\cvHeaderIconWidth}
1490 \node[%
1491 below=\cvSectionSep of cv@last item %
1492 \the\value{cv@lastItem}.south west,
1493 cv@sectionTitle]
1494 (cv@title \the\value{cv@titleNext})
1495 {\begingroup\edef\y{\endgroup%
1496 \cvSection\bgroup\noexpand\kleft{%
1497 \extract{#1}{1}}}%
1498 \y\StrGobbleLeft{#1}{1}\egroup};
1499 \node[%
1500 left=\cvTimeDotSep of cv@title \the\value{cv@titleNext},
1501 cv@headerIcon]
1502 {#2};
1503 \node[
1504 below=\cvSectionSep of cv@last item %
1505 \the\value{cv@lastItem}.south west,
1506 cv@sectionTitle]
1507 (cv@title \the\value{cv@titleNext} dummy) {%
1508 \phantom{\cvSection{Education}}};
1509 \begin{scope}[on background layer]
1510 \draw[line width=\cvTitleLineWidth,cvGreen]
1511 let \p1=(cv@title \the\value{cv@titleNext} %
1512 dummy.south west),
1513 \p2=(current page.east) in
1514 (\x1,\y1-\cvTitleLineSpacing) to (\x2,\y1-\cvTitleLineSpacing);
1515 \end{scope}
1516 }{%
1517 \node[cv@sectionTitle] at (0,0) (cv@title %
1518 \the\value{cv@titleNext})
1519 {\begingroup\edef\y{\endgroup%
1520 \cvSection\bgroup\noexpand\kleft{\extract{#1}{1}}}%
1521 \y\StrGobbleLeft{#1}{1}\egroup};
1522 \node[%
1523 left=\cvTimeDotSep of cv@title \the\value{cv@titleNext},
1524 cv@headerIcon]
1525 {#2};
1526 \node[cv@sectionTitle] at (0,0)
1527 (cv@title \the\value{cv@titleNext} dummy) {%
1528 \phantom{\cvSection{Education}}};
1529 \begin{scope}[on background layer]
1530 \draw[line width=\cvTitleLineWidth,cvGreen]
1531 let \p1=(cv@title \the\value{cv@titleNext} %
1532 dummy.south west),
1533 \p2=(current page.east) in
1534 (\x1,\y1-\cvTitleLineSpacing) to (\x2,\y1-\cvTitleLineSpacing);
1535 \end{scope}
1536 }%
1537 \stepcounter{cv@titlePrev}%
1538 \stepcounter{cv@titleNext}
1539 }
1540 % \end{macrocode}
1541 % Draw the timeline
1542 % \begin{macrocode}
1543 \NewDocumentCommand{\cv@EndSectionDraw}{}{
1544 \draw (start) to (end.center);}
1545 % \end{macrocode}
1546 % Item counters
1547 % \begin{macrocode}
1548 \newcounter{cv@itemPrev}
1549 \setcounter{cv@itemPrev}{0}
1550 \newcounter{cv@itemNext}
1551 \setcounter{cv@itemNext}{1}
1552 \newcounter{cv@lastItem}
1553 \setcounter{cv@lastItem}{1}
1554 % \end{macrocode}
1555 % List a timeline entry
1556 % \begin{macrocode}
1557 \NewDocumentCommand{\cv@definecvItem}{}{
1558 \NewDocumentCommand{\cvItem}{m}{%
1559 \ifnodedefined{item \the\value{cv@itemPrev}}{%
1560 \node[%
1561 below=\cvItemSep of item %
1562 \the\value{cv@itemPrev}.south west,
1563 cv@eventdottext]
1564 (item \the\value{cv@itemNext} header)
1565 {\phantom{Evening}};
1566 \node[%
1567 below=\cvItemSep of item %
1568 \the\value{cv@itemPrev}.south west,
1569 cv@sectionEduText]
1570 (item \the\value{cv@itemNext})
1571 {##1};
1572 \node[%
1573 left=\cvTimeDotSep of item %
1574 \the\value{cv@itemNext} header,
1575 cv@timedot]
1576 {};
1577 }{
1578 \node[%
1579 below=\cvItemSep of cv@title %
1580 \the\value{cv@titlePrev}.south west,
1581 cv@eventdottext]
1582 (item \the\value{cv@itemNext} header)
1583 {\phantom{Evening}};
1584 \node[
1585 below=\cvItemSep of cv@title %
1586 \the\value{cv@titlePrev}.south west,
1587 cv@sectionEduText]
1588 (item \the\value{cv@itemNext})
1589 {##1};
1590 \node[
1591 left=\cvTimeDotSep of item %
1592 \the\value{cv@itemNext} header,
1593 cv@timedot]
1594 (start)
1595 {};
1596 }
1597 \node[
1598 left=\cvTimeDotSep of item %
1599 \the\value{cv@itemNext}.south west,
1600 cv@invisibletimedot]
1601 (end)
1602 {};
1603 \stepcounter{cv@itemPrev}
1604 \stepcounter{cv@itemNext}
1605 }
1606 }
1607 % \end{macrocode}
1608 %
1609 %-----------------------
1610 % Language
1611 % \begin{macrocode}
1612 \pgfkeys{/@cv/names/.is family,
1613 /@cv/names/.unknown/.style = %
1614 {\pgfkeyscurrentpath/\pgfkeyscurrentname/%
1615 .initial = #1}}
1616 % \end{macrocode}
1617 % Set all title names to English (default):
1618 % \begin{macrocode}
1619 \NewDocumentCommand{\cv@setEnglish}{}{
1620 \pgfkeys{/@cv/names/profile = Profile}%
1621 \pgfkeys{/@cv/names/contact = Contact}%
1622 \pgfkeys{/@cv/names/languages = Languages}%
1623 \pgfkeys{/@cv/names/interests = Interests}%
1624 \pgfkeys{/@cv/names/professional = Professional}%
1625 \pgfkeys{/@cv/names/personal = Personal}%
1626 \pgfkeys{/@cv/names/projects = Projects}%
1627 \pgfkeys{/@cv/names/education = Education}%
1628 \pgfkeys{/@cv/names/experience = Experience}%
1629 \pgfkeys{/@cv/names/references = References}%
1630 \pgfkeys{/@cv/names/skills = Skills}%
1631 \pgfkeys{/@cv/names/publications = Publications}%
1632 }
1633 % \end{macrocode}
1634 %
1635 % Set all title names to Dutch:
1636 % \begin{macrocode}
1637 \NewDocumentCommand{\cv@setDutch}{}{
1638 \pgfkeys{/@cv/names/profile = Profiel}%
1639 \pgfkeys{/@cv/names/contact = Gegevens}%
1640 \pgfkeys{/@cv/names/languages = Talenkennis}%
1641 \pgfkeys{/@cv/names/interests = Interesses}%
1642 \pgfkeys{/@cv/names/professional = Professioneel}%
1643 \pgfkeys{/@cv/names/personal = Persoonlijk}%
1644 \pgfkeys{/@cv/names/projects = Projecten}%
1645 \pgfkeys{/@cv/names/education = Opleiding}%
1646 \pgfkeys{/@cv/names/experience = Werkervaring}%
1647 \pgfkeys{/@cv/names/references = Referenties}%
1648 \pgfkeys{/@cv/names/skills = Vaardigheden}%
1649 \pgfkeys{/@cv/names/publications = Publicaties}%
1650 }
1651 % \end{macrocode}
1652 %
1653 %
1654 % Set all title names to Chinese (Mandarin):
1655 % \begin{macrocode}
1656 \NewDocumentCommand{\cv@setChinese}{}{
1657 \pgfkeys{/@cv/names/profile = 关于我}%
1658 \pgfkeys{/@cv/names/contact = 联系我}%
1659 \pgfkeys{/@cv/names/languages = 语言能力}%
1660 \pgfkeys{/@cv/names/interests = 兴趣爱好}%
1661 \pgfkeys{/@cv/names/professional = Professional}%
1662 \pgfkeys{/@cv/names/personal = Personal}%
1663 \pgfkeys{/@cv/names/projects = 我的项目}%
1664 \pgfkeys{/@cv/names/education = 教育背景}%
1665 \pgfkeys{/@cv/names/experience = 工作经验}%
1666 \pgfkeys{/@cv/names/references = References}%
1667 \pgfkeys{/@cv/names/skills = IT技能}%
1668 \pgfkeys{/@cv/names/publications = 出版作品}%
1669 }
1670 % \end{macrocode}
1671 %
1672 %
1673 % Set all title names to French:
1674 % \begin{macrocode}
1675 \NewDocumentCommand{\cv@setFrench}{}{
1676 \pgfkeys{/@cv/names/profile = Profil}%
1677 \pgfkeys{/@cv/names/contact = Contact}%
1678 \pgfkeys{/@cv/names/languages = Langues}%
1679 \pgfkeys{/@cv/names/interests = Centres d'int\'{e}r\^{e}t}%
1680 \pgfkeys{/@cv/names/professional = Professionel}%
1681 \pgfkeys{/@cv/names/personal = Personnel}%
1682 \pgfkeys{/@cv/names/projects = Projets}%
1683 \pgfkeys{/@cv/names/education = Education}%
1684 \pgfkeys{/@cv/names/experience = Exp\'{e}riences}%
1685 \pgfkeys{/@cv/names/references = R\'{e}f\'{e}rences}%
1686 \pgfkeys{/@cv/names/skills = Comp\'{e}tences}%
1687 }
1688 % \end{macrocode}
1689 %
1690 %
1691 % Set all title names to German:
1692 % \begin{macrocode}
1693 \NewDocumentCommand{\cv@setGerman}{}{
1694 \pgfkeys{/@cv/names/profile = Profil}%
1695 \pgfkeys{/@cv/names/contact = Kontakt}%
1696 \pgfkeys{/@cv/names/languages = Sprachen}%
1697 \pgfkeys{/@cv/names/interests = Interessen}%
1698 \pgfkeys{/@cv/names/professional = Beruflich}%
1699 \pgfkeys{/@cv/names/personal = Pers\"{o}nlich}%
1700 \pgfkeys{/@cv/names/projects = Projekte}%
1701 \pgfkeys{/@cv/names/education = Ausbildung}%
1702 \pgfkeys{/@cv/names/experience = Berufliche Erfahrung}%
1703 \pgfkeys{/@cv/names/references = Referenzen}%
1704 \pgfkeys{/@cv/names/skills = Kenntnisse}%
1705 \pgfkeys{/@cv/names/publications = Ver\"{o}ffentlichungen}%
1706 }
1707 % \end{macrocode}
1708 %
1709 %
1710 % Set all title names to Italian:
1711 % \begin{macrocode}
1712 \NewDocumentCommand{\cv@setItalian}{}{
1713 \pgfkeys{/@cv/names/profile = Profilo}%
1714 \pgfkeys{/@cv/names/contact = Contatti}%
1715 \pgfkeys{/@cv/names/languages = Lingue}%
1716 \pgfkeys{/@cv/names/interests = Interessi}%
1717 \pgfkeys{/@cv/names/professional = Professionali}%
1718 \pgfkeys{/@cv/names/personal = Personali}%
1719 \pgfkeys{/@cv/names/projects = Progetti}%
1720 \pgfkeys{/@cv/names/education = Formazione}%
1721 \pgfkeys{/@cv/names/experience = Esperienze lavorative}%
1722 \pgfkeys{/@cv/names/references = Referenze}%
1723 \pgfkeys{/@cv/names/skills = Competenze}%
1724 \pgfkeys{/@cv/names/publications = Pubblicazioni}%
1725 }
1726 % \end{macrocode}
1727 %
1728 %
1729 % Set the title names to Spanish:
1730 % \begin{macrocode}
1731 \NewDocumentCommand{\cv@setSpanish}{}{
1732 \pgfkeys{/@cv/names/profile = Perfil}%
1733 \pgfkeys{/@cv/names/contact = Contacto}%
1734 \pgfkeys{/@cv/names/languages = Idiomas}%
1735 \pgfkeys{/@cv/names/interests = Intereses}%
1736 \pgfkeys{/@cv/names/professional = Profesionales}%
1737 \pgfkeys{/@cv/names/personal = Personales}%
1738 \pgfkeys{/@cv/names/projects = Proyectos}%
1739 \pgfkeys{/@cv/names/education = Formación}%
1740 \pgfkeys{/@cv/names/experience = Experiencia}%
1741 \pgfkeys{/@cv/names/skills = Habilidades}%
1742 \pgfkeys{/@cv/names/references = Referencias}%
1743 \pgfkeys{/@cv/names/publications = Publicaciones}%
1744 }
1745 % \end{macrocode}
1746 %
1747 %
1748 % Set the actual language to English. This can be overwritten by the user in the
1749 % preamble
1750 %
1751 % Define the command to change the language
1752 % \begin{macrocode}
1753 \ExplSyntaxOn
1754 \NewDocumentCommand{\cvSetLanguage}{m}{
1755 \str_case:nnF {#1}
1756 {
1757 {dutch} {\cv@setDutch}
1758 {english} {\cv@setEnglish}
1759 {french} {\cv@setFrench}
1760 {german} {\cv@setGerman}
1761 {italian} {\cv@setItalian}
1762 {spanish} {\cv@setSpanish}
1763 {chinese} {%
1764 \usepackage[BoldFont,SlantFont]{xeCJK}%
1765 \cv@setChinese%
1766 }
1767 }
1768 {\ClassError{limecv}{Unknown option `#1' for cvLanguage %
1769 macro.}{Only `english', `chinese`, `dutch`, `french`, `german`, %
1770 `italian` and `spanish` are valid options for this macro.}}
1771 }
1772 \ExplSyntaxOff
1773 \cvSetLanguage{english}
1774 % \end{macrocode}
1775 %
1776 % \begin{macrocode}
1777 % \cvSetLanguage{english}
1778 % \end{macrocode}
1779 %------------------------------------------------------
1780 %
1781 % Commands specific for cvSkills section
1782 %
1783 %
1784 % information in temporary command yes/no
1785 % \begin{macrocode}
1786 \newif\ifcv@firstskill
1787 % \end{macrocode}
1788 % temporary command that stores skill information
1789 % \begin{macrocode}
1790 \NewDocumentCommand{\cv@skillsTable}{}{}
1791 % \end{macrocode}
1792 % typeset two skills
1793 % \begin{macrocode}
1794 \NewDocumentCommand{\cvSkillTwo}{mmmm}{%
1795 \ifcv@firstskill
1796 \g@addto@macro\cv@skillsTable{\cvSkill{#1} %
1797 & #2 & \cvSkill{#3} & #4}
1798 \cv@firstskillfalse
1799 \else
1800 \g@addto@macro\cv@skillsTable{\\[\cvSkillSep] \cvSkill{#1} %
1801 & #2 & \cvSkill{#3} & #4}
1802 \fi
1803 }
1804 % \end{macrocode}
1805 % typeset one skill
1806 % \begin{macrocode}
1807 \NewDocumentCommand{\cvSkillOne}{mm}{%
1808 \ifcv@firstskill
1809 \g@addto@macro\cv@skillsTable{\cvSkill{#1} & #2}
1810 \cv@firstskillfalse
1811 \else
1812 \g@addto@macro\cv@skillsTable{\\[\cvSkillSep] \cvSkill{#1} & #2}
1813 \fi
1814 }
1815 % \end{macrocode}
1816 %------------------------------------------------------
1817 %
1818 % cvMainContent environments
1819 %
1820 %
1821 % \begin{macrocode}
1822 \NewDocumentEnvironment{cvMainContent}{}{%
1823 \stepcounter{cv@titlePrev}
1824 \stepcounter{cv@titleNext}
1825 \stepcounter{cv@itemPrev}
1826 \stepcounter{cv@itemNext}
1827 \stepcounter{cv@lastItem}
1828 \begin{tikzpicture}[%
1829 every node/.style={%
1830 inner sep=0pt,
1831 outer sep=0pt},
1832 remember picture,
1833 overlay,
1834 shift={($(current page.north west)+%
1835 (\cvSideWidth+3\cvMargin+\cvTimeDotSep,-\cvMargin)$)}]
1836 }{%
1837 \end{tikzpicture}
1838 }
1839 \NewDocumentEnvironment{cvMainContent*}{}{%
1840 \stepcounter{cv@titlePrev}
1841 \stepcounter{cv@titleNext}
1842 \stepcounter{cv@itemPrev}
1843 \stepcounter{cv@itemNext}
1844 \stepcounter{cv@lastItem}
1845 \begin{tikzpicture}[%
1846 every node/.style={
1847 inner sep=0pt,
1848 outer sep=0pt},
1849 remember picture,
1850 overlay,
1851 shift={($(current page.north west)+%
1852 (\cvMargin+\cvTimeDotSep,-\cvMargin)$)}]
1853 }{%
1854 \end{tikzpicture}%
1855 }
1856 % \end{macrocode}
1857 %------------------------------------------------------
1858 %
1859 % cvList environment: a general environment for
1860 % grouped lists. This environment is used to
1861 % generate e.g.\ |cvEducation|, |cvExperience| etc.
1862 %
1863 % \begin{macrocode}
1864 \NewDocumentCommand{\cvList}{mmm} {%
1865 \NewDocumentEnvironment{#1}{}{%
1866 \cv@Title{\pgfkeysvalueof{/@cv/names/#2}}{#3}
1867 % \end{macrocode}
1868 % insures uniqueness
1869 % \begin{macrocode}
1870 \stepcounter{cv@itemPrev}
1871 \stepcounter{cv@itemNext}
1872 \cv@definecvItem
1873 }{%
1874 \cv@EndSectionDraw
1875 \stepcounter{cv@lastItem}
1876 \draw (item \the\value{cv@itemPrev}.south west)
1877 node (cv@last item \the\value{cv@lastItem}) {};
1878 }
1879 }
1880 % \end{macrocode}
1881 %------------------------------------------------------
1882 %
1883 % cvEductation environment
1884 %
1885 % \begin{macrocode}
1886 \cvList{cvEducation}{education}{\faGraduationCap}
1887 % \end{macrocode}
1888 %------------------------------------------------------
1889 %
1890 % cvExperience environment
1891 %
1892 % \begin{macrocode}
1893 \cvList{cvExperience}{experience}{\faBriefcase}
1894 % \end{macrocode}
1895 %------------------------------------------------------
1896 %
1897 % cvSkills environment
1898 %
1899 % \begin{macrocode}
1900 \NewDocumentEnvironment{cvSkills}{}{%
1901 \cv@Title{\pgfkeysvalueof{/@cv/names/skills}}{\faStar}
1902 \global\cv@firstskilltrue
1903 \RenewDocumentCommand{\cv@skillsTable}{}{}
1904 }{%
1905 \node[
1906 below=\cvSectionSep of cv@title \the\value{cv@titlePrev}%
1907 .south west,
1908 anchor=north west] (skills) %
1909 {\begin{tabular}{@{}ll@{\hskip\cvColSep}ll@{}}%
1910 \cv@skillsTable
1911 \end{tabular}};
1912 \stepcounter{cv@lastItem}
1913 \draw (skills.south west) node %
1914 (cv@last item \the\value{cv@lastItem}) {};
1915 }
1916 % \end{macrocode}
1917 %------------------------------------------------------
1918 %
1919 % cvPublications environment
1920 %
1921 % \begin{macrocode}
1922 \cvList{cvPublications}{publications}{\faNewspaper}
1923 % \end{macrocode}
1924 %------------------------------------------------------
1925 %
1926 % cvReferences environment
1927 %
1928 % \begin{macrocode}
1929 \NewDocumentEnvironment{cvReferences}{}{%
1930 \cv@Title{\pgfkeysvalueof{/@cv/names/references}}{\faLink}
1931 \node[
1932 below=\cvSectionSep of cv@title \the\value{cv@titlePrev}.%
1933 south west,
1934 anchor=north west,
1935 ] (cv@References) \bgroup %
1936 }{%
1937 \egroup;
1938 \stepcounter{cv@lastItem}
1939 \draw ([email protected] west) node %
1940 (cv@last item \the\value{cv@lastItem}) {};
1941 }
1942 % \end{macrocode}
1943 % Key-value parsing structure
1944 % \begin{macrocode}
1945 \pgfkeys{/@cv/references/.is family,
1946 /@cv/references/.unknown/.style = %
1947 {\pgfkeyscurrentpath/\pgfkeyscurrentname/%
1948 .initial = #1}}
1949 \newif\ifcv@refName
1950 \pgfkeys{/@cv/references/name/.is if=cv@refName}
1951 \pgfkeys{/@cv/references/name=false}
1952 \newif\ifcv@refPosition
1953 \pgfkeys{/@cv/references/position/.is if=cv@refPosition}
1954 \pgfkeys{/@cv/references/position=false}
1955 \newif\ifcv@refCompany
1956 \pgfkeys{/@cv/references/company/.is if=cv@refCompany}
1957 \pgfkeys{/@cv/references/copmany=false}
1958 \newif\ifcv@refAddressLineA
1959 \pgfkeys{/@cv/references/address line 1/.is if=%
1960 cv@refAddressLineA}
1961 \pgfkeys{/@cv/references/address line 1=false}
1962 \newif\ifcv@refAddressLineB
1963 \pgfkeys{/@cv/references/address line 2/.is if=%
1964 cv@refAddressLineB}
1965 \pgfkeys{/@cv/references/address line 2=false}
1966 \newif\ifcv@refAddressLineC
1967 \pgfkeys{/@cv/references/address line 3/.is if=%
1968 cv@refAddressLineC}
1969 \pgfkeys{/@cv/references/address line 3=false}
1970 \newif\ifcv@refWorkPhone
1971 \pgfkeys{/@cv/references/work phone/.is if=%
1972 cv@refWorkPhone}
1973 \pgfkeys{/@cv/references/work phone=false}
1974 \newif\ifcv@refMobilePhone
1975 \pgfkeys{/@cv/references/mobile phone/.is if=%
1976 cv@refMobilePhone}
1977 \pgfkeys{/@cv/references/mobile phone=false}
1978 \newif\ifcv@refEmail
1979 \pgfkeys{/@cv/references/email/.is if=%
1980 cv@refEmail}
1981 \pgfkeys{/@cv/references/email=false}
1982 \newif\ifcv@refStored
1983 \pgfkeys{/@cv/references/value stored/.is if=%
1984 cv@refStored}
1985 \pgfkeys{/@cv/references/value stored=false}
1986 % \end{macrocode}
1987 %
1988 % keys
1989 % \begin{macrocode}
1990 \define@key{cvAddReferenceA}{name}{%
1991 \global\def\cv@refAName{#1}%
1992 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/name = true}}}
1993 % \end{macrocode}
1994 %
1995 %
1996 % \begin{macrocode}
1997 \define@key{cvAddReferenceA}{company}{%
1998 \global\def\cv@refACompany{#1}%
1999 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/company = true}}}
2000 % \end{macrocode}
2001 %
2002 %
2003 % \begin{macrocode}
2004 \define@key{cvAddReferenceA}{position}{%
2005 \global\def\cv@refAPosition{#1}%
2006 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/position = true}}}
2007 % \end{macrocode}
2008 %
2009 %
2010 % \begin{macrocode}
2011 \define@key{cvAddReferenceA}{address line 1}{%
2012 \global\def\cv@refAAddressLineA{#1}%
2013 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 1 = true}}}
2014 % \end{macrocode}
2015 %
2016 %
2017 % \begin{macrocode}
2018 \define@key{cvAddReferenceA}{address line 2}{%
2019 \global\def\cv@refAAddressLineB{#1}%
2020 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 2 = true}}}
2021 % \end{macrocode}
2022 %
2023 %
2024 % \begin{macrocode}
2025 \define@key{cvAddReferenceA}{address line 3}{%
2026 \global\def\cv@refAAddressLineC{#1}%
2027 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 3 = true}}}
2028 % \end{macrocode}
2029 %
2030 %
2031 % \begin{macrocode}
2032 \define@key{cvAddReferenceA}{phone work}{%
2033 \global\def\cv@refAPhoneWork{#1}%
2034 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/phone work = true}}}
2035 % \end{macrocode}
2036 %
2037 %
2038 % \begin{macrocode}
2039 \define@key{cvAddReferenceA}{mobile phone}{%
2040 \global\def\cv@refAMobilePhone{#1}%
2041 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/mobile phone = true}}}
2042 % \end{macrocode}
2043 %
2044 % \begin{macrocode}
2045 \define@key{cvAddReferenceA}{email}{%
2046 \global\def\cv@refAEmail{#1}%
2047 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/email = true}}}
2048 % \end{macrocode}
2049 %
2050 % \begin{macrocode}
2051 \define@key{cvAddReferenceB}{name}{%
2052 \global\def\cv@refBName{#1}%
2053 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/name = true}}}
2054 % \end{macrocode}
2055 %
2056 %
2057 % \begin{macrocode}
2058 \define@key{cvAddReferenceB}{company}{%
2059 \global\def\cv@refBCompany{#1}%
2060 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/company = true}}}
2061 % \end{macrocode}
2062 %
2063 %
2064 % \begin{macrocode}
2065 \define@key{cvAddReferenceB}{position}{%
2066 \global\def\cv@refBPosition{#1}%
2067 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/position = true}}}
2068 % \end{macrocode}
2069 %
2070 %
2071 % \begin{macrocode}
2072 \define@key{cvAddReferenceB}{address line 1}{%
2073 \global\def\cv@refBAddressLineA{#1}%
2074 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 1 = true}}}
2075 % \end{macrocode}
2076 %
2077 %
2078 % \begin{macrocode}
2079 \define@key{cvAddReferenceB}{address line 2}{%
2080 \global\def\cv@refBAddressLineB{#1}%
2081 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 2 = true}}}
2082 % \end{macrocode}
2083 %
2084 %
2085 % \begin{macrocode}
2086 \define@key{cvAddReferenceB}{address line 3}{%
2087 \global\def\cv@refBAddressLineC{#1}%
2088 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/address line 3 = true}}}
2089 % \end{macrocode}
2090 %
2091 %
2092 % \begin{macrocode}
2093 \define@key{cvAddReferenceB}{phone work}{%
2094 \global\def\cv@refBPhoneWork{#1}%
2095 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/phone work = true}}}
2096 % \end{macrocode}
2097 %
2098 %
2099 % \begin{macrocode}
2100 \define@key{cvAddReferenceB}{mobile phone}{%
2101 \global\def\cv@refBMobilePhone{#1}%
2102 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/mobile phone = true}}}
2103 % \end{macrocode}
2104 %
2105 %
2106 % \begin{macrocode}
2107 \define@key{cvAddReferenceB}{email}{%
2108 \global\def\cv@refBEmail{#1}%
2109 \@IfNoValueOrEmptyTF{#1}{}{\pgfkeys{/@cv/references/email = true}}}
2110 % \end{macrocode}
2111 %
2112 %
2113 % \begin{macrocode}
2114 \NewDocumentCommand{\cvAddReference}{sm}{%
2115 \IfBooleanTF{#1}{%
2116 \setkeys{cvAddReferenceA}{name=,company=,
2117 position=,address line 1=,address line 2=,
2118 address line 3=,phone work=,mobile phone=,#2}
2119 \pgfkeys{/@cv/references/name = true}%
2120 }{%
2121 \setkeys{cvAddReferenceB}{name=,company=,
2122 position=,address line 1=,address line 2=,
2123 address line 3=,phone work=,mobile phone=,#2}
2124 \ifcv@refStored%
2125 \begin{tabular}{@{}L{0.5\cvMainWidth-0.5\cvTimeDotSep%
2126 -0.5\cvTableSepWidth}@{\hskip \cvTableSepWidth}%
2127 L{0.5\cvMainWidth-0.5\cvTimeDotSep%
2128 -0.5\cvTableSepWidth}@{}}%
2129 \ifcv@refName \cv@refAName & \cv@refBName \fi %
2130 \ifcv@refCompany \\ \cv@refACompany & \cv@refBCompany \fi %
2131 \ifcv@refPosition \\ \cv@refAPosition & \cv@refBPosition \fi %
2132 \ifcv@refAddressLineA \\ \cv@refAAddressLineA & \cv@refBAddressLineA \fi %
2133 \ifcv@refAddressLineB \\ \cv@refAAddressLineB & \cv@refBAddressLineB \fi %
2134 \ifcv@refAddressLineC \\ \cv@refAAddressLineC & \cv@refBAddressLineC \fi %
2135 \ifcv@refWorkPhone \\ \cv@refAPhoneWork & \cv@refBPhoneWork \fi %
2136 \ifcv@refMobilePhone \\ \cv@refAMobilePhone & \cv@refBMobilePhone \fi %
2137 \ifcv@refEmail \\ \cv@refAEmail & \cv@refBEmail \fi %
2138 \end{tabular}%
2139 \pgfkeys{/@cv/references/value stored = false}%
2140 \else%
2141 \begin{tabular}{@{}L{0.5\cvMainWidth%
2142 -0.5\cvTimeDotSep}@{}}%
2143 \ifcv@refName \cv@refBName \fi %
2144 \ifcv@refCompany \\ \cv@refBCompany \fi %
2145 \ifcv@refPosition \\ \cv@refBPosition \fi %
2146 \ifcv@refAddressLineA \\ \cv@refBAddressLineA \fi %
2147 \ifcv@refAddressLineB \\ \cv@refBAddressLineB \fi %
2148 \ifcv@refAddressLineC \\ \cv@refBAddressLineC \fi %
2149 \ifcv@refWorkPhone \\ \cv@refBPhoneWork \fi %
2150 \ifcv@refMobilePhone \\ \cv@refBMobilePhone \fi %
2151 \ifcv@refEmail \\ \cv@refBEmail \fi %
2152 \end{tabular}%
2153 \fi%
2154 }%
2155 }
2156 % \end{macrocode}
2157 %
2158 %------------------------------------------------------
2159 %
2160 % cvSidebar environment
2161 %
2162 %
2163 % \begin{macrocode}
2164 \NewDocumentEnvironment{cvSidebar}{}{%
2165 \vspace*{\fill}
2166 \vspace*{-0.5\cvMargin}
2167 \begin{tikzpicture}[remember picture,overlay]
2168 \fill[cvGreenLight] (current page.north west) rectangle %
2169 ++(\cvSideWidth+2\cvMargin,-\paperheight);
2170 \end{tikzpicture}%
2171 \begin{minipage}{\cvSideWidth}
2172 \begin{center}
2173 }{%
2174 \end{center}
2175 \end{minipage}
2176 \vspace*{\fill}
2177 }
2178 \NewDocumentEnvironment{cvSidebar*}{}{%
2179 \vspace*{\fill}
2180 \vspace*{-0.5\cvMargin}
2181 \begin{tikzpicture}[remember picture,overlay]
2182 \fill[cvGreenLight] (current page.north east) rectangle %
2183 ++(-\cvSideWidth-2\cvMargin,-\paperheight);
2184 \end{tikzpicture}%
2185 \hspace*{\paperwidth-\cvSideWidth-2\cvMargin}%
2186 \begin{minipage}{\cvSideWidth}
2187 \begin{center}
2188 }{%
2189 \end{center}
2190 \end{minipage}
2191 \vspace*{\fill}
2192 }
2193 % \end{macrocode}
2194 %------------------------------------------------------
2195 %
2196 % cvProfile environment
2197 %
2198 % \begin{macrocode}
2199 \NewDocumentEnvironment{cvProfile}{}{%
2200 \vspace{\cvSectionSBSep}
2201 \ruleline{\pgfkeysvalueof{/@cv/names/profile}}
2202 }{%
2203 }
2204 % \end{macrocode}
2205 %------------------------------------------------------
2206 %
2207 % cvContact environment
2208 %
2209 %
2210 % \begin{macrocode}
2211 \NewDocumentCommand{\cv@ContactTemplate}{mm}{
2212 \NewDocumentCommand{#1}{m}{
2213 \ifcv@contactfirst \\ \else %
2214 \global\cv@contactfirsttrue \fi\node[cv@contactIcon]{#2};
2215 \pgfmatrixnextcell \node[cv@contactText]{##1};
2216 }
2217 }
2218 \NewDocumentCommand{\cv@ContactTemplateLink}{mm}{
2219 \NewDocumentCommand{#1}{mm}{
2220 \ifcv@contactfirst \\ \else %
2221 \global\cv@contactfirsttrue \fi\node[cv@contactIcon]{#2};
2222 \pgfmatrixnextcell \node[cv@contactText]{%
2223 \@IfNoValueOrEmptyTF{##1}{##2}{\href{##1}{##2}}};
2224 }
2225 }
2226 \NewDocumentCommand{\cvContactTemplate}{O{} mm}{
2227 \ifcv@contactfirst%
2228 \\%
2229 \else %
2230 \global\cv@contactfirsttrue %
2231 \fi %
2232 \node[cv@contactIcon]{#2};
2233 \pgfmatrixnextcell \node[cv@contactText]{%
2234 \@IfNoValueOrEmptyTF{#1}{#3}{\href{#1}{#3}}%
2235 };
2236 }
2237 \newif\ifcv@contactfirst
2238 \NewDocumentEnvironment{cvContact}{}{%
2239 \vspace{\cvSectionSBSep}
2240 \ruleline{\pgfkeysvalueof{/@cv/names/contact}}%
2241 \vspace{\cvSectionSBSep}
2242
2243 \global\cv@contactfirstfalse
2244 \cv@ContactTemplate{\cvContactAddress}{\faMapMarker}
2245 \cv@ContactTemplate{\cvContactPhone}{\faPhone}
2246
2247 \cv@ContactTemplateLink{\cvContactEmail}{\faEnvelope}
2248 \cv@ContactTemplateLink{\cvContactWebsite}{\faGlobe}
2249 \cv@ContactTemplateLink{\cvContactGithub}{\faGithub}
2250 \cv@ContactTemplateLink{\cvContactGitlab}{\faGitlab}
2251 \cv@ContactTemplateLink{\cvContactLinkedin}{\faLinkedin}
2252 \cv@ContactTemplateLink{\cvContactTwitter}{\faTwitter}
2253 \cv@ContactTemplateLink{\cvContactKeybase}{\faKey}
2254 \begin{tikzpicture}[%
2255 every node/.style={inner sep=0pt, outer sep=0pt}]
2256 \matrix [
2257 column 1/.style={anchor=center},
2258 column 2/.style={anchor=west,align=left},
2259 column sep=\cvContactItemSep,
2260 row sep=\cvContactItemSep,
2261 inner sep=0pt,
2262 outer sep=0pt] (contact) \bgroup
2263 }{%
2264 \\\egroup; % \\ required, does not compile otherwise
2265 \end{tikzpicture}%
2266 }
2267 % \end{macrocode}
2268 %------------------------------------------------------
2269 %
2270 % cvInterests environment
2271 %
2272 % \begin{macrocode}
2273 \newif\ifcv@interestLong
2274 \cv@interestLongtrue
2275 \newcounter{cv@cvInterestCounter}
2276 \setcounter{cv@cvInterestCounter}{1}
2277 \newcounter{cv@cvInterestCounterPrev}
2278 \setcounter{cv@cvInterestCounterPrev}{0}
2279 \newif\ifcv@interestContent
2280 \cv@interestContentfalse
2281 \NewDocumentCommand{\cv@TypesetTableRows}{}{}
2282 \newif\ifcv@interesttikzopen
2283 \cv@interesttikzopenfalse
2284 \NewDocumentCommand{\cv@interestClose}{}{
2285 \ifcv@interestLong
2286 \ifcv@interesttikzopen
2287 \end{tikzpicture}
2288 \global\cv@interesttikzopenfalse
2289 \fi
2290 \else
2291 \ifcv@interestContent
2292 \begin{tabular}{@{}cl@{}}
2293 \cv@TypesetTableRows
2294 \end{tabular}
2295 \fi
2296 \fi
2297 }
2298 \NewDocumentCommand{\cv@interestOpen}{}{
2299 \ifcv@interestLong
2300 \ifcv@interesttikzopen
2301 \else
2302 \cv@interesttikzopentrue
2303 \begin{tikzpicture}[%
2304 every node/.style={inner sep=0cm,outer sep=0cm}]
2305 \fi
2306 \else
2307 \global\def\cv@TypesetTableRows{}
2308 \global\cv@interestContentfalse
2309 \fi
2310 }
2311 \NewDocumentCommand{\cv@definecv@interestSection}{}{
2312 \NewDocumentCommand{\cv@interestSection}{m}{%
2313 \cv@interestClose\\
2314 \ifcv@interestContent
2315 \vspace*{2\cvSectionSBSep}
2316 \fi
2317 {\color{cvGreen}---} ##1 {\color{cvGreen}---}\\
2318 \vspace*{\cvSectionSBSep}
2319 \cv@interestOpen
2320 }
2321 }
2322 \NewDocumentCommand{\cv@definecvInterestLong}{}{
2323 \NewDocumentCommand{\cvInterest}{mm}{%
2324 \ifcv@interestContent %
2325 \node[
2326 below=\cvItemSep of cv@interest text %
2327 \the\value{cv@cvInterestCounterPrev},
2328 cv@interesticon]
2329 (cv@interest icon \the\value{cv@cvInterestCounter}) {##1};
2330 \node[
2331 below=\cvInterestDetailsSep of cv@interest icon %
2332 \the\value{cv@cvInterestCounter},
2333 cv@interesttext]
2334 (cv@interest text \the\value{cv@cvInterestCounter}) {##2};
2335 \else
2336 \cv@interestOpen
2337 \node[cv@interesticon]
2338 (cv@interest icon \the\value{cv@cvInterestCounter}) {##1};
2339 \node[
2340 below=\cvInterestDetailsSep of cv@interest icon %
2341 \the\value{cv@cvInterestCounter},
2342 cv@interesttext]
2343 (cv@interest text \the\value{cv@cvInterestCounter}) {##2};
2344 \fi
2345 \stepcounter{cv@cvInterestCounter}
2346 \stepcounter{cv@cvInterestCounterPrev}
2347 \global\cv@interestContenttrue
2348 }
2349 }
2350 \NewDocumentCommand{\cv@definecvInterestShort}{}{
2351 % \end{macrocode}
2352 % https://tex.stackexchange.com/questions/12761
2353 % \begin{macrocode}
2354 %\def\Z{\vphantom{\parbox[c]{1cm}{\Huge Something Long}}}
2355 \NewDocumentCommand{\cvInterest}{mm}{%
2356 % \end{macrocode}
2357 % parse optinal argument if present
2358 % \begin{macrocode}
2359 \g@addto@macro\cv@TypesetTableRows{##1}%
2360 \g@addto@macro\cv@TypesetTableRows{&}%
2361 \g@addto@macro\cv@TypesetTableRows{##2}%
2362 \g@addto@macro\cv@TypesetTableRows{\\[\cvInterestDetailsSep]}%
2363 \global\cv@interestContenttrue
2364 }
2365 }
2366 \ExplSyntaxOn
2367 \NewDocumentEnvironment{cvInterests}{o}{%
2368 % \end{macrocode}
2369 % set defaults
2370 % \begin{macrocode}
2371 \cv@interestLongtrue
2372 % \end{macrocode}
2373 % parse optional arguments
2374 % \begin{macrocode}
2375
2376 \@IfNoValueOrEmptyTF{#1}{}{%
2377 \str_case:nnF {#1}{
2378 {long}{\cv@interestLongtrue}
2379 {short}{\cv@interestLongfalse}
2380 }{\ClassError{limecv}{Unkown option `#1' for cvInterests %
2381 environment.}{Only `long' and `short' are valid options %
2382 for this environment.}}
2383 }
2384
2385 \stepcounter{cv@cvInterestCounter}
2386 \stepcounter{cv@cvInterestCounterPrev}
2387
2388 \cv@definecv@interestSection
2389 % \end{macrocode}
2390 % define new commands
2391 % \begin{macrocode}
2392 \NewDocumentCommand{\cvInterestsPersonal}{}{%
2393 \cv@interestSection{\faUser\ \emph{\pgfkeysvalueof{/@cv/names/personal}}}}
2394 % \end{macrocode}
2395 % \begin{macrocode}
2396 \NewDocumentCommand{\cvInterestsProfessional}{}{%
2397 \cv@interestSection{\faBriefcase\ \emph{%
2398 \pgfkeysvalueof{/@cv/names/professional}}%
2399 }}
2400 % \end{macrocode}
2401 % \begin{macrocode}
2402 \ifcv@interestLong
2403 \cv@definecvInterestLong
2404 \else
2405 \cv@definecvInterestShort
2406 \fi
2407 %%%%%%
2408 \vspace{\cvSectionSBSep}
2409 \ruleline{\pgfkeysvalueof{/@cv/names/interests}}%
2410 \vspace{\cvSectionSBSep}
2411 }{%
2412 \cv@interestClose
2413 \global\cv@interestContentfalse
2414 }
2415 \ExplSyntaxOff
2416 % \end{macrocode}
2417 %------------------------------------------------------
2418 %
2419 % cvProject environment
2420 %
2421 %
2422 % \begin{macrocode}
2423 \newif\ifcv@projectImage
2424 \cv@projectImagefalse
2425 \newif\ifcv@projectLink
2426 \cv@projectLinkfalse
2427 \newif\ifcv@projectWidth
2428 \cv@projectWidthfalse
2429 \newif\ifcv@projectHeight
2430 \cv@projectHeightfalse
2431 \newcounter{cv@projectCurrent}
2432 \setcounter{cv@projectCurrent}{1}
2433 \newcounter{cv@projectPrevious}
2434 \setcounter{cv@projectPrevious}{0}
2435 % \end{macrocode}
2436 %
2437 % \begin{macrocode}
2438 \define@key{cv@Project}{image}{%
2439 \global\def\cv@projectImage{#1}%
2440 \cv@projectImagetrue}
2441 % \end{macrocode}
2442 %
2443 %
2444 % \begin{macrocode}
2445 \define@key{cv@Project}{link}{%
2446 \global\def\cv@projectLink{#1}%
2447 \cv@projectLinktrue}
2448 % \end{macrocode}
2449 %
2450 %
2451 % \begin{macrocode}
2452 \define@key{cv@Project}{width}{%
2453 \global\def\cv@projectWidth{#1}%
2454 \cv@projectWidthtrue}
2455 % \end{macrocode}
2456 %
2457 %
2458 % \begin{macrocode}
2459 \define@key{cv@Project}{height}{%
2460 \global\def\cv@projectHeight{#1}%
2461 \cv@projectHeighttrue}
2462 \NewDocumentCommand{\cv@definecvProject}{}{
2463 \NewDocumentCommand{\cvProject}{omm}{%
2464 % \end{macrocode}
2465 % default settings
2466 % \begin{macrocode}
2467 \cv@projectImagefalse
2468 \cv@projectLinkfalse
2469 \cv@projectWidthfalse
2470 \cv@projectHeightfalse
2471 % \end{macrocode}
2472 % parse optional arguments
2473 % \begin{macrocode}
2474 \@IfNoValueOrEmptyTF{##1}{}{\setkeys{cv@Project}{##1}}
2475 \ifnodedefined{project \the\value{cv@projectPrevious} %
2476 description}{}{%
2477 \node (project \the\value{cv@projectPrevious} %
2478 description) {};
2479 }
2480 % \end{macrocode}
2481 % draw image
2482 % \begin{macrocode}
2483 \ifcv@projectImage
2484 \ifcv@projectWidth
2485 \node[below=\cv@projectSep of project %
2486 \the\value{cv@projectPrevious} description]
2487 (project \the\value{cv@projectCurrent} image)
2488 {\includegraphics[width=\cv@projectWidth]{\cv@projectImage}};
2489 \else
2490 \ifcv@projectHeight
2491 \node[below=\cv@projectSep of project %
2492 \the\value{cv@projectPrevious} description]
2493 (project \the\value{cv@projectCurrent} image)
2494 {\includegraphics[height=\cv@projectHeight]{\cv@projectImage}};
2495 \else
2496 \ClassError{limecv}{No width or height specified, %
2497 but image specified.}{Always specify the height or %
2498 width if an image is set.}
2499 \fi
2500 \fi
2501 % \end{macrocode}
2502 % draw title (and add href if specified)
2503 % \begin{macrocode}
2504 \node[%
2505 text width=\cvSideWidth,
2506 align=center,
2507 below=\cvProjectDetailsSep of project \the\value{cv@projectCurrent} %
2508 image]
2509 (project \the\value{cv@projectCurrent} title) {%
2510 \ifcv@projectLink \href{\cv@projectLink}{##2} \else ##2 \fi };
2511 \else
2512 % \end{macrocode}
2513 % draw title (and add href if specified)
2514 % \begin{macrocode}
2515 \node[below=\cv@projectSep of project %
2516 \the\value{cv@projectPrevious} description,
2517 text width=\cvSideWidth,
2518 align=center]
2519 (project \the\value{cv@projectCurrent} title) {%
2520 \ifcv@projectLink \href{\cv@projectLink}{##2} \else ##2 \fi };
2521 \fi
2522 \node[
2523 below=\cvProjectDetailsSep of project \the\value{cv@projectCurrent} title,
2524 text width=\cvSideWidth,
2525 align=center]
2526 (project \the\value{cv@projectCurrent} description) {##3};
2527
2528 \setlength\cv@projectSep\cvItemSep
2529 % \end{macrocode}
2530 % increase counter value
2531 % \begin{macrocode}
2532 \stepcounter{cv@projectCurrent}
2533 \stepcounter{cv@projectPrevious}
2534 }
2535 }
2536 % \end{macrocode}
2537 %
2538 % \begin{macrocode}
2539 \NewDocumentEnvironment{cvProjects}{}{%
2540 \vspace{\cvSectionSBSep}
2541 \ruleline{\pgfkeysvalueof{/@cv/names/projects}}%
2542 \vspace{\cvSectionSBSep}
2543 \cv@definecvProject
2544 \begin{tikzpicture}[every node/.style={inner sep=0cm,outer sep=0cm}]
2545 }{
2546 \end{tikzpicture}
2547 }
2548 % \end{macrocode}
2549 %------------------------------------------------------
2550 %
2551 % cvLanguages environment
2552 %
2553 % \begin{macrocode}
2554 \newcounter{cv@languages}
2555 \setcounter{cv@languages}{1}
2556 \pgfkeys{/@cv/languages/.is family,
2557 /@cv/languages/.unknown/.style = {%
2558 \pgfkeyscurrentpath/\pgfkeyscurrentname/.initial = #1}}
2559
2560 \newif\ifcv@languagerating
2561 \cv@languageratingtrue
2562 \NewDocumentEnvironment{cvLanguages}{ o }{%
2563 \IfNoValueTF{#1}{
2564 \NewDocumentCommand{\cvLanguage}{mm}{%
2565 {\globaldefs=1\relax\pgfkeys{%
2566 /@cv/languages/lang\the\value{cv@languages} = ##2}}
2567 \node[cv@languageText]{##1}; \pgfmatrixnextcell %
2568 \node[cv@progressArea] (cv@language \the\value{cv@languages}) {}; \\
2569 \stepcounter{cv@languages}
2570 }%
2571 \cv@languageratingtrue
2572 }{
2573 \NewDocumentCommand{\cvLanguage}{m}{%
2574 \node[cv@languageText]{##1}; \\
2575 \stepcounter{cv@languages}
2576 }%
2577 \cv@languageratingfalse
2578 }
2579 \vspace{\cvSectionSBSep}
2580 \ruleline{\pgfkeysvalueof{/@cv/names/languages}}%
2581 \vspace{\cvSectionSBSep}
2582 \begin{tikzpicture}[%
2583 every node/.style={text depth=0pt,inner sep=0pt,outer sep=0pt}]
2584 \ifcv@languagerating
2585 \matrix [%
2586 column 1/.style={anchor=east},
2587 column sep=1.5\cvSectionSBSep,
2588 row sep=1.5\cvSectionSBSep,
2589 column 2/.style={anchor=west,align=left}
2590 ] (contact) \bgroup
2591 \else
2592 \matrix [%
2593 column sep=1.5\cvSectionSBSep,
2594 row sep=1.5\cvSectionSBSep,
2595 column 2/.style={anchor=west,align=left}
2596 ] (contact) \bgroup
2597 \fi
2598 }{%
2599 \\\egroup;
2600 \ifcv@languagerating
2601 \newcounter{cv@languagelevel}
2602 \setcounter{cv@languagelevel}{1}
2603 \loop\ifnum\value{cv@languagelevel}<\value{cv@languages}
2604 \draw (cv@language \the\value{cv@languagelevel}.west) %
2605 node[%
2606 cv@progressBar,
2607 minimum width=\pgfkeysvalueof{%
2608 /@cv/languages/lang\the\value{cv@languagelevel}}em]%
2609 {};
2610 \stepcounter{cv@languagelevel}
2611 \repeat
2612 \fi
2613 \end{tikzpicture}
2614 }
2615 % \end{macrocode}
2616 %------------------------------------------------------
2617 %
2618 % cvCoverLetter environment
2619 %
2620 %
2621 %
2622 % cover letter keys
2623 % \begin{macrocode}
2624 \define@key{cvCoverLetter}{name}{%
2625 % \end{macrocode}
2626 %
2627 %
2628 % \begin{macro}{\cv@coverletterName}
2629 % \begin{macrocode}
2630 \global\def\cv@coverletterName{#1}}
2631 % \end{macrocode}
2632 % \end{macro}
2633 %
2634 %
2635 % \begin{macrocode}
2636 \define@key{cvCoverLetter}{company}{%
2637 % \end{macrocode}
2638 %
2639 %
2640 % \begin{macro}{\cv@coverletterCompany}
2641 % \begin{macrocode}
2642 \global\def\cv@coverletterCompany{#1}}
2643 % \end{macrocode}
2644 % \end{macro}
2645 %
2646 %
2647
2648 % \begin{macrocode}
2649 \define@key{cvCoverLetter}{position}{%
2650 % \end{macrocode}
2651 %
2652 %
2653 % \begin{macro}{\cv@coverletterPosition}
2654 % \begin{macrocode}
2655 \global\def\cv@coverletterPosition{#1}}
2656 % \end{macrocode}
2657 % \end{macro}
2658 %
2659 %
2660 % \begin{macrocode}
2661 \define@key{cvCoverLetter}{address line 1}{%
2662 % \end{macrocode}
2663 %
2664 %
2665 % \begin{macro}{\cv@coverletterAddressLineA}
2666 % \begin{macrocode}
2667 \global\def\cv@coverletterAddressLineA{#1}}
2668 % \end{macrocode}
2669 % \end{macro}
2670 %
2671 %
2672 % \begin{macrocode}
2673 \define@key{cvCoverLetter}{address line 2}{%
2674 % \end{macrocode}
2675 %
2676 %
2677 % \begin{macro}{\cv@coverletterAddressLineB}
2678 % \begin{macrocode}
2679 \global\def\cv@coverletterAddressLineB{#1}}
2680 % \end{macrocode}
2681 % \end{macro}
2682 %
2683 %
2684 % \begin{macrocode}
2685 \define@key{cvCoverLetter}{address line 3}{%
2686 % \end{macrocode}
2687 %
2688 %
2689 % \begin{macro}{\cv@coverletterAddressLineC}
2690 % \begin{macrocode}
2691 \global\def\cv@coverletterAddressLineC{#1}}
2692 \NewDocumentCommand{\cv@definecvBeneficiary}{}{
2693 \NewDocumentCommand{\cvBeneficiary}{m}{%
2694 \setkeys{cvCoverLetter}{name={},company={},
2695 position={},address line 1={},address line 2={},
2696 address line 3={},##1}
2697 \begin{tabular}{@{}l}
2698 \@IfNoValueOrEmptyTF{%
2699 \cv@coverletterName}{}{%
2700 \MakeUppercase{\cv@coverletterName}} %
2701 \@IfNoValueOrEmptyTF{%
2702 \cv@coverletterCompany}{}{\\ %
2703 \cv@coverletterCompany} %
2704 \@IfNoValueOrEmptyTF{%
2705 \cv@coverletterPosition}{}{\\ %
2706 \cv@coverletterPosition} %
2707 \@IfNoValueOrEmptyTF{%
2708 \cv@coverletterAddressLineA}{}{\\ %
2709 \cv@coverletterAddressLineA} %
2710 \@IfNoValueOrEmptyTF{%
2711 \cv@coverletterAddressLineB}{}{\\ %
2712 \cv@coverletterAddressLineB} %
2713 \@IfNoValueOrEmptyTF{%
2714 \cv@coverletterAddressLineC}{}{\\ %
2715 \cv@coverletterAddressLineC} %
2716 \end{tabular}%
2717 \vspace{\cvMargin}
2718 }
2719 }
2720 % \end{macrocode}
2721 % \end{macro}
2722 %
2723 % \begin{macrocode}
2724 \NewDocumentCommand{\cv@definecvFullName}{}{
2725 \NewDocumentCommand{\cvFullName}{}{%
2726 \pgfkeysvalueof{/@cv/info/first name} %
2727 \pgfkeysvalueof{/@cv/info/last name}
2728 }
2729 }
2730 \NewDocumentEnvironment{cvCoverLetter}{}{%
2731 \newgeometry{textwidth=\cvCoverLetterWidth,noheadfoot}
2732 \begin{tikzpicture}[%
2733 remember picture,
2734 overlay,
2735 every node/.style={inner sep=0cm,outer sep=0cm}]
2736 % \end{macrocode}
2737 % draw green background
2738 % \begin{macrocode}
2739 \begin{scope}[on background layer]
2740 \fill[cvGreenLight] (current page.north west) rectangle %
2741 ++(\paperwidth,-\cvCoverLetterHeight);
2742 \end{scope}
2743 \draw (current page.north east) %
2744 ++(-0.5\paperwidth+0.5\cvCoverLetterWidth,
2745 -\cvCoverLetterHeight/2) node (cv@h7) {};
2746 \node[%
2747 anchor=east,
2748 align=flush right,
2749 text width=\textwidth] at (cv@h7) (cv cover letter name){%
2750 \fontsize{50}{60}\selectfont
2751 % \end{macrocode}
2752 % trick to expand argument such that `kleft` sees an
2753 % alphabetic constant (i.e. a single letter)
2754 % \begin{macrocode}
2755 \begingroup\edef\y{\endgroup%
2756 \noexpand\kleft{\cv@FirstNameLetter}}%
2757 \y
2758 \StrGobbleLeft{\pgfkeysvalueof{/@cv/info/first name}}{1}\space
2759 \StrGobbleRight{\pgfkeysvalueof{/@cv/info/last name}}{1}
2760 % \end{macrocode}
2761 % same trick
2762 % trick to expand argument such that `kleft` sees an
2763 % alphabetic constant (i.e. a single letter)
2764 % \begin{macrocode}
2765 \begingroup\edef\y{\endgroup%
2766 \noexpand\kright{\cv@LastNameLetter}}%
2767 \y
2768 };
2769 \node[%
2770 align=right,
2771 cvAccent,
2772 below=\cvCoverLetterPositionSpacing of cv cover letter name.south east,
2773 anchor=north east]{%
2774 \StrGobbleRight{\pgfkeysvalueof{/@cv/info/position}}{1}
2775 \begingroup\edef\y{\endgroup%
2776 \noexpand\kright{\cv@PositionLetter}}%
2777 \y};
2778
2779 \begin{scope}[on background layer]
2780 \draw[line width=\cvCoverLetterLineWidth,cvGreen]
2781 ($(cv cover letter name.south west)+(0,-\cvCoverLetterLineSpacing)$) to
2782 ($(cv cover letter name.south east)+(0,-\cvCoverLetterLineSpacing)$);
2783 \end{scope}
2784 \end{tikzpicture}
2785 \vspace{\dimexpr\cvCoverLetterHeight-1in-\topmargin\relax}
2786
2787 \today
2788
2789 \vspace{\baselineskip}
2790 \cv@definecvBeneficiary
2791 \cv@definecvFullName
2792 }{%
2793 \restoregeometry
2794 }
2795 % \end{macrocode}
2796 %
2797 %
2798 %------------------------------------------------------
2799 %
2800 % cvID macro
2801 %
2802 %
2803 % \begin{macrocode}
2804 \pgfkeys{/@cv/info/.is family,
2805 /@cv/info/.unknown/.style = %
2806 {\pgfkeyscurrentpath/\pgfkeyscurrentname/%
2807 .initial = #1}}
2808 % \end{macrocode}
2809 % first name, second name, picture, position
2810 % \begin{macrocode}
2811 \NewDocumentCommand{\cvID}{mmmm}{
2812 \@IfNoValueOrEmptyTF{#3}{}{
2813 \begin{tikzpicture}
2814 \node[
2815 circle,
2816 text=white,
2817 minimum size=\cvPictureWidth,
2818 path picture={
2819 \node at (path picture bounding box.center){
2820 \includegraphics[width=\cvPictureWidth]{#3}
2821 };
2822 }]
2823 {};
2824 \end{tikzpicture}\\
2825 }
2826 {\LARGE
2827 \vspace{\cvIDNameSep}
2828 \color{cvAccent} #1
2829 \vspace{\cvIDNameSep}
2830 \color{cvAccent} #2}
2831
2832 \vspace{\cvPositionSep}
2833
2834 \@IfNoValueOrEmptyTF{#4}{}{\color{cvAccent} #4}
2835
2836 \vspace{\cvPositionSep}
2837 {\globaldefs=1\relax\pgfkeys{/@cv/info/first name = %
2838 #1}\def\cv@FirstNameLetter{\extract{#1}{1}}}
2839 {\globaldefs=1\relax\pgfkeys{/@cv/info/last name = %
2840 #2}\def\cv@LastNameLetter{\extract{#2}{-1}}}
2841 {\globaldefs=1\relax\pgfkeys{/@cv/info/position = %
2842 #4}\def\cv@PositionLetter{\extract{#4}{-1}}}
2843 }
2844 % \end{macrocode}
2845
2846 %
2847 % \iffalse
2848 %</class>
2849 % \fi
2850 %
2851 % \Finale
2852 \endinput
2853