I am planning on writing my document using opensans font and want to use the siunitx package. My minimal code is given below:
\documentclass[a4paper]{article}
\usepackage[T1]{fontenc}
\usepackage[default,oldstyle,scale=0.95]{opensans}
\usepackage[alsoload=synchem,%
range-phrase=--,%
repeatunits=false%
]{siunitx}
\sisetup{range-units=single}
\sisetup{separate-uncertainty}
\sisetup{detect-family}
\sisetup{detect-weight}
\sisetup{detect-all}
\begin{document}
The temperature measured was \SI{14(1)}{\kelvin} and was observed between time points \SIrange{34}{90}{\second}.
\SI{1.45(20)e-4}{\Molar}
There are 365 days in a year. And I want \SI{2.6(4)e3}{\hectare} land allocation.
\end{document}
As instructed in the siunitx manual (page 17 and 19), the \sisetup{detect-family} and/or \sisetup{detect-weight} and/or \sisetup{detect-all}
should make the numbers and units in the required font. But it does not. Any suggestions on how to fix this?
P.S: I have seen this: Math font changing and siunitx?, but I am not sure it directly solves my problem.
Font choice not respected in siunitx posts \sisetup{detect-all}
as the solution, but as you can see in my code, I have included it and it doesn't seem to work.
EDIT1: I use pdflatex and TexMaker as my frontend.