colorwheel
PROMPT
,
COLOR

The colorwheel statement allows the user to pick a color using the operating systems standard color picker dialog


Parameters

This statement has two parameters:

prompt – is a message that will be displayed in the color picker dialog. The prompt should be a text item like “Background Color” or “Negative Highlight Color”. Note: This parameter is currently not supported, the specified text is not displayed in the dialog.

color – must be a variable or text field. The color the user picks (a binary data value) will be placed into the field or variable. Note: If this field or variable already contains a color, that color will be the initial color displayed in the dialog. Otherwise the default color is white.


Description

This statement displays the color picker dialog. The user can pick a color, then press the Ok or Cancel buttons (the procedure can tell what button was pressed by using the info(“dialogtrigger”) function.

The procedure below lets the user pick a color, then changes the color of foreground objects to that color. (Note: For this example, foreground objects are defined as objects that contain the word foreground in the object name.)

local foreColor
colorwheel "Foreground Color",foreColor
if info("dialogtrigger") contains "Cancel"
    stop
endif
selectobjects objectinfo("name") contains "Foreground"
changeobjects "color",foreColor
selectnoobjects

See Also


History

VersionStatusNotes
10.0UpdatedCarried over from Panorama 6.0, but does not display prompt text, and allows program to specify the initial color.