File GuiWidgetDescription.h

Parent directory (include/mola_kernel)

Backend-agnostic description of a GUI sub-window and its widgets.

Definition (include/mola_kernel/GuiWidgetDescription.h)

Detailed Description

Design goals

  • Pure data / std types - no GUI toolkit headers required by clients.

  • Compatible with both nanogui (retained mode) and Dear ImGui docking branch (immediate mode).

  • Thread-safe label updates via LiveString.

  • Widget values are bound to caller-owned variables (T*) so the module always holds ground truth; the GUI is a view of it.

Nanogui mapping notes

WindowDescription → nanogui::Window inside CDisplayWindowGUI Tab → nanogui::TabWidget + one tab per Tab entry Row → nanogui::Widget with BoxLayout(Horizontal) Label → nanogui::Label (caption refreshed via LiveString::poll) Separator → zero-height nanogui::Widget used as spacer CheckBox → nanogui::CheckBox Button → nanogui::Button (ENTYPO icon optional, ignored if 0) TextBox → nanogui::TextBox (editable) SliderFloat → nanogui::Slider + adjacent nanogui::Label showing value SliderInt → same, integer clamped ComboBox → nanogui::ComboBox

Dear ImGui (docking branch) mapping notes

WindowDescription → ImGui::Begin / End. position/size passed as ImGuiCond_FirstUseEver so the dock manager can freely override them. Tab → ImGui::BeginTabBar / ImGui::BeginTabItem Row → consecutive widgets separated by ImGui::SameLine() Label → ImGui::TextUnformatted (reads LiveString each frame) Separator → ImGui::Separator() CheckBox → ImGui::Checkbox (binds directly to bool*) Button → ImGui::Button; callback fired when returns true TextBox → ImGui::InputText (uses internal 256-byte buffer, flushed to std::string* on every edit) SliderFloat → ImGui::SliderFloat SliderInt → ImGui::SliderInt ComboBox → ImGui::Combo

Jose Luis Blanco Claraco

2026

Includes

Included By

Namespaces

Classes

Typedefs