KGantt

kganttproxymodel.h
1/*
2 * SPDX-FileCopyrightText: 2001-2015 Klaralvdalens Datakonsult AB. All rights reserved.
3 *
4 * This file is part of the KGantt library.
5 *
6 * SPDX-License-Identifier: GPL-2.0-or-later
7 */
8
9#ifndef KGANTTPROXYMODEL_H
10#define KGANTTPROXYMODEL_H
11
12#include "kganttforwardingproxymodel.h"
13
14namespace KGantt {
15 class KGANTT_EXPORT ProxyModel : public ForwardingProxyModel {
16 Q_OBJECT
17 Q_DISABLE_COPY(ProxyModel)
18 KGANTT_DECLARE_PRIVATE_BASE_POLYMORPHIC( ProxyModel )
19 public:
20 explicit ProxyModel( QObject* parent = nullptr );
21 ~ProxyModel() override;
22
23 void setColumn( int ganttrole, int col );
24 void removeColumn( int ganttrole );
25 void setRole( int ganttrole, int role );
26 void removeRole( int ganttrole );
27
28 int column( int ganttrole ) const;
29 int role( int ganttrole ) const;
30
31#if 0
32 void setCalendarMode( bool enable );
33 bool calendarMode() const;
34#endif
35
36 /*reimp*/ QModelIndex mapFromSource( const QModelIndex& idx) const override;
37 /*reimp*/ QModelIndex mapToSource( const QModelIndex& proxyIdx ) const override;
38
39 /*reimp*/ int rowCount( const QModelIndex& idx ) const override;
40 /*reimp*/ int columnCount( const QModelIndex& idx ) const override;
41
42 /*reimp*/ QVariant data( const QModelIndex& idx, int role = Qt::DisplayRole ) const override;
43 /*reimp*/ bool setData( const QModelIndex& idx, const QVariant& value, int role=Qt::EditRole ) override;
44 };
45}
46
47#endif /* KGANTTPROXYMODEL_H */
48
Global namespace.
DisplayRole
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Dec 13 2024 11:52:09 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.