Container

Undocumented in source.

Constructors

this
this(vec2 position, Size!int size)
Undocumented in source.

Members

Functions

addChild
void addChild(Control control)

Adds child control

draw
void draw(float deltaTime)

Draws the container with children

focusControl
void focusControl(Control control)

Gives focus to a control

getControl
T getControl(uint id)

Returns child control by id

initialize
void initialize()

Initializes control

onKey
void onKey(int key)

Event called on key input

onMouseClick
void onMouseClick(MouseButton mouseButton, vec2 mousePosition)

Event called on mouse button click

onMouseLeave
void onMouseLeave()

Event called when mouse leaves control's rect

onMouseMove
void onMouseMove(vec2 position)

Event called when mouse enters in control's rect

onMouseUp
void onMouseUp(MouseButton mouseButton)

Event called on mouse button release

onText
void onText(int key)

Event called on character input

reSize
void reSize()

Resize the container if a child control is bigger

remove
void remove(Control toRemove)

Removes a control from control list

unfocusControl
void unfocusControl(Control control)

Removes focus from a control

update
void update(float deltaTime)
Undocumented in source. Be warned that the author may not have intended to support it.
updateChildPosition
void updateChildPosition(Control childControl)

Updates child control position using dock property

Properties

controlUnderMouse
Control controlUnderMouse [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
controls
Control[] controls [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
focusedControl
Control focusedControl [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
opacity
ubyte opacity [@property setter]
Undocumented in source. Be warned that the author may not have intended to support it.
realPosition
const(vec2) realPosition [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
realPosition
vec2 realPosition [@property setter]
Undocumented in source. Be warned that the author may not have intended to support it.
tooltip
Tooltip tooltip [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Templates

ControlGetter
template ControlGetter(string controlClass)
Undocumented in source.

Variables

m_autoResize
bool m_autoResize;

Container should be resized if a child control is bigger ?

m_controlUnderMouse
Control m_controlUnderMouse;
Undocumented in source.
m_controls
Control[] m_controls;

Children list

m_focusedControl
Control m_focusedControl;

Current focused child

m_horizontalScrollBar
ScrollBar m_horizontalScrollBar;
Undocumented in source.
m_tooltip
Tooltip m_tooltip;

Current selected control tooltip

m_verticalScrollBar
ScrollBar m_verticalScrollBar;
Undocumented in source.

Meta