Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
GpiDrawFrom (1.2)
◄Function Group► ◄Overview► ◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
#define INCL_GPISEGMENTS
BOOL GpiDrawFrom(hps, idFirstSegment, idLastSegment)
HPS hps; /* presentation-space handle */
LONG idFirstSegment; /* first chain segment to draw */
LONG idLastSegment; /* last chain segment to draw */
The GpiDrawFrom function draws one or more segments in the picture chain.
The function draws all chained and called segments between and including the
segments identified by the idFirstSegment and idLastSegment parameters.
Although idFirstSegment must identify an existing segment, idLastSegment
need not. If idLastSegment does not specify an existing segment, the
function draws to the end of the picture chain.
GpiDrawFrom draws the segments using the current draw controls (except
correlation control), as set by the GpiSetDrawControl function. The function
does not affect drawing modes or open segments. Also, GpiDrawFrom cannot be
used in an area, path, or element bracket.
Parameter Description
────────────────────────────────────────────────────────────────────────────
hps Identifies the presentation space.
idFirstSegment Specifies the identifier of the first segment to draw. This
parameter must be greater than zero.
idLastSegment Specifies the identifier of the last segment to draw. This
parameter must be greater than zero.
Return Value
The return value is GPI_OK if the function is successful or GPI_ERROR if an
error occurred.
Errors
Use the WinGetLastError function to retrieve the error value, which may be
one of the following:
PMERR_AREA_INCOMPLETE
PMERR_IMAGE_INCOMPLETE
PMERR_INV_HPS
PMERR_INV_MICROPS_FUNCTION
PMERR_INV_SEG_NAME
PMERR_PATH_INCOMPLETE
PMERR_PS_BUSY
PMERR_SEG_NOT_CHAINED
PMERR_SEG_NOT_FOUND
PMERR_STOP_DRAW_OCCURRED
Example
This example uses the GpiDrawFrom function to draw all segments in the
picture chain between and including the segments 1 and 4:
GpiDrawFrom(hps, 1L, 4L);
See Also
GpiCloseSegment, GpiDrawChain, GpiDrawDynamics, GpiDrawSegment,
GpiQuerySegmentNames, GpiSetDrawControl, WinGetLastError
♦