\documentclass[a4paper,12pt]{report}
\usepackage[utf8]{inputenc}
\usepackage{fontenc}
\usepackage[french, arabic]{babel} % If you write in French
\usepackage{a4wide}
\usepackage{graphicx}
\usepackage{placeins}
\usepackage{listings}
%\usepackage{pythonhighlight}
\usepackage{amsmath}
\usepackage{xcolor}
%pour la mise en page des tableaux %%%dFDFDFD
\usepackage{array}
\usepackage{polyglossia}
\usepackage{tabularx}
%\usepackage[table,xcdraw]{xcolor}
\usepackage{wrapfig}
\usepackage{subcaption}
\usepackage{color, colortbl}
\definecolor{Gray}{gray}{0.9}
\definecolor{LightCyan}{rgb}{0.88,1,1}
\usepackage{longtable}
\usepackage{float}
\usepackage{array} % for extrarowheight
\usepackage{lscape}
\usepackage{afterpage}
\usepackage{rotating}
\usepackage[nottoc,notlof,notlot]{tocbibind}
\usepackage{tocloft}
\renewcommand{\cfttoctitlefont}{\hfill\Large\bfseries}
\renewcommand{\cftaftertoctitle}{\hfill\mbox{}}
\usepackage{pdfpages}
\graphicspath{{images/}{images_pfe/}}
\newlength\figureheight
\newlength\figurewidth
\usepackage{ifthen}
\usepackage{ifpdf}
\ifpdf
\usepackage[pdftex]{hyperref}
\else
\usepackage{hyperref}
\fi
\usepackage{color}
\hypersetup{%
colorlinks=true,
linkcolor=black,
citecolor=black,
urlcolor=blue}
% \urlstyle{same}
\usepackage[top=2.5cm,bottom=2.5cm,right=2.5cm,left=2.5cm]{geometry}
\usepackage{changepage}
\usepackage{tabularx}
\newcolumntype{L}{>{\raggedright\arraybackslash}X}
\usepackage{longtable}
\usepackage{xltabular}
\renewcommand{\tablename}{Tableau}
\renewcommand{\figurename}{Figure}
%pour les références bibliographiques
\usepackage[citestyle=numeric,bibstyle=numeric,doi=false,isbn=false,eprint=false,maxcitenames=1,uniquelist=false,backend=biber]{biblatex}
\addbibresource{references.bib}
\AtEveryBibitem{
\ifentrytype{misc}{
}{
\clearfield{url}
\clearfield{urlyear}
}
}
%% pour la numération des sous sou sections
\setcounter{tocdepth}{2}
\setcounter{secnumdepth}{2}
% pour les algorithmes
\usepackage[ruled,vlined,linesnumbered]{algorithm2e}
\DontPrintSemicolon
\setlength\arrayrulewidth{1pt}
\renewcommand{\baselinestretch}{1.05}
\usepackage{fancyhdr}
\pagestyle{fancy}
\fancyhf{}
\lhead{\bfseries\nouppercase{\leftmark}}
\rfoot{\bfseries\thepage}
\setlength{\headheight}{14.5pt}
\let\headruleORIG\headrule
\renewcommand{\headrule}{\color{black} \headruleORIG}
\renewcommand{\headrulewidth}{1.0pt}
\usepackage{colortbl}
\arrayrulecolor{black}
\fancypagestyle{plain}{
\fancyhead{}
\fancyfoot[R]{\bfseries\thepage}
\renewcommand{\headrulewidth}{0pt}
}
\makeatletter
\def\@textbottom{\vskip \z@ \@plus 1pt}
\let\@texttop\relax
\makeatother
\makeatletter
\def\cleardoublepage{\clearpage\if@twoside \ifodd\c@page\else%
\hbox{}%
\thispagestyle{empty}%
\newpage%
\if@twocolumn\hbox{}\newpage\fi\fi\fi}
\makeatother
\usepackage{amsthm}
\usepackage{amssymb,amsmath,bbm}
\usepackage{array}
\usepackage{bm}
\usepackage{multirow}
\usepackage[footnote]{acronym}
\usepackage[bottom]{footmisc}
\newtheoremstyle{break}
{11pt}{11pt}%
{\itshape}{}%
{\bfseries}{}%
{\newline}{}%
\theoremstyle{break}
%\theoremstyle{definition}
\newtheorem{definition}{Définition}[chapter]
%\theoremstyle{definition}
\newtheorem{theoreme}{Théorème}[chapter]
%\theoremstyle{remark}
\newtheorem{remarque}{Remarque}[chapter]
%\theoremstyle{plain}
\newtheorem{propriete}{Propriété}[chapter]
\newtheorem{exemple}{Exemple}[chapter]
%table break line
\usepackage{tikz}
\usepackage{xcolor}
\usepackage{makecell}
\renewcommand\theadalign{bl}
\renewcommand\theadfont{\bfseries}
\renewcommand\cellalign{bl}
\renewcommand\cellgape{\Gape[2pt]}
\parskip=5pt
%\sloppy
%%%%********************************************************************
\usepackage{xcolor}
\definecolor{quotemark}{gray}{0.7}
\makeatletter
\def\fquote{%
\@ifnextchar[{\fquote@i}{\fquote@i[]}%]
}%
\def\fquote@i[#1]{%
\def\tempa{#1}%
\@ifnextchar[{\fquote@ii}{\fquote@ii[]}%]
}%
\def\fquote@ii[#1]{%
\def\tempb{#1}%
\@ifnextchar[{\fquote@iii}{\fquote@iii[]}%]
}%
\def\fquote@iii[#1]{%
\def\tempc{#1}%
\vspace{1em}%
\noindent%
\begin{list}{}{%
\setlength{\leftmargin}{0.1\textwidth}%
\setlength{\rightmargin}{0.1\textwidth}%
}%
\item[]%
\begin{picture}(0,0)%
\put(-15,-5){\makebox(0,0){\scalebox{3}{\textcolor{quotemark}{``}}}}%
\end{picture}%
\begingroup\itshape}%
%%%%********************************************************************
\def\endfquote{%
\endgroup\par%
\makebox[0pt][l]{%
\hspace{0.8\textwidth}%
\begin{picture}(0,0)(0,0)%
\put(15,15){\makebox(0,0){%
\scalebox{3}{\color{quotemark}''}}}%
\end{picture}}%
\ifx\tempa\empty%
\else%
\ifx\tempc\empty%
\hfill\rule{100pt}{0.5pt}\\\mbox{}\hfill\tempa,\ \emph{\tempb}%
\else%
\hfill\rule{100pt}{0.5pt}\\\mbox{}\hfill\tempa,\ \emph{\tempb},\ \tempc%
\fi\fi\par%
\vspace{0.5em}%
\end{list}%
}%
\makeatother
%%%%********************************************************************
\usepackage{afterpage}
\newcommand\blankpage{%
\null
\thispagestyle{empty}%
\addtocounter{page}{-1}%
\newpage}
\renewcommand{\listalgorithmcfname}{List of listings}
\setmainlanguage{english}
\setotherlanguage{arabic}
\newfontfamily\arabicfont[Script=Arabic,Scale=1.3]{Scheherazade}
\newcommand{\mychapter}[2]{
\chapter*{#2}
\addcontentsline{toc}{chapter}{#2}
}
\usepackage[page,toc,titletoc,title]{appendix}
\addto\captionsfrench{%
\renewcommand\appendixname{Annexe}
\renewcommand\appendixpagename{Annexes}
\renewcommand{\appendixtocname}{Annexes}
}
\usepackage{etoolbox}
\appto\appendix{\addtocontents{toc}{\protect\setcounter{tocdepth}{0}}}
% reinstate the correct level for list of tables and figures and algorithms
\appto\listoffigures{\addtocontents{lof}{\protect\setcounter{tocdepth}{1}}}
\appto\listoftables{\addtocontents{lot}{\protect\setcounter{tocdepth}{1}}}
\appto\lstlistoflistings{\addtocontents{lot}{\protect\setcounter{tocdepth}{1}}}
\begin{document}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% definitions the style of the code %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\definecolor{codegreen}{rgb}{0,0.6,0}
\definecolor{codegray}{rgb}{0.52,0.26,0.76}
\definecolor{codepurple}{rgb}{0.87,0.23,0.29}
\definecolor{backcolour}{rgb}{0.96,0.97,0.98}
\lstdefinestyle{mystyle}{
backgroundcolor=\color{backcolour},
commentstyle=\color{codegreen},
keywordstyle=\color{codepurple},
numberstyle=\tiny\color{codegray},
stringstyle=\color{codepurple},
basicstyle=\ttfamily\footnotesize,
breakatwhitespace=false,
breaklines=true,
captionpos=b,
keepspaces=true,
numbers=left,
numbersep=5pt,
showspaces=false,
showstringspaces=false,
showtabs=false,
tabsize=2
}
\lstset{style=mystyle}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% end style definitions the code %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%\includepdf[pages=-]{00-Page-de-garde.pdf}
\pagenumbering{Roman}
\include{FrontMatter/00-Page}
%\include{FrontMatter/00-Note}
\include{FrontMatter/01-Dedicace}
\include{FrontMatter/02-Remerciements}
\include{FrontMatter/03-Resume}
\clearpage
\renewcommand{\cftpartleader}
{\cftdotfill{\cftdotsep}}
\renewcommand{\cftchapleader}{\cftdotfill{\cftdotsep}}
\tableofcontents
\clearpage
\listoffigures
\clearpage
\listoftables
\clearpage
\lstlistoflistings
\clearpage
\include{FrontMatter/04-Acronymes}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% Content of the report and references %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\cleardoublepage
%%اي فصل جديد تضيفه تقوم بتعريفه هنا
\pagenumbering{arabic}
\include{Chapters/Introduction}
\include{Chapters/ChpaterNumberX}
%%\include{Chapters/Ch1}
%%\include{Chapters/Ch2}
%%\include{Chapters/Ch3}
%%\include{Chapters/Ch4}
\include{11-Conclusion}
%choix du style de la biblio
\printbibliography[nottype=misc,title={Bibliography}]
\printbibliography[type=misc,title={Webography}]
\appendix
\appendixpage
\input{12-Annexe.tex}
\clearpage
\thispagestyle{empty}
\end{document}
%code