PostScript::Font::TTtoType42 - Wrap a TrueType font into PostScript Type42
use PostScript::Font::TTtoType42; # Open a TrueType font. my $font = PostScript::Font::TTtoType42::->new("Arial.ttf"); # Write a Type42 font. $font->write("Arial.t42"); # Get the font data (scalar ref). my $ptr = $font->as_string; # Get the font glyph names (array ref). my $gref = $font->glyphnames;
PostScript::Font::TTtoType42 is a subclass of Font::TTF::Font. It knows how to wrap a TrueType font into PostScript Type42 format.
- new(fontname [ atts ])
Opens the named TrueType font.
Returns the font data in Type42 format as reference to one single string. Newlines are embedded for readability.
Writes the font data in Type42 format to the named file.
Returns the font metrics in AFM format as a reference to a single string. Newlines are embedded for readability.
Writes the font metrics in AFM format to the named file.
Returns an array reference with the names of all the glyphs of the font, sorted alphabetically.
Certain TrueType fonts cause problems. If you find one, let me know.
CID fonts are not yet supported.
The specification of the Type 42 font format.
The True Type reference manual.
The specification of the Adobe font metrics file format. =back
Johan Vromans, Squirrel Consultancy <email@example.com>
This program is Copyright 2002 by Squirrel Consultancy. All rights reserved.
This program is free software; you can redistribute it and/or modify it under the terms of either: a) the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version, or b) the "Artistic License" which comes with Perl.
This program 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. See either the GNU General Public License or the Artistic License for more details.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 670:
You forgot a '=back' before '=head1'