Loading...
Searching...
No Matches
Go to the documentation of this file.
22#define PT_UNWRAP_TILESET_CONFIG_PTR(ptr, config, tileset_name, return_type) \
23 auto config##_result = ptr->config(ConfigScopeType::tileset, tileset_name); \
24 if (!config##_result.has_value()) { \
25 return ChainableResult<return_type>{ \
27 "Failed to get config value '{}:{}:{}'.", \
28 FormatParam{"tileset", Style::bold}, \
29 FormatParam{tileset_name, Style::bold}, \
30 FormatParam{#config, Style::bold}}, \
33 auto config = std::move(config##_result).value();
50#define PT_UNWRAP_TILESET_CONFIG_REF(ref, config, tileset_name, return_type) \
51 auto config##_result = ref.config(ConfigScopeType::tileset, tileset_name); \
52 if (!config##_result.has_value()) { \
53 return ChainableResult<return_type>{ \
55 "Failed to get config value '{}:{}:{}'.", \
56 FormatParam{"tileset", Style::bold}, \
57 FormatParam{tileset_name, Style::bold}, \
58 FormatParam{#config, Style::bold}}, \
61 auto config = std::move(config##_result).value();
77#define PT_UNWRAP_LAYOUT_CONFIG(ptr, config, layout_name, return_type) \
78 auto config##_result = ptr->config(ConfigScopeType::layout, layout_name); \
79 if (!config##_result.has_value()) { \
80 return ChainableResult<return_type>{ \
82 "Failed to get config value '{}:{}:{}'.", \
83 FormatParam{"layout", Style::bold}, \
84 FormatParam{layout_name, Style::bold}, \
85 FormatParam{#config, Style::bold}}, \
88 auto config = std::move(config##_result).value();