aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile5
-rwxr-xr-xmodel_6/Makefile40
-rw-r--r--model_6/example.pdfbin0 -> 40704 bytes
-rwxr-xr-xmodel_6/example.rst126
-rwxr-xr-xmodel_6/resources/00_colors.tex13
-rwxr-xr-xmodel_6/resources/00_length.tex5
-rwxr-xr-xmodel_6/resources/00_preamble.tex28
-rw-r--r--model_6/resources/10_container.tex8
-rwxr-xr-xmodel_6/resources/10_fonts.tex14
-rwxr-xr-xmodel_6/resources/10_title_style.tex53
-rwxr-xr-xmodel_6/resources/99_begin.tex7
-rw-r--r--model_6/resources/CaviarDreams.ttfbin0 -> 58864 bytes
-rwxr-xr-xmodel_6/resources/modules12
-rwxr-xr-xreadme.rst14
-rw-r--r--snapshots/model6.pngbin0 -> 62104 bytes
15 files changed, 325 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 891daf7..f1523c7 100644
--- a/Makefile
+++ b/Makefile
@@ -5,6 +5,11 @@ all: $(SUBDIRS)
$(SUBDIRS):
$(MAKE) -C $@
+pngs: $(SUBDIRS)
+ for dir in $(SUBDIRS); do \
+ gs -dTextAlphaBits=4 -dFirstPage=1 -dLastPage=1 -dBATCH -dNOPAUSE -sDEVICE=png16m -r72 -dUseCropBox -sOutputFile=$$dir/example.png $$dir/example.pdf; \
+ done
+
clean:
for dir in $(SUBDIRS); do \
$(MAKE) -C $$dir clean; \
diff --git a/model_6/Makefile b/model_6/Makefile
new file mode 100755
index 0000000..170dd32
--- /dev/null
+++ b/model_6/Makefile
@@ -0,0 +1,40 @@
+TEX=xelatex
+SOURCE=.
+
+SRC =$(wildcard *.rst)
+
+PDFS = $(SRC:.rst=.pdf)
+
+all: $(PDFS)
+
+DIR = $(sort $(shell find $(SOURCE) -name '*.rst' -print))
+SOURCES = $(sort $(wildcard resources/*.tex) )
+
+null :=
+space := $(null) #
+comma := ,
+TEX_STYLE := $(subst $(space),$(comma),$(strip $(SOURCES)))
+
+PACK = $(shell sed -e 's/\#.*$$//' -e '/^$$/d' resources/modules)
+PACKAGES := $(subst $(space),$(comma),$(strip $(PACK)))
+
+tmp:
+ mkdir tmp
+
+# Generate the latex file from rst
+tmp/%.tex: %.rst $(SOURCES)| tmp
+ $$(command -v rst2latex rst2latex.py | head -n 1) --no-section-subtitles --table-style=borderless --use-latex-citations --use-latex-docinfo --documentclass=extarticle --documentoption=12pt,A4,table --syntax-highlight=short --stylesheet=$(PACKAGES),$(TEX_STYLE) $< $@
+ sed -i -e 's/continued on next page/suite sur la page suivante/;s|^%$$||' $@
+ sed -i -e 's/admonition-/admonition/g' $@
+
+# Generate each pdf with latex
+tmp/%.pdf: tmp/%.tex | tmp
+ $(TEX) -output-directory tmp $<
+ while grep 'Rerun to get ' tmp/$*.log ; do $(TEX) -output-directory tmp $< ; done
+
+# Put the pdf in the right place
+%.pdf: tmp/%.pdf | tmp
+ cp $< $@
+
+clean:
+ rm -r tmp
diff --git a/model_6/example.pdf b/model_6/example.pdf
new file mode 100644
index 0000000..c11edee
--- /dev/null
+++ b/model_6/example.pdf
Binary files differ
diff --git a/model_6/example.rst b/model_6/example.rst
new file mode 100755
index 0000000..5db07a6
--- /dev/null
+++ b/model_6/example.rst
@@ -0,0 +1,126 @@
+.. -*- mode: rst -*-
+.. -*- coding: utf-8 -*-
+
+
+.. role:: latex(raw)
+ :format: latex
+
+.. role:: level
+.. role:: levelbox
+.. role:: star
+
+.. default-role:: latex
+
+.. raw:: latex
+
+
+ %\setstretch{1.4}
+
+ % Espacement entre chaque note de marge
+ %\setlength{\notesep}{0cm}
+
+ \renewcommand{\labelitemi}{}
+
+
+.. role:: smallcaps
+.. role:: smallemph
+
+.. |phoneicon| replace:: `\renewcommand{\labelitemi}{\faPhone}`
+.. |mailicon| replace:: `\renewcommand{\labelitemi}{\faEnvelope}`
+.. |noicon| replace:: `\renewcommand{\labelitemi}{}`
+
+=============
+Nom et Prénom
+=============
+
+--------------
+Petite légende
+--------------
+
+.. container:: header
+
+ * 17 allée des cerisiers
+ * 75001 Paris |phoneicon|
+ * 01 23 45 67 89 |mailicon|
+ * email@example |noicon|
+ * 01/02/1980
+ * Permis B
+
+
+Expériences
+===========
+
+`\renewcommand{\labelitemi}{$\bullet$}`
+
+:Actuellement:
+
+ **Poste actuel** — *Entreprise* — Adresse.
+
+ :latex:`\lipsum[1-3][4-7]`
+
+ .. class:: checklist
+
+ - :latex:`\lipsum[1-3][1]`
+ - :latex:`\lipsum[1-3][2]`
+ - :latex:`\lipsum[1-3][3]`
+
+:2011 — 2018:
+
+ **Poste occupé** — *Entreprise* — Adresse.
+
+ :latex:`\lipsum[1-3][5-10]`
+
+ :latex:`\lipsum[4-7][5-10]`
+
+:2010 — 2011:
+
+ **Poste occupé** — *Entreprise* — Adresse.
+
+ :latex:`\lipsum[1-3][10-15]`
+
+
+:2008 — 2010:
+
+ **Poste occupé** — *Entreprise* — Adresse.
+
+ :latex:`\lipsum[1-3][15-21]`
+
+
+Réalisations
+============
+
+Description
+-----------
+
+:latex:`\lipsum[4-7][10-15]`
+
+:latex:`\lipsum[4-7][15-20]`
+
+Description
+-----------
+
+:latex:`\lipsum[7-10][10-15]`
+
+:latex:`\lipsum[7-10][15-20]`
+
+
+Formations
+==========
+
+:Année:
+
+ **Niveau M1** — *Université de Paris*
+
+
+:Année:
+
+ **Licence** — *Université de Paris*
+
+ Mention
+
+
+:Année:
+
+ **Baccalauréat Scientifique** — *Lycée* – Ville
+
+ Spécialité
diff --git a/model_6/resources/00_colors.tex b/model_6/resources/00_colors.tex
new file mode 100755
index 0000000..3afc69c
--- /dev/null
+++ b/model_6/resources/00_colors.tex
@@ -0,0 +1,13 @@
+\usepackage{xcolor}
+
+% Couleur utilisée pour le bandeau
+\definecolor{backsidecolor}{RGB}{255,255,255}
+
+% Couleur utilisée pour les éléments du bandeau
+%\definecolor{sidecolor}{RGB}{36,63,96}
+%\definecolor{sidecolor}{RGB}{101,114,131}
+
+% Couleur utilisée pour le texte du bandeau
+\definecolor{textsidecolor}{RGB}{0,0,0}
+
+\definecolor{altColor}{HTML}{5e81ac}
diff --git a/model_6/resources/00_length.tex b/model_6/resources/00_length.tex
new file mode 100755
index 0000000..bcd66ae
--- /dev/null
+++ b/model_6/resources/00_length.tex
@@ -0,0 +1,5 @@
+% Distance de la colonne
+\setlength{\columnsep}{0.25cm}
+
+\newlength{\definitionWidth}
+\setlength{\definitionWidth}{3.0cm}
diff --git a/model_6/resources/00_preamble.tex b/model_6/resources/00_preamble.tex
new file mode 100755
index 0000000..e1450ec
--- /dev/null
+++ b/model_6/resources/00_preamble.tex
@@ -0,0 +1,28 @@
+\usepackage{calc}
+
+\usepackage[a4paper, top=0.5cm, bottom=0.5cm, outer=2.0cm, inner=2.0cm]{geometry}
+\pagestyle{empty}
+\pagenumbering{gobble}
+
+\newcommand{\DUrolelatex}[1]{#1}
+
+% Les listes de champs sont paramétrée pour faire un alignement à droite sur le
+% label, et un alignement à gauche sur la définition.
+\newenvironment{DUfieldlist}%
+ {\description[font=\normalfont
+ ,align=right
+ ,leftmargin=\definitionWidth
+ ,itemindent=0cm
+ ]}
+ {\enddescription}
+
+\makeatletter
+\newcommand{\ifdefinedcolor}[3]{%
+ \@ifundefinedcolor{#1}{#3}{#2}
+}
+\makeatother
+
+\input{../common/10_language.tex}
+\input{../common/10_lists.tex}
+\input{../common/10_nowidows.tex}
+\input{../common/10_levels.tex}
diff --git a/model_6/resources/10_container.tex b/model_6/resources/10_container.tex
new file mode 100644
index 0000000..a880a85
--- /dev/null
+++ b/model_6/resources/10_container.tex
@@ -0,0 +1,8 @@
+\newenvironment{DUCLASSheader}
+ { % renew the itemize command in order to apply a flushright to each elements
+ \let\olditemize\itemize%
+ \renewcommand\itemize{\olditemize\raggedleft\setlength\itemsep{0.0em}\small}%
+ % Create a minipage on the right
+ \begin{flushright}\begin{minipage}[t][0cm][b]{\linewidth}%
+ \raggedleft\em\color{gray}}
+ { \end{minipage}\end{flushright}}
diff --git a/model_6/resources/10_fonts.tex b/model_6/resources/10_fonts.tex
new file mode 100755
index 0000000..0dc179e
--- /dev/null
+++ b/model_6/resources/10_fonts.tex
@@ -0,0 +1,14 @@
+\usepackage{fontspec}
+\setmainfont[Mapping=tex-text]{EB Garamond}
+
+% Set the bold font as Linux Libertine as the EB Garamond miss some characters
+\newfontfamily\LibertineFont[Mapping=tex-text]{Linux Libertine O}
+\let\bf\textbf
+\renewcommand{\textbf}[1]{{\LibertineFont\selectfont\bf{#1}}}
+
+\setmonofont{Latin Modern Mono Light}
+
+\newfontfamily\TitleFont[Path=resources/, Mapping=tex-text]{CaviarDreams}
+\newfontfamily\CaviarDreamsFont[Path=resources/, Mapping=tex-text]{CaviarDreams}
+
+%\newfontfamily\AltFont[Mapping=tex-text]{Linux Libertine O}
diff --git a/model_6/resources/10_title_style.tex b/model_6/resources/10_title_style.tex
new file mode 100755
index 0000000..05036f4
--- /dev/null
+++ b/model_6/resources/10_title_style.tex
@@ -0,0 +1,53 @@
+\usepackage[explicit]{titlesec}
+\usepackage{pgfplots}
+\pgfplotsset{compat=newest}
+
+\providecommand{\DUdocumentsubtitle}[1]{%
+ \color{gray}
+ \normalfont
+ \em
+ \huge
+ #1
+}
+
+\makeatletter
+
+\def\@maketitle{%
+ \vspace*{1cm}
+ \fontsize{1.2cm}{2cm}
+ \TitleFont\selectfont \@title
+}
+\makeatother
+
+\newcommand\SecTitle[1]{%
+\begin{tikzpicture}
+
+ \node (A) at (0,0)
+ {\Large{\CaviarDreamsFont{#1}}};
+
+ \draw [line width=1.5mm,color=altColor]
+ (- \definitionWidth - 1.5cm,0) -- (A.west);
+
+\end{tikzpicture}}
+
+% Titre de niveau 1
+\titleformat{\section}
+ {}
+ {\thesection}
+ {}
+ {\SecTitle{\textcolor{altColor}{#1}}}
+
+% Titre de niveau 2
+\titleformat{\subsection}
+ {\large}
+ {\thesubsection}
+ {}
+ {\textcolor{altColor}{\Large \bf {#1}}}
+
+% Titre de niveau 3
+\titleformat{\subsubsection}
+ {\bfseries\normalsize}
+ {\thesubsubsection}
+ {2em}
+ {}
+ {}
diff --git a/model_6/resources/99_begin.tex b/model_6/resources/99_begin.tex
new file mode 100755
index 0000000..4867a82
--- /dev/null
+++ b/model_6/resources/99_begin.tex
@@ -0,0 +1,7 @@
+\input{../common/90_ref.tex}
+
+%% On charge les colonnes dès le début du document.
+%\AtBeginDocument{%
+% \begin{paracol}{2}
+%}
+
diff --git a/model_6/resources/CaviarDreams.ttf b/model_6/resources/CaviarDreams.ttf
new file mode 100644
index 0000000..4ba4279
--- /dev/null
+++ b/model_6/resources/CaviarDreams.ttf
Binary files differ
diff --git a/model_6/resources/modules b/model_6/resources/modules
new file mode 100755
index 0000000..7ed0581
--- /dev/null
+++ b/model_6/resources/modules
@@ -0,0 +1,12 @@
+tikz
+parskip # Ne pas indenter la premiere ligne d'un paragraphe
+setspace
+
+# Polices mathematiques.
+amsmath
+amsfonts
+amssymb
+
+DUsmallcaps
+pgfornament
+lipsum
diff --git a/readme.rst b/readme.rst
index 8ffc72a..8629320 100755
--- a/readme.rst
+++ b/readme.rst
@@ -79,6 +79,20 @@ Une version inspirée par le `CV Rambo`__
.. __: /latex_template.git/plain/model_5/example.pdf
+Model 6
+-------
+
+Une version inspirée par le fameux `moderncv`__
+
+.. __: https://ctan.org/pkg/moderncv
+
+.. image:: /latex_template.git/plain/snapshots/model6.png
+ :width: 400px
+
+`[Version PDF]`__
+
+.. __: /latex_template.git/plain/model_6/example.pdf
+
La syntaxe
==========
diff --git a/snapshots/model6.png b/snapshots/model6.png
new file mode 100644
index 0000000..df42609
--- /dev/null
+++ b/snapshots/model6.png
Binary files differ