You are hereBlogs / luano's blog / Update style handling

Update style handling


By luano - Posted on 14 October 2008

A significant bug in the handling of styles has been fixed. The bug prevented styles being applied to generic component instances.

The idea of the styles was to support CSS like styles and a style for a class such as Button or Label could be created and applied to any instances of these components that did not explicitly specify a style. This is now fixed.

While repairing the feature is a major improvement, the feature still faced a major limitation in that during the construction of component the UIManager class could influence the same component attributes affected by the styles. Furthermore the UIManager settings could also be used by these components post creation such that the styles would be lost.

Aria's styles now integrate with the UIManager. To have an Aria style affect the UIManager just add a uimgr="true" attribute to the style, for example:


        <style name="Label" uimgr="true">
            <color_back value="ffffff"/>
            <color_fore value="333333"/>
            <font_face value="arial"/>
            <font_size value="11"/>
            <font_weight value="0"/>
            <font_italic value="0"/>
        </style>