1 /***************************************************************************
2 astrocalc.h - description
4 begin : wed dec 19 16:20:11 CET 2002
5 copyright : (C) 2001-2002 by Pablo de Vicente
7 ***************************************************************************/
9 /***************************************************************************
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
16 ***************************************************************************/
26 #include <kdialogbase.h>
28 #include <kapplication.h>
39 class modCalcGeodCoord
;
40 class modCalcGalCoord
;
44 class modCalcDayLength
;
48 class modCalcEclCoords
;
52 /** Astrocalc is the base class for the KStars astronomical calculator
53 * @author: Pablo de Vicente
57 class AstroCalc
: public KDialogBase
63 AstroCalc(QWidget
*parent
= 0);
68 /**Generate explanatory text for time modules. */
69 void genTimeText(void);
71 /**Generate explanatory text for coordinate modules. */
72 void genCoordText(void);
74 /**Generate explanatory text for geodetic modules. */
75 void genGeodText(void);
77 /**Generate explanatory text for solar system modules. */
78 void genSolarText(void);
80 /**Generate frame for Julian Date functions. */
81 void genJdFrame(void);
83 /**Generate frame for Sidereal Time functions. */
84 void genSidFrame(void);
86 /**Generate frame for Day Length functions. */
87 void genDayFrame(void);
89 /**Generates the frame for the Equinox and Solstice functions */
90 void genEquinoxFrame(void);
92 /**Generate frame for geodetic coordinates frame. */
93 void genGeodCoordFrame(void);
95 /**Generate frame for galactic coordinates frame. */
96 void genGalFrame(void);
98 /**Generate frame for ecliptic coordinates frame. */
99 void genEclFrame(void);
101 /**Generate frame for Precession frame. */
102 void genPrecFrame(void);
104 /**Generate frame for apparent coordinates frame. */
105 void genAppFrame(void);
107 /**Generate frame for horizontal coordinates frame. */
108 void genAzelFrame(void);
110 /**Generate frame for planets coordinates frame. */
111 void genPlanetsFrame(void);
113 /**Generate frame for angular distances frame. */
114 void genAngDistFrame(void);
116 /**Generate frame for Vlsr frame. */
117 void genVlsrFrame(void);
119 /**remove whatever frame is loaded in the right panel. */
120 void delRightPanel(void);
122 /**@returns suggested size of calculator window. */
123 QSize
sizeHint() const;
126 /**Determine which item is selected in the function menu QListBox.
127 *Generate the corresponding calculator module.
129 void slotItemSelection(QListViewItem
*it
);
134 QListView
*navigationPanel
, *auxiliar
;
135 QTextView
*splashScreen
;
136 // QListViewItem *timeItem, *coordItem, *jdItem, *stItem, *dayItem;
137 QVBox
*vbox
, *rightBox
;
138 QString previousElection
;
140 enum typeOfPanel
{GenText
, TimeText
, GeoText
, SolarText
, CoordText
, JD
, SidTime
, DayLength
, Equinox
, GeoCoord
, Galactic
, Precessor
, Apparent
, Azel
, Planets
, Ecliptic
, AngDist
, Vlsr
};
141 typeOfPanel rightPanel
;
144 modCalcGeodCoord
*GeodCoordFrame
;
145 modCalcGalCoord
*GalFrame
;
146 modCalcSidTime
*SidFrame
;
147 modCalcPrec
*PrecFrame
;
148 modCalcApCoord
*AppFrame
;
149 modCalcDayLength
*DayFrame
;
150 modCalcAzel
*AzelFrame
;
151 modCalcPlanets
*PlanetsFrame
;
152 modCalcEquinox
*EquinoxFrame
;
153 modCalcEclCoords
*EclFrame
;
154 modCalcAngDist
*AngDistFrame
;
155 modCalcVlsr
*VlsrFrame
;