Horizontal numeric view using the existing control style, layout and input runtime. NumericValue remains authoritative through its binding. Paint reads only prepared presentation.
More...
#include <slider.hpp >
portals::Slider portals::Slider
Control (GraphemeText text, std::string_view prefix, std::string_view suffix, ControlStyle style, SizePolicy policy)
Own text/options and create fixed ASCII decorations under the text's validated width policy.
Control (GraphemeText text, GraphemeText prefix, GraphemeText checkedPrefix, ControlStyle style, SizePolicy policy)
Own explicitly validated equal-width boolean decorations; no additional retained fields.
bool booleanChromeMatches () const
std::expected< void, TreeError > paintCaption (PaintContext &context, bool stretchChrome)
Paint the synchronized caption with intrinsic or allocated-width decorations.
void showChecked (bool checked)
Select a same-width prefix between frames; used only by the checkbox binding.
bool shownChecked () const
Inspect the single checked presentation flag on UI.
void showMixed (bool mixed)
Select the fixed mixed decoration after caller-owned paint invalidation.
Horizontal numeric view using the existing control style, layout and input runtime. NumericValue remains authoritative through its binding. Paint reads only prepared presentation.
◆ Slider()
Parameters
width Complete receiving text policy used to prepare track, fill and thumb glyphs.
options Intrinsic extent, page increment, paint cap, user-mutation policy and owning glyph selection.
style Owning manual appearances beneath ordinary theme rules.
policy Owning layout constraints validated by the layout owner. Constructor arguments and glyph construction may throw; tree emplacement translates internal failures.
◆ arrange()
Parameters
local Parent-local allocation; only the extent is retained.
Returns Success or INVALID_GEOMETRY; no model reads or callbacks occur.
Reimplemented from portals::Control .
◆ measure()
Parameters
available Offered extent, ignored for intrinsic width.
Returns Configured width and height one, or INVALID_ARGUMENT for invalid options.
Reimplemented from portals::Control .
◆ paint()
Parameters
context Synchronous sink borrowing this widget's glyphs through the frame.
Returns Success, WOULD_BLOCK above the paint cap, or the unchanged sink error.
Reimplemented from portals::Control .
◆ range()
Returns Last synchronized validated bounds and user increment.
◆ readOnly()
bool portals::Slider::readOnly
(
)
const
inline noexcept
Returns Whether user mutation is currently prohibited; focus remains available.
◆ styleReadOnly()
bool portals::Slider::styleReadOnly
(
)
const
inline override virtual noexcept
Returns Whether the read-only style selector matches this slider.
Reimplemented from portals::Widget .
◆ value()
double portals::Slider::value
(
)
const
inline noexcept
Returns Last synchronized finite numeric value; borrow the widget only inside checked tree access.
◆ setSliderReadOnly
Parameters
tree Borrowed UI tree.
node Live slider.
readOnly New user-mutation policy.
Returns Checked tree result; equal settings do not invalidate. Programmatic writes remain allowed.
The documentation for this class was generated from the following file: