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

#include "UiGuiSettingsDialogBase.h"

#include <ntqvariant.h>
#include <ntqpushbutton.h>
#include <ntqtabwidget.h>
#include <ntqwidget.h>
#include <ntqlabel.h>
#include <ntqcombobox.h>
#include <ntqcheckbox.h>
#include <ntqspinbox.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a UiGuiSettingsDialogBase as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 *
 *  The qdialog will by default be modeless, unless you set 'modal' to
 *  true to construct a modal qdialog.
 */
UiGuiSettingsDialogBase::UiGuiSettingsDialogBase( TQWidget* parent, const char* name, bool modal, WFlags fl )
    : TQDialog( parent, name, modal, fl )
{
    if ( !name )
	setName( "UiGuiSettingsDialogBase" );
    UiGuiSettingsDialogBaseLayout = new TQVBoxLayout( this, 11, 6, "UiGuiSettingsDialogBaseLayout"); 

    tabWidget = new TQTabWidget( this, "tabWidget" );
    tabWidget->setCurrentPage( 0 );

    tabCommon = new TQWidget( tabWidget, "tabCommon" );
    tabCommonLayout = new TQVBoxLayout( tabCommon, 11, 6, "tabCommonLayout"); 
    hbox = new TQHBoxLayout( 0, 0, 6, "hbox"); 

    languageLabel = new TQLabel( tabCommon, "languageLabel" );
    hbox->addWidget( languageLabel );

    cmbBoxLanguageSelection = new TQComboBox( false, tabCommon, "cmbBoxLanguageSelection" );
    cmbBoxLanguageSelection->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, cmbBoxLanguageSelection->sizePolicy().hasHeightForWidth() ) );
    hbox->addWidget( cmbBoxLanguageSelection );
    spacer8 = new TQSpacerItem( 20, 40, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    hbox->addItem( spacer8 );
    tabCommonLayout->addLayout( hbox );

    cbLoadLastOpenedFileOnStartup = new TQCheckBox( tabCommon, "cbLoadLastOpenedFileOnStartup" );
    tabCommonLayout->addWidget( cbLoadLastOpenedFileOnStartup );

    cbEnableIndenterParameterTooltips = new TQCheckBox( tabCommon, "cbEnableIndenterParameterTooltips" );
    tabCommonLayout->addWidget( cbEnableIndenterParameterTooltips );
    hbox_2 = new TQHBoxLayout( 0, 0, 6, "hbox_2"); 

    labelRecentlyOpenedListSize = new TQLabel( tabCommon, "labelRecentlyOpenedListSize" );
    hbox_2->addWidget( labelRecentlyOpenedListSize );

    sbRecentlyOpenedListSize = new TQSpinBox( tabCommon, "sbRecentlyOpenedListSize" );
    sbRecentlyOpenedListSize->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, sbRecentlyOpenedListSize->sizePolicy().hasHeightForWidth() ) );
    sbRecentlyOpenedListSize->setMaxValue( 30 );
    sbRecentlyOpenedListSize->setMinValue( 1 );
    hbox_2->addWidget( sbRecentlyOpenedListSize );
    spacer7 = new TQSpacerItem( 20, 40, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    hbox_2->addItem( spacer7 );
    tabCommonLayout->addLayout( hbox_2 );
    spacer6 = new TQSpacerItem( 20, 40, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    tabCommonLayout->addItem( spacer6 );
    tabWidget->insertTab( tabCommon, TQString::fromLatin1("") );

    tabEditor = new TQWidget( tabWidget, "tabEditor" );
    tabEditorLayout = new TQVBoxLayout( tabEditor, 11, 6, "tabEditorLayout"); 

    cbWhiteSpaceIsVisible = new TQCheckBox( tabEditor, "cbWhiteSpaceIsVisible" );
    tabEditorLayout->addWidget( cbWhiteSpaceIsVisible );
    hbox_3 = new TQHBoxLayout( 0, 0, 6, "hbox_3"); 

    labelTabWidth = new TQLabel( tabEditor, "labelTabWidth" );
    hbox_3->addWidget( labelTabWidth );

    sbTabWidth = new TQSpinBox( tabEditor, "sbTabWidth" );
    sbTabWidth->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, sbTabWidth->sizePolicy().hasHeightForWidth() ) );
    sbTabWidth->setMaxValue( 99 );
    sbTabWidth->setMinValue( 1 );
    hbox_3->addWidget( sbTabWidth );
    spacer5 = new TQSpacerItem( 20, 40, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    hbox_3->addItem( spacer5 );
    tabEditorLayout->addLayout( hbox_3 );
    spacer4 = new TQSpacerItem( 20, 40, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    tabEditorLayout->addItem( spacer4 );
    tabWidget->insertTab( tabEditor, TQString::fromLatin1("") );

    tabSyntaxHighlight = new TQWidget( tabWidget, "tabSyntaxHighlight" );
    tabSyntaxHighlightLayout = new TQVBoxLayout( tabSyntaxHighlight, 11, 6, "tabSyntaxHighlightLayout"); 

    cbEnableSyntaxHL = new TQCheckBox( tabSyntaxHighlight, "cbEnableSyntaxHL" );
    tabSyntaxHighlightLayout->addWidget( cbEnableSyntaxHL );
    spacer2 = new TQSpacerItem( 20, 40, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    tabSyntaxHighlightLayout->addItem( spacer2 );
    tabWidget->insertTab( tabSyntaxHighlight, TQString::fromLatin1("") );
    UiGuiSettingsDialogBaseLayout->addWidget( tabWidget );
    hbox_4 = new TQHBoxLayout( 0, 0, 6, "hbox_4"); 
    spacer1 = new TQSpacerItem( 40, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    hbox_4->addItem( spacer1 );

    okButton = new TQPushButton( this, "okButton" );
    okButton->setDefault( true );
    hbox_4->addWidget( okButton );

    cancelButton = new TQPushButton( this, "cancelButton" );
    hbox_4->addWidget( cancelButton );
    UiGuiSettingsDialogBaseLayout->addLayout( hbox_4 );
    languageChange();
    resize( TQSize(503, 336).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( okButton, TQ_SIGNAL( clicked() ), this, TQ_SLOT( accept() ) );
    connect( cancelButton, TQ_SIGNAL( clicked() ), this, TQ_SLOT( reject() ) );

    // buddies
    languageLabel->setBuddy( cmbBoxLanguageSelection );
    labelRecentlyOpenedListSize->setBuddy( sbRecentlyOpenedListSize );
    labelTabWidth->setBuddy( sbTabWidth );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void UiGuiSettingsDialogBase::languageChange()
{
    setCaption( tr( "Settings" ) );
    languageLabel->setText( tr( "Application language" ) );
    TQWhatsThis::add( languageLabel, tr( "Choose UniversalIndentGui language." ) );
    TQWhatsThis::add( cmbBoxLanguageSelection, tr( "Choose UniversalIndentGui language." ) );
    cbLoadLastOpenedFileOnStartup->setText( tr( "Automatically open last file on startup" ) );
    TQWhatsThis::add( cbLoadLastOpenedFileOnStartup, tr( "If checked, reopen the last used source code file on startup." ) );
    cbEnableIndenterParameterTooltips->setText( tr( "Enable Parameter Tooltips" ) );
    TQWhatsThis::add( cbEnableIndenterParameterTooltips, tr( "If checked, tool tips will show up for the indenter parameters." ) );
    labelRecentlyOpenedListSize->setText( tr( "Number of files in recently opened list" ) );
    TQWhatsThis::add( labelRecentlyOpenedListSize, tr( "Sets number of files in the list of recently opened files." ) );
    TQWhatsThis::add( sbRecentlyOpenedListSize, tr( "Sets number of files in the list of recently opened files." ) );
    tabWidget->changeTab( tabCommon, tr( "Common" ) );
    cbWhiteSpaceIsVisible->setText( tr( "Display white space character (tabs, spaces, etc.)" ) );
    TQWhatsThis::add( cbWhiteSpaceIsVisible, tr( "Enables or disables displaying of white space characters in the editor." ) );
    labelTabWidth->setText( tr( "Displayed width of tabs" ) );
    TQWhatsThis::add( labelTabWidth, tr( "Defines how many spaces should be displayed in the editor for one tab." ) );
    TQWhatsThis::add( sbTabWidth, tr( "Defines how many spaces should be displayed in the editor for one tab." ) );
    tabWidget->changeTab( tabEditor, tr( "Editor" ) );
    cbEnableSyntaxHL->setText( tr( "Enable syntax highlighting" ) );
    TQWhatsThis::add( cbEnableSyntaxHL, tr( "By enabling special key words of the source code are highlighted." ) );
    tabWidget->changeTab( tabSyntaxHighlight, tr( "Syntax Highlighting" ) );
    okButton->setText( tr( "&Ok" ) );
    cancelButton->setText( tr( "&Cancel" ) );
}

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

TQMetaObject *UiGuiSettingsDialogBase::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_UiGuiSettingsDialogBase( "UiGuiSettingsDialogBase", &UiGuiSettingsDialogBase::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* UiGuiSettingsDialogBase::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 = TQDialog::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"UiGuiSettingsDialogBase", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_UiGuiSettingsDialogBase.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

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

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

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

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