2

I have a problem with \listoffigures and \listoftables; they do not follow the chapter style. Below a test document and the class style used in writing my thesis. I don't know where is the problem. thank you in advance.

\documentclass[sommairechap,styleben]{these_gi}
\usepackage{titlesec,microtype}
\titleformat{\chapter}[display]
{\normalfont\normalsize\scshape}
{\makebox[\textwidth]{\titlerule[0.8ex]\quad\textls{\chaptername}\    \thechapter\quad\titlerule[0.8ex]}}
{1ex}
{\titlerule\vspace{1ex}\centering\huge\textls[50]}
[\titlerule]
\titleformat{name=\chapter,numberless}[display]
{\normalfont\normalsize\scshape}
{\makebox[\textwidth]{\titlerule[0.8ex]}}
{1ex}
{\titlerule\vspace{1ex}\centering\huge\textls[50]}
[\titlerule]
\begin{document}
\chapter*{Tables des mati\`{e}res}
\clearpage
\listoffigures
\clearpage
\listoftables
\chapter{Premier chapitre}
\end{document} 

The class style used is:

\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{stylejchiquet}
\newif\if@sommairechap \@sommairechapfalse
\DeclareOption{sommairechap}{\@sommairechaptrue}
\ProcessOptions
% =======================================================================
% PACKAGES ADDITIONNELS
 % Police MathPazo
\RequirePackage[osf,sc]{mathpazo}
\RequirePackage[scaled=.95]{helvet}
\RequirePackage{courier}
% EntÍtes amÈliorÈs
\RequirePackage{fancyhdr}
% Enumerations personnalisÈe
\RequirePackage{enumerate}
 % Calcul des tailles d'environnement
\RequirePackage{calc}
\RequirePackage{amsmath,amsfonts,amssymb,amsthm}
\RequirePackage{dsfont,mathrsfs}
 % Lettrine
\RequirePackage{lettrine}
% Ajout d'entrÈes dans la table des matiËres
\RequirePackage{tocbibind}
\RequirePackage{caption}
\DeclareCaptionLabelSeparator{mysep}{~--~}
\captionsetup{singlelinecheck=no,labelsep=mysep,font=small,textfont=it}
\setlength{\abovecaptionskip}{5pt}
\setlength{\belowcaptionskip}{-5pt}
\RequirePackage{supertabular}
\RequirePackage{natbib}
\bibliographystyle{plainnatfrench}
\bibpunct{(}{)}{,}{a}{}{;}
% Gestion des rÈfÈrence selon le format de sortie
\RequirePackage{ifpdf}
\ifpdf
% configuration de graphicx et hyperref pour sortie PDF
\RequirePackage[pdftex]{graphicx}
\RequirePackage[pdftex,bookmarksopen=false,pdfauthor=Julien  Chiquet,colorlinks=false,pagebackref,plainpages=false]{hyperref}
\DeclareGraphicsExtensions{.pdf,.png,.jpg}
\else
% configuration de graphicx et hyperref pour sortie PS
\RequirePackage[dvips]{graphicx}
\DeclareGraphicsExtensions{.eps,.ps}
\RequirePackage[dvips,bookmarksopen=false,pdfauthor=Julien Chiquet,colorlinks=false,pagebackref,plainpages=false]{hyperref}
\fi
% Gestion Èventuel des sommaires en dÈbut de chapitre
\if@sommairechap
 \RequirePackage[french]{minitoc}
 \dominitoc
 \setlength{\mtcindent}{0em}
 \renewcommand{\mtifont}{\large\rm\scshape}
 \renewcommand{\mtcSfont}{\small\rm\scshape}
 \fi
 \RequirePackage{tocloft}
 \renewcommand{\cftsubsecfont}{\small}
 \renewcommand{\cftsecfont}{\normalsize\scshape}
 \renewcommand{\cftchapfont}{\large\scshape}
\renewcommand{\cfttoctitlefont}{\Huge\scshape}
\renewcommand{\cftloftitlefont}{\Huge\scshape}
\renewcommand{\cftloftitlefont}{\Huge\scshape}
\renewcommand{\cftlottitlefont}{\Huge\scshape}
\tolerance = 1414
 \hbadness = 1414
 \emergencystretch 1em
 \hfuzz 0.3pt
 \widowpenalty=10000
 \vfuzz \hfuzz
 \raggedbottom
 % =============================================
 % PAGE DE GARDE
 \newif\ifdefinitif\definitiftrue
 \def\titleFR#1{\gdef\@titleFR{#1}}
 \def\titleEN#1{\gdef\@titleEN{#1}}
 \def\abstractFR#1{\gdef\@abstractFR{#1}}
 \def\abstractEN#1{\gdef\@abstractEN{#1}}
 \def\keywordsFR#1{\gdef\@keywordsFR{#1}}
 \def\keywordsEN#1{\gdef\@keywordsEN{#1}}
 \def\@author{}
 \def\address#1{\gdef\@address{#1}}
 \def\universite#1{\gdef\@universite{#1}}
 \def\laboratoire#1{\gdef\@laboratoire{#1}}
 \def\filiere#1{\gdef\@filiere{#1}}
 \def\domaine#1{\gdef\@domaine{#1}}
 \def\specialite#1{\gdef\@specialite{#1}}
 \def\datesoumission#1{\gdef\@datesoumission{#1}}
 \def\datesoutenance#1{\gdef\@datesoutenance{#1}}
  \def\jury#1{\gdef\@jury{#1}}
  \def\dedicate#1{\gdef\dedication@text{#1}}
  \renewcommand{\titlepage}{%
 \ifdefinitif
  % \normalsize{N? d'ordre : $40138$}
   \begin{center}
   \textbf{\small{\@universite}} \\ \bigskip \bigskip
   \textbf{\Huge\textsc{THÈSE}} \\ \bigskip
   \textbf{\LARGE{EN VUE DE L'OBTENTION DU DIPLÔME DE }}\\ \bigskip
   \textbf{\LARGE{DOCTORAT}} \\ \bigskip
   \textbf{Domaine :} \textbf{\@domaine}~~~~ \textbf{Filière :}     \textbf{\@filiere} \\
       \textbf{Spècialitè :} \textbf{\@specialite} \\ \bigskip
    \textbf{\Large{Présentée par}} \\
    \@author \\ \bigskip
    \textbf{\emph{\Large{Thème}}}
  \HRule \\[0.1cm]
 { \huge \bfseries {\@titleFR}\\[0.1cm] }
 \HRule \\[0.5cm]
 \normalsize
\setlength{\parindent}{-8.9em}{ \textbf{\large Soutenue publiquement le   \@datesoutenance{} devant le jury composé de :}}\\
 \vspace{0.8cm}
 \setlength{\parindent}{-2.3em}
  \@jury \vfill
  \vspace{2cm}
 \textbf{\large Année Universitaire : 2016/2017}
\end{center}
\clearpage
\else
 % --------------------------------------------------
   % NON DEFINITIF : PAGE DE SOUMISSION AUX RAPPORTEURS
   \thispagestyle{empty}
   \vskip3cm
   \vfill
   \begin{center}
   \large
    Rapport soumis aux rapporteurs, dans le but de sanctionner
   le dossier pour l'obtention du grade de \\
   Docteur en \@specialite\\
   de \\
   l'\@universite
  \end{center}
  \vskip3cm
  \begin{center}
  \huge {\sc \@titleFR }\\ \vskip2cm
  \large \@author, le \@submitdate \\
  \end{center}
   \vskip3cm
   \vskip3cm
   \vfill
   \textsc{Mots-clés :} \@keywordsFR
   \fi
   }
 % ===========================================================
  % PAGE DE DEDICACE
  \newcommand{\dedicacepage}{%
  \begin{flushright}
   \large\em\null\vskip1in\dedication@text\vfill
   \end{flushright}
  }
  \newcommand{\abstractpage}{%
  \pagestyle{empty}
   ~\newpage
   \par
   \footnotesize
   \textbf{Résumé : }
  }
 % ===================================================================
 % COLOPHON
 \newcommand{\colophon}[1]{
   ~\vfill
  \begin{center}
  \small #1
  \end{center}
 }
% =====================================================================
% MISE EN PAGE
\RequirePackage{geometry}
  \geometry{textheight=142ex,textwidth=40em,top=85pt,headheight=30pt,headsep=30pt,right=2cm,left = 2.91cm}
\addtolength{\marginparwidth}{-80pt}
\addtolength{\headwidth}{\marginparsep}
 % =====================================================================
 % ENT TES
 % EntÍtes standards

 \fancypagestyle{plain}{
 \fancyhf{}
 \fancyfoot[RO,LE]{\thepage}
 \renewcommand{\headrulewidth}{0pt}
 \renewcommand{\footrulewidth}{0pt}
 }
\fancypagestyle{main}{
\fancyhf{}
\fancyhead[LO]{\nouppercase{\rightmark}}
\fancyhead[RO,LE]{\thepage}
 \fancyhead[RE]{\nouppercase{\leftmark}}
 \renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0pt}
}
 % ============================================================
 % PR?FACE
 \newcommand{\beforepreface}{
 \frontmatter
 \pagestyle{empty}
 \titlepage
 \pagestyle{plain}
 }
 % ==============================================================
 % CONTENU MA?TRE
 \newcommand{\afterpreface}{
  \mainmatter
  \pagestyle{main}
  }
  % =====================================================================
  % PAGE DE GARDE DES CHAPITRES
  % Le rÈsumÈ + le minitoc Èventuel
  \newenvironment{chapintro}{%
  \if@sommairechap \nomtcrule \vspace{1.5cm} \minitoc[l] \fi}{%
  }
  % ==============================================================
  % ANNEXE, BIBLIOGRAPHIE
 \RequirePackage[hyperpageref]{backref}
  \backreffrench
 \renewcommand*{\backref}[1]{}  % Disable standard
 \renewcommand*{\backrefalt}[4]{% Detailed backref
  \ifcase #1 %
  \relax%(Not cited.)%
   \fi}
  % ---------------------------------------------------------------
 % LETTRINE
\newcommand{\malettrine}[1]{
 \lettrine[lines=2,lhang=0.33,loversize=0.33]{#1}
}

\addto{\captionsfrench}{
\renewcommand*{\listfigurename}{Liste des figures}
% \renewcommand*{\appendixname}{}%
}

the class these_gi:

\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{these_gi}[2005/09/21 Classe pour ma]
 %% Les differents styles
 \newif\if@styleben \@stylebenfalse

 %% Chargement de la classe book, avec transfert d'options
 \PassOptionsToClass{a4paper}{book}
 \PassOptionsToClass{11pt}{book}
 \PassOptionsToClass{oneside}{book}
 \DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}}
 \DeclareOption{styleben}{\@stylebentrue}
 \DeclareOption*{}
 \ProcessOptions
 \LoadClass{book}

 %--------------------PACKAGES STANDARD REQUIS-------------------%

 % FONTS ET CARACTERES
 %\RequirePackage[utf8]{inputenc}
 \RequirePackage[T1]{fontenc}
 %\RequirePackage[latin1]{inputenc}
  %\usepackage[free]{ARfonts}
 \RequirePackage[frenchb]{babel}

 \frenchspacing
 \RequirePackage{eurosym}
 \RequirePackage{xcolor}
\RequirePackage[toc,page]{appendix}

\RequirePackage{exscale,relsize}
\RequirePackage{stmaryrd}

 % MODIF des compteurs.
 \RequirePackage{remreset}
 %\makeatletter \@addtoreset{chapter}{part} \makeatother

 %--------------------CHARGEMENT DE LA FEUILLE DE STYLE     CHOISIE-------------------%
 \if@styleben
 \RequirePackage{styleben}
\fi
  • 1
    The comments at the begin of a file are not just little quirks of the author or meant to be funny, they tell what the file is and who the author of the file is. Please add those comments along with the license of the files. Check if you are even allowed to distribute the files. – Johannes_B Dec 4 '16 at 10:28
  • I get an error message, about LaTeX not being able to find the file styleben.sty. If I remove the option styleben from the \documentclass instruction, the document compiles fine and the same style is applied to the Table of Contents (Tables des matières) [observe the plural form in "Tables"], the List of Figures (Table des figures), and the List of Tables (Liste des tableaux). – Mico Dec 4 '16 at 11:32
1

Don't use the option styleben (and likewise sommairechap). Its purpose is to make these_gi.cls load styleben.sty (which happens to be the file that you provide but which claims that it \ProvidesPackage{stylejchiquet}).

You definitely don't want to load this style file.

  • It is responsible for messing up the chapter headings, the reason of your complaint.
  • You don't want to have the name "Julien Chiquet" as the PDF author of your thesis (which this package does), unless your name is Julien Chiquet.
  • This style file loads several style files that are incompatible with the thesis class. Loading and using fancyhdr and tocloft alongside with titlesec is asking for trouble. Also the minitoc package complains about interferences by other packages.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.