# Using MinionPro Tabular Figures in Tables and Proportional Figures in text

I am trying to use MinionPro tabular figures in tables because they look much better than proportional figures. However, I would like to keep proportional figures in text. This is the configuration that I use:

\usepackage[lf,opticals]{MinionPro}      % Minion Pro
\usepackage[toc,eqno,enum,bib,lineno]{tabfigures} % Tabular figures
\usepackage{etoolbox}                    % For \AtBeginEnvironment for tabular figures

\AtBeginEnvironment{tabular}{%
\figureversion{lf,tab}
}


I see that when I use siunitx inside a table, it seems to ignore the command \figureversion because proportional figures are used in place of tabular ones.

This is the configuration of siunitx:

\sisetup{detect-weight=true, detect-family=true, detect-mode=true} % Make siunitx detect font-face and weight


When numbers are put outside the siunitx environment (either by using an S column or \SI{somenumber}{someunit}), tabular figures are correctly used.

Where might the problem be?

UPDATE: I just provide a picture and the correspondent LaTeX code, for simplicity. The second column, in the picture, displays how tabular figures should look like. In the first column tabular and proportional figures are compared and the third column shows that the S column ignores completely the \figureversion{lf,tab} command.

\documentclass[english]{article}

\usepackage[lf,opticals]{MinionPro}      % Minion Pro
\usepackage[toc,eqno,enum,bib,lineno]{tabfigures} % Tabular figures
\usepackage{etoolbox}                    % For \AtBeginEnvironment for tabular figures
\usepackage{babel}
\usepackage{graphicx}
\usepackage{siunitx}

\AtBeginEnvironment{tabular}{%
\figureversion{lf,tab}
}

\sisetup{detect-weight=true, detect-family=true, detect-mode=true} % Make siunitx detect font-face and weight

\begin{document}

\begin{table}[!htp]
\centering
\begin{tabular}{|l|l|S|}
\hline
\SI{1.11}{\volt} & 1.11 & 1.11 \\
1.11 V           & 4.44 & 4.44 \\
23.44            & 45.4 & 45.4 \\
\hline
\end{tabular}
\caption{A simple table}
\end{table}

\end{document}


As you said, siunitx does not detect your figure selection. However, you can explicitly tell siunitx which figure version to use with

\sisetup{text-rm={\figureversion{tab,lf}}}


Obviously, in your example, add this line to \AtBeginEnvironment{tabular}. Thus, the following should do the trick:

\documentclass[english]{article}

\usepackage[lf,opticals]{MinionPro}      % Minion Pro
\usepackage[toc,eqno,enum,bib,lineno]{tabfigures} % Tabular figures
\usepackage{etoolbox}                    % For \AtBeginEnvironment for tabular figures
\usepackage{babel}
\usepackage{graphicx}
\usepackage{siunitx}

\AtBeginEnvironment{tabular}{%
\figureversion{lf,tab}
\sisetup{text-rm={\figureversion{tab,lf}}}
}

\sisetup{detect-weight=true, detect-family=true, detect-mode=true} % Make siunitx detect font-face and weight

\begin{document}

\begin{table}[!htp]
\centering
\begin{tabular}{|l|l|S|}
\hline
\SI{1.11}{\volt} & 1.11 & 1.11 \\
1.11 V           & 4.44 & 4.44 \\
23.44            & 45.4 & 45.4 \\
\hline
\end{tabular}
\caption{A simple table}
\end{table}

\end{document}