summaryrefslogtreecommitdiffstats
path: root/src/common/gui
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:33:27 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:33:27 -0600
commit9d6927a7d6a543332f828bffedf65eecf6774c6d (patch)
tree9f8210096908fddb7d266b477152021c45fa1a00 /src/common/gui
parent3534213800bd8d151759df307755f2bbd592dfa1 (diff)
downloadpiklab-9d6927a7d6a543332f828bffedf65eecf6774c6d.tar.gz
piklab-9d6927a7d6a543332f828bffedf65eecf6774c6d.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'src/common/gui')
-rw-r--r--src/common/gui/container.cpp8
-rw-r--r--src/common/gui/container.h6
-rw-r--r--src/common/gui/dialog.h2
-rw-r--r--src/common/gui/editlistbox.cpp2
-rw-r--r--src/common/gui/editlistbox.h2
-rw-r--r--src/common/gui/hexword_gui.cpp4
-rw-r--r--src/common/gui/hexword_gui.h4
-rw-r--r--src/common/gui/key_gui.h2
-rw-r--r--src/common/gui/list_view.cpp16
-rw-r--r--src/common/gui/misc_gui.h2
-rw-r--r--src/common/gui/pfile_ext.cpp8
-rw-r--r--src/common/gui/purl_gui.cpp4
12 files changed, 30 insertions, 30 deletions
diff --git a/src/common/gui/container.cpp b/src/common/gui/container.cpp
index 8a747d3..b5917dc 100644
--- a/src/common/gui/container.cpp
+++ b/src/common/gui/container.cpp
@@ -55,19 +55,19 @@ void Container::initLayout()
setFrame(_type);
}
-void Container::addWidget(TQWidget *w, uint startRow, uint endRow, uint startCol, uint endCol, int tqalignment)
+void Container::addWidget(TQWidget *w, uint startRow, uint endRow, uint startCol, uint endCol, int alignment)
{
Q_ASSERT( startRow<=endRow );
Q_ASSERT( startCol<=endCol );
w->show();
- _gridLayout->addMultiCellWidget(w, startRow, endRow, startCol, endCol, tqalignment);
+ _gridLayout->addMultiCellWidget(w, startRow, endRow, startCol, endCol, alignment);
}
-void Container::addLayout(TQLayout *l, uint startRow, uint endRow, uint startCol, uint endCol, int tqalignment)
+void Container::addLayout(TQLayout *l, uint startRow, uint endRow, uint startCol, uint endCol, int alignment)
{
Q_ASSERT( startRow<=endRow );
Q_ASSERT( startCol<=endCol );
- _gridLayout->addMultiCellLayout(l, startRow, endRow, startCol, endCol, tqalignment);
+ _gridLayout->addMultiCellLayout(l, startRow, endRow, startCol, endCol, alignment);
}
//----------------------------------------------------------------------------
diff --git a/src/common/gui/container.h b/src/common/gui/container.h
index af3e5a6..d377561 100644
--- a/src/common/gui/container.h
+++ b/src/common/gui/container.h
@@ -12,7 +12,7 @@
#include <tqframe.h>
#include <tqwidgetstack.h>
#include <tqtabwidget.h>
-#include <tqlayout.h>
+#include <layout.h>
class PopupButton;
@@ -26,8 +26,8 @@ public:
Container(TQWidget *parent = 0, Type type = Flat);
Container(TQWidgetStack *stack, uint index, Type type = Flat);
Container(TQTabWidget *tabw, const TQString &title, Type type = Flat);
- void addWidget(TQWidget *widget, uint startRow, uint endRow, uint startCol, uint endCol, int tqalignment = 0);
- void addLayout(TQLayout *tqlayout, uint startRow, uint endRow, uint startCol, uint endCol, int tqalignment = 0);
+ void addWidget(TQWidget *widget, uint startRow, uint endRow, uint startCol, uint endCol, int alignment = 0);
+ void addLayout(TQLayout *layout, uint startRow, uint endRow, uint startCol, uint endCol, int alignment = 0);
uint numRows() const { return _gridLayout->numRows(); }
uint numCols() const { return _gridLayout->numCols(); }
void setFrame(Type type);
diff --git a/src/common/gui/dialog.h b/src/common/gui/dialog.h
index f506411..a28c607 100644
--- a/src/common/gui/dialog.h
+++ b/src/common/gui/dialog.h
@@ -9,7 +9,7 @@
#ifndef DIALOG_H
#define DIALOG_H
-#include <tqlayout.h>
+#include <layout.h>
#include <kdialogbase.h>
#include <klistview.h>
diff --git a/src/common/gui/editlistbox.cpp b/src/common/gui/editlistbox.cpp
index b881e0f..ca2c675 100644
--- a/src/common/gui/editlistbox.cpp
+++ b/src/common/gui/editlistbox.cpp
@@ -53,7 +53,7 @@ void EditListBox::init(uint nbColumns, TQWidget *view)
_moveDownButton = 0;
_removeAllButton = 0;
_resetButton = 0;
- tqsetSizePolicy(TQSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::MinimumExpanding));
+ setSizePolicy(TQSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::MinimumExpanding));
TQGridLayout *grid = new TQGridLayout(this, 1, 1, 0, KDialog::spacingHint());
uint row = 0;
diff --git a/src/common/gui/editlistbox.h b/src/common/gui/editlistbox.h
index 53b4294..57b156f 100644
--- a/src/common/gui/editlistbox.h
+++ b/src/common/gui/editlistbox.h
@@ -19,7 +19,7 @@
#ifndef EDITLISTBOX_H
#define EDITLISTBOX_H
-#include <tqlayout.h>
+#include <layout.h>
#include <klineedit.h>
#include <kpushbutton.h>
#include <klistview.h>
diff --git a/src/common/gui/hexword_gui.cpp b/src/common/gui/hexword_gui.cpp
index bf1430c..3030d65 100644
--- a/src/common/gui/hexword_gui.cpp
+++ b/src/common/gui/hexword_gui.cpp
@@ -125,12 +125,12 @@ bool GenericHexWordEditor::event(TQEvent *e)
return TQLineEdit::event(e);
}
-TQSize GenericHexWordEditor::tqsizeHint() const
+TQSize GenericHexWordEditor::sizeHint() const
{
return TQSize(maxCharWidth(NumberBase::Hex, font()) * (_nbChars+1), fontMetrics().height());
}
-TQSize GenericHexWordEditor::tqminimumSizeHint() const
+TQSize GenericHexWordEditor::minimumSizeHint() const
{
return TQSize(maxCharWidth(NumberBase::Hex, font()) * (_nbChars+1), fontMetrics().height());
}
diff --git a/src/common/gui/hexword_gui.h b/src/common/gui/hexword_gui.h
index a973291..2be2a75 100644
--- a/src/common/gui/hexword_gui.h
+++ b/src/common/gui/hexword_gui.h
@@ -35,8 +35,8 @@ Q_OBJECT
TQ_OBJECT
public:
GenericHexWordEditor(uint nbChars, bool hasBlankValue, TQWidget *parent);
- virtual TQSize tqsizeHint() const;
- virtual TQSize tqminimumSizeHint() const;
+ virtual TQSize sizeHint() const;
+ virtual TQSize minimumSizeHint() const;
signals:
void modified();
diff --git a/src/common/gui/key_gui.h b/src/common/gui/key_gui.h
index 5afce35..f40c5d2 100644
--- a/src/common/gui/key_gui.h
+++ b/src/common/gui/key_gui.h
@@ -77,7 +77,7 @@ public:
ParentType::_widget->clear();
}
void fixMinimumWidth() {
- ParentType::_widget->setMinimumWidth(ParentType::_widget->tqsizeHint().width());
+ ParentType::_widget->setMinimumWidth(ParentType::_widget->sizeHint().width());
}
protected:
diff --git a/src/common/gui/list_view.cpp b/src/common/gui/list_view.cpp
index 52bd32b..1e0cb66 100644
--- a/src/common/gui/list_view.cpp
+++ b/src/common/gui/list_view.cpp
@@ -62,8 +62,8 @@ bool ListView::eventFilter(TQObject *o, TQEvent *e)
break;
}
case TQEvent::FocusOut: {
- //qDebug("focus out %i %i=%i", tqApp->tqfocusWidget(), tqfocusWidget(), (*it)->_editWidgets[i]);
- if ( tqApp->tqfocusWidget() && tqfocusWidget()==(*it)->_editWidgets[i] ) break;
+ //qDebug("focus out %i %i=%i", tqApp->focusWidget(), focusWidget(), (*it)->_editWidgets[i]);
+ if ( tqApp->focusWidget() && focusWidget()==(*it)->_editWidgets[i] ) break;
//qDebug("ext");
TQCustomEvent *e = new TQCustomEvent(9999);
TQApplication::postEvent(o, e);
@@ -95,7 +95,7 @@ void ListViewToolTip::maybeTip(const TQPoint &p)
if ( _listView==0 ) return;
const TQListViewItem* item = _listView->itemAt(p);
if ( item==0 ) return;
- TQRect rect = _listView->tqitemRect(item);
+ TQRect rect = _listView->itemRect(item);
if ( !rect.isValid() ) return;
int col = _listView->header()->sectionAt(p.x());
TQString text = _listView->tooltip(*item, col);
@@ -149,7 +149,7 @@ void EditListViewItem::startRename()
_renaming = true;
_editWidgets.resize(lv->columns());
for (uint i=0; i<_editWidgets.count(); i++) {
- TQRect r = lv->tqitemRect(this);
+ TQRect r = lv->itemRect(this);
r = TQRect(lv->viewportToContents(r.topLeft()), r.size());
r.setLeft(lv->header()->sectionPos(i));
r.setWidth(lv->header()->sectionSize(i) - 1);
@@ -162,7 +162,7 @@ void EditListViewItem::startRename()
if ( _editWidgets[i]==0 ) continue;
_editWidgets[i]->installEventFilter(lv);
lv->addChild(_editWidgets[i], r.x(), r.y());
- uint w = TQMIN(r.width(), _editWidgets[i]->tqsizeHint().width());
+ uint w = TQMIN(r.width(), _editWidgets[i]->sizeHint().width());
_editWidgets[i]->resize(w, r.height());
lv->viewport()->setFocusProxy(_editWidgets[i]);
_editWidgets[i]->setFocus();
@@ -191,9 +191,9 @@ void EditListViewItem::removeEditBox()
void EditListViewItem::editDone(int col, const TQWidget *edit)
{
- if ( edit->tqmetaObject()->findProperty("text", true)!=-1 )
+ if ( edit->metaObject()->findProperty("text", true)!=-1 )
emit listView()->itemRenamed(this, col, edit->property("text").toString());
- else if ( edit->tqmetaObject()->findProperty("currentText", true)!=-1 )
+ else if ( edit->metaObject()->findProperty("currentText", true)!=-1 )
emit listView()->itemRenamed(this, col, edit->property("currentText").toString());
}
@@ -215,7 +215,7 @@ int EditListViewItem::width(const TQFontMetrics &fm, const TQListView *lv, int c
int w = KListViewItem::width(fm, lv, col);
TQWidget *edit = editWidgetFactory(col);
if ( edit==0 ) return w;
- w = TQMAX(w, edit->tqsizeHint().width());
+ w = TQMAX(w, edit->sizeHint().width());
delete edit;
return w;
}
diff --git a/src/common/gui/misc_gui.h b/src/common/gui/misc_gui.h
index 8c6a2ee..eea2e1f 100644
--- a/src/common/gui/misc_gui.h
+++ b/src/common/gui/misc_gui.h
@@ -9,7 +9,7 @@
#ifndef MISC_GUI_H
#define MISC_GUI_H
-#include <tqlayout.h>
+#include <layout.h>
#include <tqsplitter.h>
#include <tqvaluevector.h>
#include <tqvalidator.h>
diff --git a/src/common/gui/pfile_ext.cpp b/src/common/gui/pfile_ext.cpp
index 43f9e81..080421f 100644
--- a/src/common/gui/pfile_ext.cpp
+++ b/src/common/gui/pfile_ext.cpp
@@ -22,7 +22,7 @@ bool PURL::File::openForWrite()
_tmp->setAutoDelete(true);
if ( _tmp->status()!=0 ) {
_error = i18n("Could not create temporary file.");
- _log.sorry(_error, i18n("File: %1").tqarg(_tmp->name()));
+ _log.sorry(_error, i18n("File: %1").arg(_tmp->name()));
return false;
}
return true;
@@ -61,7 +61,7 @@ bool PURL::File::openForRead()
_file->setName(tmp);
if ( !_file->open(IO_ReadOnly) ) {
_error = i18n("Could not open temporary file.");
- _log.sorry(_error, i18n("File: %1").tqarg(_file->name()));
+ _log.sorry(_error, i18n("File: %1").arg(_file->name()));
return false;
}
return true;
@@ -92,7 +92,7 @@ bool PURL::TempFile::close()
_tmp->close();
if ( _tmp->status()!=IO_Ok ) {
_error = i18n("Could not write to temporary file.");
- _log.sorry(_error, i18n("File: %1").tqarg(_tmp->name()));
+ _log.sorry(_error, i18n("File: %1").arg(_tmp->name()));
return false;
}
}
@@ -107,7 +107,7 @@ bool PURL::TempFile::openForWrite()
_tmp->setAutoDelete(true);
if ( _tmp->status()!=0 ) {
_error = i18n("Could not create temporary file.");
- _log.sorry(_error, i18n("File: %1").tqarg(_tmp->name()));
+ _log.sorry(_error, i18n("File: %1").arg(_tmp->name()));
return false;
}
return true;
diff --git a/src/common/gui/purl_gui.cpp b/src/common/gui/purl_gui.cpp
index 0284682..0299bcb 100644
--- a/src/common/gui/purl_gui.cpp
+++ b/src/common/gui/purl_gui.cpp
@@ -8,7 +8,7 @@
***************************************************************************/
#include "purl_gui.h"
-#include <tqlayout.h>
+#include <layout.h>
#include <kiconloader.h>
#include <kpushbutton.h>
#include <krun.h>
@@ -40,7 +40,7 @@ PURL::Url PURL::getSaveUrl(const TQString &startDir, const TQString &filter,
case NoSaveAction: break;
case AskOverwrite:
if ( url.exists() ) {
- if ( !MessageBox::askContinue(i18n("File \"%1\" already exists. Overwrite ?").tqarg(url.pretty())) ) return Url();
+ if ( !MessageBox::askContinue(i18n("File \"%1\" already exists. Overwrite ?").arg(url.pretty())) ) return Url();
}
break;
case CancelIfExists: