GGUI::FieldInfo struct

One field of a type. The strings are only valid during the visit.

Public functions

template<typename T>
auto Get(const GGHint<T>& hint) const -> std::optional<T>
The value of hint on this field; none if it hasn't the hint.
template<typename T>
auto Get(const GGHint<T>& hint, std::type_identity_t<T> fallback) const -> T
The value of hint on this field, or fallback.

Public variables

uint64_t ID
stable across builds; use it as the key
FieldID Field
what a binding reads for its value; NoField if it has none
TypeID Type
picks its editor
std::string_view Name
as in code
std::string_view DisplayName
as shown
std::string_view Category
the group it is shown in; empty: none
std::string_view Tooltip
shown on its label; empty: none
bool bReadOnly
std::span<const GGFieldHint> Hints
Editor hints (UIHints.h). Valid during the visit.

Variable documentation

bool GGUI::FieldInfo::bReadOnly

shown, not edited