|
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.trolltech.qt.QSignalEmitter
com.trolltech.qt.QtJambiObject
com.trolltech.qt.gui.QStyleOption
com.trolltech.qt.gui.QStyleOptionComplex
com.trolltech.qt.gui.QStyleOptionSlider
public class QStyleOptionSlider
The QStyleOptionSlider class is used to describe the parameters needed for drawing a slider.
QStyleOptionSlider contains all the information that QStyle functions need to draw QSlider and QScrollBar.
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.
Nested Class Summary | |
---|---|
static class |
QStyleOptionSlider.StyleOptionType
This enum is used to hold information about the type of the style option, and is defined for each QStyleOption subclass. |
static class |
QStyleOptionSlider.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.Signal0, QSignalEmitter.Signal1<A>, QSignalEmitter.Signal2<A,B>, QSignalEmitter.Signal3<A,B,C>, QSignalEmitter.Signal4<A,B,C,D>, QSignalEmitter.Signal5<A,B,C,D,E>, QSignalEmitter.Signal6<A,B,C,D,E,F>, QSignalEmitter.Signal7<A,B,C,D,E,F,G>, QSignalEmitter.Signal8<A,B,C,D,E,F,G,H>, QSignalEmitter.Signal9<A,B,C,D,E,F,G,H,I> |
Constructor Summary | |
---|---|
|
QStyleOptionSlider()
Constructs a QStyleOptionSlider, initializing the members variables to their default values. |
protected |
QStyleOptionSlider(int version)
|
|
QStyleOptionSlider(QStyleOptionSlider other)
Constructs a copy of the other style option. |
Method Summary | |
---|---|
boolean |
dialWrapping()
Returns whether the dial should wrap or not. |
static QStyleOptionSlider |
fromNativePointer(QNativePointer nativePointer)
This function returns the QStyleOptionSlider instance pointed to by nativePointer |
int |
maximum()
Returns the maximum value for the slider. |
int |
minimum()
Returns the minimum value for the slider. |
static QNativePointer |
nativePointerArray(QStyleOptionSlider[] array)
This function returns a QNativePointer that is pointing to the specified QStyleOptionSlider array. |
double |
notchTarget()
Returns the number of pixel between notches. |
Qt.Orientation |
orientation()
Returns the slider's orientation (horizontal or vertical). |
int |
pageStep()
Returns the size of the page step of the slider. |
void |
setDialWrapping(boolean dialWrapping)
Sets whether the dial should wrap or not to dialWrapping. |
void |
setMaximum(int maximum)
Sets the maximum value for the slider to maximum. |
void |
setMinimum(int minimum)
Sets the minimum value for the slider to minimum. |
void |
setNotchTarget(double notchTarget)
Sets the number of pixel between notches to notchTarget. |
void |
setOrientation(Qt.Orientation orientation)
Sets the slider's orientation (horizontal or vertical) to orientation. |
void |
setPageStep(int pageStep)
Sets the size of the page step of the slider to pageStep. |
void |
setSingleStep(int singleStep)
Sets the size of the single step of the slider to singleStep. |
void |
setSliderPosition(int sliderPosition)
Sets the position of the slider handle to sliderPosition. |
void |
setSliderValue(int sliderValue)
Sets the value of the slider to sliderValue. |
void |
setTickInterval(int tickInterval)
Sets the interval that should be drawn between tick marks to tickInterval. |
void |
setTickPosition(QSlider.TickPosition tickPosition)
Sets the position of the slider's tick marks, if any to tickPosition. |
void |
setUpsideDown(boolean upsideDown)
Sets the slider control orientation to upsideDown. |
int |
singleStep()
Returns the size of the single step of the slider. |
int |
sliderPosition()
Returns the position of the slider handle. |
int |
sliderValue()
Returns the value of the slider. |
int |
tickInterval()
Returns the interval that should be drawn between tick marks. |
QSlider.TickPosition |
tickPosition()
Returns the position of the slider's tick marks, if any. |
boolean |
upsideDown()
Returns the slider control orientation. |
Methods inherited from class com.trolltech.qt.gui.QStyleOptionComplex |
---|
activeSubControls, nativePointerArray, setActiveSubControls, setSubControls, subControls |
Methods inherited from class com.trolltech.qt.gui.QStyleOption |
---|
direction, fontMetrics, initFrom, nativePointerArray, palette, rect, setDirection, setFontMetrics, setPalette, setRect, setState, setState, setType, setVersion, state, type, version |
Methods inherited from class com.trolltech.qt.QtJambiObject |
---|
dispose, disposed, finalize, reassignNativeResources, tr, tr, tr |
Methods inherited from class com.trolltech.qt.QSignalEmitter |
---|
blockSignals, disconnect, disconnect, signalsBlocked, signalSender, thread |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.trolltech.qt.QtJambiInterface |
---|
disableGarbageCollection, nativeId, nativePointer, reenableGarbageCollection, setJavaOwnership |
Constructor Detail |
---|
public QStyleOptionSlider(QStyleOptionSlider other)
Constructs a copy of the other style option.
public QStyleOptionSlider()
Constructs a QStyleOptionSlider, initializing the members variables to their default values.
protected QStyleOptionSlider(int version)
Method Detail |
---|
public final void setTickInterval(int tickInterval)
Sets the interval that should be drawn between tick marks to tickInterval.
The default value is 0.
public final int tickInterval()
Returns the interval that should be drawn between tick marks.
The default value is 0.
public final void setMinimum(int minimum)
Sets the minimum value for the slider to minimum.
The default value is 0.
public final int minimum()
Returns the minimum value for the slider.
The default value is 0.
public final void setNotchTarget(double notchTarget)
Sets the number of pixel between notches to notchTarget.
The default value is 0.0.
public final double notchTarget()
Returns the number of pixel between notches.
The default value is 0.0.
public final void setMaximum(int maximum)
Sets the maximum value for the slider to maximum.
The default value is 0.
public final int maximum()
Returns the maximum value for the slider.
The default value is 0.
public final void setSliderPosition(int sliderPosition)
Sets the position of the slider handle to sliderPosition.
If the slider has active feedback (i.e., QAbstractSlider::tracking is true), this value will be the same as sliderValue. Otherwise, it will have the current position of the handle. The default value is 0.
public final int sliderPosition()
Returns the position of the slider handle.
If the slider has active feedback (i.e., QAbstractSlider::tracking is true), this value will be the same as sliderValue. Otherwise, it will have the current position of the handle. The default value is 0.
public final void setDialWrapping(boolean dialWrapping)
Sets whether the dial should wrap or not to dialWrapping.
The default value is false, i.e. the dial is not wrapped.
public final boolean dialWrapping()
Returns whether the dial should wrap or not.
The default value is false, i.e. the dial is not wrapped.
public final void setSliderValue(int sliderValue)
Sets the value of the slider to sliderValue.
If the slider has active feedback (i.e., QAbstractSlider::tracking is true), this value will be the same as sliderPosition. Otherwise, it will have the value the slider had before the mouse was pressed.
The default value is 0.
public final int sliderValue()
Returns the value of the slider.
If the slider has active feedback (i.e., QAbstractSlider::tracking is true), this value will be the same as sliderPosition. Otherwise, it will have the value the slider had before the mouse was pressed.
The default value is 0.
public final void setSingleStep(int singleStep)
Sets the size of the single step of the slider to singleStep.
The default value is 0.
public final int singleStep()
Returns the size of the single step of the slider.
The default value is 0.
public final void setTickPosition(QSlider.TickPosition tickPosition)
Sets the position of the slider's tick marks, if any to tickPosition.
The default value is QSlider::NoTicks.
public final QSlider.TickPosition tickPosition()
Returns the position of the slider's tick marks, if any.
The default value is QSlider::NoTicks.
public final void setPageStep(int pageStep)
Sets the size of the page step of the slider to pageStep.
The default value is 0.
public final int pageStep()
Returns the size of the page step of the slider.
The default value is 0.
public final void setOrientation(Qt.Orientation orientation)
Sets the slider's orientation (horizontal or vertical) to orientation.
The default orientation is Qt::Horizontal.
Qt::Orientation
public final Qt.Orientation orientation()
Returns the slider's orientation (horizontal or vertical).
The default orientation is Qt::Horizontal.
Qt::Orientation
public final void setUpsideDown(boolean upsideDown)
Sets the slider control orientation to upsideDown.
Normally a slider increases as it moves up or to the right; upsideDown indicates that it should do the opposite (increase as it moves down or to the left). The default value is false, i.e. the slider increases as it moves up or to the right.
public final boolean upsideDown()
Returns the slider control orientation.
Normally a slider increases as it moves up or to the right; upsideDown indicates that it should do the opposite (increase as it moves down or to the left). The default value is false, i.e. the slider increases as it moves up or to the right.
public static QStyleOptionSlider fromNativePointer(QNativePointer nativePointer)
nativePointer
- the QNativePointer of which object should be returned.public static QNativePointer nativePointerArray(QStyleOptionSlider[] array)
array
- the array that the returned pointer will point to.
|
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |