home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Fresh Fonts 1
/
freshfonts1.bin
/
programs
/
amiga
/
pastex
/
macros
/
latex2e
/
base
/
tracefnt.sty
< prev
next >
Wrap
Text File
|
1994-06-12
|
9KB
|
266 lines
%%
%% This is file `tracefnt.sty', generated
%% on <1994/6/12> with the docstrip utility (2.2h).
%%
%% The original source files were:
%%
%% tracefnt.dtx (with options: `package,trace')
%%
%% Copyright 1994 the LaTeX3 project and the individual authors.
%% All rights reserved. For further copyright information see the file
%% legal.txt, and any other copyright indicated in this file.
%%
%% This file is part of the LaTeX2e system.
%% ----------------------------------------
%%
%% This system is distributed in the hope that it will be useful,
%% but WITHOUT ANY WARRANTY; without even the implied warranty of
%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
%%
%%
%% IMPORTANT NOTICE:
%%
%% For error reports in case of UNCHANGED versions see bugs.txt.
%%
%% Please do not request updates from us directly. Distribution is
%% done through Mail-Servers and TeX organizations.
%%
%% You are not allowed to change this file.
%%
%% You are allowed to distribute this file under the condition that
%% it is distributed together with all files mentioned in manifest.txt.
%%
%% If you receive only some of these files from someone, complain!
%%
%% You are NOT ALLOWED to distribute this file alone. You are NOT
%% ALLOWED to take money for the distribution or use of either this
%% file or a changed version, except for a nominal charge for copying
%% etc.
%%% File: tracefnt
\def\filename{tracefnt}
\def\fileversion{v2.3k}
\def\filedate{1994/05/29}
\def\docdate {1994/01/17}
%% Copyright (C) 1989-94 by Frank Mittelbach and Rainer Sch\"opf.
%% Copyright (C) 1994 by LaTeX3 project. All rights reserved.
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{tracefnt}[\filedate\space\fileversion\space
Standard LaTeX package (font tracing)]
\newcount\tracingfonts
\tracingfonts=0
\def\@font@warning#1{%
\GenericWarning{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Warning: #1}%
}
\def\@font@info#1{%
\GenericInfo{(Font)\@spaces\@spaces\space\@spaces\space}%
{LaTeX Font Info: \space\space\space#1}%
}
\DeclareOption{errorshow}{%
\def\@font@info##1{%
\GenericInfo{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Info: \space\space\space##1}}%
\def\@font@warning##1{%
\GenericInfo{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Warning: ##1}}%
}
\DeclareOption{warningshow}{%
\def\@font@info##1{%
\GenericInfo{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Info: \space\space\space##1}}%
\def\@font@warning##1{%
\GenericWarning{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Warning: ##1}}%
}
\DeclareOption{infoshow}{%
\def\@font@info##1{%
\GenericWarning{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Info: \space\space\space##1}}%
\def\@font@warning##1{%
\GenericWarning{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Warning: ##1}}%
}
\DeclareOption{loading}{%
\tracingfonts\tw@
}
\DeclareOption{debugshow}{%
\ExecuteOptions{infoshow}%
\tracingfonts\thr@@
}
\DeclareOption{pausing}{%
\def\@font@warning##1{%
\GenericError
{(Font)\@spaces\@spaces\@spaces\space\space}%
{LaTeX Font Warning: ##1}%
{See the LaTeX Companion for details.}%
{I'll stop for every LaTeX Font Warning because
you requested\\the `pausing' option
to the tracefnt package.}}%
}
\ExecuteOptions{infoshow}
\ProcessOptions
\def\extract@font{%
\get@external@font
\global\expandafter\font\font@name\external@font\relax
\ifnum \tracingfonts >\@ne
\@font@info{External font `\external@font'
loaded as\MessageBreak \font@name}\fi
\font@name \relax
\csname \f@encoding+\f@family\endcsname
\csname\curr@fontshape\endcsname
\relax
}
\DeclareRobustCommand\selectfont
{%
\ifx\f@linespread\baselinestretch \else
\set@fontsize\baselinestretch\f@size\f@baselineskip \fi
\xdef\font@name{%
\csname\curr@fontshape/\f@size\endcsname}%
\pickup@font
\font@name
\ifnum \tracingfonts>\tw@
\@font@info{Switching to \font@name}\fi
\size@update
\enc@update
}
\def\set@fontsize#1#2#3{%
\@defaultunits\@tempdimb#2pt\relax\@nnil
\edef\f@size{\strip@pt\@tempdimb}%
\@defaultunits\@tempskipa#3pt\relax\@nnil
\edef\f@baselineskip{\the\@tempskipa}%
\edef\f@linespread{#1}%
\let\baselinestretch\f@linespread
\def\size@update{%
\baselineskip\f@baselineskip\relax
\baselineskip\f@linespread\baselineskip
\normalbaselineskip\baselineskip
\setbox\strutbox\hbox{%
\vrule\@height.7\baselineskip
\@depth.3\baselineskip
\@width\z@}%
\the\every@size
\ifnum \tracingfonts>\tw@
\ifx\f@linespread\@empty
\let\@tempa\@empty
\else
\def\@tempa{\f@linespread x}%
\fi
\@font@info{Changing size to \f@size/\@tempa
\f@baselineskip}%
\aftergroup\type@restoreinfo \fi
\let\size@update\relax}%
}
\let\size@update\relax
\def\type@restoreinfo{%
\ifx\f@linespread\@empty
\let\@tempa\@empty
\else
\def\@tempa{\f@linespread x}%
\fi
\@font@info{Restoring size to
\f@size/\@tempa\f@baselineskip}}
\def\glb@settings{\begingroup
\ifnum \tracingfonts>\tw@
\ifmath@fonts
\@font@info{Setting up math fonts for
\f@size/\f@baselineskip}\fi
\else
\@font@info{No math setup}\fi
\expandafter\ifx\csname S@\f@size\endcsname\relax
\calculate@math@sizes
\fi
\csname S@\f@size\endcsname
\ifmath@fonts
\escapechar\m@ne
\csname mv@\math@version \endcsname
\else
\math@fontstrue
\fi
\globaldefs\@ne
\math@fonts
\let \glb@currsize \f@size
\endgroup
\the\every@size
}
\def\check@mathfonts{%
\ifx \glb@currsize \f@size
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: no change \f@size\space
curr/global (\curr@math@size/\glb@currsize)}\fi
\else
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: setting up \f@size\space
curr/global (\curr@math@size/\glb@currsize)}\fi
\glb@settings
\if@inmath
\aftergroup\restglb@settings
\else
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: no resetting (not in math)}\fi
\fi
\fi
\let\curr@math@size\f@size
\@inmathtrue
}
\def\restglb@settings{%
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: restoring}\fi
\begingroup
\let\f@size\curr@math@size
\ifx\glb@currsize \f@size
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: ... already okay (\f@size)}\fi
\else
\ifnum \tracingfonts>\thr@@
\@font@info{*** MATH: ... to \f@size}\fi
\glb@settings
\fi
\endgroup
}
\def\use@mathgroup#1#2{\relax\ifmmode
\ifnum \tracingfonts>\tw@
\count@#2\relax
\@font@info{Using \noexpand\mathgroup
(\the\count@) #2}\fi
\math@bgroup
\expandafter\ifx\csname M@\f@encoding\endcsname#1\else
#1\fi
\mathgroup#2\relax
\expandafter\math@egroup\fi}%
\ifx\math@bgroup\begingroup
\def\math@egroup#1{#1\endgroup
\ifnum \tracingfonts>\tw@
\@font@info{Restoring \noexpand\mathgroup
(\ifnum\mathgroup=\m@ne default\else \the\mathgroup \fi)%
}\fi}
\fi
\def\getanddefine@fonts#1#2{%
\ifnum \tracingfonts>\tw@
\count@#1\relax
\@font@info{\noexpand\mathgroup (\the\count@) #1 :=\MessageBreak
\string#2 \tf@size/\sf@size/\ssf@size}\fi
\xdef\font@name{\csname \string#2/\tf@size\endcsname}%
\pickup@font \let\textfont@name\font@name
\xdef\font@name{\csname \string#2/\sf@size\endcsname}%
\pickup@font \let\scriptfont@name\font@name
\xdef\font@name{\csname \string#2/\ssf@size\endcsname}%
\pickup@font
\edef\math@font