GMLinesButton:
Filter:
GraphicalModule/Classes (extension) | GUI > Graphical Module

GMLinesButton
ExtensionExtension

A simple multi states button for creating graphical interfaces

Description

GMLinesButton is an easy to use customisable multi states button. It allows to order its buttons on multipe lines.

It does not discriminate button identifiers.

A note about this documentation

This class is an extension of GMMultiButton. The only difference between those two classes are their states specification, and the way their action is evaluated. Only those differences are documented here.

See GMMultiButton documentation for others methods documentation.

States and action arguments

Instead of taking an array of states as argument, GMLinesButton takes an array containing arrays of states as argument. This allows to arrange the buttons into several layers, which can ease the location of the desired button :

The Function associated to the action will be evaluated with two arguments : first, the index of the selected array, then the index of the button within this array. In the previous example, clicking the "b" button would call the function with 2, 1 as arguments.

Class Methods

.new

Creates a new instance of GMLinesButton.

Its graphical properties are defined by its associated GMStyle.

Returns:

a GMLinesButton instance.

Instance Methods

GMMultiButton methods

See the GMMultiButton class documentation for those methods.

.action

.mouseDownAction

.mouseMoveAction

.states

.state

.allowRetrigger

.allowMouseMove

.free

.orientation

.desindex

.direction

.drawSelected

.fontRatio

.unselectedRatio

.setColorAll

.setFontColorAll

.displayAltValue

.svgRatio

Internal Methods

.draw

The function associated to the View's drawFunc. Shouldn't be modified

.prResizeSVGs

Examples