digiKam
kmlwidget.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-05-16
7  * Description : a tool to export GPS data to KML file.
8  *
9  * Copyright (C) 2006-2007 by Stephane Pontier <shadow dot walker at free dot fr>
10  * Copyright (C) 2008-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_KML_WIDGET_H
25 #define DIGIKAM_KML_WIDGET_H
26 
27 // Qt includes
28 
29 #include <QWidget>
30 #include <QList>
31 #include <QUrl>
32 
33 // Local includes
34 
35 #include "kmlexport.h"
36 #include "dfileselector.h"
37 #include "dcolorselector.h"
38 #include "dinfointerface.h"
39 #include "geolocationedit.h"
40 #include "gpsitemmodel.h"
41 
42 class QButtonGroup;
43 class QCheckBox;
44 class QGridLayout;
45 class QGroupBox;
46 class QLabel;
47 class QLineEdit;
48 class QRadioButton;
49 class QSpacerItem;
50 class QComboBox;
51 class QCloseEvent;
52 class QSpinBox;
53 class QPushButton;
54 
55 using namespace Digikam;
56 
58 {
59 
60 class KmlWidget : public QWidget
61 {
62  Q_OBJECT
63 
64 public:
65 
66  explicit KmlWidget(GeolocationEdit* const dlg,
67  GPSItemModel* const imageModel,
68  DInfoInterface* const iface);
69  ~KmlWidget() override;
70 
71 public:
72 
73  QLabel* ImageSizeLabel;
74  QLabel* IconSizeLabel;
76  QLabel* FileNameLabel_;
78  QLabel* GPXFileLabel_;
79  QLabel* timeZoneLabel_;
81  QLabel* GPXColorLabel_;
84 
86  QGroupBox* TargetTypeGroupBox;
87 
88  QButtonGroup* buttonGroupTargetType;
89 
90  QRadioButton* LocalTargetRadioButton_;
92 
93  QLineEdit* DestinationUrl_;
94  QLineEdit* FileName_;
95 
96  QCheckBox* GPXTracksCheckBox_;
97 
98  QComboBox* AltitudeCB_;
99  QComboBox* timeZoneCB;
100  QComboBox* GPXAltitudeCB_;
101 
103 
106  QPushButton* m_geneBtn;
107 
108  QSpinBox* ImageSizeInput_;
109  QSpinBox* IconSizeInput_;
112 
115 
116 Q_SIGNALS:
117 
118  void signalSetUIEnabled(const bool enabledState);
119  void signalProgressSetup(const int maxProgress, const QString& progressText);
120 
121 public Q_SLOTS:
122 
123  void slotGoogleMapTargetRadioButtonToggled(bool);
124  void slotKMLTracksCheckButtonToggled(bool);
125 
126 protected:
127 
128  void saveSettings();
129  void readSettings();
130 
131 protected Q_SLOTS:
132 
133  void slotKMLGenerate();
134 
135 protected:
136 
137  QGridLayout* KMLExportConfigLayout;
138  QGridLayout* SizeGroupBoxLayout;
141 
143 };
144 
145 } // namespace DigikamGenericGeolocationEditPlugin
146 
147 #endif // DIGIKAM_KML_WIDGET_H
QLabel * GPXLineWidthLabel_
Definition: kmlwidget.h:80
QPushButton * m_geneBtn
Definition: kmlwidget.h:106
QComboBox * AltitudeCB_
Definition: kmlwidget.h:98
GeolocationEdit * m_dlg
Definition: kmlwidget.h:114
QLabel * destinationDirectoryLabel_
Definition: kmlwidget.h:75
QComboBox * timeZoneCB
Definition: kmlwidget.h:99
void signalProgressSetup(const int maxProgress, const QString &progressText)
QLabel * GPXColorLabel_
Definition: kmlwidget.h:81
QSpinBox * IconSizeInput_
Definition: kmlwidget.h:109
GPSItemModel * m_model
Definition: kmlwidget.h:113
QLabel * ImageSizeLabel
Definition: kmlwidget.h:73
QLabel * GPXAltitudeLabel_
Definition: kmlwidget.h:82
QGroupBox * TargetPreferenceGroupBox
Definition: kmlwidget.h:85
QGridLayout * SizeGroupBoxLayout
Definition: kmlwidget.h:138
QSpinBox * GPXLineWidthInput_
Definition: kmlwidget.h:111
QGroupBox * TargetTypeGroupBox
Definition: kmlwidget.h:86
QLabel * timeZoneLabel_
Definition: kmlwidget.h:79
QLineEdit * FileName_
Definition: kmlwidget.h:94
QLabel * GPXTracksOpacityLabel_
Definition: kmlwidget.h:83
QSpinBox * GPXTracksOpacityInput_
Definition: kmlwidget.h:110
QGridLayout * TargetPreferenceGroupBoxLayout
Definition: kmlwidget.h:139
DFileSelector * GPXFileUrlRequester_
Definition: kmlwidget.h:105
KmlExport m_kmlExport
Definition: kmlwidget.h:142
QLabel * GPXFileLabel_
Definition: kmlwidget.h:78
QLabel * DestinationUrlLabel_
Definition: kmlwidget.h:77
QGridLayout * buttonGroupTargetTypeLayout
Definition: kmlwidget.h:140
QRadioButton * LocalTargetRadioButton_
Definition: kmlwidget.h:90
QLabel * FileNameLabel_
Definition: kmlwidget.h:76
QLineEdit * DestinationUrl_
Definition: kmlwidget.h:93
DColorSelector * GPXTrackColor_
Definition: kmlwidget.h:102
QLabel * IconSizeLabel
Definition: kmlwidget.h:74
QComboBox * GPXAltitudeCB_
Definition: kmlwidget.h:100
QRadioButton * GoogleMapTargetRadioButton_
Definition: kmlwidget.h:91
void signalSetUIEnabled(const bool enabledState)
QButtonGroup * buttonGroupTargetType
Definition: kmlwidget.h:88
QGridLayout * KMLExportConfigLayout
Definition: kmlwidget.h:137
QSpinBox * ImageSizeInput_
Definition: kmlwidget.h:108
QCheckBox * GPXTracksCheckBox_
Definition: kmlwidget.h:96
DFileSelector * DestinationDirectory_
Definition: kmlwidget.h:104
Definition: dcolorselector.h:43
Definition: dfileselector.h:48
Definition: dinfointerface.h:56
Definition: gpsitemmodel.h:43
Definition: geolocationedit.cpp:97
Definition: datefolderview.cpp:43