HPUX man pages für Kapitel 3w



fa - summary of fast alpha library routines DISCUSSION The fast alpha library, /usr/lib/libfa.a, provides high-performance alpha (textual) capabilities with graphics windows and bitmapped displays. Fast alpha assumes uniform width fonts and provides a row and column interface. Fast alpha also implements the concepts of a cursor and display enhancements. All fast alpha library calls require a gopen(3G) file descriptor that may be for a bitmapped display device or for a graphics window. Programs that call fast alpha routines must link in the fast alpha library (-lfa). In addition, programs that call fast alpha library routines must also link in the font manager (-lfontm) and Starbase (-lsb1 -lsb2) libraries. The header file /usr/include/fa.h contains structure and constant definitions used by fast alpha library routines. Programs should attempt to use these definitions when calling fast alpha library routines. Fast alpha library routines are summarized below. For more information on each routine, consult its reference page. faclear(3w) Clear a window area specified by a fa_rectangle structure, defined in fa.h. facolors(3w) Set the font foreground and background colors for the currently activated fast alpha font. facursor(3w) Position and enable/disable the fast alpha cursor. fafontactivate(3w) Activate a fast alpha font. fafontload(3w) Load a font file into the font cache and activate it. fafontremove(3w) Remove a font from the font cache. fagetinfo(3w) Get information about the current fast alpha environment. Return this information in an fainfo structure, defined in fa.h. fainit(3w) Prepare a fast alpha window for output; set the window's fast alpha environment to default values. Hewlett-Packard Company - 1 - HP-UX Release 9.0: August 1992 fa(3w) fa(3w) farectwrite(3w) Fill an area of a window, defined by an fa_rectangle structure from fa.h, with a character. faroll(3w) Roll (scroll) a portion of a window. The area to roll is defined by an fa_rectangle structure from fa.h. fasetinfo(3w) Set information about the fast alpha environment. Information is set from an fainfo structure, defined in fa.h. faterminate(3w) Terminate the current fast alpha environment, which was initialized via fainit(3w). fawrite(3w) Write characters in the active font. EXAMPLES The following example compiles a program, named fawinprog.c, that calls fast alpha routines to display text in graphics windows. The program will run on a Series 300 high-resolution display using retained graphics windows (thus the -ldd300h and -lddbyte options). cc fawinprog.c -lfa -lfontm -ldd300h -lddbyte -lwindow -lsb1 -lsb2 SEE ALSO windows(1),fontm(3w),gopen(3G),window(3w). Hewlett-Packard Company - 2 - HP-UX Release 9.0: August 1992

faclear - clear the window area specified by the given rectangle

facolors - set the fast alpha font foreground and background colors

facursor - control the displayed cursor

fafontactivate - activate a fast alpha font

fafontload - load a font into the user's font cache and prepare it for activation

fafontremove - remove a font from the user's font cache

fagetinfo - get information about the fast alpha environment

fainit - prepare a fast alpha window device for output, and set up all defaults

farectwrite - fill an area of the window with the specified character

faroll - roll a portion of the window

fasetinfo - set information about the fast alpha environment

faterminate - terminate the current fast alpha environment

fawrite - write a line of characters with their enhancements

fm_activate - make a font active

fm_clipflag - set clipping flag

fm_cliplim - set clip limits

fm_colors - set active font's foreground and background colors

fm_fileinfo - return the size of cells in a font file

fm_fontdir - set character direction

fm_getname - translate font id to filename

fm_load - load a font into memory

fm_opt - optimize character generation if possible

fm_rasterinfo - return the size of cells in a font

fm_remove - remove a font

fm_sixteen_bit - set sixteen bit flag

fm_str_len - determine the pixel length of a character string

fm_styleinf : fm_styleinto - return style information about a font

fm_write - write characters to the screen

fontm - summary of font manager library routines DISCUSSION The font manager library, /usr/lib/libfontm.a, provides a high- performance alpha (textual) interface to graphics windows and bitmapped displays. The font manager can handle different sizes of fonts and provides an x,y pixel interface (as opposed to the row and column interface of fast alpha). All font manager library calls require a file descriptor from gopen(3G) which may be that of a bitmapped display device or of a graphics window. Programs that call font manager routines must link in the font manager (-lfontm) and Starbase (-lsb1 -lsb2) libraries. The header file /usr/include/fonticon.h contains type and constant definitions used by font manager routines. Programs should use these definitions when calling font manager library routines. Font manager library routines are summarized below. For more information on each routine, consult its reference page. fm_activate(3w) Make a loaded font the active font. fm_clipflag(3w) Set clipping flag. This enables or disables the ability to write outside a window's boundaries. fm_cliplim(3w) Set the clip limits; that is, define the area of a window in which clipping pertains. fm_colors(3w) Set the active font's foreground and background colors. fm_fileinfo(3w) Given the path name of a font file, this routine returns size information (i.e., pixel width, height, and baseline) about the font's character cells. fm_fontdir(3w) Set the direction for writing characters. fm_getname(3w) Return the path name of the font's definition file. fm_load(3w) Load a font file into memory and activate it. fm_opt(3w) Optimize character generation if possible. Hewlett-Packard Company - 1 - HP-UX Release 9.0: August 1992 fontm(3w) fontm(3w) fm_rasterinfo(3w) This routine returns size information (i.e., pixel width, height, and baseline) about the font's character cells. fm_remove(3w) Remove a font from memory. Once a font is removed from memory, it must be reloaded, via fm_load(3w), before it can be used again. fm_str_len(3w) Return the pixel length of a character string. The length is determined from the font size of the active font. fm_styleinfo(3w) Return style information about a font. This information is returned in an escapecodes structure, as defined in /usr/include/fonticon.h. fm_write(3w) Use the active font to display characters. EXAMPLES The following example compiles a program, named fontmprog.c, that calls font manager routines to display text in graphics windows. The program will run on a Series 300 low-resolution display using retained windows (thus the -ldd300l and -lddbyte options). cc fontmprog.c -lfontm -ldd300l -lddbyte -lwindow -lsb1 -lsb2 SEE ALSO windows(1),fa(3w),gopen(3G),window(3w). Hewlett-Packard Company - 2 - HP-UX Release 9.0: August 1992