User`s guide
mlreportgen.dom.Color class
12-39
Color for document element, represented by an mlreportgen.dom.Color object.
Properties
HexValue — hexidecimal color value (read-only)
string
Hexadecimal number representing an RGB color value. For example, '#8b008b'
specifies dark magenta. You can use either uppercase or lowercase letters as part of a
hexadecimal value.
Id — ID for document element
string
A session-unique ID is generated as part of document element creation. You can specify
an ID to replace the generated ID.
Tag — Tag for document element
string
Tag for document element, specified as a string.
A session-unique ID is generated as part of document element creation. The generated
tag has the form CLASS:ID, where CLASS is the class of the element and ID is the value
of the Id property of the object. You can specify a tag to replace the generated tag.
Specify your own tag value, for example, to make it easier to identify where an issue
occurred during document generation.
Value — CSS color name or hexidecimal RGB value for this color
string
Either a CSS color name or a hexidecimal RGB value.
Examples
Create and Apply a Color Object
Create a blue color object and apply it to a paragraph. Instead of specifying the CSS color
name 'blue', you could use the hexadecimal value '#0000ff'.