mlreportgen.dom.Color class
Package: mlreportgen.dom
Superclasses:
Color of document element
Description
Specifies the color of a document element.
Construction
creates a
black color object.colorObj
= mlreportgen.dom.Color()
creates a color object based on the specified CSS color name.colorObj
= mlreportgen.dom.Color(colorName
)
creates a color object using the hexadecimal RGB color value.colorObj
= mlreportgen.dom.Color(rgbValue
)
Input Arguments
Output Arguments
Properties
Methods
Public Methods
Method | Purpose |
---|---|
mlreportgen.dom.Color.isValid | Use this method to check if a string is a valid
color.tf = mlreportgen.dom.Color.isValid('red'); tf = logical 1 |
mlreportgen.dom.Color.getUnitVector | Use this method to get the unit vector values for a valid
color.redVector = mlreportgen.dom.Color.getUnitVector('red'); redVector = 1 0 0 |