latex3 / babel

The babel system for LaTeX, LuaLaTeX and XeLaTeX
LaTeX Project Public License v1.3c
123 stars 34 forks source link

babel, fontsetup, and NewComputerModern (and other fonts) #275

Closed GMS103 closed 6 months ago

GMS103 commented 6 months ago

French spacing does not seem to work anymore. The following does not add any spacing before :?!;.

% !TEX encoding = UTF-8 Unicode
% !TEX program = xelatexmk
\documentclass[french]{report}
\usepackage{fontspec}
\usepackage{fontsetup} % will load the Book weight of the NewCM family
\usepackage[main=french]{babel}
\begin{document}
Ààà: bbb? ccc! ddd; ééé.
\end{document}

Using other fonts instead of NewComputerModern does not work either. Commenting \usepackage{fontsetup} to use CM it works as before.

u-fischer commented 6 months ago

fontspec now loads the ucharclass package. You would need something similar to https://tex.stackexchange.com/a/261091/2388 with the command names translated for babel-french.

GMS103 commented 6 months ago

Thanks, Ulrike. When you say "you", do you mean "me", or "Javier"?

u-fischer commented 6 months ago

Imho either you in your document or Daniel Flipo in babel-french.

GMS103 commented 6 months ago

Thanks, I told Daniel in case he could solve it for everybody.

jbezos commented 6 months ago

Given the huge limitations in the interchar mechanism, I think loading ucharclasses by default is not a good idea.

jbezos commented 6 months ago

I'm closing this issue because it’s not directly related to the babel core. However, I’ll keep an eye on it because I was currently working on language dependent interchar rules (https://latex3.github.io/babel/news/whats-new-in-babel-3.97.html).

jbezos commented 6 months ago

fontspec now loads the ucharclass package

I was re-installing my system and I couldn’t make tests, but now I realize there was a slip: you meant fontsetup, which is quite fine 😌.