LaTeX forum ⇒ Document Classespaper class problem with French/babel Topic is solved

Information and discussion about specific document classes and how to create your own document classes.
User avatar
Cham
Posts: 820
Joined: Sat Apr 02, 2011 4:06 pm

paper class problem with French/babel

Postby Cham » Wed Dec 06, 2017 11:47 pm

I know that the paper class is very old, and its documentation is German only (I didn't found an English version). Yet, I would like to set up a French document with this class, and I'm encountering a problem with the figure's label. Here's a MWE showing the issue :
  1. \RequirePackage[l2tabu,orthodox]{nag}
  2. \documentclass[11pt,twoside]{paper}
  3. \usepackage[T1]{fontenc}
  4. \usepackage[french]{babel}
  5. \usepackage{graphicx}
  6. \usepackage{subfig}
  7. \usepackage[total={6.25in,10in},left=1.25in,top=0.5in,includehead,includefoot]{geometry}
  8.  
  9. \begin{document}
  10.  
  11. \begin{figure}
  12. \centering
  13. \includegraphics[height=4cm]{example-image-a}
  14. \caption{Some caption text.}
  15. \end{figure}
  16.  
  17. \end{document}


There is no space before the ":" (just after the caption's number. Is it possible to change this to a French like "--" with a space on both sides?

Weirdly, this class is the only one giving me an hard time in setting a proper French version of its captions, even using some options to the caption/subfig package :
  1. \usepackage{subfig}
  2. \captionsetup{figurename=Figure,margin=1in,format=hang,font=small,format=plain,labelfont={bf,up,sf},textfont={up}}
  3. \captionsetup[subfigure]{margin=0cm,font=small,format=plain,labelfont={bf,up},textfont={up}}
  4. \captionsetup[table]{name=Table,labelfont={bf,up}}

User avatar
Stefan Kottwitz
Site Admin
Posts: 8537
Joined: Mon Mar 10, 2008 9:44 pm
Location: Hamburg, Germany
Contact:

Postby Stefan Kottwitz » Thu Dec 07, 2017 1:20 am

Hi Cham,

simply add

\captionsetup{labelsep=endash}

Stefan
Site admin

User avatar
Cham
Posts: 820
Joined: Sat Apr 02, 2011 4:06 pm

Postby Cham » Thu Dec 07, 2017 2:58 am

Nice one, thanks Stefan!


Return to “Document Classes”

Who is online

Users browsing this forum: No registered users and 2 guests