StelObject.hpp   StelObject.hpp 
skipping to change at line 38 skipping to change at line 38
#include <QString> #include <QString>
class StelCore; class StelCore;
//! The base abstract class for sky objects used in Stellarium like Stars, Planets, Constellations etc... //! The base abstract class for sky objects used in Stellarium like Stars, Planets, Constellations etc...
//! Normally you should use StelObjectP instead of StelObject* which have b y default the same behaviour, //! Normally you should use StelObjectP instead of StelObject* which have b y default the same behaviour,
//! but which can be added reference counting if needed. //! but which can be added reference counting if needed.
//! @sa StelObjectP //! @sa StelObjectP
class StelObject : public StelRegionObject class StelObject : public StelRegionObject
{ {
//Required for Q_FLAGS macro, this requires this header to be MOC'ed
Q_GADGET
Q_FLAGS(InfoStringGroupFlags InfoStringGroup)
public: public:
//! @enum InfoStringGroup used as named bitfield flags as specifiers to //! Used as named bitfield flags as specifiers to
//! filter results of getInfoString. The precise definition of these should //! filter results of getInfoString. The precise definition of these should
//! be documented in the getInfoString documentation for the derived classes //! be documented in the getInfoString documentation for the derived classes
//! for all specifiers which are defined in that derivative. //! for all specifiers which are defined in that derivative.
//! Use InfoStringGroup instead. //! Use InfoStringGroup instead.
enum InfoStringGroupFlags enum InfoStringGroupFlags
{ {
Name = 0x00000001, //!< An object's name Name = 0x00000001, //!< An object's name
CatalogNumber = 0x00000002, //!< Catalog numbers CatalogNumber = 0x00000002, //!< Catalog numbers
Magnitude = 0x00000004, //!< Magnitude related data Magnitude = 0x00000004, //!< Magnitude related data
RaDecJ2000 = 0x00000008, //!< The equatorial po sition (J2000 ref) RaDecJ2000 = 0x00000008, //!< The equatorial po sition (J2000 ref)
skipping to change at line 61 skipping to change at line 64
AltAzi = 0x00000020, //!< The position (Alt itude/Azimuth) AltAzi = 0x00000020, //!< The position (Alt itude/Azimuth)
Distance = 0x00000040, //!< Info about an obj ect's distance Distance = 0x00000040, //!< Info about an obj ect's distance
Size = 0x00000080, //!< Info about an obj ect's size Size = 0x00000080, //!< Info about an obj ect's size
Extra = 0x00000100, //!< Derived class-spe cific extra fields Extra = 0x00000100, //!< Derived class-spe cific extra fields
HourAngle = 0x00000200, //!< The hour angle + DE (of date) HourAngle = 0x00000200, //!< The hour angle + DE (of date)
AbsoluteMagnitude = 0x00000400, //!< The absolute magn itude AbsoluteMagnitude = 0x00000400, //!< The absolute magn itude
GalacticCoord = 0x00000800, //!< The galactic posi tion GalacticCoord = 0x00000800, //!< The galactic posi tion
ObjectType = 0x00001000, //!< The type of the o bject (star, planet, etc.) ObjectType = 0x00001000, //!< The type of the o bject (star, planet, etc.)
EclipticCoord = 0x00002000, //!< The ecliptic posi tion EclipticCoord = 0x00002000, //!< The ecliptic posi tion
EclipticCoordXYZ = 0x00004000, //!< The ecliptic posi tion, XYZ of VSOP87A (used mainly for debugging, not public) EclipticCoordXYZ = 0x00004000, //!< The ecliptic posi tion, XYZ of VSOP87A (used mainly for debugging, not public)
NoFont = 0x00008000,
PlainText = 0x00010000, //!< Strip HTML tags from output PlainText = 0x00010000, //!< Strip HTML tags from output
// TODO GZ // TODO GZ
// RaDecJ2000Planetocentric = 0x00020000, //!< The planetocent ric equatorial position (J2000 ref) [Mostly to compare with almanacs] // RaDecJ2000Planetocentric = 0x00020000, //!< The planetocent ric equatorial position (J2000 ref) [Mostly to compare with almanacs]
// RaDecOfDatePlanetocentric = 0x00040000 //!< The planetocent ric equatorial position (of date) // RaDecOfDatePlanetocentric = 0x00040000 //!< The planetocent ric equatorial position (of date)
// // and split Ecliptical into // // and split Ecliptical into
// EclipticCoordJ2000 = 0x00002000, //!< The ecliptic posi tion w.r.t. ecliptic of eq.J2000.0 // EclipticCoordJ2000 = 0x00002000, //!< The ecliptic posi tion w.r.t. ecliptic of eq.J2000.0
// EclipticCoordOfDate = 0x00002000, //!< The ecliptic posi tion w.r.t. ecliptic of eq. of date // EclipticCoordOfDate = 0x00002000, //!< The ecliptic posi tion w.r.t. ecliptic of eq. of date
}; };
typedef QFlags<InfoStringGroupFlags> InfoStringGroup; Q_DECLARE_FLAGS(InfoStringGroup, InfoStringGroupFlags)
Q_FLAGS(InfoStringGroup)
//! A pre-defined set of specifiers for the getInfoString flags argu ment to getInfoString //! A pre-defined set of specifiers for the getInfoString flags argu ment to getInfoString
static const InfoStringGroupFlags AllInfo = (InfoStringGroupFlags)(N ame|CatalogNumber|Magnitude|RaDecJ2000|RaDecOfDate|AltAzi|Distance|Size|Ext ra|HourAngle| static const InfoStringGroupFlags AllInfo = (InfoStringGroupFlags)(N ame|CatalogNumber|Magnitude|RaDecJ2000|RaDecOfDate|AltAzi|Distance|Size|Ext ra|HourAngle|
A bsoluteMagnitude|GalacticCoord|ObjectType|EclipticCoord|EclipticCoordXYZ); A bsoluteMagnitude|GalacticCoord|ObjectType|EclipticCoord|EclipticCoordXYZ);
//! A pre-defined set of specifiers for the getInfoString flags argu ment to getInfoString //! A pre-defined set of specifiers for the getInfoString flags argu ment to getInfoString
static const InfoStringGroupFlags ShortInfo = (InfoStringGroupFlags) (Name|CatalogNumber|Magnitude|RaDecJ2000); static const InfoStringGroupFlags ShortInfo = (InfoStringGroupFlags) (Name|CatalogNumber|Magnitude|RaDecJ2000);
virtual ~StelObject() {} virtual ~StelObject() {}
//! Default implementation of the getRegion method. //! Default implementation of the getRegion method.
skipping to change at line 175 skipping to change at line 178
//! @return radius in degree. This value is the apparent angular siz e of the object, and is independent of the current FOV. //! @return radius in degree. This value is the apparent angular siz e of the object, and is independent of the current FOV.
virtual double getAngularSize(const StelCore* core) const = 0; virtual double getAngularSize(const StelCore* core) const = 0;
protected: protected:
//! Format the positional info string contain J2000/of date/altaz/ho ur angle positions for the object //! Format the positional info string contain J2000/of date/altaz/ho ur angle positions for the object
QString getPositionInfoString(const StelCore *core, const InfoString Group& flags) const; QString getPositionInfoString(const StelCore *core, const InfoString Group& flags) const;
//! Apply post processing on the info string //! Apply post processing on the info string
void postProcessInfoString(QString& str, const InfoStringGroup& flag s) const; void postProcessInfoString(QString& str, const InfoStringGroup& flag s) const;
private:
static int stelObjectPMetaTypeID;
}; };
Q_DECLARE_OPERATORS_FOR_FLAGS(StelObject::InfoStringGroup) Q_DECLARE_OPERATORS_FOR_FLAGS(StelObject::InfoStringGroup)
#endif // _STELOBJECT_HPP_ #endif // _STELOBJECT_HPP_
 End of changes. 5 change blocks. 
3 lines changed or deleted 8 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/