Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Using KOMA-script I got a bold font for chapter/section titles. I had a unit, \SI{1}{\something}, in one of them which was not set in bold font. Giving siunitx the following options

detect-weight=true, detect-family=true

helped. Probably there are good reasons not to enable this by default. Which are they?

share|improve this question
add comment

2 Answers 2

up vote 12 down vote accepted

The aim of siunitx is to be a flexible and comprehensive units package which follows the 'standards' as far as possible when loaded. If you read up on the use of units, you'll find that quantities (the combination of a number and a unit) is a mathematical entity. As with other mathematics, things like font shape and weight are therefore important. With the default settings, the package uses the current upright roman font for everything: that's the same as any other mathematics:

\textbf{Bold text but $y = mx + c$}

However, some people prefer to follow some or all of the surrounding style, particularly in section headings. That's where the 'flexible' part comes in: you can do that using a package option without otherwise changing the input.

share|improve this answer
add comment

This is the choice of the package writer.

As written in the manual:

The siunitx package controls the font used to print output independently of the surrounding material. The standard method is to ignore the surroundings entirely, and to use the current body fonts.

To enable your choices by default, you just have to write these options in the preamble of your document, using \sisetup

\sisetup{detect-weight=true, detect-family=true}
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.