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

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

#include "ArtQueryDlgForm.h"

#include <ntqvariant.h>
#include <kprogress.h>
#include <ntqpushbutton.h>
#include <ntqlabel.h>
#include <ntqbuttongroup.h>
#include <ntqradiobutton.h>
#include <ntqgroupbox.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a ArtQueryDlgForm as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
ArtQueryDlgForm::ArtQueryDlgForm( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "ArtQueryDlgForm" );
    setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)3, (TQSizePolicy::SizeType)1, 0, 0, sizePolicy().hasHeightForWidth() ) );
    ArtQueryDlgFormLayout = new TQGridLayout( this, 1, 1, 0, 6, "ArtQueryDlgFormLayout"); 

    TextLabel1 = new TQLabel( this, "TextLabel1" );
    TQFont TextLabel1_font(  TextLabel1->font() );
    TextLabel1_font.setBold( true );
    TextLabel1->setFont( TextLabel1_font ); 

    ArtQueryDlgFormLayout->addWidget( TextLabel1, 0, 0 );

    orgField = new TQLabel( this, "orgField" );
    orgField->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)1, 0, 0, orgField->sizePolicy().hasHeightForWidth() ) );
    orgField->setFrameShape( TQLabel::GroupBoxPanel );
    orgField->setFrameShadow( TQLabel::Plain );

    ArtQueryDlgFormLayout->addWidget( orgField, 1, 0 );

    artGroup = new TQButtonGroup( this, "artGroup" );
    artGroup->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, artGroup->sizePolicy().hasHeightForWidth() ) );
    artGroup->setFrameShape( TQButtonGroup::NoFrame );
    artGroup->setColumnLayout(0, TQt::Vertical );
    artGroup->layout()->setSpacing( 6 );
    artGroup->layout()->setMargin( 0 );
    artGroupLayout = new TQGridLayout( artGroup->layout() );
    artGroupLayout->setAlignment( TQt::AlignTop );

    rb_fem = new TQRadioButton( artGroup, "rb_fem" );

    artGroupLayout->addWidget( rb_fem, 0, 0 );

    male = new TQRadioButton( artGroup, "male" );

    artGroupLayout->addWidget( male, 1, 0 );

    natural = new TQRadioButton( artGroup, "natural" );

    artGroupLayout->addWidget( natural, 2, 0 );

    ArtQueryDlgFormLayout->addWidget( artGroup, 2, 0 );

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

    progressgroup = new TQGroupBox( this, "progressgroup" );
    progressgroup->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, progressgroup->sizePolicy().hasHeightForWidth() ) );
    progressgroup->setColumnLayout(0, TQt::Vertical );
    progressgroup->layout()->setSpacing( 6 );
    progressgroup->layout()->setMargin( 11 );
    progressgroupLayout = new TQGridLayout( progressgroup->layout() );
    progressgroupLayout->setAlignment( TQt::AlignTop );

    countbar = new KProgress( progressgroup, "countbar" );

    progressgroupLayout->addWidget( countbar, 0, 1 );

    timebar = new KProgress( progressgroup, "timebar" );

    progressgroupLayout->addWidget( timebar, 1, 1 );

    countlabel = new TQLabel( progressgroup, "countlabel" );
    countlabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, countlabel->sizePolicy().hasHeightForWidth() ) );

    progressgroupLayout->addWidget( countlabel, 0, 0 );

    timelabel = new TQLabel( progressgroup, "timelabel" );
    timelabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, timelabel->sizePolicy().hasHeightForWidth() ) );

    progressgroupLayout->addWidget( timelabel, 1, 0 );

    Cyclelabel = new TQLabel( progressgroup, "Cyclelabel" );
    Cyclelabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, Cyclelabel->sizePolicy().hasHeightForWidth() ) );
    Cyclelabel->setFrameShape( TQLabel::NoFrame );

    progressgroupLayout->addWidget( Cyclelabel, 2, 0 );

    progCount = new TQLabel( progressgroup, "progCount" );
    progCount->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)1, 0, 0, progCount->sizePolicy().hasHeightForWidth() ) );

    progressgroupLayout->addWidget( progCount, 2, 1 );

    layout10->addMultiCellWidget( progressgroup, 0, 1, 1, 1 );

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

    verify = new TQPushButton( this, "verify" );
    verify->setEnabled( false );
    verify->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, verify->sizePolicy().hasHeightForWidth() ) );

    layout9->addWidget( verify, 1, 0 );

    know_it = new TQPushButton( this, "know_it" );
    know_it->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, know_it->sizePolicy().hasHeightForWidth() ) );

    layout9->addWidget( know_it, 0, 1 );

    show_all = new TQPushButton( this, "show_all" );
    show_all->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, show_all->sizePolicy().hasHeightForWidth() ) );

    layout9->addWidget( show_all, 0, 0 );

    dont_know = new TQPushButton( this, "dont_know" );
    dont_know->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)1, 0, 0, dont_know->sizePolicy().hasHeightForWidth() ) );

    layout9->addWidget( dont_know, 1, 1 );

    layout10->addLayout( layout9, 0, 0 );

    status = new TQLabel( this, "status" );
    status->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)1, 0, 0, status->sizePolicy().hasHeightForWidth() ) );
    status->setFrameShape( TQLabel::GroupBoxPanel );
    status->setFrameShadow( TQLabel::Plain );

    layout10->addWidget( status, 1, 0 );

    ArtQueryDlgFormLayout->addLayout( layout10, 3, 0 );
    languageChange();
    resize( TQSize(369, 240).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( rb_fem, male );
    setTabOrder( male, natural );
    setTabOrder( natural, show_all );
    setTabOrder( show_all, verify );
    setTabOrder( verify, know_it );
    setTabOrder( know_it, dont_know );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void ArtQueryDlgForm::languageChange()
{
    TextLabel1->setText( tr2i18n( "Select the correct article for this noun:" ) );
    orgField->setText( TQString::null );
    artGroup->setTitle( TQString::null );
    rb_fem->setText( tr2i18n( "&female" ) );
    male->setText( tr2i18n( "&male" ) );
    natural->setText( tr2i18n( "&neutral" ) );
    progressgroup->setTitle( tr2i18n( "Progress" ) );
    countlabel->setText( tr2i18n( "Count:" ) );
    timelabel->setText( tr2i18n( "Time:" ) );
    Cyclelabel->setText( tr2i18n( "Cycle:" ) );
    verify->setText( tr2i18n( "&Verify" ) );
    know_it->setText( tr2i18n( "I &Know It" ) );
    show_all->setText( tr2i18n( "Show &All" ) );
    dont_know->setText( tr2i18n( "&Do Not Know" ) );
    status->setText( TQString::null );
}

/****************************************************************************
** ArtQueryDlgForm meta object code from reading C++ file 'ArtQueryDlgForm.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 "ArtQueryDlgForm.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 *ArtQueryDlgForm::className() const
{
    return "ArtQueryDlgForm";
}

TQMetaObject *ArtQueryDlgForm::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_ArtQueryDlgForm( "ArtQueryDlgForm", &ArtQueryDlgForm::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* ArtQueryDlgForm::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(
	"ArtQueryDlgForm", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_ArtQueryDlgForm.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

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

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

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

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