Overview | Package | Class | Tree | Deprecated | Index | Help
Qt Jambi Home |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.trolltech.qt.gui
Class QStyleOptionProgressBar

    java.lang.Object
      com.trolltech.qt.QSignalEmitter
          com.trolltech.qt.QtJambiObject
              com.trolltech.qt.gui.QStyleOption
                  com.trolltech.qt.gui.QStyleOptionProgressBar

All Implemented Interfaces:
  QtJambiInterface

Direct Known Subclasses:
  QStyleOptionProgressBarV2

    public class QStyleOptionProgressBar

extends QStyleOption

The `QStyleOptionProgressBar` class is used to describe the parameters necessary for drawing a progress bar.

Since Qt 4.1, Qt uses the `QStyleOptionProgressBarV2` subclass for drawing `QProgressBar`.

An instance of the `QStyleOptionProgressBar` class has type `SO_ProgressBar` and version 1.

The type is used internally by `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 `QStyleOption` subclass and your own styles. The version is used by `QStyleOption` subclasses to implement extensions without breaking compatibility. If you use qstyleoption_cast(), you normally don't need to check it.

If you create your own `QStyle` subclass, you should handle both `QStyleOptionProgressBar` and `QStyleOptionProgressBarV2`.

For an example demonstrating how style options can be used, see the Styles example.

See Also:
  `QStyleOptionProgressBarV2`, `QStyleOption`

Nested Class Summary
`static class` | `QStyleOptionProgressBar.StyleOptionType` This enum is used to hold information about the type of the style option, and is defined for each `QStyleOption` subclass.
`static class` | `QStyleOptionProgressBar.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<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
`` | `QStyleOptionProgressBar()` Constructs a `QStyleOptionProgressBar`, initializing the members variables to their default values.
`protected` | `QStyleOptionProgressBar(int version)`
`` | `QStyleOptionProgressBar(QStyleOptionProgressBar other)` Constructs a copy of the `other` style option.

Method Summary
`static QStyleOptionProgressBar` | `fromNativePointer(QNativePointer nativePointer)` This function returns the QStyleOptionProgressBar instance pointed to by nativePointer
`int` | `maximum()` Returns the maximum value for the progress bar.
`int` | `minimum()` Returns the minimum value for the progress bar.
`static QNativePointer` | `nativePointerArray(QStyleOptionProgressBar[] array)` This function returns a QNativePointer that is pointing to the specified QStyleOptionProgressBar array.
`int` | `progress()` Returns the current progress for the progress bar.
`void` | `setMaximum(int maximum)` Sets the maximum value for the progress bar to `maximum`.
`void` | `setMinimum(int minimum)` Sets the minimum value for the progress bar to `minimum`.
`void` | `setProgress(int progress)` Sets the current progress for the progress bar to `progress`.
`void` | `setText(java.lang.String text)` Sets the text for the progress bar to `text`.
`void` | `setTextAlignment(Qt.Alignment textAlignment)` Sets the text alignment for the text in the `QProgressBar` to `textAlignment`.
`void` | `setTextAlignment(Qt.AlignmentFlag... textAlignment)` Sets the text alignment for the text in the `QProgressBar` to `textAlignment`.
`void` | `setTextVisible(boolean textVisible)` Sets a flag indicating whether or not text is visible to `textVisible`.
`java.lang.String` | `text()` Returns the text for the progress bar.
`Qt.Alignment` | `textAlignment()` Returns the text alignment for the text in the `QProgressBar`.
`boolean` | `textVisible()` Returns a flag indicating whether or not text is visible.

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

### QStyleOptionProgressBar

    public QStyleOptionProgressBar(QStyleOptionProgressBar other)

  Constructs a copy of the `other` style option.

### QStyleOptionProgressBar

    public QStyleOptionProgressBar()

  Constructs a `QStyleOptionProgressBar`, initializing the members variables to their default values.

### QStyleOptionProgressBar

    protected QStyleOptionProgressBar(int version)

Method Detail

### setMinimum

    public final void setMinimum(int minimum)

  Sets the minimum value for the progress bar to `minimum`.

  This is the minimum value in the progress bar. The default value is 0.

  See Also:
    `QProgressBar::minimum`

### minimum

    public final int minimum()

  Returns the minimum value for the progress bar.

  This is the minimum value in the progress bar. The default value is 0.

  See Also:
    `setMinimum`, `QProgressBar::minimum`

### setMaximum

    public final void setMaximum(int maximum)

  Sets the maximum value for the progress bar to `maximum`.

  This is the maximum value in the progress bar. The default value is 0.

  See Also:
    `QProgressBar::maximum`

### maximum

    public final int maximum()

  Returns the maximum value for the progress bar.

  This is the maximum value in the progress bar. The default value is 0.

  See Also:
    `setMaximum`, `QProgressBar::maximum`

### setProgress

    public final void setProgress(int progress)

  Sets the current progress for the progress bar to `progress`.

  The current progress. A value of QStyleOptionProgressBar::minimum - 1 indicates that the progress hasn't started yet. The default value is 0.

  See Also:
    `progress`, `QProgressBar::value`

### progress

    public final int progress()

  Returns the current progress for the progress bar.

  The current progress. A value of QStyleOptionProgressBar::minimum - 1 indicates that the progress hasn't started yet. The default value is 0.

  See Also:
    `setProgress`, `QProgressBar::value`

### setTextAlignment

    public final void setTextAlignment(Qt.AlignmentFlag... textAlignment)

  Sets the text alignment for the text in the `QProgressBar` to `textAlignment`.

  This can be used as a guide on where the text should be in the progress bar. The default value is Qt::AlignLeft.

  See Also:
    `textAlignment`

### setTextAlignment

    public final void setTextAlignment(Qt.Alignment textAlignment)

  Sets the text alignment for the text in the `QProgressBar` to `textAlignment`.

  This can be used as a guide on where the text should be in the progress bar. The default value is Qt::AlignLeft.

  See Also:
    `textAlignment`

### textAlignment

    public final Qt.Alignment textAlignment()

  Returns the text alignment for the text in the `QProgressBar`.

  This can be used as a guide on where the text should be in the progress bar. The default value is Qt::AlignLeft.

  See Also:
    `setTextAlignment`

### setText

    public final void setText(java.lang.String text)

  Sets the text for the progress bar to `text`.

  The progress bar text is usually just the progress expressed as a string. An empty string indicates that the progress bar has not started yet. The default value is an empty string.

  See Also:
    `QProgressBar::text`

### text

    public final java.lang.String text()

  Returns the text for the progress bar.

  The progress bar text is usually just the progress expressed as a string. An empty string indicates that the progress bar has not started yet. The default value is an empty string.

  See Also:
    `setText`, `QProgressBar::text`

### setTextVisible

    public final void setTextVisible(boolean textVisible)

  Sets a flag indicating whether or not text is visible to `textVisible`.

  If this flag is true then the text is visible. Otherwise, the text is not visible. The default value is false.

  See Also:
    `QProgressBar::textVisible`

### textVisible

    public final boolean textVisible()

  Returns a flag indicating whether or not text is visible.

  If this flag is true then the text is visible. Otherwise, the text is not visible. The default value is false.

  See Also:
    `setTextVisible`, `QProgressBar::textVisible`

### fromNativePointer

    public static QStyleOptionProgressBar fromNativePointer(QNativePointer nativePointer)

  This function returns the QStyleOptionProgressBar instance pointed to by nativePointer

  Parameters:
    `nativePointer` - the QNativePointer of which object should be returned.

### nativePointerArray

    public static QNativePointer nativePointerArray(QStyleOptionProgressBar[] array)

  This function returns a QNativePointer that is pointing to the specified QStyleOptionProgressBar array.

  Parameters:
    `array` - the array that the returned pointer will point to.
  Returns:
    a QNativePointer that is pointing to the specified array.

Overview | Package | Class | Tree | Deprecated | Index | Help
Qt Jambi Home |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD