Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
composition:texte:renvois:les_references_croisees_sont_fausses [2018/06/03 13:16] joseph.wrightcomposition:texte:renvois:les_references_croisees_sont_fausses [2021/01/11 22:25] (Version actuelle) – Traduction de l'article anglais. yannick.tanguy
Ligne 1: Ligne 1:
---- +====== Pourquoi ma référence croisée n'est pas correcte? ======
-title: LaTeX gets cross-references wrong +
-category: errors +
-permalink: /FAQ-crossref +
----+
  
-Sometimeshowever many times you run LaTeX, the cross-references +Parfoismalgré de multiples exécutions de <latex>\LaTeX</latex>les références croisées restent tout simplement faussesIl est ici probable que vous avez placé l'étiquette avant que les données de l'étiquette ne soient définies. Ainsi, si l'étiquette enregistre la référence d'une commande ''\caption''la commande ''\label'' doit apparaître //après// la commande ''\caption''ou en faire partieVoici ici deux exemples corrects 
-are just wrong A likely reason is that you have placed the label + 
-before the data for the label was set; if the label is recording a +<code latex>
-`\caption` commandthe `\label` command must appear +
-_after_ the `\caption` commandor be part of itFor example+
-```latex+
 \begin{figure} \begin{figure}
-  <the illustration itself> +  ... la figure ... 
-  \caption{My figure} +  \caption{Ma figure} 
-  \label{myfig}+  \label{mafig}
 \end{figure} \end{figure}
-``` +</code
-is correct, as is + 
-<!-- {% raw %} --+<code latex>
-```latex+
 \begin{figure} \begin{figure}
-  <the illustration itself> +  ... la figure ... 
-  \caption{My figure+  \caption{Ma figure \label{mafig}}
-    \label{myfig}}+
 \end{figure} \end{figure}
-``` +</code
-<!-- {% endraw %} --+ 
-whereasin +Par contrel'exemple suivant ne fonctionnera pas bien et l'étiquette indiquera le numéro de la section (ou autre) :  
-```latex+ 
 +<code latex>
 \begin{figure} \begin{figure}
-  <the illustration itself> +  ... la figure ... 
-  \label{myfig+  \label{mafig
-  \caption{My figure}+  \caption{Ma figure}
 \end{figure} \end{figure}
-``` +</code>
-the label will report the number of the section (or whatever) in which +
-the surrounding text resides, or the like.+
  
-You canwith the same malign effectshield the `\caption` command +Vous pouvezavec les mêmes conséquences fâcheusesprotéger la commande ''\caption'' de sa commande ''\label'' associéeen enfermant la légende dans un environnement qui lui est propreEn voici une illustration 
-from its associated `\label` commandby enclosing the caption in an + 
-environment of its own This effect will be seen with+<code latex>
-```latex+
 \begin{figure} \begin{figure}
-  <the illustration itself> +  ... la figure ... 
-  \caption{A Figure}+  \caption{Ma figure}
 \end{figure} \end{figure}
-\label{myfig+\label{mafig
-``` +</code> 
-where the `\label` definitely _is_ after the `\caption`, + 
-but because the `figure` environment closed before the +Ici, la commande ''\label'' est bien après la commande ''\caption''mais parce que l'environnement ''figure'' s'est fermé avant la commande ''\label''''\caption'' n'est plus « visible » de ''\label''. 
-`\label` commandthe `\caption` is no longer "visible".+ 
 +En résumé, la commande ''\label'' doit être //après// la commande qui la définit (par exemple, ''\caption''), et si la commande ''\caption'' est à l'intérieur d'un environnement, la commande ''\label'' doit y figurer également. 
 + 
 +-----
  
-In summary, the `\label` must be _after_ the command that +//Source:// [[faquk>FAQ-crossref|LaTeX gets cross-references wrong]]
-defines it (e.g., `\caption`), and if the `\caption` is inside +
-an environment, the `\label` must be in there too.+
  
 +{{htmlmetatags>metatag-keywords=(LaTeX,errors)
 +metatag-og:title=(Pourquoi ma référence croisée n'est pas correcte)
 +metatag-og:site_name=(FAQ LaTeX francophone)
 +}}
  
3_composition/texte/renvois/les_references_croisees_sont_fausses.1528031767.txt.gz · Dernière modification : 2018/06/03 13:16 de joseph.wright
CC Attribution-Share Alike 4.0 International
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0