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

kstars

Public Slots | Signals | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
KStarsData Class Reference

#include <kstarsdata.h>

Inheritance diagram for KStarsData:
Inheritance graph
[legend]

Public Slots

void setTimeDirection (float scale)
 
void slotConsoleMessage (QString s)
 
void updateTime (GeoLocation *geo, SkyMap *skymap, const bool automaticDSTchange=true)
 

Signals

void clearCache ()
 
void geoChanged ()
 
void progressText (const QString &)
 
void update ()
 

Public Member Functions

virtual ~KStarsData ()
 
CatalogDB * catalogdb ()
 
void changeDateTime (const KStarsDateTime &newDate)
 
SimClock * clock ()
 
ColorScheme * colorScheme ()
 
bool executeScript (const QString &name, SkyMap *map)
 
GeoLocation * geo ()
 
const QList< FOV * > getAvailableFOVs () const
 
QList< GeoLocation * > getGeoList ()
 
KLocale * getLocale ()
 
const QMap< QString,
TimeZoneRule > & 
getRulebook ()
 
const QList< FOV * > getVisibleFOVs () const
 
unsigned int incUpdateID ()
 
bool initialize ()
 
bool isTimeRunningForward ()
 
GeoLocation * locationNamed (const QString &city, const QString &province=QString(), const QString &country=QString())
 
OAL::Log * logObject ()
 
dms * lst ()
 
const KStarsDateTime & lt () const
 
SkyObject * objectNamed (const QString &name)
 
void setFullTimeUpdate ()
 
void setLocation (const GeoLocation &l)
 
void setLocationFromOptions ()
 
void setNextDSTChange (const KStarsDateTime &dt)
 
void setSnapNextFocus (bool b=true)
 
SkyMapComposite * skyComposite ()
 
bool snapNextFocus () const
 
void syncFOV ()
 
void syncLST ()
 
void syncUpdateIDs ()
 
unsigned int updateID ()
 
KSNumbers * updateNum ()
 
unsigned int updateNumID ()
 
KSUserDB * userdb ()
 
const KStarsDateTime & ut () const
 

Static Public Member Functions

static KStarsData * Create ()
 
static KStarsData * Instance ()
 

Protected Member Functions

 KStarsData ()
 

Detailed Description

KStarsData is the backbone of KStars.

It contains all the data used by KStars, including the SkyMapComposite that contains all items in the skymap (stars, deep-sky objects, planets, constellations, etc). Other kinds of data are stored here as well: the geographic locations, the timezone rules, etc.

Author
Heiko Evermann
Version
1.0

Definition at line 66 of file kstarsdata.h.

Constructor & Destructor Documentation

KStarsData::KStarsData ( )
protected

Constructor.

Definition at line 109 of file kstarsdata.cpp.

KStarsData::~KStarsData ( )
virtual

Destructor.

Delete data objects.

Definition at line 126 of file kstarsdata.cpp.

Member Function Documentation

CatalogDB* KStarsData::catalogdb ( )
inline
Returns
pointer to the Catalog DB object

Definition at line 155 of file kstarsdata.h.

void KStarsData::changeDateTime ( const KStarsDateTime &  newDate)

change the current simulation date/time to the KStarsDateTime argument.

Specified DateTime is always universal time.

Parameters
newDatethe DateTime to set.

Definition at line 272 of file kstarsdata.cpp.

void KStarsData::clearCache ( )
signal

If data changed, emit clearCache signal.

SimClock* KStarsData::clock ( )
inline
Returns
pointer to the simulation Clock object

Definition at line 158 of file kstarsdata.h.

ColorScheme* KStarsData::colorScheme ( )
inline
Returns
pointer to the ColorScheme object

Definition at line 149 of file kstarsdata.h.

KStarsData * KStarsData::Create ( )
static

Definition at line 93 of file kstarsdata.cpp.

bool KStarsData::executeScript ( const QString &  name,
SkyMap *  map 
)

Execute a script.

This function actually duplicates the DCOP functionality for those cases when invoking DCOP is not practical (i.e., when preparing a sky image in command-line dump mode).

Parameters
namethe filename of the script to "execute".
mappointer to the SkyMap object.
Returns
true if the script was successfully parsed.

Definition at line 746 of file kstarsdata.cpp.

GeoLocation* KStarsData::geo ( )
inline
Returns
pointer to the GeoLocation object

Definition at line 164 of file kstarsdata.h.

void KStarsData::geoChanged ( )
signal

Emitted when geo location changed.

const QList<FOV*> KStarsData::getAvailableFOVs ( ) const
inline
Returns
the list of available FOVs

Definition at line 216 of file kstarsdata.h.

QList<GeoLocation*> KStarsData::getGeoList ( )
inline
Returns
list of all geographic locations

Definition at line 167 of file kstarsdata.h.

KLocale* KStarsData::getLocale ( )
inline
Returns
pointer to the localization (KLocale) object

Definition at line 114 of file kstarsdata.h.

const QMap<QString, TimeZoneRule>& KStarsData::getRulebook ( )
inline

Return map for daylight saving rules.

Definition at line 180 of file kstarsdata.h.

const QList<FOV*> KStarsData::getVisibleFOVs ( ) const
inline
Returns
the list of visible FOVs

Definition at line 211 of file kstarsdata.h.

unsigned int KStarsData::incUpdateID ( )

Definition at line 253 of file kstarsdata.cpp.

bool KStarsData::initialize ( )

Initialize KStarsData while running splash screen.

Returns
true on success.

Definition at line 138 of file kstarsdata.cpp.

static KStarsData* KStarsData::Instance ( )
inlinestatic

Definition at line 92 of file kstarsdata.h.

bool KStarsData::isTimeRunningForward ( )
inline

Returns true if time is running forward else false.

Used by KStars to prevent double calculations of daylight saving change time.

Definition at line 111 of file kstarsdata.h.

GeoLocation * KStarsData::locationNamed ( const QString &  city,
const QString &  province = QString(),
const QString &  country = QString() 
)

Definition at line 306 of file kstarsdata.cpp.

OAL::Log* KStarsData::logObject ( )
inline

Return log object.

Definition at line 219 of file kstarsdata.h.

dms* KStarsData::lst ( )
inline
Returns
pointer to the local sidereal time: a dms object

Definition at line 161 of file kstarsdata.h.

const KStarsDateTime& KStarsData::lt ( ) const
inline
Returns
pointer to the current simulation local time

Definition at line 137 of file kstarsdata.h.

SkyObject * KStarsData::objectNamed ( const QString &  name)

Find object by name.

Parameters
nameObject name to find
Returns
pointer to SkyObject matching this name

Definition at line 345 of file kstarsdata.cpp.

void KStarsData::progressText ( const QString &  )
signal

Signal that specifies the text that should be drawn in the KStarsSplash window.

void KStarsData::setFullTimeUpdate ( )

The Sky is updated more frequently than the moon, which is updated more frequently than the planets.

The date of the last update for each category is recorded so we know when we need to do it again (see KStars::updateTime()). Initializing these to -1000000.0 ensures they will be updated immediately on the first call to KStars::updateTime().

Definition at line 260 of file kstarsdata.cpp.

void KStarsData::setLocation ( const GeoLocation &  l)

Set the GeoLocation according to the argument.

Parameters
lreference to the new GeoLocation

Definition at line 323 of file kstarsdata.cpp.

void KStarsData::setLocationFromOptions ( )

Set the GeoLocation according to the values stored in the configuration file.

Definition at line 317 of file kstarsdata.cpp.

void KStarsData::setNextDSTChange ( const KStarsDateTime &  dt)
inline

Set the NextDSTChange member.

Need this accessor because I could not make KStars::privatedata a friend class for some reason...:/

Definition at line 106 of file kstarsdata.h.

void KStarsData::setSnapNextFocus ( bool  b = true)
inline

Disable or re-enable the slewing animation for the next Focus change.

Note
If the user has turned off all animated slewing, setSnapNextFocus(false) will NOT enable animation on the next slew. A false argument would only be used if you have previously called setSnapNextFocus(true), but then decided you didn't want that after all. In other words, it's extremely unlikely you'd ever want to use setSnapNextFocus(false).
Parameters
bwhen true (the default), the next Focus change will omit the slewing animation.

Definition at line 194 of file kstarsdata.h.

void KStarsData::setTimeDirection ( float  scale)
slot

Sets the direction of time and stores it in bool TimeRunForwards.

If scale >= 0 time is running forward else time runs backward. We need this to calculate just one daylight saving change time (previous or next DST change).

Definition at line 302 of file kstarsdata.cpp.

SkyMapComposite* KStarsData::skyComposite ( )
inline
Returns
pointer to SkyComposite

Definition at line 146 of file kstarsdata.h.

void KStarsData::slotConsoleMessage ( QString  s)
inlineslot

send a message to the console

Definition at line 244 of file kstarsdata.h.

bool KStarsData::snapNextFocus ( ) const
inline
Returns
whether the next Focus change will omit the slewing animation.

Definition at line 183 of file kstarsdata.h.

void KStarsData::syncFOV ( )

Synchronize list of visible FOVs and list of selected FOVs in Options.

Definition at line 1045 of file kstarsdata.cpp.

void KStarsData::syncLST ( )

Sync the LST with the simulation clock.

Definition at line 268 of file kstarsdata.cpp.

void KStarsData::syncUpdateIDs ( )

Definition at line 245 of file kstarsdata.cpp.

void KStarsData::update ( )
signal

Should be used to refresh skymap.

unsigned int KStarsData::updateID ( )
inline

Definition at line 224 of file kstarsdata.h.

KSNumbers* KStarsData::updateNum ( )
inline

Definition at line 226 of file kstarsdata.h.

unsigned int KStarsData::updateNumID ( )
inline

Definition at line 225 of file kstarsdata.h.

void KStarsData::updateTime ( GeoLocation *  geo,
SkyMap *  skymap,
const bool  automaticDSTchange = true 
)
slot

Update the Simulation Clock.

Update positions of Planets. Update Alt/Az coordinates of objects. Update precession. Update Focus position. Draw new Skymap.

This is ugly. It will change! (JH:)hey, it's much less ugly now...can we lose the comment yet? :p

Definition at line 189 of file kstarsdata.cpp.

KSUserDB* KStarsData::userdb ( )
inline
Returns
pointer to the KSUserDB object

Definition at line 152 of file kstarsdata.h.

const KStarsDateTime& KStarsData::ut ( ) const
inline
Returns
reference to the current simulation universal time

Definition at line 140 of file kstarsdata.h.


The documentation for this class was generated from the following files:
  • kstarsdata.h
  • kstarsdata.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:36:22 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

kstars

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

kdeedu API Reference

Skip menu "kdeedu API Reference"
  • Analitza
  •     lib
  • kalgebra
  • kalzium
  •   libscience
  • kanagram
  • kig
  •   lib
  • klettres
  • kstars
  • libkdeedu
  •   keduvocdocument
  • marble
  • parley
  • rocs
  •   App
  •   RocsCore
  •   VisualEditor
  •   stepcore

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal