193

I can't seem to have both the small caps and boldface styles on a line:

\huge\sc\bf Hello

This will generate bold text, and if the \sc is placed after, it will generate small caps text but not bolded. They seem to override each other, so is there any way to apply them both?

1

8 Answers 8

219

Your question requires a two-part answer.

\sc and \bf (and \it) are deprecated because, as you have noticed, they override each other. Use either

\textit{...}
\textbf{...}
\textsc{...}

or

{\itshape ...}
{\bfseries ...}
{\scshape ...}

instead.

However, not all fonts contain italic and/or bold small caps (when they even contain small caps).

(Also, italic and small caps usually don't combine at all by default, requiring \usepackage{slantsc} to do so.)

When you load the T1 font encoding, you're replacing the default Computer Modern fonts by CM-Super, a larger but lower-quality set of fonts that look mostly identical but contain many more glyphs. In older TeX distributions, you might even end up with bitmap fonts in your output.

The Latin Modern fonts are a better alternative (\usepackage{lmodern}), but they unfortunately don't contain bold small caps.

3
  • 12
    "In older TeX distributions, you might even end up with bitmap fonts in your output." - or the \textsc is just ignored and the \textbf{\textsc{...-text it printed in bold, because there is no appropriate font available and neither can it be created on the fly.
    – Stephen
    Commented Dec 9, 2011 at 18:36
  • 1
    Can you explain why you call the CM-Super font "lower quality"? I always use the T1 encoding in order to be able to correctly copy-paste umlauts (for example) from my documents. Is there an explanation somewhere of the difference between the two?
    – Fritz
    Commented Sep 14, 2014 at 12:06
  • 2
    I can't find the TUG article that discusses it explicitly (I thought there was one in the last few years), but Cm-Super, I believe, is generated more automatically; in particular, I seem to recall that its auto tracing method produced outlines that are more complex than they need to be (i.e., fonts are larger) but also not as representative of the original CM bitmaps. Commented Sep 15, 2014 at 4:29
52

For posterity, there is an easier and better alternative. Simply add

\usepackage{bold-extra}

along with your other includes. This lets you keep using the default high-quality Computer Modern fonts for normal text. It works by building a bold Computer Modern small-caps font on the fly and including it for you. Now {\bfseries\scshape Foo} works as expected!

Reference: https://texfaq.org/FAQ-bold-extras

7
  • 9
    from my own experiments, I would contest the claim that this method keeps "using the default high-quality Computer Modern fonts." My bold small caps appear pixelated if I use the bold-extra package.
    – arturomp
    Commented Jan 22, 2012 at 20:19
  • @amp sure -- the cm bold sc, etc, fonts are contributed extra metafont snippets. no-one seems to have traced them. Commented Mar 7, 2012 at 13:22
  • 12
    Just a note for readers, \bfseries and \scshape do not take arguments; more appropriate syntax for the example would be {\bfseries{\scshape Foo}} or simply {\bfseries\scshape Foo}, but the argument variants are often preferred: \textbf{\textsc{Foo}}. Commented Jan 8, 2014 at 1:34
  • 1
    @arturomp Did you combine this with \usepackage[T1]{fontenc}? Gives non-pixelated bold small caps for me. Commented May 4, 2015 at 16:25
  • 2
    Using bold-extra did not make any difference for me (running lualatex)
    – Raven
    Commented Jun 4, 2021 at 7:23
28

Ok, you need to add

\usepackage[T1]{fontenc}

and this updated command should do the trick

\huge \textbf{\textsc{Hello}}

To explain, LaTeX uses the curly braces {} to indicate scope for the formatting command. So if you type

\textbf{ ... }

then all the text between the curly braces is formatted in bold, including the

\textsc{Hello}

Result

Small Caps Bold

Small Caps Bold

compared to regular small caps

small caps regular

3
  • 16
    It doesn't seem to work. The text is only in bold. Also, I think that's the same as my statement since the braces are implied.
    – verhogen
    Commented Mar 30, 2009 at 23:10
  • ok, actually I had the [T1], I think the problem was actually my PDF viewer...
    – verhogen
    Commented Mar 31, 2009 at 4:00
  • 5
    The lmodern package prevents the good functioning of "bold" + "small caps". Is that possible ?
    – SDrolet
    Commented Mar 31, 2014 at 0:20
17

As an extension of accepted answer https://tex.stackexchange.com/a/27413/1340, I explain here how to use Latin Modern while taking serif bold small capitals from Computer Modern (= CM) Super. As explained in that answer, you'll still need to use \textsc{\textbf{Hello}} instead of \sc\bf Hello. This assumes you're using \usepackage[T1]{fontenc} as typically recommended nowadays. The solution is inspired from an aside in question How te get bold + small caps with latin modern or computer modern.

First, to obtain a "fixed" version of CM Super, add

\RequirePackage{fix-cm}

before \documentclass. After \documentclass add the following commands (with or without comments):

\usepackage[T1]{fontenc} % To switch to the T1 encoding
\usepackage{lmodern} % To switch to Latin Modern
\rmfamily % To load Latin Modern Roman and enable the following NFSS declarations.
% Declare that Latin Modern Roman (lmr) should take
% its bold (b) and bold extended (bx) weight, and small capital (sc) shape, 
% from the corresponding Computer Modern Roman (cmr) font, for the T1 font encoding.
\DeclareFontShape{T1}{lmr}{b}{sc}{<->ssub*cmr/bx/sc}{}
\DeclareFontShape{T1}{lmr}{bx}{sc}{<->ssub*cmr/bx/sc}{}

The resulting output has working bold small capitals in Type 1 format (tested with pdflatex).

3
  • 2
    Excellent answer, thank you. I could't just use \usepackage[T1]{fontenc} for bold small caps because I also needed bold teletype provide by \usepackage{lmodern} for my code listings, but your solution provides both! Commented Feb 9, 2019 at 19:28
  • It's elegant. I am writing a class which supports compilation with pdflatex, lualatex and xelatex, which means I have to either use lmodern or fontspec but whant to obtain more or less the same look. Your solution is perfect to achieve that! Commented Oct 9, 2019 at 14:46
  • 1
    @AlexandreQuenon Happy it helped! Commented Oct 9, 2019 at 14:53
16

A rather crude way of obtaining bold-like characters from a font that doesn't have it, is to repeatedly overprint a character with slight variations. This is offered by the contour package:

enter image description here

\documentclass{article}
\usepackage{contour}% http://ctan.org/pkg/contour
\setlength{\parindent}{0pt}% Just for this example
\begin{document}

% Default
Hello

% Bold
\textbf{Hello}

% Small-caps
\textsc{Hello}

% Combined
\textbf{\textsc{Hello}}

% Default \contourlength (0.03em)
\contour{black}{\textsc{Hello}}

\contourlength{0.01em}% Smaller radius
\contour{black}{\textsc{Hello}}

\contour*{black}{\textsc{Hello}}% 32 copies (default is 16)

\contour[100]{black}{\textsc{Hello}}% 100 copies

% Just for reference
\contourlength{0.05em}
\contour[5]{red}{\textsc{Hello}}

\end{document}
2
  • 1
    It's worth noting that this method generalises to awkward situations, e.g. where you don't want to (or can't) use font substitution to obtain the same effect.
    – Landak
    Commented Sep 19, 2015 at 12:49
  • This solution is so simple but effective. I love it. I recommend using \contourlength{0.01em} with 10 copies. Looks just like regular bold text. Thank you!
    – jrjrjr
    Commented Jun 23, 2023 at 23:34
13

For many years, because I rarely need it, I have used the following hack:

\textbf{\normalsize{E}\scriptsize{ITHER} \normalsize{O}\scriptsize{NE} \normalsize{B}\scriptsize{UT} \normalsize{N}\scriptsize{OT} \normalsize{B}\scriptsize{OTH}}

which gives

enter image description here

But I wish there were a better way.


Editor's note: as discussed in comments, font switches such as \normalsize don't take arguments, instead they take effect until a new font switch is used (or when the group scope ends). A syntactically better way is therefore as follows:

\textbf{\normalsize E\scriptsize ITHER \normalsize O\scriptsize NE \normalsize B\scriptsize UT \normalsize N\scriptsize OT \normalsize B\scriptsize OTH}

The result is the same as above.

8
  • 1
    @cfr I will not discuss the value of your edit but now my sentence, namelyI have used the following hack, is FALSE as, for the better of for the worse, this is NOT the hack I have used. I don't think that's appropriate. Why couldn't you write it as your answer?
    – schremmer
    Commented Aug 25, 2017 at 14:27
  • 4
    Your code was wrong: font switches don't take arguments. \scriptsize{a} \scriptsize{b} c d is just \scriptsize a b c d. The {} aren't part of the macro syntax. They are just regular TeX grouping characters. But people see this kind of bad code and they expect that \scriptsize{a} b will not put b in \scriptsize. I didn't change your hack. It is the same hack. I just corrected the use of NFSS implementing the hack. I'm certainly not going to write an answer suggesting your hack, since I think it is horrible to do this. It is still the same (horrible) hack. But it doesn't abuse NFSS.
    – cfr
    Commented Aug 25, 2017 at 23:00
  • 2
    That is pretty much how SE works. The history shows that I edited it and, indeed, precisely what I did. I want to offend you, but if you don't want your code edited regardless, you really shouldn't post it on this site. As I say, it is still your hack. It just uses NFSS correctly. I took that to be inessential to your hack, which I left unchanged. That is, I did not significantly alter your intended meaning, just corrected a common mistake which was incidental to it.
    – cfr
    Commented Aug 28, 2017 at 2:27
  • 1
    I've rolled it back and flagged the discussion. Note that I've rolled back my edit but not the previous edit, which was not mine, as you seem to object only to the changes I made, for reasons I'm not entirely sure of. I didn't mean to offend you or start an argument. I think correcting the use of NFSS improves the post. I wouldn't do this because I am generally opposed to faking font variants (small-caps, bold etc.) generally. I think it better to pick a font with the features you need. I don't have any objection to your hackery in particular, by any means.
    – cfr
    Commented Aug 28, 2017 at 2:37
  • 2
    FWIW this brutal hack is the only thing that worked for me in a section title using T1.
    – srs
    Commented Mar 29, 2019 at 18:19
8

This is an answer-sized comment, but more of a question, in the end.

Now with fontspec and xelatex/lualatex allowing access to the Unicode universe and to system fonts:

Given the multi-dimensionality of fonts

in the sense of

  • weight: thin, light, medium, bold, black, etc

  • italic shape: italic, upright

  • smallcaps shape: smallcaps, not smallcaps

  • width: normal, condensed, extra-condensed, wide, etc

such that, taking Noto Serif as an example, we have normal/italic, by various weights and widths, like so:

sample1

and the smallcaps version:

sample2

with the code for all this, defining both font commands and font switches for all the combinations:

MWE

\documentclass[12pt]{article}
\usepackage{xcolor}
\pagecolor{red!3}

\usepackage{fontspec}

\setromanfont{Noto Serif}[
  FontFace={ul}{n}{Font=* Thin},
  FontFace={el}{n}{Font=* ExtraLight},
  FontFace={l}{n}{Font=* Light},
  FontFace={m}{n}{Font=* Medium},
  FontFace={sb}{n}{Font=* SemiBold},
  FontFace={b}{n}{Font=* Bold},
  FontFace={eb}{n}{Font=* ExtraBold},
  FontFace={xb}{n}{Font=* Black},%=========================
  FontFace={ulc}{n}{Font=* Condensed Thin},
  FontFace={elc}{n}{Font=* Condensed ExtraLight},
  FontFace={lc}{n}{Font=* Condensed Light},
  FontFace={mc}{n}{Font=* Condensed Medium},
  FontFace={sbc}{n}{Font=* Condensed SemiBold},
  FontFace={bc}{n}{Font=* Condensed Bold},
  FontFace={ebc}{n}{Font=* Condensed ExtraBold},
  FontFace={xbc}{n}{Font=* Condensed Black},%====================
  FontFace={ul}{i}{Font=* Thin Italic},
  FontFace={el}{i}{Font=* ExtraLight Italic},
  FontFace={l}{i}{Font=* Light Italic},
  FontFace={m}{i}{Font=* Medium Italic},
  FontFace={sb}{i}{Font=* SemiBold Italic},
  FontFace={b}{i}{Font=* Bold Italic},
  FontFace={eb}{i}{Font=* ExtraBold Italic},
  FontFace={xb}{i}{Font=* Black Italic},%===========================
  FontFace={ulc}{i}{Font=* Condensed Thin Italic},
  FontFace={elc}{i}{Font=* Condensed ExtraLight Italic},
  FontFace={lc}{i}{Font=* Condensed Light Italic},
  FontFace={mc}{i}{Font=* Condensed Medium Italic},
  FontFace={sbc}{i}{Font=* Condensed SemiBold Italic},
  FontFace={bc}{i}{Font=* Condensed Bold Italic},
  FontFace={ebc}{i}{Font=* Condensed ExtraBold Italic},
  FontFace={xbc}{i}{Font=* Condensed Black Italic},%===================
  FontFace={ulsc}{s}{Font=* Thin,SmallCapsFont={* Thin},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={elsc}{s}{Font=* ExtraLight,SmallCapsFont={* ExtraLight},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={lsc}{s}{Font=* Light,SmallCapsFont={* Light},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={msc}{s}{Font=* Medium,SmallCapsFont={* Medium},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={sbsc}{s}{Font=* SemiBold,SmallCapsFont={* SemiBold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={bsc}{s}{Font=* Bold,SmallCapsFont={* Bold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={ebsc}{s}{Font=* ExtraBold,SmallCapsFont={* ExtraBold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={xbsc}{s}{Font=* Black,SmallCapsFont={* Black},SmallCapsFeatures={Letters=SmallCaps},},%=========================
  FontFace={ulcsc}{s}{Font=* Condensed Thin,SmallCapsFont={* Condensed Thin},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={elcsc}{s}{Font=* Condensed ExtraLight,SmallCapsFont={* Condensed ExtraLight},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={lcsc}{s}{Font=* Condensed Light,SmallCapsFont={* Condensed Light},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={mcsc}{s}{Font=* Condensed Medium,SmallCapsFont={* Condensed Medium},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={sbcsc}{s}{Font=* Condensed SemiBold,SmallCapsFont={* Condensed SemiBold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={bcsc}{s}{Font=* Condensed Bold,SmallCapsFont={* Condensed Bold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={ebcsc}{s}{Font=* Condensed ExtraBold,SmallCapsFont={* Condensed ExtraBold},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={xbcsc}{s}{Font=* Condensed Black,SmallCapsFont={* Condensed Black},SmallCapsFeatures={Letters=SmallCaps},},%====================
  FontFace={ulsci}{i}{Font=* Thin Italic,SmallCapsFont={* Thin Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={elsci}{i}{Font=* ExtraLight Italic,SmallCapsFont={* ExtraLight Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={lsci}{i}{Font=* Light Italic,SmallCapsFont={* Light Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={msci}{i}{Font=* Medium Italic,SmallCapsFont={* Medium Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={sbsci}{i}{Font=* SemiBold Italic,SmallCapsFont={* SemiBold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={bsci}{i}{Font=* Bold Italic,SmallCapsFont={* Bold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={ebsci}{i}{Font=* ExtraBold Italic,SmallCapsFont={* ExtraBold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={xbsci}{i}{Font=* Black Italic,SmallCapsFont={* Black Italic},SmallCapsFeatures={Letters=SmallCaps},},%=========================
  FontFace={ulcsci}{i}{Font=* Condensed Thin Italic,SmallCapsFont={* Condensed Thin Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={elcsci}{i}{Font=* Condensed ExtraLight Italic,SmallCapsFont={* Condensed ExtraLight Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={lcsci}{i}{Font=* Condensed Light Italic,SmallCapsFont={* Condensed Light Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={mcsci}{i}{Font=* Condensed Medium Italic,SmallCapsFont={* Condensed Medium Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={sbcsci}{i}{Font=* Condensed SemiBold Italic,SmallCapsFont={* Condensed SemiBold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={bcsci}{i}{Font=* Condensed Bold Italic,SmallCapsFont={* Condensed Bold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={ebcsci}{i}{Font=* Condensed ExtraBold Italic,SmallCapsFont={* Condensed ExtraBold Italic},SmallCapsFeatures={Letters=SmallCaps},},
  FontFace={xbcsci}{i}{Font=* Condensed Black Italic,SmallCapsFont={* Condensed Black Italic},SmallCapsFeatures={Letters=SmallCaps},},%====================
  ]

%normal
\DeclareRobustCommand{\ulseries}{\fontseries{ul}\selectfont}
\DeclareRobustCommand{\elseries}{\fontseries{el}\selectfont}
\DeclareRobustCommand{\lseries}{\fontseries{l}\selectfont}
\DeclareRobustCommand{\mseries}{\fontseries{m}\selectfont}
\DeclareRobustCommand{\sbseries}{\fontseries{sb}\selectfont}
\DeclareRobustCommand{\bseries}{\fontseries{b}\selectfont}
\DeclareRobustCommand{\ebseries}{\fontseries{eb}\selectfont}
\DeclareRobustCommand{\xbseries}{\fontseries{xb}\selectfont}

%condensed
\DeclareRobustCommand{\ulcseries}{\fontseries{ulc}\selectfont}
\DeclareRobustCommand{\elcseries}{\fontseries{elc}\selectfont}
\DeclareRobustCommand{\lcseries}{\fontseries{lc}\selectfont}
\DeclareRobustCommand{\mcseries}{\fontseries{mc}\selectfont}
\DeclareRobustCommand{\sbcseries}{\fontseries{sbc}\selectfont}
\DeclareRobustCommand{\bcseries}{\fontseries{bc}\selectfont}
\DeclareRobustCommand{\ebcseries}{\fontseries{ebc}\selectfont}
\DeclareRobustCommand{\xbcseries}{\fontseries{xbc}\selectfont}

%normal
\DeclareTextFontCommand{\textul}{\ulseries}
\DeclareTextFontCommand{\textel}{\elseries}
\DeclareTextFontCommand{\textl}{\lseries}
\DeclareTextFontCommand{\textm}{\mseries}
\DeclareTextFontCommand{\textsb}{\sbseries}
\DeclareTextFontCommand{\textb}{\bseries}
\DeclareTextFontCommand{\texteb}{\ebseries}
\DeclareTextFontCommand{\textxb}{\xbseries}


%condensed
\DeclareTextFontCommand{\textulc}{\ulcseries}
\DeclareTextFontCommand{\textelc}{\elcseries}
\DeclareTextFontCommand{\textlc}{\lcseries}
\DeclareTextFontCommand{\textmc}{\mcseries}
\DeclareTextFontCommand{\textsbc}{\sbcseries}
\DeclareTextFontCommand{\textbc}{\bcseries}
\DeclareTextFontCommand{\textebc}{\ebcseries}
\DeclareTextFontCommand{\textxbc}{\xbcseries}


%normal italic
\DeclareRobustCommand{\uliseries}{\fontseries{ul}\fontshape{i}\selectfont}
\DeclareRobustCommand{\eliseries}{\fontseries{el}\fontshape{i}\selectfont}
\DeclareRobustCommand{\liseries}{\fontseries{l}\fontshape{i}\selectfont}
\DeclareRobustCommand{\miseries}{\fontseries{m}\fontshape{i}\selectfont}
\DeclareRobustCommand{\sbiseries}{\fontseries{sb}\fontshape{i}\selectfont}
\DeclareRobustCommand{\biseries}{\fontseries{b}\fontshape{i}\selectfont}
\DeclareRobustCommand{\ebiseries}{\fontseries{eb}\fontshape{i}\selectfont}
\DeclareRobustCommand{\xbiseries}{\fontseries{xb}\fontshape{i}\selectfont}

%normal italic
\DeclareTextFontCommand{\textuli}{\uliseries}
\DeclareTextFontCommand{\texteli}{\eliseries}
\DeclareTextFontCommand{\textli}{\liseries}
\DeclareTextFontCommand{\textmi}{\miseries}
\DeclareTextFontCommand{\textsbi}{\sbiseries}
\DeclareTextFontCommand{\textbi}{\biseries}
\DeclareTextFontCommand{\textebi}{\ebiseries}
\DeclareTextFontCommand{\textxbi}{\xbiseries}

%condensed italic
\DeclareRobustCommand{\ulciseries}{\fontseries{ulc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\elciseries}{\fontseries{elc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\lciseries}{\fontseries{lc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\mciseries}{\fontseries{mc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\sbciseries}{\fontseries{sbc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\bciseries}{\fontseries{bc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\ebciseries}{\fontseries{ebc}\fontshape{i}\selectfont}
\DeclareRobustCommand{\xbciseries}{\fontseries{xbc}\fontshape{i}\selectfont}


%condensed italic
\DeclareTextFontCommand{\textulci}{\ulciseries}
\DeclareTextFontCommand{\textelci}{\elciseries}
\DeclareTextFontCommand{\textlci}{\lciseries}
\DeclareTextFontCommand{\textmci}{\mciseries}
\DeclareTextFontCommand{\textsbci}{\sbciseries}
\DeclareTextFontCommand{\textbci}{\bciseries}
\DeclareTextFontCommand{\textebci}{\ebciseries}
\DeclareTextFontCommand{\textxbci}{\xbciseries}

%normal small caps
\DeclareRobustCommand{\ulscseries}{\fontseries{ulsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\elscseries}{\fontseries{elsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\lscseries}{\fontseries{lsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\mscseries}{\fontseries{msc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\sbscseries}{\fontseries{sbsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\bscseries}{\fontseries{bsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\ebscseries}{\fontseries{ebsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\xbscseries}{\fontseries{xbsc}\fontshape{s}\scshape\selectfont}

%normal small caps
\DeclareTextFontCommand{\textulsc}{\ulscseries}
\DeclareTextFontCommand{\textelsc}{\elscseries}
\DeclareTextFontCommand{\textlsc}{\lscseries}
\DeclareTextFontCommand{\textmsc}{\mscseries}
\DeclareTextFontCommand{\textsbsc}{\sbscseries}
\DeclareTextFontCommand{\textbsc}{\bscseries}
\DeclareTextFontCommand{\textebsc}{\ebscseries}
\DeclareTextFontCommand{\textxbsc}{\xbscseries}

%condensed small caps
\DeclareRobustCommand{\ulcscseries}{\fontseries{ulcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\elcscseries}{\fontseries{elcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\lcscseries}{\fontseries{lcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\mcscseries}{\fontseries{mcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\sbcscseries}{\fontseries{sbcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\bcscseries}{\fontseries{bcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\ebcscseries}{\fontseries{ebcsc}\fontshape{s}\scshape\selectfont}
\DeclareRobustCommand{\xbcscseries}{\fontseries{xbcsc}\fontshape{s}\scshape\selectfont}


%condensed small caps
\DeclareTextFontCommand{\textulcsc}{\ulcscseries}
\DeclareTextFontCommand{\textelcsc}{\elcscseries}
\DeclareTextFontCommand{\textlcsc}{\lcscseries}
\DeclareTextFontCommand{\textmcsc}{\mcscseries}
\DeclareTextFontCommand{\textsbcsc}{\sbcscseries}
\DeclareTextFontCommand{\textbcsc}{\bcscseries}
\DeclareTextFontCommand{\textebcsc}{\ebcscseries}
\DeclareTextFontCommand{\textxbcsc}{\xbcscseries}



%normal small caps italic
\DeclareRobustCommand{\ulsciseries}{\fontseries{ulsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\elsciseries}{\fontseries{elsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\lsciseries}{\fontseries{lsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\msciseries}{\fontseries{msci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\sbsciseries}{\fontseries{sbsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\bsciseries}{\fontseries{bsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\ebsciseries}{\fontseries{ebsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\xbsciseries}{\fontseries{xbsci}\fontshape{i}\scshape\selectfont}

%normal small caps italic
\DeclareTextFontCommand{\textulsci}{\ulsciseries}
\DeclareTextFontCommand{\textelsci}{\elsciseries}
\DeclareTextFontCommand{\textlsci}{\lsciseries}
\DeclareTextFontCommand{\textmsci}{\msciseries}
\DeclareTextFontCommand{\textsbsci}{\sbsciseries}
\DeclareTextFontCommand{\textbsci}{\bsciseries}
\DeclareTextFontCommand{\textebsci}{\ebsciseries}
\DeclareTextFontCommand{\textxbsci}{\xbsciseries}

%%condensed small caps italic
\DeclareRobustCommand{\ulcsciseries}{\fontseries{ulcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\elcsciseries}{\fontseries{elcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\lcsciseries}{\fontseries{lcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\mcsciseries}{\fontseries{mcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\sbcsciseries}{\fontseries{sbcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\bcsciseries}{\fontseries{bcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\ebcsciseries}{\fontseries{ebcsci}\fontshape{i}\scshape\selectfont}
\DeclareRobustCommand{\xbcsciseries}{\fontseries{xbcsci}\fontshape{i}\scshape\selectfont}


%condensed small caps italic
\DeclareTextFontCommand{\textulcsci}{\ulcsciseries}
\DeclareTextFontCommand{\textelcsci}{\elcsciseries}
\DeclareTextFontCommand{\textlcsci}{\lcsciseries}
\DeclareTextFontCommand{\textmcsci}{\mcsciseries}
\DeclareTextFontCommand{\textsbcsci}{\sbcsciseries}
\DeclareTextFontCommand{\textbcsci}{\bcsciseries}
\DeclareTextFontCommand{\textebcsci}{\ebcsciseries}
\DeclareTextFontCommand{\textxbcsci}{\xbcsciseries}





\begin{document}

%\fontname\mseries
\section{Noto Serif}
\rmfamily
%\itshape
%\scshape
\subsection{Normal}
\begin{tabular}{c}
Normal \\
\hline\ \\
\textul{Abc Thin} {\ulseries Thin}\\
\textel{Abc ExtraLight} {\elseries ExtraLight}\\
\textl{Abc Light} {\lseries Light}\\
\textm{Abc Medium} {\mseries Medium}\\
\textsb{Abc SemiBold} {\sbseries SemiBold}\\
\textb{Abc Bold} {\bseries Bold}\\
\texteb{Abc ExtraBold} {\ebseries ExtraBold}\\
\textxb{Abc Black} {\xbseries Black}\\%
\end{tabular}
\begin{tabular}{c}
Condensed\\
\hline\ \\
\textulc{Abc Thin} {\ulcseries Thin}\\
\textelc{Abc ExtraLight} {\elcseries ExtraLight}\\
\textlc{Abc Light} {\lcseries Light}\\
\textmc{Abc Medium} {\mcseries Medium}\\
\textsbc{Abc SemiBold} {\sbcseries SemiBold}\\
\textbc{Abc Bold} {\bcseries Bold}\\
\textebc{Abc ExtraBold} {\ebcseries ExtraBold}\\
\textxbc{Abc Black} {\xbcseries Black}\\%
\end{tabular}

\vskip1em
\begin{tabular}{c}
Normal Italic \\
\hline\ \\
\textuli{Abc Thin} {\uliseries Thin}\\
\texteli{Abc ExtraLight} {\eliseries ExtraLight}\\
\textli{Abc Light} {\liseries Light}\\
\textmi{Abc Medium} {\miseries Medium}\\
\textsbi{Abc SemiBold} {\sbiseries SemiBold}\\
\textbi{Abc Bold} {\biseries Bold}\\
\textebi{Abc ExtraBold} {\ebiseries ExtraBold}\\
\textxbi{Abc Black} {\xbiseries Black}\\%
\end{tabular}
\begin{tabular}{c}
Condensed Italic\\
\hline\ \\
\textulci{Abc Thin} {\ulciseries Thin}\\
\textelci{Abc ExtraLight} {\elciseries ExtraLight}\\
\textlci{Abc Light} {\lciseries Light}\\
\textmci{Abc Medium} {\mciseries Medium}\\
\textsbci{Abc SemiBold} {\sbciseries SemiBold}\\
\textbci{Abc Bold} {\bciseries Bold}\\
\textebci{Abc ExtraBold} {\ebciseries ExtraBold}\\
\textxbci{Abc Black} {\xbciseries Black}\\%
\end{tabular}

\newpage
\subsection{Small Caps}
\vskip1em
\begin{tabular}{c}
Normal Small Caps \\
\hline\ \\
\textulsc{Abc Thin} {\ulscseries Thin}\\
\textelsc{Abc ExtraLight} {\elscseries ExtraLight}\\
\textlsc{Abc Light} {\lscseries Light}\\
\textmsc{Abc Medium} {\mscseries Medium}\\
\textsbsc{Abc SemiBold} {\sbscseries SemiBold}\\
\textbsc{Abc Bold} {\bscseries Bold}\\
\textebsc{Abc ExtraBold} {\ebscseries ExtraBold}\\
\textxbsc{Abc Black} {\xbscseries Black}\\%
\end{tabular}
\begin{tabular}{c}
Condensed Small Caps\\
\hline\ \\
\textulcsc{Abc Thin} {\ulcscseries Thin}\\
\textelcsc{Abc ExtraLight} {\elcscseries ExtraLight}\\
\textlcsc{Abc Light} {\lcscseries Light}\\
\textmcsc{Abc Medium} {\mcscseries Medium}\\
\textsbcsc{Abc SemiBold} {\sbcscseries SemiBold}\\
\textbcsc{Abc Bold} {\bcscseries Bold}\\
\textebcsc{Abc ExtraBold} {\ebcscseries ExtraBold}\\
\textxbcsc{Abc Black} {\xbcscseries Black}\\%
\end{tabular}

\vskip1em
\begin{tabular}{c}
Normal Small Caps  Italic\\
\hline\ \\
\textulsci{Abc Thin} {\ulsciseries Thin}\\
\textelsci{Abc ExtraLight} {\elsciseries ExtraLight}\\
\textlsci{Abc Light} {\lsciseries Light}\\
\textmsci{Abc Medium} {\msciseries Medium}\\
\textsbsci{Abc SemiBold} {\sbsciseries SemiBold}\\
\textbsci{Abc Bold} {\bsciseries Bold}\\
\textebsci{Abc ExtraBold} {\ebsciseries ExtraBold}\\
\textxbsci{Abc Black} {\xbsciseries Black}\\%
\end{tabular}
\begin{tabular}{c}
Condensed Small Caps Italic\\
\hline\ \\
\textulcsci{Abc Thin} {\ulcsciseries Thin}\\
\textelcsci{Abc ExtraLight} {\elcsciseries ExtraLight}\\
\textlcsci{Abc Light} {\lcsciseries Light}\\
\textmcsci{Abc Medium} {\mcsciseries Medium}\\
\textsbcsci{Abc SemiBold} {\sbcsciseries SemiBold}\\
\textbcsci{Abc Bold} {\bcsciseries Bold}\\
\textebcsci{Abc ExtraBold} {\ebcsciseries ExtraBold}\\
\textxbcsci{Abc Black} {\xbcsciseries Black}\\%
\end{tabular}




\end{document}

(a fair amount of work, but straightforward enough using concatenate in a spreadsheet)

the question is, for ease of use, how should all these commands be (systematically/verbosely) named? Is there a more powerful and/or compact way of accessing these, by indices perhaps? It is almost like thinking of names for colours.

And then, independently of what could be called the visuality bundle of dimensions, another dimension related to fonts is script(s).

FreeSerif, for example, has italic Georgian, Armenian, Cyrillic, but not the smallcaps.

FreeSerif

scripts sample 1

scripts sample 2

The days of bf and sc are long gone.

=====

Edited to add:

Actually, perhaps not.

For those who "run and type" (use of short commands), a cumulative bf-like sc-like mechanism (using font switches) can be achieved with a toggling-macro wrapper which groups the states of each font feature into sets and ratchets through the elements in the set with a stepcounter.

Cycling can be done with whatever can be grouped into sets: boldness, italics, small caps, size, font families.

font toggling

(no italics in this monospaced font)

It's easy to lose track of where you are, though, when not 'in the zone', and adding font size to the wrapper mix reveals that TeX is doing additional things behind the scenes across font families when sizes are allocated.

A reverse-ratchet, to cycle through the elements in reverse gear, is easy enough to implement, although for two-state toggles its results are identical to the forward ratchet.

MWE

\documentclass[12pt]{article}

\usepackage{fontspec}%splits itshape and scshape apart as independent shapes
\setmainfont{Noto Serif}%for small caps
\setsansfont{Noto Sans}
\setmonofont{Noto Sans Mono}    %no italic

%namespace is fx

%reset to initial state
\newcommand\fxbfreset{\fxboldinit}
\newcommand\fxitreset{\fxitalinit}
\newcommand\fxscreset{\fxscapinit}
\newcommand\fxszreset{\fxsetdefaultsize}
\newcommand\fxfmreset{\fxfmlyinit}
\newcommand\fxresetall{%
\fxbfreset%
\fxitreset%
\fxscreset%
\fxszreset%
\fxfmreset%
}


% For the element states in a closed set,
% toggle-step incrementally along each element
% and start at the beginning again, Kekule-like,

%-----------------------------------------------------
% bold
% start and end range: two states (say)
\newcounter{fxboldmax}
\setcounter{fxboldmax}{2}
\newcommand\fxboldstart{1}
% counter
\newcounter{fxboldtoggle}
\newcommand\fxboldinit{%
\setcounter{fxboldtoggle}{\fxboldstart}}
%init
\fxboldinit
% define stepnames
\expandafter\newcommand\csname fxboldstep1\endcsname{\mdseries}
\expandafter\newcommand\csname fxboldstep2\endcsname{\bfseries}
% toggle cycle
\newcommand\fxboldstep{%
%increment
\stepcounter{fxboldtoggle}%
%%cycle
\ifnum\value{fxboldtoggle} >\value{fxboldmax}\fxboldinit\fi%
%apply step
\ifcase\value{fxboldtoggle}\relax%
\relax%0
\or\csname fxboldstep\thefxboldtoggle\endcsname%1
\or\csname fxboldstep\thefxboldtoggle\endcsname%2
\else\fxboldinit%
\fi%
%\thefxboldtoggle
}

\newcommand\fxbf{\fxboldstep}


%-----------------------------------------------------
%italic
% start and end range
\newcounter{fxitalmax}
\setcounter{fxitalmax}{2}
\newcommand\fxitalstart{1}
% counter
\newcounter{fxitaltoggle}
\newcommand\fxitalinit{%
\setcounter{fxitaltoggle}{\fxitalstart}}
%init
\fxitalinit
% define stepnames
\expandafter\newcommand\csname fxitalstep1\endcsname{\upshape}
\expandafter\newcommand\csname fxitalstep2\endcsname{\itshape}
% toggle cycle
\newcommand\fxitalstep{%
%increment
\stepcounter{fxitaltoggle}%
%%cycle
\ifnum\value{fxitaltoggle} >\value{fxitalmax}\fxitalinit\fi%
%apply step
\ifcase\value{fxitaltoggle}\relax%
\relax%0
\or\csname fxitalstep\thefxitaltoggle\endcsname%1
\or\csname fxitalstep\thefxitaltoggle\endcsname%2
\else\fxitalinit%
\fi%
%\thefxitaltoggle
}

\newcommand\fxit{\fxitalstep}



%-----------------------------------------------------
%small caps
% start and end range
\newcounter{fxscapmax}
\setcounter{fxscapmax}{2}
\newcommand\fxscapstart{1}
% counter
\newcounter{fxscaptoggle}
\newcommand\fxscapinit{%
\setcounter{fxscaptoggle}{\fxscapstart}}
%init
\fxscapinit
% define stepnames
\expandafter\newcommand\csname fxscapstep1\endcsname{\upshape}
\expandafter\newcommand\csname fxscapstep2\endcsname{\scshape}
% toggle cycle
\newcommand\fxscapstep{%
%increment
\stepcounter{fxscaptoggle}%
%%cycle
\ifnum\value{fxscaptoggle} >\value{fxscapmax}\fxscapinit\fi%
%apply step
\ifcase\value{fxscaptoggle}\relax%
\relax%0
\or\csname fxscapstep\thefxscaptoggle\endcsname%1
\or\csname fxscapstep\thefxscaptoggle\endcsname%2
\else\fxscapinit%
\fi%
%\thefxscaptoggle
}

\newcommand\fxsc{\fxscapstep}





%-----------------------------------------------------
%size
% start and end range
\newcounter{fxsizemax}
\setcounter{fxsizemax}{10}
\newcommand\fxsizestart{1}
\newcommand\fxsizedefault{4}
% counter
\newcounter{fxsizetoggle}
\newcommand\fxsizeinit{%
\setcounter{fxsizetoggle}{\fxsizestart}}
% define stepnames
\expandafter\newcommand\csname fxsizestep1\endcsname{\tiny}
\expandafter\newcommand\csname fxsizestep2\endcsname{\scriptsize}
\expandafter\newcommand\csname fxsizestep3\endcsname{\footnotesize}
\expandafter\newcommand\csname fxsizestep4\endcsname{\small}
\expandafter\newcommand\csname fxsizestep5\endcsname{\normalsize}
\expandafter\newcommand\csname fxsizestep6\endcsname{\large}
\expandafter\newcommand\csname fxsizestep7\endcsname{\Large}
\expandafter\newcommand\csname fxsizestep8\endcsname{\LARGE}
\expandafter\newcommand\csname fxsizestep9\endcsname{\huge}
\expandafter\newcommand\csname fxsizestep10\endcsname{\Huge}
% toggle cycle
\newcommand\fxsizestep{%
%increment
\stepcounter{fxsizetoggle}%
%%cycle
\ifnum\value{fxsizetoggle} >\value{fxsizemax}\fxsizeinit\fi%
%apply step
\ifcase\value{fxsizetoggle}\relax%
\relax%0
\or\csname fxsizestep\thefxsizetoggle\endcsname%1
\or\csname fxsizestep\thefxsizetoggle\endcsname%2
\or\csname fxsizestep\thefxsizetoggle\endcsname%3
\or\csname fxsizestep\thefxsizetoggle\endcsname%4
\or\csname fxsizestep\thefxsizetoggle\endcsname%5
\or\csname fxsizestep\thefxsizetoggle\endcsname%6
\or\csname fxsizestep\thefxsizetoggle\endcsname%7
\or\csname fxsizestep\thefxsizetoggle\endcsname%8
\or\csname fxsizestep\thefxsizetoggle\endcsname%9
\or\csname fxsizestep\thefxsizetoggle\endcsname%10
\else\fxsizeinit%
\fi%
%\thefxsizetoggle
}
\newcommand\fxsetdefaultsize{%
\setcounter{fxsizetoggle}{\fxsizedefault}%
\fxsizestep%
}
%init
%\fxsizeinit
\fxsetdefaultsize

\newcommand\fxsz{\fxsizestep}




%-----------------------------------------------------
%family = fmly
% start and end range
\newcounter{fxfmlymax}
\setcounter{fxfmlymax}{3}
\newcommand\fxfmlystart{1}
\newcommand\fxfmlydefault{1}
% counter
\newcounter{fxfmlytoggle}
\newcommand\fxfmlyinit{%
\setcounter{fxfmlytoggle}{\fxfmlystart}}
\newcommand\fxsetdefaultfmly{%
\setcounter{fxfmlytoggle}{\fxfmlydefault}}
%init
\fxfmlyinit
%\fxsetdefaultfmly
% define stepnames
\expandafter\newcommand\csname fxfmlystep1\endcsname{\rmfamily}
\expandafter\newcommand\csname fxfmlystep2\endcsname{\sffamily}
\expandafter\newcommand\csname fxfmlystep3\endcsname{\ttfamily}
% toggle cycle
\newcommand\fxfmlystep{%
%increment
\stepcounter{fxfmlytoggle}%
%%cycle
\ifnum\value{fxfmlytoggle} >\value{fxfmlymax}\fxfmlyinit\fi%
%apply step
\ifcase\value{fxfmlytoggle}\relax%
\relax%0
\or\csname fxfmlystep\thefxfmlytoggle\endcsname%1
\or\csname fxfmlystep\thefxfmlytoggle\endcsname%2
\or\csname fxfmlystep\thefxfmlytoggle\endcsname%3
\else\fxfmlyinit%
\fi%
%\thefxfmlytoggle
}

\newcommand\fxfm{\fxfmlystep}







%========================================
\begin{document}

\section{Example}
\subsection{Three families, normal}
\indent Normal text serif
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf 
\begin{quotation}
\noindent
\fxsz Bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxszreset back to normal size.
\end{quotation}

\fxfm\fxsz
Normal text sans-serif
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf
\begin{quotation}
\noindent
\fxszreset\fxsz Bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxszreset\fxsz back to normal size.
\end{quotation}

\fxfm\fxsz
Normal text monospaced
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf
\begin{quotation}
\noindent
\fxszreset\fxsz Bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxsz bigger, \fxszreset\fxsz back to normal size.
\end{quotation}

\fxfm

\subsection{Three families, small caps}
\fxszreset\fxsz 
\fxsc
Normal text serif
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf

\fxfm
Normal text sans-serif
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf

\fxfm
Normal text monospaced
\fxbf bold \fxbf
\fxit italic
\fxbf bold italic.\fxit\fxbf
\fxfm 
\fxsc

\fxresetall
Back to normal text.

\end{document}
5
  • If this is a question, you should ask a new question...
    – CarLaTeX
    Commented Sep 16, 2019 at 13:45
  • @CarLaTex, Perhaps it is more of a musing aloud. I do not know what direction to go in when naming elements of structures. It is still too vague for a focused question.
    – Cicada
    Commented Sep 16, 2019 at 13:59
  • 1
    I would recommend that you follow the conventions in the second edition of The LaTeX Companion and in Appendix A of The LaTeX Font Encoding Guide, in which weight and extent are part of the “series” (like bx for bold extended and sbc for semibold condensed) and italic small caps is the ic shape.
    – Davislor
    Commented Sep 16, 2019 at 15:52
  • 1
    You might also check out the fontaxes package.
    – Davislor
    Commented Sep 16, 2019 at 15:52
  • @Davislor, Very handy, both suggestions. I can see a multiplicity of axes developing, even dynamic user-definable sets and supersets. With toggles for the user, and tex implementing things behind the scenes like it does now with font names.
    – Cicada
    Commented Sep 17, 2019 at 13:29
2

In XeTeX or LuaLaTeX, you can enable \bfseries\scshape by loading a font that supports it, such as \usepackage{newcomputermodern}.

In PDFTeX, you can enable bold small caps in Computer Modern with CFR’s fix-cm package and the T1 encoding:

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{fix-cm}

\begin{document}
\textsc{Foo} \textsc{\textbf{bar}}
\end{document}

There are many fonts other than Computer Modern which have bold small caps, including Libertinus.

1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .