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.
WinDrawBitmap (1.2)
◄Function Group► ◄Overview► ◄Changes► ◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
#define INCL_WINMESSAGEMGR
BOOL WinDrawBitmap(hpsDst, hbm, prclSrc, pptlDst, clrFore, clrBack, fs)
HPS hpsDst; /* handle of the destination presentation space */
HBITMAP hbm; /* handle of the bitmap */
PRECTL prclSrc; /* address of structure with rectangle coordinates */
PPOINTL pptlDst; /* address of structure with bitmap position */
LONG clrFore; /* color of the foreground */
LONG clrBack; /* color of the background */
USHORT fs; /* bitmap-drawing flags */
The WinDrawBitmap function draws a bitmap using the current image colors and
mixes.
Parameter Description
────────────────────────────────────────────────────────────────────────────
hpsDst Identifies the presentation space in which the bitmap is drawn.
hbm Identifies the bitmap.
prclSrc Points to the RECTL data structure that contains the coordinates
of the rectangle to be drawn. If this parameter is NULL, the
entire bitmap is drawn.
pptlDst Points to the position of the lower left of the bitmap in the
presentation space (in device coordinates).
clrFore Specifies the color of the foreground.
clrBack Specifies the color of the background.
fs Specifies the flags that determine how the bitmap is drawn. It
can be one of the following values:
Value Meaning
─────────────────────────────────────────────────────────────────
DBM_HALFTONE Use the OR operator to combine the bitmap with an
alternating pattern of ones and zeros before
drawing it. This flag can be used in conjunction
with either DBM_NORMAL or DBM_INVERT.
DBM_IMAGEATTRS The clrFore and clrBack parameters are ignored
and the image attribute colors already selected
in hpsDst are used instead.
DBM_INVERT Draw the bitmap inverted, using ROP_NOTSRCCOPY.
DBM_NORMAL Draw the bitmap normally, using ROP_SRCCOPY.
DBM_STRETCH The pptlDst parameter points to a RECTL data
structure, representing a rectangle in the
destination presentation space to which the
bitmap should be stretched.
Return Value
The return value is TRUE if the function is successful or FALSE if an error
occurs.
See Also
GpiCreateBitmap, GpiLoadBitmap, WinGetSysBitmap, RECTL
♦