std::vector< int > char_x_
virtual void handle_text_changed(const ucs4::string &)
void set_edit_target(textbox *target)
void draw_cursor(int pos, CVideo &video) const
void pass_event_to_target(const SDL_Event &event)
void set_text(const std::string &text, const SDL_Color &color=font::NORMAL_COLOR)
virtual void draw_contents()
const std::string text() const
textbox(CVideo &video, int width, const std::string &text="", bool editable=true, size_t max_size=256, int font_size=font::SIZE_PLUS, double alpha=0.4, double alpha_focus=0.2, const bool auto_join=true)
std::vector< int > char_y_
void update_text_cache(bool reset=false, const SDL_Color &color=font::NORMAL_COLOR)
void set_cursor_pos(const int cursor_pos)
bool handle_text_input(const SDL_Event &event)
void set_editable(bool value)
bool handle_key_down(const SDL_Event &event)
void set_font_size(int fs)
void append_text(const std::string &text, bool auto_scroll=false, const SDL_Color &color=font::NORMAL_COLOR)
void handle_event(const SDL_Event &event, bool was_forwarded)
surface add_text_line(const ucs4::string &text, const SDL_Color &color=font::NORMAL_COLOR)
void set_selection(const int selstart, const int selend)
virtual void update_location(SDL_Rect const &rect)
virtual void scroll(unsigned int pos)
virtual void set_inner_location(SDL_Rect const &)
bool requires_event_focus(const SDL_Event *event=nullptr) const
bool show_scrollbar() const