UI Control

From Jeremie Leroy - XOJO Controls Wiki
Revision as of 16:25, 7 August 2015 by Admin (Talk | contribs) (13 revisions imported)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Desktop Framework

Each UI_Control (UI_Button, UI_Slider, UI_TextArea...) is a replacement of the native Controls included in the Xojo Desktop Framework.

Each control has the same Events, Methods and Properties from the native Controls.

Web Framework

Each UI_Control (UI_Button, UI_Slider, UI_TextArea...) is a subclass and replacement of the native WebControls included in the Xojo Web Framework.

Each control keeps the same Events, Methods and Properties from the native WebControls.

Both Frameworks

The only accessible addition for each UI_Control is the MyStyle property, that holds a structure for the Style to apply to the control.



Properties
MyStyle




Class Constants

BackgroundType

The following class constants can be used to specify the value of BackgroundType and all other MyStyle.XXType properties.

Class Constant Description
FillSolid Element background will have a solid color, using XXColor1
FillGradientVertical Element background will have a vertical gradient using XXColor1 and XXColor2
FillGradientHorizontal Element background will have a horizontal gradient using XXColor1 and XXColor2
FillTexture Element background is a picture defined by XXTexture. The picture is tiled (repeated)

Changing the Style of a Control

Changing the style of a single control can be done in the Open event of the Control.

For example:
me.MyStyle.Arc = 99
Will change the border radius of the control to 99 pixels (a round corner).

All other controls with the same type will keep the default style.

UIStyle Structure

Detailed information of UI_Control.UIStyle on a dedicated page.

See also

CustomUI, WebCustomUI, UI_GroupBox