Write {\bf\it x} in LaTeX and you do not get bold italic — you get italic. Swap the order to {\it\bf x} and the italic disappears instead, leaving upright bold. The old two-letter commands simply refuse to add up, and the reason is a single word on line 493 of article.cls. Read that line and you understand, in one move, why modern LaTeX ships every font switch in two forms. This page lays out how those commands sit on three independent axes — family, series and shape, when to reach for the argument-taking \textbf{...} versus the scoped declaration \bfseries, and what the log is telling you when you ask for bold small caps and ordinary bold comes out instead. With measurements throughout.
The difference between \textbf{...} and \bfseries
Every switch comes in two forms. The command form, beginning with \text…, takes an argument and affects only what is inside its braces. The declaration form, ending in …family / …series / …shape, takes no argument and stays in force from that point to the end of the enclosing group or environment. The choice follows the length of the span: a few words call for \textbf{just this}, a whole paragraph or environment for {\bfseries …} or \begin{quote}\itshape …\end{quote}. Forget to wrap a declaration in a group and it keeps going to the end of the document, so check the { and } pairing. Declarations are also what class and package code prefers, because they add nothing of their own and leave the scoping to the caller.
% command form: for a short span
This is \textbf{bold} and this is \textit{italic}.
% declaration form: a group limits the scope
Normal here. {\bfseries Bold from here on.} Back to normal.
% declaration applied to a whole environment
\begin{quote}
\itshape The whole quotation is set in italic.
\end{quote}Beyond scope, the two forms differ in one practical way: the command form inserts the italic correction for you and the declaration form does not. A slanted glyph overhangs up and to the right, but its typesetting width does not include that overhang, so an upright letter following it collides. Measured, \textit{f}h comes to 10.74167pt and {\itshape f}h to 8.62222pt: the whole 2.11945pt difference is missing space. With a declaration you write the trailing \/ yourself — {\itshape f\/}h measures 10.74167pt, matching the command form exactly. What that correction actually is, the emphasis page covers in detail.
Family, series, shape: the three axes that pick a font
A font in LaTeX2e is the combination of three mutually independent attributes: family is the underlying letterform, series is weight together with width, and shape is the slant or form. Switch one axis and the other two are untouched — that orthogonality is the heart of the design, and it is why “bold but still sans-serif” and “italic but still bold” are straightforward to write. The scheme arrived as NFSS (New Font Selection Scheme) in 1989, reached release 2 in 1993, and shipped as standard with LaTeX2e in 1994; the earlier LaTeX 2.09 had no notion of font attributes at all. It is worth remembering that series is one axis covering both weight and width. That is why the bold of Computer Modern is written bx — bold extended, heavy and wide.
- Family — roman, i.e. serif,
\textrm/\rmfamily; sans-serif\textsf/\sffamily; typewriter, i.e. monospaced,\texttt/\ttfamily. - Series — medium, the default weight,
\textmd/\mdseries; bold\textbf/\bfseries. The attribute value is a string of up to two letters combining weight and width:m(medium),b(bold),bx(bold extended),c(condensed) and so on. - Shape — upright, the default,
\textup/\upshape; italic\textit/\itshape; slanted\textsl/\slshape; small capitals\textsc/\scshape. The attribute values aren,it,slandscrespectively. - Italic and slanted are not the same thing.
\itshapecalls up a separately drawn typeface —cmti10in Computer Modern — while\slshapecalls up the upright face mechanically sloped (cmsl10). The letterforms themselves differ; the italica, for instance, is single-storey.
| Key | Axis and effect | Command form (short span) | Declaration form (scoped by a group) |
|---|---|---|---|
roman | Family: roman (serif) | \textrm{...} | {\rmfamily ...} |
sans | Family: sans-serif | \textsf{...} | {\sffamily ...} |
typewriter | Family: typewriter (monospaced) | \texttt{...} | {\ttfamily ...} |
bold | Series: bold (attribute bx and friends) | \textbf{...} | {\bfseries ...} |
medium | Series: medium (the default, attribute m) | \textmd{...} | {\mdseries ...} |
italic | Shape: italic (attribute it) | \textit{...} | {\itshape ...} |
slanted | Shape: slanted (attribute sl) | \textsl{...} | {\slshape ...} |
small caps | Shape: small capitals (attribute sc) | \textsc{...} | {\scshape ...} |
upright | Shape: back to upright (attribute n) | \textup{...} | {\upshape ...} |
reset all | Reset all three axes to the document default | \textnormal{...} | {\normalfont ...} |
Applying bold and italic at the same time
Write \textbf{\textit{...}} and you get bold italic. The order does not matter, and with declarations you simply list them: {\bfseries\itshape ...}. Because the axes are independent, the second switch never erases the first. Measured, inside \textbf{\textit{Y}} the series stays bx and only the shape becomes it, so Computer Modern's bold italic cmbxti10 is loaded. Use all three axes and \textsf{\textbf{\textit{...}}} gives bold sans-serif italic. But being able to write a combination is not the same as the font having it: when the requested face does not exist, LaTeX substitutes something close — which is the subject of the next section.
% nest the command forms
\textsf{\textbf{\textit{Bold sans-serif italic}}}
% or list the declarations in one group (equivalent)
{\sffamily\bfseries\itshape Bold sans-serif italic\/}
% one word back to the document default inside a sans-serif run
{\sffamily A heading-like line with one \textnormal{normal} word}To reset all three axes to the document default at once, use \textnormal{...} (command form) or \normalfont (declaration form) — handy when a sans-serif heading needs one word in the ordinary text font. To reset a single axis, call the command that names that axis's default: \rmfamily, \mdseries, \upshape. Worth knowing in passing: lines 11158 to 11170 of latex.ltx are a run of \DeclareTextFontCommand calls, so every \text… listed here is manufactured mechanically from its corresponding declaration. The same run also defines \textulc (back to upper and lower case) and \textsw (swash), though very few fonts actually carry those shapes.
Why \bf and \it refuse to combine
Because \bf has a \normalfont inside its definition. Lines 490 to 496 of article.cls list the old two-letter commands like this: \DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}, \DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}, and the same pattern for \rm, \sf, \tt, \sl and \sc. So \bf does not mean “make this bold” but “reset all three axes to the default, then make this bold”. Typeset {\bf\it x} and the \normalfont hidden inside \it throws away the \bfseries that came before it: measured, the series drops from bx back to m and only the shape it survives. In the reverse order, {\it\bf x}, the shape returns to n and only the series bx survives. Mixing old with new behaves identically: \textbf{\tt x} ends up with family cmtt but series back at m, silently discarding the \textbf.
% the old two-letter commands do not stack
{\bf\it x} % italic only -- the bold is thrown away
{\it\bf x} % upright bold -- the italic is thrown away
\textbf{\tt x} % typewriter, medium weight -- \textbf silently lost
% the modern commands do stack
{\bfseries\itshape x}
\textbf{\ttfamily x}This non-orthogonality is not a defect but a faithful preservation of the LaTeX 2.09 font model from before 1994, where “the current font” was a single name rather than a set of attributes, so every switch was a wholesale replacement. LaTeX2e introduced the stackable per-axis commands in 1994 and kept the old ones through \DeclareOldFontCommand as a compatibility layer that keeps existing documents building. They still work today without error — and that is exactly the problem: someone who writes {\bf\it important} means bold italic and will not find out otherwise until they look at the PDF. Note also that the third argument of \DeclareOldFontCommand is the math-mode meaning, so \bf behaves as \mathbf inside a formula. A command that means one thing in text and another in math is one more reason to avoid it. In new code, always use the \textbf / \bfseries family.
When the log says Font shape ... undefined
That is not a typo report; it says the font has no type for the combination you asked for. The classic case is bold small capitals: Computer Modern in the default OT1 encoding has no face that is both bx and sc. Typeset \textsc{\textbf{...}} and you get the paired lines shown in the log below — a Font shape line and a using ... instead line. LaTeX does not stop with an error; it drops the small capitals and carries on in ordinary bold. So the first you learn of it is when the PDF does not show the small capitals you asked for. For the same reason \textsw{...} warns that OT1/cmr/m/sw is undefined.
LaTeX Font Warning: Font shape `OT1/cmr/bx/sc' undefined
(Font) using `OT1/cmr/bx/n' instead on input line 8.
LaTeX Font Warning: Some font shapes were not available, defaults substituted.For this particular warning there is a one-line fix: add \usepackage[T1]{fontenc}. The T1-encoded Computer Modern (the EC fonts) does have bold small capitals, so the same \textsc{\textbf{...}} compiles without a warning; recompiling with [T1]{fontenc} loaded made the font warning disappear from the log entirely. T1 also improves the handling of accented letters and hyphenation in Western text, so it is a line most such documents end up wanting anyway. When the warning names some other combination, read the four-part name in the log — OT1/cmr/bx/sc, that is encoding / family / series / shape — and identify which axis is missing. Then decide: switch to a font that has it, simplify the request by one step, or accept the substitution — and write the decision down.
% OT1 Computer Modern has no bold small caps -> warning + silent fallback
% T1 (the EC fonts) does have it
\usepackage[T1]{fontenc}
\textsc{\textbf{Bold Small Capitals}}
% low-level NFSS: name the four attributes, then commit with \selectfont
{\fontfamily{cmr}\fontseries{bx}\fontshape{sc}\selectfont Explicit}As those last two lines show, a high-level command like \textbf expands internally into the low-level NFSS commands. \fontfamily{...}, \fontseries{...} and \fontshape{...} rewrite the attributes, and \selectfont actually selects a font from whatever the four attributes hold at that moment. Setting the attributes alone does nothing; the typeface does not change until \selectfont is called. You rarely need this layer directly, but it is what you reach for when you want to summon a particular face by name, or to check what the four-part name in a warning refers to. What the encoding means, and how to load real font files, belongs to the page on the font system.
Switching Japanese typefaces: mincho and gothic
In pLaTeX and upLaTeX, Japanese text has its own axes, and the family axis has two members: mincho \textmc / \mcfamily and gothic \textgt / \gtfamily. They are defined from line 1471 of plcore.ltx and switch \kanjifamily, an attribute that belongs to the Japanese side alone. What happens under \bfseries is the interesting part. Measured, the Japanese family stays mc (mincho) and only the series becomes bx. Line 25 of jy1mc.fd then reads \DeclareFontShape{JY1}{mc}{bx}{n}{<->ssub*gt/m/n}{}: a request for “bold mincho” is defined to be served by gothic at its normal weight. So “I made it bold and it came out gothic” is neither an accident nor a fallback — it is a substitution written explicitly into the font definition file, reflecting the tradition of marking Japanese emphasis by switching typeface rather than weight.
A working policy for manuscripts
Keep the font commands you write directly in the body to the ones that carry meaning. In a thesis or a technical document, the more you scatter font switches as little visual fixes, the harder the manuscript becomes to maintain. Rules like “headings are bold”, “captions are smaller”, “defined terms are consistently sans-serif” belong in the class, in a package, or in a semantic macro of your own, not in a \textbf typed out afresh each time. Put one layer in between — \newcommand{\term}[1]{\textsf{#1}} — and a change of policy is a one-line edit. Conversely, for things whose appearance is the meaning, such as the name of a button in an interface or a key on the keyboard, using \textsf or \texttt inline is perfectly fine. The test is simply whether the look is the goal or a stand-in for meaning.
- Leave emphasis to
\emph. Embedding a visual choice in the body means you can no longer change how emphasis looks later. - Use declarations for long spans. For a whole quotation or a marginal note, declare
\itshapeat the start of the environment and let the environment close the group. - Try combinations in a minimal file first. Typeset
\textsf{\textbf{...}}or\textsc{...}once in a short document and confirm the log has no font warning before scattering them through the manuscript. - Do not leave substitutions alone. Ignore the warnings and the same markup can look different from chapter to chapter. Change the font or simplify the request.
- Do not mix in the old two-letter commands. When you find
\bfor\itin a collaborative manuscript, replace them with\bfseries/\itshapeor\textbf/\textit. They may look like they work, but they do not combine.