• 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
kdganttabstractgrid.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 KDGANTTABSTRACTGRID_H
26 #define KDGANTTABSTRACTGRID_H
27 
28 #include "kdganttglobal.h"
29 #include "kdganttconstraint.h"
30 
31 class QPainter;
32 class QRectF;
33 class QAbstractItemModel;
34 class QModelIndex;
35 
36 namespace KDGantt {
37  class AbstractRowController;
38  class Span;
39 
40  class KDGANTT_EXPORT AbstractGrid : public QObject {
41  Q_OBJECT
42  KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC( AbstractGrid )
43  friend class GraphicsScene;
44  public:
45 
46  AbstractGrid(QObject* parent = 0);
47  virtual ~AbstractGrid();
48 
49  QAbstractItemModel* model() const;
50  QModelIndex rootIndex() const;
51 
52  virtual Span mapToChart( const QModelIndex& idx ) const = 0;
53  virtual bool mapFromChart( const Span& span, const QModelIndex& idx,
54  const QList<Constraint>& constraints=QList<Constraint>() ) const = 0;
55  bool isSatisfiedConstraint( const Constraint& c ) const;
56 
57  virtual void paintGrid( QPainter* painter, const QRectF& sceneRect, const QRectF& exposedRect,
58  AbstractRowController* rowController = 0, QWidget* widget=0 ) = 0;
59  virtual void paintHeader( QPainter* painter, const QRectF& headerRect, const QRectF& exposedRect,
60  qreal offset, QWidget* widget=0 ) = 0;
61  public Q_SLOTS:
62  /*internal*/ virtual void setModel( QAbstractItemModel* model );
63  /*internal*/ virtual void setRootIndex( const QModelIndex& idx );
64  Q_SIGNALS:
65  void gridChanged();
66  };
67 }
68 
69 #endif /* KDGANTTABSTRACTGRID_H */
70 
KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC
#define KDGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC(X)
Definition: kdganttglobal.h:121
kdganttglobal.h
QWidget
KDGANTT_EXPORT
#define KDGANTT_EXPORT
Definition: kdgantt_export.h:40
kdganttconstraint.h
QObject
KDGantt::GraphicsScene
Definition: kdganttgraphicsscene.h:48
KDGantt::Span
A class representing a start point and a length.
Definition: kdganttglobal.h:220
KDGantt::AbstractGrid
Abstract baseclass for grids. A grid is used to convert between QModelIndex'es and gantt chart values...
Definition: kdganttabstractgrid.h:40
KDGantt::Constraint
A class used to represent a dependency.
Definition: kdganttconstraint.h:38
KDGantt::AbstractRowController
Abstract baseclass for row controllers. A row controller is used by the GraphicsView to nagivate the ...
Definition: kdganttabstractrowcontroller.h:34
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