# Modify indentation of a tikz-kaviat graph in a friggeri-cv

I'm trying to use the friggeri CV template and to add a kaviat graph using tikz-kaviat in the leftmost part of the CV. The problem is the alignment is not good at all and I can't change it using /noidentation. Here is the result :

And the code :

\section{Programming}
\begin{tikzpicture}[scale=.5]
\tkzKiviatDiagram[lattice=5]{C,Matlab,Python,Bash,Lisp,LaTex,HTML/CSS}
\end{tikzpicture}
How could change it so the graph is way more on the left of the document ?

Thank you very much for your patience and help.

• Welcome here. Please provide a complete minimal working example. – user156344 Jan 9 at 16:42

There are an assortment of things you can play with to move the tikzpicture leftward. Typically, you can also specify a shift (or xshift / yshift) for tikzpicture but that doesn't seem to work nicely in this documentclass and picture location (at least for me).

In all cases, the dimensions I am giving are arbitrary (as I tried them in in Overleaf and thought they looked OK with the default template). It appears you modified fonts and other things...so these values will likely need tweaking!

Simplest version may be to put \hspace*{-1.2cm} immediately before \begin{tikzpicture}[scale=0.5] (i.e. \hspace*{-1.2cm}\begin{tikzpicture}[scale=0.5]%). Or, if you want them on separate lines:

\hspace*{-1.2cm}%
\begin{tikzpicture}[scale=0.5]%

Another option is to wrap a \makebox around it:

\makebox[3.6cm][c]{...tikz here...}

Consider also playing around with \tkzKiviatDiagram options gap, lattice, space, step, label space, and also the tikzpicture scale could be reduced slightly.

Finally, consider re-ordering the languages on the lattice. Matlab, Python, and HTML/CSS (especially the latter) are the longest strings in that last...and they are going to overlap farther to the right. Instead, try putting them into the left positions and using the shorter ones (e.g. C, Bash, Lisp) in the right-most positions. For example, \tkzKiviatDiagram[lattice=5]{Lisp,C,LaTex,Python,Matlab,HTML/CSS,Bash}%

Working Example:

Although it's rather lengthy to include, the class file and template may not be available in the future. So, I've stripped as much space from the cls file and content from the .tex file, so show my above suggestions 'in action'.

cv-style.cls

% -- Encoding UTF-8 without BOM
\ProvidesClass{cv-style}[2015/02/27 CV class]
\NeedsTeXFormat{LaTeX2e}
%
\DeclareOption{espanol}{\def\@cv@espanol{}}
\DeclareOption{print}{\def\@cv@print{}}
\DeclareOption*{%
\PassOptionsToClass{\CurrentOption}{article}%
}
\ProcessOptions\relax
%---------------------------------------------------------------------------------
% Colors %
%---------------------------------------------------------------------------------
\RequirePackage{xcolor}
\definecolor{white}{RGB}{255,255,255}
\definecolor{darkgray}{HTML}{333333}
\definecolor{gray}{HTML}{4D4D4D}
\definecolor{lightgray}{HTML}{999999}
\definecolor{blue}{HTML}{66D9EE}
\definecolor{red}{HTML}{FA2772}
\definecolor{orange}{HTML}{FE9720}
\definecolor{green}{HTML}{A7E22E}
\definecolor{purple}{HTML}{9358FE}
\definecolor{aquamarine}{HTML}{36AF90}
\definecolor{date}{HTML}{A4A4A4}
%
\ifdefined\@cv@print
\colorlet{blue}{gray}
\colorlet{red}{gray}
\colorlet{orange}{gray}
\colorlet{green}{gray}
\colorlet{purple}{gray}
\colorlet{aquamarine}{gray}
\else
\fi
\colorlet{textcolor}{gray}
%
%---------------------------------------------------------------------------------
% Fonts %
%---------------------------------------------------------------------------------
\RequirePackage[quiet]{fontspec}
\RequirePackage[math-style=TeX,vargreek-shape=unicode]{unicode-math}
%
\newfontfamily\bodyfont{Roboto-Regular}[Path=fonts/]
\newfontfamily\bodyfontit{Roboto-LightItalic}[Path=fonts/]
\newfontfamily\thinfont{Roboto-Thin}[Path=fonts/]
%
\defaultfontfeatures{Mapping=tex-text}
\setmainfont[Mapping=tex-text, Color=textcolor, Path = fonts/]{Roboto-Light}
%
\newcommand{\italica}[1]{%
{\color{gray}\bodyfontit #1}%
}
%
%---------------------------------------------------------------------------------
%---------------------------------------------------------------------------------
\RequirePackage{tikz}
%
\begin{tikzpicture}[remember picture,overlay]
\node [rectangle, fill=fillheader, anchor=north, minimum width=\paperwidth, minimum height=2cm] (box) at (current page.north){};
\node [anchor=center] (name) at (box) {%
{\thinfont #1}{\bodyfont  #2}
};
\end{tikzpicture}
\vspace{1cm}
\vspace{-2\parskip}
}
%
%---------------------------------------------------------------------------------
%   Last updated command %
%---------------------------------------------------------------------------------
\RequirePackage[absolute,overlay]{textpos}
\RequirePackage{polyglossia}
%
\newcommand{\sethyphenation}[3][]{%
\sbox0{\begin{otherlanguage}[#1]{#2}
\hyphenation{#3}\end{otherlanguage}}}
%
\ifdefined\@cv@espanol
\setdefaultlanguage{spanish}
\def\lastupdatedtext{Última Actualización el}
\else
\setdefaultlanguage[variant=british]{english}
\def\lastupdatedtext{Last Updated on}
\fi
%
\setlength{\TPHorizModule}{0.01\paperwidth}
\setlength{\TPVertModule}{0.01\paperwidth}
%
\newcommand{\lastupdated}{
\begin{textblock}{10}(11.3, 0.05)
\raggedleft
\fontsize{8pt}{10pt}\color{date}\thinfont
\lastupdatedtext{} \today
\end{textblock}}
%---------------------------------------------------------------------------------
% Structure %
%---------------------------------------------------------------------------------
\RequirePackage{parskip}
%
\newcounter{colorCounter}
\def\@sectioncolor#1#2#3{%
{%
\color{%
\ifcase\value{colorCounter}%
blue\or%
red\or%
orange\or%
green\or%
purple\or%
aquamarine\else%
} #1#2#3%
}%
\stepcounter{colorCounter}%
}
%
\renewcommand{\section}[1]{
{\par\vspace{\parskip}
{%
\@sectioncolor #1%
}
\par\vspace{\parskip}}
}
%
\renewcommand{\subsection}[2]{
\par\vspace{.5\parskip}%
\par\vspace{.25\parskip}%
}
%
\newcommand{\jobtitle}[1]{%
{\color{gray}\bodyfontit #1}%
}
%
\pagestyle{empty}
%----------------------------------------------------------------------------------------
% List environment %
%---------------------------------------------------------------------------------
\setlength{\tabcolsep}{0pt}
\newenvironment{entrylist}{%
\begin{tabular*}{\textwidth}{@{\extracolsep{\fill}}ll}
}{%
\end{tabular*}
}
\newcommand{\entry}[4]{%
#1&\parbox[t]{12.8cm}{%
\textbf{#2}%
\hfill%
#4\vspace{\parsep}%
}\\}
%---------------------------------------------------------------------------------
% Side block %
%---------------------------------------------------------------------------------
\setlength{\TPHorizModule}{1cm}
\setlength{\TPVertModule}{1cm}
\newenvironment{aside}{%
\let\oldsection\section
\renewcommand{\section}[1]{
}
\begin{textblock}{3.6}(1, 1.87)
\begin{flushright}
\obeycr
}{%
\restorecr
\end{flushright}
\end{textblock}
\let\section\oldsection
}
%---------------------------------------------------------------------------------
% Other tweaks %
%---------------------------------------------------------------------------------
\RequirePackage{hyperref}
\hypersetup{
pdftitle=CV/Resume \textbar{} Alejandro Pérez Londoño,
pdfauthor=Alejandro Pérez Londoño,
pdfsubject=CV/Resume%
}

main.tex

% -- Encoding UTF-8 without BOM
% -- XeLaTeX => PDF (BIBER)
\documentclass[]{cv-style}
%
\sethyphenation[variant=british]{english}{}%
%
\usepackage{tkz-kiviat}
\usetikzlibrary{arrows}
%
\begin{document}
%
\lastupdated
%
\begin{aside}
%
\section{contact}
City, State 050022
Country
~
+0 (000) 111 1111
+0 (000) 111 1112
~
john@smith.com
%
\section{languages}
English mother tongue
Spanish fluency
%
\section{programming}
\hspace*{-1.2cm}%
\begin{tikzpicture}[scale=0.5]%
\tkzKiviatDiagram[lattice=5,]{Lisp,C,LaTex,Python,Matlab,HTML/CSS,Bash}%
\end{tikzpicture}
~
{\color{red} $\varheartsuit$} R
VBA, SQL, Python
\LaTeX{}
%
\end{aside}
%
\section{skills}
\vspace{-0.2cm}
Skill 1, skill 2, skill 3, skill 4, skill 5.
%
\section{experience}
\begin{entrylist}
\entry
{2014--Now}
{COMPANY 3}
{City, Country}
{\jobtitle{Job Title}\\
Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description.}
\entry
{2011--2014}
{COMPANY 2}
{City, Country}
{\jobtitle{Job Title}\\
Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description.\\
Detailed achievements:
\begin{itemize}
\item Achievement 1. Achievement 1. Achievement 1.
\item Achievement 2. Achievement 2. Achievement 2. Achievement 2. Achievement 2. Achievement 2.
\item Achievement 3. Achievement 3. Achievement 3. Achievement 3.
\end{itemize}}
\entry
{2008--2011}
{COMPANY 1}
{City, Country}
{\jobtitle{Job Title}\\
Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description. Job description.\\
Detailed achievements:
\begin{itemize}
\item Achievement 1. Achievement 1. Achievement 1. Achievement 1. Achievement 1. Achievement 1. Achievement 1. Achievement 1.
\end{itemize}}
\end{entrylist}
\end{document}

The other version is approximately the same:

\makebox[3.6cm][c]{%
\begin{tikzpicture}[scale=0.5]
\tkzKiviatDiagram[lattice=5]{Lisp,C,LaTex,Python,Matlab,HTML/CSS,Bash}
\end{tikzpicture}}

As an aside, I was getting a couple identical errors (LaTeX Error: Something's wrong--perhaps a missing \item.) - which still compiled in Overleaf. I found that the \begin{aside}...\end{aside} (left sidebar) uses \obeycr...\restorecr. Because of this, you need to use % at the end of each line of the tikzpicture, in other words:

\hspace*{-1.2cm}%
\begin{tikzpicture}[scale=0.5]%
\tkzKiviatDiagram[lattice=5,]{Lisp,C,LaTex,Python,Matlab,HTML/CSS,Bash}%
\end{tikzpicture}

and not:

\hspace*{-1.2cm}%
\begin{tikzpicture}[scale=0.5]
\tkzKiviatDiagram[lattice=5,]{Lisp,C,LaTex,Python,Matlab,HTML/CSS,Bash}
\end{tikzpicture}
• Ehm, getting an error means it doesn't compile. Depending on context you can get reasonable output even when skipping through errors, but one really should fix them. – Torbjørn T. Jan 13 at 11:25
• @TorbjørnT. It's in Overleaf - it compiles and gives the error. I don't know what their compilation options are, however. Plus, the OP's code snippet is the one that gives me the error (so it appears to compile there also). But after your comment, I found that the left bar is wrapped in \obeycr...\restorecr. Removing these fixes the error, and changes the formatting slightly. Which made me realize I can include % and the end of each line for the tikzpicture to remove it. Will update to reflect this finding. – whatisit Jan 13 at 16:39
• Perhaps a question of semantics, or perhaps I put too much into the term. It compiles in the sense that you get some PDF output, as Overleaf by default tells TeX to step through errors (nonstopmode, or whatever it's called). But seeing as you do get an error, I wouldn't call it a successful compilation. Nice addition to the answer by the way. – Torbjørn T. Jan 13 at 19:03
• @TorbjørnT. No, you are correct. I glanced at the cls file originally, but did not recognize any list-like environment...which is why I was confused. It compiled in Overlear fine, and that is where OP was compiling it. Your comment got me thinking that I should fix this for future users, or ones who don't use Overleaf but use the template. – whatisit Jan 13 at 19:51