ComponentOne List for WinForms
In This Topic
    Named Style Inheritance
    In This Topic

    To see for yourself how named style inheritance works, place a list on a form and set the Caption property of the list and its default columns. Set the FooterText property of the default columns and set the ColumnFooters property of the list to True. The list should look something like this:

    In the Style Collection Editor, expand the Normal node, select its Font property, and set Bold to True. Note that the column headers, column footers, and list caption are all bold, since all built-in styles inherit from the Normal style or one of its children.

    Next, expand the Heading node and select its ForeColor property. Choose Web from the color tabs, then select Navy. Note that the text color of both the column headers and the list's caption bar is now white, since the Caption style inherits its color properties from the Heading style. The column footers remain the same because the Footer style inherits from Normal, not Heading.

    Finally, expand the Caption node and select its BackColor property. Choose Web from the color tabs, then select LightCyan. Note that the background color of the column headers is not changed, and that the Caption style continues to inherit its text color from its parent style, Heading.