class
MCheckBox
- Module
- Miri
- Header
#include "Miri/Widgets/MCheckBox.h"- Namespace
Miri
Public functions
| Returns | Name | Description |
|---|---|---|
MIRI_WIDGET_ARGS | "Don't ask again"), not a setting of its own. | |
WidgetArgsType& | AnimateHover | |
MIRI_WIDGET_ARGS_END | ||
MiriVec2 | ComputeDesiredSize | |
int32_t | OnPaint | |
CReply | OnMouseButtonDown | |
CReply | OnMouseButtonUp | |
CReply | OnMouseMove | |
void | OnMouseEnter | |
void | OnMouseLeave | |
void | SetIsChecked | |
bool | IsChecked | |
void | SetCheckState | |
ECheckBoxState | GetCheckState | |
void | SetHasError | The design's error state: an Error-coloured border, nothing else. |
bool | HasError | |
void | SetLabel | |
const std::string& | GetLabel | |
float | GetBoxSize | The box edge: the spec's 14 px unless a host asked for another size. |
float | GetFocusRadius | |
bool | CanCacheDesiredSize | A square of m_size. |
bool | CanRetainPaint | A leaf. |
const char* | GetTypeName | |
EAccessibleRole | GetAccessibleRole | |
std::string | GetAccessibleValue | |
bool | IsFocusable | |
bool | OnActivate | |
void | SetAnimateHover |
Function details
MIRI_WIDGET_ARGS
C++
MIRI_WIDGET_ARGS(MCheckBox) MIRI_ATTR(bool, IsChecked) MIRI_EVENT(COnBoolChanged, OnCheckStateChanged) MIRI_ATTR(MiriColor, CheckedColor) MIRI_ATTR(MiriColor, UncheckedColor) MIRI_ARG(float, Size) MIRI_ARG(std::string, Label) MIRI_ARG(bool, QuietLabel) bool _AnimateHover = true"Don't ask again"), not a setting of its own.
AnimateHover
C++
WidgetArgsType& AnimateHover(bool value)MIRI_WIDGET_ARGS_END
C++
MIRI_WIDGET_ARGS_END() void Construct(const CArguments& args)ComputeDesiredSize
C++
MiriVec2 ComputeDesiredSize(float scale) const overrideOnPaint
C++
int32_t OnPaint(const CMiriPaintArgs& args, const CGeometry& geo, CMiriRenderer& renderer, int32_t layerId) const overrideOnMouseButtonDown
C++
CReply OnMouseButtonDown(const CGeometry& geo, const CPointerEvent& event) overrideOnMouseButtonUp
C++
CReply OnMouseButtonUp(const CGeometry& geo, const CPointerEvent& event) overrideOnMouseMove
C++
CReply OnMouseMove(const CGeometry& geo, const CPointerEvent& event) overrideOnMouseEnter
C++
void OnMouseEnter(const CGeometry& geo, const CPointerEvent& event) overrideOnMouseLeave
C++
void OnMouseLeave(const CPointerEvent& event) overrideSetIsChecked
C++
void SetIsChecked(bool checked)IsChecked
C++
bool IsChecked() constSetCheckState
C++
void SetCheckState(ECheckBoxState state)GetCheckState
C++
ECheckBoxState GetCheckState() constSetHasError
C++
void SetHasError(bool hasError)The design's error state: an Error-coloured border, nothing else.
HasError
C++
bool HasError() constSetLabel
C++
void SetLabel(const std::string& label)GetLabel
C++
const std::string& GetLabel() constGetBoxSize
C++
float GetBoxSize() constThe box edge: the spec's 14 px unless a host asked for another size.
GetFocusRadius
C++
float GetFocusRadius() const overrideCanCacheDesiredSize
C++
bool CanCacheDesiredSize() const overrideA square of m_size. Check state and hover drive the paint, never the measure, so neither can move the desired size.
CanRetainPaint
C++
bool CanRetainPaint() const overrideA leaf. Refused while the hover fade runs — that is a clock nothing invalidates on — and whenever a bound attribute could hand back a new check state or colour with no write to see. The enter/move/leave handlers drop the slice so the settled frame cannot replay the box from before the fade.
GetTypeName
C++
const char* GetTypeName() const overrideGetAccessibleRole
C++
EAccessibleRole GetAccessibleRole() const overrideGetAccessibleValue
C++
std::string GetAccessibleValue() const overrideIsFocusable
C++
bool IsFocusable() const overrideOnActivate
C++
bool OnActivate() overrideSetAnimateHover
C++
void SetAnimateHover(bool animate)Generated from Miri/Widgets/MCheckBox.h via miri.json · Dec 5, 2026Version 1.1.0