20 #ifndef _SEARCHDIALOG_HPP_
21 #define _SEARCHDIALOG_HPP_
27 #include "StelDialog.hpp"
28 #include "VecMath.hpp"
31 class Ui_searchDialogForm;
35 bool operator()(
const QString &s1,
const QString &s2)
const
37 return s1.length() < s2.length();
52 QString getSelected(
void);
53 void setValues(
const QStringList&);
54 bool isEmpty()
const {
return values.isEmpty();}
55 void appendValues(
const QStringList&);
60 void selectPrevious();
69 QT_FORWARD_DECLARE_CLASS(QListWidgetItem)
76 Q_ENUMS(CoordinateSystem)
95 bool eventFilter(QObject *
object, QEvent *event);
100 void setSimpleStyle();
103 void setCurrentCoordinateSystem(CoordinateSystem cs)
105 currentCoordinateSystem = cs;
108 CoordinateSystem getCurrentCoordinateSystem()
const
110 return currentCoordinateSystem;
113 QString getCurrentCoordinateSystemKey(
void)
const;
115 void setCurrentCoordinateSystemKey(QString key);
117 void setCoordinateSystem(
int csID);
118 void populateCoordinateSystemsList();
119 void populateCoordinateAxis();
122 Ui_searchDialogForm* ui;
124 virtual void createDialogContent();
127 void greekLetterClicked();
129 void onSimbadStatusChanged();
131 void onSearchTextChanged(
const QString& text);
134 void gotoObject(
const QString& nameI18n);
136 void gotoObject(QListWidgetItem* item);
138 void searchListChanged(
const QString& newText);
141 void manualPositionChanged();
144 void enableSimbadSearch(
bool enable);
147 void enableStartOfWordsAutofill(
bool enable);
150 void setHasSelectedFlag();
153 void selectSimbadServer(
int index);
156 void updateListWidget(
int index);
159 void updateListTab();
161 void showContextMenu(
const QPoint &pt);
168 QMap<QString, Vec3d> simbadResults;
170 class QSettings* conf;
172 QString substituteGreek(
const QString& keyString);
173 QString getGreekLetterByName(
const QString& potentialGreekLetterName);
174 QHash<QString, QString> greekLetters;
176 bool flagHasSelectedText;
178 bool useStartOfWords;
181 QString simbadServerUrl;
182 void populateSimbadServerList();
184 static const char* DEF_SIMBAD_URL;
187 CoordinateSystem currentCoordinateSystem;
190 #endif // _SEARCHDIALOG_HPP_
Base class for all the GUI windows in Stellarium.
Contains all the information about a current simbad lookup query.
Display a list of results matching the search string, and allow to tab through those selections...
Manage the selection and queries on one or more StelObjects.
The sky object search dialog.
Provides lookup features into the online Simbad service from CDS.