The SlideMenu can be found in the Containers widget group in TouchGFX Designer.
The properties for the SlideMenu are described in the following sections.
|Property Group||Property Descriptions|
|Name||Name of the widget. Name is the unique identifier used in TouchGFX Designer and code.|
|Location||X and Y specify the top left corner of the widget relative to its parent.|
W and H specify the width and height of the widget.
The size of a SlideMenu is determined by the size of its background and button images.
Lock specifies if the widget should be locked in its current X, Y, W and H.
Locking the widget also disables interacting with the widget through the screen.
Visible specifies the visibility of the widget.
Making the widget invisible also disables interacting with the widget through the screen.
|Expanding Direction||Expanding Direction specifies the direction the SlideMenu should expand.|
|State||State specifies the initial state of the SlideMenu, either collapsed or expanded.|
Collapsed: Visible Pixels specifies the amount of pixels that should be visible when the state is collapsed.
Expanded: Hidden Pixels Specifices the amount of pixels that should be hidden when the state is expanded.
Expanded Timeout specifies the amount of time before automatically returning to the collapsed state from the expanded state.
|Background||Background Image specifies the image to use as background.|
Background Location specifies the x,y coordinate of the background image relative to the widgets' coordinates.
|Button||Use Button Specifies whether or not to make use of a button to control the state of the widget.|
Released Image specifies the image to use for the buttons' released state.
Pressed Image specifies the image to use for the buttons' pressed state.
Button Location specifies the x,y coordinate of the button relative to the widgets' coordinates.
|Animation||Easing and Easing Option specify which easing equation to use for animations.|
Duration specifies the amount of time the animation should take.
|Mixins||Draggable specifies if the widget is draggable at runtime.|
ClickListener specifies if the widget emits a callback when clicked.
FadeAnimator specifies if the widget can animate changes to its Alpha value.
MoveAnimator specifies if the widget can animate changes to X and Y values.
The actions and triggers supported by the SlideMenu are described in the following sections.
|Widget specific action||Description|
|Change State of SlideMenu||Change the state of a SlideMenu to either collapsed or expanded|
|Reset Timer of SlideMenu||Reset the timer automatically returning the SlideMenu state to collapsed|
|Standard widget action||Description|
|Move widget||Move a widget to a new position over time.|
|Hide widget||Hides a widget (sets visibility to false).|
|Show widget||Make a hidden widget visible (sets visibility to true).|
|SlideMenu animation ended||A SlideMenu animation from one state to another has ended.|
|SlideMenu state changed||A SlideMenu has had its state changed.|
A SlideMenu is a Container type and does not per default appear in the draw chain. Therefore, the performance is mostly dependent on the drawing performance of the children.
For more details on drawing performance, read the General UI Component Performance section.
In the generated code for the View base class we can see how the TouchGFX Designer sets up a SlideMenu.
SlideMenuName.invalidate()if you change the appearance of the widget.
To further explore the SlideMenu, try creating a new application within TouchGFX Designer with the following UI template: