Gooey GUI Library
Loading...
Searching...
No Matches
gooey_textbox.h
Go to the documentation of this file.
1#ifndef GOOEY_TEXTBOX_H
2#define GOOEY_TEXTBOX_H
3
4#include "core/gooey_backend_internal.h"
5#include "gooey_event_internal.h"
6
19GooeyTextbox *GooeyTextBox_Add(GooeyWindow *win, int x, int y, int width,
20 int height, char *placeholder, void (*onTextChanged)(char *text));
21
27void GooeyTextbox_Draw(GooeyWindow *win);
28
37bool GooeyTextbox_HandleClick(GooeyWindow *win, int x, int y);
38
45void GooeyTextbox_HandleKeyPress(GooeyWindow *win, GooeyEvent *event);
46
53const char *GooeyTextbox_GetText(GooeyTextbox *textbox);
54
61void GooeyTextbox_SetText(GooeyTextbox *textbox, const char *text);
62
63
64#endif
bool GooeyTextbox_HandleClick(GooeyWindow *win, int x, int y)
Handles textbox click events.
void GooeyTextbox_Draw(GooeyWindow *win)
Draws the textbox on the window.
void GooeyTextbox_HandleKeyPress(GooeyWindow *win, GooeyEvent *event)
Handles key press events for the textbox.
const char * GooeyTextbox_GetText(GooeyTextbox *textbox)
Gets the text of the textbox.
void GooeyTextbox_SetText(GooeyTextbox *textbox, const char *text)
Sets the text of the textbox.
GooeyTextbox * GooeyTextBox_Add(GooeyWindow *win, int x, int y, int width, int height, char *placeholder, void(*onTextChanged)(char *text))
Adds a textbox to the window.