summaryrefslogtreecommitdiffstats
path: root/src/modules/options/optw_texticons.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/options/optw_texticons.cpp')
-rw-r--r--src/modules/options/optw_texticons.cpp62
1 files changed, 31 insertions, 31 deletions
diff --git a/src/modules/options/optw_texticons.cpp b/src/modules/options/optw_texticons.cpp
index d1752c0f..257689c1 100644
--- a/src/modules/options/optw_texticons.cpp
+++ b/src/modules/options/optw_texticons.cpp
@@ -27,23 +27,23 @@
#include "kvi_locale.h"
#include "kvi_filedialog.h"
-#include <qlayout.h>
-#include <qcursor.h>
+#include <tqlayout.h>
+#include <tqcursor.h>
#include "kvi_tal_hbox.h"
-KviTextIconEditor::KviTextIconEditor(QWidget * par,KviTextIcon * icon,KviTextIconTableItem* item)
+KviTextIconEditor::KviTextIconEditor(TQWidget * par,KviTextIcon * icon,KviTextIconTableItem* item)
: KviTalHBox(par),m_pTableItem(item)
{
- m_pIconButton=new QToolButton(this);
- m_pBrowseButton=new QToolButton(this);
- m_pBrowseButton->setSizePolicy(QSizePolicy(QSizePolicy::Maximum,QSizePolicy::Maximum));
+ m_pIconButton=new TQToolButton(this);
+ m_pBrowseButton=new TQToolButton(this);
+ m_pBrowseButton->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Maximum,TQSizePolicy::Maximum));
m_pBrowseButton->setText("...");
m_pIcon = icon;
m_pPopup = 0;
updateIcon();
- connect(m_pIconButton,SIGNAL(clicked()),this,SLOT(doPopup()));
- connect(m_pBrowseButton,SIGNAL(clicked()),this,SLOT(chooseFromFile()));
+ connect(m_pIconButton,TQT_SIGNAL(clicked()),this,TQT_SLOT(doPopup()));
+ connect(m_pBrowseButton,TQT_SIGNAL(clicked()),this,TQT_SLOT(chooseFromFile()));
}
@@ -58,10 +58,10 @@ void KviTextIconEditor::doPopup()
{
m_pPopup = new KviTalPopupMenu(this);
KviIconWidget * iw = new KviIconWidget(m_pPopup);
- connect(iw,SIGNAL(selected(int)),this,SLOT(iconSelected(int)));
+ connect(iw,TQT_SIGNAL(selected(int)),this,TQT_SLOT(iconSelected(int)));
m_pPopup->insertItem(iw);
}
- m_pPopup->popup(QCursor::pos());
+ m_pPopup->popup(TQCursor::pos());
}
void KviTextIconEditor::iconSelected(int id)
@@ -72,8 +72,8 @@ void KviTextIconEditor::iconSelected(int id)
void KviTextIconEditor::chooseFromFile()
{
- QString szFile;
- KviFileDialog::askForOpenFileName(szFile,"Choose icon filename",QString::null,"*.png","options");
+ TQString szFile;
+ KviFileDialog::askForOpenFileName(szFile,"Choose icon filename",TQString(),"*.png","options");
if(!szFile.isEmpty())
{
if(g_pIconManager->getPixmap(szFile))
@@ -89,20 +89,20 @@ void KviTextIconEditor::updateIcon()
{
if(m_pIcon)
{
- QPixmap* pix=m_pIcon->pixmap();
+ TQPixmap* pix=m_pIcon->pixmap();
if(pix)
m_pIconButton->setPixmap(*pix);
}
}
KviTextIconTableItem::KviTextIconTableItem(KviTalTable * t,KviTextIcon * icon)
-: KviTalTableItem(t,KviTalTableItem::WhenCurrent,QString::null)
+: KviTalTableItem(t,KviTalTableItem::WhenCurrent,TQString())
{
if(icon)
m_pIcon=icon;
else
m_pIcon=new KviTextIcon(0);
- QPixmap* pix=m_pIcon->pixmap();
+ TQPixmap* pix=m_pIcon->pixmap();
if(pix)
setPixmap(*pix);
}
@@ -115,33 +115,33 @@ KviTextIconTableItem::~KviTextIconTableItem()
void KviTextIconTableItem::setId(int id)
{
m_pIcon->setId(id);
- QPixmap* pix=m_pIcon->pixmap();
+ TQPixmap* pix=m_pIcon->pixmap();
if(pix)
setPixmap(*pix);
}
-QWidget * KviTextIconTableItem::createEditor() const
+TQWidget * KviTextIconTableItem::createEditor() const
{
return new KviTextIconEditor(table()->viewport(),m_pIcon,(KviTextIconTableItem*)this);
}
-void KviTextIconTableItem::setContentFromEditor(QWidget * w)
+void KviTextIconTableItem::setContentFromEditor(TQWidget * w)
{
if(w->inherits("KviTextIconEditor"))
{
- QPixmap* pix=m_pIcon->pixmap();
+ TQPixmap* pix=m_pIcon->pixmap();
if(pix)
setPixmap(*pix);
}
}
-KviTextIconsOptionsWidget::KviTextIconsOptionsWidget(QWidget * parent)
-: KviOptionsWidget(parent,"texticons_options_widget")
+KviTextIconsOptionsWidget::KviTextIconsOptionsWidget(TQWidget * tqparent)
+: KviOptionsWidget(tqparent,"texticons_options_widget")
{
createLayout(2,2);
- KviPointerHashTableIterator<QString,KviTextIcon> it(*(g_pTextIconManager->textIconDict()));
+ KviPointerHashTableIterator<TQString,KviTextIcon> it(*(g_pTextIconManager->textIconDict()));
m_pTable = new KviTalTable(g_pTextIconManager->textIconDict()->count(),2,this);
@@ -160,19 +160,19 @@ KviTextIconsOptionsWidget::KviTextIconsOptionsWidget(QWidget * parent)
++it;
}
- layout()->addMultiCellWidget(m_pTable,0,0,0,1);
+ tqlayout()->addMultiCellWidget(m_pTable,0,0,0,1);
- m_pAdd = new QPushButton(__tr2qs_ctx("Add","options"),this);
- layout()->addWidget(m_pAdd,1,0);
- connect(m_pAdd,SIGNAL(clicked()),this,SLOT(addClicked()));
+ m_pAdd = new TQPushButton(__tr2qs_ctx("Add","options"),this);
+ tqlayout()->addWidget(m_pAdd,1,0);
+ connect(m_pAdd,TQT_SIGNAL(clicked()),this,TQT_SLOT(addClicked()));
- m_pDel = new QPushButton(__tr2qs_ctx("Delete","options"),this);
- layout()->addWidget(m_pDel,1,1);
- connect(m_pDel,SIGNAL(clicked()),this,SLOT(delClicked()));
+ m_pDel = new TQPushButton(__tr2qs_ctx("Delete","options"),this);
+ tqlayout()->addWidget(m_pDel,1,1);
+ connect(m_pDel,TQT_SIGNAL(clicked()),this,TQT_SLOT(delClicked()));
m_pDel->setEnabled(false);
- connect(m_pTable,SIGNAL(selectionChanged()),this,SLOT(selectionChanged()));
+ connect(m_pTable,TQT_SIGNAL(selectionChanged()),this,TQT_SLOT(selectionChanged()));
}
KviTextIconsOptionsWidget::~KviTextIconsOptionsWidget()
@@ -222,7 +222,7 @@ void KviTextIconsOptionsWidget::commit()
int n = m_pTable->numRows();
for(int i=0;i < n;i++)
{
- QString szVal = m_pTable->text(i,0);
+ TQString szVal = m_pTable->text(i,0);
if(!szVal.isEmpty())
{
KviTextIconTableItem * it = (KviTextIconTableItem *)m_pTable->item(i,1);