Previous: Iterators In Guile, Up: Guile API [Contents][Index]
You can assign instance of <gdb:color>
to the value of
a <gdb:parameter>
object created with PARAM_COLOR
.
<gdb:color>
may refer to an index from color palette or contain
components of a color from some colorspace.
value is an integer index of a color in palette, tuple with color components or a string. String can be a hex RGB triplet in ‘#RRGGBB’ format or one of the following color names: ‘none’ (meaning the terminal’s default color), ‘black’, ‘red’, ‘green’, ‘yellow’, ‘blue’, ‘magenta’, ‘cyan’, or ‘white’.
color-space should be one of the ‘COLORSPACE_’ constants. This argument tells GDB which color space value belongs.
Return #t
if object is a <gdb:color>
object.
Otherwise return #f
.
Return #t
if color is terminal’s default.
Otherwise return #f
.
Return #t
if color is indexed, i.e. belongs to some palette.
Otherwise return #f
.
Return #t
if color is direct in the sense of ISO/IEC 8613-6.
Otherwise return #f
.
Return the textual representation of a <gdb:color>
object.
Return the color space of a <gdb:color>
object.
Return index of the color of a <gdb:color>
object in a palette.
Return components of the direct <gdb:color>
object.
Return string to change terminal’s color to this.
If is_foreground is #t
, then the returned sequence will change
foreground color. Otherwise, the returned sequence will change background
color.
When color is initialized, its color space must be specified. The
available color spaces are represented by constants defined in the gdb
module:
COLORSPACE_MONOCHROME
Palette with only terminal’s default color.
COLORSPACE_ANSI_8COLOR
Palette with eight standard colors of ISO/IEC 6429 "black", "red", "green", etc.
COLORSPACE_AIXTERM_16COLOR
Palette with 16 colors. First eight are standard colors of ISO/IEC 6429 "black", "red", "green", etc. Next eight are their bright version.
COLORSPACE_XTERM_256COLOR
Palette with 256 colors. First 16 are from COLORSPACE_AIXTERM_16COLOR. Next 216 colors are 6x6x6 RGB cube. And last 24 colors form grayscale ramp.
COLORSPACE_RGB_24BIT
Direct 24-bit RGB colors.
Previous: Iterators In Guile, Up: Guile API [Contents][Index]