Skip to main content

mask_widget::MaskBrushSelectionWidget

mask_widget::MaskBrushSelectionWidget

Widget for the “Brush” selection mode. More…

#include <MaskBrushSelectionWidget.hpp>

Inherits from QWidget

Public Signals

Name
void brushSizeChanged(int size)
Signal emitted when brush size is changed.
void hoverCircleVisibilityChanged(bool visible)
Signal emitted when hover circle visibility is toggled.
void allowEmptyMaskChanged(bool allow)
Signal emitted when allow empty mask setting is toggled.

Public Functions

Name
MaskBrushSelectionWidget(QWidget * parent =[nullptr])
Constructor.
~MaskBrushSelectionWidget()
Destructor.
int getBrushSize() const
Get the current brush size.
void setBrushSize(int size)
Set the brush size.
bool isHoverCircleVisible() const
Get the current hover circle visibility state.
void setHoverCircleVisible(bool visible)
Set the hover circle visibility.
bool isAllowEmptyMask() const
Get the current allow empty mask state.
void setAllowEmptyMask(bool allow)
Set the allow empty mask state.

Detailed Description

class mask_widget::MaskBrushSelectionWidget;

Widget for the “Brush” selection mode.

This widget provides UI for both adding to and erasing from mask areas:

  • Left click adds to the mask
  • Right click erases from the mask
  • Brush size adjustment affects both operations
  • Hover circle visibility can be toggled

Public Signals Documentation

signal brushSizeChanged

void brushSizeChanged(
    int size
)

Signal emitted when brush size is changed.

Parameters:

  • size The new brush size value

signal hoverCircleVisibilityChanged

void hoverCircleVisibilityChanged(
    bool visible
)

Signal emitted when hover circle visibility is toggled.

Parameters:

  • visible Whether the hover circle should be visible

signal allowEmptyMaskChanged

void allowEmptyMaskChanged(
    bool allow
)

Signal emitted when allow empty mask setting is toggled.

Parameters:

  • allow Whether empty masks should be preserved

Public Functions Documentation

function MaskBrushSelectionWidget

explicit MaskBrushSelectionWidget(
    QWidget * parent =nullptr
)

Constructor.

Parameters:

  • parent The parent widget

function ~MaskBrushSelectionWidget

~MaskBrushSelectionWidget()

Destructor.

function getBrushSize

int getBrushSize() const

Get the current brush size.

Return: The current brush size value

function setBrushSize

void setBrushSize(
    int size
)

Set the brush size.

Parameters:

  • size The new size value

function isHoverCircleVisible

bool isHoverCircleVisible() const

Get the current hover circle visibility state.

Return: Whether the hover circle is visible

function setHoverCircleVisible

void setHoverCircleVisible(
    bool visible
)

Set the hover circle visibility.

Parameters:

  • visible Whether the hover circle should be visible

function isAllowEmptyMask

bool isAllowEmptyMask() const

Get the current allow empty mask state.

Return: Whether empty masks should be preserved

function setAllowEmptyMask

void setAllowEmptyMask(
    bool allow
)

Set the allow empty mask state.

Parameters:

  • allow Whether empty masks should be preserved

Updated on 2026-11-13 at 20:25:42 +0000