Panel

Element implementing basic panel

Constructors

this
this(uvec2 _pos, uvec2 _size, col _color)

Creates new panel

Members

Functions

_render
void _render()

Panel render

Mixins

__anonymous
mixin property!_color
Undocumented in source.
__anonymous
mixin property!_size
Undocumented in source.

Inherited Members

From Element

__anonymous
mixin getter!_app

Returns App element is attached to

__anonymous
mixin getter!_parent

Returns current parent

__anonymous
mixin getter!_children

Returns array of children

__anonymous
mixin getter!_isRoot

Returns true if element is root

__anonymous
mixin getter!_isInit

Returns true if Element was initialized

__anonymous
mixin property!_pos

Element position property

addChild
void addChild(Element child)

Adds child to element

removeChild
void removeChild(Element child)

Removes child from element

moveChild
void moveChild(Element child, size_t index)

Moves child to position

hasChild
bool hasChild(Element child)

Returns true if this has child

childCount
size_t childCount()

Returns amount of children element has

getChild
Element getChild(size_t index)

Returns child at pos

getChildPos
long getChildPos(Element child)

Returns child at pos

setParent
void setParent(Element p_parent)

Reparents element if it's not root

setRoot
void setRoot()

Sets element as root if there's no root already

setApp
void setApp(App p_app)

Sets App element attached to if it's not already defined

propagateCreate
void propagateCreate()
propagateDestroy
void propagateDestroy()
propagateUpdate
void propagateUpdate(float delta)
propagateInput
void propagateInput(InputEvent e)
propagateRender
void propagateRender()

Propagates internal function calls

create
void create()

Public create method. Can be overriden. Called when element is first added as child

destroy
void destroy()

Public destroy method. Can be overriden. Called when element is queued for deletion or when App is being closed

update
void update(float delta)

Public update method. Can be overriden. Called each frame

input
void input(InputEvent e)

Public input method. Can be overriden. Called each frame if there's unprocessed input event

render
void render()

Public render method. Can be overriden. Called each frame if render is needed

_create
void _create()

Private create method. Used for internal logic Called when element is first added as child

_destroy
void _destroy()

Private destroy method. Used for internal logic Called when element is queued for deletion or when App is being closed

_update
void _update(float delta)

Private update method. Used for internal logic Called each frame

_input
void _input(InputEvent e)

Private input method. Used for internal logic Called each frame if there's unprocessed input event

_render
void _render()

Private render method. Used for internal logic Called each frame if render is needed

Meta