Fonts and styles\bf

\bfCommand

Changes the font of subsequent characters in the current group to bold.

x \bf y
Available in
base, textmacros
Kind
declarative
Allowed mode
math, text
Frequency
2.17% of corpus formulasrank 26 of 263
Commonality
high
Tags
presentation, discouraged
Renderer support
PackageMathJaxKaTeXXeTeX
baseMathJax: FullKaTeX: FullXeTeX: Full
textmacrosMathJax: FullKaTeX: FullXeTeX: Full
About the test scope

Syntax#

\bf

Takes no arguments. Same argspec in base and textmacros. Reading argspecs

Common tasks#

How to switch a short run into bold math#

{\bf ...} is a legacy switch; prefer \mathbf for new writing.

{\bf x} = {\bf A}{\bf v}

How to bold only one identifier#

{\bf F} = m{\bf a}

Examples#

base

{x \bf y} z

textmacros

\text{\bf x}

Package variants#

PackageSignatureAllowed modeNotes
basemathChanges the font of subsequent characters in the current group to bold.
textmacrostextLegacy declaration that switches following text to bold styling until the current group ends.

In TeXForm#

TeXForm parses this entry as declarative syntax; the package determines its argument specification.

Equivalent forms#

  • \textbf{...}approximate

    \textbf is a command with arguments, whereas \bf is declarative.

  • {\bfseries ...}exact

See also#

Test cases#

base
InputCaseMathJaxKaTeXXeTeX
{\bf a}Positive · baselinePassPassPass
textmacros
InputCaseMathJaxKaTeXXeTeX
{\bf a}Positive · baselinePassPassPass
All 80 in Fonts and styles