digiKam
tableview_column_digikam.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2013-02-28
7  * Description : Table view column helpers: Digikam properties
8  *
9  * Copyright (C) 2017-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
10  * Copyright (C) 2013 by Michael G. Hansen <mike at mghansen dot de>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option) any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_TABLE_VIEW_COLUMN_DIGIKAM_H
25 #define DIGIKAM_TABLE_VIEW_COLUMN_DIGIKAM_H
26 
27 // Qt includes
28 
29 #include <QStringList>
30 
31 // Local includes
32 
34 
35 namespace Digikam
36 {
37 
38 namespace TableViewColumns
39 {
40 
42 {
43  Q_OBJECT
44 
45 public:
46 
47  enum SubColumn
48  {
54  SubColumnTags = 5
55  };
56 
57 public:
58 
59  explicit ColumnDigikamProperties(
60  TableViewShared* const tableViewShared,
61  const TableViewColumnConfiguration& pConfiguration,
62  const SubColumn pSubColumn,
63  QObject* const parent = nullptr);
64  ~ColumnDigikamProperties() override;
65 
66  QString getTitle() const override;
67  ColumnFlags getColumnFlags() const override;
68  QVariant data(TableViewModel::Item* const item, const int role) const override;
69  ColumnCompareResult compare(TableViewModel::Item* const itemA, TableViewModel::Item* const itemB) const override;
70  bool columnAffectedByChangeset(const ImageChangeset& imageChangeset) const override;
71 
73  static QStringList getSubColumns();
74 
75 private:
76 
77  SubColumn subColumn;
78 };
79 
80 } // namespace TableViewColumns
81 
82 } // namespace Digikam
83 
84 #endif // DIGIKAM_TABLE_VIEW_COLUMN_DIGIKAM_H
Definition: coredbchangesets.h:48
Definition: tableview_columnfactory.h:50
Definition: tableview_columnfactory.h:81
Definition: tableview_columnfactory.h:196
ColumnCompareResult
Definition: tableview_columnfactory.h:216
Definition: tableview_column_digikam.h:42
~ColumnDigikamProperties() override
Definition: tableview_column_digikam.cpp:57
QString getTitle() const override
Definition: tableview_column_digikam.cpp:96
ColumnFlags getColumnFlags() const override
Definition: tableview_column_digikam.cpp:134
QVariant data(TableViewModel::Item *const item, const int role) const override
Definition: tableview_column_digikam.cpp:150
static QStringList getSubColumns()
Definition: tableview_column_digikam.cpp:61
ColumnDigikamProperties(TableViewShared *const tableViewShared, const TableViewColumnConfiguration &pConfiguration, const SubColumn pSubColumn, QObject *const parent=nullptr)
Definition: tableview_column_digikam.cpp:48
bool columnAffectedByChangeset(const ImageChangeset &imageChangeset) const override
Definition: tableview_column_digikam.cpp:527
static TableViewColumnDescription getDescription()
Definition: tableview_column_digikam.cpp:74
ColumnCompareResult compare(TableViewModel::Item *const itemA, TableViewModel::Item *const itemB) const override
Definition: tableview_column_digikam.cpp:480
SubColumn
Definition: tableview_column_digikam.h:48
@ SubColumnRating
Definition: tableview_column_digikam.h:49
@ SubColumnColorLabel
Definition: tableview_column_digikam.h:51
@ SubColumnCaption
Definition: tableview_column_digikam.h:53
@ SubColumnTitle
Definition: tableview_column_digikam.h:52
@ SubColumnPickLabel
Definition: tableview_column_digikam.h:50
@ SubColumnTags
Definition: tableview_column_digikam.h:54
Definition: tableview_model.h:71
Definition: tableview_shared.h:44
Definition: datefolderview.cpp:43