The PAINTFILL structure holds information used to fill an area.
typedef struct _PAINTFILL
{
L_INT nSize;
L_UINT32 dwMask;
PAINTFILLSTYLE nStyle;
COLORREF crSolidFillColor;
pBITMAPHANDLE pBackgroundTileBitmap;
PAINTFILLGRADIENTSTYLE nGradientStyle;
COLORREF crGradientStartColor;
COLORREF crGradientEndColor;
L_UINT uGradientSteps;
COLORREF crUpperTolerance;
COLORREF crLowerTolerance;
L_INT nOpacity;
pBITMAPHANDLE pTexture;
} PAINTFILL, *pPAINTFILL;
Size of this structure.
Flags that indicate which structure members contain valid information. Possible values are:
Value | Meaning |
---|---|
PFF_ALL | All the fields contain valid data. |
PFF_STYLE | The nStyle field contains valid data. |
PFF_SOLIDFILLCOLOR | The crSolidFillColor field contains valid data. |
PFF_BACKGROUNDTILEBITMAP | The pBackgroundTileBitmap field contains valid data. |
PFF_GRADIENTSTYLE | The nGradientStyle field contains valid data. |
PFF_GRADIENTSTARTCOLOR | The crGradientStartColor field contains valid data. |
PFF_GRADIENTENDCOLOR | The crGradientEndColor field contains valid data. |
PFF_GRADIENTSTEPS | The uGradientSteps field contains valid data. |
PFF_UPPERTOLERANCE | The crUpperTolerance field contains valid data. |
PFF_LOWERTOLERANCE | The crLowerTolerance field contains valid data. |
PFF_OPACITY | The nOpacity field contains valid data. |
PFF_TEXTURE | The pTexture field contains valid data. |
The values can be combined using the bit-wise OR operator ( | )
An enumerated type that indicates the fill style. For a list of possible values, refer to PAINTFILLSTYLE.
COLORREF value that specifies the color to use when nStyle is PAINT_FILL_STYLE_SOLID.
Pointer to the bitmap handle referencing the bitmap to be used for filling, when nStyle is PAINT_FILL_STYLE_TILEDIMAGE. The BITMAPHANDLE pointer, should still be valid after setting this field.
An enumerated type that indicates the background gradient fill style. For a list of possible values, refer to PAINTFILLGRADIENTSTYLE.
The COLORREF value that specifies the color to use as the starting color for the gradient fill.
The COLORREF value that specifies the color to use as the ending color for the gradient fill.
Number of gradient fill steps. Valid values are 2 to 255.
COLORREF value that contains the amount of upper variance allowed from the selected color. Valid values are between 0 and 255.
COLORREF value that contains the amount of lower variance allowed from the selected color. Valid values are between 0 and 255.
Value indicating the transparency of the fill when combined with the painting canvas. Valid values are 0 to 255. A color or an image with an opacity of 255 is transparent. A color or an image with an opacity of 0 is completely opaque (solid).
Pointer to the bitmap handle referencing the bitmap that will simulate paper texture. This gives the appearance of painting on paper having that texture. The BITMAPHANDLE pointer, should still be valid after setting this field.
The default values for this structure are:
nSize = sizeof (PAINTFILL)
nStyle = PAINT_FILL_STYLE_SOLID
crSolidFillColor = RGB (255, 255, 255)
pBackgroundTileBitmap = NULL
nGradientStyle = PAINT_FILL_GRADIENT_STYLE_RECTANGLE_TO_C
nGradientStartColor = RGB (0, 0, 0)
nGradientEndColor = RGB (255, 255, 255)
uGradientSteps = 255
crUpperTolerance = RGB (0, 0, 0)
crLowerTolerance = RGB (0, 0, 0)
nOpacity = 0
pTexture = NULL
pPAINTFILL is a pointer to a PAINTFILL structure.