|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.trolltech.qt.internal.QSignalEmitterInternal
com.trolltech.qt.QSignalEmitter
com.trolltech.qt.QtJambiObject
com.trolltech.qt.gui.QStyleOption
com.trolltech.qt.gui.QStyleOptionViewItem
public class QStyleOptionViewItem
The QStyleOptionViewItem class is used to describe the parameters used to draw an item in a view widget. QStyleOptionViewItem contains all the information that QStyle
functions need to draw the items for Qt's model/view classes.
For performance reasons, the access to the member variables is direct (i.e., using the . or -> operator). This low-level feel makes the structures straightforward to use and emphasizes that these are simply parameters used by the style functions.
For an example demonstrating how style options can be used, see the Styles example.
QStyleOption
, and Model/View Programming.
Nested Class Summary | |
---|---|
static class |
QStyleOptionViewItem.Position
This enum describes the position of the item's decoration. |
static class |
QStyleOptionViewItem.StyleOptionType
This enum is used to hold information about the type of the style option, and is defined for each QStyleOption subclass. |
static class |
QStyleOptionViewItem.StyleOptionVersion
This enum is used to hold information about the version of the style option, and is defined for each QStyleOption subclass. |
Nested classes/interfaces inherited from class com.trolltech.qt.gui.QStyleOption |
---|
QStyleOption.OptionType |
Nested classes/interfaces inherited from class com.trolltech.qt.QSignalEmitter |
---|
QSignalEmitter.AbstractSignal, QSignalEmitter.Signal0, QSignalEmitter.Signal1, QSignalEmitter.Signal2, QSignalEmitter.Signal3, QSignalEmitter.Signal4, QSignalEmitter.Signal5, QSignalEmitter.Signal6, QSignalEmitter.Signal7, QSignalEmitter.Signal8, QSignalEmitter.Signal9 |
Nested classes/interfaces inherited from class com.trolltech.qt.internal.QSignalEmitterInternal |
---|
com.trolltech.qt.internal.QSignalEmitterInternal.AbstractSignalInternal |
Field Summary |
---|
Fields inherited from class com.trolltech.qt.internal.QSignalEmitterInternal |
---|
currentSender |
Constructor Summary | |
---|---|
QStyleOptionViewItem()
Constructs a QStyleOptionViewItem, initializing the members variables to their default values. |
|
QStyleOptionViewItem(QStyleOptionViewItem other)
Constructs a copy of the other style option. |
Method Summary | |
---|---|
QStyleOptionViewItem |
clone()
This method is reimplemented for internal reasons |
Qt.Alignment |
decorationAlignment()
This variable holds the alignment of the decoration for the item. |
QStyleOptionViewItem.Position |
decorationPosition()
This variable holds the position of the decoration for the item. |
QSize |
decorationSize()
This variable holds the size of the decoration for the item. |
Qt.Alignment |
displayAlignment()
This variable holds the alignment of the display value for the item. |
QFont |
font()
This variable holds the font used for the item. |
void |
setDecorationAlignment(Qt.Alignment decorationAlignment)
This variable holds the alignment of the decoration for the item. |
void |
setDecorationAlignment(Qt.AlignmentFlag[] decorationAlignment)
|
void |
setDecorationPosition(QStyleOptionViewItem.Position decorationPosition)
This variable holds the position of the decoration for the item. |
void |
setDecorationSize(QSize decorationSize)
This variable holds the size of the decoration for the item. |
void |
setDisplayAlignment(Qt.Alignment displayAlignment)
This variable holds the alignment of the display value for the item. |
void |
setDisplayAlignment(Qt.AlignmentFlag[] displayAlignment)
|
void |
setFont(QFont font)
This variable holds the font used for the item. |
void |
setShowDecorationSelected(boolean showDecorationSelected)
This variable holds whether the decoration should be highlighted on selected items. |
void |
setTextElideMode(Qt.TextElideMode textElideMode)
This variable holds where ellipsis should be added for text that is too long to fit into an item. |
boolean |
showDecorationSelected()
This variable holds whether the decoration should be highlighted on selected items. |
Qt.TextElideMode |
textElideMode()
This variable holds where ellipsis should be added for text that is too long to fit into an item. |
Methods inherited from class com.trolltech.qt.gui.QStyleOption |
---|
direction, fontMetrics, initFrom, palette, rect, setDirection, setFontMetrics, setPalette, setRect, setState, setState, setType, setVersion, state, type, version |
Methods inherited from class com.trolltech.qt.QtJambiObject |
---|
dispose, disposed, equals, finalize, reassignNativeResources, tr, tr, tr |
Methods inherited from class com.trolltech.qt.QSignalEmitter |
---|
blockSignals, disconnect, disconnect, signalsBlocked, signalSender, thread |
Methods inherited from class com.trolltech.qt.internal.QSignalEmitterInternal |
---|
__qt_signalInitialization |
Methods inherited from class java.lang.Object |
---|
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.trolltech.qt.QtJambiInterface |
---|
disableGarbageCollection, nativeId, nativePointer, reenableGarbageCollection, setJavaOwnership |
Constructor Detail |
---|
public QStyleOptionViewItem()
public QStyleOptionViewItem(QStyleOptionViewItem other)
Method Detail |
---|
public final void setShowDecorationSelected(boolean showDecorationSelected)
QStyle::SH_ItemView_ShowDecorationSelected
, and QAbstractItemView
.
public final boolean showDecorationSelected()
QStyle::SH_ItemView_ShowDecorationSelected
, and QAbstractItemView
.
public final void setDecorationPosition(QStyleOptionViewItem.Position decorationPosition)
Left
. Position
.
public final QStyleOptionViewItem.Position decorationPosition()
Left
. Position
.
public final void setDecorationAlignment(Qt.AlignmentFlag[] decorationAlignment)
public final void setDecorationAlignment(Qt.Alignment decorationAlignment)
Qt::AlignLeft
.
public final Qt.Alignment decorationAlignment()
Qt::AlignLeft
.
public final void setDisplayAlignment(Qt.AlignmentFlag[] displayAlignment)
public final void setDisplayAlignment(Qt.Alignment displayAlignment)
Qt::AlignLeft
.
public final Qt.Alignment displayAlignment()
Qt::AlignLeft
.
public final void setTextElideMode(Qt.TextElideMode textElideMode)
Qt::ElideMiddle
, i.e. the ellipsis appears in the middle of the text. Qt::TextElideMode
, and QStyle::SH_ItemView_EllipsisLocation
.
public final Qt.TextElideMode textElideMode()
Qt::ElideMiddle
, i.e. the ellipsis appears in the middle of the text. Qt::TextElideMode
, and QStyle::SH_ItemView_EllipsisLocation
.
public final void setDecorationSize(QSize decorationSize)
QSize
(-1, -1), i.e. an invalid size.
public final QSize decorationSize()
QSize
(-1, -1), i.e. an invalid size.
public final void setFont(QFont font)
QFont
.
public final QFont font()
QFont
.
public QStyleOptionViewItem clone()
clone
in class QStyleOption
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |