App

Terminal UI application

Members

Functions

aspectRatio
float aspectRatio()

Returns aspect ratio (w / h)

create
void create()

Public create method. Can be overriden. Called when app is created, but before all elements created

destroy
void destroy()

Public destroy method. Can be overriden. Called when app is destroyed, but after all elements destroyed

fps
int fps()

Returns current FPS

fpsString
string fpsString()

Returns current FPS as string

getFpsTarget
float getFpsTarget()
Undocumented in source. Be warned that the author may not have intended to support it.
height
uint height()

Returns app width/height

input
void input(InputEvent e)

Public update method. Can be overriden. Called each frame if there's input available after all elements have processed input

isRunning
bool isRunning()

Returns true if app is running

render
void render()

Public render method. Can be overriden. Called each frame after all elements have rendered

rootElement
Element rootElement()

Returns root element

run
void run()

Starts application and goes into raw alt terminal mode

setFpsTarget
void setFpsTarget(float t)
Undocumented in source. Be warned that the author may not have intended to support it.
setTitle
void setTitle(string title)

Sets app title

size
uvec2 size()

Returns app width/height

stop
void stop()

Requests application to be stopped

update
void update(float delta)

Public update method. Can be overriden. Called each frame after all elements have been updated

width
uint width()

Returns app width/height

Meta