From 4a797a4226893b382ffc3c1f92e844f6743c7220 Mon Sep 17 00:00:00 2001 From: Alexander Pickering Date: Sat, 20 Oct 2018 14:05:30 -0400 Subject: Added more documentation Added documentation for several gui elements also moved documentation of generic iguielements to an iguielement class Also added a setvisible() function to iguielements --- src/client/lua_api/gui/iguibutton.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/client/lua_api/gui/iguibutton.cpp') diff --git a/src/client/lua_api/gui/iguibutton.cpp b/src/client/lua_api/gui/iguibutton.cpp index aabc992..42d2846 100644 --- a/src/client/lua_api/gui/iguibutton.cpp +++ b/src/client/lua_api/gui/iguibutton.cpp @@ -28,8 +28,14 @@ extern IrrlichtDevice* device; char lhashkey[20]; /*** +Creates a new button. +Buttons may have the following fields set for callbacks: +`.onClick(self)` +`.onFocus(self)` +`.onUnfocus(self)` +`.onHover(self)` +`.onLeave(self)` @function newbutton() -Creates a new checkbox @tparam rect dimensions The rectangle to place the button at. If the box has a parent, it is offset from the upper-left of the parent element. @tparam string default_text The default text to have in the button -- cgit v1.2.3-70-g09d2