1Font::TTF::Dumper(3)  User Contributed Perl Documentation Font::TTF::Dumper(3)
2
3
4

NAME

6       Font::TTF::Dumper - Debug dump of a font datastructure, avoiding
7       recursion on ' PARENT'
8

SYNOPSIS

10           Font::TTF::Dumper;
11
12           # Print a table from the font structure:
13           print ttfdump($font->{$tag});
14
15           # Print font table with name
16           print ttfdump($font->{'head'}, 'head');
17
18           # Print one glyph's data:
19           print ttfdump($font->{'loca'}->read->{'glyphs'}[$gid], "glyph_$gid");
20

DESCRIPTION

22       Font::TTF data structures are trees created from hashes and arrays.
23       When trying to figure out how the structures work, sometimes it is
24       helpful to use Data::Dumper on them. However, many of the object
25       structures have ' PARENT' links that refer back to the object's parent,
26       which means that Data::Dumper ends up dumping the whole font no matter
27       what.
28
29       The purpose of this module is to do just one thing: invoke Data::Dumper
30       with a filter that skips over the ' PARENT' element of any hash.
31
32       To reduce output further, this module also skips over ' CACHE' elements
33       and any hash element whose value is a Font::TTF::Glyph or
34       Font::TTF::Font object.  (Really should make this configurable.)
35

See also

37       Font::TTF::Font
38
39
40
41perl v5.16.3                      2011-10-13              Font::TTF::Dumper(3)
Impressum