|
AIPaintStyleSuite Struct Reference
[API Suite List]
This suite provides functions to examine and operate on the Color and Gradient palettes, which display and modify the paint style of the current selection, and the Color Editor, which allows a user to choose and edit colors.
More...
#include <AIPaintStyle.h>
List of all members.
Public Attributes |
void ASAPI(* | SetStrokeActive )() |
| Causes the Color palette to show the stroke color (not fill).
|
ASBoolean ASAPI(* | IsStrokeActive )() |
| Reports whether the Color palette shows the stroke color (not fill).
|
void ASAPI(* | SetFillActive )() |
| Causes the Color palette to show the fill color (not stroke).
|
ASBoolean ASAPI(* | IsFillActive )() |
| Reports whether the Color palette shows the fill color (not stroke).
|
void ASAPI(* | SetDefaultFillStroke )() |
| Sets the fill and stroke states of the current selection to those of the default style (usually white for fill and solid 1-point black for stroke).
|
int ASAPI(* | GetActiveGradientStopIndex )() |
| Retrieves the index position of the selected stop the current gradient.
|
ASErr ASAPI(* | GetCurrentGradient )(AIColor *color) |
| Retrieves the gradient currently shown in the Gradient palette.
|
ASErr ASAPI(* | GetCurrentColor )(AIColor *color) |
| Retrieves the fill, stroke, or currently active gradient stop color currently shown in the Color palette.
|
ASErr ASAPI(* | ShowGradientDialog )() |
| Invokes the Gradient palette.
|
ASErr ASAPI(* | ShowColorDialog )() |
| Invokes the Color palette.
|
ASErr ASAPI(* | SetActiveColor )(AIColor *color, ASBoolean useGradientStop) |
| If caching is not active, applies a color to the selection, or to the active gradient stop.
|
ASErr ASAPI(* | BeginActiveColor )() |
| Starts caching for color application to proxies.
|
ASErr ASAPI(* | EndActiveColor )() |
| Finishes caching for color application to proxies.
|
ASBoolean ASAPI(* | IsCurrentColorStroke )() |
| Reports whether the current color in the Color palette is for a stroke or fill.
|
ASErr ASAPI(* | SetAIColor )(AIColor *color, AIColorMap *colorMap, ASBoolean isStroke) |
| If caching is not active, applies a stroke or fill color to the current selection, using a partial color specification.
|
ASErr ASAPI(* | SetCurrentGradient )(AIColor *color) |
| Shows a gradient in the Gradient palette.
|
ASErr ASAPI(* | SetCurrentColor )(AIColor *color) |
| Shows a color in the Color palette.
|
ASErr ASAPI(* | ToggleColorDialog )() |
| Shows the Color palette if it is hidden, hides the Color palette if it is shown.
|
void ASAPI(* | SwapFillStroke )() |
| Exchanges the fill and stroke colors for the current selection.
|
ASBoolean ASAPI(* | DisplayColorPicker )(AIColor *currentColor) |
| Invokes the color-chooser dialog and reports the chosen color.
|
ASBoolean ASAPI(* | DisplayColorPickerWithOptions )(AIColor *currentColor, const AIColorPickerOptions &options) |
| Invokes the Color Picker dialog with options and reports the chosen color.
|
AIErr ASAPI(* | SetStrokeAlignment )(AIArtHandle art, ai::uint32 strokeAlignment) |
| Changes the stroke alignment for an art object.
|
AIErr ASAPI(* | SetStrokeAlignmentOnSelection )(ai::uint32 strokeAlignment) |
| Changes the stroke alignment for the currently selected art object or objects.
|
ai::uint32 ASAPI(* | GetStrokeAlignmentFromSelection )() |
| Retrieves the stroke alignment for the currently selected art object or objects.
|
Detailed Description
This suite provides functions to examine and operate on the Color and Gradient palettes, which display and modify the paint style of the current selection, and the Color Editor, which allows a user to choose and edit colors.
Member Data Documentation
Invokes the color-chooser dialog and reports the chosen color.
(Note that this function returns a boolean value, not an error code.)
- Parameters:
-
| currentColor | specifies the initial color the picker will display. When the function returns currentColor will become the color the user picked. |
- Returns:
- True if the user clicked OK, false of the user clicked Cancel.
Invokes the Color Picker dialog with options and reports the chosen color.
(Note that this function returns a boolean value, not an error code.)
- Parameters:
-
| currentColor | [in/out] On input, the initial color to display. On output, the color the user selected. |
| options | Options for initial display. The Color Picker opens in the swatch-list view if the initial color exactly matches the color in a swatch from the AIColorPickerOptions::swatchList . |
- Returns:
- True if the user clicked OK in the Color Picker, false if the user clicked Cancel.
Retrieves the index position of the selected stop the current gradient.
(Note that this function returns a numeric value, not an error code.)
- Returns:
- The 0-based position index, or -1 if a gradient stop is not currently being edited.
Retrieves the fill, stroke, or currently active gradient stop color currently shown in the Color palette.
- Parameters:
-
| color | [out] A buffer in which to return the color. |
Retrieves the gradient currently shown in the Gradient palette.
- Parameters:
-
| color | [out] A buffer in which to return the gradient. |
Retrieves the stroke alignment for the currently selected art object or objects.
(Note that this function returns a numeric value, not an error code.)
- Returns:
- The stroke alignment type of the current selection, a constant in
AIStrokeAlignmentType . If there is no selection or selected art objects have different states, returns kAIStrokeAlignmentCenter .
Reports whether the current color in the Color palette is for a stroke or fill.
(Note that this function returns a boolean value, not an error code.)
- Returns:
- True if the color is for a stroke, false if it is for a fill.
Reports whether the Color palette shows the fill color (not stroke).
(Note that this function returns a boolean value, not an error code.)
- Returns:
- True if fill is active.
Reports whether the Color palette shows the stroke color (not fill).
(Note that this function returns a boolean value, not an error code.)
- Returns:
- True if stroke is active.
If caching is not active, applies a color to the selection, or to the active gradient stop.
If caching is active--that is, between a call to BeginActiveColor() and a call to EndActiveColor() --applies the color to proxies (such as the color previews in the Tools palette) rather than to the selection or gradient stop. (The eyedropper tool uses this during mouse-drag.)
- Parameters:
-
| color | The new color. |
| useGradientStop | True to replace the color in the currently active gradient stop only, false to replace the color in the entire selection. |
If caching is not active, applies a stroke or fill color to the current selection, using a partial color specification.
If caching is active--that is, between a call to BeginActiveColor() and a call to EndActiveColor() --applies the color to proxies (such as the color previews in the Tools palette) rather than to the selection.
- Parameters:
-
| color | The color structure containing new color component values. |
| colorMap | A color map that specifies which members of the color structure contain valid values. |
| isStroke | True to set the current stroke color, false to set the fill color. |
Shows a color in the Color palette.
- Parameters:
-
Shows a gradient in the Gradient palette.
- Parameters:
-
Sets the fill and stroke states of the current selection to those of the default style (usually white for fill and solid 1-point black for stroke).
(Note that this function does not return an error code.)
Causes the Color palette to show the fill color (not stroke).
(Note that this function does not return an error code.)
Causes the Color palette to show the stroke color (not fill).
(Note that this function does not return an error code.)
Changes the stroke alignment for an art object.
- Parameters:
-
| art | [in] The art handle. |
| strokeAlignment | [in] The new alignment type, a constant in AIStrokeAlignmentType . |
- Returns:
kNoErr if successful, error code otherwise.
Changes the stroke alignment for the currently selected art object or objects.
- Parameters:
-
- Returns:
kNoErr if successful, error code otherwise.
Invokes the Color palette.
Invokes the Gradient palette.
Exchanges the fill and stroke colors for the current selection.
(Note that this function does not return an error code.)
Shows the Color palette if it is hidden, hides the Color palette if it is shown.
The documentation for this struct was generated from the following file:
|