summaryrefslogtreecommitdiffstats
path: root/knode
diff options
context:
space:
mode:
Diffstat (limited to 'knode')
-rw-r--r--knode/articlewidget.cpp304
-rw-r--r--knode/articlewidget.h58
-rw-r--r--knode/csshelper.cpp2
-rw-r--r--knode/csshelper.h2
-rw-r--r--knode/headerview.cpp102
-rw-r--r--knode/headerview.h36
-rw-r--r--knode/knaccountmanager.cpp44
-rw-r--r--knode/knaccountmanager.h12
-rw-r--r--knode/knapplication.cpp2
-rw-r--r--knode/knarticle.cpp18
-rw-r--r--knode/knarticle.h50
-rw-r--r--knode/knarticlecollection.cpp10
-rw-r--r--knode/knarticlecollection.h6
-rw-r--r--knode/knarticlefactory.cpp164
-rw-r--r--knode/knarticlefactory.h24
-rw-r--r--knode/knarticlefilter.cpp24
-rw-r--r--knode/knarticlefilter.h10
-rw-r--r--knode/knarticlemanager.cpp74
-rw-r--r--knode/knarticlemanager.h14
-rw-r--r--knode/knarticlewindow.cpp20
-rw-r--r--knode/knarticlewindow.h4
-rw-r--r--knode/kncleanup.cpp38
-rw-r--r--knode/kncleanup.h14
-rw-r--r--knode/kncollection.h12
-rw-r--r--knode/kncollectionview.cpp84
-rw-r--r--knode/kncollectionview.h22
-rw-r--r--knode/kncollectionviewitem.cpp30
-rw-r--r--knode/kncollectionviewitem.h10
-rw-r--r--knode/kncomposer.cpp690
-rw-r--r--knode/kncomposer.h126
-rw-r--r--knode/knconfig.cpp156
-rw-r--r--knode/knconfig.h166
-rw-r--r--knode/knconfigmanager.cpp12
-rw-r--r--knode/knconfigmanager.h6
-rw-r--r--knode/knconfigpages.cpp32
-rw-r--r--knode/knconfigpages.h12
-rw-r--r--knode/knconfigwidgets.cpp808
-rw-r--r--knode/knconfigwidgets.h156
-rw-r--r--knode/knconvert.cpp88
-rw-r--r--knode/knconvert.h38
-rw-r--r--knode/kndisplayedheader.cpp12
-rw-r--r--knode/kndisplayedheader.h26
-rw-r--r--knode/knfilterconfigwidget.cpp24
-rw-r--r--knode/knfilterconfigwidget.h6
-rw-r--r--knode/knfilterdialog.cpp28
-rw-r--r--knode/knfilterdialog.h8
-rw-r--r--knode/knfiltermanager.cpp52
-rw-r--r--knode/knfiltermanager.h16
-rw-r--r--knode/knfolder.cpp34
-rw-r--r--knode/knfolder.h14
-rw-r--r--knode/knfoldermanager.cpp48
-rw-r--r--knode/knfoldermanager.h8
-rw-r--r--knode/knglobals.cpp2
-rw-r--r--knode/knglobals.h4
-rw-r--r--knode/kngroup.cpp66
-rw-r--r--knode/kngroup.h34
-rw-r--r--knode/kngroupbrowser.cpp140
-rw-r--r--knode/kngroupbrowser.h54
-rw-r--r--knode/kngroupdialog.cpp76
-rw-r--r--knode/kngroupdialog.h14
-rw-r--r--knode/kngroupmanager.cpp100
-rw-r--r--knode/kngroupmanager.h38
-rw-r--r--knode/kngrouppropdlg.cpp74
-rw-r--r--knode/kngrouppropdlg.h6
-rw-r--r--knode/kngroupselectdialog.cpp50
-rw-r--r--knode/kngroupselectdialog.h8
-rw-r--r--knode/knhdrviewitem.cpp62
-rw-r--r--knode/knhdrviewitem.h14
-rw-r--r--knode/knjobdata.cpp18
-rw-r--r--knode/knjobdata.h18
-rw-r--r--knode/knmainwidget.cpp380
-rw-r--r--knode/knmainwidget.h52
-rw-r--r--knode/knmemorymanager.cpp16
-rw-r--r--knode/knmemorymanager.h8
-rw-r--r--knode/knnetaccess.cpp46
-rw-r--r--knode/knnetaccess.h24
-rw-r--r--knode/knnntpaccount.cpp22
-rw-r--r--knode/knnntpaccount.h24
-rw-r--r--knode/knnntpclient.cpp72
-rw-r--r--knode/knnntpclient.h12
-rw-r--r--knode/knode.cpp22
-rw-r--r--knode/knode.h6
-rw-r--r--knode/knode_part.cpp16
-rw-r--r--knode/knode_part.h10
-rw-r--r--knode/knodecomposeriface.h2
-rw-r--r--knode/knodeiface.h2
-rw-r--r--knode/knprotocolclient.cpp22
-rw-r--r--knode/knprotocolclient.h22
-rw-r--r--knode/knrangefilter.cpp28
-rw-r--r--knode/knrangefilter.h12
-rw-r--r--knode/knscoring.cpp26
-rw-r--r--knode/knscoring.h14
-rw-r--r--knode/knsearchdialog.cpp30
-rw-r--r--knode/knsearchdialog.h12
-rw-r--r--knode/knserverinfo.cpp14
-rw-r--r--knode/knserverinfo.h16
-rw-r--r--knode/knsourceviewwindow.cpp20
-rw-r--r--knode/knsourceviewwindow.h4
-rw-r--r--knode/knstatusfilter.cpp22
-rw-r--r--knode/knstatusfilter.h18
-rw-r--r--knode/knstringfilter.cpp24
-rw-r--r--knode/knstringfilter.h14
-rw-r--r--knode/knwidgets.cpp36
-rw-r--r--knode/knwidgets.h26
-rw-r--r--knode/utilities.cpp120
-rw-r--r--knode/utilities.h78
106 files changed, 2903 insertions, 2903 deletions
diff --git a/knode/articlewidget.cpp b/knode/articlewidget.cpp
index 805632c24..1bb7527fe 100644
--- a/knode/articlewidget.cpp
+++ b/knode/articlewidget.cpp
@@ -15,17 +15,17 @@
#include <stdlib.h>
#include <sys/stat.h>
-#include <qbuffer.h>
-#include <qclipboard.h>
-#include <qdir.h>
-#include <qfile.h>
-#include <qimage.h>
-#include <qlayout.h>
-#include <qpaintdevicemetrics.h>
-#include <qpopupmenu.h>
-#include <qstringlist.h>
-#include <qtextcodec.h>
-#include <qtimer.h>
+#include <tqbuffer.h>
+#include <tqclipboard.h>
+#include <tqdir.h>
+#include <tqfile.h>
+#include <tqimage.h>
+#include <tqlayout.h>
+#include <tqpaintdevicemetrics.h>
+#include <tqpopupmenu.h>
+#include <tqstringlist.h>
+#include <tqtextcodec.h>
+#include <tqtimer.h>
#include <kaction.h>
#include <kaddrbook.h>
@@ -73,13 +73,13 @@
using namespace KNode;
-QValueList<ArticleWidget*> ArticleWidget::mInstances;
+TQValueList<ArticleWidget*> ArticleWidget::mInstances;
-ArticleWidget::ArticleWidget( QWidget *parent,
+ArticleWidget::ArticleWidget( TQWidget *parent,
KXMLGUIClient *guiClient,
KActionCollection *actionCollection,
const char *name ) :
- QWidget( parent, name ),
+ TQWidget( parent, name ),
mArticle( 0 ),
mViewer( 0 ),
mCSSHelper( 0 ),
@@ -95,7 +95,7 @@ ArticleWidget::ArticleWidget( QWidget *parent,
{
mInstances.append( this );
- QHBoxLayout *box = new QHBoxLayout( this );
+ TQHBoxLayout *box = new TQHBoxLayout( this );
mViewer = new KHTMLPart( this, "mViewer" );
box->addWidget( mViewer->widget() );
mViewer->widget()->setFocusPolicy( WheelFocus );
@@ -104,14 +104,14 @@ ArticleWidget::ArticleWidget( QWidget *parent,
mViewer->setJavaEnabled( false );
mViewer->setMetaRefreshEnabled( false );
mViewer->setOnlyLocalReferences( true );
- mViewer->view()->setFocusPolicy( QWidget::WheelFocus );
- connect( mViewer->browserExtension(), SIGNAL(openURLRequestDelayed(const KURL&, const KParts::URLArgs&)),
- SLOT(slotURLClicked(const KURL&)) );
- connect( mViewer, SIGNAL(popupMenu(const QString&, const QPoint&)),
- SLOT(slotURLPopup(const QString&, const QPoint&)) );
+ mViewer->view()->setFocusPolicy( TQWidget::WheelFocus );
+ connect( mViewer->browserExtension(), TQT_SIGNAL(openURLRequestDelayed(const KURL&, const KParts::URLArgs&)),
+ TQT_SLOT(slotURLClicked(const KURL&)) );
+ connect( mViewer, TQT_SIGNAL(popupMenu(const TQString&, const TQPoint&)),
+ TQT_SLOT(slotURLPopup(const TQString&, const TQPoint&)) );
- mTimer = new QTimer( this );
- connect( mTimer, SIGNAL(timeout()), SLOT(slotTimeout()) );
+ mTimer = new TQTimer( this );
+ connect( mTimer, TQT_SIGNAL(timeout()), TQT_SLOT(slotTimeout()) );
initActions();
readConfig();
@@ -134,85 +134,85 @@ ArticleWidget::~ArticleWidget()
void ArticleWidget::initActions()
{
- mSaveAction = KStdAction::save( this, SLOT(slotSave()), mActionCollection );
+ mSaveAction = KStdAction::save( this, TQT_SLOT(slotSave()), mActionCollection );
mSaveAction->setText( KStdGuiItem::saveAs().text() );
- mPrintAction = KStdAction::print( this, SLOT(slotPrint()), mActionCollection );
- mCopySelectionAction = KStdAction::copy( this, SLOT(slotCopySelection()), mActionCollection );
- mSelectAllAction = KStdAction::selectAll( this, SLOT(slotSelectAll()), mActionCollection );
- mFindAction = KStdAction::find( this, SLOT(slotFind()), mActionCollection, "find_in_article" );
+ mPrintAction = KStdAction::print( this, TQT_SLOT(slotPrint()), mActionCollection );
+ mCopySelectionAction = KStdAction::copy( this, TQT_SLOT(slotCopySelection()), mActionCollection );
+ mSelectAllAction = KStdAction::selectAll( this, TQT_SLOT(slotSelectAll()), mActionCollection );
+ mFindAction = KStdAction::find( this, TQT_SLOT(slotFind()), mActionCollection, "find_in_article" );
mFindAction->setText( i18n("F&ind in Article...") );
mViewSourceAction = new KAction( i18n("&View Source"), Key_V , this,
- SLOT(slotViewSource()), mActionCollection, "article_viewSource" );
+ TQT_SLOT(slotViewSource()), mActionCollection, "article_viewSource" );
mReplyAction = new KAction( i18n("&Followup to Newsgroup..."), "message_reply",
- Key_R, this, SLOT(slotReply()), mActionCollection, "article_postReply" );
+ Key_R, this, TQT_SLOT(slotReply()), mActionCollection, "article_postReply" );
mRemailAction = new KAction( i18n("Reply by E&mail..."), "mail_reply",
- Key_A, this, SLOT(slotRemail()), mActionCollection, "article_mailReply" );
+ Key_A, this, TQT_SLOT(slotRemail()), mActionCollection, "article_mailReply" );
mForwardAction = new KAction( i18n("Forw&ard by Email..."), "mail_forward",
- Key_F, this, SLOT(slotForward()), mActionCollection, "article_forward" );
+ Key_F, this, TQT_SLOT(slotForward()), mActionCollection, "article_forward" );
mCancelAction = new KAction( i18n("article","&Cancel Article"),
- 0, this, SLOT(slotCancel()), mActionCollection, "article_cancel" );
+ 0, this, TQT_SLOT(slotCancel()), mActionCollection, "article_cancel" );
mSupersedeAction = new KAction(i18n("S&upersede Article"),
- 0, this, SLOT(slotSupersede()), mActionCollection, "article_supersede" );
+ 0, this, TQT_SLOT(slotSupersede()), mActionCollection, "article_supersede" );
mFixedFontToggle = new KToggleAction( i18n("U&se Fixed Font"),
- Key_X ,this, SLOT(slotToggleFixedFont()), mActionCollection, "view_useFixedFont" );
+ Key_X ,this, TQT_SLOT(slotToggleFixedFont()), mActionCollection, "view_useFixedFont" );
mFancyToggle = new KToggleAction( i18n("Fancy Formating"),
- Key_Y, this, SLOT(slotToggleFancyFormating()), mActionCollection, "view_fancyFormating" );
+ Key_Y, this, TQT_SLOT(slotToggleFancyFormating()), mActionCollection, "view_fancyFormating" );
mRot13Toggle = new KToggleAction( i18n("&Unscramble (Rot 13)"), "decrypted", 0 , this,
- SLOT(slotToggleRot13()), mActionCollection, "view_rot13" );
+ TQT_SLOT(slotToggleRot13()), mActionCollection, "view_rot13" );
mRot13Toggle->setChecked( false );
KRadioAction *ra;
mHeaderStyleMenu = new KActionMenu( i18n("&Headers"), mActionCollection, "view_headers" );
- ra = new KRadioAction( i18n("&Fancy Headers"), 0, this, SLOT(slotFancyHeaders()),
+ ra = new KRadioAction( i18n("&Fancy Headers"), 0, this, TQT_SLOT(slotFancyHeaders()),
mActionCollection, "view_headers_fancy" );
ra->setExclusiveGroup( "view_headers" );
mHeaderStyleMenu->insert( ra );
- ra = new KRadioAction( i18n("&Standard Headers"), 0, this, SLOT(slotStandardHeaders()),
+ ra = new KRadioAction( i18n("&Standard Headers"), 0, this, TQT_SLOT(slotStandardHeaders()),
mActionCollection, "view_headers_standard" );
ra->setExclusiveGroup( "view_headers" );
mHeaderStyleMenu->insert( ra );
- ra = new KRadioAction( i18n("&All Headers"), 0, this, SLOT(slotAllHeaders()),
+ ra = new KRadioAction( i18n("&All Headers"), 0, this, TQT_SLOT(slotAllHeaders()),
mActionCollection, "view_headers_all" );
ra->setExclusiveGroup( "view_headers" );
mHeaderStyleMenu->insert( ra );
mAttachmentStyleMenu = new KActionMenu( i18n("&Attachments"), mActionCollection, "view_attachments" );
- ra = new KRadioAction( i18n("&As Icon"), 0, this, SLOT(slotIconAttachments()),
+ ra = new KRadioAction( i18n("&As Icon"), 0, this, TQT_SLOT(slotIconAttachments()),
mActionCollection, "view_attachments_icon" );
ra->setExclusiveGroup( "view_attachments" );
mAttachmentStyleMenu->insert( ra );
- ra = new KRadioAction( i18n("&Inline"), 0, this, SLOT(slotInlineAttachments()),
+ ra = new KRadioAction( i18n("&Inline"), 0, this, TQT_SLOT(slotInlineAttachments()),
mActionCollection, "view_attachments_inline" );
ra->setExclusiveGroup( "view_attachments" );
mAttachmentStyleMenu->insert( ra );
- ra = new KRadioAction( i18n("&Hide"), 0, this, SLOT(slotHideAttachments()),
+ ra = new KRadioAction( i18n("&Hide"), 0, this, TQT_SLOT(slotHideAttachments()),
mActionCollection, "view_attachments_hide" );
ra->setExclusiveGroup( "view_attachments" );
mAttachmentStyleMenu->insert( ra );
mCharsetSelect = new KSelectAction( i18n("Chars&et"), 0, mActionCollection, "set_charset" );
mCharsetSelect->setShortcutConfigurable( false );
- QStringList cs = KGlobal::charsets()->descriptiveEncodingNames();
+ TQStringList cs = KGlobal::charsets()->descriptiveEncodingNames();
cs.prepend( i18n("Automatic") );
mCharsetSelect->setItems( cs );
mCharsetSelect->setCurrentItem( 0 );
- connect( mCharsetSelect, SIGNAL(activated(const QString&)),SLOT(slotSetCharset(const QString&)) );
+ connect( mCharsetSelect, TQT_SIGNAL(activated(const TQString&)),TQT_SLOT(slotSetCharset(const TQString&)) );
mCharsetSelectKeyb = new KAction( i18n("Charset"), Key_C, this,
- SLOT(slotSetCharsetKeyboard()), mActionCollection, "set_charset_keyboard" );
+ TQT_SLOT(slotSetCharsetKeyboard()), mActionCollection, "set_charset_keyboard" );
- new KAction( i18n("&Open URL"), "fileopen", 0, this, SLOT(slotOpenURL()),
+ new KAction( i18n("&Open URL"), "fileopen", 0, this, TQT_SLOT(slotOpenURL()),
mActionCollection, "open_url" );
- new KAction( i18n("&Copy Link Address"), "editcopy", 0, this, SLOT( slotCopyURL()),
+ new KAction( i18n("&Copy Link Address"), "editcopy", 0, this, TQT_SLOT( slotCopyURL()),
mActionCollection, "copy_url" );
- new KAction( i18n("&Bookmark This Link"), "bookmark_add", 0, this, SLOT(slotAddBookmark()),
+ new KAction( i18n("&Bookmark This Link"), "bookmark_add", 0, this, TQT_SLOT(slotAddBookmark()),
mActionCollection, "add_bookmark" );
- new KAction( i18n("&Add to Address Book"), 0, this, SLOT(slotAddToAddressBook()),
+ new KAction( i18n("&Add to Address Book"), 0, this, TQT_SLOT(slotAddToAddressBook()),
mActionCollection, "add_addr_book" );
- new KAction( i18n("&Open in Address Book"), 0, this, SLOT(slotOpenInAddressBook()),
+ new KAction( i18n("&Open in Address Book"), 0, this, TQT_SLOT(slotOpenInAddressBook()),
mActionCollection, "openin_addr_book" );
- new KAction( i18n("&Open Attachment"), "fileopen", 0, this, SLOT(slotOpenAttachment()),
+ new KAction( i18n("&Open Attachment"), "fileopen", 0, this, TQT_SLOT(slotOpenAttachment()),
mActionCollection, "open_attachment" );
- new KAction( i18n("&Save Attachment As..."), "filesaveas", 0, this, SLOT(slotSaveAttachment()),
+ new KAction( i18n("&Save Attachment As..."), "filesaveas", 0, this, TQT_SLOT(slotSaveAttachment()),
mActionCollection, "save_attachment" );
}
@@ -288,13 +288,13 @@ void ArticleWidget::readConfig()
mAttachmentStyle = conf->readEntry( "attachmentStyle", "inline" );
mHeaderStyle = conf->readEntry( "headerStyle", "fancy" );
KRadioAction *ra = 0;
- ra = static_cast<KRadioAction*>( mActionCollection->action( QString("view_attachments_%1").arg(mAttachmentStyle).latin1() ) );
+ ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_attachments_%1").arg(mAttachmentStyle).latin1() ) );
ra->setChecked( true );
- ra = static_cast<KRadioAction*>( mActionCollection->action( QString("view_headers_%1").arg(mHeaderStyle).latin1() ) );
+ ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_headers_%1").arg(mHeaderStyle).latin1() ) );
ra->setChecked( true );
delete mCSSHelper;
- mCSSHelper = new CSSHelper( QPaintDeviceMetrics( mViewer->view() ) );
+ mCSSHelper = new CSSHelper( TQPaintDeviceMetrics( mViewer->view() ) );
if ( !knGlobals.configManager()->readNewsGeneral()->autoMark() )
mTimer->stop();
@@ -391,29 +391,29 @@ void ArticleWidget::displayArticle()
displayHeader();
// body
- QString html;
+ TQString html;
KMime::Content *text = mArticle->textContent();
// check if codec is available
if ( text && !canDecodeText( text->contentType()->charset() ) ) {
- html += QString("<table width=\"100%\" border=\"0\"><tr><td bgcolor=\"#FF0000\">%1</td></tr></table>")
+ html += TQString("<table width=\"100%\" border=\"0\"><tr><td bgcolor=\"#FF0000\">%1</td></tr></table>")
.arg( i18n("Unknown charset. Default charset is used instead.") );
kdDebug(5003) << k_funcinfo << "unknown charset = " << text->contentType()->charset() << endl;
}
// if the article is pgp signed and the user asked for verifying the
// signature, we show a nice header:
- QPtrList<Kpgp::Block> pgpBlocks;
- QStrList nonPgpBlocks;
+ TQPtrList<Kpgp::Block> pgpBlocks;
+ TQStrList nonPgpBlocks;
bool containsPGP = Kpgp::Module::prepareMessageForDecryption( mArticle->body(), pgpBlocks, nonPgpBlocks );
mViewer->write ( html );
- html = QString();
+ html = TQString();
if ( containsPGP ) {
- QPtrListIterator<Kpgp::Block> pbit( pgpBlocks );
- QStrListIterator npbit( nonPgpBlocks );
- QTextCodec *codec;
+ TQPtrListIterator<Kpgp::Block> pbit( pgpBlocks );
+ TQStrListIterator npbit( nonPgpBlocks );
+ TQTextCodec *codec;
if ( text )
codec = KGlobal::charsets()->codecForName( text->contentType()->charset() );
else
@@ -421,18 +421,18 @@ void ArticleWidget::displayArticle()
for( ; *pbit != 0; ++pbit, ++npbit ) {
// handle non-pgp block
- QCString str( *npbit );
+ TQCString str( *npbit );
if( !str.isEmpty() ) {
- QStringList lines = QStringList::split( '\n', codec->toUnicode( str ), true );
+ TQStringList lines = TQStringList::split( '\n', codec->toUnicode( str ), true );
displayBodyBlock( lines );
}
// handle pgp block
Kpgp::Block* block = *pbit;
if ( block->type() == Kpgp::ClearsignedBlock )
block->verify();
- QStringList lines = QStringList::split( '\n', codec->toUnicode( block->text() ), true );
+ TQStringList lines = TQStringList::split( '\n', codec->toUnicode( block->text() ), true );
if ( block->isSigned() ) {
- QString signClass = displaySigHeader( block );
+ TQString signClass = displaySigHeader( block );
displayBodyBlock( lines );
displaySigFooter( signClass );
} else {
@@ -440,9 +440,9 @@ void ArticleWidget::displayArticle()
}
}
// deal with the last non-pgp block
- QCString str( *npbit );
+ TQCString str( *npbit );
if( !str.isEmpty() ) {
- QStringList lines = QStringList::split( '\n', codec->toUnicode( str ), true );
+ TQStringList lines = TQStringList::split( '\n', codec->toUnicode( str ), true );
displayBodyBlock( lines );
}
}
@@ -464,7 +464,7 @@ void ArticleWidget::displayArticle()
if ( text && text->hasContent() && !ct->isPartial() ) {
// handle HTML messages
if ( text->contentType()->isHTMLText() ) {
- QString htmlTxt;
+ TQString htmlTxt;
text->decodedText( htmlTxt, true, knGlobals.configManager()->readNewsViewer()->removeTrailingNewlines() );
if ( mShowHtml ) {
// strip </html> & </body>
@@ -486,7 +486,7 @@ void ArticleWidget::displayArticle()
}
else {
if ( !containsPGP ) {
- QStringList lines;
+ TQStringList lines;
text->decodedText( lines, true, knGlobals.configManager()->readNewsViewer()->removeTrailingNewlines() );
displayBodyBlock( lines );
}
@@ -513,12 +513,12 @@ void ArticleWidget::displayArticle()
}
-void ArticleWidget::displayErrorMessage( const QString &msg )
+void ArticleWidget::displayErrorMessage( const TQString &msg )
{
mViewer->begin();
mViewer->setUserStyleSheet( mCSSHelper->cssDefinitions( mFixedFontToggle->isChecked() ) );
mViewer->write( mCSSHelper->htmlHead( mFixedFontToggle->isChecked() ) );
- QString errMsg = msg;
+ TQString errMsg = msg;
mViewer->write( "<b><font size=\"+1\" color=\"red\">" );
mViewer->write( i18n("An error occurred.") );
mViewer->write( "</font></b><hr/><br/>" );
@@ -542,18 +542,18 @@ void ArticleWidget::displayErrorMessage( const QString &msg )
void ArticleWidget::displayHeader()
{
- QString headerHtml;
+ TQString headerHtml;
// full header style
if ( mHeaderStyle == "all" ) {
- QCString head = mArticle->head();
+ TQCString head = mArticle->head();
KMime::Headers::Generic *header = 0;
while ( !head.isEmpty() ) {
header = mArticle->getNextHeader( head );
if ( header ) {
headerHtml += "<tr>";
- headerHtml+=QString( "<td align=\"right\" valign=\"top\"><b>%1</b></td><td width=\"100%\">%2</td></tr>" )
+ headerHtml+=TQString( "<td align=\"right\" valign=\"top\"><b>%1</b></td><td width=\"100%\">%2</td></tr>" )
.arg( toHtmlString( header->type(), None ) + ": " )
.arg( toHtmlString( header->asUnicodeString() , ParseURL ) );
delete header;
@@ -569,8 +569,8 @@ void ArticleWidget::displayHeader()
// standard & fancy header style
KMime::Headers::Base *hb;
- QValueList<KNDisplayedHeader*> dhs = knGlobals.configManager()->displayedHeaders()->headers();
- for ( QValueList<KNDisplayedHeader*>::Iterator it = dhs.begin(); it != dhs.end(); ++it ) {
+ TQValueList<KNDisplayedHeader*> dhs = knGlobals.configManager()->displayedHeaders()->headers();
+ for ( TQValueList<KNDisplayedHeader*>::Iterator it = dhs.begin(); it != dhs.end(); ++it ) {
KNDisplayedHeader *dh = (*it);
hb = mArticle->getHeaderByType(dh->header().latin1());
if ( !hb || hb->is("Subject") || hb->is("Organization") )
@@ -589,7 +589,7 @@ void ArticleWidget::displayHeader()
headerHtml+="<tr><td colspan=\"2\">";
if ( hb->is("From") ) {
- headerHtml += QString( "<a href=\"mailto:%1\">%2</a>")
+ headerHtml += TQString( "<a href=\"mailto:%1\">%2</a>")
.arg( KPIM::getEmailAddress( hb->asUnicodeString() ) )
.arg( toHtmlString( hb->asUnicodeString(), None ) );
KMime::Headers::Base *orgHdr = mArticle->getHeaderByType( "Organization" );
@@ -602,7 +602,7 @@ void ArticleWidget::displayHeader()
KMime::Headers::Date *date=static_cast<KMime::Headers::Date*>(hb);
headerHtml += toHtmlString( KGlobal::locale()->formatDateTime(date->qdt(), false, true), None );
} else if ( hb->is("Newsgroups") ) {
- QString groups = hb->asUnicodeString();
+ TQString groups = hb->asUnicodeString();
groups.replace( ',', ", " );
headerHtml += toHtmlString( groups, ParseURL );
} else
@@ -621,24 +621,24 @@ void ArticleWidget::displayHeader()
}
// X-Face support
- QString xfhead;
+ TQString xfhead;
KMime::Headers::Base *temp = mArticle->getHeaderByType("X-Face");
if (temp)
xfhead = temp->asUnicodeString();
- QString xface = "";
+ TQString xface = "";
if ( !xfhead.isEmpty() ) {
KPIM::KXFace xf;
- xface = QString::fromLatin1( "<div class=\"senderpic\"><img src=\"%1\" width=\"48\" height=\"48\"/></div>" )
+ xface = TQString::fromLatin1( "<div class=\"senderpic\"><img src=\"%1\" width=\"48\" height=\"48\"/></div>" )
.arg( imgToDataUrl( xf.toImage( xfhead ), "PNG" ) );
}
// fancy header style
mViewer->write( "<div class=\"fancy header\"" );
- mViewer->write( QString("<div>") );
+ mViewer->write( TQString("<div>") );
mViewer->write( toHtmlString( mArticle->subject()->asUnicodeString(), ParseURL | FancyFormatting ) );
- mViewer->write( QString("</div>") );
+ mViewer->write( TQString("</div>") );
- QString html = QString("<table class=\"outer\"><tr><td width=\"100%\"><table>");
+ TQString html = TQString("<table class=\"outer\"><tr><td width=\"100%\"><table>");
html += headerHtml;
html+="</td></tr></table></td>";
@@ -651,12 +651,12 @@ void ArticleWidget::displayHeader()
&& knGlobals.configManager()->readNewsViewer()->showRefBar() ) {
html += "<div class=\"spamheader\">";
int refCnt = refs->count(), i = 1;
- QCString id = refs->first();
+ TQCString id = refs->first();
id = id.mid( 1, id.length() - 2 ); // remove <>
- html += QString( "<b>%1</b>" ).arg( i18n("References:") );
+ html += TQString( "<b>%1</b>" ).arg( i18n("References:") );
while ( i <= refCnt ) {
- html += " <a href=\"news:" + QString::fromLatin1( id ) + "\">" + QString::number( i ) + "</a>";
+ html += " <a href=\"news:" + TQString::fromLatin1( id ) + "\">" + TQString::number( i ) + "</a>";
id = refs->next();
id = id.mid( 1, id.length() - 2 ); // remove <>
i++;
@@ -669,17 +669,17 @@ void ArticleWidget::displayHeader()
}
-void ArticleWidget::displayBodyBlock( const QStringList &lines )
+void ArticleWidget::displayBodyBlock( const TQStringList &lines )
{
int oldLevel = -2, newLevel = -2;
bool isSig = false;
- QString line, html;
+ TQString line, html;
KNConfig::ReadNewsViewer *rnv = knGlobals.configManager()->readNewsViewer();
- QString quoteChars = rnv->quoteCharacters().simplifyWhiteSpace();
+ TQString quoteChars = rnv->quoteCharacters().simplifyWhiteSpace();
if (quoteChars.isEmpty())
quoteChars = ">";
- for ( QStringList::const_iterator it = lines.begin(); it != lines.end(); ++it) {
+ for ( TQStringList::const_iterator it = lines.begin(); it != lines.end(); ++it) {
line = (*it);
if ( !line.isEmpty() ) {
// signature found
@@ -732,12 +732,12 @@ void ArticleWidget::displayBodyBlock( const QStringList &lines )
}
-QString ArticleWidget::displaySigHeader( Kpgp::Block* block )
+TQString ArticleWidget::displaySigHeader( Kpgp::Block* block )
{
- QString signClass = "signErr";
- QString signer = block->signatureUserId();
- QCString signerKey = block->signatureKeyId();
- QString message;
+ TQString signClass = "signErr";
+ TQString signer = block->signatureUserId();
+ TQCString signerKey = block->signatureKeyId();
+ TQString message;
if ( signer.isEmpty() ) {
message = i18n( "Message was signed with unknown key 0x%1." )
.arg( signerKey );
@@ -799,7 +799,7 @@ QString ArticleWidget::displaySigHeader( Kpgp::Block* block )
}
}
- QString html = "<table cellspacing=\"1\" cellpadding=\"1\" class=\"" + signClass + "\">";
+ TQString html = "<table cellspacing=\"1\" cellpadding=\"1\" class=\"" + signClass + "\">";
html += "<tr class=\"" + signClass + "H\"><td>";
html += message;
html += "</td></tr><tr class=\"" + signClass + "B\"><td>";
@@ -808,9 +808,9 @@ QString ArticleWidget::displaySigHeader( Kpgp::Block* block )
}
-void ArticleWidget::displaySigFooter( const QString &signClass )
+void ArticleWidget::displaySigFooter( const TQString &signClass )
{
- QString html = "</td></tr><tr class=\"" + signClass + "H\">";
+ TQString html = "</td></tr><tr class=\"" + signClass + "H\">";
html += "<td>" + i18n( "End of signed message" ) + "</td></tr></table>";
mViewer->write( html );
}
@@ -821,26 +821,26 @@ void ArticleWidget::displayAttachment( KMime::Content *att, int partNum )
if ( mAttachmentStyle == "hide" )
return;
- QString html;
+ TQString html;
KMime::Headers::ContentType *ct = att->contentType();
// attachment label
- QString label = ct->name();
+ TQString label = ct->name();
if ( label.isEmpty() )
label = i18n("unnamed" );
// if label consists of only whitespace replace them by underscores
if ( (uint)label.contains( ' ' ) == label.length() )
- label.replace( QRegExp( " ", true, true ), "_" );
+ label.replace( TQRegExp( " ", true, true ), "_" );
label = toHtmlString( label, None );
// attachment comment
- QString comment = att->contentDescription()->asUnicodeString();
+ TQString comment = att->contentDescription()->asUnicodeString();
comment = toHtmlString( comment, ParseURL | FancyFormatting );
- QString href;
- QString fileName = writeAttachmentToTempFile( att, partNum );
+ TQString href;
+ TQString fileName = writeAttachmentToTempFile( att, partNum );
if ( fileName.isEmpty() ) {
- href = "part://" + QString::number( partNum );
+ href = "part://" + TQString::number( partNum );
} else {
href = "file:" + KURL::encode_string( fileName );
mAttachementMap[fileName] = partNum;
@@ -861,7 +861,7 @@ void ArticleWidget::displayAttachment( KMime::Content *att, int partNum )
html += "<br>" + comment;
html += "</td></tr><tr class=\"textAtmB\"><td>";
// content
- QString tmp;
+ TQString tmp;
att->decodedText( tmp );
/*if( ct->isHTMLText() )
// ### to dangerous, we should use the same stuff as for the main text here
@@ -872,10 +872,10 @@ void ArticleWidget::displayAttachment( KMime::Content *att, int partNum )
html += "</td></tr></table>";
}
} else { // icon
- QCString mimetype = ct->mimeType();
+ TQCString mimetype = ct->mimeType();
KPIM::kAsciiToLower( mimetype.data() );
- QString iconName = KMimeType::mimeType( mimetype )->icon( QString::null, false );
- QString iconFile = KGlobal::instance()->iconLoader()->iconPath( iconName, KIcon::Desktop );
+ TQString iconName = KMimeType::mimeType( mimetype )->icon( TQString::null, false );
+ TQString iconFile = KGlobal::instance()->iconLoader()->iconPath( iconName, KIcon::Desktop );
html += "<div><a href=\"" + href + "\"><img src=\"" +
iconFile + "\" border=\"0\">" + label +
"</a></div><div>" + comment + "</div><br>";
@@ -884,14 +884,14 @@ void ArticleWidget::displayAttachment( KMime::Content *att, int partNum )
}
-QString ArticleWidget::toHtmlString( const QString &line, int flags )
+TQString ArticleWidget::toHtmlString( const TQString &line, int flags )
{
int llflags = LinkLocator::PreserveSpaces;
if ( !(flags & ArticleWidget::ParseURL) )
llflags |= LinkLocator::IgnoreUrls;
if ( mFancyToggle->isChecked() && (flags & ArticleWidget::FancyFormatting) )
llflags |= LinkLocator::ReplaceSmileys | LinkLocator::HighlightText;
- QString text = line;
+ TQString text = line;
if ( flags & ArticleWidget::AllowROT13 ) {
if ( mRot13 )
text = KNHelper::rot13( line );
@@ -901,19 +901,19 @@ QString ArticleWidget::toHtmlString( const QString &line, int flags )
// from KMail headerstyle.cpp
-QString ArticleWidget::imgToDataUrl( const QImage &image, const char* fmt )
+TQString ArticleWidget::imgToDataUrl( const TQImage &image, const char* fmt )
{
- QByteArray ba;
- QBuffer buffer( ba );
+ TQByteArray ba;
+ TQBuffer buffer( ba );
buffer.open( IO_WriteOnly );
image.save( &buffer, fmt );
- return QString::fromLatin1("data:image/%1;base64,%2")
+ return TQString::fromLatin1("data:image/%1;base64,%2")
.arg( fmt, KCodecs::base64Encode( ba ) );
}
-int ArticleWidget::quotingDepth( const QString &line, const QString &quoteChars )
+int ArticleWidget::quotingDepth( const TQString &line, const TQString &quoteChars )
{
int level = -1;
for ( uint i = 0; i < line.length(); ++i ) {
@@ -936,7 +936,7 @@ bool ArticleWidget::inlinePossible( KMime::Content *c )
}
-bool ArticleWidget::canDecodeText( const QCString &charset ) const
+bool ArticleWidget::canDecodeText( const TQCString &charset ) const
{
if ( charset.isEmpty() )
return false;
@@ -961,26 +961,26 @@ void ArticleWidget::updateContents()
-QString ArticleWidget::writeAttachmentToTempFile( KMime::Content *att, int partNum )
+TQString ArticleWidget::writeAttachmentToTempFile( KMime::Content *att, int partNum )
{
// more or less KMail code
- KTempFile *tempFile = new KTempFile( QString::null, "." + QString::number( partNum ) );
+ KTempFile *tempFile = new KTempFile( TQString::null, "." + TQString::number( partNum ) );
tempFile->setAutoDelete( true );
- QString fname = tempFile->name();
+ TQString fname = tempFile->name();
delete tempFile;
- if( ::access( QFile::encodeName( fname ), W_OK ) != 0 )
+ if( ::access( TQFile::encodeName( fname ), W_OK ) != 0 )
// Not there or not writable
- if( ::mkdir( QFile::encodeName( fname ), 0 ) != 0
- || ::chmod( QFile::encodeName( fname ), S_IRWXU ) != 0 )
- return QString::null; //failed create
+ if( ::mkdir( TQFile::encodeName( fname ), 0 ) != 0
+ || ::chmod( TQFile::encodeName( fname ), S_IRWXU ) != 0 )
+ return TQString::null; //failed create
Q_ASSERT( !fname.isNull() );
mTempDirs.append( fname );
// strip off a leading path
KMime::Headers::ContentType* ct = att->contentType();
- QString attName = ct->name();
+ TQString attName = ct->name();
int slashPos = attName.findRev( '/' );
if( -1 != slashPos )
attName = attName.mid( slashPos + 1 );
@@ -988,16 +988,16 @@ QString ArticleWidget::writeAttachmentToTempFile( KMime::Content *att, int partN
attName = "unnamed";
fname += "/" + attName;
- QByteArray data = att->decodedContent();
+ TQByteArray data = att->decodedContent();
size_t size = data.size();
// ### KMail does crlf2lf conversion here before writing the file
if( !KPIM::kBytesToFile( data.data(), size, fname, false, false, false ) )
- return QString::null;
+ return TQString::null;
mTempFiles.append( fname );
// make file read-only so that nobody gets the impression that he might
// edit attached files
- ::chmod( QFile::encodeName( fname ), S_IRUSR );
+ ::chmod( TQFile::encodeName( fname ), S_IRUSR );
return fname;
}
@@ -1005,11 +1005,11 @@ QString ArticleWidget::writeAttachmentToTempFile( KMime::Content *att, int partN
void ArticleWidget::removeTempFiles( )
{
- for ( QStringList::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it )
- QFile::remove(*it);
+ for ( TQStringList::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it )
+ TQFile::remove(*it);
mTempFiles.clear();
- for ( QStringList::Iterator it = mTempDirs.begin(); it != mTempDirs.end(); ++it )
- QDir(*it).rmdir(*it);
+ for ( TQStringList::Iterator it = mTempDirs.begin(); it != mTempDirs.end(); ++it )
+ TQDir(*it).rmdir(*it);
mTempDirs.clear();
}
@@ -1035,7 +1035,7 @@ void ArticleWidget::processJob( KNJobData * job )
-typedef QValueList<ArticleWidget*>::ConstIterator InstanceIterator;
+typedef TQValueList<ArticleWidget*>::ConstIterator InstanceIterator;
void ArticleWidget::configChanged()
{
@@ -1071,7 +1071,7 @@ void ArticleWidget::articleChanged( KNArticle *article )
}
-void ArticleWidget::articleLoadError( KNArticle *article, const QString &error )
+void ArticleWidget::articleLoadError( KNArticle *article, const TQString &error )
{
for ( InstanceIterator it = mInstances.begin(); it != mInstances.end(); ++it )
if ( (*it)->article() == article )
@@ -1171,10 +1171,10 @@ void ArticleWidget::slotURLClicked( const KURL &url, bool forceOpen)
}
-void ArticleWidget::slotURLPopup( const QString &url, const QPoint &point )
+void ArticleWidget::slotURLPopup( const TQString &url, const TQPoint &point )
{
mCurrentURL = KURL( url );
- QString popupName;
+ TQString popupName;
if ( url.isEmpty() ) // plain text
popupName = "body_popup";
else if ( mCurrentURL.protocol() == "mailto" )
@@ -1186,7 +1186,7 @@ void ArticleWidget::slotURLPopup( const QString &url, const QPoint &point )
return; // skip
else
popupName = "url_popup"; // all other URLs
- QPopupMenu *popup = static_cast<QPopupMenu*>( mGuiClient->factory()->container( popupName, mGuiClient ) );
+ TQPopupMenu *popup = static_cast<TQPopupMenu*>( mGuiClient->factory()->container( popupName, mGuiClient ) );
if ( popup )
popup->popup( point );
}
@@ -1354,7 +1354,7 @@ void ArticleWidget::slotToggleRot13()
-void ArticleWidget::slotSetCharset( const QString &charset )
+void ArticleWidget::slotSetCharset( const TQString &charset )
{
if ( charset.isEmpty() )
return;
@@ -1394,20 +1394,20 @@ void ArticleWidget::slotOpenURL()
void ArticleWidget::slotCopyURL()
{
- QString address;
+ TQString address;
if ( mCurrentURL.protocol() == "mailto" )
address = mCurrentURL.path();
else
address = mCurrentURL.url();
- QApplication::clipboard()->setText( address, QClipboard::Clipboard );
- QApplication::clipboard()->setText( address, QClipboard::Selection );
+ TQApplication::clipboard()->setText( address, QClipboard::Clipboard );
+ TQApplication::clipboard()->setText( address, QClipboard::Selection );
}
void ArticleWidget::slotAddBookmark()
{
if ( mCurrentURL.isEmpty() )
return;
- QString filename = locateLocal( "data", QString::fromLatin1("konqueror/bookmarks.xml") );
+ TQString filename = locateLocal( "data", TQString::fromLatin1("konqueror/bookmarks.xml") );
KBookmarkManager *bookManager = KBookmarkManager::managerForFile( filename, false );
KBookmarkGroup group = bookManager->root();
group.addBookmark( bookManager, mCurrentURL.url(), mCurrentURL );
@@ -1449,26 +1449,26 @@ void ArticleWidget::slotSaveAttachment()
-void ArticleWidget::focusInEvent( QFocusEvent *e )
+void ArticleWidget::focusInEvent( TQFocusEvent *e )
{
emit focusChanged(e);
- QWidget::focusInEvent(e);
+ TQWidget::focusInEvent(e);
}
-void ArticleWidget::focusOutEvent( QFocusEvent *e )
+void ArticleWidget::focusOutEvent( TQFocusEvent *e )
{
emit focusChanged(e);
- QWidget::focusOutEvent(e);
+ TQWidget::focusOutEvent(e);
}
-bool ArticleWidget::eventFilter( QObject *o, QEvent *e )
+bool ArticleWidget::eventFilter( TQObject *o, TQEvent *e )
{
- if ( e->type() == QEvent::KeyPress && (static_cast<QKeyEvent*>(e)->key() == Key_Tab) ) {
+ if ( e->type() == TQEvent::KeyPress && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab) ) {
emit focusChangeRequest( this );
if ( !hasFocus() ) // focusChangeRequest was successful
return true;
}
- return QWidget::eventFilter(o, e);
+ return TQWidget::eventFilter(o, e);
}
#include "articlewidget.moc"
diff --git a/knode/articlewidget.h b/knode/articlewidget.h
index d22926196..66e4106ec 100644
--- a/knode/articlewidget.h
+++ b/knode/articlewidget.h
@@ -14,9 +14,9 @@
#ifndef KNODE_ARTICLEWIDGET_H
#define KNODE_ARTICLEWIDGET_H
-#include <qmap.h>
-#include <qvaluelist.h>
-#include <qwidget.h>
+#include <tqmap.h>
+#include <tqvaluelist.h>
+#include <tqwidget.h>
#include <kurl.h>
@@ -50,13 +50,13 @@ class CSSHelper;
/**
Widget to display a news article
*/
-class ArticleWidget : public QWidget, public KNJobConsumer {
+class ArticleWidget : public TQWidget, public KNJobConsumer {
Q_OBJECT
public:
/// Construct a new article widget
- ArticleWidget( QWidget *parent,
+ ArticleWidget( TQWidget *parent,
KXMLGUIClient *guiClient,
KActionCollection *actionCollection,
const char *name = 0 );
@@ -83,7 +83,7 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
/// notify all instances that the given article has changed
static void articleChanged( KNArticle *article );
/// notify all instances about an error during loading the given article
- static void articleLoadError( KNArticle *article, const QString &error );
+ static void articleLoadError( KNArticle *article, const TQString &error );
/// notify all instances that the given collection has been removed
static void collectionRemoved( KNArticleCollection *coll );
/// cleanup all instances
@@ -99,16 +99,16 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
void scrollNext();
signals:
- void focusChanged( QFocusEvent* );
- void focusChangeRequest( QWidget* );
+ void focusChanged( TQFocusEvent* );
+ void focusChangeRequest( TQWidget* );
protected:
/// process download jobs for view source action
void processJob( KNJobData *j );
- virtual void focusInEvent( QFocusEvent *e );
- virtual void focusOutEvent( QFocusEvent *e );
- virtual bool eventFilter( QObject *o, QEvent *e );
+ virtual void focusInEvent( TQFocusEvent *e );
+ virtual void focusOutEvent( TQFocusEvent *e );
+ virtual bool eventFilter( TQObject *o, TQEvent *e );
private:
void initActions();
@@ -123,18 +123,18 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
/// displays the current article or clears the view if no article is set
void displayArticle();
/// displays the given error message in the viewer
- void displayErrorMessage( const QString &msg );
+ void displayErrorMessage( const TQString &msg );
/// display the message header (should be replaced by KMail's HeaderStyle class)
void displayHeader();
/** displays the given text block, including quote and signature handling
* @param lines A list of lines to display.
*/
- void displayBodyBlock( const QStringList &lines );
+ void displayBodyBlock( const TQStringList &lines );
/// displays a signature block header
- QString displaySigHeader( Kpgp::Block* block );
+ TQString displaySigHeader( Kpgp::Block* block );
/// displays a signature footer
- void displaySigFooter( const QString &signClass );
+ void displaySigFooter( const TQString &signClass );
/// displays the given attachment
void displayAttachment( KMime::Content *att, int partNum );
@@ -146,18 +146,18 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
AllowROT13 = 4
};
/// convert the given string into an HTML string
- QString toHtmlString( const QString &line, int flags = ParseURL );
+ TQString toHtmlString( const TQString &line, int flags = ParseURL );
/// convert the given image into a data:/ URL
- static QString imgToDataUrl( const QImage &image, const char* fmt );
+ static TQString imgToDataUrl( const TQImage &image, const char* fmt );
/** calculates the quoting depth of the given line
* @returns -1 if no quoting was found, the quoting level otherwise
*/
- static int quotingDepth( const QString &line, const QString &quoteChars );
+ static int quotingDepth( const TQString &line, const TQString &quoteChars );
/// checks wether the given attachment can be shown inline
bool inlinePossible( KMime::Content *c );
/// checks if the given charset is supported
- bool canDecodeText( const QCString &charset ) const;
+ bool canDecodeText( const TQCString &charset ) const;
/// regenerated viewer content without changing scrollbar position
void updateContents();
@@ -165,7 +165,7 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
/** stores the given attachment into a temporary file
* @returns the filename the attachment has been stored to
*/
- QString writeAttachmentToTempFile( KMime::Content *att, int partNum );
+ TQString writeAttachmentToTempFile( KMime::Content *att, int partNum );
/// removes all temporary files
void removeTempFiles();
@@ -173,7 +173,7 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
/// called if the user clicked on an URL
void slotURLClicked( const KURL &url, bool forceOpen = false );
/// called if the user RMB clicked on an URL
- void slotURLPopup( const QString &url, const QPoint &point );
+ void slotURLPopup( const TQString &url, const TQPoint &point );
/// mark as read timeout
void slotTimeout();
@@ -201,7 +201,7 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
void slotInlineAttachments();
void slotHideAttachments();
- void slotSetCharset( const QString &charset );
+ void slotSetCharset( const TQString &charset );
void slotSetCharsetKeyboard();
void slotOpenURL();
@@ -218,28 +218,28 @@ class ArticleWidget : public QWidget, public KNJobConsumer {
/// attachments of the current article
KMime::Content::List mAttachments;
/// mapping of temporary file names to part numbers
- QMap<QString, int> mAttachementMap;
+ TQMap<TQString, int> mAttachementMap;
KHTMLPart *mViewer;
CSSHelper *mCSSHelper;
- QStringList mTempDirs, mTempFiles;
+ TQStringList mTempDirs, mTempFiles;
- QString mHeaderStyle;
- QString mAttachmentStyle;
+ TQString mHeaderStyle;
+ TQString mAttachmentStyle;
bool mShowHtml;
bool mRot13;
bool mForceCharset;
- QCString mOverrideCharset;
+ TQCString mOverrideCharset;
/// mark as read timer
- QTimer *mTimer;
+ TQTimer *mTimer;
/// the last RMB clicked URL
KURL mCurrentURL;
/// list of all instances of this class
- static QValueList<ArticleWidget*> mInstances;
+ static TQValueList<ArticleWidget*> mInstances;
KXMLGUIClient *mGuiClient;
KActionCollection *mActionCollection;
diff --git a/knode/csshelper.cpp b/knode/csshelper.cpp
index 144d52bc8..04fcbb6a8 100644
--- a/knode/csshelper.cpp
+++ b/knode/csshelper.cpp
@@ -17,7 +17,7 @@
#include "knglobals.h"
-KNode::CSSHelper::CSSHelper( const QPaintDeviceMetrics &pdm ) :
+KNode::CSSHelper::CSSHelper( const TQPaintDeviceMetrics &pdm ) :
KPIM::CSSHelper( pdm )
{
KNConfig::Appearance *app = knGlobals.configManager()->appearance();
diff --git a/knode/csshelper.h b/knode/csshelper.h
index 23b2216a0..1ad63470e 100644
--- a/knode/csshelper.h
+++ b/knode/csshelper.h
@@ -21,7 +21,7 @@ namespace KNode {
class CSSHelper : public KPIM::CSSHelper
{
public:
- CSSHelper( const QPaintDeviceMetrics &pdm );
+ CSSHelper( const TQPaintDeviceMetrics &pdm );
};
diff --git a/knode/headerview.cpp b/knode/headerview.cpp
index aef02f13a..ede75bb66 100644
--- a/knode/headerview.cpp
+++ b/knode/headerview.cpp
@@ -12,10 +12,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qcursor.h>
-#include <qheader.h>
-#include <qstylesheet.h>
-#include <qtimer.h>
+#include <tqcursor.h>
+#include <tqheader.h>
+#include <tqstylesheet.h>
+#include <tqtimer.h>
#include <klocale.h>
#include <kdebug.h>
@@ -32,7 +32,7 @@
#include "knmainwidget.h"
-KNHeaderView::KNHeaderView(QWidget *parent, const char *name) :
+KNHeaderView::KNHeaderView(TQWidget *parent, const char *name) :
KListView(parent,name),
mSortCol( -1 ),
mSortAsc( true ),
@@ -55,7 +55,7 @@ KNHeaderView::KNHeaderView(QWidget *parent, const char *name) :
setAcceptDrops( false );
setDragEnabled( true );
setAllColumnsShowFocus( true );
- setSelectionMode( QListView::Extended );
+ setSelectionMode( TQListView::Extended );
setShowSortIndicator( true );
setShadeSortColumn ( true );
setRootIsDecorated( true );
@@ -65,9 +65,9 @@ KNHeaderView::KNHeaderView(QWidget *parent, const char *name) :
setColumnAlignment( mPaintInfo.scoreCol, Qt::AlignRight );
// due to our own column text squeezing we need to repaint on column resizing
- disconnect( header(), SIGNAL(sizeChange(int, int, int)) );
- connect( header(), SIGNAL(sizeChange(int, int, int)),
- SLOT(slotSizeChanged(int, int, int)) );
+ disconnect( header(), TQT_SIGNAL(sizeChange(int, int, int)) );
+ connect( header(), TQT_SIGNAL(sizeChange(int, int, int)),
+ TQT_SLOT(slotSizeChanged(int, int, int)) );
// column selection RMB menu
mPopup = new KPopupMenu( this );
@@ -76,11 +76,11 @@ KNHeaderView::KNHeaderView(QWidget *parent, const char *name) :
mPopup->insertItem( i18n("Line Count"), KPaintInfo::COL_SIZE );
mPopup->insertItem( i18n("Score"), KPaintInfo::COL_SCORE );
- connect( mPopup, SIGNAL(activated(int)), this, SLOT(toggleColumn(int)) );
+ connect( mPopup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(toggleColumn(int)) );
// connect to the article manager
- connect( knGlobals.articleManager(), SIGNAL(aboutToShowGroup()), SLOT(prepareForGroup()) );
- connect( knGlobals.articleManager(), SIGNAL(aboutToShowFolder()), SLOT(prepareForFolder()) );
+ connect( knGlobals.articleManager(), TQT_SIGNAL(aboutToShowGroup()), TQT_SLOT(prepareForGroup()) );
+ connect( knGlobals.articleManager(), TQT_SIGNAL(aboutToShowFolder()), TQT_SLOT(prepareForFolder()) );
new KNHeaderViewToolTip( this );
@@ -114,9 +114,9 @@ void KNHeaderView::readConfig()
mDateFormatter.setFormat( rngConf->dateFormat() );
KNConfig::Appearance *app = knGlobals.configManager()->appearance();
- QPalette p = palette();
- p.setColor( QColorGroup::Base, app->backgroundColor() );
- p.setColor( QColorGroup::Text, app->textColor() );
+ TQPalette p = palette();
+ p.setColor( TQColorGroup::Base, app->backgroundColor() );
+ p.setColor( TQColorGroup::Text, app->textColor() );
setPalette( p );
setAlternateBackground( app->alternateBackgroundColor() );
setFont( app->articleListFont() );
@@ -137,7 +137,7 @@ void KNHeaderView::writeConfig()
}
-void KNHeaderView::setActive( QListViewItem *i )
+void KNHeaderView::setActive( TQListViewItem *i )
{
KNHdrViewItem *item = static_cast<KNHdrViewItem*>( i );
@@ -162,16 +162,16 @@ void KNHeaderView::setActive( QListViewItem *i )
void KNHeaderView::clear()
{
mActiveItem = 0;
- QListView::clear();
+ TQListView::clear();
}
-void KNHeaderView::ensureItemVisibleWithMargin( const QListViewItem *i )
+void KNHeaderView::ensureItemVisibleWithMargin( const TQListViewItem *i )
{
if ( !i )
return;
- QListViewItem *parent = i->parent();
+ TQListViewItem *parent = i->parent();
while ( parent ) {
if ( !parent->isOpen() )
parent->setOpen( true );
@@ -188,7 +188,7 @@ void KNHeaderView::ensureItemVisibleWithMargin( const QListViewItem *i )
{
ensureVisible( contentsX(), y + h/2, 0, h/2 );
mDelayedCenter = y + h/2;
- QTimer::singleShot( 300, this, SLOT(slotCenterDelayed()) );
+ TQTimer::singleShot( 300, this, TQT_SLOT(slotCenterDelayed()) );
} else {
ensureVisible( contentsX(), y + h/2, 0, h/2 );
}
@@ -267,7 +267,7 @@ void KNHeaderView::prevArticle()
void KNHeaderView::incCurrentArticle()
{
- QListViewItem *lvi = currentItem();
+ TQListViewItem *lvi = currentItem();
if ( lvi && lvi->isExpandable() )
lvi->setOpen( true );
if ( lvi && lvi->itemBelow() ) {
@@ -279,7 +279,7 @@ void KNHeaderView::incCurrentArticle()
void KNHeaderView::decCurrentArticle()
{
- QListViewItem *lvi = currentItem();
+ TQListViewItem *lvi = currentItem();
if ( lvi && lvi->itemAbove() ) {
if ( lvi->itemAbove()->isExpandable() )
lvi->itemAbove()->setOpen( true );
@@ -451,24 +451,24 @@ void KNHeaderView::prepareForFolder()
}
-bool KNHeaderView::event( QEvent *e )
+bool KNHeaderView::event( TQEvent *e )
{
// we don't want to have the alternate list background restored
// to the system defaults!
- if (e->type() == QEvent::ApplicationPaletteChange)
- return QListView::event(e);
+ if (e->type() == TQEvent::ApplicationPaletteChange)
+ return TQListView::event(e);
else
return KListView::event(e);
}
-void KNHeaderView::contentsMousePressEvent( QMouseEvent *e )
+void KNHeaderView::contentsMousePressEvent( TQMouseEvent *e )
{
if (!e) return;
bool selectMode=(( e->state() & ShiftButton ) || ( e->state() & ControlButton ));
- QPoint vp = contentsToViewport(e->pos());
- QListViewItem *i = itemAt(vp);
+ TQPoint vp = contentsToViewport(e->pos());
+ TQListViewItem *i = itemAt(vp);
KListView::contentsMousePressEvent( e );
@@ -485,11 +485,11 @@ void KNHeaderView::contentsMousePressEvent( QMouseEvent *e )
}
-void KNHeaderView::contentsMouseDoubleClickEvent( QMouseEvent *e )
+void KNHeaderView::contentsMouseDoubleClickEvent( TQMouseEvent *e )
{
if (!e) return;
- QListViewItem *i = itemAt( contentsToViewport(e->pos()) );
+ TQListViewItem *i = itemAt( contentsToViewport(e->pos()) );
if (i) {
emit doubleClick( i );
return;
@@ -499,11 +499,11 @@ void KNHeaderView::contentsMouseDoubleClickEvent( QMouseEvent *e )
}
-void KNHeaderView::keyPressEvent(QKeyEvent *e)
+void KNHeaderView::keyPressEvent(TQKeyEvent *e)
{
if (!e) return;
- QListViewItem *i = currentItem();
+ TQListViewItem *i = currentItem();
switch(e->key()) {
case Key_Space:
@@ -522,9 +522,9 @@ void KNHeaderView::keyPressEvent(QKeyEvent *e)
}
-QDragObject* KNHeaderView::dragObject()
+TQDragObject* KNHeaderView::dragObject()
{
- KNHdrViewItem *item = static_cast<KNHdrViewItem*>( itemAt(viewport()->mapFromGlobal(QCursor::pos())) );
+ KNHdrViewItem *item = static_cast<KNHdrViewItem*>( itemAt(viewport()->mapFromGlobal(TQCursor::pos())) );
if (item)
return item->dragObject();
else
@@ -538,20 +538,20 @@ void KNHeaderView::slotSizeChanged( int section, int, int newSize )
}
-bool KNHeaderView::eventFilter(QObject *o, QEvent *e)
+bool KNHeaderView::eventFilter(TQObject *o, TQEvent *e)
{
- if ((e->type() == QEvent::KeyPress) && (static_cast<QKeyEvent*>(e)->key() == Key_Tab)) {
+ if ((e->type() == TQEvent::KeyPress) && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab)) {
emit(focusChangeRequest(this));
if (!hasFocus()) // focusChangeRequest was successful
return true;
}
// right click on header
- if ( e->type() == QEvent::MouseButtonPress &&
- static_cast<QMouseEvent*>(e)->button() == RightButton &&
- o->isA("QHeader") )
+ if ( e->type() == TQEvent::MouseButtonPress &&
+ static_cast<TQMouseEvent*>(e)->button() == RightButton &&
+ o->isA("TQHeader") )
{
- mPopup->popup( static_cast<QMouseEvent*>(e)->globalPos() );
+ mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() );
return true;
}
@@ -559,16 +559,16 @@ bool KNHeaderView::eventFilter(QObject *o, QEvent *e)
}
-void KNHeaderView::focusInEvent(QFocusEvent *e)
+void KNHeaderView::focusInEvent(TQFocusEvent *e)
{
- QListView::focusInEvent(e);
+ TQListView::focusInEvent(e);
emit focusChanged(e);
}
-void KNHeaderView::focusOutEvent(QFocusEvent *e)
+void KNHeaderView::focusOutEvent(TQFocusEvent *e)
{
- QListView::focusOutEvent(e);
+ TQListView::focusOutEvent(e);
emit focusChanged(e);
}
@@ -576,20 +576,20 @@ void KNHeaderView::focusOutEvent(QFocusEvent *e)
void KNHeaderView::resetCurrentTime()
{
mDateFormatter.reset();
- QTimer::singleShot( 1000, this, SLOT(resetCurrentTime()) );
+ TQTimer::singleShot( 1000, this, TQT_SLOT(resetCurrentTime()) );
}
//BEGIN: KNHeaderViewToolTip ==================================================
KNHeaderViewToolTip::KNHeaderViewToolTip( KNHeaderView *parent ) :
- QToolTip( parent->viewport() ),
+ TQToolTip( parent->viewport() ),
listView( parent )
{
}
-void KNHeaderViewToolTip::maybeTip( const QPoint &p )
+void KNHeaderViewToolTip::maybeTip( const TQPoint &p )
{
const KNHdrViewItem *item = static_cast<KNHdrViewItem*>( listView->itemAt( p ) );
if ( !item )
@@ -601,15 +601,15 @@ void KNHeaderViewToolTip::maybeTip( const QPoint &p )
if ( !item->showToolTip( column ) )
return;
- const QRect itemRect = listView->itemRect( item );
+ const TQRect itemRect = listView->itemRect( item );
if ( !itemRect.isValid() )
return;
- const QRect headerRect = listView->header()->sectionRect( column );
+ const TQRect headerRect = listView->header()->sectionRect( column );
if ( !headerRect.isValid() )
return;
- tip( QRect( headerRect.left(), itemRect.top(), headerRect.width(), itemRect.height() ),
- QStyleSheet::escape( item->text( column ) ) );
+ tip( TQRect( headerRect.left(), itemRect.top(), headerRect.width(), itemRect.height() ),
+ TQStyleSheet::escape( item->text( column ) ) );
}
//END: KNHeaderViewToolTip ====================================================
diff --git a/knode/headerview.h b/knode/headerview.h
index 411258d2f..519b7d84e 100644
--- a/knode/headerview.h
+++ b/knode/headerview.h
@@ -15,7 +15,7 @@
#ifndef KNHEADERVIEW_H
#define KNHEADERVIEW_H
-#include <qtooltip.h>
+#include <tqtooltip.h>
#include <klistview.h>
#include <kfoldertree.h>
@@ -31,13 +31,13 @@ class KNHeaderView : public KListView {
friend class KNHdrViewItem;
public:
- KNHeaderView( QWidget *parent, const char *name = 0 );
+ KNHeaderView( TQWidget *parent, const char *name = 0 );
~KNHeaderView();
- void setActive( QListViewItem *item );
+ void setActive( TQListViewItem *item );
void clear();
- void ensureItemVisibleWithMargin( const QListViewItem *i );
+ void ensureItemVisibleWithMargin( const TQListViewItem *i );
virtual void setSorting( int column, bool ascending = true );
bool sortByThreadChangeDate() const { return mSortByThreadChangeDate; }
@@ -52,11 +52,11 @@ class KNHeaderView : public KListView {
const KPaintInfo* paintInfo() const { return &mPaintInfo; }
signals:
- void itemSelected( QListViewItem* );
- void doubleClick( QListViewItem* );
+ void itemSelected( TQListViewItem* );
+ void doubleClick( TQListViewItem* );
void sortingChanged( int );
- void focusChanged( QFocusEvent* );
- void focusChangeRequest( QWidget* );
+ void focusChanged( TQFocusEvent* );
+ void focusChangeRequest( TQWidget* );
public slots:
void nextArticle();
@@ -75,14 +75,14 @@ class KNHeaderView : public KListView {
* Reimplemented to avoid that KListview reloads the alternate
* background on palette changes.
*/
- virtual bool event( QEvent *e );
- void contentsMousePressEvent( QMouseEvent *e );
- void contentsMouseDoubleClickEvent( QMouseEvent *e );
- void keyPressEvent( QKeyEvent *e );
- bool eventFilter( QObject *, QEvent * );
- void focusInEvent( QFocusEvent *e );
- void focusOutEvent( QFocusEvent *e );
- virtual QDragObject* dragObject();
+ virtual bool event( TQEvent *e );
+ void contentsMousePressEvent( TQMouseEvent *e );
+ void contentsMouseDoubleClickEvent( TQMouseEvent *e );
+ void keyPressEvent( TQKeyEvent *e );
+ bool eventFilter( TQObject *, TQEvent * );
+ void focusInEvent( TQFocusEvent *e );
+ void focusOutEvent( TQFocusEvent *e );
+ virtual TQDragObject* dragObject();
private:
int mSortCol;
@@ -104,13 +104,13 @@ class KNHeaderView : public KListView {
};
-class KNHeaderViewToolTip : public QToolTip {
+class KNHeaderViewToolTip : public TQToolTip {
public:
KNHeaderViewToolTip( KNHeaderView *parent );
protected:
- void maybeTip( const QPoint &p );
+ void maybeTip( const TQPoint &p );
private:
KNHeaderView *listView;
diff --git a/knode/knaccountmanager.cpp b/knode/knaccountmanager.cpp
index be43e56b0..167a49c65 100644
--- a/knode/knaccountmanager.cpp
+++ b/knode/knaccountmanager.cpp
@@ -14,7 +14,7 @@
#include <stdlib.h>
-#include <qdir.h>
+#include <tqdir.h>
#include <kdebug.h>
#include <ksimpleconfig.h>
@@ -34,8 +34,8 @@
KWallet::Wallet* KNAccountManager::mWallet = 0;
bool KNAccountManager::mWalletOpenFailed = false;
-KNAccountManager::KNAccountManager(KNGroupManager *gm, QObject * parent, const char * name)
- : QObject(parent, name), gManager(gm), c_urrentAccount(0),
+KNAccountManager::KNAccountManager(KNGroupManager *gm, TQObject * parent, const char * name)
+ : TQObject(parent, name), gManager(gm), c_urrentAccount(0),
mAsyncOpening( false )
{
s_mtp = new KNServerInfo();
@@ -51,7 +51,7 @@ KNAccountManager::KNAccountManager(KNGroupManager *gm, QObject * parent, const c
KNAccountManager::~KNAccountManager()
{
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = mAccounts.begin(); it != mAccounts.end(); ++it )
delete (*it);
mAccounts.clear();
@@ -63,7 +63,7 @@ KNAccountManager::~KNAccountManager()
void KNAccountManager::prepareShutdown()
{
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = mAccounts.begin(); it != mAccounts.end(); ++it )
(*it)->saveInfo();
}
@@ -71,16 +71,16 @@ void KNAccountManager::prepareShutdown()
void KNAccountManager::loadAccounts()
{
- QString dir(locateLocal("data","knode/"));
+ TQString dir(locateLocal("data","knode/"));
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
}
- QDir d(dir);
+ TQDir d(dir);
KNNntpAccount *a;
- QStringList entries(d.entryList("nntp.*", QDir::Dirs));
+ TQStringList entries(d.entryList("nntp.*", TQDir::Dirs));
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for(it = entries.begin(); it != entries.end(); ++it) {
a = new KNNntpAccount();
if (a->readInfo(dir+(*it) + "/info")) {
@@ -99,7 +99,7 @@ KNNntpAccount* KNAccountManager::account( int id )
{
if ( id <= 0 )
return 0;
- QValueList<KNNntpAccount*>::ConstIterator it;
+ TQValueList<KNNntpAccount*>::ConstIterator it;
for ( it = mAccounts.begin(); it != mAccounts.end(); ++it )
if ( (*it)->id() == id )
return *it;
@@ -117,22 +117,22 @@ void KNAccountManager::setCurrentAccount(KNNntpAccount *a)
bool KNAccountManager::newAccount(KNNntpAccount *a)
{
// find a unused id for the new account...
- QString dir(locateLocal("data","knode/"));
+ TQString dir(locateLocal("data","knode/"));
if (dir.isNull()) {
delete a;
KNHelper::displayInternalFileError();
return false;
}
- QDir d(dir);
- QStringList entries(d.entryList("nntp.*", QDir::Dirs));
+ TQDir d(dir);
+ TQStringList entries(d.entryList("nntp.*", TQDir::Dirs));
int id = 1;
- while (entries.findIndex(QString("nntp.%1").arg(id))!=-1)
+ while (entries.findIndex(TQString("nntp.%1").arg(id))!=-1)
++id;
a->setId(id);
- dir = locateLocal("data",QString("knode/nntp.%1/").arg(a->id()));
+ dir = locateLocal("data",TQString("knode/nntp.%1/").arg(a->id()));
if (!dir.isNull()) {
mAccounts.append(a);
emit(accountAdded(a));
@@ -151,22 +151,22 @@ bool KNAccountManager::removeAccount(KNNntpAccount *a)
if(!a) a=c_urrentAccount;
if(!a) return false;
- QValueList<KNGroup*> lst;
+ TQValueList<KNGroup*> lst;
if(knGlobals.folderManager()->unsentForAccount(a->id()) > 0) {
KMessageBox::sorry(knGlobals.topWidget, i18n("This account cannot be deleted since there are some unsent messages for it."));
}
else if(KMessageBox::warningContinueCancel(knGlobals.topWidget, i18n("Do you really want to delete this account?"),"",KGuiItem(i18n("&Delete"),"editdelete"))==KMessageBox::Continue) {
lst = gManager->groupsOfAccount( a );
- for ( QValueList<KNGroup*>::Iterator it = lst.begin(); it != lst.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = lst.begin(); it != lst.end(); ++it ) {
if ( (*it)->isLocked() ) {
KMessageBox::sorry(knGlobals.topWidget, i18n("At least one group of this account is currently in use.\nThe account cannot be deleted at the moment."));
return false;
}
}
- for ( QValueList<KNGroup*>::Iterator it = lst.begin(); it != lst.end(); ++it )
+ for ( TQValueList<KNGroup*>::Iterator it = lst.begin(); it != lst.end(); ++it )
gManager->unsubscribeGroup( (*it) );
- QDir dir(a->path());
+ TQDir dir(a->path());
if (dir.exists()) {
const QFileInfoList *list = dir.entryInfoList(); // get list of matching files and delete all
if (list) {
@@ -177,7 +177,7 @@ bool KNAccountManager::removeAccount(KNNntpAccount *a)
}
}
dir.cdUp(); // directory should now be empty, deleting it
- dir.rmdir(QString("nntp.%1/").arg(a->id()));
+ dir.rmdir(TQString("nntp.%1/").arg(a->id()));
}
if(c_urrentAccount==a) setCurrentAccount(0);
@@ -228,7 +228,7 @@ void KNAccountManager::loadPasswordsAsync()
else
mWallet = Wallet::openWallet( Wallet::NetworkWallet(), 0, Wallet::Asynchronous );
if ( mWallet ) {
- connect( mWallet, SIGNAL(walletOpened(bool)), SLOT(slotWalletOpened(bool)) );
+ connect( mWallet, TQT_SIGNAL(walletOpened(bool)), TQT_SLOT(slotWalletOpened(bool)) );
mAsyncOpening = true;
}
else {
@@ -245,7 +245,7 @@ void KNAccountManager::loadPasswordsAsync()
void KNAccountManager::loadPasswords()
{
s_mtp->readPassword();
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = mAccounts.begin(); it != mAccounts.end(); ++it )
(*it)->readPassword();
emit passwordsChanged();
diff --git a/knode/knaccountmanager.h b/knode/knaccountmanager.h
index 5b6cd4ef9..f871e2be8 100644
--- a/knode/knaccountmanager.h
+++ b/knode/knaccountmanager.h
@@ -15,8 +15,8 @@
#ifndef KNACCOUNTMANAGER_H
#define KNACCOUNTMANAGER_H
-#include <qglobal.h>
-#include <qvaluelist.h>
+#include <tqglobal.h>
+#include <tqvaluelist.h>
namespace KWallet {
class Wallet;
@@ -32,7 +32,7 @@ class KNAccountManager : public QObject
Q_OBJECT
public:
- KNAccountManager(KNGroupManager *gm, QObject * parent=0, const char * name=0);
+ KNAccountManager(KNGroupManager *gm, TQObject * parent=0, const char * name=0);
~KNAccountManager();
void prepareShutdown();
@@ -49,8 +49,8 @@ class KNAccountManager : public QObject
KNServerInfo* smtp() const { return s_mtp; }
/** Returns the account with the given id. */
KNNntpAccount* account( int id );
- QValueList<KNNntpAccount*>::Iterator begin() { return mAccounts.begin(); }
- QValueList<KNNntpAccount*>::Iterator end() { return mAccounts.end(); }
+ TQValueList<KNNntpAccount*>::Iterator begin() { return mAccounts.begin(); }
+ TQValueList<KNNntpAccount*>::Iterator end() { return mAccounts.end(); }
/** Returns the first account (used as fallback sometimes). */
KNNntpAccount* first() const;
@@ -83,7 +83,7 @@ class KNAccountManager : public QObject
static void prepareWallet();
private:
- QValueList<KNNntpAccount*> mAccounts;
+ TQValueList<KNNntpAccount*> mAccounts;
static KWallet::Wallet *mWallet;
static bool mWalletOpenFailed;
bool mAsyncOpening;
diff --git a/knode/knapplication.cpp b/knode/knapplication.cpp
index 2bbcf0494..c8b2837f3 100644
--- a/knode/knapplication.cpp
+++ b/knode/knapplication.cpp
@@ -33,7 +33,7 @@ int KNApplication::newInstance()
KConfig *conf=knGlobals.config();
conf->setGroup("GENERAL");
- QString ver=conf->readEntry("Version");
+ TQString ver=conf->readEntry("Version");
if(!ver.isEmpty() && ver!=KNODE_VERSION) { //new version installed
if(KNConvert::needToConvert(ver)) { //we need to convert
diff --git a/knode/knarticle.cpp b/knode/knarticle.cpp
index d43e501ea..fe475b1b3 100644
--- a/knode/knarticle.cpp
+++ b/knode/knarticle.cpp
@@ -85,7 +85,7 @@ KNRemoteArticle::~KNRemoteArticle()
void KNRemoteArticle::parse()
{
KNArticle::parse();
- QCString raw;
+ TQCString raw;
if( !(raw=rawHeader(m_essageID.type())).isEmpty() )
m_essageID.from7BitString(raw);
@@ -168,7 +168,7 @@ void KNRemoteArticle::initListItem()
if(f_rom.hasName())
i_tem->setText(1, f_rom.name());
else
- i_tem->setText(1, QString(f_rom.email()));
+ i_tem->setText(1, TQString(f_rom.email()));
updateListItem();
}
@@ -296,7 +296,7 @@ KNLocalArticle::~KNLocalArticle()
void KNLocalArticle::parse()
{
KNArticle::parse();
- QCString raw;
+ TQCString raw;
if( !(raw=rawHeader(n_ewsgroups.type())).isEmpty() )
n_ewsgroups.from7BitString(raw);
@@ -359,7 +359,7 @@ void KNLocalArticle::updateListItem()
if(!i_tem)
return;
- QString tmp;
+ TQString tmp;
int idx=0;
KNConfig::Appearance *app=knGlobals.configManager()->appearance();
@@ -448,7 +448,7 @@ KNAttachment::~KNAttachment()
}
-void KNAttachment::setMimeType(const QString &s)
+void KNAttachment::setMimeType(const TQString &s)
{
m_imeType=s.latin1();
h_asChanged=true;
@@ -467,9 +467,9 @@ void KNAttachment::setMimeType(const QString &s)
}
-QString KNAttachment::contentSize() const
+TQString KNAttachment::contentSize() const
{
- QString ret;
+ TQString ret;
int s=0;
if(c_ontent && c_ontent->hasContent())
@@ -537,7 +537,7 @@ void KNAttachment::attach(Content *c)
updateContentInfo();
Headers::ContentType *type=c_ontent->contentType();
Headers::CTEncoding *e=c_ontent->contentTransferEncoding();
- QByteArray data(f_ile->size());
+ TQByteArray data(f_ile->size());
int readBytes=f_ile->readBlock(data.data(), f_ile->size());
@@ -552,7 +552,7 @@ void KNAttachment::attach(Content *c)
e->setCte(Headers::CEbase64);
e->setDecoded(false);
} else {
- c_ontent->setBody( QCString(data.data(), data.size()+1) + '\n' );
+ c_ontent->setBody( TQCString(data.data(), data.size()+1) + '\n' );
// c_ontent->b_ody += '\n';
e->setDecoded(true);
}
diff --git a/knode/knarticle.h b/knode/knarticle.h
index 9c2fc8979..798742e17 100644
--- a/knode/knarticle.h
+++ b/knode/knarticle.h
@@ -15,13 +15,13 @@
#ifndef KNARTICLE_H
#define KNARTICLE_H
-#include <qstringlist.h>
-#include <qtextstream.h>
-#include <qfile.h>
-#include <qfont.h>
-#include <qcolor.h>
-#include <qasciidict.h>
-#include <qvaluelist.h>
+#include <tqstringlist.h>
+#include <tqtextstream.h>
+#include <tqfile.h>
+#include <tqfont.h>
+#include <tqcolor.h>
+#include <tqasciidict.h>
+#include <tqvaluelist.h>
#include <kmime_headers.h>
#include <kmime_newsarticle.h>
@@ -36,13 +36,13 @@ class KNArticleCollection;
/** This class encapsulates a generic article. It provides all the
usual headers of a RFC822-message. Further more it contains an
- unique id and can store a pointer to a @ref QListViewItem. It is
+ unique id and can store a pointer to a @ref TQListViewItem. It is
used as a base class for all visible articles. */
class KNArticle : public KMime::NewsArticle, public KNJobItem {
public:
- typedef QValueList<KNArticle*> List;
+ typedef TQValueList<KNArticle*> List;
KNArticle(KNArticleCollection *c);
~KNArticle();
@@ -87,7 +87,7 @@ class KNGroup;
class KNRemoteArticle : public KNArticle {
public:
- typedef QValueList<KNRemoteArticle*> List;
+ typedef TQValueList<KNRemoteArticle*> List;
KNRemoteArticle(KNGroup *g);
~KNRemoteArticle();
@@ -169,8 +169,8 @@ class KNRemoteArticle : public KNArticle {
void setForceDefaultCS(bool b);
- QColor color() const { return c_olor; }
- void setColor(const QColor& c) { c_olor = c; }
+ TQColor color() const { return c_olor; }
+ void setColor(const TQColor& c) { c_olor = c; }
time_t subThreadChangeDate() { return s_ubThreadChangeDate; }
void setSubThreadChangeDate(time_t date) { s_ubThreadChangeDate = date; }
@@ -188,7 +188,7 @@ class KNRemoteArticle : public KNArticle {
KNRemoteArticle *d_ref; // displayed reference-article (may differ from i_dRef)
unsigned char t_hrLevel; // quality of threading
short s_core; // guess what ;-)
- QColor c_olor; // color for the header list
+ TQColor c_olor; // color for the header list
unsigned short u_nreadFups, // number of the article's unread follow-ups
n_ewFups; // number of the article's new follow-ups
time_t s_ubThreadChangeDate; // the last time the sub-thread of this article changed
@@ -207,7 +207,7 @@ class KNRemoteArticle : public KNArticle {
class KNLocalArticle : public KNArticle {
public:
- typedef QValueList<KNLocalArticle*> List;
+ typedef TQValueList<KNLocalArticle*> List;
KNLocalArticle(KNArticleCollection *c=0);
~KNLocalArticle();
@@ -294,27 +294,27 @@ class KNAttachment {
~KNAttachment();
//name (used as a Content-Type parameter and as filename)
- const QString& name() { return n_ame; }
- void setName(const QString &s) { n_ame=s; h_asChanged=true; }
+ const TQString& name() { return n_ame; }
+ void setName(const TQString &s) { n_ame=s; h_asChanged=true; }
//mime type
- const QCString& mimeType() { return m_imeType; }
- void setMimeType(const QString &s);
+ const TQCString& mimeType() { return m_imeType; }
+ void setMimeType(const TQString &s);
//Content-Description
- const QString& description() { return d_escription; }
- void setDescription(const QString &s) { d_escription=s; h_asChanged=true; }
+ const TQString& description() { return d_escription; }
+ void setDescription(const TQString &s) { d_escription=s; h_asChanged=true; }
//Encoding
int cte() { return e_ncoding.cte(); }
void setCte(int e) { e_ncoding.setCte( (KMime::Headers::contentEncoding)(e) );
h_asChanged=true; }
bool isFixedBase64()const { return f_b64; }
- QString encoding() { return e_ncoding.asUnicodeString(); }
+ TQString encoding() { return e_ncoding.asUnicodeString(); }
//content handling
KMime::Content* content()const { return c_ontent; }
- QString contentSize() const;
+ TQString contentSize() const;
bool isAttached() const { return i_sAttached; }
bool hasChanged() const { return h_asChanged; }
void updateContentInfo();
@@ -324,9 +324,9 @@ class KNAttachment {
protected:
KMime::Content *c_ontent;
KNLoadHelper *l_oadHelper;
- QFile *f_ile;
- QCString m_imeType;
- QString n_ame,
+ TQFile *f_ile;
+ TQCString m_imeType;
+ TQString n_ame,
d_escription;
KMime::Headers::CTEncoding e_ncoding;
bool i_sAttached,
diff --git a/knode/knarticlecollection.cpp b/knode/knarticlecollection.cpp
index bd8def75b..cbb4779b3 100644
--- a/knode/knarticlecollection.cpp
+++ b/knode/knarticlecollection.cpp
@@ -198,7 +198,7 @@ int KNArticleVector::compareById(const void *p1, const void *p2)
int KNArticleVector::compareByMsgId(const void *p1, const void *p2)
{
KNArticle *a1, *a2;
- QCString mid1, mid2;
+ TQCString mid1, mid2;
a1=*(KNArticle**)(p1);
a2=*(KNArticle**)(p2);
@@ -221,7 +221,7 @@ KNArticle* KNArticleVector::bsearch(int id)
}
-KNArticle* KNArticleVector::bsearch(const QCString &id)
+KNArticle* KNArticleVector::bsearch(const TQCString &id)
{
int idx=indexForMsgId(id);
@@ -261,12 +261,12 @@ int KNArticleVector::indexForId(int id)
}
-int KNArticleVector::indexForMsgId(const QCString &id)
+int KNArticleVector::indexForMsgId(const TQCString &id)
{
if(s_ortType!=STmsgId) return -1;
int start=0, end=l_en, mid=0;
- QCString currentMid=0;
+ TQCString currentMid=0;
bool found=false;
KNArticle *current=0;
int cnt=0;
@@ -368,7 +368,7 @@ KNArticle* KNArticleCollection::byId(int id)
}
-KNArticle* KNArticleCollection::byMessageId(const QCString &mid)
+KNArticle* KNArticleCollection::byMessageId(const TQCString &mid)
{
if(m_idIndex.isEmpty()) {
m_idIndex.syncWithMaster();
diff --git a/knode/knarticlecollection.h b/knode/knarticlecollection.h
index 3a92f2182..507ff266b 100644
--- a/knode/knarticlecollection.h
+++ b/knode/knarticlecollection.h
@@ -57,10 +57,10 @@ class KNArticleVector {
// article access
KNArticle* at(int i) { return ( (i>=0 && i<l_en) ? l_ist[i] : 0 ); }
KNArticle* bsearch(int id);
- KNArticle* bsearch(const QCString &id);
+ KNArticle* bsearch(const TQCString &id);
int indexForId(int id);
- int indexForMsgId(const QCString &id);
+ int indexForMsgId(const TQCString &id);
protected:
KNArticleVector *m_aster;
@@ -102,7 +102,7 @@ class KNArticleCollection : public KNCollection {
// article access
KNArticle* at(int i) { return a_rticles.at(i); }
KNArticle* byId(int id);
- KNArticle* byMessageId(const QCString &mid);
+ KNArticle* byMessageId(const TQCString &mid);
// search index
void syncSearchIndex();
diff --git a/knode/knarticlefactory.cpp b/knode/knarticlefactory.cpp
index 3c072887b..410c2bf40 100644
--- a/knode/knarticlefactory.cpp
+++ b/knode/knarticlefactory.cpp
@@ -12,9 +12,9 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qvbox.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqvbox.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -35,15 +35,15 @@
#include "resource.h"
-KNArticleFactory::KNArticleFactory(QObject *p, const char *n)
- : QObject(p, n), s_endErrDlg(0)
+KNArticleFactory::KNArticleFactory(TQObject *p, const char *n)
+ : TQObject(p, n), s_endErrDlg(0)
{
}
KNArticleFactory::~KNArticleFactory()
{
- for ( QValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
+ for ( TQValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
delete (*it);
delete s_endErrDlg;
}
@@ -54,7 +54,7 @@ void KNArticleFactory::createPosting(KNNntpAccount *a)
if(!a)
return;
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(a, sig, knGlobals.configManager()->postNewsTechnical()->charset());
if(!art)
return;
@@ -63,9 +63,9 @@ void KNArticleFactory::createPosting(KNNntpAccount *a)
art->setDoPost(true);
art->setDoMail(false);
- KNComposer *c = new KNComposer( art, QString::null, sig, QString::null, true );
+ KNComposer *c = new KNComposer( art, TQString::null, sig, TQString::null, true );
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
@@ -75,13 +75,13 @@ void KNArticleFactory::createPosting(KNGroup *g)
if(!g)
return;
- QCString chset;
+ TQCString chset;
if (g->useCharset())
chset = g->defaultCharset();
else
chset = knGlobals.configManager()->postNewsTechnical()->charset();
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(g, sig, chset);
if(!art)
@@ -92,21 +92,21 @@ void KNArticleFactory::createPosting(KNGroup *g)
art->setDoMail(false);
art->newsgroups()->fromUnicodeString(g->groupname(), art->defaultCharset());
- KNComposer *c=new KNComposer(art, QString::null, sig, QString::null, true);
+ KNComposer *c=new KNComposer(art, TQString::null, sig, TQString::null, true);
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
-void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, bool post, bool mail)
+void KNArticleFactory::createReply(KNRemoteArticle *a, TQString selectedText, bool post, bool mail)
{
if(!a)
return;
KNGroup *g=static_cast<KNGroup*>(a->collection());
- QCString chset;
+ TQCString chset;
if (knGlobals.configManager()->postNewsTechnical()->useOwnCharset()) {
if (g->useCharset())
chset = g->defaultCharset();
@@ -116,7 +116,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
chset = knGlobals.configManager()->postNewsTechnical()->findComposerCharset(a->contentType()->charset());
//create new article
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(g, sig, chset, true, a);
if(!art)
return;
@@ -128,7 +128,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
//------------------------- <Headers> ----------------------------
//subject
- QString subject=a->subject()->asUnicodeString();
+ TQString subject=a->subject()->asUnicodeString();
if(subject.left(3).upper()!="RE:")
subject.prepend("Re: ");
art->subject()->fromUnicodeString(subject, a->subject()->rfc2047Charset());
@@ -140,7 +140,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
if( post && // user wanted to reply by public posting?
// ask the user if she wants to ignore this F'up-To: poster
( KMessageBox::Yes != KMessageBox::questionYesNo(knGlobals.topWidget,
- i18n("The author has requested a reply by email instead\nof a followup to the newsgroup. (Followup-To: poster)\nDo you want to reply in public anyway?"), QString::null, i18n("Reply Public"), i18n("Reply by Email")) ))
+ i18n("The author has requested a reply by email instead\nof a followup to the newsgroup. (Followup-To: poster)\nDo you want to reply in public anyway?"), TQString::null, i18n("Reply Public"), i18n("Reply by Email")) ))
{
art->setDoPost(false);
art->setDoMail(true);
@@ -173,7 +173,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
//References
KMime::Headers::References *references=a->references(false);
- QCString refs;
+ TQCString refs;
if (references)
refs=references->as7BitString(false);
else
@@ -192,7 +192,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
authorWantsMailCopies = mailCopiesTo->alwaysCopy();
if (authorWantsMailCopies) // warn the user
KMessageBox::information(knGlobals.topWidget,i18n("The author requested a mail copy of your reply. (Mail-Copies-To header)"),
- QString::null,"mailCopiesToWarning");
+ TQString::null,"mailCopiesToWarning");
if (authorWantsMailCopies && mailCopiesTo->hasEmail()) {
address.setName(mailCopiesTo->name());
address.setEmail(mailCopiesTo->email());
@@ -206,22 +206,22 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
//--------------------------- <Body> -----------------------------
// attribution line
- QString attribution=knGlobals.configManager()->postNewsComposer()->intro();
- QString name(a->from()->name());
+ TQString attribution=knGlobals.configManager()->postNewsComposer()->intro();
+ TQString name(a->from()->name());
if (name.isEmpty())
- name = QString::fromLatin1(a->from()->email());
- attribution.replace(QRegExp("%NAME"),name);
- attribution.replace(QRegExp("%EMAIL"),QString::fromLatin1(a->from()->email()));
- attribution.replace(QRegExp("%DATE"),KGlobal::locale()->formatDateTime(a->date()->qdt(),false));
- attribution.replace(QRegExp("%MSID"),a->messageID()->asUnicodeString());
- attribution.replace(QRegExp("%GROUP"),g->groupname());
- attribution.replace(QRegExp("%L"),"\n");
+ name = TQString::fromLatin1(a->from()->email());
+ attribution.replace(TQRegExp("%NAME"),name);
+ attribution.replace(TQRegExp("%EMAIL"),TQString::fromLatin1(a->from()->email()));
+ attribution.replace(TQRegExp("%DATE"),KGlobal::locale()->formatDateTime(a->date()->qdt(),false));
+ attribution.replace(TQRegExp("%MSID"),a->messageID()->asUnicodeString());
+ attribution.replace(TQRegExp("%GROUP"),g->groupname());
+ attribution.replace(TQRegExp("%L"),"\n");
attribution+="\n\n";
- QString quoted=attribution;
- QString notRewraped=QString::null;
- QStringList text;
- QStringList::Iterator line;
+ TQString quoted=attribution;
+ TQString notRewraped=TQString::null;
+ TQStringList text;
+ TQStringList::Iterator line;
bool incSig=knGlobals.configManager()->postNewsComposer()->includeSignature();
if (selectedText.isEmpty()) {
@@ -230,7 +230,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
tc->decodedText(text, true, knGlobals.configManager()->readNewsViewer()->removeTrailingNewlines());
}
else
- text = QStringList::split('\n',selectedText,true);
+ text = TQStringList::split('\n',selectedText,true);
for(line=text.begin(); line!=text.end(); ++line) {
if(!incSig && (*line)=="-- ")
@@ -264,7 +264,7 @@ void KNArticleFactory::createReply(KNRemoteArticle *a, QString selectedText, boo
//open composer
KNComposer *c=new KNComposer(art, quoted, sig, notRewraped, true, authorDislikesMailCopies, authorWantsMailCopies);
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
@@ -275,11 +275,11 @@ void KNArticleFactory::createForward(KNArticle *a)
return;
KMime::Headers::ContentType *ct=a->contentType();
- QCString chset;
+ TQCString chset;
bool incAtt = ( !knGlobals.configManager()->postNewsTechnical()->useExternalMailer() &&
ct->isMultipart() && ct->isSubtype("mixed") &&
KMessageBox::Yes == KMessageBox::questionYesNo(knGlobals.topWidget,
- i18n("This article contains attachments. Do you want them to be forwarded as well?"), QString::null, i18n("Forward"), i18n("Do Not Forward"))
+ i18n("This article contains attachments. Do you want them to be forwarded as well?"), TQString::null, i18n("Forward"), i18n("Do Not Forward"))
);
if (knGlobals.configManager()->postNewsTechnical()->useOwnCharset())
@@ -288,7 +288,7 @@ void KNArticleFactory::createForward(KNArticle *a)
chset = knGlobals.configManager()->postNewsTechnical()->findComposerCharset(a->contentType()->charset());
//create new article
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(knGlobals.groupManager()->currentGroup(), sig, chset);
if(!art)
return;
@@ -299,14 +299,14 @@ void KNArticleFactory::createForward(KNArticle *a)
//------------------------- <Headers> ----------------------------
//subject
- QString subject=("Fwd: "+a->subject()->asUnicodeString());
+ TQString subject=("Fwd: "+a->subject()->asUnicodeString());
art->subject()->fromUnicodeString(subject, a->subject()->rfc2047Charset());
//------------------------- </Headers> ---------------------------
//--------------------------- <Body> -----------------------------
- QString fwd = QString("\n--------------- %1\n\n").arg(i18n("Forwarded message (begin)"));
+ TQString fwd = TQString("\n--------------- %1\n\n").arg(i18n("Forwarded message (begin)"));
fwd+=( i18n("Subject") + ": " + a->subject()->asUnicodeString() + "\n" );
fwd+=( i18n("From") + ": " + a->from()->asUnicodeString() + "\n" );
@@ -315,13 +315,13 @@ void KNArticleFactory::createForward(KNArticle *a)
KMime::Content *text=a->textContent();
if(text) {
- QStringList decodedLines;
+ TQStringList decodedLines;
text->decodedText( decodedLines, false, false );
- for(QStringList::Iterator it=decodedLines.begin(); it!=decodedLines.end(); ++it)
+ for(TQStringList::Iterator it=decodedLines.begin(); it!=decodedLines.end(); ++it)
fwd += (*it) + "\n";
}
- fwd += QString("\n--------------- %1\n").arg(i18n("Forwarded message (end)"));
+ fwd += TQString("\n--------------- %1\n").arg(i18n("Forwarded message (end)"));
//--------------------------- </Body> ----------------------------
@@ -341,15 +341,15 @@ void KNArticleFactory::createForward(KNArticle *a)
if (knGlobals.configManager()->postNewsTechnical()->useExternalMailer()) {
- sendMailExternal(QString::null, subject, fwd);
+ sendMailExternal(TQString::null, subject, fwd);
delete art;
return;
}
//open composer
- KNComposer *c=new KNComposer(art, fwd, sig, QString::null, true);
+ KNComposer *c=new KNComposer(art, fwd, sig, TQString::null, true);
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
@@ -360,7 +360,7 @@ void KNArticleFactory::createCancel(KNArticle *a)
return;
if(KMessageBox::No==KMessageBox::questionYesNo(knGlobals.topWidget,
- i18n("Do you really want to cancel this article?"), QString::null, i18n("Cancel Article"), KStdGuiItem::cancel()))
+ i18n("Do you really want to cancel this article?"), TQString::null, i18n("Cancel Article"), KStdGuiItem::cancel()))
return;
bool sendNow;
@@ -390,7 +390,7 @@ void KNArticleFactory::createCancel(KNArticle *a)
grp=knGlobals.groupManager()->group(a->newsgroups()->firstGroup(), nntp);
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(grp, sig, "us-ascii", false);
if(!art)
return;
@@ -404,7 +404,7 @@ void KNArticleFactory::createCancel(KNArticle *a)
//subject
KMime::Headers::MessageID *msgId=a->messageID();
- QCString tmp;
+ TQCString tmp;
tmp="cancel of "+msgId->as7BitString(false);
art->subject()->from7BitString(tmp);
@@ -419,7 +419,7 @@ void KNArticleFactory::createCancel(KNArticle *a)
art->lines()->setNumberOfLines(1);
//body
- art->fromUnicodeString(QString::fromLatin1("cancel by original author\n"));
+ art->fromUnicodeString(TQString::fromLatin1("cancel by original author\n"));
//assemble
art->assemble();
@@ -440,7 +440,7 @@ void KNArticleFactory::createSupersede(KNArticle *a)
return;
if(KMessageBox::No==KMessageBox::questionYesNo(knGlobals.topWidget,
- i18n("Do you really want to supersede this article?"), QString::null, i18n("Supersede"), KStdGuiItem::cancel()))
+ i18n("Do you really want to supersede this article?"), TQString::null, i18n("Supersede"), KStdGuiItem::cancel()))
return;
KNGroup *grp;
@@ -464,7 +464,7 @@ void KNArticleFactory::createSupersede(KNArticle *a)
grp=knGlobals.groupManager()->group(a->newsgroups()->firstGroup(), nntp);
//new article
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(grp, sig, knGlobals.configManager()->postNewsTechnical()->findComposerCharset(a->contentType()->charset()));
if(!art)
return;
@@ -492,7 +492,7 @@ void KNArticleFactory::createSupersede(KNArticle *a)
art->supersedes()->from7BitString(a->messageID()->as7BitString(false));
//Body
- QString text;
+ TQString text;
KMime::Content *textContent=a->textContent();
if(textContent)
textContent->decodedText(text);
@@ -500,7 +500,7 @@ void KNArticleFactory::createSupersede(KNArticle *a)
//open composer
KNComposer *c=new KNComposer(art, text, sig);
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
@@ -513,7 +513,7 @@ void KNArticleFactory::createMail(KMime::Headers::AddressField *address)
}
//create new article
- QString sig;
+ TQString sig;
KNLocalArticle *art=newArticle(knGlobals.groupManager()->currentGroup(), sig, knGlobals.configManager()->postNewsTechnical()->charset());
if(!art)
return;
@@ -523,18 +523,18 @@ void KNArticleFactory::createMail(KMime::Headers::AddressField *address)
art->to()->addAddress((*address));
//open composer
- KNComposer *c=new KNComposer(art, QString::null, sig, QString::null, true);
+ KNComposer *c=new KNComposer(art, TQString::null, sig, TQString::null, true);
mCompList.append( c );
- connect(c, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(c, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
c->show();
}
-void KNArticleFactory::sendMailExternal(const QString &address, const QString &subject, const QString &body)
+void KNArticleFactory::sendMailExternal(const TQString &address, const TQString &subject, const TQString &body)
{
KURL mailtoURL;
- QStringList queries;
- QString query=QString::null;
+ TQStringList queries;
+ TQString query=TQString::null;
mailtoURL.setProtocol("mailto");
if (!address.isEmpty())
@@ -546,7 +546,7 @@ void KNArticleFactory::sendMailExternal(const QString &address, const QString &s
if (queries.count() > 0) {
query = "?";
- for ( QStringList::Iterator it = queries.begin(); it != queries.end(); ++it ) {
+ for ( TQStringList::Iterator it = queries.begin(); it != queries.end(); ++it ) {
if (it != queries.begin())
query.append("&");
query.append((*it));
@@ -596,7 +596,7 @@ void KNArticleFactory::edit(KNLocalArticle *a)
knGlobals.articleManager()->loadArticle(a);
//open composer
- com=new KNComposer(a, QString::null, id->getSignature());
+ com=new KNComposer(a, TQString::null, id->getSignature());
if(id->useSigGenerator() && !id->getSigGeneratorStdErr().isEmpty())
KMessageBox::information(knGlobals.topWidget,
i18n("<qt>The signature generator program produced the "
@@ -604,7 +604,7 @@ void KNArticleFactory::edit(KNLocalArticle *a)
.arg(id->getSigGeneratorStdErr()));
mCompList.append( com );
- connect(com, SIGNAL(composerDone(KNComposer*)), this, SLOT(slotComposerDone(KNComposer*)));
+ connect(com, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*)));
com->show();
}
@@ -682,7 +682,7 @@ void KNArticleFactory::sendOutbox()
bool KNArticleFactory::closeComposeWindows()
{
while ( !mCompList.isEmpty() ) {
- QValueList<KNComposer*>::Iterator it = mCompList.begin();
+ TQValueList<KNComposer*>::Iterator it = mCompList.begin();
if ( !(*it)->close() )
return false;
}
@@ -703,7 +703,7 @@ void KNArticleFactory::deleteComposerForArticle(KNLocalArticle *a)
KNComposer* KNArticleFactory::findComposer(KNLocalArticle *a)
{
- for ( QValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
+ for ( TQValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
if ( (*it)->article() == a )
return (*it);
return 0;
@@ -712,7 +712,7 @@ KNComposer* KNArticleFactory::findComposer(KNLocalArticle *a)
void KNArticleFactory::configChanged()
{
- for ( QValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
+ for ( TQValueList<KNComposer*>::Iterator it = mCompList.begin(); it != mCompList.end(); ++it )
(*it)->setConfig( false );
}
@@ -774,7 +774,7 @@ void KNArticleFactory::processJob(KNJobData *j)
}
-KNLocalArticle* KNArticleFactory::newArticle(KNCollection *col, QString &sig, QCString defChset, bool withXHeaders, KNArticle *origPost)
+KNLocalArticle* KNArticleFactory::newArticle(KNCollection *col, TQString &sig, TQCString defChset, bool withXHeaders, KNArticle *origPost)
{
KNConfig::PostNewsTechnical *pnt=knGlobals.configManager()->postNewsTechnical();
@@ -871,19 +871,19 @@ KNLocalArticle* KNArticleFactory::newArticle(KNCollection *col, QString &sig, QC
if(withXHeaders) {
KNConfig::XHeaders::Iterator it;
for(it=pnt->xHeaders().begin(); it!=pnt->xHeaders().end(); ++it) {
- QString value = (*it).value();
+ TQString value = (*it).value();
if(origPost) {
- QString name(origPost->from()->name());
+ TQString name(origPost->from()->name());
if (name.isEmpty())
- name = QString::fromLatin1(origPost->from()->email());
- value.replace(QRegExp("%NAME"), name);
- value.replace(QRegExp("%EMAIL"), QString::fromLatin1(origPost->from()->email()));
+ name = TQString::fromLatin1(origPost->from()->email());
+ value.replace(TQRegExp("%NAME"), name);
+ value.replace(TQRegExp("%EMAIL"), TQString::fromLatin1(origPost->from()->email()));
}
else
if(value.find("%NAME") != -1 || value.find("%EMAIL") != -1)
continue;
- art->setHeader( new KMime::Headers::Generic( (QCString("X-")+(*it).name()), art, value, pnt->charset() ) );
+ art->setHeader( new KMime::Headers::Generic( (TQCString("X-")+(*it).name()), art, value, pnt->charset() ) );
}
}
@@ -898,7 +898,7 @@ KNLocalArticle* KNArticleFactory::newArticle(KNCollection *col, QString &sig, QC
.arg(id->getSigGeneratorStdErr()));
}
else
- sig=QString::null;
+ sig=TQString::null;
return art;
}
@@ -990,7 +990,7 @@ void KNArticleFactory::showSendErrorDialog()
{
if(!s_endErrDlg) {
s_endErrDlg=new KNSendErrorDialog();
- connect(s_endErrDlg, SIGNAL(closeClicked()), this, SLOT(slotSendErrorDialogDone()));
+ connect(s_endErrDlg, TQT_SIGNAL(closeClicked()), this, TQT_SLOT(slotSendErrorDialogDone()));
}
s_endErrDlg->show();
}
@@ -1068,16 +1068,16 @@ KNSendErrorDialog::KNSendErrorDialog()
{
p_ixmap=knGlobals.configManager()->appearance()->icon(KNConfig::Appearance::sendErr);
- QVBox *page = makeVBoxMainWidget();
+ TQVBox *page = makeVBoxMainWidget();
- new QLabel(QString("<b>%1</b><br>%2").arg(i18n("Errors occurred while sending these articles:"))
+ new TQLabel(TQString("<b>%1</b><br>%2").arg(i18n("Errors occurred while sending these articles:"))
.arg(i18n("The unsent articles are stored in the \"Outbox\" folder.")), page);
j_obs=new KNDialogListBox(true, page);
- e_rror=new QLabel(QString::null, page);
+ e_rror=new TQLabel(TQString::null, page);
- connect(j_obs, SIGNAL(highlighted(int)), this, SLOT(slotHighlighted(int)));
+ connect(j_obs, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(slotHighlighted(int)));
- KNHelper::restoreWindowSize("sendDlg", this, QSize(320,250));
+ KNHelper::restoreWindowSize("sendDlg", this, TQSize(320,250));
}
@@ -1087,7 +1087,7 @@ KNSendErrorDialog::~KNSendErrorDialog()
}
-void KNSendErrorDialog::append(const QString &subject, const QString &error)
+void KNSendErrorDialog::append(const TQString &subject, const TQString &error)
{
LBoxItem *it=new LBoxItem(error, subject, &p_ixmap);
@@ -1100,7 +1100,7 @@ void KNSendErrorDialog::slotHighlighted(int idx)
{
LBoxItem *it=static_cast<LBoxItem*>(j_obs->item(idx));
if(it) {
- QString tmp=i18n("<b>Error message:</b><br>")+it->error;
+ TQString tmp=i18n("<b>Error message:</b><br>")+it->error;
e_rror->setText(tmp);
}
}
diff --git a/knode/knarticlefactory.h b/knode/knarticlefactory.h
index 6b18b6e5b..995fcdc0d 100644
--- a/knode/knarticlefactory.h
+++ b/knode/knarticlefactory.h
@@ -15,7 +15,7 @@
#ifndef KNARTICLEFACTORY_H
#define KNARTICLEFACTORY_H
-#include <qvaluelist.h>
+#include <tqvaluelist.h>
#include <kdialogbase.h>
#include "knjobdata.h"
@@ -36,27 +36,27 @@ namespace KNConfig {
}
-class KNArticleFactory : public QObject , public KNJobConsumer {
+class KNArticleFactory : public TQObject , public KNJobConsumer {
Q_OBJECT
public:
enum replyType { RTgroup, RTmail, RTboth };
- KNArticleFactory(QObject *p=0, const char *n=0);
+ KNArticleFactory(TQObject *p=0, const char *n=0);
~KNArticleFactory();
//factory methods
void createPosting(KNNntpAccount *a);
void createPosting(KNGroup *g);
- void createReply(KNRemoteArticle *a, QString selectedText=QString::null, bool post=true, bool mail=false);
+ void createReply(KNRemoteArticle *a, TQString selectedText=TQString::null, bool post=true, bool mail=false);
void createForward(KNArticle *a);
void createCancel(KNArticle *a);
void createSupersede(KNArticle *a);
void createMail(KMime::Headers::AddressField *address);
// send a mail via an external program...
- void sendMailExternal(const QString &address=QString::null, const QString &subject=QString::null, const QString &body=QString::null);
+ void sendMailExternal(const TQString &address=TQString::null, const TQString &subject=TQString::null, const TQString &body=TQString::null);
//article handling
void edit(KNLocalArticle *a);
@@ -75,7 +75,7 @@ class KNArticleFactory : public QObject , public KNJobConsumer {
//article generation
// col: group or account
- KNLocalArticle* newArticle(KNCollection *col, QString &sig, QCString defChset, bool withXHeaders=true, KNArticle *origPost=0);
+ KNLocalArticle* newArticle(KNCollection *col, TQString &sig, TQCString defChset, bool withXHeaders=true, KNArticle *origPost=0);
//cancel & supersede
bool cancelAllowed(KNArticle *a);
@@ -83,7 +83,7 @@ class KNArticleFactory : public QObject , public KNJobConsumer {
//send-errors
void showSendErrorDialog();
- QValueList<KNComposer*> mCompList;
+ TQValueList<KNComposer*> mCompList;
KNSendErrorDialog *s_endErrDlg;
protected slots:
@@ -101,21 +101,21 @@ class KNSendErrorDialog : public KDialogBase {
KNSendErrorDialog();
~KNSendErrorDialog();
- void append(const QString &subject, const QString &error);
+ void append(const TQString &subject, const TQString &error);
protected:
class LBoxItem : public KNListBoxItem {
public:
- LBoxItem(const QString &e, const QString &t, QPixmap *p=0)
+ LBoxItem(const TQString &e, const TQString &t, TQPixmap *p=0)
: KNListBoxItem(t, p) , error(e) {}
~LBoxItem() {}
- QString error;
+ TQString error;
};
KNDialogListBox *j_obs;
- QLabel *e_rror;
- QPixmap p_ixmap;
+ TQLabel *e_rror;
+ TQPixmap p_ixmap;
protected slots:
void slotHighlighted(int idx);
diff --git a/knode/knarticlefilter.cpp b/knode/knarticlefilter.cpp
index b5a49d55b..60d0e0320 100644
--- a/knode/knarticlefilter.cpp
+++ b/knode/knarticlefilter.cpp
@@ -74,7 +74,7 @@ KNArticleFilter::~KNArticleFilter()
bool KNArticleFilter::loadInfo()
{
if (i_d!=-1) {
- QString fname(locate("data",QString( "knode/filters/%1.fltr" ).arg(i_d) ) );
+ TQString fname(locate("data",TQString( "knode/filters/%1.fltr" ).arg(i_d) ) );
if (fname.isNull())
return false;
@@ -94,7 +94,7 @@ bool KNArticleFilter::loadInfo()
void KNArticleFilter::load()
{
- QString fname(locate("data",QString( "knode/filters/%1.fltr").arg(i_d) ) );
+ TQString fname(locate("data",TQString( "knode/filters/%1.fltr").arg(i_d) ) );
if (fname.isNull())
return;
@@ -136,15 +136,15 @@ void KNArticleFilter::save()
{
if (i_d==-1)
return;
- QString dir(locateLocal("data","knode/")+"filters/");
+ TQString dir(locateLocal("data","knode/")+"filters/");
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
}
- KSimpleConfig conf(dir+QString("%1.fltr").arg(i_d));
+ KSimpleConfig conf(dir+TQString("%1.fltr").arg(i_d));
conf.setGroup("GENERAL");
- conf.writeEntry("name", QString(n_ame));
+ conf.writeEntry("name", TQString(n_ame));
conf.writeEntry("Translate_Name",translateName);
conf.writeEntry("enabled", e_nabled);
conf.writeEntry("applyOn", (int) apon);
@@ -253,7 +253,7 @@ void KNArticleFilter::doFilter(KNGroup *g)
if( orphant_threads.count() > 0 ) {
// try to merge orphant threads by subject
KNRemoteArticle::List same_subjects;
- QString s;
+ TQString s;
for ( KNRemoteArticle::List::Iterator it = orphant_threads.begin(); it != orphant_threads.end(); ++it ) {
if ( (*it)->displayedReference() ) // already processed
continue;
@@ -301,7 +301,7 @@ void KNArticleFilter::doFilter(KNFolder *f)
// *tries* to translate the name
-QString KNArticleFilter::translatedName()
+TQString KNArticleFilter::translatedName()
{
if (translateName) {
// major hack alert !!!
@@ -311,7 +311,7 @@ QString KNArticleFilter::translatedName()
else
return n_ame;
} else
- return QString::null;
+ return TQString::null;
} else
return n_ame;
}
@@ -319,12 +319,12 @@ QString KNArticleFilter::translatedName()
// *tries* to retranslate the name to english
-void KNArticleFilter::setTranslatedName(const QString &s)
+void KNArticleFilter::setTranslatedName(const TQString &s)
{
bool retranslated = false;
for (const char **c=defFil;(*c)!=0;c++) // ok, try if it matches any of the standard filter names
if (s==i18n("default filter name",*c)) {
- n_ame = QString::fromLatin1(*c);
+ n_ame = TQString::fromLatin1(*c);
retranslated = true;
break;
}
@@ -348,7 +348,7 @@ bool KNArticleFilter::applyFilter(KNRemoteArticle *a)
if(result) result=age.doFilter(a->date()->ageInDays());
if(result) result=subject.doFilter(a->subject()->asUnicodeString());
if(result) {
- QString tmp = (a->from()->name()+"##") + QString(a->from()->email().data());
+ TQString tmp = (a->from()->name()+"##") + TQString(a->from()->email().data());
result=from.doFilter(tmp);
}
if(result) result=messageId.doFilter(a->messageID()->asUnicodeString());
@@ -370,7 +370,7 @@ bool KNArticleFilter::applyFilter(KNLocalArticle *a)
if(result) result=age.doFilter(a->date()->ageInDays());
if(result) result=subject.doFilter(a->subject()->asUnicodeString());
if(result) {
- QString tmp = (a->from()->name()+"##") + QString(a->from()->email().data());
+ TQString tmp = (a->from()->name()+"##") + TQString(a->from()->email().data());
result=from.doFilter(tmp);
}
if(result) result=messageId.doFilter(a->messageID()->asUnicodeString());
diff --git a/knode/knarticlefilter.h b/knode/knarticlefilter.h
index 6d544342d..b01cdf6a3 100644
--- a/knode/knarticlefilter.h
+++ b/knode/knarticlefilter.h
@@ -47,8 +47,8 @@ class KNArticleFilter {
int count()const { return c_ount; }
int id()const { return i_d; }
int applyOn() { return static_cast<int>(apon); }
- const QString& name() { return n_ame; }
- QString translatedName(); // *tries* to translate the name
+ const TQString& name() { return n_ame; }
+ TQString translatedName(); // *tries* to translate the name
bool isEnabled()const { return e_nabled; }
bool loaded()const { return l_oaded; }
bool isSearchFilter()const { return s_earchFilter; }
@@ -56,8 +56,8 @@ class KNArticleFilter {
void setId(int i) { i_d=i; }
void setApplyOn(int i) { apon=(ApOn)i; }
void setLoaded(bool l) { l_oaded=l; }
- void setName(const QString &s) { n_ame=s; }
- void setTranslatedName(const QString &s); // *tries* to retranslate the name to english
+ void setName(const TQString &s) { n_ame=s; }
+ void setTranslatedName(const TQString &s); // *tries* to retranslate the name to english
void setEnabled(bool l) { e_nabled=l; }
void setSearchFilter(bool b) { s_earchFilter = b; }
@@ -67,7 +67,7 @@ class KNArticleFilter {
bool applyFilter(KNRemoteArticle *a);
bool applyFilter(KNLocalArticle *a);
- QString n_ame;
+ TQString n_ame;
int i_d, c_ount;
bool l_oaded, e_nabled, translateName, s_earchFilter;
ApOn apon;
diff --git a/knode/knarticlemanager.cpp b/knode/knarticlemanager.cpp
index 4f1786e8c..86bcd8df9 100644
--- a/knode/knarticlemanager.cpp
+++ b/knode/knarticlemanager.cpp
@@ -44,7 +44,7 @@
using namespace KNode;
-KNArticleManager::KNArticleManager() : QObject(0,0)
+KNArticleManager::KNArticleManager() : TQObject(0,0)
{
g_roup=0;
f_older=0;
@@ -53,8 +53,8 @@ KNArticleManager::KNArticleManager() : QObject(0,0)
s_earchDlg=0;
d_isableExpander=false;
- connect(f_ilterMgr, SIGNAL(filterChanged(KNArticleFilter*)), this,
- SLOT(slotFilterChanged(KNArticleFilter*)));
+ connect(f_ilterMgr, TQT_SIGNAL(filterChanged(KNArticleFilter*)), this,
+ TQT_SLOT(slotFilterChanged(KNArticleFilter*)));
}
@@ -66,7 +66,7 @@ KNArticleManager::~KNArticleManager()
void KNArticleManager::deleteTempFiles()
{
- for ( QValueList<KTempFile*>::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it ) {
+ for ( TQValueList<KTempFile*>::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it ) {
(*it)->unlink();
delete (*it);
}
@@ -74,24 +74,24 @@ void KNArticleManager::deleteTempFiles()
}
-void KNArticleManager::saveContentToFile(KMime::Content *c, QWidget *parent)
+void KNArticleManager::saveContentToFile(KMime::Content *c, TQWidget *parent)
{
KNSaveHelper helper(c->contentType()->name(),parent);
- QFile *file = helper.getFile(i18n("Save Attachment"));
+ TQFile *file = helper.getFile(i18n("Save Attachment"));
if (file) {
- QByteArray data=c->decodedContent();
+ TQByteArray data=c->decodedContent();
if (file->writeBlock(data.data(), data.size()) == -1 )
KNHelper::displayExternalFileError( parent );
}
}
-void KNArticleManager::saveArticleToFile(KNArticle *a, QWidget *parent)
+void KNArticleManager::saveArticleToFile(KNArticle *a, TQWidget *parent)
{
- QString fName = a->subject()->asUnicodeString();
- QString s = "";
+ TQString fName = a->subject()->asUnicodeString();
+ TQString s = "";
for (unsigned int i=0; i<fName.length(); i++)
if (fName[i].isLetterOrNumber())
@@ -99,22 +99,22 @@ void KNArticleManager::saveArticleToFile(KNArticle *a, QWidget *parent)
else
s.append(' ');
fName = s.simplifyWhiteSpace();
- fName.replace(QRegExp("[\\s]"),"_");
+ fName.replace(TQRegExp("[\\s]"),"_");
KNSaveHelper helper(fName,parent);
- QFile *file = helper.getFile(i18n("Save Article"));
+ TQFile *file = helper.getFile(i18n("Save Article"));
if (file) {
- QCString tmp=a->encodedContent(false);
+ TQCString tmp=a->encodedContent(false);
if ( file->writeBlock(tmp.data(), tmp.size()) == -1 )
KNHelper::displayExternalFileError( parent );
}
}
-QString KNArticleManager::saveContentToTemp(KMime::Content *c)
+TQString KNArticleManager::saveContentToTemp(KMime::Content *c)
{
- QString path;
+ TQString path;
KTempFile* tmpFile;
KMime::Headers::Base *pathHdr=c->getHeaderByType("X-KNode-Tempfile"); // check for existing temp file
@@ -123,7 +123,7 @@ QString KNArticleManager::saveContentToTemp(KMime::Content *c)
bool found=false;
// lets see if the tempfile-path is still valid...
- for ( QValueList<KTempFile*>::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it ) {
+ for ( TQValueList<KTempFile*>::Iterator it = mTempFiles.begin(); it != mTempFiles.end(); ++it ) {
if ( (*it)->name() == path ) {
found = true;
break;
@@ -140,12 +140,12 @@ QString KNArticleManager::saveContentToTemp(KMime::Content *c)
if (tmpFile->status()!=0) {
KNHelper::displayTempFileError();
delete tmpFile;
- return QString::null;
+ return TQString::null;
}
mTempFiles.append(tmpFile);
- QFile *f=tmpFile->file();
- QByteArray data=c->decodedContent();
+ TQFile *f=tmpFile->file();
+ TQByteArray data=c->decodedContent();
f->writeBlock(data.data(), data.size());
tmpFile->close();
path=tmpFile->name();
@@ -158,7 +158,7 @@ QString KNArticleManager::saveContentToTemp(KMime::Content *c)
void KNArticleManager::openContent(KMime::Content *c)
{
- QString path=saveContentToTemp(c);
+ TQString path=saveContentToTemp(c);
if(path.isNull()) return;
KService::Ptr offer = KServiceTypeProfile::preferredService(c->contentType()->mimeType(), "Application");
@@ -324,7 +324,7 @@ void KNArticleManager::showHdrs(bool clear)
knGlobals.top->articleViewer()->setArticle( 0 );
}
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
updateStatusString();
knGlobals.top->setCursorBusy(false);
}
@@ -390,10 +390,10 @@ void KNArticleManager::search()
KWin::activateWindow(s_earchDlg->winId());
} else {
s_earchDlg=new KNSearchDialog(KNSearchDialog::STgroupSearch, 0);
- connect(s_earchDlg, SIGNAL(doSearch(KNArticleFilter*)), this,
- SLOT(slotFilterChanged(KNArticleFilter*)));
- connect(s_earchDlg, SIGNAL(dialogDone()), this,
- SLOT(slotSearchDialogDone()));
+ connect(s_earchDlg, TQT_SIGNAL(doSearch(KNArticleFilter*)), this,
+ TQT_SLOT(slotFilterChanged(KNArticleFilter*)));
+ connect(s_earchDlg, TQT_SIGNAL(dialogDone()), this,
+ TQT_SLOT(slotSearchDialogDone()));
s_earchDlg->show();
}
}
@@ -569,7 +569,7 @@ void KNArticleManager::moveIntoFolder(KNLocalArticle::List &l, KNFolder *f)
bool KNArticleManager::deleteArticles(KNLocalArticle::List &l, bool ask)
{
if(ask) {
- QStringList lst;
+ TQStringList lst;
for ( KNLocalArticle::List::Iterator it = l.begin(); it != l.end(); ++it ) {
if ( (*it)->isLocked() )
continue;
@@ -660,13 +660,13 @@ void KNArticleManager::setRead(KNRemoteArticle::List &l, bool r, bool handleXPos
if( r && knGlobals.configManager()->readNewsGeneral()->markCrossposts() &&
handleXPosts && (*it)->newsgroups()->isCrossposted() ) {
- QStringList groups = (*it)->newsgroups()->getGroups();
+ TQStringList groups = (*it)->newsgroups()->getGroups();
KNGroup *targetGroup=0;
KNRemoteArticle *xp=0;
KNRemoteArticle::List al;
- QCString mid = (*it)->messageID()->as7BitString( false );
+ TQCString mid = (*it)->messageID()->as7BitString( false );
- for ( QStringList::Iterator it2 = groups.begin(); it2 != groups.end(); ++it2 ) {
+ for ( TQStringList::Iterator it2 = groups.begin(); it2 != groups.end(); ++it2 ) {
targetGroup = knGlobals.groupManager()->group(*it2, g->account());
if (targetGroup) {
if (targetGroup->isLoaded() && (xp=targetGroup->byMessageId(mid)) ) {
@@ -987,7 +987,7 @@ void KNArticleManager::updateStatusString()
else
displCnt=g_roup->count();
- QString name = g_roup->name();
+ TQString name = g_roup->name();
if (g_roup->status()==KNGroup::moderated)
name += i18n(" (moderated)");
@@ -997,7 +997,7 @@ void KNArticleManager::updateStatusString()
if(f_ilter)
knGlobals.setStatusMsg(i18n(" Filter: %1").arg(f_ilter->translatedName()), SB_FILTER);
else
- knGlobals.setStatusMsg(QString::null, SB_FILTER);
+ knGlobals.setStatusMsg(TQString::null, SB_FILTER);
}
else if(f_older) {
if(f_ilter)
@@ -1006,10 +1006,10 @@ void KNArticleManager::updateStatusString()
displCnt=f_older->count();
knGlobals.setStatusMsg(i18n(" %1: %2 displayed")
.arg(f_older->name()).arg(displCnt), SB_GROUP);
- knGlobals.setStatusMsg(QString::null, SB_FILTER);
+ knGlobals.setStatusMsg(TQString::null, SB_FILTER);
} else {
- knGlobals.setStatusMsg(QString::null, SB_GROUP);
- knGlobals.setStatusMsg(QString::null, SB_FILTER);
+ knGlobals.setStatusMsg(TQString::null, SB_GROUP);
+ knGlobals.setStatusMsg(TQString::null, SB_FILTER);
}
}
@@ -1028,7 +1028,7 @@ void KNArticleManager::slotSearchDialogDone()
}
-void KNArticleManager::slotItemExpanded(QListViewItem *p)
+void KNArticleManager::slotItemExpanded(TQListViewItem *p)
{
if (d_isableExpander) // we don't want to call this method recursively
return;
@@ -1081,8 +1081,8 @@ void KNArticleManager::slotItemExpanded(QListViewItem *p)
void KNArticleManager::setView(KNHeaderView* v) {
v_iew = v;
if(v) {
- connect(v, SIGNAL(expanded(QListViewItem*)), this,
- SLOT(slotItemExpanded(QListViewItem*)));
+ connect(v, TQT_SIGNAL(expanded(TQListViewItem*)), this,
+ TQT_SLOT(slotItemExpanded(TQListViewItem*)));
}
}
diff --git a/knode/knarticlemanager.h b/knode/knarticlemanager.h
index 07335e1c1..f82cddd5c 100644
--- a/knode/knarticlemanager.h
+++ b/knode/knarticlemanager.h
@@ -15,7 +15,7 @@
#ifndef KNARTICLEMANAGER_H
#define KNARTICLEMANAGER_H
-#include <qvaluelist.h>
+#include <tqvaluelist.h>
#include "knjobdata.h"
#include "knarticle.h"
@@ -36,7 +36,7 @@ class KNSearchDialog;
class KNJobData;
-class KNArticleManager : public QObject, public KNJobConsumer {
+class KNArticleManager : public TQObject, public KNJobConsumer {
Q_OBJECT
@@ -46,9 +46,9 @@ class KNArticleManager : public QObject, public KNJobConsumer {
//content handling
void deleteTempFiles();
- void saveContentToFile(KMime::Content *c, QWidget *parent);
- void saveArticleToFile(KNArticle *a, QWidget *parent);
- QString saveContentToTemp(KMime::Content *c);
+ void saveContentToFile(KMime::Content *c, TQWidget *parent);
+ void saveArticleToFile(KNArticle *a, TQWidget *parent);
+ TQString saveContentToTemp(KMime::Content *c);
void openContent(KMime::Content *c);
//listview handling
@@ -109,13 +109,13 @@ class KNArticleManager : public QObject, public KNJobConsumer {
KNArticleFilter *f_ilter;
KNFilterManager *f_ilterMgr;
KNSearchDialog *s_earchDlg;
- QValueList<KTempFile*> mTempFiles;
+ TQValueList<KTempFile*> mTempFiles;
bool d_isableExpander;
public slots:
void slotFilterChanged(KNArticleFilter *f);
void slotSearchDialogDone();
- void slotItemExpanded(QListViewItem *p);
+ void slotItemExpanded(TQListViewItem *p);
};
diff --git a/knode/knarticlewindow.cpp b/knode/knarticlewindow.cpp
index 3e6898182..05b4f83ae 100644
--- a/knode/knarticlewindow.cpp
+++ b/knode/knarticlewindow.cpp
@@ -29,13 +29,13 @@
using namespace KNode;
-QValueList<KNArticleWindow*> KNArticleWindow::mInstances;
+TQValueList<KNArticleWindow*> KNArticleWindow::mInstances;
bool KNArticleWindow::closeAllWindowsForCollection( KNArticleCollection *col, bool force )
{
- QValueList<KNArticleWindow*> list = mInstances;
- for ( QValueList<KNArticleWindow*>::Iterator it = list.begin(); it != list.end(); ++it )
+ TQValueList<KNArticleWindow*> list = mInstances;
+ for ( TQValueList<KNArticleWindow*>::Iterator it = list.begin(); it != list.end(); ++it )
if ( (*it)->artW->article() && (*it)->artW->article()->collection() == col ) {
if ( force )
(*it)->close();
@@ -48,8 +48,8 @@ bool KNArticleWindow::closeAllWindowsForCollection( KNArticleCollection *col, bo
bool KNArticleWindow::closeAllWindowsForArticle( KNArticle *art, bool force )
{
- QValueList<KNArticleWindow*> list = mInstances;
- for ( QValueList<KNArticleWindow*>::Iterator it = list.begin(); it != list.end(); ++it )
+ TQValueList<KNArticleWindow*> list = mInstances;
+ for ( TQValueList<KNArticleWindow*>::Iterator it = list.begin(); it != list.end(); ++it )
if ( (*it)->artW->article() && (*it)->artW->article() == art ) {
if ( force )
(*it)->close();
@@ -62,7 +62,7 @@ bool KNArticleWindow::closeAllWindowsForArticle( KNArticle *art, bool force )
bool KNArticleWindow::raiseWindowForArticle( KNArticle *art )
{
- for ( QValueList<KNArticleWindow*>::Iterator it = mInstances.begin(); it != mInstances.end(); ++it )
+ for ( TQValueList<KNArticleWindow*>::Iterator it = mInstances.begin(); it != mInstances.end(); ++it )
if ( (*it)->artW->article() && (*it)->artW->article() == art ) {
KWin::activateWindow( (*it)->winId() );
return true;
@@ -71,9 +71,9 @@ bool KNArticleWindow::raiseWindowForArticle( KNArticle *art )
}
-bool KNArticleWindow::raiseWindowForArticle(const QCString &mid)
+bool KNArticleWindow::raiseWindowForArticle(const TQCString &mid)
{
- for ( QValueList<KNArticleWindow*>::Iterator it = mInstances.begin(); it != mInstances.end(); ++it )
+ for ( TQValueList<KNArticleWindow*>::Iterator it = mInstances.begin(); it != mInstances.end(); ++it )
if ( (*it)->artW->article() && (*it)->artW->article()->messageID()->as7BitString( false ) == mid ) {
KWin::activateWindow( (*it)->winId() );
return true;
@@ -101,10 +101,10 @@ KNArticleWindow::KNArticleWindow(KNArticle *art)
mInstances.append( this );
// file menu
- KStdAction::close( this, SLOT(close()), actionCollection() );
+ KStdAction::close( this, TQT_SLOT(close()), actionCollection() );
// settings menu
- KStdAction::preferences(knGlobals.top, SLOT(slotSettings()), actionCollection());
+ KStdAction::preferences(knGlobals.top, TQT_SLOT(slotSettings()), actionCollection());
KAccel *accel = new KAccel( this );
artW->setCharsetKeyboardAction()->plugAccel( accel );
diff --git a/knode/knarticlewindow.h b/knode/knarticlewindow.h
index 224af1dfb..1859e773f 100644
--- a/knode/knarticlewindow.h
+++ b/knode/knarticlewindow.h
@@ -36,11 +36,11 @@ class KNArticleWindow : public KMainWindow {
static bool closeAllWindowsForCollection(KNArticleCollection *col, bool force=true);
static bool closeAllWindowsForArticle(KNArticle *art, bool force=true);
static bool raiseWindowForArticle(KNArticle *art); // false: no window found
- static bool raiseWindowForArticle(const QCString &mid);
+ static bool raiseWindowForArticle(const TQCString &mid);
protected:
KNode::ArticleWidget *artW;
- static QValueList<KNArticleWindow*> mInstances;
+ static TQValueList<KNArticleWindow*> mInstances;
};
diff --git a/knode/kncleanup.cpp b/knode/kncleanup.cpp
index 4998bd4c2..3e79b4a62 100644
--- a/knode/kncleanup.cpp
+++ b/knode/kncleanup.cpp
@@ -14,10 +14,10 @@
#include <stdlib.h>
-#include <qdir.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qprogressbar.h>
+#include <tqdir.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqprogressbar.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -54,7 +54,7 @@ void KNCleanUp::start()
d_lg = new ProgressDialog( mColList.count() );
d_lg->show();
- for ( QValueList<KNArticleCollection*>::Iterator it = mColList.begin(); it != mColList.end(); ++it ) {
+ for ( TQValueList<KNArticleCollection*>::Iterator it = mColList.begin(); it != mColList.end(); ++it ) {
if ( (*it)->type() == KNCollection::CTgroup ) {
d_lg->showMessage( i18n("Deleting expired articles in <b>%1</b>").arg( (*it)->name() ) );
kapp->processEvents();
@@ -198,7 +198,7 @@ void KNCleanUp::compactFolder(KNFolder *f)
if (!f)
return;
- QDir dir(f->path());
+ TQDir dir(f->path());
if(!dir.exists())
return;
@@ -211,14 +211,14 @@ void KNCleanUp::compactFolder(KNFolder *f)
}
f->closeFiles();
- QFileInfo info(f->m_boxFile);
- QString oldName=info.fileName();
- QString newName=oldName+".new";
+ TQFileInfo info(f->m_boxFile);
+ TQString oldName=info.fileName();
+ TQString newName=oldName+".new";
KNFile newMBoxFile(info.dirPath(true)+"/"+newName);
if( (f->m_boxFile.open(IO_ReadOnly)) && (newMBoxFile.open(IO_WriteOnly)) ) {
- QTextStream ts(&newMBoxFile);
- ts.setEncoding(QTextStream::Latin1);
+ TQTextStream ts(&newMBoxFile);
+ ts.setEncoding(TQTextStream::Latin1);
for(int idx=0; idx<f->length(); idx++) {
art=f->at(idx);
if(f->m_boxFile.at(art->startOffset())) {
@@ -247,7 +247,7 @@ void KNCleanUp::compactFolder(KNFolder *f)
KNCleanUp::ProgressDialog::ProgressDialog(int steps)
- : QDialog(knGlobals.topWidget, 0, true)
+ : TQDialog(knGlobals.topWidget, 0, true)
{
const int w=400,
h=160;
@@ -258,21 +258,21 @@ KNCleanUp::ProgressDialog::ProgressDialog(int steps)
setCaption(kapp->makeStdCaption(i18n("Cleaning Up")));
setFixedSize(w,h);
- QFrame *top=new QFrame(this);
+ TQFrame *top=new TQFrame(this);
top->setGeometry(0,0, w,h);
- QVBoxLayout *topL=new QVBoxLayout(top, 10);
+ TQVBoxLayout *topL=new TQVBoxLayout(top, 10);
- QLabel *l=new QLabel(i18n("Cleaning up. Please wait..."), top);
+ TQLabel *l=new TQLabel(i18n("Cleaning up. Please wait..."), top);
topL->addWidget(l);
KSeparator *sep=new KSeparator(top);
topL->addWidget(sep);
- m_sg=new QLabel(top);
+ m_sg=new TQLabel(top);
topL->addWidget(m_sg);
- p_bar=new QProgressBar(top);
+ p_bar=new TQProgressBar(top);
topL->addWidget(p_bar);
p_bar->setTotalSteps(100*s_teps);
p_bar->setProgress(1);
@@ -298,7 +298,7 @@ KNCleanUp::ProgressDialog::~ProgressDialog()
}
-void KNCleanUp::ProgressDialog::showMessage(const QString &s)
+void KNCleanUp::ProgressDialog::showMessage(const TQString &s)
{
m_sg->setText(s);
}
@@ -311,7 +311,7 @@ void KNCleanUp::ProgressDialog::doProgress()
}
-void KNCleanUp::ProgressDialog::closeEvent(QCloseEvent *)
+void KNCleanUp::ProgressDialog::closeEvent(TQCloseEvent *)
{
// do nothing => prevent that the user closes the window
}
diff --git a/knode/kncleanup.h b/knode/kncleanup.h
index 81e453dff..f6cd53151 100644
--- a/knode/kncleanup.h
+++ b/knode/kncleanup.h
@@ -15,7 +15,7 @@
#ifndef KNCLEANUP_H
#define KNCLEANUP_H
-#include <qsemimodal.h>
+#include <tqsemimodal.h>
class QProgressBar;
class QLabel;
@@ -44,26 +44,26 @@ class KNCleanUp {
protected:
- class ProgressDialog : public QDialog {
+ class ProgressDialog : public TQDialog {
public:
ProgressDialog(int steps);
~ProgressDialog();
- void showMessage(const QString &s);
+ void showMessage(const TQString &s);
void doProgress();
protected:
- void closeEvent(QCloseEvent *e);
+ void closeEvent(TQCloseEvent *e);
- QLabel *m_sg;
- QProgressBar *p_bar;
+ TQLabel *m_sg;
+ TQProgressBar *p_bar;
int s_teps, p_rogress;
};
ProgressDialog *d_lg;
- QValueList<KNArticleCollection*> mColList;
+ TQValueList<KNArticleCollection*> mColList;
};
diff --git a/knode/kncollection.h b/knode/kncollection.h
index 80907ca55..f6c4b9150 100644
--- a/knode/kncollection.h
+++ b/knode/kncollection.h
@@ -17,7 +17,7 @@
#ifndef KNCOLLECTION_H
#define KNCOLLECTION_H
-#include <qstring.h>
+#include <tqstring.h>
class KNCollectionViewItem;
@@ -41,8 +41,8 @@ class KNCollection {
virtual void updateListItem();
// info
- virtual QString path()=0;
- virtual bool readInfo(const QString &confPath)=0;
+ virtual TQString path()=0;
+ virtual bool readInfo(const TQString &confPath)=0;
virtual void saveInfo()=0;
// parent
@@ -50,8 +50,8 @@ class KNCollection {
virtual void setParent(KNCollection *p) { p_arent=p; }
// name
- virtual const QString& name() { return n_ame; }
- void setName(const QString &s) { n_ame=s; }
+ virtual const TQString& name() { return n_ame; }
+ void setName(const TQString &s) { n_ame=s; }
// count
int count()const { return c_ount; }
@@ -62,7 +62,7 @@ class KNCollection {
protected:
KNCollection *p_arent;
KNCollectionViewItem *l_istItem;
- QString n_ame;
+ TQString n_ame;
int c_ount;
};
diff --git a/knode/kncollectionview.cpp b/knode/kncollectionview.cpp
index 2d48a9e5d..63542cad4 100644
--- a/knode/kncollectionview.cpp
+++ b/knode/kncollectionview.cpp
@@ -11,8 +11,8 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qcursor.h>
-#include <qheader.h>
+#include <tqcursor.h>
+#include <tqheader.h>
#include <kiconloader.h>
#include <klistview.h>
@@ -32,7 +32,7 @@
#include "kncollectionview.h"
#include "kncollectionviewitem.h"
-KNCollectionView::KNCollectionView(QWidget *parent, const char* name) :
+KNCollectionView::KNCollectionView(TQWidget *parent, const char* name) :
KFolderTree(parent, name),
mActiveItem( 0 ),
mPopup( 0 )
@@ -49,8 +49,8 @@ KNCollectionView::KNCollectionView(QWidget *parent, const char* name) :
mPopup = new KPopupMenu( this );
mPopup->insertTitle( i18n("View Columns") );
mPopup->setCheckable( true );
- mUnreadPop = mPopup->insertItem( i18n("Unread Column"), this, SLOT(toggleUnreadColumn()) );
- mTotalPop = mPopup->insertItem( i18n("Total Column"), this, SLOT(toggleTotalColumn()) );
+ mUnreadPop = mPopup->insertItem( i18n("Unread Column"), this, TQT_SLOT(toggleUnreadColumn()) );
+ mTotalPop = mPopup->insertItem( i18n("Total Column"), this, TQT_SLOT(toggleTotalColumn()) );
// add unread and total columns if necessary
readConfig();
@@ -61,21 +61,21 @@ KNCollectionView::KNCollectionView(QWidget *parent, const char* name) :
// connect to the account manager
KNAccountManager* am = knGlobals.accountManager();
- connect(am, SIGNAL(accountAdded(KNNntpAccount*)), SLOT(addAccount(KNNntpAccount*)));
- connect(am, SIGNAL(accountRemoved(KNNntpAccount*)), SLOT(removeAccount(KNNntpAccount*)));
- connect(am, SIGNAL(accountModified(KNNntpAccount*)), SLOT(updateAccount(KNNntpAccount*)));
+ connect(am, TQT_SIGNAL(accountAdded(KNNntpAccount*)), TQT_SLOT(addAccount(KNNntpAccount*)));
+ connect(am, TQT_SIGNAL(accountRemoved(KNNntpAccount*)), TQT_SLOT(removeAccount(KNNntpAccount*)));
+ connect(am, TQT_SIGNAL(accountModified(KNNntpAccount*)), TQT_SLOT(updateAccount(KNNntpAccount*)));
// connect to the group manager
KNGroupManager* gm = knGlobals.groupManager();
- connect(gm, SIGNAL(groupAdded(KNGroup*)), SLOT(addGroup(KNGroup*)));
- connect(gm, SIGNAL(groupRemoved(KNGroup*)), SLOT(removeGroup(KNGroup*)));
- connect(gm, SIGNAL(groupUpdated(KNGroup*)), SLOT(updateGroup(KNGroup*)));
+ connect(gm, TQT_SIGNAL(groupAdded(KNGroup*)), TQT_SLOT(addGroup(KNGroup*)));
+ connect(gm, TQT_SIGNAL(groupRemoved(KNGroup*)), TQT_SLOT(removeGroup(KNGroup*)));
+ connect(gm, TQT_SIGNAL(groupUpdated(KNGroup*)), TQT_SLOT(updateGroup(KNGroup*)));
// connect to the folder manager
KNFolderManager* fm = knGlobals.folderManager();
- connect(fm, SIGNAL(folderAdded(KNFolder*)), SLOT(addPendingFolders()));
- connect(fm, SIGNAL(folderRemoved(KNFolder*)), SLOT(removeFolder(KNFolder*)));
- connect(fm, SIGNAL(folderActivated(KNFolder*)), SLOT(activateFolder(KNFolder*)));
+ connect(fm, TQT_SIGNAL(folderAdded(KNFolder*)), TQT_SLOT(addPendingFolders()));
+ connect(fm, TQT_SIGNAL(folderRemoved(KNFolder*)), TQT_SLOT(removeFolder(KNFolder*)));
+ connect(fm, TQT_SIGNAL(folderActivated(KNFolder*)), TQT_SLOT(activateFolder(KNFolder*)));
installEventFilter(this);
}
@@ -118,13 +118,13 @@ void KNCollectionView::readConfig()
KNConfig::Appearance *app = knGlobals.configManager()->appearance();
setFont( app->groupListFont() );
- QPalette p = palette();
- p.setColor( QColorGroup::Base, app->backgroundColor() );
- p.setColor( QColorGroup::Text, app->textColor() );
+ TQPalette p = palette();
+ p.setColor( TQColorGroup::Base, app->backgroundColor() );
+ p.setColor( TQColorGroup::Text, app->textColor() );
setPalette( p );
setAlternateBackground( app->backgroundColor() );
// FIXME: make this configurable
- mPaintInfo.colUnread = QColor( "blue" );
+ mPaintInfo.colUnread = TQColor( "blue" );
mPaintInfo.colFore = app->textColor();
mPaintInfo.colBack = app->backgroundColor();
}
@@ -149,8 +149,8 @@ void KNCollectionView::addAccount(KNNntpAccount *a)
item->setOpen( a->wasOpen() );
// add groups for this account
- QValueList<KNGroup*> groups = knGlobals.groupManager()->groupsOfAccount( a );
- for ( QValueList<KNGroup*>::Iterator it = groups.begin(); it != groups.end(); ++it ) {
+ TQValueList<KNGroup*> groups = knGlobals.groupManager()->groupsOfAccount( a );
+ for ( TQValueList<KNGroup*>::Iterator it = groups.begin(); it != groups.end(); ++it ) {
KNCollectionViewItem *gitem = new KNCollectionViewItem( item, KFolderTreeItem::News );
(*it)->setListItem( gitem );
(*it)->updateListItem();
@@ -179,7 +179,7 @@ void KNCollectionView::updateAccount(KNNntpAccount *a)
void KNCollectionView::reloadAccounts()
{
KNAccountManager* am = knGlobals.accountManager();
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = am->begin(); it != am->end(); ++it ) {
removeAccount( *it );
addAccount( *it );
@@ -269,12 +269,12 @@ void KNCollectionView::reloadFolders()
void KNCollectionView::addPendingFolders()
{
- QValueList<KNFolder*> folders = knGlobals.folderManager()->folders();
- for ( QValueList<KNFolder*>::Iterator it = folders.begin(); it != folders.end(); ++it )
+ TQValueList<KNFolder*> folders = knGlobals.folderManager()->folders();
+ for ( TQValueList<KNFolder*>::Iterator it = folders.begin(); it != folders.end(); ++it )
if ( !(*it)->listItem() )
addFolder( (*it) );
// now open the folders if they were open in the last session
- for ( QValueList<KNFolder*>::Iterator it = folders.begin(); it != folders.end(); ++it )
+ for ( TQValueList<KNFolder*>::Iterator it = folders.begin(); it != folders.end(); ++it )
if ( (*it)->listItem())
(*it)->listItem()->setOpen( (*it)->wasOpen() );
}
@@ -299,7 +299,7 @@ void KNCollectionView::reload()
reloadFolders();
}
-void KNCollectionView::setActive( QListViewItem *i )
+void KNCollectionView::setActive( TQListViewItem *i )
{
if (!i || mActiveItem == i)
return;
@@ -328,7 +328,7 @@ void KNCollectionView::prevGroup()
void KNCollectionView::decCurrentFolder()
{
- QListViewItemIterator it( currentItem() );
+ TQListViewItemIterator it( currentItem() );
--it;
KFolderTreeItem* fti = static_cast<KFolderTreeItem*>(it.current());
if (fti) {
@@ -341,7 +341,7 @@ void KNCollectionView::decCurrentFolder()
void KNCollectionView::incCurrentFolder()
{
- QListViewItemIterator it( currentItem() );
+ TQListViewItemIterator it( currentItem() );
++it;
KFolderTreeItem* fti = static_cast<KFolderTreeItem*>(it.current());
if (fti) {
@@ -362,12 +362,12 @@ void KNCollectionView::selectCurrentFolder()
}
-QDragObject* KNCollectionView::dragObject()
+TQDragObject* KNCollectionView::dragObject()
{
KFolderTreeItem *item = static_cast<KFolderTreeItem*>
- (itemAt(viewport()->mapFromGlobal(QCursor::pos())));
+ (itemAt(viewport()->mapFromGlobal(TQCursor::pos())));
if ( item && item->protocol() == KFolderTreeItem::Local && item->type() == KFolderTreeItem::Other ) {
- QDragObject *d = new QStoredDrag( "x-knode-drag/folder", viewport() );
+ TQDragObject *d = new TQStoredDrag( "x-knode-drag/folder", viewport() );
d->setPixmap( SmallIcon("folder") );
return d;
}
@@ -375,10 +375,10 @@ QDragObject* KNCollectionView::dragObject()
}
-void KNCollectionView::contentsDropEvent( QDropEvent *e )
+void KNCollectionView::contentsDropEvent( TQDropEvent *e )
{
cleanItemHighlighter(); // necessary since we overwrite KListView::contentsDropEvent()
- QListViewItem *item = itemAt( contentsToViewport(e->pos()) );
+ TQListViewItem *item = itemAt( contentsToViewport(e->pos()) );
KNCollectionViewItem *fti = static_cast<KNCollectionViewItem*>(item);
if (fti && (fti->coll) && acceptDrag(e)) {
emit folderDrop( e, fti );
@@ -419,20 +419,20 @@ void KNCollectionView::updatePopup() const
-bool KNCollectionView::eventFilter(QObject *o, QEvent *e)
+bool KNCollectionView::eventFilter(TQObject *o, TQEvent *e)
{
- if ((e->type() == QEvent::KeyPress) && (static_cast<QKeyEvent*>(e)->key() == Key_Tab)) {
+ if ((e->type() == TQEvent::KeyPress) && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab)) {
emit(focusChangeRequest(this));
if (!hasFocus()) // focusChangeRequest was successful
return true;
}
// header popup menu
- if ( e->type() == QEvent::MouseButtonPress &&
- static_cast<QMouseEvent*>(e)->button() == RightButton &&
- o->isA("QHeader") )
+ if ( e->type() == TQEvent::MouseButtonPress &&
+ static_cast<TQMouseEvent*>(e)->button() == RightButton &&
+ o->isA("TQHeader") )
{
- mPopup->popup( static_cast<QMouseEvent*>(e)->globalPos() );
+ mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() );
return true;
}
@@ -440,16 +440,16 @@ bool KNCollectionView::eventFilter(QObject *o, QEvent *e)
}
-void KNCollectionView::focusInEvent(QFocusEvent *e)
+void KNCollectionView::focusInEvent(TQFocusEvent *e)
{
- QListView::focusInEvent(e);
+ TQListView::focusInEvent(e);
emit focusChanged(e);
}
-void KNCollectionView::focusOutEvent(QFocusEvent *e)
+void KNCollectionView::focusOutEvent(TQFocusEvent *e)
{
- QListView::focusOutEvent(e);
+ TQListView::focusOutEvent(e);
emit focusChanged(e);
}
diff --git a/knode/kncollectionview.h b/knode/kncollectionview.h
index 3c7e0f61c..000e1289d 100644
--- a/knode/kncollectionview.h
+++ b/knode/kncollectionview.h
@@ -29,10 +29,10 @@ class KNCollectionView : public KFolderTree {
Q_OBJECT
public:
- KNCollectionView(QWidget *parent, const char *name = 0);
+ KNCollectionView(TQWidget *parent, const char *name = 0);
~KNCollectionView();
- void setActive(QListViewItem *item);
+ void setActive(TQListViewItem *item);
void readConfig();
void writeConfig();
@@ -69,22 +69,22 @@ class KNCollectionView : public KFolderTree {
void updatePopup() const;
signals:
- void folderDrop( QDropEvent *e, KNCollectionViewItem *item );
+ void folderDrop( TQDropEvent *e, KNCollectionViewItem *item );
- void focusChanged( QFocusEvent* );
- void focusChangeRequest( QWidget* );
+ void focusChanged( TQFocusEvent* );
+ void focusChangeRequest( TQWidget* );
protected:
// dnd
- virtual QDragObject* dragObject();
- virtual void contentsDropEvent( QDropEvent *e );
+ virtual TQDragObject* dragObject();
+ virtual void contentsDropEvent( TQDropEvent *e );
- bool eventFilter( QObject *, QEvent * );
- void focusInEvent( QFocusEvent *e );
- void focusOutEvent( QFocusEvent *e );
+ bool eventFilter( TQObject *, TQEvent * );
+ void focusInEvent( TQFocusEvent *e );
+ void focusOutEvent( TQFocusEvent *e );
private:
- QListViewItem *mActiveItem;
+ TQListViewItem *mActiveItem;
KPopupMenu *mPopup;
int mUnreadPop, mTotalPop;
diff --git a/knode/kncollectionviewitem.cpp b/knode/kncollectionviewitem.cpp
index ace78a63a..8fed1f968 100644
--- a/knode/kncollectionviewitem.cpp
+++ b/knode/kncollectionviewitem.cpp
@@ -18,8 +18,8 @@
#include <config.h>
#endif
-#include <qdragobject.h>
-#include <qpainter.h>
+#include <tqdragobject.h>
+#include <tqpainter.h>
#include <kiconloader.h>
#include <kstringhandler.h>
@@ -33,14 +33,14 @@
KNCollectionViewItem::KNCollectionViewItem( KFolderTree *parent, Protocol protocol, Type type) :
- KFolderTreeItem(parent, QString::null, protocol, type), coll(0)
+ KFolderTreeItem(parent, TQString::null, protocol, type), coll(0)
{
setIcon();
}
KNCollectionViewItem::KNCollectionViewItem( KFolderTreeItem *it, Protocol protocol, Type type, int unread, int total ) :
- KFolderTreeItem(it, QString::null, protocol, type, unread, total), coll(0)
+ KFolderTreeItem(it, TQString::null, protocol, type, unread, total), coll(0)
{
setIcon();
}
@@ -81,7 +81,7 @@ void KNCollectionViewItem::setIcon() {
}
-int KNCollectionViewItem::compare(QListViewItem *i, int col, bool ascending) const
+int KNCollectionViewItem::compare(TQListViewItem *i, int col, bool ascending) const
{
KFolderTreeItem *other = static_cast<KFolderTreeItem*>(i);
@@ -101,7 +101,7 @@ int KNCollectionViewItem::compare(QListViewItem *i, int col, bool ascending) con
}
-bool KNCollectionViewItem::acceptDrag(QDropEvent* event) const
+bool KNCollectionViewItem::acceptDrag(TQDropEvent* event) const
{
if (event && coll && coll->type()==KNCollection::CTfolder) {
if (event->provides("x-knode-drag/article"))
@@ -113,7 +113,7 @@ bool KNCollectionViewItem::acceptDrag(QDropEvent* event) const
}
-void KNCollectionViewItem::paintCell( QPainter * p, const QColorGroup & cg,int column, int width, int align )
+void KNCollectionViewItem::paintCell( TQPainter * p, const TQColorGroup & cg,int column, int width, int align )
{
KFolderTree *ft = static_cast<KFolderTree*>( listView() );
@@ -126,19 +126,19 @@ void KNCollectionViewItem::paintCell( QPainter * p, const QColorGroup & cg,int c
// find out if we will use bold font, necessary for the text squeezing
if ( (column == 0 || column == ft->unreadIndex()) && ( mUnread > 0 ) ) {
- QFont f = p->font();
- f.setWeight(QFont::Bold);
+ TQFont f = p->font();
+ f.setWeight(TQFont::Bold);
p->setFont(f);
}
// consider pixmap size for squeezing
int pxWidth = 8;
- const QPixmap *px = pixmap(column);
+ const TQPixmap *px = pixmap(column);
if (px)
pxWidth += px->width();
// temporary set the squeezed text and use the parent class to paint it
- QString curText = text( column );
+ TQString curText = text( column );
if ( p->fontMetrics().width( curText ) > width - pxWidth ) {
setText( column, squeezeFolderName( curText, p->fontMetrics(), width - pxWidth ) );
KFolderTreeItem::paintCell( p, cg, column, width, align );
@@ -148,14 +148,14 @@ void KNCollectionViewItem::paintCell( QPainter * p, const QColorGroup & cg,int c
}
-QString KNCollectionViewItem::squeezeFolderName( const QString &text,
- const QFontMetrics &fm,
+TQString KNCollectionViewItem::squeezeFolderName( const TQString &text,
+ const TQFontMetrics &fm,
uint width ) const
{
if (protocol() == KFolderTreeItem::News && type() == KFolderTreeItem::Other) {
- QString t(text);
+ TQString t(text);
int curPos = 0, nextPos = 0;
- QString temp;
+ TQString temp;
while ( (uint)fm.width(t) > width && nextPos != -1 ) {
nextPos = t.find('.', curPos);
if ( nextPos != -1 ) {
diff --git a/knode/kncollectionviewitem.h b/knode/kncollectionviewitem.h
index 0d13678f2..6899dc9ae 100644
--- a/knode/kncollectionviewitem.h
+++ b/knode/kncollectionviewitem.h
@@ -33,19 +33,19 @@ class KNCollectionViewItem : public KFolderTreeItem {
Type type = Other, int unread = 0, int total = 0 );
~KNCollectionViewItem();
- void paintCell( QPainter * p, const QColorGroup & cg,
+ void paintCell( TQPainter * p, const TQColorGroup & cg,
int column, int width, int align );
- int compare(QListViewItem *i, int col, bool ascending) const;
+ int compare(TQListViewItem *i, int col, bool ascending) const;
// DND
- virtual bool acceptDrag(QDropEvent* event) const;
+ virtual bool acceptDrag(TQDropEvent* event) const;
KNCollection *coll;
protected:
- virtual QString squeezeFolderName( const QString &text,
- const QFontMetrics &fm,
+ virtual TQString squeezeFolderName( const TQString &text,
+ const TQFontMetrics &fm,
uint width ) const;
private:
diff --git a/knode/kncomposer.cpp b/knode/kncomposer.cpp
index b6fdd4249..111bdf19e 100644
--- a/knode/kncomposer.cpp
+++ b/knode/kncomposer.cpp
@@ -12,10 +12,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qheader.h>
-#include <qtextcodec.h>
-#include <qclipboard.h>
-#include <qapplication.h>
+#include <tqheader.h>
+#include <tqtextcodec.h>
+#include <tqclipboard.h>
+#include <tqapplication.h>
#include <kspelldlg.h>
#include <kdeversion.h>
#include "addressesdialog.h"
@@ -42,7 +42,7 @@ using KRecentAddress::RecentAddresses;
#include <kprocess.h>
#include <kqcstringsplitter.h>
#include <ksyntaxhighlighter.h>
-#include <qcursor.h>
+#include <tqcursor.h>
#include <kurldrag.h>
#include <kcompletionbox.h>
@@ -58,27 +58,27 @@ using KRecentAddress::RecentAddresses;
#include "knarticlefactory.h"
#include <kstatusbar.h>
#include <klocale.h>
-#include <qpopupmenu.h>
+#include <tqpopupmenu.h>
#include <spellingfilter.h>
#include <kstdguiitem.h>
KNLineEdit::KNLineEdit(KNComposer::ComposerView *_composerView, bool useCompletion,
- QWidget *parent, const char *name)
+ TQWidget *parent, const char *name)
: KNLineEditInherited(parent,useCompletion,name) , composerView(_composerView)
{
}
-QPopupMenu *KNLineEdit::createPopupMenu()
+TQPopupMenu *KNLineEdit::createPopupMenu()
{
- QPopupMenu *menu = KLineEdit::createPopupMenu();
+ TQPopupMenu *menu = KLineEdit::createPopupMenu();
if ( !menu )
return 0;
menu->insertSeparator();
menu->insertItem( i18n( "Edit Recent Addresses..." ),
- this, SLOT( editRecentAddresses() ) );
+ this, TQT_SLOT( editRecentAddresses() ) );
return menu;
}
@@ -89,8 +89,8 @@ void KNLineEdit::editRecentAddresses()
dlg.setAddresses( RecentAddresses::self( knGlobals.config() )->addresses() );
if ( dlg.exec() ) {
RecentAddresses::self( knGlobals.config() )->clear();
- QStringList addrList = dlg.addresses();
- QStringList::Iterator it;
+ TQStringList addrList = dlg.addresses();
+ TQStringList::Iterator it;
for ( it = addrList.begin(); it != addrList.end(); ++it )
RecentAddresses::self( knGlobals.config() )->add( *it );
@@ -102,13 +102,13 @@ void KNLineEdit::loadAddresses()
{
KNLineEditInherited::loadAddresses();
- QStringList recent = RecentAddresses::self(knGlobals.config())->addresses();
- QStringList::Iterator it = recent.begin();
+ TQStringList recent = RecentAddresses::self(knGlobals.config())->addresses();
+ TQStringList::Iterator it = recent.begin();
for ( ; it != recent.end(); ++it )
addAddress( *it );
}
-void KNLineEdit::keyPressEvent(QKeyEvent *e)
+void KNLineEdit::keyPressEvent(TQKeyEvent *e)
{
// ---sven's Return is same Tab and arrow key navigation start ---
if ((e->key() == Key_Enter || e->key() == Key_Return) &&
@@ -131,7 +131,7 @@ void KNLineEdit::keyPressEvent(QKeyEvent *e)
KNLineEditInherited::keyPressEvent(e);
}
-KNLineEditSpell::KNLineEditSpell( KNComposer::ComposerView *_composerView, bool useCompletion,QWidget * parent, const char * name)
+KNLineEditSpell::KNLineEditSpell( KNComposer::ComposerView *_composerView, bool useCompletion,TQWidget * parent, const char * name)
:KNLineEdit( _composerView, useCompletion, parent,name )
{
}
@@ -141,18 +141,18 @@ void KNLineEditSpell::highLightWord( unsigned int length, unsigned int pos )
setSelection ( pos, length );
}
-void KNLineEditSpell::spellCheckDone( const QString &s )
+void KNLineEditSpell::spellCheckDone( const TQString &s )
{
if( s != text() )
setText( s );
}
-void KNLineEditSpell::spellCheckerMisspelling( const QString &_text, const QStringList &, unsigned int pos)
+void KNLineEditSpell::spellCheckerMisspelling( const TQString &_text, const TQStringList &, unsigned int pos)
{
highLightWord( _text.length(),pos );
}
-void KNLineEditSpell::spellCheckerCorrected( const QString &old, const QString &corr, unsigned int pos)
+void KNLineEditSpell::spellCheckerCorrected( const TQString &old, const TQString &corr, unsigned int pos)
{
if( old!= corr )
{
@@ -163,7 +163,7 @@ void KNLineEditSpell::spellCheckerCorrected( const QString &old, const QString &
}
-KNComposer::KNComposer(KNLocalArticle *a, const QString &text, const QString &sig, const QString &unwraped, bool firstEdit, bool dislikesCopies, bool createCopy)
+KNComposer::KNComposer(KNLocalArticle *a, const TQString &text, const TQString &sig, const TQString &unwraped, bool firstEdit, bool dislikesCopies, bool createCopy)
: KMainWindow(0,"composerWindow"), r_esult(CRsave), a_rticle(a), s_ignature(sig), u_nwraped(unwraped),
n_eeds8Bit(true), v_alidated(false), a_uthorDislikesMailCopies(dislikesCopies), e_xternalEdited(false), e_xternalEditor(0),
e_ditorTempfile(0), s_pellChecker(0), a_ttChanged(false),
@@ -183,74 +183,74 @@ KNComposer::KNComposer(KNLocalArticle *a, const QString &text, const QString &si
v_iew=new ComposerView(this);
setCentralWidget(v_iew);
- connect(v_iew->c_ancelEditorBtn, SIGNAL(clicked()), SLOT(slotCancelEditor()));
- connect(v_iew->e_dit, SIGNAL(sigDragEnterEvent(QDragEnterEvent *)), SLOT(slotDragEnterEvent(QDragEnterEvent *)));
- connect(v_iew->e_dit, SIGNAL(sigDropEvent(QDropEvent *)), SLOT(slotDropEvent(QDropEvent *)));
+ connect(v_iew->c_ancelEditorBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotCancelEditor()));
+ connect(v_iew->e_dit, TQT_SIGNAL(sigDragEnterEvent(TQDragEnterEvent *)), TQT_SLOT(slotDragEnterEvent(TQDragEnterEvent *)));
+ connect(v_iew->e_dit, TQT_SIGNAL(sigDropEvent(TQDropEvent *)), TQT_SLOT(slotDropEvent(TQDropEvent *)));
//statusbar
KStatusBar *sb=statusBar();
- sb->insertItem(QString::null, 1,1); // type
+ sb->insertItem(TQString::null, 1,1); // type
sb->setItemAlignment (1,AlignLeft | AlignVCenter);
- sb->insertItem(QString::null, 2,1); // charset
+ sb->insertItem(TQString::null, 2,1); // charset
sb->setItemAlignment (2,AlignLeft | AlignVCenter);
- sb->insertItem(QString::null, 3,0); // column
+ sb->insertItem(TQString::null, 3,0); // column
sb->setItemAlignment (3,AlignCenter | AlignVCenter);
- sb->insertItem(QString::null, 4,0); // column
+ sb->insertItem(TQString::null, 4,0); // column
sb->setItemAlignment (4,AlignCenter | AlignVCenter);
- sb->insertItem(QString::null, 5,0); // line
+ sb->insertItem(TQString::null, 5,0); // line
sb->setItemAlignment (5,AlignCenter | AlignVCenter);
- connect(v_iew->e_dit, SIGNAL(CursorPositionChanged()), SLOT(slotUpdateCursorPos()));
- connect(v_iew->e_dit, SIGNAL(toggle_overwrite_signal()), SLOT(slotUpdateStatusBar()));
+ connect(v_iew->e_dit, TQT_SIGNAL(CursorPositionChanged()), TQT_SLOT(slotUpdateCursorPos()));
+ connect(v_iew->e_dit, TQT_SIGNAL(toggle_overwrite_signal()), TQT_SLOT(slotUpdateStatusBar()));
//------------------------------- <Actions> --------------------------------------
//file menu
new KAction(i18n("&Send Now"),"mail_send", CTRL + Key_Return , this,
- SLOT(slotSendNow()), actionCollection(), "send_now");
+ TQT_SLOT(slotSendNow()), actionCollection(), "send_now");
new KAction(i18n("Send &Later"), "queue", 0, this,
- SLOT(slotSendLater()), actionCollection(), "send_later");
+ TQT_SLOT(slotSendLater()), actionCollection(), "send_later");
new KAction(i18n("Save as &Draft"),"filesave", 0 , this,
- SLOT(slotSaveAsDraft()), actionCollection(), "save_as_draft");
+ TQT_SLOT(slotSaveAsDraft()), actionCollection(), "save_as_draft");
new KAction(i18n("D&elete"),"editdelete", 0 , this,
- SLOT(slotArtDelete()), actionCollection(), "art_delete");
+ TQT_SLOT(slotArtDelete()), actionCollection(), "art_delete");
- KStdAction::close(this, SLOT(close()),actionCollection());
+ KStdAction::close(this, TQT_SLOT(close()),actionCollection());
//edit menu
- KStdAction::undo(this, SLOT(slotUndo()), actionCollection());
- KStdAction::redo(this, SLOT(slotRedo()), actionCollection());
+ KStdAction::undo(this, TQT_SLOT(slotUndo()), actionCollection());
+ KStdAction::redo(this, TQT_SLOT(slotRedo()), actionCollection());
- KStdAction::cut(this, SLOT(slotCut()), actionCollection());
+ KStdAction::cut(this, TQT_SLOT(slotCut()), actionCollection());
- KStdAction::copy(this, SLOT(slotCopy()), actionCollection());
+ KStdAction::copy(this, TQT_SLOT(slotCopy()), actionCollection());
- KStdAction::pasteText(this, SLOT(slotPaste()), actionCollection());
+ KStdAction::pasteText(this, TQT_SLOT(slotPaste()), actionCollection());
new KAction(i18n("Paste as &Quotation"), 0, v_iew->e_dit,
- SLOT(slotPasteAsQuotation()), actionCollection(), "paste_quoted");
+ TQT_SLOT(slotPasteAsQuotation()), actionCollection(), "paste_quoted");
- KStdAction::selectAll(this, SLOT(slotSelectAll()), actionCollection());
+ KStdAction::selectAll(this, TQT_SLOT(slotSelectAll()), actionCollection());
- KStdAction::find(v_iew->e_dit, SLOT(slotFind()), actionCollection());
- KStdAction::findNext(v_iew->e_dit, SLOT(slotSearchAgain()), actionCollection());
+ KStdAction::find(v_iew->e_dit, TQT_SLOT(slotFind()), actionCollection());
+ KStdAction::findNext(v_iew->e_dit, TQT_SLOT(slotSearchAgain()), actionCollection());
- KStdAction::replace(v_iew->e_dit, SLOT(slotReplace()), actionCollection());
+ KStdAction::replace(v_iew->e_dit, TQT_SLOT(slotReplace()), actionCollection());
//attach menu
- new KAction(i18n("Append &Signature"), 0 , this, SLOT(slotAppendSig()),
+ new KAction(i18n("Append &Signature"), 0 , this, TQT_SLOT(slotAppendSig()),
actionCollection(), "append_signature");
- new KAction(i18n("&Insert File..."), 0, this, SLOT(slotInsertFile()),
+ new KAction(i18n("&Insert File..."), 0, this, TQT_SLOT(slotInsertFile()),
actionCollection(), "insert_file");
- new KAction(i18n("Insert File (in a &box)..."), 0, this, SLOT(slotInsertFileBoxed()),
+ new KAction(i18n("Insert File (in a &box)..."), 0, this, TQT_SLOT(slotInsertFileBoxed()),
actionCollection(), "insert_file_boxed");
- new KAction(i18n("Attach &File..."), "attach", 0, this, SLOT(slotAttachFile()),
+ new KAction(i18n("Attach &File..."), "attach", 0, this, TQT_SLOT(slotAttachFile()),
actionCollection(), "attach_file");
a_ctPGPsign = new KToggleAction(i18n("Sign Article with &PGP"),
@@ -258,69 +258,69 @@ KNComposer::KNComposer(KNLocalArticle *a, const QString &text, const QString &si
actionCollection(), "sign_article");
a_ctRemoveAttachment = new KAction(i18n("&Remove"), 0, this,
- SLOT(slotRemoveAttachment()), actionCollection(), "remove_attachment");
+ TQT_SLOT(slotRemoveAttachment()), actionCollection(), "remove_attachment");
a_ctAttachmentProperties = new KAction(i18n("&Properties"), 0, this,
- SLOT(slotAttachmentProperties()), actionCollection(), "attachment_properties");
+ TQT_SLOT(slotAttachmentProperties()), actionCollection(), "attachment_properties");
//options menu
a_ctDoPost = new KToggleAction(i18n("Send &News Article"), "filenew", 0 , this,
- SLOT(slotToggleDoPost()), actionCollection(), "send_news");
+ TQT_SLOT(slotToggleDoPost()), actionCollection(), "send_news");
a_ctDoMail = new KToggleAction(i18n("Send E&mail"), "mail_generic" , 0 , this,
- SLOT(slotToggleDoMail()), actionCollection(), "send_mail");
+ TQT_SLOT(slotToggleDoMail()), actionCollection(), "send_mail");
a_ctSetCharset = new KSelectAction(i18n("Set &Charset"), 0, actionCollection(), "set_charset");
a_ctSetCharset->setItems(knGlobals.configManager()->postNewsTechnical()->composerCharsets());
a_ctSetCharset->setShortcutConfigurable(false);
- connect(a_ctSetCharset, SIGNAL(activated(const QString&)),
- this, SLOT(slotSetCharset(const QString&)));
+ connect(a_ctSetCharset, TQT_SIGNAL(activated(const TQString&)),
+ this, TQT_SLOT(slotSetCharset(const TQString&)));
a_ctSetCharsetKeyb = new KAction(i18n("Set Charset"), 0, this,
- SLOT(slotSetCharsetKeyboard()), actionCollection(), "set_charset_keyboard");
+ TQT_SLOT(slotSetCharsetKeyboard()), actionCollection(), "set_charset_keyboard");
a_ctWordWrap = new KToggleAction(i18n("&Word Wrap"), 0 , this,
- SLOT(slotToggleWordWrap()), actionCollection(), "toggle_wordwrap");
+ TQT_SLOT(slotToggleWordWrap()), actionCollection(), "toggle_wordwrap");
//tools menu
new KAction(i18n("Add &Quote Characters"), 0, v_iew->e_dit,
- SLOT(slotAddQuotes()), actionCollection(), "tools_quote");
+ TQT_SLOT(slotAddQuotes()), actionCollection(), "tools_quote");
new KAction(i18n("&Remove Quote Characters"), 0, v_iew->e_dit,
- SLOT(slotRemoveQuotes()), actionCollection(), "tools_unquote");
+ TQT_SLOT(slotRemoveQuotes()), actionCollection(), "tools_unquote");
new KAction(i18n("Add &Box"), 0, v_iew->e_dit,
- SLOT(slotAddBox()), actionCollection(), "tools_box");
+ TQT_SLOT(slotAddBox()), actionCollection(), "tools_box");
new KAction(i18n("Re&move Box"), 0, v_iew->e_dit,
- SLOT(slotRemoveBox()), actionCollection(), "tools_unbox");
+ TQT_SLOT(slotRemoveBox()), actionCollection(), "tools_unbox");
KAction *undoRewrap = new KAction(i18n("Get &Original Text (not re-wrapped)"), 0, this,
- SLOT(slotUndoRewrap()), actionCollection(), "tools_undoRewrap");
+ TQT_SLOT(slotUndoRewrap()), actionCollection(), "tools_undoRewrap");
undoRewrap->setEnabled(!u_nwraped.isNull());
KAction *rot13 = new KAction(i18n("S&cramble (Rot 13)"), "encrypted", 0, v_iew->e_dit,
- SLOT(slotRot13()), actionCollection(), "tools_rot13");
+ TQT_SLOT(slotRot13()), actionCollection(), "tools_rot13");
rot13->setEnabled(false);
- connect(v_iew->e_dit, SIGNAL(copyAvailable(bool)), rot13, SLOT(setEnabled(bool)));
+ connect(v_iew->e_dit, TQT_SIGNAL(copyAvailable(bool)), rot13, TQT_SLOT(setEnabled(bool)));
a_ctExternalEditor = new KAction(i18n("Start &External Editor"), "run", 0, this,
- SLOT(slotExternalEditor()), actionCollection(), "external_editor");
+ TQT_SLOT(slotExternalEditor()), actionCollection(), "external_editor");
- a_ctSpellCheck = KStdAction::spelling (this, SLOT(slotSpellcheck()), actionCollection());
+ a_ctSpellCheck = KStdAction::spelling (this, TQT_SLOT(slotSpellcheck()), actionCollection());
//settings menu
createStandardStatusBarAction();
setStandardToolBarMenuEnabled(true);
- KStdAction::keyBindings(this, SLOT(slotConfKeys()), actionCollection());
+ KStdAction::keyBindings(this, TQT_SLOT(slotConfKeys()), actionCollection());
- KStdAction::configureToolbars(this, SLOT(slotConfToolbar()), actionCollection());
+ KStdAction::configureToolbars(this, TQT_SLOT(slotConfToolbar()), actionCollection());
- KStdAction::preferences(knGlobals.top, SLOT(slotSettings()), actionCollection());
+ KStdAction::preferences(knGlobals.top, TQT_SLOT(slotSettings()), actionCollection());
a_ccel=new KAccel(this);
a_ctSetCharsetKeyb->plugAccel(a_ccel);
@@ -331,8 +331,8 @@ KNComposer::KNComposer(KNLocalArticle *a, const QString &text, const QString &si
//attachment popup
- a_ttPopup=static_cast<QPopupMenu*> (factory()->container("attachment_popup", this));
- if(!a_ttPopup) a_ttPopup = new QPopupMenu();
+ a_ttPopup=static_cast<TQPopupMenu*> (factory()->container("attachment_popup", this));
+ if(!a_ttPopup) a_ttPopup = new TQPopupMenu();
slotAttachmentSelected(0);
//init
@@ -398,7 +398,7 @@ KNComposer::~KNComposer()
delete e_ditorTempfile;
}
- for ( QValueList<KNAttachment*>::Iterator it = mDeletedAttachments.begin(); it != mDeletedAttachments.end(); ++it )
+ for ( TQValueList<KNAttachment*>::Iterator it = mDeletedAttachments.begin(); it != mDeletedAttachments.end(); ++it )
delete (*it);
KConfig *conf = knGlobals.config();
@@ -406,21 +406,21 @@ KNComposer::~KNComposer()
saveMainWindowSettings(conf);
}
-int KNComposer::listOfResultOfCheckWord( const QStringList & lst , const QString & selectWord)
+int KNComposer::listOfResultOfCheckWord( const TQStringList & lst , const TQString & selectWord)
{
createGUI("kncomposerui.rc", false);
unplugActionList("spell_result" );
m_listAction.clear();
if ( !lst.contains( selectWord ) )
{
- QStringList::ConstIterator it = lst.begin();
+ TQStringList::ConstIterator it = lst.begin();
for ( ; it != lst.end() ; ++it )
{
if ( !(*it).isEmpty() ) // in case of removed subtypes or placeholders
{
KAction * act = new KAction( *it );
- connect( act, SIGNAL(activated()), v_iew->e_dit, SLOT(slotCorrectWord()) );
+ connect( act, TQT_SIGNAL(activated()), v_iew->e_dit, TQT_SLOT(slotCorrectWord()) );
m_listAction.append( act );
}
}
@@ -432,47 +432,47 @@ int KNComposer::listOfResultOfCheckWord( const QStringList & lst , const QString
void KNComposer::slotUndo()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
if (fw->inherits("KEdit"))
- ((QMultiLineEdit*)fw)->undo();
- else if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->undo();
+ ((TQMultiLineEdit*)fw)->undo();
+ else if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->undo();
}
void KNComposer::slotRedo()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
if (fw->inherits("KEdit"))
- ((QMultiLineEdit*)fw)->redo();
- else if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->redo();
+ ((TQMultiLineEdit*)fw)->redo();
+ else if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->redo();
}
void KNComposer::slotCut()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
if (fw->inherits("KEdit"))
- ((QMultiLineEdit*)fw)->cut();
- else if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->cut();
+ ((TQMultiLineEdit*)fw)->cut();
+ else if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->cut();
else kdDebug(5003) << "wrong focus widget" << endl;
}
void KNComposer::slotCopy()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
if (fw->inherits("KEdit"))
- ((QMultiLineEdit*)fw)->copy();
- else if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->copy();
+ ((TQMultiLineEdit*)fw)->copy();
+ else if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->copy();
else kdDebug(5003) << "wrong focus widget" << endl;
}
@@ -480,25 +480,25 @@ void KNComposer::slotCopy()
void KNComposer::slotPaste()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
if (fw->inherits("KEdit"))
- ((QMultiLineEdit*)fw)->paste();
- else if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->paste();
+ ((TQMultiLineEdit*)fw)->paste();
+ else if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->paste();
else kdDebug(5003) << "wrong focus widget" << endl;
}
void KNComposer::slotSelectAll()
{
- QWidget* fw = focusWidget();
+ TQWidget* fw = focusWidget();
if (!fw) return;
- if (fw->inherits("QLineEdit"))
- ((QLineEdit*)fw)->selectAll();
- else if (fw->inherits("QMultiLineEdit"))
- ((QMultiLineEdit*)fw)->selectAll();
+ if (fw->inherits("TQLineEdit"))
+ ((TQLineEdit*)fw)->selectAll();
+ else if (fw->inherits("TQMultiLineEdit"))
+ ((TQMultiLineEdit*)fw)->selectAll();
}
@@ -506,7 +506,7 @@ void KNComposer::setConfig(bool onlyFonts)
{
if (!onlyFonts) {
v_iew->e_dit->setWordWrap(knGlobals.configManager()->postNewsComposer()->wordWrap()?
- QMultiLineEdit::FixedColumnWidth : QMultiLineEdit::NoWrap);
+ TQMultiLineEdit::FixedColumnWidth : TQMultiLineEdit::NoWrap);
v_iew->e_dit->setWrapColumnOrWidth(knGlobals.configManager()->postNewsComposer()->maxLineLength());
a_ctWordWrap->setChecked(knGlobals.configManager()->postNewsComposer()->wordWrap());
@@ -514,7 +514,7 @@ void KNComposer::setConfig(bool onlyFonts)
a_ctPGPsign->setEnabled(pgp->usePGP());
}
- QFont fnt=knGlobals.configManager()->appearance()->composerFont();
+ TQFont fnt=knGlobals.configManager()->appearance()->composerFont();
v_iew->s_ubject->setFont(fnt);
v_iew->t_o->setFont(fnt);
v_iew->g_roups->setFont(fnt);
@@ -533,7 +533,7 @@ void KNComposer::setMessageMode(MessageMode mode)
v_iew->setMessageMode(m_ode);
if (m_ode == news_mail) {
- QString s = v_iew->e_dit->textLine(0);
+ TQString s = v_iew->e_dit->textLine(0);
if (!s.contains(i18n("<posted & mailed>")))
v_iew->e_dit->insertAt(i18n("<posted & mailed>\n\n"),0,0);
} else {
@@ -568,8 +568,8 @@ bool KNComposer::hasValidData()
return false;
}
- int groupCount = QStringList::split(',',v_iew->g_roups->text()).count();
- int fupCount = QStringList::split(',',v_iew->f_up2->currentText()).count();
+ int groupCount = TQStringList::split(',',v_iew->g_roups->text()).count();
+ int fupCount = TQStringList::split(',',v_iew->f_up2->currentText()).count();
bool followUp = !v_iew->f_up2->currentText().isEmpty();
if (groupCount>12) {
@@ -579,7 +579,7 @@ bool KNComposer::hasValidData()
if (groupCount>5)
if (!(KMessageBox::warningYesNo( this, i18n("You are crossposting to more than five newsgroups.\nPlease reconsider whether this is really useful\nand remove groups in which your article is off-topic.\nDo you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
+ TQString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
return false;
if ( !followUp && groupCount > 2 ) {
@@ -588,7 +588,7 @@ bool KNComposer::hasValidData()
"Please use the \"Followup-To\" header to direct the replies "
"to your article into one group.\n"
"Do you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"), i18n("edit article","&Edit"), "missingFollowUpTo" )
+ TQString::null, i18n("&Send"), i18n("edit article","&Edit"), "missingFollowUpTo" )
!= KMessageBox::Yes )
return false;
}
@@ -600,7 +600,7 @@ bool KNComposer::hasValidData()
if (fupCount>5)
if (!(KMessageBox::warningYesNo( this, i18n("You are directing replies to more than five newsgroups.\nPlease reconsider whether this is really useful.\nDo you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
+ TQString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
return false;
}
@@ -621,9 +621,9 @@ bool KNComposer::hasValidData()
int sigLength = 0;
int notQuoted = 0;
int textLines = 0;
- QStringList text = v_iew->e_dit->processedText();
+ TQStringList text = v_iew->e_dit->processedText();
- for (QStringList::Iterator it = text.begin(); it != text.end(); ++it) {
+ for (TQStringList::Iterator it = text.begin(); it != text.end(); ++it) {
if (!n_eeds8Bit && !KMime::isUsAscii(*it))
n_eeds8Bit=true;
@@ -670,7 +670,7 @@ bool KNComposer::hasValidData()
if ((textLines>1)&&(notQuoted==1)) {
if (hasAttributionLine)
if (!(KMessageBox::warningYesNo( this, i18n("Your article seems to consist entirely of quoted text;\ndo you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
+ TQString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
return false;
} else {
if (notQuoted==0) {
@@ -684,23 +684,23 @@ bool KNComposer::hasValidData()
if (!(KMessageBox::warningYesNo( this,
i18n("Your article contains lines longer than 80 characters.\n"
"Do you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"),
+ TQString::null, i18n("&Send"),
i18n("edit article","&Edit")) == KMessageBox::Yes))
return false;
if (sigLength>8) {
if (!(KMessageBox::warningYesNo( this, i18n("Your signature is more than 8 lines long.\nYou should shorten it to match the widely accepted limit of 4 lines.\nDo you want to re-edit the article or send it anyway?"),
- QString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
+ TQString::null, i18n("&Send"),i18n("edit article","&Edit")) == KMessageBox::Yes))
return false;
} else
if (sigLength>4)
KMessageBox::information(this, i18n("Your signature exceeds the widely-accepted limit of 4 lines:\nplease consider shortening your signature;\notherwise, you will probably annoy your readers."),
- QString::null,"longSignatureWarning");
+ TQString::null,"longSignatureWarning");
// check if article can be signed
if ( a_ctPGPsign->isChecked() ) {
// try to get the signing key
- QCString signingKey = knGlobals.configManager()->identity()->signingKey();
+ TQCString signingKey = knGlobals.configManager()->identity()->signingKey();
KNNntpAccount *acc = knGlobals.accountManager()->account( a_rticle->serverId() );
if ( acc ) {
KMime::Headers::Newsgroups *grps = a_rticle->newsgroups();
@@ -721,7 +721,7 @@ bool KNComposer::hasValidData()
"in the account properties or in the "
"group properties.\n"
"The article will be sent unsigned." ),
- QString::null, i18n( "Send Unsigned" ),
+ TQString::null, i18n( "Send Unsigned" ),
"sendUnsignedDialog" )
== KMessageBox::Cancel )
return false;
@@ -746,7 +746,7 @@ bool KNComposer::applyChanges()
//Newsgroups
if (m_ode != mail) {
- a_rticle->newsgroups()->fromUnicodeString(v_iew->g_roups->text().remove(QRegExp("\\s")), KMime::Headers::Latin1);
+ a_rticle->newsgroups()->fromUnicodeString(v_iew->g_roups->text().remove(TQRegExp("\\s")), KMime::Headers::Latin1);
a_rticle->setDoPost(true);
} else
a_rticle->setDoPost(false);
@@ -766,7 +766,7 @@ bool KNComposer::applyChanges()
if(a_ttChanged && (v_iew->a_ttView)) {
- QListViewItemIterator it(v_iew->a_ttView);
+ TQListViewItemIterator it(v_iew->a_ttView);
while(it.current()) {
a=(static_cast<AttachmentViewItem*> (it.current()))->attachment;
if(a->hasChanged()) {
@@ -779,7 +779,7 @@ bool KNComposer::applyChanges()
}
}
- for ( QValueList<KNAttachment*>::Iterator it = mDeletedAttachments.begin(); it != mDeletedAttachments.end(); ++it )
+ for ( TQValueList<KNAttachment*>::Iterator it = mDeletedAttachments.begin(); it != mDeletedAttachments.end(); ++it )
if ( (*it)->isAttached() )
(*it)->detach( a_rticle );
@@ -817,15 +817,15 @@ bool KNComposer::applyChanges()
}
//assemble the text line by line
- QString tmp;
- QStringList textLines = v_iew->e_dit->processedText();
- for (QStringList::Iterator it = textLines.begin(); it != textLines.end(); ++it)
+ TQString tmp;
+ TQStringList textLines = v_iew->e_dit->processedText();
+ for (TQStringList::Iterator it = textLines.begin(); it != textLines.end(); ++it)
tmp += *it + "\n";
// Sign article if needed
if ( a_ctPGPsign->isChecked() ) {
// first get the signing key
- QCString signingKey = knGlobals.configManager()->identity()->signingKey();
+ TQCString signingKey = knGlobals.configManager()->identity()->signingKey();
KNNntpAccount *acc = knGlobals.accountManager()->account( a_rticle->serverId() );
if ( acc ) {
KMime::Headers::Newsgroups *grps = a_rticle->newsgroups();
@@ -837,17 +837,17 @@ bool KNComposer::applyChanges()
}
// now try to sign the article
if (!signingKey.isEmpty()) {
- QString tmpText = tmp;
+ TQString tmpText = tmp;
Kpgp::Block block;
bool ok=true;
- QTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
+ TQTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
if(!ok) // no suitable codec found => try local settings and hope the best ;-)
codec=KGlobal::locale()->codecForEncoding();
block.setText( codec->fromUnicode(tmpText) );
kdDebug(5003) << "signing article from " << article()->from()->email() << endl;
if( block.clearsign( signingKey, codec->name() ) == Kpgp::Ok ) {
- QCString result = block.text();
+ TQCString result = block.text();
tmp = codec->toUnicode(result.data(), result.length() );
} else {
return false;
@@ -866,7 +866,7 @@ bool KNComposer::applyChanges()
}
-void KNComposer::closeEvent(QCloseEvent *e)
+void KNComposer::closeEvent(TQCloseEvent *e)
{
if(!v_iew->e_dit->isModified() && !a_ttChanged) { // nothing to save, don't show nag screen
if(a_rticle->id()==-1)
@@ -876,7 +876,7 @@ void KNComposer::closeEvent(QCloseEvent *e)
}
else {
switch ( KMessageBox::warningYesNoCancel( this, i18n("Do you want to save this article in the draft folder?"),
- QString::null, KStdGuiItem::save(), KStdGuiItem::discard())) {
+ TQString::null, KStdGuiItem::save(), KStdGuiItem::discard())) {
case KMessageBox::Yes :
r_esult=CRsave;
break;
@@ -896,11 +896,11 @@ void KNComposer::closeEvent(QCloseEvent *e)
}
-void KNComposer::initData(const QString &text)
+void KNComposer::initData(const TQString &text)
{
//Subject
if(a_rticle->subject()->isEmpty())
- slotSubjectChanged(QString::null);
+ slotSubjectChanged(TQString::null);
else
v_iew->s_ubject->setText(a_rticle->subject()->asUnicodeString());
@@ -916,7 +916,7 @@ void KNComposer::initData(const QString &text)
v_iew->f_up2->lineEdit()->setText(fup2->asUnicodeString());
KMime::Content *textContent=a_rticle->textContent();
- QString s;
+ TQString s;
if(text.isEmpty()) {
if(textContent)
@@ -960,21 +960,21 @@ void KNComposer::initData(const QString &text)
// inserts at cursor position if clear is false, replaces content otherwise
// puts the file content into a box if box==true
// "file" is already open for reading
-void KNComposer::insertFile(QFile *file, bool clear, bool box, QString boxTitle)
+void KNComposer::insertFile(TQFile *file, bool clear, bool box, TQString boxTitle)
{
- QString temp;
+ TQString temp;
bool ok=true;
- QTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
- QTextStream ts(file);
+ TQTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
+ TQTextStream ts(file);
ts.setCodec(codec);
if (box)
- temp = QString::fromLatin1(",----[ %1 ]\n").arg(boxTitle);
+ temp = TQString::fromLatin1(",----[ %1 ]\n").arg(boxTitle);
- if (box && (v_iew->e_dit->wordWrap()!=QMultiLineEdit::NoWrap)) {
+ if (box && (v_iew->e_dit->wordWrap()!=TQMultiLineEdit::NoWrap)) {
int wrapAt = v_iew->e_dit->wrapColumnOrWidth();
- QStringList lst;
- QString line;
+ TQStringList lst;
+ TQString line;
while(!file->atEnd()) {
line=ts.readLine();
if (!file->atEnd())
@@ -993,7 +993,7 @@ void KNComposer::insertFile(QFile *file, bool clear, bool box, QString boxTitle)
}
if (box)
- temp += QString::fromLatin1("`----");
+ temp += TQString::fromLatin1("`----");
if(clear)
v_iew->e_dit->setText(temp);
@@ -1006,9 +1006,9 @@ void KNComposer::insertFile(QFile *file, bool clear, bool box, QString boxTitle)
void KNComposer::insertFile(bool clear, bool box)
{
KNLoadHelper helper(this);
- QFile *file = helper.getFile(i18n("Insert File"));
+ TQFile *file = helper.getFile(i18n("Insert File"));
KURL url;
- QString boxName;
+ TQString boxName;
if (file) {
url = helper.getURL();
@@ -1165,19 +1165,19 @@ void KNComposer::slotToggleDoMail()
if (a_ctDoMail->isChecked()) {
if (a_uthorDislikesMailCopies) {
if (!(KMessageBox::warningContinueCancel(this, i18n("The poster does not want a mail copy of your reply (Mail-Copies-To: nobody);\nplease respect their request."),
- QString::null, i18n("&Send Copy")) == KMessageBox::Continue)) {
+ TQString::null, i18n("&Send Copy")) == KMessageBox::Continue)) {
a_ctDoMail->setChecked(false); //revert
return;
}
}
if (knGlobals.configManager()->postNewsTechnical()->useExternalMailer()) {
- QString s = v_iew->e_dit->textLine(0);
+ TQString s = v_iew->e_dit->textLine(0);
if (!s.contains(i18n("<posted & mailed>")))
v_iew->e_dit->insertAt(i18n("<posted & mailed>\n\n"),0,0);
- QString tmp;
- QStringList textLines = v_iew->e_dit->processedText();
- for (QStringList::Iterator it = textLines.begin(); it != textLines.end(); ++it) {
+ TQString tmp;
+ TQStringList textLines = v_iew->e_dit->processedText();
+ for (TQStringList::Iterator it = textLines.begin(); it != textLines.end(); ++it) {
if (*it == "-- ") // try to be smart, don't include the signature,
break; // kmail will append one, too.
tmp+=*it+"\n";
@@ -1203,7 +1203,7 @@ void KNComposer::slotToggleDoMail()
}
-void KNComposer::slotSetCharset(const QString &s)
+void KNComposer::slotSetCharset(const TQString &s)
{
if(s.isEmpty())
return;
@@ -1225,7 +1225,7 @@ void KNComposer::slotSetCharsetKeyboard()
void KNComposer::slotToggleWordWrap()
{
- v_iew->e_dit->setWordWrap(a_ctWordWrap->isChecked()? QMultiLineEdit::FixedColumnWidth : QMultiLineEdit::NoWrap);
+ v_iew->e_dit->setWordWrap(a_ctWordWrap->isChecked()? TQMultiLineEdit::FixedColumnWidth : TQMultiLineEdit::NoWrap);
}
@@ -1242,7 +1242,7 @@ void KNComposer::slotExternalEditor()
if(e_xternalEditor) // in progress...
return;
- QString editorCommand=knGlobals.configManager()->postNewsComposer()->externalEditor();
+ TQString editorCommand=knGlobals.configManager()->postNewsComposer()->externalEditor();
if(editorCommand.isEmpty())
KMessageBox::sorry(this, i18n("No editor configured.\nPlease do this in the settings dialog."));
@@ -1264,18 +1264,18 @@ void KNComposer::slotExternalEditor()
}
bool ok=true;
- QTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
+ TQTextCodec *codec=KGlobal::charsets()->codecForName(c_harset, ok);
- QString tmp;
- QStringList textLines = v_iew->e_dit->processedText();
- for (QStringList::Iterator it = textLines.begin(); it != textLines.end();) {
+ TQString tmp;
+ TQStringList textLines = v_iew->e_dit->processedText();
+ for (TQStringList::Iterator it = textLines.begin(); it != textLines.end();) {
tmp += *it;
++it;
if (it != textLines.end())
tmp+="\n";
}
- QCString local = codec->fromUnicode(tmp);
+ TQCString local = codec->fromUnicode(tmp);
e_ditorTempfile->file()->writeBlock(local.data(),local.length());
e_ditorTempfile->file()->flush();
@@ -1290,11 +1290,11 @@ void KNComposer::slotExternalEditor()
e_xternalEditor=new KProcess();
// construct command line...
- QStringList command = QStringList::split(' ',editorCommand);
+ TQStringList command = TQStringList::split(' ',editorCommand);
bool filenameAdded=false;
- for ( QStringList::Iterator it = command.begin(); it != command.end(); ++it ) {
+ for ( TQStringList::Iterator it = command.begin(); it != command.end(); ++it ) {
if ((*it).contains("%f")) {
- (*it).replace(QRegExp("%f"),e_ditorTempfile->name());
+ (*it).replace(TQRegExp("%f"),e_ditorTempfile->name());
filenameAdded=true;
}
(*e_xternalEditor) << (*it);
@@ -1302,7 +1302,7 @@ void KNComposer::slotExternalEditor()
if(!filenameAdded) // no %f in the editor command
(*e_xternalEditor) << e_ditorTempfile->name();
- connect(e_xternalEditor, SIGNAL(processExited(KProcess *)),this, SLOT(slotEditorFinished(KProcess *)));
+ connect(e_xternalEditor, TQT_SIGNAL(processExited(KProcess *)),this, TQT_SLOT(slotEditorFinished(KProcess *)));
if(!e_xternalEditor->start()) {
KMessageBox::error(this, i18n("Unable to start external editor.\nPlease check your configuration in the settings dialog."));
delete e_xternalEditor;
@@ -1327,21 +1327,21 @@ void KNComposer::slotSpellcheck()
a_ctExternalEditor->setEnabled(false);
a_ctSpellCheck->setEnabled(false);
- s_pellChecker = new KSpell(this, i18n("Spellcheck"), this, SLOT(slotSpellStarted(KSpell *)));
- QStringList l = KSpellingHighlighter::personalWords();
- for ( QStringList::Iterator it = l.begin(); it != l.end(); ++it ) {
+ s_pellChecker = new KSpell(this, i18n("Spellcheck"), this, TQT_SLOT(slotSpellStarted(KSpell *)));
+ TQStringList l = KSpellingHighlighter::personalWords();
+ for ( TQStringList::Iterator it = l.begin(); it != l.end(); ++it ) {
s_pellChecker->addPersonal( *it );
}
- connect(s_pellChecker, SIGNAL(death()), this, SLOT(slotSpellFinished()));
- connect(s_pellChecker, SIGNAL(done(const QString&)), this, SLOT(slotSpellDone(const QString&)));
- connect(s_pellChecker, SIGNAL(misspelling (const QString &, const QStringList &, unsigned int)),
- this, SLOT(slotMisspelling (const QString &, const QStringList &, unsigned int)));
- connect(s_pellChecker, SIGNAL(corrected (const QString &, const QString &, unsigned int)),
- this, SLOT(slotCorrected (const QString &, const QString &, unsigned int)));
+ connect(s_pellChecker, TQT_SIGNAL(death()), this, TQT_SLOT(slotSpellFinished()));
+ connect(s_pellChecker, TQT_SIGNAL(done(const TQString&)), this, TQT_SLOT(slotSpellDone(const TQString&)));
+ connect(s_pellChecker, TQT_SIGNAL(misspelling (const TQString &, const TQStringList &, unsigned int)),
+ this, TQT_SLOT(slotMisspelling (const TQString &, const TQStringList &, unsigned int)));
+ connect(s_pellChecker, TQT_SIGNAL(corrected (const TQString &, const TQString &, unsigned int)),
+ this, TQT_SLOT(slotCorrected (const TQString &, const TQString &, unsigned int)));
}
-void KNComposer::slotMisspelling(const QString &text, const QStringList &lst, unsigned int pos)
+void KNComposer::slotMisspelling(const TQString &text, const TQStringList &lst, unsigned int pos)
{
if( spellLineEdit )
v_iew->s_ubject->spellCheckerMisspelling( text, lst, pos);
@@ -1350,7 +1350,7 @@ void KNComposer::slotMisspelling(const QString &text, const QStringList &lst, un
}
-void KNComposer::slotCorrected (const QString &oldWord, const QString &newWord, unsigned int pos)
+void KNComposer::slotCorrected (const TQString &oldWord, const TQString &newWord, unsigned int pos)
{
if( spellLineEdit )
v_iew->s_ubject->spellCheckerCorrected( oldWord, newWord, pos);
@@ -1360,7 +1360,7 @@ void KNComposer::slotCorrected (const QString &oldWord, const QString &newWord,
void KNComposer::slotUpdateStatusBar()
{
- QString typeDesc;
+ TQString typeDesc;
switch (m_ode) {
case news: typeDesc = i18n("News Article");
break;
@@ -1368,7 +1368,7 @@ void KNComposer::slotUpdateStatusBar()
break;
default : typeDesc = i18n("News Article & Email");
}
- QString overwriteDesc;
+ TQString overwriteDesc;
if (v_iew->e_dit->isOverwriteMode())
overwriteDesc = i18n(" OVR ");
else
@@ -1401,7 +1401,7 @@ void KNComposer::slotConfToolbar()
conf->setGroup("composerWindow_options");
saveMainWindowSettings(conf);
KEditToolbar dlg(guiFactory(),this);
- connect(&dlg,SIGNAL( newToolbarConfig() ), this, SLOT( slotNewToolbarConfig() ));
+ connect(&dlg,TQT_SIGNAL( newToolbarConfig() ), this, TQT_SLOT( slotNewToolbarConfig() ));
dlg.exec();
}
@@ -1409,8 +1409,8 @@ void KNComposer::slotNewToolbarConfig()
{
createGUI("kncomposerui.rc");
- a_ttPopup=static_cast<QPopupMenu*> (factory()->container("attachment_popup", this));
- if(!a_ttPopup) a_ttPopup = new QPopupMenu();
+ a_ttPopup=static_cast<TQPopupMenu*> (factory()->container("attachment_popup", this));
+ if(!a_ttPopup) a_ttPopup = new TQPopupMenu();
KConfig *conf = knGlobals.config();
conf->setGroup("composerWindow_options");
@@ -1420,10 +1420,10 @@ void KNComposer::slotNewToolbarConfig()
//-------------------------------- </Actions> -----------------------------------
-void KNComposer::slotSubjectChanged(const QString &t)
+void KNComposer::slotSubjectChanged(const TQString &t)
{
// replace newlines
- QString subject = t;
+ TQString subject = t;
subject.replace( '\n', ' ' );
subject.replace( '\r', ' ' );
if ( subject != t ) // setText() sets the cursor to the end
@@ -1436,18 +1436,18 @@ void KNComposer::slotSubjectChanged(const QString &t)
}
-void KNComposer::slotGroupsChanged(const QString &t)
+void KNComposer::slotGroupsChanged(const TQString &t)
{
KQCStringSplitter split;
bool splitOk;
- QString currText=v_iew->f_up2->currentText();
+ TQString currText=v_iew->f_up2->currentText();
v_iew->f_up2->clear();
split.init(t.latin1(), ",");
splitOk=split.first();
while(splitOk) {
- v_iew->f_up2->insertItem(QString::fromLatin1(split.string()));
+ v_iew->f_up2->insertItem(TQString::fromLatin1(split.string()));
splitOk=split.next();
}
v_iew->f_up2->insertItem("");
@@ -1460,12 +1460,12 @@ void KNComposer::slotGroupsChanged(const QString &t)
void KNComposer::slotToBtnClicked()
{
AddressesDialog dlg( this );
- QString txt;
- QString to = v_iew->t_o->text();
+ TQString txt;
+ TQString to = v_iew->t_o->text();
dlg.setShowBCC(false);
dlg.setShowCC(false);
#if 0
- QStringList lst;
+ TQStringList lst;
txt = mEdtTo->text().stripWhiteSpace();
@@ -1475,7 +1475,7 @@ void KNComposer::slotToBtnClicked()
}
#endif
dlg.setRecentAddresses( RecentAddresses::self(knGlobals.config())->kabcAddresses() );
- if (dlg.exec()==QDialog::Rejected) return;
+ if (dlg.exec()==TQDialog::Rejected) return;
if(!to.isEmpty())
to+=", ";
@@ -1506,12 +1506,12 @@ void KNComposer::slotGroupsBtnClicked()
if(id==-1)
a_rticle->setServerId(nntp->id());
- KNGroupSelectDialog *dlg=new KNGroupSelectDialog(this, nntp, v_iew->g_roups->text().remove(QRegExp("\\s")));
+ KNGroupSelectDialog *dlg=new KNGroupSelectDialog(this, nntp, v_iew->g_roups->text().remove(TQRegExp("\\s")));
- connect(dlg, SIGNAL(loadList(KNNntpAccount*)),
- knGlobals.groupManager(), SLOT(slotLoadGroupList(KNNntpAccount*)));
- connect(knGlobals.groupManager(), SIGNAL(newListReady(KNGroupListData*)),
- dlg, SLOT(slotReceiveList(KNGroupListData*)));
+ connect(dlg, TQT_SIGNAL(loadList(KNNntpAccount*)),
+ knGlobals.groupManager(), TQT_SLOT(slotLoadGroupList(KNNntpAccount*)));
+ connect(knGlobals.groupManager(), TQT_SIGNAL(newListReady(KNGroupListData*)),
+ dlg, TQT_SLOT(slotReceiveList(KNGroupListData*)));
if(dlg->exec())
v_iew->g_roups->setText(dlg->selectedGroups());
@@ -1547,14 +1547,14 @@ void KNComposer::slotCancelEditor()
}
-void KNComposer::slotAttachmentPopup(KListView*, QListViewItem *it, const QPoint &p)
+void KNComposer::slotAttachmentPopup(KListView*, TQListViewItem *it, const TQPoint &p)
{
if(it)
a_ttPopup->popup(p);
}
-void KNComposer::slotAttachmentSelected(QListViewItem *it)
+void KNComposer::slotAttachmentSelected(TQListViewItem *it)
{
if(v_iew->a_ttWidget) {
v_iew->a_ttRemoveBtn->setEnabled((it!=0));
@@ -1563,13 +1563,13 @@ void KNComposer::slotAttachmentSelected(QListViewItem *it)
}
-void KNComposer::slotAttachmentEdit(QListViewItem *)
+void KNComposer::slotAttachmentEdit(TQListViewItem *)
{
slotAttachmentProperties();
}
-void KNComposer::slotAttachmentRemove(QListViewItem *)
+void KNComposer::slotAttachmentRemove(TQListViewItem *)
{
slotRemoveAttachment();
}
@@ -1590,7 +1590,7 @@ void KNComposer::slotSpellStarted( KSpell *)
// read the quote indicator from the preferences
KConfig *config=knGlobals.config();
KConfigGroupSaver saver(config, "READNEWS");
- QString quotePrefix;
+ TQString quotePrefix;
quotePrefix = config->readEntry("quoteCharacters",">");
//todo fixme
//quotePrefix = mComposer->msg()->formatString(quotePrefix);
@@ -1605,7 +1605,7 @@ void KNComposer::slotSpellStarted( KSpell *)
s_pellChecker->check( v_iew->s_ubject->text());
}
-void KNComposer::slotSpellDone(const QString &newtext)
+void KNComposer::slotSpellDone(const TQString &newtext)
{
a_ctExternalEditor->setEnabled(true);
a_ctSpellCheck->setEnabled(true);
@@ -1619,7 +1619,7 @@ void KNComposer::slotSpellDone(const QString &newtext)
{
//stop spell check
spellLineEdit = false;
- QString tmpText( newtext);
+ TQString tmpText( newtext);
tmpText = tmpText.remove('\n');
if( tmpText != v_iew->s_ubject->text() )
@@ -1669,14 +1669,14 @@ void KNComposer::slotSpellFinished()
}
-void KNComposer::slotDragEnterEvent(QDragEnterEvent *ev)
+void KNComposer::slotDragEnterEvent(TQDragEnterEvent *ev)
{
- QStringList files;
+ TQStringList files;
ev->accept(KURLDrag::canDecode(ev));
}
-void KNComposer::slotDropEvent(QDropEvent *ev)
+void KNComposer::slotDropEvent(TQDropEvent *ev)
{
KURL::List urls;
@@ -1701,22 +1701,22 @@ void KNComposer::slotDropEvent(QDropEvent *ev)
}
-void KNComposer::dragEnterEvent(QDragEnterEvent *ev)
+void KNComposer::dragEnterEvent(TQDragEnterEvent *ev)
{
slotDragEnterEvent(ev);
}
-void KNComposer::dropEvent(QDropEvent *ev)
+void KNComposer::dropEvent(TQDropEvent *ev)
{
slotDropEvent(ev);
}
-QPopupMenu * KNComposer::popupMenu( const QString& name )
+TQPopupMenu * KNComposer::popupMenu( const TQString& name )
{
Q_ASSERT(factory());
if ( factory() )
- return ((QPopupMenu*)factory()->container( name, this ));
+ return ((TQPopupMenu*)factory()->container( name, this ));
return 0L;
}
@@ -1725,43 +1725,43 @@ QPopupMenu * KNComposer::popupMenu( const QString& name )
KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n)
- : QSplitter(QSplitter::Vertical, composer, n), a_ttWidget(0), a_ttView(0), v_iewOpen(false)
+ : TQSplitter(TQSplitter::Vertical, composer, n), a_ttWidget(0), a_ttView(0), v_iewOpen(false)
{
- QWidget *main=new QWidget(this);
+ TQWidget *main=new TQWidget(this);
//headers
- QFrame *hdrFrame=new QFrame(main);
- hdrFrame->setFrameStyle(QFrame::Box | QFrame::Sunken);
- QGridLayout *hdrL=new QGridLayout(hdrFrame, 4,3, 7,5);
+ TQFrame *hdrFrame=new TQFrame(main);
+ hdrFrame->setFrameStyle(TQFrame::Box | TQFrame::Sunken);
+ TQGridLayout *hdrL=new TQGridLayout(hdrFrame, 4,3, 7,5);
hdrL->setColStretch(1,1);
//To
t_o=new KNLineEdit(this, true, hdrFrame);
mEdtList.append(t_o);
- l_to=new QLabel(t_o, i18n("T&o:"), hdrFrame);
- t_oBtn=new QPushButton(i18n("&Browse..."), hdrFrame);
+ l_to=new TQLabel(t_o, i18n("T&o:"), hdrFrame);
+ t_oBtn=new TQPushButton(i18n("&Browse..."), hdrFrame);
hdrL->addWidget(l_to, 0,0);
hdrL->addWidget(t_o, 0,1);
hdrL->addWidget(t_oBtn, 0,2);
- connect(t_oBtn, SIGNAL(clicked()), parent(), SLOT(slotToBtnClicked()));
+ connect(t_oBtn, TQT_SIGNAL(clicked()), parent(), TQT_SLOT(slotToBtnClicked()));
//Newsgroups
g_roups=new KNLineEdit(this, false, hdrFrame);
mEdtList.append(g_roups);
- l_groups=new QLabel(g_roups, i18n("&Groups:"), hdrFrame);
- g_roupsBtn=new QPushButton(i18n("B&rowse..."), hdrFrame);
+ l_groups=new TQLabel(g_roups, i18n("&Groups:"), hdrFrame);
+ g_roupsBtn=new TQPushButton(i18n("B&rowse..."), hdrFrame);
hdrL->addWidget(l_groups, 1,0);
hdrL->addWidget(g_roups, 1,1);
hdrL->addWidget(g_roupsBtn, 1,2);
- connect(g_roups, SIGNAL(textChanged(const QString&)),
- parent(), SLOT(slotGroupsChanged(const QString&)));
- connect(g_roupsBtn, SIGNAL(clicked()), parent(), SLOT(slotGroupsBtnClicked()));
+ connect(g_roups, TQT_SIGNAL(textChanged(const TQString&)),
+ parent(), TQT_SLOT(slotGroupsChanged(const TQString&)));
+ connect(g_roupsBtn, TQT_SIGNAL(clicked()), parent(), TQT_SLOT(slotGroupsBtnClicked()));
//Followup-To
f_up2=new KComboBox(true, hdrFrame);
- l_fup2=new QLabel(f_up2, i18n("Follo&wup-To:"), hdrFrame);
+ l_fup2=new TQLabel(f_up2, i18n("Follo&wup-To:"), hdrFrame);
hdrL->addWidget(l_fup2, 2,0);
hdrL->addMultiCellWidget(f_up2, 2,2, 1,2);
@@ -1769,11 +1769,11 @@ KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n)
s_ubject=new KNLineEditSpell(this, false, hdrFrame);
mEdtList.append(s_ubject);
- QLabel *l=new QLabel(s_ubject, i18n("S&ubject:"), hdrFrame);
+ TQLabel *l=new TQLabel(s_ubject, i18n("S&ubject:"), hdrFrame);
hdrL->addWidget(l, 3,0);
hdrL->addMultiCellWidget(s_ubject, 3,3, 1,2);
- connect(s_ubject, SIGNAL(textChanged(const QString&)),
- parent(), SLOT(slotSubjectChanged(const QString&)));
+ connect(s_ubject, TQT_SIGNAL(textChanged(const TQString&)),
+ parent(), TQT_SLOT(slotSubjectChanged(const TQString&)));
//Editor
e_dit=new Editor(this, composer, main);
@@ -1781,34 +1781,34 @@ KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n)
KConfig *config = knGlobals.config();
KConfigGroupSaver saver(config, "VISUAL_APPEARANCE");
- QColor defaultColor1( kapp->palette().active().text()); // defaults from kmreaderwin.cpp
- QColor defaultColor2( kapp->palette().active().text() );
- QColor defaultColor3( kapp->palette().active().text() );
- QColor defaultForeground( kapp->palette().active().text() );
- QColor col1 = config->readColorEntry( "ForegroundColor", &defaultForeground );
- QColor col2 = config->readColorEntry( "quote3Color", &defaultColor3 );
- QColor col3 = config->readColorEntry( "quote2Color", &defaultColor2 );
- QColor col4 = config->readColorEntry( "quote1Color", &defaultColor1 );
- QColor c = QColor("red");
+ TQColor defaultColor1( kapp->palette().active().text()); // defaults from kmreaderwin.cpp
+ TQColor defaultColor2( kapp->palette().active().text() );
+ TQColor defaultColor3( kapp->palette().active().text() );
+ TQColor defaultForeground( kapp->palette().active().text() );
+ TQColor col1 = config->readColorEntry( "ForegroundColor", &defaultForeground );
+ TQColor col2 = config->readColorEntry( "quote3Color", &defaultColor3 );
+ TQColor col3 = config->readColorEntry( "quote2Color", &defaultColor2 );
+ TQColor col4 = config->readColorEntry( "quote1Color", &defaultColor1 );
+ TQColor c = TQColor("red");
mSpellChecker = new KDictSpellingHighlighter(e_dit, /*active*/ true, /*autoEnabled*/ true,
/*spellColor*/ config->readColorEntry("NewMessage", &c),
/*colorQuoting*/ true, col1, col2, col3, col4);
- connect( mSpellChecker, SIGNAL(newSuggestions(const QString&, const QStringList&, unsigned int)), e_dit,
- SLOT(slotAddSuggestion(const QString&, const QStringList&, unsigned int)) );
+ connect( mSpellChecker, TQT_SIGNAL(newSuggestions(const TQString&, const TQStringList&, unsigned int)), e_dit,
+ TQT_SLOT(slotAddSuggestion(const TQString&, const TQStringList&, unsigned int)) );
- QVBoxLayout *notL=new QVBoxLayout(e_dit);
+ TQVBoxLayout *notL=new TQVBoxLayout(e_dit);
notL->addStretch(1);
- n_otification=new QGroupBox(2, Qt::Horizontal, e_dit);
- l=new QLabel(i18n("You are currently editing the article body\nin an external editor. To continue, you have\nto close the external editor."), n_otification);
- c_ancelEditorBtn=new QPushButton(i18n("&Kill External Editor"), n_otification);
- n_otification->setFrameStyle(QFrame::Panel | QFrame::Raised);
+ n_otification=new TQGroupBox(2, Qt::Horizontal, e_dit);
+ l=new TQLabel(i18n("You are currently editing the article body\nin an external editor. To continue, you have\nto close the external editor."), n_otification);
+ c_ancelEditorBtn=new TQPushButton(i18n("&Kill External Editor"), n_otification);
+ n_otification->setFrameStyle(TQFrame::Panel | TQFrame::Raised);
n_otification->setLineWidth(2);
n_otification->hide();
notL->addWidget(n_otification, 0, Qt::AlignHCenter);
notL->addStretch(1);
//finish GUI
- QVBoxLayout *topL=new QVBoxLayout(main, 4,4);
+ TQVBoxLayout *topL=new TQVBoxLayout(main, 4,4);
topL->addWidget(hdrFrame);
topL->addWidget(e_dit, 1);
}
@@ -1822,8 +1822,8 @@ KNComposer::ComposerView::~ComposerView()
conf->writeEntry("Att_Splitter",sizes()); // save splitter pos
- QValueList<int> lst; // save header sizes
- QHeader *h=a_ttView->header();
+ TQValueList<int> lst; // save header sizes
+ TQHeader *h=a_ttView->header();
for (int i=0; i<5; i++)
lst << h->sectionSize(i);
conf->writeEntry("Att_Headers",lst);
@@ -1832,14 +1832,14 @@ KNComposer::ComposerView::~ComposerView()
}
-void KNComposer::ComposerView::focusNextPrevEdit(const QWidget* aCur, bool aNext)
+void KNComposer::ComposerView::focusNextPrevEdit(const TQWidget* aCur, bool aNext)
{
- QValueList<QWidget*>::Iterator it;
+ TQValueList<TQWidget*>::Iterator it;
if ( !aCur ) {
it = --( mEdtList.end() );
} else {
- for ( QValueList<QWidget*>::Iterator it2 = mEdtList.begin(); it2 != mEdtList.end(); ++it2 ) {
+ for ( TQValueList<TQWidget*>::Iterator it2 = mEdtList.begin(); it2 != mEdtList.end(); ++it2 ) {
if ( (*it2) == aCur ) {
it = it2;
break;
@@ -1899,40 +1899,40 @@ void KNComposer::ComposerView::restartBackgroundSpellCheck()
void KNComposer::ComposerView::showAttachmentView()
{
if(!a_ttWidget) {
- a_ttWidget=new QWidget(this);
- QGridLayout *topL=new QGridLayout(a_ttWidget, 3, 2, 4, 4);
+ a_ttWidget=new TQWidget(this);
+ TQGridLayout *topL=new TQGridLayout(a_ttWidget, 3, 2, 4, 4);
a_ttView=new AttachmentView(a_ttWidget);
topL->addMultiCellWidget(a_ttView, 0,2, 0,0);
//connections
- connect(a_ttView, SIGNAL(currentChanged(QListViewItem*)),
- parent(), SLOT(slotAttachmentSelected(QListViewItem*)));
- connect(a_ttView, SIGNAL(clicked ( QListViewItem * )),
- parent(), SLOT(slotAttachmentSelected(QListViewItem*)));
-
- connect(a_ttView, SIGNAL(contextMenu(KListView*, QListViewItem*, const QPoint&)),
- parent(), SLOT(slotAttachmentPopup(KListView*, QListViewItem*, const QPoint&)));
- connect(a_ttView, SIGNAL(delPressed(QListViewItem*)),
- parent(), SLOT(slotAttachmentRemove(QListViewItem*)));
- connect(a_ttView, SIGNAL(doubleClicked(QListViewItem*)),
- parent(), SLOT(slotAttachmentEdit(QListViewItem*)));
- connect(a_ttView, SIGNAL(returnPressed(QListViewItem*)),
- parent(), SLOT(slotAttachmentEdit(QListViewItem*)));
+ connect(a_ttView, TQT_SIGNAL(currentChanged(TQListViewItem*)),
+ parent(), TQT_SLOT(slotAttachmentSelected(TQListViewItem*)));
+ connect(a_ttView, TQT_SIGNAL(clicked ( TQListViewItem * )),
+ parent(), TQT_SLOT(slotAttachmentSelected(TQListViewItem*)));
+
+ connect(a_ttView, TQT_SIGNAL(contextMenu(KListView*, TQListViewItem*, const TQPoint&)),
+ parent(), TQT_SLOT(slotAttachmentPopup(KListView*, TQListViewItem*, const TQPoint&)));
+ connect(a_ttView, TQT_SIGNAL(delPressed(TQListViewItem*)),
+ parent(), TQT_SLOT(slotAttachmentRemove(TQListViewItem*)));
+ connect(a_ttView, TQT_SIGNAL(doubleClicked(TQListViewItem*)),
+ parent(), TQT_SLOT(slotAttachmentEdit(TQListViewItem*)));
+ connect(a_ttView, TQT_SIGNAL(returnPressed(TQListViewItem*)),
+ parent(), TQT_SLOT(slotAttachmentEdit(TQListViewItem*)));
//buttons
- a_ttAddBtn=new QPushButton(i18n("A&dd..."),a_ttWidget);
- connect(a_ttAddBtn, SIGNAL(clicked()), parent(), SLOT(slotAttachFile()));
+ a_ttAddBtn=new TQPushButton(i18n("A&dd..."),a_ttWidget);
+ connect(a_ttAddBtn, TQT_SIGNAL(clicked()), parent(), TQT_SLOT(slotAttachFile()));
topL->addWidget(a_ttAddBtn, 0,1);
- a_ttRemoveBtn=new QPushButton(i18n("&Remove"), a_ttWidget);
+ a_ttRemoveBtn=new TQPushButton(i18n("&Remove"), a_ttWidget);
a_ttRemoveBtn->setEnabled(false);
- connect(a_ttRemoveBtn, SIGNAL(clicked()), parent(), SLOT(slotRemoveAttachment()));
+ connect(a_ttRemoveBtn, TQT_SIGNAL(clicked()), parent(), TQT_SLOT(slotRemoveAttachment()));
topL->addWidget(a_ttRemoveBtn, 1,1);
- a_ttEditBtn=new QPushButton(i18n("&Properties"), a_ttWidget);
+ a_ttEditBtn=new TQPushButton(i18n("&Properties"), a_ttWidget);
a_ttEditBtn->setEnabled(false);
- connect(a_ttEditBtn, SIGNAL(clicked()), parent(), SLOT(slotAttachmentProperties()));
+ connect(a_ttEditBtn, TQT_SIGNAL(clicked()), parent(), TQT_SLOT(slotAttachmentProperties()));
topL->addWidget(a_ttEditBtn, 2,1, Qt::AlignTop);
topL->setRowStretch(2,1);
@@ -1946,16 +1946,16 @@ void KNComposer::ComposerView::showAttachmentView()
KConfig *conf=knGlobals.config();
conf->setGroup("POSTNEWS");
- QValueList<int> lst=conf->readIntListEntry("Att_Splitter");
+ TQValueList<int> lst=conf->readIntListEntry("Att_Splitter");
if(lst.count()!=2)
lst << 267 << 112;
setSizes(lst);
lst=conf->readIntListEntry("Att_Headers");
if(lst.count()==5) {
- QValueList<int>::Iterator it=lst.begin();
+ TQValueList<int>::Iterator it=lst.begin();
- QHeader *h=a_ttView->header();
+ TQHeader *h=a_ttView->header();
for(int i=0; i<5; i++) {
h->resizeSection(i,(*it));
++it;
@@ -1991,14 +1991,14 @@ void KNComposer::ComposerView::hideExternalNotification()
//=====================================================================================
#include <kcursor.h>
-KNComposer::Editor::Editor(KNComposer::ComposerView *_composerView, KNComposer *_composer, QWidget *parent, char *name)
+KNComposer::Editor::Editor(KNComposer::ComposerView *_composerView, KNComposer *_composer, TQWidget *parent, char *name)
: KEdit(parent, name), m_composer( _composer ), m_composerView(_composerView)
{
setOverwriteEnabled(true);
spell = 0L;
installEventFilter(this);
KCursor::setAutoHideCursor( this, true, true );
- m_bound = QRegExp( QString::fromLatin1("[\\s\\W]") );
+ m_bound = TQRegExp( TQString::fromLatin1("[\\s\\W]") );
}
@@ -2009,14 +2009,14 @@ KNComposer::Editor::~Editor()
}
//-----------------------------------------------------------------------------
-bool KNComposer::Editor::eventFilter(QObject*o, QEvent* e)
+bool KNComposer::Editor::eventFilter(TQObject*o, TQEvent* e)
{
if (o == this)
KCursor::autoHideEventFilter(o, e);
- if (e->type() == QEvent::KeyPress)
+ if (e->type() == TQEvent::KeyPress)
{
- QKeyEvent *k = (QKeyEvent*)e;
+ TQKeyEvent *k = (TQKeyEvent*)e;
// ---sven's Arrow key navigation start ---
// Key Up in first line takes you to Subject line.
if (k->key() == Key_Up && k->state() != ShiftButton && currentLine() == 0
@@ -2034,14 +2034,14 @@ bool KNComposer::Editor::eventFilter(QObject*o, QEvent* e)
m_composerView->focusNextPrevEdit(0, false);
return true;
}
- } else if ( e->type() == QEvent::ContextMenu ) {
- QContextMenuEvent *event = (QContextMenuEvent*) e;
+ } else if ( e->type() == TQEvent::ContextMenu ) {
+ TQContextMenuEvent *event = (TQContextMenuEvent*) e;
int para = 1, charPos, firstSpace, lastSpace;
//Get the character at the position of the click
charPos = charAt( viewportToContents(event->pos() ), &para );
- QString paraText = text( para );
+ TQString paraText = text( para );
if( !paraText.at(charPos).isSpace() )
{
@@ -2050,7 +2050,7 @@ bool KNComposer::Editor::eventFilter(QObject*o, QEvent* e)
lastSpace = paraText.find( m_bound, charPos );
if( lastSpace == -1 )
lastSpace = paraText.length();
- QString word = paraText.mid( firstSpace, lastSpace - firstSpace );
+ TQString word = paraText.mid( firstSpace, lastSpace - firstSpace );
//Continue if this word was misspelled
if( !word.isEmpty() && m_replacements.contains( word ) )
{
@@ -2058,18 +2058,18 @@ bool KNComposer::Editor::eventFilter(QObject*o, QEvent* e)
p.insertTitle( i18n("Suggestions") );
//Add the suggestions to the popup menu
- QStringList reps = m_replacements[word];
+ TQStringList reps = m_replacements[word];
if( reps.count() > 0 )
{
int listPos = 0;
- for ( QStringList::Iterator it = reps.begin(); it != reps.end(); ++it ) {
+ for ( TQStringList::Iterator it = reps.begin(); it != reps.end(); ++it ) {
p.insertItem( *it, listPos );
listPos++;
}
}
else
{
- p.insertItem( QString::fromLatin1("No Suggestions"), -2 );
+ p.insertItem( TQString::fromLatin1("No Suggestions"), -2 );
}
//Execute the popup inline
@@ -2097,16 +2097,16 @@ bool KNComposer::Editor::eventFilter(QObject*o, QEvent* e)
return KEdit::eventFilter(o, e);
}
-void KNComposer::Editor::slotAddSuggestion( const QString &text, const QStringList &lst, unsigned int )
+void KNComposer::Editor::slotAddSuggestion( const TQString &text, const TQStringList &lst, unsigned int )
{
m_replacements[text] = lst;
}
// expand tabs to avoid the "tab-damage",
// auto-wraped paragraphs have to split (code taken from KEdit::saveText)
-QStringList KNComposer::Editor::processedText()
+TQStringList KNComposer::Editor::processedText()
{
- QStringList ret;
+ TQStringList ret;
int lines = numLines()-1;
if (lines < 0)
return ret;
@@ -2121,7 +2121,7 @@ QStringList KNComposer::Editor::processedText()
if (lines_in_parag == 1) {
ret.append(textLine(i));
} else {
- QString parag_text = textLine(i);
+ TQString parag_text = textLine(i);
int pos = 0;
int last_pos = 0;
int current_line = 0;
@@ -2137,11 +2137,11 @@ QStringList KNComposer::Editor::processedText()
}
}
- QString replacement;
+ TQString replacement;
int tabPos;
- for (QStringList::Iterator it = ret.begin(); it != ret.end(); ++it ) {
+ for (TQStringList::Iterator it = ret.begin(); it != ret.end(); ++it ) {
while ((tabPos=(*it).find('\t'))!=-1) {
- replacement.fill(QChar(' '), 8-(tabPos%8));
+ replacement.fill(TQChar(' '), 8-(tabPos%8));
(*it).replace(tabPos, 1, replacement);
}
}
@@ -2152,14 +2152,14 @@ QStringList KNComposer::Editor::processedText()
void KNComposer::Editor::slotPasteAsQuotation()
{
- QString s = QApplication::clipboard()->text();
+ TQString s = TQApplication::clipboard()->text();
if (!s.isEmpty()) {
for (int i=0; (uint)i<s.length(); i++) {
if ( s[i] < ' ' && s[i] != '\n' && s[i] != '\t' )
s[i] = ' ';
}
s.prepend("> ");
- s.replace(QRegExp("\n"),"\n> ");
+ s.replace(TQRegExp("\n"),"\n> ");
insert(s);
}
}
@@ -2184,14 +2184,14 @@ void KNComposer::Editor::slotReplace()
void KNComposer::Editor::slotAddQuotes()
{
if (hasMarkedText()) {
- QString s = markedText();
+ TQString s = markedText();
s.prepend("> ");
- s.replace(QRegExp("\n"),"\n> ");
+ s.replace(TQRegExp("\n"),"\n> ");
insert(s);
} else {
int l = currentLine();
int c = currentColumn();
- QString s = textLine(l);
+ TQString s = textLine(l);
s.prepend("> ");
insertLine(s,l);
removeLine(l+1);
@@ -2203,15 +2203,15 @@ void KNComposer::Editor::slotAddQuotes()
void KNComposer::Editor::slotRemoveQuotes()
{
if (hasMarkedText()) {
- QString s = markedText();
+ TQString s = markedText();
if (s.left(2) == "> ")
s.remove(0,2);
- s.replace(QRegExp("\n> "),"\n");
+ s.replace(TQRegExp("\n> "),"\n");
insert(s);
} else {
int l = currentLine();
int c = currentColumn();
- QString s = textLine(l);
+ TQString s = textLine(l);
if (s.left(2) == "> ") {
s.remove(0,2);
insertLine(s,l);
@@ -2225,15 +2225,15 @@ void KNComposer::Editor::slotRemoveQuotes()
void KNComposer::Editor::slotAddBox()
{
if (hasMarkedText()) {
- QString s = markedText();
+ TQString s = markedText();
s.prepend(",----[ ]\n");
- s.replace(QRegExp("\n"),"\n| ");
+ s.replace(TQRegExp("\n"),"\n| ");
s.append("\n`----");
insert(s);
} else {
int l = currentLine();
int c = currentColumn();
- QString s = QString::fromLatin1(",----[ ]\n| %1\n`----").arg(textLine(l));
+ TQString s = TQString::fromLatin1(",----[ ]\n| %1\n`----").arg(textLine(l));
insertLine(s,l);
removeLine(l+3);
setCursorPosition(l+1,c+2);
@@ -2244,10 +2244,10 @@ void KNComposer::Editor::slotAddBox()
void KNComposer::Editor::slotRemoveBox()
{
if (hasMarkedText()) {
- QString s = QString::fromLatin1("\n") + markedText() + QString::fromLatin1("\n");
- s.replace(QRegExp("\n,----[^\n]*\n"),"\n");
- s.replace(QRegExp("\n| "),"\n");
- s.replace(QRegExp("\n`----[^\n]*\n"),"\n");
+ TQString s = TQString::fromLatin1("\n") + markedText() + TQString::fromLatin1("\n");
+ s.replace(TQRegExp("\n,----[^\n]*\n"),"\n");
+ s.replace(TQRegExp("\n| "),"\n");
+ s.replace(TQRegExp("\n`----[^\n]*\n"),"\n");
s.remove(0,1);
s.truncate(s.length()-1);
insert(s);
@@ -2255,7 +2255,7 @@ void KNComposer::Editor::slotRemoveBox()
int l = currentLine();
int c = currentColumn();
- QString s = textLine(l); // test if we are in a box
+ TQString s = textLine(l); // test if we are in a box
if (!((s.left(2) == "| ")||(s.left(5)==",----")||(s.left(5)=="`----")))
return;
@@ -2309,7 +2309,7 @@ void KNComposer::Editor::slotRot13()
}
-void KNComposer::Editor::contentsDragEnterEvent(QDragEnterEvent *ev)
+void KNComposer::Editor::contentsDragEnterEvent(TQDragEnterEvent *ev)
{
if (KURLDrag::canDecode(ev))
emit(sigDragEnterEvent(ev));
@@ -2318,7 +2318,7 @@ void KNComposer::Editor::contentsDragEnterEvent(QDragEnterEvent *ev)
}
-void KNComposer::Editor::contentsDropEvent(QDropEvent *ev)
+void KNComposer::Editor::contentsDropEvent(TQDropEvent *ev)
{
if (KURLDrag::canDecode(ev))
emit(sigDropEvent(ev));
@@ -2326,12 +2326,12 @@ void KNComposer::Editor::contentsDropEvent(QDropEvent *ev)
KEdit::dropEvent(ev);
}
-void KNComposer::Editor::keyPressEvent ( QKeyEvent *e)
+void KNComposer::Editor::keyPressEvent ( TQKeyEvent *e)
{
if( e->key() == Key_Return ) {
int line, col;
getCursorPosition( &line, &col );
- QString lineText = text( line );
+ TQString lineText = text( line );
// returns line with additional trailing space (bug in Qt?), cut it off
lineText.truncate( lineText.length() - 1 );
// special treatment of quoted lines only if the cursor is neither at
@@ -2360,7 +2360,7 @@ void KNComposer::Editor::keyPressEvent ( QKeyEvent *e)
if( isQuotedLine
&& ( bot != lineText.length() )
&& ( col >= int( bot ) ) ) {
- QString newLine = text( line + 1 );
+ TQString newLine = text( line + 1 );
// remove leading white space from the new line and instead
// add the quote indicators of the previous line
unsigned int leadingWhiteSpaceCount = 0;
@@ -2386,27 +2386,27 @@ void KNComposer::Editor::keyPressEvent ( QKeyEvent *e)
}
-void KNComposer::Editor::contentsContextMenuEvent( QContextMenuEvent */*e*/ )
+void KNComposer::Editor::contentsContextMenuEvent( TQContextMenuEvent */*e*/ )
{
- QString selectWord = selectWordUnderCursor();
- QPopupMenu* popup = 0L;
+ TQString selectWord = selectWordUnderCursor();
+ TQPopupMenu* popup = 0L;
if ( selectWord.isEmpty())
{
popup = m_composer ? m_composer->popupMenu( "edit" ): 0;
if ( popup )
- popup->popup(QCursor::pos());
+ popup->popup(TQCursor::pos());
}
else
{
- spell = new KSpell(this, i18n("Spellcheck"), this, SLOT(slotSpellStarted(KSpell *)));
- QStringList l = KSpellingHighlighter::personalWords();
- for ( QStringList::Iterator it = l.begin(); it != l.end(); ++it ) {
+ spell = new KSpell(this, i18n("Spellcheck"), this, TQT_SLOT(slotSpellStarted(KSpell *)));
+ TQStringList l = KSpellingHighlighter::personalWords();
+ for ( TQStringList::Iterator it = l.begin(); it != l.end(); ++it ) {
spell->addPersonal( *it );
}
- connect(spell, SIGNAL(death()), this, SLOT(slotSpellFinished()));
- connect(spell, SIGNAL(done(const QString&)), this, SLOT(slotSpellDone(const QString&)));
- connect(spell, SIGNAL(misspelling (const QString &, const QStringList &, unsigned int)),
- this, SLOT(slotMisspelling (const QString &, const QStringList &, unsigned int)));
+ connect(spell, TQT_SIGNAL(death()), this, TQT_SLOT(slotSpellFinished()));
+ connect(spell, TQT_SIGNAL(done(const TQString&)), this, TQT_SLOT(slotSpellDone(const TQString&)));
+ connect(spell, TQT_SIGNAL(misspelling (const TQString &, const TQStringList &, unsigned int)),
+ this, TQT_SLOT(slotMisspelling (const TQString &, const TQStringList &, unsigned int)));
}
}
@@ -2416,7 +2416,7 @@ void KNComposer::Editor::slotSpellStarted( KSpell *)
}
-void KNComposer::Editor::slotSpellDone(const QString &/*newtext*/)
+void KNComposer::Editor::slotSpellDone(const TQString &/*newtext*/)
{
spell->cleanUp();
}
@@ -2456,20 +2456,20 @@ void KNComposer::Editor::del()
}
-void KNComposer::Editor::slotMisspelling (const QString &, const QStringList &lst, unsigned int)
+void KNComposer::Editor::slotMisspelling (const TQString &, const TQStringList &lst, unsigned int)
{
int countAction = m_composer->listOfResultOfCheckWord( lst , selectWordUnderCursor());
if ( countAction>0 )
{
- QPopupMenu* popup = m_composer ? m_composer->popupMenu( "edit_with_spell" ): 0;
+ TQPopupMenu* popup = m_composer ? m_composer->popupMenu( "edit_with_spell" ): 0;
if ( popup )
- popup->popup(QCursor::pos());
+ popup->popup(TQCursor::pos());
}
else
{
- QPopupMenu* popup = m_composer ? m_composer->popupMenu( "edit" ): 0;
+ TQPopupMenu* popup = m_composer ? m_composer->popupMenu( "edit" ): 0;
if ( popup )
- popup->popup(QCursor::pos());
+ popup->popup(TQCursor::pos());
}
}
@@ -2490,10 +2490,10 @@ void KNComposer::Editor::slotCorrectWord()
//=====================================================================================
-KNComposer::AttachmentView::AttachmentView(QWidget *parent, char *name)
+KNComposer::AttachmentView::AttachmentView(TQWidget *parent, char *name)
: KListView(parent, name)
{
- setFrameStyle(QFrame::WinPanel | QFrame::Sunken); // match the QMultiLineEdit style
+ setFrameStyle(TQFrame::WinPanel | TQFrame::Sunken); // match the TQMultiLineEdit style
addColumn(i18n("File"), 115);
addColumn(i18n("Type"), 91);
addColumn(i18n("Size"), 55);
@@ -2509,7 +2509,7 @@ KNComposer::AttachmentView::~AttachmentView()
}
-void KNComposer::AttachmentView::keyPressEvent(QKeyEvent *e)
+void KNComposer::AttachmentView::keyPressEvent(TQKeyEvent *e)
{
if(!e)
return; // subclass bug
@@ -2545,44 +2545,44 @@ KNComposer::AttachmentViewItem::~AttachmentViewItem()
//=====================================================================================
-KNComposer::AttachmentPropertiesDlg::AttachmentPropertiesDlg(KNAttachment *a, QWidget *p, const char *n) :
+KNComposer::AttachmentPropertiesDlg::AttachmentPropertiesDlg(KNAttachment *a, TQWidget *p, const char *n) :
KDialogBase(p, n, true, i18n("Attachment Properties"), Help|Ok|Cancel, Ok), a_ttachment(a),
n_onTextAsText(false)
{
//init GUI
- QWidget *page=new QWidget(this);
+ TQWidget *page=new TQWidget(this);
setMainWidget(page);
- QVBoxLayout *topL=new QVBoxLayout(page);
+ TQVBoxLayout *topL=new TQVBoxLayout(page);
//file info
- QGroupBox *fileGB=new QGroupBox(i18n("File"), page);
- QGridLayout *fileL=new QGridLayout(fileGB, 3,2, 15,5);
+ TQGroupBox *fileGB=new TQGroupBox(i18n("File"), page);
+ TQGridLayout *fileL=new TQGridLayout(fileGB, 3,2, 15,5);
fileL->addRowSpacing(0, fontMetrics().lineSpacing()-9);
- fileL->addWidget(new QLabel(i18n("Name:"), fileGB) ,1,0);
- fileL->addWidget(new QLabel(QString("<b>%1</b>").arg(a->name()), fileGB), 1,1, Qt::AlignLeft);
- fileL->addWidget(new QLabel(i18n("Size:"), fileGB), 2,0);
- fileL->addWidget(new QLabel(a->contentSize(), fileGB), 2,1, Qt::AlignLeft);
+ fileL->addWidget(new TQLabel(i18n("Name:"), fileGB) ,1,0);
+ fileL->addWidget(new TQLabel(TQString("<b>%1</b>").arg(a->name()), fileGB), 1,1, Qt::AlignLeft);
+ fileL->addWidget(new TQLabel(i18n("Size:"), fileGB), 2,0);
+ fileL->addWidget(new TQLabel(a->contentSize(), fileGB), 2,1, Qt::AlignLeft);
fileL->setColStretch(1,1);
topL->addWidget(fileGB);
//mime info
- QGroupBox *mimeGB=new QGroupBox(i18n("Mime"), page);
- QGridLayout *mimeL=new QGridLayout(mimeGB, 4,2, 15,5);
+ TQGroupBox *mimeGB=new TQGroupBox(i18n("Mime"), page);
+ TQGridLayout *mimeL=new TQGridLayout(mimeGB, 4,2, 15,5);
mimeL->addRowSpacing(0, fontMetrics().lineSpacing()-9);
m_imeType=new KLineEdit(mimeGB);
m_imeType->setText(a->mimeType());
mimeL->addWidget(m_imeType, 1,1);
- mimeL->addWidget(new QLabel(m_imeType, i18n("&Mime-Type:"), mimeGB), 1,0);
+ mimeL->addWidget(new TQLabel(m_imeType, i18n("&Mime-Type:"), mimeGB), 1,0);
d_escription=new KLineEdit(mimeGB);
d_escription->setText(a->description());
mimeL->addWidget(d_escription, 2,1);
- mimeL->addWidget(new QLabel(d_escription, i18n("&Description:"), mimeGB), 2,0);
+ mimeL->addWidget(new TQLabel(d_escription, i18n("&Description:"), mimeGB), 2,0);
- e_ncoding=new QComboBox(false, mimeGB);
+ e_ncoding=new TQComboBox(false, mimeGB);
e_ncoding->insertItem("7Bit");
e_ncoding->insertItem("8Bit");
e_ncoding->insertItem("quoted-printable");
@@ -2594,18 +2594,18 @@ KNComposer::AttachmentPropertiesDlg::AttachmentPropertiesDlg(KNAttachment *a, QW
else
e_ncoding->setCurrentItem(a->cte());
mimeL->addWidget(e_ncoding, 3,1);
- mimeL->addWidget(new QLabel(e_ncoding, i18n("&Encoding:"), mimeGB), 3,0);
+ mimeL->addWidget(new TQLabel(e_ncoding, i18n("&Encoding:"), mimeGB), 3,0);
mimeL->setColStretch(1,1);
topL->addWidget(mimeGB);
//connections
- connect(m_imeType, SIGNAL(textChanged(const QString&)),
- this, SLOT(slotMimeTypeTextChanged(const QString&)));
+ connect(m_imeType, TQT_SIGNAL(textChanged(const TQString&)),
+ this, TQT_SLOT(slotMimeTypeTextChanged(const TQString&)));
//finish GUI
setFixedHeight(sizeHint().height());
- KNHelper::restoreWindowSize("attProperties", this, QSize(300,250));
+ KNHelper::restoreWindowSize("attProperties", this, TQSize(300,250));
setHelp("anc-knode-editor-advanced");
}
@@ -2639,7 +2639,7 @@ void KNComposer::AttachmentPropertiesDlg::accept()
}
-void KNComposer::AttachmentPropertiesDlg::slotMimeTypeTextChanged(const QString &text)
+void KNComposer::AttachmentPropertiesDlg::slotMimeTypeTextChanged(const TQString &text)
{
enableButtonOK( !text.isEmpty() );
if(text.left(5)!="text/") {
diff --git a/knode/kncomposer.h b/knode/kncomposer.h
index 12c2150f8..a44397b81 100644
--- a/knode/kncomposer.h
+++ b/knode/kncomposer.h
@@ -20,8 +20,8 @@
#include <kmainwindow.h>
#include <kdialogbase.h>
#include <keditcl.h>
-#include <qlineedit.h>
-#include <qregexp.h>
+#include <tqlineedit.h>
+#include <tqregexp.h>
#include <kdeversion.h>
#include <keditcl.h>
@@ -52,7 +52,7 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
// unwraped == original, not rewraped text
// firstEdit==true: place the cursor at the end of the article
- KNComposer(KNLocalArticle *a, const QString &text=QString::null, const QString &sig=QString::null, const QString &unwraped=QString::null, bool firstEdit=false, bool dislikesCopies=false, bool createCopy=false);
+ KNComposer(KNLocalArticle *a, const TQString &text=TQString::null, const TQString &sig=TQString::null, const TQString &unwraped=TQString::null, bool firstEdit=false, bool dislikesCopies=false, bool createCopy=false);
~KNComposer();
void setConfig(bool onlyFonts);
void setMessageMode(MessageMode mode);
@@ -63,21 +63,21 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
KNLocalArticle* article()const { return a_rticle; }
bool applyChanges();
- void closeEvent(QCloseEvent *e);
+ void closeEvent(TQCloseEvent *e);
//set data from the given article
- void initData(const QString &text);
+ void initData(const TQString &text);
// inserts at cursor position if clear is false, replaces content otherwise
// puts the file content into a box if box==true
// "file" is already open for reading
- void insertFile(QFile *file, bool clear=false, bool box=false, QString boxTitle=QString::null);
+ void insertFile(TQFile *file, bool clear=false, bool box=false, TQString boxTitle=TQString::null);
// ask for a filename, handle network urls
void insertFile(bool clear=false, bool box=false);
- QPopupMenu * popupMenu( const QString& name );
- int listOfResultOfCheckWord( const QStringList & lst , const QString & selectWord);
+ TQPopupMenu * popupMenu( const TQString& name );
+ int listOfResultOfCheckWord( const TQStringList & lst , const TQString & selectWord);
//internal classes
class ComposerView;
@@ -88,13 +88,13 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
//GUI
ComposerView *v_iew;
- QPopupMenu *a_ttPopup;
+ TQPopupMenu *a_ttPopup;
//Data
composerResult r_esult;
KNLocalArticle *a_rticle;
- QString s_ignature, u_nwraped;
- QCString c_harset;
+ TQString s_ignature, u_nwraped;
+ TQCString c_harset;
MessageMode m_ode;
bool n_eeds8Bit, // false: fall back to us-ascii
v_alidated, // hasValidData was run and found no problems, n_eeds8Bit is valid
@@ -108,8 +108,8 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
SpellingFilter* mSpellingFilter;
//Attachments
- QValueList<KNAttachment*> mDeletedAttachments;
- QPtrList<KAction> m_listAction;
+ TQValueList<KNAttachment*> mDeletedAttachments;
+ TQPtrList<KAction> m_listAction;
bool a_ttChanged;
//------------------------------ <Actions> -----------------------------
@@ -137,7 +137,7 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
void slotAttachmentProperties();
void slotToggleDoPost();
void slotToggleDoMail();
- void slotSetCharset(const QString &s);
+ void slotSetCharset(const TQString &s);
void slotSetCharsetKeyboard();
void slotToggleWordWrap();
void slotUndoRewrap();
@@ -153,8 +153,8 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
//------------------------------ </Actions> ----------------------------
// GUI
- void slotSubjectChanged(const QString &t);
- void slotGroupsChanged(const QString &t);
+ void slotSubjectChanged(const TQString &t);
+ void slotGroupsChanged(const TQString &t);
void slotToBtnClicked();
void slotGroupsBtnClicked();
@@ -163,19 +163,19 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
void slotCancelEditor();
// attachment list
- void slotAttachmentPopup(KListView*, QListViewItem *it, const QPoint &p);
- void slotAttachmentSelected(QListViewItem *it);
- void slotAttachmentEdit(QListViewItem *it);
- void slotAttachmentRemove(QListViewItem *it);
+ void slotAttachmentPopup(KListView*, TQListViewItem *it, const TQPoint &p);
+ void slotAttachmentSelected(TQListViewItem *it);
+ void slotAttachmentEdit(TQListViewItem *it);
+ void slotAttachmentRemove(TQListViewItem *it);
// spellcheck operation
void slotSpellStarted(KSpell *);
- void slotSpellDone(const QString&);
+ void slotSpellDone(const TQString&);
void slotSpellFinished();
// DND handling
- virtual void slotDragEnterEvent(QDragEnterEvent *);
- virtual void slotDropEvent(QDropEvent *);
+ virtual void slotDragEnterEvent(TQDragEnterEvent *);
+ virtual void slotDropEvent(TQDropEvent *);
void slotUndo();
void slotRedo();
@@ -183,15 +183,15 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
void slotCopy();
void slotPaste();
void slotSelectAll();
- void slotMisspelling(const QString &text, const QStringList &lst, unsigned int pos);
- void slotCorrected (const QString &oldWord, const QString &newWord, unsigned int pos);
+ void slotMisspelling(const TQString &text, const TQStringList &lst, unsigned int pos);
+ void slotCorrected (const TQString &oldWord, const TQString &newWord, unsigned int pos);
void addRecentAddress();
protected:
// DND handling
- virtual void dragEnterEvent(QDragEnterEvent *);
- virtual void dropEvent(QDropEvent *);
+ virtual void dragEnterEvent(TQDragEnterEvent *);
+ virtual void dropEvent(TQDropEvent *);
signals:
void composerDone(KNComposer*);
@@ -206,21 +206,21 @@ class KNComposer : public KMainWindow , virtual public KNodeComposerIface {
class KNLineEditSpell;
class KNLineEdit;
-class KNComposer::ComposerView : public QSplitter {
+class KNComposer::ComposerView : public TQSplitter {
public:
ComposerView(KNComposer *_composer, const char *n=0);
~ComposerView();
- void focusNextPrevEdit(const QWidget* aCur, bool aNext);
+ void focusNextPrevEdit(const TQWidget* aCur, bool aNext);
void setMessageMode(KNComposer::MessageMode mode);
void showAttachmentView();
void hideAttachmentView();
void showExternalNotification();
void hideExternalNotification();
void restartBackgroundSpellCheck();
- QValueList<QWidget*> mEdtList;
+ TQValueList<TQWidget*> mEdtList;
- QLabel *l_to,
+ TQLabel *l_to,
*l_groups,
*l_fup2;
KNLineEditSpell *s_ubject;
@@ -229,16 +229,16 @@ class KNComposer::ComposerView : public QSplitter {
KNLineEdit *t_o;
KComboBox *f_up2;
- QPushButton *g_roupsBtn,
+ TQPushButton *g_roupsBtn,
*t_oBtn;
Editor *e_dit;
- QGroupBox *n_otification;
- QPushButton *c_ancelEditorBtn;
+ TQGroupBox *n_otification;
+ TQPushButton *c_ancelEditorBtn;
- QWidget *a_ttWidget;
+ TQWidget *a_ttWidget;
AttachmentView *a_ttView;
- QPushButton *a_ttAddBtn,
+ TQPushButton *a_ttAddBtn,
*a_ttRemoveBtn,
*a_ttEditBtn;
KDictSpellingHighlighter *mSpellChecker;
@@ -253,9 +253,9 @@ class KNComposer::Editor : public KEdit {
Q_OBJECT
public:
- Editor(KNComposer::ComposerView *_composerView, KNComposer *_composer, QWidget *parent=0, char *name=0);
+ Editor(KNComposer::ComposerView *_composerView, KNComposer *_composer, TQWidget *parent=0, char *name=0);
~Editor();
- QStringList processedText();
+ TQStringList processedText();
public slots:
void slotPasteAsQuotation();
@@ -271,32 +271,32 @@ class KNComposer::Editor : public KEdit {
protected slots:
void slotSpellStarted( KSpell *);
- void slotSpellDone(const QString &);
+ void slotSpellDone(const TQString &);
void slotSpellFinished();
- void slotMisspelling (const QString &, const QStringList &lst, unsigned int);
+ void slotMisspelling (const TQString &, const TQStringList &lst, unsigned int);
virtual void cut();
virtual void clear();
virtual void del();
- void slotAddSuggestion( const QString &, const QStringList &lst, unsigned int );
+ void slotAddSuggestion( const TQString &, const TQStringList &lst, unsigned int );
signals:
- void sigDragEnterEvent(QDragEnterEvent *);
- void sigDropEvent(QDropEvent *);
+ void sigDragEnterEvent(TQDragEnterEvent *);
+ void sigDropEvent(TQDropEvent *);
protected:
// DND handling
- virtual void contentsDragEnterEvent(QDragEnterEvent *);
- virtual void contentsDropEvent(QDropEvent *);
- virtual void contentsContextMenuEvent( QContextMenuEvent *e );
- virtual void keyPressEvent ( QKeyEvent *e);
+ virtual void contentsDragEnterEvent(TQDragEnterEvent *);
+ virtual void contentsDropEvent(TQDropEvent *);
+ virtual void contentsContextMenuEvent( TQContextMenuEvent *e );
+ virtual void keyPressEvent ( TQKeyEvent *e);
- virtual bool eventFilter(QObject*, QEvent*);
+ virtual bool eventFilter(TQObject*, TQEvent*);
private:
KNComposer *m_composer;
KNComposer::ComposerView *m_composerView;
KSpell *spell;
- QMap<QString,QStringList> m_replacements;
- QRegExp m_bound;
+ TQMap<TQString,TQStringList> m_replacements;
+ TQRegExp m_bound;
};
@@ -305,14 +305,14 @@ class KNComposer::AttachmentView : public KListView {
Q_OBJECT
public:
- AttachmentView(QWidget *parent, char *name=0);
+ AttachmentView(TQWidget *parent, char *name=0);
~AttachmentView();
protected:
- void keyPressEvent( QKeyEvent *e );
+ void keyPressEvent( TQKeyEvent *e );
signals:
- void delPressed ( QListViewItem * ); // the user used Key_Delete on a list view item
+ void delPressed ( TQListViewItem * ); // the user used Key_Delete on a list view item
};
@@ -332,7 +332,7 @@ class KNComposer::AttachmentPropertiesDlg : public KDialogBase {
Q_OBJECT
public:
- AttachmentPropertiesDlg( KNAttachment *a, QWidget *p=0, const char *n=0);
+ AttachmentPropertiesDlg( KNAttachment *a, TQWidget *p=0, const char *n=0);
~AttachmentPropertiesDlg();
void apply();
@@ -340,14 +340,14 @@ class KNComposer::AttachmentPropertiesDlg : public KDialogBase {
protected:
KLineEdit *m_imeType,
*d_escription;
- QComboBox *e_ncoding;
+ TQComboBox *e_ncoding;
KNAttachment *a_ttachment;
bool n_onTextAsText;
protected slots:
void accept();
- void slotMimeTypeTextChanged(const QString &text);
+ void slotMimeTypeTextChanged(const TQString &text);
};
//-----------------------------------------------------------------------------
@@ -357,13 +357,13 @@ class KNLineEdit : public KABC::AddressLineEdit
typedef KABC::AddressLineEdit KNLineEditInherited;
public:
- KNLineEdit(KNComposer::ComposerView *_composerView, bool useCompletion, QWidget *parent = 0,
+ KNLineEdit(KNComposer::ComposerView *_composerView, bool useCompletion, TQWidget *parent = 0,
const char *name = 0);
protected:
// Inherited. Always called by the parent when this widget is created.
virtual void loadAddresses();
- void keyPressEvent(QKeyEvent *e);
- virtual QPopupMenu *createPopupMenu();
+ void keyPressEvent(TQKeyEvent *e);
+ virtual TQPopupMenu *createPopupMenu();
private slots:
void editRecentAddresses();
private:
@@ -374,11 +374,11 @@ class KNLineEditSpell : public KNLineEdit
{
Q_OBJECT
public:
- KNLineEditSpell(KNComposer::ComposerView *_composerView, bool useCompletion,QWidget * parent, const char * name = 0);
+ KNLineEditSpell(KNComposer::ComposerView *_composerView, bool useCompletion,TQWidget * parent, const char * name = 0);
void highLightWord( unsigned int length, unsigned int pos );
- void spellCheckDone( const QString &s );
- void spellCheckerMisspelling( const QString &text, const QStringList &, unsigned int pos);
- void spellCheckerCorrected( const QString &old, const QString &corr, unsigned int pos);
+ void spellCheckDone( const TQString &s );
+ void spellCheckerMisspelling( const TQString &text, const TQStringList &, unsigned int pos);
+ void spellCheckerCorrected( const TQString &old, const TQString &corr, unsigned int pos);
};
#endif
diff --git a/knode/knconfig.cpp b/knode/knconfig.cpp
index cadf402b8..85606d89d 100644
--- a/knode/knconfig.cpp
+++ b/knode/knconfig.cpp
@@ -16,7 +16,7 @@
#include <stdlib.h>
-#include <qtextcodec.h>
+#include <tqtextcodec.h>
#include <ksimpleconfig.h>
#include <kmessagebox.h>
@@ -75,7 +75,7 @@ void KNConfig::Identity::saveConfig(KConfigBase *c)
c->writeEntry("Reply-To", r_eplyTo);
c->writeEntry("Mail-Copies-To", m_ailCopiesTo);
c->writeEntry("Org", o_rga);
- c->writeEntry("SigningKey", QString(s_igningKey));
+ c->writeEntry("SigningKey", TQString(s_igningKey));
c->writeEntry("UseSigFile", u_seSigFile);
c->writeEntry("UseSigGenerator",u_seSigGenerator);
c->writePathEntry("sigFile", s_igPath);
@@ -110,17 +110,17 @@ bool KNConfig::Identity::emailIsValid()
}
-QString KNConfig::Identity::getSignature()
+TQString KNConfig::Identity::getSignature()
{
- s_igContents = QString::null; // don't cache file contents
- s_igStdErr = QString::null;
+ s_igContents = TQString::null; // don't cache file contents
+ s_igStdErr = TQString::null;
if (u_seSigFile) {
if(!s_igPath.isEmpty()) {
if (!u_seSigGenerator) {
- QFile f(s_igPath);
+ TQFile f(s_igPath);
if(f.open(IO_ReadOnly)) {
- QTextStream ts(&f);
+ TQTextStream ts(&f);
while(!ts.atEnd()) {
s_igContents += ts.readLine();
if (!ts.atEnd())
@@ -134,12 +134,12 @@ QString KNConfig::Identity::getSignature()
KProcess process;
// construct command line...
- QStringList command = QStringList::split(' ',s_igPath);
- for ( QStringList::Iterator it = command.begin(); it != command.end(); ++it )
+ TQStringList command = TQStringList::split(' ',s_igPath);
+ for ( TQStringList::Iterator it = command.begin(); it != command.end(); ++it )
process << (*it);
- connect(&process, SIGNAL(receivedStdout(KProcess *, char *, int)), SLOT(slotReceiveStdout(KProcess *, char *, int)));
- connect(&process, SIGNAL(receivedStderr(KProcess *, char *, int)), SLOT(slotReceiveStderr(KProcess *, char *, int)));
+ connect(&process, TQT_SIGNAL(receivedStdout(KProcess *, char *, int)), TQT_SLOT(slotReceiveStdout(KProcess *, char *, int)));
+ connect(&process, TQT_SIGNAL(receivedStderr(KProcess *, char *, int)), TQT_SLOT(slotReceiveStderr(KProcess *, char *, int)));
if (!process.start(KProcess::Block,KProcess::AllOutput))
KMessageBox::error(knGlobals.topWidget, i18n("Cannot run the signature generator."));
@@ -158,13 +158,13 @@ QString KNConfig::Identity::getSignature()
void KNConfig::Identity::slotReceiveStdout(KProcess *, char *buffer, int buflen)
{
- s_igContents.append(QString::fromLocal8Bit(buffer,buflen));
+ s_igContents.append(TQString::fromLocal8Bit(buffer,buflen));
}
void KNConfig::Identity::slotReceiveStderr(KProcess *, char *buffer, int buflen)
{
- s_igStdErr.append(QString::fromLocal8Bit(buffer,buflen));
+ s_igStdErr.append(TQString::fromLocal8Bit(buffer,buflen));
}
@@ -179,7 +179,7 @@ KNConfig::Appearance::Appearance()
//colors
u_seColors=c->readBoolEntry("customColors", false);
- QColor defCol = defaultColor( background );
+ TQColor defCol = defaultColor( background );
c_olors[background] = c->readColorEntry( "backgroundColor", &defCol );
c_olorNames[background] = i18n("Background");
@@ -242,7 +242,7 @@ KNConfig::Appearance::Appearance()
//fonts
u_seFonts = c->readBoolEntry("customFonts", false);
- QFont defFont=KGlobalSettings::generalFont();
+ TQFont defFont=KGlobalSettings::generalFont();
f_onts[article]=c->readFontEntry("articleFont",&defFont);
f_ontNames[article]=i18n("Article Body");
@@ -319,7 +319,7 @@ void KNConfig::Appearance::save()
}
-QColor KNConfig::Appearance::backgroundColor() const
+TQColor KNConfig::Appearance::backgroundColor() const
{
if(u_seColors)
return c_olors[background];
@@ -328,7 +328,7 @@ QColor KNConfig::Appearance::backgroundColor() const
}
-QColor KNConfig::Appearance::alternateBackgroundColor() const
+TQColor KNConfig::Appearance::alternateBackgroundColor() const
{
if(u_seColors)
return c_olors[alternateBackground];
@@ -337,7 +337,7 @@ QColor KNConfig::Appearance::alternateBackgroundColor() const
}
-QColor KNConfig::Appearance::textColor() const
+TQColor KNConfig::Appearance::textColor() const
{
if(u_seColors)
return c_olors[normalText];
@@ -346,7 +346,7 @@ QColor KNConfig::Appearance::textColor() const
}
-QColor KNConfig::Appearance::quoteColor( int depth ) const
+TQColor KNConfig::Appearance::quoteColor( int depth ) const
{
if ( u_seColors )
return c_olors[quoted1 + depth];
@@ -355,7 +355,7 @@ QColor KNConfig::Appearance::quoteColor( int depth ) const
}
-QColor KNConfig::Appearance::linkColor() const
+TQColor KNConfig::Appearance::linkColor() const
{
if(u_seColors)
return c_olors[url];
@@ -365,7 +365,7 @@ QColor KNConfig::Appearance::linkColor() const
}
-QColor KNConfig::Appearance::unreadThreadColor() const
+TQColor KNConfig::Appearance::unreadThreadColor() const
{
if(u_seColors)
return c_olors[unreadThread];
@@ -374,7 +374,7 @@ QColor KNConfig::Appearance::unreadThreadColor() const
}
-QColor KNConfig::Appearance::readThreadColor() const
+TQColor KNConfig::Appearance::readThreadColor() const
{
if(u_seColors)
return c_olors[readThread];
@@ -383,7 +383,7 @@ QColor KNConfig::Appearance::readThreadColor() const
}
-QColor KNConfig::Appearance::unreadArticleColor() const
+TQColor KNConfig::Appearance::unreadArticleColor() const
{
if(u_seColors)
return c_olors[unreadArticle];
@@ -392,7 +392,7 @@ QColor KNConfig::Appearance::unreadArticleColor() const
}
-QColor KNConfig::Appearance::readArticleColor() const
+TQColor KNConfig::Appearance::readArticleColor() const
{
if(u_seColors)
return c_olors[readArticle];
@@ -401,7 +401,7 @@ QColor KNConfig::Appearance::readArticleColor() const
}
-QFont KNConfig::Appearance::articleFont() const
+TQFont KNConfig::Appearance::articleFont() const
{
if(u_seFonts)
return f_onts[article];
@@ -410,7 +410,7 @@ QFont KNConfig::Appearance::articleFont() const
}
-QFont KNConfig::Appearance::articleFixedFont() const
+TQFont KNConfig::Appearance::articleFixedFont() const
{
if(u_seFonts)
return f_onts[articleFixed];
@@ -419,7 +419,7 @@ QFont KNConfig::Appearance::articleFixedFont() const
}
-QFont KNConfig::Appearance::composerFont() const
+TQFont KNConfig::Appearance::composerFont() const
{
if(u_seFonts)
return f_onts[composer];
@@ -428,7 +428,7 @@ QFont KNConfig::Appearance::composerFont() const
}
-QFont KNConfig::Appearance::groupListFont() const
+TQFont KNConfig::Appearance::groupListFont() const
{
if(u_seFonts)
return f_onts[groupList];
@@ -437,7 +437,7 @@ QFont KNConfig::Appearance::groupListFont() const
}
-QFont KNConfig::Appearance::articleListFont() const
+TQFont KNConfig::Appearance::articleListFont() const
{
if(u_seFonts)
return f_onts[articleList];
@@ -446,7 +446,7 @@ QFont KNConfig::Appearance::articleListFont() const
}
-QColor KNConfig::Appearance::defaultColor(int i) const
+TQColor KNConfig::Appearance::defaultColor(int i) const
{
// defaults should match libkdepim/csshelper.cpp
switch(i) {
@@ -458,11 +458,11 @@ QColor KNConfig::Appearance::defaultColor(int i) const
return KGlobalSettings::alternateBackgroundColor();
case quoted1:
- return QColor( 0x00, 0x80, 0x00 );
+ return TQColor( 0x00, 0x80, 0x00 );
case quoted2:
- return QColor( 0x00, 0x70, 0x00 );
+ return TQColor( 0x00, 0x70, 0x00 );
case quoted3:
- return QColor( 0x00, 0x60, 0x00 );
+ return TQColor( 0x00, 0x60, 0x00 );
case normalText:
case unreadThread:
@@ -475,28 +475,28 @@ QColor KNConfig::Appearance::defaultColor(int i) const
return kapp->palette().disabled().text();
case unreadArticle:
- return QColor( 183, 154, 11 );
+ return TQColor( 183, 154, 11 );
case readArticle:
- return QColor( 136, 136, 136 );
+ return TQColor( 136, 136, 136 );
case signOkKeyOk:
- return QColor( 0x40, 0xFF, 0x00 );
+ return TQColor( 0x40, 0xFF, 0x00 );
case signOkKeyBad:
case signWarn:
- return QColor( 0xFF, 0xFF, 0x40 );
+ return TQColor( 0xFF, 0xFF, 0x40 );
case signErr:
return Qt::red;
case htmlWarning:
- return QColor( 0xFF, 0x40, 0x40 );
+ return TQColor( 0xFF, 0x40, 0x40 );
}
return kapp->palette().disabled().text();
}
-QFont KNConfig::Appearance::defaultFont(int i) const
+TQFont KNConfig::Appearance::defaultFont(int i) const
{
if ( i == articleFixed || i == composer )
return KGlobalSettings::fixedFont();
@@ -507,9 +507,9 @@ QFont KNConfig::Appearance::defaultFont(int i) const
void KNConfig::Appearance::recreateLVIcons()
{
- QPixmap tempPix = UserIcon("greyball");
+ TQPixmap tempPix = UserIcon("greyball");
- QImage tempImg=tempPix.convertToImage();
+ TQImage tempImg=tempPix.convertToImage();
KIconEffect::colorize(tempImg, readArticleColor(), 1.0);
i_cons[greyBall].convertFromImage(tempImg);
@@ -697,18 +697,18 @@ void KNConfig::ReadNewsViewer::save()
KNConfig::DisplayedHeaders::DisplayedHeaders()
{
- QString fname( locate("data","knode/headers.rc") );
+ TQString fname( locate("data","knode/headers.rc") );
if (!fname.isNull()) {
KSimpleConfig headerConf(fname,true);
- QStringList headers = headerConf.groupList();
+ TQStringList headers = headerConf.groupList();
headers.remove("<default>");
headers.sort();
KNDisplayedHeader *h;
- QValueList<int> flags;
+ TQValueList<int> flags;
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for( it = headers.begin(); it != headers.end(); ++it ) {
h=createNewHeader();
headerConf.setGroup((*it));
@@ -732,7 +732,7 @@ KNConfig::DisplayedHeaders::DisplayedHeaders()
KNConfig::DisplayedHeaders::~DisplayedHeaders()
{
- for ( QValueList<KNDisplayedHeader*>::Iterator it = mHeaderList.begin(); it != mHeaderList.end(); ++it )
+ for ( TQValueList<KNDisplayedHeader*>::Iterator it = mHeaderList.begin(); it != mHeaderList.end(); ++it )
delete (*it);
}
@@ -744,23 +744,23 @@ void KNConfig::DisplayedHeaders::save()
kdDebug(5003) << "KNConfig::DisplayedHeaders::save()" << endl;
- QString dir(locateLocal("data","knode/"));
+ TQString dir(locateLocal("data","knode/"));
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
}
KSimpleConfig headerConf(dir+"headers.rc");
- QStringList oldHeaders = headerConf.groupList();
+ TQStringList oldHeaders = headerConf.groupList();
- QStringList::Iterator oldIt=oldHeaders.begin();
+ TQStringList::Iterator oldIt=oldHeaders.begin();
for( ;oldIt != oldHeaders.end(); ++oldIt ) // remove all old groups
headerConf.deleteGroup((*oldIt)); // find a better way to do it?
- QValueList<int> flags;
+ TQValueList<int> flags;
int idx=0;
- QString group;
+ TQString group;
- for ( QValueList<KNDisplayedHeader*>::Iterator it = mHeaderList.begin(); it != mHeaderList.end(); ++it ) {
+ for ( TQValueList<KNDisplayedHeader*>::Iterator it = mHeaderList.begin(); it != mHeaderList.end(); ++it ) {
group.setNum(idx++);
while (group.length()<3)
group.prepend("0");
@@ -859,7 +859,7 @@ void KNConfig::Scoring::save()
//==============================================================================================================
-KNConfig::XHeader::XHeader(const QString &s)
+KNConfig::XHeader::XHeader(const TQString &s)
{
if(s.left(2)=="X-") {
int pos=s.find(": ");
@@ -885,14 +885,14 @@ KNConfig::PostNewsTechnical::PostNewsTechnical()
c_omposerCharsets=conf->readListEntry("ComposerCharsets");
if (c_omposerCharsets.isEmpty())
- c_omposerCharsets=QStringList::split(',',"us-ascii,utf-8,iso-8859-1,iso-8859-2,"
+ c_omposerCharsets=TQStringList::split(',',"us-ascii,utf-8,iso-8859-1,iso-8859-2,"
"iso-8859-3,iso-8859-4,iso-8859-5,iso-8859-6,iso-8859-7,iso-8859-8,"
"iso-8859-9,iso-8859-10,iso-8859-13,iso-8859-14,iso-8859-15,koi8-r,koi8-u,"
"iso-2022-jp,iso-2022-jp-2,iso-2022-kr,euc-jp,euc-kr,Big5,gb2312");
c_harset=conf->readEntry("Charset").latin1();
if (c_harset.isEmpty()) {
- QCString localeCharset(QTextCodec::codecForLocale()->mimeName());
+ TQCString localeCharset(TQTextCodec::codecForLocale()->mimeName());
// special logic for japanese users:
// "euc-jp" is default encoding for them, but in the news
@@ -912,11 +912,11 @@ KNConfig::PostNewsTechnical::PostNewsTechnical()
d_ontIncludeUA=conf->readBoolEntry("dontIncludeUA", false);
u_seExternalMailer=conf->readBoolEntry("useExternalMailer", false);
- QString dir(locateLocal("data","knode/"));
+ TQString dir(locateLocal("data","knode/"));
if (!dir.isNull()) {
- QFile f(dir+"xheaders");
+ TQFile f(dir+"xheaders");
if(f.open(IO_ReadOnly)) {
- QTextStream ts(&f);
+ TQTextStream ts(&f);
while(!ts.eof())
x_headers.append( XHeader(ts.readLine()) );
@@ -942,21 +942,21 @@ void KNConfig::PostNewsTechnical::save()
conf->setGroup("POSTNEWS");
conf->writeEntry("ComposerCharsets", c_omposerCharsets);
- conf->writeEntry("Charset", QString::fromLatin1(c_harset));
+ conf->writeEntry("Charset", TQString::fromLatin1(c_harset));
conf->writeEntry("8BitEncoding", a_llow8BitBody);
conf->writeEntry("UseOwnCharset", u_seOwnCharset);
conf->writeEntry("generateMId", g_enerateMID);
- conf->writeEntry("MIdhost", QString::fromLatin1(h_ostname));
+ conf->writeEntry("MIdhost", TQString::fromLatin1(h_ostname));
conf->writeEntry("dontIncludeUA", d_ontIncludeUA);
conf->writeEntry("useExternalMailer", u_seExternalMailer);
- QString dir(locateLocal("data","knode/"));
+ TQString dir(locateLocal("data","knode/"));
if (dir.isNull())
KNHelper::displayInternalFileError();
else {
- QFile f(dir+"xheaders");
+ TQFile f(dir+"xheaders");
if(f.open(IO_WriteOnly)) {
- QTextStream ts(&f);
+ TQTextStream ts(&f);
XHeaders::Iterator it;
for(it=x_headers.begin(); it!=x_headers.end(); ++it)
ts << (*it).header() << "\n";
@@ -970,11 +970,11 @@ void KNConfig::PostNewsTechnical::save()
}
-int KNConfig::PostNewsTechnical::indexForCharset(const QCString &str)
+int KNConfig::PostNewsTechnical::indexForCharset(const TQCString &str)
{
int i=0;
bool found=false;
- for ( QStringList::Iterator it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
+ for ( TQStringList::Iterator it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
if ((*it).lower() == str.lower().data()) {
found = true;
break;
@@ -983,7 +983,7 @@ int KNConfig::PostNewsTechnical::indexForCharset(const QCString &str)
}
if (!found) {
i=0;
- for ( QStringList::Iterator it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
+ for ( TQStringList::Iterator it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
if ((*it).lower() == c_harset.lower().data()) {
found = true;
break;
@@ -997,15 +997,15 @@ int KNConfig::PostNewsTechnical::indexForCharset(const QCString &str)
}
-QCString KNConfig::PostNewsTechnical::findComposerCharset(QCString cs)
+TQCString KNConfig::PostNewsTechnical::findComposerCharset(TQCString cs)
{
- QCString *ret=findComposerCSCache.find(cs);
+ TQCString *ret=findComposerCSCache.find(cs);
if (ret)
return *ret;
- QCString s;
+ TQCString s;
- QStringList::Iterator it;
+ TQStringList::Iterator it;
for( it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
// match by name
if ((*it).lower()==cs.lower().data()) {
@@ -1018,8 +1018,8 @@ QCString KNConfig::PostNewsTechnical::findComposerCharset(QCString cs)
for( it = c_omposerCharsets.begin(); it != c_omposerCharsets.end(); ++it ) {
// match by charset, avoid to return "us-ascii" for iso-8859-1
if ((*it).lower()!="us-ascii") {
- QTextCodec *composerCodec = QTextCodec::codecForName((*it).latin1());
- QTextCodec *csCodec = QTextCodec::codecForName(cs);
+ TQTextCodec *composerCodec = TQTextCodec::codecForName((*it).latin1());
+ TQTextCodec *csCodec = TQTextCodec::codecForName(cs);
if ((composerCodec != 0) &&
(csCodec != 0) &&
(0 == strcmp(composerCodec->name(), csCodec->name()))) {
@@ -1033,7 +1033,7 @@ QCString KNConfig::PostNewsTechnical::findComposerCharset(QCString cs)
if (s.isEmpty())
s = "us-ascii";
- findComposerCSCache.insert(cs, new QCString(s));
+ findComposerCSCache.insert(cs, new TQCString(s));
return s;
}
@@ -1100,7 +1100,7 @@ KNConfig::Cleanup::Cleanup( bool global ) :
// default values for new accounts / groups
d_oExpire( true ), r_emoveUnavailable( true ), p_reserveThr( true ),
e_xpireInterval( 5 ), r_eadMaxAge( 10 ), u_nreadMaxAge( 15 ),
- mGlobal(global), mDefault(!global), mLastExpDate( QDate::currentDate() )
+ mGlobal(global), mDefault(!global), mLastExpDate( TQDate::currentDate() )
{
if (mGlobal) {
KConfig *conf = knGlobals.config();
@@ -1174,7 +1174,7 @@ bool KNConfig::Cleanup::expireToday()
if (!d_oExpire)
return false;
- QDate today = QDate::currentDate();
+ TQDate today = TQDate::currentDate();
if (mLastExpDate == today)
return false;
@@ -1184,7 +1184,7 @@ bool KNConfig::Cleanup::expireToday()
void KNConfig::Cleanup::setLastExpireDate()
{
- mLastExpDate = QDateTime::currentDateTime();
+ mLastExpDate = TQDateTime::currentDateTime();
}
@@ -1193,7 +1193,7 @@ bool KNConfig::Cleanup::compactToday()
if (!d_oCompact)
return false;
- QDate today = QDate::currentDate();
+ TQDate today = TQDate::currentDate();
if (mLastCompDate == today)
return false;
@@ -1203,7 +1203,7 @@ bool KNConfig::Cleanup::compactToday()
void KNConfig::Cleanup::setLastCompactDate()
{
- mLastCompDate = QDateTime::currentDateTime();
+ mLastCompDate = TQDateTime::currentDateTime();
}
diff --git a/knode/knconfig.h b/knode/knconfig.h
index 2248a361c..e2aa682bf 100644
--- a/knode/knconfig.h
+++ b/knode/knconfig.h
@@ -15,12 +15,12 @@
#ifndef KNCONFIG_H
#define KNCONFIG_H
-#include <qasciidict.h>
-#include <qcolor.h>
-#include <qdatetime.h>
-#include <qfont.h>
-#include <qobject.h>
-#include <qpixmap.h>
+#include <tqasciidict.h>
+#include <tqcolor.h>
+#include <tqdatetime.h>
+#include <tqfont.h>
+#include <tqobject.h>
+#include <tqpixmap.h>
#include <kconfig.h>
@@ -63,7 +63,7 @@ class Base {
};
-class KDE_EXPORT Identity : public QObject, public Base {
+class KDE_EXPORT Identity : public TQObject, public Base {
Q_OBJECT
@@ -81,35 +81,35 @@ Q_OBJECT
//personal information
bool hasName() { return (!n_ame.isEmpty()); }
- QString name() const { return n_ame; }
- void setName(const QString &s) { n_ame=s; }
+ TQString name() const { return n_ame; }
+ void setName(const TQString &s) { n_ame=s; }
bool emailIsValid();
bool hasEmail() { return (!e_mail.isEmpty()); }
- QString email() { return e_mail; }
- void setEmail(const QCString &s) { e_mail=s; }
+ TQString email() { return e_mail; }
+ void setEmail(const TQCString &s) { e_mail=s; }
bool hasReplyTo() { return (!r_eplyTo.isEmpty()); }
- QString replyTo() { return r_eplyTo; }
- void setReplyTo(const QString &s) { r_eplyTo=s; }
+ TQString replyTo() { return r_eplyTo; }
+ void setReplyTo(const TQString &s) { r_eplyTo=s; }
bool hasMailCopiesTo() { return (!m_ailCopiesTo.isEmpty()); }
- QString mailCopiesTo() { return m_ailCopiesTo; }
- void setMailCopiesTo(const QString &s) { m_ailCopiesTo=s; }
+ TQString mailCopiesTo() { return m_ailCopiesTo; }
+ void setMailCopiesTo(const TQString &s) { m_ailCopiesTo=s; }
bool hasOrga() { return (!o_rga.isEmpty()); }
- QString orga() const { return o_rga; }
- void setOrga(const QString &s) { o_rga=s; }
+ TQString orga() const { return o_rga; }
+ void setOrga(const TQString &s) { o_rga=s; }
// OpenPGP signing key
bool hasSigningKey() { return (!s_igningKey.isEmpty()); }
- QCString signingKey() { return s_igningKey; }
- void setSigningKey(const QCString &s) { s_igningKey=s;}
+ TQCString signingKey() { return s_igningKey; }
+ void setSigningKey(const TQCString &s) { s_igningKey=s;}
//signature
bool hasSignature() { return ( (u_seSigFile && !s_igPath.isEmpty()) || !s_igText.isEmpty() ); }
bool useSigFile() const { return u_seSigFile; }
bool useSigGenerator()const { return u_seSigGenerator; }
- QString sigPath()const { return s_igPath; }
- QString sigText()const { return s_igText; }
- QString getSignature();
- QString getSigGeneratorStdErr() { return s_igStdErr; }
+ TQString sigPath()const { return s_igPath; }
+ TQString sigText()const { return s_igText; }
+ TQString getSignature();
+ TQString getSigGeneratorStdErr() { return s_igStdErr; }
protected slots:
@@ -117,7 +117,7 @@ Q_OBJECT
void slotReceiveStderr(KProcess *proc, char *buffer, int buflen);
protected:
- QString n_ame,
+ TQString n_ame,
e_mail,
o_rga,
r_eplyTo,
@@ -126,7 +126,7 @@ Q_OBJECT
s_igContents,
s_igStdErr,
s_igPath;
- QCString s_igningKey;
+ TQCString s_igningKey;
bool u_seSigFile,
u_seSigGenerator,
g_lobal;
@@ -160,49 +160,49 @@ class KDE_EXPORT Appearance : public Base {
void save();
- QColor backgroundColor() const;
- QColor alternateBackgroundColor() const;
- QColor textColor() const;
- QColor quoteColor( int depth ) const;
- QColor linkColor() const;
- QColor unreadThreadColor() const;
- QColor readThreadColor() const;
- QColor unreadArticleColor() const;
- QColor readArticleColor() const;
- QColor signOkKeyOkColor() const { return u_seColors ? c_olors[signOkKeyOk] : defaultColor( signOkKeyOk ); }
- QColor signOkKeyBadColor() const { return u_seColors ? c_olors[signOkKeyBad] : defaultColor( signOkKeyBad ); }
- QColor signWarnColor() const { return u_seColors ? c_olors[signWarn] : defaultColor( signWarn ); }
- QColor signErrColor() const { return u_seColors ? c_olors[signErr] : defaultColor( signErr ); }
- QColor htmlWarningColor() const { return u_seColors ? c_olors[htmlWarning] : defaultColor( htmlWarning ); }
-
- QFont articleFont() const;
- QFont articleFixedFont() const;
- QFont composerFont() const;
- QFont groupListFont() const;
- QFont articleListFont() const;
-
- const QPixmap& icon(IconIndex i) { return i_cons[i]; }
+ TQColor backgroundColor() const;
+ TQColor alternateBackgroundColor() const;
+ TQColor textColor() const;
+ TQColor quoteColor( int depth ) const;
+ TQColor linkColor() const;
+ TQColor unreadThreadColor() const;
+ TQColor readThreadColor() const;
+ TQColor unreadArticleColor() const;
+ TQColor readArticleColor() const;
+ TQColor signOkKeyOkColor() const { return u_seColors ? c_olors[signOkKeyOk] : defaultColor( signOkKeyOk ); }
+ TQColor signOkKeyBadColor() const { return u_seColors ? c_olors[signOkKeyBad] : defaultColor( signOkKeyBad ); }
+ TQColor signWarnColor() const { return u_seColors ? c_olors[signWarn] : defaultColor( signWarn ); }
+ TQColor signErrColor() const { return u_seColors ? c_olors[signErr] : defaultColor( signErr ); }
+ TQColor htmlWarningColor() const { return u_seColors ? c_olors[htmlWarning] : defaultColor( htmlWarning ); }
+
+ TQFont articleFont() const;
+ TQFont articleFixedFont() const;
+ TQFont composerFont() const;
+ TQFont groupListFont() const;
+ TQFont articleListFont() const;
+
+ const TQPixmap& icon(IconIndex i) { return i_cons[i]; }
protected:
- const QColor& color( int i ) const { return c_olors[i]; }
- const QString& colorName( int i ) const { return c_olorNames[i]; }
+ const TQColor& color( int i ) const { return c_olors[i]; }
+ const TQString& colorName( int i ) const { return c_olorNames[i]; }
int colorCount() const { return COL_CNT; }
- QColor defaultColor(int i) const;
+ TQColor defaultColor(int i) const;
- const QFont& font(int i) const { return f_onts[i]; }
- const QString& fontName(int i) const { return f_ontNames[i]; }
+ const TQFont& font(int i) const { return f_onts[i]; }
+ const TQString& fontName(int i) const { return f_ontNames[i]; }
int fontCount() const { return FNT_CNT; }
- QFont defaultFont(int) const;
+ TQFont defaultFont(int) const;
void recreateLVIcons();
bool u_seColors,
u_seFonts;
- QColor c_olors[COL_CNT];
- QString c_olorNames[COL_CNT];
- QFont f_onts[FNT_CNT];
- QString f_ontNames[FNT_CNT];
- QPixmap i_cons[ICON_CNT];
+ TQColor c_olors[COL_CNT];
+ TQString c_olorNames[COL_CNT];
+ TQFont f_onts[FNT_CNT];
+ TQString f_ontNames[FNT_CNT];
+ TQPixmap i_cons[ICON_CNT];
};
@@ -237,7 +237,7 @@ class KDE_EXPORT ReadNewsGeneral : public Base {
void setShowThreads(bool b) { d_irty=true; s_howThreads=b;}
KMime::DateFormatter::FormatType dateFormat() const { return mDateFormat; }
- QString dateCustomFormat() const { return mDateCustomFormat; }
+ TQString dateCustomFormat() const { return mDateCustomFormat; }
void setShowLines( bool show ) { d_irty = true; s_howLines = show; }
void setShowScore( bool show ) { d_irty = true; s_howScore = show; }
@@ -260,7 +260,7 @@ class KDE_EXPORT ReadNewsGeneral : public Base {
a_rtCacheSize;
KMime::DateFormatter::FormatType mDateFormat;
- QString mDateCustomFormat;
+ TQString mDateCustomFormat;
};
@@ -308,7 +308,7 @@ class KDE_EXPORT ReadNewsViewer : public Base {
bool showSignature()const { return s_howSig; }
bool interpretFormatTags()const { return i_nterpretFormatTags; }
void setInterpretFormatTags( bool f ) { d_irty = true; i_nterpretFormatTags = f; }
- QString quoteCharacters()const { return q_uoteCharacters; }
+ TQString quoteCharacters()const { return q_uoteCharacters; }
bool openAttachmentsOnClick()const { return o_penAtt; }
bool showAlternativeContents()const { return s_howAlts; }
@@ -332,7 +332,7 @@ class KDE_EXPORT ReadNewsViewer : public Base {
u_seFixedFont,
mShowRefBar,
mAlwaysShowHTML;
- QString q_uoteCharacters;
+ TQString q_uoteCharacters;
};
@@ -349,11 +349,11 @@ class KDE_EXPORT DisplayedHeaders : public Base
void up(KNDisplayedHeader *h);
void down(KNDisplayedHeader *h);
- QValueList<KNDisplayedHeader*> headers() const { return mHeaderList; }
+ TQValueList<KNDisplayedHeader*> headers() const { return mHeaderList; }
protected:
- QValueList<KNDisplayedHeader*> mHeaderList;
+ TQValueList<KNDisplayedHeader*> mHeaderList;
};
@@ -382,22 +382,22 @@ class KDE_EXPORT XHeader {
public:
XHeader() {}
- XHeader(const QString &s);
+ XHeader(const TQString &s);
XHeader(const XHeader &s) { n_ame=s.n_ame; v_alue=s.v_alue; }
~XHeader() {}
XHeader& operator=(const XHeader &s) { n_ame=s.n_ame; v_alue=s.v_alue; return (*this); }
- QCString name() { return n_ame; }
- QString value() { return v_alue; }
- QString header() { return (QString::fromLatin1(("X-"+n_ame+": "))+v_alue); }
+ TQCString name() { return n_ame; }
+ TQString value() { return v_alue; }
+ TQString header() { return (TQString::fromLatin1(("X-"+n_ame+": "))+v_alue); }
protected:
- QCString n_ame;
- QString v_alue;
+ TQCString n_ame;
+ TQString v_alue;
};
-typedef QValueList<XHeader> XHeaders;
+typedef TQValueList<XHeader> XHeaders;
class KDE_EXPORT PostNewsTechnical : public Base {
@@ -411,23 +411,23 @@ class KDE_EXPORT PostNewsTechnical : public Base {
void save();
- QCString charset() const { return c_harset; }
- QStringList composerCharsets() { return c_omposerCharsets; }
- int indexForCharset(const QCString &str);
- QCString findComposerCharset(QCString cs);
+ TQCString charset() const { return c_harset; }
+ TQStringList composerCharsets() { return c_omposerCharsets; }
+ int indexForCharset(const TQCString &str);
+ TQCString findComposerCharset(TQCString cs);
bool allow8BitBody() const { return a_llow8BitBody; }
bool useOwnCharset() const { return u_seOwnCharset; }
bool generateMessageID()const { return g_enerateMID; }
- QCString hostname()const { return h_ostname; }
+ TQCString hostname()const { return h_ostname; }
XHeaders& xHeaders() { return x_headers; }
bool noUserAgent()const { return d_ontIncludeUA; }
bool useExternalMailer()const { return u_seExternalMailer; }
protected:
- QCString c_harset,
+ TQCString c_harset,
h_ostname;
- QStringList c_omposerCharsets;
+ TQStringList c_omposerCharsets;
bool a_llow8BitBody,
u_seOwnCharset,
@@ -437,7 +437,7 @@ class KDE_EXPORT PostNewsTechnical : public Base {
XHeaders x_headers;
- QAsciiDict<QCString> findComposerCSCache;
+ TQAsciiDict<TQCString> findComposerCSCache;
};
@@ -455,12 +455,12 @@ class PostNewsComposer : public Base {
int maxLineLength()const { return m_axLen; }
bool appendOwnSignature()const { return a_ppSig; }
- QString intro()const { return i_ntro; }
+ TQString intro()const { return i_ntro; }
bool rewrap()const { return r_ewrap; }
bool includeSignature()const { return i_ncSig; }
bool cursorOnTop()const { return c_ursorOnTop; }
- QString externalEditor()const { return e_xternalEditor; }
+ TQString externalEditor()const { return e_xternalEditor; }
bool useExternalEditor()const { return u_seExtEditor; }
@@ -472,7 +472,7 @@ class PostNewsComposer : public Base {
i_ncSig,
c_ursorOnTop,
u_seExtEditor;
- QString i_ntro,
+ TQString i_ntro,
e_xternalEditor;
};
@@ -526,7 +526,7 @@ class KDE_EXPORT Cleanup : public Base {
/** use default cleanup configuration */
bool mDefault;
/** last expiration and last comapction date */
- QDateTime mLastExpDate, mLastCompDate;
+ TQDateTime mLastExpDate, mLastCompDate;
};
diff --git a/knode/knconfigmanager.cpp b/knode/knconfigmanager.cpp
index b117f3c49..ad77b0235 100644
--- a/knode/knconfigmanager.cpp
+++ b/knode/knconfigmanager.cpp
@@ -21,7 +21,7 @@
#include <klocale.h>
#include <kwin.h>
-#include <qhbox.h>
+#include <tqhbox.h>
#include "utilities.h"
#include "knglobals.h"
@@ -30,8 +30,8 @@
#include "knmainwidget.h"
-KNConfigManager::KNConfigManager(QObject *p, const char *n)
- : QObject(p, n), d_ialog(0)
+KNConfigManager::KNConfigManager(TQObject *p, const char *n)
+ : TQObject(p, n), d_ialog(0)
{
i_dentity = new KNConfig::Identity();
a_ppearance = new KNConfig::Appearance();
@@ -67,7 +67,7 @@ void KNConfigManager::configure()
{
if(!d_ialog) {
d_ialog=new KNConfigDialog(knGlobals.topWidget, "Preferences_Dlg");
- connect(d_ialog, SIGNAL(finished()), this, SLOT(slotDialogDone()));
+ connect(d_ialog, TQT_SIGNAL(finished()), this, TQT_SLOT(slotDialogDone()));
d_ialog->show();
}
else
@@ -100,7 +100,7 @@ void KNConfigManager::slotDialogDone()
//===================================================================================================
-KNConfigDialog::KNConfigDialog(QWidget *p, const char *n)
+KNConfigDialog::KNConfigDialog(TQWidget *p, const char *n)
: KCMultiDialog(p, n)
{
addModule ( "knode_config_identity", false );
@@ -113,7 +113,7 @@ KNConfigDialog::KNConfigDialog(QWidget *p, const char *n)
setHelp("anc-setting-your-identity");
- connect(this, SIGNAL(configCommitted()), this, SLOT(slotConfigCommitted()));
+ connect(this, TQT_SIGNAL(configCommitted()), this, TQT_SLOT(slotConfigCommitted()));
}
diff --git a/knode/knconfigmanager.h b/knode/knconfigmanager.h
index 6f0db527d..5a002a933 100644
--- a/knode/knconfigmanager.h
+++ b/knode/knconfigmanager.h
@@ -24,12 +24,12 @@
class KNConfigDialog;
-class KNConfigManager : QObject {
+class KNConfigManager : TQObject {
Q_OBJECT
public:
- KNConfigManager(QObject *p=0, const char *n=0);
+ KNConfigManager(TQObject *p=0, const char *n=0);
~KNConfigManager();
KNConfig::Identity* identity() const { return i_dentity; }
@@ -73,7 +73,7 @@ class KNConfigDialog : public KCMultiDialog {
Q_OBJECT
public:
- KNConfigDialog(QWidget *p=0, const char *n=0);
+ KNConfigDialog(TQWidget *p=0, const char *n=0);
protected slots:
void slotConfigCommitted();
diff --git a/knode/knconfigpages.cpp b/knode/knconfigpages.cpp
index c7d0c0758..030838acb 100644
--- a/knode/knconfigpages.cpp
+++ b/knode/knconfigpages.cpp
@@ -11,7 +11,7 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
+#include <tqlayout.h>
#include <kcmodule.h>
#include <kdebug.h>
@@ -28,17 +28,17 @@
//
// common config page with tabs (code mostly taken from kmail)
//
-KNConfig::BasePageWithTabs::BasePageWithTabs( QWidget * parent, const char * name )
+KNConfig::BasePageWithTabs::BasePageWithTabs( TQWidget * parent, const char * name )
: KCModule( parent, name )
{
- QVBoxLayout *vlay = new QVBoxLayout( this, 0, KDialog::spacingHint() );
- mTabWidget = new QTabWidget( this );
+ TQVBoxLayout *vlay = new TQVBoxLayout( this, 0, KDialog::spacingHint() );
+ mTabWidget = new TQTabWidget( this );
vlay->addWidget( mTabWidget );
}
-void KNConfig::BasePageWithTabs::addTab( KCModule* tab, const QString & title ) {
+void KNConfig::BasePageWithTabs::addTab( KCModule* tab, const TQString & title ) {
mTabWidget->addTab( tab, title );
- connect( tab, SIGNAL(changed( bool )), this, SIGNAL(changed( bool )) );
+ connect( tab, TQT_SIGNAL(changed( bool )), this, TQT_SIGNAL(changed( bool )) );
}
void KNConfig::BasePageWithTabs::load() {
@@ -72,7 +72,7 @@ void KNConfig::BasePageWithTabs::defaults() {
//
extern "C"
{
- KDE_EXPORT KCModule *create_knode_config_identity( QWidget *parent, const char * )
+ KDE_EXPORT KCModule *create_knode_config_identity( TQWidget *parent, const char * )
{
KNConfig::IdentityWidget *page = new KNConfig::IdentityWidget(
knGlobals.configManager()->identity(),
@@ -89,14 +89,14 @@ extern "C"
//
extern "C"
{
- KCModule *create_knode_config_accounts( QWidget *parent, const char * )
+ KCModule *create_knode_config_accounts( TQWidget *parent, const char * )
{
KNConfig::AccountsPage *page = new KNConfig::AccountsPage( parent, "kcmknode_config_accounts" );
return page;
}
}
-KNConfig::AccountsPage::AccountsPage(QWidget *parent, const char *name)
+KNConfig::AccountsPage::AccountsPage(TQWidget *parent, const char *name)
: BasePageWithTabs(parent, name) {
addTab(new KNConfig::NntpAccountListWidget(this), i18n("Newsgroup Servers"));
@@ -110,7 +110,7 @@ KNConfig::AccountsPage::AccountsPage(QWidget *parent, const char *name)
//
extern "C"
{
- KCModule *create_knode_config_appearance( QWidget *parent, const char * )
+ KCModule *create_knode_config_appearance( TQWidget *parent, const char * )
{
KNConfig::AppearanceWidget *page = new KNConfig::AppearanceWidget( parent, "kcmknode_config_appearance" );
return page;
@@ -124,14 +124,14 @@ extern "C"
//
extern "C"
{
- KCModule *create_knode_config_read_news( QWidget *parent, const char * )
+ KCModule *create_knode_config_read_news( TQWidget *parent, const char * )
{
KNConfig::ReadNewsPage *page = new KNConfig::ReadNewsPage( parent, "kcmknode_config_read_news" );
return page;
}
}
-KNConfig::ReadNewsPage::ReadNewsPage(QWidget *parent, const char *name)
+KNConfig::ReadNewsPage::ReadNewsPage(TQWidget *parent, const char *name)
: BasePageWithTabs(parent, name) {
KNConfigManager *cfgMgr = knGlobals.configManager();
@@ -150,14 +150,14 @@ KNConfig::ReadNewsPage::ReadNewsPage(QWidget *parent, const char *name)
//
extern "C"
{
- KCModule *create_knode_config_post_news( QWidget *parent, const char * )
+ KCModule *create_knode_config_post_news( TQWidget *parent, const char * )
{
KNConfig::PostNewsPage *page = new KNConfig::PostNewsPage( parent, "kcmknode_config_post_news" );
return page;
}
}
-KNConfig::PostNewsPage::PostNewsPage(QWidget *parent, const char *name)
+KNConfig::PostNewsPage::PostNewsPage(TQWidget *parent, const char *name)
: BasePageWithTabs(parent, name) {
KNConfigManager *cfgMgr = knGlobals.configManager();
@@ -173,7 +173,7 @@ KNConfig::PostNewsPage::PostNewsPage(QWidget *parent, const char *name)
//
extern "C"
{
- KCModule *create_knode_config_privacy( QWidget *parent, const char * )
+ KCModule *create_knode_config_privacy( TQWidget *parent, const char * )
{
KNConfig::PrivacyWidget *page = new KNConfig::PrivacyWidget( parent, "kcmknode_config_privacy" );
return page;
@@ -187,7 +187,7 @@ extern "C"
//
extern "C"
{
- KCModule *create_knode_config_cleanup( QWidget *parent, const char * )
+ KCModule *create_knode_config_cleanup( TQWidget *parent, const char * )
{
KNConfig::CleanupWidget *page = new KNConfig::CleanupWidget( parent, "kcmknode_config_cleanup" );
return page;
diff --git a/knode/knconfigpages.h b/knode/knconfigpages.h
index c76432b78..c1426fbc8 100644
--- a/knode/knconfigpages.h
+++ b/knode/knconfigpages.h
@@ -32,7 +32,7 @@ namespace KNConfig {
class KDE_EXPORT BasePageWithTabs : public KCModule {
Q_OBJECT
public:
- BasePageWithTabs( QWidget * parent=0, const char * name=0 );
+ BasePageWithTabs( TQWidget * parent=0, const char * name=0 );
~BasePageWithTabs() {};
virtual void load();
@@ -40,10 +40,10 @@ class KDE_EXPORT BasePageWithTabs : public KCModule {
virtual void defaults();
protected:
- void addTab( KCModule* tab, const QString & title );
+ void addTab( KCModule* tab, const TQString & title );
private:
- QTabWidget *mTabWidget;
+ TQTabWidget *mTabWidget;
};
@@ -53,7 +53,7 @@ class AccountsPage : public BasePageWithTabs {
Q_OBJECT
public:
- AccountsPage(QWidget *parent = 0, const char *name = 0);
+ AccountsPage(TQWidget *parent = 0, const char *name = 0);
};
@@ -62,7 +62,7 @@ class KDE_EXPORT ReadNewsPage : public BasePageWithTabs {
Q_OBJECT
public:
- ReadNewsPage(QWidget *parent = 0, const char *name = 0);
+ ReadNewsPage(TQWidget *parent = 0, const char *name = 0);
};
// post news page
@@ -70,7 +70,7 @@ class KDE_EXPORT PostNewsPage : public BasePageWithTabs {
Q_OBJECT
public:
- PostNewsPage(QWidget *parent = 0, const char *name = 0);
+ PostNewsPage(TQWidget *parent = 0, const char *name = 0);
};
diff --git a/knode/knconfigwidgets.cpp b/knode/knconfigwidgets.cpp
index 72d8f366c..91fba601e 100644
--- a/knode/knconfigwidgets.cpp
+++ b/knode/knconfigwidgets.cpp
@@ -13,10 +13,10 @@
*/
-#include <qvbox.h>
-#include <qpainter.h>
-#include <qwhatsthis.h>
-#include <qlabel.h>
+#include <tqvbox.h>
+#include <tqpainter.h>
+#include <tqwhatsthis.h>
+#include <tqlabel.h>
#include <klocale.h>
#include <knumvalidator.h>
@@ -50,128 +50,128 @@
#include <kpgp.h>
-KNConfig::IdentityWidget::IdentityWidget( Identity *d, QWidget *p, const char *n ) :
+KNConfig::IdentityWidget::IdentityWidget( Identity *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QString msg;
+ TQString msg;
- QGridLayout *topL=new QGridLayout(this, 11, 3, 5,5);
+ TQGridLayout *topL=new TQGridLayout(this, 11, 3, 5,5);
n_ame=new KLineEdit(this);
- QLabel *l=new QLabel(n_ame, i18n("&Name:"), this);
+ TQLabel *l=new TQLabel(n_ame, i18n("&Name:"), this);
topL->addWidget(l, 0,0);
topL->addMultiCellWidget(n_ame, 0,0, 1,2);
msg = i18n("<qt><p>Your name as it will appear to others reading your articles.</p>"
"<p>Ex: <b>John Stuart Masterson III</b>.</p></qt>");
- QWhatsThis::add( n_ame, msg );
- QWhatsThis::add( l, msg );
- connect( n_ame, SIGNAL(textChanged(const QString&)), SLOT(changed()) );
+ TQWhatsThis::add( n_ame, msg );
+ TQWhatsThis::add( l, msg );
+ connect( n_ame, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()) );
o_rga=new KLineEdit(this);
- l=new QLabel(o_rga, i18n("Organi&zation:"), this);
+ l=new TQLabel(o_rga, i18n("Organi&zation:"), this);
topL->addWidget(l, 1,0);
topL->addMultiCellWidget(o_rga, 1,1, 1,2);
msg = i18n( "<qt><p>The name of the organization you work for.</p>"
"<p>Ex: <b>KNode, Inc</b>.</p></qt>" );
- QWhatsThis::add( o_rga, msg );
- QWhatsThis::add( l, msg );
- connect( o_rga, SIGNAL(textChanged(const QString&)), SLOT(changed()) );
+ TQWhatsThis::add( o_rga, msg );
+ TQWhatsThis::add( l, msg );
+ connect( o_rga, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()) );
e_mail=new KLineEdit(this);
- l=new QLabel(e_mail, i18n("Email a&ddress:"), this);
+ l=new TQLabel(e_mail, i18n("Email a&ddress:"), this);
topL->addWidget(l, 2,0);
topL->addMultiCellWidget(e_mail, 2,2, 1,2);
msg = i18n( "<qt><p>Your email address as it will appear to others "
"reading your articles</p><p>Ex: <b>nospam@please.com</b>.</qt>" );
- QWhatsThis::add( l, msg );
- QWhatsThis::add( e_mail, msg );
- connect( e_mail, SIGNAL(textChanged(const QString&)), SLOT(changed()) );
+ TQWhatsThis::add( l, msg );
+ TQWhatsThis::add( e_mail, msg );
+ connect( e_mail, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()) );
r_eplyTo=new KLineEdit(this);
- l=new QLabel(r_eplyTo, i18n("&Reply-to address:"), this);
+ l=new TQLabel(r_eplyTo, i18n("&Reply-to address:"), this);
topL->addWidget(l, 3,0);
topL->addMultiCellWidget(r_eplyTo, 3,3, 1,2);
msg = i18n( "<qt><p>When someone reply to your article by email, this is the address the message "
"will be sent. If you fill in this field, please do it with a real "
"email address.</p><p>Ex: <b>john@example.com</b>.</p></qt>" );
- QWhatsThis::add( l, msg );
- QWhatsThis::add( r_eplyTo, msg );
- connect( r_eplyTo, SIGNAL(textChanged(const QString&)), SLOT(changed()) );
+ TQWhatsThis::add( l, msg );
+ TQWhatsThis::add( r_eplyTo, msg );
+ connect( r_eplyTo, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()) );
m_ailCopiesTo=new KLineEdit(this);
- l=new QLabel(m_ailCopiesTo, i18n("&Mail-copies-to:"), this);
+ l=new TQLabel(m_ailCopiesTo, i18n("&Mail-copies-to:"), this);
topL->addWidget(l, 4,0);
topL->addMultiCellWidget(m_ailCopiesTo, 4,4, 1,2);
- connect( m_ailCopiesTo, SIGNAL(textChanged(const QString&)), SLOT(changed()) );
+ connect( m_ailCopiesTo, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()) );
s_igningKey = new Kpgp::SecretKeyRequester(this);
s_igningKey->dialogButton()->setText(i18n("Chan&ge..."));
s_igningKey->setDialogCaption(i18n("Your OpenPGP Key"));
s_igningKey->setDialogMessage(i18n("Select the OpenPGP key which should be "
"used for signing articles."));
- l=new QLabel(s_igningKey, i18n("Signing ke&y:"), this);
+ l=new TQLabel(s_igningKey, i18n("Signing ke&y:"), this);
topL->addWidget(l, 5,0);
topL->addMultiCellWidget(s_igningKey, 5,5, 1,2);
msg = i18n("<qt><p>The OpenPGP key you choose here will be "
"used to sign your articles.</p></qt>");
- QWhatsThis::add( l, msg );
- QWhatsThis::add( s_igningKey, msg );
- connect( s_igningKey, SIGNAL(changed()), SLOT(changed()) );
+ TQWhatsThis::add( l, msg );
+ TQWhatsThis::add( s_igningKey, msg );
+ connect( s_igningKey, TQT_SIGNAL(changed()), TQT_SLOT(changed()) );
- b_uttonGroup = new QButtonGroup(this);
- connect( b_uttonGroup, SIGNAL(clicked(int)),
- this, SLOT(slotSignatureType(int)) );
+ b_uttonGroup = new TQButtonGroup(this);
+ connect( b_uttonGroup, TQT_SIGNAL(clicked(int)),
+ this, TQT_SLOT(slotSignatureType(int)) );
b_uttonGroup->setExclusive(true);
b_uttonGroup->hide();
- s_igFile = new QRadioButton( i18n("&Use a signature from file"), this );
+ s_igFile = new TQRadioButton( i18n("&Use a signature from file"), this );
b_uttonGroup->insert(s_igFile, 0);
topL->addMultiCellWidget(s_igFile, 6, 6, 0, 2);
- QWhatsThis::add( s_igFile,
+ TQWhatsThis::add( s_igFile,
i18n( "<qt><p>Mark this to let KNode read the signature from a file.</p></qt>" ) );
s_ig = new KLineEdit(this);
- f_ileName = new QLabel(s_ig, i18n("Signature &file:"), this);
+ f_ileName = new TQLabel(s_ig, i18n("Signature &file:"), this);
topL->addWidget(f_ileName, 7, 0 );
topL->addWidget(s_ig, 7, 1 );
c_ompletion = new KURLCompletion();
s_ig->setCompletionObject(c_ompletion);
msg = i18n( "<qt><p>The file from which the signature will be read.</p>"
"<p>Ex: <b>/home/robt/.sig</b>.</p></qt>" );
- QWhatsThis::add( f_ileName, msg );
- QWhatsThis::add( s_ig, msg );
+ TQWhatsThis::add( f_ileName, msg );
+ TQWhatsThis::add( s_ig, msg );
- c_hooseBtn = new QPushButton( i18n("Choo&se..."), this);
- connect(c_hooseBtn, SIGNAL(clicked()),
- this, SLOT(slotSignatureChoose()));
+ c_hooseBtn = new TQPushButton( i18n("Choo&se..."), this);
+ connect(c_hooseBtn, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotSignatureChoose()));
topL->addWidget(c_hooseBtn, 7, 2 );
- e_ditBtn = new QPushButton( i18n("&Edit File"), this);
- connect(e_ditBtn, SIGNAL(clicked()),
- this, SLOT(slotSignatureEdit()));
+ e_ditBtn = new TQPushButton( i18n("&Edit File"), this);
+ connect(e_ditBtn, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotSignatureEdit()));
topL->addWidget(e_ditBtn, 8, 2);
- s_igGenerator = new QCheckBox(i18n("&The file is a program"), this);
+ s_igGenerator = new TQCheckBox(i18n("&The file is a program"), this);
topL->addMultiCellWidget(s_igGenerator, 8, 8, 0, 1);
msg = i18n( "<qt><p>Mark this option if the signature will be generated by a program</p>"
"<p>Ex: <b>/home/robt/gensig.sh</b>.</p></qt>" );
- QWhatsThis::add( s_igGenerator, msg );
- connect( s_igGenerator, SIGNAL(toggled(bool)), SLOT(changed()) );
+ TQWhatsThis::add( s_igGenerator, msg );
+ connect( s_igGenerator, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()) );
- s_igEdit = new QRadioButton( i18n("Specify signature &below"), this);
+ s_igEdit = new TQRadioButton( i18n("Specify signature &below"), this);
b_uttonGroup->insert(s_igEdit, 1);
topL->addMultiCellWidget(s_igEdit, 9, 9, 0, 2);
- s_igEditor = new QTextEdit(this);
+ s_igEditor = new TQTextEdit(this);
s_igEditor->setTextFormat(Qt::PlainText);
topL->addMultiCellWidget(s_igEditor, 10, 10, 0, 2);
- connect( s_igEditor, SIGNAL(textChanged()), SLOT(changed()) );
+ connect( s_igEditor, TQT_SIGNAL(textChanged()), TQT_SLOT(changed()) );
topL->setColStretch(1,1);
topL->setRowStretch(7,1);
- topL->setResizeMode(QLayout::Minimum);
- connect(s_ig,SIGNAL(textChanged ( const QString & )),
- this,SLOT(textFileNameChanged(const QString &)));
+ topL->setResizeMode(TQLayout::Minimum);
+ connect(s_ig,TQT_SIGNAL(textChanged ( const TQString & )),
+ this,TQT_SLOT(textFileNameChanged(const TQString &)));
load();
}
@@ -182,7 +182,7 @@ KNConfig::IdentityWidget::~IdentityWidget()
delete c_ompletion;
}
-void KNConfig::IdentityWidget::textFileNameChanged(const QString &text)
+void KNConfig::IdentityWidget::textFileNameChanged(const TQString &text)
{
e_ditBtn->setEnabled(!text.isEmpty());
emit changed( true );
@@ -242,7 +242,7 @@ void KNConfig::IdentityWidget::slotSignatureType(int type)
void KNConfig::IdentityWidget::slotSignatureChoose()
{
- QString tmp=KFileDialog::getOpenFileName(c_ompletion->replacedPath(s_ig->text()),QString::null,this,i18n("Choose Signature"));
+ TQString tmp=KFileDialog::getOpenFileName(c_ompletion->replacedPath(s_ig->text()),TQString::null,this,i18n("Choose Signature"));
if(!tmp.isEmpty()) s_ig->setText(tmp);
emit changed( true );
}
@@ -250,14 +250,14 @@ void KNConfig::IdentityWidget::slotSignatureChoose()
void KNConfig::IdentityWidget::slotSignatureEdit()
{
- QString fileName = c_ompletion->replacedPath(s_ig->text()).stripWhiteSpace();
+ TQString fileName = c_ompletion->replacedPath(s_ig->text()).stripWhiteSpace();
if (fileName.isEmpty()) {
KMessageBox::sorry(this, i18n("You must specify a filename."));
return;
}
- QFileInfo fileInfo( fileName );
+ TQFileInfo fileInfo( fileName );
if (fileInfo.isDir()) {
KMessageBox::sorry(this, i18n("You have specified a folder."));
return;
@@ -279,42 +279,42 @@ void KNConfig::IdentityWidget::slotSignatureEdit()
//BEGIN: NNTP account configuration widgets ----------------------------------
-KNConfig::NntpAccountListWidget::NntpAccountListWidget(QWidget *p, const char *n) :
+KNConfig::NntpAccountListWidget::NntpAccountListWidget(TQWidget *p, const char *n) :
KCModule( p, n ),
a_ccManager( knGlobals.accountManager() )
{
p_ixmap = SmallIcon("server");
- QGridLayout *topL=new QGridLayout(this, 6,2, 5,5);
+ TQGridLayout *topL=new TQGridLayout(this, 6,2, 5,5);
// account listbox
l_box=new KNDialogListBox(false, this);
- connect(l_box, SIGNAL(selected(int)), this, SLOT(slotItemSelected(int)));
- connect(l_box, SIGNAL(selectionChanged()), this, SLOT(slotSelectionChanged()));
+ connect(l_box, TQT_SIGNAL(selected(int)), this, TQT_SLOT(slotItemSelected(int)));
+ connect(l_box, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(slotSelectionChanged()));
topL->addMultiCellWidget(l_box, 0,4, 0,0);
// info box
- QGroupBox *gb = new QGroupBox(2,Qt::Vertical,QString::null,this);
+ TQGroupBox *gb = new TQGroupBox(2,Qt::Vertical,TQString::null,this);
topL->addWidget(gb,5,0);
- s_erverInfo = new QLabel(gb);
- p_ortInfo = new QLabel(gb);
+ s_erverInfo = new TQLabel(gb);
+ p_ortInfo = new TQLabel(gb);
// buttons
- a_ddBtn=new QPushButton(i18n("&Add..."), this);
- connect(a_ddBtn, SIGNAL(clicked()), this, SLOT(slotAddBtnClicked()));
+ a_ddBtn=new TQPushButton(i18n("&Add..."), this);
+ connect(a_ddBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAddBtnClicked()));
topL->addWidget(a_ddBtn, 0,1);
- e_ditBtn=new QPushButton(i18n("modify something","&Edit..."), this);
- connect(e_ditBtn, SIGNAL(clicked()), this, SLOT(slotEditBtnClicked()));
+ e_ditBtn=new TQPushButton(i18n("modify something","&Edit..."), this);
+ connect(e_ditBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotEditBtnClicked()));
topL->addWidget(e_ditBtn, 1,1);
- d_elBtn=new QPushButton(i18n("&Delete"), this);
- connect(d_elBtn, SIGNAL(clicked()), this, SLOT(slotDelBtnClicked()));
+ d_elBtn=new TQPushButton(i18n("&Delete"), this);
+ connect(d_elBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDelBtnClicked()));
topL->addWidget(d_elBtn, 2,1);
- s_ubBtn=new QPushButton(i18n("&Subscribe..."), this);
- connect(s_ubBtn, SIGNAL(clicked()), this, SLOT(slotSubBtnClicked()));
+ s_ubBtn=new TQPushButton(i18n("&Subscribe..."), this);
+ connect(s_ubBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSubBtnClicked()));
topL->addWidget(s_ubBtn, 3,1);
topL->setRowStretch(4,1); // stretch the server listbox
@@ -323,9 +323,9 @@ KNConfig::NntpAccountListWidget::NntpAccountListWidget(QWidget *p, const char *n
// the settings dialog is non-modal, so we have to react to changes
// made outside of the dialog
- connect(a_ccManager, SIGNAL(accountAdded(KNNntpAccount*)), this, SLOT(slotAddItem(KNNntpAccount*)));
- connect(a_ccManager, SIGNAL(accountRemoved(KNNntpAccount*)), this, SLOT(slotRemoveItem(KNNntpAccount*)));
- connect(a_ccManager, SIGNAL(accountModified(KNNntpAccount*)), this, SLOT(slotUpdateItem(KNNntpAccount*)));
+ connect(a_ccManager, TQT_SIGNAL(accountAdded(KNNntpAccount*)), this, TQT_SLOT(slotAddItem(KNNntpAccount*)));
+ connect(a_ccManager, TQT_SIGNAL(accountRemoved(KNNntpAccount*)), this, TQT_SLOT(slotRemoveItem(KNNntpAccount*)));
+ connect(a_ccManager, TQT_SIGNAL(accountModified(KNNntpAccount*)), this, TQT_SLOT(slotUpdateItem(KNNntpAccount*)));
slotSelectionChanged(); // disable Delete & Edit initially
}
@@ -339,7 +339,7 @@ KNConfig::NntpAccountListWidget::~NntpAccountListWidget()
void KNConfig::NntpAccountListWidget::load()
{
l_box->clear();
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = a_ccManager->begin(); it != a_ccManager->end(); ++it )
slotAddItem( *it );
}
@@ -460,67 +460,67 @@ void KNConfig::NntpAccountListWidget::slotSubBtnClicked()
//=======================================================================================
-KNConfig::NntpAccountConfDialog::NntpAccountConfDialog(KNNntpAccount *a, QWidget *p, const char *n)
+KNConfig::NntpAccountConfDialog::NntpAccountConfDialog(KNNntpAccount *a, TQWidget *p, const char *n)
: KDialogBase(Tabbed, (a->id()!=-1)? i18n("Properties of %1").arg(a->name()):i18n("New Account"),
Ok|Cancel|Help, Ok, p, n),
a_ccount(a)
{
- QFrame* page=addPage(i18n("Ser&ver"));
- QGridLayout *topL=new QGridLayout(page, 11, 3, 5);
+ TQFrame* page=addPage(i18n("Ser&ver"));
+ TQGridLayout *topL=new TQGridLayout(page, 11, 3, 5);
n_ame=new KLineEdit(page);
- QLabel *l=new QLabel(n_ame,i18n("&Name:"),page);
+ TQLabel *l=new TQLabel(n_ame,i18n("&Name:"),page);
topL->addWidget(l, 0,0);
n_ame->setText(a->name());
topL->addMultiCellWidget(n_ame, 0, 0, 1, 2);
s_erver=new KLineEdit(page);
- l=new QLabel(s_erver,i18n("&Server:"), page);
+ l=new TQLabel(s_erver,i18n("&Server:"), page);
s_erver->setText(a->server());
topL->addWidget(l, 1,0);
topL->addMultiCellWidget(s_erver, 1, 1, 1, 2);
p_ort=new KLineEdit(page);
- l=new QLabel(p_ort, i18n("&Port:"), page);
+ l=new TQLabel(p_ort, i18n("&Port:"), page);
p_ort->setValidator(new KIntValidator(0,65536,this));
- p_ort->setText(QString::number(a->port()));
+ p_ort->setText(TQString::number(a->port()));
topL->addWidget(l, 2,0);
topL->addWidget(p_ort, 2,1);
h_old = new KIntSpinBox(5,1800,5,5,10,page);
- l = new QLabel(h_old,i18n("Hol&d connection for:"), page);
+ l = new TQLabel(h_old,i18n("Hol&d connection for:"), page);
h_old->setSuffix(i18n(" sec"));
h_old->setValue(a->hold());
topL->addWidget(l,3,0);
topL->addWidget(h_old,3,1);
t_imeout = new KIntSpinBox(15,600,5,15,10,page);
- l = new QLabel(t_imeout, i18n("&Timeout:"), page);
+ l = new TQLabel(t_imeout, i18n("&Timeout:"), page);
t_imeout->setValue(a->timeout());
t_imeout->setSuffix(i18n(" sec"));
topL->addWidget(l,4,0);
topL->addWidget(t_imeout,4,1);
- f_etchDes=new QCheckBox(i18n("&Fetch group descriptions"), page);
+ f_etchDes=new TQCheckBox(i18n("&Fetch group descriptions"), page);
f_etchDes->setChecked(a->fetchDescriptions());
topL->addMultiCellWidget(f_etchDes, 5,5, 0,3);
- /*u_seDiskCache=new QCheckBox(i18n("&Cache articles on disk"), page);
+ /*u_seDiskCache=new TQCheckBox(i18n("&Cache articles on disk"), page);
u_seDiskCache->setChecked(a->useDiskCache());
topL->addMultiCellWidget(u_seDiskCache, 6,6, 0,3);*/
- a_uth=new QCheckBox(i18n("Server requires &authentication"), page);
- connect(a_uth, SIGNAL(toggled(bool)), this, SLOT(slotAuthChecked(bool)));
+ a_uth=new TQCheckBox(i18n("Server requires &authentication"), page);
+ connect(a_uth, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotAuthChecked(bool)));
topL->addMultiCellWidget(a_uth, 6,6, 0,3);
u_ser=new KLineEdit(page);
- u_serLabel=new QLabel(u_ser,i18n("&User:"), page);
+ u_serLabel=new TQLabel(u_ser,i18n("&User:"), page);
u_ser->setText(a->user());
topL->addWidget(u_serLabel, 7,0);
topL->addMultiCellWidget(u_ser, 7,7, 1,2);
p_ass=new KLineEdit(page);
- p_assLabel=new QLabel(p_ass, i18n("Pass&word:"), page);
+ p_assLabel=new TQLabel(p_ass, i18n("Pass&word:"), page);
p_ass->setEchoMode(KLineEdit::Password);
if ( a->readyForLogin() )
p_ass->setText(a->pass());
@@ -530,12 +530,12 @@ KNConfig::NntpAccountConfDialog::NntpAccountConfDialog(KNNntpAccount *a, QWidget
topL->addWidget(p_assLabel, 8,0);
topL->addMultiCellWidget(p_ass, 8,8, 1,2);
- i_nterval=new QCheckBox(i18n("Enable &interval news checking"), page);
- connect(i_nterval, SIGNAL(toggled(bool)), this, SLOT(slotIntervalChecked(bool)));
+ i_nterval=new TQCheckBox(i18n("Enable &interval news checking"), page);
+ connect(i_nterval, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotIntervalChecked(bool)));
topL->addMultiCellWidget(i_nterval, 9,9, 0,3);
c_heckInterval=new KIntSpinBox(1,10000,1,1,10,page);
- c_heckIntervalLabel=new QLabel(c_heckInterval, i18n("Check inter&val:"), page);
+ c_heckIntervalLabel=new TQLabel(c_heckInterval, i18n("Check inter&val:"), page);
c_heckInterval->setSuffix(i18n(" min") );
c_heckInterval->setValue(a->checkInterval());
c_heckIntervalLabel->setBuddy(c_heckInterval);
@@ -552,14 +552,14 @@ KNConfig::NntpAccountConfDialog::NntpAccountConfDialog(KNNntpAccount *a, QWidget
i_dWidget=new KNConfig::IdentityWidget(a->identity(), addVBoxPage(i18n("&Identity")));
// per server cleanup configuration
- QFrame* cleanupPage = addPage( i18n("&Cleanup") );
- QVBoxLayout *cleanupLayout = new QVBoxLayout( cleanupPage, KDialog::spacingHint() );
+ TQFrame* cleanupPage = addPage( i18n("&Cleanup") );
+ TQVBoxLayout *cleanupLayout = new TQVBoxLayout( cleanupPage, KDialog::spacingHint() );
mCleanupWidget = new GroupCleanupWidget( a->cleanupConfig(), cleanupPage );
mCleanupWidget->load();
cleanupLayout->addWidget( mCleanupWidget );
cleanupLayout->addStretch( 1 );
- connect( knGlobals.accountManager(), SIGNAL(passwordsChanged()), SLOT(slotPasswordChanged()) );
+ connect( knGlobals.accountManager(), TQT_SIGNAL(passwordsChanged()), TQT_SLOT(slotPasswordChanged()) );
KNHelper::restoreWindowSize("accNewsPropDLG", this, sizeHint());
@@ -629,11 +629,11 @@ void KNConfig::NntpAccountConfDialog::slotPasswordChanged()
//=============================================================================================
-KNConfig::SmtpAccountWidget::SmtpAccountWidget( QWidget *p, const char *n ) :
+KNConfig::SmtpAccountWidget::SmtpAccountWidget( TQWidget *p, const char *n ) :
SmtpAccountWidgetBase( p, n )
{
mAccount = knGlobals.accountManager()->smtp();
- connect( knGlobals.accountManager(), SIGNAL(passwordsChanged()), SLOT(slotPasswordChanged()) );
+ connect( knGlobals.accountManager(), TQT_SIGNAL(passwordsChanged()), TQT_SLOT(slotPasswordChanged()) );
load();
}
@@ -731,8 +731,8 @@ void KNConfig::SmtpAccountWidget::slotPasswordChanged()
//===================================================================================
// code taken from KMail, Copyright (C) 2000 Espen Sand, espen@kde.org
-KNConfig::AppearanceWidget::ColorListItem::ColorListItem( const QString &text, const QColor &color )
- : QListBoxText(text), mColor( color )
+KNConfig::AppearanceWidget::ColorListItem::ColorListItem( const TQString &text, const TQColor &color )
+ : TQListBoxText(text), mColor( color )
{
}
@@ -742,9 +742,9 @@ KNConfig::AppearanceWidget::ColorListItem::~ColorListItem()
}
-void KNConfig::AppearanceWidget::ColorListItem::paint( QPainter *p )
+void KNConfig::AppearanceWidget::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() );
@@ -755,13 +755,13 @@ void KNConfig::AppearanceWidget::ColorListItem::paint( QPainter *p )
}
-int KNConfig::AppearanceWidget::ColorListItem::height(const QListBox *lb ) const
+int KNConfig::AppearanceWidget::ColorListItem::height(const TQListBox *lb ) const
{
return( lb->fontMetrics().lineSpacing()+1 );
}
-int KNConfig::AppearanceWidget::ColorListItem::width(const QListBox *lb ) const
+int KNConfig::AppearanceWidget::ColorListItem::width(const TQListBox *lb ) const
{
return( 30 + lb->fontMetrics().width( text() ) + 6 );
}
@@ -770,10 +770,10 @@ int KNConfig::AppearanceWidget::ColorListItem::width(const QListBox *lb ) const
//===================================================================================
-KNConfig::AppearanceWidget::FontListItem::FontListItem( const QString &name, const QFont &font )
- : QListBoxText(name), f_ont(font)
+KNConfig::AppearanceWidget::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());
}
@@ -782,28 +782,28 @@ KNConfig::AppearanceWidget::FontListItem::~FontListItem()
}
-void KNConfig::AppearanceWidget::FontListItem::setFont(const QFont &font)
+void KNConfig::AppearanceWidget::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 KNConfig::AppearanceWidget::FontListItem::paint( QPainter *p )
+void KNConfig::AppearanceWidget::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 KNConfig::AppearanceWidget::FontListItem::width(const QListBox *lb ) const
+int KNConfig::AppearanceWidget::FontListItem::width(const TQListBox *lb ) const
{
return( lb->fontMetrics().width(fontInfo) + lb->fontMetrics().width(text()) + 20 );
}
@@ -812,38 +812,38 @@ int KNConfig::AppearanceWidget::FontListItem::width(const QListBox *lb ) const
//===================================================================================
-KNConfig::AppearanceWidget::AppearanceWidget( QWidget *p, const char *n ) :
+KNConfig::AppearanceWidget::AppearanceWidget( TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( knGlobals.configManager()->appearance() )
{
- QGridLayout *topL=new QGridLayout(this, 8,2, 5,5);
+ TQGridLayout *topL=new TQGridLayout(this, 8,2, 5,5);
//color-list
c_List = new KNDialogListBox(false, this);
topL->addMultiCellWidget(c_List,1,3,0,0);
- 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"),this);
+ c_olorCB = new TQCheckBox(i18n("&Use custom colors"),this);
topL->addWidget(c_olorCB,0,0);
- connect(c_olorCB, SIGNAL(toggled(bool)), this, SLOT(slotColCheckBoxToggled(bool)));
+ connect(c_olorCB, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotColCheckBoxToggled(bool)));
- c_olChngBtn=new QPushButton(i18n("Cha&nge..."), this);
- connect(c_olChngBtn, SIGNAL(clicked()), this, SLOT(slotColChangeBtnClicked()));
+ c_olChngBtn=new TQPushButton(i18n("Cha&nge..."), this);
+ connect(c_olChngBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotColChangeBtnClicked()));
topL->addWidget(c_olChngBtn,1,1);
//font-list
f_List = new KNDialogListBox(false, this);
topL->addMultiCellWidget(f_List,5,7,0,0);
- 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"),this);
+ f_ontCB = new TQCheckBox(i18n("Use custom &fonts"),this);
topL->addWidget(f_ontCB,4,0);
- connect(f_ontCB, SIGNAL(toggled(bool)), this, SLOT(slotFontCheckBoxToggled(bool)));
+ connect(f_ontCB, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotFontCheckBoxToggled(bool)));
- f_ntChngBtn=new QPushButton(i18n("Chang&e..."), this);
- connect(f_ntChngBtn, SIGNAL(clicked()), this, SLOT(slotFontChangeBtnClicked()));
+ f_ntChngBtn=new TQPushButton(i18n("Chang&e..."), this);
+ connect(f_ntChngBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotFontChangeBtnClicked()));
topL->addWidget(f_ntChngBtn,5,1);
load();
@@ -920,11 +920,11 @@ void KNConfig::AppearanceWidget::slotColCheckBoxToggled(bool b)
// show color dialog for the entry
-void KNConfig::AppearanceWidget::slotColItemSelected(QListBoxItem *it)
+void KNConfig::AppearanceWidget::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) {
@@ -959,11 +959,11 @@ void KNConfig::AppearanceWidget::slotFontCheckBoxToggled(bool b)
// show font dialog for the entry
-void KNConfig::AppearanceWidget::slotFontItemSelected(QListBoxItem *it)
+void KNConfig::AppearanceWidget::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) {
@@ -991,42 +991,42 @@ void KNConfig::AppearanceWidget::slotFontSelectionChanged()
//=============================================================================================
-KNConfig::ReadNewsGeneralWidget::ReadNewsGeneralWidget( ReadNewsGeneral *d, QWidget *p, const char *n ) :
+KNConfig::ReadNewsGeneralWidget::ReadNewsGeneralWidget( ReadNewsGeneral *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QGroupBox *hgb=new QGroupBox(i18n("Article Handling"), this);
- QGroupBox *lgb=new QGroupBox(i18n("Article List"), this);
- QGroupBox *cgb=new QGroupBox(i18n("Memory Consumption"), this);
- QLabel *l1, *l2, *l3;
+ TQGroupBox *hgb=new TQGroupBox(i18n("Article Handling"), this);
+ TQGroupBox *lgb=new TQGroupBox(i18n("Article List"), this);
+ TQGroupBox *cgb=new TQGroupBox(i18n("Memory Consumption"), this);
+ TQLabel *l1, *l2, *l3;
- a_utoCB=new QCheckBox(i18n("Check for new articles a&utomatically"), hgb);
+ a_utoCB=new TQCheckBox(i18n("Check for new articles a&utomatically"), hgb);
m_axFetch=new KIntSpinBox(0, 100000, 1, 0, 10, hgb);
- l1=new QLabel(m_axFetch, i18n("&Maximum number of articles to fetch:"), hgb);
- m_arkCB=new QCheckBox(i18n("Mar&k article as read after:"), hgb);
+ l1=new TQLabel(m_axFetch, i18n("&Maximum number of articles to fetch:"), hgb);
+ m_arkCB=new TQCheckBox(i18n("Mar&k article as read after:"), hgb);
m_arkSecs=new KIntSpinBox(0, 9999, 1, 0, 10, hgb);
- connect(m_arkCB, SIGNAL(toggled(bool)), m_arkSecs, SLOT(setEnabled(bool)));
+ connect(m_arkCB, TQT_SIGNAL(toggled(bool)), m_arkSecs, TQT_SLOT(setEnabled(bool)));
m_arkSecs->setSuffix(i18n(" sec"));
- m_arkCrossCB=new QCheckBox(i18n("Mark c&rossposted articles as read"), hgb);
+ m_arkCrossCB=new TQCheckBox(i18n("Mark c&rossposted articles as read"), hgb);
- s_martScrollingCB=new QCheckBox(i18n("Smart scrolli&ng"), lgb);
- e_xpThrCB=new QCheckBox(i18n("Show &whole thread on expanding"), lgb);
- d_efaultExpandCB=new QCheckBox(i18n("Default to e&xpanded threads"), lgb);
- s_coreCB=new QCheckBox(i18n("Show article &score"), lgb);
- l_inesCB=new QCheckBox(i18n("Show &line count"), lgb);
- u_nreadCB=new QCheckBox(i18n("Show unread count in &thread"), lgb);
+ s_martScrollingCB=new TQCheckBox(i18n("Smart scrolli&ng"), lgb);
+ e_xpThrCB=new TQCheckBox(i18n("Show &whole thread on expanding"), lgb);
+ d_efaultExpandCB=new TQCheckBox(i18n("Default to e&xpanded threads"), lgb);
+ s_coreCB=new TQCheckBox(i18n("Show article &score"), lgb);
+ l_inesCB=new TQCheckBox(i18n("Show &line count"), lgb);
+ u_nreadCB=new TQCheckBox(i18n("Show unread count in &thread"), lgb);
c_ollCacheSize=new KIntSpinBox(0, 99999, 1, 1, 10, cgb);
c_ollCacheSize->setSuffix(" KB");
- l2=new QLabel(c_ollCacheSize, i18n("Cach&e size for headers:"), cgb);
+ l2=new TQLabel(c_ollCacheSize, i18n("Cach&e size for headers:"), cgb);
a_rtCacheSize=new KIntSpinBox(0, 99999, 1, 1, 10, cgb);
a_rtCacheSize->setSuffix(" KB");
- l3=new QLabel(a_rtCacheSize, i18n("Cache si&ze for articles:"), cgb);
+ l3=new TQLabel(a_rtCacheSize, i18n("Cache si&ze for articles:"), cgb);
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
- QGridLayout *hgbL=new QGridLayout(hgb, 5,2, 8,5);
- QVBoxLayout *lgbL=new QVBoxLayout(lgb, 8, 5);
- QGridLayout *cgbL=new QGridLayout(cgb, 3,2, 8,5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
+ TQGridLayout *hgbL=new TQGridLayout(hgb, 5,2, 8,5);
+ TQVBoxLayout *lgbL=new TQVBoxLayout(lgb, 8, 5);
+ TQGridLayout *cgbL=new TQGridLayout(cgb, 3,2, 8,5);
topL->addWidget(hgb);
topL->addWidget(lgb);
@@ -1057,21 +1057,21 @@ KNConfig::ReadNewsGeneralWidget::ReadNewsGeneralWidget( ReadNewsGeneral *d, QWid
cgbL->addWidget(a_rtCacheSize, 2,1);
cgbL->setColStretch(0,1);
- topL->setResizeMode(QLayout::Minimum);
-
- connect(a_utoCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(m_axFetch, SIGNAL(valueChanged(int)), SLOT(changed()));
- connect(m_arkCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(m_arkSecs, SIGNAL(valueChanged(int)), SLOT(changed()));
- connect(m_arkCrossCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(s_martScrollingCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(e_xpThrCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(d_efaultExpandCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(l_inesCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(s_coreCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(u_nreadCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(c_ollCacheSize, SIGNAL(valueChanged(int)), SLOT(changed()));
- connect(a_rtCacheSize, SIGNAL(valueChanged(int)), SLOT(changed()));
+ topL->setResizeMode(TQLayout::Minimum);
+
+ connect(a_utoCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(m_axFetch, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
+ connect(m_arkCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(m_arkSecs, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
+ connect(m_arkCrossCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(s_martScrollingCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(e_xpThrCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(d_efaultExpandCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(l_inesCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(s_coreCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(u_nreadCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(c_ollCacheSize, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
+ connect(a_rtCacheSize, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
load();
}
@@ -1122,56 +1122,56 @@ void KNConfig::ReadNewsGeneralWidget::save()
//=============================================================================================
-KNConfig::ReadNewsNavigationWidget::ReadNewsNavigationWidget( ReadNewsNavigation *d, QWidget *p, const char *n ) :
+KNConfig::ReadNewsNavigationWidget::ReadNewsNavigationWidget( ReadNewsNavigation *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
// ==== Mark All as Read ====================================================
- QGroupBox *gb=new QGroupBox(i18n("\"Mark All as Read\" Triggers Following Actions"), this);
- QVBoxLayout *gbL=new QVBoxLayout(gb, 8, 5);
+ TQGroupBox *gb=new TQGroupBox(i18n("\"Mark All as Read\" Triggers Following Actions"), this);
+ TQVBoxLayout *gbL=new TQVBoxLayout(gb, 8, 5);
topL->addWidget(gb);
gbL->addSpacing(fontMetrics().lineSpacing()-4);
- m_arkAllReadGoNextCB=new QCheckBox(i18n("&Switch to the next group"), gb);
+ m_arkAllReadGoNextCB=new TQCheckBox(i18n("&Switch to the next group"), gb);
gbL->addWidget(m_arkAllReadGoNextCB);
- connect(m_arkAllReadGoNextCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(m_arkAllReadGoNextCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
// ==== Mark Thread as Read =================================================
- gb=new QGroupBox(i18n("\"Mark Thread as Read\" Triggers Following Actions"), this);
- gbL=new QVBoxLayout(gb, 8, 5);
+ gb=new TQGroupBox(i18n("\"Mark Thread as Read\" Triggers Following Actions"), this);
+ gbL=new TQVBoxLayout(gb, 8, 5);
topL->addWidget(gb);
gbL->addSpacing(fontMetrics().lineSpacing()-4);
- m_arkThreadReadCloseThreadCB=new QCheckBox(i18n("Clos&e the current thread"), gb);
+ m_arkThreadReadCloseThreadCB=new TQCheckBox(i18n("Clos&e the current thread"), gb);
gbL->addWidget(m_arkThreadReadCloseThreadCB);
- m_arkThreadReadGoNextCB=new QCheckBox(i18n("Go &to the next unread thread"), gb);
+ m_arkThreadReadGoNextCB=new TQCheckBox(i18n("Go &to the next unread thread"), gb);
gbL->addWidget(m_arkThreadReadGoNextCB);
- connect(m_arkThreadReadCloseThreadCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(m_arkThreadReadGoNextCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(m_arkThreadReadCloseThreadCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(m_arkThreadReadGoNextCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
// ==== Ignore Thread =======================================================
- gb=new QGroupBox(i18n("\"Ignore Thread\" Triggers Following Actions"), this);
- gbL=new QVBoxLayout(gb, 8, 5);
+ gb=new TQGroupBox(i18n("\"Ignore Thread\" Triggers Following Actions"), this);
+ gbL=new TQVBoxLayout(gb, 8, 5);
topL->addWidget(gb);
gbL->addSpacing(fontMetrics().lineSpacing()-4);
- i_gnoreThreadCloseThreadCB=new QCheckBox(i18n("Close the cu&rrent thread"), gb);
+ i_gnoreThreadCloseThreadCB=new TQCheckBox(i18n("Close the cu&rrent thread"), gb);
gbL->addWidget(i_gnoreThreadCloseThreadCB);
- i_gnoreThreadGoNextCB=new QCheckBox(i18n("Go to the next &unread thread"), gb);
+ i_gnoreThreadGoNextCB=new TQCheckBox(i18n("Go to the next &unread thread"), gb);
gbL->addWidget(i_gnoreThreadGoNextCB);
- connect(i_gnoreThreadCloseThreadCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(i_gnoreThreadGoNextCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(i_gnoreThreadCloseThreadCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(i_gnoreThreadGoNextCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
topL->addStretch(1);
- topL->setResizeMode(QLayout::Minimum);
+ topL->setResizeMode(TQLayout::Minimum);
load();
}
@@ -1206,30 +1206,30 @@ void KNConfig::ReadNewsNavigationWidget::save()
//=============================================================================================
-KNConfig::ReadNewsViewerWidget::ReadNewsViewerWidget( ReadNewsViewer *d, QWidget *p, const char *n ) :
+KNConfig::ReadNewsViewerWidget::ReadNewsViewerWidget( ReadNewsViewer *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QGroupBox *appgb=new QGroupBox(i18n("Appearance"), this);
- QGroupBox *agb=new QGroupBox(i18n("Attachments"), this);
- QGroupBox *secbox = new QGroupBox( i18n("Security"), this );
+ TQGroupBox *appgb=new TQGroupBox(i18n("Appearance"), this);
+ TQGroupBox *agb=new TQGroupBox(i18n("Attachments"), this);
+ TQGroupBox *secbox = new TQGroupBox( i18n("Security"), this );
- r_ewrapCB=new QCheckBox(i18n("Re&wrap text when necessary"), appgb);
- r_emoveTrailingCB=new QCheckBox(i18n("Re&move trailing empty lines"), appgb);
- s_igCB=new QCheckBox(i18n("Show sig&nature"), appgb);
- mShowRefBar = new QCheckBox( i18n("Show reference bar"), appgb );
+ r_ewrapCB=new TQCheckBox(i18n("Re&wrap text when necessary"), appgb);
+ r_emoveTrailingCB=new TQCheckBox(i18n("Re&move trailing empty lines"), appgb);
+ s_igCB=new TQCheckBox(i18n("Show sig&nature"), appgb);
+ mShowRefBar = new TQCheckBox( i18n("Show reference bar"), appgb );
q_uoteCharacters=new KLineEdit(appgb);
- QLabel *quoteCharL = new QLabel(q_uoteCharacters, i18n("Recognized q&uote characters:"), appgb);
+ TQLabel *quoteCharL = new TQLabel(q_uoteCharacters, i18n("Recognized q&uote characters:"), appgb);
- o_penAttCB=new QCheckBox(i18n("Open a&ttachments on click"), agb);
- a_ltAttCB=new QCheckBox(i18n("Show alternati&ve contents as attachments"), agb);
+ o_penAttCB=new TQCheckBox(i18n("Open a&ttachments on click"), agb);
+ a_ltAttCB=new TQCheckBox(i18n("Show alternati&ve contents as attachments"), agb);
- mAlwaysShowHTML = new QCheckBox( i18n("Prefer HTML to plain text"), secbox );
+ mAlwaysShowHTML = new TQCheckBox( i18n("Prefer HTML to plain text"), secbox );
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
- QGridLayout *appgbL=new QGridLayout(appgb, 5,2, 8,5);
- QVBoxLayout *agbL=new QVBoxLayout(agb, 8, 5);
- QVBoxLayout *secLayout = new QVBoxLayout( secbox, 8, 5 );
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
+ TQGridLayout *appgbL=new TQGridLayout(appgb, 5,2, 8,5);
+ TQVBoxLayout *agbL=new TQVBoxLayout(agb, 8, 5);
+ TQVBoxLayout *secLayout = new TQVBoxLayout( secbox, 8, 5 );
topL->addWidget(appgb);
topL->addWidget(agb);
@@ -1251,16 +1251,16 @@ KNConfig::ReadNewsViewerWidget::ReadNewsViewerWidget( ReadNewsViewer *d, QWidget
secLayout->addSpacing( fontMetrics().lineSpacing() - 4 );
secLayout->addWidget( mAlwaysShowHTML );
- topL->setResizeMode(QLayout::Minimum);
+ topL->setResizeMode(TQLayout::Minimum);
- connect(r_ewrapCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(r_emoveTrailingCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(s_igCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(q_uoteCharacters, SIGNAL(textChanged(const QString&)), SLOT(changed()));
- connect(o_penAttCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(a_ltAttCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect( mShowRefBar, SIGNAL(toggled(bool)), SLOT(changed()) );
- connect( mAlwaysShowHTML, SIGNAL(toggled(bool)), SLOT(changed()) );
+ connect(r_ewrapCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(r_emoveTrailingCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(s_igCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(q_uoteCharacters, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()));
+ connect(o_penAttCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(a_ltAttCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect( mShowRefBar, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()) );
+ connect( mAlwaysShowHTML, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()) );
load();
}
@@ -1302,38 +1302,38 @@ void KNConfig::ReadNewsViewerWidget::save()
//=============================================================================================
-KNConfig::DisplayedHeadersWidget::DisplayedHeadersWidget( DisplayedHeaders *d, QWidget *p, const char *n ) :
+KNConfig::DisplayedHeadersWidget::DisplayedHeadersWidget( DisplayedHeaders *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
s_ave( false ),
d_ata( d )
{
- QGridLayout *topL=new QGridLayout(this, 7,2, 5,5);
+ TQGridLayout *topL=new TQGridLayout(this, 7,2, 5,5);
//listbox
l_box=new KNDialogListBox(false, this);
- connect(l_box, SIGNAL(selected(int)), this, SLOT(slotItemSelected(int)));
- connect(l_box, SIGNAL(selectionChanged()), this, SLOT(slotSelectionChanged()));
+ connect(l_box, TQT_SIGNAL(selected(int)), this, TQT_SLOT(slotItemSelected(int)));
+ connect(l_box, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(slotSelectionChanged()));
topL->addMultiCellWidget(l_box, 0,6, 0,0);
// buttons
- a_ddBtn=new QPushButton(i18n("&Add..."), this);
- connect(a_ddBtn, SIGNAL(clicked()), this, SLOT(slotAddBtnClicked()));
+ a_ddBtn=new TQPushButton(i18n("&Add..."), this);
+ connect(a_ddBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAddBtnClicked()));
topL->addWidget(a_ddBtn, 0,1);
- d_elBtn=new QPushButton(i18n("&Delete"), this);
- connect(d_elBtn, SIGNAL(clicked()), this, SLOT(slotDelBtnClicked()));
+ d_elBtn=new TQPushButton(i18n("&Delete"), this);
+ connect(d_elBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDelBtnClicked()));
topL->addWidget(d_elBtn, 1,1);
- e_ditBtn=new QPushButton(i18n("modify something","&Edit..."), this);
- connect(e_ditBtn, SIGNAL(clicked()), this, SLOT(slotEditBtnClicked()));
+ e_ditBtn=new TQPushButton(i18n("modify something","&Edit..."), this);
+ connect(e_ditBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotEditBtnClicked()));
topL->addWidget(e_ditBtn, 2,1);
- u_pBtn=new QPushButton(i18n("&Up"), this);
- connect(u_pBtn, SIGNAL(clicked()), this, SLOT(slotUpBtnClicked()));
+ u_pBtn=new TQPushButton(i18n("&Up"), this);
+ connect(u_pBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotUpBtnClicked()));
topL->addWidget(u_pBtn, 4,1);
- d_ownBtn=new QPushButton(i18n("Do&wn"), this);
- connect(d_ownBtn, SIGNAL(clicked()), this, SLOT(slotDownBtnClicked()));
+ d_ownBtn=new TQPushButton(i18n("Do&wn"), this);
+ connect(d_ownBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDownBtnClicked()));
topL->addWidget(d_ownBtn, 5,1);
topL->addRowSpacing(3,20); // separate up/down buttons
@@ -1354,8 +1354,8 @@ KNConfig::DisplayedHeadersWidget::~DisplayedHeadersWidget()
void KNConfig::DisplayedHeadersWidget::load()
{
l_box->clear();
- QValueList<KNDisplayedHeader*> list = d_ata->headers();
- for ( QValueList<KNDisplayedHeader*>::Iterator it = list.begin(); it != list.end(); ++it )
+ TQValueList<KNDisplayedHeader*> list = d_ata->headers();
+ for ( TQValueList<KNDisplayedHeader*>::Iterator it = list.begin(); it != list.end(); ++it )
l_box->insertItem( generateItem( (*it) ) );
}
@@ -1372,7 +1372,7 @@ void KNConfig::DisplayedHeadersWidget::save()
KNConfig::DisplayedHeadersWidget::HdrItem* KNConfig::DisplayedHeadersWidget::generateItem(KNDisplayedHeader *h)
{
- QString text;
+ TQString text;
if(h->hasName()) {
text=h->translatedName();
text+=": <";
@@ -1487,53 +1487,53 @@ void KNConfig::DisplayedHeadersWidget::slotDownBtnClicked()
//=============================================================================================
-KNConfig::DisplayedHeaderConfDialog::DisplayedHeaderConfDialog(KNDisplayedHeader *h, QWidget *p, char *n)
+KNConfig::DisplayedHeaderConfDialog::DisplayedHeaderConfDialog(KNDisplayedHeader *h, TQWidget *p, char *n)
: KDialogBase(Plain, i18n("Header Properties"),Ok|Cancel|Help, Ok, p, n),
h_dr(h)
{
- QFrame* page=plainPage();
- QGridLayout *topL=new QGridLayout(page, 2, 2, 0, 5);
+ TQFrame* page=plainPage();
+ TQGridLayout *topL=new TQGridLayout(page, 2, 2, 0, 5);
- QWidget *nameW = new QWidget(page);
- QGridLayout *nameL=new QGridLayout(nameW, 2, 2, 5);
+ TQWidget *nameW = new TQWidget(page);
+ TQGridLayout *nameL=new TQGridLayout(nameW, 2, 2, 5);
h_drC=new KComboBox(true, nameW);
h_drC->lineEdit()->setMaxLength(64);
- connect(h_drC, SIGNAL(activated(int)), this, SLOT(slotActivated(int)));
- nameL->addWidget(new QLabel(h_drC, i18n("H&eader:"),nameW),0,0);
+ connect(h_drC, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotActivated(int)));
+ nameL->addWidget(new TQLabel(h_drC, i18n("H&eader:"),nameW),0,0);
nameL->addWidget(h_drC,0,1);
n_ameE=new KLineEdit(nameW);
n_ameE->setMaxLength(64);
- nameL->addWidget(new QLabel(n_ameE, i18n("Displayed na&me:"),nameW),1,0);
+ nameL->addWidget(new TQLabel(n_ameE, i18n("Displayed na&me:"),nameW),1,0);
nameL->addWidget(n_ameE,1,1);
nameL->setColStretch(1,1);
topL->addMultiCellWidget(nameW,0,0,0,1);
- QGroupBox *ngb=new QGroupBox(i18n("Name"), page);
+ TQGroupBox *ngb=new TQGroupBox(i18n("Name"), page);
// ### hide style settings for now, the new viewer doesn't support this yet
ngb->hide();
- QVBoxLayout *ngbL = new QVBoxLayout(ngb, 8, 5);
+ TQVBoxLayout *ngbL = new TQVBoxLayout(ngb, 8, 5);
ngbL->setAutoAdd(true);
ngbL->addSpacing(fontMetrics().lineSpacing()-4);
- n_ameCB[0]=new QCheckBox(i18n("&Large"), ngb);
- n_ameCB[1]=new QCheckBox(i18n("&Bold"), ngb);
- n_ameCB[2]=new QCheckBox(i18n("&Italic"), ngb);
- n_ameCB[3]=new QCheckBox(i18n("&Underlined"), ngb);
+ n_ameCB[0]=new TQCheckBox(i18n("&Large"), ngb);
+ n_ameCB[1]=new TQCheckBox(i18n("&Bold"), ngb);
+ n_ameCB[2]=new TQCheckBox(i18n("&Italic"), ngb);
+ n_ameCB[3]=new TQCheckBox(i18n("&Underlined"), ngb);
topL->addWidget(ngb,1,0);
- QGroupBox *vgb=new QGroupBox(i18n("Value"), page);
+ TQGroupBox *vgb=new TQGroupBox(i18n("Value"), page);
// ### hide style settings for now, the new viewer doen't support this yet
vgb->hide();
- QVBoxLayout *vgbL = new QVBoxLayout(vgb, 8, 5);
+ TQVBoxLayout *vgbL = new TQVBoxLayout(vgb, 8, 5);
vgbL->setAutoAdd(true);
vgbL->addSpacing(fontMetrics().lineSpacing()-4);
- v_alueCB[0]=new QCheckBox(i18n("L&arge"), vgb);
- v_alueCB[1]=new QCheckBox(i18n("Bol&d"), vgb);
- v_alueCB[2]=new QCheckBox(i18n("I&talic"), vgb);
- v_alueCB[3]=new QCheckBox(i18n("U&nderlined"), vgb);
+ v_alueCB[0]=new TQCheckBox(i18n("L&arge"), vgb);
+ v_alueCB[1]=new TQCheckBox(i18n("Bol&d"), vgb);
+ v_alueCB[2]=new TQCheckBox(i18n("I&talic"), vgb);
+ v_alueCB[3]=new TQCheckBox(i18n("U&nderlined"), vgb);
topL->addWidget(vgb,1,1);
topL->setColStretch(0,1);
@@ -1551,7 +1551,7 @@ KNConfig::DisplayedHeaderConfDialog::DisplayedHeaderConfDialog(KNDisplayedHeader
setFixedHeight(sizeHint().height());
KNHelper::restoreWindowSize("accReadHdrPropDLG", this, sizeHint());
- connect(n_ameE, SIGNAL(textChanged(const QString&)), SLOT(slotNameChanged(const QString&)));
+ connect(n_ameE, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(slotNameChanged(const TQString&)));
setHelp("anc-knode-headers");
slotNameChanged( n_ameE->text() );
@@ -1587,7 +1587,7 @@ void KNConfig::DisplayedHeaderConfDialog::slotActivated(int pos)
// disable the name format options when the name is empty
-void KNConfig::DisplayedHeaderConfDialog::slotNameChanged(const QString& str)
+void KNConfig::DisplayedHeaderConfDialog::slotNameChanged(const TQString& str)
{
for(int i=0; i<4; i++)
n_ameCB[i]->setEnabled(!str.isEmpty());
@@ -1596,27 +1596,27 @@ void KNConfig::DisplayedHeaderConfDialog::slotNameChanged(const QString& str)
//=============================================================================================
-KNConfig::ScoringWidget::ScoringWidget( Scoring *d, QWidget *p, const char *n ) :
+KNConfig::ScoringWidget::ScoringWidget( Scoring *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QGridLayout *topL = new QGridLayout(this,4,2, 5,5);
+ TQGridLayout *topL = new TQGridLayout(this,4,2, 5,5);
ksc = new KScoringEditorWidget(knGlobals.scoringManager(), this);
topL->addMultiCellWidget(ksc, 0,0, 0,1);
topL->addRowSpacing(1, 10);
i_gnored=new KIntSpinBox(-100000, 100000, 1, 0, 10, this);
- QLabel *l=new QLabel(i_gnored, i18n("Default score for &ignored threads:"), this);
+ TQLabel *l=new TQLabel(i_gnored, i18n("Default score for &ignored threads:"), this);
topL->addWidget(l, 2, 0);
topL->addWidget(i_gnored, 2, 1);
- connect(i_gnored, SIGNAL(valueChanged(int)), SLOT(changed()));
+ connect(i_gnored, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
w_atched=new KIntSpinBox(-100000, 100000, 1, 0, 10, this);
- l=new QLabel(w_atched, i18n("Default score for &watched threads:"), this);
+ l=new TQLabel(w_atched, i18n("Default score for &watched threads:"), this);
topL->addWidget(l, 3, 0);
topL->addWidget(w_atched, 3, 1);
- connect(w_atched, SIGNAL(valueChanged(int)), SLOT(changed()));
+ connect(w_atched, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
topL->setColStretch(0, 1);
@@ -1647,59 +1647,59 @@ void KNConfig::ScoringWidget::save()
//=============================================================================================
-KNConfig::FilterListWidget::FilterListWidget( QWidget *p, const char *n ) :
+KNConfig::FilterListWidget::FilterListWidget( TQWidget *p, const char *n ) :
KCModule( p, n ),
f_ilManager( knGlobals.filterManager() )
{
- QGridLayout *topL=new QGridLayout(this, 6,2, 5,5);
+ TQGridLayout *topL=new TQGridLayout(this, 6,2, 5,5);
// == Filters =================================================
f_lb=new KNDialogListBox(false, this);
- topL->addWidget(new QLabel(f_lb, i18n("&Filters:"),this),0,0);
+ topL->addWidget(new TQLabel(f_lb, i18n("&Filters:"),this),0,0);
- connect(f_lb, SIGNAL(selectionChanged()), SLOT(slotSelectionChangedFilter()));
- connect(f_lb, SIGNAL(selected(int)), SLOT(slotItemSelectedFilter(int)));
+ connect(f_lb, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotSelectionChangedFilter()));
+ connect(f_lb, TQT_SIGNAL(selected(int)), TQT_SLOT(slotItemSelectedFilter(int)));
topL->addMultiCellWidget(f_lb,1,5,0,0);
- a_ddBtn=new QPushButton(i18n("&Add..."), this);
- connect(a_ddBtn, SIGNAL(clicked()), this, SLOT(slotAddBtnClicked()));
+ a_ddBtn=new TQPushButton(i18n("&Add..."), this);
+ connect(a_ddBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAddBtnClicked()));
topL->addWidget(a_ddBtn,1,1);
- e_ditBtn=new QPushButton(i18n("modify something","&Edit..."), this);
- connect(e_ditBtn, SIGNAL(clicked()), this, SLOT(slotEditBtnClicked()));
+ e_ditBtn=new TQPushButton(i18n("modify something","&Edit..."), this);
+ connect(e_ditBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotEditBtnClicked()));
topL->addWidget(e_ditBtn,2,1);
- c_opyBtn=new QPushButton(i18n("Co&py..."), this);
- connect(c_opyBtn, SIGNAL(clicked()), this, SLOT(slotCopyBtnClicked()));
+ c_opyBtn=new TQPushButton(i18n("Co&py..."), this);
+ connect(c_opyBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotCopyBtnClicked()));
topL->addWidget(c_opyBtn,3,1);
- d_elBtn=new QPushButton(i18n("&Delete"), this);
- connect(d_elBtn, SIGNAL(clicked()), this, SLOT(slotDelBtnClicked()));
+ d_elBtn=new TQPushButton(i18n("&Delete"), this);
+ connect(d_elBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDelBtnClicked()));
topL->addWidget(d_elBtn,4,1);
// == Menu ====================================================
m_lb=new KNDialogListBox(false, this);
- topL->addWidget(new QLabel(m_lb, i18n("&Menu:"),this),6,0);
+ topL->addWidget(new TQLabel(m_lb, i18n("&Menu:"),this),6,0);
- connect(m_lb, SIGNAL(selectionChanged()), SLOT(slotSelectionChangedMenu()));
+ connect(m_lb, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotSelectionChangedMenu()));
topL->addMultiCellWidget(m_lb,7,11,0,0);
- u_pBtn=new QPushButton(i18n("&Up"), this);
- connect(u_pBtn, SIGNAL(clicked()), this, SLOT(slotUpBtnClicked()));
+ u_pBtn=new TQPushButton(i18n("&Up"), this);
+ connect(u_pBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotUpBtnClicked()));
topL->addWidget(u_pBtn,7,1);
- d_ownBtn=new QPushButton(i18n("Do&wn"), this);
- connect(d_ownBtn, SIGNAL(clicked()), this, SLOT(slotDownBtnClicked()));
+ d_ownBtn=new TQPushButton(i18n("Do&wn"), this);
+ connect(d_ownBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDownBtnClicked()));
topL->addWidget(d_ownBtn,8,1);
- s_epAddBtn=new QPushButton(i18n("Add\n&Separator"), this);
- connect(s_epAddBtn, SIGNAL(clicked()), this, SLOT(slotSepAddBtnClicked()));
+ s_epAddBtn=new TQPushButton(i18n("Add\n&Separator"), this);
+ connect(s_epAddBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSepAddBtnClicked()));
topL->addWidget(s_epAddBtn,9,1);
- s_epRemBtn=new QPushButton(i18n("&Remove\nSeparator"), this);
- connect(s_epRemBtn, SIGNAL(clicked()), this, SLOT(slotSepRemBtnClicked()));
+ s_epRemBtn=new TQPushButton(i18n("&Remove\nSeparator"), this);
+ connect(s_epRemBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSepRemBtnClicked()));
topL->addWidget(s_epRemBtn,10,1);
topL->setRowStretch(5,1);
@@ -1791,10 +1791,10 @@ void KNConfig::FilterListWidget::removeMenuItem(KNArticleFilter *f)
}
-QValueList<int> KNConfig::FilterListWidget::menuOrder()
+TQValueList<int> KNConfig::FilterListWidget::menuOrder()
{
KNArticleFilter *f;
- QValueList<int> lst;
+ TQValueList<int> lst;
for(uint i=0; i<m_lb->count(); i++) {
f= (static_cast<LBoxItem*>(m_lb->item(i)))->filter;
@@ -1807,7 +1807,7 @@ QValueList<int> KNConfig::FilterListWidget::menuOrder()
}
-int KNConfig::FilterListWidget::findItem(QListBox *l, KNArticleFilter *f)
+int KNConfig::FilterListWidget::findItem(TQListBox *l, KNArticleFilter *f)
{
int idx=0;
bool found=false;
@@ -1929,79 +1929,79 @@ void KNConfig::FilterListWidget::slotSelectionChangedMenu()
//=============================================================================================
-KNConfig::PostNewsTechnicalWidget::PostNewsTechnicalWidget( PostNewsTechnical *d, QWidget *p, const char *n ) :
+KNConfig::PostNewsTechnicalWidget::PostNewsTechnicalWidget( PostNewsTechnical *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
// ==== General =============================================================
- QGroupBox *ggb=new QGroupBox(i18n("General"), this);
- QGridLayout *ggbL=new QGridLayout(ggb, 6,2, 8,5);
+ TQGroupBox *ggb=new TQGroupBox(i18n("General"), this);
+ TQGridLayout *ggbL=new TQGridLayout(ggb, 6,2, 8,5);
topL->addWidget(ggb);
ggbL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
- c_harset=new QComboBox(ggb);
+ c_harset=new TQComboBox(ggb);
c_harset->insertStringList(d->composerCharsets());
- ggbL->addWidget(new QLabel(c_harset, i18n("Cha&rset:"), ggb), 1,0);
+ ggbL->addWidget(new TQLabel(c_harset, i18n("Cha&rset:"), ggb), 1,0);
ggbL->addWidget(c_harset, 1,1);
- connect(c_harset, SIGNAL(activated(int)), SLOT(changed()));
+ connect(c_harset, TQT_SIGNAL(activated(int)), TQT_SLOT(changed()));
- e_ncoding=new QComboBox(ggb);
+ e_ncoding=new TQComboBox(ggb);
e_ncoding->insertItem(i18n("Allow 8-bit"));
e_ncoding->insertItem(i18n("7-bit (Quoted-Printable)"));
- ggbL->addWidget(new QLabel(e_ncoding, i18n("Enco&ding:"), ggb), 2,0);
+ ggbL->addWidget(new TQLabel(e_ncoding, i18n("Enco&ding:"), ggb), 2,0);
ggbL->addWidget(e_ncoding, 2,1);
- connect(e_ncoding, SIGNAL(activated(int)), SLOT(changed()));
+ connect(e_ncoding, TQT_SIGNAL(activated(int)), TQT_SLOT(changed()));
- u_seOwnCSCB=new QCheckBox(i18n("Use o&wn default charset when replying"), ggb);
+ u_seOwnCSCB=new TQCheckBox(i18n("Use o&wn default charset when replying"), ggb);
ggbL->addMultiCellWidget(u_seOwnCSCB, 3,3, 0,1);
- connect(u_seOwnCSCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(u_seOwnCSCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
- g_enMIdCB=new QCheckBox(i18n("&Generate message-id"), ggb);
- connect(g_enMIdCB, SIGNAL(toggled(bool)), this, SLOT(slotGenMIdCBToggled(bool)));
+ g_enMIdCB=new TQCheckBox(i18n("&Generate message-id"), ggb);
+ connect(g_enMIdCB, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotGenMIdCBToggled(bool)));
ggbL->addMultiCellWidget(g_enMIdCB, 4,4, 0,1);
h_ost=new KLineEdit(ggb);
h_ost->setEnabled(false);
- h_ostL=new QLabel(h_ost, i18n("Ho&st name:"), ggb);
+ h_ostL=new TQLabel(h_ost, i18n("Ho&st name:"), ggb);
h_ostL->setEnabled(false);
ggbL->addWidget(h_ostL, 5,0);
ggbL->addWidget(h_ost, 5,1);
ggbL->setColStretch(1,1);
- connect(h_ost, SIGNAL(textChanged(const QString&)), SLOT(changed()));
+ connect(h_ost, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()));
// ==== X-Headers =============================================================
- QGroupBox *xgb=new QGroupBox(i18n("X-Headers"), this);
+ TQGroupBox *xgb=new TQGroupBox(i18n("X-Headers"), this);
topL->addWidget(xgb, 1);
- QGridLayout *xgbL=new QGridLayout(xgb, 7,2, 8,5);
+ TQGridLayout *xgbL=new TQGridLayout(xgb, 7,2, 8,5);
xgbL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
l_box=new KNDialogListBox(false, xgb);
- connect(l_box, SIGNAL(selected(int)), SLOT(slotItemSelected(int)));
- connect(l_box, SIGNAL(selectionChanged()), SLOT(slotSelectionChanged()));
+ connect(l_box, TQT_SIGNAL(selected(int)), TQT_SLOT(slotItemSelected(int)));
+ connect(l_box, TQT_SIGNAL(selectionChanged()), TQT_SLOT(slotSelectionChanged()));
xgbL->addMultiCellWidget(l_box, 1,4, 0,0);
- a_ddBtn=new QPushButton(i18n("&Add..."), xgb);
- connect(a_ddBtn, SIGNAL(clicked()), SLOT(slotAddBtnClicked()));
+ a_ddBtn=new TQPushButton(i18n("&Add..."), xgb);
+ connect(a_ddBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotAddBtnClicked()));
xgbL->addWidget(a_ddBtn, 1,1);
- d_elBtn=new QPushButton(i18n("Dele&te"), xgb);
- connect(d_elBtn, SIGNAL(clicked()), SLOT(slotDelBtnClicked()));
+ d_elBtn=new TQPushButton(i18n("Dele&te"), xgb);
+ connect(d_elBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotDelBtnClicked()));
xgbL->addWidget(d_elBtn, 2,1);
- e_ditBtn=new QPushButton(i18n("modify something","&Edit..."), xgb);
- connect(e_ditBtn, SIGNAL(clicked()), SLOT(slotEditBtnClicked()));
+ e_ditBtn=new TQPushButton(i18n("modify something","&Edit..."), xgb);
+ connect(e_ditBtn, TQT_SIGNAL(clicked()), TQT_SLOT(slotEditBtnClicked()));
xgbL->addWidget(e_ditBtn, 3,1);
- QLabel *placeHolders = new QLabel(i18n("<qt>Placeholders for replies: <b>%NAME</b>=sender's name, <b>%EMAIL</b>=sender's address</qt>"), xgb);
+ TQLabel *placeHolders = new TQLabel(i18n("<qt>Placeholders for replies: <b>%NAME</b>=sender's name, <b>%EMAIL</b>=sender's address</qt>"), xgb);
xgbL->addMultiCellWidget(placeHolders, 5, 5, 0, 1);
- i_ncUaCB=new QCheckBox(i18n("Do not add the \"&User-Agent\" identification header"), xgb);
+ i_ncUaCB=new TQCheckBox(i18n("Do not add the \"&User-Agent\" identification header"), xgb);
xgbL->addMultiCellWidget(i_ncUaCB, 6,6, 0,1);
- connect(i_ncUaCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(i_ncUaCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
xgbL->setRowStretch(4,1);
xgbL->setColStretch(0,1);
@@ -2074,7 +2074,7 @@ void KNConfig::PostNewsTechnicalWidget::slotItemSelected(int)
void KNConfig::PostNewsTechnicalWidget::slotAddBtnClicked()
{
- XHeaderConfDialog *dlg=new XHeaderConfDialog(QString::null, this);
+ XHeaderConfDialog *dlg=new XHeaderConfDialog(TQString::null, this);
if (dlg->exec())
l_box->insertItem(dlg->result());
@@ -2119,16 +2119,16 @@ void KNConfig::PostNewsTechnicalWidget::slotEditBtnClicked()
//===================================================================================================
-KNConfig::XHeaderConfDialog::XHeaderConfDialog(const QString &h, QWidget *p, const char *n)
+KNConfig::XHeaderConfDialog::XHeaderConfDialog(const TQString &h, TQWidget *p, const char *n)
: KDialogBase(Plain, i18n("X-Headers"),Ok|Cancel, Ok, p, n)
{
- QFrame* page=plainPage();
- QHBoxLayout *topL=new QHBoxLayout(page, 5,8);
+ TQFrame* page=plainPage();
+ TQHBoxLayout *topL=new TQHBoxLayout(page, 5,8);
topL->setAutoAdd(true);
- new QLabel("X-", page);
+ new TQLabel("X-", page);
n_ame=new KLineEdit(page);
- new QLabel(":", page);
+ new TQLabel(":", page);
v_alue=new KLineEdit(page);
int pos=h.find(": ", 2);
@@ -2153,95 +2153,95 @@ KNConfig::XHeaderConfDialog::~XHeaderConfDialog()
-QString KNConfig::XHeaderConfDialog::result()
+TQString KNConfig::XHeaderConfDialog::result()
{
- QString value = v_alue->text();
+ TQString value = v_alue->text();
// just in case someone pastes a newline
value.replace( '\n', ' ' );
- return QString( "X-%1: %2" ).arg( n_ame->text() ).arg( value );
+ return TQString( "X-%1: %2" ).arg( n_ame->text() ).arg( value );
}
//===================================================================================================
-KNConfig::PostNewsComposerWidget::PostNewsComposerWidget( PostNewsComposer *d, QWidget *p, const char *n ) :
+KNConfig::PostNewsComposerWidget::PostNewsComposerWidget( PostNewsComposer *d, TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( d )
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
// === general ===========================================================
- QGroupBox *generalB=new QGroupBox(i18n("General"), this);
+ TQGroupBox *generalB=new TQGroupBox(i18n("General"), this);
topL->addWidget(generalB);
- QGridLayout *generalL=new QGridLayout(generalB, 3,3, 8,5);
+ TQGridLayout *generalL=new TQGridLayout(generalB, 3,3, 8,5);
generalL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
- w_ordWrapCB=new QCheckBox(i18n("Word &wrap at column:"), generalB);
+ w_ordWrapCB=new TQCheckBox(i18n("Word &wrap at column:"), generalB);
generalL->addWidget(w_ordWrapCB,1,0);
m_axLen=new KIntSpinBox(20, 200, 1, 20, 10, generalB);
generalL->addWidget(m_axLen,1,2);
- connect(w_ordWrapCB, SIGNAL(toggled(bool)), m_axLen, SLOT(setEnabled(bool)));
- connect(w_ordWrapCB, SIGNAL(toggled(bool)), SLOT(changed()));
- connect(m_axLen, SIGNAL(valueChanged(int)), SLOT(changed()));
+ connect(w_ordWrapCB, TQT_SIGNAL(toggled(bool)), m_axLen, TQT_SLOT(setEnabled(bool)));
+ connect(w_ordWrapCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
+ connect(m_axLen, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
- o_wnSigCB=new QCheckBox(i18n("Appe&nd signature automatically"), generalB);
+ o_wnSigCB=new TQCheckBox(i18n("Appe&nd signature automatically"), generalB);
generalL->addMultiCellWidget(o_wnSigCB,2,2,0,1);
- connect(o_wnSigCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(o_wnSigCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
generalL->setColStretch(1,1);
// === reply =============================================================
- QGroupBox *replyB=new QGroupBox(i18n("Reply"), this);
+ TQGroupBox *replyB=new TQGroupBox(i18n("Reply"), this);
topL->addWidget(replyB);
- QGridLayout *replyL=new QGridLayout(replyB, 7,2, 8,5);
+ TQGridLayout *replyL=new TQGridLayout(replyB, 7,2, 8,5);
replyL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
i_ntro=new KLineEdit(replyB);
- replyL->addMultiCellWidget(new QLabel(i_ntro,i18n("&Introduction phrase:"), replyB),1,1,0,1);
+ replyL->addMultiCellWidget(new TQLabel(i_ntro,i18n("&Introduction phrase:"), replyB),1,1,0,1);
replyL->addMultiCellWidget(i_ntro, 2,2,0,1);
- replyL->addMultiCellWidget(new QLabel(i18n("<qt>Placeholders: <b>%NAME</b>=sender's name, <b>%EMAIL</b>=sender's address,<br><b>%DATE</b>=date, <b>%MSID</b>=message-id, <b>%GROUP</b>=group name, <b>%L</b>=line break</qt>"), replyB),3,3,0,1);
- connect(i_ntro, SIGNAL(textChanged(const QString&)), SLOT(changed()));
+ replyL->addMultiCellWidget(new TQLabel(i18n("<qt>Placeholders: <b>%NAME</b>=sender's name, <b>%EMAIL</b>=sender's address,<br><b>%DATE</b>=date, <b>%MSID</b>=message-id, <b>%GROUP</b>=group name, <b>%L</b>=line break</qt>"), replyB),3,3,0,1);
+ connect(i_ntro, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()));
- r_ewrapCB=new QCheckBox(i18n("Rewrap quoted te&xt automatically"), replyB);
+ r_ewrapCB=new TQCheckBox(i18n("Rewrap quoted te&xt automatically"), replyB);
replyL->addMultiCellWidget(r_ewrapCB, 4,4,0,1);
- connect(r_ewrapCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(r_ewrapCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
- a_uthSigCB=new QCheckBox(i18n("Include the a&uthor's signature"), replyB);
+ a_uthSigCB=new TQCheckBox(i18n("Include the a&uthor's signature"), replyB);
replyL->addMultiCellWidget(a_uthSigCB, 5,5,0,1);
- connect(a_uthSigCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(a_uthSigCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
- c_ursorOnTopCB=new QCheckBox(i18n("Put the cursor &below the introduction phrase"), replyB);
+ c_ursorOnTopCB=new TQCheckBox(i18n("Put the cursor &below the introduction phrase"), replyB);
replyL->addMultiCellWidget(c_ursorOnTopCB, 6,6,0,1);
- connect(c_ursorOnTopCB, SIGNAL(toggled(bool)), SLOT(changed()));
+ connect(c_ursorOnTopCB, TQT_SIGNAL(toggled(bool)), TQT_SLOT(changed()));
replyL->setColStretch(1,1);
// === external editor ========================================================
- QGroupBox *editorB=new QGroupBox(i18n("External Editor"), this);
+ TQGroupBox *editorB=new TQGroupBox(i18n("External Editor"), this);
topL->addWidget(editorB);
- QGridLayout *editorL=new QGridLayout(editorB, 6,3, 8,5);
+ TQGridLayout *editorL=new TQGridLayout(editorB, 6,3, 8,5);
editorL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
e_ditor=new KLineEdit(editorB);
- editorL->addWidget(new QLabel(e_ditor, i18n("Specify edi&tor:"), editorB),1,0);
+ editorL->addWidget(new TQLabel(e_ditor, i18n("Specify edi&tor:"), editorB),1,0);
editorL->addWidget(e_ditor,1,1);
- QPushButton *btn = new QPushButton(i18n("Choo&se..."),editorB);
- connect(btn, SIGNAL(clicked()), SLOT(slotChooseEditor()));
- connect(e_ditor, SIGNAL(textChanged(const QString&)), SLOT(changed()));
+ TQPushButton *btn = new TQPushButton(i18n("Choo&se..."),editorB);
+ connect(btn, TQT_SIGNAL(clicked()), TQT_SLOT(slotChooseEditor()));
+ connect(e_ditor, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(changed()));
editorL->addWidget(btn,1,2);
- editorL->addMultiCellWidget(new QLabel(i18n("%f will be replaced with the filename to edit."), editorB),2,2,0,2);
+ editorL->addMultiCellWidget(new TQLabel(i18n("%f will be replaced with the filename to edit."), editorB),2,2,0,2);
- e_xternCB=new QCheckBox(i18n("Start exte&rnal editor automatically"), editorB);
+ e_xternCB=new TQCheckBox(i18n("Start exte&rnal editor automatically"), editorB);
editorL->addMultiCellWidget(e_xternCB, 3,3,0,2);
- connect(e_xternCB, SIGNAL(clicked()), SLOT(changed()));
+ connect(e_xternCB, TQT_SIGNAL(clicked()), TQT_SLOT(changed()));
editorL->setColStretch(1,1);
@@ -2289,11 +2289,11 @@ void KNConfig::PostNewsComposerWidget::save()
void KNConfig::PostNewsComposerWidget::slotChooseEditor()
{
- QString path=e_ditor->text().simplifyWhiteSpace();
+ TQString path=e_ditor->text().simplifyWhiteSpace();
if (path.right(3) == " %f")
path.truncate(path.length()-3);
- path=KFileDialog::getOpenFileName(path, QString::null, this, i18n("Choose Editor"));
+ path=KFileDialog::getOpenFileName(path, TQString::null, this, i18n("Choose Editor"));
if (!path.isEmpty())
e_ditor->setText(path+" %f");
@@ -2303,14 +2303,14 @@ void KNConfig::PostNewsComposerWidget::slotChooseEditor()
//===================================================================================================
-KNConfig::PostNewsSpellingWidget::PostNewsSpellingWidget( QWidget *p, const char *n ) :
+KNConfig::PostNewsSpellingWidget::PostNewsSpellingWidget( TQWidget *p, const char *n ) :
KCModule( p, n )
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
c_onf = new KSpellConfig( this, "spell", 0, false );
topL->addWidget(c_onf);
- connect(c_onf, SIGNAL(configChanged()), SLOT(changed()));
+ connect(c_onf, TQT_SIGNAL(configChanged()), TQT_SLOT(changed()));
topL->addStretch(1);
}
@@ -2329,13 +2329,13 @@ void KNConfig::PostNewsSpellingWidget::save()
//==============================================================================================================
-KNConfig::PrivacyWidget::PrivacyWidget(QWidget *p, const char *n) :
+KNConfig::PrivacyWidget::PrivacyWidget(TQWidget *p, const char *n) :
KCModule( p, n )
{
- QBoxLayout *topLayout = new QVBoxLayout(this, 5);
+ TQBoxLayout *topLayout = new TQVBoxLayout(this, 5);
c_onf = new Kpgp::Config(this,"knode pgp config",false);
topLayout->addWidget(c_onf);
- connect(c_onf, SIGNAL(changed()), SLOT(changed()));
+ connect(c_onf, TQT_SIGNAL(changed()), TQT_SLOT(changed()));
topLayout->addStretch(1);
@@ -2360,60 +2360,60 @@ void KNConfig::PrivacyWidget::save()
//BEGIN: Cleanup configuration widgets ---------------------------------------
-KNConfig::GroupCleanupWidget::GroupCleanupWidget( Cleanup *data, QWidget *parent, const char *name )
- : QWidget( parent, name ), mData( data )
+KNConfig::GroupCleanupWidget::GroupCleanupWidget( Cleanup *data, TQWidget *parent, const char *name )
+ : TQWidget( parent, name ), mData( data )
{
- QVBoxLayout *top = new QVBoxLayout( this );
+ TQVBoxLayout *top = new TQVBoxLayout( this );
if (!mData->isGlobal()) {
- mDefault = new QCheckBox( i18n("&Use global cleanup configuration"), this );
- connect( mDefault, SIGNAL(toggled(bool)), SLOT(slotDefaultToggled(bool)) );
+ mDefault = new TQCheckBox( i18n("&Use global cleanup configuration"), this );
+ connect( mDefault, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotDefaultToggled(bool)) );
top->addWidget( mDefault );
}
- mExpGroup = new QGroupBox( i18n("Newsgroup Cleanup Settings"), this );
+ mExpGroup = new TQGroupBox( i18n("Newsgroup Cleanup Settings"), this );
mExpGroup->setColumnLayout(0, Qt::Vertical );
mExpGroup->layout()->setSpacing( KDialog::spacingHint() );
mExpGroup->layout()->setMargin( KDialog::marginHint() );
top->addWidget( mExpGroup );
- QGridLayout *grid = new QGridLayout( mExpGroup->layout(), 7, 2 );
+ TQGridLayout *grid = new TQGridLayout( mExpGroup->layout(), 7, 2 );
grid->setRowSpacing( 0, KDialog::spacingHint() );
- mExpEnabled = new QCheckBox( i18n("&Expire old articles automatically"), mExpGroup );
+ mExpEnabled = new TQCheckBox( i18n("&Expire old articles automatically"), mExpGroup );
grid->addMultiCellWidget( mExpEnabled, 1, 1, 0, 1 );
- connect( mExpEnabled, SIGNAL(toggled(bool)), SIGNAL(changed()) );
+ connect( mExpEnabled, TQT_SIGNAL(toggled(bool)), TQT_SIGNAL(changed()) );
mExpDays = new KIntSpinBox( 0, 99999, 1, 0, 10, mExpGroup );
- QLabel *label = new QLabel( mExpDays, i18n("&Purge groups every:"), mExpGroup );
+ TQLabel *label = new TQLabel( mExpDays, i18n("&Purge groups every:"), mExpGroup );
grid->addWidget( label, 2, 0 );
grid->addWidget( mExpDays, 2, 1, Qt::AlignRight );
- connect( mExpDays, SIGNAL(valueChanged(int)), SIGNAL(changed()) );
- connect( mExpDays, SIGNAL(valueChanged(int)), SLOT(expDaysChanged(int)) );
- connect( mExpEnabled, SIGNAL(toggled(bool)), label, SLOT(setEnabled(bool)) );
- connect( mExpEnabled, SIGNAL(toggled(bool)), mExpDays, SLOT(setEnabled(bool)) );
+ connect( mExpDays, TQT_SIGNAL(valueChanged(int)), TQT_SIGNAL(changed()) );
+ connect( mExpDays, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(expDaysChanged(int)) );
+ connect( mExpEnabled, TQT_SIGNAL(toggled(bool)), label, TQT_SLOT(setEnabled(bool)) );
+ connect( mExpEnabled, TQT_SIGNAL(toggled(bool)), mExpDays, TQT_SLOT(setEnabled(bool)) );
mExpReadDays = new KIntSpinBox( 0, 99999, 1, 0, 10, mExpGroup );
- label = new QLabel( mExpReadDays, i18n("&Keep read articles:"), mExpGroup );
+ label = new TQLabel( mExpReadDays, i18n("&Keep read articles:"), mExpGroup );
grid->addWidget( label, 3, 0 );
grid->addWidget( mExpReadDays, 3, 1, Qt::AlignRight );
- connect( mExpReadDays, SIGNAL(valueChanged(int)), SIGNAL(changed()) );
- connect( mExpReadDays, SIGNAL(valueChanged(int)), SLOT(expReadDaysChanged(int)) );
+ connect( mExpReadDays, TQT_SIGNAL(valueChanged(int)), TQT_SIGNAL(changed()) );
+ connect( mExpReadDays, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(expReadDaysChanged(int)) );
mExpUnreadDays = new KIntSpinBox( 0, 99999, 1, 0, 10, mExpGroup );
- label = new QLabel( mExpUnreadDays, i18n("Keep u&nread articles:"), mExpGroup );
+ label = new TQLabel( mExpUnreadDays, i18n("Keep u&nread articles:"), mExpGroup );
grid->addWidget( label, 4, 0 );
grid->addWidget( mExpUnreadDays, 4, 1, Qt::AlignRight );
- connect( mExpUnreadDays, SIGNAL(valueChanged(int)), SIGNAL(changed()) );
- connect( mExpUnreadDays, SIGNAL(valueChanged(int)), SLOT(expUnreadDaysChanged(int)) );
+ connect( mExpUnreadDays, TQT_SIGNAL(valueChanged(int)), TQT_SIGNAL(changed()) );
+ connect( mExpUnreadDays, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(expUnreadDaysChanged(int)) );
- mExpUnavailable = new QCheckBox( i18n("&Remove articles that are not available on the server"), mExpGroup );
+ mExpUnavailable = new TQCheckBox( i18n("&Remove articles that are not available on the server"), mExpGroup );
grid->addMultiCellWidget( mExpUnavailable, 5, 5, 0, 1 );
- connect( mExpUnavailable, SIGNAL(toggled(bool)), SIGNAL(changed()) );
+ connect( mExpUnavailable, TQT_SIGNAL(toggled(bool)), TQT_SIGNAL(changed()) );
- mPreserveThreads = new QCheckBox( i18n("Preser&ve threads"), mExpGroup );
+ mPreserveThreads = new TQCheckBox( i18n("Preser&ve threads"), mExpGroup );
grid->addMultiCellWidget( mPreserveThreads, 6, 6, 0, 1 );
- connect( mPreserveThreads, SIGNAL(toggled(bool)), SIGNAL(changed()) );
+ connect( mPreserveThreads, TQT_SIGNAL(toggled(bool)), TQT_SIGNAL(changed()) );
grid->setColStretch(1,1);
}
@@ -2468,38 +2468,38 @@ void KNConfig::GroupCleanupWidget::slotDefaultToggled( bool state )
}
-KNConfig::CleanupWidget::CleanupWidget( QWidget *p, const char *n ) :
+KNConfig::CleanupWidget::CleanupWidget( TQWidget *p, const char *n ) :
KCModule( p, n ),
d_ata( knGlobals.configManager()->cleanup() )
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
mGroupCleanup = new GroupCleanupWidget( d_ata, this );
topL->addWidget( mGroupCleanup );
- connect( mGroupCleanup, SIGNAL(changed()), SLOT(changed()) );
+ connect( mGroupCleanup, TQT_SIGNAL(changed()), TQT_SLOT(changed()) );
// === folders =========================================================
- QGroupBox *foldersB=new QGroupBox(i18n("Folders"), this);
+ TQGroupBox *foldersB=new TQGroupBox(i18n("Folders"), this);
foldersB->setColumnLayout(0, Qt::Vertical );
foldersB->layout()->setSpacing( KDialog::spacingHint() );
foldersB->layout()->setMargin( KDialog::marginHint() );
topL->addWidget(foldersB);
- QGridLayout *foldersL=new QGridLayout(foldersB->layout(), 3,2);
+ TQGridLayout *foldersL=new TQGridLayout(foldersB->layout(), 3,2);
foldersL->setRowSpacing( 0, KDialog::spacingHint() );
- f_olderCB=new QCheckBox(i18n("Co&mpact folders automatically"), foldersB);
- connect(f_olderCB, SIGNAL(toggled(bool)), this, SLOT(slotFolderCBtoggled(bool)));
+ f_olderCB=new TQCheckBox(i18n("Co&mpact folders automatically"), foldersB);
+ connect(f_olderCB, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotFolderCBtoggled(bool)));
foldersL->addMultiCellWidget(f_olderCB,1,1,0,1);
f_olderDays=new KIntSpinBox(0, 99999, 1, 0, 10, foldersB);
- f_olderDaysL=new QLabel(f_olderDays,i18n("P&urge folders every:"), foldersB);
+ f_olderDaysL=new TQLabel(f_olderDays,i18n("P&urge folders every:"), foldersB);
foldersL->addWidget(f_olderDaysL,2,0);
foldersL->addWidget(f_olderDays,2,1,Qt::AlignRight);
- connect(f_olderDays, SIGNAL(valueChanged(int)), SLOT(changed()));
- connect(f_olderDays, SIGNAL(valueChanged(int)), SLOT(slotFolderDaysChanged(int)));
+ connect(f_olderDays, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(changed()));
+ connect(f_olderDays, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotFolderDaysChanged(int)));
foldersL->setColStretch(1,1);
@@ -2551,22 +2551,22 @@ void KNConfig::CleanupWidget::slotFolderDaysChanged(int value)
//==============================================================================================================
/*
-KNConfig::CacheWidget::CacheWidget(Cache *d, QWidget *p, const char *n)
+KNConfig::CacheWidget::CacheWidget(Cache *d, TQWidget *p, const char *n)
: KCModule p, n), d_ata(d)
{
- QVBoxLayout *topL=new QVBoxLayout(this, 5);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5);
// memory
- QGroupBox *memGB=new QGroupBox(i18n("Memory Cache"), this);
+ TQGroupBox *memGB=new TQGroupBox(i18n("Memory Cache"), this);
topL->addWidget(memGB);
- QGridLayout *memL=new QGridLayout(memGB, 3,2, 8,5);
+ TQGridLayout *memL=new TQGridLayout(memGB, 3,2, 8,5);
memL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
- memL->addWidget(new QLabel(i18n("Max articles to keep:"), memGB), 1,0);
+ memL->addWidget(new TQLabel(i18n("Max articles to keep:"), memGB), 1,0);
m_emMaxArt=new KIntSpinBox(0, 99999, 1, 1, 10, memGB);
memL->addWidget(m_emMaxArt, 1,1);
- memL->addWidget(new QLabel(i18n("Max memory usage:"), memGB), 2,0);
+ memL->addWidget(new TQLabel(i18n("Max memory usage:"), memGB), 2,0);
m_emMaxKB=new KIntSpinBox(0, 99999, 1, 1, 10, memGB);
m_emMaxKB->setSuffix(" KB");
memL->addWidget(m_emMaxKB, 2,1);
@@ -2575,17 +2575,17 @@ KNConfig::CacheWidget::CacheWidget(Cache *d, QWidget *p, const char *n)
// disk
- QGroupBox *diskGB=new QGroupBox(i18n("Disk Cache"), this);
+ TQGroupBox *diskGB=new TQGroupBox(i18n("Disk Cache"), this);
topL->addWidget(diskGB);
- QGridLayout *diskL=new QGridLayout(diskGB, 3,2, 8,5);
+ TQGridLayout *diskL=new TQGridLayout(diskGB, 3,2, 8,5);
diskL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
- d_iskMaxArtL=new QLabel(i18n("Max articles to keep:"), diskGB);
+ d_iskMaxArtL=new TQLabel(i18n("Max articles to keep:"), diskGB);
diskL->addWidget(d_iskMaxArtL, 2,0);
d_iskMaxArt=new KIntSpinBox(0, 99999, 1, 1, 10, diskGB);
diskL->addWidget(d_iskMaxArt, 2,1);
- d_iskMaxKBL=new QLabel(i18n("Max disk usage:"), diskGB);
+ d_iskMaxKBL=new TQLabel(i18n("Max disk usage:"), diskGB);
diskL->addWidget(d_iskMaxKBL, 3,0);
d_iskMaxKB=new KIntSpinBox(0, 99999, 1, 1, 10, diskGB);
d_iskMaxKB->setSuffix(" KB");
diff --git a/knode/knconfigwidgets.h b/knode/knconfigwidgets.h
index 109ea7dc7..0bd604e8c 100644
--- a/knode/knconfigwidgets.h
+++ b/knode/knconfigwidgets.h
@@ -68,27 +68,27 @@ class KDE_EXPORT IdentityWidget : public KCModule {
Q_OBJECT
public:
- IdentityWidget(Identity *d, QWidget *p=0, const char *n=0);
+ IdentityWidget(Identity *d, TQWidget *p=0, const char *n=0);
~IdentityWidget();
void load();
void save();
protected:
- QLabel *f_ileName;
+ TQLabel *f_ileName;
KLineEdit *n_ame,
*o_rga,
*e_mail,
*r_eplyTo,
*m_ailCopiesTo,
*s_ig;
- QRadioButton *s_igFile,
+ TQRadioButton *s_igFile,
*s_igEdit;
- QCheckBox *s_igGenerator;
- QPushButton *c_hooseBtn,
+ TQCheckBox *s_igGenerator;
+ TQPushButton *c_hooseBtn,
*e_ditBtn;
- QTextEdit *s_igEditor;
- QButtonGroup *b_uttonGroup;
+ TQTextEdit *s_igEditor;
+ TQButtonGroup *b_uttonGroup;
Kpgp::SecretKeyRequester
*s_igningKey;
KURLCompletion *c_ompletion;
@@ -99,7 +99,7 @@ class KDE_EXPORT IdentityWidget : public KCModule {
void slotSignatureType(int type);
void slotSignatureChoose();
void slotSignatureEdit();
- void textFileNameChanged(const QString &);
+ void textFileNameChanged(const TQString &);
};
@@ -109,7 +109,7 @@ class KDE_EXPORT NntpAccountListWidget : public KCModule {
Q_OBJECT
public:
- NntpAccountListWidget(QWidget *p=0, const char *n=0);
+ NntpAccountListWidget(TQWidget *p=0, const char *n=0);
~NntpAccountListWidget();
void load();
@@ -117,19 +117,19 @@ class KDE_EXPORT NntpAccountListWidget : public KCModule {
protected:
class LBoxItem : public KNListBoxItem {
public:
- LBoxItem(KNNntpAccount *a, const QString &t, QPixmap *p=0)
+ LBoxItem(KNNntpAccount *a, const TQString &t, TQPixmap *p=0)
: KNListBoxItem(t, p) , account(a) {}
~LBoxItem() {}
KNNntpAccount *account;
};
KNDialogListBox *l_box;
- QPushButton *a_ddBtn,
+ TQPushButton *a_ddBtn,
*d_elBtn,
*e_ditBtn,
*s_ubBtn;
- QPixmap p_ixmap;
- QLabel *s_erverInfo,
+ TQPixmap p_ixmap;
+ TQLabel *s_erverInfo,
*p_ortInfo;
KNAccountManager *a_ccManager;
@@ -156,7 +156,7 @@ class KDE_EXPORT NntpAccountConfDialog : public KDialogBase {
Q_OBJECT
public:
- NntpAccountConfDialog(KNNntpAccount* acc, QWidget *p=0, const char *n=0);
+ NntpAccountConfDialog(KNNntpAccount* acc, TQWidget *p=0, const char *n=0);
~NntpAccountConfDialog();
protected:
@@ -165,13 +165,13 @@ class KDE_EXPORT NntpAccountConfDialog : public KDialogBase {
*u_ser,
*p_ass,
*p_ort;
- QLabel *u_serLabel,
+ TQLabel *u_serLabel,
*p_assLabel,
*c_heckIntervalLabel;
KIntSpinBox *h_old,
*t_imeout,
*c_heckInterval;
- QCheckBox *f_etchDes,
+ TQCheckBox *f_etchDes,
*a_uth,
*u_seDiskCache,
*i_nterval;
@@ -197,7 +197,7 @@ class KDE_EXPORT SmtpAccountWidget : public SmtpAccountWidgetBase {
Q_OBJECT
public:
- SmtpAccountWidget(QWidget *p=0, const char *n=0);
+ SmtpAccountWidget(TQWidget *p=0, const char *n=0);
~SmtpAccountWidget() {}
virtual void load();
@@ -218,7 +218,7 @@ class KDE_EXPORT AppearanceWidget : public KCModule {
Q_OBJECT
public:
- AppearanceWidget(QWidget *p=0, const char *n=0);
+ AppearanceWidget(TQWidget *p=0, const char *n=0);
~AppearanceWidget();
void load();
@@ -228,49 +228,49 @@ class KDE_EXPORT AppearanceWidget : public KCModule {
//===================================================================================
// code taken from KMail, Copyright (C) 2000 Espen Sand, espen@kde.org
- class KDE_EXPORT ColorListItem : public QListBoxText {
+ class KDE_EXPORT ColorListItem : public TQListBoxText {
public:
- ColorListItem( const QString &text, const QColor &color=Qt::black );
+ ColorListItem( const TQString &text, const TQColor &color=Qt::black );
~ColorListItem();
- const QColor& color() { return mColor; }
- void setColor( const QColor &color ) { mColor = color; }
+ const TQColor& color() { return mColor; }
+ void setColor( const TQColor &color ) { mColor = color; }
protected:
- virtual void paint( QPainter * );
- virtual int height( const QListBox * ) const;
- virtual int width( const QListBox * ) const;
+ virtual void paint( TQPainter * );
+ virtual int height( const TQListBox * ) const;
+ virtual int width( const TQListBox * ) const;
private:
- QColor mColor;
+ TQColor mColor;
};
//===================================================================================
- class KDE_EXPORT FontListItem : public QListBoxText {
+ class KDE_EXPORT FontListItem : public TQListBoxText {
public:
- FontListItem( const QString &name, const QFont & );
+ FontListItem( const TQString &name, const TQFont & );
~FontListItem();
- const QFont& font() { return f_ont; }
- void setFont( const QFont &);
+ const TQFont& font() { return f_ont; }
+ void setFont( const TQFont &);
protected:
- virtual void paint( QPainter * );
- virtual int width( const QListBox * ) const;
+ virtual void paint( TQPainter * );
+ virtual int width( const TQListBox * ) const;
private:
- QFont f_ont;
- QString fontInfo;
+ TQFont f_ont;
+ TQString fontInfo;
};
//===================================================================================
KNDialogListBox *c_List,
*f_List;
- QCheckBox *c_olorCB,
+ TQCheckBox *c_olorCB,
*f_ontCB;
- QPushButton *c_olChngBtn,
+ TQPushButton *c_olChngBtn,
*f_ntChngBtn;
Appearance *d_ata;
@@ -278,13 +278,13 @@ class KDE_EXPORT AppearanceWidget : public KCModule {
protected slots:
//colors
void slotColCheckBoxToggled(bool b);
- void slotColItemSelected(QListBoxItem *); // show color dialog for the entry
+ void slotColItemSelected(TQListBoxItem *); // show color dialog for the entry
void slotColChangeBtnClicked();
void slotColSelectionChanged();
//fonts
void slotFontCheckBoxToggled(bool b);
- void slotFontItemSelected(QListBoxItem *); // show font dialog for the entry
+ void slotFontItemSelected(TQListBoxItem *); // show font dialog for the entry
void slotFontChangeBtnClicked();
void slotFontSelectionChanged();
@@ -294,14 +294,14 @@ class KDE_EXPORT AppearanceWidget : public KCModule {
class KDE_EXPORT ReadNewsGeneralWidget : public KCModule {
public:
- ReadNewsGeneralWidget(ReadNewsGeneral *d, QWidget *p=0, const char *n=0);
+ ReadNewsGeneralWidget(ReadNewsGeneral *d, TQWidget *p=0, const char *n=0);
~ReadNewsGeneralWidget();
void load();
void save();
protected:
- QCheckBox *a_utoCB,
+ TQCheckBox *a_utoCB,
*m_arkCB,
*m_arkCrossCB,
*s_martScrollingCB,
@@ -323,14 +323,14 @@ class KDE_EXPORT ReadNewsGeneralWidget : public KCModule {
class KDE_EXPORT ReadNewsNavigationWidget : public KCModule {
public:
- ReadNewsNavigationWidget(ReadNewsNavigation *d, QWidget *p=0, const char *n=0);
+ ReadNewsNavigationWidget(ReadNewsNavigation *d, TQWidget *p=0, const char *n=0);
~ReadNewsNavigationWidget();
void load();
void save();
protected:
- QCheckBox *m_arkAllReadGoNextCB,
+ TQCheckBox *m_arkAllReadGoNextCB,
*m_arkThreadReadGoNextCB,
*m_arkThreadReadCloseThreadCB,
*i_gnoreThreadGoNextCB,
@@ -346,14 +346,14 @@ class KDE_EXPORT ReadNewsViewerWidget : public KCModule {
Q_OBJECT
public:
- ReadNewsViewerWidget(ReadNewsViewer *d, QWidget *p=0, const char *n=0);
+ ReadNewsViewerWidget(ReadNewsViewer *d, TQWidget *p=0, const char *n=0);
~ReadNewsViewerWidget();
void load();
void save();
protected:
- QCheckBox *r_ewrapCB,
+ TQCheckBox *r_ewrapCB,
*r_emoveTrailingCB,
*s_igCB,
*o_penAttCB,
@@ -372,7 +372,7 @@ class KDE_EXPORT DisplayedHeadersWidget : public KCModule {
Q_OBJECT
public:
- DisplayedHeadersWidget(DisplayedHeaders *d, QWidget *p=0, const char *n=0);
+ DisplayedHeadersWidget(DisplayedHeaders *d, TQWidget *p=0, const char *n=0);
~DisplayedHeadersWidget();
void load();
@@ -380,10 +380,10 @@ class KDE_EXPORT DisplayedHeadersWidget : public KCModule {
protected:
- class HdrItem : public QListBoxText {
+ class HdrItem : public TQListBoxText {
public:
- HdrItem( const QString &t, KNDisplayedHeader *h ) : QListBoxText(t), hdr(h) {}
+ HdrItem( const TQString &t, KNDisplayedHeader *h ) : TQListBoxText(t), hdr(h) {}
~HdrItem() {}
KNDisplayedHeader *hdr;
@@ -392,7 +392,7 @@ class KDE_EXPORT DisplayedHeadersWidget : public KCModule {
HdrItem* generateItem(KNDisplayedHeader *);
KNDialogListBox *l_box;
- QPushButton *a_ddBtn,
+ TQPushButton *a_ddBtn,
*d_elBtn,
*e_ditBtn,
*u_pBtn,
@@ -418,7 +418,7 @@ class KDE_EXPORT DisplayedHeaderConfDialog : public KDialogBase {
Q_OBJECT
public:
- DisplayedHeaderConfDialog(KNDisplayedHeader *h, QWidget *p=0, char *n=0);
+ DisplayedHeaderConfDialog(KNDisplayedHeader *h, TQWidget *p=0, char *n=0);
~DisplayedHeaderConfDialog();
@@ -426,14 +426,14 @@ class KDE_EXPORT DisplayedHeaderConfDialog : public KDialogBase {
KNDisplayedHeader *h_dr;
KComboBox *h_drC;
KLineEdit *n_ameE;
- QCheckBox *n_ameCB[4],
+ TQCheckBox *n_ameCB[4],
*v_alueCB[4];
protected slots:
void slotOk();
void slotActivated(int);
- void slotNameChanged(const QString&);
+ void slotNameChanged(const TQString&);
};
@@ -442,7 +442,7 @@ class KDE_EXPORT ScoringWidget : public KCModule {
Q_OBJECT
public:
- ScoringWidget(Scoring *d, QWidget *p=0, const char *n=0);
+ ScoringWidget(Scoring *d, TQWidget *p=0, const char *n=0);
~ScoringWidget();
void load();
@@ -462,7 +462,7 @@ class KDE_EXPORT FilterListWidget : public KCModule {
Q_OBJECT
public:
- FilterListWidget(QWidget *p=0, const char *n=0);
+ FilterListWidget(TQWidget *p=0, const char *n=0);
~FilterListWidget();
void load();
@@ -473,25 +473,25 @@ class KDE_EXPORT FilterListWidget : public KCModule {
void updateItem(KNArticleFilter *f);
void addMenuItem(KNArticleFilter *f);
void removeMenuItem(KNArticleFilter *f);
- QValueList<int> menuOrder();
+ TQValueList<int> menuOrder();
protected:
class LBoxItem : public KNListBoxItem {
public:
- LBoxItem(KNArticleFilter *f, const QString &t, QPixmap *p=0)
+ LBoxItem(KNArticleFilter *f, const TQString &t, TQPixmap *p=0)
: KNListBoxItem(t, p) , filter(f) {}
~LBoxItem() {}
KNArticleFilter *filter;
};
- int findItem(QListBox *l, KNArticleFilter *f);
+ int findItem(TQListBox *l, KNArticleFilter *f);
KNDialogListBox *f_lb,
*m_lb;
- QPushButton *a_ddBtn,
+ TQPushButton *a_ddBtn,
*d_elBtn,
*e_ditBtn,
*c_opyBtn,
@@ -500,7 +500,7 @@ class KDE_EXPORT FilterListWidget : public KCModule {
*s_epAddBtn,
*s_epRemBtn;
- QPixmap a_ctive,
+ TQPixmap a_ctive,
d_isabled;
KNFilterManager *f_ilManager;
@@ -527,24 +527,24 @@ class KDE_EXPORT PostNewsTechnicalWidget : public KCModule {
Q_OBJECT
public:
- PostNewsTechnicalWidget(PostNewsTechnical *d, QWidget *p=0, const char *n=0);
+ PostNewsTechnicalWidget(PostNewsTechnical *d, TQWidget *p=0, const char *n=0);
~PostNewsTechnicalWidget();
void load();
void save();
protected:
- QComboBox *c_harset,
+ TQComboBox *c_harset,
*e_ncoding;
- QCheckBox *u_seOwnCSCB,
+ TQCheckBox *u_seOwnCSCB,
*g_enMIdCB,
*i_ncUaCB;
KNDialogListBox *l_box;
- QPushButton *a_ddBtn,
+ TQPushButton *a_ddBtn,
*d_elBtn,
*e_ditBtn;
KLineEdit *h_ost;
- QLabel *h_ostL;
+ TQLabel *h_ostL;
PostNewsTechnical *d_ata;
@@ -562,10 +562,10 @@ class KDE_EXPORT PostNewsTechnicalWidget : public KCModule {
class KDE_EXPORT XHeaderConfDialog : public KDialogBase {
public:
- XHeaderConfDialog(const QString &h=QString::null, QWidget *p=0, const char *n=0);
+ XHeaderConfDialog(const TQString &h=TQString::null, TQWidget *p=0, const char *n=0);
~XHeaderConfDialog();
- QString result();
+ TQString result();
protected:
@@ -580,7 +580,7 @@ class KDE_EXPORT PostNewsComposerWidget : public KCModule {
Q_OBJECT
public:
- PostNewsComposerWidget(PostNewsComposer *d, QWidget *p=0, const char *n=0);
+ PostNewsComposerWidget(PostNewsComposer *d, TQWidget *p=0, const char *n=0);
~PostNewsComposerWidget();
void load();
@@ -588,7 +588,7 @@ class KDE_EXPORT PostNewsComposerWidget : public KCModule {
protected:
KIntSpinBox *m_axLen;
- QCheckBox *w_ordWrapCB,
+ TQCheckBox *w_ordWrapCB,
*o_wnSigCB,
*r_ewrapCB,
*a_uthSigCB,
@@ -608,7 +608,7 @@ class KDE_EXPORT PostNewsComposerWidget : public KCModule {
class KDE_EXPORT PostNewsSpellingWidget : public KCModule {
public:
- PostNewsSpellingWidget(QWidget *p=0, const char *n=0);
+ PostNewsSpellingWidget(TQWidget *p=0, const char *n=0);
~PostNewsSpellingWidget();
void save();
@@ -625,7 +625,7 @@ class KDE_EXPORT PrivacyWidget : public KCModule {
Q_OBJECT
public:
- PrivacyWidget(QWidget *p=0, const char *n=0);
+ PrivacyWidget(TQWidget *p=0, const char *n=0);
~PrivacyWidget();
void save();
@@ -639,12 +639,12 @@ class KDE_EXPORT PrivacyWidget : public KCModule {
//BEGIN: Cleanup configuration -----------------------------------------------
/** Configuration widget for group expireration */
-class KDE_EXPORT GroupCleanupWidget : public QWidget {
+class KDE_EXPORT GroupCleanupWidget : public TQWidget {
Q_OBJECT
public:
- GroupCleanupWidget( Cleanup *data, QWidget *parent = 0, const char *name = 0 );
+ GroupCleanupWidget( Cleanup *data, TQWidget *parent = 0, const char *name = 0 );
void load();
void save();
@@ -653,9 +653,9 @@ class KDE_EXPORT GroupCleanupWidget : public QWidget {
void changed();
private:
- QCheckBox *mDefault, *mExpEnabled, *mExpUnavailable, *mPreserveThreads;
+ TQCheckBox *mDefault, *mExpEnabled, *mExpUnavailable, *mPreserveThreads;
KIntSpinBox *mExpDays, *mExpReadDays, *mExpUnreadDays;
- QGroupBox *mExpGroup;
+ TQGroupBox *mExpGroup;
Cleanup *mData;
private slots:
@@ -672,16 +672,16 @@ class KDE_EXPORT CleanupWidget : public KCModule {
Q_OBJECT
public:
- CleanupWidget(QWidget *p=0, const char *n=0);
+ CleanupWidget(TQWidget *p=0, const char *n=0);
~CleanupWidget();
void load();
void save();
protected:
- QCheckBox *f_olderCB;
+ TQCheckBox *f_olderCB;
KIntSpinBox *f_olderDays;
- QLabel *f_olderDaysL;
+ TQLabel *f_olderDaysL;
Cleanup *d_ata;
@@ -704,7 +704,7 @@ class KDE_EXPORT CleanupWidget : public KCModule {
Q_OBJECT
public:
- CacheWidget(Cache *d, QWidget *p=0, const char *n=0);
+ CacheWidget(Cache *d, TQWidget *p=0, const char *n=0);
~CacheWidget();
void apply();
@@ -716,7 +716,7 @@ class KDE_EXPORT CleanupWidget : public KCModule {
*d_iskMaxArt,
*d_iskMaxKB;
- QLabel *d_iskMaxArtL,
+ TQLabel *d_iskMaxArtL,
*d_iskMaxKBL;
Cache *d_ata;
diff --git a/knode/knconvert.cpp b/knode/knconvert.cpp
index 40461139b..8fdb4890c 100644
--- a/knode/knconvert.cpp
+++ b/knode/knconvert.cpp
@@ -12,10 +12,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qwidgetstack.h>
-#include <qlabel.h>
-#include <qcheckbox.h>
+#include <tqlayout.h>
+#include <tqwidgetstack.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <kfiledialog.h>
@@ -33,7 +33,7 @@
#include "resource.h"
-bool KNConvert::needToConvert(const QString &oldVersion)
+bool KNConvert::needToConvert(const TQString &oldVersion)
{
bool ret=(
(oldVersion.left(3)=="0.3") ||
@@ -44,31 +44,31 @@ bool KNConvert::needToConvert(const QString &oldVersion)
}
-KNConvert::KNConvert(const QString &version)
- : QDialog(0,0,true), l_ogList(0), c_onversionDone(false), v_ersion(version)
+KNConvert::KNConvert(const TQString &version)
+ : TQDialog(0,0,true), l_ogList(0), c_onversionDone(false), v_ersion(version)
{
setCaption(kapp->makeStdCaption(i18n("Conversion")));
- QVBoxLayout *topL=new QVBoxLayout(this, 5,5);
- s_tack=new QWidgetStack(this);
+ TQVBoxLayout *topL=new TQVBoxLayout(this, 5,5);
+ s_tack=new TQWidgetStack(this);
topL->addWidget(s_tack, 1);
topL->addWidget(new KSeparator(this));
- QHBoxLayout *btnL=new QHBoxLayout(topL, 5);
- s_tartBtn=new QPushButton(i18n("Start Conversion..."), this);
+ TQHBoxLayout *btnL=new TQHBoxLayout(topL, 5);
+ s_tartBtn=new TQPushButton(i18n("Start Conversion..."), this);
s_tartBtn->setDefault(true);
btnL->addStretch(1);
btnL->addWidget(s_tartBtn);
c_ancelBtn=new KPushButton(KStdGuiItem::cancel(), this);
btnL->addWidget(c_ancelBtn);
- connect(s_tartBtn, SIGNAL(clicked()), this, SLOT(slotStart()));
- connect(c_ancelBtn, SIGNAL(clicked()), this, SLOT(reject()));
+ connect(s_tartBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotStart()));
+ connect(c_ancelBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(reject()));
- w_1=new QWidget(s_tack);
+ w_1=new TQWidget(s_tack);
s_tack->addWidget(w_1, 1);
- QGridLayout *w1L=new QGridLayout(w_1, 5,3, 5,5);
+ TQGridLayout *w1L=new TQGridLayout(w_1, 5,3, 5,5);
- QLabel *l1=new QLabel(i18n(
+ TQLabel *l1=new TQLabel(i18n(
"<b>Congratulations, you have upgraded to KNode version %1.</b><br>\
Unfortunately this version uses a different format for some data-files, so \
in order to keep your existing data it is necessary to convert it first. This is \
@@ -76,37 +76,37 @@ now done automatically by KNode. If you want to, a backup of your existing data
will be created before the conversion starts.").arg(KNODE_VERSION), w_1);
w1L->addMultiCellWidget(l1, 0,0, 0,2);
- c_reateBkup=new QCheckBox(i18n("Create backup of old data"), w_1);
+ c_reateBkup=new TQCheckBox(i18n("Create backup of old data"), w_1);
w1L->addMultiCellWidget(c_reateBkup, 2,2, 0,2);
- connect(c_reateBkup, SIGNAL(toggled(bool)), this, SLOT(slotCreateBkupToggled(bool)));
+ connect(c_reateBkup, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotCreateBkupToggled(bool)));
- b_ackupPathLabel=new QLabel(i18n("Save backup in:"), w_1);
+ b_ackupPathLabel=new TQLabel(i18n("Save backup in:"), w_1);
w1L->addWidget(b_ackupPathLabel, 3,0);
- b_ackupPath=new KLineEdit(QDir::homeDirPath()+QString("/knodedata-")+v_ersion+".tar.gz", w_1);
+ b_ackupPath=new KLineEdit(TQDir::homeDirPath()+TQString("/knodedata-")+v_ersion+".tar.gz", w_1);
w1L->addWidget(b_ackupPath, 3,1);
- b_rowseBtn= new QPushButton(i18n("Browse..."), w_1);
- connect(b_rowseBtn, SIGNAL(clicked()), this, SLOT(slotBrowse()));
+ b_rowseBtn= new TQPushButton(i18n("Browse..."), w_1);
+ connect(b_rowseBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotBrowse()));
w1L->addWidget(b_rowseBtn, 3,2);
w1L->setColStretch(1,1);
w1L->addRowSpacing(1,15);
w1L->setRowStretch(4,1);
w1L->addRowSpacing(4,15);
- w_2=new QLabel(s_tack);
+ w_2=new TQLabel(s_tack);
w_2->setText(i18n("<b>Converting, please wait...</b>"));
w_2->setAlignment(AlignCenter);
s_tack->addWidget(w_2, 2);
- w_3=new QWidget(s_tack);
+ w_3=new TQWidget(s_tack);
s_tack->addWidget(w_3, 3);
- QVBoxLayout *w3L=new QVBoxLayout(w_3, 5,5);
+ TQVBoxLayout *w3L=new TQVBoxLayout(w_3, 5,5);
- r_esultLabel=new QLabel(w_3);
+ r_esultLabel=new TQLabel(w_3);
w3L->addWidget(r_esultLabel);
- QLabel *l2=new QLabel(i18n("Processed tasks:"), w_3);
- l_ogList=new QListBox(w_3);
+ TQLabel *l2=new TQLabel(i18n("Processed tasks:"), w_3);
+ l_ogList=new TQListBox(w_3);
w3L->addSpacing(15);
w3L->addWidget(l2);
w3L->addWidget(l_ogList, 1);
@@ -118,7 +118,7 @@ will be created before the conversion starts.").arg(KNODE_VERSION), w_1);
KNConvert::~KNConvert()
{
- for ( QValueList<Converter*>::Iterator it = mConverters.begin(); it != mConverters.end(); ++it )
+ for ( TQValueList<Converter*>::Iterator it = mConverters.begin(); it != mConverters.end(); ++it )
delete (*it);
}
@@ -126,7 +126,7 @@ KNConvert::~KNConvert()
void KNConvert::convert()
{
int errors=0;
- for ( QValueList<Converter*>::Iterator it = mConverters.begin(); it != mConverters.end(); ++it )
+ for ( TQValueList<Converter*>::Iterator it = mConverters.begin(); it != mConverters.end(); ++it )
if( !(*it)->doConvert() )
errors++;
@@ -172,12 +172,12 @@ void KNConvert::slotStart()
return;
}
- QString dataDir=locateLocal("data","knode/");
+ TQString dataDir=locateLocal("data","knode/");
t_ar=new KProcess;
*t_ar << "tar";
*t_ar << "-cz" << dataDir
<< "-f" << b_ackupPath->text();
- connect(t_ar, SIGNAL(processExited(KProcess*)), this, SLOT(slotTarExited(KProcess*)));
+ connect(t_ar, TQT_SIGNAL(processExited(KProcess*)), this, TQT_SLOT(slotTarExited(KProcess*)));
if(!t_ar->start()) {
delete t_ar;
t_ar = 0;
@@ -199,7 +199,7 @@ void KNConvert::slotCreateBkupToggled(bool b)
void KNConvert::slotBrowse()
{
- QString newPath=KFileDialog::getSaveFileName(b_ackupPath->text());
+ TQString newPath=KFileDialog::getSaveFileName(b_ackupPath->text());
if(!newPath.isEmpty())
b_ackupPath->setText(newPath);
@@ -240,12 +240,12 @@ void KNConvert::slotTarExited(KProcess *proc)
bool KNConvert::Converter04::doConvert()
{
- QString dir=locateLocal("data","knode/")+"folders/";
+ TQString dir=locateLocal("data","knode/")+"folders/";
int num;
bool error=false;
//Drafts
- if(QFile::exists(dir+"folder1.idx")) {
+ if(TQFile::exists(dir+"folder1.idx")) {
num=convertFolder(dir+"folder1", dir+"drafts_1");
if(num==-1) {
error=true;
@@ -259,7 +259,7 @@ bool KNConvert::Converter04::doConvert()
l_og->append(i18n("nothing to be done for folder \"Drafts\""));
//Outbox
- if(QFile::exists(dir+"folder2.idx")) {
+ if(TQFile::exists(dir+"folder2.idx")) {
num=convertFolder(dir+"folder2", dir+"outbox_2");
if(num==-1) {
error=true;
@@ -273,7 +273,7 @@ bool KNConvert::Converter04::doConvert()
l_og->append(i18n("nothing to be done for folder \"Outbox\""));
//Sent
- if(QFile::exists(dir+"folder3.idx")) {
+ if(TQFile::exists(dir+"folder3.idx")) {
num=convertFolder(dir+"folder3", dir+"sent_3");
if(num==-1) {
error=true;
@@ -287,20 +287,20 @@ bool KNConvert::Converter04::doConvert()
l_og->append(i18n("nothing to be done for folder \"Sent\""));
//remove old info-files
- QFile::remove(dir+"standard.info");
- QFile::remove(dir+".standard.info");
+ TQFile::remove(dir+"standard.info");
+ TQFile::remove(dir+".standard.info");
return (!error);
}
-int KNConvert::Converter04::convertFolder(QString srcPrefix, QString dstPrefix)
+int KNConvert::Converter04::convertFolder(TQString srcPrefix, TQString dstPrefix)
{
- QFile srcMBox(srcPrefix+".mbox"),
+ TQFile srcMBox(srcPrefix+".mbox"),
srcIdx(srcPrefix+".idx"),
dstMBox(dstPrefix+".mbox"),
dstIdx(dstPrefix+".idx");
- QTextStream ts(&dstMBox);
- ts.setEncoding(QTextStream::Latin1);
+ TQTextStream ts(&dstMBox);
+ ts.setEncoding(TQTextStream::Latin1);
OldFolderIndex oldIdx;
NewFolderIndex newIdx;
@@ -399,7 +399,7 @@ int KNConvert::Converter04::convertFolder(QString srcPrefix, QString dstPrefix)
//read mbox-data
unsigned int size=oldIdx.eo-oldIdx.so;
- QCString buff(size+10);
+ TQCString buff(size+10);
srcMBox.at(oldIdx.so);
int readBytes=srcMBox.readBlock(buff.data(), size);
buff.at(readBytes)='\0'; //terminate string;
diff --git a/knode/knconvert.h b/knode/knconvert.h
index c75e0da00..e81e048a5 100644
--- a/knode/knconvert.h
+++ b/knode/knconvert.h
@@ -17,10 +17,10 @@
#include <time.h>
-#include <qdialog.h>
+#include <tqdialog.h>
-#include <qglobal.h>
-#include <qvaluelist.h>
+#include <tqglobal.h>
+#include <tqvaluelist.h>
#include <kdepimmacros.h>
class QListBox;
@@ -32,14 +32,14 @@ class KLineEdit;
class KProcess;
-class KDE_EXPORT KNConvert : public QDialog {
+class KDE_EXPORT KNConvert : public TQDialog {
Q_OBJECT
public:
- static bool needToConvert(const QString &oldVersion);
+ static bool needToConvert(const TQString &oldVersion);
- KNConvert(const QString &version);
+ KNConvert(const TQString &version);
~KNConvert();
bool conversionDone()const { return c_onversionDone; }
@@ -52,12 +52,12 @@ class KDE_EXPORT KNConvert : public QDialog {
class Converter {
public:
- Converter(QStringList *log) { l_og=log; }
+ Converter(TQStringList *log) { l_og=log; }
virtual ~Converter() {}
virtual bool doConvert()=0;
protected:
- QStringList *l_og;
+ TQStringList *l_og;
};
@@ -65,12 +65,12 @@ class KDE_EXPORT KNConvert : public QDialog {
class Converter04 : public Converter {
public:
- Converter04(QStringList *log) : Converter(log) {}
+ Converter04(TQStringList *log) : Converter(log) {}
~Converter04() {}
bool doConvert();
protected:
- int convertFolder(QString srcPrefix, QString dstPrefix);
+ int convertFolder(TQString srcPrefix, TQString dstPrefix);
struct OldFolderIndex {
int id,
@@ -93,23 +93,23 @@ class KDE_EXPORT KNConvert : public QDialog {
//------------ </Converter-classes> --------------
- QWidgetStack *s_tack;
- QWidget *w_1,
+ TQWidgetStack *s_tack;
+ TQWidget *w_1,
*w_3;
- QCheckBox *c_reateBkup;
- QLabel *b_ackupPathLabel,
+ TQCheckBox *c_reateBkup;
+ TQLabel *b_ackupPathLabel,
*w_2,
*r_esultLabel;
KLineEdit *b_ackupPath;
- QPushButton *b_rowseBtn,
+ TQPushButton *b_rowseBtn,
*s_tartBtn,
*c_ancelBtn;
- QListBox *l_ogList;
+ TQListBox *l_ogList;
- QValueList<Converter*> mConverters;
- QStringList l_og;
+ TQValueList<Converter*> mConverters;
+ TQStringList l_og;
bool c_onversionDone;
- QString v_ersion;
+ TQString v_ersion;
KProcess *t_ar;
void convert();
diff --git a/knode/kndisplayedheader.cpp b/knode/kndisplayedheader.cpp
index 589bd0027..cf25d57ef 100644
--- a/knode/kndisplayedheader.cpp
+++ b/knode/kndisplayedheader.cpp
@@ -85,7 +85,7 @@ const char** KNDisplayedHeader::predefs()
// *tries* to translate the name
-QString KNDisplayedHeader::translatedName()
+TQString KNDisplayedHeader::translatedName()
{
if (t_ranslateName) {
// major hack alert !!!
@@ -95,19 +95,19 @@ QString KNDisplayedHeader::translatedName()
else
return n_ame;
} else
- return QString::null;
+ return TQString::null;
} else
return n_ame;
}
// *tries* to retranslate the name to english
-void KNDisplayedHeader::setTranslatedName(const QString &s)
+void KNDisplayedHeader::setTranslatedName(const TQString &s)
{
bool retranslated = false;
for (const char **c=predef;(*c)!=0;c++) { // ok, first the standard header names
if (s==i18n("collection of article headers",*c)) {
- n_ame = QString::fromLatin1(*c);
+ n_ame = TQString::fromLatin1(*c);
retranslated = true;
break;
}
@@ -116,7 +116,7 @@ void KNDisplayedHeader::setTranslatedName(const QString &s)
if (!retranslated) {
for (const char **c=disp;(*c)!=0;c++) // now our standard display names
if (s==i18n("collection of article headers",*c)) {
- n_ame = QString::fromLatin1(*c);
+ n_ame = TQString::fromLatin1(*c);
retranslated = true;
break;
}
@@ -135,7 +135,7 @@ void KNDisplayedHeader::createTags()
const char *tokens[] = { "<big>","</big>","<b>","</b>",
"<i>","</i>","<u>","</u>" };
- for(int i=0; i<4; i++) t_ags[i]=QString::null;
+ for(int i=0; i<4; i++) t_ags[i]=TQString::null;
if(f_lags.at(0)) { // <big>
t_ags[0]=tokens[0];
diff --git a/knode/kndisplayedheader.h b/knode/kndisplayedheader.h
index 84f260e58..5f639740c 100644
--- a/knode/kndisplayedheader.h
+++ b/knode/kndisplayedheader.h
@@ -15,7 +15,7 @@
#ifndef KNDISPLAYEDHEADER_H
#define KNDISPLAYEDHEADER_H
-#include <qbitarray.h>
+#include <tqbitarray.h>
class KNDisplayedHeader {
@@ -28,19 +28,19 @@ class KNDisplayedHeader {
static const char** predefs();
//name
- const QString& name() { return n_ame; }
- void setName(const QString &s) { n_ame = s; }
+ const TQString& name() { return n_ame; }
+ void setName(const TQString &s) { n_ame = s; }
bool hasName() const { return !n_ame.isEmpty(); }
//translated name
- QString translatedName(); // *tries* to translate the name
- void setTranslatedName(const QString &s); // *tries* to retranslate the name to english
+ TQString translatedName(); // *tries* to translate the name
+ void setTranslatedName(const TQString &s); // *tries* to retranslate the name to english
void setTranslateName(bool b) { t_ranslateName=b; }
bool translateName() const { return t_ranslateName; }
//header
- const QString& header() { return h_eader; }
- void setHeader(const QString &s) { h_eader = s; }
+ const TQString& header() { return h_eader; }
+ void setHeader(const TQString &s) { h_eader = s; }
//flags
bool flag(int i) { return f_lags.at(i); }
@@ -48,15 +48,15 @@ class KNDisplayedHeader {
//HTML-tags
void createTags();
- const QString& nameOpenTag() { return t_ags[0]; }
- const QString& nameCloseTag() { return t_ags[1]; }
- const QString& headerOpenTag() { return t_ags[2]; }
- const QString& headerCloseTag() { return t_ags[3]; }
+ const TQString& nameOpenTag() { return t_ags[0]; }
+ const TQString& nameCloseTag() { return t_ags[1]; }
+ const TQString& headerOpenTag() { return t_ags[2]; }
+ const TQString& headerCloseTag() { return t_ags[3]; }
protected:
bool t_ranslateName;
- QString n_ame, h_eader, t_ags[4];
- QBitArray f_lags;
+ TQString n_ame, h_eader, t_ags[4];
+ TQBitArray f_lags;
};
diff --git a/knode/knfilterconfigwidget.cpp b/knode/knfilterconfigwidget.cpp
index 2a7a8cc47..3c7daee1e 100644
--- a/knode/knfilterconfigwidget.cpp
+++ b/knode/knfilterconfigwidget.cpp
@@ -14,8 +14,8 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qlabel.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
#include <klocale.h>
@@ -25,23 +25,23 @@
#include "knfilterconfigwidget.h"
-KNFilterConfigWidget::KNFilterConfigWidget(QWidget *parent, const char *name ) :
- QTabWidget(parent,name)
+KNFilterConfigWidget::KNFilterConfigWidget(TQWidget *parent, const char *name ) :
+ TQTabWidget(parent,name)
{
- QWidget *sf, *idW, *add;
- sf=new QWidget(this);
- QVBoxLayout *sfL=new QVBoxLayout(sf, 8,5);
+ TQWidget *sf, *idW, *add;
+ sf=new TQWidget(this);
+ TQVBoxLayout *sfL=new TQVBoxLayout(sf, 8,5);
subject=new KNStringFilterWidget(i18n("Subject"), sf);
sfL->addWidget(subject);
from=new KNStringFilterWidget(i18n("From"), sf);
sfL->addWidget(from);
- QLabel *l = new QLabel(i18n("The following placeholders are supported:\n%MYNAME=own name, %MYEMAIL=own email address"),sf);
+ TQLabel *l = new TQLabel(i18n("The following placeholders are supported:\n%MYNAME=own name, %MYEMAIL=own email address"),sf);
sfL->addWidget(l);
sfL->addStretch(1);
addTab(sf, i18n("Subject && &From"));
- idW=new QWidget(this);
- QVBoxLayout *idL=new QVBoxLayout(idW, 8,5);
+ idW=new TQWidget(this);
+ TQVBoxLayout *idL=new TQVBoxLayout(idW, 8,5);
messageId=new KNStringFilterWidget(i18n("Message-ID"), idW);
idL->addWidget(messageId);
references=new KNStringFilterWidget(i18n("References"), idW);
@@ -52,8 +52,8 @@ KNFilterConfigWidget::KNFilterConfigWidget(QWidget *parent, const char *name ) :
status=new KNStatusFilterWidget(this);
addTab(status, i18n("&Status"));
- add=new QWidget(this);
- QVBoxLayout *addL=new QVBoxLayout(add, 8,5);
+ add=new TQWidget(this);
+ TQVBoxLayout *addL=new TQVBoxLayout(add, 8,5);
score=new KNRangeFilterWidget(i18n("Score"), -99999, 99999, add);
addL->addWidget(score);
age=new KNRangeFilterWidget(i18n("Age"), 0, 999, add, i18n(" days"));
diff --git a/knode/knfilterconfigwidget.h b/knode/knfilterconfigwidget.h
index 7cafa18db..8d87d53fa 100644
--- a/knode/knfilterconfigwidget.h
+++ b/knode/knfilterconfigwidget.h
@@ -17,14 +17,14 @@
#ifndef KNFILTERCONFIGWIDGET_H
#define KNFILTERCONFIGWIDGET_H
-#include <qtabwidget.h>
+#include <tqtabwidget.h>
class KNStatusFilterWidget;
class KNStringFilterWidget;
class KNRangeFilterWidget;
-class KNFilterConfigWidget : public QTabWidget {
+class KNFilterConfigWidget : public TQTabWidget {
Q_OBJECT
@@ -32,7 +32,7 @@ class KNFilterConfigWidget : public QTabWidget {
friend class KNSearchDialog;
public:
- KNFilterConfigWidget(QWidget *parent=0, const char *name=0);
+ KNFilterConfigWidget(TQWidget *parent=0, const char *name=0);
~KNFilterConfigWidget();
void reset();
diff --git a/knode/knfilterdialog.cpp b/knode/knfilterdialog.cpp
index e363e6ad0..e9ebf66e1 100644
--- a/knode/knfilterdialog.cpp
+++ b/knode/knfilterdialog.cpp
@@ -14,9 +14,9 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlabel.h>
-#include <qcheckbox.h>
-#include <qlayout.h>
+#include <tqlabel.h>
+#include <tqcheckbox.h>
+#include <tqlayout.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -30,25 +30,25 @@
#include "knfilterdialog.h"
-KNFilterDialog::KNFilterDialog(KNArticleFilter *f, QWidget *parent, const char *name)
+KNFilterDialog::KNFilterDialog(KNArticleFilter *f, TQWidget *parent, const char *name)
: KDialogBase(Plain, (f->id()==-1)? i18n("New Filter"):i18n("Properties of %1").arg(f->name()),
Ok|Cancel|Help, Ok, parent, name),
fltr(f)
{
- QFrame* page=plainPage();
+ TQFrame* page=plainPage();
- QGroupBox *gb=new QGroupBox(page);
+ TQGroupBox *gb=new TQGroupBox(page);
fname=new KLineEdit(gb);
- QLabel *l1=new QLabel(fname, i18n("Na&me:"), gb);
- apon=new QComboBox(gb);
+ TQLabel *l1=new TQLabel(fname, i18n("Na&me:"), gb);
+ apon=new TQComboBox(gb);
apon->insertItem(i18n("Single Articles"));
apon->insertItem(i18n("Whole Threads"));
- QLabel *l2=new QLabel(apon, i18n("Apply o&n:"), gb);
- enabled=new QCheckBox(i18n("Sho&w in menu"), gb);
+ TQLabel *l2=new TQLabel(apon, i18n("Apply o&n:"), gb);
+ enabled=new TQCheckBox(i18n("Sho&w in menu"), gb);
fw=new KNFilterConfigWidget(page);
- QGridLayout *gbL=new QGridLayout(gb, 2,4,8,5);
+ TQGridLayout *gbL=new TQGridLayout(gb, 2,4,8,5);
gbL->addWidget(l1, 0,0);
gbL->addMultiCellWidget(fname, 0,0,1,3);
gbL->addWidget(enabled, 1,0);
@@ -56,7 +56,7 @@ KNFilterDialog::KNFilterDialog(KNArticleFilter *f, QWidget *parent, const char *
gbL->addWidget(apon, 1,3);
gbL->setColStretch(1,1);
- QVBoxLayout *topL=new QVBoxLayout(page,0,5);
+ TQVBoxLayout *topL=new TQVBoxLayout(page,0,5);
topL->addWidget(gb);
topL->addWidget(fw,1);
@@ -78,7 +78,7 @@ KNFilterDialog::KNFilterDialog(KNArticleFilter *f, QWidget *parent, const char *
KNHelper::restoreWindowSize("filterDLG", this, sizeHint());
setHelp("anc-using-filters");
- connect( fname, SIGNAL( textChanged ( const QString & )), this, SLOT( slotTextChanged( const QString & )));
+ connect( fname, TQT_SIGNAL( textChanged ( const TQString & )), this, TQT_SLOT( slotTextChanged( const TQString & )));
slotTextChanged( fname->text() );
}
@@ -89,7 +89,7 @@ KNFilterDialog::~KNFilterDialog()
KNHelper::saveWindowSize("filterDLG", size());
}
-void KNFilterDialog::slotTextChanged( const QString &_text )
+void KNFilterDialog::slotTextChanged( const TQString &_text )
{
enableButtonOK( !_text.isEmpty() );
}
diff --git a/knode/knfilterdialog.h b/knode/knfilterdialog.h
index a7dcbfebf..ca7dc493e 100644
--- a/knode/knfilterdialog.h
+++ b/knode/knfilterdialog.h
@@ -33,7 +33,7 @@ class KNFilterDialog : public KDialogBase {
friend class KNFilterManager;
public:
- KNFilterDialog(KNArticleFilter *f=0, QWidget *parent=0, const char *name=0);
+ KNFilterDialog(KNArticleFilter *f=0, TQWidget *parent=0, const char *name=0);
~KNFilterDialog();
KNArticleFilter* filter() { return fltr; }
@@ -41,14 +41,14 @@ class KNFilterDialog : public KDialogBase {
protected:
KNFilterConfigWidget *fw;
KLineEdit *fname;
- QComboBox *apon;
- QCheckBox *enabled;
+ TQComboBox *apon;
+ TQCheckBox *enabled;
KNArticleFilter *fltr;
protected slots:
void slotOk();
- void slotTextChanged( const QString & );
+ void slotTextChanged( const TQString & );
};
#endif
diff --git a/knode/knfiltermanager.cpp b/knode/knfiltermanager.cpp
index ce8469512..be57996f9 100644
--- a/knode/knfiltermanager.cpp
+++ b/knode/knfiltermanager.cpp
@@ -29,12 +29,12 @@
#include "knconfigwidgets.h"
-KNFilterSelectAction::KNFilterSelectAction( const QString& text, const QString& pix,
- QObject* parent, const char *name )
+KNFilterSelectAction::KNFilterSelectAction( const TQString& text, const TQString& pix,
+ TQObject* parent, const char *name )
: KActionMenu(text,pix,parent,name), currentItem(-42)
{
popupMenu()->setCheckable(true);
- connect(popupMenu(),SIGNAL(activated(int)),this,SLOT(slotMenuActivated(int)));
+ connect(popupMenu(),TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotMenuActivated(int)));
setDelayed(false);
}
@@ -61,8 +61,8 @@ void KNFilterSelectAction::slotMenuActivated(int id)
//==============================================================================
-KNFilterManager::KNFilterManager(QObject * parent, const char * name)
- : QObject(parent,name), fset(0), currFilter(0), a_ctFilter(0)
+KNFilterManager::KNFilterManager(TQObject * parent, const char * name)
+ : TQObject(parent,name), fset(0), currFilter(0), a_ctFilter(0)
{
loadFilters();
@@ -75,7 +75,7 @@ KNFilterManager::KNFilterManager(QObject * parent, const char * name)
KNFilterManager::~KNFilterManager()
{
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
delete (*it);
}
@@ -104,15 +104,15 @@ void KNFilterManager::prepareShutdown()
void KNFilterManager::loadFilters()
{
- QString fname(locate("data","knode/filters/filters.rc") );
+ TQString fname(locate("data","knode/filters/filters.rc") );
if (!fname.isNull()) {
KSimpleConfig conf(fname,true);
- QValueList<int> activeFilters = conf.readIntListEntry("Active");
+ TQValueList<int> activeFilters = conf.readIntListEntry("Active");
menuOrder = conf.readIntListEntry("Menu");
- QValueList<int>::Iterator it = activeFilters.begin();
+ TQValueList<int>::Iterator it = activeFilters.begin();
while (it != activeFilters.end()) {
KNArticleFilter *f=new KNArticleFilter((*it));
if (f->loadInfo())
@@ -129,15 +129,15 @@ void KNFilterManager::loadFilters()
void KNFilterManager::saveFilterLists()
{
- QString dir(locateLocal("data","knode/")+"filters/");
+ TQString dir(locateLocal("data","knode/")+"filters/");
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
}
KSimpleConfig conf(dir+"filters.rc");
- QValueList<int> activeFilters;
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ TQValueList<int> activeFilters;
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
activeFilters << (*it)->id();
conf.writeEntry("Active",activeFilters);
@@ -151,10 +151,10 @@ void KNFilterManager::startConfig(KNConfig::FilterListWidget *fs)
fset=fs;
commitNeeded = false;
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
fset->addItem( (*it) );
- QValueList<int>::Iterator it = menuOrder.begin();
+ TQValueList<int>::Iterator it = menuOrder.begin();
while (it != menuOrder.end()) {
if ((*it)!=-1)
fset->addMenuItem(byID((*it)));
@@ -200,9 +200,9 @@ void KNFilterManager::newFilter()
void KNFilterManager::addFilter(KNArticleFilter *f)
{
if ( f->id() == -1 ) { // new filter, find suitable ID
- QValueList<int> activeFilters;
+ TQValueList<int> activeFilters;
// ok, this is a ugly hack: we want to reuse old id's, so we try to find the first unused id
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
activeFilters << (*it)->id();
int newId = 1;
while ( activeFilters.contains( newId ) > 0 )
@@ -262,7 +262,7 @@ void KNFilterManager::copyFilter(KNArticleFilter *f)
void KNFilterManager::deleteFilter(KNArticleFilter *f)
{
if ( KMessageBox::warningContinueCancel( fset ? fset : knGlobals.topWidget,
- i18n("Do you really want to delete this filter?"), QString::null, KGuiItem( i18n("&Delete"), "editdelete" ) )
+ i18n("Do you really want to delete this filter?"), TQString::null, KGuiItem( i18n("&Delete"), "editdelete" ) )
== KMessageBox::Continue ) {
if ( mFilterList.remove( f ) ) { // does not delete surplus config files
if ( fset ) { // we reuse ids to reduce the number of dead files
@@ -278,9 +278,9 @@ void KNFilterManager::deleteFilter(KNArticleFilter *f)
}
-bool KNFilterManager::newNameIsOK(KNArticleFilter *f, const QString &newName)
+bool KNFilterManager::newNameIsOK(KNArticleFilter *f, const TQString &newName)
{
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
if ( (*it) != f && newName == (*it)->translatedName() )
return false;
@@ -309,7 +309,7 @@ KNArticleFilter* KNFilterManager::setFilter(const int id)
KNArticleFilter* KNFilterManager::byID(int id)
{
- for ( QValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
+ for ( TQValueList<KNArticleFilter*>::Iterator it = mFilterList.begin(); it != mFilterList.end(); ++it )
if ( (*it)->id() == id )
return (*it);
@@ -326,7 +326,7 @@ void KNFilterManager::updateMenu()
a_ctFilter->popupMenu()->clear();
KNArticleFilter *f=0;
- QValueList<int>::Iterator it = menuOrder.begin();
+ TQValueList<int>::Iterator it = menuOrder.begin();
while (it != menuOrder.end()) {
if ((*it)!=-1) {
if ((f=byID((*it))))
@@ -354,10 +354,10 @@ void KNFilterManager::slotMenuActivated(int id)
void KNFilterManager::slotShowFilterChooser()
{
KNArticleFilter *f=0;
- QStringList items;
- QValueList<int> ids;
+ TQStringList items;
+ TQValueList<int> ids;
- QValueList<int>::Iterator it = menuOrder.begin();
+ TQValueList<int>::Iterator it = menuOrder.begin();
while (it != menuOrder.end()) {
if ((*it)!=-1)
if ((f=byID((*it)))) {
@@ -383,10 +383,10 @@ void KNFilterManager::setMenuAction(KNFilterSelectAction *a, KAction *keybA)
{
if(a) {
a_ctFilter = a;
- connect(a_ctFilter, SIGNAL(activated(int)), this, SLOT(slotMenuActivated(int)));
+ connect(a_ctFilter, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotMenuActivated(int)));
}
if(keybA)
- connect(keybA, SIGNAL(activated()), this, SLOT(slotShowFilterChooser()));
+ connect(keybA, TQT_SIGNAL(activated()), this, TQT_SLOT(slotShowFilterChooser()));
updateMenu();
}
diff --git a/knode/knfiltermanager.h b/knode/knfiltermanager.h
index ca76bcb75..2dc431f34 100644
--- a/knode/knfiltermanager.h
+++ b/knode/knfiltermanager.h
@@ -15,8 +15,8 @@
#ifndef KNFILTERMANAGER_H
#define KNFILTERMANAGER_H
-#include <qglobal.h>
-#include <qvaluelist.h>
+#include <tqglobal.h>
+#include <tqvaluelist.h>
#include <kaction.h>
@@ -33,8 +33,8 @@ class KNFilterSelectAction : public KActionMenu
Q_OBJECT
public:
- KNFilterSelectAction( const QString& text, const QString& pix,
- QObject* parent, const char *name );
+ KNFilterSelectAction( const TQString& text, const TQString& pix,
+ TQObject* parent, const char *name );
~KNFilterSelectAction();
void setCurrentItem(int id);
@@ -55,7 +55,7 @@ class KNFilterManager : public QObject
Q_OBJECT
public:
- KNFilterManager(QObject * parent = 0, const char * name = 0);
+ KNFilterManager(TQObject * parent = 0, const char * name = 0);
~KNFilterManager();
void readOptions();
@@ -73,7 +73,7 @@ class KNFilterManager : public QObject
void copyFilter(KNArticleFilter *f);
void addFilter(KNArticleFilter *f);
void deleteFilter(KNArticleFilter *f);
- bool newNameIsOK(KNArticleFilter *f, const QString &newName);
+ bool newNameIsOK(KNArticleFilter *f, const TQString &newName);
// Allow to delay the setup of UI elements, since the knode part may not
// be available when the config dialog is called
@@ -86,11 +86,11 @@ class KNFilterManager : public QObject
KNArticleFilter* byID(int id);
void updateMenu();
- QValueList<KNArticleFilter*> mFilterList;
+ TQValueList<KNArticleFilter*> mFilterList;
KNConfig::FilterListWidget *fset;
KNArticleFilter *currFilter;
KNFilterSelectAction *a_ctFilter;
- QValueList<int> menuOrder;
+ TQValueList<int> menuOrder;
bool commitNeeded;
protected slots:
diff --git a/knode/knfolder.cpp b/knode/knfolder.cpp
index 9cdb2f054..01855d5bd 100644
--- a/knode/knfolder.cpp
+++ b/knode/knfolder.cpp
@@ -12,7 +12,7 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qfileinfo.h>
+#include <tqfileinfo.h>
#include <ksimpleconfig.h>
#include <kstandarddirs.h>
@@ -41,10 +41,10 @@ KNFolder::KNFolder()
}
-KNFolder::KNFolder(int id, const QString &name, KNFolder *parent)
+KNFolder::KNFolder(int id, const TQString &name, KNFolder *parent)
: KNArticleCollection(parent), i_d(id), i_ndexDirty(false), w_asOpen(true)
{
- QString fname=path()+QString("custom_%1").arg(i_d);
+ TQString fname=path()+TQString("custom_%1").arg(i_d);
n_ame = name;
m_boxFile.setName(fname+".mbox");
@@ -60,10 +60,10 @@ KNFolder::KNFolder(int id, const QString &name, KNFolder *parent)
}
-KNFolder::KNFolder(int id, const QString &name, const QString &prefix, KNFolder *parent)
+KNFolder::KNFolder(int id, const TQString &name, const TQString &prefix, KNFolder *parent)
: KNArticleCollection(parent), i_d(id), i_ndexDirty(false), w_asOpen(true)
{
- QString fname=path()+QString("%1_%2").arg(prefix).arg(i_d);
+ TQString fname=path()+TQString("%1_%2").arg(prefix).arg(i_d);
n_ame = name;
m_boxFile.setName(fname+".mbox");
@@ -95,16 +95,16 @@ void KNFolder::updateListItem()
}
-QString KNFolder::path()
+TQString KNFolder::path()
{
- QString dir(locateLocal("data","knode/")+"folders/");
+ TQString dir(locateLocal("data","knode/")+"folders/");
/*if (dir.isNull())
KNHelper::displayInternalFileError();*/
return dir;
}
-bool KNFolder::readInfo(const QString &infoPath)
+bool KNFolder::readInfo(const TQString &infoPath)
{
if(infoPath.isEmpty())
return false;
@@ -120,8 +120,8 @@ bool KNFolder::readInfo(const QString &infoPath)
w_asOpen=info.readBoolEntry("wasOpen", true);
if(i_d>-1) {
- QFileInfo fi(infoPath);
- QString fname=fi.dirPath(true)+"/"+fi.baseName();
+ TQFileInfo fi(infoPath);
+ TQString fname=fi.dirPath(true)+"/"+fi.baseName();
closeFiles();
clear();
@@ -186,7 +186,7 @@ bool KNFolder::loadHdrs()
return false;
}
- QCString tmp;
+ TQCString tmp;
KQCStringSplitter split;
KNLocalArticle *art;
DynData dynamic;
@@ -284,7 +284,7 @@ bool KNFolder::loadHdrs()
clear();
closeFiles();
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
return false;
}
@@ -297,7 +297,7 @@ bool KNFolder::loadHdrs()
c_ount=cnt;
updateListItem();
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
return true;
@@ -347,7 +347,7 @@ bool KNFolder::loadArticle(KNLocalArticle *a)
m_boxFile.readLine(); //skip X-KNode-Overview
unsigned int size=a->endOffset()-m_boxFile.at()-1;
- QCString buff(size+10);
+ TQCString buff(size+10);
int readBytes=m_boxFile.readBlock(buff.data(), size);
closeFiles();
if(readBytes < (int)(size) && m_boxFile.status() != IO_Ok) { //cannot read file
@@ -378,8 +378,8 @@ bool KNFolder::saveArticles( KNLocalArticle::List &l )
int addCnt=0;
bool ret=true;
bool clear=false;
- QTextStream ts(&m_boxFile);
- ts.setEncoding(QTextStream::Latin1);
+ TQTextStream ts(&m_boxFile);
+ ts.setEncoding(TQTextStream::Latin1);
for ( KNLocalArticle::List::Iterator it = l.begin(); it != l.end(); ++it ) {
@@ -527,7 +527,7 @@ void KNFolder::deleteFiles()
{
m_boxFile.remove();
i_ndexFile.remove();
- QFile::remove(i_nfoPath);
+ TQFile::remove(i_nfoPath);
}
diff --git a/knode/knfolder.h b/knode/knfolder.h
index 0e2bfafb9..0be6dafde 100644
--- a/knode/knfolder.h
+++ b/knode/knfolder.h
@@ -28,8 +28,8 @@ class KNFolder : public KNArticleCollection {
public:
KNFolder();
- KNFolder(int id, const QString &name, KNFolder *parent=0);
- KNFolder(int id, const QString &name, const QString &prefix, KNFolder *parent=0);
+ KNFolder(int id, const TQString &name, KNFolder *parent=0);
+ KNFolder(int id, const TQString &name, const TQString &prefix, KNFolder *parent=0);
~KNFolder();
//type
@@ -47,15 +47,15 @@ class KNFolder : public KNArticleCollection {
bool wasOpen()const { return w_asOpen; }
//info
- QString path();
- bool readInfo(const QString &confPath);
+ TQString path();
+ bool readInfo(const TQString &confPath);
bool readInfo();
void saveInfo();
//article access
KNLocalArticle* at(int i) { return static_cast<KNLocalArticle*>(KNArticleCollection::at(i)); }
KNLocalArticle* byId(int id) { return static_cast<KNLocalArticle*>(KNArticleCollection::byId(id)); }
- KNLocalArticle* byMessageId(const QCString &mid)
+ KNLocalArticle* byMessageId(const TQCString &mid)
{ return static_cast<KNLocalArticle*>(KNArticleCollection::byMessageId(mid)); }
//parent
@@ -80,8 +80,8 @@ class KNFolder : public KNArticleCollection {
bool i_ndexDirty; // do we need to sync?
bool w_asOpen; // was this folder open in the listview on the last shutdown?
KNFile m_boxFile;
- QFile i_ndexFile;
- QString i_nfoPath;
+ TQFile i_ndexFile;
+ TQString i_nfoPath;
/* helper-class: stores index-data of an article */
class DynData {
diff --git a/knode/knfoldermanager.cpp b/knode/knfoldermanager.cpp
index 5acb41866..7e3465bff 100644
--- a/knode/knfoldermanager.cpp
+++ b/knode/knfoldermanager.cpp
@@ -12,7 +12,7 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qdir.h>
+#include <tqdir.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -33,7 +33,7 @@
KNFolderManager::KNFolderManager(KNArticleManager *a) : a_rtManager(a)
{
//standard folders
- QString dir(locateLocal("data","knode/")+"folders/");
+ TQString dir(locateLocal("data","knode/")+"folders/");
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
@@ -68,7 +68,7 @@ KNFolderManager::KNFolderManager(KNArticleManager *a) : a_rtManager(a)
KNFolderManager::~KNFolderManager()
{
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
delete (*it);
}
@@ -128,7 +128,7 @@ bool KNFolderManager::unloadHeaders(KNFolder *f, bool force)
KNFolder* KNFolderManager::folder(int i)
{
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
if ( (*it)->id() == i )
return (*it);
return 0;
@@ -151,11 +151,11 @@ bool KNFolderManager::deleteFolder(KNFolder *f)
if(!f || f->isRootFolder() || f->isStandardFolder() || f->lockedArticles()>0)
return false;
- QValueList<KNFolder*> del;
+ TQValueList<KNFolder*> del;
KNCollection *p;
// find all subfolders of the folder we want to delete
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
p = (*it)->parent();
while ( p ) {
if ( p == f ) {
@@ -171,7 +171,7 @@ bool KNFolderManager::deleteFolder(KNFolder *f)
emit folderRemoved(f);
del.append(f);
- for ( QValueList<KNFolder*>::Iterator it = del.begin(); it != del.end(); ++it ) {
+ for ( TQValueList<KNFolder*>::Iterator it = del.begin(); it != del.end(); ++it ) {
if ( c_urrentFolder == (*it) )
c_urrentFolder = 0;
@@ -231,7 +231,7 @@ int KNFolderManager::unsentForAccount(int accId)
{
int cnt=0;
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
for ( int idx = 0; idx < (*it)->length(); ++idx ) {
KNLocalArticle *a = (*it)->at( idx );
if ( a->serverId() == accId && a->doPost() && !a->posted() )
@@ -255,7 +255,7 @@ void KNFolderManager::compactFolder(KNFolder *f)
void KNFolderManager::compactAll(KNCleanUp *cup)
{
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it )
if ( !(*it)->isRootFolder() && (*it)->lockedArticles() == 0 )
cup->appendCollection( (*it) );
}
@@ -288,7 +288,7 @@ void KNFolderManager::importFromMBox(KNFolder *f)
KNFile *file = helper.getFile(i18n("Import MBox Folder"));
KNLocalArticle::List list;
KNLocalArticle *art;
- QString s;
+ TQString s;
int artStart=0, artEnd=0;
bool done=true;
@@ -322,7 +322,7 @@ void KNFolderManager::importFromMBox(KNFolder *f)
if (artEnd != -1) {
file->at(artStart); // seek the first character of the article
int size=artEnd-artStart;
- QCString buff(size+10);
+ TQCString buff(size+10);
int readBytes=file->readBlock(buff.data(), size);
if (readBytes != -1) {
@@ -341,7 +341,7 @@ void KNFolderManager::importFromMBox(KNFolder *f)
if ((int)file->size() > artStart) {
file->at(artStart); // seek the first character of the article
int size=file->size()-artStart;
- QCString buff(size+10);
+ TQCString buff(size+10);
int readBytes=file->readBlock(buff.data(), size);
if (readBytes != -1) {
@@ -366,7 +366,7 @@ void KNFolderManager::importFromMBox(KNFolder *f)
if (!list.isEmpty())
knGlobals.articleManager()->moveIntoFolder(list, f);
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
}
@@ -387,15 +387,15 @@ void KNFolderManager::exportToMBox(KNFolder *f)
}
KNSaveHelper helper(f->name()+".mbox", knGlobals.topWidget);
- QFile *file = helper.getFile(i18n("Export Folder"));
+ TQFile *file = helper.getFile(i18n("Export Folder"));
if (file) {
knGlobals.top->setCursorBusy(true);
knGlobals.setStatusMsg(i18n(" Exporting articles..."));
knGlobals.top->secureProcessEvents();
- QTextStream ts(file);
- ts.setEncoding(QTextStream::Latin1);
+ TQTextStream ts(file);
+ ts.setEncoding(TQTextStream::Latin1);
KNLocalArticle *a;
for(int idx=0; idx<f->length(); idx++) {
@@ -415,7 +415,7 @@ void KNFolderManager::exportToMBox(KNFolder *f)
knGlobals.top->secureProcessEvents();
}
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
}
}
@@ -423,14 +423,14 @@ void KNFolderManager::exportToMBox(KNFolder *f)
void KNFolderManager::syncFolders()
{
- QString dir(locateLocal("data","knode/")+"folders/");
+ TQString dir(locateLocal("data","knode/")+"folders/");
if (dir.isNull()) {
KNHelper::displayInternalFileError();
return;
}
//sync
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
if ( !(*it)->isRootFolder() )
(*it)->syncIndex();
(*it)->saveInfo();
@@ -441,7 +441,7 @@ void KNFolderManager::syncFolders()
int KNFolderManager::loadCustomFolders()
{
int cnt=0;
- QString dir(locateLocal("data","knode/")+"folders/");
+ TQString dir(locateLocal("data","knode/")+"folders/");
KNFolder *f;
if (dir.isNull()) {
@@ -449,9 +449,9 @@ int KNFolderManager::loadCustomFolders()
return 0;
}
- QDir d(dir);
- QStringList entries(d.entryList("custom_*.info")); // ignore info files of standard folders
- for(QStringList::Iterator it=entries.begin(); it != entries.end(); ++it) {
+ TQDir d(dir);
+ TQStringList entries(d.entryList("custom_*.info")); // ignore info files of standard folders
+ for(TQStringList::Iterator it=entries.begin(); it != entries.end(); ++it) {
f=new KNFolder();
if(f->readInfo(d.absFilePath(*it))) {
if(f->id()>l_astId)
@@ -465,7 +465,7 @@ int KNFolderManager::loadCustomFolders()
// set parents
if(cnt>0) {
- for ( QValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
+ for ( TQValueList<KNFolder*>::Iterator it = mFolderList.begin(); it != mFolderList.end(); ++it ) {
if ( !(*it)->isRootFolder() ) { // the root folder has no parent
KNFolder *par = folder( (*it)->parentId() );
if ( !par )
diff --git a/knode/knfoldermanager.h b/knode/knfoldermanager.h
index 9bc8254e8..a6337d801 100644
--- a/knode/knfoldermanager.h
+++ b/knode/knfoldermanager.h
@@ -15,8 +15,8 @@
#ifndef KNFOLDERMANAGER_H
#define KNFOLDERMANAGER_H
-#include <qobject.h>
-#include <qvaluelist.h>
+#include <tqobject.h>
+#include <tqvaluelist.h>
class KNFolder;
class KNArticleManager;
@@ -36,7 +36,7 @@ class KNFolderManager : public QObject
KNFolder* currentFolder() const { return c_urrentFolder; }
bool hasCurrentFolder() const { return (c_urrentFolder!=0); }
KNFolder* folder(int id);
- QValueList<KNFolder*> folders() const { return mFolderList; }
+ TQValueList<KNFolder*> folders() const { return mFolderList; }
//standard folders
KNFolder* root() const { return mFolderList[0]; }
@@ -82,7 +82,7 @@ class KNFolderManager : public QObject
int loadCustomFolders();
KNFolder *c_urrentFolder;
- QValueList<KNFolder*> mFolderList;
+ TQValueList<KNFolder*> mFolderList;
int l_astId;
KNArticleManager *a_rtManager;
diff --git a/knode/knglobals.cpp b/knode/knglobals.cpp
index 5238bebec..be9bb1488 100644
--- a/knode/knglobals.cpp
+++ b/knode/knglobals.cpp
@@ -107,7 +107,7 @@ KNMemoryManager* KNGlobals::memoryManager()
}
-void KNGlobals::setStatusMsg(const QString &text, int id)
+void KNGlobals::setStatusMsg(const TQString &text, int id)
{
if(top)
top->setStatusMsg(text, id);
diff --git a/knode/knglobals.h b/knode/knglobals.h
index 12b934dae..4f4c84c31 100644
--- a/knode/knglobals.h
+++ b/knode/knglobals.h
@@ -52,7 +52,7 @@ namespace KNode {
class KDE_EXPORT KNGlobals {
public:
/** topWidget == top, used for message boxes, */
- QWidget *topWidget;
+ TQWidget *topWidget;
/** no need to include knode.h everywhere */
KNMainWidget *top;
KXMLGUIClient *guiClient;
@@ -73,7 +73,7 @@ class KDE_EXPORT KNGlobals {
KNMemoryManager *memoryManager();
/** forwarded to top->setStatusMsg() if available */
- void setStatusMsg(const QString& text = QString::null, int id = SB_MAIN);
+ void setStatusMsg(const TQString& text = TQString::null, int id = SB_MAIN);
private:
KSharedConfig::Ptr c_onfig;
diff --git a/knode/kngroup.cpp b/knode/kngroup.cpp
index 1c8bdfbf1..e55bee10e 100644
--- a/knode/kngroup.cpp
+++ b/knode/kngroup.cpp
@@ -51,15 +51,15 @@ KNGroup::~KNGroup()
}
-QString KNGroup::path()
+TQString KNGroup::path()
{
return p_arent->path();
}
-const QString& KNGroup::name()
+const TQString& KNGroup::name()
{
- static QString ret;
+ static TQString ret;
if(n_ame.isEmpty()) ret=g_roupname;
else ret=n_ame;
return ret;
@@ -75,7 +75,7 @@ void KNGroup::updateListItem()
}
-bool KNGroup::readInfo(const QString &confPath)
+bool KNGroup::readInfo(const TQString &confPath)
{
KSimpleConfig info(confPath);
@@ -90,7 +90,7 @@ bool KNGroup::readInfo(const QString &confPath)
d_ynDataFormat = info.readNumEntry("dynDataFormat",0);
u_seCharset = info.readBoolEntry("useCharset", false);
d_efaultChSet = info.readEntry("defaultChSet").latin1();
- QString s = info.readEntry("status","unknown");
+ TQString s = info.readEntry("status","unknown");
if (s=="readOnly")
s_tatus = readOnly;
else if (s=="postingAllowed")
@@ -104,7 +104,7 @@ bool KNGroup::readInfo(const QString &confPath)
i_dentity=new KNConfig::Identity(false);
i_dentity->loadConfig(&info);
if(!i_dentity->isEmpty()) {
- kdDebug(5003) << "KNGroup::readInfo(const QString &confPath) : using alternative user for " << g_roupname << endl;
+ kdDebug(5003) << "KNGroup::readInfo(const TQString &confPath) : using alternative user for " << g_roupname << endl;
}
else {
delete i_dentity;
@@ -119,7 +119,7 @@ bool KNGroup::readInfo(const QString &confPath)
void KNGroup::saveInfo()
{
- QString dir(path());
+ TQString dir(path());
if (!dir.isNull()) {
KSimpleConfig info(dir+g_roupname+".grpinfo");
@@ -133,7 +133,7 @@ void KNGroup::saveInfo()
info.writeEntry("dynDataFormat", d_ynDataFormat);
info.writeEntry("name", n_ame);
info.writeEntry("useCharset", u_seCharset);
- info.writeEntry("defaultChSet", QString::fromLatin1(d_efaultChSet));
+ info.writeEntry("defaultChSet", TQString::fromLatin1(d_efaultChSet));
switch (s_tatus) {
case unknown: info.writeEntry("status","unknown");
break;
@@ -182,14 +182,14 @@ bool KNGroup::loadHdrs()
}
kdDebug(5003) << "KNGroup::loadHdrs() : loading headers" << endl;
- QCString buff, hdrValue;
+ TQCString buff, hdrValue;
KNFile f;
KQCStringSplitter split;
int cnt=0, id, lines, fileFormatVersion, artNumber;
unsigned int timeT;
KNRemoteArticle *art;
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return false;
@@ -255,7 +255,7 @@ bool KNGroup::loadHdrs()
for (uint i = buff.toUInt(); i > 0; --i) {
buff = f.readLine();
int pos = buff.find(':');
- QCString hdrName = buff.left( pos );
+ TQCString hdrName = buff.left( pos );
// skip headers we already set above and which we actually never should
// find here, but however it still happens... (eg. #101355)
if ( hdrName == "Subject" || hdrName == "From" || hdrName == "Date"
@@ -384,14 +384,14 @@ bool KNGroup::unloadHdrs(bool force)
// Attention: this method is called from the network thread!
-void KNGroup::insortNewHeaders(QStrList *hdrs, QStrList *hdrfmt, KNProtocolClient *client)
+void KNGroup::insortNewHeaders(TQStrList *hdrs, TQStrList *hdrfmt, KNProtocolClient *client)
{
KNRemoteArticle *art=0, *art2=0;
- QCString data, hdr, hdrName;
+ TQCString data, hdr, hdrName;
KQCStringSplitter split;
split.setIncludeSep(false);
int new_cnt=0, added_cnt=0, todo=hdrs->count();
- QTime timer;
+ TQTime timer;
l_astFetchCount=0;
@@ -442,7 +442,7 @@ void KNGroup::insortNewHeaders(QStrList *hdrs, QStrList *hdrfmt, KNProtocolClien
//References
split.next();
if(!split.string().isEmpty())
- art->references()->from7BitString(split.string()); //use QCString::copy() ?
+ art->references()->from7BitString(split.string()); //use TQCString::copy() ?
// Bytes
split.next();
@@ -514,19 +514,19 @@ int KNGroup::saveStaticData(int cnt,bool ovr)
int idx, savedCnt=0, mode;
KNRemoteArticle *art;
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return 0;
- QFile f(dir+g_roupname+".static");
+ TQFile f(dir+g_roupname+".static");
if(ovr) mode=IO_WriteOnly;
else mode=IO_WriteOnly | IO_Append;
if(f.open(mode)) {
- QTextStream ts(&f);
- ts.setEncoding(QTextStream::Latin1);
+ TQTextStream ts(&f);
+ ts.setEncoding(TQTextStream::Latin1);
for(idx=length()-cnt; idx<length(); idx++) {
@@ -557,7 +557,7 @@ int KNGroup::saveStaticData(int cnt,bool ovr)
// optional headers
ts << mOptionalHeaders.count() << '\n';
- for (QCString hdrName = mOptionalHeaders.first(); hdrName; hdrName = mOptionalHeaders.next()) {
+ for (TQCString hdrName = mOptionalHeaders.first(); hdrName; hdrName = mOptionalHeaders.next()) {
hdrName = hdrName.left( hdrName.find(':') );
KMime::Headers::Base *hdr = art->getHeaderByType( hdrName );
if ( hdr )
@@ -583,11 +583,11 @@ void KNGroup::saveDynamicData(int cnt,bool ovr)
KNRemoteArticle *art;
if(length()>0) {
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return;
- QFile f(dir+g_roupname+".dynamic");
+ TQFile f(dir+g_roupname+".dynamic");
if(ovr) mode=IO_WriteOnly;
else mode=IO_WriteOnly | IO_Append;
@@ -616,11 +616,11 @@ void KNGroup::syncDynamicData()
if(length()>0) {
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return;
- QFile f(dir+g_roupname+".dynamic");
+ TQFile f(dir+g_roupname+".dynamic");
if(f.open(IO_ReadWrite)) {
@@ -652,7 +652,7 @@ void KNGroup::syncDynamicData()
}
-void KNGroup::appendXPostID(const QString &id)
+void KNGroup::appendXPostID(const TQString &id)
{
c_rosspostIDBuffer.append(id);
}
@@ -660,11 +660,11 @@ void KNGroup::appendXPostID(const QString &id)
void KNGroup::processXPostBuffer(bool deleteAfterwards)
{
- QStringList remainder;
+ TQStringList remainder;
KNRemoteArticle *xp;
KNRemoteArticle::List al;
- for (QStringList::Iterator it = c_rosspostIDBuffer.begin(); it != c_rosspostIDBuffer.end(); ++it) {
+ for (TQStringList::Iterator it = c_rosspostIDBuffer.begin(); it != c_rosspostIDBuffer.end(); ++it) {
if ((xp=byMessageId((*it).local8Bit())))
al.append(xp);
else
@@ -686,7 +686,7 @@ void KNGroup::buildThreads(int cnt, KNProtocolClient *client)
foundCnt=0, bySubCnt=0, refCnt=0,
resortCnt=0, idx, oldRef; // idRef;
KNRemoteArticle *art, *ref;
- QTime timer;
+ TQTime timer;
timer.start();
@@ -869,7 +869,7 @@ void KNGroup::buildThreads(int cnt, KNProtocolClient *client)
KNRemoteArticle* KNGroup::findReference(KNRemoteArticle *a)
{
int found=false;
- QCString ref_mid;
+ TQCString ref_mid;
int ref_nr=0;
KNRemoteArticle *ref_art=0;
@@ -936,7 +936,7 @@ void KNGroup::scoreArticles(bool onlynew)
incReadCount();
}
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
//kdDebug(5003) << KNScorableArticle::notifyC->collection() << endl;
@@ -965,7 +965,7 @@ void KNGroup::reorganize()
saveStaticData(length(), true);
saveDynamicData(length(), true);
knGlobals.top->headerView()->repaint();
- knGlobals.setStatusMsg(QString::null);
+ knGlobals.setStatusMsg(TQString::null);
knGlobals.top->setCursorBusy(false);
}
@@ -1047,10 +1047,10 @@ int KNGroup::statThrWithUnread()
return cnt;
}
-QString KNGroup::prepareForExecution()
+TQString KNGroup::prepareForExecution()
{
if (knGlobals.groupManager()->loadHeaders(this))
- return QString::null;
+ return TQString::null;
else
return i18n("Cannot load saved headers: %1").arg(groupname());
}
diff --git a/knode/kngroup.h b/knode/kngroup.h
index 8158e192b..dc28b9121 100644
--- a/knode/kngroup.h
+++ b/knode/kngroup.h
@@ -47,17 +47,17 @@ class KNGroup : public KNArticleCollection , public KNJobItem {
void updateListItem();
/** info */
- QString path();
- bool readInfo(const QString &confPath);
+ TQString path();
+ bool readInfo(const TQString &confPath);
void saveInfo();
/** name */
bool hasName() const { return (!n_ame.isEmpty()); }
- const QString& name();
- const QString& groupname() { return g_roupname; }
- void setGroupname(const QString &s) { g_roupname=s; }
- const QString& description() { return d_escription; }
- void setDescription(const QString &s) { d_escription=s; }
+ const TQString& name();
+ const TQString& groupname() { return g_roupname; }
+ void setGroupname(const TQString &s) { g_roupname=s; }
+ const TQString& description() { return d_escription; }
+ void setDescription(const TQString &s) { d_escription=s; }
/** count + numbers */
int newCount() const { return n_ewCount; }
@@ -88,18 +88,18 @@ class KNGroup : public KNArticleCollection , public KNJobItem {
/** article access */
KNRemoteArticle* at(int i) { return static_cast<KNRemoteArticle*> (KNArticleCollection::at(i)); }
KNRemoteArticle* byId(int id) { return static_cast<KNRemoteArticle*> (KNArticleCollection::byId(id)); }
- KNRemoteArticle* byMessageId(const QCString &mId)
+ KNRemoteArticle* byMessageId(const TQCString &mId)
{ return static_cast<KNRemoteArticle*> (KNArticleCollection::byMessageId(mId)); }
/** load + save */
bool loadHdrs();
bool unloadHdrs(bool force=true);
- void insortNewHeaders(QStrList *hdrs, QStrList *hdrfmt, KNProtocolClient *client=0);
+ void insortNewHeaders(TQStrList *hdrs, TQStrList *hdrfmt, KNProtocolClient *client=0);
int saveStaticData(int cnt,bool ovr=false);
void saveDynamicData(int cnt,bool ovr=false);
void syncDynamicData();
/** mark articles with this id as read when we later load the headers / fetch new articles */
- void appendXPostID(const QString &id);
+ void appendXPostID(const TQString &id);
void processXPostBuffer(bool deleteAfterwards);
/** article handling */
@@ -111,11 +111,11 @@ class KNGroup : public KNArticleCollection , public KNJobItem {
bool isLocked() { return l_ocked; }
void setLocked(bool l) { l_ocked=l; }
- QString prepareForExecution();
+ TQString prepareForExecution();
/** charset-handling */
- const QCString defaultCharset() { return d_efaultChSet; }
- void setDefaultCharset(const QCString &s) { d_efaultChSet=s; }
+ const TQCString defaultCharset() { return d_efaultChSet; }
+ void setDefaultCharset(const TQCString &s) { d_efaultChSet=s; }
bool useCharset() { return ( u_seCharset && !d_efaultChSet.isEmpty() ); }
void setUseCharset(bool b) { u_seCharset=b; }
@@ -146,8 +146,8 @@ class KNGroup : public KNArticleCollection , public KNJobItem {
d_ynDataFormat,
f_irstNew;
- QCString d_efaultChSet;
- QString g_roupname,
+ TQCString d_efaultChSet;
+ TQString g_roupname,
d_escription;
bool l_ocked,
@@ -155,12 +155,12 @@ class KNGroup : public KNArticleCollection , public KNJobItem {
Status s_tatus;
- QStringList c_rosspostIDBuffer;
+ TQStringList c_rosspostIDBuffer;
/** Optional headers provided by the XOVER command
* These headers will be saved within the static data
*/
- QStrList mOptionalHeaders;
+ TQStrList mOptionalHeaders;
KNConfig::Identity *i_dentity;
KNConfig::Cleanup *mCleanupConf;
diff --git a/knode/kngroupbrowser.cpp b/knode/kngroupbrowser.cpp
index 17342a4be..be91593a7 100644
--- a/knode/kngroupbrowser.cpp
+++ b/knode/kngroupbrowser.cpp
@@ -14,10 +14,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qcheckbox.h>
-#include <qtimer.h>
-#include <qapplication.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
+#include <tqtimer.h>
+#include <tqapplication.h>
#include <kseparator.h>
#include <kiconloader.h>
@@ -30,73 +30,73 @@
#include "knconfigmanager.h"
#include "knnntpaccount.h"
#include "kngroupbrowser.h"
-#include <qlabel.h>
-#include <qpushbutton.h>
+#include <tqlabel.h>
+#include <tqpushbutton.h>
-KNGroupBrowser::KNGroupBrowser(QWidget *parent, const QString &caption, KNNntpAccount *a,
- int buttons, bool newCBact, const QString &user1, const QString &user2) :
+KNGroupBrowser::KNGroupBrowser(TQWidget *parent, const TQString &caption, KNNntpAccount *a,
+ int buttons, bool newCBact, const TQString &user1, const TQString &user2) :
KDialogBase( parent, 0L, true, caption, buttons | Help | Ok | Cancel, Ok, true, user1, user2 ),
incrementalFilter(false), a_ccount(a)
{
- refilterTimer = new QTimer();
+ refilterTimer = new TQTimer();
- allList=new QSortedList<KNGroupInfo>;
+ allList=new TQSortedList<KNGroupInfo>;
allList->setAutoDelete(true);
- matchList=new QSortedList<KNGroupInfo>;
+ matchList=new TQSortedList<KNGroupInfo>;
matchList->setAutoDelete(false);
//create Widgets
- page=new QWidget(this);
+ page=new TQWidget(this);
setMainWidget(page);
filterEdit=new KLineEdit(page);
- QLabel *l=new QLabel(filterEdit,i18n("S&earch:"), page);
- noTreeCB=new QCheckBox(i18n("Disable &tree view"), page);
+ TQLabel *l=new TQLabel(filterEdit,i18n("S&earch:"), page);
+ noTreeCB=new TQCheckBox(i18n("Disable &tree view"), page);
noTreeCB->setChecked(false);
- subCB=new QCheckBox(i18n("&Subscribed only"), page);
+ subCB=new TQCheckBox(i18n("&Subscribed only"), page);
subCB->setChecked(false);
- newCB=new QCheckBox(i18n("&New only"), page);
+ newCB=new TQCheckBox(i18n("&New only"), page);
if (!newCBact)
newCB->hide();
newCB->setChecked(false);
KSeparator *sep=new KSeparator(KSeparator::HLine, page);
- QFont fnt=font();
+ TQFont fnt=font();
fnt.setBold(true);
- leftLabel=new QLabel(i18n("Loading groups..."), page);
- rightLabel=new QLabel(page);
+ leftLabel=new TQLabel(i18n("Loading groups..."), page);
+ rightLabel=new TQLabel(page);
leftLabel->setFont(fnt);
rightLabel->setFont(fnt);
pmGroup=knGlobals.configManager()->appearance()->icon(KNConfig::Appearance::group);
pmNew=knGlobals.configManager()->appearance()->icon(KNConfig::Appearance::redBall);
- pmRight=BarIconSet( QApplication::reverseLayout()? "back": "forward");
- pmLeft=BarIconSet( QApplication::reverseLayout() ? "forward" : "back");
+ pmRight=BarIconSet( TQApplication::reverseLayout()? "back": "forward");
+ pmLeft=BarIconSet( TQApplication::reverseLayout() ? "forward" : "back");
- arrowBtn1=new QPushButton(page);
+ arrowBtn1=new TQPushButton(page);
arrowBtn1->setEnabled(false);
- arrowBtn2=new QPushButton(page);
+ arrowBtn2=new TQPushButton(page);
arrowBtn2->setEnabled(false);
arrowBtn1->setIconSet(pmRight);
arrowBtn2->setIconSet(pmLeft);
arrowBtn1->setFixedSize(35,30);
arrowBtn2->setFixedSize(35,30);
- groupView=new QListView(page);
+ groupView=new TQListView(page);
groupView->setRootIsDecorated(true);
groupView->addColumn(i18n("Name"));
groupView->addColumn(i18n("Description"));
groupView->setTreeStepSize(15);
- connect(groupView, SIGNAL(doubleClicked(QListViewItem*)),
- this, SLOT(slotItemDoubleClicked(QListViewItem*)));
+ connect(groupView, TQT_SIGNAL(doubleClicked(TQListViewItem*)),
+ this, TQT_SLOT(slotItemDoubleClicked(TQListViewItem*)));
//layout
- QGridLayout *topL=new QGridLayout(page,3,1,0,5);
- QHBoxLayout *filterL=new QHBoxLayout(10);
- QVBoxLayout *arrL=new QVBoxLayout(10);
- listL=new QGridLayout(2, 3, 5);
+ TQGridLayout *topL=new TQGridLayout(page,3,1,0,5);
+ TQHBoxLayout *filterL=new TQHBoxLayout(10);
+ TQVBoxLayout *arrL=new TQVBoxLayout(10);
+ listL=new TQGridLayout(2, 3, 5);
topL->addLayout(filterL, 0,0);
topL->addWidget(sep,1,0);
@@ -121,22 +121,22 @@ KNGroupBrowser::KNGroupBrowser(QWidget *parent, const QString &caption, KNNntpAc
arrL->addWidget(arrowBtn2, AlignCenter);
//connect
- connect(filterEdit, SIGNAL(textChanged(const QString&)),
- SLOT(slotFilterTextChanged(const QString&)));
- connect(groupView, SIGNAL(expanded(QListViewItem*)),
- SLOT(slotItemExpand(QListViewItem*)));
+ connect(filterEdit, TQT_SIGNAL(textChanged(const TQString&)),
+ TQT_SLOT(slotFilterTextChanged(const TQString&)));
+ connect(groupView, TQT_SIGNAL(expanded(TQListViewItem*)),
+ TQT_SLOT(slotItemExpand(TQListViewItem*)));
- connect(refilterTimer, SIGNAL(timeout()), SLOT(slotRefilter()));
- connect(noTreeCB, SIGNAL(clicked()), SLOT(slotTreeCBToggled()));
- connect(subCB, SIGNAL(clicked()), SLOT(slotSubCBToggled()));
- connect(newCB, SIGNAL(clicked()), SLOT(slotNewCBToggled()));
+ connect(refilterTimer, TQT_SIGNAL(timeout()), TQT_SLOT(slotRefilter()));
+ connect(noTreeCB, TQT_SIGNAL(clicked()), TQT_SLOT(slotTreeCBToggled()));
+ connect(subCB, TQT_SIGNAL(clicked()), TQT_SLOT(slotSubCBToggled()));
+ connect(newCB, TQT_SIGNAL(clicked()), TQT_SLOT(slotNewCBToggled()));
enableButton(User1,false);
enableButton(User2,false);
filterEdit->setFocus();
- QTimer::singleShot(2, this, SLOT(slotLoadList()));
+ TQTimer::singleShot(2, this, TQT_SLOT(slotLoadList()));
}
@@ -169,7 +169,7 @@ void KNGroupBrowser::slotReceiveList(KNGroupListData* d)
void KNGroupBrowser::changeItemState(const KNGroupInfo &gi, bool s)
{
- QListViewItemIterator it(groupView);
+ TQListViewItemIterator it(groupView);
for( ; it.current(); ++it)
if (it.current()->isSelectable() && (static_cast<CheckItem*>(it.current())->info==gi))
@@ -177,10 +177,10 @@ void KNGroupBrowser::changeItemState(const KNGroupInfo &gi, bool s)
}
-bool KNGroupBrowser::itemInListView(QListView *view, const KNGroupInfo &gi)
+bool KNGroupBrowser::itemInListView(TQListView *view, const KNGroupInfo &gi)
{
if(!view) return false;
- QListViewItemIterator it(view);
+ TQListViewItemIterator it(view);
for( ; it.current(); ++it)
if(static_cast<GroupItem*>(it.current())->info==gi)
@@ -190,16 +190,16 @@ bool KNGroupBrowser::itemInListView(QListView *view, const KNGroupInfo &gi)
}
-void KNGroupBrowser::createListItems(QListViewItem *parent)
+void KNGroupBrowser::createListItems(TQListViewItem *parent)
{
- QString prefix, tlgn, compare;
- QListViewItem *it;
+ TQString prefix, tlgn, compare;
+ TQListViewItem *it;
CheckItem *cit;
int colon;
bool expandit=false;
if(parent) {
- QListViewItem *p=parent;
+ TQListViewItem *p=parent;
while(p) {
prefix.prepend(p->text(0));
p=p->parent();
@@ -229,9 +229,9 @@ void KNGroupBrowser::createListItems(QListViewItem *parent)
if(expandit) {
if(parent)
- it=new QListViewItem(parent, tlgn);
+ it=new TQListViewItem(parent, tlgn);
else
- it=new QListViewItem(groupView, tlgn);
+ it=new TQListViewItem(groupView, tlgn);
it->setSelectable(false);
it->setExpandable(true);
@@ -248,10 +248,10 @@ void KNGroupBrowser::createListItems(QListViewItem *parent)
}
-void KNGroupBrowser::removeListItem(QListView *view, const KNGroupInfo &gi)
+void KNGroupBrowser::removeListItem(TQListView *view, const KNGroupInfo &gi)
{
if(!view) return;
- QListViewItemIterator it(view);
+ TQListViewItemIterator it(view);
for( ; it.current(); ++it)
if(static_cast<GroupItem*>(it.current())->info==gi) {
@@ -267,7 +267,7 @@ void KNGroupBrowser::slotLoadList()
}
-void KNGroupBrowser::slotItemExpand(QListViewItem *it)
+void KNGroupBrowser::slotItemExpand(TQListViewItem *it)
{
if(!it) return;
@@ -287,7 +287,7 @@ void KNGroupBrowser::slotItemExpand(QListViewItem *it)
{
groupView->ensureVisible(groupView->contentsX(), y+h/2, 0, h/2);
delayedCenter = y+h/2;
- QTimer::singleShot(300, this, SLOT(slotCenterDelayed()));
+ TQTimer::singleShot(300, this, TQT_SLOT(slotCenterDelayed()));
}
}
@@ -299,29 +299,29 @@ void KNGroupBrowser::slotCenterDelayed()
}
-void KNGroupBrowser::slotItemDoubleClicked(QListViewItem *it)
+void KNGroupBrowser::slotItemDoubleClicked(TQListViewItem *it)
{
if (it && (it->childCount()==0)) static_cast<CheckItem*>(it)->setOn(!static_cast<CheckItem*>(it)->isOn());
}
#define MIN_FOR_TREE 200
-void KNGroupBrowser::slotFilter(const QString &txt)
+void KNGroupBrowser::slotFilter(const TQString &txt)
{
- QString filtertxt = txt.lower();
- QRegExp reg(filtertxt, false, false);
+ TQString filtertxt = txt.lower();
+ TQRegExp reg(filtertxt, false, false);
CheckItem *cit=0;
bool notCheckSub = !subCB->isChecked();
bool notCheckNew = !newCB->isChecked();
bool notCheckStr = (filtertxt.isEmpty());
- bool isRegexp = filtertxt.contains(QRegExp("[^a-z0-9\\-\\+.]"));
+ bool isRegexp = filtertxt.contains(TQRegExp("[^a-z0-9\\-\\+.]"));
bool doIncrementalUpdate = (!isRegexp && incrementalFilter && (filtertxt.left(lastFilter.length())==lastFilter));
if (doIncrementalUpdate) {
- QSortedList<KNGroupInfo> *tempList = new QSortedList<KNGroupInfo>();
+ TQSortedList<KNGroupInfo> *tempList = new TQSortedList<KNGroupInfo>();
tempList->setAutoDelete(false);
for(KNGroupInfo *g=matchList->first(); g; g=matchList->next()) {
@@ -386,7 +386,7 @@ void KNGroupBrowser::slotNewCBToggled()
}
-void KNGroupBrowser::slotFilterTextChanged(const QString &)
+void KNGroupBrowser::slotFilterTextChanged(const TQString &)
{
if (subCB->isChecked() || newCB->isChecked())
slotRefilter();
@@ -405,10 +405,10 @@ void KNGroupBrowser::slotRefilter()
//=======================================================================================
-KNGroupBrowser::CheckItem::CheckItem(QListView *v, const KNGroupInfo &gi, KNGroupBrowser *b) :
- QCheckListItem(v, gi.name, QCheckListItem::CheckBox), info(gi), browser(b)
+KNGroupBrowser::CheckItem::CheckItem(TQListView *v, const KNGroupInfo &gi, KNGroupBrowser *b) :
+ TQCheckListItem(v, gi.name, TQCheckListItem::CheckBox), info(gi), browser(b)
{
- QString des(gi.description);
+ TQString des(gi.description);
if (gi.status == KNGroup::moderated) {
setText(0,gi.name+" (m)");
if (!des.upper().contains(i18n("moderated").upper()))
@@ -418,10 +418,10 @@ KNGroupBrowser::CheckItem::CheckItem(QListView *v, const KNGroupInfo &gi, KNGrou
}
-KNGroupBrowser::CheckItem::CheckItem(QListViewItem *i, const KNGroupInfo &gi, KNGroupBrowser *b) :
- QCheckListItem(i, gi.name, QCheckListItem::CheckBox), info(gi), browser(b)
+KNGroupBrowser::CheckItem::CheckItem(TQListViewItem *i, const KNGroupInfo &gi, KNGroupBrowser *b) :
+ TQCheckListItem(i, gi.name, TQCheckListItem::CheckBox), info(gi), browser(b)
{
- QString des(gi.description);
+ TQString des(gi.description);
if (gi.status == KNGroup::moderated) {
setText(0,gi.name+" (m)");
if (!des.upper().contains(i18n("moderated").upper()))
@@ -440,7 +440,7 @@ void KNGroupBrowser::CheckItem::setChecked(bool c)
{
KNGroupBrowser *b=browser;
browser=0;
- QCheckListItem::setOn(c);
+ TQCheckListItem::setOn(c);
browser=b;
}
@@ -457,16 +457,16 @@ void KNGroupBrowser::CheckItem::stateChange(bool s)
//=======================================================================================
-KNGroupBrowser::GroupItem::GroupItem(QListView *v, const KNGroupInfo &gi)
- : QListViewItem(v, gi.name), info(gi)
+KNGroupBrowser::GroupItem::GroupItem(TQListView *v, const KNGroupInfo &gi)
+ : TQListViewItem(v, gi.name), info(gi)
{
if (gi.status == KNGroup::moderated)
setText(0,gi.name+" (m)");
}
-KNGroupBrowser::GroupItem::GroupItem(QListViewItem *i, const KNGroupInfo &gi)
- : QListViewItem(i, gi.name), info(gi)
+KNGroupBrowser::GroupItem::GroupItem(TQListViewItem *i, const KNGroupInfo &gi)
+ : TQListViewItem(i, gi.name), info(gi)
{
}
diff --git a/knode/kngroupbrowser.h b/knode/kngroupbrowser.h
index eb633c8b9..15e639281 100644
--- a/knode/kngroupbrowser.h
+++ b/knode/kngroupbrowser.h
@@ -17,7 +17,7 @@
#ifndef KNGROUPBROWSER_H
#define KNGROUPBROWSER_H
-#include <qlistview.h>
+#include <tqlistview.h>
#include <kdialogbase.h>
@@ -37,11 +37,11 @@ class KNGroupBrowser : public KDialogBase {
Q_OBJECT
public:
- class CheckItem : public QCheckListItem {
+ class CheckItem : public TQCheckListItem {
public:
- CheckItem(QListView *v, const KNGroupInfo &gi, KNGroupBrowser *b);
- CheckItem(QListViewItem *i, const KNGroupInfo &gi, KNGroupBrowser *b);
+ CheckItem(TQListView *v, const KNGroupInfo &gi, KNGroupBrowser *b);
+ CheckItem(TQListViewItem *i, const KNGroupInfo &gi, KNGroupBrowser *b);
~CheckItem();
void setChecked(bool c);
@@ -52,18 +52,18 @@ class KNGroupBrowser : public KDialogBase {
KNGroupBrowser *browser;
};
- class GroupItem : public QListViewItem {
+ class GroupItem : public TQListViewItem {
public:
- GroupItem(QListView *v, const KNGroupInfo &gi);
- GroupItem(QListViewItem *i, const KNGroupInfo &gi);
+ GroupItem(TQListView *v, const KNGroupInfo &gi);
+ GroupItem(TQListViewItem *i, const KNGroupInfo &gi);
~GroupItem();
KNGroupInfo info;
};
- KNGroupBrowser(QWidget *parent, const QString &caption, KNNntpAccount *a, int buttons=0,
- bool newCBact=false, const QString &user1=QString::null, const QString &user2=QString::null);
+ KNGroupBrowser(TQWidget *parent, const TQString &caption, KNNntpAccount *a, int buttons=0,
+ bool newCBact=false, const TQString &user1=TQString::null, const TQString &user2=TQString::null);
~KNGroupBrowser();
KNNntpAccount* account()const { return a_ccount; }
@@ -78,38 +78,38 @@ class KNGroupBrowser : public KDialogBase {
protected:
virtual void updateItemState(CheckItem *it)=0;
void changeItemState(const KNGroupInfo &gi, bool s);
- bool itemInListView(QListView *view, const KNGroupInfo &gi);
- void removeListItem(QListView *view, const KNGroupInfo &gi);
- void createListItems(QListViewItem *parent=0);
+ bool itemInListView(TQListView *view, const KNGroupInfo &gi);
+ void removeListItem(TQListView *view, const KNGroupInfo &gi);
+ void createListItems(TQListViewItem *parent=0);
- QWidget *page;
- QListView *groupView;
+ TQWidget *page;
+ TQListView *groupView;
int delayedCenter;
KLineEdit *filterEdit;
- QCheckBox *noTreeCB, *subCB, *newCB;
- QPushButton *arrowBtn1, *arrowBtn2;
- QPixmap pmGroup, pmNew;
- QIconSet pmRight, pmLeft;
- QGridLayout *listL;
- QLabel *leftLabel, *rightLabel;
- QTimer *refilterTimer;
- QString lastFilter;
+ TQCheckBox *noTreeCB, *subCB, *newCB;
+ TQPushButton *arrowBtn1, *arrowBtn2;
+ TQPixmap pmGroup, pmNew;
+ TQIconSet pmRight, pmLeft;
+ TQGridLayout *listL;
+ TQLabel *leftLabel, *rightLabel;
+ TQTimer *refilterTimer;
+ TQString lastFilter;
bool incrementalFilter;
KNNntpAccount *a_ccount;
- QSortedList<KNGroupInfo> *allList, *matchList;
+ TQSortedList<KNGroupInfo> *allList, *matchList;
protected slots:
void slotLoadList();
- void slotItemExpand(QListViewItem *it);
+ void slotItemExpand(TQListViewItem *it);
void slotCenterDelayed();
/** double click checks/unchecks (opens/closes) item */
- void slotItemDoubleClicked(QListViewItem *it);
- void slotFilter(const QString &txt);
+ void slotItemDoubleClicked(TQListViewItem *it);
+ void slotFilter(const TQString &txt);
void slotTreeCBToggled();
void slotSubCBToggled();
void slotNewCBToggled();
- void slotFilterTextChanged(const QString &txt);
+ void slotFilterTextChanged(const TQString &txt);
void slotRefilter();
};
diff --git a/knode/kngroupdialog.cpp b/knode/kngroupdialog.cpp
index b983f724a..64deea4f8 100644
--- a/knode/kngroupdialog.cpp
+++ b/knode/kngroupdialog.cpp
@@ -14,11 +14,11 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qbuttongroup.h>
-#include <qradiobutton.h>
-#include <qcheckbox.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqbuttongroup.h>
+#include <tqradiobutton.h>
+#include <tqcheckbox.h>
#include <kdebug.h>
#include <kglobal.h>
@@ -31,19 +31,19 @@
#include "knnntpaccount.h"
#include "kngroupdialog.h"
#include "knglobals.h"
-#include <qpushbutton.h>
+#include <tqpushbutton.h>
-KNGroupDialog::KNGroupDialog(QWidget *parent, KNNntpAccount *a) :
+KNGroupDialog::KNGroupDialog(TQWidget *parent, KNNntpAccount *a) :
KNGroupBrowser(parent, i18n("Subscribe to Newsgroups"),a, User1 | User2, true, i18n("New &List"), i18n("New &Groups...") )
{
rightLabel->setText(i18n("Current changes:"));
- subView=new QListView(page);
+ subView=new TQListView(page);
subView->addColumn(i18n("Subscribe To"));
- unsubView=new QListView(page);
+ unsubView=new TQListView(page);
unsubView->addColumn(i18n("Unsubscribe From"));
- QVBoxLayout *protL=new QVBoxLayout(3);
+ TQVBoxLayout *protL=new TQVBoxLayout(3);
listL->addLayout(protL, 1,2);
protL->addWidget(subView);
protL->addWidget(unsubView);
@@ -51,19 +51,19 @@ KNGroupDialog::KNGroupDialog(QWidget *parent, KNNntpAccount *a) :
dir1=right;
dir2=left;
- connect(groupView, SIGNAL(selectionChanged(QListViewItem*)),
- this, SLOT(slotItemSelected(QListViewItem*)));
- connect(groupView, SIGNAL(selectionChanged()),
- this, SLOT(slotSelectionChanged()));
- connect(subView, SIGNAL(selectionChanged(QListViewItem*)),
- this, SLOT(slotItemSelected(QListViewItem*)));
- connect(unsubView, SIGNAL(selectionChanged(QListViewItem*)),
- this, SLOT(slotItemSelected(QListViewItem*)));
+ connect(groupView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ this, TQT_SLOT(slotItemSelected(TQListViewItem*)));
+ connect(groupView, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(slotSelectionChanged()));
+ connect(subView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ this, TQT_SLOT(slotItemSelected(TQListViewItem*)));
+ connect(unsubView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ this, TQT_SLOT(slotItemSelected(TQListViewItem*)));
- connect(arrowBtn1, SIGNAL(clicked()), this, SLOT(slotArrowBtn1()));
- connect(arrowBtn2, SIGNAL(clicked()), this, SLOT(slotArrowBtn2()));
+ connect(arrowBtn1, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotArrowBtn1()));
+ connect(arrowBtn2, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotArrowBtn2()));
- KNHelper::restoreWindowSize("groupDlg", this, QSize(662,393)); // optimized for 800x600
+ KNHelper::restoreWindowSize("groupDlg", this, TQSize(662,393)); // optimized for 800x600
setHelp("anc-fetch-group-list");
}
@@ -121,14 +121,14 @@ void KNGroupDialog::updateItemState(CheckItem *it)
-void KNGroupDialog::toSubscribe(QSortedList<KNGroupInfo> *l)
+void KNGroupDialog::toSubscribe(TQSortedList<KNGroupInfo> *l)
{
KNGroupInfo *info;
l->clear();
l->setAutoDelete(true);
bool moderated=false;
- QListViewItemIterator it(subView);
+ TQListViewItemIterator it(subView);
for(; it.current(); ++it) {
info = new KNGroupInfo();
*info = ((static_cast<GroupItem*>(it.current()))->info);
@@ -138,15 +138,15 @@ void KNGroupDialog::toSubscribe(QSortedList<KNGroupInfo> *l)
}
if (moderated) // warn the user
KMessageBox::information(knGlobals.topWidget,i18n("You have subscribed to a moderated newsgroup.\nYour articles will not appear in the group immediately.\nThey have to go through a moderation process."),
- QString::null,"subscribeModeratedWarning");
+ TQString::null,"subscribeModeratedWarning");
}
-void KNGroupDialog::toUnsubscribe(QStringList *l)
+void KNGroupDialog::toUnsubscribe(TQStringList *l)
{
l->clear();
- QListViewItemIterator it(unsubView);
+ TQListViewItemIterator it(unsubView);
for(; it.current(); ++it)
l->append(((static_cast<GroupItem*>(it.current()))->info).name);
}
@@ -155,7 +155,7 @@ void KNGroupDialog::toUnsubscribe(QStringList *l)
void KNGroupDialog::setButtonDirection(arrowButton b, arrowDirection d)
{
- QPushButton *btn=0;
+ TQPushButton *btn=0;
if(b==btn1 && dir1!=d) {
btn=arrowBtn1;
dir1=d;
@@ -175,9 +175,9 @@ void KNGroupDialog::setButtonDirection(arrowButton b, arrowDirection d)
-void KNGroupDialog::slotItemSelected(QListViewItem *it)
+void KNGroupDialog::slotItemSelected(TQListViewItem *it)
{
- const QObject *s=sender();
+ const TQObject *s=sender();
if(s==subView) {
@@ -281,29 +281,29 @@ void KNGroupDialog::slotUser1()
// new groups
void KNGroupDialog::slotUser2()
{
- QDate lastDate = a_ccount->lastNewFetch();
+ TQDate lastDate = a_ccount->lastNewFetch();
KDialogBase *dlg = new KDialogBase( this, 0L, true, i18n("New Groups"), Ok | Cancel, Ok);
- QButtonGroup *btnGrp = new QButtonGroup(i18n("Check for New Groups"),dlg);
+ TQButtonGroup *btnGrp = new TQButtonGroup(i18n("Check for New Groups"),dlg);
dlg->setMainWidget(btnGrp);
- QGridLayout *topL = new QGridLayout(btnGrp,4,2,25,10);
+ TQGridLayout *topL = new TQGridLayout(btnGrp,4,2,25,10);
- QRadioButton *takeLast = new QRadioButton( i18n("Created since last check:"), btnGrp );
+ TQRadioButton *takeLast = new TQRadioButton( i18n("Created since last check:"), btnGrp );
topL->addMultiCellWidget(takeLast, 0, 0, 0, 1);
- QLabel *l = new QLabel(KGlobal::locale()->formatDate(lastDate, false),btnGrp);
+ TQLabel *l = new TQLabel(KGlobal::locale()->formatDate(lastDate, false),btnGrp);
topL->addWidget(l, 1, 1, Qt::AlignLeft);
- connect(takeLast, SIGNAL(toggled(bool)), l, SLOT(setEnabled(bool)));
+ connect(takeLast, TQT_SIGNAL(toggled(bool)), l, TQT_SLOT(setEnabled(bool)));
- QRadioButton *takeCustom = new QRadioButton( i18n("Created since this date:"), btnGrp );
+ TQRadioButton *takeCustom = new TQRadioButton( i18n("Created since this date:"), btnGrp );
topL->addMultiCellWidget(takeCustom, 2, 2, 0, 1);
KDatePicker *dateSel = new KDatePicker(btnGrp, lastDate);
dateSel->setMinimumSize(dateSel->sizeHint());
topL->addWidget(dateSel, 3, 1, Qt::AlignLeft);
- connect(takeCustom, SIGNAL(toggled(bool)), dateSel, SLOT(setEnabled(bool)));
+ connect(takeCustom, TQT_SIGNAL(toggled(bool)), dateSel, TQT_SLOT(setEnabled(bool)));
takeLast->setChecked(true);
dateSel->setEnabled(false);
@@ -314,7 +314,7 @@ void KNGroupDialog::slotUser2()
if (dlg->exec()) {
if (takeCustom->isChecked())
lastDate = dateSel->date();
- a_ccount->setLastNewFetch(QDate::currentDate());
+ a_ccount->setLastNewFetch(TQDate::currentDate());
leftLabel->setText(i18n("Checking for new groups..."));
enableButton(User1,false);
enableButton(User2,false);
diff --git a/knode/kngroupdialog.h b/knode/kngroupdialog.h
index 306a36810..a2d747986 100644
--- a/knode/kngroupdialog.h
+++ b/knode/kngroupdialog.h
@@ -25,11 +25,11 @@ class KNGroupDialog : public KNGroupBrowser {
Q_OBJECT
public:
- KNGroupDialog(QWidget *parent, KNNntpAccount *a);
+ KNGroupDialog(TQWidget *parent, KNNntpAccount *a);
~KNGroupDialog();
- void toSubscribe(QSortedList<KNGroupInfo> *l);
- void toUnsubscribe(QStringList *l);
+ void toSubscribe(TQSortedList<KNGroupInfo> *l);
+ void toUnsubscribe(TQStringList *l);
protected:
enum arrowDirection { right, left };
@@ -37,12 +37,12 @@ class KNGroupDialog : public KNGroupBrowser {
void updateItemState(CheckItem *it);
void itemChangedState(CheckItem *it, bool s);
void setButtonDirection(arrowButton b, arrowDirection d);
- QPushButton *newListBtn;
- QListView *subView, *unsubView;
+ TQPushButton *newListBtn;
+ TQListView *subView, *unsubView;
arrowDirection dir1, dir2;
protected slots:
- void slotItemSelected(QListViewItem *it);
+ void slotItemSelected(TQListViewItem *it);
/** deactivates the button when a root item is selected */
void slotSelectionChanged();
void slotArrowBtn1();
@@ -54,7 +54,7 @@ class KNGroupDialog : public KNGroupBrowser {
signals:
void fetchList(KNNntpAccount *a);
- void checkNew(KNNntpAccount *a,QDate date);
+ void checkNew(KNNntpAccount *a,TQDate date);
};
#endif
diff --git a/knode/kngroupmanager.cpp b/knode/kngroupmanager.cpp
index 584896091..429b93bc5 100644
--- a/knode/kngroupmanager.cpp
+++ b/knode/kngroupmanager.cpp
@@ -14,7 +14,7 @@
#include <stdio.h>
#include <stdlib.h>
-#include <qdir.h>
+#include <tqdir.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -51,7 +51,7 @@ KNGroupInfo::KNGroupInfo()
}
-KNGroupInfo::KNGroupInfo(const QString &n_ame, const QString &d_escription, bool n_ewGroup, bool s_ubscribed, KNGroup::Status s_tatus)
+KNGroupInfo::KNGroupInfo(const TQString &n_ame, const TQString &d_escription, bool n_ewGroup, bool s_ubscribed, KNGroup::Status s_tatus)
: name(n_ame), description(d_escription), newGroup(n_ewGroup), subscribed(s_ubscribed),
status(s_tatus)
{
@@ -81,7 +81,7 @@ bool KNGroupInfo::operator< (const KNGroupInfo &gi2)
KNGroupListData::KNGroupListData()
: codecForDescriptions(0)
{
- groups = new QSortedList<KNGroupInfo>;
+ groups = new TQSortedList<KNGroupInfo>;
groups->setAutoDelete(true);
}
@@ -97,12 +97,12 @@ KNGroupListData::~KNGroupListData()
bool KNGroupListData::readIn(KNProtocolClient *client)
{
KNFile f(path+"groups");
- QCString line;
+ TQCString line;
int sepPos1,sepPos2;
- QString name,description;
+ TQString name,description;
bool sub;
KNGroup::Status status=KNGroup::unknown;
- QTime timer;
+ TQTime timer;
uint size=f.size()+2;
timer.start();
@@ -114,18 +114,18 @@ bool KNGroupListData::readIn(KNProtocolClient *client)
sepPos1 = line.find(' ');
if (sepPos1==-1) { // no description
- name = QString::fromUtf8(line);
- description = QString::null;
+ name = TQString::fromUtf8(line);
+ description = TQString::null;
status = KNGroup::unknown;
} else {
- name = QString::fromUtf8(line.left(sepPos1));
+ name = TQString::fromUtf8(line.left(sepPos1));
sepPos2 = line.find(' ',sepPos1+1);
if (sepPos2==-1) { // no status
- description = QString::fromUtf8(line.right(line.length()-sepPos1-1));
+ description = TQString::fromUtf8(line.right(line.length()-sepPos1-1));
status = KNGroup::unknown;
} else {
- description = QString::fromUtf8(line.right(line.length()-sepPos2-1));
+ description = TQString::fromUtf8(line.right(line.length()-sepPos2-1));
switch (line[sepPos1+1]) {
case 'u': status = KNGroup::unknown;
break;
@@ -165,8 +165,8 @@ bool KNGroupListData::readIn(KNProtocolClient *client)
bool KNGroupListData::writeOut()
{
- QFile f(path+"groups");
- QCString temp;
+ TQFile f(path+"groups");
+ TQCString temp;
if(f.open(IO_WriteOnly)) {
for (KNGroupInfo *i=groups->first(); i; i=groups->next()) {
@@ -196,7 +196,7 @@ bool KNGroupListData::writeOut()
// merge in new groups, we want to preserve the "subscribed"-flag
// of the loaded groups and the "new"-flag of the new groups.
-void KNGroupListData::merge(QSortedList<KNGroupInfo>* newGroups)
+void KNGroupListData::merge(TQSortedList<KNGroupInfo>* newGroups)
{
bool subscribed;
@@ -213,9 +213,9 @@ void KNGroupListData::merge(QSortedList<KNGroupInfo>* newGroups)
}
-QSortedList<KNGroupInfo>* KNGroupListData::extractList()
+TQSortedList<KNGroupInfo>* KNGroupListData::extractList()
{
- QSortedList<KNGroupInfo>* temp = groups;
+ TQSortedList<KNGroupInfo>* temp = groups;
groups = 0;
return temp;
}
@@ -224,8 +224,8 @@ QSortedList<KNGroupInfo>* KNGroupListData::extractList()
//===============================================================================
-KNGroupManager::KNGroupManager(QObject * parent, const char * name)
- : QObject(parent,name)
+KNGroupManager::KNGroupManager(TQObject * parent, const char * name)
+ : TQObject(parent,name)
{
c_urrentGroup=0;
a_rticleMgr = knGlobals.articleManager();
@@ -234,14 +234,14 @@ KNGroupManager::KNGroupManager(QObject * parent, const char * name)
KNGroupManager::~KNGroupManager()
{
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
delete (*it);
}
void KNGroupManager::syncGroups()
{
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
(*it)->syncDynamicData();
(*it)->saveInfo();
}
@@ -252,13 +252,13 @@ void KNGroupManager::loadGroups(KNNntpAccount *a)
{
KNGroup *group;
- QString dir(a->path());
+ TQString dir(a->path());
if (dir.isNull())
return;
- QDir d(dir);
+ TQDir d(dir);
- QStringList entries(d.entryList("*.grpinfo"));
- for(QStringList::Iterator it=entries.begin(); it != entries.end(); ++it) {
+ TQStringList entries(d.entryList("*.grpinfo"));
+ for(TQStringList::Iterator it=entries.begin(); it != entries.end(); ++it) {
group=new KNGroup(a);
if (group->readInfo(dir+(*it))) {
mGroupList.append( group );
@@ -271,19 +271,19 @@ void KNGroupManager::loadGroups(KNNntpAccount *a)
}
-void KNGroupManager::getSubscribed(KNNntpAccount *a, QStringList &l)
+void KNGroupManager::getSubscribed(KNNntpAccount *a, TQStringList &l)
{
l.clear();
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
if ( (*it)->account() == a )
l.append( (*it)->groupname() );
}
-QValueList<KNGroup*> KNGroupManager::groupsOfAccount( KNNntpAccount *a )
+TQValueList<KNGroup*> KNGroupManager::groupsOfAccount( KNNntpAccount *a )
{
- QValueList<KNGroup*> ret;
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
+ TQValueList<KNGroup*> ret;
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
if ( (*it)->account() == a )
ret.append( (*it) );
return ret;
@@ -330,9 +330,9 @@ bool KNGroupManager::unloadHeaders(KNGroup *g, bool force)
}
-KNGroup* KNGroupManager::group(const QString &gName, const KNServerInfo *s)
+KNGroup* KNGroupManager::group(const TQString &gName, const KNServerInfo *s)
{
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
if ( (*it)->account() == s && (*it)->groupname() == gName )
return (*it);
@@ -342,7 +342,7 @@ KNGroup* KNGroupManager::group(const QString &gName, const KNServerInfo *s)
KNGroup* KNGroupManager::firstGroupOfAccount(const KNServerInfo *s)
{
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it )
if ( (*it)->account() == s )
return (*it);
@@ -352,7 +352,7 @@ KNGroup* KNGroupManager::firstGroupOfAccount(const KNServerInfo *s)
void KNGroupManager::expireAll(KNCleanUp *cup)
{
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
if( (*it)->isLocked() || (*it)->lockedArticles() > 0 )
continue;
if ( !(*it)->activeCleanupConfig()->expireToday() )
@@ -366,7 +366,7 @@ void KNGroupManager::expireAll(KNNntpAccount *a)
{
KNCleanUp *cup = new KNCleanUp();
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
if( (*it)->account() != a || (*it)->isLocked() || (*it)->lockedArticles() > 0 )
continue;
@@ -376,7 +376,7 @@ void KNGroupManager::expireAll(KNNntpAccount *a)
cup->start();
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
if( (*it)->account() != a || (*it)->isLocked() || (*it)->lockedArticles() > 0 )
continue;
@@ -393,31 +393,31 @@ void KNGroupManager::expireAll(KNNntpAccount *a)
}
-void KNGroupManager::showGroupDialog(KNNntpAccount *a, QWidget *parent)
+void KNGroupManager::showGroupDialog(KNNntpAccount *a, TQWidget *parent)
{
KNGroupDialog* gDialog=new KNGroupDialog((parent!=0)? parent:knGlobals.topWidget, a);
- connect(gDialog, SIGNAL(loadList(KNNntpAccount*)), this, SLOT(slotLoadGroupList(KNNntpAccount*)));
- connect(gDialog, SIGNAL(fetchList(KNNntpAccount*)), this, SLOT(slotFetchGroupList(KNNntpAccount*)));
- connect(gDialog, SIGNAL(checkNew(KNNntpAccount*,QDate)), this, SLOT(slotCheckForNewGroups(KNNntpAccount*,QDate)));
- connect(this, SIGNAL(newListReady(KNGroupListData*)), gDialog, SLOT(slotReceiveList(KNGroupListData*)));
+ connect(gDialog, TQT_SIGNAL(loadList(KNNntpAccount*)), this, TQT_SLOT(slotLoadGroupList(KNNntpAccount*)));
+ connect(gDialog, TQT_SIGNAL(fetchList(KNNntpAccount*)), this, TQT_SLOT(slotFetchGroupList(KNNntpAccount*)));
+ connect(gDialog, TQT_SIGNAL(checkNew(KNNntpAccount*,TQDate)), this, TQT_SLOT(slotCheckForNewGroups(KNNntpAccount*,TQDate)));
+ connect(this, TQT_SIGNAL(newListReady(KNGroupListData*)), gDialog, TQT_SLOT(slotReceiveList(KNGroupListData*)));
if(gDialog->exec()) {
KNGroup *g=0;
- QStringList lst;
+ TQStringList lst;
gDialog->toUnsubscribe(&lst);
if (lst.count()>0) {
if (KMessageBox::Yes == KMessageBox::questionYesNoList((parent!=0)? parent:knGlobals.topWidget,i18n("Do you really want to unsubscribe\nfrom these groups?"),
- lst, QString::null, i18n("Unsubscribe"), KStdGuiItem::cancel())) {
- for ( QStringList::Iterator it = lst.begin(); it != lst.end(); ++it ) {
+ lst, TQString::null, i18n("Unsubscribe"), KStdGuiItem::cancel())) {
+ for ( TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it ) {
if((g=group(*it, a)))
unsubscribeGroup(g);
}
}
}
- QSortedList<KNGroupInfo> lst2;
+ TQSortedList<KNGroupInfo> lst2;
gDialog->toSubscribe(&lst2);
for(KNGroupInfo *var=lst2.first(); var; var=lst2.next()) {
subscribeGroup(var, a);
@@ -458,7 +458,7 @@ bool KNGroupManager::unsubscribeGroup(KNGroup *g)
acc=g->account();
- QDir dir(acc->path(),g->groupname()+"*");
+ TQDir dir(acc->path(),g->groupname()+"*");
if (dir.exists()) {
if (unloadHeaders(g, true)) {
if(c_urrentGroup==g) {
@@ -570,7 +570,7 @@ void KNGroupManager::checkAll(KNNntpAccount *a, bool silent)
{
if(!a) return;
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
if ( (*it)->account() == a ) {
(*it)->setMaxFetch( knGlobals.configManager()->readNewsGeneral()->maxToFetch() );
if ( silent )
@@ -591,7 +591,7 @@ void KNGroupManager::processJob(KNJobData *j)
if (j->success()) {
if ((j->type()==KNJobData::JTFetchGroups)||(j->type()==KNJobData::JTCheckNewGroups)) {
// update the descriptions of the subscribed groups
- for ( QValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
+ for ( TQValueList<KNGroup*>::Iterator it = mGroupList.begin(); it != mGroupList.end(); ++it ) {
if ( (*it)->account() == j->account() ) {
for ( KNGroupInfo* inf = d->groups->first(); inf; inf = d->groups->next() )
if ( inf->name == (*it)->groupname() ) {
@@ -651,8 +651,8 @@ void KNGroupManager::slotLoadGroupList(KNNntpAccount *a)
KNGroupListData *d = new KNGroupListData();
d->path = a->path();
- if(!QFileInfo(d->path+"groups").exists()) {
- if (KMessageBox::Yes==KMessageBox::questionYesNo(knGlobals.topWidget,i18n("You do not have any groups for this account;\ndo you want to fetch a current list?"), QString::null, i18n("Fetch List"), i18n("Do Not Fetch"))) {
+ if(!TQFileInfo(d->path+"groups").exists()) {
+ if (KMessageBox::Yes==KMessageBox::questionYesNo(knGlobals.topWidget,i18n("You do not have any groups for this account;\ndo you want to fetch a current list?"), TQString::null, i18n("Fetch List"), i18n("Do Not Fetch"))) {
delete d;
slotFetchGroupList(a);
return;
@@ -684,7 +684,7 @@ void KNGroupManager::slotFetchGroupList(KNNntpAccount *a)
// check for new groups (created after the given date)
-void KNGroupManager::slotCheckForNewGroups(KNNntpAccount *a, QDate date)
+void KNGroupManager::slotCheckForNewGroups(KNNntpAccount *a, TQDate date)
{
KNGroupListData *d = new KNGroupListData();
d->path = a->path();
diff --git a/knode/kngroupmanager.h b/knode/kngroupmanager.h
index f3805dc81..f42407126 100644
--- a/knode/kngroupmanager.h
+++ b/knode/kngroupmanager.h
@@ -15,8 +15,8 @@
#ifndef KNGROUPMANAGER_H
#define KNGROUPMANAGER_H
-#include <qobject.h>
-#include <qsortedlist.h>
+#include <tqobject.h>
+#include <tqsortedlist.h>
#include "knjobdata.h"
#include "kngroup.h"
@@ -38,11 +38,11 @@ class KNGroupInfo {
public:
KNGroupInfo();
- KNGroupInfo(const QString &n_ame, const QString &d_escription, bool n_ewGroup=false, bool s_ubscribed=false, KNGroup::Status s_tatus=KNGroup::unknown );
+ KNGroupInfo(const TQString &n_ame, const TQString &d_escription, bool n_ewGroup=false, bool s_ubscribed=false, KNGroup::Status s_tatus=KNGroup::unknown );
~KNGroupInfo();
/** group names will be utf-8 encoded in the future... */
- QString name,description;
+ TQString name,description;
bool newGroup, subscribed;
KNGroup::Status status;
@@ -59,47 +59,47 @@ class KNGroupListData : public KNJobItem {
bool readIn(KNProtocolClient *client=0);
bool writeOut();
- void merge(QSortedList<KNGroupInfo>* newGroups);
+ void merge(TQSortedList<KNGroupInfo>* newGroups);
- QSortedList<KNGroupInfo>* extractList();
+ TQSortedList<KNGroupInfo>* extractList();
- QStringList subscribed;
- QString path;
- QSortedList<KNGroupInfo> *groups;
- QDate fetchSince;
+ TQStringList subscribed;
+ TQString path;
+ TQSortedList<KNGroupInfo> *groups;
+ TQDate fetchSince;
bool getDescriptions;
- QTextCodec *codecForDescriptions;
+ TQTextCodec *codecForDescriptions;
};
//===============================================================================
-class KNGroupManager : public QObject , public KNJobConsumer {
+class KNGroupManager : public TQObject , public KNJobConsumer {
Q_OBJECT
public:
- KNGroupManager(QObject * parent=0, const char * name=0);
+ KNGroupManager(TQObject * parent=0, const char * name=0);
~KNGroupManager();
// group access
void loadGroups(KNNntpAccount *a);
- void getSubscribed(KNNntpAccount *a, QStringList &l);
- QValueList<KNGroup*> groupsOfAccount( KNNntpAccount *a );
+ void getSubscribed(KNNntpAccount *a, TQStringList &l);
+ TQValueList<KNGroup*> groupsOfAccount( KNNntpAccount *a );
bool loadHeaders(KNGroup *g);
bool unloadHeaders(KNGroup *g, bool force=true);
- KNGroup* group(const QString &gName, const KNServerInfo *s);
+ KNGroup* group(const TQString &gName, const KNServerInfo *s);
KNGroup* firstGroupOfAccount(const KNServerInfo *s);
KNGroup* currentGroup() const { return c_urrentGroup; }
bool hasCurrentGroup() const { return (c_urrentGroup!=0); }
void setCurrentGroup(KNGroup *g);
// group handling
- void showGroupDialog(KNNntpAccount *a, QWidget *parent=0);
+ void showGroupDialog(KNNntpAccount *a, TQWidget *parent=0);
void subscribeGroup(const KNGroupInfo *gi, KNNntpAccount *a);
bool unsubscribeGroup(KNGroup *g=0);
void showGroupProperties(KNGroup *g=0);
@@ -119,12 +119,12 @@ class KNGroupManager : public QObject , public KNJobConsumer {
/** fetch group list from server */
void slotFetchGroupList(KNNntpAccount *a);
/** check for new groups (created after the given date) */
- void slotCheckForNewGroups(KNNntpAccount *a, QDate date);
+ void slotCheckForNewGroups(KNNntpAccount *a, TQDate date);
protected:
/** reimplemented from @ref KNJobConsumer */
void processJob(KNJobData *j);
- QValueList<KNGroup*> mGroupList;
+ TQValueList<KNGroup*> mGroupList;
KNGroup *c_urrentGroup;
KNArticleManager *a_rticleMgr;
diff --git a/knode/kngrouppropdlg.cpp b/knode/kngrouppropdlg.cpp
index b93669374..3ad2fee7a 100644
--- a/knode/kngrouppropdlg.cpp
+++ b/knode/kngrouppropdlg.cpp
@@ -12,10 +12,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qgroupbox.h>
-#include <qlayout.h>
-#include <qvbox.h>
-#include <qcheckbox.h>
+#include <tqgroupbox.h>
+#include <tqlayout.h>
+#include <tqvbox.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <klineedit.h>
@@ -26,10 +26,10 @@
#include "utilities.h"
#include "kngroup.h"
#include "kngrouppropdlg.h"
-#include <qlabel.h>
+#include <tqlabel.h>
-KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, QWidget *parent, const char *name )
+KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, TQWidget *parent, const char *name )
: KDialogBase(Tabbed, i18n("Properties of %1").arg(group->groupname()),
Ok|Cancel|Help, Ok, parent, name),
g_rp(group), n_ickChanged(false)
@@ -37,57 +37,57 @@ KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, QWidget *parent, const char *name
// General tab ===============================================
- QWidget *page = addPage(i18n("&General"));
- QVBoxLayout *pageL = new QVBoxLayout(page, 3);
+ TQWidget *page = addPage(i18n("&General"));
+ TQVBoxLayout *pageL = new TQVBoxLayout(page, 3);
// settings
- QGroupBox *gb=new QGroupBox(i18n("Settings"), page);
+ TQGroupBox *gb=new TQGroupBox(i18n("Settings"), page);
pageL->addWidget(gb);
- QGridLayout *grpL=new QGridLayout(gb, 3, 3, 15, 5);
+ TQGridLayout *grpL=new TQGridLayout(gb, 3, 3, 15, 5);
grpL->addRowSpacing(0, fontMetrics().lineSpacing()-9);
n_ick=new KLineEdit(gb);
if (g_rp->hasName())
n_ick->setText(g_rp->name());
- QLabel *l=new QLabel(n_ick, i18n("&Nickname:"), gb);
+ TQLabel *l=new TQLabel(n_ick, i18n("&Nickname:"), gb);
grpL->addWidget(l,1,0);
grpL->addMultiCellWidget(n_ick,1,1,1,2);
- u_seCharset=new QCheckBox(i18n("&Use different default charset:"), gb);
+ u_seCharset=new TQCheckBox(i18n("&Use different default charset:"), gb);
u_seCharset->setChecked(g_rp->useCharset());
grpL->addMultiCellWidget(u_seCharset,2,2,0,1);
- c_harset=new QComboBox(false, gb);
+ c_harset=new TQComboBox(false, gb);
c_harset->insertStringList(knGlobals.configManager()->postNewsTechnical()->composerCharsets());
c_harset->setCurrentItem(knGlobals.configManager()->postNewsTechnical()->indexForCharset(g_rp->defaultCharset()));
c_harset->setEnabled(g_rp->useCharset());
- connect(u_seCharset, SIGNAL(toggled(bool)), c_harset, SLOT(setEnabled(bool)));
+ connect(u_seCharset, TQT_SIGNAL(toggled(bool)), c_harset, TQT_SLOT(setEnabled(bool)));
grpL->addWidget(c_harset, 2,2);
grpL->setColStretch(1,1);
grpL->setColStretch(2,2);
// group name & description
- gb=new QGroupBox(i18n("Description"), page);
+ gb=new TQGroupBox(i18n("Description"), page);
pageL->addWidget(gb);
- grpL=new QGridLayout(gb, 4, 3, 15, 5);
+ grpL=new TQGridLayout(gb, 4, 3, 15, 5);
grpL->addRowSpacing(0, fontMetrics().lineSpacing()-9);
- l=new QLabel(i18n("Name:"), gb);
+ l=new TQLabel(i18n("Name:"), gb);
grpL->addWidget(l,1,0);
- l=new QLabel(group->groupname(),gb);
+ l=new TQLabel(group->groupname(),gb);
grpL->addWidget(l,1,2);
- l=new QLabel(i18n("Description:"), gb);
+ l=new TQLabel(i18n("Description:"), gb);
grpL->addWidget(l,2,0);
- l=new QLabel(g_rp->description(),gb);
+ l=new TQLabel(g_rp->description(),gb);
grpL->addWidget(l,2,2);
- l=new QLabel(i18n("Status:"), gb);
+ l=new TQLabel(i18n("Status:"), gb);
grpL->addWidget(l,3,0);
- QString status;
+ TQString status;
switch (g_rp->status()) {
case KNGroup::unknown: status=i18n("unknown");
break;
@@ -98,42 +98,42 @@ KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, QWidget *parent, const char *name
case KNGroup::moderated: status=i18n("moderated");
break;
}
- l=new QLabel(status,gb);
+ l=new TQLabel(status,gb);
grpL->addWidget(l,3,2);
grpL->addColSpacing(1,20);
grpL->setColStretch(2,1);
// statistics
- gb=new QGroupBox(i18n("Statistics"), page);
+ gb=new TQGroupBox(i18n("Statistics"), page);
pageL->addWidget(gb);
- grpL=new QGridLayout(gb, 6, 3, 15, 5);
+ grpL=new TQGridLayout(gb, 6, 3, 15, 5);
grpL->addRowSpacing(0, fontMetrics().lineSpacing()-9);
- l=new QLabel(i18n("Articles:"), gb);
+ l=new TQLabel(i18n("Articles:"), gb);
grpL->addWidget(l,1,0);
- l=new QLabel(QString::number(g_rp->count()),gb);
+ l=new TQLabel(TQString::number(g_rp->count()),gb);
grpL->addWidget(l,1,2);
- l=new QLabel(i18n("Unread articles:"), gb);
+ l=new TQLabel(i18n("Unread articles:"), gb);
grpL->addWidget(l,2,0);
- l=new QLabel(QString::number(g_rp->count()-g_rp->readCount()),gb);
+ l=new TQLabel(TQString::number(g_rp->count()-g_rp->readCount()),gb);
grpL->addWidget(l,2,2);
- l=new QLabel(i18n("New articles:"), gb);
+ l=new TQLabel(i18n("New articles:"), gb);
grpL->addWidget(l,3,0);
- l=new QLabel(QString::number(g_rp->newCount()),gb);
+ l=new TQLabel(TQString::number(g_rp->newCount()),gb);
grpL->addWidget(l,3,2);
- l=new QLabel(i18n("Threads with unread articles:"), gb);
+ l=new TQLabel(i18n("Threads with unread articles:"), gb);
grpL->addWidget(l,4,0);
- l=new QLabel(QString::number(g_rp->statThrWithUnread()),gb);
+ l=new TQLabel(TQString::number(g_rp->statThrWithUnread()),gb);
grpL->addWidget(l,4,2);
- l=new QLabel(i18n("Threads with new articles:"), gb);
+ l=new TQLabel(i18n("Threads with new articles:"), gb);
grpL->addWidget(l,5,0);
- l=new QLabel(QString::number(g_rp->statThrWithNew()),gb);
+ l=new TQLabel(TQString::number(g_rp->statThrWithNew()),gb);
grpL->addWidget(l,5,2);
grpL->addColSpacing(1,20);
@@ -145,8 +145,8 @@ KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, QWidget *parent, const char *name
i_dWidget=new KNConfig::IdentityWidget(g_rp->identity(), addVBoxPage(i18n("&Identity")));
// per server cleanup configuration
- QFrame* cleanupPage = addPage( i18n("&Cleanup") );
- QVBoxLayout *cleanupLayout = new QVBoxLayout( cleanupPage, KDialog::spacingHint() );
+ TQFrame* cleanupPage = addPage( i18n("&Cleanup") );
+ TQVBoxLayout *cleanupLayout = new TQVBoxLayout( cleanupPage, KDialog::spacingHint() );
mCleanupWidget = new KNConfig::GroupCleanupWidget( g_rp->cleanupConfig(), cleanupPage );
mCleanupWidget->load();
cleanupLayout->addWidget( mCleanupWidget );
diff --git a/knode/kngrouppropdlg.h b/knode/kngrouppropdlg.h
index 3b67df9dc..c5a17a702 100644
--- a/knode/kngrouppropdlg.h
+++ b/knode/kngrouppropdlg.h
@@ -35,7 +35,7 @@ namespace KNConfig {
class KNGroupPropDlg : public KDialogBase {
public:
- KNGroupPropDlg(KNGroup *group, QWidget *parent=0, const char *name=0);
+ KNGroupPropDlg(KNGroup *group, TQWidget *parent=0, const char *name=0);
~KNGroupPropDlg();
bool nickHasChanged()const { return n_ickChanged; }
@@ -46,8 +46,8 @@ class KNGroupPropDlg : public KDialogBase {
KNConfig::IdentityWidget* i_dWidget;
KNConfig::GroupCleanupWidget *mCleanupWidget;
KLineEdit *n_ick;
- QCheckBox *u_seCharset;
- QComboBox *c_harset;
+ TQCheckBox *u_seCharset;
+ TQComboBox *c_harset;
protected slots:
void slotOk();
diff --git a/knode/kngroupselectdialog.cpp b/knode/kngroupselectdialog.cpp
index e9ac3a2dd..2cb024011 100644
--- a/knode/kngroupselectdialog.cpp
+++ b/knode/kngroupselectdialog.cpp
@@ -14,46 +14,46 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qlabel.h>
-#include <qheader.h>
-#include <qcheckbox.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
+#include <tqheader.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <kmessagebox.h>
#include "utilities.h"
#include "kngroupselectdialog.h"
-#include <qpushbutton.h>
+#include <tqpushbutton.h>
-KNGroupSelectDialog::KNGroupSelectDialog(QWidget *parent, KNNntpAccount *a, const QString &act) :
+KNGroupSelectDialog::KNGroupSelectDialog(TQWidget *parent, KNNntpAccount *a, const TQString &act) :
KNGroupBrowser(parent, i18n("Select Destinations"), a)
{
- selView=new QListView(page);
- selView->addColumn(QString::null);
+ selView=new TQListView(page);
+ selView->addColumn(TQString::null);
selView->header()->hide();
listL->addWidget(selView, 1,2);
rightLabel->setText(i18n("Groups for this article:"));
subCB->setChecked(true);
KNGroupInfo info;
- QStringList actGroups = QStringList::split(',',act);
- for ( QStringList::Iterator it = actGroups.begin(); it != actGroups.end(); ++it ) {
+ TQStringList actGroups = TQStringList::split(',',act);
+ for ( TQStringList::Iterator it = actGroups.begin(); it != actGroups.end(); ++it ) {
info.name = *it;
new GroupItem(selView, info);
}
- connect(selView, SIGNAL(selectionChanged(QListViewItem*)),
- this, SLOT(slotItemSelected(QListViewItem*)));
- connect(groupView, SIGNAL(selectionChanged(QListViewItem*)),
- this, SLOT(slotItemSelected(QListViewItem*)));
- connect(groupView, SIGNAL(selectionChanged()),
- this, SLOT(slotSelectionChanged()));
- connect(arrowBtn1, SIGNAL(clicked()), this, SLOT(slotArrowBtn1()));
- connect(arrowBtn2, SIGNAL(clicked()), this, SLOT(slotArrowBtn2()));
+ connect(selView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ this, TQT_SLOT(slotItemSelected(TQListViewItem*)));
+ connect(groupView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ this, TQT_SLOT(slotItemSelected(TQListViewItem*)));
+ connect(groupView, TQT_SIGNAL(selectionChanged()),
+ this, TQT_SLOT(slotSelectionChanged()));
+ connect(arrowBtn1, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotArrowBtn1()));
+ connect(arrowBtn2, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotArrowBtn2()));
- KNHelper::restoreWindowSize("groupSelDlg", this, QSize(659,364)); // optimized for 800x600
+ KNHelper::restoreWindowSize("groupSelDlg", this, TQSize(659,364)); // optimized for 800x600
}
@@ -85,10 +85,10 @@ void KNGroupSelectDialog::updateItemState(CheckItem *it)
-QString KNGroupSelectDialog::selectedGroups()const
+TQString KNGroupSelectDialog::selectedGroups()const
{
- QString ret;
- QListViewItemIterator it(selView);
+ TQString ret;
+ TQListViewItemIterator it(selView);
bool moderated=false;
int count=0;
bool isFirst=true;
@@ -105,16 +105,16 @@ QString KNGroupSelectDialog::selectedGroups()const
if (moderated && (count>=2)) // warn the user
KMessageBox::information(parentWidget(),i18n("You are crossposting to a moderated newsgroup.\nPlease be aware that your article will not appear in any group\nuntil it has been approved by the moderators of the moderated group."),
- QString::null,"crosspostModeratedWarning");
+ TQString::null,"crosspostModeratedWarning");
return ret;
}
-void KNGroupSelectDialog::slotItemSelected(QListViewItem *it)
+void KNGroupSelectDialog::slotItemSelected(TQListViewItem *it)
{
- const QObject *s=sender();
+ const TQObject *s=sender();
if(s==groupView) {
selView->clearSelection();
diff --git a/knode/kngroupselectdialog.h b/knode/kngroupselectdialog.h
index d46826cc3..11c6fd39b 100644
--- a/knode/kngroupselectdialog.h
+++ b/knode/kngroupselectdialog.h
@@ -25,18 +25,18 @@ class KNGroupSelectDialog : public KNGroupBrowser {
Q_OBJECT
public:
- KNGroupSelectDialog(QWidget *parent, KNNntpAccount *a, const QString &act);
+ KNGroupSelectDialog(TQWidget *parent, KNNntpAccount *a, const TQString &act);
~KNGroupSelectDialog();
- QString selectedGroups()const;
+ TQString selectedGroups()const;
void itemChangedState(CheckItem *it, bool s);
protected:
void updateItemState(CheckItem *it);
- QListView *selView;
+ TQListView *selView;
protected slots:
- void slotItemSelected(QListViewItem *it);
+ void slotItemSelected(TQListViewItem *it);
/** deactivates the button when a root item is selected */
void slotSelectionChanged();
void slotArrowBtn1();
diff --git a/knode/knhdrviewitem.cpp b/knode/knhdrviewitem.cpp
index 93b54fc0a..e547b11d9 100644
--- a/knode/knhdrviewitem.cpp
+++ b/knode/knhdrviewitem.cpp
@@ -14,8 +14,8 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qdragobject.h>
-#include <qpainter.h>
+#include <tqdragobject.h>
+#include <tqpainter.h>
#include <kdeversion.h>
#include <kdebug.h>
@@ -54,7 +54,7 @@ void KNHdrViewItem::init( KNArticle *a )
KNHdrViewItem::~KNHdrViewItem()
{
if (mActive) {
- QListView *lv = listView();
+ TQListView *lv = listView();
if (lv)
static_cast<KNHeaderView*>( lv )->activeRemoved();
}
@@ -65,7 +65,7 @@ KNHdrViewItem::~KNHdrViewItem()
void KNHdrViewItem::expandChildren()
{
- QListViewItemIterator it( firstChild() );
+ TQListViewItemIterator it( firstChild() );
for ( ; it.current(); ++it) {
if (it.current()->depth() <= depth())
break;
@@ -74,7 +74,7 @@ void KNHdrViewItem::expandChildren()
}
-int KNHdrViewItem::compare( QListViewItem *i, int col, bool ) const
+int KNHdrViewItem::compare( TQListViewItem *i, int col, bool ) const
{
KNArticle *otherArticle = static_cast<KNHdrViewItem*>( i )->art;
int diff = 0;
@@ -114,13 +114,13 @@ int KNHdrViewItem::compare( QListViewItem *i, int col, bool ) const
}
-void KNHdrViewItem::paintCell( QPainter *p, const QColorGroup &cg, int column, int width, int alignment )
+void KNHdrViewItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int alignment )
{
int xText = 0, xPM = 3, yPM = 0;
- QColor base;
+ TQColor base;
const KPaintInfo *paintInfo = static_cast<KNHeaderView*>( listView() )->paintInfo();
- QPen pen = p->pen();
+ TQPen pen = p->pen();
if (isSelected() || mActive) {
pen.setColor( cg.highlightedText() );
base = cg.highlight();
@@ -134,13 +134,13 @@ void KNHdrViewItem::paintCell( QPainter *p, const QColorGroup &cg, int column, i
p->setPen( pen );
- p->fillRect( 0, 0, width, height(), QBrush(base) );
+ p->fillRect( 0, 0, width, height(), TQBrush(base) );
if ( column == paintInfo->subCol ) {
- QFont font = p->font();
+ TQFont font = p->font();
font.setBold( firstColBold() );
p->setFont( font );
- const QPixmap *pm;
+ const TQPixmap *pm;
for (int i = 0; i < 4; i++) {
pm = pixmap( i );
@@ -156,15 +156,15 @@ void KNHdrViewItem::paintCell( QPainter *p, const QColorGroup &cg, int column, i
if (width - xText - 5 > 0) {
int cntWidth = 0;
- QString t2;
- QFont f2;
+ TQString t2;
+ TQFont f2;
if (countUnreadInThread() > 0 && column == paintInfo->subCol && !isOpen()) {
- t2 = QString( " (%1)" ).arg( countUnreadInThread() );
+ t2 = TQString( " (%1)" ).arg( countUnreadInThread() );
f2 = p->font();
f2.setBold( true );
- cntWidth = QFontMetrics( f2 ).width( t2, -1 );
+ cntWidth = TQFontMetrics( f2 ).width( t2, -1 );
}
- QString t = KStringHandler::rPixelSqueeze( text( column ), p->fontMetrics(), width - xText - cntWidth - 5 );
+ TQString t = KStringHandler::rPixelSqueeze( text( column ), p->fontMetrics(), width - xText - cntWidth - 5 );
// show tooltip if we have to squeeze the text
if ( t != text( column ) )
@@ -174,29 +174,29 @@ void KNHdrViewItem::paintCell( QPainter *p, const QColorGroup &cg, int column, i
p->drawText( xText, 0, width - xText - 5, height(), alignment | AlignVCenter, t );
if (cntWidth) {
- QFont orig = p->font();
+ TQFont orig = p->font();
p->setFont( f2 );
- QPen pen = p->pen();
+ TQPen pen = p->pen();
if (isSelected() || mActive) {
pen.setColor( cg.highlightedText() );
} else {
pen.setColor( cg.link() );
}
p->setPen( pen );
- p->drawText( xText + QFontMetrics( orig ).width( t, -1 ), 0, width - xText - 5, height(), alignment | AlignVCenter, t2 );
+ p->drawText( xText + TQFontMetrics( orig ).width( t, -1 ), 0, width - xText - 5, height(), alignment | AlignVCenter, t2 );
}
}
}
-int KNHdrViewItem::width( const QFontMetrics &fm, const QListView *, int column )
+int KNHdrViewItem::width( const TQFontMetrics &fm, const TQListView *, int column )
{
int ret = fm.boundingRect( text(column) ).width();
const KPaintInfo *paintInfo = static_cast<KNHeaderView*>( listView() )->paintInfo();
// all pixmaps are drawn in the first column
if ( column == paintInfo->subCol ) {
- const QPixmap *pm;
+ const TQPixmap *pm;
for (int i = 0; i < 4; ++i) {
pm = pixmap( i );
if (pm && !pm->isNull())
@@ -208,10 +208,10 @@ int KNHdrViewItem::width( const QFontMetrics &fm, const QListView *, int column
}
-QString KNHdrViewItem::text( int col ) const
+TQString KNHdrViewItem::text( int col ) const
{
if ( !art )
- return QString::null;
+ return TQString::null;
KNHeaderView *hv = static_cast<KNHeaderView*>( listView() );
if ( col == hv->paintInfo()->subCol ) {
@@ -220,16 +220,16 @@ QString KNHdrViewItem::text( int col ) const
if ( col == hv->paintInfo()->sizeCol ) {
if ( art->lines()->numberOfLines() != -1 )
- return QString::number( art->lines()->numberOfLines() );
+ return TQString::number( art->lines()->numberOfLines() );
else
- return QString::null;
+ return TQString::null;
}
if ( col == hv->paintInfo()->scoreCol ) {
if ( art->type() == KMime::Base::ATremote )
- return QString::number( static_cast<KNRemoteArticle*>( art )->score() );
+ return TQString::number( static_cast<KNRemoteArticle*>( art )->score() );
else
- return QString::null;
+ return TQString::null;
}
if ( col == hv->paintInfo()->dateCol ) {
@@ -239,9 +239,9 @@ QString KNHdrViewItem::text( int col ) const
}
-QDragObject* KNHdrViewItem::dragObject()
+TQDragObject* KNHdrViewItem::dragObject()
{
- QDragObject *d = new QStoredDrag( "x-knode-drag/article" , listView()->viewport() );
+ TQDragObject *d = new TQStoredDrag( "x-knode-drag/article" , listView()->viewport() );
d->setPixmap( knGlobals.configManager()->appearance()->icon( KNConfig::Appearance::posting ) );
return d;
}
@@ -278,7 +278,7 @@ bool KNHdrViewItem::firstColBold()
}
-QColor KNHdrViewItem::normalColor()
+TQColor KNHdrViewItem::normalColor()
{
if (art->type()==KMime::Base::ATremote)
return static_cast<KNRemoteArticle*>( art )->color();
@@ -287,7 +287,7 @@ QColor KNHdrViewItem::normalColor()
}
-QColor KNHdrViewItem::greyColor()
+TQColor KNHdrViewItem::greyColor()
{
return knGlobals.configManager()->appearance()->readThreadColor();
}
diff --git a/knode/knhdrviewitem.h b/knode/knhdrviewitem.h
index a080c8381..476c6d53c 100644
--- a/knode/knhdrviewitem.h
+++ b/knode/knhdrviewitem.h
@@ -31,12 +31,12 @@ class KNHdrViewItem : public KListViewItem {
KNHdrViewItem( KNHdrViewItem *ref, KNArticle *a = 0 );
~KNHdrViewItem();
- virtual int compare(QListViewItem *i, int col, bool ascending) const;
+ virtual int compare(TQListViewItem *i, int col, bool ascending) const;
- void paintCell(QPainter *p, const QColorGroup &cg, int column, int width, int alignment);
- int width(const QFontMetrics &fm, const QListView *lv, int column);
+ void paintCell(TQPainter *p, const TQColorGroup &cg, int column, int width, int alignment);
+ int width(const TQFontMetrics &fm, const TQListView *lv, int column);
- virtual QString text( int col ) const;
+ virtual TQString text( int col ) const;
void expandChildren();
@@ -44,7 +44,7 @@ class KNHdrViewItem : public KListViewItem {
bool isActive() const { return mActive; }
// DND
- QDragObject* dragObject();
+ TQDragObject* dragObject();
KNArticle *art;
int countUnreadInThread();
@@ -56,8 +56,8 @@ class KNHdrViewItem : public KListViewItem {
bool greyOut();
bool firstColBold();
- QColor normalColor();
- QColor greyColor();
+ TQColor normalColor();
+ TQColor greyColor();
bool mActive;
bool mShowToolTip[5]; // ### hardcoded column count :-(
diff --git a/knode/knjobdata.cpp b/knode/knjobdata.cpp
index 7d8cb6f8f..5d46c29d9 100644
--- a/knode/knjobdata.cpp
+++ b/knode/knjobdata.cpp
@@ -24,7 +24,7 @@
#include "knnetaccess.h"
#include "knnntpaccount.h"
-#include <qstylesheet.h>
+#include <tqstylesheet.h>
KNJobConsumer::KNJobConsumer()
{
@@ -33,7 +33,7 @@ KNJobConsumer::KNJobConsumer()
KNJobConsumer::~KNJobConsumer()
{
- QValueList<KNJobData*>::Iterator it;
+ TQValueList<KNJobData*>::Iterator it;
for ( it = mJobs.begin(); it != mJobs.end(); ++it )
(*it)->c_onsumer = 0;
}
@@ -105,10 +105,10 @@ void KNJobData::setJob( KIO::Job *job )
{
mJob = job;
if ( job ) {
- connect( job, SIGNAL( percent(KIO::Job*, unsigned long) ),
- SLOT( slotJobPercent(KIO::Job*, unsigned long) ) );
- connect( job, SIGNAL( infoMessage(KIO::Job*, const QString&) ),
- SLOT( slotJobInfoMessage(KIO::Job*, const QString&) ) );
+ connect( job, TQT_SIGNAL( percent(KIO::Job*, unsigned long) ),
+ TQT_SLOT( slotJobPercent(KIO::Job*, unsigned long) ) );
+ connect( job, TQT_SIGNAL( infoMessage(KIO::Job*, const TQString&) ),
+ TQT_SLOT( slotJobInfoMessage(KIO::Job*, const TQString&) ) );
}
}
@@ -117,12 +117,12 @@ void KNJobData::createProgressItem()
if ( mProgressItem )
return;
KNNntpAccount *acc = static_cast<KNNntpAccount*>( account() );
- QString msg = i18n( "KNode" );
+ TQString msg = i18n( "KNode" );
if ( type() == JTmail )
msg = i18n( "Sending message" );
else {
if ( acc )
- msg = QStyleSheet::escape( acc->name() );
+ msg = TQStyleSheet::escape( acc->name() );
}
bool encr = false;
if ( acc && acc->encryption() != KNServerInfo::None )
@@ -137,7 +137,7 @@ void KNJobData::slotJobPercent( KIO::Job*, unsigned long percent )
setProgress( percent );
}
-void KNJobData::slotJobInfoMessage( KIO::Job*, const QString &msg )
+void KNJobData::slotJobInfoMessage( KIO::Job*, const TQString &msg )
{
kdDebug(5003) << k_funcinfo << "Status: " << msg << endl;
setStatus( msg );
diff --git a/knode/knjobdata.h b/knode/knjobdata.h
index 5733a9883..35b54e934 100644
--- a/knode/knjobdata.h
+++ b/knode/knjobdata.h
@@ -15,8 +15,8 @@
#ifndef KNJOBDATA_H
#define KNJOBDATA_H
-#include <qobject.h>
-#include <qvaluelist.h>
+#include <tqobject.h>
+#include <tqvaluelist.h>
#include <libkdepim/progressmanager.h>
@@ -49,7 +49,7 @@ class KNJobConsumer {
protected:
/** The actual work is done here */
virtual void processJob(KNJobData *j);
- QValueList<KNJobData*> mJobs;
+ TQValueList<KNJobData*> mJobs;
};
@@ -63,7 +63,7 @@ class KNJobItem {
virtual bool isLocked() { return false; }
virtual void setLocked(bool) { }
- virtual QString prepareForExecution() { return QString::null; }
+ virtual TQString prepareForExecution() { return TQString::null; }
};
@@ -95,12 +95,12 @@ class KNJobData : public QObject
KNServerInfo* account() const { return a_ccount; }
KNJobItem* data() const { return d_ata; }
- const QString& errorString() const { return e_rrorString; }
+ const TQString& errorString() const { return e_rrorString; }
bool success() const { return e_rrorString.isEmpty(); }
bool canceled() const { return c_anceled; }
bool authError() const { return a_uthError; }
- void setErrorString(const QString& s) { e_rrorString=s; }
+ void setErrorString(const TQString& s) { e_rrorString=s; }
void cancel();
void setAuthError(bool b) { a_uthError=b; }
@@ -114,7 +114,7 @@ class KNJobData : public QObject
void createProgressItem();
// safe forwards to the progress item
- void setStatus( const QString &msg ) { if ( mProgressItem ) mProgressItem->setStatus( msg ); }
+ void setStatus( const TQString &msg ) { if ( mProgressItem ) mProgressItem->setStatus( msg ); }
void setProgress( unsigned int progress ) { if ( mProgressItem ) mProgressItem->setProgress( progress ); }
void setComplete() { if ( mProgressItem ) { mProgressItem->setComplete(); mProgressItem = 0; } }
@@ -122,14 +122,14 @@ class KNJobData : public QObject
jobType t_ype;
KNJobItem *d_ata;
KNServerInfo *a_ccount;
- QString e_rrorString;
+ TQString e_rrorString;
bool c_anceled;
bool a_uthError;
KNJobConsumer *c_onsumer;
private slots:
void slotJobPercent( KIO::Job *job, unsigned long percent );
- void slotJobInfoMessage( KIO::Job *job, const QString &msg );
+ void slotJobInfoMessage( KIO::Job *job, const TQString &msg );
private:
KIO::Job *mJob;
diff --git a/knode/knmainwidget.cpp b/knode/knmainwidget.cpp
index e4d91e812..0697a919e 100644
--- a/knode/knmainwidget.cpp
+++ b/knode/knmainwidget.cpp
@@ -13,8 +13,8 @@
*/
#include "knmainwidget.h"
-#include <qhbox.h>
-#include <qlayout.h>
+#include <tqhbox.h>
+#include <tqlayout.h>
#include <ktoolbar.h>
#include <kinputdialog.h>
@@ -70,7 +70,7 @@ using namespace KNode;
KNGlobals knGlobals;
-KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* parent,
+KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, TQWidget* parent,
const char* name )
: DCOPObject("KNodeIface"), KDockArea( parent, name ),
b_lockui( false ), m_GUIClient( client )
@@ -84,7 +84,7 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
//------------------------------- </CONFIG> ----------------------------------
//-------------------------------- <GUI> ------------------------------------
- QAccel *accel = new QAccel( this );
+ TQAccel *accel = new TQAccel( this );
initStatusBar();
//setup splitter behavior
@@ -106,9 +106,9 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
//setView(a_rtDock);
setMainDockWidget(a_rtDock);
- connect(a_rtDock, SIGNAL(iMBeingClosed()), SLOT(slotArticleDockHidden()));
- connect(a_rtDock, SIGNAL(hasUndocked()), SLOT(slotArticleDockHidden()));
- connect( mArticleViewer, SIGNAL(focusChangeRequest(QWidget*)), SLOT(slotDockWidgetFocusChangeRequest(QWidget*)) );
+ connect(a_rtDock, TQT_SIGNAL(iMBeingClosed()), TQT_SLOT(slotArticleDockHidden()));
+ connect(a_rtDock, TQT_SIGNAL(hasUndocked()), TQT_SLOT(slotArticleDockHidden()));
+ connect( mArticleViewer, TQT_SIGNAL(focusChangeRequest(TQWidget*)), TQT_SLOT(slotDockWidgetFocusChangeRequest(TQWidget*)) );
//collection view
c_olDock = createDockWidget("group_view", UserIcon("group"), 0,
@@ -123,22 +123,22 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
c_olDock->setWidget(c_olView);
c_olDock->manualDock(a_rtDock, KDockWidget::DockLeft, 3000);
- connect(c_olDock, SIGNAL(iMBeingClosed()), SLOT(slotGroupDockHidden()));
- connect(c_olDock, SIGNAL(hasUndocked()), SLOT(slotGroupDockHidden()));
- connect(c_olView, SIGNAL(focusChangeRequest(QWidget *)), SLOT(slotDockWidgetFocusChangeRequest(QWidget *)));
- connect(c_olView, SIGNAL(selectionChanged(QListViewItem*)),
- SLOT(slotCollectionSelected(QListViewItem*)));
- connect(c_olView, SIGNAL(contextMenu(KListView*, QListViewItem*, const QPoint&)),
- SLOT(slotCollectionRMB(KListView*, QListViewItem*, const QPoint&)));
- connect(c_olView, SIGNAL(folderDrop(QDropEvent*, KNCollectionViewItem*)),
- SLOT(slotCollectionViewDrop(QDropEvent*, KNCollectionViewItem*)));
- connect(c_olView, SIGNAL(itemRenamed(QListViewItem*)),
- SLOT(slotCollectionRenamed(QListViewItem*)));
-
- accel->connectItem( accel->insertItem(Key_Up), mArticleViewer, SLOT(scrollUp()) );
- accel->connectItem( accel->insertItem(Key_Down), mArticleViewer, SLOT(scrollDown()) );
- accel->connectItem( accel->insertItem(Key_Prior), mArticleViewer, SLOT(scrollPrior()) );
- accel->connectItem( accel->insertItem(Key_Next), mArticleViewer, SLOT(scrollNext()) );
+ connect(c_olDock, TQT_SIGNAL(iMBeingClosed()), TQT_SLOT(slotGroupDockHidden()));
+ connect(c_olDock, TQT_SIGNAL(hasUndocked()), TQT_SLOT(slotGroupDockHidden()));
+ connect(c_olView, TQT_SIGNAL(focusChangeRequest(TQWidget *)), TQT_SLOT(slotDockWidgetFocusChangeRequest(TQWidget *)));
+ connect(c_olView, TQT_SIGNAL(selectionChanged(TQListViewItem*)),
+ TQT_SLOT(slotCollectionSelected(TQListViewItem*)));
+ connect(c_olView, TQT_SIGNAL(contextMenu(KListView*, TQListViewItem*, const TQPoint&)),
+ TQT_SLOT(slotCollectionRMB(KListView*, TQListViewItem*, const TQPoint&)));
+ connect(c_olView, TQT_SIGNAL(folderDrop(TQDropEvent*, KNCollectionViewItem*)),
+ TQT_SLOT(slotCollectionViewDrop(TQDropEvent*, KNCollectionViewItem*)));
+ connect(c_olView, TQT_SIGNAL(itemRenamed(TQListViewItem*)),
+ TQT_SLOT(slotCollectionRenamed(TQListViewItem*)));
+
+ accel->connectItem( accel->insertItem(Key_Up), mArticleViewer, TQT_SLOT(scrollUp()) );
+ accel->connectItem( accel->insertItem(Key_Down), mArticleViewer, TQT_SLOT(scrollDown()) );
+ accel->connectItem( accel->insertItem(Key_Prior), mArticleViewer, TQT_SLOT(scrollPrior()) );
+ accel->connectItem( accel->insertItem(Key_Next), mArticleViewer, TQT_SLOT(scrollNext()) );
//header view
h_drDock = createDockWidget("header_view", SmallIcon("text_block"), 0,
@@ -148,8 +148,8 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
}
header = new KDockWidgetHeader(h_drDock, "headerDockHeader");
h_drDock->setHeader(header);
- QWidget *dummy = new QWidget(h_drDock);
- QVBoxLayout *vlay = new QVBoxLayout(dummy);
+ TQWidget *dummy = new TQWidget(h_drDock);
+ TQVBoxLayout *vlay = new TQVBoxLayout(dummy);
h_drView = new KNHeaderView( dummy, "hdrView" );
header->setDragPanel(new KNDockWidgetHeaderDrag(h_drView, header, h_drDock));
h_drDock->setWidget(dummy);
@@ -157,7 +157,7 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
q_uicksearch = new KToolBar(dummy, "search toolbar");
KAction *resetQuickSearch = new KAction( i18n( "Reset Quick Search" ),
- QApplication::reverseLayout()
+ TQApplication::reverseLayout()
? "clear_left"
: "locationbar_erase",
0, actionCollection(),
@@ -167,29 +167,29 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
"Resets the quick search so that "
"all messages are shown again." ) );
- QLabel *lbl = new QLabel(i18n("&Search:"), q_uicksearch, "kde toolbar widget");
+ TQLabel *lbl = new TQLabel(i18n("&Search:"), q_uicksearch, "kde toolbar widget");
s_earchLineEdit = new KListViewSearchLine(q_uicksearch, h_drView, "KListViewSearchLine");
q_uicksearch->setStretchableWidget(s_earchLineEdit);
lbl->setBuddy(s_earchLineEdit);
- connect( resetQuickSearch, SIGNAL( activated() ), s_earchLineEdit, SLOT( clear() ));
+ connect( resetQuickSearch, TQT_SIGNAL( activated() ), s_earchLineEdit, TQT_SLOT( clear() ));
vlay->addWidget(q_uicksearch);
vlay->addWidget(h_drView);
- connect(h_drDock, SIGNAL(iMBeingClosed()), SLOT(slotHeaderDockHidden()));
- connect(h_drDock, SIGNAL(hasUndocked()), SLOT(slotHeaderDockHidden()));
- connect(h_drView, SIGNAL(focusChangeRequest(QWidget *)),
- SLOT(slotDockWidgetFocusChangeRequest(QWidget *)));
- connect(h_drView, SIGNAL(itemSelected(QListViewItem*)),
- SLOT(slotArticleSelected(QListViewItem*)));
- connect(h_drView, SIGNAL(selectionChanged()),
- SLOT(slotArticleSelectionChanged()));
- connect(h_drView, SIGNAL(contextMenu(KListView*, QListViewItem*, const QPoint&)),
- SLOT(slotArticleRMB(KListView*, QListViewItem*, const QPoint&)));
- connect(h_drView, SIGNAL(doubleClick(QListViewItem *)),
- SLOT(slotOpenArticle(QListViewItem *)));
- connect(h_drView, SIGNAL(sortingChanged(int)),
- SLOT(slotHdrViewSortingChanged(int)));
+ connect(h_drDock, TQT_SIGNAL(iMBeingClosed()), TQT_SLOT(slotHeaderDockHidden()));
+ connect(h_drDock, TQT_SIGNAL(hasUndocked()), TQT_SLOT(slotHeaderDockHidden()));
+ connect(h_drView, TQT_SIGNAL(focusChangeRequest(TQWidget *)),
+ TQT_SLOT(slotDockWidgetFocusChangeRequest(TQWidget *)));
+ connect(h_drView, TQT_SIGNAL(itemSelected(TQListViewItem*)),
+ TQT_SLOT(slotArticleSelected(TQListViewItem*)));
+ connect(h_drView, TQT_SIGNAL(selectionChanged()),
+ TQT_SLOT(slotArticleSelectionChanged()));
+ connect(h_drView, TQT_SIGNAL(contextMenu(KListView*, TQListViewItem*, const TQPoint&)),
+ TQT_SLOT(slotArticleRMB(KListView*, TQListViewItem*, const TQPoint&)));
+ connect(h_drView, TQT_SIGNAL(doubleClick(TQListViewItem *)),
+ TQT_SLOT(slotOpenArticle(TQListViewItem *)));
+ connect(h_drView, TQT_SIGNAL(sortingChanged(int)),
+ TQT_SLOT(slotHdrViewSortingChanged(int)));
//actions
initActions();
@@ -200,7 +200,7 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
//Network
n_etAccess = knGlobals.netAccess();
- connect(n_etAccess, SIGNAL(netActive(bool)), this, SLOT(slotNetworkActive(bool)));
+ connect(n_etAccess, TQT_SIGNAL(netActive(bool)), this, TQT_SLOT(slotNetworkActive(bool)));
//Filter Manager
f_ilManager = knGlobals.filterManager();
@@ -225,8 +225,8 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
// Score Manager
s_coreManager = knGlobals.scoringManager();
- //connect(s_coreManager, SIGNAL(changedRules()), SLOT(slotReScore()));
- connect(s_coreManager, SIGNAL(finishedEditing()), SLOT(slotReScore()));
+ //connect(s_coreManager, TQT_SIGNAL(changedRules()), TQT_SLOT(slotReScore()));
+ connect(s_coreManager, TQT_SIGNAL(finishedEditing()), TQT_SLOT(slotReScore()));
// Memory Manager
m_emManager = knGlobals.memoryManager();
@@ -245,7 +245,7 @@ KNMainWidget::KNMainWidget( KXMLGUIClient* client, bool detachable, QWidget* par
// set the keyboard focus indicator on the first item in the Collection View
if( c_olView->firstChild() ) {
- QListViewItem *i = c_olView->firstChild();
+ TQListViewItem *i = c_olView->firstChild();
bool open = i->isOpen();
c_olView->setActive( i );
i->setOpen( open );
@@ -307,15 +307,15 @@ void KNMainWidget::initStatusBar()
//statusbar
KMainWindow *mainWin = dynamic_cast<KMainWindow*>(topLevelWidget());
KStatusBar *sb = mainWin ? mainWin->statusBar() : 0;
- s_tatusFilter = new KRSqueezedTextLabel( QString::null, sb );
+ s_tatusFilter = new KRSqueezedTextLabel( TQString::null, sb );
s_tatusFilter->setAlignment( AlignLeft | AlignVCenter );
- s_tatusGroup = new KRSqueezedTextLabel( QString::null, sb );
+ s_tatusGroup = new KRSqueezedTextLabel( TQString::null, sb );
s_tatusGroup->setAlignment( AlignLeft | AlignVCenter );
}
//================================== GUI =================================
-void KNMainWidget::setStatusMsg(const QString& text, int id)
+void KNMainWidget::setStatusMsg(const TQString& text, int id)
{
KMainWindow *mainWin = dynamic_cast<KMainWindow*>(topLevelWidget());
KStatusBar *bar = mainWin ? mainWin->statusBar() : 0;
@@ -340,7 +340,7 @@ void KNMainWidget::setStatusMsg(const QString& text, int id)
}
-void KNMainWidget::setStatusHelpMsg(const QString& text)
+void KNMainWidget::setStatusHelpMsg(const TQString& text)
{
KMainWindow *mainWin = dynamic_cast<KMainWindow*>(topLevelWidget());
KStatusBar *bar = mainWin ? mainWin->statusBar() : 0;
@@ -351,7 +351,7 @@ void KNMainWidget::setStatusHelpMsg(const QString& text)
void KNMainWidget::updateCaption()
{
- QString newCaption=i18n("KDE News Reader");
+ TQString newCaption=i18n("KDE News Reader");
if (g_rpManager->currentGroup()) {
newCaption = g_rpManager->currentGroup()->name();
if (g_rpManager->currentGroup()->status()==KNGroup::moderated)
@@ -431,23 +431,23 @@ void KNMainWidget::secureProcessEvents()
}
-QSize KNMainWidget::sizeHint() const
+TQSize KNMainWidget::sizeHint() const
{
- return QSize(759,478); // default optimized for 800x600
+ return TQSize(759,478); // default optimized for 800x600
}
void KNMainWidget::openURL(const KURL &url)
{
kdDebug(5003) << k_funcinfo << url << endl;
- QString host = url.host();
+ TQString host = url.host();
unsigned short int port = url.port();
KNNntpAccount *acc=0;
if (url.url().left(7) == "news://") {
// lets see if we already have an account for this host...
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = a_ccManager->begin(); it != a_ccManager->end(); ++it ) {
if ( (*it)->server().lower() == host.lower() && ( port==0 || (*it)->port() == port ) ) {
acc = *it;
@@ -487,10 +487,10 @@ void KNMainWidget::openURL(const KURL &url)
bool isMID=(url.url().contains('@')==1);
if (!isMID) {
- QString groupname=url.path(-1);
+ TQString groupname=url.path(-1);
while(groupname.startsWith("/"))
groupname.remove(0,1);
- QListViewItem *item=0;
+ TQListViewItem *item=0;
if(groupname.isEmpty())
item=acc->listItem();
else {
@@ -512,7 +512,7 @@ void KNMainWidget::openURL(const KURL &url)
c_olView->setActive( item );
}
} else {
- QString groupname = url.url().mid( url.protocol().length()+1 );
+ TQString groupname = url.url().mid( url.protocol().length()+1 );
KNGroup *g = g_rpManager->currentGroup();
if (g == 0)
g = g_rpManager->firstGroupOfAccount(acc);
@@ -520,7 +520,7 @@ void KNMainWidget::openURL(const KURL &url)
if (g) {
if(!KNArticleWindow::raiseWindowForArticle(groupname.latin1())) { //article not yet opened
KNRemoteArticle *a=new KNRemoteArticle(g);
- QString messageID = "<"+groupname+">";
+ TQString messageID = "<"+groupname+">";
a->messageID()->from7BitString(messageID.latin1());
KNArticleWindow *awin=new KNArticleWindow(a);
awin->show();
@@ -551,117 +551,117 @@ void KNMainWidget::initActions()
//navigation
a_ctNavNextArt = new KAction( KGuiItem(i18n("&Next Article"), "next",
i18n("Go to next article")), "N;Right", h_drView,
- SLOT(nextArticle()), actionCollection(), "go_nextArticle" );
+ TQT_SLOT(nextArticle()), actionCollection(), "go_nextArticle" );
a_ctNavPrevArt = new KAction( KGuiItem(i18n("&Previous Article"), "previous",
i18n("Go to previous article")), "P;Left" , h_drView,
- SLOT(prevArticle()), actionCollection(), "go_prevArticle" );
+ TQT_SLOT(prevArticle()), actionCollection(), "go_prevArticle" );
a_ctNavNextUnreadArt = new KAction(i18n("Next Unread &Article"), "1rightarrow", ALT+SHIFT+Key_Space , this,
- SLOT(slotNavNextUnreadArt()), actionCollection(), "go_nextUnreadArticle");
+ TQT_SLOT(slotNavNextUnreadArt()), actionCollection(), "go_nextUnreadArticle");
a_ctNavNextUnreadThread = new KAction(i18n("Next Unread &Thread"),"2rightarrow", SHIFT+Key_Space , this,
- SLOT(slotNavNextUnreadThread()), actionCollection(), "go_nextUnreadThread");
+ TQT_SLOT(slotNavNextUnreadThread()), actionCollection(), "go_nextUnreadThread");
a_ctNavNextGroup = new KAction(i18n("Ne&xt Group"), "down", Key_Plus , c_olView,
- SLOT(nextGroup()), actionCollection(), "go_nextGroup");
+ TQT_SLOT(nextGroup()), actionCollection(), "go_nextGroup");
a_ctNavPrevGroup = new KAction(i18n("Pre&vious Group"), "up", Key_Minus , c_olView,
- SLOT(prevGroup()), actionCollection(), "go_prevGroup");
+ TQT_SLOT(prevGroup()), actionCollection(), "go_prevGroup");
a_ctNavReadThrough = new KAction(i18n("Read &Through Articles"), Key_Space , this,
- SLOT(slotNavReadThrough()), actionCollection(), "go_readThrough");
+ TQT_SLOT(slotNavReadThrough()), actionCollection(), "go_readThrough");
a_ctNavReadThrough->plugAccel(a_ccel);
- QAccel *accel = new QAccel( this );
+ TQAccel *accel = new TQAccel( this );
new KAction( i18n("Focus on Next Folder"), CTRL+Key_Right, c_olView,
- SLOT(incCurrentFolder()), actionCollection(), "inc_current_folder" );
+ TQT_SLOT(incCurrentFolder()), actionCollection(), "inc_current_folder" );
accel->connectItem(accel->insertItem(CTRL+Key_Right),
- c_olView, SLOT(incCurrentFolder()));
+ c_olView, TQT_SLOT(incCurrentFolder()));
new KAction( i18n("Focus on Previous Folder"), CTRL+Key_Left, c_olView,
- SLOT(decCurrentFolder()), actionCollection(), "dec_current_folder" );
+ TQT_SLOT(decCurrentFolder()), actionCollection(), "dec_current_folder" );
accel->connectItem(accel->insertItem(CTRL+Key_Left),
- c_olView, SLOT(decCurrentFolder()));
+ c_olView, TQT_SLOT(decCurrentFolder()));
new KAction( i18n("Select Folder with Focus"), CTRL+Key_Space, c_olView,
- SLOT(selectCurrentFolder()), actionCollection(), "select_current_folder" );
+ TQT_SLOT(selectCurrentFolder()), actionCollection(), "select_current_folder" );
accel->connectItem(accel->insertItem(CTRL+Key_Space),
- c_olView, SLOT(selectCurrentFolder()));
+ c_olView, TQT_SLOT(selectCurrentFolder()));
new KAction( i18n("Focus on Next Article"), ALT+Key_Right, h_drView,
- SLOT(incCurrentArticle()), actionCollection(), "inc_current_article" );
+ TQT_SLOT(incCurrentArticle()), actionCollection(), "inc_current_article" );
accel->connectItem( accel->insertItem(ALT+Key_Right),
- h_drView, SLOT(incCurrentArticle()) );
+ h_drView, TQT_SLOT(incCurrentArticle()) );
new KAction( i18n("Focus on Previous Article"), ALT+Key_Left, h_drView,
- SLOT(decCurrentArticle()), actionCollection(), "dec_current_article" );
+ TQT_SLOT(decCurrentArticle()), actionCollection(), "dec_current_article" );
accel->connectItem( accel->insertItem(ALT+Key_Left),
- h_drView, SLOT(decCurrentArticle()) );
+ h_drView, TQT_SLOT(decCurrentArticle()) );
new KAction( i18n("Select Article with Focus"), ALT+Key_Space, h_drView,
- SLOT(selectCurrentArticle()), actionCollection(), "select_current_article" );
+ TQT_SLOT(selectCurrentArticle()), actionCollection(), "select_current_article" );
accel->connectItem( accel->insertItem(ALT+Key_Space),
- h_drView, SLOT(selectCurrentArticle()) );
+ h_drView, TQT_SLOT(selectCurrentArticle()) );
//collection-view - accounts
a_ctAccProperties = new KAction(i18n("Account &Properties"), "configure", 0, this,
- SLOT(slotAccProperties()), actionCollection(), "account_properties");
+ TQT_SLOT(slotAccProperties()), actionCollection(), "account_properties");
a_ctAccRename = new KAction(i18n("&Rename Account"), "text", 0, this,
- SLOT(slotAccRename()), actionCollection(), "account_rename");
+ TQT_SLOT(slotAccRename()), actionCollection(), "account_rename");
a_ctAccSubscribe = new KAction(i18n("&Subscribe to Newsgroups..."), "news_subscribe", 0, this,
- SLOT(slotAccSubscribe()), actionCollection(), "account_subscribe");
+ TQT_SLOT(slotAccSubscribe()), actionCollection(), "account_subscribe");
a_ctAccExpireAll = new KAction(i18n("&Expire All Groups"), 0, this,
- SLOT(slotAccExpireAll()), actionCollection(), "account_expire_all");
+ TQT_SLOT(slotAccExpireAll()), actionCollection(), "account_expire_all");
a_ctAccGetNewHdrs = new KAction(i18n("&Get New Articles in All Groups"), "mail_get", 0, this,
- SLOT(slotAccGetNewHdrs()), actionCollection(), "account_dnlHeaders");
+ TQT_SLOT(slotAccGetNewHdrs()), actionCollection(), "account_dnlHeaders");
a_ctAccGetNewHdrsAll = new KAction(i18n("&Get New Articles in All Accounts"), "mail_get_all", 0, this,
- SLOT(slotAccGetNewHdrsAll()), actionCollection(), "account_dnlAllHeaders");
+ TQT_SLOT(slotAccGetNewHdrsAll()), actionCollection(), "account_dnlAllHeaders");
a_ctAccDelete = new KAction(i18n("&Delete Account"), "editdelete", 0, this,
- SLOT(slotAccDelete()), actionCollection(), "account_delete");
+ TQT_SLOT(slotAccDelete()), actionCollection(), "account_delete");
a_ctAccPostNewArticle = new KAction(i18n("&Post to Newsgroup..."), "mail_new", CTRL+Key_N, this,
- SLOT(slotAccPostNewArticle()), actionCollection(), "article_postNew");
+ TQT_SLOT(slotAccPostNewArticle()), actionCollection(), "article_postNew");
//collection-view - groups
a_ctGrpProperties = new KAction(i18n("Group &Properties"), "configure", 0, this,
- SLOT(slotGrpProperties()), actionCollection(), "group_properties");
+ TQT_SLOT(slotGrpProperties()), actionCollection(), "group_properties");
a_ctGrpRename = new KAction(i18n("Rename &Group"), "text", 0, this,
- SLOT(slotGrpRename()), actionCollection(), "group_rename");
+ TQT_SLOT(slotGrpRename()), actionCollection(), "group_rename");
a_ctGrpGetNewHdrs = new KAction(i18n("&Get New Articles"), "mail_get" , 0, this,
- SLOT(slotGrpGetNewHdrs()), actionCollection(), "group_dnlHeaders");
+ TQT_SLOT(slotGrpGetNewHdrs()), actionCollection(), "group_dnlHeaders");
a_ctGrpExpire = new KAction(i18n("E&xpire Group"), "wizard", 0, this,
- SLOT(slotGrpExpire()), actionCollection(), "group_expire");
+ TQT_SLOT(slotGrpExpire()), actionCollection(), "group_expire");
a_ctGrpReorganize = new KAction(i18n("Re&organize Group"), 0, this,
- SLOT(slotGrpReorganize()), actionCollection(), "group_reorg");
+ TQT_SLOT(slotGrpReorganize()), actionCollection(), "group_reorg");
a_ctGrpUnsubscribe = new KAction(i18n("&Unsubscribe From Group"), "news_unsubscribe", 0, this,
- SLOT(slotGrpUnsubscribe()), actionCollection(), "group_unsubscribe");
+ TQT_SLOT(slotGrpUnsubscribe()), actionCollection(), "group_unsubscribe");
a_ctGrpSetAllRead = new KAction(i18n("Mark All as &Read"), "goto", 0, this,
- SLOT(slotGrpSetAllRead()), actionCollection(), "group_allRead");
+ TQT_SLOT(slotGrpSetAllRead()), actionCollection(), "group_allRead");
a_ctGrpSetAllUnread = new KAction(i18n("Mark All as U&nread"), 0, this,
- SLOT(slotGrpSetAllUnread()), actionCollection(), "group_allUnread");
+ TQT_SLOT(slotGrpSetAllUnread()), actionCollection(), "group_allUnread");
a_ctGrpSetUnread = new KAction(i18n("Mark Last as Unr&ead..."), 0, this,
- SLOT(slotGrpSetUnread()), actionCollection(), "group_unread");
+ TQT_SLOT(slotGrpSetUnread()), actionCollection(), "group_unread");
(void) new KAction( i18n("&Configure KNode..."),
"configure", 0, this,
- SLOT(slotSettings()), actionCollection(),
+ TQT_SLOT(slotSettings()), actionCollection(),
"knode_configure_knode" );
//collection-view - folder
a_ctFolNew = new KAction(i18n("&New Folder"), "folder_new", 0, this,
- SLOT(slotFolNew()), actionCollection(), "folder_new");
+ TQT_SLOT(slotFolNew()), actionCollection(), "folder_new");
a_ctFolNewChild = new KAction(i18n("New &Subfolder"), "folder_new", 0, this,
- SLOT(slotFolNewChild()), actionCollection(), "folder_newChild");
+ TQT_SLOT(slotFolNewChild()), actionCollection(), "folder_newChild");
a_ctFolDelete = new KAction(i18n("&Delete Folder"), "editdelete", 0, this,
- SLOT(slotFolDelete()), actionCollection(), "folder_delete");
+ TQT_SLOT(slotFolDelete()), actionCollection(), "folder_delete");
a_ctFolRename = new KAction(i18n("&Rename Folder"), "text", 0, this,
- SLOT(slotFolRename()), actionCollection(), "folder_rename");
+ TQT_SLOT(slotFolRename()), actionCollection(), "folder_rename");
a_ctFolCompact = new KAction(i18n("C&ompact Folder"), "wizard", 0, this,
- SLOT(slotFolCompact()), actionCollection(), "folder_compact");
+ TQT_SLOT(slotFolCompact()), actionCollection(), "folder_compact");
a_ctFolCompactAll = new KAction(i18n("Co&mpact All Folders"), 0, this,
- SLOT(slotFolCompactAll()), actionCollection(), "folder_compact_all");
+ TQT_SLOT(slotFolCompactAll()), actionCollection(), "folder_compact_all");
a_ctFolEmpty = new KAction(i18n("&Empty Folder"), 0, this,
- SLOT(slotFolEmpty()), actionCollection(), "folder_empty");
+ TQT_SLOT(slotFolEmpty()), actionCollection(), "folder_empty");
a_ctFolMboxImport = new KAction(i18n("&Import MBox Folder..."), 0, this,
- SLOT(slotFolMBoxImport()), actionCollection(), "folder_MboxImport");
+ TQT_SLOT(slotFolMBoxImport()), actionCollection(), "folder_MboxImport");
a_ctFolMboxExport = new KAction(i18n("E&xport as MBox Folder..."), 0, this,
- SLOT(slotFolMBoxExport()), actionCollection(), "folder_MboxExport");
+ TQT_SLOT(slotFolMBoxExport()), actionCollection(), "folder_MboxExport");
//header-view - list-handling
a_ctArtSortHeaders = new KSelectAction(i18n("S&ort"), 0, actionCollection(), "view_Sort");
- QStringList items;
+ TQStringList items;
items += i18n("By &Subject");
items += i18n("By S&ender");
items += i18n("By S&core");
@@ -669,9 +669,9 @@ void KNMainWidget::initActions()
items += i18n("By &Date");
a_ctArtSortHeaders->setItems(items);
a_ctArtSortHeaders->setShortcutConfigurable(false);
- connect(a_ctArtSortHeaders, SIGNAL(activated(int)), this, SLOT(slotArtSortHeaders(int)));
- a_ctArtSortHeadersKeyb = new KAction(i18n("Sort"), QString::null, Key_F7 , this,
- SLOT(slotArtSortHeadersKeyb()), actionCollection(), "view_Sort_Keyb");
+ connect(a_ctArtSortHeaders, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotArtSortHeaders(int)));
+ a_ctArtSortHeadersKeyb = new KAction(i18n("Sort"), TQString::null, Key_F7 , this,
+ TQT_SLOT(slotArtSortHeadersKeyb()), actionCollection(), "view_Sort_Keyb");
a_ctArtSortHeadersKeyb->plugAccel(a_ccel);
a_ctArtFilter = new KNFilterSelectAction(i18n("&Filter"), "filter",
actionCollection(), "view_Filter");
@@ -679,86 +679,86 @@ void KNMainWidget::initActions()
a_ctArtFilterKeyb = new KAction(i18n("Filter"), Key_F6, actionCollection(), "view_Filter_Keyb");
a_ctArtFilterKeyb->plugAccel(a_ccel);
a_ctArtSearch = new KAction(i18n("&Search Articles..."),"mail_find" , Key_F4 , this,
- SLOT(slotArtSearch()), actionCollection(), "article_search");
+ TQT_SLOT(slotArtSearch()), actionCollection(), "article_search");
a_ctArtRefreshList = new KAction(i18n("&Refresh List"),"reload", KStdAccel::shortcut(KStdAccel::Reload), this,
- SLOT(slotArtRefreshList()), actionCollection(), "view_Refresh");
+ TQT_SLOT(slotArtRefreshList()), actionCollection(), "view_Refresh");
a_ctArtCollapseAll = new KAction(i18n("&Collapse All Threads"), 0 , this,
- SLOT(slotArtCollapseAll()), actionCollection(), "view_CollapseAll");
+ TQT_SLOT(slotArtCollapseAll()), actionCollection(), "view_CollapseAll");
a_ctArtExpandAll = new KAction(i18n("E&xpand All Threads"), 0 , this,
- SLOT(slotArtExpandAll()), actionCollection(), "view_ExpandAll");
+ TQT_SLOT(slotArtExpandAll()), actionCollection(), "view_ExpandAll");
a_ctArtToggleThread = new KAction(i18n("&Toggle Subthread"), Key_T, this,
- SLOT(slotArtToggleThread()), actionCollection(), "thread_toggle");
+ TQT_SLOT(slotArtToggleThread()), actionCollection(), "thread_toggle");
a_ctArtToggleShowThreads = new KToggleAction(i18n("Show T&hreads"), 0 , this,
- SLOT(slotArtToggleShowThreads()), actionCollection(), "view_showThreads");
+ TQT_SLOT(slotArtToggleShowThreads()), actionCollection(), "view_showThreads");
a_ctArtToggleShowThreads->setCheckedState(i18n("Hide T&hreads"));
a_ctArtToggleShowThreads->setChecked(c_fgManager->readNewsGeneral()->showThreads());
//header-view - remote articles
a_ctArtSetArtRead = new KAction(i18n("Mark as &Read"), Key_D , this,
- SLOT(slotArtSetArtRead()), actionCollection(), "article_read");
+ TQT_SLOT(slotArtSetArtRead()), actionCollection(), "article_read");
a_ctArtSetArtUnread = new KAction(i18n("Mar&k as Unread"), Key_U , this,
- SLOT(slotArtSetArtUnread()), actionCollection(), "article_unread");
+ TQT_SLOT(slotArtSetArtUnread()), actionCollection(), "article_unread");
a_ctArtSetThreadRead = new KAction(i18n("Mark &Thread as Read"), CTRL+Key_D , this,
- SLOT(slotArtSetThreadRead()), actionCollection(), "thread_read");
+ TQT_SLOT(slotArtSetThreadRead()), actionCollection(), "thread_read");
a_ctArtSetThreadUnread = new KAction(i18n("Mark T&hread as Unread"), CTRL+Key_U , this,
- SLOT(slotArtSetThreadUnread()), actionCollection(), "thread_unread");
+ TQT_SLOT(slotArtSetThreadUnread()), actionCollection(), "thread_unread");
a_ctArtOpenNewWindow = new KAction(i18n("Open in Own &Window"), "window_new", Key_O , this,
- SLOT(slotArtOpenNewWindow()), actionCollection(), "article_ownWindow");
+ TQT_SLOT(slotArtOpenNewWindow()), actionCollection(), "article_ownWindow");
// scoring
a_ctScoresEdit = new KAction(i18n("&Edit Scoring Rules..."), "edit", CTRL+Key_E, this,
- SLOT(slotScoreEdit()), actionCollection(), "scoreedit");
+ TQT_SLOT(slotScoreEdit()), actionCollection(), "scoreedit");
a_ctReScore = new KAction(i18n("Recalculate &Scores"), 0, this,
- SLOT(slotReScore()),actionCollection(),"rescore");
+ TQT_SLOT(slotReScore()),actionCollection(),"rescore");
a_ctScoreLower = new KAction(i18n("&Lower Score for Author..."), CTRL+Key_L, this,
- SLOT(slotScoreLower()), actionCollection(), "scorelower");
+ TQT_SLOT(slotScoreLower()), actionCollection(), "scorelower");
a_ctScoreRaise = new KAction(i18n("&Raise Score for Author..."), CTRL+Key_I, this,
- SLOT(slotScoreRaise()),actionCollection(),"scoreraise");
+ TQT_SLOT(slotScoreRaise()),actionCollection(),"scoreraise");
a_ctArtToggleIgnored = new KAction(i18n("&Ignore Thread"), "bottom", Key_I , this,
- SLOT(slotArtToggleIgnored()), actionCollection(), "thread_ignore");
+ TQT_SLOT(slotArtToggleIgnored()), actionCollection(), "thread_ignore");
a_ctArtToggleWatched = new KAction(i18n("&Watch Thread"), "top", Key_W , this,
- SLOT(slotArtToggleWatched()), actionCollection(), "thread_watch");
+ TQT_SLOT(slotArtToggleWatched()), actionCollection(), "thread_watch");
//header-view local articles
a_ctArtSendOutbox = new KAction(i18n("Sen&d Pending Messages"), "mail_send", 0, this,
- SLOT(slotArtSendOutbox()), actionCollection(), "net_sendPending");
+ TQT_SLOT(slotArtSendOutbox()), actionCollection(), "net_sendPending");
a_ctArtDelete = new KAction(i18n("&Delete Article"), "editdelete", Key_Delete, this,
- SLOT(slotArtDelete()), actionCollection(), "article_delete");
+ TQT_SLOT(slotArtDelete()), actionCollection(), "article_delete");
a_ctArtSendNow = new KAction(i18n("Send &Now"),"mail_send", 0 , this,
- SLOT(slotArtSendNow()), actionCollection(), "article_sendNow");
+ TQT_SLOT(slotArtSendNow()), actionCollection(), "article_sendNow");
a_ctArtEdit = new KAction(i18n("edit article","&Edit Article..."), "edit", Key_E , this,
- SLOT(slotArtEdit()), actionCollection(), "article_edit");
+ TQT_SLOT(slotArtEdit()), actionCollection(), "article_edit");
//network
a_ctNetCancel = new KAction(i18n("Stop &Network"),"stop",0, this,
- SLOT(slotNetCancel()), actionCollection(), "net_stop");
+ TQT_SLOT(slotNetCancel()), actionCollection(), "net_stop");
a_ctNetCancel->setEnabled(false);
a_ctFetchArticleWithID = new KAction(i18n("&Fetch Article with ID..."), 0, this,
- SLOT(slotFetchArticleWithID()), actionCollection(), "fetch_article_with_id");
+ TQT_SLOT(slotFetchArticleWithID()), actionCollection(), "fetch_article_with_id");
a_ctFetchArticleWithID->setEnabled(false);
a_ctToggleGroupView = new KToggleAction(i18n("Show &Group View"), CTRL+Key_G, this,
- SLOT(slotToggleGroupView()), actionCollection(), "settings_show_groupView");
+ TQT_SLOT(slotToggleGroupView()), actionCollection(), "settings_show_groupView");
a_ctToggleGroupView->setCheckedState(i18n("Hide &Group View"));
a_ctToggleHeaderView = new KToggleAction(i18n("Show &Header View"), CTRL+Key_H, this,
- SLOT(slotToggleHeaderView()), actionCollection(), "settings_show_headerView");
+ TQT_SLOT(slotToggleHeaderView()), actionCollection(), "settings_show_headerView");
a_ctToggleHeaderView->setCheckedState(i18n("Hide &Header View"));
a_ctToggleArticleViewer = new KToggleAction(i18n("Show &Article Viewer"), CTRL+Key_J, this,
- SLOT(slotToggleArticleViewer()), actionCollection(), "settings_show_articleViewer");
+ TQT_SLOT(slotToggleArticleViewer()), actionCollection(), "settings_show_articleViewer");
a_ctToggleArticleViewer->setCheckedState(i18n("Hide &Article Viewer"));
- a_ctToggleQuickSearch = new KToggleAction(i18n("Show Quick Search"), QString::null, this,
- SLOT(slotToggleQuickSearch()), actionCollection(), "settings_show_quickSearch");
+ a_ctToggleQuickSearch = new KToggleAction(i18n("Show Quick Search"), TQString::null, this,
+ TQT_SLOT(slotToggleQuickSearch()), actionCollection(), "settings_show_quickSearch");
a_ctToggleQuickSearch->setCheckedState(i18n("Hide Quick Search"));
a_ctSwitchToGroupView = new KAction(i18n("Switch to Group View"), Key_G , this,
- SLOT(slotSwitchToGroupView()), actionCollection(), "switch_to_group_view");
+ TQT_SLOT(slotSwitchToGroupView()), actionCollection(), "switch_to_group_view");
a_ctSwitchToGroupView->plugAccel(a_ccel);
a_ctSwitchToHeaderView = new KAction(i18n("Switch to Header View"), Key_H , this,
- SLOT(slotSwitchToHeaderView()), actionCollection(), "switch_to_header_view");
+ TQT_SLOT(slotSwitchToHeaderView()), actionCollection(), "switch_to_header_view");
a_ctSwitchToHeaderView->plugAccel(a_ccel);
a_ctSwitchToArticleViewer = new KAction(i18n("Switch to Article Viewer"), Key_J , this,
- SLOT(slotSwitchToArticleViewer()), actionCollection(), "switch_to_article_viewer");
+ TQT_SLOT(slotSwitchToArticleViewer()), actionCollection(), "switch_to_article_viewer");
a_ctSwitchToArticleViewer->plugAccel(a_ccel);
}
@@ -766,16 +766,16 @@ bool KNMainWidget::firstStart()
{
KConfig *conf=knGlobals.config();
conf->setGroup("GENERAL");
- QString ver = conf->readEntry("Version");
+ TQString ver = conf->readEntry("Version");
if(!ver.isEmpty())
return false;
KConfig emailConf("emaildefaults");
emailConf.setGroup("Defaults");
- QString group = emailConf.readEntry("Profile","Default");
+ TQString group = emailConf.readEntry("Profile","Default");
- emailConf.setGroup(QString("PROFILE_%1").arg(group));
+ emailConf.setGroup(TQString("PROFILE_%1").arg(group));
KNConfig::Identity *id=knGlobals.configManager()->identity();
id->setName(emailConf.readEntry("FullName"));
id->setEmail(emailConf.readEntry("EmailAddress").latin1());
@@ -841,7 +841,7 @@ bool KNMainWidget::requestShutdown()
if( a_rtFactory->jobsPending() &&
KMessageBox::No==KMessageBox::warningYesNo(this, i18n(
"KNode is currently sending articles. If you quit now you might lose these \
-articles.\nDo you want to quit anyway?"), QString::null, KStdGuiItem::quit(), KStdGuiItem::cancel())
+articles.\nDo you want to quit anyway?"), TQString::null, KStdGuiItem::quit(), KStdGuiItem::cancel())
)
return false;
@@ -901,13 +901,13 @@ bool KNMainWidget::queryClose()
}
-void KNMainWidget::showEvent(QShowEvent *)
+void KNMainWidget::showEvent(TQShowEvent *)
{
slotCheckDockWidgetStatus();
}
-void KNMainWidget::fontChange( const QFont & )
+void KNMainWidget::fontChange( const TQFont & )
{
a_rtFactory->configChanged();
ArticleWidget::configChanged();
@@ -915,19 +915,19 @@ void KNMainWidget::fontChange( const QFont & )
}
-void KNMainWidget::paletteChange( const QPalette & )
+void KNMainWidget::paletteChange( const TQPalette & )
{
ArticleWidget::configChanged();
configChanged();
}
-bool KNMainWidget::eventFilter(QObject *o, QEvent *e)
+bool KNMainWidget::eventFilter(TQObject *o, TQEvent *e)
{
- if (((e->type() == QEvent::KeyPress) ||
- (e->type() == QEvent::KeyRelease) ||
- (e->type() == QEvent::Accel) ||
- (e->type() == QEvent::AccelOverride)) &&
+ if (((e->type() == TQEvent::KeyPress) ||
+ (e->type() == TQEvent::KeyRelease) ||
+ (e->type() == TQEvent::Accel) ||
+ (e->type() == TQEvent::AccelOverride)) &&
b_lockui)
return true;
return KDockArea::eventFilter(o, e);
@@ -939,7 +939,7 @@ void KNMainWidget::getSelectedArticles(KNArticle::List &l)
if(!g_rpManager->currentGroup() && !f_olManager->currentFolder())
return;
- for(QListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
+ for(TQListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
if(i->isSelected() || (static_cast<KNHdrViewItem*>(i)->isActive()))
l.append( static_cast<KNArticle*> ((static_cast<KNHdrViewItem*>(i))->art) );
}
@@ -949,7 +949,7 @@ void KNMainWidget::getSelectedArticles(KNRemoteArticle::List &l)
{
if(!g_rpManager->currentGroup()) return;
- for(QListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
+ for(TQListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
if(i->isSelected() || (static_cast<KNHdrViewItem*>(i)->isActive()))
l.append( static_cast<KNRemoteArticle*> ((static_cast<KNHdrViewItem*>(i))->art) );
}
@@ -958,7 +958,7 @@ void KNMainWidget::getSelectedArticles(KNRemoteArticle::List &l)
void KNMainWidget::getSelectedThreads(KNRemoteArticle::List &l)
{
KNRemoteArticle *art;
- for(QListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
+ for(TQListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
if(i->isSelected() || (static_cast<KNHdrViewItem*>(i)->isActive())) {
art=static_cast<KNRemoteArticle*> ((static_cast<KNHdrViewItem*>(i))->art);
// ignore the article if it is already in the list
@@ -973,7 +973,7 @@ void KNMainWidget::getSelectedArticles( KNLocalArticle::List &l )
{
if(!f_olManager->currentFolder()) return;
- for(QListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
+ for(TQListViewItem *i=h_drView->firstChild(); i; i=i->itemBelow())
if(i->isSelected() || (static_cast<KNHdrViewItem*>(i)->isActive()))
l.append( static_cast<KNLocalArticle*> ((static_cast<KNHdrViewItem*>(i))->art) );
}
@@ -981,7 +981,7 @@ void KNMainWidget::getSelectedArticles( KNLocalArticle::List &l )
void KNMainWidget::closeCurrentThread()
{
- QListViewItem *item = h_drView->currentItem();
+ TQListViewItem *item = h_drView->currentItem();
if (item) {
while (item->parent())
item = item->parent();
@@ -991,9 +991,9 @@ void KNMainWidget::closeCurrentThread()
}
}
-void KNMainWidget::slotArticleSelected(QListViewItem *i)
+void KNMainWidget::slotArticleSelected(TQListViewItem *i)
{
- kdDebug(5003) << "KNMainWidget::slotArticleSelected(QListViewItem *i)" << endl;
+ kdDebug(5003) << "KNMainWidget::slotArticleSelected(TQListViewItem *i)" << endl;
if(b_lockui)
return;
KNArticle *selectedArticle=0;
@@ -1053,9 +1053,9 @@ void KNMainWidget::slotArticleSelectionChanged()
}
-void KNMainWidget::slotCollectionSelected(QListViewItem *i)
+void KNMainWidget::slotCollectionSelected(TQListViewItem *i)
{
- kdDebug(5003) << "KNMainWidget::slotCollectionSelected(QListViewItem *i)" << endl;
+ kdDebug(5003) << "KNMainWidget::slotCollectionSelected(TQListViewItem *i)" << endl;
if(b_lockui)
return;
KNCollection *c=0;
@@ -1172,9 +1172,9 @@ void KNMainWidget::slotCollectionSelected(QListViewItem *i)
}
-void KNMainWidget::slotCollectionRenamed(QListViewItem *i)
+void KNMainWidget::slotCollectionRenamed(TQListViewItem *i)
{
- kdDebug(5003) << "KNMainWidget::slotCollectionRenamed(QListViewItem *i)" << endl;
+ kdDebug(5003) << "KNMainWidget::slotCollectionRenamed(TQListViewItem *i)" << endl;
if (i) {
(static_cast<KNCollectionViewItem*>(i))->coll->setName(i->text(0));
@@ -1187,7 +1187,7 @@ void KNMainWidget::slotCollectionRenamed(QListViewItem *i)
}
-void KNMainWidget::slotCollectionViewDrop(QDropEvent* e, KNCollectionViewItem* after)
+void KNMainWidget::slotCollectionViewDrop(TQDropEvent* e, KNCollectionViewItem* after)
{
kdDebug(5003) << "KNMainWidget::slotCollectionViewDrop() : type = " << e->format(0) << endl;
@@ -1201,7 +1201,7 @@ void KNMainWidget::slotCollectionViewDrop(QDropEvent* e, KNCollectionViewItem* a
}
else if(dest && e->provides("x-knode-drag/article")) {
if(f_olManager->currentFolder()) {
- if (e->action() == QDropEvent::Move) {
+ if (e->action() == TQDropEvent::Move) {
KNLocalArticle::List l;
getSelectedArticles(l);
a_rtManager->moveIntoFolder(l, dest);
@@ -1220,17 +1220,17 @@ void KNMainWidget::slotCollectionViewDrop(QDropEvent* e, KNCollectionViewItem* a
}
-void KNMainWidget::slotArticleRMB(KListView*, QListViewItem *i, const QPoint &p)
+void KNMainWidget::slotArticleRMB(KListView*, TQListViewItem *i, const TQPoint &p)
{
if(b_lockui)
return;
if(i) {
- QPopupMenu *popup;
+ TQPopupMenu *popup;
if( (static_cast<KNHdrViewItem*>(i))->art->type()==KMime::Base::ATremote) {
- popup = static_cast<QPopupMenu *>(factory()->container("remote_popup", m_GUIClient));
+ popup = static_cast<TQPopupMenu *>(factory()->container("remote_popup", m_GUIClient));
} else {
- popup = static_cast<QPopupMenu *>(factory()->container("local_popup", m_GUIClient));
+ popup = static_cast<TQPopupMenu *>(factory()->container("local_popup", m_GUIClient));
}
if ( popup )
@@ -1239,28 +1239,28 @@ void KNMainWidget::slotArticleRMB(KListView*, QListViewItem *i, const QPoint &p)
}
-void KNMainWidget::slotCollectionRMB(KListView*, QListViewItem *i, const QPoint &p)
+void KNMainWidget::slotCollectionRMB(KListView*, TQListViewItem *i, const TQPoint &p)
{
if(b_lockui)
return;
if(i) {
if( (static_cast<KNCollectionViewItem*>(i))->coll->type()==KNCollection::CTgroup) {
- QPopupMenu *popup = static_cast<QPopupMenu *>(factory()->container("group_popup", m_GUIClient));
+ TQPopupMenu *popup = static_cast<TQPopupMenu *>(factory()->container("group_popup", m_GUIClient));
if ( popup )
popup->popup(p);
} else if ((static_cast<KNCollectionViewItem*>(i))->coll->type()==KNCollection::CTfolder) {
if (static_cast<KNFolder*>(static_cast<KNCollectionViewItem*>(i)->coll)->isRootFolder()) {
- QPopupMenu *popup = static_cast<QPopupMenu *>(factory()->container("root_folder_popup", m_GUIClient));
+ TQPopupMenu *popup = static_cast<TQPopupMenu *>(factory()->container("root_folder_popup", m_GUIClient));
if ( popup )
popup->popup(p);
} else {
- QPopupMenu *popup = static_cast<QPopupMenu *>(factory()->container("folder_popup", m_GUIClient));
+ TQPopupMenu *popup = static_cast<TQPopupMenu *>(factory()->container("folder_popup", m_GUIClient));
if ( popup )
popup->popup(p);
}
} else {
- QPopupMenu *popup = static_cast<QPopupMenu *>(factory()->container("account_popup", m_GUIClient));
+ TQPopupMenu *popup = static_cast<TQPopupMenu *>(factory()->container("account_popup", m_GUIClient));
if ( popup )
popup->popup( p );
}
@@ -1268,7 +1268,7 @@ void KNMainWidget::slotCollectionRMB(KListView*, QListViewItem *i, const QPoint
}
-void KNMainWidget::slotOpenArticle(QListViewItem *item)
+void KNMainWidget::slotOpenArticle(TQListViewItem *item)
{
if(b_lockui)
return;
@@ -1327,7 +1327,7 @@ void KNMainWidget::slotArticleDockHidden()
}
-void KNMainWidget::slotDockWidgetFocusChangeRequest(QWidget *w)
+void KNMainWidget::slotDockWidgetFocusChangeRequest(TQWidget *w)
{
if ( w == mArticleViewer ) {
if (c_olView->isVisible()) {
@@ -1448,7 +1448,7 @@ void KNMainWidget::slotAccDelete()
void KNMainWidget::slotAccGetNewHdrsAll()
{
- QValueList<KNNntpAccount*>::Iterator it;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = a_ccManager->begin(); it != a_ccManager->end(); ++it )
g_rpManager->checkAll( *it );
}
@@ -1511,7 +1511,7 @@ void KNMainWidget::slotGrpUnsubscribe()
kdDebug(5003) << "KNMainWidget::slotGrpUnsubscribe()" << endl;
if(g_rpManager->currentGroup()) {
if(KMessageBox::Yes==KMessageBox::questionYesNo(knGlobals.topWidget,
- i18n("Do you really want to unsubscribe from %1?").arg(g_rpManager->currentGroup()->groupname()), QString::null, i18n("Unsubscribe"), KStdGuiItem::cancel()))
+ i18n("Do you really want to unsubscribe from %1?").arg(g_rpManager->currentGroup()->groupname()), TQString::null, i18n("Unsubscribe"), KStdGuiItem::cancel()))
if (g_rpManager->unsubscribeGroup(g_rpManager->currentGroup()))
slotCollectionSelected(0);
}
@@ -1945,10 +1945,10 @@ void KNMainWidget::slotFetchArticleWithID()
FetchArticleIdDlg *dlg = new FetchArticleIdDlg(this, "messageid" );
if (dlg->exec()) {
- QString id = dlg->messageId().simplifyWhiteSpace();
- if (id.find(QRegExp("*@*",false,true))!=-1) {
- if (id.find(QRegExp("<*>",false,true))==-1) // add "<>" when necessary
- id = QString("<%1>").arg(id);
+ TQString id = dlg->messageId().simplifyWhiteSpace();
+ if (id.find(TQRegExp("*@*",false,true))!=-1) {
+ if (id.find(TQRegExp("<*>",false,true))==-1) // add "<>" when necessary
+ id = TQString("<%1>").arg(id);
if(!KNArticleWindow::raiseWindowForArticle(id.latin1())) { //article not yet opened
KNRemoteArticle *a=new KNRemoteArticle(g_rpManager->currentGroup());
@@ -2043,27 +2043,27 @@ KXMLGUIFactory* KNMainWidget::factory() const
//--------------------------------
-FetchArticleIdDlg::FetchArticleIdDlg(QWidget *parent, const char */*name*/ )
+FetchArticleIdDlg::FetchArticleIdDlg(TQWidget *parent, const char */*name*/ )
:KDialogBase(parent, 0, true, i18n("Fetch Article with ID"), KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok)
{
- QHBox *page = makeHBoxMainWidget();
+ TQHBox *page = makeHBoxMainWidget();
- QLabel *label = new QLabel(i18n("&Message-ID:"),page);
+ TQLabel *label = new TQLabel(i18n("&Message-ID:"),page);
edit = new KLineEdit(page);
label->setBuddy(edit);
edit->setFocus();
enableButtonOK( false );
setButtonOK( i18n("&Fetch") );
- connect( edit, SIGNAL(textChanged( const QString & )), this, SLOT(slotTextChanged(const QString & )));
- KNHelper::restoreWindowSize("fetchArticleWithID", this, QSize(325,66));
+ connect( edit, TQT_SIGNAL(textChanged( const TQString & )), this, TQT_SLOT(slotTextChanged(const TQString & )));
+ KNHelper::restoreWindowSize("fetchArticleWithID", this, TQSize(325,66));
}
-QString FetchArticleIdDlg::messageId() const
+TQString FetchArticleIdDlg::messageId() const
{
return edit->text();
}
-void FetchArticleIdDlg::slotTextChanged(const QString &_text )
+void FetchArticleIdDlg::slotTextChanged(const TQString &_text )
{
enableButtonOK( !_text.isEmpty() );
}
diff --git a/knode/knmainwidget.h b/knode/knmainwidget.h
index 2b3660bd7..19f2b4aaf 100644
--- a/knode/knmainwidget.h
+++ b/knode/knmainwidget.h
@@ -20,7 +20,7 @@
#include <kdialogbase.h>
#include "resource.h"
-#include <qglobal.h>
+#include <tqglobal.h>
#include <kdepimmacros.h>
class QListViewItem;
@@ -64,7 +64,7 @@ class KDE_EXPORT KNMainWidget : public KDockArea, virtual public KNodeIface
{
Q_OBJECT
public:
- KNMainWidget( KXMLGUIClient *client, bool detachable, QWidget* parent, const char* name );
+ KNMainWidget( KXMLGUIClient *client, bool detachable, TQWidget* parent, const char* name );
~KNMainWidget();
/** exit */
@@ -72,8 +72,8 @@ public:
void prepareShutdown();
//GUI
- void setStatusMsg(const QString& = QString::null, int id=SB_MAIN);
- void setStatusHelpMsg(const QString& text);
+ void setStatusMsg(const TQString& = TQString::null, int id=SB_MAIN);
+ void setStatusHelpMsg(const TQString& text);
void updateCaption();
void setCursorBusy(bool b=true);
void blockUI(bool b=true);
@@ -82,7 +82,7 @@ public:
void secureProcessEvents();
/** useful default value */
- virtual QSize sizeHint() const;
+ virtual TQSize sizeHint() const;
/** handle URL given as command-line argument */
void openURL(const KURL &url);
@@ -155,7 +155,7 @@ public:
//end dcop interface
signals:
- void signalCaptionChangeRequest( const QString& );
+ void signalCaptionChangeRequest( const TQString& );
protected:
@@ -173,19 +173,19 @@ protected:
bool requestShutdown();
- virtual void showEvent(QShowEvent *);
+ virtual void showEvent(TQShowEvent *);
/** update appearance */
- virtual void fontChange( const QFont & );
- virtual void paletteChange ( const QPalette & );
+ virtual void fontChange( const TQFont & );
+ virtual void paletteChange ( const TQPalette & );
- bool eventFilter(QObject *, QEvent *);
+ bool eventFilter(TQObject *, TQEvent *);
// convenience methods...
- void getSelectedArticles( QValueList<KNArticle*> &l );
- void getSelectedArticles( QValueList<KNRemoteArticle*> &l );
- void getSelectedThreads( QValueList<KNRemoteArticle*> &l );
- void getSelectedArticles( QValueList<KNLocalArticle*> &l );
+ void getSelectedArticles( TQValueList<KNArticle*> &l );
+ void getSelectedArticles( TQValueList<KNRemoteArticle*> &l );
+ void getSelectedThreads( TQValueList<KNRemoteArticle*> &l );
+ void getSelectedArticles( TQValueList<KNLocalArticle*> &l );
void closeCurrentThread();
//GUI
@@ -197,7 +197,7 @@ protected:
KDockWidget *c_olDock, *h_drDock, *a_rtDock;
bool b_lockui;
KToolBar *q_uicksearch;
- QLineEdit *s_earchLineEdit;
+ TQLineEdit *s_earchLineEdit;
//Core
KNConfigManager *c_fgManager;
@@ -214,15 +214,15 @@ protected:
protected slots:
//listview slots
- void slotArticleSelected(QListViewItem*);
+ void slotArticleSelected(TQListViewItem*);
void slotArticleSelectionChanged();
- void slotCollectionSelected(QListViewItem*);
- void slotCollectionRenamed(QListViewItem*);
- void slotCollectionViewDrop(QDropEvent* e, KNCollectionViewItem* after);
- void slotArticleRMB(KListView*, QListViewItem *i, const QPoint &p);
- void slotCollectionRMB(KListView*, QListViewItem *i, const QPoint &p);
+ void slotCollectionSelected(TQListViewItem*);
+ void slotCollectionRenamed(TQListViewItem*);
+ void slotCollectionViewDrop(TQDropEvent* e, KNCollectionViewItem* after);
+ void slotArticleRMB(KListView*, TQListViewItem *i, const TQPoint &p);
+ void slotCollectionRMB(KListView*, TQListViewItem *i, const TQPoint &p);
/** Open selected article in own composer/reader window */
- void slotOpenArticle(QListViewItem *item);
+ void slotOpenArticle(TQListViewItem *item);
void slotHdrViewSortingChanged(int i);
//network slots
@@ -233,7 +233,7 @@ protected slots:
void slotGroupDockHidden();
void slotHeaderDockHidden();
void slotArticleDockHidden();
- void slotDockWidgetFocusChangeRequest(QWidget *w);
+ void slotDockWidgetFocusChangeRequest(TQWidget *w);
//---------------------------------- <Actions> ----------------------------------
@@ -414,11 +414,11 @@ class FetchArticleIdDlg : public KDialogBase
{
Q_OBJECT
public:
- FetchArticleIdDlg(QWidget *parent, const char */*name*/ );
- QString messageId() const;
+ FetchArticleIdDlg(TQWidget *parent, const char */*name*/ );
+ TQString messageId() const;
protected slots:
- void slotTextChanged(const QString & );
+ void slotTextChanged(const TQString & );
protected:
KLineEdit *edit;
};
diff --git a/knode/knmemorymanager.cpp b/knode/knmemorymanager.cpp
index 283bcf546..37a639287 100644
--- a/knode/knmemorymanager.cpp
+++ b/knode/knmemorymanager.cpp
@@ -31,9 +31,9 @@ KNMemoryManager::KNMemoryManager()
KNMemoryManager::~KNMemoryManager()
{
- for ( QValueList<CollectionItem*>::Iterator it = mColList.begin(); it != mColList.end(); ++it )
+ for ( TQValueList<CollectionItem*>::Iterator it = mColList.begin(); it != mColList.end(); ++it )
delete (*it);
- for ( QValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ++it )
+ for ( TQValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ++it )
delete (*it);
}
@@ -122,7 +122,7 @@ void KNMemoryManager::removeCacheEntry(KNArticle *a)
KNMemoryManager::CollectionItem* KNMemoryManager::findCacheEntry(KNArticleCollection *c, bool take)
{
- for ( QValueList<CollectionItem*>::Iterator it = mColList.begin(); it != mColList.end(); ++it ) {
+ for ( TQValueList<CollectionItem*>::Iterator it = mColList.begin(); it != mColList.end(); ++it ) {
if ( (*it)->col == c ) {
CollectionItem *ret = (*it);
if ( take )
@@ -137,7 +137,7 @@ KNMemoryManager::CollectionItem* KNMemoryManager::findCacheEntry(KNArticleCollec
KNMemoryManager::ArticleItem* KNMemoryManager::findCacheEntry(KNArticle *a, bool take)
{
- for ( QValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ++it ) {
+ for ( TQValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ++it ) {
if ( (*it)->art == a ) {
ArticleItem *ret = (*it);
if ( take )
@@ -156,10 +156,10 @@ void KNMemoryManager::checkMemoryUsageCollections()
KNArticleCollection *c=0;
if (c_ollCacheSize > maxSize) {
- QValueList<CollectionItem*> tempList( mColList ); // work on a copy, KNGroup-/Foldermanager will
+ TQValueList<CollectionItem*> tempList( mColList ); // work on a copy, KNGroup-/Foldermanager will
// modify the original list
- for ( QValueList<CollectionItem*>::Iterator it = tempList.begin(); it != tempList.end(); ) {
+ for ( TQValueList<CollectionItem*>::Iterator it = tempList.begin(); it != tempList.end(); ) {
if ( c_ollCacheSize <= maxSize )
break;
// unloadHeaders() will remove the cache entry and thus invalidate the iterator!
@@ -185,10 +185,10 @@ void KNMemoryManager::checkMemoryUsageArticles()
int maxSize = knGlobals.configManager()->readNewsGeneral()->artCacheSize() * 1024;
if (a_rtCacheSize > maxSize) {
- QValueList<ArticleItem*> tempList( mArtList ); // work on a copy, KNArticlemanager will
+ TQValueList<ArticleItem*> tempList( mArtList ); // work on a copy, KNArticlemanager will
// modify the original list
- for ( QValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ) {
+ for ( TQValueList<ArticleItem*>::Iterator it = mArtList.begin(); it != mArtList.end(); ) {
if ( a_rtCacheSize <= maxSize )
break;
// unloadArticle() will remove the cache entry and thus invalidate the iterator!
diff --git a/knode/knmemorymanager.h b/knode/knmemorymanager.h
index a9a79d9cf..71d222425 100644
--- a/knode/knmemorymanager.h
+++ b/knode/knmemorymanager.h
@@ -15,8 +15,8 @@
#ifndef KNMEMORYMANAGER_H
#define KNMEMORYMANAGER_H
-#include <qglobal.h>
-#include <qvaluelist.h>
+#include <tqglobal.h>
+#include <tqvaluelist.h>
class KNArticle;
class KNArticleCollection;
@@ -65,8 +65,8 @@ class KNMemoryManager {
void checkMemoryUsageCollections();
void checkMemoryUsageArticles();
- QValueList<CollectionItem*> mColList;
- QValueList<ArticleItem*> mArtList;
+ TQValueList<CollectionItem*> mColList;
+ TQValueList<ArticleItem*> mArtList;
int c_ollCacheSize, a_rtCacheSize;
};
diff --git a/knode/knnetaccess.cpp b/knode/knnetaccess.cpp
index 65b43e7a5..7fc6fd371 100644
--- a/knode/knnetaccess.cpp
+++ b/knode/knnetaccess.cpp
@@ -15,7 +15,7 @@
#include <unistd.h>
#include <fcntl.h>
-#include <qsocketnotifier.h>
+#include <tqsocketnotifier.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -37,8 +37,8 @@
using KPIM::ProgressManager;
-KNNetAccess::KNNetAccess(QObject *parent, const char *name )
- : QObject(parent,name), currentNntpJob(0), currentSmtpJob(0)
+KNNetAccess::KNNetAccess(TQObject *parent, const char *name )
+ : TQObject(parent,name), currentNntpJob(0), currentSmtpJob(0)
{
if ( pipe(nntpInPipe) == -1 || pipe(nntpOutPipe) == -1 ) {
KMessageBox::error(knGlobals.topWidget, i18n("Internal error:\nFailed to open pipes for internal communication."));
@@ -50,8 +50,8 @@ KNNetAccess::KNNetAccess(QObject *parent, const char *name )
kapp->exit(1);
}
- nntpNotifier=new QSocketNotifier(nntpInPipe[0], QSocketNotifier::Read);
- connect(nntpNotifier, SIGNAL(activated(int)), this, SLOT(slotThreadSignal(int)));
+ nntpNotifier=new TQSocketNotifier(nntpInPipe[0], TQSocketNotifier::Read);
+ connect(nntpNotifier, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotThreadSignal(int)));
// initialize the KSocks stuff in the main thread, otherwise we get
// strange effects on FreeBSD
@@ -60,14 +60,14 @@ KNNetAccess::KNNetAccess(QObject *parent, const char *name )
nntpClient=new KNNntpClient(nntpOutPipe[0],nntpInPipe[1],nntp_Mutex);
nntpClient->start();
- connect( knGlobals.accountManager(), SIGNAL(passwordsChanged()), SLOT(slotPasswordsChanged()) );
+ connect( knGlobals.accountManager(), TQT_SIGNAL(passwordsChanged()), TQT_SLOT(slotPasswordsChanged()) );
}
KNNetAccess::~KNNetAccess()
{
- disconnect(nntpNotifier, SIGNAL(activated(int)), this, SLOT(slotThreadSignal(int)));
+ disconnect(nntpNotifier, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotThreadSignal(int)));
nntpClient->terminateClient();
triggerAsyncThread(nntpOutPipe[1]);
@@ -95,7 +95,7 @@ void KNNetAccess::addJob(KNJobData *job)
}
job->createProgressItem();
- connect( job->progressItem(), SIGNAL(progressItemCanceled(KPIM::ProgressItem*)), SLOT(slotCancelJob(KPIM::ProgressItem*)) );
+ connect( job->progressItem(), TQT_SIGNAL(progressItemCanceled(KPIM::ProgressItem*)), TQT_SLOT(slotCancelJob(KPIM::ProgressItem*)) );
emit netActive( true );
// put jobs which are waiting for the wallet into an extra queue
@@ -120,7 +120,7 @@ void KNNetAccess::addJob(KNJobData *job)
// avoid duplicate fetchNewHeader jobs...
bool duplicate = false;
if ( job->type() == KNJobData::JTfetchNewHeaders || job->type() == KNJobData::JTsilentFetchNewHeaders ) {
- QValueList<KNJobData*>::ConstIterator it;
+ TQValueList<KNJobData*>::ConstIterator it;
for ( it = nntpJobQueue.begin(); it != nntpJobQueue.end(); ++it ) {
if ( ( (*it)->type() == KNJobData::JTfetchNewHeaders || (*it)->type() == KNJobData::JTsilentFetchNewHeaders )
&& (*it)->data() == job->data() ) // job works on the same group...
@@ -159,7 +159,7 @@ void KNNetAccess::stopJobsNntp( int type )
{
cancelCurrentNntpJob( type );
KNJobData *tmp = 0;
- QValueList<KNJobData*>::Iterator it;
+ TQValueList<KNJobData*>::Iterator it;
for ( it = nntpJobQueue.begin(); it != nntpJobQueue.end();) {
tmp = *it;
if ( type == 0 || tmp->type() == type ) {
@@ -197,7 +197,7 @@ void KNNetAccess::stopJobsSmtp( int type )
{
cancelCurrentSmtpJob( type );
KNJobData *tmp = 0;
- QValueList<KNJobData*>::Iterator it;
+ TQValueList<KNJobData*>::Iterator it;
for ( it = smtpJobQueue.begin(); it != smtpJobQueue.end();) {
tmp = *it;
if ( type == 0 || tmp->type() == type ) {
@@ -253,9 +253,9 @@ void KNNetAccess::startJobSmtp()
if (currentSmtpJob->success()) {
KNLocalArticle *art = static_cast<KNLocalArticle*>( currentSmtpJob->data() );
// create url query part
- QString query("headers=0&from=");
+ TQString query("headers=0&from=");
query += KURL::encode_string( art->from()->email() );
- QStrList emails;
+ TQStrList emails;
art->to()->emails( &emails );
for ( char *e = emails.first(); e; e = emails.next() ) {
query += "&to=" + KURL::encode_string( e );
@@ -275,8 +275,8 @@ void KNNetAccess::startJobSmtp()
destination.setPass( account->pass() );
}
KIO::Job* job = KIO::storedPut( art->encodedContent(true), destination, -1, false, false, false );
- connect( job, SIGNAL( result(KIO::Job*) ),
- SLOT( slotJobResult(KIO::Job*) ) );
+ connect( job, TQT_SIGNAL( result(KIO::Job*) ),
+ TQT_SLOT( slotJobResult(KIO::Job*) ) );
if ( account->encryption() == KNServerInfo::TLS )
job->addMetaData( "tls", "on" );
else
@@ -307,8 +307,8 @@ void KNNetAccess::threadDoneNntp()
kdDebug(5003) << "KNNetAccess::threadDoneNntp(): authentication error" << endl;
KNServerInfo *info = tmp->account();
if (info) {
- QString user = info->user();
- QString pass = info->pass();
+ TQString user = info->user();
+ TQString pass = info->pass();
bool keep=false;
if (KDialog::Accepted == KIO::PasswordDialog::getNameAndPassword(user, pass, &keep,
i18n("You need to supply a username and a\npassword to access this server"), false,
@@ -317,7 +317,7 @@ void KNNetAccess::threadDoneNntp()
info->setUser(user);
info->setPass(pass);
tmp->setAuthError(false);
- tmp->setErrorString(QString::null);
+ tmp->setErrorString(TQString::null);
kdDebug(5003) << "KNNetAccess::threadDoneNntp(): trying again with authentication data" << endl;
@@ -331,7 +331,7 @@ void KNNetAccess::threadDoneNntp()
nntpClient->removeJob();
currentNntpJob = 0L;
- currMsg = QString::null;
+ currMsg = TQString::null;
knGlobals.setStatusMsg();
tmp->setComplete();
@@ -358,7 +358,7 @@ void KNNetAccess::threadDoneSmtp()
tmp = currentSmtpJob;
currentSmtpJob = 0L;
if (!currentNntpJob) {
- currMsg = QString::null;
+ currMsg = TQString::null;
knGlobals.setStatusMsg();
}
tmp->setComplete();
@@ -383,7 +383,7 @@ void KNNetAccess::cancelAllJobs()
void KNNetAccess::slotThreadSignal(int i)
{
int signal;
- QString tmp;
+ TQString tmp;
//kdDebug(5003) << "KNNetAccess::slotThreadSignal() : signal received from net thread" << endl;
if(read(i, &signal, sizeof(int))==-1) {
@@ -475,7 +475,7 @@ void KNNetAccess::slotJobResult( KIO::Job *job )
void KNNetAccess::slotPasswordsChanged()
{
- QValueList<KNJobData*>::ConstIterator it;
+ TQValueList<KNJobData*>::ConstIterator it;
for ( it = mWalletQueue.begin(); it != mWalletQueue.end(); ++it ) {
(*it)->setStatus( i18n("Waiting...") );
if ( (*it)->type() == KNJobData::JTmail )
@@ -494,7 +494,7 @@ void KNNetAccess::slotPasswordsChanged()
void KNNetAccess::slotCancelJob( KPIM::ProgressItem *item )
{
KNJobData *tmp = 0;
- QValueList<KNJobData*>::Iterator it;
+ TQValueList<KNJobData*>::Iterator it;
for ( it = nntpJobQueue.begin(); it != nntpJobQueue.end();) {
tmp = *it;
if ( tmp->progressItem() == item ) {
diff --git a/knode/knnetaccess.h b/knode/knnetaccess.h
index 02450b9c7..e86f4a9cb 100644
--- a/knode/knnetaccess.h
+++ b/knode/knnetaccess.h
@@ -15,9 +15,9 @@
#ifndef KNNETACCESS_H
#define KNNETACCESS_H
-#include <qobject.h>
-#include <qmutex.h>
-#include <qvaluelist.h>
+#include <tqobject.h>
+#include <tqmutex.h>
+#include <tqvaluelist.h>
class QSocketNotifier;
@@ -34,13 +34,13 @@ class KNJobData;
class KNNntpClient;
-class KNNetAccess : public QObject {
+class KNNetAccess : public TQObject {
Q_OBJECT
public:
- KNNetAccess(QObject *parent=0, const char *name=0);
+ KNNetAccess(TQObject *parent=0, const char *name=0);
~KNNetAccess();
void addJob(KNJobData *job);
@@ -51,9 +51,9 @@ class KNNetAccess : public QObject {
void cancelAllJobs();
/** current statusbar message */
- QString currentMsg() const { return currMsg; }
+ TQString currentMsg() const { return currMsg; }
- QMutex& nntpMutex() { return nntp_Mutex; }
+ TQMutex& nntpMutex() { return nntp_Mutex; }
protected:
/** passes a signal through the ipc-pipe to the net-thread */
@@ -65,14 +65,14 @@ class KNNetAccess : public QObject {
/** stores the current status message,
so that it can be restored by the mainwindow */
- QString currMsg;
+ TQString currMsg;
KNNntpClient *nntpClient;
- QValueList<KNJobData*> nntpJobQueue, smtpJobQueue;
+ TQValueList<KNJobData*> nntpJobQueue, smtpJobQueue;
KNJobData *currentNntpJob, *currentSmtpJob;
- QMutex nntp_Mutex;
+ TQMutex nntp_Mutex;
int nntpInPipe[2], nntpOutPipe[2];
- QSocketNotifier *nntpNotifier;
+ TQSocketNotifier *nntpNotifier;
protected slots:
void slotThreadSignal(int i);
@@ -95,7 +95,7 @@ class KNNetAccess : public QObject {
private:
/// jobs waiting for async wallet loading
- QValueList<KNJobData*> mWalletQueue;
+ TQValueList<KNJobData*> mWalletQueue;
};
diff --git a/knode/knnntpaccount.cpp b/knode/knnntpaccount.cpp
index 22ff904b2..ba1657c0c 100644
--- a/knode/knnntpaccount.cpp
+++ b/knode/knnntpaccount.cpp
@@ -45,8 +45,8 @@ void KNNntpAccountIntervalChecking::installTimer()
if (a_ccount->checkInterval() <= 0) return;
if(!t_imer)
{
- t_imer = new QTimer();
- connect(t_imer,SIGNAL(timeout()),this,SLOT(slotCheckNews()));
+ t_imer = new TQTimer();
+ connect(t_imer,TQT_SIGNAL(timeout()),this,TQT_SLOT(slotCheckNews()));
}
else
{
@@ -75,7 +75,7 @@ void KNNntpAccountIntervalChecking::slotCheckNews()
KNNntpAccount::KNNntpAccount()
: KNCollection(0), KNServerInfo(), i_dentity(0), f_etchDescriptions(true), w_asOpen(false), i_ntervalChecking(false), c_heckInterval(10)
{
- l_astNewFetch = QDate::currentDate();
+ l_astNewFetch = TQDate::currentDate();
a_ccountIntervalChecking = new KNNntpAccountIntervalChecking(this);
mCleanupConf = new KNConfig::Cleanup( false );
}
@@ -90,7 +90,7 @@ KNNntpAccount::~KNNntpAccount()
// tries to read information, returns false if it fails to do so
-bool KNNntpAccount::readInfo(const QString &confPath)
+bool KNNntpAccount::readInfo(const TQString &confPath)
{
KSimpleConfig conf(confPath);
@@ -109,7 +109,7 @@ bool KNNntpAccount::readInfo(const QString &confPath)
i_dentity=new KNConfig::Identity(false);
i_dentity->loadConfig(&conf);
if(!i_dentity->isEmpty()) {
- kdDebug(5003) << "KNGroup::readInfo(const QString &confPath) : using alternative user for " << n_ame << endl;
+ kdDebug(5003) << "KNGroup::readInfo(const TQString &confPath) : using alternative user for " << n_ame << endl;
} else {
delete i_dentity;
i_dentity=0;
@@ -126,7 +126,7 @@ bool KNNntpAccount::readInfo(const QString &confPath)
void KNNntpAccount::saveInfo()
{
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return;
@@ -135,7 +135,7 @@ void KNNntpAccount::saveInfo()
conf.writeEntry("name", n_ame);
//conf.writeEntry("unsentCnt", u_nsentCount);
conf.writeEntry("fetchDescriptions", f_etchDescriptions);
- conf.writeEntry("lastNewFetch", QDateTime(l_astNewFetch));
+ conf.writeEntry("lastNewFetch", TQDateTime(l_astNewFetch));
if(l_istItem)
conf.writeEntry("listItemOpen", l_istItem->isOpen());
conf.writeEntry("useDiskCache", u_seDiskCache);
@@ -164,7 +164,7 @@ void KNNntpAccount::saveInfo()
/*void KNNntpAccount::syncInfo()
{
- QString dir(path());
+ TQString dir(path());
if (dir.isNull())
return;
KSimpleConfig conf(dir+"info");
@@ -172,16 +172,16 @@ void KNNntpAccount::saveInfo()
}*/
-QString KNNntpAccount::path()
+TQString KNNntpAccount::path()
{
- QString dir(locateLocal("data","knode/")+QString("nntp.%1/").arg(i_d));
+ TQString dir(locateLocal("data","knode/")+TQString("nntp.%1/").arg(i_d));
if (dir.isNull())
KNHelper::displayInternalFileError();
return (dir);
}
-bool KNNntpAccount::editProperties(QWidget *parent)
+bool KNNntpAccount::editProperties(TQWidget *parent)
{
if(!i_dentity) i_dentity=new KNConfig::Identity(false);
KNConfig::NntpAccountConfDialog *d = new KNConfig::NntpAccountConfDialog(this, parent);
diff --git a/knode/knnntpaccount.h b/knode/knnntpaccount.h
index 4c7694ff6..611339191 100644
--- a/knode/knnntpaccount.h
+++ b/knode/knnntpaccount.h
@@ -17,12 +17,12 @@
#ifndef KNNNTPACCOUNT_H
#define KNNNTPACCOUNT_H
-#include <qdatetime.h>
+#include <tqdatetime.h>
#include "kncollection.h"
#include "knserverinfo.h"
-#include <qobject.h>
-#include <qtimer.h>
+#include <tqobject.h>
+#include <tqtimer.h>
class KNNntpAccount;
@@ -32,7 +32,7 @@ namespace KNConfig {
}
-class KNNntpAccountIntervalChecking : public QObject {
+class KNNntpAccountIntervalChecking : public TQObject {
Q_OBJECT
@@ -43,7 +43,7 @@ class KNNntpAccountIntervalChecking : public QObject {
void deinstallTimer();
protected:
- QTimer *t_imer;
+ TQTimer *t_imer;
KNNntpAccount *a_ccount;
protected slots:
@@ -60,19 +60,19 @@ class KNNntpAccount : public KNCollection , public KNServerInfo {
collectionType type() { return CTnntpAccount; }
/** tries to read information, returns false if it fails to do so */
- bool readInfo(const QString &confPath);
+ bool readInfo(const TQString &confPath);
void saveInfo();
//void syncInfo();
- QString path();
+ TQString path();
/** returns true when the user accepted */
- bool editProperties(QWidget *parent);
+ bool editProperties(TQWidget *parent);
// news interval checking
void startTimer();
//get
bool fetchDescriptions() const { return f_etchDescriptions; }
- QDate lastNewFetch() const { return l_astNewFetch; }
+ TQDate lastNewFetch() const { return l_astNewFetch; }
bool wasOpen() const { return w_asOpen; }
bool useDiskCache() const { return u_seDiskCache; }
KNConfig::Identity* identity() const { return i_dentity; }
@@ -85,7 +85,7 @@ class KNNntpAccount : public KNCollection , public KNServerInfo {
//set
void setFetchDescriptions(bool b) { f_etchDescriptions = b; }
- void setLastNewFetch(QDate date) { l_astNewFetch = date; }
+ void setLastNewFetch(TQDate date) { l_astNewFetch = date; }
void setUseDiskCache(bool b) { u_seDiskCache=b; }
void setCheckInterval(int c);
void setIntervalChecking(bool b) { i_ntervalChecking=b; }
@@ -98,7 +98,7 @@ class KNNntpAccount : public KNCollection , public KNServerInfo {
/** use an additional "list newsgroups" command to fetch the newsgroup descriptions */
bool f_etchDescriptions;
/** last use of "newgroups" */
- QDate l_astNewFetch;
+ TQDate l_astNewFetch;
/** was the server open in the listview on the last shutdown? */
bool w_asOpen;
/** cache fetched articles on disk */
@@ -107,7 +107,7 @@ class KNNntpAccount : public KNCollection , public KNServerInfo {
bool i_ntervalChecking;
int c_heckInterval;
- /** helper class for news interval checking, manages the QTimer */
+ /** helper class for news interval checking, manages the TQTimer */
KNNntpAccountIntervalChecking *a_ccountIntervalChecking;
};
diff --git a/knode/knnntpclient.cpp b/knode/knnntpclient.cpp
index 2c594be34..47942d6b3 100644
--- a/knode/knnntpclient.cpp
+++ b/knode/knnntpclient.cpp
@@ -16,15 +16,15 @@
#include <stdlib.h>
#include <klocale.h>
-#include <qtextcodec.h>
-#include <qmutex.h>
+#include <tqtextcodec.h>
+#include <tqmutex.h>
#include "kngroupmanager.h"
#include "knnntpclient.h"
#include "utilities.h"
-KNNntpClient::KNNntpClient(int NfdPipeIn, int NfdPipeOut, QMutex& nntpMutex)
+KNNntpClient::KNNntpClient(int NfdPipeIn, int NfdPipeOut, TQMutex& nntpMutex)
: KNProtocolClient(NfdPipeIn,NfdPipeOut), mutex(nntpMutex)
{}
@@ -92,7 +92,7 @@ void KNNntpClient::doFetchGroups()
return;
char *s, *line;
- QString name;
+ TQString name;
KNGroup::Status status;
bool subscribed;
@@ -113,7 +113,7 @@ void KNNntpClient::doFetchGroups()
} else {
s[0] = 0; // cut string
- name = QString::fromUtf8(line);
+ name = TQString::fromUtf8(line);
if (target->subscribed.contains(name)) {
target->subscribed.remove(name); // group names are unique, we wont find it again anyway...
@@ -132,7 +132,7 @@ void KNNntpClient::doFetchGroups()
default : status = KNGroup::unknown;
}
- target->groups->append(new KNGroupInfo(name,QString::null,false,subscribed,status));
+ target->groups->append(new KNGroupInfo(name,TQString::null,false,subscribed,status));
}
doneLines++;
}
@@ -158,7 +158,7 @@ void KNNntpClient::doFetchGroups()
return;
if (rep == 215) { // 215 informations follows
- QString description;
+ TQString description;
KNGroupInfo info;
int pos;
@@ -182,11 +182,11 @@ void KNNntpClient::doFetchGroups()
s++;
while (*s == ' ' || *s == '\t') s++; // go on to the description
- name = QString::fromUtf8(line);
+ name = TQString::fromUtf8(line);
if (target->codecForDescriptions) // some countries use local 8 bit characters in the tag line
description = target->codecForDescriptions->toUnicode(s);
else
- description = QString::fromLocal8Bit(s);
+ description = TQString::fromLocal8Bit(s);
info.name = name;
if ((pos=tempVector.bsearch(&info))!=-1)
@@ -221,15 +221,15 @@ void KNNntpClient::doCheckNewGroups()
progressValue = 100;
predictedLines = 30; // rule of thumb ;-)
- QCString cmd;
+ TQCString cmd;
cmd.sprintf("NEWGROUPS %.2d%.2d%.2d 000000",target->fetchSince.year()%100,target->fetchSince.month(),target->fetchSince.day());
if (!sendCommandWCheck(cmd,231)) // 231 list of new newsgroups follows
return;
char *s, *line;
- QString name;
+ TQString name;
KNGroup::Status status;
- QSortedList<KNGroupInfo> tmpList;
+ TQSortedList<KNGroupInfo> tmpList;
tmpList.setAutoDelete(true);
while (getNextLine()) {
@@ -248,7 +248,7 @@ void KNNntpClient::doCheckNewGroups()
#endif
} else {
s[0] = 0; // cut string
- name = QString::fromUtf8(line);
+ name = TQString::fromUtf8(line);
while (s[1]!=0) s++; // the last character determines the moderation status
switch (s[0]) {
@@ -261,7 +261,7 @@ void KNNntpClient::doCheckNewGroups()
default : status = KNGroup::unknown;
}
- tmpList.append(new KNGroupInfo(name,QString::null,true,false,status));
+ tmpList.append(new KNGroupInfo(name,TQString::null,true,false,status));
}
doneLines++;
}
@@ -279,7 +279,7 @@ void KNNntpClient::doCheckNewGroups()
sendSignal(TSprogressUpdate);
cmd = "LIST NEWSGROUPS ";
- QStrList desList;
+ TQStrList desList;
char *s;
int rep;
@@ -304,7 +304,7 @@ void KNNntpClient::doCheckNewGroups()
if (target->codecForDescriptions) // some countries use local 8 bit characters in the tag line
group->description = target->codecForDescriptions->toUnicode(s);
else
- group->description = QString::fromLocal8Bit(s);
+ group->description = TQString::fromLocal8Bit(s);
}
}
}
@@ -330,7 +330,7 @@ void KNNntpClient::doFetchNewHeaders()
KNGroup* target=static_cast<KNGroup*>(job->data());
char* s;
int first=0, last=0, oldlast=0, toFetch=0, rep=0;
- QCString cmd;
+ TQCString cmd;
target->setLastFetchCount(0);
@@ -362,7 +362,7 @@ void KNNntpClient::doFetchNewHeaders()
if (s) {
last=atoi(s);
} else {
- QString tmp=i18n("No new articles could be retrieved.\nThe server sent a malformatted response:\n");
+ TQString tmp=i18n("No new articles could be retrieved.\nThe server sent a malformatted response:\n");
tmp+=getCurrentLine();
job->setErrorString(tmp);
closeConnection();
@@ -396,12 +396,12 @@ void KNNntpClient::doFetchNewHeaders()
// get list of additional headers provided by the XOVER command
// see RFC 2980 section 2.1.7
- QStrList headerformat;
+ TQStrList headerformat;
cmd = "LIST OVERVIEW.FMT";
if ( sendCommand( cmd, rep ) && rep == 215 ) {
- QStrList tmp;
+ TQStrList tmp;
if (getMsg(tmp)) {
- for(QCString s = tmp.first(); s; s = tmp.next()) {
+ for(TQCString s = tmp.first(); s; s = tmp.next()) {
s = s.stripWhiteSpace();
// remove the mandatory xover header
if (s == "Subject:" || s == "From:" || s == "Date:" || s == "Message-ID:"
@@ -427,7 +427,7 @@ void KNNntpClient::doFetchNewHeaders()
return;
}
- QStrList headers;
+ TQStrList headers;
if (!getMsg(headers)) {
return;
}
@@ -447,7 +447,7 @@ void KNNntpClient::doFetchNewHeaders()
void KNNntpClient::doFetchArticle()
{
KNRemoteArticle *target = static_cast<KNRemoteArticle*>(job->data());
- QCString cmd;
+ TQCString cmd;
sendSignal(TSdownloadArticle);
errorPrefix = i18n("Article could not be retrieved.\nThe following error occurred:\n");
@@ -456,7 +456,7 @@ void KNNntpClient::doFetchArticle()
predictedLines = target->lines()->numberOfLines()+10;
if (target->collection()) {
- QString groupName = static_cast<KNGroup*>(target->collection())->groupname();
+ TQString groupName = static_cast<KNGroup*>(target->collection())->groupname();
if (currentGroup != groupName) {
cmd="GROUP ";
cmd+=groupName.utf8();
@@ -476,7 +476,7 @@ void KNNntpClient::doFetchArticle()
if (!sendCommandWCheck(cmd,220)) { // 220 n <a> article retrieved - head and body follow
int code = atoi(getCurrentLine());
if ( code == 430 || code == 423 ) { // 430 no such article found || 423 no such article number in this group
- QString msgId = target->messageID()->as7BitString( false );
+ TQString msgId = target->messageID()->as7BitString( false );
// strip of '<' and '>'
msgId = msgId.mid( 1, msgId.length() - 2 );
job->setErrorString( errorPrefix + getCurrentLine() +
@@ -487,7 +487,7 @@ void KNNntpClient::doFetchArticle()
return;
}
- QStrList msg;
+ TQStrList msg;
if (!getMsg(msg))
return;
@@ -507,7 +507,7 @@ void KNNntpClient::doPostArticle()
if (art->messageID(false)!=0) {
int rep;
- if (!sendCommand(QCString("STAT ")+art->messageID(false)->as7BitString(false),rep))
+ if (!sendCommand(TQCString("STAT ")+art->messageID(false)->as7BitString(false),rep))
return;
if (rep==223) { // 223 n <a> article retrieved - request text separately
@@ -522,8 +522,8 @@ void KNNntpClient::doPostArticle()
return;
if (art->messageID(false)==0) { // article has no message ID => search for a ID in the response
- QCString s = getCurrentLine();
- int start = s.findRev(QRegExp("<[^\\s]*@[^\\s]*>"));
+ TQCString s = getCurrentLine();
+ int start = s.findRev(TQRegExp("<[^\\s]*@[^\\s]*>"));
if (start != -1) { // post response includes a recommended id
int end = s.find('>',start);
art->messageID()->from7BitString(s.mid(start,end-start+1));
@@ -552,11 +552,11 @@ void KNNntpClient::doFetchSource()
progressValue = 100;
predictedLines = target->lines()->numberOfLines()+10;
- QCString cmd = "ARTICLE " + target->messageID()->as7BitString(false);
+ TQCString cmd = "ARTICLE " + target->messageID()->as7BitString(false);
if (!sendCommandWCheck(cmd,220)) // 220 n <a> article retrieved - head and body follow
return;
- QStrList msg;
+ TQStrList msg;
if (!getMsg(msg))
return;
@@ -569,9 +569,9 @@ void KNNntpClient::doFetchSource()
bool KNNntpClient::openConnection()
{
- currentGroup = QString::null;
+ currentGroup = TQString::null;
- QString oldPrefix = errorPrefix;
+ TQString oldPrefix = errorPrefix;
errorPrefix=i18n("Unable to connect.\nThe following error occurred:\n");
if (!KNProtocolClient::openConnection())
@@ -609,7 +609,7 @@ bool KNNntpClient::openConnection()
if (account.needsLogon() && !account.user().isEmpty()) {
//qDebug("knode: user: %s",account.user().latin1());
- QCString command = "AUTHINFO USER ";
+ TQCString command = "AUTHINFO USER ";
command += account.user().local8Bit();
if (!KNProtocolClient::sendCommand(command,rep))
return false;
@@ -669,7 +669,7 @@ bool KNNntpClient::openConnection()
// authentication on demand
-bool KNNntpClient::sendCommand(const QCString &cmd, int &rep)
+bool KNNntpClient::sendCommand(const TQCString &cmd, int &rep)
{
if (!KNProtocolClient::sendCommand(cmd,rep))
return false;
@@ -686,7 +686,7 @@ bool KNNntpClient::sendCommand(const QCString &cmd, int &rep)
//qDebug("knode: user: %s",account.user().data());
- QCString command = "AUTHINFO USER ";
+ TQCString command = "AUTHINFO USER ";
command += account.user().local8Bit();
if (!KNProtocolClient::sendCommand(command,rep))
return false;
diff --git a/knode/knnntpclient.h b/knode/knnntpclient.h
index 274c12271..14ecff359 100644
--- a/knode/knnntpclient.h
+++ b/knode/knnntpclient.h
@@ -17,7 +17,7 @@
#ifndef KNNNTPCLIENT_H
#define KNNNTPCLIENT_H
-#include <qmutex.h>
+#include <tqmutex.h>
#include <knprotocolclient.h>
@@ -26,7 +26,7 @@ class KNNntpClient : public KNProtocolClient {
public:
- KNNntpClient(int NfdPipeIn, int NfdPipeOut, QMutex& nntpMutex);
+ KNNntpClient(int NfdPipeIn, int NfdPipeOut, TQMutex& nntpMutex);
~KNNntpClient();
protected:
@@ -45,12 +45,12 @@ class KNNntpClient : public KNProtocolClient {
/** connect, handshake */
virtual bool openConnection();
/** authentication on demand */
- virtual bool sendCommand(const QCString &cmd, int &rep);
+ virtual bool sendCommand(const TQCString &cmd, int &rep);
virtual void handleErrors();
- bool switchToGroup(const QString &newGroup);
+ bool switchToGroup(const TQString &newGroup);
- QString currentGroup;
- QMutex& mutex;
+ TQString currentGroup;
+ TQMutex& mutex;
};
diff --git a/knode/knode.cpp b/knode/knode.cpp
index 0dd4e6a38..c2d7ee7f6 100644
--- a/knode/knode.cpp
+++ b/knode/knode.cpp
@@ -38,7 +38,7 @@
#include "kncollectionviewitem.h"
#include "knhdrviewitem.h"
-KNMainWindow::KNMainWindow( QWidget* pWidget )
+KNMainWindow::KNMainWindow( TQWidget* pWidget )
: KMainWindow(pWidget,"mainWindow")
{
//setupStatusBar();
@@ -46,17 +46,17 @@ KNMainWindow::KNMainWindow( QWidget* pWidget )
setStandardToolBarMenuEnabled(true);
//config stuff
- KStdAction::quit(kapp, SLOT(closeAllWindows()), actionCollection());
- KStdAction::configureToolbars(this, SLOT(slotConfToolbar()), actionCollection());
- KStdAction::keyBindings(this, SLOT(slotConfKeys()), actionCollection());
+ KStdAction::quit(kapp, TQT_SLOT(closeAllWindows()), actionCollection());
+ KStdAction::configureToolbars(this, TQT_SLOT(slotConfToolbar()), actionCollection());
+ KStdAction::keyBindings(this, TQT_SLOT(slotConfKeys()), actionCollection());
m_mainWidget = new KNMainWidget( this, true, this, 0 );
- connect( m_mainWidget, SIGNAL(signalCaptionChangeRequest(const QString&)),
- SLOT( setCaption(const QString&)) );
+ connect( m_mainWidget, TQT_SIGNAL(signalCaptionChangeRequest(const TQString&)),
+ TQT_SLOT( setCaption(const TQString&)) );
setCentralWidget( m_mainWidget );
setupStatusBar();
- connect( KPIM::BroadcastStatus::instance(), SIGNAL(statusMsg(const QString&)),
- this, SLOT(slotShowStatusMsg(const QString& )) );
+ connect( KPIM::BroadcastStatus::instance(), TQT_SIGNAL(statusMsg(const TQString&)),
+ this, TQT_SLOT(slotShowStatusMsg(const TQString& )) );
createGUI( "knodeui.rc" );
knGlobals.instance = 0;
@@ -77,7 +77,7 @@ void KNMainWindow::slotConfToolbar()
{
saveMainWindowSettings(knGlobals.config(),"mainWindow_options");
KEditToolbar dlg(actionCollection(), "knodeui.rc");
- connect(&dlg,SIGNAL( newToolbarConfig() ), this, SLOT( slotNewToolbarConfig() ));
+ connect(&dlg,TQT_SIGNAL( newToolbarConfig() ), this, TQT_SLOT( slotNewToolbarConfig() ));
dlg.exec();
}
@@ -108,14 +108,14 @@ void KNMainWindow::setupStatusBar()
statusBar()->addWidget( mLittleProgress, 0 , true );
- mStatusMsgLabel = new KRSqueezedTextLabel( QString::null, statusBar() );
+ mStatusMsgLabel = new KRSqueezedTextLabel( TQString::null, statusBar() );
mStatusMsgLabel->setAlignment( AlignLeft | AlignVCenter );
statusBar()->addWidget( mStatusMsgLabel, 2 );
statusBar()->addWidget(m_mainWidget->statusBarLabelFilter(), 2);
statusBar()->addWidget(m_mainWidget->statusBarLabelGroup(), 3);
}
-void KNMainWindow::slotShowStatusMsg( const QString &msg ) {
+void KNMainWindow::slotShowStatusMsg( const TQString &msg ) {
mStatusMsgLabel->setText( msg );
}
diff --git a/knode/knode.h b/knode/knode.h
index 8b719a5d8..d628df1b6 100644
--- a/knode/knode.h
+++ b/knode/knode.h
@@ -25,7 +25,7 @@
#include <kdialogbase.h>
#include "resource.h"
-#include <qglobal.h>
+#include <tqglobal.h>
class KURL;
@@ -46,7 +46,7 @@ class KNMainWindow : public KMainWindow
Q_OBJECT
public:
- KNMainWindow( QWidget* parentWidget=0 );
+ KNMainWindow( TQWidget* parentWidget=0 );
~KNMainWindow();
void openURL( const KURL& );
KNMainWidget *mainWidget() { return m_mainWidget; }
@@ -64,7 +64,7 @@ private:
ProgressDialog *mProgressDialog;
KRSqueezedTextLabel *mStatusMsgLabel;
private slots:
- void slotShowStatusMsg( const QString& );
+ void slotShowStatusMsg( const TQString& );
};
#endif // KNODE_H
diff --git a/knode/knode_part.cpp b/knode/knode_part.cpp
index b1280ced5..52b3e4dd6 100644
--- a/knode/knode_part.cpp
+++ b/knode/knode_part.cpp
@@ -41,14 +41,14 @@
#include <kstatusbar.h>
#include <krsqueezedtextlabel.h>
-#include <qlayout.h>
+#include <tqlayout.h>
typedef KParts::GenericFactory< KNodePart > KNodeFactory;
K_EXPORT_COMPONENT_FACTORY( libknodepart, KNodeFactory )
-KNodePart::KNodePart(QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name, const QStringList &)
+KNodePart::KNodePart(TQWidget *parentWidget, const char *widgetName,
+ TQObject *parent, const char *name, const TQStringList &)
: KParts::ReadOnlyPart(parent, name),
mParentWidget( parentWidget )
{
@@ -67,14 +67,14 @@ KNodePart::KNodePart(QWidget *parentWidget, const char *widgetName,
knGlobals.instance = KNodeFactory::instance();
// create a canvas to insert our widget
- QWidget *canvas = new QWidget(parentWidget, widgetName);
- canvas->setFocusPolicy(QWidget::ClickFocus);
+ TQWidget *canvas = new TQWidget(parentWidget, widgetName);
+ canvas->setFocusPolicy(TQWidget::ClickFocus);
setWidget(canvas);
mainWidget = new KNMainWidget( this, false, canvas, "knode_widget" );
- QVBoxLayout *topLayout = new QVBoxLayout(canvas);
+ TQVBoxLayout *topLayout = new TQVBoxLayout(canvas);
topLayout->addWidget(mainWidget);
- mainWidget->setFocusPolicy(QWidget::ClickFocus);
+ mainWidget->setFocusPolicy(TQWidget::ClickFocus);
kapp->dcopClient()->resume(); // Ok. We are ready for DCOP requests.
@@ -114,7 +114,7 @@ void KNodePart::guiActivateEvent(KParts::GUIActivateEvent *e)
}
-QWidget* KNodePart::parentWidget() const
+TQWidget* KNodePart::parentWidget() const
{
return mParentWidget;
}
diff --git a/knode/knode_part.h b/knode/knode_part.h
index 951befc5f..67e1ae549 100644
--- a/knode/knode_part.h
+++ b/knode/knode_part.h
@@ -31,7 +31,7 @@
#include <kparts/event.h>
#include <kparts/part.h>
-#include <qwidget.h>
+#include <tqwidget.h>
class KInstance;
class KAboutData;
@@ -43,11 +43,11 @@ class KNodePart: public KParts::ReadOnlyPart
{
Q_OBJECT
public:
- KNodePart(QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name, const QStringList &);
+ KNodePart(TQWidget *parentWidget, const char *widgetName,
+ TQObject *parent, const char *name, const TQStringList &);
virtual ~KNodePart();
- QWidget* parentWidget() const;
+ TQWidget* parentWidget() const;
static KAboutData *createAboutData();
@@ -57,7 +57,7 @@ class KNodePart: public KParts::ReadOnlyPart
private:
ActionManager *mActionManager;
- QWidget *mParentWidget;
+ TQWidget *mParentWidget;
KNMainWidget *mainWidget;
};
diff --git a/knode/knodecomposeriface.h b/knode/knodecomposeriface.h
index d311541be..d6f25f5ab 100644
--- a/knode/knodecomposeriface.h
+++ b/knode/knodecomposeriface.h
@@ -8,7 +8,7 @@ class KNodeComposerIface : virtual public DCOPObject
{
K_DCOP
k_dcop:
- virtual void initData(const QString &text) = 0;
+ virtual void initData(const TQString &text) = 0;
};
#endif
diff --git a/knode/knodeiface.h b/knode/knodeiface.h
index f92967bbb..9a52923fe 100644
--- a/knode/knodeiface.h
+++ b/knode/knodeiface.h
@@ -21,7 +21,7 @@
#include <dcopobject.h>
#include <dcopref.h>
#include <kurl.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
class KNodeIface : virtual public DCOPObject
diff --git a/knode/knprotocolclient.cpp b/knode/knprotocolclient.cpp
index 1d992d8a3..4831087c9 100644
--- a/knode/knprotocolclient.cpp
+++ b/knode/knprotocolclient.cpp
@@ -166,7 +166,7 @@ void KNProtocolClient::waitForWork()
if (isConnected()) // connection is ready
processJob();
}
- errorPrefix = QString::null;
+ errorPrefix = TQString::null;
clearPipe();
}
@@ -235,7 +235,7 @@ void KNProtocolClient::closeConnection()
int ret = KSocks::self()->select(FD_SETSIZE, NULL, &fdsW, NULL, &tv);
if (ret > 0) { // we can write...
- QCString cmd = "QUIT\r\n";
+ TQCString cmd = "QUIT\r\n";
int todo = cmd.length();
KSocks::self()->write(tcpSocket,&cmd.data()[0],todo);
}
@@ -244,7 +244,7 @@ void KNProtocolClient::closeConnection()
// sends a command (one line), return code is written to rep
-bool KNProtocolClient::sendCommand(const QCString &cmd, int &rep)
+bool KNProtocolClient::sendCommand(const TQCString &cmd, int &rep)
{
if (!sendStr(cmd + "\r\n"))
return false;
@@ -255,7 +255,7 @@ bool KNProtocolClient::sendCommand(const QCString &cmd, int &rep)
// checks return code and calls handleErrors() if necessary
-bool KNProtocolClient::sendCommandWCheck(const QCString &cmd, int rep)
+bool KNProtocolClient::sendCommandWCheck(const TQCString &cmd, int rep)
{
int code;
@@ -270,11 +270,11 @@ bool KNProtocolClient::sendCommandWCheck(const QCString &cmd, int rep)
// sends a message (multiple lines)
-bool KNProtocolClient::sendMsg(const QCString &msg)
+bool KNProtocolClient::sendMsg(const TQCString &msg)
{
const char *line = msg.data();
const char *end;
- QCString buffer;
+ TQCString buffer;
size_t length;
char inter[10000];
@@ -382,7 +382,7 @@ bool KNProtocolClient::getNextLine()
// receives a message (multiple lines)
-bool KNProtocolClient::getMsg(QStrList &msg)
+bool KNProtocolClient::getMsg(TQStrList &msg)
{
char *line;
@@ -469,7 +469,7 @@ bool KNProtocolClient::waitForRead()
if (ret == -1) { // select failed
if (job) {
- QString str = i18n("Communication error:\n");
+ TQString str = i18n("Communication error:\n");
str += strerror(errno);
job->setErrorString(str);
}
@@ -531,7 +531,7 @@ bool KNProtocolClient::waitForWrite()
if (ret == -1) { // select failed
if (job) {
- QString str = i18n("Communication error:\n");
+ TQString str = i18n("Communication error:\n");
str += strerror(errno);
job->setErrorString(str);
}
@@ -579,7 +579,7 @@ void KNProtocolClient::closeSocket()
// sends str to the server
-bool KNProtocolClient::sendStr(const QCString &str)
+bool KNProtocolClient::sendStr(const TQCString &str)
{
int ret;
int todo = str.length();
@@ -591,7 +591,7 @@ bool KNProtocolClient::sendStr(const QCString &str)
ret = KSocks::self()->write(tcpSocket,&str.data()[done],todo);
if (ret <= 0) {
if (job) {
- QString str = i18n("Communication error:\n");
+ TQString str = i18n("Communication error:\n");
str += strerror(errno);
job->setErrorString(str);
}
diff --git a/knode/knprotocolclient.h b/knode/knprotocolclient.h
index e531a278b..a17b68782 100644
--- a/knode/knprotocolclient.h
+++ b/knode/knprotocolclient.h
@@ -17,9 +17,9 @@
#ifndef KNPROTOCOLCLIENT_H
#define KNPROTOCOLCLIENT_H
-#include <qdatetime.h>
-#include <qthread.h>
-#include <qcstring.h>
+#include <tqdatetime.h>
+#include <tqthread.h>
+#include <tqcstring.h>
#include <knserverinfo.h>
@@ -28,7 +28,7 @@ class KNJobData;
struct in_addr;
-class KNProtocolClient : public QThread {
+class KNProtocolClient : public TQThread {
public:
enum threadSignal { TSworkDone=0, TSjobStarted=1, TSconnect=2, TSloadGrouplist=3,
@@ -66,18 +66,18 @@ class KNProtocolClient : public QThread {
virtual void closeConnection();
/** sends a command (one line), return code is written to rep */
- virtual bool sendCommand(const QCString &cmd, int &rep);
+ virtual bool sendCommand(const TQCString &cmd, int &rep);
/** checks return code and calls handleErrors() if necessary */
- bool sendCommandWCheck(const QCString &cmd, int rep);
+ bool sendCommandWCheck(const TQCString &cmd, int rep);
/** sends a message (multiple lines) */
- bool sendMsg(const QCString &msg);
+ bool sendMsg(const TQCString &msg);
/** reads next complete line of input */
bool getNextLine();
/** returns pointer to current line of input */
char* getCurrentLine() { return thisLine; };
/** receives a message (multiple lines) */
- bool getMsg(QStrList &msg);
+ bool getMsg(TQStrList &msg);
/** reads next line and returns the response code */
bool getNextResponse(int &rep);
/** checks return code and calls handleErrors() if necessary */
@@ -91,7 +91,7 @@ class KNProtocolClient : public QThread {
KNJobData *job;
KNServerInfo account;
/** handleErrors() adds this string to the error message */
- QString errorPrefix;
+ TQString errorPrefix;
int progressValue, predictedLines, doneLines;
bool byteCountMode;
@@ -102,7 +102,7 @@ class KNProtocolClient : public QThread {
bool waitForWrite();
void closeSocket();
/** sends str to the server */
- bool sendStr(const QCString &str);
+ bool sendStr(const TQCString &str);
/** removes start/stop signal */
void clearPipe();
@@ -114,7 +114,7 @@ class KNProtocolClient : public QThread {
int tcpSocket;
/** bytes in&out for the current connection */
int byteCount;
- QTime timer;
+ TQTime timer;
bool mTerminate;
};
diff --git a/knode/knrangefilter.cpp b/knode/knrangefilter.cpp
index bfa02110f..ee14c794f 100644
--- a/knode/knrangefilter.cpp
+++ b/knode/knrangefilter.cpp
@@ -14,10 +14,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qcheckbox.h>
-#include <qcombobox.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
+#include <tqcombobox.h>
#include <ksimpleconfig.h>
#include <knuminput.h>
@@ -96,31 +96,31 @@ void KNRangeFilter::save(KSimpleConfig *conf)
//=====================================================================================
//=====================================================================================
-KNRangeFilterWidget::KNRangeFilterWidget(const QString& value, int min, int max, QWidget* parent, const QString &unit)
- : QGroupBox(value, parent)
+KNRangeFilterWidget::KNRangeFilterWidget(const TQString& value, int min, int max, TQWidget* parent, const TQString &unit)
+ : TQGroupBox(value, parent)
{
- enabled=new QCheckBox(this);
+ enabled=new TQCheckBox(this);
val1=new KIntSpinBox(min, max, 1, min, 10, this);
val1->setSuffix(unit);
val2=new KIntSpinBox(min, max, 1, min, 10, this);
val2->setSuffix(unit);
- op1=new QComboBox(this);
+ op1=new TQComboBox(this);
op1->insertItem("<");
op1->insertItem("<=");
op1->insertItem("=");
op1->insertItem(">=");
op1->insertItem(">");
- op2=new QComboBox(this);
+ op2=new TQComboBox(this);
op2->insertItem("");
op2->insertItem("<");
op2->insertItem("<=");
- des=new QLabel(value, this);
+ des=new TQLabel(value, this);
des->setAlignment(AlignCenter);
- QGridLayout *topL=new QGridLayout(this, 2,6, 8,5 );
+ TQGridLayout *topL=new TQGridLayout(this, 2,6, 8,5 );
topL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
topL->addWidget(enabled,1,0, Qt::AlignHCenter);
@@ -134,9 +134,9 @@ KNRangeFilterWidget::KNRangeFilterWidget(const QString& value, int min, int max,
topL->setColStretch(1,1);
topL->setColStretch(5,1);
- connect(op1, SIGNAL(activated(int)), SLOT(slotOp1Changed(int)));
- connect(op2, SIGNAL(activated(int)), SLOT(slotOp2Changed(int)));
- connect(enabled, SIGNAL(toggled(bool)), SLOT(slotEnabled(bool)));
+ connect(op1, TQT_SIGNAL(activated(int)), TQT_SLOT(slotOp1Changed(int)));
+ connect(op2, TQT_SIGNAL(activated(int)), TQT_SLOT(slotOp2Changed(int)));
+ connect(enabled, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotEnabled(bool)));
slotEnabled(false);
}
diff --git a/knode/knrangefilter.h b/knode/knrangefilter.h
index 702a2ca55..297a21344 100644
--- a/knode/knrangefilter.h
+++ b/knode/knrangefilter.h
@@ -17,7 +17,7 @@
#ifndef KNRANGEFILTER_H
#define KNRANGEFILTER_H
-#include <qgroupbox.h>
+#include <tqgroupbox.h>
class QLabel;
class KIntSpinBox;
@@ -60,12 +60,12 @@ class KNRangeFilter {
//==================================================================================
-class KNRangeFilterWidget : public QGroupBox {
+class KNRangeFilterWidget : public TQGroupBox {
Q_OBJECT
public:
- KNRangeFilterWidget(const QString& value, int min, int max, QWidget* parent, const QString &unit=QString::null);
+ KNRangeFilterWidget(const TQString& value, int min, int max, TQWidget* parent, const TQString &unit=TQString::null);
~KNRangeFilterWidget();
KNRangeFilter filter();
@@ -73,10 +73,10 @@ class KNRangeFilterWidget : public QGroupBox {
void clear();
protected:
- QCheckBox *enabled;
- QLabel *des;
+ TQCheckBox *enabled;
+ TQLabel *des;
KIntSpinBox *val1, *val2;
- QComboBox *op1, *op2;
+ TQComboBox *op1, *op2;
protected slots:
void slotEnabled(bool e);
diff --git a/knode/knscoring.cpp b/knode/knscoring.cpp
index cad44fc81..c83cbccde 100644
--- a/knode/knscoring.cpp
+++ b/knode/knscoring.cpp
@@ -12,7 +12,7 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qstring.h>
+#include <tqstring.h>
#include <kwin.h>
#include <kscoringeditor.h>
@@ -43,35 +43,35 @@ void KNScorableArticle::addScore(short s)
_a->setChanged(true);
}
-void KNScorableArticle::changeColor(const QColor& c)
+void KNScorableArticle::changeColor(const TQColor& c)
{
_a->setColor(c);
}
-void KNScorableArticle::displayMessage(const QString& s)
+void KNScorableArticle::displayMessage(const TQString& s)
{
if (!_a->isNew()) return;
if (!notifyC) notifyC = new NotifyCollection();
notifyC->addNote(*this,s);
}
-QString KNScorableArticle::from() const
+TQString KNScorableArticle::from() const
{
return _a->from()->asUnicodeString();
}
-QString KNScorableArticle::subject() const
+TQString KNScorableArticle::subject() const
{
return _a->subject()->asUnicodeString();
}
-QString KNScorableArticle::getHeaderByType(const QString& s) const
+TQString KNScorableArticle::getHeaderByType(const TQString& s) const
{
KMime::Headers::Base *h = _a->getHeaderByType(s.latin1());
if (!h) return "";
- QString t = _a->getHeaderByType(s.latin1())->asUnicodeString();
+ TQString t = _a->getHeaderByType(s.latin1())->asUnicodeString();
Q_ASSERT( !t.isEmpty() );
return t;
}
@@ -105,13 +105,13 @@ KNScoringManager::~KNScoringManager()
}
-QStringList KNScoringManager::getGroups() const
+TQStringList KNScoringManager::getGroups() const
{
KNAccountManager *am = knGlobals.accountManager();
- QStringList res;
- QValueList<KNNntpAccount*>::Iterator it;
+ TQStringList res;
+ TQValueList<KNNntpAccount*>::Iterator it;
for ( it = am->begin(); it != am->end(); ++it ) {
- QStringList groups;
+ TQStringList groups;
knGlobals.groupManager()->getSubscribed( (*it), groups);
res += groups;
}
@@ -120,9 +120,9 @@ QStringList KNScoringManager::getGroups() const
}
-QStringList KNScoringManager::getDefaultHeaders() const
+TQStringList KNScoringManager::getDefaultHeaders() const
{
- QStringList l = KScoringManager::getDefaultHeaders();
+ TQStringList l = KScoringManager::getDefaultHeaders();
l << "Lines";
l << "References";
return l;
diff --git a/knode/knscoring.h b/knode/knscoring.h
index 77b011e22..68b23c585 100644
--- a/knode/knscoring.h
+++ b/knode/knscoring.h
@@ -29,11 +29,11 @@ public:
virtual ~KNScorableArticle();
virtual void addScore(short s);
- virtual void changeColor(const QColor&);
- virtual void displayMessage(const QString&);
- virtual QString from() const;
- virtual QString subject() const;
- virtual QString getHeaderByType(const QString&) const;
+ virtual void changeColor(const TQColor&);
+ virtual void displayMessage(const TQString&);
+ virtual TQString from() const;
+ virtual TQString subject() const;
+ virtual TQString getHeaderByType(const TQString&) const;
virtual void markAsRead();
static NotifyCollection* notifyC;
@@ -65,8 +65,8 @@ class KNScoringManager : public KScoringManager
public:
KNScoringManager();
virtual ~KNScoringManager();
- virtual QStringList getGroups() const;
- virtual QStringList getDefaultHeaders() const;
+ virtual TQStringList getGroups() const;
+ virtual TQStringList getDefaultHeaders() const;
void configure();
bool canColors()const { return true; }
diff --git a/knode/knsearchdialog.cpp b/knode/knsearchdialog.cpp
index 113bfe733..f72afe472 100644
--- a/knode/knsearchdialog.cpp
+++ b/knode/knsearchdialog.cpp
@@ -14,8 +14,8 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qcheckbox.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <kapplication.h>
@@ -29,25 +29,25 @@
#include "knsearchdialog.h"
-KNSearchDialog::KNSearchDialog(searchType /*t*/, QWidget *parent)
- : QDialog(parent)
+KNSearchDialog::KNSearchDialog(searchType /*t*/, TQWidget *parent)
+ : TQDialog(parent)
{
setCaption(kapp->makeStdCaption( i18n("Search for Articles") ));
setIcon(SmallIcon("knode"));
- QGroupBox *bg=new QGroupBox(this);
+ TQGroupBox *bg=new TQGroupBox(this);
- startBtn=new QPushButton(SmallIcon("mail_find"),i18n("Sea&rch"), bg);
+ startBtn=new TQPushButton(SmallIcon("mail_find"),i18n("Sea&rch"), bg);
startBtn->setDefault(true);
- newBtn=new QPushButton(SmallIcon("editclear"),i18n("C&lear"), bg);
+ newBtn=new TQPushButton(SmallIcon("editclear"),i18n("C&lear"), bg);
closeBtn=new KPushButton(KStdGuiItem::close(), bg);
- completeThreads=new QCheckBox(i18n("Sho&w complete threads"),this);
+ completeThreads=new TQCheckBox(i18n("Sho&w complete threads"),this);
fcw=new KNFilterConfigWidget(this);
fcw->reset();
- QHBoxLayout *topL=new QHBoxLayout(this, 5);
- QVBoxLayout *filterL=new QVBoxLayout(this, 0, 5);
- QVBoxLayout *btnL=new QVBoxLayout(bg, 8, 5);
+ TQHBoxLayout *topL=new TQHBoxLayout(this, 5);
+ TQVBoxLayout *filterL=new TQVBoxLayout(this, 0, 5);
+ TQVBoxLayout *btnL=new TQVBoxLayout(bg, 8, 5);
filterL->addWidget(completeThreads);
filterL->addWidget(fcw,1);
@@ -60,9 +60,9 @@ KNSearchDialog::KNSearchDialog(searchType /*t*/, QWidget *parent)
topL->addLayout(filterL, 1);
topL->addWidget(bg);
- connect(startBtn, SIGNAL(clicked()), this, SLOT(slotStartClicked()));
- connect(newBtn, SIGNAL(clicked()), this, SLOT(slotNewClicked()));
- connect(closeBtn, SIGNAL(clicked()), this, SLOT(slotCloseClicked()));
+ connect(startBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotStartClicked()));
+ connect(newBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotNewClicked()));
+ connect(closeBtn, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotCloseClicked()));
f_ilter=new KNArticleFilter();
f_ilter->setLoaded(true);
@@ -111,7 +111,7 @@ void KNSearchDialog::slotCloseClicked()
}
-void KNSearchDialog::closeEvent( QCloseEvent * )
+void KNSearchDialog::closeEvent( TQCloseEvent * )
{
emit dialogDone();
}
diff --git a/knode/knsearchdialog.h b/knode/knsearchdialog.h
index 7c68a49fd..8923bd813 100644
--- a/knode/knsearchdialog.h
+++ b/knode/knsearchdialog.h
@@ -17,7 +17,7 @@
#ifndef KNSEARCHDIALOG_H
#define KNSEARCHDIALOG_H
-#include <qdialog.h>
+#include <tqdialog.h>
class QPushButton;
@@ -25,23 +25,23 @@ class KNFilterConfigWidget;
class KNArticleFilter;
-class KNSearchDialog : public QDialog {
+class KNSearchDialog : public TQDialog {
Q_OBJECT
public:
enum searchType { STfolderSearch, STgroupSearch };
- KNSearchDialog(searchType t=STgroupSearch, QWidget *parent=0);
+ KNSearchDialog(searchType t=STgroupSearch, TQWidget *parent=0);
~KNSearchDialog();
KNArticleFilter* filter() const { return f_ilter; }
protected:
- void closeEvent( QCloseEvent* e );
+ void closeEvent( TQCloseEvent* e );
KNFilterConfigWidget *fcw;
- QPushButton *startBtn, *newBtn, *closeBtn;
- QCheckBox *completeThreads;
+ TQPushButton *startBtn, *newBtn, *closeBtn;
+ TQCheckBox *completeThreads;
KNArticleFilter *f_ilter;
protected slots:
diff --git a/knode/knserverinfo.cpp b/knode/knserverinfo.cpp
index b79735a2f..d314a7710 100644
--- a/knode/knserverinfo.cpp
+++ b/knode/knserverinfo.cpp
@@ -25,7 +25,7 @@ using namespace KWallet;
#include "knaccountmanager.h"
#include "utilities.h"
-#include <qwidget.h>
+#include <tqwidget.h>
KNServerInfo::KNServerInfo() :
t_ype(STnntp), i_d(-1), p_ort(119), h_old(300),
@@ -77,7 +77,7 @@ void KNServerInfo::readConf(KConfig *conf)
if (Wallet::isOpen( Wallet::NetworkWallet() ))
readPassword();
- QString encStr = conf->readEntry( "encryption", "None" );
+ TQString encStr = conf->readEntry( "encryption", "None" );
if ( encStr.contains( "SSL", false ) )
mEncryption = SSL;
else if ( encStr.contains( "TLS", false ) )
@@ -102,7 +102,7 @@ void KNServerInfo::saveConf(KConfig *conf)
// open wallet for storing only if the user actually changed the password
if (n_eedsLogon && p_assDirty) {
Wallet *wallet = KNAccountManager::wallet();
- if (!wallet || wallet->writePassword(QString::number(i_d), p_ass)) {
+ if (!wallet || wallet->writePassword(TQString::number(i_d), p_ass)) {
if ( KMessageBox::warningYesNo( 0,
i18n("KWallet is not available. It is strongly recommended to use "
"KWallet for managing your passwords.\n"
@@ -151,7 +151,7 @@ bool KNServerInfo::operator==(const KNServerInfo &s)
}
-const QString &KNServerInfo::pass()
+const TQString &KNServerInfo::pass()
{
// if we need to load the password, load all of them
if (n_eedsLogon && !mPassLoaded && p_ass.isEmpty() )
@@ -160,7 +160,7 @@ const QString &KNServerInfo::pass()
return p_ass;
}
-void KNServerInfo::setPass(const QString &s)
+void KNServerInfo::setPass(const TQString &s)
{
if (p_ass != s) {
p_ass = s;
@@ -178,11 +178,11 @@ void KNServerInfo::readPassword()
// check wether there is a chance to find our password at all
if (Wallet::folderDoesNotExist(Wallet::NetworkWallet(), "knode") ||
- Wallet::keyDoesNotExist(Wallet::NetworkWallet(), "knode", QString::number(i_d)))
+ Wallet::keyDoesNotExist(Wallet::NetworkWallet(), "knode", TQString::number(i_d)))
return;
// finally try to open the wallet and read the password
KWallet::Wallet *wallet = KNAccountManager::wallet();
if ( wallet )
- wallet->readPassword( QString::number(i_d), p_ass );
+ wallet->readPassword( TQString::number(i_d), p_ass );
}
diff --git a/knode/knserverinfo.h b/knode/knserverinfo.h
index 6f564d934..68c39699a 100644
--- a/knode/knserverinfo.h
+++ b/knode/knserverinfo.h
@@ -15,7 +15,7 @@
#ifndef KNSERVERINFO_H
#define KNSERVERINFO_H
-#include <qstring.h>
+#include <tqstring.h>
class KConfig;
namespace KWallet {
@@ -38,9 +38,9 @@ class KNServerInfo {
//get
serverType type()const { return t_ype; }
int id()const { return i_d; }
- const QString& server() { return s_erver; }
- const QString& user() { return u_ser; }
- const QString& pass();
+ const TQString& server() { return s_erver; }
+ const TQString& user() { return u_ser; }
+ const TQString& pass();
int port() const { return p_ort; }
int hold() const { return h_old; }
int timeout() const { return t_imeout; }
@@ -52,9 +52,9 @@ class KNServerInfo {
//set
void setType(serverType t) { t_ype=t; }
void setId(int i) { i_d=i; }
- void setServer(const QString &s) { s_erver=s; }
- void setUser(const QString &s) { u_ser=s; }
- void setPass(const QString &s);
+ void setServer(const TQString &s) { s_erver=s; }
+ void setUser(const TQString &s) { u_ser=s; }
+ void setPass(const TQString &s);
void setPort(int p) { p_ort=p; }
void setHold(int h) { h_old=h; }
void setTimeout(int t) { t_imeout=t; }
@@ -69,7 +69,7 @@ class KNServerInfo {
protected:
serverType t_ype;
- QString s_erver,
+ TQString s_erver,
u_ser,
p_ass;
diff --git a/knode/knsourceviewwindow.cpp b/knode/knsourceviewwindow.cpp
index ad0eb1cf5..f0b2b75d8 100644
--- a/knode/knsourceviewwindow.cpp
+++ b/knode/knsourceviewwindow.cpp
@@ -12,7 +12,7 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qaccel.h>
+#include <tqaccel.h>
#include <kapplication.h>
@@ -22,33 +22,33 @@
#include "utilities.h"
-KNSourceViewWindow::KNSourceViewWindow( const QString &text )
+KNSourceViewWindow::KNSourceViewWindow( const TQString &text )
: KTextBrowser(0)
{
setWFlags(WType_TopLevel | WDestructiveClose);
- QAccel *accel = new QAccel( this, "browser close-accel" );
- accel->connectItem( accel->insertItem( Qt::Key_Escape ), this , SLOT( close() ));
+ TQAccel *accel = new TQAccel( this, "browser close-accel" );
+ accel->connectItem( accel->insertItem( Qt::Key_Escape ), this , TQT_SLOT( close() ));
KNConfig::Appearance *app=knGlobals.configManager()->appearance();
setTextFormat( PlainText );
setCaption(kapp->makeStdCaption(i18n("Article Source")));
- setPaper( QBrush(app->backgroundColor()) );
+ setPaper( TQBrush(app->backgroundColor()) );
setFont( app->articleFixedFont() );
setColor( app->textColor() );
setWordWrap( KTextBrowser::NoWrap );
setText( text );
- KNHelper::restoreWindowSize("sourceWindow", this, QSize(500,300));
+ KNHelper::restoreWindowSize("sourceWindow", this, TQSize(500,300));
show();
}
-void KNSourceViewWindow::setPalette( const QPalette &pal )
+void KNSourceViewWindow::setPalette( const TQPalette &pal )
{
- QPalette p = pal;
- p.setColor( QColorGroup::Text, knGlobals.configManager()->appearance()->textColor() );
- p.setColor( QColorGroup::Background, knGlobals.configManager()->appearance()->backgroundColor() );
+ TQPalette p = pal;
+ p.setColor( TQColorGroup::Text, knGlobals.configManager()->appearance()->textColor() );
+ p.setColor( TQColorGroup::Background, knGlobals.configManager()->appearance()->backgroundColor() );
KTextBrowser::setPalette( p );
}
diff --git a/knode/knsourceviewwindow.h b/knode/knsourceviewwindow.h
index c3a7fc8ca..aabe14b50 100644
--- a/knode/knsourceviewwindow.h
+++ b/knode/knsourceviewwindow.h
@@ -23,9 +23,9 @@ class KNSourceViewWindow : public KTextBrowser {
Q_OBJECT
public:
- KNSourceViewWindow( const QString &text );
+ KNSourceViewWindow( const TQString &text );
~KNSourceViewWindow();
- virtual void setPalette( const QPalette &pal );
+ virtual void setPalette( const TQPalette &pal );
};
diff --git a/knode/knstatusfilter.cpp b/knode/knstatusfilter.cpp
index 6389794d7..a1379a265 100644
--- a/knode/knstatusfilter.cpp
+++ b/knode/knstatusfilter.cpp
@@ -14,8 +14,8 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qcheckbox.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <ksimpleconfig.h>
@@ -94,21 +94,21 @@ bool KNStatusFilter::doFilter(KNRemoteArticle *a)
//==============================================================================
-KNStatusFilterWidget::KNStatusFilterWidget(QWidget *parent) :
- QButtonGroup(0, parent)
+KNStatusFilterWidget::KNStatusFilterWidget(TQWidget *parent) :
+ TQButtonGroup(0, parent)
{
setFrameStyle(NoFrame);
- enR=new QCheckBox(i18n("Is read:"), this);
- enN=new QCheckBox(i18n("Is new:"), this);
- enUS=new QCheckBox(i18n("Has unread followups:"), this);
- enNS=new QCheckBox(i18n("Has new followups:"), this);
+ enR=new TQCheckBox(i18n("Is read:"), this);
+ enN=new TQCheckBox(i18n("Is new:"), this);
+ enUS=new TQCheckBox(i18n("Has unread followups:"), this);
+ enNS=new TQCheckBox(i18n("Has new followups:"), this);
rCom=new TFCombo(this);
nCom=new TFCombo(this);
usCom=new TFCombo(this);
nsCom=new TFCombo(this);
- QGridLayout *topL=new QGridLayout(this, 5, 3, 15,5);
+ TQGridLayout *topL=new TQGridLayout(this, 5, 3, 15,5);
topL->addWidget(enR,0,0); topL->addWidget(rCom,0,1);
topL->addWidget(enN,1,0); topL->addWidget(nCom,1,1);
topL->addWidget(enUS,2,0); topL->addWidget(usCom,2,1);
@@ -116,7 +116,7 @@ KNStatusFilterWidget::KNStatusFilterWidget(QWidget *parent) :
topL->setColStretch(2,1);
topL->setRowStretch(4,1);
- connect(this, SIGNAL(clicked(int)), this, SLOT(slotEnabled(int)));
+ connect(this, TQT_SIGNAL(clicked(int)), this, TQT_SLOT(slotEnabled(int)));
}
@@ -197,7 +197,7 @@ void KNStatusFilterWidget::slotEnabled(int c)
//==============================================================================
-KNStatusFilterWidget::TFCombo::TFCombo(QWidget *parent) : QComboBox(parent)
+KNStatusFilterWidget::TFCombo::TFCombo(TQWidget *parent) : TQComboBox(parent)
{
insertItem(i18n("True"));
insertItem(i18n("False"));
diff --git a/knode/knstatusfilter.h b/knode/knstatusfilter.h
index 43030de4e..6497b3021 100644
--- a/knode/knstatusfilter.h
+++ b/knode/knstatusfilter.h
@@ -17,9 +17,9 @@
#ifndef KNSTATUSFILTER_H
#define KNSTATUSFILTER_H
-#include <qbuttongroup.h>
-#include <qcombobox.h>
-#include <qbitarray.h>
+#include <tqbuttongroup.h>
+#include <tqcombobox.h>
+#include <tqbitarray.h>
class QCheckBox;
class KSimpleConfig;
@@ -43,7 +43,7 @@ class KNStatusFilter {
bool doFilter(KNRemoteArticle *a);
protected:
- QBitArray data;
+ TQBitArray data;
};
@@ -51,12 +51,12 @@ class KNStatusFilter {
//=================================================================================
-class KNStatusFilterWidget : public QButtonGroup {
+class KNStatusFilterWidget : public TQButtonGroup {
Q_OBJECT
public:
- KNStatusFilterWidget(QWidget *parent);
+ KNStatusFilterWidget(TQWidget *parent);
~KNStatusFilterWidget();
KNStatusFilter filter();
@@ -66,17 +66,17 @@ class KNStatusFilterWidget : public QButtonGroup {
protected:
- class TFCombo : public QComboBox {
+ class TFCombo : public TQComboBox {
public:
- TFCombo(QWidget *parent);
+ TFCombo(TQWidget *parent);
~TFCombo();
void setValue(bool b) { if(b) setCurrentItem(0); else setCurrentItem(1); }
bool value() const { return (currentItem()==0); }
};
- QCheckBox *enR, *enN, *enUS, *enNS;
+ TQCheckBox *enR, *enN, *enUS, *enNS;
TFCombo *rCom, *nCom, *usCom, *nsCom;
protected slots:
diff --git a/knode/knstringfilter.cpp b/knode/knstringfilter.cpp
index c41b723fe..4f69f7eaf 100644
--- a/knode/knstringfilter.cpp
+++ b/knode/knstringfilter.cpp
@@ -12,9 +12,9 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qcombobox.h>
-#include <qlayout.h>
-#include <qcheckbox.h>
+#include <tqcombobox.h>
+#include <tqlayout.h>
+#include <tqcheckbox.h>
#include <klocale.h>
#include <ksimpleconfig.h>
@@ -38,13 +38,13 @@ KNStringFilter& KNStringFilter::operator=(const KNStringFilter &sf)
-bool KNStringFilter::doFilter(const QString &s)
+bool KNStringFilter::doFilter(const TQString &s)
{
bool ret=true;
if(!expanded.isEmpty()) {
if(regExp) {
- QRegExp matcher(expanded);
+ TQRegExp matcher(expanded);
ret = ( matcher.search(s) >= 0 );
} else
ret=(s.find(expanded,0,false)!=-1);
@@ -69,8 +69,8 @@ void KNStringFilter::expand(KNGroup *g)
}
expanded = data;
- expanded.replace(QRegExp("%MYNAME"), id->name());
- expanded.replace(QRegExp("%MYEMAIL"), id->email());
+ expanded.replace(TQRegExp("%MYNAME"), id->name());
+ expanded.replace(TQRegExp("%MYEMAIL"), id->email());
}
@@ -94,18 +94,18 @@ void KNStringFilter::save(KSimpleConfig *conf)
//===============================================================================
-KNStringFilterWidget::KNStringFilterWidget(const QString& title, QWidget *parent)
- : QGroupBox(title, parent)
+KNStringFilterWidget::KNStringFilterWidget(const TQString& title, TQWidget *parent)
+ : TQGroupBox(title, parent)
{
- fType=new QComboBox(this);
+ fType=new TQComboBox(this);
fType->insertItem(i18n("Does Contain"));
fType->insertItem(i18n("Does NOT Contain"));
fString=new KLineEdit(this);
- regExp=new QCheckBox(i18n("Regular expression"), this);
+ regExp=new TQCheckBox(i18n("Regular expression"), this);
- QGridLayout *topL=new QGridLayout(this, 3,3, 8,5 );
+ TQGridLayout *topL=new TQGridLayout(this, 3,3, 8,5 );
topL->addRowSpacing(0, fontMetrics().lineSpacing()-4);
topL->addWidget(fType, 1,0);
topL->addColSpacing(1, 10);
diff --git a/knode/knstringfilter.h b/knode/knstringfilter.h
index 17199cbe7..e70e7e307 100644
--- a/knode/knstringfilter.h
+++ b/knode/knstringfilter.h
@@ -17,7 +17,7 @@
#ifndef KNSTRINGFILTER_H
#define KNSTRINGFILTER_H
-#include <qgroupbox.h>
+#include <tqgroupbox.h>
class QCheckBox;
class QComboBox;
@@ -43,10 +43,10 @@ class KNStringFilter {
void load(KSimpleConfig *conf);
void save(KSimpleConfig *conf);
- bool doFilter(const QString &s);
+ bool doFilter(const TQString &s);
protected:
- QString data, expanded;
+ TQString data, expanded;
bool con, regExp;
};
@@ -55,12 +55,12 @@ class KNStringFilter {
//===============================================================================
-class KNStringFilterWidget : public QGroupBox {
+class KNStringFilterWidget : public TQGroupBox {
Q_OBJECT
public:
- KNStringFilterWidget(const QString& title, QWidget *parent);
+ KNStringFilterWidget(const TQString& title, TQWidget *parent);
~KNStringFilterWidget();
KNStringFilter filter();
@@ -71,8 +71,8 @@ class KNStringFilterWidget : public QGroupBox {
void setStartFocus();
protected:
- QCheckBox *regExp;
- QComboBox *fType;
+ TQCheckBox *regExp;
+ TQComboBox *fType;
KLineEdit *fString;
};
diff --git a/knode/knwidgets.cpp b/knode/knwidgets.cpp
index d71624eb6..d75cf9bf7 100644
--- a/knode/knwidgets.cpp
+++ b/knode/knwidgets.cpp
@@ -14,15 +14,15 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qpainter.h>
-#include <qpixmap.h>
+#include <tqpainter.h>
+#include <tqpixmap.h>
#include "knwidgets.h"
//====================================================================================
-KNListBoxItem::KNListBoxItem(const QString& text, QPixmap *pm)
+KNListBoxItem::KNListBoxItem(const TQString& text, TQPixmap *pm)
{
p_m=pm;
setText(text);
@@ -34,10 +34,10 @@ KNListBoxItem::~KNListBoxItem()
}
-void KNListBoxItem::paint(QPainter *p)
+void KNListBoxItem::paint(TQPainter *p)
{
- QFontMetrics fm = p->fontMetrics();
+ TQFontMetrics fm = p->fontMetrics();
int tYPos=0, tXPos=3, pYPos=0;
@@ -62,7 +62,7 @@ void KNListBoxItem::paint(QPainter *p)
}
-int KNListBoxItem::height(const QListBox *lb) const
+int KNListBoxItem::height(const TQListBox *lb) const
{
if(p_m)
return QMAX( p_m->height(), lb->fontMetrics().lineSpacing() + 1 );
@@ -71,7 +71,7 @@ int KNListBoxItem::height(const QListBox *lb) const
}
-int KNListBoxItem::width(const QListBox *lb) const
+int KNListBoxItem::width(const TQListBox *lb) const
{
if(p_m)
return (p_m->width() + lb->fontMetrics().width( text() ) + 6);
@@ -84,8 +84,8 @@ int KNListBoxItem::width(const QListBox *lb) const
// **** listbox for dialogs **************************************************
-KNDialogListBox::KNDialogListBox(bool alwaysIgnore, QWidget * parent, const char * name)
- : QListBox(parent, name), a_lwaysIgnore(alwaysIgnore)
+KNDialogListBox::KNDialogListBox(bool alwaysIgnore, TQWidget * parent, const char * name)
+ : TQListBox(parent, name), a_lwaysIgnore(alwaysIgnore)
{
}
@@ -95,22 +95,22 @@ KNDialogListBox::~KNDialogListBox()
}
-void KNDialogListBox::keyPressEvent(QKeyEvent *e)
+void KNDialogListBox::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);
}
//====================================================================================
-KNDockWidgetHeaderDrag::KNDockWidgetHeaderDrag(QWidget *focusWidget, KDockWidgetAbstractHeader* parent, KDockWidget* dock, const char* name )
+KNDockWidgetHeaderDrag::KNDockWidgetHeaderDrag(TQWidget *focusWidget, KDockWidgetAbstractHeader* parent, KDockWidget* dock, const char* name )
: KDockWidgetHeaderDrag(parent, dock, name), f_ocus(false)
{
- connect(focusWidget, SIGNAL(focusChanged(QFocusEvent*)), SLOT(slotFocusChanged(QFocusEvent*)));
+ connect(focusWidget, TQT_SIGNAL(focusChanged(TQFocusEvent*)), TQT_SLOT(slotFocusChanged(TQFocusEvent*)));
}
@@ -119,7 +119,7 @@ KNDockWidgetHeaderDrag::~KNDockWidgetHeaderDrag()
}
-void KNDockWidgetHeaderDrag::slotFocusChanged(QFocusEvent *e)
+void KNDockWidgetHeaderDrag::slotFocusChanged(TQFocusEvent *e)
{
if(e->gotFocus()) {
f_ocus = true;
@@ -130,18 +130,18 @@ void KNDockWidgetHeaderDrag::slotFocusChanged(QFocusEvent *e)
}
-void KNDockWidgetHeaderDrag::paintEvent(QPaintEvent* ev)
+void KNDockWidgetHeaderDrag::paintEvent(TQPaintEvent* ev)
{
if (!f_ocus) {
KDockWidgetHeaderDrag::paintEvent(ev);
return;
}
- QPixmap drawBuffer(width(), height());
- QPainter paint;
+ TQPixmap drawBuffer(width(), height());
+ TQPainter paint;
paint.begin(&drawBuffer);
- paint.fillRect(drawBuffer.rect(), QBrush(colorGroup().brush(QColorGroup::Background)));
+ paint.fillRect(drawBuffer.rect(), TQBrush(colorGroup().brush(TQColorGroup::Background)));
paint.setPen(palette().active().highlight());
paint.drawLine(1, 2, width(), 2);
diff --git a/knode/knwidgets.h b/knode/knwidgets.h
index af71bd5f0..7e8dd7d3b 100644
--- a/knode/knwidgets.h
+++ b/knode/knwidgets.h
@@ -17,8 +17,8 @@
#ifndef KNWIDGETS_H
#define KNWIDGETS_H
-#include <qlistbox.h>
-#include <qbitarray.h>
+#include <tqlistbox.h>
+#include <tqbitarray.h>
#include <kdockwidget.h>
#include <kprogress.h>
@@ -29,19 +29,19 @@ class QPixmap;
//====================================================================================
-class KNListBoxItem : public QListBoxItem {
+class KNListBoxItem : public TQListBoxItem {
public:
- KNListBoxItem(const QString& text, QPixmap *pm=0);
+ KNListBoxItem(const TQString& text, TQPixmap *pm=0);
~KNListBoxItem();
protected:
- virtual void paint(QPainter *);
- virtual int height(const QListBox *) const;
- virtual int width(const QListBox *) const;
+ virtual void paint(TQPainter *);
+ virtual int height(const TQListBox *) const;
+ virtual int width(const TQListBox *) const;
- QPixmap *p_m;
+ TQPixmap *p_m;
};
@@ -53,11 +53,11 @@ class KNDialogListBox : public QListBox
{
public:
// alwaysIgnore==false: enter is ignored when the widget isn't visible/out of focus
- KNDialogListBox(bool alwaysIgnore=false, QWidget * parent=0, const char * name=0);
+ KNDialogListBox(bool alwaysIgnore=false, TQWidget * parent=0, const char * name=0);
~KNDialogListBox();
protected:
- void keyPressEvent( QKeyEvent *e );
+ void keyPressEvent( TQKeyEvent *e );
bool a_lwaysIgnore;
};
@@ -71,15 +71,15 @@ class KNDockWidgetHeaderDrag : public KDockWidgetHeaderDrag
Q_OBJECT
public:
- KNDockWidgetHeaderDrag(QWidget *focusWidget, KDockWidgetAbstractHeader* parent, KDockWidget* dock,
+ KNDockWidgetHeaderDrag(TQWidget *focusWidget, KDockWidgetAbstractHeader* parent, KDockWidget* dock,
const char* name = 0);
virtual ~KNDockWidgetHeaderDrag();
protected slots:
- void slotFocusChanged(QFocusEvent *e);
+ void slotFocusChanged(TQFocusEvent *e);
protected:
- virtual void paintEvent( QPaintEvent* );
+ virtual void paintEvent( TQPaintEvent* );
bool f_ocus;
};
diff --git a/knode/utilities.cpp b/knode/utilities.cpp
index 5f9c2e98c..67d4e3bac 100644
--- a/knode/utilities.cpp
+++ b/knode/utilities.cpp
@@ -12,10 +12,10 @@
Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, US
*/
-#include <qlayout.h>
-#include <qregexp.h>
-#include <qapplication.h>
-#include <qcursor.h>
+#include <tqlayout.h>
+#include <tqregexp.h>
+#include <tqapplication.h>
+#include <tqcursor.h>
#include <klocale.h>
#include <kmessagebox.h>
@@ -33,8 +33,8 @@
//================================================================================
-KNFile::KNFile(const QString& fname)
- : QFile(fname), filePos(0), readBytes(0)
+KNFile::KNFile(const TQString& fname)
+ : TQFile(fname), filePos(0), readBytes(0)
{
buffer.resize(512);
dataPtr=buffer.data();
@@ -47,15 +47,15 @@ KNFile::~KNFile()
}
-const QCString& KNFile::readLine()
+const TQCString& KNFile::readLine()
{
filePos=at();
- readBytes=QFile::readLine(dataPtr, buffer.size()-1);
+ readBytes=TQFile::readLine(dataPtr, buffer.size()-1);
if(readBytes!=-1) {
while ((dataPtr[readBytes-1]!='\n')&&(static_cast<uint>(readBytes+2)==buffer.size())) { // don't get tricked by files without newline
at(filePos);
if (!increaseBuffer() ||
- (readBytes=QFile::readLine(dataPtr, buffer.size()-1))==-1) {
+ (readBytes=TQFile::readLine(dataPtr, buffer.size()-1))==-1) {
readBytes=1;
break;
}
@@ -68,15 +68,15 @@ const QCString& KNFile::readLine()
}
-const QCString& KNFile::readLineWnewLine()
+const TQCString& KNFile::readLineWnewLine()
{
filePos=at();
- readBytes=QFile::readLine(dataPtr, buffer.size()-1);
+ readBytes=TQFile::readLine(dataPtr, buffer.size()-1);
if(readBytes!=-1) {
while ((dataPtr[readBytes-1]!='\n')&&(static_cast<uint>(readBytes+2)==buffer.size())) { // don't get tricked by files without newline
at(filePos);
if (!increaseBuffer() ||
- (readBytes=QFile::readLine(dataPtr, buffer.size()-1))==-1) {
+ (readBytes=TQFile::readLine(dataPtr, buffer.size()-1))==-1) {
dataPtr[0] = '\0';
break;
}
@@ -90,7 +90,7 @@ const QCString& KNFile::readLineWnewLine()
int KNFile::findString(const char *s)
{
- QCString searchBuffer;
+ TQCString searchBuffer;
searchBuffer.resize(2048);
char *buffPtr = searchBuffer.data(), *pos;
int readBytes, currentFilePos;
@@ -132,9 +132,9 @@ bool KNFile::increaseBuffer()
//===============================================================================
-QString KNSaveHelper::lastPath;
+TQString KNSaveHelper::lastPath;
-KNSaveHelper::KNSaveHelper(QString saveName, QWidget *parent)
+KNSaveHelper::KNSaveHelper(TQString saveName, TQWidget *parent)
: p_arent(parent), s_aveName(saveName), file(0), tmpFile(0)
{
}
@@ -155,9 +155,9 @@ KNSaveHelper::~KNSaveHelper()
}
-QFile* KNSaveHelper::getFile(const QString &dialogTitle)
+TQFile* KNSaveHelper::getFile(const TQString &dialogTitle)
{
- url = KFileDialog::getSaveURL(lastPath + s_aveName, QString::null, p_arent, dialogTitle);
+ url = KFileDialog::getSaveURL(lastPath + s_aveName, TQString::null, p_arent, dialogTitle);
if (url.isEmpty())
return 0;
@@ -165,14 +165,14 @@ QFile* KNSaveHelper::getFile(const QString &dialogTitle)
lastPath = url.upURL().url();
if (url.isLocalFile()) {
- if (QFileInfo(url.path()).exists() &&
+ if (TQFileInfo(url.path()).exists() &&
(KMessageBox::warningContinueCancel(knGlobals.topWidget,
i18n("<qt>A file named <b>%1</b> already exists.<br>Do you want to replace it?</qt>").arg(url.path()),
dialogTitle, i18n("&Replace")) != KMessageBox::Continue)) {
return 0;
}
- file = new QFile(url.path());
+ file = new TQFile(url.path());
if(!file->open(IO_WriteOnly)) {
KNHelper::displayExternalFileError();
delete file;
@@ -194,9 +194,9 @@ QFile* KNSaveHelper::getFile(const QString &dialogTitle)
//===============================================================================
-QString KNLoadHelper::l_astPath;
+TQString KNLoadHelper::l_astPath;
-KNLoadHelper::KNLoadHelper(QWidget *parent)
+KNLoadHelper::KNLoadHelper(TQWidget *parent)
: p_arent(parent), f_ile(0)
{
}
@@ -210,12 +210,12 @@ KNLoadHelper::~KNLoadHelper()
}
-KNFile* KNLoadHelper::getFile( const QString &dialogTitle )
+KNFile* KNLoadHelper::getFile( const TQString &dialogTitle )
{
if (f_ile)
return f_ile;
- KURL url = KFileDialog::getOpenURL(l_astPath,QString::null,p_arent,dialogTitle);
+ KURL url = KFileDialog::getOpenURL(l_astPath,TQString::null,p_arent,dialogTitle);
if (url.isEmpty())
return 0;
@@ -237,7 +237,7 @@ KNFile* KNLoadHelper::setURL(KURL url)
if (u_rl.isEmpty())
return 0;
- QString fileName;
+ TQString fileName;
if (!u_rl.isLocalFile()) {
if (KIO::NetAccess::download(u_rl, t_empName, 0))
fileName = t_empName;
@@ -261,26 +261,26 @@ KNFile* KNLoadHelper::setURL(KURL url)
// **** keyboard selection dialog *********************************************
-int KNHelper::selectDialog(QWidget *parent, const QString &caption, const QStringList &options, int initialValue)
+int KNHelper::selectDialog(TQWidget *parent, const TQString &caption, const TQStringList &options, int initialValue)
{
KDialogBase *dlg=new KDialogBase(KDialogBase::Plain, caption, KDialogBase::Ok|KDialogBase::Cancel,
KDialogBase::Ok, parent);
- QFrame *page = dlg->plainPage();
- QHBoxLayout *pageL = new QHBoxLayout(page,8,5);
+ TQFrame *page = dlg->plainPage();
+ TQHBoxLayout *pageL = new TQHBoxLayout(page,8,5);
KNDialogListBox *list = new KNDialogListBox(true, page);
pageL->addWidget(list);
- QString s;
- for ( QStringList::ConstIterator it = options.begin(); it != options.end(); ++it ) {
+ TQString s;
+ for ( TQStringList::ConstIterator it = options.begin(); it != options.end(); ++it ) {
s = (*it);
- s.replace(QRegExp("&"),""); // remove accelerators
+ s.replace(TQRegExp("&"),""); // remove accelerators
list->insertItem(s);
}
list->setCurrentItem(initialValue);
list->setFocus();
- restoreWindowSize("selectBox", dlg, QSize(247,174));
+ restoreWindowSize("selectBox", dlg, TQSize(247,174));
int ret;
if (dlg->exec())
@@ -295,7 +295,7 @@ int KNHelper::selectDialog(QWidget *parent, const QString &caption, const QStrin
// **** window geometry managing *********************************************
-void KNHelper::saveWindowSize(const QString &name, const QSize &s)
+void KNHelper::saveWindowSize(const TQString &name, const TQSize &s)
{
KConfig *c=knGlobals.config();
c->setGroup("WINDOW_SIZES");
@@ -303,15 +303,15 @@ void KNHelper::saveWindowSize(const QString &name, const QSize &s)
}
-void KNHelper::restoreWindowSize(const QString &name, QWidget *d, const QSize &defaultSize)
+void KNHelper::restoreWindowSize(const TQString &name, TQWidget *d, const TQSize &defaultSize)
{
KConfig *c=knGlobals.config();
c->setGroup("WINDOW_SIZES");
- QSize s=c->readSizeEntry(name,&defaultSize);
+ TQSize s=c->readSizeEntry(name,&defaultSize);
if(s.isValid()) {
- QRect max = KGlobalSettings::desktopGeometry(QCursor::pos());
+ TQRect max = KGlobalSettings::desktopGeometry(TQCursor::pos());
if ( s.width() > max.width() ) s.setWidth( max.width()-5 );
if ( s.height() > max.height() ) s.setHeight( max.height()-5 );
d->resize(s);
@@ -320,10 +320,10 @@ void KNHelper::restoreWindowSize(const QString &name, QWidget *d, const QSize &d
// **** scramble password strings **********************************************
-const QString KNHelper::encryptStr(const QString& aStr)
+const TQString KNHelper::encryptStr(const TQString& aStr)
{
uint i,val,len = aStr.length();
- QCString result;
+ TQCString result;
for (i=0; i<len; i++)
{
@@ -336,25 +336,25 @@ const QString KNHelper::encryptStr(const QString& aStr)
}
-const QString KNHelper::decryptStr(const QString& aStr)
+const TQString KNHelper::decryptStr(const TQString& aStr)
{
return encryptStr(aStr);
}
// **** rot13 *******************************************************************
-QString KNHelper::rot13(const QString &s)
+TQString KNHelper::rot13(const TQString &s)
{
- QString r(s);
+ TQString r(s);
for (int i=0; (uint)i<r.length(); i++) {
- if ( r[i] >= QChar('A') && r[i] <= QChar('M') ||
- r[i] >= QChar('a') && r[i] <= QChar('m') )
- r[i] = (char)((int)QChar(r[i]) + 13);
+ if ( r[i] >= TQChar('A') && r[i] <= TQChar('M') ||
+ r[i] >= TQChar('a') && r[i] <= TQChar('m') )
+ r[i] = (char)((int)TQChar(r[i]) + 13);
else
- if ( r[i] >= QChar('N') && r[i] <= QChar('Z') ||
- r[i] >= QChar('n') && r[i] <= QChar('z') )
- r[i] = (char)((int)QChar(r[i]) - 13);
+ if ( r[i] >= TQChar('N') && r[i] <= TQChar('Z') ||
+ r[i] >= TQChar('n') && r[i] <= TQChar('z') )
+ r[i] = (char)((int)TQChar(r[i]) - 13);
}
return r;
@@ -362,7 +362,7 @@ QString KNHelper::rot13(const QString &s)
// **** text rewraping *********************************************************
-int findBreakPos(const QString &text, int start)
+int findBreakPos(const TQString &text, int start)
{
int i;
for(i=start;i>=0;i--)
@@ -377,9 +377,9 @@ int findBreakPos(const QString &text, int start)
}
-void appendTextWPrefix(QString &result, const QString &text, int wrapAt, const QString &prefix)
+void appendTextWPrefix(TQString &result, const TQString &text, int wrapAt, const TQString &prefix)
{
- QString txt=text;
+ TQString txt=text;
int breakPos;
while(!txt.isEmpty()) {
@@ -390,18 +390,18 @@ void appendTextWPrefix(QString &result, const QString &text, int wrapAt, const Q
txt.remove(0,breakPos+1);
} else {
result+=(prefix+txt+"\n");
- txt=QString::null;
+ txt=TQString::null;
}
}
}
-QString KNHelper::rewrapStringList(QStringList text, int wrapAt, QChar quoteChar, bool stopAtSig, bool alwaysSpace)
+TQString KNHelper::rewrapStringList(TQStringList text, int wrapAt, TQChar quoteChar, bool stopAtSig, bool alwaysSpace)
{
- QString quoted, lastPrefix, thisPrefix, leftover, thisLine;
+ TQString quoted, lastPrefix, thisPrefix, leftover, thisLine;
int breakPos;
- for(QStringList::Iterator line=text.begin(); line!=text.end(); ++line) {
+ for(TQStringList::Iterator line=text.begin(); line!=text.end(); ++line) {
if(stopAtSig && (*line)=="-- ")
break;
@@ -412,8 +412,8 @@ QString KNHelper::rewrapStringList(QStringList text, int wrapAt, QChar quoteChar
else
thisLine.prepend(quoteChar+' ');
- thisPrefix=QString::null;
- QChar c;
+ thisPrefix=TQString::null;
+ TQChar c;
for(int idx=0; idx<(int)(thisLine.length()); idx++) {
c=thisLine.at(idx);
if( (c==' ') ||
@@ -431,7 +431,7 @@ QString KNHelper::rewrapStringList(QStringList text, int wrapAt, QChar quoteChar
appendTextWPrefix(quoted, leftover, wrapAt, lastPrefix);
else
thisLine.prepend(leftover+" ");
- leftover=QString::null;
+ leftover=TQString::null;
}
if((int)(thisPrefix.length()+thisLine.length()) > wrapAt) {
@@ -454,25 +454,25 @@ QString KNHelper::rewrapStringList(QStringList text, int wrapAt, QChar quoteChar
// **** misc. message-boxes **********************************************************
-void KNHelper::displayInternalFileError(QWidget *w)
+void KNHelper::displayInternalFileError(TQWidget *w)
{
KMessageBox::error((w!=0)? w : knGlobals.topWidget, i18n("Unable to load/save configuration.\nWrong permissions on home folder?\nYou should close KNode now to avoid data loss."));
}
-void KNHelper::displayExternalFileError(QWidget *w)
+void KNHelper::displayExternalFileError(TQWidget *w)
{
KMessageBox::error((w!=0)? w : knGlobals.topWidget, i18n("Unable to load/save file."));
}
-void KNHelper::displayRemoteFileError(QWidget *w)
+void KNHelper::displayRemoteFileError(TQWidget *w)
{
KMessageBox::error((w!=0)? w : knGlobals.topWidget, i18n("Unable to save remote file."));
}
-void KNHelper::displayTempFileError(QWidget *w)
+void KNHelper::displayTempFileError(TQWidget *w)
{
KMessageBox::error((w!=0)? w : knGlobals.topWidget, i18n("Unable to create temporary file."));
}
diff --git a/knode/utilities.h b/knode/utilities.h
index 31f83d989..9d0180961 100644
--- a/knode/utilities.h
+++ b/knode/utilities.h
@@ -17,11 +17,11 @@
#include <kurl.h>
-#include <qfile.h>
+#include <tqfile.h>
-#include <qglobal.h>
-#include <qptrvector.h>
-#include <qptrlist.h>
+#include <tqglobal.h>
+#include <tqptrvector.h>
+#include <tqptrlist.h>
class QWidget;
class QString;
@@ -36,18 +36,18 @@ class KTempFile;
// utility classes
//*****************************************************************************
-/** clone of QSortedList... */
-template<class type> class Q_EXPORT QSortedVector : public QPtrVector<type>
+/** clone of TQSortedList... */
+template<class type> class Q_EXPORT QSortedVector : public TQPtrVector<type>
{
public:
QSortedVector() {}
- QSortedVector ( uint size ) : QPtrVector<type>(size) {}
- QSortedVector( const QSortedVector<type> &l ) : QPtrVector<type>(l) {}
- ~QSortedVector() { QPtrVector<type>::clear(); }
+ QSortedVector ( uint size ) : TQPtrVector<type>(size) {}
+ QSortedVector( const QSortedVector<type> &l ) : TQPtrVector<type>(l) {}
+ ~QSortedVector() { TQPtrVector<type>::clear(); }
QSortedVector<type> &operator=(const QSortedVector<type> &l)
- { return (QSortedVector<type>&)QPtrList<type>::operator=(l); }
+ { return (QSortedVector<type>&)TQPtrList<type>::operator=(l); }
- virtual int compareItems( QPtrCollection::Item s1, QPtrCollection::Item s2 )
+ virtual int compareItems( TQPtrCollection::Item s1, TQPtrCollection::Item s2 )
{ if ( *((type*)s1) == *((type*)s2) ) return 0; return ( *((type*)s1) < *((type*)s2) ? -1 : 1 ); }
};
@@ -55,13 +55,13 @@ public:
//==============================================================================
-class KNFile : public QFile {
+class KNFile : public TQFile {
public:
- KNFile(const QString& fname=QString::null);
+ KNFile(const TQString& fname=TQString::null);
~KNFile();
- const QCString& readLine();
- const QCString& readLineWnewLine();
+ const TQCString& readLine();
+ const TQCString& readLineWnewLine();
/** searches for the string from the current file position
returns -1 when the string wasn't found. */
int findString(const char *s);
@@ -69,7 +69,7 @@ class KNFile : public QFile {
protected:
bool increaseBuffer();
- QCString buffer;
+ TQCString buffer;
char *dataPtr;
int filePos, readBytes;
};
@@ -82,20 +82,20 @@ class KNSaveHelper {
public:
- KNSaveHelper(QString saveName, QWidget *parent);
+ KNSaveHelper(TQString saveName, TQWidget *parent);
~KNSaveHelper();
/** returns a file open for writing */
- QFile* getFile(const QString &dialogTitle);
+ TQFile* getFile(const TQString &dialogTitle);
private:
- QWidget *p_arent;
- QString s_aveName;
+ TQWidget *p_arent;
+ TQString s_aveName;
KURL url;
- QFile* file;
+ TQFile* file;
KTempFile* tmpFile;
- static QString lastPath;
+ static TQString lastPath;
};
@@ -107,25 +107,25 @@ class KNLoadHelper {
public:
- KNLoadHelper(QWidget *parent);
+ KNLoadHelper(TQWidget *parent);
~KNLoadHelper();
/** opens a file dialog and returns a file open for reading */
- KNFile* getFile( const QString &dialogTitle );
+ KNFile* getFile( const TQString &dialogTitle );
/** tries to access the file specified by the url and returns
a file open for reading */
KNFile* setURL(KURL url);
- /** returns the file after getFile(QString) of setURL(url) was called */
+ /** returns the file after getFile(TQString) of setURL(url) was called */
KNFile* getFile()const { return f_ile; };
KURL getURL() const { return u_rl; };
private:
- QWidget *p_arent;
+ TQWidget *p_arent;
KURL u_rl;
KNFile *f_ile;
- QString t_empName;
- static QString l_astPath;
+ TQString t_empName;
+ static TQString l_astPath;
};
@@ -140,26 +140,26 @@ public:
/** list selection dialog, used instead of a popup menu
when a select action is called via the keyboard.
returns -1 when the user canceled the dialog. */
- static int selectDialog(QWidget *parent, const QString &caption, const QStringList &options, int initialValue);
+ static int selectDialog(TQWidget *parent, const TQString &caption, const TQStringList &options, int initialValue);
- static void saveWindowSize(const QString &name, const QSize &s);
- static void restoreWindowSize(const QString &name, QWidget *d, const QSize &defaultSize);
+ static void saveWindowSize(const TQString &name, const TQSize &s);
+ static void restoreWindowSize(const TQString &name, TQWidget *d, const TQSize &defaultSize);
- static const QString encryptStr(const QString& aStr);
- static const QString decryptStr(const QString& aStr);
- static QString rot13(const QString &s);
+ static const TQString encryptStr(const TQString& aStr);
+ static const TQString decryptStr(const TQString& aStr);
+ static TQString rot13(const TQString &s);
/** used for rewarping a text when replying to a message or inserting a file into a box */
- static QString rewrapStringList(QStringList text, int wrapAt, QChar quoteChar, bool stopAtSig, bool alwaysSpace);
+ static TQString rewrapStringList(TQStringList text, int wrapAt, TQChar quoteChar, bool stopAtSig, bool alwaysSpace);
/** use this for all internal files */
- static void displayInternalFileError(QWidget *w=0);
+ static void displayInternalFileError(TQWidget *w=0);
/** use this for all external files */
- static void displayExternalFileError(QWidget *w=0);
+ static void displayExternalFileError(TQWidget *w=0);
/** use this for remote files */
- static void displayRemoteFileError(QWidget *w=0);
+ static void displayRemoteFileError(TQWidget *w=0);
/** use this for error on temporary files */
- static void displayTempFileError(QWidget *w=0);
+ static void displayTempFileError(TQWidget *w=0);
};