LaTeX Tabular Column with specific font type

Problem:

You want to use a custom column type for your LaTeX tabular that has a specific font attribute (we’ll use the font family for this example).

Solution:

You can use the array package for this:

\usepackage{array}

You can now define a new column type using \newcolumntype. The array package is pretty powerful because you can insert arbitrary commands before and after a column type.

For example, to define a Typewriter font family centered column, you can use this:

\newcolumntype{T}{c<{\ttfamily}}

In this case, the new T column type equals the c (centered) column type but \ttfamily is inserted before any column.

You can substitute \ttfamily for any font attribute you like, e.g. \sffamily.

See the Wikibook on LaTeX fonts for further reference.

After defining the column type, you can use it just like any standard column type (e.g. c, l or r):

\begin{tabular}{T}
...
\end{tabular}