Button

fun Button(    posX: Number = 0,     posY: Number = 0,     width: Number = DEFAULT_BUTTON_WIDTH,     height: Number = DEFAULT_BUTTON_HEIGHT,     text: String = "",     font: Font = Font(),     alignment: Alignment = Alignment.CENTER,     isWrapText: Boolean = false,     visual: Visual = ColorVisual.WHITE)

Creates a Button.

Parameters

posX

Horizontal coordinate for this Button. Default: 0.

posY

Vertical coordinate for this Button. Default: 0.

width

Width for this Button. Default: DEFAULT_BUTTON_WIDTH.

height

Height for this Button. Default: DEFAULT_BUTTON_HEIGHT.

text

Text for this Button. Default: empty String.

font

Font to be used for the text. Default: default Font constructor.

alignment

Alignment to be used for the text Default: Alignment.CENTER.

isWrapText

Defines if text should be wrapped. Default: false.

visual

Visual for this button. Default: ColorVisual.WHITE