% \iffalse
%
%% File `mathcomp.dtx'.
%% Copyright (C) 1996 Tilmann B{\"o}{\ss}.
%% Please mail suggestions, enhancements ... to the author.
%% Feel free to modify this file if required by your installation, but do
%% not distribute modified versions of this file under its original name.
%
% \fi

% ^^A  don't forget to update \mathcompversion + \mathcompdate below
\def\fileversion{0.1c}
\def\filedate{1996/10/09}

%
% \changes{0.1a}{1996/10/07}{first usable version}
% \changes{0.1b}{1996/10/08}{documentation added}
% \changes{0.1c}{1996/10/09}{better documentation}
%
% \CheckSum{26}
%
% \iffalse
%<*driver>
\def\mathcompversion{0.1c}	 %  version of this file, not of textcomp!
\def\mathcompdate{1996/10/09}	 %  date of this file, not of textcomp!
\def\textcomp{\textsf{textcomp}}
\def\mathcomp{\textsf{mathcomp}}
\def\TSone{\textsf{TS1}}
\documentclass{ltxdoc}
\usepackage{textcomp, mathcomp}
\RecordChanges
\setlength{\parindent}{0pt}
\setlength{\parskip}{3pt plus1pt minus1pt}
\begin{document}
 \title{The \mathcomp\ package for using Text Companion fonts in math
	mode
	\thanks{Preliminary version \mathcompversion}}
 \author{Tilmann B{\"o}{\ss}\\ \texttt{tilmann@physik.uni-wuerzburg.de}}
 \date{\mathcompdate}
 \maketitle
 \DocInput{mathcomp.dtx} \PrintChanges
\end{document}
%</driver>
% \fi
%
% \section{Purpose}
%
% It always bothered me that I had to write the unit `$\mu$m' with an italic
% `$\mu$'.
% There is a `\textmu' in the Text Companion (TC) fonts, and it's
% available in most of the font families, shapes and series.
% The \textcomp\ package provides access to the TC fonts from \LaTeXe.
% But I wanted to use some of these fonts in math mode, so I decided to write a
% package to achieve this goal.
%
% Most of the characters don't make sense in math mode or they are already
% present in the CM fonts.
% The useful ones are:
%
% \begin{center}
% \begin{tabular}{ll@{\qquad}ll}
% |$\tcohm$| & $\tcohm$ & |$\tcperthousand$| & $\tcperthousand$ \\
% |$\tccentigrade$| & $\tccentigrade$ & |$\tcpertenthousand$|
% & $\tcpertenthousand$ \\
% |$\tcmu$| & $\tcmu$ & |$\tcdigitoldstyle{0}$| & $\tcdigitoldstyle{0}$ \\
% |...| & $\ldots$ & |$\tcdigitoldstyle{9}$| & $\tcdigitoldstyle{9}$ \\
% \end{tabular}
% \end{center}
%
% The names for the symbols are the same as in the \textcomp\ package except
% that you have to type \texttt{\bslash tc\textit{symbol-name}} instead of
% \texttt{\bslash text\textit{symbol-name}}.
% Only the oldstyle digits are defined in another way, see section~\ref{s:code}.
% These fonts are available for math versions `normal' and `bold'.
% The fonts used are |TS1/cmr/m/n| for `normal' and |TS1/cmr/bx/n| for `bold'.
% The package is based on the \textcomp\
% package\footnote{Ver.~1.4, 1995/12/11} by Sebastian Rahtz.
% This package is required because I didn't want to declare the font encoding
% \TSone\ again.
%
% The \mathcomp\ package is preliminary because both the \TSone\ encoding and the
% \textcomp\ package might change in the future.
%
% \StopEventually{}
%
% \section{The code}\label{s:code}
%
% The code is quite simple, short and obvious so there is not much to say.
% The package is announced (but not too loudly):
%    \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{mathcomp}[\filedate\space\fileversion\space(TBo)]
%    \end{macrocode}
%
% The \textcomp\ package is loaded to define the \TSone\ encoding:
%    \begin{macrocode}
\RequirePackage{textcomp}
%    \end{macrocode}
%
% The new symbol font |TS1/cmr/m/n| is declared under the name \texttt{TC}.
% It is the default font for all math versions.
% For the math version `bold' |TS1/cmr/bx/n| is defined.
%    \begin{macrocode}
\DeclareSymbolFont{TC}{TS1}{cmr}{m}{n}
\SetSymbolFont{TC}{bold}{TS1}{cmr}{bx}{n}
%    \end{macrocode}
%
% The symbol alphabet for the oldstyle digits is declared:
%    \begin{macrocode}
\DeclareSymbolFontAlphabet{\tcdigitoldstyle}{TC}
%    \end{macrocode}
%
% Finally, the extra symbols are defined:
%    \begin{macrocode}
\DeclareMathSymbol{\tcohm}{\mathalpha}{TC}{'127}
\DeclareMathSymbol{\tcperthousand}{\mathalpha}{TC}{'207}
\DeclareMathSymbol{\tccentigrade}{\mathalpha}{TC}{'211}
\DeclareMathSymbol{\tcpertenthousand}{\mathalpha}{TC}{'230}
\DeclareMathSymbol{\tcmu}{\mathalpha}{TC}{'265}
%    \end{macrocode}
%
% \Finale
\endinput

