Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ fm_fileinfo(3G) — HP-UX ANSI C A.10.11

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

fm_rasterinfo(3G)

fm_load(3G)

fm_fileinfo(3G)

NAME

fm_fileinfo − return the size of cells in a font file

SYNOPSIS

int fm_fileinfo ( path, width, height, baseline );
char *path;
int *width,*height,*baseline;

DESCRIPTION

path is the path name to the font file. 

Gidth width of 1-byte character cells in the font. 

height height of character cells in the font. 

baseline baseline of character cells in the font; distance from the bottom of the character cell to the bottom of a typical character image which does not have a descender. 

DISCUSSION

For the designated font file, the width, height and baseline for the character cells are returned. The returned cell width is the cell width of the 1-byte characters, even if the designated font is a HP-15 (2-byte) character font that includes 1- and 2-byte characters.  2-byte characters are twice as wide as the returned width.  The baseline is also returned for the 1-byte character cell, regardless of whether a character is one or two bytes, and the baseline of the 2-byte characters is equal to the descender line of 1/2-byte characters. 

For proportional fonts, width and height are the maximums, respectively, of the widths and heights of the character cells in the font file. The baseline is sometimes useful for lining up characters in different-sized fonts. 

This library call is useful for determining what size to create a window that will contain fixed text. 

SEE ALSO

fm_rasterinfo(3G), fm_load(3G). 

DIAGNOSTICS

A −1 is returned if path does not designate a font file; otherwise, 0 is returned.  See errno(2) in HP-UX Reference for more information. 

Hewlett-Packard Company  —  HP-UX Release 10.0

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026