diff options
Diffstat (limited to 'kword/mailmerge/KWClassicSerialDataSource.cpp')
-rw-r--r-- | kword/mailmerge/KWClassicSerialDataSource.cpp | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/kword/mailmerge/KWClassicSerialDataSource.cpp b/kword/mailmerge/KWClassicSerialDataSource.cpp index 1e6c20fe..57b574a5 100644 --- a/kword/mailmerge/KWClassicSerialDataSource.cpp +++ b/kword/mailmerge/KWClassicSerialDataSource.cpp @@ -24,7 +24,7 @@ #include <kinputdialog.h> #include <tqlabel.h> #include <tqhbox.h> -#include <tqlayout.h> +#include <layout.h> #include <tqvbox.h> #include <tqpushbutton.h> #include <tqlineedit.h> @@ -107,7 +107,7 @@ void KWClassicSerialDataSource::removeRecord( int i ) if ( (i < 0) || (i > (int)db.count() - 1) ) return; - kdDebug()<<TQString("Removing record %1").tqarg(i)<<endl; + kdDebug()<<TQString("Removing record %1").arg(i)<<endl; Db::Iterator it = db.at( i); db.remove( it ); @@ -115,25 +115,25 @@ void KWClassicSerialDataSource::removeRecord( int i ) void KWClassicSerialDataSource::save( TQDomDocument &doc, TQDomElement &parent) { - TQDomElement def=doc.createElement(TQString::tqfromLatin1("DEFINITION")); + TQDomElement def=doc.createElement(TQString::fromLatin1("DEFINITION")); parent.appendChild(def); for (DbRecord::Iterator it=sampleRecord.begin();it!=sampleRecord.end();++it) { - TQDomElement defEnt=doc.createElement(TQString::tqfromLatin1("FIELD")); - defEnt.setAttribute(TQString::tqfromLatin1("name"),it.key()); + TQDomElement defEnt=doc.createElement(TQString::fromLatin1("FIELD")); + defEnt.setAttribute(TQString::fromLatin1("name"),it.key()); def.appendChild(defEnt); } - TQDomElement cont=doc.createElement(TQString::tqfromLatin1("CONTENT")); + TQDomElement cont=doc.createElement(TQString::fromLatin1("CONTENT")); parent.appendChild(cont); for (Db::Iterator dbI=db.begin();dbI!=db.end();++dbI) { - TQDomElement rec=doc.createElement(TQString::tqfromLatin1("RECORD")); + TQDomElement rec=doc.createElement(TQString::fromLatin1("RECORD")); cont.appendChild(rec); for (DbRecord::Iterator it=sampleRecord.begin();it!=sampleRecord.end();++it) { - TQDomElement recEnt=doc.createElement(TQString::tqfromLatin1("ITEM")); - recEnt.setAttribute(TQString::tqfromLatin1("name"),it.key()); - recEnt.setAttribute(TQString::tqfromLatin1("data"),(*dbI)[it.key()]); + TQDomElement recEnt=doc.createElement(TQString::fromLatin1("ITEM")); + recEnt.setAttribute(TQString::fromLatin1("name"),it.key()); + recEnt.setAttribute(TQString::fromLatin1("data"),(*dbI)[it.key()]); rec.appendChild(recEnt); } } @@ -148,7 +148,7 @@ void KWClassicSerialDataSource::load( TQDomElement& parentElem ) TQDomElement def=defNd.toElement(); for (TQDomElement defEnt=def.firstChild().toElement();!defEnt.isNull();defEnt=defEnt.nextSibling().toElement()) { - sampleRecord[defEnt.attribute(TQString::tqfromLatin1("name"))]=i18n( "No Value" ); + sampleRecord[defEnt.attribute(TQString::fromLatin1("name"))]=i18n( "No Value" ); } TQDomNode contNd=parentElem.namedItem("CONTENT"); if (contNd.isNull()) return; @@ -157,8 +157,8 @@ void KWClassicSerialDataSource::load( TQDomElement& parentElem ) appendRecord(); for (TQDomElement recEnt=rec.firstChild().toElement();!recEnt.isNull();recEnt=recEnt.nextSibling().toElement()) { - setValue(recEnt.attribute(TQString::tqfromLatin1("name")), - recEnt.attribute(TQString::tqfromLatin1("data")),db.count()-1); + setValue(recEnt.attribute(TQString::fromLatin1("name")), + recEnt.attribute(TQString::fromLatin1("data")),db.count()-1); } } } @@ -219,9 +219,9 @@ TQString KWClassicMailMergeEditorListItem::text( int i ) const void KWClassicMailMergeEditorListItem::setup() { setHeight( TQMAX( listView()->fontMetrics().height(), - editWidget->tqsizeHint().height() ) ); - if ( listView()->columnWidth( 1 ) < editWidget->tqsizeHint().width() ) - listView()->setColumnWidth( 1, editWidget->tqsizeHint().width() ); + editWidget->sizeHint().height() ) ); + if ( listView()->columnWidth( 1 ) < editWidget->sizeHint().width() ) + listView()->setColumnWidth( 1, editWidget->sizeHint().width() ); } void KWClassicMailMergeEditorListItem::update() @@ -342,27 +342,27 @@ KWClassicMailMergeEditor::KWClassicMailMergeEditor( TQWidget *parent, KWClassicS first = new TQToolButton( toolbar ); first->setIconSet( SmallIconSet( "start" ) ); - first->setFixedSize( first->tqsizeHint() ); + first->setFixedSize( first->sizeHint() ); connect(first, TQT_SIGNAL(clicked()), this, TQT_SLOT(firstRecord())); back_ = new TQToolButton( toolbar ); back_->setIconSet( SmallIconSet( "back" ) ); - back_->setFixedSize( back_->tqsizeHint() ); + back_->setFixedSize( back_->sizeHint() ); connect(back_, TQT_SIGNAL(clicked()), this, TQT_SLOT(prevRecord())); records = new TQSpinBox( 1, db->getNumRecords(), 1, toolbar ); - records->setMaximumHeight( records->tqsizeHint().height() ); + records->setMaximumHeight( records->sizeHint().height() ); connect( records, TQT_SIGNAL( valueChanged( int ) ), this, TQT_SLOT( changeRecord( int ) ) ); forward = new TQToolButton( toolbar ); forward->setIconSet( SmallIconSet( "forward" ) ); - forward->setFixedSize( forward->tqsizeHint() ); + forward->setFixedSize( forward->sizeHint() ); connect(forward, TQT_SIGNAL(clicked()), this, TQT_SLOT(nextRecord())); finish = new TQToolButton( toolbar ); finish->setIconSet( SmallIconSet( "finish" ) ); - finish->setFixedSize( finish->tqsizeHint() ); + finish->setFixedSize( finish->sizeHint() ); connect(finish, TQT_SIGNAL(clicked()), this, TQT_SLOT(lastRecord())); TQWidget *sep = new TQWidget( toolbar ); @@ -370,28 +370,28 @@ KWClassicMailMergeEditor::KWClassicMailMergeEditor( TQWidget *parent, KWClassicS newRecord = new TQToolButton( toolbar ); newRecord->setIconSet( SmallIconSet( "sl_addrecord" ) ); - newRecord->setFixedSize( newRecord->tqsizeHint() ); + newRecord->setFixedSize( newRecord->sizeHint() ); connect( newRecord, TQT_SIGNAL( clicked() ), this, TQT_SLOT( addRecord() ) ); TQToolTip::add( newRecord, i18n( "Add record" ) ); newEntry = new TQToolButton( toolbar ); newEntry->setIconSet( SmallIconSet( "sl_addentry" ) ); - newEntry->setFixedSize( newEntry->tqsizeHint() ); + newEntry->setFixedSize( newEntry->sizeHint() ); connect( newEntry, TQT_SIGNAL( clicked() ), this, TQT_SLOT( addEntry() ) ); TQToolTip::add( newEntry, i18n( "Add entry" ) ); deleteRecord = new TQToolButton( toolbar ); deleteRecord->setIconSet( SmallIconSet( "sl_delrecord" ) ); - deleteRecord->setFixedSize( deleteRecord->tqsizeHint() ); + deleteRecord->setFixedSize( deleteRecord->sizeHint() ); connect( deleteRecord, TQT_SIGNAL( clicked() ), this, TQT_SLOT( removeRecord() ) ); TQToolTip::add( deleteRecord, i18n( "Remove record" ) ); deleteEntry = new TQToolButton( toolbar ); deleteEntry->setIconSet( SmallIconSet( "sl_delentry" ) ); - deleteEntry->setFixedSize( deleteEntry->tqsizeHint() ); + deleteEntry->setFixedSize( deleteEntry->sizeHint() ); connect( deleteEntry, TQT_SIGNAL( clicked() ), this, TQT_SLOT( removeEntry() ) ); TQToolTip::add( deleteEntry, i18n( "Remove entry" ) ); |