NAME

PostScript::FontInfo - module to fetch data from PostScript font .inf files

SYNOPSIS

my $info = new PostScript::FontInfo (filename, options);
print STDOUT ("Name = ", $info->name, "\n");

DESCRIPTION

This package allows font info files, so called .inf files, to be read and (partly) parsed.

CONSTRUCTOR

new ( FILENAME [ , OPTIONS ] )

The constructor will read the file and parse its contents.

OPTIONS

error => [ 'die' | 'warn' | 'ignore' ]

DEPRECATED. Please use 'eval { ... }' to intercept errors.

How errors must be handled. Default is to call die(). In any case, new() returns a undefined result. Setting 'error' to 'ignore' may cause surprising results.

verbose => value

Prints verbose info if value is true.

trace => value

Prints tracing info if value is true.

debug => value

Prints debugging info if value is true. Implies 'trace' and 'verbose'.

INSTANCE METHODS

Each of these methods can return undef if the corresponding information could not be found in the file.

FileName

The name of the file, e.g. 'tir_____.inf'.

FontName

The name of the font, e.g. 'Times-Roman'.

FullName

The full name of the font, e.g. 'Times Roman'.

FontFamily

The family name of the font, e.g. 'Times'.

Version

The version of the font, e.g. '001.007'.

PCFileNamePrefix

The prefix used to form MS-DOS compliant file names, e.g. 'tir__'.

InfoData

The complete contents of the file, normalised to Unix-style line endings.

AUTHOR

Johan Vromans, Squirrel Consultancy <jvromans@squirrel.nl>

COPYRIGHT and DISCLAIMER

This program is Copyright 2003,1998 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.