edifice.ScrollBar#

class edifice.ScrollBar(value=0, minimum=0, maximum=100, step_single=None, step_page=None, orientation=<Orientation.Vertical: 2>, on_value_changed=None, on_slider_pressed=None, on_slider_released=None, **kwargs)[source]#

Bases: QtWidgetElement[QScrollBar]

Scroll bar widget.

Render a scroll bar widget that allows the user to scroll through a range of values.

Props

All props from QtWidgetElement plus:

Parameters:
  • value (int) – The current value of the scroll bar.

  • minimum (int) – The minimum value of the scroll bar.

  • maximum (int) – The maximum value of the scroll bar.

  • step_single (Optional[int]) – The step size for arrow keys.

  • step_page (Optional[int]) – The step size for PgUp/PgDown keys.

  • orientation (Orientation) – The scroll bar Orientation.

  • on_value_changed (Optional[Callable[[int], None | Awaitable[None]]]) – Callback for when the value of the scroll bar changes.

  • on_slider_pressed (Optional[Callable[[], None | Awaitable[None]]]) – Callback for when the slider is pressed.

  • on_slider_released (Optional[Callable[[], None | Awaitable[None]]]) – Callback for when the slider is released.

Methods

__init__([value, minimum, maximum, ...])

register_ref(reference)

Registers provided Reference to this Element.

set_key(key)

Set the key of an Element.

Attributes

children

The children of this Element.

props

The props of this Element.

underlying

The underlying QWidget, which may not exist if this Element has not rendered.