::pix::paintTop, Main, Index
Enum PaintKind:Top, Main, Index
- SolidPaint
- ImagePaint
- TiledImagePaint
- LinearGradientPaint
- RadialGradientPaint
- AngularGradientPaint
CommandsTop, Main, Index
configure [::pix::paint]Top, Main, Index
Configures the parameters of a paint object.
configure paint options
Parameters
paint | paint object handle |
options | A Tcl list of key-value pairs (see supported options below). |
Description
| image | img object handle. |
| imageMat | 3x3 transformation matrix (list of 9 numbers). |
| color | Color string. |
| blendMode | Enum value (BlendMode). |
| opacity | Double value (0 to 1). |
| gradientHandlePositions | List coordinates {{x y} {x y}}. |
| gradientStops | List of color stops {{color offset} {color1 offset1}}. |
Return value
Nothing.
copy [::pix::paint]Top, Main, Index
Creates a copy of the specified paint object.
copy paint
Parameters
paint | paint object handle |
Return value
A new copied type paint object.
destroy [::pix::paint]Top, Main, Index
Destroy the paint or all paints if special word all is specified.
destroy value
Parameters
value | paint object or string. |
Return value
Nothing.
fillGradient [::pix::paint]Top, Main, Index
Fills an entire image using the gradient settings of the paint object.
fillGradient paint image
Parameters
paint | paint object handle |
image | img object handle |
Return value
Nothing.
get [::pix::paint]Top, Main, Index
Gets the parameters of a paint object.
get paint
Parameters
paint | paint object handle |
Description
The dictionary includes the keys of paint::configure, plus kind:
| kind | Enum value (PaintKind). |
| blendMode | Enum value (BlendMode). |
| opacity | Double value (0 to 1). |
| color | Color string, rgba(r, g, b, a). |
| image | img object handle, or an empty string. |
| imageMat | 3x3 transformation matrix (list of 9 numbers). |
| gradientHandlePositions | List coordinates {{x y} {x y}}. |
| gradientStops | List of color stops {{color offset} {color1 offset1}}. |
Return value
A Tcl dictionary object.
new [::pix::paint]Top, Main, Index
Creates and returns a new paint object.
new paintKind
Parameters
paintKind | Enum value (PaintKind) |
Return value
A new handle paint object.