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 QGraphicsPathItem

    java.lang.Object
      com.trolltech.qt.QSignalEmitter
          com.trolltech.qt.QtJambiObject
              com.trolltech.qt.gui.QAbstractGraphicsShapeItem
                  com.trolltech.qt.gui.QGraphicsPathItem

All Implemented Interfaces:
  QGraphicsItemInterface, QtJambiInterface

    public class QGraphicsPathItem

extends QAbstractGraphicsShapeItem

The `QGraphicsPathItem` class provides a path item that you can add to a `QGraphicsScene`.

To set the item's path, pass a `QPainterPath` to `QGraphicsPathItem`'s constructor, or call the `setPath` function. The `path` function returns the current path.

`QGraphicsPathItem` uses the path to provide a reasonable implementation of `boundingRect`, `shape`, and `contains`. The `paint` function draws the path using the item's associated pen and brush, which you can set by calling the `setPen` and `setBrush` functions.

See Also:
  `QGraphicsRectItem`, `QGraphicsEllipseItem`, `QGraphicsPolygonItem`, `QGraphicsTextItem`, `QGraphicsLineItem`, `QGraphicsPixmapItem`, The Graphics View Framework

Nested Class Summary
`static class` | `QGraphicsPathItem.enum_1` Press link for info on QGraphicsPathItem.enum_1

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
`QGraphicsPathItem()` Equivalent to `QGraphicsPathItem`(, 0).
`QGraphicsPathItem(QGraphicsItemInterface parent)` Equivalent to `QGraphicsPathItem`(`parent`, 0).
`QGraphicsPathItem(QGraphicsItemInterface parent, QGraphicsScene scene)` Constructs a QGraphicsPath item using `parent` as the default path.
`QGraphicsPathItem(QPainterPath path)` Creates a new QGraphicsPathItem from the specified `path`.
`QGraphicsPathItem(QPainterPath path, QGraphicsItemInterface parent)` Creates a new QGraphicsPathItem from the specified `path` and `parent`.
`QGraphicsPathItem(QPainterPath path, QGraphicsItemInterface parent, QGraphicsScene scene)` Creates a new QGraphicsPathItem from the specified `path`, `parent`, and `scene`.

Method Summary
`QRectF` | `boundingRect()` This function is reimplemented for internal reasons.
`boolean` | `contains(QPointF point)` This function is reimplemented for internal reasons.
`java.lang.Object` | `extension(java.lang.Object variant)` This function is reimplemented for internal reasons.
`static QGraphicsPathItem` | `fromNativePointer(QNativePointer nativePointer)` This function returns the QGraphicsPathItem instance pointed to by nativePointer
`boolean` | `isObscuredBy(QGraphicsItemInterface item)` This function is reimplemented for internal reasons.
`QPainterPath` | `opaqueArea()` This function is reimplemented for internal reasons.
`void` | `paint(QPainter painter, QStyleOptionGraphicsItem option, QWidget widget)` This function is reimplemented for internal reasons.
`QPainterPath` | `path()` Returns the item's path as a `QPainterPath`.
`void` | `setExtension(QGraphicsItem.Extension extension, java.lang.Object variant)`
`void` | `setPath(QPainterPath path)` Sets the item's path to be the given `path`.
`QPainterPath` | `shape()` This function is reimplemented for internal reasons.
`boolean` | `supportsExtension(QGraphicsItem.Extension extension)`
`int` | `type()` This function is reimplemented for internal reasons.

Methods inherited from class com.trolltech.qt.gui.QAbstractGraphicsShapeItem
`acceptDrops, acceptedMouseButtons, acceptsHoverEvents, addToIndex, advance, brush, childItems, childrenBoundingRect, clearFocus, collidesWithItem, collidesWithPath, collidingItems, contextMenuEvent, cursor, data, deviceTransform, dragEnterEvent, dragLeaveEvent, dragMoveEvent, dropEvent, ensureVisible, ensureVisible, flags, focusInEvent, focusOutEvent, group, handlesChildEvents, hasCursor, hasFocus, hide, hoverEnterEvent, hoverLeaveEvent, hoverMoveEvent, inputMethodEvent, inputMethodQuery, installSceneEventFilter, isAncestorOf, isEnabled, isObscured, isObscured, isObscured, isSelected, isVisible, itemChange, keyPressEvent, keyReleaseEvent, mapFromItem, mapFromItem, mapFromItem, mapFromItem, mapFromItem, mapFromItem, mapFromParent, mapFromParent, mapFromParent, mapFromParent, mapFromParent, mapFromParent, mapFromScene, mapFromScene, mapFromScene, mapFromScene, mapFromScene, mapFromScene, mapToItem, mapToItem, mapToItem, mapToItem, mapToItem, mapToItem, mapToParent, mapToParent, mapToParent, mapToParent, mapToParent, mapToParent, mapToScene, mapToScene, mapToScene, mapToScene, mapToScene, mapToScene, mouseDoubleClickEvent, mouseMoveEvent, mousePressEvent, mouseReleaseEvent, moveBy, parentItem, pen, pos, prepareGeometryChange, removeFromIndex, removeSceneEventFilter, resetTransform, rotate, scale, scene, sceneBoundingRect, sceneEvent, sceneEventFilter, scenePos, sceneTransform, setAcceptDrops, setAcceptedMouseButtons, setAcceptsHoverEvents, setBrush, setCursor, setData, setEnabled, setFlag, setFlags, setFocus, setGroup, setHandlesChildEvents, setParentItem, setPen, setPos, setPos, setSelected, setToolTip, setTransform, setVisible, setZValue, shear, show, toolTip, topLevelItem, transform, translate, unsetCursor, update, update, wheelEvent, x, y, zValue`

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

### QGraphicsPathItem

    public QGraphicsPathItem(QGraphicsItemInterface parent)

  Equivalent to `QGraphicsPathItem`(`parent`, 0).

### QGraphicsPathItem

    public QGraphicsPathItem()

  Equivalent to `QGraphicsPathItem`(, 0).

### QGraphicsPathItem

    public QGraphicsPathItem(QGraphicsItemInterface parent,
                             QGraphicsScene scene)

  Constructs a QGraphicsPath item using `parent` as the default path. `scene` is passed to `QAbstractGraphicsShapeItem`'s constructor.

  See Also:
    `QGraphicsScene::addItem`

### QGraphicsPathItem

    public QGraphicsPathItem(QPainterPath path,
                             QGraphicsItemInterface parent)

  Creates a new QGraphicsPathItem from the specified `path` and `parent`.

### QGraphicsPathItem

    public QGraphicsPathItem(QPainterPath path)

  Creates a new QGraphicsPathItem from the specified `path`.

### QGraphicsPathItem

    public QGraphicsPathItem(QPainterPath path,
                             QGraphicsItemInterface parent,
                             QGraphicsScene scene)

  Creates a new QGraphicsPathItem from the specified `path`, `parent`, and `scene`.

Method Detail

### path

    public final QPainterPath path()

  Returns the item's path as a `QPainterPath`. If no item has been set, an empty `QPainterPath` is returned.

  See Also:
    `setPath`

### setPath

    public final void setPath(QPainterPath path)

  Sets the item's path to be the given `path`.

  See Also:
    `path`

### boundingRect

    public QRectF boundingRect()

  This function is reimplemented for internal reasons.

  Specified by:
    `boundingRect` in interface `QGraphicsItemInterface`
  Specified by:
    `boundingRect` in class `QAbstractGraphicsShapeItem`
  See Also:
    `shape`, `contains`, The Graphics View Coordinate System, `prepareGeometryChange`

### contains

    public boolean contains(QPointF point)

  This function is reimplemented for internal reasons.

  Specified by:
    `contains` in interface `QGraphicsItemInterface`
  Overrides:
    `contains` in class `QAbstractGraphicsShapeItem`
  See Also:
    `shape`, `boundingRect`, `collidesWithPath`

### extension

    public java.lang.Object extension(java.lang.Object variant)

  This function is reimplemented for internal reasons.

  Specified by:
    `extension` in interface `QGraphicsItemInterface`
  Overrides:
    `extension` in class `QAbstractGraphicsShapeItem`
  See Also:
    `setExtension`

### isObscuredBy

    public boolean isObscuredBy(QGraphicsItemInterface item)

  This function is reimplemented for internal reasons.

  Specified by:
    `isObscuredBy` in interface `QGraphicsItemInterface`
  Overrides:
    `isObscuredBy` in class `QAbstractGraphicsShapeItem`
  See Also:
    `opaqueArea`, `isObscured`

### opaqueArea

    public QPainterPath opaqueArea()

  This function is reimplemented for internal reasons.

  Specified by:
    `opaqueArea` in interface `QGraphicsItemInterface`
  Overrides:
    `opaqueArea` in class `QAbstractGraphicsShapeItem`
  See Also:
    `isObscuredBy`, `isObscured`, `shape`

### paint

    public void paint(QPainter painter,
                      QStyleOptionGraphicsItem option,
                      QWidget widget)

  This function is reimplemented for internal reasons.

  Specified by:
    `paint` in interface `QGraphicsItemInterface`
  Specified by:
    `paint` in class `QAbstractGraphicsShapeItem`

### setExtension

    public void setExtension(QGraphicsItem.Extension extension,
                             java.lang.Object variant)

  Specified by:
    `setExtension` in interface `QGraphicsItemInterface`
  Overrides:
    `setExtension` in class `QAbstractGraphicsShapeItem`
  See Also:
    `extension`

### shape

    public QPainterPath shape()

  This function is reimplemented for internal reasons.

  Specified by:
    `shape` in interface `QGraphicsItemInterface`
  Overrides:
    `shape` in class `QAbstractGraphicsShapeItem`
  See Also:
    `boundingRect`, `contains`, `prepareGeometryChange`

### supportsExtension

    public boolean supportsExtension(QGraphicsItem.Extension extension)

  Specified by:
    `supportsExtension` in interface `QGraphicsItemInterface`
  Overrides:
    `supportsExtension` in class `QAbstractGraphicsShapeItem`

### type

    public int type()

  This function is reimplemented for internal reasons.

  Specified by:
    `type` in interface `QGraphicsItemInterface`
  Overrides:
    `type` in class `QAbstractGraphicsShapeItem`

### fromNativePointer

    public static QGraphicsPathItem fromNativePointer(QNativePointer nativePointer)

  This function returns the QGraphicsPathItem instance pointed to by nativePointer

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

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