\documentclass[a5, 10pt, twosides]{book} \usepackage[utf8]{inputenc} \usepackage{fontspec} \usepackage{graphicx} \usepackage{tikz} \usepackage{fancyhdr} \usepackage{fontenc}[T1] \usepackage[raggedright]{titlesec} \usepackage{tocloft} \usepackage{geometry} \usepackage{setspace} \usepackage{afterpage} \usepackage{listings} \usepackage{array} % for fixed width tables \usepackage{tabularx} % for multiple alignments in cells \usepackage[hang]{footmisc} % \usepackage[a4,cross,pdftex,center]{crop} % cropmarks \usepackage{perpage} \usepackage{setspace} \usepackage{hyphenat} \usepackage{scrextend} \usepackage{xcolor} \usepackage{tcolorbox} \usepackage{afterpage} \usepackage{paralist} \usepackage{caption} \usepackage{xurl} \usepackage{ltablex} \usepackage{vcell} \usepackage{float} \usepackage{calc} \usepackage{etoolbox} \usepackage[vskip=12pt,indentfirst=false, leftmargin=2em, rightmargin=2em]{quoting} \usepackage{multicol} \usepackage{yfonts} \usepackage{graphicx} \usepackage{pbox} \usepackage{eso-pic} \usepackage{xespotcolor} % CONFIGURE PACKAGES \usetikzlibrary{positioning} \RequirePackage{fix-cm} \tcbuselibrary{skins} \setlength\LTpre{12pt} \setlength\LTpost{12pt} \makeatletter \g@addto@macro{\newpage}{\nointerlineskip} \makeatother \newcommand\BackgroundPic{% \put(0,0){% \parbox[b][\paperheight]{\paperwidth}{% \vfill \centering \includegraphics[width=\paperwidth,height=\paperheight,% keepaspectratio]{04_magic-magick/test_toc-03-white.png}% \vfill }}} % CONFIGURE PACKAGES > SIZE \geometry{a5paper,left=24mm,top=12mm,bottom=20mm,right=16mm} % COMMANDS \let\endchangemargin=\endlist \setlength{\footnotemargin}{1em} % footnote space % VARIABLES \newcommand{\titlefontsize}{64pt} \newcommand{\titlelineheight}{56pt} \newcommand{\chapterfontsize}{24pt} \newcommand{\chapterlineheight}{24pt} \newcommand{\imgwidth}{\textwidth} \newcommand{\imgdir}{../00_contributions/FINAL/} \newcommand{\ballsize}{7mm} % VARIABLES > CHAPTER SIGNS \newcommand{\chaptersignone}{*} \newcommand{\chaptersigntwo}{†} \newcommand{\chaptersignthree}{‡} \newcommand{\chaptersignfour}{§} \newcommand{\chaptersignfive}{¶} \newcommand{\chaptersignsix}{‖} % FONT-FACES \setmainfont[Scale=0.95]{Arial} \setsansfont[Scale=0.95]{Arial} \setmonofont[Scale=0.95]{Courier} \newfontfamily\sectionfont{Times}[ItalicFont ={* Italic}, BoldFont ={* Bold}, BoldItalicFont={* Bold Italic}] % PAGE STYLES % All pages \pagestyle{fancy} \fancyhf{} \fancyhead[LE,RO]{} \fancyhead[RE,LO]{} \fancyfoot[CE,CO]{} \fancyfoot[LE,RO]{\thepage} \renewcommand{\headrulewidth}{0pt} \renewcommand{\footrulewidth}{0pt} % Chapter pages \fancypagestyle{plain}{ \fancyhf{} \fancyfoot[LE,RO]{\fontsize{\chapterfontsize}{\chapterlineheight}\selectfont\bfseries\thepage} \fancyfoot[LO,RE]{\fontsize{\chapterfontsize}{\chapterlineheight}\selectfont\bfseries\thechapter} \renewcommand{\headrulewidth}{0pt} \renewcommand{\footrulewidth}{0pt} \renewcommand{\fontruleskip}{0pt} \renewcommand{\headruleskip}{0pt} } % COVER \usetikzlibrary{positioning,fadings,through} \definecolor{left} {HTML}{000000} \title{''Titre du livre''} \author{''Nom de l'auteur''} \date{''date de fin de rédaction''} % CONTENTS \renewcommand{\contentsname}{} \renewcommand\cftchapfont{\bfseries} \renewcommand\cftchappagefont{\bfseries} % CHAPTER \renewcommand{\chaptername}{} \renewcommand{\thechapter}{\fnsymbol{chapter}} \titleformat{\chapter}[block]{\bfseries\fontsize{\chapterfontsize}{\chapterlineheight}\selectfont}{\chaptername}{0pt}{} \titlespacing{\chapter}{0pt}{0pt}{0pt} % SECTION \renewcommand{\thesection}{\arabic{section}} \titleformat{\section}[block]{\sectionfont\fontsize{\chapterfontsize}{\chapterlineheight}\selectfont}{}{0pt}{} \titlespacing{\section}{2em}{12pt}{8pt}{} % SUBSECTION \renewcommand{\thesubsection}{\arabic{subsection}} \titleformat{\subsection}[block]{\bfseries\fontsize{10pt }{12pt}\selectfont}{}{0pt}{} \titlespacing{\subsection}{0pt}{12pt}{12pt}{} % SUBSUBSECTION \renewcommand{\thesubsubsection}{\arabic{subsubsection}} \titleformat{\subsubsection}[block]{\sectionfont\fontsize{11pt}{12pt}\selectfont}{}{0pt}{} \titlespacing{\subsubsection}{24pt}{12pt}{8pt}{} % PARAGRAPHS \setlength{\parindent}{2em} \setlength{\parskip}{0pt} \renewcommand{\baselinestretch}{1.0} % CODE STYLE \lstset{ aboveskip=3mm, belowskip=3mm, showstringspaces=false, columns=flexible, basicstyle={\small\ttfamily}, numbers=none, numberstyle=\tiny, keywordstyle=\bfseries, commentstyle= stringstyle=, breaklines=true, breakatwhitespace=true, tabsize=3espace=true, tabsize=3 } \setlength{\textfloatsep}{0cm} % FOOTNOTE \begin{document} \setlength{\baselineskip}{12pt} \frenchspacing \urlstyle{sf} \tcbset{enhanced} \nointerlineskip % CONTENTS % \addtocontents{toc}{\protect\setcounter{tocdepth}{0}} % \vspace*{-8\baselineskip} % \tableofcontents{\thispagestyle{empty}} % \clearpage{\thispagestyle{empty}\cleardoublepage}