# Is it possible to disable old style numbers for specific cases?

Is there a way to disable old style numbering only for specific cases? Right now I have old style numbering enabled globally for my whole document via \usepackage[osf]{libertine}, but I want to disable it only for one block of text.

I am hoping there is a way to simply disable old style for that block of text (which has numbers scattered throughout it) rather than having to add \somecommand{123} for each number instance in the block of text.

-

Educated guess: enclose the text block in a group and switch to the fxl font.

\documentclass{article}

\usepackage[T1]{fontenc}
\usepackage[osf]{libertine}

\begin{document}

\Large

Some text 0123 with some \emph{456 numbers \textbf{789}} in between.

\begingroup
\usefont{T1}{fxl}{m}{n}\selectfont

Some text 0123 with some \emph{456 numbers \textbf{789}} in between.

\endgroup

Some text 0123 with some \emph{456 numbers \textbf{789}} in between.

\end{document}

-
This works; I'd probably just define a command \newcommand{\uprightnums}[1]{{\fontfamily{fxl}\selectfont #1}} and then use \uprightnums{123}. –  frabjous Jan 17 '11 at 18:40
Thanks! This is exactly what I was looking for. –  squidbear Jan 17 '11 at 19:05
This probably needs an update due to the new libertine version. –  mafp May 15 '13 at 15:25