DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: T f

⟦e139de4ee⟧ TextFile

    Length: 5777 (0x1691)
    Types: TextFile
    Names: »fontbl.tex«

Derivation

└─⟦52210d11f⟧ Bits:30007239 EUUGD2: TeX 3 1992-12
    └─⟦63303ae94⟧ »unix3.14/TeX3.14.tar.Z« 
        └─⟦c58930e5c⟧ 
            └─⟦this⟧ »TeX3.14/TeXcontrib/uw/fontbl.tex« 

TextFile

% The essential parts of this macro appeared in {\it TUGboat, Volume 3, No. 1}
% in the note: "DISPLAY OF A FONT IN TABLE FORM." by Roger L. Beeman.
% This version was rewritten by Pierre A. MacKay to take advantage of
% the new features of \TeX82.  It is now interactive, and prompts the
% user for a font name.  If the font is a text font, a sample paragraph
% is set, which is justified to three times the lower-case alphabet length
% if that will fit in the overall \hsize.  (If the font is a fixed-width
% font such as "amtt", the sample is set with a ragged right margin.)
% The sample is leaded 20% over the stated point-size, so that a
% 10-point font is set 10 on 12.  The length of both upper and lower
% case alphabets is given, along with the height and depth of the
% lower case alphabet and the height of the upper case alphabet.  These
% last dimensions can be very useful for calculating the size of
% close-fitting boxes and struts.
%
% And modified for 256 char fonts, and converted to hexadecimal notation
% by Tom Ridgeway, 1989.  I haven't thought of anything clever to
% do about printing out samples of the extra characters . . .
%
% Non-text fonts are displayed in table form only.
%
% If you have \TeX\ running with "plain.tex" loaded,
% you can start this macro by typing "tex fontbl" and you will be prompted
% for the rest
%
\baselineskip 0pt \lineskip 0pt
\vsize 8.5truein
\font\sl=cmr10
\sl
\newcount\bighand\newcount\littlehand
\bighand=\time\divide\bighand by 60
\littlehand=\bighand\multiply\littlehand by -60
\advance\littlehand by\time
\def\makedateline{\line{{\sl \fontname scaled magstep \step\hskip1in
  \the\bighand:\ifnum\littlehand<10{0}\fi
  \the\littlehand\ - \the\month/\the\day/\the\year\hfil}}}

\output{\shipout\vbox{\hrule width1em\vskip 1ex
\makedateline\vskip1em\box255\vskip1em
\hrule width1em}\global\advance\count0 by 1}

\newdimen\maxwide
\dimendef\vu=\maxwide
\setbox 9\hbox{\sl 0}

\def\spike{\hbox to 0pt{\vbox to 1\ht9{}}}
\def\cell#1{\hbox to \vu{\hfill\char"#1\hfill}\vrule}
\def\label#1{\vbox to 1\ht8{\vfill
  \hbox to 35pt{\hfill\sl '#10\hskip1em}\vfill}\vrule}

\def\seprow{\def\m{\hskip \vu{}\vrule height 2pt}\hbox{\m\m\m\m\m\m\m\m\m\m\m\m\m\m\m\m}}
\def\cellrow#1{\setbox 8\vbox{\seprow\hbox{\spike\ignorespaces
	       \cell{#10}\cell{#11}\cell{#12}\cell{#13}\ignorespaces
	       \cell{#14}\cell{#15}\cell{#16}\cell{#17}\ignorespaces
	       \cell{#18}\cell{#19}\cell{#1A}\cell{#1B}\ignorespaces
	       \cell{#1C}\cell{#1D}\cell{#1E}\cell{#1F}\ignorespaces
	       \hfill}\seprow\hrule}\hbox{\label{#1}\box8}}

\def\lcol#1{\hbox to \vu{\hfill{\sl #1}\hfill}\hskip .4pt}
\def\chw#1{\hbox{\char"#1}}

\def\colw#1{\vbox{\chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
                  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}
		  \chw{#1}}}

\def\setw#1{\vbox{\colw{#10}
		  \colw{#11}
		  \colw{#12}
		  \colw{#13}
		  \colw{#14}
		  \colw{#15}
		  \colw{#16}
		  \colw{#17}
                  \colw{#18}
		  \colw{#19}
		  \colw{#1A}
		  \colw{#1B}
		  \colw{#1C}
		  \colw{#1D}
		  \colw{#1E}
		  \colw{#1F}}}
\def\getw{\setbox 0\vbox{\setw0\setw1\hbox to 1\wd9{}
	  \hbox to 1em{}}\vu=1.625\wd0}

\def\table#1{\font\tablefont=#1 scaled \scale
\tablefont\getw\null\vfil
\hbox to 6in{\hfil\ignorespaces
\vbox{\ifdim\fontdimen2\tablefont>0pt \hbox{\hskip35pt \fontname \hfil} \fi
      \vskip10pt
      \hbox{\hskip35pt\lcol0\lcol1\lcol2\lcol3\lcol4\lcol5\lcol6\lcol7\ignorespaces
                       \lcol8\lcol9\lcol A\lcol B\lcol C\lcol D\lcol E\lcol F}
      \vskip 4 pt
      \hbox{\hskip35pt\vbox{\hrule width 16\vu}\vbox{\hrule width 7.2pt}}
      \cellrow{0}\cellrow{1}\cellrow{2}\cellrow{3}
      \cellrow{4}\cellrow{5}\cellrow{6}\cellrow{7}
      \cellrow{8}\cellrow{9}\cellrow{A}\cellrow{B}
      \cellrow{C}\cellrow{D}\cellrow{E}\cellrow{F}}\ignorespaces
\hss}}
\def\tblraggedright{\rightskip0pt plus5em}

\global\def\test{}
\global\def\fin{END }
\global\def\lcfin{end }
\global\def\halfstep{half }
\def\\{$\backslash$}
\def\doit{
\baselineskip 0pt \lineskip 0pt
\message{Type a valid font name, or type END to quit :}
\read16 to\fontname
\ifx\fontname\lcfin\let\test=\fin\else\global\let\test=\fontname\fi
\ifx \fin\test \relax
\else \message{Scaled to what magstep? (half, or 0..5):}
\read16 to\step
\ifx \halfstep\step \global\def\scale{1095 } \else
  \global\def\scale{\ifcase\step 1000\or
    1200\or 1440\or 1728\or 2074\or 2488\fi\relax}
  \fi
\message{Graphing font \fontname}
       \table{\fontname}
\rightskip 0pt % So that one ragged right font doesn't affect all
%    following fonts
\vskip 1em
\ifdim\fontdimen2\tablefont>0pt
  \setbox8=\hbox{abcdefghijklmnopqrstuvwxyz}
  \setbox7=\hbox{ABCDEFGHIJKLMNOPQRSTUVWXYZ}
  \global\dimen8=1\wd8\global\dimen7=.5\hsize
  \global\dimen5=1\ht8\global\dimen4=1\dp8\global\dimen3=1\ht7
  \edef\length{\the\dimen8}
  \global\dimen6=\dimen8\global\multiply\dimen6 by 3
  \ifdim\dimen6>\hsize \global\dimen6=\hsize \fi
  \ifdim\fontdimen3\tablefont=0pt \tblraggedright
     \global\advance\dimen6 by -40pt \fi
  \vskip 1em
  \noindent
  \ifdim\dimen8<\dimen6
    \line{\unhbox8\hfil }
    \vskip 1ex \fi
  \centerline{{\rm Alphabet length \length. Quad is \the\fontdimen6\tablefont}}
  \vskip .25em
  \centerline{{\rm Lower case height is \the\dimen5 ; depth is \the\dimen4}}
    \vskip 1em
    \global\dimen8=1\wd7 \edef\length{\the\dimen8}
    \noindent
  \ifdim\dimen8<\dimen6
    \line{\unhbox7 \hfil}
    \vskip 1ex  \fi
    \centerline{{\rm Alphabet length \length ; height \the\dimen3}}
  \vskip 1em \vfil
  \vbox{\hsize \dimen6
  \baselineskip 1.2em
  \parskip .15em
  \lineskip .2em
}
\fi

\vfill\penalty-10000

\doit
\fi
}

\doit
\bye