7

I have a command \work which will format titles in SmallCaps and with less letter spacing. Now the funny thing: If I try to add some word spacing, too, and only for SmallCaps, it affects the whole document, as you can see in the MWE. Any ideas how to achieve that the word spacing only affects SmallCaps or my command?

\documentclass{article}

\usepackage{blindtext}
\usepackage{fontspec}
\setmainfont[SmallCapsFont={Latin Modern Roman Caps},
             SmallCapsFeatures={LetterSpace=-6,WordSpace={3}}]{Latin Modern Roman}

\newcommand{\work}[1]{\textsc{{#1}}}

\begin{document}

    Immanuel Kants \work{Kritik der praktischen Vernunft}, \work{Kritik der reinen Vernunft} und \work{Kritik der Urteilskraft}...

    \blindtext

\end{document}

enter image description here

  • LetterSpace works just fine – musicman Oct 24 '14 at 17:14
  • 3
    @musicman I already told you that negative letter spacing is exactly the contrary of what you should do; bigger word spacing only for small caps is something I can't understand the purpose of. Nonetheless, you seem to have discovered a bug in fontspec. – egreg Oct 24 '14 at 17:29
  • (I know you don't like it. But I couldn't find a proper font which gives me a similar output. In fact I want less letterspacing, and so I also need to shrink the wordspacing... And I'm not happy to find bugs) – musicman Oct 24 '14 at 17:33
5

An acceptable workaround, which still let's you use \textsc without changing it, it defines a similar command \work which does have the desired spacing.

I think that there's absolutely no reason to desire this spacing: letters overlap! They need room to breathe…

\documentclass{scrartcl}

\usepackage{blindtext}
\usepackage{fontspec}
\setmainfont{Latin Modern Roman}
\newfontface\workcaps{Latin Modern Roman Caps}[LetterSpace=-6,WordSpace=3]
\DeclareTextFontCommand\work{\workcaps}

\begin{document}

Immanuel Kants \work{Kritik der praktischen Vernunft}, \work{Kritik der
reinen Vernunft} und \work{Kritik der Urteilskraft}...

\blindtext

\end{document}

enter image description here

  • Thank you for this easy workaround. Works perfectly! If I don't get other answers I will accept yours. My current LetterSpace is -4 btw :-) – musicman Oct 24 '14 at 19:52
  • Even if I said this is a workaround, because if there were no bug you wouldn't need it, this is the official way of doing this. Since you don't want to change all the small caps from the document, just create a macro to document the work of an author… – Manuel Oct 24 '14 at 19:54
  • 1
    this really needs extra word space before (and possibly after) the title. mashing together the text with the title makes this really hard to read. (i agree that negative letterspacing is a bad thing, and increasing the word spacing makes things even worse.) – barbara beeton Feb 16 '15 at 21:45
0

After fiddling around with the same issue, I found the source of the «bug». It was the «Wordspace» feature. I am not quite sure that the «Letterspace» definition takes care of the spaces as well.

\documentclass{article}
\usepackage{blindtext}
\usepackage{fontspec}
\setmainfont[SmallCapsFont={Latin Modern Roman Caps},
             SmallCapsFeatures={LetterSpace=-6}]{Latin Modern Roman}
\newcommand{\work}[1]{\textsc{{#1}}}

\begin{document}
    Immanuel Kants \work{Kritik der praktischen Vernunft}, \work{Kritik der reinen Vernunft} und \work{Kritik der Urteilskraft}...
    \blindtext
\end{document}

enter image description here

  • The new syntax is \setmainfont{..}[..]. – Manuel Feb 16 '15 at 19:44
  • Your test confirm that we are not seen a bug. Word space is the distance between words. The question ask for a local word spacing and your excersie, proves that the parameter you found is an optimum for the letter space, for the given type face. – djnavas Apr 26 '16 at 17:03

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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