26 #include "sdl_widget.hpp"
34 SDL_INPUT_READONLY = 2
37 SdlInputWidget(SDL_Renderer* renderer, std::string label, std::string initial, Uint32 flags,
38 size_t offset,
size_t width,
size_t height);
45 bool fill_label(SDL_Renderer* renderer, SDL_Color color);
46 bool update_label(SDL_Renderer* renderer);
48 bool set_mouseover(SDL_Renderer* renderer,
bool mouseOver);
49 bool set_highlight(SDL_Renderer* renderer,
bool highlight);
50 bool update_input(SDL_Renderer* renderer);
51 bool resize_input(
size_t size);
53 bool set_str(SDL_Renderer* renderer,
const std::string& text);
54 bool remove_str(SDL_Renderer* renderer,
size_t count);
55 bool append_str(SDL_Renderer* renderer,
const std::string& text);
57 [[nodiscard]]
const SDL_Rect& input_rect()
const;
58 [[nodiscard]] std::string value()
const;
60 [[nodiscard]]
bool readonly()
const;
63 bool update_input(SDL_Renderer* renderer, SDL_Color fgcolor);
68 std::string _text_label;