3

How can I select the typeface for all terms like Fire Prism and Rangers inside description environment across the document?

\documentclass[10pt, a5paper]{report}

\usepackage[left=12mm, top=18mm, right=12mm, bottom=24mm]{geometry}
\usepackage[]{geometry}
\usepackage{dirtytalk}
\usepackage{multicol}
\usepackage{enumitem}
\usepackage{soul}

\usepackage{raleway} % tlf
\usepackage{almendra} % osf
\usepackage[T1]{fontenc}

\setlist{leftmargin=*, nosep}

\begin{document}

\begin{description}
  \item[Fire Prism] This battle calls for massive firepower.
  \item[Rangers] We walk the path less travelled.
\end{description}

\end{document}
4
  • 3
    please provide a complete minimal document we can compile. it matters a lot which class you are using and whether you're loading any packages which affect lists, whether you're using the new template code or not etc. etc. Commented Nov 12 at 16:59
  • What font do you want? Without this information, it's guesswork. Commented Nov 12 at 17:22
  • @egreg Does it matter? I want the label to be Almendra bold and the description to be Raleway regular. Commented Nov 12 at 17:26
  • @MonsieurPierreDoune Of course it does… Commented Nov 12 at 17:37

2 Answers 2

2
  1. \usepackage{almendra} sets the default font to Almendra.
  2. \usepackage{raleway} sets the sans serif font to Raleway.

So your document is in Almendra, of course.

\documentclass[10pt, a5paper]{report}
\usepackage[left=12mm, top=18mm, right=12mm, bottom=24mm]{geometry}

\usepackage[T1]{fontenc}
\usepackage{raleway} % tlf
\usepackage{almendra} % osf

\setlist{
%  leftmargin=*,% makes no sense for all lists
  nosep,
}
\setlist[description]{font=\normalfont\bfseries}% Almendra in labels

\AtBeginEnvironment{description}{\sffamily}% Raleway in items

\begin{document}

This is normal text in Almendra.

\begin{description}
  \item[Fire Prism] This battle calls for massive firepower.
  \item[Rangers] We walk the path less travelled.
\end{description}

\end{document}

output

3

You can use the font=... option to change the font of the label. Here an example with labels in computer modern:

\documentclass[10pt, a5paper]{report}

\usepackage[left=12mm, top=18mm, right=12mm, bottom=24mm]{geometry}
\usepackage[]{geometry}
\usepackage{dirtytalk}
\usepackage{multicol}
\usepackage{enumitem}
\usepackage{soul}

\usepackage[default]{raleway} % tlf
\usepackage[T1]{fontenc}

\setlist{leftmargin=*, nosep}
\setlist[description]{font=\normalfont\fontfamily{Almndr-OsF}\selectfont\bfseries}

\begin{document}

\begin{description}
  \item[Fire Prism] This battle calls for massive firepower \textbf{test}.
  \item[Rangers] We walk the path less travelled.
\end{description}

\end{document}

enter image description here

2
  • This does not work as expected. I'd like the label to be Almendra bold and the rest to be Raleway regular. I cannot deduce from your answer how to change this. Moreover, it messes with any bold text inside description, it makes it regular. Is there no way to change the label's font precisely? Commented Nov 12 at 17:36
  • 1
    @MonsieurPierreDoune See my edited answer Commented Nov 12 at 17:39

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.