Class: QgsBlendModeComboBox

A combobox which lets the user select blend modes from a predefined list.

Class Hierarchy

Inheritance diagram of qgis.gui.QgsBlendModeComboBox

Base classes

QComboBox

QWidget

QObject

QPaintDevice

class qgis.gui.QgsBlendModeComboBox[source]

Bases: QComboBox

__init__(parent: QWidget | None = None)

Constructor for QgsBlendModeComboBox

Parameters:

parent (Optional[QWidget] = None)

blendMode(self) QPainter.CompositionMode[source]

Returns the selected blend mode.

See also

setBlendMode()

Return type:

QPainter.CompositionMode

setBlendMode(self, blendMode: QPainter.CompositionMode)[source]

Sets the selected blend mode.

See also

blendMode()

Parameters:

blendMode (QPainter.CompositionMode)

setShowClippingModes(self, show: bool)[source]

Sets whether composition modes which cause clipping are shown in the combo box.

By default, these composition modes (such as QPainter.CompositionMode.CompositionMode_DestinationIn ) are not shown in the combo box, as they can only be used with predictable results in a limited set of circumstances. By setting show to True these additional composition modes will be shown in the combo box.

Added in version 3.24.

Parameters:

show (bool)

showClippingModes(self) bool[source]

Returns True if composition modes which cause clipping are shown in the combo box.

By default, these composition modes (such as QPainter.CompositionMode.CompositionMode_DestinationIn ) are not shown in the combo box, as they can only be used with predictable results in a limited set of circumstances.

Added in version 3.24.

Return type:

bool

updateModes(self)[source]

Populates the blend mode combo box, and sets up mapping for blend modes to combo box indexes