16 #ifndef GUI_WIDGETS_MULTI_PAGE_HPP_INCLUDED
17 #define GUI_WIDGETS_MULTI_PAGE_HPP_INCLUDED
31 struct tbuilder_multi_page;
73 add_page(
const std::map<std::string /* widget id */, string_map>&
data);
97 void select_page(
const unsigned page,
const bool select =
true);
133 virtual unsigned get_state()
const override;
148 void finalize(
const std::vector<string_map>& page_data);
165 int y_offset)
override;
209 std::vector<std::map<std::string, t_string> >
data;
Abstract base class for the generator.
void set_page_builder(tbuilder_grid_ptr page_builder)
virtual unsigned get_state() const override
See tcontrol::get_state.
tbuilder_multi_page(const config &cfg)
GLint GLenum GLsizei GLint GLsizei const GLvoid * data
const tgrid & page_grid(const unsigned page) const
Returns the grid for the page.
Base class of a resolution, contains the common keys for a resolution.
std::vector< std::map< std::string, t_string > > data
Multi page data.
A class inherited from ttext_box that displays its input as stars.
tresolution(const config &cfg)
virtual const std::string & get_control_type() const override
See tcontrol::get_control_type.
void finalize(const std::vector< string_map > &page_data)
Finishes the building initialization of the widget.
int get_selected_page() const
Returns the selected page.
void add_page(const string_map &item)
Adds single page to the grid.
GLuint GLuint GLsizei count
tmulti_page_definition(const config &cfg)
std::map< std::string, t_string > string_map
virtual void set_self_active(const bool active) override
See tcontainer_::set_self_active.
tbuilder_grid_ptr builder
unsigned get_page_count() const
Returns the number of pages.
tgenerator_ * generator_
Contains a pointer to the generator.
void remove_page(const unsigned page, unsigned count=1)
Removes a page in the multi page.
virtual void impl_draw_background(surface &frame_buffer, int x_offset, int y_offset) override
See twidget::impl_draw_background.
void clear()
Removes all pages in the multi page, clearing it.
void select_page(const unsigned page, const bool select=true)
Selectes a page.
A generic container base class.
virtual bool get_active() const override
See tcontrol::get_active.
A config object defines a single node in a WML file, with access to child nodes.
friend class tdebug_layout_graph
GLsizei const GLcharARB ** string
Contains the implementation details for lexical_cast and shouldn't be used directly.
tbuilder_grid_const_ptr page_builder_
Contains the builder for the new items.