• Skip to content
  • Skip to link menu
KDE 4.5 API Reference
  • KDE API Reference
  • kdeedu
  • Sitemap
  • Contact Us
 

kstars

SkyMapComposite Class Reference

SkyMapComposite is the root object in the object hierarchy of the sky map. More...

#include <skymapcomposite.h>

Inheritance diagram for SkyMapComposite:
Inheritance graph
[legend]

List of all members.

Signals

void progressText (const QString &message)

Public Member Functions

 SkyMapComposite (SkyComposite *parent)
 ~SkyMapComposite ()
void addCustomCatalog (const QString &filename, int index)
bool addNameLabel (SkyObject *o)
const QList< SkyObject * > & asteroids () const
const QList< SkyObject * > & comets () const
const QList< SkyObject * > & constellationNames () const
QString currentCulture ()
QList< SkyComponent * > customCatalogs ()
const QList< DeepSkyObject * > & deepSkyObjects () const
virtual void draw (QPainter &psky)
KSPlanet * earth ()
virtual void emitProgressText (const QString &message)
virtual SkyObject * findByName (const QString &name)
QList< SkyObject * > findObjectsInArea (const SkyPoint &p1, const SkyPoint &p2)
SkyObject * findStarByGenetiveName (const QString name)
FlagComponent * flags ()
ConstellationBoundaryLines * getConstellationBoundary ()
QString getCultureName (int index)
QStringList getCultureNames ()
bool isLocalCNames ()
QList< SkyObject * > & labelObjects ()
virtual SkyObject * objectNearest (SkyPoint *p, double &maxrad)
KSPlanetBase * planet (int n)
void reloadAsteroids ()
void reloadCLines ()
void reloadCNames ()
void reloadComets ()
void reloadDeepSky ()
void removeCustomCatalog (const QString &name)
bool removeNameLabel (SkyObject *o)
void setCurrentCulture (QString culture)
SkyObject * starNearest (SkyPoint *p, double &maxrad)
const QList< SkyObject * > & stars () const
virtual void update (KSNumbers *num=0)
virtual void updateMoons (KSNumbers *num)
virtual void updatePlanets (KSNumbers *num)

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 61 of file skymapcomposite.h.


Constructor & Destructor Documentation

SkyMapComposite::SkyMapComposite ( SkyComposite *  parent  ) 

Constructor parent pointer to the parent SkyComponent.

Definition at line 50 of file skymapcomposite.cpp.

SkyMapComposite::~SkyMapComposite (  ) 

Definition at line 95 of file skymapcomposite.cpp.


Member Function Documentation

void SkyMapComposite::addCustomCatalog ( const QString &  filename,
int  index 
)

Definition at line 398 of file skymapcomposite.cpp.

bool SkyMapComposite::addNameLabel ( SkyObject *  o  ) 

Definition at line 327 of file skymapcomposite.cpp.

const QList< SkyObject * > & SkyMapComposite::asteroids (  )  const

Definition at line 455 of file skymapcomposite.cpp.

const QList< SkyObject * > & SkyMapComposite::comets (  )  const

Definition at line 459 of file skymapcomposite.cpp.

const QList< SkyObject * > & SkyMapComposite::constellationNames (  )  const

Definition at line 445 of file skymapcomposite.cpp.

QString SkyMapComposite::currentCulture (  ) 

Definition at line 483 of file skymapcomposite.cpp.

QList< SkyComponent * > SkyMapComposite::customCatalogs (  ) 

Definition at line 467 of file skymapcomposite.cpp.

const QList< DeepSkyObject * > & SkyMapComposite::deepSkyObjects (  )  const

Definition at line 441 of file skymapcomposite.cpp.

void SkyMapComposite::draw ( QPainter &  psky  )  [virtual]

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

Reimplemented from SkyComposite.

Definition at line 152 of file skymapcomposite.cpp.

KSPlanet * SkyMapComposite::earth (  ) 

Definition at line 463 of file skymapcomposite.cpp.

void SkyMapComposite::emitProgressText ( const QString &  message  )  [virtual]

Emit signal about progress.

See also:
SkyMapComposite::emitProgressText

Reimplemented from SkyComponent.

Definition at line 435 of file skymapcomposite.cpp.

SkyObject * SkyMapComposite::findByName ( const QString &  name  )  [virtual]

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
Returns:
a pointer to the SkyObject whose name matches the argument, or a NULL pointer if no match was found.

Reimplemented from SkyComposite.

Definition at line 358 of file skymapcomposite.cpp.

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

Definition at line 345 of file skymapcomposite.cpp.

SkyObject * SkyMapComposite::findStarByGenetiveName ( const QString  name  ) 

Definition at line 379 of file skymapcomposite.cpp.

FlagComponent * SkyMapComposite::flags (  ) 

Definition at line 487 of file skymapcomposite.cpp.

ConstellationBoundaryLines* SkyMapComposite::getConstellationBoundary (  )  [inline]

Definition at line 187 of file skymapcomposite.h.

QString SkyMapComposite::getCultureName ( int  index  ) 

Definition at line 475 of file skymapcomposite.cpp.

QStringList SkyMapComposite::getCultureNames (  ) 

Definition at line 471 of file skymapcomposite.cpp.

bool SkyMapComposite::isLocalCNames (  ) 

Definition at line 431 of file skymapcomposite.cpp.

QList<SkyObject*>& SkyMapComposite::labelObjects (  )  [inline]

Definition at line 169 of file skymapcomposite.h.

SkyObject * SkyMapComposite::objectNearest ( SkyPoint *  p,
double &  maxrad 
) [virtual]
Returns:
the object nearest a given point in the sky.
Parameters:
p The point to find an object near
maxrad The 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 258 of file skymapcomposite.cpp.

KSPlanetBase * SkyMapComposite::planet ( int  n  ) 

Definition at line 383 of file skymapcomposite.cpp.

void SkyMapComposite::progressText ( const QString &  message  )  [signal]
void SkyMapComposite::reloadAsteroids (  ) 
void SkyMapComposite::reloadCLines (  ) 

Definition at line 420 of file skymapcomposite.cpp.

void SkyMapComposite::reloadCNames (  ) 

Definition at line 425 of file skymapcomposite.cpp.

void SkyMapComposite::reloadComets (  ) 
void SkyMapComposite::reloadDeepSky (  ) 
void SkyMapComposite::removeCustomCatalog ( const QString &  name  ) 

Definition at line 407 of file skymapcomposite.cpp.

bool SkyMapComposite::removeNameLabel ( SkyObject *  o  ) 

Definition at line 333 of file skymapcomposite.cpp.

void SkyMapComposite::setCurrentCulture ( QString  culture  ) 

Definition at line 479 of file skymapcomposite.cpp.

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

Definition at line 311 of file skymapcomposite.cpp.

const QList< SkyObject * > & SkyMapComposite::stars (  )  const

Definition at line 450 of file skymapcomposite.cpp.

void SkyMapComposite::update ( KSNumbers *  num = 0  )  [virtual]

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 NULL, indicating that Precession/Nutation computation should be skipped; this computation is only occasionally required.

Reimplemented from SkyComposite.

Definition at line 103 of file skymapcomposite.cpp.

void SkyMapComposite::updateMoons ( KSNumbers *  num  )  [virtual]

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 141 of file skymapcomposite.cpp.

void SkyMapComposite::updatePlanets ( KSNumbers *  num  )  [virtual]

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 136 of file skymapcomposite.cpp.


The documentation for this class was generated from the following files:
  • skymapcomposite.h
  • skymapcomposite.cpp

kstars

Skip menu "kstars"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdeedu

Skip menu "kdeedu"
  •     lib
  • kalzium
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  •   stepcore
Generated for kdeedu by doxygen 1.5.9-20090814
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal