KDGantt::View Class Reference

#include <KDGanttView>

Inheritance diagram for KDGantt::View:

Inheritance graph
[legend]
Collaboration diagram for KDGantt::View:

Collaboration graph
[legend]

List of all members.


Detailed Description

This widget that consists of a QTreeView and a GraphicsView.

This is the easy to use, complete gantt chart widget. It consists of a QTreeView on the left and a KDGantt::GraphicsView on the right separated by a QSplitter. The two views share the same model.

Definition at line 47 of file kdganttview.h.


Public Slots

void setConstraintModel (ConstraintModel *)
void setGrid (AbstractGrid *)
void setItemDelegate (ItemDelegate *)
void setModel (QAbstractItemModel *model)
void setRootIndex (const QModelIndex &idx)
void setSelectionModel (QItemSelectionModel *smodel)

Protected Member Functions

void resizeEvent (QResizeEvent *)

Member Function Documentation

void View::resizeEvent ( QResizeEvent *  ev  )  [protected]

Definition at line 449 of file kdganttview.cpp.

00450 {
00451     QWidget::resizeEvent(ev);
00452 }

void View::setConstraintModel ( ConstraintModel cm  )  [slot]

Sets the constraintmodel displayed by this view.

See also:
KDGantt::ConstraintModel.

Definition at line 426 of file kdganttview.cpp.

References d.

00427 {
00428     d->constraintProxy.setSourceModel( cm );
00429     d->gfxview.setConstraintModel( &d->mappedConstraintModel );
00430 }

void View::setGrid ( AbstractGrid grid  )  [slot]

Sets the AbstractGrid for this view. The grid is an object that controls how QModelIndexes are mapped to and from the view and how the background and header is rendered.

See also:
AbstractGrid and DateTimeGrid.

Definition at line 379 of file kdganttview.cpp.

References d.

00380 {
00381     d->gfxview.setGrid( grid );
00382 }

void View::setItemDelegate ( ItemDelegate delegate  )  [slot]

Sets the KDGantt::ItemDelegate used for rendering items on this view.

See also:
ItemDelegate and QAbstractItemDelegate.

Definition at line 417 of file kdganttview.cpp.

References d.

00418 {
00419     leftView()->setItemDelegate( delegate );
00420     d->gfxview.setItemDelegate( delegate );
00421 }

void View::setModel ( QAbstractItemModel *  model  )  [slot]

Sets the QAbstractItemModel to be displayed in this view to model.

See also:
GraphicsView::setModel

Definition at line 351 of file kdganttview.cpp.

References d.

00352 {
00353     leftView()->setModel( model );
00354     d->ganttProxyModel.setSourceModel( model );
00355     d->gfxview.setModel( &d->ganttProxyModel );
00356 }

void View::setRootIndex ( const QModelIndex &  idx  )  [slot]

Sets the root index of the model displayed by this view. Similar to QAbstractItemView::setRootIndex, default is QModelIndex().

Definition at line 401 of file kdganttview.cpp.

References d.

00402 {
00403     leftView()->setRootIndex( idx );
00404     d->gfxview.setRootIndex( idx );
00405 }

void View::setSelectionModel ( QItemSelectionModel *  smodel  )  [slot]

Sets the QItemSelectionModel used by this view to manage selections. Similar to QAbstractItemView::setSelectionModel

Definition at line 368 of file kdganttview.cpp.

References d.

00369 {
00370     leftView()->setSelectionModel( smodel );
00371     d->gfxview.setSelectionModel( new QItemSelectionModel( &( d->ganttProxyModel ),this ) );
00372 }


The documentation for this class was generated from the following files:
Generated on Thu Mar 4 23:27:23 2010 for KD Chart 2 by  doxygen 1.5.4