The QGraphicsEllipseItem class provides an ellipse item that you can add to a QGraphicsScene . 更多...
继承 QAbstractGraphicsShapeItem .
The QGraphicsEllipseItem class provides an ellipse item that you can add to a QGraphicsScene .
QGraphicsEllipseItem respresents an ellipse with a fill and an outline, and you can also use it for ellipse segments (see startAngle (), spanAngle ()).
|
|
To set the item's ellipse, pass a QRectF to QGraphicsEllipseItem's constructor, or call setRect ()。 rect () function returns the current ellipse geometry.
QGraphicsEllipseItem uses the rect and the pen width to provide a reasonable implementation of boundingRect (), shape (),和 contains ()。 paint () function draws the ellipse using the item's associated pen and brush, which you can set by calling setPen () 和 setBrush ().
parent argument, if not None, causes self to be owned by Qt instead of PyQt.
scene argument, if not None, causes self to be owned by Qt instead of PyQt.
构造 QGraphicsEllipseItem . parent 会被传递给 QAbstractGraphicsShapeItem 's 构造函数。
另请参阅 QGraphicsScene.addItem ().
parent argument, if not None, causes self to be owned by Qt instead of PyQt.
scene argument, if not None, causes self to be owned by Qt instead of PyQt.
构造 QGraphicsEllipseItem 使用 rect as the default rectangle. parent 会被传递给 QAbstractGraphicsShapeItem 's 构造函数。
另请参阅 QGraphicsScene.addItem ().
parent argument, if not None, causes self to be owned by Qt instead of PyQt.
scene argument, if not None, causes self to be owned by Qt instead of PyQt.
构造 QGraphicsEllipseItem 使用 rectangle defined by ( x , y ) and the given width and height , as the default rectangle. parent 会被传递给 QAbstractGraphicsShapeItem 's 构造函数。
该函数在 Qt 4.3 引入。
另请参阅 QGraphicsScene.addItem ().
重实现自 QGraphicsItem.boundingRect ().
重实现自 QGraphicsItem.contains ().
重实现自 QGraphicsItem.isObscuredBy ().
重实现自 QGraphicsItem.opaqueArea ().
重实现自 QGraphicsItem.paint ().
Returns the item's ellipse geometry as a QRectF .
另请参阅 setRect () 和 QPainter.drawEllipse ().
Sets the item's ellipse geometry to rect . The rectangle's left edge defines the left edge of the ellipse, and the rectangle's top edge describes the top of the ellipse. The height and width of the rectangle describe the height and width of the ellipse.
另请参阅 rect () 和 QPainter.drawEllipse ().
Sets the item's rectangle to the rectangle defined by ( x , y ) and the given width and height .
This convenience function is equivalent to calling setRect(QRectF(x, y, width, height))
另请参阅 rect ().
Sets the span angle for an ellipse segment to angle , which is in 16ths of a degree. This angle is used together with startAngle () 到 represent an ellipse segment (a pie). By default, the span angle is 5760 (360 * 16, a full ellipse).
另请参阅 spanAngle (), setStartAngle (),和 QPainter.drawPie ().
Sets the start angle for an ellipse segment to angle , which is in 16ths of a degree. This angle is used together with spanAngle () for representing an ellipse segment (a pie). By default, the start angle is 0.
另请参阅 startAngle (), setSpanAngle (),和 QPainter.drawPie ().
重实现自 QGraphicsItem.shape ().
Returns the span angle of an ellipse segment in 16ths of a degree. This angle is used together with startAngle () for representing an ellipse segment (a pie). By default, this function returns 5760 (360 * 16, a full ellipse).
另请参阅 setSpanAngle () 和 startAngle ().
Returns the start angle for an ellipse segment in 16ths of a degree. This angle is used together with spanAngle () for representing an ellipse segment (a pie). By default, the start angle is 0.
另请参阅 setStartAngle () 和 spanAngle ().
重实现自 QGraphicsItem.type ().