(acad_colordlg color-number [flag])
Display the Select Color dialog box.
This function displays the Color dialog box. This function returns the color number that the user selects from the dialog box or nil when the user clicks the Cancel button.
The function accepts two optional arguments:
| Argument | Meaning | Example | Range |
|---|---|---|---|
| color-number | Color Number | 1 | 0 - 256 |
| flag | Flag | nil | nil or true (which is the same as not using the flag) |
NOTES
- The color-number argument lets you provide a default color. When clrno is 0, the default is BYBLOCK; when clrno is 256, the default is BYLAYER.
- When nil, the dialog box disables the BYBLOCK and BYLAYER buttons.
Examples
| Code | Result |
|---|---|
| (acad_colordlg 1) | Displays dialog box with color 1 (red) selected as the default. |
| (acad_colordlg 1 nil) | Displays dialog box with color 1 (red) selected as the default, and the BYBLOCK and BYLAYER buttons are disabled. |
NOTE The first eight color numbers have the following meanings:
| Number | Color |
|---|---|
| 1 | Red |
| 2 | Yellow |
| 3 | Green |
| 4 | Cyan (light blue) |
| 5 | Blue |
| 6 | Magenta (pink) |
| 7 | Black or White |
| 8 | Dark Gray |
| 9 | Light Gray |
en
italiano
čeština
Deutsch
français
hrvatski
magyar
polski
српски
русский
中文
中文
한국어
español