1Font::TTF::OldCmap(3) User Contributed Perl DocumentationFont::TTF::OldCmap(3)
2
3
4
6 Font::TTF::OldCmap - Character map table
7
8 This module is deprecated
9
11 Looks after the character map. The primary structure used for handling
12 a cmap is the Font::TTF::Segarr which handles the segmented arrays of
13 format 4 tables, and in a simpler form for format 0 tables.
14
15 Due to the complexity of working with segmented arrays, most of the
16 handling of such arrays is via methods rather than via instance
17 variables.
18
19 One important feature of a format 4 table is that it always contains a
20 segment with a final address of 0xFFFF. If you are creating a table
21 from scratch this is important (although Font::TTF::Segarr can work
22 quite happily without it).
23
25 The instance variables listed here are not preceeded by a space due to
26 their emulating structural information in the font.
27
28 Num Number of subtables in this table
29
30 Tables
31 An array of subtables ([0..Num-1])
32
33 Each subtables also has its own instance variables which are, again,
34 not preceeded by a space.
35
36 Platform
37 The platform number for this subtable
38
39 Encoding
40 The encoding number for this subtable
41
42 Format
43 Gives the stored format of this subtable
44
45 Ver Gives the version (or language) information for this subtable
46
47 val This points to a Font::TTF::Segarr which contains the content of
48 the particular subtable.
49
51 $t->read
52 Reads the cmap into memory. Format 4 subtables read the whole subtable
53 and fill in the segmented array accordingly.
54
55 Format 2 subtables are not read at all.
56
57 $t->ms_lookup($uni)
58 Given a Unicode value in the MS table (Platform 3, Encoding 1) locates
59 that table and looks up the appropriate glyph number from it.
60
61 $t->find_ms
62 Finds the Microsoft Unicode table and sets the "mstable" instance
63 variable to it if found. Returns the table it finds.
64
65 $t->out($fh)
66 Writes out a cmap table to a filehandle. If it has not been read, then
67 just copies from input file to output
68
69 @map = $t->reverse([$num])
70 Returns a reverse map of the table of given number or the Microsoft
71 cmap. I.e. given a glyph gives the Unicode value for it.
72
74 ยท No support for format 2 tables (MBCS)
75
77 Martin Hosken Martin_Hosken@sil.org. See Font::TTF::Font for copyright
78 and licensing.
79
80
81
82perl v5.16.3 2012-02-23 Font::TTF::OldCmap(3)