1Font::TTF::Coverage(3)User Contributed Perl DocumentationFont::TTF::Coverage(3)
2
3
4

NAME

6       Font::TTF::Coverage - Opentype coverage and class definition objects
7

DESCRIPTION

9       Coverage tables and class definition objects are virtually identical
10       concepts in OpenType. Their difference comes purely in their storage.
11       Therefore we can say that a coverage table is a class definition in
12       which the class definition for each glyph is the corresponding index in
13       the coverage table. The resulting data structure is that a Coverage ta‐
14       ble has the following fields:
15
16cover
17A boolean to indicate whether this table is a coverage table (TRUE) or a class
18definition (FALSE)
19
20val
21A hash of glyph ids against values (either coverage index or class value)
22
23fmt
24The storage format used is given here, but is recalculated when the table is
25written out.
26
27count
28A count of the elements in a coverage table for use with add. Each subsequent
29addition is added with the current count and increments the count.
30

METHODS

32       new($isCover [, vals])
33
34       Creates a new coverage table or class definition table, depending upon
35       the value of $isCover. if $isCover then vals may be a list of glyphs to
36       include in order.  If no $isCover, then vals is a hash of glyphs
37       against class values.
38
39       read($fh)
40
41       Reads the coverage/class table from the given file handle
42
43       out($fh, $state)
44
45       Writes the coverage/class table to the given file handle. If $state is
46       1 then the output string is returned rather than being output to a
47       filehandle.
48
49       $c->add($glyphid)
50
51       Adds a glyph id to the coverage table incrementing the count so that
52       each subsequent addition has the next sequential number. Returns the
53       index number of the glyphid added
54
55       $c->out_xml($context)
56
57       Outputs this coverage/class in XML
58

AUTHOR

60       Martin Hosken Martin_Hosken@sil.org. See Font::TTF::Font for copyright
61       and licensing.
62
63
64
65perl v5.8.8                       2005-06-14            Font::TTF::Coverage(3)
Impressum