![]() |
KD Chart 2
[rev.2.8]
|
#include <kdganttgraphicsitem.h>
Public Types | |
enum | { Type = UserType + 42 } |
Public Member Functions | |
void | addEndConstraint (ConstraintGraphicsItem *) |
void | addStartConstraint (ConstraintGraphicsItem *) |
QRectF | boundingRect () const override |
QList< ConstraintGraphicsItem * > | endConstraints () const |
virtual QString | ganttToolTip () const |
GraphicsItem (const QModelIndex &idx, QGraphicsItem *parent=0, GraphicsScene *scene=0) | |
GraphicsItem (QGraphicsItem *parent=0, GraphicsScene *scene=0) | |
const QPersistentModelIndex & | index () const |
bool | isEditable () const |
bool | isUpdating () const |
QVariant | itemChange (GraphicsItemChange, const QVariant &value) override |
void | paint (QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0) override |
QRectF | rect () const |
void | removeEndConstraint (ConstraintGraphicsItem *) |
void | removeStartConstraint (ConstraintGraphicsItem *) |
GraphicsScene * | scene () const |
void | setBoundingRect (const QRectF &r) |
void | setIndex (const QPersistentModelIndex &idx) |
void | setRect (const QRectF &r) |
QList< ConstraintGraphicsItem * > | startConstraints () const |
int | type () const override |
void | updateItem (const Span &rowgeometry, const QPersistentModelIndex &idx) |
~GraphicsItem () override | |
Protected Member Functions | |
void | focusInEvent (QFocusEvent *event) override |
void | hoverLeaveEvent (QGraphicsSceneHoverEvent *) override |
void | hoverMoveEvent (QGraphicsSceneHoverEvent *) override |
void | mouseDoubleClickEvent (QGraphicsSceneMouseEvent *) override |
void | mouseMoveEvent (QGraphicsSceneMouseEvent *) override |
void | mousePressEvent (QGraphicsSceneMouseEvent *) override |
void | mouseReleaseEvent (QGraphicsSceneMouseEvent *) override |
Definition at line 42 of file kdganttgraphicsitem.h.
anonymous enum |
Enumerator | |
---|---|
Type |
Definition at line 44 of file kdganttgraphicsitem.h.
|
explicit |
Definition at line 68 of file kdganttgraphicsitem.cpp.
References scene().
|
explicit |
Definition at line 76 of file kdganttgraphicsitem.cpp.
References scene().
|
override |
Definition at line 85 of file kdganttgraphicsitem.cpp.
void GraphicsItem::addEndConstraint | ( | ConstraintGraphicsItem * | item | ) |
Definition at line 242 of file kdganttgraphicsitem.cpp.
References KDGantt::ConstraintGraphicsItem::setEnd().
Referenced by KDGantt::GraphicsScene::insertItem().
void GraphicsItem::addStartConstraint | ( | ConstraintGraphicsItem * | item | ) |
Definition at line 234 of file kdganttgraphicsitem.cpp.
References KDGantt::ConstraintGraphicsItem::setStart().
Referenced by KDGantt::GraphicsScene::insertItem().
|
override |
Definition at line 196 of file kdganttgraphicsitem.cpp.
Referenced by mouseReleaseEvent(), and paint().
QList<ConstraintGraphicsItem*> KDGantt::GraphicsItem::endConstraints | ( | ) | const |
Definition at line 77 of file kdganttgraphicsitem.h.
Referenced by KDGantt::GraphicsScene::removeItem().
|
overrideprotected |
Definition at line 342 of file kdganttgraphicsitem.cpp.
References index(), scene(), and KDGantt::GraphicsScene::selectionModel().
|
virtual |
Definition at line 191 of file kdganttgraphicsitem.cpp.
References index(), KDGantt::GraphicsScene::itemDelegate(), scene(), and KDGantt::ItemDelegate::toolTip().
|
overrideprotected |
Definition at line 411 of file kdganttgraphicsitem.cpp.
|
overrideprotected |
Definition at line 379 of file kdganttgraphicsitem.cpp.
References index(), KDGantt::ItemDelegate::interactionStateFor(), isEditable(), KDGantt::GraphicsScene::itemDelegate(), KDGantt::GraphicsScene::itemEntered(), scene(), KDGantt::ItemDelegate::State_ExtendLeft, KDGantt::ItemDelegate::State_ExtendRight, and KDGantt::ItemDelegate::State_Move.
const QPersistentModelIndex& KDGantt::GraphicsItem::index | ( | ) | const |
Definition at line 66 of file kdganttgraphicsitem.h.
Referenced by focusInEvent(), ganttToolTip(), hoverMoveEvent(), itemChange(), mouseDoubleClickEvent(), mouseMoveEvent(), mousePressEvent(), mouseReleaseEvent(), paint(), and updateItem().
bool GraphicsItem::isEditable | ( | ) | const |
Definition at line 168 of file kdganttgraphicsitem.cpp.
References KDGantt::GraphicsScene::isReadOnly(), and scene().
Referenced by hoverMoveEvent(), itemChange(), mouseMoveEvent(), and mouseReleaseEvent().
bool KDGantt::GraphicsItem::isUpdating | ( | ) | const |
Definition at line 70 of file kdganttgraphicsitem.h.
Referenced by itemChange().
|
override |
Definition at line 316 of file kdganttgraphicsitem.cpp.
References index(), isEditable(), isUpdating(), scene(), and KDGantt::GraphicsScene::selectionModel().
|
overrideprotected |
Definition at line 504 of file kdganttgraphicsitem.cpp.
References index(), KDGantt::ItemDelegate::interactionStateFor(), KDGantt::GraphicsScene::itemDelegate(), KDGantt::GraphicsScene::itemDoubleClicked(), KDGantt::ItemTypeRole, scene(), KDGantt::ItemDelegate::State_None, and KDGantt::TypeSummary.
|
overrideprotected |
Definition at line 546 of file kdganttgraphicsitem.cpp.
References index(), isEditable(), rect(), scene(), KDGantt::GraphicsScene::selectionModel(), KDGantt::GraphicsScene::setDragSource(), KDGantt::ItemDelegate::State_DragConstraint, KDGantt::ItemDelegate::State_ExtendLeft, KDGantt::ItemDelegate::State_ExtendRight, and KDGantt::ItemDelegate::State_Move.
|
overrideprotected |
Definition at line 418 of file kdganttgraphicsitem.cpp.
References index(), KDGantt::ItemDelegate::interactionStateFor(), KDGantt::GraphicsScene::itemDelegate(), KDGantt::GraphicsScene::itemPressed(), scene(), KDGantt::ItemDelegate::State_ExtendLeft, KDGantt::ItemDelegate::State_ExtendRight, and KDGantt::ItemDelegate::State_None.
|
overrideprotected |
Definition at line 444 of file kdganttgraphicsitem.cpp.
References KDGantt::GraphicsView::addConstraint(), boundingRect(), index(), isEditable(), KDGantt::GraphicsScene::itemClicked(), KDGantt::ItemTypeRole, rect(), scene(), KDGantt::GraphicsScene::setDragSource(), and KDGantt::TypeEvent.
|
override |
Definition at line 173 of file kdganttgraphicsitem.cpp.
References boundingRect(), index(), KDGantt::GraphicsScene::itemDelegate(), KDGantt::ItemDelegate::paintGanttItem(), and scene().
QRectF KDGantt::GraphicsItem::rect | ( | ) | const |
Definition at line 60 of file kdganttgraphicsitem.h.
Referenced by mouseMoveEvent(), mouseReleaseEvent(), updateItem(), and KDGantt::GraphicsScene::updateItems().
void GraphicsItem::removeEndConstraint | ( | ConstraintGraphicsItem * | item | ) |
Definition at line 257 of file kdganttgraphicsitem.cpp.
void GraphicsItem::removeStartConstraint | ( | ConstraintGraphicsItem * | item | ) |
Definition at line 250 of file kdganttgraphicsitem.cpp.
GraphicsScene * GraphicsItem::scene | ( | ) | const |
Definition at line 141 of file kdganttgraphicsitem.cpp.
Referenced by focusInEvent(), ganttToolTip(), GraphicsItem(), hoverMoveEvent(), isEditable(), itemChange(), mouseDoubleClickEvent(), mouseMoveEvent(), mousePressEvent(), mouseReleaseEvent(), paint(), and updateItem().
void GraphicsItem::setBoundingRect | ( | const QRectF & | r | ) |
Definition at line 161 of file kdganttgraphicsitem.cpp.
Referenced by updateItem().
void GraphicsItem::setIndex | ( | const QPersistentModelIndex & | idx | ) |
Definition at line 185 of file kdganttgraphicsitem.cpp.
Referenced by updateItem(), and KDGantt::GraphicsScene::updateRow().
void GraphicsItem::setRect | ( | const QRectF & | r | ) |
Definition at line 146 of file kdganttgraphicsitem.cpp.
Referenced by updateItem().
QList<ConstraintGraphicsItem*> KDGantt::GraphicsItem::startConstraints | ( | ) | const |
Definition at line 76 of file kdganttgraphicsitem.h.
Referenced by KDGantt::GraphicsScene::removeItem().
|
override |
Definition at line 99 of file kdganttgraphicsitem.cpp.
References Type.
void GraphicsItem::updateItem | ( | const Span & | rowgeometry, |
const QPersistentModelIndex & | idx | ||
) |
Definition at line 278 of file kdganttgraphicsitem.cpp.
References KDGantt::GraphicsScene::grid(), index(), KDGantt::ItemDelegate::itemBoundingSpan(), KDGantt::GraphicsScene::itemDelegate(), KDGantt::ItemTypeRole, KDGantt::Span::length(), KDGantt::AbstractRowController::maximumItemHeight(), rect(), KDGantt::GraphicsScene::rowController(), scene(), setBoundingRect(), setIndex(), setRect(), KDGantt::Span::start(), and KDGantt::TypeMulti.
Referenced by KDGantt::GraphicsScene::updateItems(), and KDGantt::GraphicsScene::updateRow().