#include <context_menu.hpp>
|
| static Item | make_separator () |
| static Item | make_header (std::string title) |
| static Item | make_toggle (int id, std::string label, bool checked, std::function< void(const Item &)> on_change) |
| static Item | make_slider (int id, std::string label, float normalized, float step, std::function< void(const Item &)> on_change) |
| static Item | make_choice (int id, std::string label, std::vector< std::string > choices, std::size_t selected, std::function< void(const Item &)> on_change) |
◆ ControlKind
| Enumerator |
|---|
| action | |
| toggle | |
| slider | |
| choice | |
◆ make_choice()
| Item pulp::view::ContextMenu::Item::make_choice |
( |
int | id, |
|
|
std::string | label, |
|
|
std::vector< std::string > | choices, |
|
|
std::size_t | selected, |
|
|
std::function< void(const Item &)> | on_change ) |
|
inlinestatic |
◆ make_header()
| Item pulp::view::ContextMenu::Item::make_header |
( |
std::string | title | ) |
|
|
inlinestatic |
◆ make_separator()
| Item pulp::view::ContextMenu::Item::make_separator |
( |
| ) |
|
|
inlinestatic |
◆ make_slider()
| Item pulp::view::ContextMenu::Item::make_slider |
( |
int | id, |
|
|
std::string | label, |
|
|
float | normalized, |
|
|
float | step, |
|
|
std::function< void(const Item &)> | on_change ) |
|
inlinestatic |
◆ make_toggle()
| Item pulp::view::ContextMenu::Item::make_toggle |
( |
int | id, |
|
|
std::string | label, |
|
|
bool | checked, |
|
|
std::function< void(const Item &)> | on_change ) |
|
inlinestatic |
◆ set_choice_index()
| void pulp::view::ContextMenu::Item::set_choice_index |
( |
std::size_t | value | ) |
|
|
inline |
◆ set_normalized_value()
| void pulp::view::ContextMenu::Item::set_normalized_value |
( |
float | value | ) |
|
|
inline |
◆ set_toggled()
| void pulp::view::ContextMenu::Item::set_toggled |
( |
bool | value | ) |
|
|
inline |
◆ checked
| bool pulp::view::ContextMenu::Item::checked = false |
◆ choice_index
| std::size_t pulp::view::ContextMenu::Item::choice_index = 0 |
◆ choices
| std::vector<std::string> pulp::view::ContextMenu::Item::choices |
◆ control_kind
◆ enabled
| bool pulp::view::ContextMenu::Item::enabled = true |
◆ has_submenu
| bool pulp::view::ContextMenu::Item::has_submenu = false |
◆ header
| bool pulp::view::ContextMenu::Item::header = false |
A non-selectable title row that groups the items below it.
◆ id
| int pulp::view::ContextMenu::Item::id = 0 |
◆ label
| std::string pulp::view::ContextMenu::Item::label |
◆ normalized_step
| float pulp::view::ContextMenu::Item::normalized_step = 0.05f |
◆ normalized_value
| float pulp::view::ContextMenu::Item::normalized_value = 0.0f |
◆ on_change
| std::function<void(const Item&)> pulp::view::ContextMenu::Item::on_change |
◆ separator
| bool pulp::view::ContextMenu::Item::separator = false |
◆ tab
| bool pulp::view::ContextMenu::Item::tab = false |
A toggle that is one of several sibling tabs (an "edit lane 1 /
edit lane 2" pair): painted as a row with a leading accent bar when checked instead of a switch, since it selects rather than enables.
◆ value_label
| std::string pulp::view::ContextMenu::Item::value_label |
Text shown at the right end of a slider row ("2.50 Hz", "65%").
When set, the track stops short of it so the thumb never runs under the text; the product keeps it current from on_change.
The documentation for this struct was generated from the following file: