2

I'm creating a title page with large fonts, in French, and I really hate the usual hyphen for such a big title. So I'm looking for a shorter hyphen, something elegant and simple. Here's a MWE showing the issue (I'm using manual kerning to adjust the spacements, since it's a big title on a title page. Not the main text!):

\documentclass[11pt,letterpaper,twoside]{book}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[french]{babel}
\usepackage{lmodern}
\usepackage[total={6in,10in},left=1.5in,top=0.5in,includehead,includefoot]{geometry}
\usepackage{microtype}
\usepackage{libertine}
\renewcommand*\familydefault{\sfdefault}

\begin{document}

\raggedleft
        {\fontsize{58}{0}\selectfont{l\kern-0.03em '\kern-0.10em e\kern-0.02em s\kern-0.03em p\kern-0.03em a\kern-0.02em c\kern-0.02em e\textperiodcentered t\kern-0.03em e\kern-0.03em m\kern-0.04em p\kern-0.03em s}}

        {\fontsize{58}{0}\selectfont{l\kern-0.03em '\kern-0.10em e\kern-0.02em s\kern-0.03em p\kern-0.03em a\kern-0.02em c\kern-0.02em e-t\kern-0.03em e\kern-0.03em m\kern-0.04em p\kern-0.03em s}}

        {\fontsize{58}{0}\selectfont{l'espace-temps}}

\end{document}

Preview:

enter image description here

So is there a way to define or get a shorter hyphen, just for this title? I'm really jealous of the English word spacetime, which I can't use in my French book!

8
  • 1
    Well, it is adapted to the font size of your title! Consistency in sizes is important. – Bernard Aug 12 '20 at 18:51
  • Well, yes, but it’s a special case for a title page. I could get a better looking result with half an hyphen. – Cham Aug 12 '20 at 18:55
  • 1
    You may try \scalebox{0.5}[1]{-} (but maybe you'll have to adapt the kerning). – Bernard Aug 12 '20 at 19:01
  • It works. But it’s weird. Too small with 50%. Is it a good idea to use a bullet instead (the one shown above) ? – Cham Aug 12 '20 at 19:11
  • I was going to suggest what @Bernard just did. If you find it too small, make it {0.7}. – Steven B. Segletes Aug 12 '20 at 19:12
2

With fontspec, you have several options. One is to add the font feature FakeStretch= with a value less than 1.0.

\documentclass[11pt]{book}
\tracinglostchars=2
\usepackage[french]{babel}
\usepackage{fontspec}
\usepackage{microtype}
\usepackage{libertinus}
\renewcommand*\familydefault{\sfdefault}

\newcommand\shorthyphen{{\addfontfeature{FakeStretch=0.5}^^^^2010}}

\begin{document}

\raggedleft
        {\huge l'espace-temps}
        
        {\huge l'espace{\shorthyphen}temps}
\end{document}

Libertinus sample

If your font has it, you could substitute a shorter hyphen-like character, such as ﹣ (U+FE63 small hyphen-minus).

\newcommand\shorthyphen{^^^^fe63}

If you have a condensed or extra-condensed version of the font, you could load the hyphen character from that. If you’d previously declared \newfontfamily\condensedfont{...}, that might be

\newcommand\shorthyphen{{\condensedfont -}}

or if using the NFSS scheme where medium condensed is the series mc, something like

{\fontseries{mc}\selectfont -}

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.