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);
139 void userNotesEditFinished();
140 void keywordEditFinished();
141 void loadImagedFile();
143 void loadCatalogViaMenu();
145 void openOptionsMenu();
151 void catalogLoaded();
152 void loadCatalog(
const QString &path);
156 void setupHideButtons(
bool(*option)(),
void(*setOption)(
bool),
159 void setupFilterButton(
QCheckBox *checkbox,
bool(*option)(),
void(*setOption)(
bool));
160 void setupFilter2Buttons(
162 bool(*yesOption)(),
bool(*noOption)(),
bool(*dontCareOption)(),
163 void(*setYesOption)(
bool),
void(*setNoOption)(
bool),
void(*setDontCareOption)(
bool));
165 void updateSortConstraints();
168 QDate getDate()
const;
170 void loadInitialCatalog();
171 QString defaultDirectory()
const;
172 QString findDefaultCatalog()
const;
174 bool addCatalogItem(
const KSAlmanac &ksal,
const QString &name,
int flags = 0);
175 QUrl getAstrobinUrl(
const QString &target,
bool requireAwards,
bool requireSomeFilters,
double minRadius,
double maxRadius);
176 void popupAstrobin(
const QString &target);
177 void plotAltitudeGraph(
const QDate &date,
const dms &ra,
const dms &dec);
179 void moveBackOneDay();
180 void moveForwardOneDay();
181 bool scrollToName(
const QString &name);
183 void setStatus(
const QString &message);
187 void updateNotes(
const QString ¬es);
188 void initUserNotes();
189 void disableUserNotes();
190 void setupNotesLinks(
const QString ¬es);
192 void setDefaultImage();
194 QString currentObjectName()
const;
195 int currentObjectFlags();
197 void setCurrentObjectNotes(
const QString ¬es);
204 void loadCatalogFromFile(
QString filename =
"",
bool reset=
true);
205 bool findCatalogImageInfo(
const QString &name, CatalogImageInfo *info);
206 void addCatalogImageInfo(
const CatalogImageInfo &info);
208 void objectDetails();
209 void updateDisplays();
215 void saveToDB(
const QString &name,
bool picked,
bool imaged,
bool ignored,
const QString ¬es);
216 void saveToDB(
const QString &name,
int flags,
const QString ¬es);
219 void highlightImagedObject(
const QModelIndex &index,
bool imaged);
220 void highlightPickedObject(
const QModelIndex &index,
bool picked);
223 void adjustWindowSize();
228 ImagingPlannerUI *ui {
nullptr };
230 bool m_initialResultsLoad {
false };
231 bool m_InitialLoad =
true;
245 double m_MinMoon = 30.0;
246 double m_MinAltitude = 30.0;
247 double m_MinHours = 0;
248 bool m_UseArtificialHorizon =
true;
251 int m_numWithImage = 0;
252 int m_numMissingImage = 0;
257class ImagingPlannerPopup :
public QMenu
261 ImagingPlannerPopup();
262 virtual ~ImagingPlannerPopup()
override =
default;
264 void init(ImagingPlanner *planner,
const QStringList &names,
265 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 Mon Nov 18 2024 12:16:42 by
doxygen 1.12.0 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.