#include <kdialog.h>
#include <klocale.h>
/****************************************************************************
** Form implementation generated from reading ui file '/usr/src/ports/kdegames3/kdegames3-3.5.10-11.i686/src/kdegames-3.5.10/ksnake/general.ui'
**
** Created by User Interface Compiler
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "general.h"

#include <qvariant.h>
#include <qpushbutton.h>
#include <qgroupbox.h>
#include <qslider.h>
#include <qlabel.h>
#include <qcombobox.h>
#include <qspinbox.h>
#include <qlayout.h>
#include <qtooltip.h>
#include <qwhatsthis.h>

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

    groupBox4 = new QGroupBox( this, "groupBox4" );
    groupBox4->setColumnLayout(0, Qt::Vertical );
    groupBox4->layout()->setSpacing( 6 );
    groupBox4->layout()->setMargin( 11 );
    groupBox4Layout = new QGridLayout( groupBox4->layout() );
    groupBox4Layout->setAlignment( Qt::AlignTop );

    kcfg_Skill = new QSlider( groupBox4, "kcfg_Skill" );
    kcfg_Skill->setMaxValue( 3 );
    kcfg_Skill->setPageStep( 1 );
    kcfg_Skill->setOrientation( QSlider::Horizontal );
    kcfg_Skill->setTickmarks( QSlider::Below );

    groupBox4Layout->addMultiCellWidget( kcfg_Skill, 0, 0, 0, 1 );

    textLabel10 = new QLabel( groupBox4, "textLabel10" );

    groupBox4Layout->addWidget( textLabel10, 1, 0 );

    textLabel12 = new QLabel( groupBox4, "textLabel12" );
    textLabel12->setAlignment( int( QLabel::AlignVCenter | QLabel::AlignRight ) );

    groupBox4Layout->addWidget( textLabel12, 1, 1 );
    GeneralLayout->addWidget( groupBox4 );

    groupBox6 = new QGroupBox( this, "groupBox6" );
    groupBox6->setColumnLayout(0, Qt::Vertical );
    groupBox6->layout()->setSpacing( 6 );
    groupBox6->layout()->setMargin( 11 );
    groupBox6Layout = new QGridLayout( groupBox6->layout() );
    groupBox6Layout->setAlignment( Qt::AlignTop );

    textLabel7 = new QLabel( groupBox6, "textLabel7" );

    groupBox6Layout->addWidget( textLabel7, 1, 0 );

    kcfg_SnakesAI = new QComboBox( FALSE, groupBox6, "kcfg_SnakesAI" );

    groupBox6Layout->addWidget( kcfg_SnakesAI, 1, 1 );

    kcfg_ComputerSnakes = new QSpinBox( groupBox6, "kcfg_ComputerSnakes" );
    kcfg_ComputerSnakes->setValue( 1 );

    groupBox6Layout->addWidget( kcfg_ComputerSnakes, 0, 1 );

    textLabel8 = new QLabel( groupBox6, "textLabel8" );

    groupBox6Layout->addWidget( textLabel8, 0, 0 );
    GeneralLayout->addWidget( groupBox6 );

    groupBox5 = new QGroupBox( this, "groupBox5" );
    groupBox5->setColumnLayout(0, Qt::Vertical );
    groupBox5->layout()->setSpacing( 6 );
    groupBox5->layout()->setMargin( 11 );
    groupBox5Layout = new QGridLayout( groupBox5->layout() );
    groupBox5Layout->setAlignment( Qt::AlignTop );

    textLabel9 = new QLabel( groupBox5, "textLabel9" );

    groupBox5Layout->addWidget( textLabel9, 0, 0 );

    kcfg_Balls = new QSpinBox( groupBox5, "kcfg_Balls" );
    kcfg_Balls->setValue( 1 );

    groupBox5Layout->addWidget( kcfg_Balls, 0, 1 );

    kcfg_BallsAI = new QComboBox( FALSE, groupBox5, "kcfg_BallsAI" );

    groupBox5Layout->addWidget( kcfg_BallsAI, 1, 1 );

    textLabel13 = new QLabel( groupBox5, "textLabel13" );

    groupBox5Layout->addWidget( textLabel13, 1, 0 );
    GeneralLayout->addWidget( groupBox5 );
    spacer1 = new QSpacerItem( 20, 70, QSizePolicy::Minimum, QSizePolicy::Expanding );
    GeneralLayout->addItem( spacer1 );
    languageChange();
    resize( QSize(333, 409).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void General::languageChange()
{
    groupBox4->setTitle( tr2i18n( "Speed" ) );
    textLabel10->setText( tr2i18n( "Slow" ) );
    textLabel12->setText( tr2i18n( "Fast" ) );
    groupBox6->setTitle( tr2i18n( "Snakes" ) );
    textLabel7->setText( tr2i18n( "Snake behavior:" ) );
    kcfg_SnakesAI->clear();
    kcfg_SnakesAI->insertItem( tr2i18n( "Random" ) );
    kcfg_SnakesAI->insertItem( tr2i18n( "Eater" ) );
    kcfg_SnakesAI->insertItem( tr2i18n( "Killer" ) );
    textLabel8->setText( tr2i18n( "Number of snakes:" ) );
    groupBox5->setTitle( tr2i18n( "Balls" ) );
    textLabel9->setText( tr2i18n( "Number of balls:" ) );
    kcfg_BallsAI->clear();
    kcfg_BallsAI->insertItem( tr2i18n( "Dumb" ) );
    kcfg_BallsAI->insertItem( tr2i18n( "Average" ) );
    kcfg_BallsAI->insertItem( tr2i18n( "Killer" ) );
    textLabel13->setText( tr2i18n( "Ball behavior:" ) );
}

#include "general.moc"
