SHARE
TWEET

Untitled

a guest Jun 18th, 2019 51 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. % -- Encoding UTF-8 without BOM
  2.  
  3. ProvidesClass{cv-style}[2015/02/27 CV class]
  4. NeedsTeXFormat{LaTeX2e}
  5.  
  6. DeclareOption{espanol}{def@cv@espanol{}}
  7. DeclareOption{print}{def@cv@print{}}
  8. DeclareOption*{%
  9.   PassOptionsToClass{CurrentOption}{article}%
  10. }
  11. ProcessOptionsrelax
  12. LoadClass{article}
  13.  
  14. %----------------------------------------------------------------------------------------
  15. % Colors %
  16. %----------------------------------------------------------------------------------------
  17.  
  18. RequirePackage{xcolor}
  19.  
  20. definecolor{white}{RGB}{255,255,255}
  21.  
  22. definecolor{darkgray}{HTML}{333333}
  23. definecolor{gray}{HTML}{4D4D4D}
  24. definecolor{lightgray}{HTML}{999999}
  25.  
  26. definecolor{blue}{HTML}{66D9EE}
  27. definecolor{red}{HTML}{FA2772}
  28. definecolor{orange}{HTML}{FE9720}
  29. definecolor{green}{HTML}{A7E22E}
  30. definecolor{purple}{HTML}{9358FE}
  31. definecolor{aquamarine}{HTML}{36AF90}
  32.  
  33. definecolor{date}{HTML}{A4A4A4}
  34.  
  35. ifdefined@cv@print
  36.   colorlet{blue}{gray}
  37.   colorlet{red}{gray}
  38.   colorlet{orange}{gray}
  39.   colorlet{green}{gray}
  40.   colorlet{purple}{gray}
  41.   colorlet{aquamarine}{gray}
  42.   colorlet{fillheader}{white}
  43.   colorlet{header}{gray}
  44. else
  45.   colorlet{fillheader}{gray}
  46.   colorlet{header}{white}
  47. fi
  48. colorlet{textcolor}{gray}
  49. colorlet{headercolor}{gray}
  50.  
  51. %----------------------------------------------------------------------------------------
  52. % Fonts %
  53. %----------------------------------------------------------------------------------------
  54.  
  55. RequirePackage[quiet]{fontspec}
  56. RequirePackage{unicode-math}
  57.  
  58. newfontfamilybodyfont{Computer
  59.  Modern}
  60. newfontfamilybodyfontit{Computer Modern}
  61. newfontfamilythinfont{Computer Modern}
  62. newfontfamilyheadingfont{Computer Modern}
  63.  
  64. defaultfontfeatures{Mapping=tex-text}
  65. setmainfont[Mapping=tex-text, Color=textcolor]{Computer Modern}
  66.  
  67. newcommand{italica}[1]{%
  68.     {color{gray}bodyfontit #1}%
  69. }
  70.  
  71. %----------------------------------------------------------------------------------------
  72. % Header %
  73. %----------------------------------------------------------------------------------------
  74.  
  75. RequirePackage{tikz}
  76.  
  77. newcommand{header}[2]{%
  78.   begin{tikzpicture}[remember picture,overlay]
  79.     node [rectangle, fill=fillheader, anchor=north, minimum width=paperwidth, minimum height=2cm] (box) at (current page.north){};
  80.     node [anchor=center] (name) at (box) {%
  81.       fontsize{40pt}{65pt}color{header}%
  82.       {thinfont #1}{bodyfont  #2}
  83.     };
  84.   end{tikzpicture}
  85.   vspace{1cm}
  86.   vspace{-2parskip}
  87. }
  88.  
  89. %----------------------------------------------------------------------------------------
  90. %   Last updated command %
  91. %----------------------------------------------------------------------------------------
  92.  
  93. RequirePackage[absolute,overlay]{textpos}
  94. RequirePackage{polyglossia}
  95.  
  96. newcommand{sethyphenation}[3][]{%
  97.   sbox0{begin{otherlanguage}[#1]{#2}
  98.     hyphenation{#3}end{otherlanguage}}}
  99. %sethyphenation[<options>]{<language>}{<list of words separated by spaces>}
  100.  
  101. ifdefined@cv@espanol
  102.   setdefaultlanguage{spanish}
  103.   deflastupdatedtext{Última Actualización el}
  104. else
  105.   setdefaultlanguage[variant=british]{english}
  106.   deflastupdatedtext{Last Updated on}
  107. fi
  108.  
  109. setlength{TPHorizModule}{0.01paperwidth}
  110. setlength{TPVertModule}{0.01paperwidth}
  111.  
  112. newcommand{lastupdated}{
  113.   begin{textblock}{10}(11.3, 0.05)
  114.     raggedleft
  115.     fontsize{8pt}{10pt}color{date}thinfont
  116.     lastupdatedtext{} today
  117.   end{textblock}}
  118.  
  119. %----------------------------------------------------------------------------------------
  120. % Structure %
  121. %----------------------------------------------------------------------------------------
  122. RequirePackage{parskip}
  123.  
  124. newcounter{colorCounter}
  125. def@sectioncolor#1#2#3{%
  126.   {%
  127.     color{%
  128.       ifcasevalue{colorCounter}%
  129.         blueor%
  130.         redor%
  131.         orangeor%
  132.         greenor%
  133.         purpleor%
  134.         aquamarineelse%
  135.         headercolorfi%
  136.     } #1#2#3%
  137.   }%
  138.   stepcounter{colorCounter}%
  139. }
  140.  
  141. renewcommand{section}[1]{
  142.   {parvspace{parskip}
  143.   {%
  144.     LARGEheadingfontcolor{headercolor}%
  145.     @sectioncolor #1%
  146.   }
  147.   parvspace{parskip}}
  148. }
  149.  
  150. renewcommand{subsection}[2]{
  151.   parvspace{.5parskip}%
  152.   Largeheadingfontcolor{headercolor} #2%
  153.   parvspace{.25parskip}%
  154. }
  155.  
  156. newcommand{jobtitle}[1]{%
  157.     {color{gray}bodyfontit #1}%
  158. }
  159.  
  160. pagestyle{empty}
  161.  
  162. %----------------------------------------------------------------------------------------
  163. % List environment %
  164. %----------------------------------------------------------------------------------------
  165.  
  166. setlength{tabcolsep}{0pt}
  167. newenvironment{entrylist}{%
  168.   begin{tabular*}{textwidth}{@{extracolsep{fill}}ll}
  169. }{%
  170.   end{tabular*}
  171. }
  172. renewcommand{bfseries}{headingfontcolor{headercolor}}
  173. newcommand{entry}[4]{%
  174.   #1&parbox[t]{12.8cm}{%
  175.     textbf{#2}%
  176.     hfill%
  177.     {footnotesizeaddfontfeature{Color=lightgray} #3}\%
  178.     #4vspace{parsep}%
  179.   }\}
  180.  
  181. %----------------------------------------------------------------------------------------
  182. % Side block %
  183. %----------------------------------------------------------------------------------------
  184.  
  185.  
  186. setlength{TPHorizModule}{1cm}
  187. setlength{TPVertModule}{1cm}
  188. newenvironment{aside}{%
  189.   letoldsectionsection
  190.   renewcommand{section}[1]{
  191.     parvspace{baselineskip}{Largeheadingfontcolor{headercolor} ##1}
  192.   }
  193.   begin{textblock}{3.6}(1, 1.87)
  194.   begin{flushright}
  195.   obeycr
  196. }{%
  197.   restorecr
  198.   end{flushright}
  199.   end{textblock}
  200.   letsectionoldsection
  201. }
  202.  
  203. %----------------------------------------------------------------------------------------
  204. % Other tweaks %
  205. %----------------------------------------------------------------------------------------
  206.  
  207. RequirePackage[left=5.6cm,top=1cm,right=1cm,bottom=1cm,nohead,nofoot]{geometry}
  208. RequirePackage{hyperref}
  209. hypersetup{
  210.     pdftitle=CV/Resume textbar{} Alejandro Pérez Londoño,
  211.     pdfauthor=Alejandro Pérez Londoño,
  212.     pdfsubject=CV/Resume%
  213.     }
  214.      
  215. % -- Encoding UTF-8 without BOM
  216. % -- XeLaTeX => PDF (BIBER)
  217. documentclass{cv-style}
  218. RequirePackage{unicode-math}
  219.  
  220.  
  221. begin{document}
  222. header{My}{Name}
  223. begin{aside}
  224. %
  225. section{contact}
  226. 123 Broadway
  227. City, State 050022
  228. Country
  229. ~
  230. +0 (000) 111 1111
  231. +0 (000) 111 1112
  232. ~
  233. myemailistoolong@gmail.com
  234. mywebsitetoo.wordpress.com
  235. %
  236. end{aside}
  237. %
  238. section{skills}
  239.   vspace{-0.2cm}
  240.  
  241. Skill 1, skill 2, skill 3, skill 4, skill 5.
  242.  
  243. section{education}
  244. begin{entrylist}
  245. %------------------------------------------------
  246. entry
  247. {2010--2011}
  248. {M.Sc. {normalfont in Economics [Grade]}}
  249. {University}
  250. {vspace{-0.3cm}}
  251. %------------------------------------------------
  252. entry
  253. {2004--2009}
  254. {B.Eng. {normalfont in Engineering Management [Grade]}}
  255. {University}
  256. {(Emphasis in ...)}
  257. %------------------------------------------------
  258. end{entrylist}
  259.  
  260.  
  261. end{document}
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top