% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Pour convertir en png :       %
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% lancer : make test.pdf-test.png
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Pour convertir en gif animé : %
% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% lancer : make test.pdf-test.gif
%
% \listfiles
%
% \makeatletter
% \makeatother
%
% \ExplSyntaxOn
% \ExplSyntaxOff

\documentclass{article}
\usepackage[french]{babel}
\begin{document}
Test
\end{document}

\documentclass{article}
\AddToHook{env/document/begin}[mydoc/loadbib]{%
  \RequirePackage{biblatex}%
}
\DeclareHookRule{env/document/begin}{mydoc/loadbib}{before}{hyperref}
\begin{document}
\end{document}

\documentclass{article}
\usepackage{scontents}

% Fix part of a MCE that should go before babel's loading
\begin{scontents}[store-env=mce]
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\end{scontents}

% Fix part of a MCE that should go after (>=) babel's loading
\begin{scontents}[store-env=mce]
\usepackage{babel}
\begin{document}
\end{scontents}

% Fix part of a MCE that should go after its body
\begin{scontents}[store-env=mce]
\end{document}
\end{scontents}

\begin{document}

\section{First answer}
% Variable part of a MCE that should added to the fixed preamble, before babel's
% loading
\begin{scontents}[store-env=mce-1]
\usepackage{amsmath}
\end{scontents}

% Variable part of a MCE being the code snippet
\begin{scontents}[store-env=mce-1]
\begin{align}
  0 & \neq 1 \\
  1 & \neq 0
\end{align}
\end{scontents}

\begin{description}
\item[Preamble's addition]\leavevmode
  \typestored[4]{mce}
\item[Code snippet]\leavevmode
  \typestored[5]{mce}
\item[MCE]\leavevmode
  \typestored[1]{mce}%
  \typestored[1]{mce-1}%
  \typestored[2]{mce}%
  \typestored[2]{mce-1}%
  \typestored[3]{mce}%
\end{description}

\section{Second answer}
% Variable part of a MCE that should added to the fixed preamble, before babel's
% loading
\begin{scontents}[store-env=mce-2]
\usepackage{amsmath}
\end{scontents}

% Variable part of a MCE being the code snippet
\begin{scontents}[store-env=mce-2]
\begin{flalign}
  0 & \neq 1 \\
  1 & \neq 0
\end{flalign}
\end{scontents}

\begin{description}
\item[Preamble's addition]\leavevmode
  \typestored[4]{mce}
\item[Code snippet]\leavevmode
  \typestored[5]{mce}
\item[MCE]\leavevmode
  \typestored[1]{mce}%
  \typestored[1]{mce-2}%
  \typestored[2]{mce}%
  \typestored[2]{mce-2}%
  \typestored[3]{mce}%
\end{description}

\end{document}

\documentclass{yathesis}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{kpfonts}
\supervisor{Michel}{de Montaigne}
\cosupervisor{Étienne}{de la Boétie}
%
\referee{René}{Descartes}
\referee{Denis}{Diderot}
%
\committeepresident{Victor}{Hugo}
\examiner{Charles}{Baudelaire}
\examiner{Émile}{Zola}
\examiner{Paul}{Verlaine}
%
\guest{George}{Sand}
\begin{document}
\maketitle
\end{document}

\documentclass[a4paper]{article}
\usepackage{cmap}
\usepackage[lining]{libertine}
\usepackage{tcolorbox}
\usepackage{newunicodechar}
% \DeclareUnicodeCharacter{27E8}{\ensuremath\langle}
% \DeclareUnicodeCharacter{27E9}{\ensuremath\rangle}
\newunicodechar{⟨}{$\langle$}
\newunicodechar{⟩}{$\rangle$}
\tcbuselibrary{documentation}
\begin{document}
\meta{text}
\end{document}

\documentclass{article}
\usepackage{scontents}

% Fix part of a MCE that should go before babel's loading
\begin{scontents}[store-env=mce]
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\end{scontents}

% Fix part of a MCE that should go after (>=) babel's loading
\begin{scontents}[store-env=mce]
\usepackage{babel}
\begin{document}
\end{scontents}

% Fix part of a MCE that should go after its body
\begin{scontents}[store-env=mce]
\end{document}
\end{scontents}

\begin{document}

% Variable part of a MCE that should added to the fixed preamble, before babel's
% loading
\begin{scontents}[store-env=mce]
\usepackage{amsmath}
\end{scontents}

% Variable part of a MCE being the code snippet
\begin{scontents}[store-env=mce]
\begin{align}
  0 & \neq 1 \\
  1 & \neq 0
\end{align}
\end{scontents}

\begin{description}
\item[Preamble's addition]\leavevmode
  \typestored[4]{mce}
\item[Code snippet]\leavevmode
  \typestored[5]{mce}
\item[MCE]\leavevmode
  \typestored[1]{mce}%
  \typestored[4]{mce}%
  \typestored[2]{mce}%
  \typestored[5]{mce}%
  \typestored[3]{mce}%
\end{description}

\end{document}

\documentclass{article}
\usepackage{listings}
\usepackage[overwrite,force-eol]{scontents}

% \begin{scontents}[write-env=\jobname-test.tex]
% \documentclass[french]{article}
% \usepackage[T1]{fontenc}
% \usepackage[utf8]{inputenc}
% \usepackage{lmodern}
% \usepackage[a4paper]{geometry}
% \begin{scontents}[store-env=inner]
% \usepackage{babel}
% \end{scontents}
% \usepackage{babel}
% \begin{document}
% \begin{scontents}[store-env=inner]
% \begin{equation}
%   \begin{split}
%     a & = b+c-d    \\
%       & \quad +e-f \\
%       & = i
%   \end{split}
% \end{equation}
% \begin{multline}
%   a+b+c+d+e+f      \\
%   +i+j+k+l+m+n
% \end{multline}
% \end{scontents}
% \end{document}
% \end{scontents}

\begin{scontents}[store-env=mce,write-env=\jobname-scontents.tex]
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\end{scontents}

\begin{scontents}[store-env=mce,write-env=\jobname-scontents.tex]
\usepackage{babel}
\begin{document}
\end{scontents}

\begin{scontents}[store-env=mce,write-env=\jobname-scontents.tex]
\end{document}
\end{scontents}

\makeatletter
\let\verbatimsc\@undefined
\let\endverbatimsc\@undefined
\makeatother
\usepackage{listings}
\lstnewenvironment{verbatimsc}
{
  \lstset{
    language=[AlLaTeX]TeX, %
    alsolanguage=[LaTeX]TeX,%
    basicstyle=\ttfamily,%
  }
}{}

\begin{document}
\begin{scontents}[store-env=mce,write-env=\jobname-scontents.tex]
\usepackage{amsmath}
\end{scontents}

\begin{scontents}[store-env=mce,write-env=\jobname-scontents.tex]
\begin{equation}
  \begin{split}
    a & = b+c-d    \\
      & \quad +e-f \\
      & = i
  \end{split}
\end{equation}
\begin{multline}
  a+b+c+d+e+f      \\
  +i+j+k+l+m+n
\end{multline}
\end{scontents}

\begin{description}
\item[Preamble's addition]\leavevmode
  \typestored[4]{mce}
\item[Code snippet]\leavevmode
  \lstset{numbers=left}
  \typestored[5]{mce}
  \lstset{numbers=none}
\item[MCE]\leavevmode
  \typestored[1]{mce}%
  \typestored[4]{mce}%
  \typestored[2]{mce}%
  \typestored[5]{mce}%
  \typestored[3]{mce}%
\end{description}

\end{document}

\documentclass{article}
\usepackage{fancyvrb}
\usepackage{listings}

\lstset{%
  language=[AlLaTeX]TeX, %
  alsolanguage=[LaTeX]TeX,%
  basicstyle=\ttfamily,%
}

\ExplSyntaxOn

\newenvironment{preambleaddition}{%
  \VerbatimOut{\g_file_curr_name_str _preambleaddition.tex}%
}{%
  \endVerbatimOut
}

\iow_new:N \g__denis_output_stream

\cs_generate_variant:Nn \iow_now:Nn {NV}

\newenvironment{codesnippet}{%
  \VerbatimOut{\g_file_curr_name_str _codesnippet.tex}%
}{%
  \endVerbatimOut
  \begin{description}
    \file_if_exist:nT {\g_file_curr_name_str _preambleaddition.tex} {
    \item[Preamble's~ addition]\leavevmode
      \lstinputlisting{\g_file_curr_name_str _preambleaddition.tex}
    }%
  \item[Code~ snippet]\leavevmode
    \lstinputlisting{\g_file_curr_name_str _codesnippet.tex}
  \item[MCE]\leavevmode
    % We write to the whole file the desired structure and input:
    % - the preamble's addition,
    % - the code snippet.
    \iow_open:Nn \g__denis_output_stream { \g_file_curr_name_str _wholefile.tex }
    \iow_now:Nn \g__denis_output_stream {
    \documentclass[french]{article}^^J
    \usepackage[T1]{fontenc}^^J
    \usepackage[utf8]{inputenc}^^J
    \usepackage{lmodern}^^J
    \usepackage[a4paper]{geometry}
  }
  \file_if_exist:nT {\g_file_curr_name_str _preambleaddition.tex} {
    \file_get:nnN {\g_file_curr_name_str _preambleaddition} {} \l_tmpa_tl
    \iow_now:NV \g__denis_output_stream { \l_tmpa_tl }
  }
  \iow_now:Nn \g__denis_output_stream {
    \usepackage{babel}^^J
    \begin{document}
  }
  \file_get:nnN {\g_file_curr_name_str _codesnippet} {} \l_tmpa_tl
  \iow_now:NV \g__denis_output_stream { \l_tmpa_tl }
  \iow_now:Nn \g__denis_output_stream {
    \end{document}
  }
  \iow_close:N \g__denis_output_stream
  \lstinputlisting{\g_file_curr_name_str _wholefile.tex}
  \end{description}
}

\ExplSyntaxOff

\begin{document}
\begin{preambleaddition}
\usepackage{amsmath}
\end{preambleaddition}
\begin{codesnippet}
\begin{equation}
  \begin{split}
    a & = b+c-d    \\
      & \quad +e-f \\
      & = i
  \end{split}
\end{equation}
\begin{multline}
  a+b+c+d+e+f      \\
  +i+j+k+l+m+n
\end{multline}
\end{codesnippet}
\end{document}

\documentclass{article}
\usepackage{fancyvrb}
\usepackage{listings}

\NewDocumentEnvironment {ecm}{}{
  \VerbatimOut{\jobname-ecm.tex}%
}{
  \endVerbatimOut
  \begin{description}
  \item[preamble's addition]\leavevmode
  \lstinputlisting[
  rangebeginprefix=\\usepackage\[a4paper\]\{,
  rangeendprefix=\\usepackage\{,
  rangesuffix=\},
  linerange=geometry-babel,
  ]{\jobname-ecm.tex}
\item[Code snippet]\leavevmode
  \lstinputlisting[
  rangebeginprefix=\\begin\{,
  rangeendprefix=\\end\{,
  rangesuffix=\},
  linerange=document-document,
  firstnumber=0
  ]{\jobname-ecm.tex}
\item[Whole file]\leavevmode
    \lstinputlisting[numbers=none]{\jobname-ecm.tex}
  \end{description}
}

\lstset
{
  language=[AlLaTeX]TeX, %
  alsolanguage=[LaTeX]TeX,%
  basicstyle=\ttfamily,%
  includerangemarker=false,
}

\begin{document}
\begin{ecm}
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{amsmath}
\usepackage{babel}
\begin{document}
\begin{equation}
  \begin{split}
    a & = b+c-d    \\
      & \quad +e-f \\
      & = i
  \end{split}
\end{equation}
\begin{multline}
  a+b+c+d+e+f      \\
  +i+j+k+l+m+n
\end{multline}
\end{document}
\end{ecm}
\end{document}

\documentclass{article}
\usepackage{xcolor}
\usepackage{fancyvrb}
\usepackage{listings}
\usepackage{accsupp}
\newcommand\emptyaccsupp[1]{\BeginAccSupp{ActualText={}}#1\EndAccSupp{}}

\NewDocumentEnvironment {ecm}{}{
  \VerbatimOut{\jobname-ecm.tex}%
}{
  \endVerbatimOut
  \begin{description}
  \item[preamble's addition]\leavevmode
  \lstinputlisting[
  rangebeginprefix=\\usepackage\[a4paper\]\{,
  rangeendprefix=\\usepackage\{,
  rangesuffix=\},
  linerange=geometry-babel,
  numbers=none,
  frame=shadowbox,
  rulesepcolor=\color{black},
  basicstyle=\ttfamily\footnotesize
  ]{\jobname-ecm.tex}
\item[Code snippet]\leavevmode
  \lstinputlisting[
  rangebeginprefix=\\begin\{,
  rangeendprefix=\\end\{,
  rangesuffix=\},
  linerange=document-document,
  firstnumber=0
  ]{\jobname-ecm.tex}
\item[Whole file]\leavevmode
    \lstinputlisting[numbers=none]{\jobname-ecm.tex}
  \end{description}
}

\colorlet{texcs}{blue}
\colorlet{commentaires}{gray}
% Couleur des mots-clés de niveau 1
\colorlet{keyword}{teal}
% Couleur des mots-clés de niveau 2
% \colorlet{keyword2}{keyword}
\colorlet{keyword2}{red!75!black}
% Couleur des mots-clés de niveau 3
% \colorlet{keyword3}{red!75!black}
\colorlet{keyword3}{violet}
% Couleur des mots-clés de niveau 4
\colorlet{keyword4}{purple}
% Couleur des mots-clés de niveau 5
\colorlet{keyword5}{texcs}

\lstset
{
  language=[AlLaTeX]TeX, %
  alsolanguage=[LaTeX]TeX,%
  gobble=0,%
  breaklines=true,%
  escapechar=ß,%
  numbers=left,%
  numbersep=5pt,%
  numberstyle=\footnotesize\ttfamily\emptyaccsupp,%
  basicstyle=\ttfamily,%
  texcsstyle=*\color{texcs},%
  % Mots-clés de niveau 1 : arguments obligatoires de commandes
  keywordstyle=\color{keyword},%
  % Mots-clés de niveau 2 : arguments et clés optionnels de commandes
  keywordstyle=[2]\color{keyword2},%
  % Mots-clés de niveau 3 : valeurs associés à des clés dans arguments
  % optionnels de commandes
  keywordstyle=[3]\color{keyword3},%
  keywordstyle=[4]\color{keyword4},%
  keywordstyle=[5]\color{keyword5},%
  commentstyle=\color{commentaires}\itshape,%
  fancyvrb=true,%
  columns=flexible,%
  keepspaces=true,%
  includerangemarker=false,
}

\begin{document}
\begin{ecm}
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{mathtools} % charge amsmath
\usepackage{babel}
\begin{document}
\begin{equation}
  \begin{split}
    a & = b+c-d    \\
      & \quad +e-f \\
      & = i
  \end{split}
\end{equation}
\begin{multline}
  a+b+c+d+e+f      \\
  +i+j+k+l+m+n
\end{multline}
\end{document}
\end{ecm}
\end{document}

\documentclass{article}
\usepackage{fontspec}
\usepackage{xparse}

\ExplSyntaxOn
\iow_new:N \g_giampiero_output_stream
\tl_new:N \l__giampiero_write_temp_tl


\AtBeginDocument
 {
   \iow_open:Nn \g_giampiero_output_stream { \c_sys_jobname_str _extra.txt }
 }
\AtEndDocument
 {
  \iow_close:N \g_giampiero_output_stream
 }

\NewDocumentCommand{\writeauthors}{sm}
 {% *-version for doing a variable
  \IfBooleanTF{#1}
   {
    \giampiero_writeauthors:V #2
   }
   {
    \giampiero_writeauthors:n { #2 }
   }
 }

\cs_new_protected:Nn \giampiero_writeauthors:n
 {
  \tl_set:Nn \l__giampiero_write_temp_tl { #1 }
  \tl_replace_all:Nnn \l__giampiero_write_temp_tl { ~and~ } { , }
  \seq_set_split:NnV \l__giampiero_write_temp_seq { , } \l__giampiero_write_temp_tl
  \seq_map_inline:Nn \l__giampiero_write_temp_seq
   {
    \giampiero_write_generic:n  { ##1 }
   }
 }
% This can be used for other similar write operations
\cs_new_protected:Nn \giampiero_write_generic:n
{
  \iow_now:Nn \g_giampiero_output_stream { #1 }
 }

\cs_generate_variant:Nn \seq_set_split:Nnn {NnV}
\cs_generate_variant:Nn \giampiero_writeauthors:n { V }
\ExplSyntaxOff


\begin{document}

\writeauthors{%
  \usepackage{fontspec}\\
  \usepackage{menukeys}
}


\end{document}


\documentclass{article}
\usepackage{fontspec}
\usepackage{menukeys}
\usepackage{mathtools}
\usepackage{xparse} % but it's already loaded by fontspec

\ExplSyntaxOn
% "v" means "verbatim argument"

\iow_new:N \g_denis_output_stream
\tl_new:N \l__denis_write_temp_tl

\AtBeginDocument
{
  \iow_open:Nn \g_denis_output_stream { \g_file_curr_name_str _preambule.tex }
}
\AtEndDocument
{
  \iow_close:N \g_denis_output_stream
}

\cs_new_protected:Nn \denis_writeauthors:n
 {
  \tl_set:Nn \l__denis_write_temp_tl { #1 }
  \tl_replace_all:Nnn \l__denis_write_temp_tl { ~and~ } { , }
  \seq_set_split:NnV \l__denis_write_temp_seq { , } \l__denis_write_temp_tl
  \seq_map_inline:Nn \l__denis_write_temp_seq
   {
    \denis_write_generic:nn { author } { ##1 }
   }
 }

\NewDocumentCommand{\exemple}{+v+v}
{
  \tl_set:Nn \l_preambule_tl { #1 }
  \tl_show:N \l_preambule_tl
  \iow_now:Nn \g_denis_output_stream { #1 }
  \tl_set:Nn \l_code_tl { #2 }
  \texttt{
    \l_preambule_tl
  }
  \par
  \texttt{
    \l_code_tl
  }
  \tl_set_rescan:NnV \l_code_rescanne_tl {} \l_code_tl
  \l_code_rescanne_tl
}

\NewDocumentEnvironment{command}{+v+v}
 {
  % store the two arguments in variables
  % xparse has absorbed them "verbatim"
  \tl_set:Nn \l_macmad_argument_i_tl { #1 }
  \tl_set:Nn \l_macmad_argument_ii_tl { #2 }
  \par
  \noindent
  % print the first argument in the margin
  \makebox[0pt][r]{\ttfamily\l_macmad_argument_i_tl\hspace{2em}}
  \ignorespaces
 }
 {
  \par\nopagebreak
  \noindent
  \textbf{Example:~}
  \texttt
   {
    % print the first argument
    \l_macmad_argument_i_tl
    % print the second argument (but only if non empty)
    \tl_if_blank:VF \l_macmad_argument_ii_tl
     { \l_macmad_argument_ii_tl }
   }
  \\*
  % transform back the first argument from verbatim into "standard tokens"
  \tl_set_rescan:NnV \l_macmad_argument_tl {} \l_macmad_argument_i_tl
  \tl_if_blank:VF \l_macmad_argument_ii_tl
   {
    % do the same for the second argument (if non empty)
    \tl_set_rescan:NnV \l_macmad_temp_tl {} \l_macmad_argument_ii_tl
    % append the rescanned text to the previous
    \tl_put_right:Nx \l_macmad_argument_tl { \exp_not:V \l_macmad_temp_tl }
   }
  % process the contents of the rescanned arguments
  \l_macmad_argument_tl
  \par
 }

% allocate the variables
\tl_new:N \l_macmad_argument_tl
\tl_new:N \l_macmad_argument_i_tl
\tl_new:N \l_macmad_argument_ii_tl
\tl_new:N \l_macmad_temp_tl
% generate a variant command
\cs_generate_variant:Nn \tl_set_rescan:Nnn { NnV }
\ExplSyntaxOff

\begin{document}

\exemple{
\usepackage{mathtools} % amsmath chargé
}{
\begin{equation}
  \begin{split}
    a & = b+c-d    \\
      & \quad +e-f \\
      & = i
  \end{split}
\end{equation}
\begin{multline}
  a+b+c+d+e+f      \\
  +i+j+k+l+m+n
\end{multline}
}

\begin{command}{\keys}{{Shift + F5}}
This command allows you to add keyboard strokes.
\end{command}

\begin{command}{
    \begin{center}
      Coucou
    \end{center}
  }{}
This command prints the \TeX\ logo.
\end{command}

\begin{command}{\textbf}{{\TeX}}
This command prints its argument in bold.
\end{command}

\begin{command}{\framebox}{[3cm][l]{\TeX}}
This command frames text in a specified area.
\end{command}

\end{document}

\documentclass{article}

\newcommand{\test}{%
\begin{filecontents}[overwrite]{\jobname-codecomplet.tex}
\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\InputIfFileExists{\jobname-preambule}{}{}
\usepackage{babel}
\pagestyle{empty}
\begin{document}
\InputIfFileExists{\jobname-code}{}{}
\end{document}
\end{filecontents}
}

\begin{document}
Coucou
\test{}
\end{document}


\documentclass{article}
\usepackage{listings}
\lstset{basicstyle=\ttfamily,language=[AlLaTeX]TeX}

\begin{document}
\NewDocumentEnvironment { twice } { O{\ttfamily} +b }
{
\begin{filecontents}[overwrite]{coucou.tex}
  #2
\end{filecontents}
  \lstinputlisting{coucou.tex}
} {}

\begin{twice}
\textbf{Hello world!}
\end{twice}
\end{document}


\documentclass{article}

% dummy text for examples
\usepackage{lipsum}

% admonition blocks around text to inform/alert readers
\usepackage{awesomebox}
% or without using xelatex
\usepackage{alertmessage}

\begin{document}

% awesomebox
\tipbox{\lipsum[2]}
\notebox{\lipsum[3]}
\warningbox{\lipsum[4]}
\cautionbox{\lipsum[5]}
\importantbox{\lipsum[5]}

% alertmessage
\alertinfo{\lipsum[2]}
\alertsuccess{\lipsum[2]}
\alertwarning{\lipsum[2]}
\alerterror{\lipsum[2]}

\begin{alertinfo}
Test
\end{alertinfo}


\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{varioref}
\usepackage{lipsum}
\usepackage{tcolorbox}
\usepackage{babel}
\usepackage{hyperref}

\tcbuselibrary{skins,breakable,minted}

\tcbset{listing engine=minted,
minted style=colorful,
minted language=latex,
minted options={fontsize=\small,breaklines,autogobble,linenos,numbersep=3mm},
colback=blue!5!white,colframe=blue!75!black,listing only,
left=5mm,enhanced,
overlay={\begin{tcbclipinterior}\fill[red!20!blue!20!white] (frame.south west)
    rectangle ([xshift=5mm]frame.north west);\end{tcbclipinterior}}}

\newtcblisting{lstlisting}[1][]{}

\begin{document}
\begin{lstlisting}[language=latex]
\documentclass[convert,varwidth,french]{standalone}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}
Coucou
\end{document}
\end{lstlisting}

Comme nous le verrons à la section \ref{sec:coucou}

\lipsum[1-15]

\section{Coucou}
\label{sec:coucou}

Blah !

\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{varioref}
\usepackage{lipsum}
\usepackage{tcolorbox}
\usepackage{babel}
\usepackage{hyperref}

\tcbuselibrary{skins,breakable,minted}

\tcbset{listing engine=minted,
minted style=colorful,
minted language=latex,
minted options={fontsize=\small,breaklines,autogobble,linenos,numbersep=3mm},
colback=blue!5!white,colframe=blue!75!black,listing only,
left=5mm,enhanced,
overlay={\begin{tcbclipinterior}\fill[red!20!blue!20!white] (frame.south west)
    rectangle ([xshift=5mm]frame.north west);\end{tcbclipinterior}}}

\newtcblisting{lstlisting}[1][]{}

\begin{document}
\begin{lstlisting}[language=latex]
\documentclass[convert,varwidth,french]{standalone}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}
Coucou
\end{document}
\end{lstlisting}

Comme nous le verrons à la section \ref{sec:coucou}

\lipsum[1-15]

\section{Coucou}
\label{sec:coucou}

Blah !

\end{document}

\documentclass{article}
\usepackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
% \usepackage{fourier}
\else
% \usepackage{fourier-otf}
\fi
\usepackage[p,osf,scaled=.98,space]{erewhon}
\begin{document}
L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER

\textit{L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER}

\textsl{L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER}

\bfseries
L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER

\textit{L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER}

\textsl{L'AS L'ÂGE L'ÉTÉ L'ÎLE L'OR L'URNE L'YPRES L'HIVER}
\end{document}

\documentclass{beamer}
\setbeamertemplate{blocks}[rounded][shadow=true]
\setbeamercolor{background canvas}{bg=red}
\usepackage{kpfonts}
\begin{document}
\begin{frame}
  \begin{block}{Foo}
    Bar
  \end{block}
\end{frame}
\end{document}

\documentclass{article}
\usepackage{expl3}
\usepackage{xparse}
\begin{document}

\ExplSyntaxOn

\tl_new:N \g__matl_tl

\keys_define:nn{keylib}{%
    macle .tl_gset:N = \g__matl_tl,
    macle .default:n = defaut
}

\NewDocumentCommand\macommande { o m } {
   \IfNoValueF {#1}
   {
       \keys_set:nn { keylib } { #1 }
   }
  Ma~commande~{#2}~et~la~valeur~de~macle~\tl_use:N \g__matl_tl.
  \tl_clear:N \g__matl_tl
}
\ExplSyntaxOff

\macommande{Test}

\macommande{Test}[foo]
\end{document}

\documentclass{article}
\usepackage{tcolorbox}

\tcbset{colback=red!5!white,colframe=red!75!black}

\newcommand{\test}{%
  \begin{tcolorbox}
    Lorem ipsum dolor sit amet, consectetuer adipiscing elit.  Ut purus elit,
    vestibulum ut, placerat ac, adipiscing vitae, felis.
  \end{tcolorbox}
}

\begin{document}
\test{}

\tcbset{halign=flush center}

\test{}

\tcbset{halign=center}

\test{}
\end{document}

\documentclass[t]{beamer}
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\usepackage{csquotes}
\usepackage{tcolorbox}

\usetheme[hideothersubsections]{PaloAlto}

\tcbset{colback=red!5!white,colframe=red!75!black}

\newcommand{\test}{%
  \begin{tcolorbox}
    Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
  \end{tcolorbox}
}

\begin{document}
\begin{frame}

\test{}

\tcbset{halign=flush center}

\test{}

\tcbset{halign=center}

\test{}

\end{frame}
\end{document}

\documentclass[varwidth=true]{standalone}
\usepackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\else
\usepackage{kpfonts-otf}
\fi
\usepackage{xcolor}

\newcommand{\test}{%
  $1$%
}

\begin{document}
\begin{tabular}{c}
  \test\\[-.38cm]
  \color{green}\small\test\\[-.38cm]
  \color{red}\footnotesize\test\\[-.38cm]
  \color{blue}\scriptsize\test\\[-.38cm]
  \color{orange}\tiny\test
\end{tabular}
\end{document}

\documentclass[t]{beamer}
\usetheme[hideothersubsections]{PaloAlto}
\begin{document}
\begin{frame}
  Foo
  \begin{onlyenv}<2->
    \begin{alertblock}{}
      Foo
    \end{alertblock}
  \end{onlyenv}
\end{frame}
\begin{frame}
  Bar
  \begin{onlyenv}<2->%
    \begin{alertblock}{}
      Bar
    \end{alertblock}
  \end{onlyenv}
\end{frame}
\end{document}

\documentclass{article}
\usepackage{lmodern}
\usepackage{tcolorbox}

\tcbuselibrary{skins,breakable,minted}

\tcbset{listing engine=minted,
minted style=colorful,
minted language=latex,
minted options={fontsize=\small,breaklines,autogobble,linenos,numbersep=3mm},
colback=blue!5!white,colframe=blue!75!black,listing only,
left=5mm,enhanced,
overlay={\begin{tcbclipinterior}\fill[red!20!blue!20!white] (frame.south west)
    rectangle ([xshift=5mm]frame.north west);\end{tcbclipinterior}}}

\newtcblisting{lstlisting}{%
  % colback=red!5!white,
  % colframe=red!75!black
}

\begin{document}
\begin{lstlisting}
\documentclass[convert,varwidth,french]{standalone}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}
Coucou
\end{document}
\end{lstlisting}
\end{document}

\documentclass[convert,varwidth,french]{standalone}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}
Coucou
\end{document}

\documentclass{article}
\usepackage{lmodern}

\begin{document}
\slshape
coucou

\rmfamily
coucou

\sffamily
coucou

\ttfamily
coucou
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{tikz} % load TikZ for some examples
% \usepackage{expl3} % load latex3 packages
\usepackage{lmodern}
\begin{document}
\newcommand{\mynamea}{John Doe}
\newcommand{\mynameb}{\mynamea}
\newcommand{\myname}{\mynameb}
My name is \myname.
\end{document}


\documentclass{article}
\usepackage{fontspec}
\makeatletter
\DeclareUnicodeEncoding{luxi}{
  \input{tuenc.def}
  \DeclareTextCommand{\^}{\UnicodeEncodingName}[1]{\accent"02C6\relax#1}
  \DeclareUnicodeComposite{\^}              {}{"005E}
  \DeclareUnicodeComposite{\^}             {A}{"00C2}
  \DeclareUnicodeComposite{\^}             {E}{"00CA}
  \DeclareUnicodeComposite{\^}             {I}{"00CE}
  \DeclareUnicodeComposite{\^}             {O}{"00D4}
  \DeclareUnicodeComposite{\^}             {U}{"00DB}
  \DeclareUnicodeComposite{\^}             {a}{"00E2}
  \DeclareUnicodeComposite{\^}             {e}{"00EA}
  \DeclareUnicodeComposite{\^}             \i {"00EE}
  \DeclareUnicodeComposite{\^}             {i}{"00EE}
  \DeclareUnicodeComposite{\^}             {o}{"00F4}
  \DeclareUnicodeComposite{\^}             {u}{"00FB}
  \DeclareUnicodeComposite{\^}             {C}{"0108}
  \DeclareUnicodeComposite{\^}             {c}{"0109}
  \DeclareUnicodeComposite{\^}             {G}{"011C}
  \DeclareUnicodeComposite{\^}             {g}{"011D}
  \DeclareUnicodeComposite{\^}             {H}{"0124}
  \DeclareUnicodeComposite{\^}             {h}{"0125}
  \DeclareUnicodeComposite{\^}             {J}{"0134}
  \DeclareUnicodeComposite{\^}             \j {"0135}
  \DeclareUnicodeComposite{\^}             {j}{"0135}
  \DeclareUnicodeComposite{\^}             {S}{"015C}
  \DeclareUnicodeComposite{\^}             {s}{"015D}
  \DeclareUnicodeComposite{\^}             {W}{"0174}
  \DeclareUnicodeComposite{\^}             {w}{"0175}
  \DeclareUnicodeComposite{\^}             {Y}{"0176}
  \DeclareUnicodeComposite{\^}             {y}{"0177}
}
\newcommand{\luxi@accent}[2]{%
  \leavevmode\vbox{\offinterlineskip
    \ialign{\hfil##\hfil\cr\char#1\cr\noalign{\vskip-1ex}#2\cr}%
  }%
}
\makeatother

\setmonofont{luxim}[
  Path=/usr/share/fonts/drakfont/ttf/,% <--- adjust to your setting
  Extension=.ttf,
  NFSSEncoding=luxi,
  UprightFont=*r,
  BoldFont=*b,
  ItalicFont=*ri,
  BoldItalicFont=*bi,
  Scale=0.8,
]

\pagestyle{empty}

\begin{document}

\^a \ttfamily\^m\^a\^j

\end{document}

% \documentclass[t]{beamer}
\documentclass{article}

\usepackage{etoolbox}
\usepackage{accsupp}
\usepackage{listings}
\usepackage{lmodern}

\lstset{numbers=left}

\newcommand\emptyaccsupp[1]{\BeginAccSupp{ActualText={}}#1\EndAccSupp{}}

\ExplSyntaxOn
\makeatletter

\int_new:N \l_index_font_size_int

\@ifclassloaded{beamer}{%
  \seq_const_from_clist:Nn \c_font_sizes_seq {%
    TINY,Tiny,tiny,scriptsize,footnotesize,small,normalsize,large,Large,LARGE,huge,Huge
  }
}{
  \seq_const_from_clist:Nn \c_font_sizes_seq {%
              tiny,scriptsize,footnotesize,small,normalsize,large,Large,LARGE,huge,Huge
  }
  \renewenvironment{frame}[1][]{\newpage}{}
  \newcommand{\frametitle}[1]{}
}%

\seq_map_inline:Nn \c_font_sizes_seq
{
  \cs_new_eq:cc {ORI_#1} {#1}
}

\int_gset:Nn \g_tmpa_int { \seq_count:N \c_font_sizes_seq }

% \apptocmd{\Huge}{
%   \int_set:Nn \l_tmpb_int { 10 - \g_tmpa_int + 5}
%   % \int_set:Nn \l_index_font_size_int { \l_tmpb_int }
%   \int_use:N \l_tmpb_int
% }{}{\aaa{}}

\cs_new_protected:Nn \__map_test:nn
{
  \csgappto{ORI_#2}{
    \int_set:Nn \l_tmpb_int { #1 - \g_tmpa_int + 5}
    \int_show:N \l_tmpb_int
    \tl_set:Nn \l_tmpa_tl {ORI_#2}
    \tl_show:N \l_tmpa_tl
    % \int_set:Nn \l_index_font_size_int { \l_tmpb_int }
    % \int_use:N \l_tmpb_int
  }
}

\seq_map_indexed_function:NN \c_font_sizes_seq \__map_test:nn

\cs_new_protected:Nn \__rel_size:n
{
  \int_set:Nn \l_index_font_size_int {#1+\g_tmpa_int-5}
  % \int_show:N \l_index_font_size_int
  \tl_set:Nx \l_tmpb_tl { \seq_item:Nn \c_font_sizes_seq { \l_index_font_size_int } }
  % \tl_show:N \l_tmpb_tl
  \__text_font_size:n { ORI_\l_tmpb_tl }
}

\cs_new_protected:Nn \__simplified_font_size_names:n
{
  \str_case:nn {#1} {
    {tiny} { ORI_#1 }
    {script} { ORI_#1size }
    {foot} { ORI_#1notesize }
    {small} { ORI_#1 }
    {normal} { ORI_#1size }
  }
}

\cs_new_protected:Nn \__text_font_size:n
{
  \use:c { #1 }
}

\cs_new_protected:Nn \__code_font_size:n
{
  \lstset{%
    numberstyle=\__rel_size:n { #1 }\ttfamily\emptyaccsupp,%
    basicstyle=\ttfamily\__rel_size:n { #1 }%
  }%
}

\NewDocumentCommand \relsize { m }
{
  \__rel_size:n { #1 }
}

\NewDocumentCommand \codetextsize
 { m m }
{
  \__code_font_size:n {#1}
  \__rel_size:n {#2}
}

\makeatother
\ExplSyntaxOff

\begin{document}



{\small smaller}
{\Huge%
  \relsize{-1} smaller
}

\begin{frame}
  \frametitle{Relative sizes}
  \relsize{-6} Foo%
  \relsize{-5} Foo%
  \relsize{-4} Foo%
  \relsize{-3} Foo%
  \relsize{-2} Foo%
  \relsize{-1} Foo%
  \relsize{0} Foo%
  \relsize{1} Foo%
  \relsize{2} Foo%
  \relsize{3} Foo%
  \relsize{4} Foo%
  \relsize{5} Foo%
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
  \codetextsize{-6}{-6}
  Foo (TINY)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
  \codetextsize{-5}{-5}
  Foo (Tiny)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
  \codetextsize{-4}{-4}
  Foo (tiny)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{-3}{-3}
Foo (scriptsize)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{-2}{-2}
Foo (footnotesize)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{-1}{-1}
Foo (small)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{0}{0}
Foo (normalsize)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{1}{1}
Foo (large)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{2}{2}
Foo (Large)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{3}{3}
Foo (LARGE)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{4}{4}
Foo (huge)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\begin{frame}[fragile]
  \frametitle{Test}
\codetextsize{5}{5}
Foo (Huge)
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
\end{frame}

\end{document}

\documentclass{article}
\usepackage{lmodern}

\begin{document}
\ExplSyntaxOn
\newcommand{\strcase}[1]{%
  \str_case:nn {#1} {
    {TeX} {\use:c{#1}\space is\space the\space predecessor\space of\space \LaTeX}
    {LaTeX} {\use:c{#1}\space is\space the\space successor\space of\space \TeX}
  }
}\ExplSyntaxOff
\end{document}

\documentclass{beamer}

\usepackage{libertine}
% \usepackage{lmodern}

\setbeamercolor{background canvas}{bg=yellow}

\begin{document}
\begin{frame}
  \begin{beamerboxesrounded}[shadow=true]{Theorem}
    $A = B$.
  \end{beamerboxesrounded}
\end{frame}
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[cmintegrals,cmbraces]{newtxmath}
\usepackage{ebgaramond-maths}
% \usepackage[cmintegrals,cmbraces]{newtxmath}
% \usepackage{ebgaramond}
% \usepackage{garamondx}
% \usepackage[lining,semibold,scaled=1.05]{ebgaramond}
% Latex BOLD renders with ebgaramond semibold
% \usepackage[varqu,varl]{inconsolata}% a typewriter font must be defined
\usepackage{mathtools}
% \usepackage[ebgaramond,vvarbb,subscriptcorrection]{newtxmath} % STIX Bbb
% \usepackage{bm}% load after all math to give access to bold math
\usepackage[math]{blindtext}
\usepackage{hyperref}
\begin{document}
Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de
bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789

\emph{Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de
  bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789}

\textsf{Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de
bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789}

\textsl{Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de
bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789}

\textsc{Dès Noël où un zéphyr haï me vêt de glaçons würmiens}

\textsc{je dîne d'exquis rôtis de
bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789}

\texttt{Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de
bœuf au kir à l'aÿ d'âge mûr \& cætera ! 0123456789}

$\mathbb{R}$

\Blinddocument
\end{document}

\documentclass{article}
\usepackage{fontspec}
\usepackage{listings}

\makeatletter
\lst@InputCatcodes
\def\lst@DefEC{%
 \lst@CCECUse \lst@ProcessLetter
  ^^80^^81^^82^^83^^84^^85^^86^^87^^88^^89^^8a^^8b^^8c^^8d^^8e^^8f%
  ^^90^^91^^92^^93^^94^^95^^96^^97^^98^^99^^9a^^9b^^9c^^9d^^9e^^9f%
  ^^a0^^a1^^a2^^a3^^a4^^a5^^a6^^a7^^a8^^a9^^aa^^ab^^ac^^ad^^ae^^af%
  ^^b0^^b1^^b2^^b3^^b4^^b5^^b6^^b7^^b8^^b9^^ba^^bb^^bc^^bd^^be^^bf%
  ^^c0^^c1^^c2^^c3^^c4^^c5^^c6^^c7^^c8^^c9^^ca^^cb^^cc^^cd^^ce^^cf%
  ^^d0^^d1^^d2^^d3^^d4^^d5^^d6^^d7^^d8^^d9^^da^^db^^dc^^dd^^de^^df%
  ^^e0^^e1^^e2^^e3^^e4^^e5^^e6^^e7^^e8^^e9^^ea^^eb^^ec^^ed^^ee^^ef%
  ^^f0^^f1^^f2^^f3^^f4^^f5^^f6^^f7^^f8^^f9^^fa^^fb^^fc^^fd^^fe^^ff%
  ^^^^20ac^^^^0153^^^^0152% nouveau pour xetex
  ^^00}
\lst@RestoreCatcodes
\makeatother
\begin{document}
\begin{lstlisting}
bœuf BŒeuf a€e
Dès Noël où un zéphyr haï me
vêt de glaçons würmiens je
dîne d'exquis rôtis de bœuf
au kir à l'aÿ d'âge mûr \& cætera!
\end{lstlisting}

\begin{lstlisting}[extendedchars=false]
bœuf BŒeuf a€e
Dès Noël où un zéphyr haï me
vêt de glaçons würmiens je
dîne d'exquis rôtis de bœuf
au kir à l'aÿ d'âge mûr \& cætera!
\end{lstlisting}


\begin{lstlisting}[language=XML]
bœuf BŒeuf a€e
Dès Noël où un zéphyr haï me
vêt de glaçons würmiens je
dîne d'exquis rôtis de bœuf
au kir à l'aÿ d'âge mûr \& cætera!
\end{lstlisting}
\end{document}

\documentclass{article}

\ExplSyntaxOn
\NewDocumentCommand{\unit}{}
 {
  % if we're not in math mode open it and remember to close it
  \mode_if_math:F { $ \bool_set_true:N \l_merzong_close_bool }
  % clear the container for the units
  \seq_clear:N \merzong_units_seq
  % start looking forward for an open brace
  \merzong_scan_arg:
 }

\cs_new_protected:Npn \merzong_scan_arg:
 {
  \peek_catcode:NTF \c_group_begin_token
   {% the next token is an open brace, absorb the argument
    \merzong_add_unit:n
   }
   {% the next token is not an open brace, deliver the units
    % absorbed so far, with \unitmulti between them
    \seq_use:Nn \merzong_units_seq { \unitmulti }
    % close math mode if we started it
    \bool_if:NT \l_merzong_close_bool { $ }
   }
 }
\cs_new_protected:Npn \merzong_add_unit:n #1
 {
  % absorb the argument and add it to the sequence
  \seq_put_right:Nn \merzong_units_seq { \mathrm{#1} }
  % restart the recursion
  \merzong_scan_arg:
 }

\seq_new:N \merzong_units_seq
\ExplSyntaxOff

\newcommand\useunitmultidot{\let\unitmulti=\cdot}
\newcommand\useunitmultispace{\let\unitmulti=\,}
\useunitmultidot % initialize

\begin{document}

\section{Centered dot}

\unit{kg}{m^2}{s^{-2}}

\section{Space}
\useunitmultispace

\unit{kg}{m^2}

\end{document}

\documentclass{beamer}
\usepackage{tcolorbox}
\tcbuselibrary{documentation}
\begin{document}
\begin{frame}
  \begin{docKeys}[
    doc no index,
    doc name = version,
    ]
    {
      {
        doc parameter = {=\docValue{foo}},
      },
      {
        doc parameter = {=\docValue{foo*}},
      },
    }
    %
    Foo\pause{}. \docValue{bar} :
    \begin{enumerate}
    \item Version en date du \meta{date du jour} ;
    \item  manquants
    \item en pages de titre
    \item mention Version soumise en date du
        \meta{date}\footnote<.->[frame]{Uniquement avec \docValue{submitted*}.}
      en pieds de pages.
    \end{enumerate}
  \end{docKeys}
\end{frame}
\end{document}

\documentclass{article}
\usepackage[colorlinks]{hyperref}%
\usepackage{intopdf}
\begin{document}
The source of the document is attached
\attachandlink{\jobname.tex}[application/x-tex]{The source of this
  document}{here}.

\url{www.test.org}
\end{document}

\documentclass[french,t]{beamer}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

% Police `kpfonts'. On peut lui en préférer une autre mais il est conseillé de
% privilégier une police fournissant des petites capitales sans serif
% (libertine, fourier, etc.).
\usepackage{kpfonts}

% Le package suivant n'est chargé ici que pour fournir des images « factices »
% (cf. commandes \logo et \titlegraphic ci-dessous).
\usepackage{mwe}
%
\usepackage{babel}
%
% Choix du thème Beamer. Comme tous ceux avec barre latérale contenant la table
% des matières, le thème `PaloAlto' dispose de l'option `hideothersubsections'
% qui affiche cette table des matières en « accordéon ».
\usetheme[hideothersubsections]{PaloAlto}

\title{Titre de la présentation}
% En cas de titre long, utiliser plutôt :
% \title[Version courte du titre]{Titre de la présentation (long)}

% À utiliser seulement s'il y a un sous-titre.
\subtitle{Sous-titre de la présentation}
% En cas de sous-titre long, utiliser plutôt :
% \subtitle[Version courte du sous-titre]{Sous-titre de la présentation (long)}

\author{Prénom \textsc{Nom}}
% En cas de nom d'auteur long, utiliser plutôt par exemple :
% \author[P. \textsc{Nom}]{Prénom \textsc{Nom} (long)}

\institute{Institut}
% En cas d'institut long, utiliser plutôt :
% \institute[Version courte du l'institut]{Institut (long)}

% Graphique de titre. Il peut comporter plusieurs images, comme ici
% (régulièrement espacées sur la ligne).
\titlegraphic{%
  \hfill%
  \includegraphics[width=.25\linewidth]{example-image-a}%
  \hfill%
  \includegraphics[width=.25\linewidth]{example-image-b}%
  \hfill%
  \mbox{}
}

\date{Date}
% En cas de date longue, utiliser plutôt :
% \date[Version courte de la date]{Date (longue)}

% Ce qui est passé en argument des deux commandes suivantes n'est inséré que
% dans le catalogue d'information (c.-à-d. en métadonnées du) PDF et n'est pas
% visible dans le PDF lui-même. Peut être ignoré.
\subject{Sujet}
\keywords{Mots clés}

% Logo inséré sur chacun des frames du diaporama.
\logo{\includegraphics[width=1.5cm]{example-image}}

% La commande suivante insère automatiquement au début de chaque section une
% table des matières partielle.
\AtBeginSection{%
  \begin{frame}
    \frametitle{Plan}
    \tableofcontents[
         sectionstyle=show/shaded,
      subsectionstyle=hide
    ]
  \end{frame}
}
% La commande suivante insère (dans le mode « beamer » seulement)
% automatiquement au début de chaque sous-section une table des matières
% partielle.
\AtBeginSubsection{%
  \begin{frame}<beamer>
    \frametitle{Plan}
    \tableofcontents[
         sectionstyle=show/hide,
      subsectionstyle=show/shaded/hide
    ]
  \end{frame}
}

% Hack permettant de faire figurer les numéros de « transparents » (à la place
% des symboles de navigation, peu utiles), en cas de thème avec barre latérale.
\ifcsdef{beamer@sidebarwidth}{%
  \setbeamertemplate{navigation symbols}{%
    \ifbool{beamer@plainframe}{%
    }{%
      \color{black}\tiny\insertframenumber%
    }%
  }%
}{%
}

% Si vous ne souhaitez pas que tout ce qui doit être découvert le soit pas
% à pas, commentez la commande suivante :
\beamerdefaultoverlayspecification{<+->}

\begin{document}

\begingroup
% Hack permettant de centrer le titre dans la page en cas de thème avec barre
% latérale.
\ifcsdef{beamer@sidebarwidth}{\setlength{\hoffset}{-.5\csuse{beamer@sidebarwidth}}}{}
\begin{frame}[plain]
  \maketitle
\end{frame}
\endgroup

\begin{frame}
  \frametitle{Plan}
  % On affiche le plan global. Pour éviter qu'il ne soit trop détaillé, on en
  % masque les sous-sections (option `hideallsubsections').
  \tableofcontents[hideallsubsections]
  % Vous pourriez souhaiter ajouter l'option [pausesections] à la
  % commande \tableofcontents ci-dessus pour que les sections de votre plan se
  % découvrent progressivement.
\end{frame}

% Structurer un exposé est une tâche difficile et la structure
% suivante peut ne pas être appropriée. Voici quelques règles
% qui s'appliquent à cette solution :

% - Exactement 2 ou 3 sections (à part le sommaire).
% - Au *plus* 3 sous-sections par section.
% - Discours de 30 s à 2 mn par « frame » (groupe de transparents). Il
%   devrait ainsi y avoir entre 15 et 30 « frames », tout compris.

% - Un public de conférence sait probablement très peu de ce dont
%   vous allez parler. Donc *simplifiez* !
% - Dans un exposé de 20 mn, aborder toutes les idées essentielles est
%   déjà assez difficile. Passez les détails, même si le discours est
%   moins précis que vous le jugez nécessaire.
% - Si vous omettez des détails qui sont vitaux à la
%   preuve/l'implémentation, signalez-le juste une fois. Tout le monde
%   sera content de cela.

\section{Motivation}

\subsection{Le problème basique étudié}

\begin{frame}
  % L'usage typographique français veut que seules
  % les 1re lettres des titres soient accentuées.
  % En anglais, toutes les initiales des titres
  % peuvent être en capitales.
  %
  % Un titre doit résumer la diapositive de manière
  % compréhensible à tous ceux qui ne suivraient pas tout
  % le contenu de la diapositive elle-même.
  \frametitle{Faire des titres informatifs}
  \framesubtitle{Les sous-titres sont optionnels}

\end{frame}


\begin{frame}
  \frametitle{Faire des titres informatifs}
  Bla bla !
\end{frame}

\subsection{Travaux antérieurs}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Ble ble !
\end{frame}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Bli bli !
\end{frame}

\section{Nos résultats}

\subsection{Résultats principaux}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Blo blo !
\end{frame}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Blu blu !
\end{frame}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Bly bly !
\end{frame}

\subsection{Principes des implémentations}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Bla bla !
\end{frame}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Ble ble !
\end{frame}

\begin{frame}
  \frametitle{Faire des titres informatifs}
  Bli bli !
\end{frame}

\section{Conclusion}

\begin{frame}
  \frametitle{Conclusion}
  Blo blo !
\end{frame}

\begin{frame}[c]
	\frametitle{Tigre}
	\begin{columns}
		%
		\begin{column}<1->{0.5\textwidth}
			\begin{center}
				\includegraphics[width=0.4\linewidth]{tiger}
			\end{center}
		\end{column}
		%
		\begin{column}<2->{0.5\textwidth}
			\begin{description}
				\item[\og anticonstitutionnellement\fg{} :] mot long
				\item[\og y\fg{} :] mot court
				\item[\og ordinateur\fg{} :] mot ni long, ni court
				\end{description}
		\end{column}
		%
	\end{columns}
\end{frame}

\begin{frame}
	\frametitle{description}
		\framesubtitle{sous description}
\end{frame}

\end{document}

% \documentclass{article}
\documentclass[t]{beamer}
\usetheme{PaloAlto}
\usepackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\else
\usepackage{fontspec}
\ifluatex
\defaultfontfeatures{Renderer=HarfBuzz}
\fi
% \usepackage[T1]{fontenc}
\usepackage{biolinum}
\setmainfont{KpRoman}
\setsansfont{KpSans}
\DeclareTextSymbol{\textlangle}\UnicodeEncodingName{"3008}
\DeclareTextSymbol{\textrangle}\UnicodeEncodingName{"3009}
\setmonofont[Scale=0.85]{Luxi Mono}
\fi

\newcommand{\meta}[2][red]{{\color{#1}{\normalfont\textlangle}\emph{\texttt{#2}}{\normalfont\textrangle}}}


\begin{document}
\begin{frame}
\end{frame}
\end{document}

\documentclass{beamer}
\usetheme{PaloAlto}
\usepackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\else
\usepackage{fontspec}
\ifluatex
\defaultfontfeatures{Renderer=HarfBuzz}
\fi
% \usepackage[T1]{fontenc}
\usepackage{biolinum}
\setmainfont{KpRoman}
\setsansfont{KpSans}
\DeclareTextSymbol{\textlangle}\UnicodeEncodingName{"3008}
\DeclareTextSymbol{\textrangle}\UnicodeEncodingName{"3009}
\setmonofont[Scale=0.85]{Luxi Mono}
\usepackage{kpfonts-otf}
\fi
\begin{document}
\begin{frame}
  \textit{Test}


  \Huge%
  \begin{alertblock}{Test}
    $A\Longrightarrow B$
  \end{alertblock}
\end{frame}
\end{document}

\documentclass[12pt,french]{article}
\usepackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\else
\usepackage{fontspec}
\fi
\usepackage[a4paper]{geometry}
\geometry{vmargin={2pt,15.92cm},includefoot}
\usepackage{xcolor}
\usepackage{lmodern}
% \usepackage{pagegrid}
%
\usepackage{lipsum}
% \usepackage{parskip}
% \usepackage[indent]{parskip}
% \usepackage[parfill]{parskip}
\usepackage{babel}
\begin{document}
\lipsum[1-2]

\textcolor{blue}{\lipsum[13]}

\textcolor{red}{\lipsum[14]}

\lipsum[15]
\end{document}

%%% Local Variables:
%%% mode: latex
%%% TeX-master: t
%%% End:

\documentclass[french,12pt]{article}
\RequirePackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\usepackage[scaled=0.85]{luximono}
% \usepackage[scaled=0.85]{beramono}
% Hack pour que les copiés-collés de code fonctionnent aussi depuis Acrobat
% Reader (cf. https://tex.stackexchange.com/q/369596/18401)
\pdfglyphtounicode{hyphen}{002D}
\pdfgentounicode=1
% Tentative pour que les documents à imprimer (4 pages sur 1) contiennent les
% bons glyphes. Cf. https://www.tex.ac.uk/FAQ-pdf-fig-chars.html
\pdfinclusioncopyfonts=1
% Contournement évitant l'erreur « There was a problem reading this document
% (131) ». Cf. https://tex.stackexchange.com/q/64448/18401
\pdfobjcompresslevel=0
%
\else
\usepackage{fontspec}
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\usepackage[scaled=0.85]{luximono}
\fi
\usepackage[a4paper]{geometry}
\usepackage{mathtools}
\usepackage{amssymb}
\usepackage{babel}
\usepackage{listings}

\lstset{
  basicstyle=\ttfamily,   % Use \ttfamily for source code listings
  escapeinside=~~
}


\begin{document}
% $Dès Noël, où un zéphyr haï me vêt de glaçons würmiens, je dîne d'exquis rôtis
% de bœuf au kir, à l'aÿ d'âge mûr, cætera$

\itshape\texttt{\^m}

\begin{lstlisting}
~\itshape\texttt{\^m}~
\end{lstlisting}
\end{document}

\documentclass[french,12pt]{article}
\RequirePackage{iftex}
\ifpdftex
\usepackage[T1]{fontenc}
\usepackage{kpfonts}
\usepackage[scaled=0.85]{luximono}
% \usepackage[scaled=0.85]{beramono}
% Hack pour que les copiés-collés de code fonctionnent aussi depuis Acrobat
% Reader (cf. https://tex.stackexchange.com/q/369596/18401)
\pdfglyphtounicode{hyphen}{002D}
\pdfgentounicode=1
% Tentative pour que les documents à imprimer (4 pages sur 1) contiennent les
% bons glyphes. Cf. https://www.tex.ac.uk/FAQ-pdf-fig-chars.html
\pdfinclusioncopyfonts=1
% Contournement évitant l'erreur « There was a problem reading this document
% (131) ». Cf. https://tex.stackexchange.com/q/64448/18401
\pdfobjcompresslevel=0
%
\else
\usepackage{unicode-math}
\setmainfont{KpRoman}
\setsansfont{KpSans}
\setmonofont[Scale=0.85]{Luxi Mono}
\setmathfont{KpMath-Regular.otf}
% % \RequirePackage{xltxtra}
% \setmainfont{Latin Modern Roman}
% Hack pour que les copiés-collés de code fonctionnent aussi depuis Acrobat
% Reader (cf. https://tex.stackexchange.com/q/369596/18401)
\pdfextension glyphtounicode{hyphen}{002D}
\pdfvariable inclusioncopyfonts=1
\pdfvariable gentounicode=1
\fi
\usepackage[a4paper]{geometry}
\usepackage{tcolorbox}
\usepackage{babel}
\usepackage[locale=FR,detect-all]{siunitx}

\tcbuselibrary{skins,xparse,breakable,hooks}

\newlength{\defaultparindent}
\setlength{\defaultparindent}{\parindent}

\DeclareTColorBox{ExempleAReproduire}{ O{cyan}  !O{Exemple à reproduire} !O{} }
{
  enhanced,
  colframe=#1!75!black,
  colback=#1!5!white,
  breakable,
  % size=minimal,
  size=normal,
  text width=\textwidth,
  left skip=-5.5mm,
  right skip=5.5mm,
  opacityback=0.5,
  skin=enhanced jigsaw,
  before upper={\parindent\defaultparindent\footnotesize},
  fontupper={%
    \setmainfont{Latin Modern Roman}[
    SmallCapsFont=Latin Modern Roman Caps,
    SmallCapsFeatures = { Letters=SmallCaps},
    ItalicFeatures  = {SmallCapsFont=LMRomanCaps10-Oblique}
    ]
    \setmathfont{latinmodern-math.otf}
    % \setmathfont{Latin Modern Math}[version=lm]
  },
  after app={\setmathfont{KpMath-Regular.otf}},
  title={#2},
  #3
}

\NewDocumentCommand\exemple{ o O{} o m }{
  \tcbincludegraphics[enhanced,
  IfValueTF={#3}{colframe=#3!75!black,colback=#3!5!white}{colframe=cyan!75!black,colback=cyan!5!white},
  size=normal,
  text width=\textwidth,
  left skip=-5.5mm,
  right skip=5.5mm,
  opacityback=0.5,
  skin=enhanced jigsaw,
  IfValueTF={#1}{title=Exemple à reproduire (exercice~\ref{#1})}{title=Exemple à reproduire},
  #2
  ]{#4}
}

\colorlet{meta}{brown}
\newcommand{\meta}[2][meta]{{\color{#1}{\normalfont\textlangle}\emph{\texttt{#2}}{\normalfont\textrangle}}}

\begin{document}
\textlangle\textrangle

La plus belle égalité mathématique est, sans conteste:
\begin{equation}\label{plus-belle-eq}
  e^{i\pi}+1=0
\end{equation}
\begin{enumerate}
\item Coucou
  \begin{ExempleAReproduire}
    Voici une liste \emph{décrivant} le soleil :
    \begin{description}
    \item[diamètre moyen:] \SI{1392684}{\kilo\meter}
    \item[température à la surface:] \SI{5750}{\kelvin} (soit
      \SI{6023.15}{\celsius})
    \item[flux énergétique:] \SI{3,826e26}{\watt}
    \item[volume:] \SI{1,412e18}{\kilo\meter\cubed}
    \item[température au centre:] \SI{15,1}{\mega\kelvin} (mégakelvin)
    \item[proportion d'hydrogène:] \SI{73,46}{\percent}
    \item[masse volumique moyenne:] \SI{1408}{\kilo\gram\per\cubic\meter}
    \item[masse volumique au centre:] \SI{150000}{\kilo\gram\per\cubic\meter}
    \item[gravité à la surface:] \SI{273,95}{\meter\per\second\squared}
    \end{description}
    La plus belle égalité mathématique est, sans conteste:
    \begin{equation}\label{plus-belle-eq}
      e^{i\pi}+1=0
    \end{equation}
    Environ \num{3,4e38} protons (noyaux d'hydrogène), soit 619~millions de
    tonnes d'hydrogène, sont convertis en 614~millions de tonnes d'hélium chaque
    seconde, libérant une énergie correspondant à l'annihilation de
    4,26~millions de tonnes de matière par seconde, produisant
    \SI{383}{\yotta\joule} (yottajoules) (\SI{383e24}{\joule}) par seconde, soit
    l'équivalent de l'explosion de \SI{91,5e15}{\tonne} de \textsc{tnt}.
  \end{ExempleAReproduire}
\end{enumerate}
La plus belle égalité mathématique est, sans conteste:
  \begin{equation}\label{plus-belle-eq-bis}
    e^{i\pi}+1=0
  \end{equation}

\exemple{test-crop.pdf}

\exemple[bar]{test-crop.pdf}

\exemple[][][red]{test-crop.pdf}

\exemple[][title=coucou]{test-crop.pdf}

\end{document}

\documentclass[french,12pt]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\usepackage[locale=FR]{siunitx}
\begin{document}
Voici une liste \emph{décrivant} le soleil :
\begin{description}
\item[diamètre moyen:] \SI{1392684}{\kilo\meter}
\item[température à la surface:] \SI{5750}{\kelvin} (soit
  \SI{6023.15}{\celsius})
\item[flux énergétique:] \SI{3,826e26}{\watt}
\item[volume:] \SI{1,412e18}{\kilo\meter\cubed}
\item[température au centre:] \SI{15,1}{\mega\kelvin} (mégakelvin)
\item[proportion d'hydrogène:] \SI{73,46}{\percent}
\item[masse volumique moyenne:] \SI{1408}{\kilo\gram\per\cubic\meter}
\item[masse volumique au centre:] \SI{150000}{\kilo\gram\per\cubic\meter}
\item[gravité à la surface:] \SI{273,95}{\meter\per\second\squared}
\end{description}
Environ \num{3,4e38} protons (noyaux d'hydrogène), soit
619~millions de tonnes d'hydrogène, sont convertis en
614~millions de tonnes d'hélium chaque seconde, libérant
une énergie correspondant à l'annihilation de 4,26~millions
de tonnes de matière par seconde, produisant
\SI{383}{\yotta\joule} (yottajoules) (\SI{383e24}{\joule})
par seconde, soit l'équivalent de l'explosion de
\SI{91,5e15}{\tonne} de \textsc{tnt}.
\end{document}

\documentclass{article}
\newcommand{\unit}[1]{\text{\texttt{#1}}}

\begin{document}
\begin{tcolorbox}[enhanced,enlarge by=5mm,colframe=blue!75!black,colback=white,show bounding box]
\lipsum[1-10]
\end{tcolorbox}
\end{document}

\documentclass{article}
\usepackage{fontspec}
\setmainfont{Fira Code}[ItalicFont=FiraSans-Italic]
\setmonofont{Fira Code}[
  Contextuals=Alternate  % Activate the calt feature
]
\usepackage{listings}
\usepackage{lstfiracode} % https://ctan.org/pkg/lstfiracode
\lstset{
  language=C++,
  style=FiraCodeStyle,   % Use predefined FiraCodeStyle
  basicstyle=\ttfamily   % Use \ttfamily for source code listings
}
\begin{document}
\begin{lstlisting}
--fi-fl-ff-ffi-ffl
/* A simple C++ program */
int main() {
    cout << "Hello World"; // prints Hello World
    return 0;
}
\end{lstlisting}
  \ttfamily
  a\textvisiblespace\verbvisiblespace a
\end{document}

\documentclass{article}
\usepackage{fontspec}
\usepackage{listings}

% \setmonofont[Ligatures=TeX]{TeX Gyre Pagella}
\setmonofont{Inconsolatazi4-Regular.otf}[Scale=MatchLowercase,Ligatures=TeX]

\lstset{
  language=[AlLaTeX]TeX, %
  alsolanguage=[extLaTeX]TeX, % cf. lstlang0.sty
  basicstyle=\ttfamily,%
  columns=flexible,%
}

\begin{document}
\verb|--fi-fl-ff-ffi-ffl|

\lstinline|--fi-fl-ff-ffi-ffl|
\end{document}

\documentclass[french]{article}
\usepackage{fontspec}
\usepackage{luacode}
\usepackage{lmodern}
\usepackage{ulem}
% \usepackage{amsmath}
\usepackage[a4paper]{geometry}
% \usepackage{lua-physical}
\usepackage{babel}
\usepackage{siunitx}
% configure siunitx
\sisetup{
  locale = FR,
  per-mode = symbol,
  separate-uncertainty = true,
  add-decimal-zero = true,
  exponent-product = \cdot,
  round-mode = off
}
% load the lua- physical package
\begin{luacode*}
physical = require("physical")
N = physical.Number
\end{luacode*}
% print a physical quantity
\newcommand{\q}[1]{%
  \directlua{
    tex.print(
    physical.Quantity.tosiunitx(
    #1,
    "scientific-notation=fixed,exponent-to-prefix=false"
    )
    )
  }%
}
\begin{document}
\begin{luacode}
s = 10 * _m
t = 2 * _s
v = s/t
\end{luacode}
A car travels $\q{s}$ in $\q{t}$. calculate its velocity.
\begin{equation}
v=\frac{s}{t} = \frac{\q{s}}{\q{t}} = \uuline{\q{v}}
\end{equation}
\end{document}

\begin{filecontents}{foo.tex}
\documentclass{article}
\begin{document}
I am the \texttt{foo.tex} file.
\end{document}
\end{filecontents}

\documentclass{beamer}
\newcommand\myPth{file:///home/bitouze/latex/divers/}
\begin{document}
\begin{frame}
  \href{\myPth foo.tex}{Open the \texttt{foo.tex} file in the default \TeX{} editor.}
\end{frame}
\end{document}

% Test pour pdfpc
\documentclass{beamer}
\begin{document}
\begin{frame}
  Foofoo
\end{frame}
\begin{frame}
  \href{run:paolo-parle-aux-taties.mp4?autostart&loop}{\includegraphics[height=0.7\textheight]{out.png}}
\end{frame}
\end{document}

\documentclass[hdr]{yathesis}
\usepackage{hyperref}
\begin{document}
\author[denis.bitouze@lmpa.univ-littoral.fr]{Denis}{Bitouzé}
\maketitle
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
% \usepackage{kpfonts}
% \usepackage[scaled]{berasans}
% \renewcommand*\familydefault{\sfdefault}
\usepackage[sfdefault,book]{FiraSans}
\usepackage{graphicx}
\usepackage[a4paper,margin=.5cm]{geometry}
\usepackage{babel}
\begin{document}
\includegraphics[height=2.5cm]{logoulcofondbleufonce}

\begin{center}
  \textbf{\Large Accusé de réception de 10 masques grand public lavables testés 60
    lavages}
\end{center}
\bigskip{}
\begin{description}
\item[Nom :] Bitouzé
\item[Prénom :] Denis
\item[Fonction :] Enseignant-chercheur
\item[Lieux d'exercice :] Dunkerque
\item[Site :] Citadelle
\item[Reçus le :] 31/08/2020
\item[Signature :] \

  \includegraphics[height=1.5cm]{signature}
\end{description}
\end{document}

\documentclass[
NF,
fromemail=true,
fromalign=left,
fontsize=12pt
fromphone,
fromemail,
version=last
]{scrlttr2} %Format, taille police, classe du document.
%\documentclass[paper=a4,pagenumber=off,fromalign=left,fontsize=12pt,foldmarks=off,KOMAold]{scrlttr2}

%\usepackage{lmodern} %Fonte LaTeX par défaut
%\usepackage{mathpazo}% Fonte Palatino
%\usepackage{helvet}% Fonte helvetica

\usepackage[utf8x]{inputenc}% Encodage Unicode du fichier source
\usepackage[T1]{fontenc} % Codage des caractères de la fonte.
\usepackage{xcolor} %Couleurs
\usepackage[french]{babel}
\usepackage{eurosym} %sSymbole euro: écrire \nombre{5000}~\euro
%\usepackage{lmodern}
%\usepackage{microtype}

\KOMAoptions{foldmarks=hp}
\KOMAoptions{backaddress=false}
\KOMAoptions{frommobilephone}
\KOMAoptions{fromphone}

\begin{document}
%\setkomavar{firsthead}{}


\setkomavar{place}{Lanterne}
\setkomavar{fromname}{Jean Dupont}
\setkomavar{fromphone}{+33 111111111}
\setkomavar{frommobilephone}{+33 6 22222222}
\setkomavar{fromzipcode}{1000}

\setkomavar{fromaddress}{1 rue du Latex\\ 1000 Lanterne
}


\setkomavar{place}{Lanterne}
\setkomavar{fromemail}{Jean.dupont@mail.fr}
\setkomavar{subject}{Le sujet}
\setkomavar{signature}{Jean Dupont}
\setkomavar{frommobilephone}{+ 33 66666666}
\setkomavar{toaddress}{}
\setkomavar{toname}{}

\setkomavar{yourmail}{}
\setkomavar{yourref}{}


%Fin du préambule (instructions de configuration)
%----------------------------------------------------------------
% Destinataire:
\begin{letter}{Destinataire\\
}


\opening{Madame, Monsieur, }

\closing{\bigskip Salutations}

\vfill

%\encl{}

\end{letter}

\end{document}

\documentclass[french]{article}
\RequirePackage{tracklang}[2019/11/30]
\RequirePackage{babel}
\begin{document}
\SetCurrentTrackedDialect{\languagename}
Dialect: \CurrentTrackedDialect.
Language: \CurrentTrackedLanguage.
ISO Code: \CurrentTrackedIsoCode.
Region: \CurrentTrackedRegion.
Modifier: \CurrentTrackedDialectModifier.
Variant: \CurrentTrackedDialectVariant.
Script: \CurrentTrackedDialectScript.
Sub-Lang: \CurrentTrackedDialectSubLang.
Additional: \CurrentTrackedDialectAdditional.
Language Tag: \CurrentTrackedLanguageTag.

\IfTrackedLanguageFileExists{french}{studentreport}{.ldf}{found}
{not found}
\end{document}

\begin{filecontents*}[overwrite]{myclass.cls}
\RequirePackage{l3keys2e}
\RequirePackage{expl3}
\RequirePackage{xparse}
\ExplSyntaxOn
\ProvidesExplClass
  {myclass}
  {2020/07/10}
  {0.1}
  {
    My~Nice~Class.
  }
\NeedsTeXFormat{LaTeX2e}
\LoadClass { article }

\ExplSyntaxOn

\prop_new:N \l__myclass_institute_prop
\prop_new:N \l__myclass_tmpa_prop
\int_new:N \g__myclass_institutes_number_int

\keys_define:nn { myclass/institute }
 {
  name         .prop_put:N = \l__myclass_tmpa_prop,
  url          .prop_put:N = \l__myclass_tmpa_prop,
  logo~ file   .prop_put:N = \l__myclass_tmpa_prop,
 }

\NewDocumentCommand \setinstitute { m }
 {
  \prop_clear:N \l__myclass_tmpa_prop
  \keys_set:nn { myclass/institute } { #1 }
  % \prop_show:c { l__myclass_tmpa_prop }
  \int_gincr:N \g__myclass_institutes_number_int
  % \prop_new:c {l__myclass_institute_ \tl_to_str:n {#1} _prop}
  \prop_set_eq:cN
   {l__myclass_institute_ \int_use:N \g__myclass_institutes_number_int _prop}
   \l__myclass_tmpa_prop
 }

\NewDocumentCommand \displayinstitutes {  }
 {
  \int_step_inline:nn { \g__myclass_institutes_number_int }
   {
    \begin{description}
    \item[Institute~##1:]\mbox{}
    % \prop_show:c { l__myclass_institute_##1_prop }
      \begin{description}
        \prop_map_inline:cn { l__myclass_institute_##1_prop }
         {
          \item[####1:]####2
         }
      \end{description}
    \end{description}
   }
 }

\ProcessKeysOptions { myclass }
\ExplSyntaxOff
\end{filecontents*}

\documentclass{myclass}
\begin{document}
\setinstitute{
  name      = \textbf{foo1},
  url       = \textsc{bar1},
  logo file = baz1,
}
\setinstitute{
  name      = foo2,
  url       = bar2,
  logo file = baz2,
}
\displayinstitutes
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{tcolorbox}

\tcbuselibrary{listings,xparse}

\lstset{basicstyle=\ttfamily}

\DeclareTotalTCBox{\myverb}{ v }{ verbatim }{#1}
% \DeclareTotalTCBox{\myverb}{ v }{ fontupper=\ttfamily }{#1}

\begin{document}
\verb|--all|

\lstinline|--all|

\myverb{-all}

\myverb{--all}

\myverb{---all}
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{accsupp}
\usepackage{tcolorbox}

\tcbuselibrary{listings,breakable,skins,xparse}

\tcbset{%
  commandshell/.style={%
    colback=black,
    colupper=white,
    colframe=yellow!75!black,
    breakable,
    listing only,
    listing options={style=tcblatex,language=bash,escapeinside={(*@}{@*)}},
    every listing line={%
      \textcolor{red}{%
        \small\ttfamily\bfseries%
        \BeginAccSupp{method=plain,ActualText={}}
        \$
        \EndAccSupp{}%
      }
    },
  }
}

\DeclareTotalTCBox{\myverb}{ O{red} v !O{} }
{ fontupper=\ttfamily,nobeforeafter,tcbox raise base,arc=0pt,outer arc=0pt,
  top=0pt,bottom=0pt,left=0mm,right=0mm,
  leftrule=0pt,rightrule=0pt,toprule=0.3mm,bottomrule=0.3mm,boxsep=0.5mm,
  colback=#1!10!white,colframe=#1!50!black,#3}{#2}

\newtcblisting{listingshell}[1][]{%
  commandshell,
  #1
}

\begin{document}
On pourra utiliser l'option \myverb{---all} de la commande \myverb{ls}.

Noter qu'on peut aussi lancer :
\begin{listingshell}
i=Coucou\ !
echo $i
\end{listingshell}
\end{document}


\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{iftex}
\ifpdftex
\else
\usepackage{fontspec}
\fi
\usepackage{kpfonts}

% \usepackage{xcolor}
% \usepackage{adjustbox}
% \newcommand{\surlignage}[2][yellow]{%
%   \adjustbox{bgcolor=#1}{#2}%
% }
%
% \newcommand{\test}{%
%   \surlignage{Foo}
%
%   \surlignage[green]{Foo}
%
%   \surlignage{\surlignage[green]{Foo}}
% }

\usepackage{tcolorbox}
\tcbuselibrary{skins,xparse}
\tcbset{surlignage/.style={enhanced,standard jigsaw,on line,size=minimal}}
\DeclareTotalTCBox{\surlignage}{ o m !O{} }{%
  surlignage,
  IfValueTF={#1}{colback=#1}{colback=yellow,extrude by=1.5pt},
  #3
}{#2}

\newcommand{\test}{%
  \surlignage{Foo}

  \surlignage{Foo}[colback=cyan,extrude right by=-1.5pt]

  \surlignage[green]{Foo}

  \surlignage{\surlignage[green]{Foo}}
}

\begin{document}
\test{}
% \tcbsetforeverylayer{opacityback=0}

\test{}
\end{document}

lualatex test.tex  1,10s user 1,72s system 99% cpu 2,843 total
lualatex test.tex  1,03s user 1,69s system 99% cpu 2,735 total

pdflatex test.tex  0,69s user 1,39s system 98% cpu 2,115 total
pdflatex test.tex  0,41s user 0,77s system 99% cpu 1,187 total

\documentclass[t]{beamer}
\usetheme{PaloAlto}
\setbeamertemplate{navigation symbols}{Slide \insertslidenumber{} of frame \insertframenumber}
\usepackage{tcolorbox}
\usepackage{adjustbox}
\tcbuselibrary{skins}
\tcbset{enhanced}
\begin{document}
% \begin{frame}
%   \frametitle{Naive approach}
%   \only<2>{\adjustbox{}{Colored background on and only on slides 1 and 3}}%
%   \only<1,3>{\adjustbox{bgcolor=yellow}{Colored background on and only on slides 1 and 3}}%
% \end{frame}
% %
% \begin{frame}
%   \frametitle{Less naive approach}
%   \framesubtitle{Works only with a single, global background color}
%   \only<1,3>{\adjustboxset{bgcolor=yellow}}%
%   \adjustbox{}{Colored background on and only on slides 1 and 3}
% \end{frame}
% %
% \begin{frame}
%   \frametitle{Less naive approach}
%   \framesubtitle{Doesn't work if multiple background colors involved}
%   \adjustbox{bgcolor*={\color<1,3>{yellow}}}{Colored background on and only on slides 1 and 3}
%   \adjustbox{bgcolor*=\color{green}}{Green    background on and only on slides 1 and 3}
% \end{frame}
%
  \begin{frame}
    \tcbset{
      enhanced,
      colframe=red,
      colback=yellow!25!white,
      frame style={opacity=0.25},
      interior style={opacity=0.5},
      nobeforeafter,
      tcbox raise base,
      shrink tight,
      extrude by=2mm
    }
%
    Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Ut purus elit,
    vestibulum ut, placerat ac, adipiscing vitae, felis. \tcbox{Curabitur}
    dictum gravida mauris. \tcbox[colframe=green,interior
    style={opacity=0.0}]{Nam} arcu libero, nonummy eget, consectetuer id,
    \tcbox{vulputate} a, magna. Donec vehicula augue eu neque. Pellentesque
    habitant morbi tristique senectus et netus et malesuada fames ac turpis
    egestas. \tcbox{Mauris ut leo.}
  \end{frame}

  % \tcbset{enhanced,every box/.style={standard jigsaw,on line,size=minimal}}
  \tcbsetforeverylayer{enhanced,standard jigsaw,on line,size=minimal}
\begin{frame}
  \frametitle{Less naive approach}
  \framesubtitle{tcbox}
  \only<2>{\tcbsetforeverylayer{opacityback=0}}
  %
  \begin{alertblock}{Test}
    Foo \tcbox[colback=yellow% ,left=1.5pt,right=1.5pt
    ]{Foo
      \tcbox[colback=green]{Bar} Baz} Baz
  \end{alertblock}
  \begin{alertblock}{Test}
    Foo \tcbox[colback=yellow,boxsep=1.5pt]{Foo
      \tcbox[colback=green]{Bar} Baz} Baz
  \end{alertblock}
    habitant morbi tristique senectus et netus et malesuada fames ac turpis
    Foo \tcbox[colback=yellow% ,left=1.5pt,right=1.5pt
    ]{Foo
      \tcbox[colback=green]{Bar} Baz} Baz
    habitant morbi tristique senectus et netus et malesuada fames ac turpis

    habitant morbi tristique senectus et netus et malesuada fames ac turpis
    Foo \tcbox[colback=yellow,extrude top by=1.5pt,extrude bottom by=1.5pt]{Foo
      \tcbox[colback=green]{Bar} Baz} Baz
    habitant morbi tristique senectus et netus et malesuada fames ac turpis
  \end{frame}
%
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{kpfonts}

\newcommand{\amoureux}[1]{\textsc{\emph{#1}}}
\newcommand{\couple}[2]{%
  \textbf{#1 et #2, couple intemporel}%
}
\newcommand{\couplebis}[2]{%
  \textbf{\amoureux{#1} et \amoureux{#2}, couple intemporel}%
}

\begin{document}
\amoureux{Roméo} et \amoureux{Juliette}, couple...

\begin{enumerate}
\item D'abord apparut \couple{Ulysse}{Pénélope}...
\item Ensuite vint \couple{Roméo}{Juliette}...
\item Enfin avec \couple{Johnny}{Læticia}...
\end{enumerate}

\begin{enumerate}
\item D'abord apparut \couplebis{Ulysse}{Pénélope}...
\item Ensuite vint \couplebis{Roméo}{Juliette}...
\item Enfin avec \couplebis{Johnny}{Læticia}...
\end{enumerate}

\end{document}

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[french]{babel}
\usepackage{lipsum}


\usepackage[xindy]{indextools}
\makeindex[options=-L french,title=Mots clefs]


\begin{document}

\section{Introduction}
\index{premier mot}
\lipsum[1]
\index{deuxième mot}
\lipsum[2]

\index{Troisième mot}
\lipsum[2-3]
\index{énergie}

\printindex

\end{document}

\documentclass{beamer}

\begin{document}

\begin{frame}
  \frametitle{Titre}
  \begin{columns}[T]
    \begin{column}{.23\textwidth}
      \centering
      \includegraphics[width=\linewidth]{example-image-duck}

      Spaghettis
    \end{column}
    \begin{column}{.23\textwidth}
      \centering
      \includegraphics[width=\linewidth]{example-image-duck}

      Doigts crochus
    \end{column}
    \begin{column}{.23\textwidth}
      \centering
      \includegraphics[width=\linewidth]{example-image-duck}

      Ramener à soi un mot dont on a besoin
    \end{column}
    \begin{column}{.23\textwidth}
      \centering
      \includegraphics[width=\linewidth]{example-image-duck}

      Confiance, joie, énergie, force
    \end{column}
\end{columns}
\end{frame}

\end{document}

\documentclass{book}
\usepackage{lipsum}
\showoutput
\begin{document}
\chapter*{Heading on level 0}
\lipsum
\end{document}

\documentclass{book}
\usepackage{titleps}
\usepackage{blindtext}
\begin{document}
\Blinddocument
\end{document}

\documentclass{book}
\usepackage[pagestyles]{titlesec}
\usepackage{blindtext}
\begin{document}
\Blinddocument
\end{document}

\documentclass[oneside,10pt,spanish,]{extbook}
% \usepackage{fontspec}
% % \setmainfont[Numbers={OldStyle,Proportional}]{EBGaramond-Regular}
% \usepackage[papersize={4.8in,6.4in},left=.5in,right=.5in]{geometry}
% \begin{document}
% \thispagestyle{empty}
% \begin{tabular}{p{.8\textwidth}}
%   \ \ \ \ Bonjour \ \ \ \ \ \ \
% \end{tabular}
% \end{document}

\documentclass[oneside,10pt,spanish,]{extbook}
\usepackage{fontspec}
% \setmainfont[Numbers={OldStyle,Proportional}]{EBGaramond-Regular}
\usepackage[papersize={4.8in,6.4in},left=.5in,right=.5in]{geometry}
\begin{document}
\thispagestyle{empty}
\begin{tabular}{p{.8\textwidth}}
  \ \ \ \ \hspace{12mm} les dégâts \ \ \ \ \ \ \
\end{tabular}
\end{document}

\documentclass[
project,french
%internship
]{studentreport}
\begin{document}
\SIrange{0,1}{0,5}{\bar}
\end{document}

\documentclass[a4paper,11pt]{article}
\usepackage[utf8]{inputenc}

\usepackage{titleps}
\newpagestyle{fancy}{
    \headrule
    \sethead{}{\itshape\sectiontitle}{}
    \setfoot{}{\thepage}{}
}
\pagestyle{fancy}

\usepackage{lipsum}

\begin{document}

\section{First section}
\lipsum[1-4]
\clearpage

\section{Second section}
\lipsum[5-8]
\clearpage

\section*{Unnumbered section}
\lipsum[9-12]

\end{document}

\documentclass{article}

\usepackage{titleps,xparse}
\newpagestyle{fancy}{
    \headrule
    \sethead{}{\itshape\sectiontitle}{}
    \setfoot{}{\thepage}{}
}
\pagestyle{fancy}
\let\oldsection\section
\makeatletter
\RenewDocumentCommand{\section}{s o m}{%
  \IfBooleanTF{#1}
    {{% \section*
      \oldsection*{#3}% \section*[.]{..}
      \sectionmark{#3}%
    }}{% \section
      \IfNoValueTF{#2}
        {\oldsection{#3}}% \section{..}
        {\oldsection[#2]{#3}}% \section[.]{..}
    }%
}
\makeatother
\usepackage{lipsum}

\begin{document}

\section{Numbered section}
\lipsum[1-3]
\clearpage

\section*{Unnumbered section}
\lipsum[4-6]

\end{document}

\documentclass{article}
\usepackage{biblatex}
\addbibresource{biblatex-examples.bib}

\newcounter{no_journals}
\newcounter{no_conferences}
\newcounter{no_thesis}

\AtDataInput{%
  \ifentrytype{article}
    {\stepcounter{no_journals}}
    {\ifentrytype{inproceedings}
       {\stepcounter{no_conferences}}
       {\ifentrytype{thesis}
          {\stepcounter{no_thesis}}
          {}}}}

\begin{document}
\nocite{sigfridsson,worman,baez/article,geer}

journals: \arabic{no_journals}, theses: \arabic{no_thesis}
\end{document}

\documentclass{yathesis}
\usepackage{biblatex}
\addbibresource{\jobname.bib}
\usepackage{filecontents}
\begin{filecontents}{\jobname.bib}
@book{keya,
  author = {Author, A.},
  year = {2001},
  title = {TitleA},
  publisher = {Publisher},
}

@book{keyb,
  author = {Author, B.},
  year = {2001},
  title = {TitleB},
  publisher = {Publisher},
}
\end{filecontents}

\begin{document}

\chapter{Liste des publications}

Un peu de texte

\nocite{*}
\printbibliography[heading=subbibnumbered,title={Articles dans des journaux à comité de lecture}]

\end{document}

\documentclass[french]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}

\usepackage{babel}
\usepackage{minted}

\begin{document}
   Voici un bloc de code en LaTeX.

\begin{minted}{latex}
En LaTeX, on écrit des maths en ligne entre deux signes dollars.
Par exemple, $1 + 3^2 = 10$.
Pour les maths hors-texte, voici un exemple.
\[
   1 + 3^2.
\]
\end{minted}
\end{document}

\documentclass{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{xcolor}
\usepackage{listings}

  \colorlet{texcs}{blue}
  \colorlet{visible}{white}
  \colorlet{commentaires}{gray}
  % Couleur des mots-clés de niveau 1
  \colorlet{keyword}{teal}
  % Couleur des mots-clés de niveau 2
  % \colorlet{keyword2}{keyword}
  \colorlet{keyword2}{red!75!black}
  % Couleur des mots-clés de niveau 3
  % \colorlet{keyword3}{red!75!black}
  \colorlet{keyword3}{violet}
  % Couleur des mots-clés de niveau 4
  \colorlet{keyword4}{purple}
  % Couleur des mots-clés de niveau 5
  \colorlet{keyword5}{texcs}
  \colorlet{math}{green!50!black}
  \colorlet{brackets}{math}
  % \colorlet{brackets}{darkgray}
  % \colorlet{braces}{magenta}
  \colorlet{braces}{red}
  \colorlet{meta}{brown}


\lstset{
  basicstyle   = \ttfamily,%
  language     = [LaTeX]TeX,
  basicstyle   = \ttfamily,%
  texcsstyle=*\color{blue},
  escapeinside=~~
}
%% "Rehook" delimiters char table.
\makeatletter
\lst@AddToHook{SelectCharTable}
    {\ifx\lst@literate\@empty\else
         \expandafter\lst@Literate\lst@literate{}\relax\z@
     \fi}
\makeatother

\begin{document}
\begin{frame}[fragile]
\begin{lstlisting}
\[\sum_{n=1}^{+\infty}\]
\[
  \sum_{n=1}^{+\infty}
\]
~\lstset{texcsstyle=*\color{red}}~
$\sum_{n=1}^{+\infty}$
\end{lstlisting}
\end{frame}

\lstset{
  literate=*%
  {\\[}{{\color{math}\char92\char91}}2%
  {\\]}{{\color{math}\char92\char93}}2%
  {$}{{{\color{math}\char36}}}1%$
  {^}{{{\color{math}\char94}}}1%
  {_}{{{\color{math}\char95}}}1%
  {\[}{{\textcolor{brackets}{[}}}1%
  {\]}{{\textcolor{brackets}{]}}}1%
  {\{}{{\textcolor{braces}{\{}}}1%
  {\}}{{\textcolor{braces}{\}}}}1,%
}

\begin{frame}[fragile]
\begin{lstlisting}
\[\sum_{n=1}^{+\infty}\]
\[
  \sum_{n=1}^{+\infty}
\]
$\sum_{n=1}^{+\infty}$
\end{lstlisting}
\[
  \sum_{n=1}^{+\infty}
\]
$\sum_{n=1}^{+\infty}$
\end{frame}
\end{document}

\documentclass{article}
\usepackage{xparse}
\usepackage{listings}
\usepackage{tcolorbox}

\tcbuselibrary{xparse,listings,breakable}

\NewTCBListing{mybox}{ !O{} }{%
  listing only,
  breakable,
  #1%
}

\begin{document}
\begin{mybox}
\begin{align*}
a & = a\\
b & = b
\end{align*}
\end{mybox}
\end{document}

\documentclass[a4paper,fleqn]{article}
\usepackage[utf8]{inputenc}
\usepackage{tikz}
\usepackage{eso-pic}
\usepackage[style]{abstract}
\usepackage{authblk}
\usepackage{enumitem}
\setlist{leftmargin=*,nosep}
\usepackage{geometry}
\geometry{showframe,left=5.25cm,top=2cm,bottom=2.5cm,right=1.25cm,footskheadheight=2cm}

\AddToShipoutPicture{%
    \begin{tikzpicture}[overlay,remember picture]
        \foreach \y in {29.7,28.7,...,10.7}
            \draw[draw=blue] (0,\y)--(21,\y);
         \draw[draw=red,thick] (0,25.7)--(21,25.7);
    \end{tikzpicture}%
}

\makeatletter
\renewcommand{\@maketitle}{%
  \hbox{}
  \vskip\dimexpr1cm+\baselineskip%<------ dimension??
  \noindent%
  \raggedright%
  {\Large\bfseries\sffamily\@title\par}%
    \vskip2\baselineskip%
  \@author\par%
  \normalfont\normalsize%
}
\makeatother

\title{AZERTYUIOPQSDFGHJKLWXCVBN}

\author[1,2,3]{Author One}
\author[2]{Author Two}
\author[3]{Author Three}
\author[2]{Author Four}

\affil[1]{Very long long long long long long long long long long long long long long long long long long long long long long long long long long long}
\affil[2]{Very long long long long long long long long long long long long long long}
\affil[3]{Very long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long long}

\begin{document}\flushbottom
\maketitle
\begin{abstract}
Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random

Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random
\end{abstract}

\section{Title 1}
Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random
\begin{enumerate}
\item Random
\item Random
\item Random
\item Random
\item Random
\item Random
\item Random
\end{enumerate}
Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random

Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random

\section{Title 2}
Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random Random
\end{document}

\documentclass[10pt,french]{article}

\usepackage{lmodern}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage[a4paper,left=20mm,right=20mm,top=15mm,bottom=15mm]{geometry}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{systeme}

\DecimalMathComma % pour les virgules dans les nombres

\begin{document}
\[
  \systeme[\alpha_{1}\alpha_{2}\alpha_{3}]{%
    \alpha_{1}-\alpha_{2}-\alpha_{3}=0,
    \alpha_{1}-\alpha_{3}=0,
    \alpha_{1}+\alpha_{2}=0}
  \implies
  \systeme[\alpha_{1}\alpha_{2}\alpha_{3}]{%
    \alpha_{1}-\alpha_{2}-\alpha_{3}=0,
    \alpha_{1}=-\alpha_{2},
    \alpha_{1}=\alpha_{3}}
  \implies
  \systeme[\alpha_{1}\alpha_{2}\alpha_{3}]{%
    \alpha_{1}=0,
    \alpha_{2}=0,
    \alpha_{3}=0}
\]
\end{document}

\documentclass[12pt]{article}
\usepackage{moodle}
\usepackage{amsmath}
\begin{document}
\begin{quiz}{ECM}
\begin{multi}[shuffle=false,feedback={INDICE: L'évènement contraire est: aucun des 5 numéros n'est gagnant. Sa probabilité se calcule par dénombrement: il y a équiprobabilité des $\binom{49}{5}$ manières de prélever ces 5 numéros (sans remise sans ordre) et il y a $\binom{44}{5}$ manières d'en choisir aucun gagnant... }]{truc}
  Au loto, il faut cocher $5$ numéros sur une grille qui en comporte $49$. Paul
  joue au loto, quelle est la probabilité qu'il ait au moins un des $5$ numéros
  gagnants (c'est à dire désignés par le tirage au sort) ?
\item $\frac{\binom{44}{5}}{\binom{49}{5}}$
\item $\frac{5 \times \binom{44}{5}}{\binom{49}{5}}$
\item $\frac{\binom{49}{44} \times \binom{5}{1}}{49^5}$
\item $\frac{5}{49}$
\item* $\frac{\binom{49}{5}-\binom{44}{5}}{\binom{49}{5}}$ %
\end{multi}

\begin{multi}[shuffle=false,feedback={INDICE: L'événement contraire est
    $\overline{A}$ =`` les trois tentatives ont échoué ''... La probabilité de
    trouver le bon code à la 1ère tentative est
    $P(A_1)=\frac{1}{10\times 9 \times 8 \times 7 \times 6}$ donc
    $P(\overline{A_1})=\frac{10\times 9 \times 8 \times 7 \times 6~-1}{10\times
      9 \times 8 \times 7 \times 6}$. A la 2ème tentative, il ne retente pas le
    code de la 1ère donc
    $P(A_2)=\frac{1}{10\times 9 \times 8 \times 7 \times 6~-1}$ et donc
    $P(\overline{A_2})=\frac{10\times 9 \times 8 \times 7 \times 6~-2}{10\times
      9 \times 8 \times 7 \times 6~-1}$... Idem pour la 3ème
    tentative... Utiliser enfin que
    $P(\overline{A})=P(\overline{A_1}) \times P(\overline{A_2}) \times
    P(\overline{A_3})$... et simplifier... }]{machin}
  Un cambrioleur veut ouvrir le coffre-fort de Picsou protégé par un code
  à 5 chiffres distincts (parmi les 10 chiffres de 0 à 9). Le coffre-fort est
  bloqué automatiquement au bout de 3 tentatives si on n'arrive pas à trouver le
  bon code. Quelle est la probabilité que le voleur ouvre le coffre-fort ?
\item* $\frac{3}{10\times 9 \times 8 \times 7 \times 6}$ %
\item $\frac{3}{10^5}$
\item $\frac{3}{\binom{10}{5}}$
\item $\frac{3}{A_{10}^{5}}$
\item aucune réponse ne convient
\end{multi}
\end{quiz}
\end{document}

\documentclass{memoir}

\begin{filecontents}{Test.bib}
@article{Buckland:1925,
 Author = {Buckland, William Warwick},
 Date = {1925},
 Hyphenation = {french},
 Journal = {Revue historique de droit fran{\c c}ais et {\'e}tranger},
 Keywords = {Droit romain, Possession},
 Pages = {355},
 Shortjournal = {RHD},
 Title = {Le constitut possessoire: \emph{Animus} et \emph{Corpus}},
 Volume = {4}}
\end{filecontents}

\usepackage{biblatex}
\addbibresource{Test.bib}

\begin{document}

\nocite{Buckland:1925}

\printbibliography

\end{document}

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[a4paper]{geometry}
\usepackage{listings}

\lstnewenvironment{envirtest}{\lstset{morecomment=[l]{\#}}}{} %définition d'un environnement
\lstdefinestyle{styletest}{morecomment=[l]{\#}} %définition d'un style

\begin{document}

\begin{envirtest}
x = 1 #affectation de x
y = 3
\end{envirtest}

\lstinputlisting[morecomment=[l]{\#}]{TestPython.py}

\end{document}

\documentclass{article}
\begin{document}
  \noindent We have the date: 23-01-2012 \splitdate{23-01-2012}\\
  Day: \myday\\
  Month: \mymonth\\
  Year: \myyear
\end{document}

\documentclass{book}
\usepackage{mwe}
\usepackage{etoolbox}
\usepackage{titleps}
\pretocmd{\pagestyle}{\cleardoublepage}{}{\aaa{}}%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newpagestyle{foo}[]%
{%
  \sethead
  {foo}%
  {}%
  {}%
  \headrule%
  \setfoot{}{\thepage}{}%
}%
\newpagestyle{bar}[]%
{%
  \sethead
  {bar}%
  {}%
  {}%
  \headrule%
  \setfoot{}{\thepage}{}%
}%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%
\pagestyle{foo}
\chapter{Foo 1}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
% \cleardoublepage{}
\pagestyle{bar}
\chapter{Bar 1}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
% \cleardoublepage{}
\pagestyle{foo}
\chapter{Foo 2}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
\bgroup
% \cleardoublepage{}
\pagestyle{bar}
\chapter{Bar 2}
\lipsum[1-15]
% \cleardoublepage{}
\egroup
%%%%%%%%%%%%%%%%%%%%%%%
\chapter{Foo 3}
\lipsum[1-15]
\end{document}

\documentclass{report}
\usepackage{mwe}
\usepackage{titleps}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newpagestyle{foo}[]%
{%
  \sethead
  {foo}%
  {}%
  {}%
  \headrule%
  \setfoot{}{\thepage}{}%
}%
\newpagestyle{bar}[]%
{%
  \sethead
  {bar}%
  {}%
  {}%
  \headrule%
  \setfoot{}{\thepage}{}%
}%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%
\pagestyle{foo}
\chapter{Foo 1}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
% \cleardoublepage{}
\clearpage{}
\pagestyle{bar}
\chapter{Bar 1}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
% \cleardoublepage{}
\clearpage{}
\pagestyle{foo}
\chapter{Foo 2}
\lipsum[1-15]
%%%%%%%%%%%%%%%%%%%%%%%
\bgroup
% \cleardoublepage{}
\clearpage{}
\pagestyle{bar}
\chapter{Bar 2}
\lipsum[1-15]
% \cleardoublepage{}
\clearpage{}
\egroup
%%%%%%%%%%%%%%%%%%%%%%%
\chapter{Foo 3}
\lipsum[1-15]
\end{document}

\documentclass{book}
\usepackage{filecontents}
\usepackage[xindy]{imakeidx}
\usepackage{titleps}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand\indexmark[1]{#1\indexentry{#1}}
\makeatletter
\newcommand\indexentry[1]%
  {\@bsphack
   \protected@write\@auxout{}%
     {\string\newindexentry{#1}{\thepage}}%
   \@esphack
  }
\newcommand\newindexentry[2]%
  {\expandafter\@newindexentryfirst\csname first@#2\endcsname{#1}%
   \expandafter\@newindexentrylast \csname last@#2\endcsname{#1}%
  }
\newcommand\@newindexentryfirst[2]{\ifx#1\relax\gdef#1{#2}\fi}
\newcommand\@newindexentrylast [2]{\gdef#1{#2}}
\newcommand\indexentryfirst
  {\expandafter\@indexentryX\csname first@\thepage\endcsname{First}}
\newcommand\indexentrylast
  {\expandafter\@indexentryX\csname last@\thepage\endcsname{Last}}
\newcommand\@indexentryX[2]%
  {\ifx#1\relax
     \nfss@text{\reset@font\bfseries ??}%
     \@latex@warning{#2 index entry on page \thepage \space undefined}%
   \else
     #1%
   \fi
  }
\makeatother
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newpagestyle{indexpagestyle}[]%
  {\sethead
    {\indexentryfirst -- \indexentrylast}%
    {}%
    {}%
   \headrule%
   \setfoot{}{\thepage}{}%
  }%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{filecontents*}{\jobname.xdy}
(markup-index :open  "~n
\begin{theindex}
  \providecommand*\lettergroupDefault[1]{}
  \providecommand*\lettergroup[1]{\textbf{#1}}
  ~n"
  :close "~n~n\end{theindex}~n"
:tree)

(markup-keyword-list :open "\indexmark{" :close "}" )
\end{filecontents*}
\makeindex[options={-M \jobname.xdy}]

\begin{document}
\input{dummy-index-terms}
%
% Set index pagestyle
\cleardoublepage
\pagestyle{indexpagestyle}
\printindex
\end{document}

\documentclass{book}
\usepackage{filecontents}
\usepackage[xindy]{imakeidx}
\usepackage{titleps}

\newcommand\indexmark[1]{#1\indexentry{#1}}
\makeatletter
\newcommand\indexentry[1]%
  {\@bsphack
   \protected@write\@auxout{}%
     {\string\newindexentry{#1}{\thepage}}%
   \@esphack
  }
\newcommand\newindexentry[2]%
  {\expandafter\@newindexentryfirst\csname first@#2\endcsname{#1}%
   \expandafter\@newindexentrylast \csname last@#2\endcsname{#1}%
  }
\newcommand\@newindexentryfirst[2]{\ifx#1\relax\gdef#1{#2}\fi}
\newcommand\@newindexentrylast [2]{\gdef#1{#2}}
\newcommand\indexentryfirst
  {\expandafter\@indexentryX\csname first@\thepage\endcsname{First}}
\newcommand\indexentrylast
  {\expandafter\@indexentryX\csname last@\thepage\endcsname{Last}}
\newcommand\@indexentryX[2]%
  {\ifx#1\relax
     \nfss@text{\reset@font\bfseries ??}%
     \@latex@warning{#2 index entry on page \thepage \space undefined}%
   \else
     #1%
   \fi
  }
\makeatother
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newpagestyle{indexpagestyle}[]%
  {\sethead
    {\indexentryfirst -- \indexentrylast}%
    {}%
    {}%
   \headrule%
   \setfoot{}{\thepage}{}%
  }%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{filecontents*}{\jobname.xdy}
(markup-index :open  "~n
\begin{theindex}
  \providecommand*\lettergroupDefault[1]{}
  \providecommand*\lettergroup[1]{\textbf{#1}}
  ~n"
  :close "~n~n\end{theindex}~n"
:tree)

(markup-keyword-list :open "\indexmark{" :close "}" )
\end{filecontents*}
\makeindex[options={-M \jobname.xdy}]

\begin{document}
\input{dummy-index-terms}
\clearpage
% \MarkbothHack
\pagestyle{indexpagestyle}
\printindex
\end{document}

\documentclass{article}
\usepackage[xindy,nonewpage]{imakeidx}
\usepackage{filecontents}

\begin{filecontents*}{\jobname.xdy}
(markup-index :open  "~n
\begin{theindex}
  \small
  \providecommand*\lettergroupDefault[1]{}
  \providecommand*\lettergroup[1]{}
  ~n"
  :close "~n~n\end{theindex}~n"
:tree)
\end{filecontents*}

\makeindex[title=Change History,columns=1,options=-M \jobname.xdy]

\newcommand\changes[2]{\index{#1!#2}}
\newcommand\PrintChanges{\printindex}

\begin{document}
\changes{v1.0}{First public version}%
\changes{v2.0}{Second public version (much better)}%
%
This is a nice document but its next version will be much better.
%
\PrintChanges
\end{document}

\documentclass[localbibs]{yathesis}
\usepackage{csquotes}
\usepackage{biblatex}
\usepackage{hyperref}

\addbibresource{biblatex-examples.bib}

\makeatletter
\AtEndPreamble{%
  \pretocmd{\part}{%
    \ifbool{YAD@localbibs}{%
      \ifbool{YAD@localbibs@used}{%
      }{%
        \let\YAD@ORI@blx@warn@bibempty\blx@warn@bibempty%
        \def\blx@warn@bibempty{}%
        \YAD@printbibliography@ORI[segment=\therefsegment,heading=YAD@localbibs@heading]%
        \let\blx@warn@bibempty\YAD@ORI@blx@warn@bibempty%
        \booltrue{YAD@localbibs@used}%
      }%
    }{}%
  }{}{\aaa{}}%
}
\makeatother
\begin{document}
\mainmatter
\part{Salut 1}
\chapter{Coucou 1}
\autocite{sigfridsson,knuth:ct:e}.

\part{Salut 2}
\chapter{Coucou 2}
\end{document}


\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[xindy]{imakeidx}
\makeindex[columns=1]
\begin{document}
dé\index{dé}

do\index{do}
\printindex
\end{document}

\RequirePackage[enable-debug]{expl3}
\ExplSyntaxOn
\debug_on:n { deprecation }
\ExplSyntaxOff
\documentclass{gztarticle}
%
% Indiquer le (chemin vers le) fichier .bib utilisé.
%
\begin{document}
\title{Foo}
% \subtitle[short=]{}
%
\author{Foo, Bar}
%
% \acknowledgements{%
% }
%
% \begin{abstract}
% \end{abstract}
%
\maketitle
%
% Ici vient le contenu de l'article.

%
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{mathtools}      % package générique et raffinements
\usepackage{amssymb}        % symboles
\usepackage{nicematrix}
% \NiceMatrixOptions{transparent}
\usepackage{babel}
\begin{document}
$A = \begin{pmatrix}
  1      & \cdots & \cdots & 1      \\
  0      & \ddots &        & \vdots \\
  \vdots & \ddots & \ddots & \vdots \\
  0      & \cdots & 0      & 1
\end{pmatrix}$
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{lipsum}            % Juste pour faire du remplissage
\usepackage{ntheorem}          % Package pour « théorèmes ».
\usepackage{babel}
%
                               % Commandes \theorem... suivantes = bascules
\theoremstyle{break}           % On bascule en style « break ». D'autres styles existent
\theorembodyfont{\normalfont}  % On bascule en corps en fonte normale (sinon
                               % contenu en italique)
\newtheorem{exo}{Exercice}     % Nouvel environnement de « théorème » avec (tous) les réglages précéd.

\begin{document}
\begin{exo}[Métrique et prosodie chez Christopher Marlowe]
  En poésie, la métrique détermine la structure des vers, tandis que la prosodie
  traite des tons, des rythmes et des modulations au sein de la phrase. Vous
  ferez un bilan de la manière dont, chez Marlowe, la métrique s'appuie (sans
  l'englober) sur la prosodie. Vous prendrez soin de replacer Marlowe dans le
  contexte poétique de son époque, et soulignerez ses apports formels originaux.
\end{exo}

\begin{exo}
  \lipsum[1]
\end{exo}

\begin{exo}
  \lipsum[2]
\end{exo}
\end{document}

\begin{document}

\end{document}


\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage{babel}
\usepackage{csquotes}

\usepackage{amssymb} % Just for \mathbb

\usepackage[style=numeric, backend=biber]{biblatex}
\usepackage{biblatex2bibitem}

\addbibresource{biblatex-examples.bib}

\addbibresource{biblatex2bibitem-examples.bib}

\begin{document}
\cite{sigfridsson,knuth:ct:e}.

See also \cite{solymosi2010question,halbeisen2019geometric,Kohnert2006IntegralPS}.
\printbibliography

\printbibitembibliography
\end{document}

\documentclass[a4paper]{article}
\usepackage[T1]{fontenc}
\begin{document}\parindent0em
Comparaison des fontes 8 bits par défaut et des fontes 8 bits de la famille lmodern :

{\fontsize{24}{36}\selectfont

Fontes à 24 pt

\fontsize{27}{36}\selectfont

Fontes à 27 pt

\fontsize{36}{36}\selectfont

Fontes à 36 pt

}
\fontfamily{lmr}\selectfont
Passage à la famille lmodern :
{\fontsize{24}{36}\selectfont

Fontes à 24 pt

\fontsize{27}{36}\selectfont

Fontes à 27 pt

\fontsize{36}{36}\selectfont

Fontes à 36 pt

}

\end{document}

\documentclass[french,a4paper,12pt]{book}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{libertine}
\usepackage[draft]{typogrid}
\usepackage{pagegrid}
\pagegridsetup{step=0.5cm}
\usepackage{blindtext}
\usepackage{babel}
\begin{document}
% \layout
\Blinddocument
\end{document}

\documentclass{article}
\usepackage{xcolor}
\usepackage{soul}
\begin{document}
\hl{test test test test test test test test test test test test test test test
  test test test test test test test test test test test test test}
\end{document}

\documentclass{article}
\usepackage{xcolor}
\usepackage{hyperref}

\makeatletter
% equivalent to "\hypersetup{hidelinks}" but allowed to use inside document env
\def\HyHidelinks{
  \Hy@colorlinksfalse
  \Hy@ocgcolorlinksfalse
  \Hy@frenchlinksfalse
  \def\Hy@colorlink##1{\begingroup}%
  \def\Hy@endcolorlink{\endgroup}%
  \def\@pdfborder{0 0 0}%
  \let\@pdfborderstyle\ltx@empty}
% equivalent to "\hypersetup{colorlinks}"
\def\HyColorlinks{
  \def\@pdfborder{0 0 0}%
  \let\@pdfborderstyle\@empty
  \def\Hy@colorlink##1{%
    \begingroup
    \HyColor@UseColor##1%
  }%
  \def\Hy@endcolorlink{\endgroup}}
\makeatother

\def\test{
  \begin{itemize}
    \item colored text: \textcolor{red}{CTAN}
    \item colored text inside href: \href{www.ctan.org}{C\textcolor{red}{T}AN}, \href{www.ctan.org}{C\textcolor{blue}{T}AN}
    \item normal ref: \ref{cmd}
  \end{itemize}}

\begin{document}
\section{title}\label{cmd}

\section*{Set \texttt{colorlinks=false} (default)}
\test

\section*{Set \texttt{colorlinks=true}}
\begingroup \HyColorlinks \test \endgroup

\section*{Set \texttt{colorlinks=true/false, hidelinks}}
\begingroup \HyHidelinks  \test \endgroup
\end{document}

\documentclass{article}
\usepackage{libertine}
\usepackage{glossaries}
\makeglossaries%
\setglossarystyle{listgroup}
\setacronymstyle{long-sc-short}
\newacronym{laser}{laser}{light amplification by stimulated
  emission of radiation}
%
\begin{document}
\begin{itemize}
\item \gls{laser}
\item \acrshort{laser}
\item \acrlong{laser}
\item \acrfull{laser}
\end{itemize}
\printglossary
\end{document}

% Test file `test.tex` be compiled with:
% pdflatex test && latexmk -norc -r latexmkrc-test.tex test
\begin{filecontents*}{latexmkrc-test}
$pdf_mode = 1;
$makeindex = 'texindy -L english';
\end{filecontents*}

\documentclass{article}
\usepackage[xindy]{imakeidx}
\makeindex
\begin{document}
Foo\index{Foo}
\printindex
\end{document}

\documentclass{article}
\usepackage{tcolorbox}
\tcbuselibrary{documentation}

\tcbset{color command=red, color key=blue}
\hypersetup{pdfborderstyle={/S/U/W 1}}

\makeatletter
% #1 = tcb link type
% #2 = hyp link color
% #3 = add page ref or not
% #4 = tcb ref name
\RenewDocumentCommand\tcb@ref@doc{ m o s m }{%
  \begingroup
  % change \@linkcolor locally, default is \kvtcb@colhyper
  \IfValueT{#2}{\hypersetup{linkcolor=#2}}%
  \hyperref[#1:#4]{\texttt{\ref*{#1:#4}}%
  \IfBooleanTF{#3}{}{%
    \ifnum\getpagerefnumber{#1:#4}=\thepage%
    \else%
      \textsuperscript{\ding{213}\,\kvtcb@text@pageshort\,\pageref*{#1:#4}}%
    \fi}}%
  \endgroup
}

%% all four usages of \tcb@ref@doc
\def\refCom{\tcb@ref@doc{com}[orange]} % set linkcolor to "orange"
\def\refEnv{\tcb@ref@doc{env}}
\def\refKey{\tcb@ref@doc{key}[]} % set linkcolor to default color (black)
\def\refPathOperation{\tcb@ref@doc{path}}
\makeatother

\begin{document}
\begin{docCommand}{foomakedocSubKey}{\marg{name}\marg{key path}}
\end{docCommand}

\begin{docKey}[foo]{footitle}{=\meta{text}}{no default, initially empty}
\end{docKey}


% test changed commands, with page ref
See \refCom{foomakedocSubKey} and \refKey{/foo/footitle}

\stepcounter{page}
% test changed commands, without page ref
See \refCom{foomakedocSubKey} and \refKey{/foo/footitle}

% test range is not leaked
\ref{com:foomakedocSubKey}
\end{document}

\documentclass[french]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage{babel}
\usetheme{PaloAlto}
\setbeamertemplate{navigation symbols}{}
\begin{document}
\section{Section 1}
\subsection{Sous-section 1 de la section 1}
\subsection{Sous-section 2 de la section 1}
\section{Section 2}
\subsection{Sous-section 1 de la section 2}
\subsection{Sous-section 2 de la section 2}
\begin{frame}
  \frametitle{Plan local}
  \tableofcontents[hideothersubsections] % Sous-sections : de la section en cours affichées, autres masquées
\end{frame}
\begin{frame}
  \frametitle{Plan local}
  \tableofcontents[currentsection,currentsubsection]       % (Sous-)Sections : en cours affichée(s), autres en filigrane
\end{frame}
\begin{frame}
  \frametitle{Plan local}
  \tableofcontents[currentsection,hideothersubsections,currentsubsection]       % (Sous-)Sections : en cours affichée(s), autres en filigrane
\end{frame}
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{csquotes}
\usepackage{biblatex}
\usepackage{babel}
% \usepackage{hyperref}
%
% \addbibresource[location=remote]{http://127.0.0.1:23119/better-bibtex/collection?/1/these.biblatex}
\addbibresource{these.bib}
%
\begin{document}
\nocite{*}

\printbibliography
\end{document}

\documentclass{article}
\usepackage{tcolorbox}
\tcbuselibrary{documentation}

\begin{document}
% copied from tcolorbox.doc.s_main
\tcbmakedocSubKey{docTcbKey}{tcb}

% copied from tcolorbox.doc.documentation.tex
\begin{docTcbKey}[][doc new={2019-09-18}]{doc label}{=\meta{text}}{no default, initially unset}
  If used inside the option list of \refEnv{docCommand}, \refEnv{docEnvironment},
  \refEnv{docKey}, or \refEnv{docPathOperation}, then \meta{text} is used
  for labeling instead of the name of the definition.
  \begin{dispExample}
    \begin{docPathOperation*}[doc label=pathline]{-{}-}{\meta{coordinate or cycle}}
      This is the documentation of \refPathOperation{pathline}.
    \end{docPathOperation*}
  \end{dispExample}
\end{docTcbKey}
\end{document}

\documentclass{article}
\usepackage{xcolor,adjustbox}
\usepackage{glossaries}
\makeglossaries

\newacronym{pc}{PC}{Personal Computer}

\setacronymstyle{long-short}
\renewcommand*{\acronymfont}[1]{\adjustbox{bgcolor=yellow}{#1}}

\begin{document}
\gls{pc}

\gls{pc}
\printglossary
\end{document}

\documentclass{article}
\usepackage{xparse}
\NewDocumentEnvironment{citequote}{!O{Shakespeare}}{%
  \begin{quotation}
    \noindent\textit{#1}:
  }{
  \end{quotation}
}
\begin{document}
\begin{citequote}
  [Foo] bar.
\end{citequote}
\end{document}

\documentclass{article}
\usepackage{adjustbox}
\usepackage{xcolor}
\usepackage{soul}
\usepackage{lipsum}
\begin{document}
% \setlength{\fboxsep}{0pt}

\adjustbox{bgcolor=cyan}{coucou}
\adjustboxset{margin=0ex 0ex 0ex 0ex}\adjustbox{bgcolor=cyan}{coucou}

\lipsum[1]

coucoucoucoucoucou

\lipsum*[1]\adjustboxset{margin=0ex 1ex 0ex 1ex}
\adjustbox{bgcolor=cyan}{coucou}%
\colorbox{green}{coucou}%
\hl{coucou}
\lipsum*[1]

\adjustbox{bgcolor=cyan}{coucou}
\adjustboxset{margin=0ex 0ex 0ex 0ex}\adjustbox{bgcolor=cyan}{coucou}

\adjustbox{bgcolor=cyan}{coucou}

\colorbox{green}{coucou}

\hl{coucou}

\end{document}


% used PGFPlots v1.16
\documentclass{article}
\usepackage{mwe}
\usepackage{listings}
\usepackage{pgfplots}
    \usetikzlibrary{spy}
    \tikzset{
        % (for simplicity I created a style so one does not have to repeat the whole code over and over again)
        /tikz/my spy settings/.style={
            spy using outlines={
                circle,
                magnification=10,
                size=6cm,
                connect spies
            },
        },
        % ---
        % add a new style similar to the `grid with coordinates` style
        add grid with coordinates/.style args={%
            with xmin #1 ymin #2 and xmax #3 ymax #4%
        }{
           % draw the grid on top of everything else (at the end of the picture)
            execute at end picture={
                \begin{axis}[
                    % -----------------------------------------------------------------
                    % stuff here was added
                    % (copied from the PGFPlots manual (v1.16) section 4.26 on page 406)
                    % -----------------------------------------------------------------
                    % tell pgfplots to "grab" the axis at its
                    % internal (0,0) coord:
                    anchor=origin,
                    % tell pgfplots to place its anchor at (0,0):
                    % (This is actually the default and can
                    % be omitted)
                    at={(0pt,0pt)},
                    % tell pgfplots to use the "natural" dimensions:
                    disabledatascaling,
                    % tell pgfplots to use the same unit vectors
                    % as tikz:
                    x=1cm,y=1cm,
                    % -----------------------------------------------------------------
                    xmin=#1,xmax=#3,
                    ymin=#2,ymax=#4,
                    xtick distance=1,
                    ytick distance=1,
                    minor tick num=4,
                    ticks=both,
                    grid=both,
                    % -----------------------------------------------------------------
                    % stuff here was added as well to make the grid visible
                    % (the default grid color matches the background color of the
                    %  chosen example image)
                    grid style={black!50},
                    major grid style={very thick},
                ]
                \end{axis}
            },
        },
    }

\makeatletter
\def\grd@save@target#1{%
  \def\grd@target{#1}}
\def\grd@save@start#1{%
  \def\grd@start{#1}}
\tikzset{
  grid with coordinates/.style={
    to path={%
      \pgfextra{%
        \edef\grd@@target{(\tikztotarget)}%
        \tikz@scan@one@point\grd@save@target\grd@@target\relax
        \edef\grd@@start{(\tikztostart)}%
        \tikz@scan@one@point\grd@save@start\grd@@start\relax
        \draw[minor help lines] (\tikztostart) grid (\tikztotarget);
        \draw[major help lines] (\tikztostart) grid (\tikztotarget);
        \grd@start
        \pgfmathsetmacro{\grd@xa}{\the\pgf@x/1cm}
        \pgfmathsetmacro{\grd@ya}{\the\pgf@y/1cm}
        \grd@target
        \pgfmathsetmacro{\grd@xb}{\the\pgf@x/1cm}
        \pgfmathsetmacro{\grd@yb}{\the\pgf@y/1cm}
        \pgfmathsetmacro{\grd@xc}{\grd@xa + \pgfkeysvalueof{/tikz/grid with coordinates/major step}}
        \pgfmathsetmacro{\grd@yc}{\grd@ya + \pgfkeysvalueof{/tikz/grid with coordinates/major step}}
        \foreach \x in {\grd@xa,\grd@xc,...,\grd@xb}
        \node[anchor=north] at (\x,\grd@ya) {\pgfmathprintnumber{\x}};
        \foreach \y in {\grd@ya,\grd@yc,...,\grd@yb}
        \node[anchor=east] at (\grd@xa,\y) {\pgfmathprintnumber{\y}};
      }
    }
  },
  minor help lines/.style={
    help lines,
    step=\pgfkeysvalueof{/tikz/grid with coordinates/minor step}
  },
  major help lines/.style={
    help lines,
    line width=\pgfkeysvalueof{/tikz/grid with coordinates/major line width},
    step=\pgfkeysvalueof{/tikz/grid with coordinates/major step}
  },
  grid with coordinates/.cd,
  minor step/.initial=.2,
  major step/.initial=1,
  major line width/.initial=2pt,
}
\makeatother
\begin{document}
\section{Examples with spies}

\subsection{Grid with coordinates: nice and useful to locate a given point}

\begin{tikzpicture}[my spy settings]
    \node[inner sep=0pt] {%
        \includegraphics[width=5cm]{example-image-golden}%
    };
    \draw (-3,-2) to[grid with coordinates] (3,2);
    \spy[red] on (-1.55,0) in node at (.7\textwidth,0);
\end{tikzpicture}


\subsection{Grid with pgfplots axis: not handy (brain storming needed to position the node?)}

\begin{tikzpicture}[
    my spy settings,
    add grid with coordinates={with xmin -3 ymin -2 and xmax 3 ymax 2},
]
    \node[inner sep=0pt] {%
\begin{lstlisting}
\foo
\end{lstlisting}
    };
    \spy[red] on (-1.55,0) in node at (.7\textwidth,0);
\end{tikzpicture}

\end{document}

\documentclass{article}
\usepackage{lmodern}
\usepackage{listings}
\usepackage{tikz}

\lstset{
  language=[AlLaTeX]TeX, %
  basicstyle=\ttfamily,%
}

\begin{document}
\begin{tikzpicture}
    \node[inner sep=0pt] {%
\begin{lstlisting}
\tikz \draw[thick,rounded corners=8pt]
(0,0) -- (0,2) -- (1,3.25) -- (2,2) -- (2,0) -- (0,2) -- (2,2) -- (0,0) -- (2,0);
\end{lstlisting}
    };
  \end{tikzpicture}
\end{document}


\documentclass{beamer}
\input GoudyIn.fd
\usepackage{kpfonts}
\usepackage{pgfornament}

\usetheme{CambridgeUS}

\newcommand*\initfamily{\usefont{U}{GoudyIn}{xl}{n}}

\begin{document}
\begin{frame}[plain]
  \newcommand{\framesize}{.8\linewidth}%
  \centering%
\begin{tikzpicture}[color=red!75,
transform shape,
every node/.style={inner sep=0pt}]
\node[minimum size=\framesize](vecbox){};
\node[anchor=north west] at (vecbox.north west){%
\pgfornament[width=0.2*\framesize]{63}};
\node[anchor=north east] at (vecbox.north east){%
\pgfornament[width=0.2*\framesize,symmetry=v]{63}};
\node[anchor=south west] at (vecbox.south west){%
\pgfornament[width=0.2*\framesize,symmetry=h]{63}};
\node[anchor=south east] at (vecbox.south east){%
\pgfornament[width=0.2*\framesize,symmetry=c]{63}};
\node[anchor=north] at (vecbox.north){%
\pgfornament[width=0.6*\framesize,symmetry=h]{46}};
\node[anchor=south] at (vecbox.south){%
\pgfornament[width=0.6*\framesize]{46}};
\node[anchor=north,rotate=90] at (vecbox.west){%
\pgfornament[width=0.6*\framesize,symmetry=h]{46}};
\node[anchor=north,rotate=-90] at (vecbox.east){%
\pgfornament[width=0.6*\framesize,symmetry=h]{46}};
\node[inner sep=6pt] (text) at (vecbox.center){%
  \begin{minipage}{.8\linewidth}
    \Large\bfseries\centering\color{black}%
    {\initfamily SELON UNE LEGENDE}

    {\initfamily DES TEMPS ANCIENS}

    {\LaTeX{}}

    {\initfamily EST COMPLEXE}
  \end{minipage}
};
\node[anchor=north] at (text.south){%
\pgfornament[width=0.5*\framesize]{75}};
\node[anchor=south] at (text.north){%
\pgfornament[width=0.5*\framesize,symmetry=h]{75}};
\end{tikzpicture}
\end{frame}
\end{document}

\documentclass{article}
\usepackage{expl3}
\ExplSyntaxOn
\cs_new:Npn \demo_cmd #1
{
  \begin{description}
  \item[argument \#1:] #1
  % \item[argument \#2:] #2
  % \item[argument \#3:] #3
  % \item[argument \#4:] #4
  % \item[argument \#5:] #5
  % \item[argument \#6:] #6
  % \item[argument \#7:] #7
  % \item[argument \#8:] #8
  % \item[argument \#9:] #9
  \end{description}
}
\ExplSyntaxOff
\begin{document}
Foo.
\end{document}

\documentclass[12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{ifpdf}
\ifpdf
\usepackage{libertine}
\fi
% \usepackage{iftex}
% \ifPDFTeX
% \usepackage{libertine}
% \fi
\begin{document}
affiliation
\end{document}

\documentclass{article}
\usepackage{varioref}
\usepackage{cleveref}
%
\begin{document}
\section{A section}\label{sec:1}
\newpage
\begin{equation}
  \label{eq:1}
  x=0
\end{equation}
It follows from \vref{eq:1,sec:1}...
\end{document}

\documentclass{article}
\usepackage{etoolbox}
\usepackage{tcolorbox}
\makeatletter
\AtEndPreamble{%
  \@ifpackageloaded{tcolorbox}{%
    \csdef{toto}{%
      Package tcolorbox loaded
    }
    \tcbuselibrary{skins}%
  }{%
    \csdef{toto}{%
      Package tcolorbox not loaded
    }
  }
}
\makeatother
\begin{document}
\csuse{toto}
\end{document}

\documentclass{yathesis}
\usepackage{mwe}
\usepackage[step=5mm]{pagegrid}
\usepackage[type=upperright]{fgruler}

\laboratory[logo=example-image-a]{laba}{aaa}
\laboratory[logo=example-image-b,logoheight=3cm]{labb}{bbb}
\laboratory[logo=example-image-c,logoheight=4cm]{labc}{ccc}
\begin{document}
\makelaboratory
\end{document}

\documentclass{minimal}
\usepackage{l3sys-shell}
\parindent0pt
\ExplSyntaxOn
\begin{document}
\sys_shell_get_pwd:N \l_tmpa_str
|\l_tmpa_str|                     \\

\endlinechar=-1
\sys_shell_get_pwd:N \l_tmpa_str
|\l_tmpa_str|

\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{tikz}
\usepackage[a4paper]{geometry}
\usepackage{babel}

\usetikzlibrary{arrows, automata, positioning}

\begin{document}
\begin{tikzpicture}[->,>=stealth',shorten >=1pt,%
auto,node distance=2cm,on grid,semithick,
inner sep=2pt,bend angle=45]
\node[initial,state] (A)
{$q_a$};
\node[state]
(B) [above right=of A] {$q_b$};
\node[state]
(D) [below right=of A] {$q_d$};
\node[state]
(C) [below right=of B] {$q_c$};
\node[state]
(E) [below=of D]
{$q_e$};
\usepackage{\path [every node/}
(A) edge
node {0,1,L} (B)
edge
node {1,1,R} (C)
(B) edge [loop above] node {1,1,L} (B)
edge
node {0,1,L} (C)
(C) edge
node {0,1,L} (D)
edge [bend left] node {1,0,R} (E)
(D) edge [loop below] node {1,1,R} (D)
edge
node {0,1,R} (A)
(E) edge [bend left] node {1,0,R} (A);
\end{tikzpicture}
\end{document}

\begin{filecontents*}{\jobname.bib}
@incollection{deitmar2005schemes,
  title={Schemes over },
  author={Deitmar, Anton},
  booktitle={Number fields and function fields---two parallel worlds},
  editor={Gerard van der Geer and Ben Moonen and Ren{\'e} Schoof},
  pages={87--100},
  year={2005},
  publisher={Birkh{\"a}user Boston}
}
@article{kurokawa2005zeta,
  title={Zeta functions over},
  author={Kurokawa, Nobushige and others},
  journal={Proceedings of the Japan Academy, Series A, Mathematical Sciences},
  volume={81},
  number={10},
  pages={180--184},
  year={2005},
  publisher={The Japan Academy}
}
\end{filecontents*}

\documentclass{yathesis}
% \usepackage{fontspec}
\usepackage{biblatex}
\usepackage{hyperref}

\addbibresource{\jobname.bib}
% \addbibresource{biblatex-examples.bib}

\begin{document}

\tableofcontents{}

\mainmatter
\chapter{test}

\nocite{*}
% \chapter*{Bibliography}
% \begingroup
% \let\cleardoublepage\relax
% \printbibliography[heading=none]
% \endgroup

\printbibliography

\end{document}

\documentclass[t]{beamer}
\usepackage[most]{tcolorbox}
\begin{document}
\begin{frame}
\begin{tcbitemize}[raster equal height=rows,
enhanced,colback=blue!5,colframe=blue!20!gray,coltitle=yellow,
beamer hidden/.style={invisible,interior hidden,colframe=blue!20!gray!15},
beamer alerted/.style={colframe=red!50!gray},
]
\tcbitem[title=One,alert=<1>]
First Statement
\tcbitem[title=Two,hide=<-1>,alert=<2>]
Second Statement
\tcbitem[title=Three,hide=<-2>,alert=<3>]
Test
\tcbitem[title=Four,hide=<-3>,alert=<4>]
\begin{equation*}
\int\limits_{1}^{x} \frac{1}{t}~dt = \ln(x).
\end{equation*}
\tcbitem[title=Five,hide=<-4>,alert=<5>]
\includegraphics[width=1cm]{goldshade.png}
\tcbitem[title=Six,hide=<-5>,alert=<6>]
Test
\end{tcbitemize}
\end{frame}
\end{document}

\documentclass[t]{beamer}
\usepackage[most]{tcolorbox}
\tcbset{
  beamer alerted/.style={colframe=red},
}
\begin{document}
\begin{frame}
\begin{tcbitemize}[raster equal height=rows,
enhanced,colback=blue!5,colframe=blue!20!gray,coltitle=yellow,
]
\tcbitem[title=One,alert=<1>]
First Statement
\tcbitem[title=Two,hide=<-1>,alert=<2>]
Second Statement
\tcbitem[title=Three,hide=<-2>,alert=<3>]
Test
\tcbitem[title=Four,hide=<-3>,alert=<4>]
\begin{equation*}
\int\limits_{1}^{x} \frac{1}{t}~dt = \ln(x).
\end{equation*}
\tcbitem[title=Five,hide=<-4>,alert=<5>]
\includegraphics[width=1cm]{goldshade.png}
\tcbitem[title=Six,hide=<-5>,alert=<6>]
Test
\end{tcbitemize}
\end{frame}
\end{document}

\begin{document}
On consultera le document~\vref{doc-1}.

\section{Bla bla}

\lipsum[1-10]

\begin{doc}[t]
    \centering
    \includegraphics[width=\linewidth]{document-annexe-1}
    \caption{Où il est question d'un beau A}
    \label{doc-1}
\end{doc}

\lipsum[1-10]
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}

\begin{figure}
  \centering
  \caption{Deux belles figures}
  \label{belles-figures}
\end{figure}

\begin{figure}
  \centering
  \caption{Deux belles figures}
  \label{belles-figures}
\end{figure}

\end{document}

\documentclass{article}
\usepackage{fontspec}
\setmainfont{Latin Modern Mono Light}

\usepackage{luacode}

\usepackage[margin=18mm]{geometry}
\parindent=0pt

\usepackage{longtable,makecell}
\renewcommand\arraystretch{2}

\begin{document}
\begin{luacode}
  myfonts=dofile(config.luaotfload.paths.index_path_luc)
  teststring = "Dès Noël où un zéphyr haï me vêt de glaçons würmiens je dîne d'exquis rôtis de bœuf au kir à l'aÿ d'âge mûr et cætera !"

for i,v in ipairs(myfonts.mappings) do
  -- Stop early for testing purposes.
  if i > 200 then break end

  tex.print(-2, v.familyname)
  tex.print(': ')
  tex.print(-2, v.fontname)
  tex.print('\\par')
  tex.print('{ \\fontspec{' .. v.fontname .. '}')
  tex.print(-2, teststring)
  tex.print('}\\par')
  tex.print('\\rule{\\textwidth}{1pt}')
end
\end{luacode}
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{babel}
\begin{document}
\DTMdate{2015-03-23}
\end{document}


\documentclass{article}
% \usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{xstring}
\begin{document}
\StrBehind*{Café}{f}[\var]
\end{document}

\documentclass{ltxdoc}

\usepackage{alltt}
\usepackage{graphicx}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[colorlinks,
            bookmarks,
            hyperindex=false,
            pdfauthor={Nicola L.C. Talbot and Paul A. Patience},
            pdftitle={datetime2.sty French Module}]{hyperref}


\CheckSum{580}

\renewcommand*{\usage}[1]{\hyperpage{#1}}
\renewcommand*{\main}[1]{\hyperpage{#1}}
\IndexPrologue{\section*{\indexname}\markboth{\indexname}{\indexname}}
\setcounter{IndexColumns}{2}

\newcommand*{\sty}[1]{\textsf{#1}}
\newcommand*{\opt}[1]{\texttt{#1}\index{#1=\texttt{#1}|main}}

\RecordChanges
\PageIndex
\CodelineNumbered

\begin{document}
\DocInput{datetime2-french.dtx}
\end{document}

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{textcomp}
\usepackage{listings}

\lstset{%
  basicstyle=\ttfamily,%
  upquote,
  columns=flexible
}

\begin{document}
\begin{lstlisting}
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{tikz}
\usetikzlibrary{arrows, automata, positioning}
\begin{document}
\section{A Ti\textit{k}Z picture}
\begin{tikzpicture}[->,>=stealth',shorten >=1pt,%
                    auto,node distance=2cm,on grid,semithick,
                    inner sep=2pt,bend angle=45]
  \node[initial,state] (A)                    {$q_a$};
  \node[state]         (B) [above right=of A] {$q_b$};
  \node[state]         (D) [below right=of A] {$q_d$};
  \node[state]         (C) [below right=of B] {$q_c$};
  \node[state]         (E) [below=of D]       {$q_e$};

  \path [every node/.style={font=\footnotesize}]
        (A) edge              node {0,1,L} (B)
            edge              node {1,1,R} (C)
        (B) edge [loop above] node {1,1,L} (B)
            edge              node {0,1,L} (C)
        (C) edge              node {0,1,L} (D)
            edge [bend left]  node {1,0,R} (E)
        (D) edge [loop below] node {1,1,R} (D)
            edge              node {0,1,R} (A)
        (E) edge [bend left]  node {1,0,R} (A);
\end{tikzpicture}



\section{A very nice math formula}
$e^{i\pi}+1 = 0$
\end{document}
\end{lstlisting}
\end{document}

\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows, automata, positioning}

\begin{document}

\begin{tikzpicture}[->,>=stealth',shorten >=1pt,%
                    auto,node distance=2cm,on grid,semithick,
                    inner sep=2pt,bend angle=45]
  \node[initial,state] (A)                    {$q_a$};
  \node[state]         (B) [above right=of A] {$q_b$};
  \node[state]         (D) [below right=of A] {$q_d$};
  \node[state]         (C) [below right=of B] {$q_c$};
  \node[state]         (E) [below=of D]       {$q_e$};

  \path [every node/.style={font=\footnotesize}]
        (A) edge              node {0,1,L} (B)
            edge              node {1,1,R} (C)
        (B) edge [loop above] node {1,1,L} (B)
            edge              node {0,1,L} (C)
        (C) edge              node {0,1,L} (D)
            edge [bend left]  node {1,0,R} (E)
        (D) edge [loop below] node {1,1,R} (D)
            edge              node {0,1,R} (A)
        (E) edge [bend left]  node {1,0,R} (A);
\end{tikzpicture}

\end{document}



\documentclass{article}
\usepackage{xcolor}
\usepackage{transparent}
\usepackage{graphicx}

\begin{document}
\input{Bitmap_VS_SVG_Fr-new.pdf_tex}
\end{document}

\documentclass{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{filecontents}
\usepackage[check-declarations]{expl3}
\usepackage{xparse}

\begin{filecontents*}{topic1}
\topictitle{\TeX{}, \LaTeX{} and café}
\begin{frame}
  \TeX{}, \LaTeX{} and café are nice!
\end{frame}
\end{filecontents*}

\begin{filecontents*}{topic2}
\topictitle{Topic 2}
\begin{frame}
  Topic 2 is nice!
\end{frame}
\end{filecontents*}

\begin{filecontents*}{topic3}
\topictitle{Topic 3}
\begin{frame}
  Topic 3 is nice!
\end{frame}
\end{filecontents*}

\begin{filecontents*}{topic4}
\topictitle{Topic 4}
\begin{frame}
  Topic 4 is nice!
\end{frame}
\end{filecontents*}

\begin{filecontents*}{topic5}
\topictitle{Topic 5}
\begin{frame}
  Topic 5 is nice!
\end{frame}
\end{filecontents*}

\ExplSyntaxOn

\seq_new:N \g_topics_seq


\NewDocumentCommand\addtopictitle{m}
{
 \seq_gput_right:Nn\g_topics_seq {#1}
}

\makeatletter
\NewDocumentCommand{\topictitle}{m}
{
  \iow_now:Nx \@mainaux
   {
    \exp_not:n {\addtopictitle{#1}}
   }
}

\title{\tl_mixed_case:n{\seq_use:Nn\g_topics_seq {,~}}}

\ExplSyntaxOff

\begin{document}
\maketitle{}
%
\input{topic1}
% \input{topic2}
\input{topic3}
\input{topic4}
\input{topic5}
\end{document}

\documentclass[french]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage{etoolbox}
\usepackage{filecontents}
\usepackage[check-declarations]{expl3}
\usepackage{xparse}
% \RequirePackage{hologo}
% \RequirePackage{bxtexlogo}
\usepackage{babel}

% \bxtexlogoimport{*}
% \AtBeginDocument{\hologoFontSetup{general=\color{alert}}}

\usetheme{PaloAlto}

\begin{filecontents*}{foo1}
\topictitle{\TeX{} is nice!}
\begin{frame}
  Here, the Foo 1 topic is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo2}
\topictitle{\LaTeX{} is café}
\begin{frame}
  Here, the Foo 2 topic is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo3}
\topictitle{Foo 3 (test)}
\begin{frame}
  Here, the Foo 3 topic is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo4}
\topictitle{Foo 4 (test)}
\begin{frame}
  Here, the Foo 4 topic is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo5}
\topictitle{Foo 5 (test)}
\begin{frame}
  Here, the Foo 5 topic is detailed.
\end{frame}
\end{filecontents*}

\ExplSyntaxOn

\seq_new:N \g_subjects_seq
\tl_new:N \g_presentation_subtitle_tl
\iow_new:N \g_output_stream

\NewDocumentCommand{\topictitle}{m}
{
  \__subject_title:n {#1}
}

\cs_new_protected:Npn \__subject_title:n #1
{
  \seq_gput_right:Nn \g_subjects_seq {#1}
}

\AtEndDocument
{
  % \seq_show:N \g_subjects_seq
  \tl_set:Nx \l_tmpa_tl
  {
    \seq_use:Nn\g_subjects_seq {,~}
  }
  \tl_gset:Nx \g_presentation_subtitle_tl {
    \tl_mixed_case:n {
      \l_tmpa_tl
    }
  }
  \iow_open:Nn \g_output_stream { \c_sys_jobname_str.sbj }
  \iow_now:Nx \g_output_stream { \exp_not:N\g_presentation_subtitle_tl }
  \iow_close:N \g_output_stream
}

\AtEndPreamble{%
  \title{Foo}
  \file_if_exist:nT {\c_sys_jobname_str.sbj} {
    \tl_set:Nx \l_tmpa_tl {\file_input:n {\c_sys_jobname_str.sbj}}
    \subtitle{\l_tmpa_tl}
  }
}
\ExplSyntaxOff

\begin{document}
\maketitle{}
%
\input{foo1}
\input{foo2}
\input{foo3}
\input{foo4}
\input{foo5}
\end{document}

\documentclass[french]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage{filecontents}
\usepackage[check-declarations]{expl3}
\usepackage{xparse}
\usepackage{currfile}
\usepackage{babel}

\begin{filecontents*}{foo1}
\topictitle{Foo 1 (test)}
\begin{frame}
  Here, the Foo 1 subject is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo2}
\topictitle{Foo 2 (test)}
\begin{frame}
  Here, the Foo 2 subject is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo3}
\topictitle{Foo 3 (test)}
\begin{frame}
  Here, the Foo 3 subject is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo4}
\topictitle{Foo 4 (test)}
\begin{frame}
  Here, the Foo 4 subject is detailed.
\end{frame}
\end{filecontents*}

\begin{filecontents*}{foo5}
\topictitle{Foo 5 (test)}
\begin{frame}
  Here, the Foo 5 subject is detailed.
\end{frame}
\end{filecontents*}

\ExplSyntaxOn

\seq_new:N \g_subjects_seq
\tl_new:N \g_presentation_subtitle_tl

\AtBeginDocument
{
  \tl_gset:Nx \g_presentation_subtitle_tl
  {
    \seq_use:Nn\g_subjects_seq {,~}
  }
  \exp_args:NV \title \g_presentation_subtitle_tl
}

\NewDocumentCommand{\topictitle}{m}
{
  \__subject_title:n {#1}
}

\cs_new_protected:Npn \__subject_title:n #1
{
  \iow_now:cn { @auxout }
   {
     \ExplSyntaxOn
     ^^J
     \seq_gput_right:Nn \g_subjects_seq {#1}
     \seq_show:N \g_subjects_seq
     ^^J
     \ExplSyntaxOff
  }
}

\ExplSyntaxOff
\begin{document}
\maketitle{}
%
% \input{foo1}
\input{foo2}
% \input{foo3}
\input{foo4}
% \input{foo5}
\end{document}

\documentclass[french]{beamer}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage{xparse}
\usepackage{filecontents}
\usepackage{babel}

\ExplSyntaxOn

\prop_new:N \g_subjects_prop
\seq_new:N \g_chosen_subjects_seq
\tl_new:N \g_first_chosen_subject_tl
\tl_new:N \g_last_chosen_subject_tl
\tl_new:N \g_title_tl

\NewDocumentCommand{\SubjectFileTitle}{mm}
 {
  \prop_gput:Nnn \g_subjects_prop {#1} {#2}
 }
%
% \NewDocumentCommand{\Gettopic}{m}
%  {
%   \prop_item:Nn \g_subjects_prop {#1}
% }

\NewDocumentCommand{\ChosenSubjects}{m}
{
  \seq_gset_from_clist:Nn \g_chosen_subjects_seq { #1 }
  \seq_set_eq:NN \g_tmpa_seq \g_chosen_subjects_seq
  % \seq_pop_left:NN \g_tmpa_seq \g_tmpa_tl
  % \tl_show:N \g_tmpa_tl
  % \prop_get:NVN \g_subjects_prop {\g_tmpa_tl} \g_first_chosen_subject_tl
  % \seq_pop_right:NN \g_tmpa_seq \g_tmpa_tl
  % \tl_show:N \g_tmpa_tl
  % \prop_get:NVN \g_subjects_prop {\g_tmpa_tl} \g_last_chosen_subject_tl
  % \tl_put_right:Nn \g_title_tl {\tl_mixed_case:n {\g_first_chosen_subject_tl},\c_space_tl}
  % \tl_show:N \g_title_tl
  % \tl_put_right:Nx \g_title_tl {
  \tl_gset:Nx \g_title_tl {
    \seq_use:Nn \g_tmpa_seq {
      \prop_item:Nn \g_subjects_prop {##1},\c_space_tl
    }
  }
  % \tl_show:N \g_title_tl
  % \tl_put_right:Nn \g_title_tl {\g_last_chosen_subject_tl}
  % \tl_show:N \g_title_tl
  \title{
    \g_title_tl
    % \seq_map_inline:Nn \g_tmpa_seq
    % {
    % \prop_item:Nn \g_subjects_prop {##1},\c_space_tl
    % }
  }
}

\NewDocumentCommand{\getsubjectstitles}{}
{
  \seq_set_eq:NN \g_tmpa_seq \g_chosen_subjects_seq
  \seq_pop_left:NN \g_tmpa_seq \g_tmpa_tl
  \prop_get:NVN \g_subjects_prop {\g_tmpa_tl} \g_first_chosen_subject_tl
  \tl_mixed_case:n {\g_first_chosen_subject_tl},\c_space_tl
  \seq_pop_right:NN \g_tmpa_seq \g_tmpb_tl
  \prop_get:NVN \g_subjects_prop {\g_tmpb_tl} \g_last_chosen_subject_tl
  \seq_map_inline:Nn \g_tmpa_seq
  {
    \prop_item:Nn \g_subjects_prop {##1},\c_space_tl
  }
  \g_last_chosen_subject_tl
 }

\NewDocumentCommand{\inputsubjects}{}
 {
   \seq_map_inline:Nn \g_chosen_subjects_seq
   {
     \par
     \file_if_exist_input:nF {##1}{Fichier~\texttt{##1.tex}~introuvable}
   }
 }
\ExplSyntaxOff

\SubjectFileTitle{commandes-latex}{commandes}
\SubjectFileTitle{packages}{packages}
\SubjectFileTitle{structuration}{structuration}
\SubjectFileTitle{pdf}{documents hypertextes}
\SubjectFileTitle{images}{images}
\SubjectFileTitle{macros}{macros personnelles}
\SubjectFileTitle{tableaux}{tableaux}
\SubjectFileTitle{documents-longs}{documents longs}
\SubjectFileTitle{ressources}{ressources}
\SubjectFileTitle{maths}{mathématiques}
\SubjectFileTitle{theoremes}{théorèmes}
\SubjectFileTitle{unites}{unités}
\SubjectFileTitle{listings}{listings informatiques}
\SubjectFileTitle{beamer}{diaporamas}
\SubjectFileTitle{biblatex}{bibliographie}
\SubjectFileTitle{citations}{citations d'extraits}
\SubjectFileTitle{glossaires}{glossaires et (liste d')acronymes}
\SubjectFileTitle{index}{index}
\SubjectFileTitle{moteurs}{nouveaux moteurs}
\SubjectFileTitle{dessins}{dessins de très haute qualité}
\SubjectFileTitle{aeration}{aération du texte}
\SubjectFileTitle{paragraphes-images}{texte habillant un flottant}
\SubjectFileTitle{html}{\LaTeX{} \texorpdfstring{$\to$}{->} HTML}
\SubjectFileTitle{courbes}{courbes de fonctions et de données expérimentales}
\SubjectFileTitle{erreurs-communes}{erreurs \texorpdfstring{\LaTeX}{LaTeX}
  courantes}

\ChosenSubjects{pdf,maths,theoremes,html,courbes}
\begin{document}
\getsubjectstitles
\begin{frame}[plain]
  \maketitle
\end{frame}
\begin{frame}
  \inputsubjects
\end{frame}
\end{document}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{csvsimple}
\usepackage{etoolbox}
\usepackage{filecontents}
\usepackage{babel}

\begin{filecontents*}{pdf}
Je suis le fichier \texttt{pdf.tex}.
\end{filecontents*}

\begin{filecontents*}{maths}
Je suis le fichier \texttt{maths.tex}.
\end{filecontents*}

\begin{filecontents*}{\jobname.csv}
fichier,titre
pdf,documents hypertextes
maths,mathématiques
\end{filecontents*}

\newcommand{\createsubtitle}[2]{%
  \apptocmd{\soustitre}{Titre. Structuration. }{}{}%
}

\begin{document}
\title{%
  \csvreader{\jobname.csv}{1=\fichier,2=\titre}{%
    \csviffirstrow{\makefirstuc{\titre}}{\titre}
  }
}
\maketitle
\end{document}

\begin{filecontents*}{\jobname.csv}
fichier,titre
commandes-latex,commandes
packages,packages
structuration,structuration
pdf,documents hypertextes
images,images
macros,macros personnelles
tableaux,tableaux
documents-longs,documents longs
ressources,ressources
maths,mathématiques
theoremes,théorèmes
unites,unités
listings,listings informatiques
beamer,diaporamas
biblatex,bibliographie
citations,citations d'extraits
glossaires,glossaires et (liste d')acronymes
index,index
moteurs,nouveaux moteurs
dessins,dessins de très haute qualité
aeration,aération du texte
paragraphes-images,texte habillant un flottant
html,\LaTeX{} \texorpdfstring{$\to$}{->} HTML
courbes,courbes de fonctions et de données expérimentales
erreurs-communes,erreurs \texorpdfstring{\LaTeX}{LaTeX} courantes
\end{filecontents*}

\documentclass[french]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[a4paper]{geometry}
\usepackage{csquotes}
\usepackage{Commandes}
\usepackage{graphicx}
\usepackage{biblatex}
\usepackage{filecontents}
\usepackage{babel}
\usepackage{hyperref}

\addbibresource{stage-latex.bib}

% \newcommand{\METAPOST}{\hologo{METAPOST}}

% \newcommand{\programme}[1]{\texttt{#1}}
% \newcommand{\package}[1]{\textsf{#1}}

\DeclareFieldFormat{note}{\includegraphics[width=3cm]{#1}}

\DeclareCiteCommand{\photo}
  {}
  {\printfield{note}}
  {}
  {}

\DeclareCiteCommand{\citehrefurl}
  {\boolfalse{citetracker}%
   \boolfalse{pagetracker}}
  {\iffieldundef{url}
     {\PackageWarning{biblatex}
        {The entry \thefield{entrykey} has no URL.\MessageBreak
         No link will be created}%
      \printfield{postnote}}
     {\href{\thefield{url}}
        {\iffieldundef{postnote}
           {\PackageWarning{biblatex}
              {Text argument missing,\MessageBreak
               using the title for entry\MessageBreak
               \thefield{entrykey}}%
            \printfield[citetitle]{labeltitle}}
           {\printfield{postnote}}}}}
  {}
  {}

\DeclareFieldFormat{citeshorttitle}{#1}

\DeclareCiteCommand{\citeshorttitle}
  {\boolfalse{citetracker}%
   \boolfalse{pagetracker}%
   \usebibmacro{prenote}}
  {\iffieldundef{shorttitle}
    {\printfield[citeshorttitle]{title}}%
    {\printfield[citeshorttitle]{shorttitle}}%
  }
  {\multicitedelim}
  {\usebibmacro{postnote}}


\newcommand*{\citehref}[2]{\citehrefurl[#2]{#1}}

\begin{document}

\newcommand{\test}[1]{%
  \section[#1]{\citefield{#1}{title}}\label{#1}
  \begin{description}
  \item[title:] \citefield{#1}{title}
  \item[shorttitle:] \citeshorttitle{#1}
  \item[href + author:] \citehref{#1}{\citename{#1}{author}}
  \item[location:] \citelist{#1}{location}
  \item[abstract:] \citefield{#1}{abstract}
  \item[photo:] \photo{#1}
  \end{description}
}

\tableofcontents

\test{productivite}
\test{mp1}
\test{mp-scratch}
\test{git}
\test{biblatex}
\test{beamer}
\end{document}

\documentclass{article}

\usepackage{xparse}
\usepackage{mwe}

\ExplSyntaxOn

\prop_new:N \l_test_res_prop

\NewDocumentCommand \res { m }
 {
  \clist_map_inline:nn { #1 }
   {
    \prop_item:Nn \l_test_res_prop { ##1 }
   }
 }
\NewDocumentCommand \testset { +m }
 {
  \prop_set_from_keyval:Nn \l_test_res_prop { #1 }
 }

\ExplSyntaxOff

\testset{
  something={\begin{center}\Huge\bfseries\itshape Something \dots\end{center}},
  this way comes={\begin{center}\Huge\bfseries\itshape \includegraphics[width=.5\linewidth]{image-1x1}\par this way comes \dots\end{center}},
  wicked={\begin{center}\Huge\bfseries\itshape wicked \dots\end{center}}
}

\usepackage{graphicx}

\begin{document}
Foo.

\res{something, this way comes,wicked}

\end{document}

\documentclass{beamer}
\usepackage{mwe}
\usetheme{PaloAlto}
\makeatletter
\logo{\includegraphics[height=\sidebarheight]{example-image-1x1}}
\makeatother
\begin{document}
\begin{frame}
Foo
\end{frame}
\end{document}

\documentclass{beamer}
\setbeamertemplate{footline}[page number]
\setbeamertemplate{navigation symbols}{}
%
\usepackage{tcolorbox}
\tcbuselibrary{xparse}

\DeclareTColorBox{mybox}{ O{} }{%
   only=<1>{lowerbox=invisible},
   #1%
}
%
\begin{document}

\begin{frame}
\frametitle{The non-tcolorbox way}
\begin{block}{Upper}
   Foo
\end{block}
\pause
\begin{block}{Lower}
   Bar
\end{block}
\pause
\begin{block}{Comment}
   Nice: the comment appears only on the 3rd slide, after the code and
   result blocks.
\end{block}
\end{frame}

\begin{frame}
   \frametitle{The tcolorbox way}
\begin{tcolorbox}[only=<1>{lowerbox=invisible}]
   Foo
   \tcblower
   Bar
\end{tcolorbox}
\begin{block}<3->{Comment}
   Not so nice: the comment appears before the 3rd slide (and the
   footline has disappeared).
\end{block}
\end{frame}

\end{document}


%%% Local Variables:
%%% mode: latex
%%% TeX-master: t
%%% End:
