summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorjussi2023-04-14 00:11:58 +0300
committerjussi2023-04-14 00:11:58 +0300
commitdc2edd69440fcc2470a45562149166695d4edbcc (patch)
tree25d4779859468d44958f41357af53396452c3f52 /include
parent895c7f1a06de2d89347909d62da41be9d62f0d09 (diff)
downloadreilua-enhanced-dc2edd69440fcc2470a45562149166695d4edbcc.tar.gz
reilua-enhanced-dc2edd69440fcc2470a45562149166695d4edbcc.tar.bz2
reilua-enhanced-dc2edd69440fcc2470a45562149166695d4edbcc.zip
Raygui wrapper lib.
Diffstat (limited to 'include')
-rw-r--r--include/raygui.h6
-rw-r--r--include/rgui.h1
-rw-r--r--include/state.h1
3 files changed, 6 insertions, 2 deletions
diff --git a/include/raygui.h b/include/raygui.h
index 38440de..73f9e0d 100644
--- a/include/raygui.h
+++ b/include/raygui.h
@@ -2049,7 +2049,8 @@ bool GuiTextBox(Rectangle bounds, char *text, int textSize, bool editMode)
// Delete text
if (keyCount > 0)
{
- if (IsKeyPressed(KEY_BACKSPACE))
+ // if (IsKeyPressed(KEY_BACKSPACE))
+ if ( GetKeyPressed() == KEY_BACKSPACE )
{
while ((keyCount > 0) && ((text[--keyCount] & 0xc0) == 0x80));
text[keyCount] = '\0';
@@ -2343,7 +2344,8 @@ bool GuiTextBoxMulti(Rectangle bounds, char *text, int textSize, bool editMode)
// Delete characters
if (textLength > 0)
{
- if (IsKeyPressed(KEY_BACKSPACE))
+ // if (IsKeyPressed(KEY_BACKSPACE))
+ if ( GetKeyPressed() == KEY_BACKSPACE )
{
if ((unsigned char)text[textLength - 1] < 127)
{
diff --git a/include/rgui.h b/include/rgui.h
index b23b472..576c0c6 100644
--- a/include/rgui.h
+++ b/include/rgui.h
@@ -11,6 +11,7 @@ int lguiGuiSetState( lua_State *L );
int lguiGuiGetState( lua_State *L );
/* Font. */
int lguiGuiSetFont( lua_State *L );
+int lguiGuiGetFont( lua_State *L );
/* Style */
int lguiGuiSetStyle( lua_State *L );
int lguiGuiGetStyle( lua_State *L );
diff --git a/include/state.h b/include/state.h
index b82cfd9..305be56 100644
--- a/include/state.h
+++ b/include/state.h
@@ -14,6 +14,7 @@ typedef struct {
lua_State *luaState;
Vector2 resolution;
int textureSource;
+ size_t guiFont;
/* Resources. */
/* Images. */
Image **images;