public class ColorDialog extends Dialog:
Themed standalone dialog for selecting a color.
The dialog hosts the complete ColorPicker experience and remains modal until the user selects a color or cancels. Use ColorLightBox when the selection must stay embedded in an existing application window.
dialog = ColorDialog(Color.fromHex("#3B82F6"))
if dialog.showDialog(window):
panel.backgroundColor = dialog.selectedColor| Modifier and Type | Member | Description |
|---|---|---|
| public readonly property | selectedColorselectedColor as Color: |
Color accepted by the user, or the initial color after cancellation. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | ColorDialogColorDialog(
selectedColor as Color = null,
title as String = "Select color"
): |
Creates a modal color-selection dialog. |
| Modifier and Type | Member | Description |
|---|---|---|
| public | showDialog | Displays the dialog and blocks until selection or cancellation. |