Message d'erreur lors de la compilation

Tout ce qui concerne le langage TeX/LaTeX et ses variantes. Ce langage est utilisable sur le forum via les balises tex.
[participation réservée aux utilisateurs inscrits]
Règles du forum
Merci de soigner la rédaction de vos messages et de consulter ce sujet avant de poster. Pensez également à utiliser la fonction recherche du forum.
dhahri

Message d'erreur lors de la compilation

Message non lu par dhahri »

Bonjour,
je suis en train de rédiger un fichier tex. lors de la compilation un message d'erreur s'affiche.
voila le fichier tex.

Code : Tout sélectionner

\documentclass[a4paper]{report}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\usepackage[french]{babel}
\usepackage{minitoc}
\usepackage{t1enc}
\usepackage[latin1]{inputenc}
\usepackage[draft,pages=1-300,color=black!10,mark=Moumni,angle=55,scale=0.8,xcoord=20,ycoord=10]{draftmark}
\usepackage{palatino,euler}
\usepackage{times}
\usepackage{fancyhdr,amsmath,amsthm,amssymb,fancybox}
\usepackage{frenchle}
\usepackage{minitoc}
\usepackage{graphicx}
\usepackage[dvips]{epsfig}
\usepackage{color,a4wide}
\input{tcilatex}
\usepackage{amsfonts}
\usepackage{tikz}
\usepackage{kpfonts}
\usepackage{pgf}
\usepackage{lipsum}
\usepackage[right=3cm,left=3cm,top=3cm,bottom=4cm]{geometry}
\usepackage[explicit]{titlesec}
\definecolor{vert}{rgb}{0.556863,0.6,0.611765}
\definecolor{bleu}{RGB}{61,83,164}
\definecolor{vert2}{RGB}{60,179,113}
\newcommand*\chapterlabel{}
\newcommand{\ifempty}[3]{\ifx#1\empty#2\else#3\fi}
\titleformat{\chapter}
{\gdef\chapterlabel{}
\normalfont\sffamily\Huge\bfseries\scshape}
{\gdef\chapterlabel{\thechapter\ }}{0pt}
{\begin{tikzpicture}[remember picture,overlay]
\node[yshift=-8cm,xshift=3cm] at (current page.north west)
{\begin{tikzpicture}[remember picture, overlay]
\fill[vert2] (0,0.5) rectangle (1.3cm,5cm);
\draw[color=vert2] (1.5cm,4.7cm) -- (15cm,4.7cm);
\node[anchor=west,yshift=4.77cm,xshift=14.7cm]{
\begin{pgfpicture}
\pgfpathmoveto{\pgfqpoint{0.016cm}{0.027cm}}
\pgfpathlineto{\pgfqpoint{1.123cm}{0.027cm}}
\pgfpathlineto{\pgfqpoint{1.123cm}{0.812cm}}
\pgfpathlineto{\pgfqpoint{0.016cm}{0.812cm}}
\pgfpathclose
\pgfusepath{clip}
\begin{pgfscope}
\begin{pgfscope}
\pgfpathmoveto{\pgfqpoint{0cm}{0cm}}
\pgfpathlineto{\pgfqpoint{88.944cm}{0cm}}
\pgfpathlineto{\pgfqpoint{88.944cm}{88.944cm}}
\pgfpathlineto{\pgfqpoint{0cm}{88.944cm}}
\pgfpathclose
\pgfusepath{clip}
\pgfsetstrokecolor{vert2}\pgfsetfillcolor{vert2}
\pgfpathmoveto{\pgfqpoint{0.024cm}{0.365cm}}
\pgfpathlineto{\pgfqpoint{0.018cm}{0.336cm}}
\pgfpathcurveto{\pgfqpoint{0.035cm}{0.338cm}}{\pgfqpoint{0.058cm}{0.336cm}}{\pgfqpoint{0.071cm}{0.334cm}}
\pgfpathcurveto{\pgfqpoint{0.117cm}{0.326cm}}{\pgfqpoint{0.165cm}{0.311cm}}{\pgfqpoint{0.249cm}{0.267cm}}
\pgfpathcurveto{\pgfqpoint{0.281cm}{0.25cm}}{\pgfqpoint{0.352cm}{0.192cm}}{\pgfqpoint{0.424cm}{0.131cm}}
\pgfpathcurveto{\pgfqpoint{0.491cm}{0.075cm}}{\pgfqpoint{0.543cm}{0.028cm}}{\pgfqpoint{0.565cm}{0.029cm}}
\pgfpathcurveto{\pgfqpoint{0.592cm}{0.029cm}}{\pgfqpoint{0.601cm}{0.048cm}}{\pgfqpoint{0.606cm}{0.053cm}}
\pgfpathcurveto{\pgfqpoint{0.616cm}{0.063cm}}{\pgfqpoint{0.618cm}{0.104cm}}{\pgfqpoint{0.628cm}{0.115cm}}
\pgfpathcurveto{\pgfqpoint{0.648cm}{0.135cm}}{\pgfqpoint{0.671cm}{0.138cm}}{\pgfqpoint{0.686cm}{0.137cm}}
\pgfpathcurveto{\pgfqpoint{0.732cm}{0.133cm}}{\pgfqpoint{0.756cm}{0.112cm}}{\pgfqpoint{0.8cm}{0.099cm}}
\pgfpathcurveto{\pgfqpoint{0.839cm}{0.088cm}}{\pgfqpoint{0.866cm}{0.091cm}}{\pgfqpoint{0.899cm}{0.101cm}}
\pgfpathcurveto{\pgfqpoint{0.93cm}{0.11cm}}{\pgfqpoint{0.958cm}{0.12cm}}{\pgfqpoint{0.979cm}{0.146cm}}
\pgfpathcurveto{\pgfqpoint{1.006cm}{0.179cm}}{\pgfqpoint{0.998cm}{0.205cm}}{\pgfqpoint{1.011cm}{0.228cm}}
\pgfpathcurveto{\pgfqpoint{1.024cm}{0.252cm}}{\pgfqpoint{1.047cm}{0.276cm}}{\pgfqpoint{1.062cm}{0.299cm}}
\pgfpathcurveto{\pgfqpoint{1.079cm}{0.323cm}}{\pgfqpoint{1.108cm}{0.356cm}}{\pgfqpoint{1.121cm}{0.432cm}}
\pgfpathcurveto{\pgfqpoint{1.092cm}{0.378cm}}{\pgfqpoint{1.044cm}{0.346cm}}{\pgfqpoint{1.025cm}{0.332cm}}
\pgfpathcurveto{\pgfqpoint{0.98cm}{0.301cm}}{\pgfqpoint{0.907cm}{0.269cm}}{\pgfqpoint{0.87cm}{0.263cm}}
\pgfpathcurveto{\pgfqpoint{0.769cm}{0.247cm}}{\pgfqpoint{0.745cm}{0.247cm}}{\pgfqpoint{0.611cm}{0.248cm}}
\pgfpathcurveto{\pgfqpoint{0.488cm}{0.249cm}}{\pgfqpoint{0.409cm}{0.258cm}}{\pgfqpoint{0.379cm}{0.26cm}}
\pgfpathcurveto{\pgfqpoint{0.41cm}{0.262cm}}{\pgfqpoint{0.536cm}{0.258cm}}{\pgfqpoint{0.671cm}{0.272cm}}
\pgfpathcurveto{\pgfqpoint{0.805cm}{0.286cm}}{\pgfqpoint{0.864cm}{0.299cm}}{\pgfqpoint{0.917cm}{0.32cm}}
\pgfpathcurveto{\pgfqpoint{0.946cm}{0.331cm}}{\pgfqpoint{1.007cm}{0.362cm}}{\pgfqpoint{1.063cm}{0.424cm}}
\pgfpathcurveto{\pgfqpoint{1.082cm}{0.446cm}}{\pgfqpoint{1.102cm}{0.478cm}}{\pgfqpoint{1.114cm}{0.509cm}}
\pgfpathcurveto{\pgfqpoint{1.11cm}{0.565cm}}{\pgfqpoint{1.077cm}{0.641cm}}{\pgfqpoint{1.04cm}{0.686cm}}
\pgfpathcurveto{\pgfqpoint{0.999cm}{0.735cm}}{\pgfqpoint{0.949cm}{0.767cm}}{\pgfqpoint{0.901cm}{0.785cm}}
\pgfpathcurveto{\pgfqpoint{0.867cm}{0.798cm}}{\pgfqpoint{0.807cm}{0.811cm}}{\pgfqpoint{0.78cm}{0.81cm}}
\pgfpathcurveto{\pgfqpoint{0.797cm}{0.795cm}}{\pgfqpoint{0.84cm}{0.762cm}}{\pgfqpoint{0.894cm}{0.702cm}}
\pgfpathcurveto{\pgfqpoint{0.93cm}{0.661cm}}{\pgfqpoint{0.955cm}{0.625cm}}{\pgfqpoint{0.968cm}{0.572cm}}
\pgfpathcurveto{\pgfqpoint{0.984cm}{0.506cm}}{\pgfqpoint{0.957cm}{0.465cm}}{\pgfqpoint{0.942cm}{0.45cm}}
\pgfpathcurveto{\pgfqpoint{0.92cm}{0.429cm}}{\pgfqpoint{0.891cm}{0.421cm}}{\pgfqpoint{0.886cm}{0.426cm}}
\pgfpathcurveto{\pgfqpoint{0.876cm}{0.437cm}}{\pgfqpoint{0.881cm}{0.452cm}}{\pgfqpoint{0.88cm}{0.468cm}}
\pgfpathcurveto{\pgfqpoint{0.878cm}{0.502cm}}{\pgfqpoint{0.869cm}{0.51cm}}{\pgfqpoint{0.822cm}{0.493cm}}
\pgfpathcurveto{\pgfqpoint{0.781cm}{0.478cm}}{\pgfqpoint{0.754cm}{0.448cm}}{\pgfqpoint{0.727cm}{0.423cm}}
\pgfpathcurveto{\pgfqpoint{0.707cm}{0.404cm}}{\pgfqpoint{0.692cm}{0.389cm}}{\pgfqpoint{0.672cm}{0.378cm}}
\pgfpathcurveto{\pgfqpoint{0.655cm}{0.367cm}}{\pgfqpoint{0.621cm}{0.362cm}}{\pgfqpoint{0.616cm}{0.372cm}}
\pgfpathcurveto{\pgfqpoint{0.61cm}{0.384cm}}{\pgfqpoint{0.624cm}{0.391cm}}{\pgfqpoint{0.641cm}{0.426cm}}
\pgfpathcurveto{\pgfqpoint{0.654cm}{0.452cm}}{\pgfqpoint{0.637cm}{0.469cm}}{\pgfqpoint{0.607cm}{0.481cm}}
\pgfpathcurveto{\pgfqpoint{0.568cm}{0.496cm}}{\pgfqpoint{0.516cm}{0.482cm}}{\pgfqpoint{0.46cm}{0.447cm}}
\pgfpathcurveto{\pgfqpoint{0.401cm}{0.41cm}}{\pgfqpoint{0.388cm}{0.395cm}}{\pgfqpoint{0.346cm}{0.362cm}}
\pgfpathcurveto{\pgfqpoint{0.305cm}{0.331cm}}{\pgfqpoint{0.294cm}{0.322cm}}{\pgfqpoint{0.277cm}{0.319cm}}
\pgfpathcurveto{\pgfqpoint{0.253cm}{0.315cm}}{\pgfqpoint{0.199cm}{0.32cm}}{\pgfqpoint{0.161cm}{0.328cm}}
\pgfpathcurveto{\pgfqpoint{0.098cm}{0.343cm}}{\pgfqpoint{0.064cm}{0.352cm}}{\pgfqpoint{0.024cm}{0.365cm}}
\pgfusepath{fill}
\end{pgfscope}
\end{pgfscope}
\end{pgfpicture}};
\node[anchor=north,yshift=5.8cm,xshift=0.645cm]{\color{vert2}{{\ifempty{\chapterlabel}{}{\normalsize \sc Chapitre}}}};
\node[anchor=north,yshift=5cm,xshift=0.65cm]{\color{white}\chapterlabel};
\node[anchor=north west,yshift=4.5cm,xshift=2cm]{\begin{minipage}[t]{10cm}\vspace{0pt}\raggedright\color{bleu}#1\vfill\end{minipage}};
\end{tikzpicture}};\end{tikzpicture}}
\titlespacing*{\chapter}{0pt}{50pt}{70pt}
\begin{document}
\dominitoc
\tableofcontents
\chapter{Introduction}
\lipsum[1-2]
\chapter{Long chapitre long chapitre long chapitre}
\section{Section}
\lipsum[1-2]
\begin{thebibliography}{99}
\bibitem{Test} test reference
\end{thebibliography}
\end{document}
Message d'erreur.

Code : Tout sélectionner

This is pdfTeX, Version 3.14159265-2.6-1.40.18 (MiKTeX 2.9.6300 64-bit)
[...]
! LaTeX Error: Command \ifempty already defined.
               Or name \end... illegal, see p.192 of the manual.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.60 ...and{\ifempty}[3]{\ifx#1\empty#2\else#3\fi}

?
Merci bien de me signaler l'erreur.
Bien cordialement
Dernière modification par MB le mercredi 13 mai 2020, 22:53, modifié 1 fois.
MB
Administrateur
Administrateur
Messages : 8058
Inscription : samedi 28 mai 2005, 14:23
Statut actuel : Enseignant
Contact :

Re: Message d'erreur lors de la compilation

Message non lu par MB »

Le message indique que la commande \ifempty est déjà définie.

Code : Tout sélectionner

\newcommand{\ifempty}[3]{\ifx#1\empty#2\else#3\fi}
La ligne suivante provoque donc une erreur et pourrait être remplacée par la ligne suivante (ou supprimée si jamais elle s'avérait inutile).

Code : Tout sélectionner

\renewcommand{\ifempty}[3]{\ifx#1\empty#2\else#3\fi}
MB. (rejoignez pCloud et bénéficiez de 10Go de stockage en ligne gratuits)
Pas d'aide en message privé. Merci de consulter ce sujet avant de poster votre premier message.
dhahri

Re: Message d'erreur lors de la compilation

Message non lu par dhahri »

Merci bien pour votre réponse. J'ai remplacé comme vous l'avez suggéré la commande initiale par celle que vous avez proposé

Code : Tout sélectionner

\renewcommand{\ifempty}[3]{\ifx#1\empty#2\else#3\fi}
mais un autre message d'erreur s'affiche

Code : Tout sélectionner

-26- Erreur d\'etect\'ee dans frenchle.sty !(voir p.ex. le fichier language.dat
)

 frenchle.sty : -71- ATTENTION : si babel est utilis\'e, mettre frenchle en opt
ion (\`a la ligne 13).
-26- Erreur d\'etect\'ee dans frenchle.sty !(voir p.ex. le fichier language.dat
)
! Extra \else.
<recently read> \else

l.13 \select@language{french}

?
j'ai essayé de chercher frenchle.sty pour l'insérer dans le même dossier ou se trouve mon fichier tex mais je ne l'ai pas trouvé.
Comment modifier ma préambule de départ pour que de tel message d'erreurs ne s'affichent plus lors de la compilation?
merci bien d'avance
MB
Administrateur
Administrateur
Messages : 8058
Inscription : samedi 28 mai 2005, 14:23
Statut actuel : Enseignant
Contact :

Re: Message d'erreur lors de la compilation

Message non lu par MB »

Je pense qu'il va falloir revoir le préambule de ton fichier car il me semble très mal construit. Certains paquets sont chargés deux fois par exemple.

Pour le paquet frenchle, le message est clair puisque tu utilises babel, il faut mettre frenchle en option de babel et ne pas le charger directement avec un usepackage.

Mais une fois de plus, tu dois revoir ton préambule et supprimer tout ce qui n'est pas indispensable.
MB. (rejoignez pCloud et bénéficiez de 10Go de stockage en ligne gratuits)
Pas d'aide en message privé. Merci de consulter ce sujet avant de poster votre premier message.
Répondre
  • Sujets similaires
    Réponses
    Vues
    Dernier message