add some helper macros

This commit is contained in:
Posquit0.BJ 2016-01-30 18:35:09 +09:00
parent 531ee35707
commit b9b981d395

View file

@ -365,7 +365,8 @@
%------------------------------------------------------------------------------- %-------------------------------------------------------------------------------
% Commands for extra % Commands for extra
%------------------------------------------------------------------------------- %-------------------------------------------------------------------------------
% Define helper macros a user can change easily in header %% Define helper macros a user can change easily
% Header
\newcommand{\acvHeaderNameDelim}{\space} \newcommand{\acvHeaderNameDelim}{\space}
\newcommand{\acvHeaderAfterNameSkip}{.4mm} \newcommand{\acvHeaderAfterNameSkip}{.4mm}
\newcommand{\acvHeaderAfterPositionSkip}{.4mm} \newcommand{\acvHeaderAfterPositionSkip}{.4mm}
@ -375,6 +376,11 @@
\newcommand{\acvHeaderAfterSocialSkip}{6mm} \newcommand{\acvHeaderAfterSocialSkip}{6mm}
\newcommand{\acvHeaderAfterQuoteSkip}{5mm} \newcommand{\acvHeaderAfterQuoteSkip}{5mm}
% Others
\newcommand{\acvSectionTopSkip}{3mm}
\newcommand{\acvEntryTopSkip}{2.5mm}
%------------------------------------------------------------------------------- %-------------------------------------------------------------------------------
% Commands for utilities % Commands for utilities
%------------------------------------------------------------------------------- %-------------------------------------------------------------------------------
@ -483,18 +489,17 @@
% Define a section for CV % Define a section for CV
% Usage: \cvsection{<section-title>} % Usage: \cvsection{<section-title>}
\newcommand{\cvsection}[1]{% \newcommand{\cvsection}[1]{%
\par\addvspace{1.5ex} \vspace{\acvSectionTopSkip}
\phantomsection{}
\sectionstyle{#1} \sectionstyle{#1}
\phantomsection
\color{gray}\vhrulefill{0.9pt} \color{gray}\vhrulefill{0.9pt}
\par\nobreak\addvspace{1ex}
} }
% Define a subsection for CV % Define a subsection for CV
% Usage: \cvsubsection{<subsection-title>} % Usage: \cvsubsection{<subsection-title>}
\newcommand{\cvsubsection}[1]{% \newcommand{\cvsubsection}[1]{%
\phantomsection{}
\subsectionstyle{#1} \subsectionstyle{#1}
\phantomsection
} }
% Define a paragraph for CV % Define a paragraph for CV
@ -515,6 +520,8 @@
% Define an entry of cv information % Define an entry of cv information
% Usage: \cventry{<position>}{<title>}{<location>}{<date>}{<description>} % Usage: \cventry{<position>}{<title>}{<location>}{<date>}{<description>}
\newcommand*{\cventry}[5]{% \newcommand*{\cventry}[5]{%
\vspace{\acvEntryTopSkip}
\vspace{-2.0mm}
\setlength\tabcolsep{0pt} \setlength\tabcolsep{0pt}
\setlength{\extrarowheight}{0pt} \setlength{\extrarowheight}{0pt}
\begin{tabular*}{\textwidth}{@{\extracolsep{\fill}} L{\textwidth - 4.5cm} R{4.5cm}} \begin{tabular*}{\textwidth}{@{\extracolsep{\fill}} L{\textwidth - 4.5cm} R{4.5cm}}
@ -522,8 +529,8 @@
{\entrypositionstyle{#1} & \entrydatestyle{#4} \\} {\entrypositionstyle{#1} & \entrydatestyle{#4} \\}
{\entrytitlestyle{#2} & \entrylocationstyle{#3} \\ {\entrytitlestyle{#2} & \entrylocationstyle{#3} \\
\entrypositionstyle{#1} & \entrydatestyle{#4} \\} \entrypositionstyle{#1} & \entrydatestyle{#4} \\}
\multicolumn{2}{L{\textwidth}}{\descriptionstyle{#5}} \\ \multicolumn{2}{L{\textwidth}}{\descriptionstyle{#5}}
\end{tabular*} \end{tabular*}%
} }
% Define an environment for cvsubentry % Define an environment for cvsubentry
@ -584,7 +591,7 @@
% Define an environment for cvitems(for cventry) % Define an environment for cvitems(for cventry)
\newenvironment{cvitems}{% \newenvironment{cvitems}{%
\vspace{-4mm} \vspace{-4.0mm}
\begin{justify} \begin{justify}
\begin{itemize}[leftmargin=2ex, nosep, noitemsep] \begin{itemize}[leftmargin=2ex, nosep, noitemsep]
\setlength{\parskip}{0pt} \setlength{\parskip}{0pt}
@ -592,7 +599,7 @@
}{% }{%
\end{itemize} \end{itemize}
\end{justify} \end{justify}
\vspace{-2mm} \vspace{-4.0mm}
} }