#include <kdialog.h>
#include <tdelocale.h>

/****************************************************************************
** Form implementation generated from reading ui file 'opssolarsystemui.ui'
**
** Created by: The TQt user interface compiler (TQt 3.5.0)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "opssolarsystemui.h"

#include <ntqvariant.h>
#include <knuminput.h>
#include <magnitudespinbox.h>
#include <kpushbutton.h>
#include <ntqpushbutton.h>
#include <ntqgroupbox.h>
#include <ntqcheckbox.h>
#include <ntqlabel.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>
#include "magnitudespinbox.h"

/*
 *  Constructs a OpsSolarSystemUI as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
OpsSolarSystemUI::OpsSolarSystemUI( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "OpsSolarSystemUI" );
    OpsSolarSystemUILayout = new TQVBoxLayout( this, 11, 6, "OpsSolarSystemUILayout"); 

    groupBox2 = new TQGroupBox( this, "groupBox2" );
    groupBox2->setColumnLayout(0, TQt::Vertical );
    groupBox2->layout()->setSpacing( 6 );
    groupBox2->layout()->setMargin( 11 );
    groupBox2Layout = new TQVBoxLayout( groupBox2->layout() );
    groupBox2Layout->setAlignment( TQt::AlignTop );

    layout20 = new TQGridLayout( 0, 1, 1, 0, 6, "layout20"); 

    kcfg_ShowSaturn = new TQCheckBox( groupBox2, "kcfg_ShowSaturn" );

    layout20->addWidget( kcfg_ShowSaturn, 1, 1 );

    kcfg_ShowPlanetImages = new TQCheckBox( groupBox2, "kcfg_ShowPlanetImages" );

    layout20->addWidget( kcfg_ShowPlanetImages, 3, 2 );

    kcfg_ShowMars = new TQCheckBox( groupBox2, "kcfg_ShowMars" );

    layout20->addWidget( kcfg_ShowMars, 4, 0 );

    kcfg_ShowPlanetNames = new TQCheckBox( groupBox2, "kcfg_ShowPlanetNames" );

    layout20->addWidget( kcfg_ShowPlanetNames, 2, 2 );

    kcfg_ShowPluto = new TQCheckBox( groupBox2, "kcfg_ShowPluto" );

    layout20->addWidget( kcfg_ShowPluto, 4, 1 );

    showAllPlanets = new KPushButton( groupBox2, "showAllPlanets" );

    layout20->addWidget( showAllPlanets, 0, 2 );

    showNonePlanets = new KPushButton( groupBox2, "showNonePlanets" );

    layout20->addWidget( showNonePlanets, 1, 2 );

    kcfg_ShowVenus = new TQCheckBox( groupBox2, "kcfg_ShowVenus" );

    layout20->addWidget( kcfg_ShowVenus, 3, 0 );

    kcfg_ShowSun = new TQCheckBox( groupBox2, "kcfg_ShowSun" );

    layout20->addWidget( kcfg_ShowSun, 0, 0 );

    kcfg_ShowJupiter = new TQCheckBox( groupBox2, "kcfg_ShowJupiter" );

    layout20->addWidget( kcfg_ShowJupiter, 0, 1 );

    kcfg_ShowMoon = new TQCheckBox( groupBox2, "kcfg_ShowMoon" );

    layout20->addWidget( kcfg_ShowMoon, 1, 0 );

    kcfg_ShowMercury = new TQCheckBox( groupBox2, "kcfg_ShowMercury" );

    layout20->addWidget( kcfg_ShowMercury, 2, 0 );

    kcfg_ShowNeptune = new TQCheckBox( groupBox2, "kcfg_ShowNeptune" );

    layout20->addWidget( kcfg_ShowNeptune, 3, 1 );
    spacer11 = new TQSpacerItem( 100, 20, TQSizePolicy::Fixed, TQSizePolicy::Minimum );
    layout20->addItem( spacer11, 4, 2 );

    kcfg_ShowUranus = new TQCheckBox( groupBox2, "kcfg_ShowUranus" );

    layout20->addWidget( kcfg_ShowUranus, 2, 1 );
    groupBox2Layout->addLayout( layout20 );
    spacer6 = new TQSpacerItem( 20, 40, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    groupBox2Layout->addItem( spacer6 );
    OpsSolarSystemUILayout->addWidget( groupBox2 );

    groupBox3 = new TQGroupBox( this, "groupBox3" );
    groupBox3->setColumnLayout(0, TQt::Vertical );
    groupBox3->layout()->setSpacing( 6 );
    groupBox3->layout()->setMargin( 11 );
    groupBox3Layout = new TQGridLayout( groupBox3->layout() );
    groupBox3Layout->setAlignment( TQt::AlignTop );

    kcfg_ShowComets = new TQCheckBox( groupBox3, "kcfg_ShowComets" );

    groupBox3Layout->addWidget( kcfg_ShowComets, 2, 0 );
    spacer8 = new TQSpacerItem( 20, 16, TQSizePolicy::Minimum, TQSizePolicy::Fixed );
    groupBox3Layout->addItem( spacer8, 1, 0 );

    textLabel3 = new TQLabel( groupBox3, "textLabel3" );

    groupBox3Layout->addWidget( textLabel3, 0, 1 );

    textLabel5 = new TQLabel( groupBox3, "textLabel5" );

    groupBox3Layout->addWidget( textLabel5, 1, 3 );

    textLabel4 = new TQLabel( groupBox3, "textLabel4" );

    groupBox3Layout->addWidget( textLabel4, 2, 3 );

    textLabel6 = new TQLabel( groupBox3, "textLabel6" );

    groupBox3Layout->addWidget( textLabel6, 0, 3 );

    kcfg_ShowAsteroids = new TQCheckBox( groupBox3, "kcfg_ShowAsteroids" );

    groupBox3Layout->addWidget( kcfg_ShowAsteroids, 0, 0 );

    kcfg_ShowAsteroidNames = new TQCheckBox( groupBox3, "kcfg_ShowAsteroidNames" );

    groupBox3Layout->addWidget( kcfg_ShowAsteroidNames, 1, 1 );

    kcfg_MaxRadCometName = new KDoubleNumInput( groupBox3, "kcfg_MaxRadCometName" );
    kcfg_MaxRadCometName->setMaxValue( 1e+07 );
    kcfg_MaxRadCometName->setPrecision( 1 );

    groupBox3Layout->addWidget( kcfg_MaxRadCometName, 2, 2 );

    kcfg_ShowCometNames = new TQCheckBox( groupBox3, "kcfg_ShowCometNames" );

    groupBox3Layout->addWidget( kcfg_ShowCometNames, 2, 1 );

    kcfg_MagLimitAsteroid = new MagnitudeSpinBox( groupBox3, "kcfg_MagLimitAsteroid" );
    kcfg_MagLimitAsteroid->setFocusPolicy( MagnitudeSpinBox::StrongFocus );

    groupBox3Layout->addWidget( kcfg_MagLimitAsteroid, 0, 2 );

    kcfg_MagLimitAsteroidName = new MagnitudeSpinBox( groupBox3, "kcfg_MagLimitAsteroidName" );
    kcfg_MagLimitAsteroidName->setFocusPolicy( MagnitudeSpinBox::StrongFocus );

    groupBox3Layout->addWidget( kcfg_MagLimitAsteroidName, 1, 2 );
    OpsSolarSystemUILayout->addWidget( groupBox3 );

    groupBox4 = new TQGroupBox( this, "groupBox4" );
    groupBox4->setColumnLayout(0, TQt::Vertical );
    groupBox4->layout()->setSpacing( 6 );
    groupBox4->layout()->setMargin( 11 );
    groupBox4Layout = new TQVBoxLayout( groupBox4->layout() );
    groupBox4Layout->setAlignment( TQt::AlignTop );

    kcfg_UseAutoTrail = new TQCheckBox( groupBox4, "kcfg_UseAutoTrail" );
    groupBox4Layout->addWidget( kcfg_UseAutoTrail );

    layout12 = new TQHBoxLayout( 0, 0, 6, "layout12"); 

    kcfg_FadePlanetTrails = new TQCheckBox( groupBox4, "kcfg_FadePlanetTrails" );
    layout12->addWidget( kcfg_FadePlanetTrails );
    spacer9 = new TQSpacerItem( 40, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout12->addItem( spacer9 );

    ClearAllTrails = new KPushButton( groupBox4, "ClearAllTrails" );
    layout12->addWidget( ClearAllTrails );
    groupBox4Layout->addLayout( layout12 );
    OpsSolarSystemUILayout->addWidget( groupBox4 );
    languageChange();
    resize( TQSize(610, 469).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( kcfg_ShowSun, kcfg_ShowMoon );
    setTabOrder( kcfg_ShowMoon, kcfg_ShowMercury );
    setTabOrder( kcfg_ShowMercury, kcfg_ShowVenus );
    setTabOrder( kcfg_ShowVenus, kcfg_ShowMars );
    setTabOrder( kcfg_ShowMars, kcfg_ShowJupiter );
    setTabOrder( kcfg_ShowJupiter, kcfg_ShowSaturn );
    setTabOrder( kcfg_ShowSaturn, kcfg_ShowUranus );
    setTabOrder( kcfg_ShowUranus, kcfg_ShowNeptune );
    setTabOrder( kcfg_ShowNeptune, kcfg_ShowPluto );
    setTabOrder( kcfg_ShowPluto, showAllPlanets );
    setTabOrder( showAllPlanets, showNonePlanets );
    setTabOrder( showNonePlanets, kcfg_ShowPlanetNames );
    setTabOrder( kcfg_ShowPlanetNames, kcfg_ShowPlanetImages );
    setTabOrder( kcfg_ShowPlanetImages, kcfg_ShowAsteroids );
    setTabOrder( kcfg_ShowAsteroids, kcfg_MagLimitAsteroid );
    setTabOrder( kcfg_MagLimitAsteroid, kcfg_ShowAsteroidNames );
    setTabOrder( kcfg_ShowAsteroidNames, kcfg_MagLimitAsteroidName );
    setTabOrder( kcfg_MagLimitAsteroidName, kcfg_ShowComets );
    setTabOrder( kcfg_ShowComets, kcfg_ShowCometNames );
    setTabOrder( kcfg_ShowCometNames, kcfg_MaxRadCometName );
    setTabOrder( kcfg_MaxRadCometName, kcfg_UseAutoTrail );
    setTabOrder( kcfg_UseAutoTrail, kcfg_FadePlanetTrails );
    setTabOrder( kcfg_FadePlanetTrails, ClearAllTrails );
}

/*
 *  Destroys the object and frees any allocated resources
 */
OpsSolarSystemUI::~OpsSolarSystemUI()
{
    // no need to delete child widgets, TQt does it all for us
}

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void OpsSolarSystemUI::languageChange()
{
    setCaption( tr2i18n( "OpsSolarSystem" ) );
    groupBox2->setTitle( tr2i18n( "Sun, Moon && Planets" ) );
    kcfg_ShowSaturn->setText( tr2i18n( "Saturn" ) );
    TQToolTip::add( kcfg_ShowSaturn, tr2i18n( "Draw Saturn?" ) );
    TQWhatsThis::add( kcfg_ShowSaturn, tr2i18n( "If checked, Saturn will be drawn on the map." ) );
    kcfg_ShowPlanetImages->setText( tr2i18n( "Use images" ) );
    TQToolTip::add( kcfg_ShowPlanetImages, tr2i18n( "Draw major bodies as images?" ) );
    TQWhatsThis::add( kcfg_ShowPlanetImages, tr2i18n( "If checked, then the planets, the Sun and the Moon will be shown as bitmap images on the map" ) );
    kcfg_ShowMars->setText( tr2i18n( "Mars" ) );
    TQToolTip::add( kcfg_ShowMars, tr2i18n( "Draw Mars?" ) );
    TQWhatsThis::add( kcfg_ShowMars, tr2i18n( "If checked, Mars will be drawn on the map." ) );
    kcfg_ShowPlanetNames->setText( tr2i18n( "Use name labels" ) );
    TQToolTip::add( kcfg_ShowPlanetNames, tr2i18n( "Attach Name labels to the major solar system bodies?" ) );
    TQWhatsThis::add( kcfg_ShowPlanetNames, tr2i18n( "If checked, name labels will be attached to the planets, the Sun and the Moon" ) );
    kcfg_ShowPluto->setText( tr2i18n( "Pluto" ) );
    TQToolTip::add( kcfg_ShowPluto, tr2i18n( "Draw Pluto?" ) );
    TQWhatsThis::add( kcfg_ShowPluto, tr2i18n( "If checked, Pluto will be drawn on the map." ) );
    showAllPlanets->setText( tr2i18n( "Select All" ) );
    TQToolTip::add( showAllPlanets, tr2i18n( "Select all major bodies" ) );
    TQWhatsThis::add( showAllPlanets, tr2i18n( "Press this to select all planets, the Sun and the Moon to be drawn in the map" ) );
    showNonePlanets->setText( tr2i18n( "Select None" ) );
    TQToolTip::add( showNonePlanets, tr2i18n( "Unselect all major bodies" ) );
    TQWhatsThis::add( showNonePlanets, tr2i18n( "Press this button to unselect all planets, the Sun and the Moon so that they will not be drawn on the map" ) );
    kcfg_ShowVenus->setText( tr2i18n( "Venus" ) );
    TQToolTip::add( kcfg_ShowVenus, tr2i18n( "Draw Venus?" ) );
    TQWhatsThis::add( kcfg_ShowVenus, tr2i18n( "If checked, Venus will be drawn on the map." ) );
    kcfg_ShowSun->setText( tr2i18n( "The sun" ) );
    TQToolTip::add( kcfg_ShowSun, tr2i18n( "Draw the Sun?" ) );
    TQWhatsThis::add( kcfg_ShowSun, tr2i18n( "If checked, the Sun will be drawn on the map." ) );
    kcfg_ShowJupiter->setText( tr2i18n( "Jupiter" ) );
    TQToolTip::add( kcfg_ShowJupiter, tr2i18n( "Draw Jupiter?" ) );
    TQWhatsThis::add( kcfg_ShowJupiter, tr2i18n( "If checked, Jupiter will be drawn on the map." ) );
    kcfg_ShowMoon->setText( tr2i18n( "The moon" ) );
    TQToolTip::add( kcfg_ShowMoon, tr2i18n( "Draw the Moon?" ) );
    TQWhatsThis::add( kcfg_ShowMoon, tr2i18n( "If checked, the Moon will be drawn on the map." ) );
    kcfg_ShowMercury->setText( tr2i18n( "Mercury" ) );
    TQToolTip::add( kcfg_ShowMercury, tr2i18n( "Draw Mercury?" ) );
    TQWhatsThis::add( kcfg_ShowMercury, tr2i18n( "If checked, Mercury will be drawn on the map." ) );
    kcfg_ShowNeptune->setText( tr2i18n( "Neptune" ) );
    TQToolTip::add( kcfg_ShowNeptune, tr2i18n( "Draw Neptune?" ) );
    TQWhatsThis::add( kcfg_ShowNeptune, tr2i18n( "If checked, Neptune will be drawn on the map." ) );
    kcfg_ShowUranus->setText( tr2i18n( "Uranus" ) );
    TQToolTip::add( kcfg_ShowUranus, tr2i18n( "Draw Uranus?" ) );
    TQWhatsThis::add( kcfg_ShowUranus, tr2i18n( "If checked, Uranus will be drawn on the map." ) );
    groupBox3->setTitle( tr2i18n( "Minor Planets" ) );
    kcfg_ShowComets->setText( tr2i18n( "Comets" ) );
    TQToolTip::add( kcfg_ShowComets, tr2i18n( "Draw comets?" ) );
    TQWhatsThis::add( kcfg_ShowComets, tr2i18n( "If checked, comets will be drawn on the map" ) );
    textLabel3->setText( tr2i18n( "Show asteroids brighter than" ) );
    textLabel5->setText( tr2i18n( "mag" ) );
    textLabel4->setText( tr2i18n( "AU" ) );
    textLabel6->setText( tr2i18n( "mag" ) );
    kcfg_ShowAsteroids->setText( tr2i18n( "Asteroids" ) );
    TQToolTip::add( kcfg_ShowAsteroids, tr2i18n( "Draw asteroids?" ) );
    TQWhatsThis::add( kcfg_ShowAsteroids, tr2i18n( "If checked, asteroids will be drawn on the map" ) );
    kcfg_ShowAsteroidNames->setText( tr2i18n( "Show names of asteroids brighter than" ) );
    TQToolTip::add( kcfg_ShowAsteroidNames, tr2i18n( "Attach names to bright asteroids?" ) );
    TQWhatsThis::add( kcfg_ShowAsteroidNames, tr2i18n( "If checked, then name labels will be attached to bright asteroids" ) );
    TQToolTip::add( kcfg_MaxRadCometName, tr2i18n( "Maximum distance for comet names" ) );
    TQWhatsThis::add( kcfg_MaxRadCometName, tr2i18n( "Set the maximum distance from the Sun for a comet to have a name label, in Astronomical Units (AU).  1 AU is the distance between the Earth and the Sun, approximately 150 million km" ) );
    kcfg_ShowCometNames->setText( tr2i18n( "Show names of comets within" ) );
    TQToolTip::add( kcfg_ShowCometNames, tr2i18n( "Show names of comets near the Sun" ) );
    TQWhatsThis::add( kcfg_ShowCometNames, tr2i18n( "If checked, the comets near the Sun will have name labels attached.  Comets vary in brightness in their orbits, so a faint magnitude is not effective in this case." ) );
    TQToolTip::add( kcfg_MagLimitAsteroid, tr2i18n( "faint limit for asteroids" ) );
    TQWhatsThis::add( kcfg_MagLimitAsteroid, tr2i18n( "Set the faintest magnitude for drawing asteroids" ) );
    TQToolTip::add( kcfg_MagLimitAsteroidName, tr2i18n( "Faint limit for asteroid name labels" ) );
    TQWhatsThis::add( kcfg_MagLimitAsteroidName, tr2i18n( "Set the faint limit for drawing asteroid name labels" ) );
    groupBox4->setTitle( tr2i18n( "Orbital Trails" ) );
    kcfg_UseAutoTrail->setText( tr2i18n( "Always show trail when tracking a solar system body" ) );
    TQToolTip::add( kcfg_UseAutoTrail, tr2i18n( "Auto-trail tracked bodies" ) );
    TQWhatsThis::add( kcfg_UseAutoTrail, tr2i18n( "If checked then any solar system body will have a temporary trail attached while it is centered in the display." ) );
    kcfg_FadePlanetTrails->setText( tr2i18n( "Fade trails to background color" ) );
    TQToolTip::add( kcfg_FadePlanetTrails, tr2i18n( "Fade trail color into the background?" ) );
    TQWhatsThis::add( kcfg_FadePlanetTrails, tr2i18n( "If checked, the color of the planet trail will be blended into the background sky color." ) );
    ClearAllTrails->setText( tr2i18n( "Remove All Trails" ) );
    TQToolTip::add( ClearAllTrails, tr2i18n( "Clear all orbit trails" ) );
    TQWhatsThis::add( ClearAllTrails, tr2i18n( "Press this to clear all orbit trails that you may have attached to solar system bodies using the right-click popup menu." ) );
}

/****************************************************************************
** OpsSolarSystemUI meta object code from reading C++ file 'opssolarsystemui.h'
**
** Created by: The TQt Meta Object Compiler version 26 (TQt 3.5.0)
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#undef TQT_NO_COMPAT
#include "opssolarsystemui.h"
#include <ntqmetaobject.h>
#include <ntqapplication.h>

#include <private/qucomextra_p.h>
#if !defined(Q_MOC_OUTPUT_REVISION) || (Q_MOC_OUTPUT_REVISION != 26)
#error "This file was generated using the moc from 3.5.0. It"
#error "cannot be used with the include files from this version of TQt."
#error "(The moc has changed too much.)"
#endif

const char *OpsSolarSystemUI::className() const
{
    return "OpsSolarSystemUI";
}

TQMetaObject *OpsSolarSystemUI::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_OpsSolarSystemUI( "OpsSolarSystemUI", &OpsSolarSystemUI::staticMetaObject );

#ifndef TQT_NO_TRANSLATION
TQString OpsSolarSystemUI::tr( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "OpsSolarSystemUI", s, c, TQApplication::DefaultCodec );
    else
	return TQString::fromLatin1( s );
}
#ifndef TQT_NO_TRANSLATION_UTF8
TQString OpsSolarSystemUI::trUtf8( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "OpsSolarSystemUI", s, c, TQApplication::UnicodeUTF8 );
    else
	return TQString::fromUtf8( s );
}
#endif // TQT_NO_TRANSLATION_UTF8

#endif // TQT_NO_TRANSLATION

TQMetaObject* OpsSolarSystemUI::staticMetaObject()
{
    if ( metaObj ) {
	return metaObj;
}
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->lock();
    if ( metaObj ) {
	if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
	return metaObj;
    }
#endif // TQT_THREAD_SUPPORT
    TQMetaObject* parentObject = TQWidget::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"OpsSolarSystemUI", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_OpsSolarSystemUI.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

void* OpsSolarSystemUI::tqt_cast( const char* clname )
{
    if ( !qstrcmp( clname, "OpsSolarSystemUI" ) )
	return this;
    return TQWidget::tqt_cast( clname );
}

bool OpsSolarSystemUI::tqt_invoke( int _id, TQUObject* _o )
{
    switch ( _id - staticMetaObject()->slotOffset() ) {
    case 0: languageChange(); break;
    default:
	return TQWidget::tqt_invoke( _id, _o );
    }
    return true;
}

bool OpsSolarSystemUI::tqt_emit( int _id, TQUObject* _o )
{
    return TQWidget::tqt_emit(_id,_o);
}
#ifndef TQT_NO_PROPERTIES

bool OpsSolarSystemUI::tqt_property( int id, int f, TQVariant* v)
{
    return TQWidget::tqt_property( id, f, v);
}

bool OpsSolarSystemUI::tqt_static_property( TQObject* , int , int , TQVariant* ){ return false; }
#endif // TQT_NO_PROPERTIES
