Home ⌂Doc Index ◂Up ▴

eric6.E5Graphics.E5ArrowItem

Module implementing a graphics item subclass for an arrow.

Global Attributes

ArrowheadAngleFactor
NormalArrow
WideArrow

Classes

E5ArrowItem Class implementing an arrow graphics item subclass.

Functions

None


E5ArrowItem

Class implementing an arrow graphics item subclass.

Derived from

QAbstractGraphicsShapeItem

Class Attributes

None

Class Methods

None

Methods

E5ArrowItem Constructor
boundingRect Public method to return the bounding rectangle.
paint Public method to paint the item in local coordinates.
setEndPoint Public method to set the end point.
setPoints Public method to set the start and end points of the line.
setStartPoint Public method to set the start point.

Static Methods

None

E5ArrowItem (Constructor)

E5ArrowItem(origin=None, end=None, filled=False, arrowType=NormalArrow, colors=None, parent=None)

Constructor

origin (QPointF)
origin of the arrow
end (QPointF)
end point of the arrow
filled (bool)
flag indicating a filled arrow head
arrowType (int, one of NormalArrow, WideArrow)
arrow type
colors (tuple of (QColor, QColor))
tuple containing the foreground and background colors
parent (QGraphicsItem)
reference to the parent object

E5ArrowItem.boundingRect

boundingRect()

Public method to return the bounding rectangle.

Returns:
bounding rectangle (QRectF)

E5ArrowItem.paint

paint(painter, option, widget=None)

Public method to paint the item in local coordinates.

painter
reference to the painter object (QPainter)
option
style options (QStyleOptionGraphicsItem)
widget
optional reference to the widget painted on (QWidget)

E5ArrowItem.setEndPoint

setEndPoint(x, y)

Public method to set the end point.

Note: This method does not redraw the item.

x
x-coordinate of the end point (float)
y
y-coordinate of the end point (float)

E5ArrowItem.setPoints

setPoints(xa, ya, xb, yb)

Public method to set the start and end points of the line.

Note: This method does not redraw the item.

xa
x-coordinate of the start point (float)
ya
y-coordinate of the start point (float)
xb
x-coordinate of the end point (float)
yb
y-coordinate of the end point (float)

E5ArrowItem.setStartPoint

setStartPoint(x, y)

Public method to set the start point.

Note: This method does not redraw the item.

x
x-coordinate of the start point (float)
y
y-coordinate of the start point (float)
Up



Home ⌂Doc Index ◂Up ▴