16 #define GETTEXT_DOMAIN "wesnoth-lib"
37 const auto conf = cast_config_to<vertical_scrollbar_definition>();
39 return conf->minimum_positioner_length;
44 const auto conf = cast_config_to<vertical_scrollbar_definition>();
46 return conf->maximum_positioner_length;
51 const auto conf = cast_config_to<vertical_scrollbar_definition>();
53 return conf->top_offset;
58 const auto conf = cast_config_to<vertical_scrollbar_definition>();
60 return conf->bottom_offset;
105 load_resolutions<resolution>(cfg);
110 , minimum_positioner_length(cfg[
"minimum_positioner_length"].to_unsigned())
111 , maximum_positioner_length(cfg[
"maximum_positioner_length"].to_unsigned())
112 , top_offset(cfg[
"top_offset"].to_unsigned())
113 , bottom_offset(cfg[
"bottom_offset"].to_unsigned())
117 "minimum_positioner_length"));
131 builder_vertical_scrollbar::builder_vertical_scrollbar(
const config& cfg)
138 auto widget = std::make_unique<vertical_scrollbar>(*
this);
143 <<
" placed vertical scrollbar '" <<
id <<
"' with definition '"
A config object defines a single node in a WML file, with access to child nodes.
Contains the implementation details for lexical_cast and shouldn't be used directly.
map_location coordinate
Contains an x and y coordinate used for starting positions in maps.
std::vector< state_definition > state
An abstract description of a rectangle with integer coordinates.
bool contains(int x, int y) const
Whether the given point lies within the rectangle.
std::string missing_mandatory_wml_tag(const std::string §ion, const std::string &tag)
Returns a standard message for a missing wml child (tag).
std::string missing_mandatory_wml_key(const std::string §ion, const std::string &key, const std::string &primary_key, const std::string &primary_value)
Returns a standard message for a missing wml key (attribute).
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)
#define VALIDATE(cond, message)
The macro to use for the validation of WML.