Style

All the controls in XWT are support the feature "Style". By using styles, you can define a common appearance such as fonts, colors and images to a control.

These style properties can be overridden by the values that are set on the control itself. For example, if you set the background color to red in the style of a Label, the Label will appear red when it is drawn on the live display area.

Otherwise, it is possible to define a style for a specific type. It is applied to all UI elements of this type under the UI tree structure. For example, MyUserControl component is a Label with text "Hello, world". We can embed it into MyUserControl_default_x_Customized component with a style.