27 struct builder_scroll_label;
28 struct builder_scrollbar_panel;
29 struct builder_styled_widget;
42 friend class debug_layout_graph;
88 virtual void layout_initialize(
const bool full_initialization)
override;
91 virtual void request_reduce_height(
const unsigned maximum_height)
override;
94 virtual void request_reduce_width(
const unsigned maximum_width)
override;
101 virtual bool can_wrap()
const override;
105 virtual point calculate_best_size()
const override;
109 virtual void place(
const point& origin,
const point&
size)
override;
112 virtual void set_origin(
const point& origin)
override;
115 virtual void set_visible_rectangle(
const SDL_Rect& rectangle)
override;
120 virtual bool get_active()
const override;
123 virtual unsigned get_state()
const override;
132 widget* find(
const std::string&
id,
const bool must_be_active)
override;
135 const widget* find(
const std::string&
id,
const bool must_be_active)
const override;
138 bool disable_click_dismiss()
const override;
147 return vertical_scrollbar_mode_;
155 return horizontal_scrollbar_mode_;
160 return content_grid_.get();
165 return content_grid_.get();
170 return content_visible_area_;
178 bool vertical_scrollbar_at_end();
184 unsigned get_vertical_scrollbar_item_position()
const;
191 void set_vertical_scrollbar_item_position(
const unsigned position);
197 unsigned get_horizontal_scrollbar_item_position()
const;
204 void set_horizontal_scrollbar_item_position(
const unsigned position);
243 void show_content_rect(
const SDL_Rect& rect);
266 void set_scrollbar_button_status();
287 bool content_resize_request(
const bool force_sizing =
false);
326 bool content_resize_request(
const int width_modification,
327 const int height_modification,
328 const int width_modification_pos = -1,
329 const int height_modification_pos = -1);
337 bool content_resize_width(
const int width_modification,
const int width_modification_pos);
344 bool content_resize_height(
const int height_modification,
const int width_modification_pos);
359 virtual void handle_key_home(SDL_Keymod modifier,
bool& handled);
371 virtual void handle_key_end(SDL_Keymod modifier,
bool& handled);
383 virtual void handle_key_page_up(SDL_Keymod modifier,
bool& handled);
395 virtual void handle_key_page_down(SDL_Keymod modifier,
bool& handled);
407 virtual void handle_key_up_arrow(SDL_Keymod modifier,
bool& handled);
419 virtual void handle_key_down_arrow(SDL_Keymod modifier,
bool& handled);
431 virtual void handle_key_left_arrow(SDL_Keymod modifier,
bool& handled);
443 virtual void handle_key_right_arrow(SDL_Keymod modifier,
bool& handled);
492 void finalize_setup();
504 virtual void layout_children()
override;
507 virtual void impl_draw_children(
surface& frame_buffer,
int x_offset,
int y_offset)
override;
510 virtual void child_populate_dirty_list(
window& caller,
const std::vector<widget*>&
call_stack)
override;
521 virtual void set_content_size(
const point& origin,
const point&
size);
524 void scrollbar_moved();
528 static const std::string&
type();
532 virtual const std::string& get_control_type()
const override;
536 void signal_handler_sdl_key_down(
537 const event::ui_event event,
bool& handled,
const SDL_Keycode key, SDL_Keymod modifier);
539 void signal_handler_sdl_wheel_up(
const event::ui_event event,
bool& handled);
540 void signal_handler_sdl_wheel_down(
const event::ui_event event,
bool& handled);
541 void signal_handler_sdl_wheel_left(
const event::ui_event event,
bool& handled);
542 void signal_handler_sdl_wheel_right(
const event::ui_event event,
bool& handled);
543 void signal_handler_sdl_touch_motion(
const event::ui_event event,
bool& handled,
544 const point& position,
const point& distance);
549 return horizontal_scrollbar_;
554 return vertical_scrollbar_;
559 return horizontal_scrollbar_grid_;
564 return vertical_scrollbar_grid_;
std::size_t size(const std::string &str)
Length in characters of a UTF-8 string.
A tree view is a control that holds several items of the same or different types. ...
A generic container base class.
An empty widget to either fill in a widget since no empty items are allowed or to reserve a fixed spa...
map_location coordinate
Contains an x and y coordinate used for starting positions in maps.
base class of top level items, the only item which needs to store the final canvases to draw on...
static std::deque< std::string > call_stack
Contains the implementation details for lexical_cast and shouldn't be used directly.
ui_event
The event send to the dispatcher.