DK for Delphi | GisTypesUI.TGIS_Color | Records | Fields | Methods | Properties
Platform-independent color type with ARGB storage, channel accessors, predefined colors, and color-space conversion helpers.
// Delphi type TGIS_Color = record end;
// C++ Builder struct DECLSPEC_DRECORD TGIS_Color { };
| Name | Visibility | Description | |
|---|---|---|---|
| ARGB | public | Internal color value stored as a little-endian ARGB integer. | |
| Name | Visibility | Description | |
|---|---|---|---|
| FromABGR | public | Creates a transparent color using the ABGR color model. | |
| FromACMYK | public | Creates a transparent color using the CMYK (Cyan, Magenta, Yellow, Key) color model. | |
| FromAHCL | public | Creates a transparent color using the HCL (Hue, Chroma, Luminance) color model. | |
| FromAHSL | public | Creates a transparent color using the HSL (Hue, Saturation, Lightness) color model. | |
| FromAHSV | public | Creates a transparent color using the HSV (Hue, Saturation, Value) color model. | |
| FromARGB(Byte; Byte; Byte; Byte) | public | Creates a transparent color using the RGB color model. | |
| FromARGB(Cardinal) | public | Creates a transparent color using the ARGB color model. | |
| FromBGR(Byte; Byte; Byte) | public | Creates a color using the BGR color model. | |
| FromBGR(Cardinal) | public | Creates a color using the BGR color model. | |
| FromCMYK | public | Creates a color using the CMYK (Cyan, Magenta, Yellow, Key) color model. | |
| FromHCL | public | Creates a color using the HCL (Hue, Chroma, Luminance) color model. | |
| FromHSL | public | Creates a color using the HSL (Hue, Saturation, Lightness) color model. | |
| FromHSV | public | Creates a color using the HSV (Hue, Saturation, Value) color model. | |
| FromRGB(Byte; Byte; Byte) | public | Creates a color using the RGB color model. | |
| FromRGB(Cardinal) | public | Creates a color using the RGB color model. | |
| FromString | public | Creates a color from a CSS-style string representation. | |
| ToABGR | public | Converts a color to an integer in the ABGR form. | |
| ToACMYK | public | Retrieves the alpha (A), cyan (C), magenta (M), yellow (Y), and black (K) components of the current color in the CMYK (Cyan, Magenta, Yellow, Key) color model. | |
| ToAHCL | public | Retrieves the alpha (A), hue (H), chroma (C), and luminance (L) components of the current color in the HCL color model. | |
| ToAHSL | public | Retrieves the alpha (A), hue (H), saturation (S) and lightness (L) components of the current color. | |
| ToAHSV | public | Retrieves the alpha (A), hue (H), saturation (S) and value (V) components of the current color. | |
| ToARGB | public | Converts a color to an integer in the ARGB form. | |
| ToBGR | public | Converts the color to a packed integer in BGR format. | |
| ToCMYK | public | Retrieves the cyan (C), magenta (M), yellow (Y), and black (K) components of the current color in the CMYK (Cyan, Magenta, Yellow, Key) color model. | |
| ToHCL | public | Retrieves the hue (H), chroma (C), and luminance (L) components of the current color in the HCL color model. | |
| ToHSL | public | Retrieves the hue (H), saturation (S) and lightness (L) components of the current color. | |
| ToHSV | public | Retrieves the hue (H), saturation (S) and value (V) components of the current color. | |
| ToRGB | public | Converts the color to a packed integer in RGB format. | |
| ToString | public | Converts the color to a hexadecimal string. | |
| TryFromString | public | Tries to create a color from a CSS-style string representation. | |
| Name | Visibility | Description | |
|---|---|---|---|
| A | public | Gets the alpha channel from the ARGB color value. | |
| Aqua | public | Constructs the standard Aqua color ($ff00ffff). | |
| B | public | Gets the blue channel from the ARGB color value. | |
| Black | public | Constructs the standard Black color ($ff000000). | |
| Blue | public | Constructs the standard Blue color ($ff0000ff). | |
| Crazy | public | Constructs the standard Crazy color ($00010816). | |
| DimGray | public | Constructs the standard DimGray color ($ff696969). | |
| Fuchsia | public | Constructs the standard Fuchsia color ($ffff00ff). | |
| G | public | Gets the green channel from the ARGB color value. | |
| Gray | public | Constructs the standard Gray color ($ff808080). | |
| Green | public | Constructs the standard Green color ($ff008000). | |
| H | public | Gets the hue component from the HSL color representation. | |
| L | public | Gets the lightness component from the HSL color representation. | |
| LightGray | public | Constructs the standard LightGray color ($ffd3d3d3). | |
| Lime | public | Constructs the standard Lime color ($ff00ff00). | |
| Maroon | public | Constructs the standard Maroon color ($ff800000). | |
| Navy | public | Constructs the standard Navy color ($ff000080). | |
| None | public | Constructs the standard None color. | |
| Olive | public | Constructs the standard Olive color ($ff808000). | |
| Purple | public | Constructs the standard Purple color ($ff800080). | |
| R | public | Gets the red channel from the ARGB color value. | |
| Red | public | Constructs the standard Red color ($ffff0000). | |
| RenderColor | public | Constructs the standard RenderColor value ($00ff9933). | |
| S | public | Gets the saturation component from the HSL color representation. | |
| Silver | public | Constructs the standard Silver color ($ffc0c0c0). | |
| Teal | public | Constructs the standard Teal color ($ff008080). | |
| White | public | Constructs the standard White color ($ffffffff). | |
| Yellow | public | Constructs the standard Yellow color ($ffffff00). | |
PURPOSE: Represents a reusable color value for cross-platform UI rendering, bitmap processing, and symbol styling without exposing target platform-specific color types.
BEHAVIOR: Stores color channels in ARGB order and provides conversions between RGB, BGR, ARGB, ABGR, HSL (Hue, Saturation, Lightness), HSV (Hue, Saturation, Value), and related formats. Depending on compilation settings, this type may be implemented as a record or as a class.
CONSTRAINTS: String parsing and some conversion helpers may raiseEGIS_Exception for invalid input values.
TGIS_Color is a platform independent color definition used by TatukGIS Developer Kernel. It is defined as little endian ARGB.
Where:
| Symbol | Name | Min | Max | Comments |
|---|---|---|---|---|
| A | Alpha | 0 | 255 | 0 means fully transparent; 255 means solid |
| R | Red | 0 | 255 | |
| G | Green | 0 | 255 | |
| B | Blue | 0 | 255 |
Sample colors:
| Hex color | Comments |
|---|---|
| $00000000 | Black |
| $00FFFFFF | Pure Red |
| $00FF0000 | Pure Red |
| $0000FF00 | Pure Green |
| $000000FF | Pure Blue |
| $FF000000 | Fully transparent; color has no meaning |
| $80000000 | 50% transparent black |
Read more at http://en.wikipedia.org/wiki/RGBA_color_space.
Each platform has defined conversion functions to convert to/from the actual platform-specific color definition. See GisFramework for VCL or FMX.