[Kstars-devel] KDE/kdeedu/kstars/kstars
James Bowlin
bowlin at mindspring.com
Fri Aug 17 22:20:03 CEST 2007
SVN commit 701254 by jbowlin:
Fixed four horizon related bugs where we checked for
Options::showGround() but not Options::showHorizon() which caused
us to assume the horizon was displayed and filled when it was
filled but not displayed:
1) start up warning of focus below the horizon
2) in checkVisibility() for displaying objects
3) for drawing transient labels
4) in slotCentered() warning of requested position below the horizon.
CCMAIL: kstars-devel at kde.org
M +1 -1 kstarsinit.cpp
M +3 -3 skymap.cpp
--- trunk/KDE/kdeedu/kstars/kstars/kstarsinit.cpp #701253:701254
@@ -665,7 +665,7 @@
map()->oldfocus()->setAlt( map()->focus()->alt()->Degrees() );
//Check whether initial position is below the horizon.
- if ( Options::useAltAz() && Options::showGround() &&
+ if ( Options::useAltAz() && Options::showHorizon() && Options::showGround() &&
map()->focus()->alt()->Degrees() < -1.0 ) {
QString caption = i18n( "Initial Position is Below Horizon" );
QString message = i18n( "The initial position is below the horizon.\nWould you like to reset to the default position?" );
--- trunk/KDE/kdeedu/kstars/kstars/skymap.cpp #701253:701254
@@ -203,7 +203,7 @@
//
//Do not show a transient label if the map is in motion, or if the mouse
//pointer is below the opaque horizon, or if the object has a permanent label
- if ( ! slewing && ! ( Options::useAltAz() && Options::showGround() &&
+ if ( ! slewing && ! ( Options::useAltAz() && Options::showHorizon() && Options::showGround() &&
refract( mousePoint()->alt(), true ).Degrees() < 0.0 ) ) {
double maxrad = 1000.0/Options::zoomFactor();
SkyObject *so = data->skyComposite()->objectNearest( mousePoint(), maxrad );
@@ -274,7 +274,7 @@
//If the requested object is below the opaque horizon, issue a warning message
//(unless user is already pointed below the horizon)
- if ( Options::useAltAz() && Options::showGround() &&
+ if ( Options::useAltAz() && Options::showHorizon() && Options::showGround() &&
focus()->alt()->Degrees() > -1.0 && focusPoint()->alt()->Degrees() < -1.0 ) {
QString caption = i18n( "Requested Position Below Horizon" );
@@ -1312,7 +1312,7 @@
// + and either of the following is true:
// - focus is above the horizon
// - field of view is larger than 50 degrees
- if ( useAltAz && Options::showHorizon && Options::showGround() && p->alt()->Degrees() < -2.0
+ if ( useAltAz && Options::showHorizon() && Options::showGround() && p->alt()->Degrees() < -2.0
&& ( focus()->alt()->Degrees() > 0. || fov() > 50. ) ) return false;
if ( useAltAz ) {
More information about the Kstars-devel
mailing list