picker_base

Module Contents

SeparatorWidget

Separator widget

ItemMaskWidget

Item mask widget

PickerColumnFormatter

Picker column formatter

DigitFormatter

Digit formatter

PickerColumnButton

Picker column button

PickerBase

Picker base class

PickerToolButton

Picker tool button

PickerPanel

picker panel

checkColumnIndex(func)

check whether the index is out of range

class SeparatorWidget(orient: PyQt5.QtCore.Qt.Orientation, parent=None)

Bases: PyQt5.QtWidgets.QWidget

Separator widget

class ItemMaskWidget(listWidgets: List[qfluentwidgets.components.widgets.cycle_list_widget.CycleListWidget], parent=None)

Bases: PyQt5.QtWidgets.QWidget

Item mask widget

paintEvent(e)
class PickerColumnFormatter

Bases: PyQt5.QtCore.QObject

Picker column formatter

encode(value)

convert original value to formatted value

decode(value: str)

convert formatted value to original value

class DigitFormatter

Bases: PickerColumnFormatter

Digit formatter

decode(value)

convert formatted value to original value

class PickerColumnButton(name: str, items: Iterable, width: int, align=Qt.AlignLeft, formatter=None, parent=None)

Bases: PyQt5.QtWidgets.QPushButton

Picker column button

align()
setAlignment(align=Qt.AlignCenter)

set the text alignment

value() str
setValue(v)
items()
setItems(items: Iterable)
formatter()
setFormatter(formatter)
name()
setName(name: str)
checkColumnIndex(func)

check whether the index is out of range

class PickerBase(parent=None)

Bases: PyQt5.QtWidgets.QPushButton

Picker base class

addColumn(name: str, items: Iterable, width: int, align=Qt.AlignCenter, formatter: PickerColumnFormatter = None)

add column

Parameters

name: str

the name of column

items: Iterable

the items of column

width: int

the width of column

align: Qt.AlignmentFlag

the text alignment of button

formatter: PickerColumnFormatter

the formatter of column

setColumnAlignment(index: int, align=Qt.AlignCenter)

set the text alignment of specified column

setColumnWidth(index: int, width: int)

set the width of specified column

setColumnTight(index: int)

make the specified column to be tight

setColumnVisible(index: int, isVisible: bool)

set the text alignment of specified column

value()
initialValue()
setColumnValue(index: int, value)
setColumnInitialValue(index: int, value)
setColumnFormatter(index: int, formatter: PickerColumnFormatter)
setColumnItems(index: int, items: Iterable)
encodeValue(index: int, value)

convert original value to formatted value

decodeValue(index: int, value)

convert formatted value to origin value

setColumn(index: int, name: str, items: Iterable, width: int, align=Qt.AlignCenter)

set column

Parameters

index: int

the index of column

name: str

the name of column

items: Iterable

the items of column

width: int

the width of column

align: Qt.AlignmentFlag

the text alignment of button

clearColumns()

clear columns

enterEvent(e)
leaveEvent(e)
mousePressEvent(e)
mouseReleaseEvent(e)
panelInitialValue()

initial value of panel

class PickerToolButton(parent: PyQt5.QtWidgets.QWidget = None)

Bases: qfluentwidgets.components.widgets.button.TransparentToolButton

Picker tool button

class PickerPanel(parent=None)

Bases: PyQt5.QtWidgets.QWidget

picker panel

confirmed
columnValueChanged
setShadowEffect(blurRadius=30, offset=(0, 8), color=QColor(0, 0, 0, 30))

add shadow to dialog

addColumn(items: Iterable, width: int, align=Qt.AlignCenter)

add one column to view

Parameters

items: Iterable[Any]

the items to be added

width: int

the width of item

align: Qt.AlignmentFlag

the text alignment of item

resizeEvent(e)
value()

return the value of columns

setValue(value: list)

set the value of columns

columnValue(index: int) str

return the value of specified column

setColumnValue(index: int, value: str)

set the value of specified column

column(index: int)

return the list widget of specified column

exec(pos, ani=True)

show panel

Parameters

pos: QPoint

pop-up position

ani: bool

Whether to show pop-up animation