digiKam
galleryinfo.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 : 2006-04-04
7  * Description : a tool to generate HTML image galleries
8  *
9  * Copyright (C) 2006-2010 by Aurelien Gateau <aurelien dot gateau at free dot fr>
10  * Copyright (C) 2012-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
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_GALLERY_INFO_H
25 #define DIGIKAM_GALLERY_INFO_H
26 
27 // Qt includes
28 
29 #include <QList>
30 #include <QUrl>
31 #include <QDebug>
32 
33 // Local includes
34 
35 #include "galleryconfig.h"
36 #include "dinfointerface.h"
37 
38 using namespace Digikam;
39 
41 {
42 
47 class GalleryInfo : public GalleryConfig
48 {
49  Q_OBJECT
50 
51 public:
52 
54  {
55  ALBUMS = 0,
56  IMAGES
57  };
58 
59 public:
60 
61  explicit GalleryInfo(DInfoInterface* const iface = nullptr);
62  ~GalleryInfo() override;
63 
64  QString fullFormatString() const;
65 
66  QString thumbnailFormatString() const;
67 
68  QString getThemeParameterValue(const QString& theme, const QString& parameter,
69  const QString& defaultValue) const;
70 
71  void setThemeParameterValue(const QString& theme, const QString& parameter,
72  const QString& value);
73 
74 public:
75 
76  ImageGetOption m_getOption; // Type of image selection (albums or images list).
77 
78  DInfoInterface::DAlbumIDs m_albumList; // Albums list for ImageGetOption::ALBUMS selection.
79 
80  QList<QUrl> m_imageList; // Images list for ImageGetOption::IMAGES selection.
81 
82  DInfoInterface* m_iface; // Interface to handle items information.
83 
84 private:
85 
90  QString getEnumString(const QString& itemName) const;
91 };
92 
94 QDebug operator<<(QDebug dbg, const GalleryInfo& t);
95 
96 } // namespace DigikamGenericHtmlGalleryPlugin
97 
98 #endif // DIGIKAM_GALLERY_INFO_H
ImageGetOption
Definition: galleryinfo.h:54
ImageGetOption m_getOption
Definition: galleryinfo.h:76
DInfoInterface::DAlbumIDs m_albumList
Definition: galleryinfo.h:78
QList< QUrl > m_imageList
Definition: galleryinfo.h:80
DInfoInterface * m_iface
Definition: galleryinfo.h:82
Definition: dinfointerface.h:56
qulonglong value
Definition: itemviewutilities.cpp:592
Definition: galleryconfig.cpp:30
Definition: datefolderview.cpp:43
QDebug operator<<(QDebug dbg, const DbEngineParameters &p)
Definition: dbengineparameters.cpp:863