class

MCheckBox

Module
Miri
Header
#include "Miri/Widgets/MCheckBox.h"
Namespace
Miri

Public functions

ReturnsNameDescription
MIRI_WIDGET_ARGS"Don't ask again"), not a setting of its own.
WidgetArgsType&AnimateHover
MIRI_WIDGET_ARGS_END
MiriVec2ComputeDesiredSize
int32_tOnPaint
CReplyOnMouseButtonDown
CReplyOnMouseButtonUp
CReplyOnMouseMove
voidOnMouseEnter
voidOnMouseLeave
voidSetIsChecked
boolIsChecked
voidSetCheckState
ECheckBoxStateGetCheckState
voidSetHasErrorThe design's error state: an Error-coloured border, nothing else.
boolHasError
voidSetLabel
const std::string&GetLabel
floatGetBoxSizeThe box edge: the spec's 14 px unless a host asked for another size.
floatGetFocusRadius
boolCanCacheDesiredSizeA square of m_size.
boolCanRetainPaintA leaf.
const char*GetTypeName
EAccessibleRoleGetAccessibleRole
std::stringGetAccessibleValue
boolIsFocusable
boolOnActivate
voidSetAnimateHover

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 override

OnPaint

C++
int32_t OnPaint(const CMiriPaintArgs& args, const CGeometry& geo, CMiriRenderer& renderer, int32_t layerId) const override

OnMouseButtonDown

C++
CReply OnMouseButtonDown(const CGeometry& geo, const CPointerEvent& event) override

OnMouseButtonUp

C++
CReply OnMouseButtonUp(const CGeometry& geo, const CPointerEvent& event) override

OnMouseMove

C++
CReply OnMouseMove(const CGeometry& geo, const CPointerEvent& event) override

OnMouseEnter

C++
void OnMouseEnter(const CGeometry& geo, const CPointerEvent& event) override

OnMouseLeave

C++
void OnMouseLeave(const CPointerEvent& event) override

SetIsChecked

C++
void SetIsChecked(bool checked)

IsChecked

C++
bool IsChecked() const

SetCheckState

C++
void SetCheckState(ECheckBoxState state)

GetCheckState

C++
ECheckBoxState GetCheckState() const

SetHasError

C++
void SetHasError(bool hasError)

The design's error state: an Error-coloured border, nothing else.

HasError

C++
bool HasError() const

SetLabel

C++
void SetLabel(const std::string& label)

GetLabel

C++
const std::string& GetLabel() const

GetBoxSize

C++
float GetBoxSize() const

The box edge: the spec's 14 px unless a host asked for another size.

GetFocusRadius

C++
float GetFocusRadius() const override

CanCacheDesiredSize

C++
bool CanCacheDesiredSize() const override

A 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 override

A 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 override

GetAccessibleRole

C++
EAccessibleRole GetAccessibleRole() const override

GetAccessibleValue

C++
std::string GetAccessibleValue() const override

IsFocusable

C++
bool IsFocusable() const override

OnActivate

C++
bool OnActivate() override

SetAnimateHover

C++
void SetAnimateHover(bool animate)
Generated from Miri/Widgets/MCheckBox.h via miri.json · Dec 5, 2026Version 1.1.0