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

NAME

6       Font::TTF::Loca - the Locations table, which is intimately tied to the
7       glyf table
8

DESCRIPTION

10       The location table holds the directory of locations of each glyph
11       within the glyf table. Due to this relationship and the unimportance of
12       the actual locations when it comes to holding glyphs in memory, reading
13       the location table results in the creation of glyph objects for each
14       glyph and stores them here.  So if you are looking for glyphs, don't
15       look in the "glyf" table, look here instead.
16
17       Things get complicated if you try to change the glyph list within the
18       one table.  The recommendation is to create another clean location
19       object to replace this table in the font, ensuring that the old table
20       is read first and to transfer or copy glyphs across from the read table
21       to the new table.
22

INSTANCE VARIABLES

24       The instance variables do not start with a space
25
26       glyphs
27           An array of glyph objects for each glyph.
28
29       glyphtype
30           A string containing the class name to create for each new glyph. If
31           empty, defaults to Font::TTF::Glyph.
32

METHODS

34       $t->new
35
36       Creates a new location table making sure it has a glyphs array
37
38       $t->read
39
40       Reads the location table creating glyph objects (Font::TTF::Glyph) for
41       each glyph allowing their later reading.
42
43       $t->out($fh)
44
45       Writes the location table out to $fh. Notice that not having read the
46       location table implies that the glyf table has not been read either, so
47       the numbers in the location table are still valid. Let's hope that
48       "maxp/numGlyphs" and "head/indexToLocFmt" haven't changed otherwise we
49       are in big trouble.
50
51       The function uses the OUTLOC location in the glyph calculated when the
52       glyf table was attempted to be output.
53
54       $t->out_xml($context, $depth)
55
56       No need to output a loca table, this is dynamically generated
57
58       $t->glyphs_do(&func)
59
60       Calls func for each glyph in this location table in numerical order:
61
62           &func($glyph, $glyph_num)
63

BUGS

65       None known
66

AUTHOR

68       Martin Hosken Martin_Hosken@sil.org. See Font::TTF::Font for copyright
69       and licensing.
70
71
72
73perl v5.8.8                       2005-06-14                Font::TTF::Loca(3)
Impressum