add working cvmatrix for all styles but fancy

This commit is contained in:
David 2021-01-17 00:23:16 +01:00
commit fa003e1738
6 changed files with 393 additions and 15 deletions

View file

@ -87,6 +87,9 @@
% used by \cvlistdoubleitem % used by \cvlistdoubleitem
\@initializelength{\listdoubleitemcolumnwidth} \@initializelength{\listdoubleitemcolumnwidth}
%% include moderncv Skillmatrix code
\input{moderncvbodyiiiskillmatrix.sty}
% commands % commands
\renewcommand*{\recomputecvbodylengths}{% \renewcommand*{\recomputecvbodylengths}{%
% body lengths % body lengths
@ -96,6 +99,7 @@
\setlength{\doubleitemcolumnwidth}{0.5\doubleitemcolumnwidth}% \setlength{\doubleitemcolumnwidth}{0.5\doubleitemcolumnwidth}%
\setlength{\listdoubleitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth-\separatorcolumnwidth-\listitemsymbolwidth}% \setlength{\listdoubleitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth-\separatorcolumnwidth-\listitemsymbolwidth}%
\setlength{\listdoubleitemcolumnwidth}{0.5\listdoubleitemcolumnwidth}% \setlength{\listdoubleitemcolumnwidth}{0.5\listdoubleitemcolumnwidth}%
\recomputecvskillmatrixlengths
% regular lengths % regular lengths
\setlength{\parskip}{0\p@}} \setlength{\parskip}{0\p@}}

View file

@ -0,0 +1,124 @@
% some packages required for this code
\RequirePackage{tikz}
% needed for the dashed lines
\RequirePackage{arydshln}
%%% The code for the Skilllevel illustration with the little boxes.
% This is idea stolen from the limecv package
\@initializelength{\cvSkillRectangleSize}
\setlength{\cvSkillRectangleSize}{1.2ex}
\newcount\my@repeat@count
\NewDocumentCommand{\cvSkill}{m}{%
\begingroup
\my@repeat@count=\z@
\@whilenum\my@repeat@count<#1\do{\tikz\filldraw[color1] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\@ne\,}%
\my@repeat@count=\numexpr5-\z@\relax
\@whilenum\my@repeat@count>#1\do{\tikz\filldraw[color2!30] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\m@ne\,}%
\endgroup
}
\@initializelength{\cvskillwidth}
\@initializelength{\cvskilldescriptorwidth}
\@initializelength{\cvskilllegenddescriptorwidth}
\@initializelength{\cvskillexperiencewidth}
\@initializelength{\skillmatrixcolumnwidth}
\@initializelength{\skillmatrixcommentwidth}
\@initializelength{\skillmatrixcommentpadding}
\@initializelength{\skillmatrixhintscolumnwidth}
\@initializelength{\skilllegendhintscolumnwidth}
\NewDocumentCommand{\recomputecvskillmatrixlengths}{}{%
\setlength{\skillmatrixcommentpadding}{1ex}
\setlength{\separatorcolumnwidth}{\skillmatrixcommentpadding}
\setlength{\skillmatrixhintscolumnwidth}{\widthof{``Languages''}}
\setlength{\skilllegendhintscolumnwidth}{\skillmatrixhintscolumnwidth} %0.175\textwidth
% \setlength{\skillmatrixhintscolumnwidth}{0.14\textwidth} %0.175\textwidth
\setlength{\cvskillwidth}{\widthof{\cvSkill{5}}}
\setlength{\cvskillexperiencewidth}{\widthof{``Jahre''}}
\@initializelength{\matrixbodylength}
\setlength{\matrixbodylength}{\maincolumnwidth-\skillmatrixhintscolumnwidth-\separatorcolumnwidth}
\setlength{\skillmatrixcolumnwidth}{0.45\matrixbodylength}%
\setlength{\cvskilldescriptorwidth}{\skillmatrixcolumnwidth-\cvskillwidth-\cvskillexperiencewidth}
\setlength{\skillmatrixcommentwidth}{\matrixbodylength-\skillmatrixcolumnwidth-\skillmatrixcommentpadding}%
\setlength{\cvskilllegenddescriptorwidth}{0.5\matrixbodylength-\cvskillwidth-\skillmatrixcommentpadding}
% regular lengths
\setlength{\parskip}{0\p@}}
\RequirePackage{multirow}
\NewDocumentCommand\legendFontSize{}{\scriptsize}
\NewDocumentCommand\cvSkillMatrixLegend{s +O{.25em} +O{basic knowledge} +O{intermediate knowledge with experience in projects} +O{extensive experience in projects} +O{deep expert knowledge} +O{expert/guru} +m}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begingroup
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
{% if no star is given, do not add dashed line
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixHeadFont{}{\normalfont}
\NewDocumentCommand\cvSkillMatrixHead{s O{.25em} +O{Level} +O{Skill} +O{Years} +O{Comment}}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} \\\cdashline{2-5}[.6pt/1pt]
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
{%if star is not given, do not add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6}
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixEntry{s O{.25em} +m +m +m +m +m}{%
%test for the star * in the command
\IfBooleanTF#1%
{% If a star is seen a dotted line is drawn above the entry
\begingroup
\renewcommand{\arraystretch}{1.25}
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\cdashline{2-5}[.6pt/1pt]
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\endgroup
\par\addvspace{#2}}
%
{% If no star is seen no line is drawn
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\par\addvspace{#2}}
}

View file

@ -26,14 +26,12 @@
\@initializelength{\skillmatrixcolumnwidth} \@initializelength{\skillmatrixcolumnwidth}
\@initializelength{\skillmatrixcommentwidth} \@initializelength{\skillmatrixcommentwidth}
\@initializelength{\skillmatrixcommentpadding} \@initializelength{\skillmatrixcommentpadding}
\@initializelength{\skillmatrixhintscolumnwidth}
\@initializelength{\skilllegendhintscolumnwidth}
\NewDocumentCommand{\recomputecvskillmatrixlengths}{}{% \NewDocumentCommand{\recomputecvskillmatrixlengths}{}{%
% % body lengths \setlength{\skillmatrixhintscolumnwidth}{\hintscolumnwidth}
% \setlength{\maincolumnwidth}{\textwidth-\leftskip-\rightskip-\separatorcolumnwidth-\hintscolumnwidth}% \setlength{\skilllegendhintscolumnwidth}{\hintscolumnwidth} %0.175\textwidth
% \setlength{\listitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth}% % \setlength{\skillmatrixhintscolumnwidth}{0.14\textwidth} %0.175\textwidth
% \setlength{\doubleitemcolumnwidth}{\maincolumnwidth-\hintscolumnwidth-\separatorcolumnwidth-\separatorcolumnwidth}%
% \setlength{\doubleitemcolumnwidth}{0.5\doubleitemcolumnwidth}%
% \setlength{\listdoubleitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth-\separatorcolumnwidth-\listitemsymbolwidth}%
% \setlength{\listdoubleitemcolumnwidth}{0.5\listdoubleitemcolumnwidth}%
\setlength{\cvskillwidth}{\widthof{\cvSkill{5}}} \setlength{\cvskillwidth}{\widthof{\cvSkill{5}}}
\setlength{\cvskillexperiencewidth}{\widthof{``Jahre''}} \setlength{\cvskillexperiencewidth}{\widthof{``Jahre''}}
\setlength{\skillmatrixcolumnwidth}{0.45\maincolumnwidth}% \setlength{\skillmatrixcolumnwidth}{0.45\maincolumnwidth}%
@ -45,22 +43,25 @@
\setlength{\parskip}{0\p@}} \setlength{\parskip}{0\p@}}
\RequirePackage{multirow} \RequirePackage{multirow}
\NewDocumentCommand\legendFontSize{}{\small} \NewDocumentCommand\legendFontSize{}{\scriptsize}
\NewDocumentCommand\cvSkillMatrixLegend{s +O{.25em} +O{basic knowledge} +O{intermediate knowledge with experience in projects} +O{extensive experience in projects} +O{deep expert knowledge} +O{expert/guru} +m}{% \NewDocumentCommand\cvSkillMatrixLegend{s +O{.25em} +O{basic knowledge} +O{intermediate knowledge with experience in projects} +O{extensive experience in projects} +O{deep expert knowledge} +O{expert/guru} +m}{%
\IfBooleanTF#1% \IfBooleanTF#1%
{% if a star is given, add dashed line {% if a star is given, add dashed line
\begin{tabular}{@{}p{\hintscolumnwidth} \begingroup
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{};{.6pt/1pt}p{0.9\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{};{.6pt/1pt}p{1.1\cvskilllegenddescriptorwidth}@{}}% \arrayrulecolor{color1}
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\ \raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
% %
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\ & \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
% %
& & & \cvSkill{5}\, &\,{\legendFontSize #7 } & & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}% \end{tabular}%
\endgroup
\par\addvspace{#2} \par\addvspace{#2}
} }
{% if no star is given, do not add dashed line {% if no star is given, do not add dashed line
\begin{tabular}{@{}p{\hintscolumnwidth} \begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth}@{}}% @{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\ \raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
% %
@ -77,7 +78,8 @@
{% if a star is given, add dashed line {% if a star is given, add dashed line
\begingroup \begingroup
\renewcommand{\arraystretch}{1.25} \renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\hintscolumnwidth} \arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}% @{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} \\\cdashline{2-5}[.6pt/1pt] & \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} \\\cdashline{2-5}[.6pt/1pt]
\end{tabular}% \end{tabular}%
@ -87,7 +89,7 @@
{%if star is not given, do not add dashed line {%if star is not given, do not add dashed line
\begingroup \begingroup
\renewcommand{\arraystretch}{1.25} \renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\hintscolumnwidth} \begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}% @{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} & \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6}
\end{tabular}% \end{tabular}%
@ -103,7 +105,8 @@
{% If a star is seen a dotted line is drawn above the entry {% If a star is seen a dotted line is drawn above the entry
\begingroup \begingroup
\renewcommand{\arraystretch}{1.25} \renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}% \arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\cdashline{2-5}[.6pt/1pt] \cdashline{2-5}[.6pt/1pt]
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}% \raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}% \end{tabular}%
@ -111,7 +114,7 @@
\par\addvspace{#2}} \par\addvspace{#2}}
% %
{% If no star is seen no line is drawn {% If no star is seen no line is drawn
\begin{tabular}{@{}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}% \begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}% \raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}% \end{tabular}%
\par\addvspace{#2}} \par\addvspace{#2}}

View file

@ -48,6 +48,9 @@
% used by \cvlistdoubleitem % used by \cvlistdoubleitem
\@initializelength{\listdoubleitemcolumnwidth} \@initializelength{\listdoubleitemcolumnwidth}
%% include moderncv Skillmatrix code
\input{moderncvbodyivskillmatrix.sty}
% commands % commands
\renewcommand*{\recomputecvbodylengths}{% \renewcommand*{\recomputecvbodylengths}{%
% body lengths % body lengths
@ -57,6 +60,7 @@
\setlength{\doubleitemcolumnwidth}{0.5\doubleitemcolumnwidth}% \setlength{\doubleitemcolumnwidth}{0.5\doubleitemcolumnwidth}%
\setlength{\listdoubleitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth-\separatorcolumnwidth-\listitemsymbolwidth}% \setlength{\listdoubleitemcolumnwidth}{\maincolumnwidth-\listitemsymbolwidth-\separatorcolumnwidth-\listitemsymbolwidth}%
\setlength{\listdoubleitemcolumnwidth}{0.5\listdoubleitemcolumnwidth}% \setlength{\listdoubleitemcolumnwidth}{0.5\listdoubleitemcolumnwidth}%
\recomputecvskillmatrixlengths
% regular lengths % regular lengths
\setlength{\parskip}{0\p@}} \setlength{\parskip}{0\p@}}

View file

@ -0,0 +1,124 @@
% some packages required for this code
\RequirePackage{tikz}
% needed for the dashed lines
\RequirePackage{arydshln}
%%% The code for the Skilllevel illustration with the little boxes.
% This is idea stolen from the limecv package
\@initializelength{\cvSkillRectangleSize}
\setlength{\cvSkillRectangleSize}{1.2ex}
\newcount\my@repeat@count
\NewDocumentCommand{\cvSkill}{m}{%
\begingroup
\my@repeat@count=\z@
\@whilenum\my@repeat@count<#1\do{\tikz\filldraw[color1] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\@ne\,}%
\my@repeat@count=\numexpr5-\z@\relax
\@whilenum\my@repeat@count>#1\do{\tikz\filldraw[color2!30] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\m@ne\,}%
\endgroup
}
\@initializelength{\cvskillwidth}
\@initializelength{\cvskilldescriptorwidth}
\@initializelength{\cvskilllegenddescriptorwidth}
\@initializelength{\cvskillexperiencewidth}
\@initializelength{\skillmatrixcolumnwidth}
\@initializelength{\skillmatrixcommentwidth}
\@initializelength{\skillmatrixcommentpadding}
\@initializelength{\skillmatrixhintscolumnwidth}
\@initializelength{\skilllegendhintscolumnwidth}
\NewDocumentCommand{\recomputecvskillmatrixlengths}{}{%
\setlength{\skillmatrixcommentpadding}{1ex}
\setlength{\separatorcolumnwidth}{\skillmatrixcommentpadding}
\setlength{\skillmatrixhintscolumnwidth}{\widthof{``Languages''}}
\setlength{\skilllegendhintscolumnwidth}{\skillmatrixhintscolumnwidth}
% \setlength{\skillmatrixhintscolumnwidth}{0.14\textwidth} %0.175\textwidth
\setlength{\cvskillwidth}{\widthof{\cvSkill{5}}}
\setlength{\cvskillexperiencewidth}{\widthof{``Jahre''}}
\@initializelength{\matrixbodylength}
\setlength{\matrixbodylength}{\maincolumnwidth-\skillmatrixhintscolumnwidth-\separatorcolumnwidth}
\setlength{\skillmatrixcolumnwidth}{0.45\matrixbodylength}%
\setlength{\cvskilldescriptorwidth}{\skillmatrixcolumnwidth-\cvskillwidth-\cvskillexperiencewidth}
\setlength{\skillmatrixcommentwidth}{\matrixbodylength-\skillmatrixcolumnwidth-\skillmatrixcommentpadding}%
\setlength{\cvskilllegenddescriptorwidth}{0.5\matrixbodylength-\cvskillwidth-\skillmatrixcommentpadding}
% regular lengths
\setlength{\parskip}{0\p@}}
\RequirePackage{multirow}
\NewDocumentCommand\legendFontSize{}{\scriptsize}
\NewDocumentCommand\cvSkillMatrixLegend{s +O{.25em} +O{basic knowledge} +O{intermediate knowledge with experience in projects} +O{extensive experience in projects} +O{deep expert knowledge} +O{expert/guru} +m}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begingroup
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
{% if no star is given, do not add dashed line
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixHeadFont{}{\normalfont}
\NewDocumentCommand\cvSkillMatrixHead{s O{.25em} +O{Level} +O{Skill} +O{Years} +O{Comment}}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} \\\cdashline{2-5}[.6pt/1pt]
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
{%if star is not given, do not add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6}
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixEntry{s O{.25em} +m +m +m +m +m}{%
%test for the star * in the command
\IfBooleanTF#1%
{% If a star is seen a dotted line is drawn above the entry
\begingroup
\renewcommand{\arraystretch}{1.25}
\arrayrulecolor{color1}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\cdashline{2-5}[.6pt/1pt]
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\endgroup
\par\addvspace{#2}}
%
{% If no star is seen no line is drawn
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\par\addvspace{#2}}
}

View file

@ -0,0 +1,119 @@
% some packages required for this code
\RequirePackage{tikz}
% needed for the dashed lines
\RequirePackage{arydshln}
%%% The code for the Skilllevel illustration with the little boxes.
% This is idea stolen from the limecv package
\@initializelength{\cvSkillRectangleSize}
\setlength{\cvSkillRectangleSize}{1.2ex}
\newcount\my@repeat@count
\NewDocumentCommand{\cvSkill}{m}{%
\begingroup
\my@repeat@count=\z@
\@whilenum\my@repeat@count<#1\do{\tikz\filldraw[color1] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\@ne\,}%
\my@repeat@count=\numexpr5-\z@\relax
\@whilenum\my@repeat@count>#1\do{\tikz\filldraw[color2!30] (0, 0) rectangle (\cvSkillRectangleSize, \cvSkillRectangleSize);\advance%
\my@repeat@count\m@ne\,}%
\endgroup
}
\@initializelength{\cvskillwidth}
\@initializelength{\cvskilldescriptorwidth}
\@initializelength{\cvskilllegenddescriptorwidth}
\@initializelength{\cvskillexperiencewidth}
\@initializelength{\skillmatrixcolumnwidth}
\@initializelength{\skillmatrixcommentwidth}
\@initializelength{\skillmatrixcommentpadding}
\@initializelength{\skillmatrixhintscolumnwidth}
\@initializelength{\skilllegendhintscolumnwidth}
\NewDocumentCommand{\recomputecvskillmatrixlengths}{}{%
\setlength{\skillmatrixcommentpadding}{1ex}
\setlength{\separatorcolumnwidth}{\skillmatrixcommentpadding}
\setlength{\skillmatrixhintscolumnwidth}{\widthof{``Languages''}}
\setlength{\skilllegendhintscolumnwidth}{\skillmatrixhintscolumnwidth} %0.175\textwidth
% \setlength{\skillmatrixhintscolumnwidth}{0.14\textwidth} %0.175\textwidth
\setlength{\cvskillwidth}{\widthof{\cvSkill{5}}}
\setlength{\cvskillexperiencewidth}{\widthof{``Jahre''}}
\@initializelength{\matrixbodylength}
\setlength{\matrixbodylength}{\maincolumnwidth-\skillmatrixhintscolumnwidth-\separatorcolumnwidth}
\setlength{\skillmatrixcolumnwidth}{0.45\matrixbodylength}%
\setlength{\cvskilldescriptorwidth}{\skillmatrixcolumnwidth-\cvskillwidth-\cvskillexperiencewidth}
\setlength{\skillmatrixcommentwidth}{\matrixbodylength-\skillmatrixcolumnwidth-\skillmatrixcommentpadding}%
\setlength{\cvskilllegenddescriptorwidth}{0.5\matrixbodylength-\cvskillwidth-\skillmatrixcommentpadding}
% regular lengths
\setlength{\parskip}{0\p@}}
\RequirePackage{multirow}
\NewDocumentCommand\legendFontSize{}{\scriptsize}
\NewDocumentCommand\cvSkillMatrixLegend{s +O{.25em} +O{basic knowledge} +O{intermediate knowledge with experience in projects} +O{extensive experience in projects} +O{deep expert knowledge} +O{expert/guru} +m}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{};{.6pt/1pt}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\par\addvspace{#2}
}
{% if no star is given, do not add dashed line
\begin{tabular}{@{}p{\skilllegendhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth} @{\hspace{2\skillmatrixcommentpadding}}p{\cvskillwidth}@{}p{\cvskilllegenddescriptorwidth}@{}}%
\raggedleft\hintstyle{#8} & \cvSkill{1}\, & \,{\legendFontSize #3} & \cvSkill{3}\, &\,{\legendFontSize #5 } \\
%
& \cvSkill{2}\, & \,\multirow{2}{\cvskilllegenddescriptorwidth}{{\legendFontSize #4}} & \cvSkill{4}\, &\,{\legendFontSize #6 } \\
%
& & & \cvSkill{5}\, &\,{\legendFontSize #7 }
\end{tabular}%
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixHeadFont{}{\normalfont}
\NewDocumentCommand\cvSkillMatrixHead{s O{.25em} +O{Level} +O{Skill} +O{Years} +O{Comment}}{%
\IfBooleanTF#1%
{% if a star is given, add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6} \\\cdashline{2-5}[.6pt/1pt]
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
{%if star is not given, do not add dashed line
\begingroup
\renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}
@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}}p{\skillmatrixcommentwidth}@{}}%
& \centering{\cvSkillMatrixHeadFont #3} & \centering{\cvSkillMatrixHeadFont #4} & \centering{\cvSkillMatrixHeadFont #5} & {\cvSkillMatrixHeadFont #6}
\end{tabular}%
\endgroup
\par\addvspace{#2}
}
}
\NewDocumentCommand\cvSkillMatrixEntry{s O{.25em} +m +m +m +m +m}{%
%test for the star * in the command
\IfBooleanTF#1%
{% If a star is seen a dotted line is drawn above the entry
\begingroup
\renewcommand{\arraystretch}{1.25}
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\cdashline{2-5}[.6pt/1pt]
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\endgroup
\par\addvspace{#2}}
%
{% If no star is seen no line is drawn
\begin{tabular}{@{}p{\skillmatrixhintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvskillwidth}@{}@{}p{\cvskilldescriptorwidth}@{} p{\cvskillexperiencewidth} @{\hspace{\skillmatrixcommentpadding}} p{\skillmatrixcommentwidth}@{}}%
\raggedleft\hintstyle{#3} &\centering \cvSkill{#4} &\centering {#5} & \centering {#6} &{\itshape#7}%
\end{tabular}%
\par\addvspace{#2}}
}