#include <st-ui.h>
|
| static void | HelpMarker (const char *desc) |
| | Draw a ? that pops up some help text in SKSE Menu Framework.
|
| template<class T> |
| static bool | SettingSlider (const char *a_label, T &a_sliderVariable, const T &a_sliderMin, const T &a_sliderMax, const char *a_sliderFormat, const char *a_helpText, const float a_sliderWidth=200.0f, const std::function< void(T)> &a_onSliderChanged=nullptr) |
| | Template to easily set up a slider with help text and have it optionally run a function if the slider changed.
|
| static bool | SetCheckbox (const char *a_label, bool &a_settingVariable, const char *a_helpText, const std::function< void(bool)> &a_onCheckbox=nullptr) |
◆ HelpMarker()
| void StyyxUtil::UIUtil::HelpMarker |
( |
const char * | desc | ) |
|
|
inlinestatic |
Draw a ? that pops up some help text in SKSE Menu Framework.
- Parameters
-
| desc | Help text that should be shown |
- Note
- Credits to: QTR-Modding
◆ SetCheckbox()
| bool StyyxUtil::UIUtil::SetCheckbox |
( |
const char * | a_label, |
|
|
bool & | a_settingVariable, |
|
|
const char * | a_helpText, |
|
|
const std::function< void(bool)> & | a_onCheckbox = nullptr ) |
|
inlinestatic |
◆ SettingSlider()
template<class T>
| bool StyyxUtil::UIUtil::SettingSlider |
( |
const char * | a_label, |
|
|
T & | a_sliderVariable, |
|
|
const T & | a_sliderMin, |
|
|
const T & | a_sliderMax, |
|
|
const char * | a_sliderFormat, |
|
|
const char * | a_helpText, |
|
|
const float | a_sliderWidth = 200.0f, |
|
|
const std::function< void(T)> & | a_onSliderChanged = nullptr ) |
|
inlinestatic |
Template to easily set up a slider with help text and have it optionally run a function if the slider changed.
- Template Parameters
-
- Parameters
-
| a_label | Name of the slider (visible) |
| a_sliderVariable | Variable of the slider to change |
| a_sliderMin | Minimum value of the slider |
| a_sliderMax | Maximum value of the slider |
| a_sliderFormat | Formatting for the slider |
| a_helpText | Help text that's shown |
| a_sliderWidth | Slider width. Default = 200.0 |
| a_onSliderChanged | Function to run when the slider changed |
- Returns
- True if slider changed
- Note
- Example. This Gives you a float slider with 2 decimals and changes a REX::TOML::F32 setting if the slider changes
SettingSlider(
"ManipToml", m_TempFloat, 0.0f, 100.0f,
"%.2f",
"This slider will change a toml setting", 300.0f, [&](
float var){mySetting.SetValue(var);});
static bool SettingSlider(const char *a_label, T &a_sliderVariable, const T &a_sliderMin, const T &a_sliderMax, const char *a_sliderFormat, const char *a_helpText, const float a_sliderWidth=200.0f, const std::function< void(T)> &a_onSliderChanged=nullptr)
Template to easily set up a slider with help text and have it optionally run a function if the slider...
Definition st-ui.h:42
The documentation for this struct was generated from the following file: