[tex-k] tfmload.c in dvips and xdvi
janl@linpro.no
janl@linpro.no
Mon, 14 May 2001 23:46:06 +0200
Hi,
The t1 font code in xdvi needed to load tfm files to aquire precise
charater widht information. I had a look around and found tfmload.c
in dvips. Based on that and my reading of various Knuthian writings
I wrote this snipped in tfmload.c in xdvik:
for (i = bc; i <= ec; i++)
if (chardat[i] != 256)
widths[i] = wtab[chardat[i]];
chardat is unsigned char. As a SunOS 4 cc pointed out this (the middle
line) makes no sense, it is always true (thanks to Stefan Ulrich for
noticing). In dvips analogous code is found (tfmload.c also):
for (i=0; i<256; i++)
if (chardat[i]!= 256) {
li = scaled[chardat[i]] ;
Persuing dvicopy.web I've been unable to find the documentation for
this. Is there a better place? Does anyone have a ready answer?
Nicolai