[Dev-luatex] T1 encoding

Taco Hoekwater taco at elvenkind.com
Mon Jul 28 12:39:32 CEST 2008



Javier Bezos wrote:
> Below is my first attempt, which reencodes a T1 font to
> Unicode (still a hack for testing). Accents are misplaced
> and there is an error:
> 
>   Error in processing VF font (ptmr8t.vf): invalid
>   character code, virtual font will be ignored
> 
> but I have no idea what's wrong. At least, kerns and
> ligatures seem to be right. (With 0.29 for Windows.)

You are copying the value of f.type into u.type before returning
the table (in the the for loop) so the font is never registered
as 'virtual' and consequently luatex tries to do vf resolving
on its own. But because you have already reencoded the base font,
the values in the vf no longer make sense.

This is harmless for the 'type', but bad for 'encodingbytes'.
You should move

 >   u.encodingbytes = 2
 >   u.type = 'virtual'

to the end of the tounicode function

Best wishes,
Taco


More information about the dev-luatex mailing list