struct mola::gui::CheckBox
Overview
A boolean toggle.
value is read at construction time to set the initial state. on_change is called (in the GUI thread) when the user toggles. The callback is responsible for any thread-safe propagation (e.g. via enqueue_request).
nanogui : nanogui::CheckBox. ImGui : ImGui::Checkbox.
#include <GuiWidgetDescription.h> struct CheckBox { // fields std::string label; bool initial_value = false; std::function<void(bool)> on_change; };
Fields
std::function<void(bool)> on_change
Called from GUI thread.