Underline Color
The sample listed here describes how to set text underline color based on a standard method of describing the color - CMYK.
Refer to the emphasis everywhere context in the Arbortext-path/samples/ALD/Colour/SettingColours.xml sample file. The context includes a set of conditions based on the value of the role attribute in the associated stylesheet. Each condition references a different property set.
For example, the condition ELSE IF attribute “role” = “CMYK underline colour” of the emphasis everywhere context references the CMYK underline colour property set. This property set sets a text underline color in CMYK format, where each of the four values is specified as a number in the range 0-255. The relevant code in that property set is given below.
style.underlineRule.color = "cmyk(200,100,10,50)";
Here you have added an underlineRule property to the styling assigned to the inline text. That property is based on the fTextRule object, which takes a color property. The value of color is described in CMYK format.
Note that this code does not apply an underline to the text. That is handled via a property setting in the Text property category in the Arbortext Styler UI.