fasetinfo(3w)
NAME
fasetinfo − set information about the fast alpha environment
SYNOPSIS
#include <fa.h>
int fasetinfo(gfd,fainfoptr);
int gfd;
struct fainfo *fainfoptr;
DESCRIPTION
gfd is an integer file descriptor for a gopened device interface.
fainfoptr is a pointer to the structure defined as follows:
struct fainfo {
struct fa_rectangle size;
int capabilities;
int enhancements;
int defaultenhancements;
int cursor;
int fontcellheight;
int fontcellwidth;
int foregroundplanes;
int backgroundplanes;
int clearbeforewrite;
int colormode;
int makecurrent;
};
Descriptions of each field in this structure are:
size a structure with one corner set to [0, 0] and the other set to [number of columns, number of lines]. (See Fast Alpha Rectangles in the Fast Alpha/Font Manager Programmer’s Manual.)
This parameter cannot be set by fasetinfo. It is used to obtain information via fagetinfo.
capabilities an integer assigned a value from a list in the header file. The contents of capabilities may be used by a program to detect what additional capabilities are available on a particular device. Currently defined capabilities are:
FAWINDOW − Device is a window or bitmapped graphics device. More information may be obtained by calls to other window system routines.
This parameter cannot be set by fasetinfo. It is used to obtain information via fagetinfo.
enhancements is assigned to the bitwise ORing of the various enhancement bits (see farectwrite) which are supported by the particular device.
defaultenhancements is initially set to a value which optimizes the performance of the window system. It is used by fawrite and faroll. It is a read/write field in that it can be changed by calling fasetinfo.
cursor cursor is TRUE if the cursor may be physically removed from the window device and is FALSE otherwise.
This parameter cannot be set by fasetinfo. It is used to obtain information via fagetinfo.
fontcellheight, fontcellwidth indicates the size (in pixels) of the 1-byte character fontcell. The 2-byte characters are twice as wide.
This parameter cannot be set by fasetinfo. It is used to obtain information via fagetinfo.
clearbeforewrite is TRUE if the fast alpha library routine clears the background of the area to be written to before the characters are written. clearbeforewrite set to FALSE indicates that the user is responsible for clearing and desires no background clearing by the library routine. clearbeforewrite defaults to TRUE. clearbeforewrite currently pertains only to FACOLOR mode; see colormode, below.
foregroundplanes, backgroundplanes specifies the number of memory planes available for controlling the foreground and background colors respectively. A value of 1 in foregroundplanes and 1 in backgroundplanes indicates a monochrome system. Values > 1 indicate a color system.
This parameter cannot be set by fasetinfo. It is used to obtain information via fagetinfo.
colormode when set to FAWONB (white on black − which is the default) indicates that the user is not using the color options. This allows the fast alpha routines to run somewhat faster than when color is incorporated. When colormode is set to FACOLOR, the additional system operations needed to incorporate color are performed. A third option is to set colormode to FABONW (black on white) that inverses the previous monochromatic option, FAWONB; see facolors.
makecurrent setting this field to bitwise ORing of values specified in the header file (/usr/include/fa.h) controls the appearance of fast alpha operations on the screen. For performance reasons, the user may choose to suppress the updating of the screen until several operations are queued up. When updating is desired, the user signals the fast alpha environment to update the screen by setting the makecurrent value to MCALWAYS (make current always). Queued up operations will show up on the screen at this time. The default value is MCALWAYS, that is, update the screen upon every fast alpha operation.
DISCUSSION
This routine is used to set information regarding the window device, or to set new values in the fast alpha environment. Parameters which are user-settable include: defaultenhancements, clearbeforewrite, makecurrent, and colormode.
fasetinfo is the counterpart of fagetinfo. It is used for changing certain parameters of a fast alpha environment.
SEE ALSO
DIAGNOSTICS
A value of −1 is returned if gfd is invalid or a call to fainit was never executed on this gfd. See errno(2) for further information.
Hewlett-Packard Company — HP-UX Release 9.10: April 1995