Visit Our UNIX and Linux User Community

Linux and UNIX Man Pages

Test Your Knowledge in Computers #723
Difficulty: Medium
Niklaus Emil Wirth, an Austrian computer scientist, designed several programming languages, including Pascal,
True or False?
Linux & Unix Commands - Search Man Pages

glyphs(5) [bsd man page]

GLYPHS(5)							File Formats Manual							 GLYPHS(5)

NAME
glyphs - format of .glyphs files DESCRIPTION
Glyph files (``.glyph'' extension) are used to store commonly-used bit patterns (glyphs) for Magic. Right now, the bit patterns are used for two purposes in Magic. First, they specify patterns for programmable cursors: each cursor shape (e.g. the arrow used for the wiring tool) is read in as a glyph from a glyph file. Second, glyphs are used by the window manager to represent the icons displayed at the ends of scroll bars. Glyph file names normally have the extension .glyph. Glyph files are stored in ASCII format. Lines beginning with ``#'' are considered to be comments and are ignored. Blank lines are also ignored. The first non-comment line in a glyph file must have the syntax size nGlyphs width height The nGlyphs field must be a number giv- ing the total number of glyphs stored in the file. The width and height fields give the dimensions of each glyph in pixels. All glyphs in the same file must have the same size. The size line is followed by a description for each of the glyphs. Each glyph consists of height lines each containing 2xwidth characters. Each pair of characters corresponds to a bit position in the glyph, with the leftmost pair on the topmost line corresponding to the upper- left pixel in the glyph. The first character of each pair specifies the color to appear in that pixel. The color is represented as as a single character, which must be the short name of a display style in the current display style file. Some commonly-used characters are K for black, W for white, and . for the background color (when . is used in a cursor, it means that that pixel position is transparent: the underlying picture appears through the cursor). See ``Magic Maintainer's Manual #3: Display Styles, Color Maps, and Glyphs'' for more information. The second character of each pair is normally blank, except for one pixel per glyph which may contain a ``*'' in the second character. The ``*'' is used for programmable cursors to indicate the hot-spot: the pixel corresponding to the ``*'' is the one that the cursor is con- sidered to point to. For an example of a glyph file, see ~cad/lib/magic/sys/color.glyphs. SEE ALSO
magic(1), dstyle(5) 4th Berkeley Distribution GLYPHS(5)

Check Out this Related Man Page

Font::TTF::Loca(3)					User Contributed Perl Documentation					Font::TTF::Loca(3)

NAME
Font::TTF::Loca - the Locations table, which is intimately tied to the glyf table DESCRIPTION
The location table holds the directory of locations of each glyph within the glyf table. Due to this relationship and the unimportance of the actual locations when it comes to holding glyphs in memory, reading the location table results in the creation of glyph objects for each glyph and stores them here. So if you are looking for glyphs, do not look in the "glyf" table, look here instead. Things get complicated if you try to change the glyph list within the one table. The recommendation is to create another clean location object to replace this table in the font, ensuring that the old table is read first and to transfer or copy glyphs across from the read table to the new table. INSTANCE VARIABLES
The instance variables do not start with a space glyphs An array of glyph objects for each glyph. glyphtype A string containing the class name to create for each new glyph. If empty, defaults to Font::TTF::Glyph. METHODS
$t->new Creates a new location table making sure it has a glyphs array $t->read Reads the location table creating glyph objects (Font::TTF::Glyph) for each glyph allowing their later reading. $t->out($fh) Writes the location table out to $fh. Notice that not having read the location table implies that the glyf table has not been read either, so the numbers in the location table are still valid. Let's hope that "maxp/numGlyphs" and "head/indexToLocFmt" haven't changed otherwise we are in big trouble. The function uses the OUTLOC location in the glyph calculated when the glyf table was attempted to be output. $t->out_xml($context, $depth) No need to output a loca table, this is dynamically generated $t->glyphs_do(&func) Calls func for each glyph in this location table in numerical order: &func($glyph, $glyph_num) BUGS
None known AUTHOR
Martin Hosken Martin_Hosken@sil.org. See Font::TTF::Font for copyright and licensing. perl v5.16.3 2012-02-23 Font::TTF::Loca(3)

Featured Tech Videos