Qt Jambi Home

com.trolltech.qt.gui
Class QPaintEngineState

java.lang.Object
  extended by com.trolltech.qt.QSignalEmitter
      extended by com.trolltech.qt.QtJambiObject
          extended by com.trolltech.qt.gui.QPaintEngineState
All Implemented Interfaces:
QtJambiInterface

public class QPaintEngineState
extends QtJambiObject

The QPaintEngineState class provides information about the active paint engine's current state.

QPaintEngineState records which properties that have changed since the last time the paint engine was updated, as well as their current value.

Which properties that have changed can at any time be retrieved using the state function. This function returns an instance of the QPaintEngine::DirtyFlags type which stores an OR combination of QPaintEngine::DirtyFlag values. The QPaintEngine::DirtyFlag enum defines whether a property has changed since the last update or not.

If a property is marked with a dirty flag, its current value can be retrieved using the corresponding get function:

Property FlagCurrent Property Value
QPaintEngine::DirtyBackgroundbackgroundBrush
QPaintEngine::DirtyBackgroundModebackgroundMode
QPaintEngine::DirtyBrushbrush
QPaintEngine::DirtyBrushOriginbrushOrigin
QPaintEngine::DirtyClipRegion or QPaintEngine::DirtyClipPathclipOperation
QPaintEngine::DirtyClipPathclipPath
QPaintEngine::DirtyClipRegionclipRegion
QPaintEngine::DirtyCompositionModecompositionMode
QPaintEngine::DirtyFontfont
QPaintEngine::DirtyTransformmatrix
QPaintEngine::DirtyClipEnabledisClipEnabled
QPaintEngine::DirtyPenpen
QPaintEngine::DirtyHintsrenderHints

The QPaintEngineState class also provide the painter function which returns a pointer to the painter that is currently updating the paint engine.

An instance of this class, representing the current state of the active paint engine, is passed as argument to the QPaintEngine::updateState() function. The only situation in which you will have to use this class directly is when implementing your own paint engine.

See Also:
QPaintEngine

Nested Class Summary
 
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>
 
Method Summary
 QBrush backgroundBrush()
          Returns the background brush in the current paint engine state.
 Qt.BGMode backgroundMode()
          Returns the background mode in the current paint engine state.
 QBrush brush()
          Returns the brush in the current paint engine state.
 boolean brushNeedsResolving()
          Returns whether the coordinate of the fill have been specified as bounded by the current rendering operation and have to be resolved (about the currently rendered primitive).
 QPointF brushOrigin()
          Returns the brush origin in the current paint engine state.
 Qt.ClipOperation clipOperation()
          Returns the clip operation in the current paint engine state.
 QPainterPath clipPath()
          Returns the clip path in the current paint engine state.
 QRegion clipRegion()
          Returns the clip region in the current paint engine state.
 QPainter.CompositionMode compositionMode()
          Returns the composition mode in the current paint engine state.
 QFont font()
          Returns the font in the current paint engine state.
static QPaintEngineState fromNativePointer(QNativePointer nativePointer)
          This function returns the QPaintEngineState instance pointed to by nativePointer
 boolean isClipEnabled()
          Returns wether clipping is enabled or not in the current paint engine state.
 QMatrix matrix()
          Returns the matrix in the current paint engine state.
 double opacity()
          Returns the opacity in the current paint engine state.
 QPainter painter()
          Returns a pointer to the painter currently updating the paint engine.
 QPen pen()
          Returns the pen in the current paint engine state.
 boolean penNeedsResolving()
          Returns whether the coordinate of the stroke have been specified as bounded by the current rendering operation and have to be resolved (about the currently rendered primitive).
 QPainter.RenderHints renderHints()
          Returns the render hints in the current paint engine state.
protected  void setDirtyFlags(QPaintEngine.DirtyFlag... dirtyFlags)
          Sets this QPaintEngineState's dirtyFlags.
 QPaintEngine.DirtyFlags state()
          Returns a combination of flags identifying the set of properties that need to be updated when updating the paint engine's state (i.e. during a call to the QPaintEngine::updateState() function).
 QTransform transform()
          Returns the matrix in the current paint engine state.
 
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
 

Method Detail

backgroundBrush

public final QBrush backgroundBrush()

Returns the background brush in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyBackground flag.

See Also:
state, QPaintEngine::updateState

backgroundMode

public final Qt.BGMode backgroundMode()

Returns the background mode in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyBackgroundMode flag.

See Also:
state, QPaintEngine::updateState

brush

public final QBrush brush()

Returns the brush in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyBrush flag.

See Also:
state, QPaintEngine::updateState

brushNeedsResolving

public final boolean brushNeedsResolving()

Returns whether the coordinate of the fill have been specified as bounded by the current rendering operation and have to be resolved (about the currently rendered primitive).


brushOrigin

public final QPointF brushOrigin()

Returns the brush origin in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyBrushOrigin flag.

See Also:
state, QPaintEngine::updateState

clipOperation

public final Qt.ClipOperation clipOperation()

Returns the clip operation in the current paint engine state.

This variable should only be used when the state returns a combination which includes either the QPaintEngine::DirtyClipPath or the QPaintEngine::DirtyClipRegion flag.

See Also:
state, QPaintEngine::updateState

clipPath

public final QPainterPath clipPath()

Returns the clip path in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyClipPath flag.

See Also:
state, QPaintEngine::updateState

clipRegion

public final QRegion clipRegion()

Returns the clip region in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyClipRegion flag.

See Also:
state, QPaintEngine::updateState

compositionMode

public final QPainter.CompositionMode compositionMode()

Returns the composition mode in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyCompositionMode flag.

See Also:
state, QPaintEngine::updateState

font

public final QFont font()

Returns the font in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyFont flag.

See Also:
state, QPaintEngine::updateState

isClipEnabled

public final boolean isClipEnabled()

Returns wether clipping is enabled or not in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyClipEnabled flag.

See Also:
state, QPaintEngine::updateState

matrix

public final QMatrix matrix()

Returns the matrix in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyTransform flag.

See Also:
state, QPaintEngine::updateState

opacity

public final double opacity()

Returns the opacity in the current paint engine state.


painter

public final QPainter painter()

Returns a pointer to the painter currently updating the paint engine.


pen

public final QPen pen()

Returns the pen in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyPen flag.

See Also:
state, QPaintEngine::updateState

penNeedsResolving

public final boolean penNeedsResolving()

Returns whether the coordinate of the stroke have been specified as bounded by the current rendering operation and have to be resolved (about the currently rendered primitive).


renderHints

public final QPainter.RenderHints renderHints()

Returns the render hints in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyHints flag.

See Also:
state, QPaintEngine::updateState

state

public final QPaintEngine.DirtyFlags state()

Returns a combination of flags identifying the set of properties that need to be updated when updating the paint engine's state (i.e. during a call to the QPaintEngine::updateState() function).

See Also:
QPaintEngine::updateState

transform

public final QTransform transform()

Returns the matrix in the current paint engine state.

This variable should only be used when the state returns a combination which includes the QPaintEngine::DirtyTransform flag.

See Also:
state, QPaintEngine::updateState

setDirtyFlags

protected final void setDirtyFlags(QPaintEngine.DirtyFlag... dirtyFlags)
Sets this QPaintEngineState's dirtyFlags.


fromNativePointer

public static QPaintEngineState fromNativePointer(QNativePointer nativePointer)
This function returns the QPaintEngineState instance pointed to by nativePointer

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

Qt Jambi Home