16 #define GETTEXT_DOMAIN "wesnoth-lib"
89 load_resolutions<resolution>(cfg);
109 builder_drawing::builder_drawing(
const config& cfg)
111 , width(cfg[
"width"])
112 , height(cfg[
"height"])
119 auto widget = std::make_unique<drawing>(*
this);
132 DBG_GUI_G <<
"Window builder: placed drawing '" <<
id
133 <<
"' with definition '" <<
definition <<
"'.";
A config object defines a single node in a WML file, with access to child nodes.
bool disable_click_dismiss() const override
See widget::disable_click_dismiss.
virtual void request_reduce_width(const unsigned maximum_width) override
See widget::request_reduce_width.
point best_size_
When we're used as a fixed size item, this holds the best size.
virtual void request_reduce_height(const unsigned maximum_height) override
See widget::request_reduce_height.
virtual bool get_active() const override
See styled_widget::get_active.
virtual void set_active(const bool active) override
See styled_widget::set_active.
virtual point calculate_best_size() const override
See widget::calculate_best_size.
virtual unsigned get_state() const override
See styled_widget::get_state.
void point(int x, int y)
Draw a single point.
void get_screen_size_variables(wfl::map_formula_callable &variable)
Gets a formula object with the screen size.
Contains the implementation details for lexical_cast and shouldn't be used directly.
std::size_t size(const std::string &str)
Length in characters of a UTF-8 string.
resolution(const config &cfg)
drawing_definition(const config &cfg)
typed_formula< unsigned > height
The height of the widget.
typed_formula< unsigned > width
The width of the widget.
virtual std::unique_ptr< widget > build() const override
std::vector< state_definition > state
std::string missing_mandatory_wml_tag(const std::string §ion, const std::string &tag)
Returns a standard message for a missing wml child (tag).
Add a special kind of assert to validate whether the input from WML doesn't contain any problems that...
#define VALIDATE_WML_CHILD(cfg, key, message)