NDEVR
API Documentation

A color identified by an AutoCAD Color Index (ACI) number from 1 through 255. More...

Inheritance diagram for ACIColor:
[legend]
Collaboration diagram for ACIColor:
[legend]

Public Member Functions

 ACIColor ()
 Constructs a default ACIColor with index 0 (black).
 ACIColor (const HSBColor &)
 Constructs an ACIColor by finding the closest ACI match to an HSB color.
 ACIColor (const HSLColor &)
 Constructs an ACIColor by finding the closest ACI match to an HSL color.
 ACIColor (const LABColor &)
 Constructs an ACIColor by finding the closest ACI match to a LAB color.
 ACIColor (const RGBColor &)
 Constructs an ACIColor by finding the closest ACI match to an RGB color.
 ACIColor (const XYZColor &)
 Constructs an ACIColor by finding the closest ACI match to an XYZ color.
constexpr ACIColor (uint01 color)
 Constructs an ACIColor from the given ACI index value.
uint01 getIndex () const
 Gets the raw ACI index value.
TranslatedString getName () const
 Gets the translated display name of this ACI color.
RGBColor getRBGAColor () const
 Converts this ACI color to its RGBA color representation.

Static Public Attributes

static const uint01 ASI_BLACK = 0
 ACI index for black.
static const uint01 ASI_BLUE = 5
 ACI index for blue.
static const uint01 ASI_GREEN = 3
 ACI index for green.
static const uint01 ASI_PURPLE = 6
 ACI index for purple (magenta).
static const uint01 ASI_RED = 1
 ACI index for red.
static const uint01 ASI_TEAL = 4
 ACI index for teal (cyan).
static const uint01 ASI_WHITE = 7
 ACI index for white.
static const uint01 ASI_YELLOW = 2
 ACI index for yellow.

Detailed Description

A color identified by an AutoCAD Color Index (ACI) number from 1 through 255.


Class: ACIColor

Standard color names are available only for colors 1 through 7. The colors are assigned as follows: 0 Black, 1 Red, 2 Yellow, 3 Green, 4 Cyan, 5 Blue, 6 Magenta, 7 White 8 Dark Gray, 9 Light Gray 10-249 are shades of colors designed to provide a spectrum to see most things. 250-255 are shades of gray going from dark to light

See also
RGBColor, ColorPalettes

Definition at line 58 of file ACIColor.h.

Constructor & Destructor Documentation

◆ ACIColor() [1/6]

ACIColor::ACIColor ( uint01 color)
inlineexplicitconstexpr

Constructs an ACIColor from the given ACI index value.

Parameters
[in]colorThe ACI index (0-255).

Definition at line 71 of file ACIColor.h.

◆ ACIColor() [2/6]

ACIColor::ACIColor ( const RGBColor & )
explicit

Constructs an ACIColor by finding the closest ACI match to an RGB color.

Parameters
[in]colorThe RGB color to convert.

◆ ACIColor() [3/6]

ACIColor::ACIColor ( const HSBColor & )
explicit

Constructs an ACIColor by finding the closest ACI match to an HSB color.

Parameters
[in]colorThe HSB color to convert.

◆ ACIColor() [4/6]

ACIColor::ACIColor ( const HSLColor & )
explicit

Constructs an ACIColor by finding the closest ACI match to an HSL color.

Parameters
[in]colorThe HSL color to convert.

◆ ACIColor() [5/6]

ACIColor::ACIColor ( const XYZColor & )
explicit

Constructs an ACIColor by finding the closest ACI match to an XYZ color.

Parameters
[in]colorThe XYZ color to convert.

◆ ACIColor() [6/6]

ACIColor::ACIColor ( const LABColor & )
explicit

Constructs an ACIColor by finding the closest ACI match to a LAB color.

Parameters
[in]colorThe LAB color to convert.

Member Function Documentation

◆ getIndex()

uint01 ACIColor::getIndex ( ) const
inline

Gets the raw ACI index value.

Returns
The ACI color index (0-255).

Definition at line 115 of file ACIColor.h.

◆ getName()

TranslatedString ACIColor::getName ( ) const

Gets the translated display name of this ACI color.

Returns
A TranslatedString containing the human-readable color name.

◆ getRBGAColor()

RGBColor ACIColor::getRBGAColor ( ) const

Converts this ACI color to its RGBA color representation.

Returns
The RGBColor corresponding to this ACI index.

The documentation for this class was generated from the following file: