Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Education
KStars
Commits
b13f9c0d
Commit
b13f9c0d
authored
Dec 01, 2004
by
nobody
Browse files
Options
Browse Files
Download
Plain Diff
This commit was manufactured by cvs2svn to create tag
'KDE_3_3_2_RELEASE'. svn path=/tags/KDE_3_3_2_RELEASE/kdeedu/kstars/; revision=367579
parents
b8bae513
c7927f1c
Changes
31
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
425 additions
and
210 deletions
+425
-210
kstars/Makefile.am
kstars/Makefile.am
+1
-1
kstars/data/Cities.dat
kstars/data/Cities.dat
+2
-2
kstars/detaildialog.cpp
kstars/detaildialog.cpp
+7
-2
kstars/indi/fli_ccd.c
kstars/indi/fli_ccd.c
+1
-0
kstars/indi/lx200generic.cpp
kstars/indi/lx200generic.cpp
+19
-1
kstars/indi/lx200generic.h
kstars/indi/lx200generic.h
+2
-0
kstars/indi/lx200gps.cpp
kstars/indi/lx200gps.cpp
+25
-32
kstars/indi/v4ldriver.cpp
kstars/indi/v4ldriver.cpp
+1
-0
kstars/indi/v4lphilips.cpp
kstars/indi/v4lphilips.cpp
+1
-0
kstars/indi/webcam/port.cpp
kstars/indi/webcam/port.cpp
+3
-3
kstars/indi/webcam/port.h
kstars/indi/webcam/port.h
+3
-3
kstars/infoboxes.cpp
kstars/infoboxes.cpp
+2
-2
kstars/kstars.desktop
kstars/kstars.desktop
+1
-3
kstars/kstars.h
kstars/kstars.h
+2
-0
kstars/kstarsactions.cpp
kstars/kstarsactions.cpp
+37
-0
kstars/kstarsdcop.cpp
kstars/kstarsdcop.cpp
+2
-1
kstars/opscatalog.cpp
kstars/opscatalog.cpp
+28
-4
kstars/opscatalog.h
kstars/opscatalog.h
+1
-1
kstars/opscolors.cpp
kstars/opscolors.cpp
+39
-13
kstars/opscolors.h
kstars/opscolors.h
+2
-0
kstars/opssolarsystem.cpp
kstars/opssolarsystem.cpp
+57
-0
kstars/opssolarsystem.h
kstars/opssolarsystem.h
+48
-0
kstars/opssolarsystemui.ui
kstars/opssolarsystemui.ui
+9
-6
kstars/skymap.cpp
kstars/skymap.cpp
+5
-1
kstars/skymapdraw.cpp
kstars/skymapdraw.cpp
+113
-127
kstars/skyobject.cpp
kstars/skyobject.cpp
+2
-1
kstars/skypoint.cpp
kstars/skypoint.cpp
+1
-1
kstars/skypoint.h
kstars/skypoint.h
+3
-3
kstars/tools/scriptbuilder.cpp
kstars/tools/scriptbuilder.cpp
+1
-1
kstars/tools/scriptfunction.cpp
kstars/tools/scriptfunction.cpp
+6
-1
kstars/tools/wutdialog.cpp
kstars/tools/wutdialog.cpp
+1
-1
No files found.
kstars/Makefile.am
View file @
b13f9c0d
bin_PROGRAMS
=
kstars
kstars_SOURCES
=
Options.kcfgc kspluto.cpp addcatdialog.cpp addlinkdialog.cpp colorscheme.cpp detaildialog.cpp dmsbox.cpp dms.cpp filesource.cpp finddialog.cpp focusdialog.cpp geolocation.cpp imageviewer.cpp indidevice.cpp indidriver.cpp indimenu.cpp infobox.cpp infoboxes.cpp jupitermoons.cpp ksasteroid.cpp kscomet.cpp ksfilereader.cpp ksmoon.cpp ksnewstuff.cpp ksnumbers.cpp ksplanetbase.cpp ksplanet.cpp kspopupmenu.cpp kssun.cpp kstarsactions.cpp kstars.cpp kstarsdata.cpp kstarsdatetime.cpp kstarsdcop.cpp kstarsinit.cpp kstarssplash.cpp ksutils.cpp locationdialog.cpp magnitudespinbox.cpp main.cpp mapcanvas.cpp objectnamelist.cpp planetcatalog.cpp simclock.cpp skymap.cpp skymapdraw.cpp skymapevents.cpp skyobject.cpp skyobjectname.cpp skypoint.cpp stardatasink.cpp starobject.cpp starpixmap.cpp telescopewizardprocess.cpp timebox.cpp timedialog.cpp timespinbox.cpp timestepbox.cpp timeunitbox.cpp timezonerule.cpp toggleaction.cpp deepskyobject.cpp fovdialog.cpp fov.cpp indigroup.cpp indiproperty.cpp indielement.cpp devicemanager.cpp indistd.cpp kswizard.cpp csegment.cpp fitsviewer.cpp conbridlg.cpp fitsimage.cpp fitsprocess.cpp imagereductiondlg.cpp opsadvanced.cpp opscatalog.cpp opscolors.cpp fitshistogram.cpp kstarsinterface.skel simclockinterface.skel addcatdialogui.ui devmanager.ui focusdialogdlg.ui indiconf.ui indihostconf.ui opsadvancedui.ui opscatalogui.ui opscolorsui.ui opsguides.ui opssolarsystem.ui telescopewizard.ui fovdialogui.ui newfovui.ui kswizardui.ui contrastbrightnessgui.ui imagereductionui.ui histdialog.ui statform.ui fitsheaderdialog.ui streamformui.ui streamwg.cpp indifitsconf.cpp imgsequencedlgui.ui imagesequence.cpp
kstars_SOURCES
=
Options.kcfgc kspluto.cpp addcatdialog.cpp addlinkdialog.cpp colorscheme.cpp detaildialog.cpp dmsbox.cpp dms.cpp filesource.cpp finddialog.cpp focusdialog.cpp geolocation.cpp imageviewer.cpp indidevice.cpp indidriver.cpp indimenu.cpp infobox.cpp infoboxes.cpp jupitermoons.cpp ksasteroid.cpp kscomet.cpp ksfilereader.cpp ksmoon.cpp ksnewstuff.cpp ksnumbers.cpp ksplanetbase.cpp ksplanet.cpp kspopupmenu.cpp kssun.cpp kstarsactions.cpp kstars.cpp kstarsdata.cpp kstarsdatetime.cpp kstarsdcop.cpp kstarsinit.cpp kstarssplash.cpp ksutils.cpp locationdialog.cpp magnitudespinbox.cpp main.cpp mapcanvas.cpp objectnamelist.cpp planetcatalog.cpp simclock.cpp skymap.cpp skymapdraw.cpp skymapevents.cpp skyobject.cpp skyobjectname.cpp skypoint.cpp stardatasink.cpp starobject.cpp starpixmap.cpp telescopewizardprocess.cpp timebox.cpp timedialog.cpp timespinbox.cpp timestepbox.cpp timeunitbox.cpp timezonerule.cpp toggleaction.cpp deepskyobject.cpp fovdialog.cpp fov.cpp indigroup.cpp indiproperty.cpp indielement.cpp devicemanager.cpp indistd.cpp kswizard.cpp csegment.cpp fitsviewer.cpp conbridlg.cpp fitsimage.cpp fitsprocess.cpp imagereductiondlg.cpp opsadvanced.cpp opscatalog.cpp opscolors.cpp fitshistogram.cpp kstarsinterface.skel simclockinterface.skel addcatdialogui.ui devmanager.ui focusdialogdlg.ui indiconf.ui indihostconf.ui opsadvancedui.ui opscatalogui.ui opscolorsui.ui opsguides.ui opssolarsystem.
cpp opssolarsystemui.
ui telescopewizard.ui fovdialogui.ui newfovui.ui kswizardui.ui contrastbrightnessgui.ui imagereductionui.ui histdialog.ui statform.ui fitsheaderdialog.ui streamformui.ui streamwg.cpp indifitsconf.cpp imgsequencedlgui.ui imagesequence.cpp
kde_kcfg_DATA
=
kstars.kcfg
kde_conf_DATA
=
kstarsrc
...
...
kstars/data/Cities.dat
View file @
b13f9c0d
...
...
@@ -447,7 +447,7 @@ Chitose : : Japan
Chittagong : : Bangladesh : 22 : 15 : 0 : N : 91 : 49 : 59 : E : 6.0 : --
Christchurch : : New Zealand : 43 : 28 : 58 : S : 172 : 31 : 58 : E : 12.0 : NZ
Christiansoe : Bornholm : Denmark : 55 : 19 : 0 : N : 15 : 11 : 0 : E : 1.0 : EU
Christmas Island : : Australia :
1 :
58
:
59
:
N
: 15
7
:
22
:
1
:
W
: 7.0
: --
Christmas Island : : Australia : 1
0
:
30
:
00
:
S
: 1
0
5 :
40
:
00
:
E
: 7.0 : --
Chula Vista : California : USA : 32 : 38 : 35 : N : 117 : 4 : 58 : W : -8.0 : US
Chuncheon : Gangwon : Korea : 37 : 54 : 0 : N : 127 : 44 : 0 : E : 9.0 : SK
Chungju : Chungbuk : Korea : 36 : 58 : 0 : N : 127 : 53 : 0 : E : 9.0 : SK
...
...
@@ -879,7 +879,7 @@ Green Bank Obs. : West Virginia : USA
Green Bay : Wisconsin : USA : 44 : 30 : 47 : N : 88 : 0 : 50 : W : -6.0 : US
Green River : Utah : USA : 39 : 0 : 0 : N : 110 : 4 : 58 : W : -7.0 : US
Green River : Wyoming : USA : 41 : 31 : 36 : N : 109 : 28 : 4 : W : -7.0 : US
Greenbelt : Maryland : USA : 39 : 0 : 0 : N : 76 : 51 : 15 :
E
: -5.0 : US
Greenbelt : Maryland : USA : 39 : 0 : 0 : N : 76 : 51 : 15 :
W
: -5.0 : US
Greensboro : North Carolina : USA : 36 : 4 : 17 : N : 79 : 47 : 25 : W : -5.0 : US
Greenville : Maine : USA : 45 : 25 : 58 : N : 69 : 34 : 58 : W : -5.0 : US
Greenville : Mississippi : USA : 33 : 24 : 24 : N : 91 : 3 : 36 : W : -6.0 : US
...
...
kstars/detaildialog.cpp
View file @
b13f9c0d
...
...
@@ -288,13 +288,18 @@ void DetailDialog::createGeneralTab( const KStarsDateTime &ut, GeoLocation *geo
default:
//deep-sky objects
dso
=
(
DeepSkyObject
*
)
selectedObject
;
if
(
!
dso
->
longname
().
isEmpty
()
)
{
if
(
!
dso
->
longname
().
isEmpty
()
&&
dso
->
longname
()
!=
dso
->
name
()
)
{
pname
=
dso
->
translatedLongName
();
oname
=
dso
->
translatedName
();
}
else
{
pname
=
dso
->
translatedName
();
}
if
(
!
dso
->
name2
().
isEmpty
()
)
oname
+=
", "
+
dso
->
translatedName2
();
if
(
!
dso
->
name2
().
isEmpty
()
)
{
if
(
oname
.
isEmpty
()
)
oname
=
dso
->
translatedName2
();
else
oname
+=
", "
+
dso
->
translatedName2
();
}
if
(
dso
->
ugc
()
!=
0
)
oname
+=
", UGC "
+
QString
(
"%1"
).
arg
(
dso
->
ugc
()
);
if
(
dso
->
pgc
()
!=
0
)
oname
+=
", PGC "
+
QString
(
"%1"
).
arg
(
dso
->
pgc
()
);
...
...
kstars/indi/fli_ccd.c
View file @
b13f9c0d
...
...
@@ -29,6 +29,7 @@
#include <fcntl.h>
#include <errno.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
...
...
kstars/indi/lx200generic.cpp
View file @
b13f9c0d
...
...
@@ -281,6 +281,7 @@ LX200Generic::LX200Generic()
trackingMode
=
LX200_TRACK_DEFAULT
;
lastSet
=
-
1
;
fault
=
false
;
simulation
=
false
;
targetRA
=
0
;
targetDEC
=
0
;
currentRA
=
0
;
...
...
@@ -1188,6 +1189,8 @@ void LX200Generic::handleError(ITextVectorProperty *tvp, int err, const char *ms
bool
LX200Generic
::
isTelescopeOn
(
void
)
{
if
(
simulation
)
return
true
;
return
(
PowerSP
.
sp
[
0
].
s
==
ISS_ON
);
}
...
...
@@ -1570,6 +1573,8 @@ int LX200Generic::getOnSwitch(ISwitchVectorProperty *sp)
int
LX200Generic
::
checkPower
(
ISwitchVectorProperty
*
sp
)
{
if
(
simulation
)
return
0
;
if
(
PowerSP
.
s
!=
IPS_OK
)
{
if
(
!
strcmp
(
sp
->
label
,
""
))
...
...
@@ -1587,7 +1592,8 @@ int LX200Generic::checkPower(ISwitchVectorProperty *sp)
int
LX200Generic
::
checkPower
(
INumberVectorProperty
*
np
)
{
if
(
simulation
)
return
0
;
if
(
PowerSP
.
s
!=
IPS_OK
)
{
...
...
@@ -1608,6 +1614,8 @@ int LX200Generic::checkPower(INumberVectorProperty *np)
int
LX200Generic
::
checkPower
(
ITextVectorProperty
*
tp
)
{
if
(
simulation
)
return
0
;
if
(
PowerSP
.
s
!=
IPS_OK
)
{
if
(
!
strcmp
(
tp
->
label
,
""
))
...
...
@@ -1712,3 +1720,13 @@ void LX200Generic::getAlignment()
IDSetSwitch
(
&
AlignmentSw
,
NULL
);
IDLog
(
"ACK success %c
\n
"
,
align
);
}
void
LX200Generic
::
enableSimulation
(
bool
enable
)
{
simulation
=
enable
;
if
(
simulation
)
IDLog
(
"Warning: Simulation is activated.
\n
"
);
else
IDLog
(
"Simulation is disabled.
\n
"
);
}
kstars/indi/lx200generic.h
View file @
b13f9c0d
...
...
@@ -54,6 +54,7 @@ class LX200Generic
int
getOnSwitch
(
ISwitchVectorProperty
*
sp
);
void
setCurrentDeviceName
(
const
char
*
devName
);
void
correctFault
();
void
enableSimulation
(
bool
enable
);
protected:
...
...
@@ -69,6 +70,7 @@ class LX200Generic
double
lastRA
;
double
lastDEC
;
bool
fault
;
bool
simulation
;
struct
tm
*
localTM
;
...
...
kstars/indi/lx200gps.cpp
View file @
b13f9c0d
...
...
@@ -33,7 +33,7 @@ extern ITextVectorProperty Time;
extern
int
MaxReticleFlashRate
;
static
ISwitch
GPSPowerS
[]
=
{{
"On"
,
""
,
ISS_OFF
,
0
,
0
},
{
"Off"
,
""
,
ISS_ON
,
0
,
0
}};
static
ISwitch
GPSStatusS
[]
=
{{
"
GPS
Sleep"
,
""
,
ISS_OFF
,
0
,
0
},
{
"
GPS
Wake up"
,
""
,
ISS_OFF
,
0
,
0
},
{
"
GPS
Restart"
,
""
,
ISS_OFF
,
0
,
0
}};
static
ISwitch
GPSStatusS
[]
=
{{
"Sleep"
,
""
,
ISS_OFF
,
0
,
0
},
{
"Wake up"
,
""
,
ISS_OFF
,
0
,
0
},
{
"Restart"
,
""
,
ISS_OFF
,
0
,
0
}};
static
ISwitch
GPSUpdateS
[]
=
{
{
"Update"
,
""
,
ISS_OFF
,
0
,
0
}};
static
ISwitch
AltDecPecS
[]
=
{{
"Enable"
,
""
,
ISS_OFF
,
0
,
0
},
{
"Disable"
,
""
,
ISS_OFF
,
0
,
0
}};
static
ISwitch
AzRaPecS
[]
=
{{
"Enable"
,
""
,
ISS_OFF
,
0
,
0
},
{
"Disable"
,
""
,
ISS_OFF
,
0
,
0
}};
...
...
@@ -53,6 +53,8 @@ static ISwitchVectorProperty AzRaBackSlashSw = { mydev, "Az/Ra Anti-backslash",
static
INumber
Temp
[]
=
{
{
"Temp."
,
""
,
"%g"
,
-
200.
,
500.
,
0.
,
0.
,
0
,
0
,
0
}
};
static
INumberVectorProperty
OTATemp
=
{
mydev
,
"OTA Temperature (C)"
,
""
,
GPSGroup
,
IP_RO
,
0
,
IPS_IDLE
,
Temp
,
NARRAY
(
Temp
),
0
,
0
};
void
updateTemp
(
void
*
/*p*/
);
void
changeLX200GPSDeviceName
(
const
char
*
newName
)
{
strcpy
(
GPSPowerSw
.
device
,
newName
);
...
...
@@ -68,7 +70,8 @@ void changeLX200GPSDeviceName(const char *newName)
LX200GPS
::
LX200GPS
()
:
LX200_16
()
{
IEAddTimer
(
900000
,
updateTemp
,
NULL
);
}
void
LX200GPS
::
ISGetProperties
(
const
char
*
dev
)
...
...
@@ -111,36 +114,18 @@ void LX200GPS::ISNewNumber (const char *dev, const char *name, double values[],
}
/*#define turnGPSOn() portWrite("#:g+#")
#define turnGPSOff() portWrite("#:g-#")
#define alignGPSScope() portWrite("#:Aa#")
#define gpsSleep() portWrite("#:hN#")
#define gpsWakeUp() portWrite("#:hW#")
#define gpsRestart() portWrite("#:I#")
#define updateGPS_System() setStandardProcedure("#:gT#")
#define enableDecAltPec() portWrite("#:QA+#")
#define disableDecAltPec() portWrite("#:QA-#")
#define enableRA_AZPec() portWrite("#:QZ+#")
#define disableRA_AZPec() portWrite("#:QZ-#")
#define activateAltDecAntiBackSlash() portWrite("#$BAdd#")
#define activateAzRaAntiBackSlash() portWrite("#$BZdd#")
#define SelenographicSync() portWrite("#:CL#")
double getOTATemp();
*/
void
LX200GPS
::
ISNewSwitch
(
const
char
*
dev
,
const
char
*
name
,
ISState
*
states
,
char
*
names
[],
int
n
)
{
int
index
;
char
msg
[
32
];
char
msg
[
64
];
if
(
strcmp
(
dev
,
thisDevice
))
return
;
if
(
!
strcmp
(
name
,
GPSPowerSw
.
name
))
{
if
(
checkPower
(
&
GPSPowerSw
))
if
(
checkPower
(
&
GPSPowerSw
))
return
;
IUResetSwitches
(
&
GPSPowerSw
);
...
...
@@ -155,10 +140,10 @@ double getOTATemp();
if
(
!
strcmp
(
name
,
GPSStatusSw
.
name
))
{
if
(
checkPower
(
&
GPSStatusSw
))
if
(
checkPower
(
&
GPSStatusSw
))
return
;
IUResetSwitches
(
&
GPS
Power
Sw
);
IUResetSwitches
(
&
GPS
Status
Sw
);
IUUpdateSwitches
(
&
GPSStatusSw
,
states
,
names
,
n
);
index
=
getOnSwitch
(
&
GPSStatusSw
);
...
...
@@ -186,7 +171,7 @@ double getOTATemp();
if
(
!
strcmp
(
name
,
GPSUpdateSw
.
name
))
{
if
(
checkPower
(
&
GPSUpdateSw
))
if
(
checkPower
(
&
GPSUpdateSw
))
return
;
GPSUpdateSw
.
s
=
IPS_OK
;
...
...
@@ -203,7 +188,7 @@ double getOTATemp();
if
(
!
strcmp
(
name
,
AltDecPecSw
.
name
))
{
if
(
checkPower
(
&
AltDecPecSw
))
if
(
checkPower
(
&
AltDecPecSw
))
return
;
IUResetSwitches
(
&
AltDecPecSw
);
...
...
@@ -229,8 +214,8 @@ double getOTATemp();
if
(
!
strcmp
(
name
,
AzRaPecSw
.
name
))
{
if
(
checkPower
(
&
AzRaPecSw
))
return
;
if
(
checkPower
(
&
AzRaPecSw
))
return
;
IUResetSwitches
(
&
AzRaPecSw
);
IUUpdateSwitches
(
&
AzRaPecSw
,
states
,
names
,
n
);
...
...
@@ -255,7 +240,7 @@ double getOTATemp();
if
(
!
strcmp
(
name
,
AltDecBackSlashSw
.
name
))
{
if
(
checkPower
(
&
AltDecBackSlashSw
))
if
(
checkPower
(
&
AltDecBackSlashSw
))
return
;
activateAltDecAntiBackSlash
();
...
...
@@ -284,12 +269,20 @@ double getOTATemp();
LX200_16
::
ISPoll
();
if
(
isTelescopeOn
())
}
void
updateTemp
(
void
*
/*p*/
)
{
if
(
telescope
->
isTelescopeOn
())
{
getOTATemp
(
&
OTATemp
.
np
[
0
].
value
);
IDSetNumber
(
&
OTATemp
,
NULL
);
}
}
IEAddTimer
(
900000
,
updateTemp
,
NULL
);
}
void
LX200GPS
::
getBasicData
()
...
...
kstars/indi/v4ldriver.cpp
View file @
b13f9c0d
...
...
@@ -30,6 +30,7 @@
#include <signal.h>
#include <errno.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
...
...
kstars/indi/v4lphilips.cpp
View file @
b13f9c0d
...
...
@@ -29,6 +29,7 @@
#include <signal.h>
#include <errno.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
...
...
kstars/indi/webcam/port.cpp
View file @
b13f9c0d
...
...
@@ -38,7 +38,7 @@
#endif
/* LOCKING */
#ifdef __linux__
#if defined(arm) || defined(__hppa__)
#if defined(arm) || defined(__hppa__)
|| defined(__sparc__) || defined(__ppc__) || defined(__powerpc__) || defined(__s390__) || defined(__s390x__) || defined(__mips__) || defined(__mc68000__)
#include <fcntl.h>
#else
#include <sys/io.h>
...
...
@@ -74,7 +74,7 @@ port_t::port_t(int iport) {
#endif
/* LOCKING */
#ifdef LINUX
#if defined(arm) || defined(__hppa__)
#if defined(arm) || defined(__hppa__)
|| defined(__sparc__) || defined(__ppc__) || defined(__powerpc__) || defined(__s390__) || defined(__s390x__) || defined(__mips__) || defined(__mc68000__)
if
((
devport
=
open
(
"/dev/port"
,
O_RDWR
))
<
0
)
{
perror
(
"open /dev/port"
);
return
;
...
...
@@ -118,7 +118,7 @@ port_t::~port_t(void) {
unlock
(
port
);
#endif
/* LOCKING */
#ifdef LINUX
#if defined(arm) || defined(__hppa__)
#if defined(arm) || defined(__hppa__)
|| defined(__sparc__) || defined(__ppc__) || defined(__powerpc__) || defined(__s390__) || defined(__s390x__) || defined(__mips__) || defined(__mc68000__)
if
(
devport
>=
0
)
close
(
devport
);
#else
...
...
kstars/indi/webcam/port.h
View file @
b13f9c0d
...
...
@@ -35,7 +35,7 @@
#include <unistd.h>
#ifdef __linux__
#if !defined(arm) && !defined(__hppa__)
#if !defined(arm) && !defined(__hppa__)
&& !defined(__sparc__) && !defined(__ppc__) && !defined(__powerpc__) && !defined(__s390__) && !defined(__s390x__) && !defined(__mips__) && !defined(__mc68000__)
#include <sys/io.h>
#endif
/* !arm */
#elif defined(QNX)
...
...
@@ -55,7 +55,7 @@
#error Please define a platform in the Makefile
#endif
#if defined(arm) || defined(__hppa__)
#if defined(arm) || defined(__hppa__)
|| defined(__sparc__) || defined(__ppc__) || defined(__powerpc__) || defined(__s390__) || defined(__s390x__) || defined(__mips__) || defined(__mc68000__)
static
char
ports_temp
;
#ifdef inb
...
...
@@ -114,7 +114,7 @@ private:
#ifdef FREEBSD
FILE
*
devio
;
#endif
#if defined(__linux__) && (defined(arm) || defined(__hppa__))
#if defined(__linux__) && (defined(arm) || defined(__hppa__)
|| defined(__sparc__) || defined(__ppc__) || defined(__powerpc__) || defined(__s390__) || defined(__s390x__) || defined(__mips__) || defined(__mc68000__)
)
int
devport
;
#endif
};
...
...
kstars/infoboxes.cpp
View file @
b13f9c0d
...
...
@@ -341,9 +341,9 @@ bool InfoBoxes::timeChanged( const KStarsDateTime &ut, const KStarsDateTime <,
QString
ot3
=
TimeBox
->
text3
();
TimeBox
->
setText1
(
i18n
(
"Local Time"
,
"LT: "
)
+
lt
.
time
().
toString
()
+
" "
+
lt
.
date
().
toString
(
"dd MMM yyyy"
)
);
+
" "
+
lt
.
date
().
toString
(
"%d %b %Y"
)
);
TimeBox
->
setText2
(
i18n
(
"Universal Time"
,
"UT: "
)
+
ut
.
time
().
toString
()
+
" "
+
ut
.
date
().
toString
(
"dd MMM yyyy"
)
);
+
" "
+
ut
.
date
().
toString
(
"%d %b %Y"
)
);
QString
STString
;
STString
=
STString
.
sprintf
(
"%02d:%02d:%02d "
,
lst
->
hour
(),
lst
->
minute
(),
lst
->
second
()
);
TimeBox
->
setText3
(
i18n
(
"Sidereal Time"
,
"ST: "
)
+
STString
+
...
...
kstars/kstars.desktop
View file @
b13f9c0d
...
...
@@ -52,7 +52,6 @@ Comment[tg]=Планетариуми Мизи Корӣ
Comment[tr]=Masaüstünde Yıldızlar
Comment[ven]=Vhusumbedzhwa mupo ya Desikithopo
Comment[xh]=Indlu ye Desktop
Comment[xx]=xxDesktop Planetariumxx
Comment[zh_CN]=桌面天文馆
Comment[zh_TW]=桌面星象儀
Comment[zu]=Okwemikhathi kwe-Desktop
...
...
@@ -70,8 +69,8 @@ Name[pt_BR]=Estrelas
Name[sv]=Kstars
Name[ta]=கேஸ்டார்ஸ்
Name[ven]=Vhadivhalea vha K
Name[xx]=xxKStarsxx
GenericName=Desktop Planetarium
GenericName[ar]=نموذج النظام الشمسي لسطح المكتب
GenericName[bg]=Планетариум за работния плот
GenericName[bs]=Desktop planetarijum
GenericName[ca]=Planetari per a l'escriptori
...
...
@@ -105,7 +104,6 @@ GenericName[sr@Latn]=Planetarijum na radnoj površinidž
GenericName[sv]=Skrivbordsplanetarium
GenericName[ta]=பணிமேடை கோளரங்கம்
GenericName[tg]=Планетариуми Мизи Корӣ
GenericName[xx]=xxDesktop Planetariumxx
GenericName[zh_CN]=桌面天文馆
X-DCOP-ServiceType=Multi
Categories=Qt;KDE;Education;Science;Astronomy
kstars/kstars.h
View file @
b13f9c0d
...
...
@@ -224,6 +224,8 @@ class KStars : public KMainWindow, virtual public KStarsInterface
void
resumeDCOP
(
void
)
{
kapp
->
dcopClient
()
->
resume
();
}
void
slotClearAllTrails
();
private
slots
:
/**
*action slot: synch kstars clock to system time
...
...
kstars/kstarsactions.cpp
View file @
b13f9c0d
...
...
@@ -53,6 +53,9 @@
#include "skyobject.h"
#include "skyobjectname.h"
#include "ksplanetbase.h"
#include "ksasteroid.h"
#include "kscomet.h"
#include "ksmoon.h"
#include "simclock.h"
#include "infoboxes.h"
#include "toggleaction.h"
...
...
@@ -334,6 +337,7 @@ void KStars::slotViewOps() {
void
KStars
::
slotApplySettings
()
{
Options
::
writeConfig
();
data
()
->
setFullTimeUpdate
();
map
()
->
forceUpdate
();
}
...
...
@@ -588,6 +592,9 @@ void KStars::slotTrack() {
map
()
->
setFocusPoint
(
NULL
);
}
else
{
map
()
->
setClickedPoint
(
map
()
->
focus
()
);
map
()
->
setClickedObject
(
NULL
);
map
()
->
setFocusObject
(
NULL
);
//no longer tracking focusObject
map
()
->
setFocusPoint
(
map
()
->
clickedPoint
()
);
Options
::
setIsTracking
(
true
);
actionCollection
()
->
action
(
"track_object"
)
->
setText
(
i18n
(
"Stop &Tracking"
)
);
actionCollection
()
->
action
(
"track_object"
)
->
setIconSet
(
BarIcon
(
"encrypted"
)
);
...
...
@@ -838,6 +845,36 @@ void KStars::slotFullScreen()
}
}
void
KStars
::
slotClearAllTrails
()
{
//Exclude object with temporary trail
SkyObject
*
exOb
(
NULL
);
if
(
map
()
->
focusObject
()
&&
map
()
->
focusObject
()
->
isSolarSystem
()
&&
data
()
->
temporaryTrail
)
{
exOb
=
map
()
->
focusObject
();
}
//Major bodies
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Moon"
)
)
data
()
->
Moon
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Sun"
)
)
data
()
->
PCat
->
findByName
(
"Sun"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Mercury"
)
)
data
()
->
PCat
->
findByName
(
"Mercury"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Venus"
)
)
data
()
->
PCat
->
findByName
(
"Venus"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Mars"
)
)
data
()
->
PCat
->
findByName
(
"Mars"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Jupiter"
)
)
data
()
->
PCat
->
findByName
(
"Jupiter"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Saturn"
)
)
data
()
->
PCat
->
findByName
(
"Saturn"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Uranus"
)
)
data
()
->
PCat
->
findByName
(
"Uranus"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Neptune"
)
)
data
()
->
PCat
->
findByName
(
"Neptune"
)
->
clearTrail
();
if
(
!
(
exOb
&&
exOb
->
name
()
==
"Pluto"
)
)
data
()
->
PCat
->
findByName
(
"Pluto"
)
->
clearTrail
();
//Asteroids
for
(
KSAsteroid
*
ast
=
data
()
->
asteroidList
.
first
();
ast
;
ast
=
data
()
->
asteroidList
.
next
()
)
if
(
!
(
exOb
&&
exOb
->
name
()
==
ast
->
name
()
)
)
ast
->
clearTrail
();
//Comets
for
(
KSComet
*
com
=
data
()
->
cometList
.
first
();
com
;
com
=
data
()
->
cometList
.
next
()
)
if
(
!
(
exOb
&&
exOb
->
name
()
==
com
->
name
()
)
)
com
->
clearTrail
();
map
()
->
forceUpdate
();
}
//toggle display of GUI Items on/off
void
KStars
::
slotShowGUIItem
(
bool
show
)
{
//Toolbars
...
...
kstars/kstarsdcop.cpp
View file @
b13f9c0d
...
...
@@ -443,8 +443,9 @@ void KStars::printImage( bool usePrintDialog, bool useChartColors ) {
if
(
useChartColors
)
{
data
()
->
colorScheme
()
->
copy
(
cs
);
// restore colormode in skymap
// restore colormode
and colorintensity
in skymap
map
()
->
setStarColorMode
(
cs
.
starColorMode
()
);
map
()
->
setStarColorIntensity
(
cs
.
starColorIntensity
()
);
map
()
->
forceUpdate
();
}
...
...
kstars/opscatalog.cpp
View file @
b13f9c0d
...
...
@@ -16,6 +16,8 @@
***************************************************************************/
#include <qlistview.h> //QCheckListItem
#include <qcheckbox.h>
#include <qlabel.h>
#include "opscatalog.h"
#include "Options.h"
...
...
@@ -43,9 +45,17 @@ OpsCatalog::OpsCatalog( QWidget *p, const char *name, WFlags fl )
showMessier
=
new
QCheckListItem
(
CatalogList
,
i18n
(
"Messier Catalog (symbols)"
),
QCheckListItem
::
CheckBox
);
showMessier
->
setOn
(
Options
::
showMessier
()
);
kcfg_MagLimitDrawStar
->
setValue
(
Options
::
magLimitDrawStar
()
);
kcfg_MagLimitDrawStarZoomOut
->
setValue
(
Options
::
magLimitDrawStarZoomOut
()
);
kcfg_MagLimitDrawStar
->
setMinValue
(
Options
::
magLimitDrawStarZoomOut
()
);
kcfg_MagLimitDrawStarZoomOut
->
setMaxValue
(
Options
::
magLimitDrawStar
()
);
kcfg_MagLimitDrawDeepSky
->
setMaxValue
(
16.0
);
kcfg_MagLimitDrawDeepSkyZoomOut
->
setMaxValue
(
16.0
);
//disable star-related widgets if not showing stars
if
(
!
kcfg_ShowStars
->
isChecked
()
)
slotStarWidgets
(
false
);
//Add custom catalogs, if necessary
for
(
unsigned
int
i
=
0
;
i
<
Options
::
catalogCount
();
++
i
)
{
//loop over custom catalogs
QCheckListItem
*
newItem
=
new
QCheckListItem
(
CatalogList
,
Options
::
catalogName
()[
i
],
QCheckListItem
::
CheckBox
);
...
...
@@ -57,13 +67,11 @@ OpsCatalog::OpsCatalog( QWidget *p, const char *name, WFlags fl )
connect
(
AddCatalog
,
SIGNAL
(
clicked
()
),
this
,
SLOT
(
slotAddCatalog
()
)
);
connect
(
RemoveCatalog
,
SIGNAL
(
clicked
()
),
this
,
SLOT
(
slotRemoveCatalog
()
)
);
// draw star magnitude box
connect
(
kcfg_MagLimitDrawStar
,
SIGNAL
(
valueChanged
(
double
)
),
SLOT
(
slotSetDrawStarMagnitude
(
double
)
)
);
// draw star zoom out magnitude box
connect
(
kcfg_MagLimitDrawStarZoomOut
,
SIGNAL
(
valueChanged
(
double
)
),
SLOT
(
slotSetDrawStarZoomOutMagnitude
(
double
)
)
);
connect
(
kcfg_ShowStars
,
SIGNAL
(
toggled
(
bool
)
),
SLOT
(
slotStarWidgets
(
bool
)
)
);
}
//empty destructor
...
...
@@ -142,13 +150,29 @@ void OpsCatalog::slotRemoveCatalog() {
}
void
OpsCatalog
::
slotSetDrawStarMagnitude
(
double
newValue
)
{
kcfg_MagLimitDrawStarZoomOut
->
setMaxValue
(
newValue
);
ksw
->
data
()
->
setMagnitude
(
newValue
);
}
void
OpsCatalog
::
slotSetDrawStarZoomOutMagnitude
(
double
newValue
)
{
Options
::
setMagLimitDrawStarZoomOut
(
newValue
);
kcfg_MagLimitDrawStar
->
setMinValue
(
newValue
);
Options
::
setMagLimitDrawStarZoomOut
(
newValue
);
// force redraw
ksw
->
map
()
->
forceUpdate
();
}
void
OpsCatalog
::
slotStarWidgets
(
bool
on
)
{
textLabelMagStars
->
setEnabled
(
on
);
textLabelMagStarsZoomOut
->
setEnabled
(
on
);
textLabelMagStarInfo
->
setEnabled
(
on
);
textLabelMag1
->
setEnabled
(
on
);
textLabelMag2
->
setEnabled
(
on
);
textLabelMag3
->
setEnabled
(
on
);
kcfg_MagLimitDrawStar
->
setEnabled
(
on
);
kcfg_MagLimitDrawStarZoomOut
->
setEnabled
(
on
);
kcfg_MagLimitDrawStarInfo
->
setEnabled
(
on
);
kcfg_ShowStarNames
->
setEnabled
(
on
);
kcfg_ShowStarMagnitudes
->
setEnabled
(
on
);
}
#include "opscatalog.moc"
kstars/opscatalog.h
View file @
b13f9c0d
...
...
@@ -51,7 +51,7 @@ private slots:
void
slotRemoveCatalog
();
void
slotSetDrawStarMagnitude
(
double
newValue
);
void
slotSetDrawStarZoomOutMagnitude
(
double
newValue
);
void
slotStarWidgets
(
bool
on
);
private:
QCheckListItem
*
showMessier
,
*
showMessImages
,
*
showNGC
,
*
showIC
;
...
...
kstars/opscolors.cpp
View file @
b13f9c0d
...
...
@@ -78,9 +78,13 @@ OpsColors::OpsColors( QWidget *p, const char *name, WFlags fl )
kcfg_StarColorMode
->
setCurrentItem
(
ksw
->
data
()
->
colorScheme
()
->
starColorMode
()
);
connect
(
ColorPalette
,
SIGNAL
(
clicked
(
QListBoxItem
*
)
),
this
,
SLOT
(
newColor
(
QListBoxItem
*
)
)
);
connect
(
kcfg_StarColorIntensity
,
SIGNAL
(
valueChanged
(
int
)
),
this
,
SLOT
(
slotStarColorIntensity
(
int
)
)
);
connect
(
kcfg_StarColorMode
,
SIGNAL
(
activated
(
int
)
),
this
,
SLOT
(
slotStarColorMode
(
int
)
)
);
connect
(
PresetBox
,
SIGNAL
(
highlighted
(
int
)
),
this
,
SLOT
(
slotPreset
(
int
)
)
);
connect
(
AddPreset
,
SIGNAL
(
clicked
()
),
this
,
SLOT
(
slotAddPreset
()
)
);
connect
(
RemovePreset
,
SIGNAL
(
clicked
()
),
this
,
SLOT
(
slotRemovePreset
()
)
);
RemovePreset
->
setEnabled
(
false
);
}
//empty destructor
...
...
@@ -130,9 +134,15 @@ bool OpsColors::setColors( QString filename ) {
test
.
close
();
ksw
->
loadColorScheme
(
filename
);
kcfg_StarColorMode
->
setCurrentItem
(
ksw
->
data
()
->
colorScheme
()
->
starColorMode
()
);
kcfg_StarColorIntensity
->
setValue
(
ksw
->
data
()
->
colorScheme
()
->
starColorIntensity
()
);
if
(
ksw
->
map
()
->
starColorMode
()
!=
ksw
->
data
()
->
colorScheme
()
->
starColorMode
()
)
ksw
->
map
()
->
setStarColorMode
(
ksw
->
data
()
->
colorScheme
()
->
starColorMode
()
);
if
(
ksw
->
map
()
->
starColorIntensity
()
!=
ksw
->
data
()
->
colorScheme
()
->
starColorIntensity
()
)
ksw
->
map
()
->
setStarColorIntensity
(
ksw
->
data
()
->
colorScheme
()
->
starColorIntensity
()
);
for
(
unsigned
int
i
=
0
;
i
<
ksw
->
data
()
->
colorScheme
()
->
numberOfColors
();
++
i
)
{
temp
->
fill
(
QColor
(
ksw
->
data
()
->
colorScheme
()
->
colorAt
(
i
)
)
);
ColorPalette
->
changeItem
(
*
temp
,
ksw
->
data
()
->
colorScheme
()
->
nameAt
(
i
),
i
);
...
...
@@ -151,8 +161,10 @@ void OpsColors::slotAddPreset() {
if
(
okPressed
&&
!
schemename
.
isEmpty
()
)
{
if
(
ksw
->
data
()
->
colorScheme
()
->
save
(
schemename
)
)
{
PresetBox
->
insertItem
(
schemename
);
PresetFileList
.
append
(
ksw
->
data
()
->
colorScheme
()
->
fileName
()
);
ksw
->
addColorMenuItem
(
schemename
,
"cs_"
+
ksw
->
data
()
->
colorScheme
()
->
fileName
().
utf8
()
);
PresetBox
->
setCurrentItem
(
PresetBox
->
findItem
(
schemename
)
);
QString
fname
=
ksw
->
data
()
->
colorScheme
()
->
fileName
();
PresetFileList
.
append
(
fname
);
ksw
->
addColorMenuItem
(
schemename
,
QString
(
"cs_"
+
fname
.
left
(
fname
.
find
(
".colors"
))).
utf8
()
);
}
}
}
...
...
@@ -163,17 +175,6 @@ void OpsColors::slotRemovePreset() {
QFile
cdatFile
;
cdatFile
.
setName
(
locateLocal
(
"appdata"
,
"colors.dat"
)
);
//determine filename in local user KDE directory tree.
//Remove entry from the ListBox and from the QStringList holding filenames.
//We don't want another color scheme to be selected, so first
//temporarily disconnect the "highlighted" signal.
disconnect
(
PresetBox
,
SIGNAL
(
highlighted
(
int
)
),
this
,
SLOT
(
slotPreset
(
int
)
)
);
PresetFileList
.
remove
(
PresetFileList
.
at
(
PresetBox
->
currentItem
()
)
);
PresetBox
->
removeItem
(
PresetBox
->
currentItem
()
);
//Reconnect the "highlighted" signal
connect
(
PresetBox
,
SIGNAL
(
highlighted
(
int
)
),
this
,
SLOT
(
slotPreset
(
int
)
)
);
//Remove action from color-schemes menu
ksw
->
removeColorMenuItem
(
QString
(
"cs_"
+
filename
.
left
(
filename
.
find
(
".colors"
))).
utf8
()
);
...
...
@@ -181,6 +182,17 @@ void OpsColors::slotRemovePreset() {