Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I am currently writing a letter in French. I know that in the French language there are some (for other european languages) unusual spacings near question marks, colons and french guillemets. I write in utf8, so I can use guillements directly. My question is if in my minimal example below all spacings are correct:

\documentclass{letter}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[francais]{babel}

\signature{Bob le bricoleur}

\address{Je\\ne\\sais\\pas}

\begin{document}

\begin{letter}{Ton\\adresse\\je\\crois}

\opening{Bonjour Bobette,}

j'espère que tu rapelle notre « arrangement ». La morale: il ne faut jamais pleurer. Tu sais ça?

\closing{Amicalement,}

\end{letter}

\end{document}

I am not sure if it would be better to make the needed spaces myself. Any ideas?

share|improve this question
1  
i'm certainly no expert on this, but if you don't want the guillemets to be able to separate from the text at a line break, you should put in an unbreakable space; the tilde ~ will "tie" them to the associated text, but otherwise act as an ordinary word space. there should also be an unbreakable space before a question mark (or an exclamation mark, or a colon or semicolon). spacing after punctuation should be no different from ordinary word spacing -- use \frenchspacing to accomplish this. corrections from french-writing natives accepted. –  barbara beeton Oct 26 '12 at 21:09
1  
For quotes, I advise the csquotes package. It should do anything automatically and is very powerful. –  Qrrbrbirlbel Oct 27 '12 at 0:04
2  
I would direct you to Daniel Flippo's website. He maintains the updated version of the french language files for babel, and from what I understand, his file should work, whether or not you use a tie (~). –  ienissei Oct 27 '12 at 7:37
add comment

3 Answers

Unfortunately, the utf8 options only translates the guillemets to the commands \guillemotleft and \guillemotright. You can get automatically the space (even if you forget to write it) with newunicodechar. If you only use French, then

\usepackage{newunicodechar}
\newunicodechar{«}{\og}
\newunicodechar{»}{\fg}

is sufficient. If you use other languages, I recommend

\usepackage{newunicodechar}
\newunicodechar{«}{\iflanguage{francais}{\og}{\guillemotleft}}
\newunicodechar{»}{\iflanguage{francais}{\fg}{\guillemotright}}

Example

\documentclass{letter}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[francais]{babel}

\usepackage{newunicodechar}
\newunicodechar{«}{\iflanguage{francais}{\og}{\guillemotleft}}
\newunicodechar{»}{\iflanguage{francais}{\fg}{\guillemotright}}

\signature{Bob le bricoleur}

\address{Je\\ne\\sais\\pas}

\begin{document}

\begin{letter}{Ton\\adresse\\je\\crois}

\opening{Bonjour Bobette,}

j'espère que tu rapelle notre « arrangement ». La morale: il ne faut jamais pleurer. Tu sais ça?

j'espère que tu rapelle notre «arrangement». La morale: il ne faut jamais pleurer. Tu sais ça?

\closing{Amicalement,}

\end{letter}

\end{document}

You'll see that the spacing is the same.

share|improve this answer
add comment

It's better use french option for babel and \og and \fg for guillemets:

\documentclass{letter}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[french]{babel}

\signature{Bob le bricoleur}

\address{Je\\ne\\sais\\pas}

\begin{document}

\begin{letter}{Ton\\adresse\\je\\crois}

\opening{Bonjour Bobette,}

j'espère que tu rappelles notre \og arrangement\fg. La morale: il ne faut jamais pleurer. Tu sais ça?

\closing{Amicalement,}

\end{letter}

\end{document}
share|improve this answer
3  
francais is a synonym for the french option in babel, so there should be no difference between the two. –  Alan Munn Oct 27 '12 at 3:12
    
I recommend reading perso.enstimac.fr/Gaborit~/latex/latex-in-french.html –  rpapa Oct 27 '12 at 7:52
    
@rpapa: the correct link is perso.enstimac.fr/~Gaborit/latex/latex-in-french.html and unfortunately some of the informations in it are outdated (e.g. package aeguill is obsolete, one should use fontenc with T1). –  Philippe Goutet Oct 27 '12 at 10:59
    
I just read about the babel option frenchb which I am currently using. \usepackage[frenchb]{babel} with \frenchbsetup{og=«, fg=», GlobalLayoutFrench=true}. Is there any difference between french and frenchb? –  Wauzl Oct 27 '12 at 19:09
    
@Wauzl: on a recent distribution, the french, frenchb and francais options will all be equivalent (they were not at some point in the past, where the french option could call something else). –  Philippe Goutet Oct 28 '12 at 9:07
add comment

You might use the package microtype and set the kerning to english or set the kerning after special characters manually. Have a look at p. 18f., 133, 136 and 187-9 of microtype.pdf. (There is even a command \nonfrenchspacing, which I've never used.)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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