Inherited by: QStyleOptionViewItemV3, QStyleOptionViewItemV4
The PySide.QtGui.QStyleOptionViewItemV2 class is used to describe the parameters necessary for drawing a frame in Qt 4.2 or above.
PySide.QtGui.QStyleOptionViewItemV2 inherits PySide.QtGui.QStyleOptionViewItem .
An instance of the PySide.QtGui.QStyleOptionViewItemV2 class has type SO_ViewItem and version 2. The type is used internally by PySide.QtGui.QStyleOption , its subclasses, and qstyleoption_cast() to determine the type of style option. In general you do not need to worry about this unless you want to create your own PySide.QtGui.QStyleOption subclass and your own styles. The version is used by PySide.QtGui.QStyleOption subclasses to implement extensions without breaking compatibility. If you use qstyleoption_cast() , you normally do not need to check it.
See PySide.QtGui.QStyleOptionFrameV2 ‘s detailed description for a discussion of how to handle “V2” classes.
Parameters: |
|
---|
Constructs a PySide.QtGui.QStyleOptionViewItemV2 object.
Constructs a PySide.QtGui.QStyleOptionViewItemV2 copy of the other style option which can be either of the PySide.QtGui.QStyleOptionViewItemV2 or PySide.QtGui.QStyleOptionViewItem types.
If the other style option’s version is 1, the new style option’s QStyleOptionViewItemV2.ViewItemFeature value is set to QStyleOptionViewItemV2.None . If its version is 2, its QStyleOptionViewItemV2.ViewItemFeature value is simply copied to the new style option.
See also
version
Constructs a copy of other .
This enum is used to hold information about the version of the style option, and is defined for each PySide.QtGui.QStyleOption subclass.
Constant | Description |
---|---|
QStyleOptionViewItemV2.Version | 2 |
The version is used by PySide.QtGui.QStyleOption subclasses to implement extensions without breaking compatibility. If you use qstyleoption_cast() , you normally do not need to check it.
See also
QStyleOptionViewItem.StyleOptionType
This enum describes the different types of features an item can have.
Constant | Description |
---|---|
QStyleOptionViewItemV2.None | Indicates a normal item. |
QStyleOptionViewItemV2.WrapText | Indicates an item with wrapped text. |
QStyleOptionViewItemV2.Alternate | Indicates that the item’s background is rendered using alternateBase. |
QStyleOptionViewItemV2.HasCheckIndicator | Indicates that the item has a check state indicator. |
QStyleOptionViewItemV2.HasDisplay | Indicates that the item has a display role. |
QStyleOptionViewItemV2.HasDecoration | Indicates that the item has a decoration role. |