00001 #include <kdialog.h>
00002 #include <klocale.h>
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #include "docprojectconfigwidgetbase.h"
00013
00014 #include <qvariant.h>
00015 #include <qpushbutton.h>
00016 #include <qgroupbox.h>
00017 #include <kurlrequester.h>
00018 #include <qlabel.h>
00019 #include <qcombobox.h>
00020 #include <qlayout.h>
00021 #include <qtooltip.h>
00022 #include <qwhatsthis.h>
00023
00024
00025
00026
00027
00028 DocProjectConfigWidgetBase::DocProjectConfigWidgetBase( QWidget* parent, const char* name, WFlags fl )
00029 : QWidget( parent, name, fl )
00030 {
00031 if ( !name )
00032 setName( "DocProjectConfigWidgetBase" );
00033 DocProjectConfigWidgetBaseLayout = new QGridLayout( this, 1, 1, 11, 6, "DocProjectConfigWidgetBaseLayout");
00034 spacer1 = new QSpacerItem( 20, 60, QSizePolicy::Minimum, QSizePolicy::Expanding );
00035 DocProjectConfigWidgetBaseLayout->addItem( spacer1, 2, 0 );
00036
00037 groupBox1 = new QGroupBox( this, "groupBox1" );
00038 groupBox1->setColumnLayout(0, Qt::Vertical );
00039 groupBox1->layout()->setSpacing( 6 );
00040 groupBox1->layout()->setMargin( 11 );
00041 groupBox1Layout = new QGridLayout( groupBox1->layout() );
00042 groupBox1Layout->setAlignment( Qt::AlignTop );
00043
00044 catalogURL = new KURLRequester( groupBox1, "catalogURL" );
00045 catalogURL->setEnabled( FALSE );
00046
00047 groupBox1Layout->addMultiCellWidget( catalogURL, 2, 2, 0, 1 );
00048
00049 textLabel2 = new QLabel( groupBox1, "textLabel2" );
00050
00051 groupBox1Layout->addMultiCellWidget( textLabel2, 1, 1, 0, 1 );
00052
00053 textLabel1 = new QLabel( groupBox1, "textLabel1" );
00054 textLabel1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)4, (QSizePolicy::SizeType)5, 0, 0, textLabel1->sizePolicy().hasHeightForWidth() ) );
00055 textLabel1->setFrameShape( QLabel::NoFrame );
00056 textLabel1->setFrameShadow( QLabel::Plain );
00057
00058 groupBox1Layout->addWidget( textLabel1, 0, 0 );
00059
00060 docSystemCombo = new QComboBox( FALSE, groupBox1, "docSystemCombo" );
00061
00062 groupBox1Layout->addWidget( docSystemCombo, 0, 1 );
00063
00064 DocProjectConfigWidgetBaseLayout->addWidget( groupBox1, 0, 0 );
00065
00066 groupBox2 = new QGroupBox( this, "groupBox2" );
00067 groupBox2->setColumnLayout(0, Qt::Vertical );
00068 groupBox2->layout()->setSpacing( 6 );
00069 groupBox2->layout()->setMargin( 11 );
00070 groupBox2Layout = new QGridLayout( groupBox2->layout() );
00071 groupBox2Layout->setAlignment( Qt::AlignTop );
00072
00073 textLabel1_2 = new QLabel( groupBox2, "textLabel1_2" );
00074
00075 groupBox2Layout->addWidget( textLabel1_2, 0, 0 );
00076
00077 manualURL = new KURLRequester( groupBox2, "manualURL" );
00078
00079 groupBox2Layout->addWidget( manualURL, 1, 0 );
00080
00081 DocProjectConfigWidgetBaseLayout->addWidget( groupBox2, 1, 0 );
00082 languageChange();
00083 resize( QSize(484, 292).expandedTo(minimumSizeHint()) );
00084 clearWState( WState_Polished );
00085
00086
00087 connect( docSystemCombo, SIGNAL( activated(const QString&) ), this, SLOT( changeDocSystem(const QString&) ) );
00088
00089
00090 setTabOrder( catalogURL, docSystemCombo );
00091
00092
00093 textLabel2->setBuddy( catalogURL );
00094 textLabel1->setBuddy( docSystemCombo );
00095 textLabel1_2->setBuddy( manualURL );
00096 }
00097
00098
00099
00100
00101 DocProjectConfigWidgetBase::~DocProjectConfigWidgetBase()
00102 {
00103
00104 }
00105
00106
00107
00108
00109
00110 void DocProjectConfigWidgetBase::languageChange()
00111 {
00112 groupBox1->setTitle( tr2i18n( "Project API Documentation" ) );
00113 textLabel2->setText( tr2i18n( "Ca&talog location:" ) );
00114 textLabel1->setText( tr2i18n( "C&ollection type:" ) );
00115 groupBox2->setTitle( tr2i18n( "Project User Manual" ) );
00116 textLabel1_2->setText( tr2i18n( "&Location:" ) );
00117 }
00118
00119 void DocProjectConfigWidgetBase::changeDocSystem(const QString&)
00120 {
00121 qWarning( "DocProjectConfigWidgetBase::changeDocSystem(const QString&): Not implemented yet" );
00122 }
00123
00124 #include "docprojectconfigwidgetbase.moc"