9#include "ui_imagingplanner.h"
10#include "catalogsdb.h"
15#include <QFutureWatcher>
16#include <QSortFilterProxyModel>
21class ImagingPlannerPopup;
25class ImagingPlannerDBEntry
39 ImagingPlannerDBEntry() {};
40 ImagingPlannerDBEntry(
const QString &name,
int flags,
const QString ¬es);
41 ImagingPlannerDBEntry(
const QString &name,
bool picked,
bool imaged,
bool ignored,
const QString ¬es);
42 void setFlags(
bool picked,
bool imaged,
bool ignored);
43 void getFlags(
bool *picked,
bool *imaged,
bool *ignored);
44 QString name() {
return m_Name; }
47class ImagingPlannerUI :
public QFrame,
public Ui::ImagingPlanner
61 CatalogImageInfo(
const QString &csv);
62 QString m_Name, m_Filename, m_Author, m_Link, m_License;
72 void setMinHours(
double hours);
73 void setImagedConstraints(
bool enabled,
bool required);
74 void setPickedConstraints(
bool enabled,
bool required);
75 void setIgnoredConstraints(
bool enabled,
bool required);
76 void setKeywordConstraints(
bool enabled,
bool required,
const QString &keyword);
77 void setSortColumn(
int column);
80 double m_MinHours = 0;
81 bool m_ImagedConstraintsEnabled =
false;
82 bool m_ImagedRequired =
false;
83 bool m_PickedConstraintsEnabled =
false;
84 bool m_PickedRequired =
false;
85 bool m_IgnoredConstraintsEnabled =
false;
86 bool m_IgnoredRequired =
false;
87 bool m_KeywordConstraintsEnabled =
false;
88 bool m_KeywordRequired =
false;
92 bool m_ReverseSort =
false;
95class ImagingPlanner :
public QDialog
101 virtual ~ImagingPlanner()
override =
default;
107 void setSelection(
int flag,
bool enabled);
109 void setSelectionIgnored();
110 void setSelectionNotIgnored();
112 void setSelectionImaged();
113 void setSelectionNotImaged();
115 void setSelectionPicked();
116 void setSelectionNotPicked();
118 void centerOnSkymap();
119 void reallyCenterOnSkymap();
123 void searchAstrobin();
124 void searchWikipedia();
126 void searchNGCICImages();
128 void sorry(
const QString &message);
131 void popupSorry(
const QString &message);
138 void userNotesEditFinished();
139 void keywordEditFinished();
140 void loadImagedFile();
142 void loadCatalogViaMenu();
144 void openOptionsMenu();
150 void catalogLoaded();
151 void loadCatalog(
const QString &path);
152 void installEventFilters();
153 void removeEventFilters();
157 void setupHideButtons(
bool(*option)(),
void(*setOption)(
bool),
160 void setupFilterButton(
QCheckBox *checkbox,
bool(*option)(),
void(*setOption)(
bool));
161 void setupFilter2Buttons(
163 bool(*yesOption)(),
bool(*noOption)(),
bool(*dontCareOption)(),
164 void(*setYesOption)(
bool),
void(*setNoOption)(
bool),
void(*setDontCareOption)(
bool));
166 void updateSortConstraints();
169 QDate getDate()
const;
171 void loadInitialCatalog();
172 QString defaultDirectory()
const;
173 QString findDefaultCatalog()
const;
175 bool addCatalogItem(
const KSAlmanac &ksal,
const QString &name,
int flags = 0);
176 QUrl getAstrobinUrl(
const QString &target,
bool requireAwards,
bool requireSomeFilters,
double minRadius,
double maxRadius);
177 void popupAstrobin(
const QString &target);
178 void plotAltitudeGraph(
const QDate &date,
const dms &ra,
const dms &dec);
180 void moveBackOneDay();
181 void moveForwardOneDay();
182 bool scrollToName(
const QString &name);
184 void setStatus(
const QString &message);
188 void updateNotes(
const QString ¬es);
189 void initUserNotes();
190 void disableUserNotes();
191 void setupNotesLinks(
const QString ¬es);
193 void setDefaultImage();
195 QString currentObjectName()
const;
196 int currentObjectFlags();
198 void setCurrentObjectNotes(
const QString ¬es);
205 void loadCatalogFromFile(
QString filename =
"",
bool reset=
true);
206 bool findCatalogImageInfo(
const QString &name, CatalogImageInfo *info);
207 void addCatalogImageInfo(
const CatalogImageInfo &info);
209 void objectDetails();
210 void updateDisplays();
216 void saveToDB(
const QString &name,
bool picked,
bool imaged,
bool ignored,
const QString ¬es);
217 void saveToDB(
const QString &name,
int flags,
const QString ¬es);
220 void highlightImagedObject(
const QModelIndex &index,
bool imaged);
221 void highlightPickedObject(
const QModelIndex &index,
bool picked);
224 void adjustWindowSize();
229 ImagingPlannerUI *ui {
nullptr };
231 bool m_initialShow {
false };
232 bool m_InitialLoad =
true;
246 double m_MinMoon = 30.0;
247 double m_MinAltitude = 30.0;
248 double m_MinHours = 0;
249 bool m_UseArtificialHorizon =
true;
252 int m_numWithImage = 0;
253 int m_numMissingImage = 0;
254 bool m_loadingCatalog =
false;
259class ImagingPlannerPopup :
public QMenu
263 ImagingPlannerPopup();
264 virtual ~ImagingPlannerPopup()
override =
default;
266 void init(ImagingPlanner *planner,
const QStringList &names,
267 const bool *imaged,
const bool *picked,
const bool *ignored);
A simple container object to hold the minimum information for a Deep Sky Object to be drawn on the sk...
Manages the catalog database and provides an interface to provide an interface to query and modify th...
Contains all relevant information for specifying a location on Earth: City Name, State/Province name,...
A class that implements methods to find sun rise, sun set, twilight begin / end times,...
Provides necessary information about the Moon.
An angle, stored as degrees, but expressible in many ways.
QObject * parent() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:04:47 by
doxygen 1.12.0 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.