|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Enum
com.trolltech.qt.gui.QGraphicsView.ViewportUpdateMode
public static final class QGraphicsView.ViewportUpdateMode
This enum describes how QGraphicsView
updates its viewport when the scene contents change or are exposed.
viewportUpdateMode
.
Field Summary | |
---|---|
static QGraphicsView.ViewportUpdateMode |
BoundingRectViewportUpdate
The bounding rectangle of all changes in the viewport will be redrawn. |
static QGraphicsView.ViewportUpdateMode |
FullViewportUpdate
When any visible part of the scene changes or is reexposed, QGraphicsView will update the entire viewport. |
static QGraphicsView.ViewportUpdateMode |
MinimalViewportUpdate
QGraphicsView will determine the minimal viewport region that requires a redraw, minimizing the time spent drawing by avoiding a redraw of areas that have not changed. |
static QGraphicsView.ViewportUpdateMode |
NoViewportUpdate
QGraphicsView will never update its viewport when the scene changes; the user is expected to control all updates. |
static QGraphicsView.ViewportUpdateMode |
SmartViewportUpdate
QGraphicsView will attempt to find an optimal update mode by analyzing the areas that require a redraw. |
Method Summary | |
---|---|
static QGraphicsView.ViewportUpdateMode |
resolve(int value)
|
int |
value()
This function should return an integer value for the enum values of the enumeration that implements this interface. |
static QGraphicsView.ViewportUpdateMode |
valueOf(java.lang.String name)
|
static QGraphicsView.ViewportUpdateMode[] |
values()
|
Methods inherited from class java.lang.Enum |
---|
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final QGraphicsView.ViewportUpdateMode FullViewportUpdate
QGraphicsView
will update the entire viewport. This approach is fastest when QGraphicsView
spends more time figuring out what to draw than it would spend drawing (e.g., when very many small items are repeatedly updated). This is the preferred update mode for viewports that do not support partial updates, such as QGLWidget
, and for viewports that need to disable scroll optimization.
public static final QGraphicsView.ViewportUpdateMode MinimalViewportUpdate
QGraphicsView
will determine the minimal viewport region that requires a redraw, minimizing the time spent drawing by avoiding a redraw of areas that have not changed. This is QGraphicsView
's default mode. Although this approach provides the best performance in general, if there are many small visible changes on the scene, QGraphicsView
might end up spending more time finding the minimal approach than it will spend drawing.
public static final QGraphicsView.ViewportUpdateMode SmartViewportUpdate
QGraphicsView
will attempt to find an optimal update mode by analyzing the areas that require a redraw.
public static final QGraphicsView.ViewportUpdateMode NoViewportUpdate
QGraphicsView
will never update its viewport when the scene changes; the user is expected to control all updates. This mode disables all (potentially slow) item visibility testing in QGraphicsView
, and is suitable for scenes that either require a fixed frame rate, or where the viewport is otherwise updated externally.
public static final QGraphicsView.ViewportUpdateMode BoundingRectViewportUpdate
QGraphicsView
searches only one region for changes, minimizing time spent determining what needs redrawing. The disadvantage is that areas that have not changed also need to be redrawn.
Method Detail |
---|
public static QGraphicsView.ViewportUpdateMode[] values()
public static QGraphicsView.ViewportUpdateMode valueOf(java.lang.String name)
public int value()
value
in interface QtEnumerator
public static QGraphicsView.ViewportUpdateMode resolve(int value)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |