3#include <cgv/gui/gui_group.h>
4#include <cgv/gui/window.h>
6#include <cgv/utils/token.h>
7#include <cgv/utils/tokenizer.h>
18 enum class SectionType {
29 SectionType
type = SectionType::kText;
33 std::vector<section> sections;
35 void add_section(SectionType
type,
const std::string& content) {
36 sections.push_back({
type, content });
41 std::vector<gui_group_ptr> groups;
52 void on_register()
override;
55 void unregister()
override;
62 add_section(SectionType::kHeading1, text);
67 add_section(SectionType::kHeading2, text);
72 add_section(SectionType::kHeading3, text);
77 add_section(SectionType::kHeading4, text);
82 add_section(SectionType::kText, text);
89 add_section(SectionType::kItems, items);
96 add_section(SectionType::kKeyBindings, key_bindings);
111 static_assert(std::is_base_of<help_menu_entry, T>::value,
"T must inherit from cgv::gui::help_menu_entry");
119#include <cgv/config/lib_end.h>
std::string name
store the name as a string
The node class keeps a pointer to its parent.
node(const std::string &name="")
construct from name
the base namespace holds the base hierarchy, support for plugin registration and signals
void register_object(base_ptr object, const std::string &options)
register an object and send event to all current registration ref_listeners()
namespace that holds the abstract gui interface
data::ref_ptr< window > window_ptr
ref counted pointer to &window
namespace for compile time type information
this header is dependency free
Helper functions to process strings.
implementation of factory for objects of type T using the standard constructor