• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepim API Reference
  • KDE Home
  • Contact Us
 

kdgantt2

  • sources
  • kde-4.12
  • kdepim
  • kdgantt2
kdganttview.h
Go to the documentation of this file.
1 /****************************************************************************
2  ** Copyright (C) 2001-2006 Klarälvdalens Datakonsult AB. All rights reserved.
3  **
4  ** This file is part of the KD Gantt library.
5  **
6  ** This file may be distributed and/or modified under the terms of the
7  ** GNU General Public License version 2 as published by the Free Software
8  ** Foundation and appearing in the file LICENSE.GPL included in the
9  ** packaging of this file.
10  **
11  ** Licensees holding valid commercial KD Gantt licenses may use this file in
12  ** accordance with the KD Gantt Commercial License Agreement provided with
13  ** the Software.
14  **
15  ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
16  ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
17  **
18  ** See http://www.kdab.net/kdgantt for
19  ** information about KD Gantt Commercial License Agreements.
20  **
21  ** Contact info@kdab.net if any conditions of this
22  ** licensing are not clear to you.
23  **
24  **********************************************************************/
25 #ifndef KDGANTTVIEW_H
26 #define KDGANTTVIEW_H
27 
28 #include <QWidget>
29 #include "kdganttglobal.h"
30 
31 class QAbstractItemModel;
32 class QAbstractProxyModel;
33 class QAbstractItemView;
34 class QModelIndex;
35 class QItemSelectionModel;
36 class QPrinter;
37 class QSplitter;
38 
39 namespace KDGantt {
40  class ItemDelegate;
41  class Constraint;
42  class ConstraintModel;
43  class AbstractGrid;
44  class GraphicsView;
45  class AbstractRowController;
46 
47  class KDGANTT_EXPORT View : public QWidget {
48  Q_OBJECT
49  KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC_QWIDGET(View)
50  Q_PRIVATE_SLOT( d, void slotCollapsed(const QModelIndex&) )
51  Q_PRIVATE_SLOT( d, void slotExpanded(const QModelIndex&) )
52  Q_PRIVATE_SLOT( d, void slotVerticalScrollValueChanged( int ) )
53  Q_PRIVATE_SLOT( d, void slotLeftWidgetVerticalRangeChanged( int, int ) )
54  Q_PRIVATE_SLOT( d, void slotGfxViewVerticalRangeChanged( int, int ) )
55 
56  public:
57 
58  explicit View(QWidget* parent=0);
59  virtual ~View();
60 
61  QAbstractItemModel* model() const;
62  QItemSelectionModel* selectionModel() const;
63  ItemDelegate* itemDelegate() const;
64  ConstraintModel* constraintModel() const;
65  AbstractGrid* grid() const;
66  QModelIndex rootIndex() const;
67 
68  QModelIndex indexAt( const QPoint& pos ) const;
69 
70  void setLeftView( QAbstractItemView* );
71  const QAbstractItemView* leftView() const;
72  QAbstractItemView* leftView();
73 
74  const QSplitter* splitter() const;
75  QSplitter* splitter();
76 
77  void setRowController( AbstractRowController* );
78  AbstractRowController* rowController();
79  const AbstractRowController* rowController() const;
80 
81  const GraphicsView* graphicsView() const;
82  GraphicsView* graphicsView();
83  const QAbstractProxyModel* ganttProxyModel() const;
84  QAbstractProxyModel* ganttProxyModel();
85 
86  void print( QPrinter* printer, bool drawRowLabels=true );
87  void print( QPrinter* printer, qreal start, qreal end, bool drawRowLabels=true );
88  void print( QPainter* painter, const QRectF& target = QRectF(), bool drawRowLabels=true);
89  void print( QPainter* painter, qreal start, qreal end,
90  const QRectF& target = QRectF(), bool drawRowLabels=true);
91 
92  public Q_SLOTS:
93  void setModel(QAbstractItemModel* model);
94  void setRootIndex( const QModelIndex& idx );
95  void setSelectionModel( QItemSelectionModel* smodel );
96  void setItemDelegate( ItemDelegate* );
97  void setConstraintModel( ConstraintModel* );
98  void setGrid( AbstractGrid* );
99 
100  protected:
101  /*reimp*/ void resizeEvent(QResizeEvent*);
102  };
103 }
104 
105 #endif /* KDGANTTVIEW_H */
KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC_QWIDGET
#define KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC_QWIDGET(X)
Definition: kdganttglobal.h:146
KDGantt::ItemDelegate
Class used to render gantt items in a KDGantt::GraphicsView.
Definition: kdganttitemdelegate.h:39
KDGantt::View
This widget that consists of a QTreeView and a GraphicsView.
Definition: kdganttview.h:47
KDGantt::GraphicsView
The GraphicsView class provides a model/view implementation of a gantt chart.
Definition: kdganttgraphicsview.h:44
kdganttglobal.h
QWidget
KDGANTT_EXPORT
#define KDGANTT_EXPORT
Definition: kdgantt_export.h:40
KDGantt::AbstractGrid
Abstract baseclass for grids. A grid is used to convert between QModelIndex'es and gantt chart values...
Definition: kdganttabstractgrid.h:40
d
#define d
Definition: kdganttabstractgrid.cpp:53
QAbstractProxyModel
QAbstractItemView
KDGantt::AbstractRowController
Abstract baseclass for row controllers. A row controller is used by the GraphicsView to nagivate the ...
Definition: kdganttabstractrowcontroller.h:34
KDGantt::ConstraintModel
Definition: kdganttconstraintmodel.h:35
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:55:05 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kdgantt2

Skip menu "kdgantt2"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Modules
  • Related Pages

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal