0

Even if I specified the French language in the preamble of my document (Tufte-book documentclass), the formatting of the legends of the figures and tables has been kept in English. So I added to the babel-french package in the preamble a command to replace "Table" by "Tableau" (the term Figure is the same in both languages) and precise at the beginning of the figure and it works:

\documentclass[symmetric,justified,marginals=raggedouter]{tufte-book}
\usepackage[french]{babel}
\addto\captionsfrench{\def\tablename{Tableau}}

\begin{document}

\begin{table*}[h]
 \selectlanguage{french}
 \footnotesize
 \begin{tabular}
 \end{tabular}
 \caption{Example to insert space before double dots}
\label{tab:example}
\end{table*}

\end{document}

On the other hand, in French language, there is a space between the number of the caption and the double dots which present the label of the caption, contrary to what is practiced in English language ("Figure 1 :" and not "Figure 1:").

What should I do to insert this space?

1

This appears to work:

\documentclass[12pt]{scrartcl}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english,french]{babel}
\usepackage[french]{cleveref}
\usepackage{caption}
% Declare a new caption label seperator with a small math space \, in front of ":"
\DeclareCaptionLabelSeparator{frcolon}{ $\,:$ }
% Set the new label seperator to be used by caption
\captionsetup{labelsep=frcolon}

\begin{document}
French \cref{tab-my_label} seems to be different from English tables...
\begin{table}[h]
    \centering
    \begin{tabular}{c|c}
        a & b \\
        c & d
    \end{tabular}
    \caption{Caption}
    \label{tab-my_label}
\end{table}
\end{document}
| improve this answer | |
  • It seems to work but the fontsize of the caption is modified. How to precise footnotesize ? – Phil8544 Apr 9 at 12:44
  • 1
    in \captionsetup{} you can add font=footnotesize separated by a "," from the other options (in this case the labelsep=frcolon option) – Manuel Popp Apr 9 at 13:07
  • When I apply the code, all the figures (but not the tables) move at the end of the chapter... ? – Phil8544 Apr 9 at 13:33
  • I don't know your text, but the figures moving to the end of the chapter should not be caused by this. Only the total size of the figure/ table including the caption and the location where the respective environment is placed within the text should affect where the figures go. Maybe you added some text somewhere and now LaTeX finds no appropriate way to place the figures in the text, but I can just guess from here. Maybe move the environments to earlier playes or change the order of the placement options (\begin{figue}[htb]) – Manuel Popp Apr 10 at 8:22
  • I try with \begin{figure}[h], \begin{figure}[t], \begin{figure}[b], \begin{figure}[!], none of them work... – Phil8544 Apr 10 at 10:18

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.