SkyMapComposite

Search for usage in LXR

SkyMapComposite Class Reference

#include <skymapcomposite.h>

Inheritance diagram for SkyMapComposite:

Signals

void progressText (const QString &message)
 

Public Member Functions

 SkyMapComposite (SkyComposite *parent=nullptr)
 
bool addNameLabel (SkyObject *o)
 
ArtificialHorizonComponent * artificialHorizon ()
 
const QList< SkyObject * > & asteroids () const
 
CatalogsComponentcatalogsComponent ()
 
const QList< SkyObject * > & comets () const
 
ConstellationArtComponentconstellationArt ()
 
ConstellationBoundaryLines * constellationBoundary ()
 
ConstellationLinesconstellationLines ()
 
const QList< SkyObject * > & constellationNames () const
 
ConstellationNamesComponentconstellationNamesComponent ()
 
QString currentCulture ()
 
void draw (SkyPainter *skyp) override
 
KSPlanetearth ()
 
Eclipticecliptic ()
 
void emitProgressText (const QString &message) override
 
Equatorequator ()
 
EquatorialCoordinateGridequatorialCoordGrid ()
 
SkyObjectfindByName (const QString &name, bool exact=true) override
 
QList< SkyObject * > findObjectsInArea (const SkyPoint &p1, const SkyPoint &p2)
 
SkyObjectfindStarByGenetiveName (const QString name)
 
FlagComponentflags ()
 
QString getCultureName (int index)
 
QStringList getCultureNames ()
 
const QList< SkyObject * > * getSkyObjectsList (SkyObject::TYPE t)
 
TargetListComponentgetStarHopRouteList ()
 
HorizonComponenthorizon ()
 
HorizontalCoordinateGridhorizontalCoordGrid ()
 
bool isLocalCNames ()
 
QList< SkyObject * > & labelObjects ()
 
LocalMeridianComponentlocalMeridianComponent ()
 
MilkyWaymilkyWay ()
 
SkyObjectobjectNearest (SkyPoint *p, double &maxrad) override
 
KSPlanetBaseplanet (int n)
 
QList< SkyObject * > planets ()
 
void reloadAsteroids ()
 
void reloadCLines ()
 
void reloadCNames ()
 
void reloadComets ()
 
void reloadConstellationArt ()
 
void reloadDeepSky ()
 
bool removeNameLabel (SkyObject *o)
 
SatellitesComponentsatellites ()
 
void setCurrentCulture (QString culture)
 
SolarSystemCompositesolarSystemComposite ()
 
SkyObjectstarNearest (SkyPoint *p, double &maxrad)
 
const QList< SkyObject * > & stars () const
 
const QList< SkyObject * > & supernovae () const
 
SupernovaeComponentsupernovaeComponent ()
 
void update (KSNumbers *num=nullptr) override
 
void updateMoons (KSNumbers *num) override
 
void updateSolarSystemBodies (KSNumbers *num) override
 
- Public Member Functions inherited from QObject
 QObject (QObject *parent)
 
bool blockSignals (bool block)
 
const QObjectListchildren () const const
 
QMetaObject::Connection connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const const
 
void deleteLater ()
 
void destroyed (QObject *obj)
 
bool disconnect (const char *signal, const QObject *receiver, const char *method) const const
 
bool disconnect (const QObject *receiver, const char *method) const const
 
void dumpObjectInfo ()
 
void dumpObjectInfo () const const
 
void dumpObjectTree ()
 
void dumpObjectTree () const const
 
QList< QByteArraydynamicPropertyNames () const const
 
virtual bool event (QEvent *e)
 
virtual bool eventFilter (QObject *watched, QEvent *event)
 
findChild (const QString &name, Qt::FindChildOptions options) const const
 
QList< T > findChildren (const QRegExp &regExp, Qt::FindChildOptions options) const const
 
QList< T > findChildren (const QRegularExpression &re, Qt::FindChildOptions options) const const
 
QList< T > findChildren (const QString &name, Qt::FindChildOptions options) const const
 
bool inherits (const char *className) const const
 
void installEventFilter (QObject *filterObj)
 
bool isWidgetType () const const
 
bool isWindowType () const const
 
void killTimer (int id)
 
virtual const QMetaObjectmetaObject () const const
 
void moveToThread (QThread *targetThread)
 
QString objectName () const const
 
void objectNameChanged (const QString &objectName)
 
QObjectparent () const const
 
QVariant property (const char *name) const const
 
 Q_CLASSINFO (Name, Value)
 
 Q_DISABLE_COPY (Class)
 
 Q_DISABLE_COPY_MOVE (Class)
 
 Q_DISABLE_MOVE (Class)
 
 Q_EMIT Q_EMIT
 
 Q_ENUM (...)
 
 Q_ENUM_NS (...)
 
 Q_ENUMS (...)
 
 Q_FLAG (...)
 
 Q_FLAG_NS (...)
 
 Q_FLAGS (...)
 
 Q_GADGET Q_GADGET
 
 Q_INTERFACES (...)
 
 Q_INVOKABLE Q_INVOKABLE
 
 Q_NAMESPACE Q_NAMESPACE
 
 Q_NAMESPACE_EXPORT (EXPORT_MACRO)
 
 Q_OBJECT Q_OBJECT
 
 Q_PROPERTY (...)
 
 Q_REVISION Q_REVISION
 
 Q_SET_OBJECT_NAME (Object)
 
 Q_SIGNAL Q_SIGNAL
 
 Q_SIGNALS Q_SIGNALS
 
 Q_SLOT Q_SLOT
 
 Q_SLOTS Q_SLOTS
 
qFindChild (const QObject *obj, const QString &name)
 
QList< T > qFindChildren (const QObject *obj, const QRegExp &regExp)
 
QList< T > qFindChildren (const QObject *obj, const QString &name)
 
qobject_cast (const QObject *object)
 
qobject_cast (QObject *object)
 
 QT_NO_NARROWING_CONVERSIONS_IN_CONNECT QT_NO_NARROWING_CONVERSIONS_IN_CONNECT
 
void removeEventFilter (QObject *obj)
 
void setObjectName (const QString &name)
 
void setParent (QObject *parent)
 
bool setProperty (const char *name, const QVariant &value)
 
bool signalsBlocked () const const
 
int startTimer (int interval, Qt::TimerType timerType)
 
int startTimer (std::chrono::milliseconds time, Qt::TimerType timerType)
 
QThreadthread () const const
 
- Public Member Functions inherited from SkyComposite
 SkyComposite (SkyComposite *parent=nullptr)
 
 ~SkyComposite () override
 
void addComponent (SkyComponent *comp, int priority=1024)
 
QList< SkyComponent * > components ()
 
QMap< int, SkyComponent * > & componentsWithPriorities ()
 
void removeComponent (SkyComponent *const comp)
 
- Public Member Functions inherited from SkyComponent
 SkyComponent (SkyComposite *parent=nullptr)
 
virtual void drawTrails (SkyPainter *skyp)
 
QHash< int, QVector< QPair< QString, const SkyObject * > > > & objectLists ()
 
QVector< QPair< QString, const SkyObject * > > & objectLists (int type)
 
QHash< int, QStringList > & objectNames ()
 
QStringListobjectNames (int type)
 
virtual void objectsInArea (QList< SkyObject * > &list, const SkyRegion &region)
 
SkyCompositeparent ()
 
void removeFromLists (const SkyObject *obj)
 
void removeFromNames (const SkyObject *obj)
 
virtual bool selected ()
 

Additional Inherited Members

- Properties inherited from QObject
 objectName
 
- Static Public Member Functions inherited from QObject
QMetaObject::Connection connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type)
 
QMetaObject::Connection connect (const QObject *sender, PointerToMemberFunction signal, Functor functor)
 
bool disconnect (const QMetaObject::Connection &connection)
 
bool disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method)
 
bool disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method)
 
bool disconnect (const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method)
 
QString tr (const char *sourceText, const char *disambiguation, int n)
 
QString trUtf8 (const char *sourceText, const char *disambiguation, int n)
 
- Public Attributes inherited from QObject
typedef QObjectList
 
- Protected Member Functions inherited from QObject
virtual void childEvent (QChildEvent *event)
 
virtual void connectNotify (const QMetaMethod &signal)
 
virtual void customEvent (QEvent *event)
 
virtual void disconnectNotify (const QMetaMethod &signal)
 
bool isSignalConnected (const QMetaMethod &signal) const const
 
int receivers (const char *signal) const const
 
QObjectsender () const const
 
int senderSignalIndex () const const
 
virtual void timerEvent (QTimerEvent *event)
 

Detailed Description

SkyMapComposite is the root object in the object hierarchy of the sky map. All requests to update, init, draw etc. will be done with this class. The requests will be delegated to it's children. The object hierarchy will created by adding new objects via addComponent().

Author
Thomas Kabelmann
Version
0.1

Definition at line 62 of file skymapcomposite.h.

Constructor & Destructor Documentation

◆ SkyMapComposite()

SkyMapComposite::SkyMapComposite ( SkyComposite parent = nullptr)
explicit

Constructor parent pointer to the parent SkyComponent.

Definition at line 57 of file skymapcomposite.cpp.

Member Function Documentation

◆ draw()

void SkyMapComposite::draw ( SkyPainter skyp)
overridevirtual

Delegate draw requests to all sub components psky Reference to the QPainter on which to paint.

Reimplemented from SkyComposite.

Definition at line 241 of file skymapcomposite.cpp.

◆ emitProgressText()

void SkyMapComposite::emitProgressText ( const QString message)
overridevirtual

Emit signal about progress.

See also
SkyMapComposite::emitProgressText

Reimplemented from SkyComponent.

Definition at line 698 of file skymapcomposite.cpp.

◆ findByName()

SkyObject * SkyMapComposite::findByName ( const QString name,
bool  exact = true 
)
overridevirtual

Search the children of this SkyMapComposite for a SkyObject whose name matches the argument.

The objects' primary, secondary and long-form names will all be checked for a match.

Note
Overloaded from SkyComposite. In this version, we search the most likely object classes first to be more efficient. name the name to be matched exact If true, it will return an exact match (default), otherwise it can return a partial match.
Returns
a pointer to the SkyObject whose name matches the argument, or a nullptr pointer if no match was found.

Reimplemented from SkyComposite.

Definition at line 553 of file skymapcomposite.cpp.

◆ findObjectsInArea()

QList< SkyObject * > SkyMapComposite::findObjectsInArea ( const SkyPoint p1,
const SkyPoint p2 
)
Returns
the list of objects in the region defined by skypoints
Parameters
p1first sky point (top-left vertex of rectangular region)
p2second sky point (bottom-right vertex of rectangular region)

Definition at line 539 of file skymapcomposite.cpp.

◆ horizon()

HorizonComponent* SkyMapComposite::horizon ( )
inline

Getters for SkyComponents.

Definition at line 172 of file skymapcomposite.h.

◆ objectNearest()

SkyObject * SkyMapComposite::objectNearest ( SkyPoint p,
double &  maxrad 
)
overridevirtual
Returns
the object nearest a given point in the sky.
Parameters
pThe point to find an object near
maxradThe maximum search radius, in Degrees
Note
the angular separation to the matched object is returned through the maxrad variable.

Reimplemented from SkyComposite.

Definition at line 407 of file skymapcomposite.cpp.

◆ starNearest()

SkyObject * SkyMapComposite::starNearest ( SkyPoint p,
double &  maxrad 
)
Returns
the star nearest a given point in the sky.
Parameters
pThe point to find a star near
maxradThe maximum search radius, in Degrees
Note
the angular separation to the matched star is returned through the maxrad variable.

Definition at line 492 of file skymapcomposite.cpp.

◆ update()

void SkyMapComposite::update ( KSNumbers num = nullptr)
overridevirtual

Delegate update-position requests to all sub components.

This function usually just updates the Horizontal (Azimuth/Altitude) coordinates. However, the precession and nutation must also be recomputed periodically. Requests to do so are sent through the doPrecess parameter. num Pointer to the KSNumbers object

See also
updatePlanets()
updateMoons()
Note
By default, the num parameter is nullptr, indicating that Precession/Nutation computation should be skipped; this computation is only occasionally required.

Reimplemented from SkyComposite.

Definition at line 183 of file skymapcomposite.cpp.

◆ updateMoons()

void SkyMapComposite::updateMoons ( KSNumbers num)
overridevirtual

Delegate moon position updates to the SolarSystemComposite.

Planet positions change over time, so they need to be recomputed periodically, but not on every call to update(). This function will recompute the positions of the Earth's Moon and Jupiter's four Galilean moons. These objects are done separately from the other solar system bodies, because their positions change more rapidly, and so updateMoons() must be called more often than updatePlanets(). num Pointer to the KSNumbers object

See also
update()
updatePlanets()
SolarSystemComposite::updateMoons()

Reimplemented from SkyComponent.

Definition at line 230 of file skymapcomposite.cpp.

◆ updateSolarSystemBodies()

void SkyMapComposite::updateSolarSystemBodies ( KSNumbers num)
overridevirtual

Delegate planet position updates to the SolarSystemComposite.

Planet positions change over time, so they need to be recomputed periodically, but not on every call to update(). This function will recompute the positions of all solar system bodies except the Earth's Moon, Jupiter's Moons AND Saturn Moons (because these objects' positions change on a much more rapid timescale). num Pointer to the KSNumbers object

See also
update()
updateMoons()
SolarSystemComposite::updatePlanets()

Reimplemented from SkyComponent.

Definition at line 225 of file skymapcomposite.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Mon Sep 26 2022 04:14:11 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.