ConstellationMgr.hpp   ConstellationMgr.hpp 
skipping to change at line 47 skipping to change at line 47
class StelPainter; class StelPainter;
//! @class ConstellationMgr //! @class ConstellationMgr
//! Display and manage the constellations. //! Display and manage the constellations.
//! It can display constellations lines, names, art textures and boundaries . //! It can display constellations lines, names, art textures and boundaries .
//! It also supports several different sky cultures. //! It also supports several different sky cultures.
class ConstellationMgr : public StelObjectModule class ConstellationMgr : public StelObjectModule
{ {
Q_OBJECT Q_OBJECT
Q_PROPERTY(bool artDisplayed Q_PROPERTY(bool artDisplayed
READ getFlagArt READ getFlagArt
WRITE setFlagArt WRITE setFlagArt
NOTIFY artDisplayedChanged) NOTIFY artDisplayedChanged)
Q_PROPERTY(float artFadeDuration Q_PROPERTY(float artFadeDuration
READ getArtFadeDuration READ getArtFadeDuration
WRITE setArtFadeDuration WRITE setArtFadeDuration
NOTIFY artFadeDurationChanged) NOTIFY artFadeDurationChanged)
Q_PROPERTY(float artIntensity Q_PROPERTY(float artIntensity
READ getArtIntensity READ getArtIntensity
WRITE setArtIntensity WRITE setArtIntensity
NOTIFY artIntensityChanged) NOTIFY artIntensityChanged)
Q_PROPERTY(Vec3f boundariesColor Q_PROPERTY(Vec3f boundariesColor
READ getBoundariesColor READ getBoundariesColor
WRITE setBoundariesColor WRITE setBoundariesColor
NOTIFY boundariesColorChanged) NOTIFY boundariesColorChanged)
Q_PROPERTY(bool boundariesDisplayed Q_PROPERTY(bool boundariesDisplayed
READ getFlagBoundaries READ getFlagBoundaries
WRITE setFlagBoundaries WRITE setFlagBoundaries
NOTIFY boundariesDisplayedChanged) NOTIFY boundariesDisplayedChanged)
Q_PROPERTY(float fontSize Q_PROPERTY(float fontSize
READ getFontSize READ getFontSize
WRITE setFontSize WRITE setFontSize
NOTIFY fontSizeChanged) NOTIFY fontSizeChanged)
Q_PROPERTY(bool isolateSelected Q_PROPERTY(bool isolateSelected
READ getFlagIsolateSelected READ getFlagIsolateSelected
WRITE setFlagIsolateSelected WRITE setFlagIsolateSelected
NOTIFY isolateSelectedChanged) NOTIFY isolateSelectedChanged)
Q_PROPERTY(Vec3f linesColor Q_PROPERTY(Vec3f linesColor
READ getLinesColor READ getLinesColor
WRITE setLinesColor WRITE setLinesColor
NOTIFY linesColorChanged) NOTIFY linesColorChanged)
Q_PROPERTY(bool linesDisplayed Q_PROPERTY(bool linesDisplayed
READ getFlagLines READ getFlagLines
WRITE setFlagLines WRITE setFlagLines
NOTIFY linesDisplayedChanged) NOTIFY linesDisplayedChanged)
Q_PROPERTY(Vec3f namesColor Q_PROPERTY(Vec3f namesColor
READ getLabelsColor READ getLabelsColor
WRITE setLabelsColor WRITE setLabelsColor
NOTIFY namesColorChanged) NOTIFY namesColorChanged)
Q_PROPERTY(bool namesDisplayed Q_PROPERTY(bool namesDisplayed
READ getFlagLabels READ getFlagLabels
WRITE setFlagLabels WRITE setFlagLabels
NOTIFY namesDisplayedChanged) NOTIFY namesDisplayedChanged)
Q_PROPERTY(ConstellationDisplayStyle constellationDisplayStyle Q_PROPERTY(ConstellationDisplayStyle constellationDisplayStyle
READ getConstellationDisplayStyle READ getConstellationDisplayStyle
WRITE setConstellationDisplayStyle WRITE setConstellationDisplayStyle
NOTIFY constellationsDisplayStyleChanged) NOTIFY constellationsDisplayStyleChanged)
Q_PROPERTY(float constellationLineThickness Q_PROPERTY(float constellationLineThickness
READ getConstellationLineThickness READ getConstellationLineThickness
WRITE setConstellationLineThickness WRITE setConstellationLineThickness
NOTIFY constellationLineThicknessChanged) NOTIFY constellationLineThicknessChanged)
//Register enum with Qt //Register enum with Qt
Q_ENUMS(ConstellationDisplayStyle) Q_ENUMS(ConstellationDisplayStyle)
public: public:
//! Constructor //! Constructor
skipping to change at line 302 skipping to change at line 302
//! Loads new constellation data and art if the SkyCulture has chang ed. //! Loads new constellation data and art if the SkyCulture has chang ed.
//! @param skyCultureDir the name of the directory containing the sk y culture to use. //! @param skyCultureDir the name of the directory containing the sk y culture to use.
void updateSkyCulture(const QString& skyCultureDir); void updateSkyCulture(const QString& skyCultureDir);
//! Update i18n names from English names according to current //! Update i18n names from English names according to current
//! locale, and update font for locale. //! locale, and update font for locale.
//! The translation is done using gettext with translated strings de fined //! The translation is done using gettext with translated strings de fined
//! in translations.h //! in translations.h
void updateI18n(); void updateI18n();
//! Remove constellations from selected objects
void deselectConstellations(void);
private: private:
//! Read constellation names from the given file. //! Read constellation names from the given file.
//! @param namesFile Name of the file containing the constellation n ames //! @param namesFile Name of the file containing the constellation n ames
//! in a format consisting of abbreviation, native name and t ranslatable english name. //! in a format consisting of abbreviation, native name and t ranslatable english name.
//! @note The abbreviation must occur in the lines file loaded first in @name loadLinesAndArt()! //! @note The abbreviation must occur in the lines file loaded first in @name loadLinesAndArt()!
void loadNames(const QString& namesFile); void loadNames(const QString& namesFile);
//! Load constellation line shapes, art textures and boundaries shap es from data files. //! Load constellation line shapes, art textures and boundaries shap es from data files.
//! @param fileName The name of the constellation data file //! @param fileName The name of the constellation data file
//! @param artFileName The name of the constellation art data file //! @param artFileName The name of the constellation art data file
skipping to change at line 352 skipping to change at line 355
void drawBoundaries(StelPainter& sPainter) const; void drawBoundaries(StelPainter& sPainter) const;
//! Handle single and multi-constellation selections. //! Handle single and multi-constellation selections.
void setSelectedConst(Constellation* c); void setSelectedConst(Constellation* c);
//! Handle unselecting a single constellation. //! Handle unselecting a single constellation.
void unsetSelectedConst(Constellation* c); void unsetSelectedConst(Constellation* c);
//! Define which constellation is selected from its abbreviation. //! Define which constellation is selected from its abbreviation.
void setSelected(const QString& abbreviation); void setSelected(const QString& abbreviation);
//! Define which constellation is selected and return brightest star . //! Define which constellation is selected and return brightest star .
StelObjectP setSelectedStar(const QString& abbreviation); StelObjectP setSelectedStar(const QString& abbreviation);
//! Define which constellation is selected from a star number. //! Define which constellation is selected from a star number.
void setSelected(const StelObject* s) {if (!s) setSelectedConst(NULL ); else setSelectedConst(isStarIn(s));} void setSelected(const StelObject* s);
//! Remove all selected constellations. //! Remove all selected constellations.
void deselect() {setSelected(NULL);} void deselect() { setSelected(NULL); }
//! Get the first selected constellation. //! Get the first selected constellation.
//! NOTE: this function should return a list of all, or may be delet ed. Please //! NOTE: this function should return a list of all, or may be delet ed. Please
//! do not use until it exhibits the proper behaviour. //! do not use until it exhibits the proper behaviour.
StelObject* getSelected(void) const; StelObject* getSelected(void) const;
//! Remove constellations from selected objects
void deselectConstellations(void);
std::vector<Constellation*> selected; // More than one can be select ed at a time std::vector<Constellation*> selected; // More than one can be select ed at a time
Constellation* isStarIn(const StelObject *s) const; Constellation* isStarIn(const StelObject *s) const;
Constellation* isObjectIn(const StelObject *s) const;
Constellation* findFromAbbreviation(const QString& abbreviation) con st; Constellation* findFromAbbreviation(const QString& abbreviation) con st;
std::vector<Constellation*> asterisms; std::vector<Constellation*> asterisms;
QFont asterFont; QFont asterFont;
StarMgr* hipStarMgr; StarMgr* hipStarMgr;
bool isolateSelected; // true to pick individual constellations. bool isolateSelected; // true to pick individual constellations.
bool constellationPickEnabled; bool constellationPickEnabled;
std::vector<std::vector<Vec3f> *> allBoundarySegments; std::vector<std::vector<Vec3f> *> allBoundarySegments;
QString lastLoadedSkyCulture; // Store the last loaded sky culture directory name QString lastLoadedSkyCulture; // Store the last loaded sky culture directory name
 End of changes. 17 change blocks. 
40 lines changed or deleted 42 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/