digiKam
tableview_column_photo.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-03-14
7  * Description : Table view column helpers: Photo 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_PHOTO_H
25 #define DIGIKAM_TABLE_VIEW_COLUMN_PHOTO_H
26 
27 // Qt includes
28 
29 #include <QStringList>
30 
31 // Local includes
32 
34 
35 class QComboBox;
36 
37 namespace Digikam
38 {
39 
40 namespace TableViewColumns
41 {
42 
44 {
45  Q_OBJECT
46 
47 public:
48 
49  enum SubColumn
50  {
61  };
62 
63 private:
64 
65  SubColumn subColumn;
66 
67 public:
68 
69  explicit ColumnPhotoProperties(TableViewShared* const tableViewShared,
70  const TableViewColumnConfiguration& pConfiguration,
71  const SubColumn pSubColumn,
72  QObject* const parent = nullptr);
73  ~ColumnPhotoProperties() override;
74 
75  QString getTitle() const override;
76  ColumnFlags getColumnFlags() const override;
77  QVariant data(TableViewModel::Item* const item, const int role) const override;
78  ColumnCompareResult compare(TableViewModel::Item* const itemA, TableViewModel::Item* const itemB) const override;
79  TableViewColumnConfigurationWidget* getConfigurationWidget(QWidget* const parentWidget) const override;
80  void setConfiguration(const TableViewColumnConfiguration& newConfiguration) override;
81 
83  static QStringList getSubColumns();
84 };
85 
86 // ----------------------------------------------------------------------------------------------------------------------
87 
89 {
90  Q_OBJECT
91 
92 public:
93 
94  explicit ColumnPhotoConfigurationWidget(TableViewShared* const sharedObject,
95  const TableViewColumnConfiguration& columnConfiguration,
96  QWidget* const parentWidget);
98 
100 
101 private Q_SLOTS:
102 
103  void slotUpdateUI();
104 
105 private:
106 
108  QComboBox* selectorExposureTimeFormat;
109  QComboBox* selectorExposureTimeUnit;
110 };
111 
112 } // namespace TableViewColumns
113 
114 } // namespace Digikam
115 
116 #endif // DIGIKAM_TABLE_VIEW_COLUMN_PHOTO_H
Definition: tableview_columnfactory.h:175
Definition: tableview_columnfactory.h:50
Definition: tableview_columnfactory.h:81
Definition: tableview_columnfactory.h:196
ColumnCompareResult
Definition: tableview_columnfactory.h:216
Definition: tableview_column_photo.h:89
TableViewColumnConfiguration getNewConfiguration() override
Definition: tableview_column_photo.cpp:487
~ColumnPhotoConfigurationWidget() override
Definition: tableview_column_photo.cpp:483
ColumnPhotoConfigurationWidget(TableViewShared *const sharedObject, const TableViewColumnConfiguration &columnConfiguration, QWidget *const parentWidget)
Definition: tableview_column_photo.cpp:436
Definition: tableview_column_photo.h:44
~ColumnPhotoProperties() override
Definition: tableview_column_photo.cpp:59
ColumnPhotoProperties(TableViewShared *const tableViewShared, const TableViewColumnConfiguration &pConfiguration, const SubColumn pSubColumn, QObject *const parent=nullptr)
Definition: tableview_column_photo.cpp:50
static QStringList getSubColumns()
Definition: tableview_column_photo.cpp:63
ColumnFlags getColumnFlags() const override
Definition: tableview_column_photo.cpp:157
void setConfiguration(const TableViewColumnConfiguration &newConfiguration) override
Definition: tableview_column_photo.cpp:498
QString getTitle() const override
Definition: tableview_column_photo.cpp:99
QVariant data(TableViewModel::Item *const item, const int role) const override
Definition: tableview_column_photo.cpp:179
ColumnCompareResult compare(TableViewModel::Item *const itemA, TableViewModel::Item *const itemB) const override
Definition: tableview_column_photo.cpp:361
TableViewColumnConfigurationWidget * getConfigurationWidget(QWidget *const parentWidget) const override
Definition: tableview_column_photo.cpp:427
static TableViewColumnDescription getDescription()
Definition: tableview_column_photo.cpp:80
SubColumn
Definition: tableview_column_photo.h:50
@ SubColumnWhiteBalance
Definition: tableview_column_photo.h:60
@ SubColumnExposure
Definition: tableview_column_photo.h:56
@ SubColumnFlash
Definition: tableview_column_photo.h:59
@ SubColumnCameraMaker
Definition: tableview_column_photo.h:51
@ SubColumnLens
Definition: tableview_column_photo.h:53
@ SubColumnFocal
Definition: tableview_column_photo.h:55
@ SubColumnCameraModel
Definition: tableview_column_photo.h:52
@ SubColumnSensitivity
Definition: tableview_column_photo.h:57
@ SubColumnAperture
Definition: tableview_column_photo.h:54
@ SubColumnModeProgram
Definition: tableview_column_photo.h:58
Definition: tableview_model.h:71
Definition: tableview_shared.h:44
Definition: datefolderview.cpp:43