Desktop User Guides > Professional > Interview scripting > Writing interview scripts > Page layout facilities > Styles > Categorical response lists > Colors for categorical response lists
Colors for categorical response lists
You can specify the foreground and backgrounds color for a complete categorical response block. The foreground color is applied to the response texts and the background color is applied to the whole area covered by the response block.
In the metadata section
Place the following element after the question text:
style([color = "TextColor"][, bgcolor = "BlockBgColor"])
TextColor is the color for the response texts.
BlockBgColor is the background color for the response block.
For example:
Sports9 "Which of the following sports do you play?"
style(color = "blue", bgcolor = "yellow") categorical [1..]
{Tennis, Football, Cricket, Basketball, Hockey};
This graphic is described in the surrounding text.
Compare this with the colors examples in Colors that use labelstyle instead of style: the yellow background now applies to the whole of the response list not just to the text.
You cannot change the color of check boxes or radio buttons.
In the routing section
Qname.Style.Color = "color"Qname.Style.BgColor = "color"
The following statements produce the same output:
Sports.Style.Color = "blue"
Sports.Style.BgColor = "yellow"
See also
Categorical response lists