diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
commit | 47c8a359c5276062c4bc17f0e82410f29081b502 (patch) | |
tree | 2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kdict/options.cpp | |
parent | 6f82532777a35e0e60bbd2b290b2e93e646f349b (diff) | |
download | tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdict/options.cpp')
-rw-r--r-- | kdict/options.cpp | 254 |
1 files changed, 127 insertions, 127 deletions
diff --git a/kdict/options.cpp b/kdict/options.cpp index a157fbf5..3220b07c 100644 --- a/kdict/options.cpp +++ b/kdict/options.cpp @@ -17,14 +17,14 @@ ------------------------------------------------------------- */ -#include <qcheckbox.h> -#include <qpushbutton.h> -#include <qradiobutton.h> -#include <qlayout.h> -#include <qlabel.h> -#include <qcombobox.h> -#include <qbuttongroup.h> -#include <qpainter.h> +#include <tqcheckbox.h> +#include <tqpushbutton.h> +#include <tqradiobutton.h> +#include <tqlayout.h> +#include <tqlabel.h> +#include <tqcombobox.h> +#include <tqbuttongroup.h> +#include <tqpainter.h> #include <kcolordialog.h> #include <kconfig.h> @@ -67,7 +67,7 @@ void GlobalData::read() config->setGroup("Colors"); useCustomColors=config->readBoolEntry("customColors", false); - QColor defCol=KGlobalSettings::textColor(); + TQColor defCol=KGlobalSettings::textColor(); c_olors[Ctext]=config->readColorEntry("textColor",&defCol); c_olorNames[Ctext]=i18n("Text"); @@ -95,7 +95,7 @@ void GlobalData::read() config->setGroup("Fonts"); useCustomFonts=config->readBoolEntry("customFonts", false); - QFont defFont=KGlobalSettings::generalFont(); + TQFont defFont=KGlobalSettings::generalFont(); f_onts[Ftext]=config->readFontEntry("textFont",&defFont); f_ontNames[Ftext]=i18n("Text"); @@ -106,7 +106,7 @@ void GlobalData::read() // geometry... config->setGroup("Geometry"); - QSize invalid(-1,-1); + TQSize invalid(-1,-1); optSize = config->readSizeEntry("Opt_Size",&invalid); setsSize = config->readSizeEntry("Sets_Size",&invalid); matchSize = config->readSizeEntry("Match_Size",&invalid); @@ -157,10 +157,10 @@ void GlobalData::read() config->setGroup("Database_Sets"); databaseSets.setAutoDelete(true); int num = config->readNumEntry("Num_Sets",0); - QStringList* temp; - QString strNum; + TQStringList* temp; + TQString strNum; while (num > 0) { - temp = new QStringList(); + temp = new TQStringList(); strNum.setNum(num); *temp = config->readListEntry(strNum); if (!temp->isEmpty()) { @@ -217,7 +217,7 @@ void GlobalData::write() config->writeEntry("Completion_mode", (int)queryComboCompletionMode); config->setGroup("Query_History"); - QStringList copy; + TQStringList copy; if (saveHistory) copy = queryHistory; config->writeEntry("History",copy); @@ -239,13 +239,13 @@ void GlobalData::write() config->setGroup("Database_Sets"); config->writeEntry("Num_Sets",databaseSets.count()); - QString strNum; + TQString strNum; for (unsigned int i = 0;i<databaseSets.count();i++) config->writeEntry(strNum.setNum(i+1),*databaseSets.at(i)); } -QColor GlobalData::defaultColor(int i) +TQColor GlobalData::defaultColor(int i) { switch(i) { case Ctext: @@ -278,7 +278,7 @@ QColor GlobalData::defaultColor(int i) } -QColor GlobalData::textColor() +TQColor GlobalData::textColor() { if(useCustomColors) return c_olors[Ctext]; @@ -287,7 +287,7 @@ QColor GlobalData::textColor() } -QColor GlobalData::backgroundColor() +TQColor GlobalData::backgroundColor() { if(useCustomColors) return c_olors[Cbackground]; @@ -296,7 +296,7 @@ QColor GlobalData::backgroundColor() } -QColor GlobalData::headingsTextColor() +TQColor GlobalData::headingsTextColor() { if(useCustomColors) return c_olors[CheadingsText]; @@ -305,7 +305,7 @@ QColor GlobalData::headingsTextColor() } -QColor GlobalData::headingsBackgroundColor() +TQColor GlobalData::headingsBackgroundColor() { if(useCustomColors) return c_olors[CheadingsBackground]; @@ -314,7 +314,7 @@ QColor GlobalData::headingsBackgroundColor() } -QColor GlobalData::linksColor() +TQColor GlobalData::linksColor() { if(useCustomColors) return c_olors[Clinks]; @@ -323,7 +323,7 @@ QColor GlobalData::linksColor() } -QColor GlobalData::visitedLinksColor() +TQColor GlobalData::visitedLinksColor() { if(useCustomColors) return c_olors[CvisitedLinks]; @@ -332,9 +332,9 @@ QColor GlobalData::visitedLinksColor() } -QFont GlobalData::defaultFont(int i) +TQFont GlobalData::defaultFont(int i) { - QFont font = KGlobalSettings::generalFont(); + TQFont font = KGlobalSettings::generalFont(); if (font.pointSize() < 5) font.setPointSize(12); @@ -346,7 +346,7 @@ QFont GlobalData::defaultFont(int i) } -QFont GlobalData::textFont() +TQFont GlobalData::textFont() { if(useCustomFonts) return f_onts[Ftext]; @@ -355,7 +355,7 @@ QFont GlobalData::textFont() } -QFont GlobalData::headingsFont() +TQFont GlobalData::headingsFont() { if(useCustomFonts) return f_onts[Fheadings]; @@ -365,10 +365,10 @@ QFont GlobalData::headingsFont() // simple password scrambling... -QString GlobalData::encryptStr(const QString& aStr) +TQString GlobalData::encryptStr(const TQString& aStr) { uint i,val,len = aStr.length(); - QString result; + TQString result; for (i=0; i<len; i++) { @@ -384,8 +384,8 @@ QString GlobalData::encryptStr(const QString& aStr) //********* OptionsDialog::DialogListBox ***************************** -OptionsDialog::DialogListBox::DialogListBox(bool alwaysIgnore, QWidget * parent, const char * name) - : QListBox(parent, name), a_lwaysIgnore(alwaysIgnore) +OptionsDialog::DialogListBox::DialogListBox(bool alwaysIgnore, TQWidget * parent, const char * name) + : TQListBox(parent, name), a_lwaysIgnore(alwaysIgnore) { } @@ -395,20 +395,20 @@ OptionsDialog::DialogListBox::~DialogListBox() } -void OptionsDialog::DialogListBox::keyPressEvent(QKeyEvent *e) +void OptionsDialog::DialogListBox::keyPressEvent(TQKeyEvent *e) { if ((a_lwaysIgnore || !(hasFocus()&&isVisible()))&&((e->key()==Key_Enter)||(e->key()==Key_Return))) e->ignore(); else - QListBox::keyPressEvent(e); + TQListBox::keyPressEvent(e); } //********* OptionsDialog::ColorListItem ***************************** -OptionsDialog::ColorListItem::ColorListItem( const QString &text, const QColor &color ) - : QListBoxText(text), mColor( color ) +OptionsDialog::ColorListItem::ColorListItem( const TQString &text, const TQColor &color ) + : TQListBoxText(text), mColor( color ) { } @@ -418,9 +418,9 @@ OptionsDialog::ColorListItem::~ColorListItem() } -void OptionsDialog::ColorListItem::paint( QPainter *p ) +void OptionsDialog::ColorListItem::paint( TQPainter *p ) { - QFontMetrics fm = p->fontMetrics(); + TQFontMetrics fm = p->fontMetrics(); int h = fm.height(); p->drawText( 30+3*2, fm.ascent() + fm.leading()/2, text() ); @@ -431,13 +431,13 @@ void OptionsDialog::ColorListItem::paint( QPainter *p ) } -int OptionsDialog::ColorListItem::height(const QListBox *lb ) const +int OptionsDialog::ColorListItem::height(const TQListBox *lb ) const { return( lb->fontMetrics().lineSpacing()+1 ); } -int OptionsDialog::ColorListItem::width(const QListBox *lb ) const +int OptionsDialog::ColorListItem::width(const TQListBox *lb ) const { return( 30 + lb->fontMetrics().width( text() ) + 6 ); } @@ -446,10 +446,10 @@ int OptionsDialog::ColorListItem::width(const QListBox *lb ) const //********* OptionsDialog::FontListItem ***************************** -OptionsDialog::FontListItem::FontListItem( const QString &name, const QFont &font ) - : QListBoxText(name), f_ont(font) +OptionsDialog::FontListItem::FontListItem( const TQString &name, const TQFont &font ) + : TQListBoxText(name), f_ont(font) { - fontInfo = QString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); + fontInfo = TQString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); } @@ -458,28 +458,28 @@ OptionsDialog::FontListItem::~FontListItem() } -void OptionsDialog::FontListItem::setFont(const QFont &font) +void OptionsDialog::FontListItem::setFont(const TQFont &font) { f_ont = font; - fontInfo = QString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); + fontInfo = TQString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); } -void OptionsDialog::FontListItem::paint( QPainter *p ) +void OptionsDialog::FontListItem::paint( TQPainter *p ) { - QFont fnt = p->font(); - fnt.setWeight(QFont::Bold); + TQFont fnt = p->font(); + fnt.setWeight(TQFont::Bold); p->setFont(fnt); int fontInfoWidth = p->fontMetrics().width(fontInfo); int h = p->fontMetrics().ascent() + p->fontMetrics().leading()/2; p->drawText(2, h, fontInfo ); - fnt.setWeight(QFont::Normal); + fnt.setWeight(TQFont::Normal); p->setFont(fnt); p->drawText(5 + fontInfoWidth, h, text() ); } -int OptionsDialog::FontListItem::width(const QListBox *lb ) const +int OptionsDialog::FontListItem::width(const TQListBox *lb ) const { return( lb->fontMetrics().width(fontInfo) + lb->fontMetrics().width(text()) + 20 ); } @@ -488,90 +488,90 @@ int OptionsDialog::FontListItem::width(const QListBox *lb ) const //********* OptionsDialog ****************************************** -OptionsDialog::OptionsDialog(QWidget *parent, const char *name) +OptionsDialog::OptionsDialog(TQWidget *parent, const char *name) : KDialogBase(IconList, i18n("Configure"), Help|Default|Ok|Apply|Cancel, Ok, parent, name, false, true) { //******** Server ************************************ serverTab = addPage(i18n("Server"),i18n("DICT Server Configuration"), BarIcon("network", KIcon::SizeMedium )); - QGridLayout* grid = new QGridLayout(serverTab,10,3,0,spacingHint()); + TQGridLayout* grid = new TQGridLayout(serverTab,10,3,0,spacingHint()); w_server = new KLineEdit(serverTab); w_server->setText(global->server); - QLabel *l = new QLabel(w_server, i18n("Host&name:"), serverTab); + TQLabel *l = new TQLabel(w_server, i18n("Host&name:"), serverTab); grid->addWidget(l,0,0); grid->addMultiCellWidget(w_server,0,0,1,2); - connect( w_server, SIGNAL( textChanged ( const QString & ) ), this, SLOT( slotChanged() ) ); + connect( w_server, TQT_SIGNAL( textChanged ( const TQString & ) ), this, TQT_SLOT( slotChanged() ) ); w_port = new KLineEdit(serverTab); w_port->setValidator(new KIntValidator(0,65536,this)); - w_port->setText(QString::number(global->port)); - l = new QLabel(w_port, i18n("&Port:"), serverTab); + w_port->setText(TQString::number(global->port)); + l = new TQLabel(w_port, i18n("&Port:"), serverTab); grid->addWidget(l,1,0); grid->addWidget(w_port,1,1); - connect( w_port, SIGNAL( textChanged ( const QString & ) ), this, SLOT( slotChanged() ) ); + connect( w_port, TQT_SIGNAL( textChanged ( const TQString & ) ), this, TQT_SLOT( slotChanged() ) ); w_idleHold = new KIntSpinBox(0,300,5,0,10,serverTab); w_idleHold->setSuffix(i18n(" sec")); w_idleHold->setValue(global->idleHold); - l = new QLabel(w_idleHold, i18n("Hold conn&ection for:"), serverTab); + l = new TQLabel(w_idleHold, i18n("Hold conn&ection for:"), serverTab); grid->addWidget(l,2,0); grid->addWidget(w_idleHold,2,1); - connect( w_idleHold, SIGNAL( valueChanged(int) ), this, SLOT( slotChanged() ) ); + connect( w_idleHold, TQT_SIGNAL( valueChanged(int) ), this, TQT_SLOT( slotChanged() ) ); w_timeout = new KIntSpinBox(5,600,5,5,10,serverTab); w_timeout->setSuffix(i18n(" sec")); w_timeout->setValue(global->timeout); - l = new QLabel(w_timeout, i18n("T&imeout:"), serverTab); + l = new TQLabel(w_timeout, i18n("T&imeout:"), serverTab); grid->addWidget(l,3,0); grid->addWidget(w_timeout,3,1); - connect( w_timeout, SIGNAL( valueChanged(int) ), this, SLOT( slotChanged() ) ); + connect( w_timeout, TQT_SIGNAL( valueChanged(int) ), this, TQT_SLOT( slotChanged() ) ); w_pipesize = new KIntSpinBox(100,5000,2,2,10,serverTab); w_pipesize->setSuffix(i18n(" bytes")); w_pipesize->setValue(global->pipeSize); - l = new QLabel(w_pipesize, i18n("Command &buffer:"), serverTab); + l = new TQLabel(w_pipesize, i18n("Command &buffer:"), serverTab); grid->addWidget(l,4,0); grid->addWidget(w_pipesize,4,1); - connect( w_pipesize, SIGNAL( valueChanged(int) ), this, SLOT( slotChanged() ) ); + connect( w_pipesize, TQT_SIGNAL( valueChanged(int) ), this, TQT_SLOT( slotChanged() ) ); - QStringList encodingNames = KGlobal::charsets()->descriptiveEncodingNames(); + TQStringList encodingNames = KGlobal::charsets()->descriptiveEncodingNames(); int i=0,x=0; - for ( QStringList::Iterator it = encodingNames.begin(); it != encodingNames.end(); ++it ) { + for ( TQStringList::Iterator it = encodingNames.begin(); it != encodingNames.end(); ++it ) { if (KGlobal::charsets()->encodingForName(*it)==global->encoding) { x = i; break; } i++; } - w_encoding = new QComboBox(serverTab); + w_encoding = new TQComboBox(serverTab); w_encoding->insertStringList(encodingNames); w_encoding->setCurrentItem(x); - l = new QLabel(w_encoding, i18n("Encod&ing:"), serverTab); + l = new TQLabel(w_encoding, i18n("Encod&ing:"), serverTab); grid->addWidget(l,5,0); grid->addMultiCellWidget(w_encoding,5,5,1,2); - connect( w_encoding, SIGNAL( activated(int) ), this, SLOT( slotChanged() ) ); + connect( w_encoding, TQT_SIGNAL( activated(int) ), this, TQT_SLOT( slotChanged() ) ); - w_auth = new QCheckBox(i18n("Server requires a&uthentication"),serverTab); + w_auth = new TQCheckBox(i18n("Server requires a&uthentication"),serverTab); w_auth->setChecked(global->authEnabled); grid->addMultiCellWidget(w_auth,6,6,0,2); - connect( w_auth, SIGNAL( toggled(bool) ), this, SLOT( slotChanged() ) ); - connect(w_auth,SIGNAL(toggled(bool)),SLOT(slotAuthRequiredToggled(bool))); + connect( w_auth, TQT_SIGNAL( toggled(bool) ), this, TQT_SLOT( slotChanged() ) ); + connect(w_auth,TQT_SIGNAL(toggled(bool)),TQT_SLOT(slotAuthRequiredToggled(bool))); w_user = new KLineEdit(serverTab); w_user->setText(global->user); - l_user = new QLabel(w_user, i18n("U&ser:"),serverTab); + l_user = new TQLabel(w_user, i18n("U&ser:"),serverTab); grid->addWidget(l_user,7,0); grid->addMultiCellWidget(w_user,7,7,1,2); - connect( w_user, SIGNAL( textChanged ( const QString & ) ), this, SLOT( slotChanged() ) ); + connect( w_user, TQT_SIGNAL( textChanged ( const TQString & ) ), this, TQT_SLOT( slotChanged() ) ); w_secret = new KLineEdit(serverTab); - w_secret->setEchoMode(QLineEdit::Password); + w_secret->setEchoMode(TQLineEdit::Password); w_secret->setText(global->secret); - l_secret = new QLabel(w_secret, i18n("Pass&word:"), serverTab); + l_secret = new TQLabel(w_secret, i18n("Pass&word:"), serverTab); grid->addWidget(l_secret,8,0); grid->addMultiCellWidget(w_secret,8,8,1,2); - connect( w_secret, SIGNAL( textChanged ( const QString & ) ), this, SLOT( slotChanged() ) ); + connect( w_secret, TQT_SIGNAL( textChanged ( const TQString & ) ), this, TQT_SLOT( slotChanged() ) ); slotAuthRequiredToggled( w_auth->isChecked() ); @@ -581,53 +581,53 @@ OptionsDialog::OptionsDialog(QWidget *parent, const char *name) //************ Appearance *************************** appTab = addPage(i18n("Appearance"),i18n("Customize Visual Appearance"), BarIcon("appearance", KIcon::SizeMedium )); - QGridLayout *topL=new QGridLayout(appTab, 8, 3, 0, spacingHint()); + TQGridLayout *topL=new TQGridLayout(appTab, 8, 3, 0, spacingHint()); //color-list c_List = new DialogListBox(false, appTab); topL->addMultiCellWidget(c_List,1,3,0,1); - connect(c_List, SIGNAL(selected(QListBoxItem*)),SLOT(slotColItemSelected(QListBoxItem*))); - connect(c_List, SIGNAL(selectionChanged()), SLOT(slotColSelectionChanged())); + connect(c_List, TQT_SIGNAL(selected(TQListBoxItem*)),TQT_SLOT(slotColItemSelected(TQListBoxItem*))); + connect(c_List, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotColSelectionChanged())); - c_olorCB = new QCheckBox(i18n("&Use custom colors"),appTab); + c_olorCB = new TQCheckBox(i18n("&Use custom colors"),appTab); topL->addWidget(c_olorCB,0,0); - connect(c_olorCB, SIGNAL(toggled(bool)), this, SLOT(slotColCheckBoxToggled(bool))); - connect(c_olorCB, SIGNAL(toggled(bool) ), this, SLOT( slotChanged())); + connect(c_olorCB, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotColCheckBoxToggled(bool))); + connect(c_olorCB, TQT_SIGNAL(toggled(bool) ), this, TQT_SLOT( slotChanged())); - c_olChngBtn=new QPushButton(i18n("Cha&nge..."), appTab); - connect(c_olChngBtn, SIGNAL(clicked()), SLOT(slotColChangeBtnClicked())); + c_olChngBtn=new TQPushButton(i18n("Cha&nge..."), appTab); + connect(c_olChngBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotColChangeBtnClicked())); topL->addWidget(c_olChngBtn,1,2); - c_olDefBtn=new QPushButton(i18n("Default&s"), appTab); - connect(c_olDefBtn, SIGNAL(clicked()), SLOT(slotColDefaultBtnClicked())); + c_olDefBtn=new TQPushButton(i18n("Default&s"), appTab); + connect(c_olDefBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotColDefaultBtnClicked())); topL->addWidget(c_olDefBtn,2,2); - connect(c_olDefBtn, SIGNAL(clicked()), SLOT(slotChanged())); + connect(c_olDefBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotChanged())); //font-list f_List = new DialogListBox(false, appTab); topL->addMultiCellWidget(f_List,5,7,0,1); - connect(f_List, SIGNAL(selected(QListBoxItem*)),SLOT(slotFontItemSelected(QListBoxItem*))); - connect(f_List, SIGNAL(selectionChanged()),SLOT(slotFontSelectionChanged())); + connect(f_List, TQT_SIGNAL(selected(TQListBoxItem*)),TQT_SLOT(slotFontItemSelected(TQListBoxItem*))); + connect(f_List, TQT_SIGNAL(selectionChanged()),TQT_SLOT(slotFontSelectionChanged())); - f_ontCB = new QCheckBox(i18n("Use custom &fonts"),appTab); + f_ontCB = new TQCheckBox(i18n("Use custom &fonts"),appTab); topL->addWidget(f_ontCB,4,0); - connect(f_ontCB, SIGNAL(toggled(bool)), SLOT(slotFontCheckBoxToggled(bool))); - connect(f_ontCB, SIGNAL(toggled(bool)), SLOT(slotChanged())); + connect(f_ontCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotFontCheckBoxToggled(bool))); + connect(f_ontCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); - f_ntChngBtn=new QPushButton(i18n("Chang&e..."), appTab); - connect(f_ntChngBtn, SIGNAL(clicked()), SLOT(slotFontChangeBtnClicked())); + f_ntChngBtn=new TQPushButton(i18n("Chang&e..."), appTab); + connect(f_ntChngBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotFontChangeBtnClicked())); topL->addWidget(f_ntChngBtn,5,2); - f_ntDefBtn=new QPushButton(i18n("Defaul&ts"), appTab); - connect(f_ntDefBtn, SIGNAL(clicked()), SLOT(slotFontDefaultBtnClicked())); + f_ntDefBtn=new TQPushButton(i18n("Defaul&ts"), appTab); + connect(f_ntDefBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotFontDefaultBtnClicked())); topL->addWidget(f_ntDefBtn,6,2); - connect(f_ntDefBtn, SIGNAL(clicked()), SLOT(slotChanged())); + connect(f_ntDefBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotChanged())); topL->setColStretch(1,2); topL->setColStretch(2,0); topL->setRowStretch(3,1); topL->setRowStretch(7,1); - topL->setResizeMode(QLayout::Minimum); + topL->setResizeMode(TQLayout::Minimum); //init c_olorCB->setChecked(global->useCustomColors); @@ -643,24 +643,24 @@ OptionsDialog::OptionsDialog(QWidget *parent, const char *name) //************ Layout *************************** layoutTab = addPage(i18n("Layout"),i18n("Customize Output Format"), BarIcon("text_left", KIcon::SizeMedium )); - QVBoxLayout *vbox = new QVBoxLayout(layoutTab, 0, spacingHint()); + TQVBoxLayout *vbox = new TQVBoxLayout(layoutTab, 0, spacingHint()); - QButtonGroup *bGroup = new QButtonGroup(i18n("Headings"),layoutTab); - QVBoxLayout *bvbox = new QVBoxLayout(bGroup,8,5); + TQButtonGroup *bGroup = new TQButtonGroup(i18n("Headings"),layoutTab); + TQVBoxLayout *bvbox = new TQVBoxLayout(bGroup,8,5); bvbox->addSpacing(fontMetrics().lineSpacing()-4); - w_layout[0] = new QRadioButton(i18n("O&ne heading for each database"),bGroup); + w_layout[0] = new TQRadioButton(i18n("O&ne heading for each database"),bGroup); w_layout[0]->setChecked(global->headLayout == 0); bvbox->addWidget(w_layout[0],1); - w_layout[1] = new QRadioButton(i18n("A&s above, with separators between the definitions"),bGroup); + w_layout[1] = new TQRadioButton(i18n("A&s above, with separators between the definitions"),bGroup); w_layout[1]->setChecked(global->headLayout == 1); bvbox->addWidget(w_layout[1],1); - w_layout[2] = new QRadioButton(i18n("A separate heading for &each definition"),bGroup); + w_layout[2] = new TQRadioButton(i18n("A separate heading for &each definition"),bGroup); w_layout[2]->setChecked(global->headLayout == 2); bvbox->addWidget(w_layout[2],1); - connect(w_layout[0], SIGNAL(toggled(bool)), SLOT(slotChanged())); - connect(w_layout[1], SIGNAL(toggled(bool)), SLOT(slotChanged())); - connect(w_layout[2], SIGNAL(toggled(bool)), SLOT(slotChanged())); + connect(w_layout[0], TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); + connect(w_layout[1], TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); + connect(w_layout[2], TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); vbox->addWidget(bGroup,0); vbox->addStretch(1); @@ -668,53 +668,53 @@ OptionsDialog::OptionsDialog(QWidget *parent, const char *name) //************ Other *************************** otherTab = addPage(i18n("Miscellaneous"),i18n("Various Settings"), BarIcon("misc", KIcon::SizeMedium )); - vbox = new QVBoxLayout(otherTab, 0, spacingHint()); + vbox = new TQVBoxLayout(otherTab, 0, spacingHint()); - QGroupBox *group = new QGroupBox(i18n("Limits"),otherTab); + TQGroupBox *group = new TQGroupBox(i18n("Limits"),otherTab); - grid = new QGridLayout(group,4,2,8,5); + grid = new TQGridLayout(group,4,2,8,5); grid->addRowSpacing(0, fontMetrics().lineSpacing()-4); w_MaxDefinitions = new KIntSpinBox(100,10000,100,100,10,group); w_MaxDefinitions->setValue(global->maxDefinitions); - l = new QLabel(w_MaxDefinitions, i18n("De&finitions:"), group); + l = new TQLabel(w_MaxDefinitions, i18n("De&finitions:"), group); grid->addWidget(l,1,0); grid->addWidget(w_MaxDefinitions,1,1); - connect(w_MaxDefinitions, SIGNAL(valueChanged(int)), SLOT(slotChanged())); + connect(w_MaxDefinitions, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotChanged())); w_Maxbrowse = new KIntSpinBox(1,100,1,1,10,group); w_Maxbrowse->setValue(global->maxBrowseListEntrys); - l = new QLabel(w_Maxbrowse, i18n("Cached &results:"), group); + l = new TQLabel(w_Maxbrowse, i18n("Cached &results:"), group); grid->addWidget(l,2,0); grid->addWidget(w_Maxbrowse,2,1); - connect(w_Maxbrowse, SIGNAL(valueChanged(int)), SLOT(slotChanged())); + connect(w_Maxbrowse, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotChanged())); w_Maxhist = new KIntSpinBox(10,5000,10,10,10,group); w_Maxhist->setValue(global->maxHistEntrys); - l = new QLabel(w_Maxhist, i18n("Hi&story entries:"), group); + l = new TQLabel(w_Maxhist, i18n("Hi&story entries:"), group); grid->addWidget(l,3,0); grid->addWidget(w_Maxhist,3,1); - connect(w_Maxhist, SIGNAL(valueChanged(int)), SLOT(slotChanged())); + connect(w_Maxhist, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotChanged())); grid->setColStretch(1,1); vbox->addWidget(group,0); - group = new QGroupBox(i18n("Other"),otherTab); + group = new TQGroupBox(i18n("Other"),otherTab); - QVBoxLayout *vbox2 = new QVBoxLayout(group, 8, 5); + TQVBoxLayout *vbox2 = new TQVBoxLayout(group, 8, 5); vbox2->addSpacing(fontMetrics().lineSpacing()-4); - w_Savehist = new QCheckBox(i18n("Sa&ve history on exit"),group); + w_Savehist = new TQCheckBox(i18n("Sa&ve history on exit"),group); w_Savehist->setChecked(global->saveHistory); vbox2->addWidget(w_Savehist,0); - connect(w_Savehist, SIGNAL(toggled(bool)), SLOT(slotChanged())); + connect(w_Savehist, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); - w_Clipboard = new QCheckBox(i18n("D&efine selected text on start"),group); + w_Clipboard = new TQCheckBox(i18n("D&efine selected text on start"),group); w_Clipboard->setChecked(global->defineClipboard); vbox2->addWidget(w_Clipboard,1); - connect(w_Clipboard, SIGNAL(toggled(bool)), SLOT(slotChanged())); + connect(w_Clipboard, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChanged())); vbox->addWidget(group,0); vbox->addStretch(2); @@ -782,7 +782,7 @@ void OptionsDialog::slotOk() void OptionsDialog::slotDefault() { - QStringList encodingNames; + TQStringList encodingNames; int i=0,x=0; switch(activePageIndex()) { @@ -793,7 +793,7 @@ void OptionsDialog::slotDefault() w_timeout->setValue(60); w_pipesize->setValue(256); encodingNames = KGlobal::charsets()->descriptiveEncodingNames(); - for ( QStringList::Iterator it = encodingNames.begin(); it != encodingNames.end(); ++it ) { + for ( TQStringList::Iterator it = encodingNames.begin(); it != encodingNames.end(); ++it ) { if (KGlobal::charsets()->encodingForName(*it)=="utf8") x = i; i++; @@ -845,11 +845,11 @@ void OptionsDialog::slotColCheckBoxToggled(bool b) // show color dialog for the entry -void OptionsDialog::slotColItemSelected(QListBoxItem *it) +void OptionsDialog::slotColItemSelected(TQListBoxItem *it) { if (it) { ColorListItem *colorItem = static_cast<ColorListItem*>(it); - QColor col = colorItem->color(); + TQColor col = colorItem->color(); int result = KColorDialog::getColor(col,this); if (result == KColorDialog::Accepted) { @@ -896,11 +896,11 @@ void OptionsDialog::slotFontCheckBoxToggled(bool b) // show font dialog for the entry -void OptionsDialog::slotFontItemSelected(QListBoxItem *it) +void OptionsDialog::slotFontItemSelected(TQListBoxItem *it) { if (it) { FontListItem *fontItem = static_cast<FontListItem*>(it); - QFont font = fontItem->font(); + TQFont font = fontItem->font(); int result = KFontDialog::getFont(font,false,this); if (result == KFontDialog::Accepted) { |