Kstars

stellarsolverprofileeditor.h
1/*
2 SPDX-FileCopyrightText: 2017 Jasem Mutlaq <mutlaqja@ikarustech.com>
3 SPDX-FileCopyrightText: 2017 Robert Lancaster <rlancaste@gmail.com>
4
5 SPDX-License-Identifier: GPL-2.0-or-later
6*/
7
8#pragma once
9
10#include "ui_stellarsolverprofileeditor.h"
11#include "parameters.h"
12#include "stellarsolverprofile.h"
13
14
15#include <QWidget>
16#include <QDir>
17
18class KConfigDialog;
19
20namespace Ekos
21{
22class Align;
23
24class StellarSolverProfileEditor : public QWidget, public Ui::StellarSolverProfileEditor
25{
27
28 public:
29 void setProfileGroup(ProfileGroup group, bool warn = true);
30
31 explicit StellarSolverProfileEditor(QWidget *parent, ProfileGroup group, KConfigDialog *dialog);
32 virtual ~StellarSolverProfileEditor() override = default;
33
34 //These functions handle the settings for the Sextractors and Solvers
35 SSolver::Parameters getSettingsFromUI();
36 void sendSettingsToUI(SSolver::Parameters a);
37
38 //These functions save and load the settings of the program.
39 void openSingleProfile();
40 void saveSingleProfile();
41 void copySingleProfile();
42 void loadProfiles(bool warn = true);
43 void saveProfiles();
44 void loadOptionsProfile();
45 void loadOptionsProfileIgnoreOldSettings(int index);
46 void saveBackupProfiles();
47 void openBackupProfiles();
48 QList<SSolver::Parameters> getDefaultProfiles();
49 void loadDefaultProfiles();
50
51 void connectOptionsProfileComboBox();
52 void disconnectOptionsProfileComboBox();
53 public slots:
54 void loadProfile(const QString &profile);
55 void showEvent(QShowEvent *e) override;
56
57 signals:
58 void optionsProfilesUpdated();
59 protected:
60
61 private slots:
62
63 void slotApply();
64
65
66 private:
67 QString savedOptionsProfiles;
68 int openOptionsProfileNum = 0;
69 void settingJustChanged();
70 QString dirPath = QDir::homePath();
72 bool optionsAreSaved = true;
73 KConfigDialog *m_ConfigDialog { nullptr };
74
75 ProfileGroup selectedProfileGroup = AlignProfiles;
76};
77}
Ekos is an advanced Astrophotography tool for Linux.
Definition align.cpp:83
QString homePath()
Q_OBJECTQ_OBJECT
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:40 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.