1

The question arose eversince I learnt about \textbf{} and I couldn't quite spot any differences against \bf.

Lambert
  • 13

1 Answers1

5

\bf has not been defined by default since LaTeX2e was introduced in 1993. Some classes may define it for compatibility with old documents but that can not be assumed.

enter image description here

\documentclass{minimal}

\begin{document}

this \textbf{that}

\end{document}

But

\documentclass{minimal}

\begin{document}

this {\bf that}

\end{document}

produces the error

! Undefined control sequence.
l.5 this {\bf
              that}
? 

Even when it is defined, the behaviour is not the same as \textbf as it ignores the current font settings:

Note that that is not italic here, but \textbf gives bold italic in an italic context.

enter image description here

\documentclass{article}

\begin{document}

\itshape

this {\bf that} \textbf{the other}

\end{document}

David Carlisle
  • 757,742