23 #ifndef KDGANTTGRAPHICSSCENE_H 24 #define KDGANTTGRAPHICSSCENE_H 28 #include <QGraphicsScene> 29 #include <QModelIndex> 35 class QItemSelectionModel;
41 class AbstractRowController;
44 class ConstraintModel;
45 class ConstraintGraphicsItem;
58 static QModelIndex mainIndex(
const QModelIndex& idx );
59 static QModelIndex dataIndex(
const QModelIndex& idx );
61 QAbstractItemModel* model()
const;
63 QModelIndex rootIndex()
const;
65 QItemSelectionModel* selectionModel()
const;
67 void insertItem(
const QPersistentModelIndex&,
GraphicsItem* );
68 void removeItem(
const QModelIndex& );
69 using QGraphicsScene::removeItem;
71 GraphicsItem* findItem(
const QPersistentModelIndex& )
const;
75 void deleteSubtree(
const QModelIndex& );
78 void clearConstraintItems();
89 bool isReadOnly()
const;
91 void updateRow(
const QModelIndex& idx );
95 void itemEntered(
const QModelIndex& );
96 void itemPressed(
const QModelIndex& );
97 void itemClicked(
const QModelIndex& );
98 void itemDoubleClicked(
const QModelIndex& );
103 void print( QPrinter* printer,
bool drawRowLabels =
true,
bool drawColumnLabels =
true );
104 void print( QPrinter* printer, qreal start, qreal end,
bool drawRowLabels =
true,
bool drawColumnLabels =
true );
105 void print( QPainter* painter,
const QRectF& target = QRectF(),
bool drawRowLabels=
true,
bool drawColumnLabels =
true );
106 void print( QPainter* painter, qreal start, qreal end,
const QRectF& target = QRectF(),
bool drawRowLabels=
true,
bool drawColumnLabels =
true );
111 void clicked(
const QModelIndex & index );
112 void qrealClicked(
const QModelIndex & index );
113 void entered(
const QModelIndex & index );
114 void pressed(
const QModelIndex & index );
117 void helpEvent( QGraphicsSceneHelpEvent *helpEvent )
override;
118 void drawBackground( QPainter* painter,
const QRectF& rect )
override;
119 void drawForeground( QPainter* painter,
const QRectF& rect )
override;
122 void setModel( QAbstractItemModel* );
125 void setRootIndex(
const QModelIndex& idx );
126 void setSelectionModel( QItemSelectionModel* selectionmodel );
127 void setReadOnly(
bool );
133 void slotGridChanged();
135 void doPrint( QPainter* painter,
const QRectF& targetRect,
136 qreal start, qreal end,
137 QPrinter* printer,
bool drawRowLabels,
bool drawColumnLabels );
#define KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC(X)
Abstract baseclass for grids. A grid is used to convert between QModelIndex'es and gantt chart values...
A class used to represent a dependency.
Class used to render gantt items in a KDGantt::GraphicsView.
Class only listed here to document inheritance of some KDChart classes.
Class only listed here to document inheritance of some KDChart classes.
Abstract baseclass for row controllers. A row controller is used by the GraphicsView to nagivate the ...