4

I have tried both of the following but the micro symbol is still incorrect since its serif whilst arev is a sans serif font:

\sisetup{detect-all}
\sisetup{math-micro={\usefont{T1}{phv}{m}{n}\text{\textmu}}}
\sisetup{text-micro={\usefont{T1}{phv}{m}{n}\text{\textmu}}}

enter image description here

1
  • Please tell us how you activate the arev font.
    – Mico
    Jun 4 at 15:40

1 Answer 1

5

This is a similar problem to micro-mu in Kurier font shows up as tcedilla, but with a different solution.

For mysterious reasons, Arev doesn't come with a suitable font description file for the TS1 encoding, notwithstanding that the fonts are available.

Also, the math-micro and text-micro options are no longer used.

Prepare a file named ts1fav.fd in the working directory:

\ProvidesFile{ts1fav.fd}[2004/09/07 scalable font definitions for TS1/fav.]

\expandafter\ifx\csname fvs@Scale\endcsname\relax
 \let\fvs@@Scale\@empty
\else
 \edef\fvs@@Scale{s*[\csname fvs@Scale\endcsname]}%
\fi

\DeclareFontFamily{TS1}{fav}{}

\DeclareFontShape{TS1}{fav}{b}{n}{
   <-> \fvs@@Scale fvsb8c
}{}

\DeclareFontShape{TS1}{fav}{b}{it}{
   <-> \fvs@@Scale fvsbo8c
}{}

\DeclareFontShape{TS1}{fav}{m}{n}{
   <-> \fvs@@Scale fvsr8c
}{}

\DeclareFontShape{TS1}{fav}{m}{it}{
   <-> \fvs@@Scale fvsro8c
}{}

\DeclareFontShape{TS1}{fav}{bx}{n}{<->ssub * fav/b/n}{}
\DeclareFontShape{TS1}{fav}{bx}{it}{<->ssub * fav/b/it}{}
\DeclareFontShape{TS1}{fav}{b}{sl}{<->ssub * fav/b/it}{}
\DeclareFontShape{TS1}{fav}{bx}{sl}{<->ssub * fav/b/it}{}
\DeclareFontShape{TS1}{fav}{m}{sl}{<->ssub * fav/m/it}{}

\endinput

Now you can modify your document into

\documentclass{article}
\usepackage{arevtext,arevmath}
\usepackage{siunitx}

\sisetup{
  detect-all, % not really needed for the solution
}

\DeclareSIPrefix{\micro}{%
  \text{%
    \fontencoding{TS1}\fontfamily{\familydefault}\upshape
    \symbol{"B5}%
  }%
}{-6}


\begin{document}

\qty{100}{\micro\meter}

$\qty{100}{\micro\meter}$

\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .