NebulaMgr.hpp   NebulaMgr.hpp 
skipping to change at line 27 skipping to change at line 27
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA. * Foundation, Inc., 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA.
*/ */
#ifndef _NEBULAMGR_HPP_ #ifndef _NEBULAMGR_HPP_
#define _NEBULAMGR_HPP_ #define _NEBULAMGR_HPP_
#include <QString> #include <QString>
#include <QStringList> #include <QStringList>
#include <QFont> #include <QFont>
#include "Nebula.hpp"
#include "StelObjectType.hpp" #include "StelObjectType.hpp"
#include "StelFader.hpp" #include "StelFader.hpp"
#include "StelSphericalIndex.hpp" #include "StelSphericalIndex.hpp"
#include "StelObjectModule.hpp" #include "StelObjectModule.hpp"
#include "StelTextureTypes.hpp"
class Nebula; class Nebula;
class StelTranslator; class StelTranslator;
class StelToneReproducer; class StelToneReproducer;
class QSettings; class QSettings;
class StelPainter;
typedef QSharedPointer<Nebula> NebulaP; typedef QSharedPointer<Nebula> NebulaP;
//! @class NebulaMgr //! @class NebulaMgr
//! Manage a collection of nebulae. This class is used //! Manage a collection of nebulae. This class is used
//! to display the NGC catalog with information, and textures for some of t hem. //! to display the NGC catalog with information, and textures for some of t hem.
class NebulaMgr : public StelObjectModule class NebulaMgr : public StelObjectModule
{ {
Q_OBJECT Q_OBJECT
skipping to change at line 64 skipping to change at line 63
//! Initialize the NebulaMgr object. //! Initialize the NebulaMgr object.
//! - Load the font into the Nebula class, which is used to draw Ne bula labels. //! - Load the font into the Nebula class, which is used to draw Ne bula labels.
//! - Load the texture used to draw nebula locations into the Nebul a class (for //! - Load the texture used to draw nebula locations into the Nebul a class (for
//! those with no individual texture). //! those with no individual texture).
//! - Load the pointer texture. //! - Load the pointer texture.
//! - Set flags values from ini parser which relate to nebula displ ay. //! - Set flags values from ini parser which relate to nebula displ ay.
//! - call updateI18n() to translate names. //! - call updateI18n() to translate names.
virtual void init(); virtual void init();
//! Draws all nebula objects. //! Draws all nebula objects.
virtual void draw(StelCore* core); virtual void draw(StelCore* core, class StelRenderer* renderer);
//! Update state which is time dependent. //! Update state which is time dependent.
virtual void update(double deltaTime) {hintsFader.update((int)(delta Time*1000)); flagShow.update((int)(deltaTime*1000));} virtual void update(double deltaTime) {hintsFader.update((int)(delta Time*1000)); flagShow.update((int)(deltaTime*1000));}
//! Determines the order in which the various modules are drawn. //! Determines the order in which the various modules are drawn.
virtual double getCallOrder(StelModuleActionName actionName) const; virtual double getCallOrder(StelModuleActionName actionName) const;
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods defined in StelObjectManager class // Methods defined in StelObjectManager class
//! Used to get a vector of objects which are near to some position. //! Used to get a vector of objects which are near to some position.
skipping to change at line 95 skipping to change at line 94
//! Return the matching nebula if exists or NULL. //! Return the matching nebula if exists or NULL.
//! @param name The case in-sensistive standard program name //! @param name The case in-sensistive standard program name
virtual StelObjectP searchByName(const QString& name) const; virtual StelObjectP searchByName(const QString& name) const;
//! Find and return the list of at most maxNbItem objects auto-compl eting the passed object I18n name. //! Find and return the list of at most maxNbItem objects auto-compl eting the passed object I18n name.
//! @param objPrefix the case insensitive first letters of the searc hed object //! @param objPrefix the case insensitive first letters of the searc hed object
//! @param maxNbItem the maximum number of returned object names //! @param maxNbItem the maximum number of returned object names
//! @return a list of matching object name by order of relevance, or an empty list if nothing match //! @return a list of matching object name by order of relevance, or an empty list if nothing match
virtual QStringList listMatchingObjectsI18n(const QString& objPrefix , int maxNbItem=5) const; virtual QStringList listMatchingObjectsI18n(const QString& objPrefix , int maxNbItem=5) const;
// empty for now
virtual QStringList listAllObjects(bool inEnglish) const { Q_UNUSED(
inEnglish) return QStringList(); }
virtual QString getName() const { return "Nebulae"; }
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Properties setters and getters // Properties setters and getters
public slots: public slots:
//! Set the color used to draw the nebula circles. //! Set the color used to draw the nebula circles.
void setCirclesColor(const Vec3f& c); void setCirclesColor(const Vec3f& c);
//! Get current value of the nebula circle color. //! Get current value of the nebula circle color.
const Vec3f& getCirclesColor(void) const; const Vec3f& getCirclesColor(void) const;
//! Set Nebulae Hints circle scale. //! Set Nebulae Hints circle scale.
skipping to change at line 169 skipping to change at line 171
//! Load a set of nebula images. //! Load a set of nebula images.
//! Each sub-directory of the INSTALLDIR/nebulae directory contains a set of //! Each sub-directory of the INSTALLDIR/nebulae directory contains a set of
//! nebula textures. The sub-directory is the setName. Each set ha s its //! nebula textures. The sub-directory is the setName. Each set ha s its
//! own nebula_textures.fab file and corresponding image files. //! own nebula_textures.fab file and corresponding image files.
//! This function loads a set of textures. //! This function loads a set of textures.
//! @param setName a string which corresponds to the directory where the set resides //! @param setName a string which corresponds to the directory where the set resides
void loadNebulaSet(const QString& setName); void loadNebulaSet(const QString& setName);
//! Draw a nice animated pointer around the object //! Draw a nice animated pointer around the object
void drawPointer(const StelCore* core, StelPainter& sPainter); void drawPointer(const StelCore* core, class StelRenderer* renderer) ;
NebulaP searchM(unsigned int M); NebulaP searchM(unsigned int M);
NebulaP searchNGC(unsigned int NGC); NebulaP searchNGC(unsigned int NGC);
NebulaP searchIC(unsigned int IC); NebulaP searchIC(unsigned int IC);
bool loadNGC(const QString& fileName); bool loadNGC(const QString& fileName);
bool loadNGCOld(const QString& catNGC); bool loadNGCOld(const QString& catNGC);
bool loadNGCNames(const QString& fileName); bool loadNGCNames(const QString& fileName);
QVector<NebulaP> nebArray; // The nebulas list QVector<NebulaP> nebArray; // The nebulas list
QHash<unsigned int, NebulaP> ngcIndex; QHash<unsigned int, NebulaP> ngcIndex;
skipping to change at line 192 skipping to change at line 194
//! The internal grid for fast positional lookup //! The internal grid for fast positional lookup
StelSphericalIndex nebGrid; StelSphericalIndex nebGrid;
//! The amount of hints (between 0 and 10) //! The amount of hints (between 0 and 10)
float hintsAmount; float hintsAmount;
//! The amount of labels (between 0 and 10) //! The amount of labels (between 0 and 10)
float labelsAmount; float labelsAmount;
//! The selection pointer texture //! The selection pointer texture
StelTextureSP texPointer; StelTextureNew* texPointer;
QFont nebulaFont; // Font used for names printing QFont nebulaFont; // Font used for names printing
//! Textures used to draw nebula hints.
Nebula::NebulaHintTextures nebulaHintTextures;
}; };
#endif // _NEBULAMGR_HPP_ #endif // _NEBULAMGR_HPP_
 End of changes. 8 change blocks. 
5 lines changed or deleted 11 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/