ItemBackground Class Reference
from PyKDE4.plasma import *
Inherits: QGraphicsWidget → QObject
Namespace: Plasma
Detailed Description
Signals |
| animationStep (float progress) |
| appearanceChanged () |
| targetItemReached (QGraphicsItem a0) |
| targetReached (QRectF a0) |
Methods |
| __init__ (self, QGraphicsWidget parent=0) |
bool | eventFilter (self, QObject watched, QEvent event) |
QVariant | itemChange (self, QGraphicsItem.GraphicsItemChange change, QVariant value) |
| paint (self, QPainter painter, QStyleOptionGraphicsItem option, QWidget widget) |
| resizeEvent (self, QGraphicsSceneResizeEvent a0) |
bool | sceneEventFilter (self, QGraphicsItem watched, QEvent event) |
| setTarget (self, QRectF newGeometry) |
| setTargetItem (self, QGraphicsItem target) |
QRectF | target (self) |
QGraphicsItem | targetItem (self) |
Signal Documentation
animationStep |
( |
float |
progress |
|
) |
|
|
|
Emitted at each animation frame. Useful for synchronizing item animations
- Signal syntax:
QObject.connect(source, SIGNAL("animationStep(qreal)"), target_slot)
Emitted when the visual layout and appearance changes. Useful for synchronizing
content margins.
- Signal syntax:
QObject.connect(source, SIGNAL("appearanceChanged()"), target_slot)
Emitted when the target has been reached. Useful to consider this instead of
the corresponding hoverEnterEvent;
- Signal syntax:
QObject.connect(source, SIGNAL("targetItemReached(QGraphicsItem*)"), target_slot)
Emitted when the target has been reached. Useful to consider this instead of
the corresponding hoverEnterEvent;
- Signal syntax:
QObject.connect(source, SIGNAL("targetReached(QRectF)"), target_slot)
Method Documentation
setTarget |
( |
self, |
|
|
|
QRectF |
newGeometry |
|
) |
|
|
|
Sets a new target geometry we want at the end of animation
@arg newGeometry the final geometry target
set the ItemBackground geometry to be the target geometry, plus the ItemBackground margins
- Returns:
- the current target rect; may be empty if there is no target currently set
- Returns:
- the target item, if any