TreeWidgetItem¶
-
class
cgp_generic_utils.qt.TreeWidgetItem(parent=None)¶ Bases:
PySide2.QtWidgets.QTreeWidgetItemQTreeWidgetItem with custom functionalities
-
addWidget(widget, index)¶ add the specified widget to the specified column of the QTreeWidgetItem
Parameters: - widget (
PySide2.QtWidgets.QWidget) – widget to add the the QTreeWidgetItem - index (int) – index of the column where to add the widget
- widget (
-
childrenItems(recursive=False)¶ get the children items parented to the QTreeWidgetItem
Parameters: recursive (bool) – defines whether or not the command will get the children items recursively through hierarchy Returns: list of children Return type: list[ PySide2.QtWidgets.QTreeWidgetItem,cgp_generic_utils.qt.TreeWidgetItem]
-
setBackgrounds(indexes, color=None, pattern='solid')¶ set background colors of the columns of the specified indexes using the specified color and pattern
Parameters:
-
setFonts(indexes, size=9, styles=None)¶ set fonts of the columns of the specified indexes using the specified size and styles
Parameters: Type:
-
setForegrounds(indexes, color=None, pattern='solid')¶ set foreground colors of the columns of the specified indexes using the specified color and pattern
Parameters:
-
setIcons(indexes, icon)¶ set the icon of the specified column of the custom QTreeWidgetItem
Parameters:
-