diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-14 20:16:30 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-04-14 20:16:30 +0000 |
commit | 1c93fca14d9ce37499bcfdf994c660186a0b6f17 (patch) | |
tree | f2defe163a805a9e34a2142dfde4cdb5e49241e7 | |
parent | 67e29a054cfcb1b0d2fe6b0a316cf6b3eec087b7 (diff) | |
download | tdepim-1c93fca14d9ce37499bcfdf994c660186a0b6f17.tar.gz tdepim-1c93fca14d9ce37499bcfdf994c660186a0b6f17.zip |
Enable kdepim compilation under Qt4
This will likely break Qt3 compilation temporarily, which is an unintended side effect.
A third and final kdepim commit will repair Qt3 compilation shortly.
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1227946 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
698 files changed, 5005 insertions, 4993 deletions
diff --git a/akregator/src/actionmanagerimpl.cpp b/akregator/src/actionmanagerimpl.cpp index bb4741edb..09a9b3cd8 100644 --- a/akregator/src/actionmanagerimpl.cpp +++ b/akregator/src/actionmanagerimpl.cpp @@ -199,7 +199,7 @@ void ActionManagerImpl::slotTagAdded(const Tag& tag) if (!d->tagActions.tqcontains(tag.id())) { - d->tagActions[tag.id()] = new TagAction(tag, d->view, TQT_SLOT(slotAssignTag(const Tag&, bool)), d->tagMenu); + d->tagActions[tag.id()] = new TagAction(tag, TQT_TQOBJECT(d->view), TQT_SLOT(slotAssignTag(const Tag&, bool)), d->tagMenu); d->tagMenu->insert(d->tagActions[tag.id()]); } } @@ -281,51 +281,51 @@ void ActionManagerImpl::initView(View* view) d->view = view; // tag actions - new KAction(i18n("&New Tag..."), "", "", d->view, TQT_SLOT(slotNewTag()), actionCollection(), "tag_new"); + new KAction(i18n("&New Tag..."), "", "", TQT_TQOBJECT(d->view), TQT_SLOT(slotNewTag()), actionCollection(), "tag_new"); // Feed/Feed Group popup menu - new KAction(i18n("&Open Homepage"), "", "Ctrl+H", d->view, TQT_SLOT(slotOpenHomepage()), actionCollection(), "feed_homepage"); - new KAction(i18n("&Add Feed..."), "bookmark_add", "Insert", d->view, TQT_SLOT(slotFeedAdd()), actionCollection(), "feed_add"); - new KAction(i18n("Ne&w Folder..."), "folder_new", "Shift+Insert", d->view, TQT_SLOT(slotFeedAddGroup()), actionCollection(), "feed_add_group"); - new KAction(i18n("&Delete Feed"), "editdelete", "Alt+Delete", d->view, TQT_SLOT(slotFeedRemove()), actionCollection(), "feed_remove"); - new KAction(i18n("&Edit Feed..."), "edit", "F2", d->view, TQT_SLOT(slotFeedModify()), actionCollection(), "feed_modify"); + new KAction(i18n("&Open Homepage"), "", "Ctrl+H", TQT_TQOBJECT(d->view), TQT_SLOT(slotOpenHomepage()), actionCollection(), "feed_homepage"); + new KAction(i18n("&Add Feed..."), "bookmark_add", "Insert", TQT_TQOBJECT(d->view), TQT_SLOT(slotFeedAdd()), actionCollection(), "feed_add"); + new KAction(i18n("Ne&w Folder..."), "folder_new", "Shift+Insert", TQT_TQOBJECT(d->view), TQT_SLOT(slotFeedAddGroup()), actionCollection(), "feed_add_group"); + new KAction(i18n("&Delete Feed"), "editdelete", "Alt+Delete", TQT_TQOBJECT(d->view), TQT_SLOT(slotFeedRemove()), actionCollection(), "feed_remove"); + new KAction(i18n("&Edit Feed..."), "edit", "F2", TQT_TQOBJECT(d->view), TQT_SLOT(slotFeedModify()), actionCollection(), "feed_modify"); KActionMenu* vm = new KActionMenu( i18n( "&View Mode" ), actionCollection(), "view_mode" ); - KRadioAction *ra = new KRadioAction(i18n("&Normal View"), "view_top_bottom", "Ctrl+Shift+1", d->view, TQT_SLOT(slotNormalView()), actionCollection(), "normal_view"); + KRadioAction *ra = new KRadioAction(i18n("&Normal View"), "view_top_bottom", "Ctrl+Shift+1", TQT_TQOBJECT(d->view), TQT_SLOT(slotNormalView()), actionCollection(), "normal_view"); ra->setExclusiveGroup( "ViewMode" ); vm->insert(ra); - ra = new KRadioAction(i18n("&Widescreen View"), "view_left_right", "Ctrl+Shift+2", d->view, TQT_SLOT(slotWidescreenView()), actionCollection(), "widescreen_view"); + ra = new KRadioAction(i18n("&Widescreen View"), "view_left_right", "Ctrl+Shift+2", TQT_TQOBJECT(d->view), TQT_SLOT(slotWidescreenView()), actionCollection(), "widescreen_view"); ra->setExclusiveGroup( "ViewMode" ); vm->insert(ra); - ra = new KRadioAction(i18n("C&ombined View"), "view_text", "Ctrl+Shift+3", d->view, TQT_SLOT(slotCombinedView()), actionCollection(), "combined_view"); + ra = new KRadioAction(i18n("C&ombined View"), "view_text", "Ctrl+Shift+3", TQT_TQOBJECT(d->view), TQT_SLOT(slotCombinedView()), actionCollection(), "combined_view"); ra->setExclusiveGroup( "ViewMode" ); vm->insert(ra); // toolbar / feed menu - new KAction(i18n("&Fetch Feed"), "down", KStdAccel::shortcut(KStdAccel::Reload), d->view, TQT_SLOT(slotFetchCurrentFeed()), actionCollection(), "feed_fetch"); - new KAction(i18n("Fe&tch All Feeds"), "bottom", "Ctrl+L", d->view, TQT_SLOT(slotFetchAllFeeds()), actionCollection(), "feed_fetch_all"); + new KAction(i18n("&Fetch Feed"), "down", KStdAccel::shortcut(KStdAccel::Reload), TQT_TQOBJECT(d->view), TQT_SLOT(slotFetchCurrentFeed()), actionCollection(), "feed_fetch"); + new KAction(i18n("Fe&tch All Feeds"), "bottom", "Ctrl+L", TQT_TQOBJECT(d->view), TQT_SLOT(slotFetchAllFeeds()), actionCollection(), "feed_fetch_all"); KAction* stopAction = new KAction(i18n( "&Abort Fetches" ), "stop", Key_Escape, Kernel::self()->fetchQueue(), TQT_SLOT(slotAbort()), actionCollection(), "feed_stop"); stopAction->setEnabled(false); - new KAction(i18n("&Mark Feed as Read"), "goto", "Ctrl+R", d->view, TQT_SLOT(slotMarkAllRead()), actionCollection(), "feed_mark_all_as_read"); - new KAction(i18n("Ma&rk All Feeds as Read"), "goto", "Ctrl+Shift+R", d->view, TQT_SLOT(slotMarkAllFeedsRead()), actionCollection(), "feed_mark_all_feeds_as_read"); + new KAction(i18n("&Mark Feed as Read"), "goto", "Ctrl+R", TQT_TQOBJECT(d->view), TQT_SLOT(slotMarkAllRead()), actionCollection(), "feed_mark_all_as_read"); + new KAction(i18n("Ma&rk All Feeds as Read"), "goto", "Ctrl+Shift+R", TQT_TQOBJECT(d->view), TQT_SLOT(slotMarkAllFeedsRead()), actionCollection(), "feed_mark_all_feeds_as_read"); // Settings menu - KToggleAction* sqf = new KToggleAction(i18n("Show Quick Filter"), TQString(), 0, d->view, TQT_SLOT(slotToggleShowQuickFilter()), actionCollection(), "show_quick_filter"); + KToggleAction* sqf = new KToggleAction(i18n("Show Quick Filter"), TQString(), 0, TQT_TQOBJECT(d->view), TQT_SLOT(slotToggleShowQuickFilter()), actionCollection(), "show_quick_filter"); sqf->setChecked( Settings::showQuickFilter() ); - new KAction( i18n("Open in Tab"), "tab_new", "Shift+Return", d->view, TQT_SLOT(slotOpenCurrentArticle()), actionCollection(), "article_open" ); - new KAction( i18n("Open in Background Tab"), TQString(), "tab_new", d->view, TQT_SLOT(slotOpenCurrentArticleBackgroundTab()), actionCollection(), "article_open_background_tab" ); - new KAction( i18n("Open in External Browser"), "window_new", "Ctrl+Shift+Return", d->view, TQT_SLOT(slotOpenCurrentArticleExternal()), actionCollection(), "article_open_external" ); - new KAction( i18n("Copy Link Address"), TQString(), TQString(), d->view, TQT_SLOT(slotCopyLinkAddress()), actionCollection(), "article_copy_link_address" ); + new KAction( i18n("Open in Tab"), "tab_new", "Shift+Return", TQT_TQOBJECT(d->view), TQT_SLOT(slotOpenCurrentArticle()), actionCollection(), "article_open" ); + new KAction( i18n("Open in Background Tab"), TQString(), "tab_new", TQT_TQOBJECT(d->view), TQT_SLOT(slotOpenCurrentArticleBackgroundTab()), actionCollection(), "article_open_background_tab" ); + new KAction( i18n("Open in External Browser"), "window_new", "Ctrl+Shift+Return", TQT_TQOBJECT(d->view), TQT_SLOT(slotOpenCurrentArticleExternal()), actionCollection(), "article_open_external" ); + new KAction( i18n("Copy Link Address"), TQString(), TQString(), TQT_TQOBJECT(d->view), TQT_SLOT(slotCopyLinkAddress()), actionCollection(), "article_copy_link_address" ); - new KAction(i18n("Pre&vious Unread Article"), "", Key_Minus, d->view, TQT_SLOT(slotPrevUnreadArticle()),actionCollection(), "go_prev_unread_article"); - new KAction(i18n("Ne&xt Unread Article"), "", Key_Plus, d->view, TQT_SLOT(slotNextUnreadArticle()),actionCollection(), "go_next_unread_article"); + new KAction(i18n("Pre&vious Unread Article"), "", Key_Minus, TQT_TQOBJECT(d->view), TQT_SLOT(slotPrevUnreadArticle()),actionCollection(), "go_prev_unread_article"); + new KAction(i18n("Ne&xt Unread Article"), "", Key_Plus, TQT_TQOBJECT(d->view), TQT_SLOT(slotNextUnreadArticle()),actionCollection(), "go_next_unread_article"); - new KAction(i18n("&Delete"), "editdelete", "Delete", d->view, TQT_SLOT(slotArticleDelete()), actionCollection(), "article_delete"); + new KAction(i18n("&Delete"), "editdelete", "Delete", TQT_TQOBJECT(d->view), TQT_SLOT(slotArticleDelete()), actionCollection(), "article_delete"); if (Settings::showTaggingGUI()) { @@ -335,7 +335,7 @@ void ActionManagerImpl::initView(View* view) KActionMenu* statusMenu = new KActionMenu ( i18n( "&Mark As" ), actionCollection(), "article_set_status" ); - d->speakSelectedArticlesAction = new KAction(i18n("&Speak Selected Articles"), "kttsd", "", d->view, TQT_SLOT(slotTextToSpeechRequest()), actionCollection(), "akr_texttospeech"); + d->speakSelectedArticlesAction = new KAction(i18n("&Speak Selected Articles"), "kttsd", "", TQT_TQOBJECT(d->view), TQT_SLOT(slotTextToSpeechRequest()), actionCollection(), "akr_texttospeech"); KAction* abortTTS = new KAction(i18n( "&Stop Speaking" ), "player_stop", Key_Escape, SpeechClient::self(), TQT_SLOT(slotAbortJobs()), actionCollection(), "akr_aborttexttospeech"); abortTTS->setEnabled(false); @@ -345,29 +345,29 @@ void ActionManagerImpl::initView(View* view) statusMenu->insert(new KAction(KGuiItem(i18n("as in: mark as read","&Read"), "", i18n("Mark selected article as read")), - "Ctrl+E", d->view, TQT_SLOT(slotSetSelectedArticleRead()), + "Ctrl+E", TQT_TQOBJECT(d->view), TQT_SLOT(slotSetSelectedArticleRead()), actionCollection(), "article_set_status_read")); statusMenu->insert(new KAction(KGuiItem(i18n("&New"), "", i18n("Mark selected article as new")), - "Ctrl+N", d->view, TQT_SLOT(slotSetSelectedArticleNew()), + "Ctrl+N", TQT_TQOBJECT(d->view), TQT_SLOT(slotSetSelectedArticleNew()), actionCollection(), "article_set_status_new" )); statusMenu->insert(new KAction(KGuiItem(i18n("&Unread"), "", i18n("Mark selected article as unread")), - "Ctrl+U", d->view, TQT_SLOT(slotSetSelectedArticleUnread()), + "Ctrl+U", TQT_TQOBJECT(d->view), TQT_SLOT(slotSetSelectedArticleUnread()), actionCollection(), "article_set_status_unread")); KToggleAction* importantAction = new KToggleAction(i18n("&Mark as Important"), "flag", "Ctrl+I", actionCollection(), "article_set_status_important"); importantAction->setCheckedState(i18n("Remove &Important Mark")); - connect(importantAction, TQT_SIGNAL(toggled(bool)), d->view, TQT_SLOT(slotArticleToggleKeepFlag(bool))); + connect(importantAction, TQT_SIGNAL(toggled(bool)), TQT_TQOBJECT(d->view), TQT_SLOT(slotArticleToggleKeepFlag(bool))); - new KAction( i18n("Move Node Up"), TQString(), "Shift+Alt+Up", view, TQT_SLOT(slotMoveCurrentNodeUp()), d->actionCollection, "feedstree_move_up" ); - new KAction( i18n("Move Node Down"), TQString(), "Shift+Alt+Down", view, TQT_SLOT(slotMoveCurrentNodeDown()), d->actionCollection, "feedstree_move_down" ); - new KAction( i18n("Move Node Left"), TQString(), "Shift+Alt+Left", view, TQT_SLOT(slotMoveCurrentNodeLeft()), d->actionCollection, "feedstree_move_left" ); - new KAction( i18n("Move Node Right"), TQString(), "Shift+Alt+Right", view, TQT_SLOT(slotMoveCurrentNodeRight()), d->actionCollection, "feedstree_move_right"); + new KAction( i18n("Move Node Up"), TQString(), "Shift+Alt+Up", TQT_TQOBJECT(view), TQT_SLOT(slotMoveCurrentNodeUp()), d->actionCollection, "feedstree_move_up" ); + new KAction( i18n("Move Node Down"), TQString(), "Shift+Alt+Down", TQT_TQOBJECT(view), TQT_SLOT(slotMoveCurrentNodeDown()), d->actionCollection, "feedstree_move_down" ); + new KAction( i18n("Move Node Left"), TQString(), "Shift+Alt+Left", TQT_TQOBJECT(view), TQT_SLOT(slotMoveCurrentNodeLeft()), d->actionCollection, "feedstree_move_left" ); + new KAction( i18n("Move Node Right"), TQString(), "Shift+Alt+Right", TQT_TQOBJECT(view), TQT_SLOT(slotMoveCurrentNodeRight()), d->actionCollection, "feedstree_move_right"); } void ActionManagerImpl::initArticleViewer(ArticleViewer* articleViewer) @@ -385,8 +385,8 @@ void ActionManagerImpl::initArticleListView(ArticleListView* articleList) else d->articleList = articleList; - new KAction( i18n("&Previous Article"), TQString(), "Left", articleList, TQT_SLOT(slotPreviousArticle()), actionCollection(), "go_previous_article" ); - new KAction( i18n("&Next Article"), TQString(), "Right", articleList, TQT_SLOT(slotNextArticle()), actionCollection(), "go_next_article" ); + new KAction( i18n("&Previous Article"), TQString(), "Left", TQT_TQOBJECT(articleList), TQT_SLOT(slotPreviousArticle()), actionCollection(), "go_previous_article" ); + new KAction( i18n("&Next Article"), TQString(), "Right", TQT_TQOBJECT(articleList), TQT_SLOT(slotNextArticle()), actionCollection(), "go_next_article" ); } void ActionManagerImpl::initListTabWidget(ListTabWidget* listTabWidget) @@ -396,17 +396,17 @@ void ActionManagerImpl::initListTabWidget(ListTabWidget* listTabWidget) else d->listTabWidget = listTabWidget; - new KAction(i18n("&Previous Feed"), "", "P", listTabWidget, TQT_SLOT(slotPrevFeed()),actionCollection(), "go_prev_feed"); - new KAction(i18n("&Next Feed"), "", "N", listTabWidget, TQT_SLOT(slotNextFeed()),actionCollection(), "go_next_feed"); - new KAction(i18n("N&ext Unread Feed"), "", "Alt+Plus", listTabWidget, TQT_SLOT(slotNextUnreadFeed()),actionCollection(), "go_next_unread_feed"); - new KAction(i18n("Prev&ious Unread Feed"), "", "Alt+Minus", listTabWidget, TQT_SLOT(slotPrevUnreadFeed()),actionCollection(), "go_prev_unread_feed"); - - new KAction( i18n("Go to Top of Tree"), TQString(), "Ctrl+Home", listTabWidget, TQT_SLOT(slotItemBegin()), d->actionCollection, "feedstree_home" ); - new KAction( i18n("Go to Bottom of Tree"), TQString(), "Ctrl+End", listTabWidget, TQT_SLOT(slotItemEnd()), d->actionCollection, "feedstree_end" ); - new KAction( i18n("Go Left in Tree"), TQString(), "Ctrl+Left", listTabWidget, TQT_SLOT(slotItemLeft()), d->actionCollection, "feedstree_left" ); - new KAction( i18n("Go Right in Tree"), TQString(), "Ctrl+Right", listTabWidget, TQT_SLOT(slotItemRight()), d->actionCollection, "feedstree_right" ); - new KAction( i18n("Go Up in Tree"), TQString(), "Ctrl+Up", listTabWidget, TQT_SLOT(slotItemUp()), d->actionCollection, "feedstree_up" ); - new KAction( i18n("Go Down in Tree"), TQString(), "Ctrl+Down", listTabWidget, TQT_SLOT(slotItemDown()), d->actionCollection, "feedstree_down" ); + new KAction(i18n("&Previous Feed"), "", "P", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotPrevFeed()),actionCollection(), "go_prev_feed"); + new KAction(i18n("&Next Feed"), "", "N", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotNextFeed()),actionCollection(), "go_next_feed"); + new KAction(i18n("N&ext Unread Feed"), "", "Alt+Plus", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotNextUnreadFeed()),actionCollection(), "go_next_unread_feed"); + new KAction(i18n("Prev&ious Unread Feed"), "", "Alt+Minus", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotPrevUnreadFeed()),actionCollection(), "go_prev_unread_feed"); + + new KAction( i18n("Go to Top of Tree"), TQString(), "Ctrl+Home", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemBegin()), d->actionCollection, "feedstree_home" ); + new KAction( i18n("Go to Bottom of Tree"), TQString(), "Ctrl+End", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemEnd()), d->actionCollection, "feedstree_end" ); + new KAction( i18n("Go Left in Tree"), TQString(), "Ctrl+Left", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemLeft()), d->actionCollection, "feedstree_left" ); + new KAction( i18n("Go Right in Tree"), TQString(), "Ctrl+Right", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemRight()), d->actionCollection, "feedstree_right" ); + new KAction( i18n("Go Up in Tree"), TQString(), "Ctrl+Up", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemUp()), d->actionCollection, "feedstree_up" ); + new KAction( i18n("Go Down in Tree"), TQString(), "Ctrl+Down", TQT_TQOBJECT(listTabWidget), TQT_SLOT(slotItemDown()), d->actionCollection, "feedstree_down" ); } void ActionManagerImpl::initTabWidget(TabWidget* tabWidget) @@ -416,11 +416,11 @@ void ActionManagerImpl::initTabWidget(TabWidget* tabWidget) else d->tabWidget = tabWidget; - new KAction(i18n("Select Next Tab"), "", "Ctrl+Period", d->tabWidget, TQT_SLOT(slotNextTab()),actionCollection(), "select_next_tab"); - new KAction(i18n("Select Previous Tab"), "", "Ctrl+Comma", d->tabWidget, TQT_SLOT(slotPreviousTab()),actionCollection(), "select_previous_tab"); - new KAction( i18n("Detach Tab"), "tab_breakoff", CTRL+SHIFT+Key_B, d->tabWidget, TQT_SLOT(slotDetachTab()), actionCollection(), "tab_detach" ); - new KAction( i18n("Copy Link Address"), TQString(), TQString(), d->tabWidget, TQT_SLOT(slotCopyLinkAddress()), actionCollection(), "tab_copylinkaddress" ); - new KAction( i18n("&Close Tab"), "tab_remove", KStdAccel::close(), d->tabWidget, TQT_SLOT(slotCloseTab()), actionCollection(), "tab_remove" ); + new KAction(i18n("Select Next Tab"), "", "Ctrl+Period", TQT_TQOBJECT(d->tabWidget), TQT_SLOT(slotNextTab()),actionCollection(), "select_next_tab"); + new KAction(i18n("Select Previous Tab"), "", "Ctrl+Comma", TQT_TQOBJECT(d->tabWidget), TQT_SLOT(slotPreviousTab()),actionCollection(), "select_previous_tab"); + new KAction( i18n("Detach Tab"), "tab_breakoff", CTRL+SHIFT+Key_B, TQT_TQOBJECT(d->tabWidget), TQT_SLOT(slotDetachTab()), actionCollection(), "tab_detach" ); + new KAction( i18n("Copy Link Address"), TQString(), TQString(), TQT_TQOBJECT(d->tabWidget), TQT_SLOT(slotCopyLinkAddress()), actionCollection(), "tab_copylinkaddress" ); + new KAction( i18n("&Close Tab"), "tab_remove", KStdAccel::close(), TQT_TQOBJECT(d->tabWidget), TQT_SLOT(slotCloseTab()), actionCollection(), "tab_remove" ); } TQWidget* ActionManagerImpl::container(const char* name) diff --git a/akregator/src/addfeeddialog.cpp b/akregator/src/addfeeddialog.cpp index 78a801039..8c5f4d4b9 100644 --- a/akregator/src/addfeeddialog.cpp +++ b/akregator/src/addfeeddialog.cpp @@ -83,7 +83,7 @@ void AddFeedDialog::slotOk( ) feedURL.prepend("http://"); f->setXmlUrl(feedURL); - widget->statusLabel->setText( i18n("Downloading %1").arg(feedURL) ); + widget->statusLabel->setText( i18n("Downloading %1").tqarg(feedURL) ); connect( feed, TQT_SIGNAL(fetched(Feed* )), this, TQT_SLOT(fetchCompleted(Feed *)) ); @@ -102,7 +102,7 @@ void AddFeedDialog::fetchCompleted(Feed */*f*/) void AddFeedDialog::fetchError(Feed *) { - KMessageBox::error(this, i18n("Feed not found from %1.").arg(feedURL)); + KMessageBox::error(this, i18n("Feed not found from %1.").tqarg(feedURL)); KDialogBase::slotCancel(); } diff --git a/akregator/src/akregator_part.cpp b/akregator/src/akregator_part.cpp index 2b0f73e79..3cdbceb19 100644 --- a/akregator/src/akregator_part.cpp +++ b/akregator/src/akregator_part.cpp @@ -54,7 +54,7 @@ #include <tqstringlist.h> #include <tqtimer.h> #include <tqwidgetlist.h> -#include <private/qucomextra_p.h> +#include <private/tqucomextra_p.h> #include <cerrno> #include <sys/types.h> @@ -146,7 +146,7 @@ Part::Part( TQWidget *tqparentWidget, const char * /*widgetName*/, TQStringList storageParams; - storageParams.append(TQString("taggingEnabled=%1").arg(Settings::showTaggingGUI() ? "true" : "false")); + storageParams.append(TQString("taggingEnabled=%1").tqarg(Settings::showTaggingGUI() ? "true" : "false")); if (factory != 0) { @@ -168,7 +168,7 @@ Part::Part( TQWidget *tqparentWidget, const char * /*widgetName*/, { m_storage = Backend::StorageFactoryRegistry::self()->getFactory("dummy")->createStorage(storageParams); - KMessageBox::error(tqparentWidget, i18n("Unable to load storage backend plugin \"%1\". No feeds are archived.").arg(Settings::archiveBackend()), i18n("Plugin error") ); + KMessageBox::error(tqparentWidget, i18n("Unable to load storage backend plugin \"%1\". No feeds are archived.").tqarg(Settings::archiveBackend()), i18n("Plugin error") ); } Filters::ArticleFilterList list; @@ -232,7 +232,7 @@ Part::Part( TQWidget *tqparentWidget, const char * /*widgetName*/, initFonts(); - RSS::FileRetriever::setUserAgent(TQString("Akregator/%1; librss/remnants").arg(AKREGATOR_VERSION)); + RSS::FileRetriever::setUserAgent(TQString("Akregator/%1; librss/remnants").tqarg(AKREGATOR_VERSION)); } void Part::loadPlugins() @@ -432,7 +432,7 @@ bool Part::openFile() copyFile(backup); - KMessageBox::error(m_view, i18n("<qt>The standard feed list is corrupted (invalid XML). A backup was created:<p><b>%2</b></p></qt>").arg(backup), i18n("XML Parsing Error") ); + KMessageBox::error(m_view, i18n("<qt>The standard feed list is corrupted (invalid XML). A backup was created:<p><b>%2</b></p></qt>").tqarg(backup), i18n("XML Parsing Error") ); } if (!doc.setContent(listBackup)) @@ -447,7 +447,7 @@ bool Part::openFile() TQString backup = m_file + "-backup." + TQString::number(TQDateTime::tqcurrentDateTime().toTime_t()); copyFile(backup); - KMessageBox::error(m_view, i18n("<qt>The standard feed list is corrupted (no valid OPML). A backup was created:<p><b>%2</b></p></qt>").arg(backup), i18n("OPML Parsing Error") ); + KMessageBox::error(m_view, i18n("<qt>The standard feed list is corrupted (no valid OPML). A backup was created:<p><b>%2</b></p></qt>").tqarg(backup), i18n("OPML Parsing Error") ); } m_view->loadFeeds(createDefaultFeedList()); } @@ -486,7 +486,7 @@ void Part::slotSaveFeedList() if (file.open(IO_WriteOnly) == false) { //FIXME: allow to save the feedlist into different location -tpr 20041118 - KMessageBox::error(m_view, i18n("Access denied: cannot save feed list (%1)").arg(m_file), i18n("Write error") ); + KMessageBox::error(m_view, i18n("Access denied: cannot save feed list (%1)").tqarg(m_file), i18n("Write error") ); return; } @@ -522,7 +522,7 @@ bool Part::mergePart(KParts::Part* part) { if (m_mergedPart) { factory()->removeClient(m_mergedPart); - if (childClients()->containsRef(m_mergedPart)) + if (childClients()->tqcontainsRef(m_mergedPart)) removeChildClient(m_mergedPart); } if (part) @@ -575,7 +575,7 @@ void Part::loadTagSet(const TQString& path) TQFile file(path); if (file.open(IO_ReadOnly)) { - doc.setContent(file.readAll()); + doc.setContent(TQByteArray(file.readAll())); file.close(); } // if we can't load the tagset from the xml file, check for the backup in the backend @@ -636,13 +636,13 @@ void Part::importFile(const KURL& url) { // Read OPML feeds list and build TQDom tree. TQDomDocument doc; - if (doc.setContent(file.readAll())) + if (doc.setContent(TQByteArray(file.readAll()))) m_view->importFeeds(doc); else - KMessageBox::error(m_view, i18n("Could not import the file %1 (no valid OPML)").arg(filename), i18n("OPML Parsing Error") ); + KMessageBox::error(m_view, i18n("Could not import the file %1 (no valid OPML)").tqarg(filename), i18n("OPML Parsing Error") ); } else - KMessageBox::error(m_view, i18n("The file %1 could not be read, check if it exists or if it is readable for the current user.").arg(filename), i18n("Read Error")); + KMessageBox::error(m_view, i18n("The file %1 could not be read, check if it exists or if it is readable for the current user.").tqarg(filename), i18n("Read Error")); if (isRemote) KIO::NetAccess::removeTempFile(filename); @@ -656,7 +656,7 @@ void Part::exportFile(const KURL& url) if ( file.exists() && KMessageBox::questionYesNo(m_view, - i18n("The file %1 already exists; do you want to overwrite it?").arg(file.name()), + i18n("The file %1 already exists; do you want to overwrite it?").tqarg(file.name()), i18n("Export"), i18n("Overwrite"), KStdGuiItem::cancel()) == KMessageBox::No ) @@ -664,7 +664,7 @@ void Part::exportFile(const KURL& url) if ( !file.open(IO_WriteOnly) ) { - KMessageBox::error(m_view, i18n("Access denied: cannot write to file %1").arg(file.name()), i18n("Write Error") ); + KMessageBox::error(m_view, i18n("Access denied: cannot write to file %1").tqarg(file.name()), i18n("Write Error") ); return; } @@ -978,11 +978,11 @@ bool Part::tryToLock(const TQString& backendName) "can cause the loss of archived articles and crashes at startup.</b> " "You should disable the archive for now " "unless you are sure that %2 is not already running.</qt>") - .arg( programName, programName, backendName ); + .tqarg( programName, programName, backendName ); // TQString::arg( st ) only replaces the first occurrence of %1 // with st while TQString::arg( s1, s2 ) replacess all occurrences // of %1 with s1 and all occurrences of %2 with s2. So don't - // even think about changing the above to .arg( programName ). + // even think about changing the above to .tqarg( programName ). else msg = i18n("<qt>%1 seems to be running on another display on this " "machine. <b>Running %1 and %2 at the same " @@ -990,7 +990,7 @@ bool Part::tryToLock(const TQString& backendName) "the loss of archived articles and crashes at startup.</b> " "You should disable the archive for now " "unless you are sure that %2 is not already running.</qt>") - .arg( oldProgramName, programName, backendName ); + .tqarg( oldProgramName, programName, backendName ); } else { @@ -1001,7 +1001,7 @@ bool Part::tryToLock(const TQString& backendName) "You should disable the archive for now " "unless you are sure that it is " "not already running on %2.</qt>") - .arg( programName, oldHostName, backendName ); + .tqarg( programName, oldHostName, backendName ); else msg = i18n("<qt>%1 seems to be running on %3. <b>Running %1 and %2 at the " "same time is not supported by the %4 backend and can cause " @@ -1009,7 +1009,7 @@ bool Part::tryToLock(const TQString& backendName) "You should disable the archive for now " "unless you are sure that %1 is " "not running on %3.</qt>") - .arg( oldProgramName, programName, oldHostName, backendName ); + .tqarg( oldProgramName, programName, oldHostName, backendName ); } KCursorSaver idle( KBusyPtr::idle() ); diff --git a/akregator/src/akregator_view.cpp b/akregator/src/akregator_view.cpp index 0d9b56afd..6df0469c7 100644 --- a/akregator/src/akregator_view.cpp +++ b/akregator/src/akregator_view.cpp @@ -145,7 +145,7 @@ class View::DeleteNodeVisitor : public TreeNodeVisitor virtual bool visitTagNode(TagNode* node) { - TQString msg = i18n("<qt>Are you sure you want to delete tag <b>%1</b>? The tag will be removed from all articles.</qt>").arg(node->title()); + TQString msg = i18n("<qt>Are you sure you want to delete tag <b>%1</b>? The tag will be removed from all articles.</qt>").tqarg(node->title()); if (KMessageBox::warningContinueCancel(0, msg, i18n("Delete Tag"), KStdGuiItem::del()) == KMessageBox::Continue) { Tag tag = node->tag(); @@ -166,7 +166,7 @@ class View::DeleteNodeVisitor : public TreeNodeVisitor if (node->title().isEmpty()) msg = i18n("<qt>Are you sure you want to delete this folder and its feeds and subfolders?</qt>"); else - msg = i18n("<qt>Are you sure you want to delete folder <b>%1</b> and its feeds and subfolders?</qt>").arg(node->title()); + msg = i18n("<qt>Are you sure you want to delete folder <b>%1</b> and its feeds and subfolders?</qt>").tqarg(node->title()); if (KMessageBox::warningContinueCancel(0, msg, i18n("Delete Folder"), KStdGuiItem::del()) == KMessageBox::Continue) { @@ -182,7 +182,7 @@ class View::DeleteNodeVisitor : public TreeNodeVisitor if (node->title().isEmpty()) msg = i18n("<qt>Are you sure you want to delete this feed?</qt>"); else - msg = i18n("<qt>Are you sure you want to delete feed <b>%1</b>?</qt>").arg(node->title()); + msg = i18n("<qt>Are you sure you want to delete feed <b>%1</b>?</qt>").tqarg(node->title()); if (KMessageBox::warningContinueCancel(0, msg, i18n("Delete Feed"), KStdGuiItem::del()) == KMessageBox::Continue) { @@ -222,11 +222,11 @@ View::View( Part *part, TQWidget *tqparent, ActionManagerImpl* actionManager, co m_shuttingDown = false; m_displayingAboutPage = false; m_currentFrame = 0L; - setFocusPolicy(TQWidget::StrongFocus); + setFocusPolicy(Qt::StrongFocus); TQVBoxLayout *lt = new TQVBoxLayout( this ); - m_horizontalSplitter = new TQSplitter(TQSplitter::Horizontal, this); + m_horizontalSplitter = new TQSplitter(Qt::Horizontal, this); m_horizontalSplitter->setOpaqueResize(true); lt->addWidget(m_horizontalSplitter); @@ -285,7 +285,7 @@ View::View( Part *part, TQWidget *tqparent, ActionManagerImpl* actionManager, co mainTabLayout->addWidget(m_searchBar); - m_articleSplitter = new TQSplitter(TQSplitter::Vertical, m_mainTab, "panner2"); + m_articleSplitter = new TQSplitter(Qt::Vertical, m_mainTab, "panner2"); m_articleList = new ArticleListView( m_articleSplitter, "articles" ); m_actionManager->initArticleListView(m_articleList); @@ -317,7 +317,7 @@ View::View( Part *part, TQWidget *tqparent, ActionManagerImpl* actionManager, co TQWhatsThis::add(m_articleViewer->widget(), i18n("Browsing area.")); mainTabLayout->addWidget( m_articleSplitter ); - m_mainFrame=new Frame(this, m_part, m_mainTab, i18n("Articles"), false); + m_mainFrame=new Frame(TQT_TQOBJECT(this), m_part, m_mainTab, i18n("Articles"), false); connectFrame(m_mainFrame); m_tabs->addFrame(m_mainFrame); @@ -431,7 +431,7 @@ void View::slotOpenNewTab(const KURL& url, bool background) connect( page, TQT_SIGNAL(urlClicked(const KURL &, Viewer*, bool, bool)), this, TQT_SLOT(slotUrlClickedInViewer(const KURL &, Viewer*, bool, bool)) ); - Frame* frame = new Frame(this, page, page->widget(), i18n("Untitled")); + Frame* frame = new Frame(TQT_TQOBJECT(this), page, page->widget(), i18n("Untitled")); frame->setAutoDeletePart(true); // delete page viewer when removing the tab connect(page, TQT_SIGNAL(setWindowCaption (const TQString &)), frame, TQT_SLOT(setTitle (const TQString &))); @@ -638,7 +638,7 @@ void View::slotNormalView() m_articleViewer->slotShowSummary(m_listTabWidget->activeView()->selectedNode()); } - m_articleSplitter->setOrientation(TQSplitter::Vertical); + m_articleSplitter->setOrientation(Qt::Vertical); m_viewMode = NormalView; Settings::setViewMode( m_viewMode ); @@ -662,7 +662,7 @@ void View::slotWidescreenView() m_articleViewer->slotShowSummary(m_listTabWidget->activeView()->selectedNode()); } - m_articleSplitter->setOrientation(TQSplitter::Horizontal); + m_articleSplitter->setOrientation(Qt::Horizontal); m_viewMode = WidescreenView; Settings::setViewMode( m_viewMode ); @@ -1100,7 +1100,7 @@ void View::slotFeedFetched(Feed *feed) void View::slotMouseButtonPressed(int button, const Article& article, const TQPoint &, int) { - if (button == TQt::MidButton) + if (button == Qt::MidButton) { KURL link = article.link(); switch (Settings::mMBBehaviour()) @@ -1266,7 +1266,7 @@ void View::slotCopyLinkAddress() link = article.link().url(); else link = article.guid(); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); cb->setText(link, TQClipboard::Clipboard); cb->setText(link, TQClipboard::Selection); } @@ -1312,7 +1312,7 @@ void View::slotArticleDelete() case 0: return; case 1: - msg = i18n("<qt>Are you sure you want to delete article <b>%1</b>?</qt>").arg(TQStyleSheet::escape(articles.first().title())); + msg = i18n("<qt>Are you sure you want to delete article <b>%1</b>?</qt>").tqarg(TQStyleSheet::escape(articles.first().title())); break; default: msg = i18n("<qt>Are you sure you want to delete the selected article?</qt>", diff --git a/akregator/src/articleviewer.cpp b/akregator/src/articleviewer.cpp index 608e2a8d9..a6ab467d8 100644 --- a/akregator/src/articleviewer.cpp +++ b/akregator/src/articleviewer.cpp @@ -72,9 +72,9 @@ class ArticleViewer::ShowSummaryVisitor : public TreeNodeVisitor m_view->m_link = TQString(); TQString text; - text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").arg(TQApplication::reverseLayout() ? "rtl" : "ltr"); + text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").tqarg(TQApplication::reverseLayout() ? "rtl" : "ltr"); - text += TQString("<div class=\"headertitle\" dir=\"%1\">").arg(directionOf(Utils::stripTags(node->title()))); + text += TQString("<div class=\"headertitle\" dir=\"%1\">").tqarg(directionOf(Utils::stripTags(node->title()))); text += node->title(); if(node->unread() == 0) text += i18n(" (no unread articles)"); @@ -90,26 +90,26 @@ class ArticleViewer::ShowSummaryVisitor : public TreeNodeVisitor TQString file = url.tqreplace("/", "_").tqreplace(":", "_"); KURL u(m_view->m_imageDir); u.setFileName(file); - text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(node->htmlUrl()).arg(u.url()); + text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").tqarg(node->htmlUrl()).tqarg(u.url()); } else text += "<div class=\"body\">"; if( !node->description().isEmpty() ) { - text += TQString("<div dir=\"%1\">").arg(Utils::stripTags(directionOf(node->description()))); - text += i18n("<b>Description:</b> %1<br><br>").arg(node->description()); + text += TQString("<div dir=\"%1\">").tqarg(Utils::stripTags(directionOf(node->description()))); + text += i18n("<b>Description:</b> %1<br><br>").tqarg(node->description()); text += "</div>\n"; // /description } if ( !node->htmlUrl().isEmpty() ) { - text += TQString("<div dir=\"%1\">").arg(directionOf(node->htmlUrl())); - text += i18n("<b>Homepage:</b> <a href=\"%1\">%2</a>").arg(node->htmlUrl()).arg(node->htmlUrl()); + text += TQString("<div dir=\"%1\">").tqarg(directionOf(node->htmlUrl())); + text += i18n("<b>Homepage:</b> <a href=\"%1\">%2</a>").tqarg(node->htmlUrl()).tqarg(node->htmlUrl()); text += "</div>\n"; // / link } - //text += i18n("<b>Unread articles:</b> %1").arg(node->unread()); + //text += i18n("<b>Unread articles:</b> %1").tqarg(node->unread()); text += "</div>"; // /body m_view->renderContent(text); @@ -121,8 +121,8 @@ class ArticleViewer::ShowSummaryVisitor : public TreeNodeVisitor m_view->m_link = TQString(); TQString text; - text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").arg(TQApplication::reverseLayout() ? "rtl" : "ltr"); - text += TQString("<div class=\"headertitle\" dir=\"%1\">%2").arg(directionOf(Utils::stripTags(node->title()))).arg(node->title()); + text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").tqarg(TQApplication::reverseLayout() ? "rtl" : "ltr"); + text += TQString("<div class=\"headertitle\" dir=\"%1\">%2").tqarg(directionOf(Utils::stripTags(node->title()))).tqarg(node->title()); if(node->unread() == 0) text += i18n(" (no unread articles)"); else @@ -139,8 +139,8 @@ class ArticleViewer::ShowSummaryVisitor : public TreeNodeVisitor m_view->m_link = TQString(); TQString text; - text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").arg(TQApplication::reverseLayout() ? "rtl" : "ltr"); - text += TQString("<div class=\"headertitle\" dir=\"%1\">%2").arg(directionOf(Utils::stripTags(node->title()))).arg(node->title()); + text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").tqarg(TQApplication::reverseLayout() ? "rtl" : "ltr"); + text += TQString("<div class=\"headertitle\" dir=\"%1\">%2").tqarg(directionOf(Utils::stripTags(node->title()))).tqarg(node->title()); if(node->unread() == 0) text += i18n(" (no unread articles)"); else @@ -188,7 +188,7 @@ ArticleViewer::~ArticleViewer() void ArticleViewer::generateNormalModeCSS() { - const TQColorGroup & cg = TQApplication::palette().active(); + const TQColorGroup & cg = TQApplication::tqpalette().active(); // from kmail::headerstyle.cpp m_normalModeCSS = TQString( @@ -198,10 +198,10 @@ void ArticleViewer::generateNormalModeCSS() " font-size: %2 ! important;\n" " color: %3 ! important;\n" " background: %4 ! important;\n" - "}\n\n").arg(Settings::standardFont()) - .arg(TQString::number(pointsToPixel(Settings::mediumFontSize()))+"px") - .arg(cg.text().name()) - .arg(cg.base().name()); + "}\n\n").tqarg(Settings::standardFont()) + .tqarg(TQString::number(pointsToPixel(Settings::mediumFontSize()))+"px") + .tqarg(cg.text().name()) + .tqarg(cg.base().name()); m_normalModeCSS += TQString( "a {\n" + TQString(" color: %1 ! important;\n") @@ -214,18 +214,18 @@ void ArticleViewer::generateNormalModeCSS() +" margin-bottom: 10pt;\n" // +" width: 99%;\n" + "}\n\n") - .arg(cg.link().name()) - .arg(cg.background().name()) - .arg(cg.text().name()); + .tqarg(cg.link().name()) + .tqarg(cg.background().name()) + .tqarg(cg.text().name()); m_normalModeCSS += TQString(".headertitle a:link { color: %1 ! important; }\n" ".headertitle a:visited { color: %2 ! important; }\n" ".headertitle a:hover{ color: %3 ! important; }\n" ".headertitle a:active { color: %4 ! important; }\n") - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()); + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()); m_normalModeCSS += TQString( ".headertitle {\n" @@ -244,8 +244,8 @@ void ArticleViewer::generateNormalModeCSS() ".headimage {\n" " float: right;\n" " margin-left: 5px;\n" - "}\n\n").arg(cg.highlight().name()) - .arg(cg.highlightedText().name()); + "}\n\n").tqarg(cg.highlight().name()) + .tqarg(cg.highlightedText().name()); m_normalModeCSS += TQString( "body { clear: none; }\n\n" @@ -267,7 +267,7 @@ void ArticleViewer::generateNormalModeCSS() void ArticleViewer::generateCombinedModeCSS() { - const TQColorGroup & cg = TQApplication::palette().active(); + const TQColorGroup & cg = TQApplication::tqpalette().active(); // from kmail::headerstyle.cpp m_combinedModeCSS = TQString ( @@ -278,10 +278,10 @@ void ArticleViewer::generateCombinedModeCSS() " font-size: %2 ! important;\n" " color: %3 ! important;\n" " background: %4 ! important;\n" - "}\n\n").arg(Settings::standardFont()) - .arg(TQString::number(pointsToPixel(Settings::mediumFontSize()))+"px") - .arg(cg.text().name()) - .arg(cg.base().name()); + "}\n\n").tqarg(Settings::standardFont()) + .tqarg(TQString::number(pointsToPixel(Settings::mediumFontSize()))+"px") + .tqarg(cg.text().name()) + .tqarg(cg.base().name()); m_combinedModeCSS += ( "a {\n" + TQString(" color: %1 ! important;\n") @@ -294,18 +294,18 @@ void ArticleViewer::generateCombinedModeCSS() +" margin-bottom: 10pt;\n" // +" width: 99%;\n" + "}\n\n") - .arg(cg.link().name()) - .arg(cg.background().name()) - .arg(cg.text().name()); + .tqarg(cg.link().name()) + .tqarg(cg.background().name()) + .tqarg(cg.text().name()); m_combinedModeCSS += TQString(".headertitle a:link { color: %1 ! important; }\n" ".headertitle a:visited { color: %2 ! important; }\n" ".headertitle a:hover{ color: %3 ! important; }\n" ".headertitle a:active { color: %4 ! important; }\n") - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()) - .arg(cg.highlightedText().name()); + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()) + .tqarg(cg.highlightedText().name()); m_combinedModeCSS += TQString( ".headertitle {\n" " background: %1 ! important;\n" @@ -323,8 +323,8 @@ void ArticleViewer::generateCombinedModeCSS() ".headimage {\n" " float: right;\n" " margin-left: 5px;\n" - "}\n\n").arg(cg.highlight().name()) - .arg(cg.highlightedText().name()); + "}\n\n").tqarg(cg.highlight().name()) + .tqarg(cg.highlightedText().name()); m_combinedModeCSS += TQString( "body { clear: none; }\n\n" @@ -368,11 +368,11 @@ void ArticleViewer::displayAboutPage() { TQString location = locate("data", "akregator/about/main.html"); TQString content = KPIM::kFileToString(location); - content = content.arg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); + content = content.tqarg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); if ( kapp->reverseLayout() ) - content = content.arg( "@import \"%1\";" ).arg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); + content = content.tqarg( "@import \"%1\";" ).tqarg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); else - content = content.arg( "" ); + content = content.tqarg( "" ); begin(KURL( location )); TQString info = @@ -389,25 +389,25 @@ void ArticleViewer::displayAboutPage() "<p>We hope that you will enjoy Akregator.</p>\n" "<p>Thank you,</p>\n" "<p style='margin-bottom: 0px'> The Akregator Team</p>\n") - .arg(AKREGATOR_VERSION) // Akregator version - .arg("http://akregator.kde.org/"); // Akregator homepage URL + .tqarg(AKREGATOR_VERSION) // Akregator version + .tqarg("http://akregator.kde.org/"); // Akregator homepage URL TQString fontSize = TQString::number( pointsToPixel( Settings::mediumFontSize() )); TQString appTitle = i18n("Akregator"); TQString catchPhrase = ""; //not enough space for a catch phrase at default window size i18n("Part of the Kontact Suite"); TQString quickDescription = i18n("An RSS feed reader for the K Desktop Environment."); - write(content.arg(fontSize).arg(appTitle).arg(catchPhrase).arg(quickDescription).arg(info)); + write(content.tqarg(fontSize).tqarg(appTitle).tqarg(catchPhrase).tqarg(quickDescription).tqarg(info)); end(); } TQString ArticleViewer::formatArticleNormalMode(Feed* feed, const Article& article) { TQString text; - text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").arg(TQApplication::reverseLayout() ? "rtl" : "ltr"); + text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").tqarg(TQApplication::reverseLayout() ? "rtl" : "ltr"); if (!article.title().isEmpty()) { - text += TQString("<div class=\"headertitle\" dir=\"%1\">\n").arg(directionOf(Utils::stripTags(article.title()))); + text += TQString("<div class=\"headertitle\" dir=\"%1\">\n").tqarg(directionOf(Utils::stripTags(article.title()))); if (article.link().isValid()) text += "<a href=\""+article.link().url()+"\">"; text += article.title().tqreplace("<", "<").tqreplace(">", ">"); // TODO: better leave things escaped in the parser @@ -417,16 +417,16 @@ TQString ArticleViewer::formatArticleNormalMode(Feed* feed, const Article& artic } if (article.pubDate().isValid()) { - text += TQString("<span class=\"header\" dir=\"%1\">").arg(directionOf(i18n("Date"))); - text += TQString ("%1:").arg(i18n("Date")); + text += TQString("<span class=\"header\" dir=\"%1\">").tqarg(directionOf(i18n("Date"))); + text += TQString ("%1:").tqarg(i18n("Date")); text += "</span><span class=\"headertext\">"; text += KGlobal::locale()->formatDateTime(article.pubDate(), false, false)+"</span>\n"; // TODO: might need RTL? } TQString author = article.author(); if (!author.isEmpty()) { - text += TQString("<br/><span class=\"header\" dir=\"%1\">").arg(directionOf(i18n("Author"))); - text += TQString ("%1:").arg(i18n("Author")); + text += TQString("<br/><span class=\"header\" dir=\"%1\">").tqarg(directionOf(i18n("Author"))); + text += TQString ("%1:").tqarg(i18n("Author")); text += "</span><span class=\"headertext\">"; text += author+"</span>\n"; // TODO: might need RTL? } @@ -437,14 +437,14 @@ TQString ArticleViewer::formatArticleNormalMode(Feed* feed, const Article& artic TQString file = Utils::fileNameForUrl(feed->xmlUrl()); KURL u(m_imageDir); u.setFileName(file); - text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(feed->htmlUrl()).arg(u.url()); + text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").tqarg(feed->htmlUrl()).tqarg(u.url()); } if (!article.description().isEmpty()) { - text += TQString("<div dir=\"%1\">").arg(directionOf(Utils::stripTags(article.description())) ); + text += TQString("<div dir=\"%1\">").tqarg(directionOf(Utils::stripTags(article.description())) ); text += "<span class=\"content\">"+article.description()+"</span>"; text += "</div>"; } @@ -486,7 +486,7 @@ TQString ArticleViewer::formatArticleNormalMode(Feed* feed, const Article& artic //int length = article.enclosure().length(); //TQString lengthStr = KIO::convertSize(length); - //text += TQString("<hr><div><a href=\"%1\">%2</a> (%3, %4)</div>").arg(url).arg(url).arg(lengthStr).arg(type); + //text += TQString("<hr><div><a href=\"%1\">%2</a> (%3, %4)</div>").tqarg(url).tqarg(url).tqarg(lengthStr).tqarg(type); } //kdDebug() << text << endl; return text; @@ -496,13 +496,13 @@ TQString ArticleViewer::formatArticleNormalMode(Feed* feed, const Article& artic TQString ArticleViewer::formatArticleCombinedMode(Feed* feed, const Article& article) { TQString text; - text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").arg(TQApplication::reverseLayout() ? "rtl" : "ltr"); + text = TQString("<div class=\"headerbox\" dir=\"%1\">\n").tqarg(TQApplication::reverseLayout() ? "rtl" : "ltr"); KURL link = article.link(); if (!article.title().isEmpty()) { - text += TQString("<div class=\"headertitle\" dir=\"%1\">\n").arg(directionOf(Utils::stripTags(article.title()))); + text += TQString("<div class=\"headertitle\" dir=\"%1\">\n").tqarg(directionOf(Utils::stripTags(article.title()))); if (link.isValid()) text += "<a href=\""+link.url()+"\">"; text += article.title().tqreplace("<", "<").tqreplace(">", ">"); // TODO: better leave things escaped in the parser @@ -512,8 +512,8 @@ TQString ArticleViewer::formatArticleCombinedMode(Feed* feed, const Article& art } if (article.pubDate().isValid()) { - text += TQString("<span class=\"header\" dir=\"%1\">").arg(directionOf(i18n("Date"))); - text += TQString ("%1:").arg(i18n("Date")); + text += TQString("<span class=\"header\" dir=\"%1\">").tqarg(directionOf(i18n("Date"))); + text += TQString ("%1:").tqarg(i18n("Date")); text += "</span><span class=\"headertext\">"; text += KGlobal::locale()->formatDateTime(article.pubDate(), false, false)+"</span>\n"; // TODO: might need RTL? } @@ -521,8 +521,8 @@ TQString ArticleViewer::formatArticleCombinedMode(Feed* feed, const Article& art TQString author = article.author(); if (!author.isEmpty()) { - text += TQString("<br/><span class=\"header\" dir=\"%1\">").arg(directionOf(i18n("Author"))); - text += TQString ("%1:").arg(i18n("Author")); + text += TQString("<br/><span class=\"header\" dir=\"%1\">").tqarg(directionOf(i18n("Author"))); + text += TQString ("%1:").tqarg(i18n("Author")); text += "</span><span class=\"headertext\">"; text += author+"</span>\n"; // TODO: might need RTL? } @@ -534,14 +534,14 @@ TQString ArticleViewer::formatArticleCombinedMode(Feed* feed, const Article& art TQString file = Utils::fileNameForUrl(feed->xmlUrl()); KURL u(m_imageDir); u.setFileName(file); - text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").arg(feed->htmlUrl()).arg(u.url()); + text += TQString("<a href=\"%1\"><img class=\"headimage\" src=\"%2.png\"></a>\n").tqarg(feed->htmlUrl()).tqarg(u.url()); } if (!article.description().isEmpty()) { - text += TQString("<div dir=\"%1\">").arg(directionOf(Utils::stripTags(article.description())) ); + text += TQString("<div dir=\"%1\">").tqarg(directionOf(Utils::stripTags(article.description())) ); text += "<span class=\"content\">"+article.description()+"</span>"; text += "</div>"; } diff --git a/akregator/src/dragobjects.h b/akregator/src/dragobjects.h index 5a232c097..ebe931f66 100644 --- a/akregator/src/dragobjects.h +++ b/akregator/src/dragobjects.h @@ -33,7 +33,7 @@ #include <tqstring.h> #include <tqvaluelist.h> -typedef class TQMemArray<char> TQByteArray; +#include <tqcstring.h> namespace Akregator { diff --git a/akregator/src/feedlistview.cpp b/akregator/src/feedlistview.cpp index 0ca068fdd..ac9c82125 100644 --- a/akregator/src/feedlistview.cpp +++ b/akregator/src/feedlistview.cpp @@ -462,7 +462,7 @@ TreeNodeItem* NodeListView::findNodeItem(TreeNode* node) TreeNodeItem* NodeListView::findItemByTitle(const TQString& text, int column, ComparisonFlags compare) const { - return dynamic_cast<TreeNodeItem*> (KListView::findItem(text, column, compare)); + return dynamic_cast<TreeNodeItem*> (KListView::tqfindItem(text, column, compare)); } void NodeListView::ensureNodeVisible(TreeNode* node) diff --git a/akregator/src/folder.cpp b/akregator/src/folder.cpp index 78612ec79..d55c75aec 100644 --- a/akregator/src/folder.cpp +++ b/akregator/src/folder.cpp @@ -137,7 +137,7 @@ TQValueList<TreeNode*> Folder::tqchildren() const void Folder::insertChild(TreeNode* node, TreeNode* after) { - int pos = d->tqchildren.findIndex(after); + int pos = d->tqchildren.tqfindIndex(after); if (pos < 0) prependChild(node); diff --git a/akregator/src/librss/feeddetector.cpp b/akregator/src/librss/feeddetector.cpp index 099cc2a79..b12164f0e 100644 --- a/akregator/src/librss/feeddetector.cpp +++ b/akregator/src/librss/feeddetector.cpp @@ -72,7 +72,7 @@ FeedDetectorEntryList FeedDetector::extractFromLinkTags(const TQString& s) TQString type; int pos = reType.search(*it, 0); if (pos != -1) - type = reType.cap(1).lower(); + type = TQString(reType.cap(1)).lower(); // we accept only type attributes indicating a feed if ( type != "application/rss+xml" && type != "application/rdf+xml" diff --git a/akregator/src/librss/tools_p.cpp b/akregator/src/librss/tools_p.cpp index 48b4a52a0..9c18fcaeb 100644 --- a/akregator/src/librss/tools_p.cpp +++ b/akregator/src/librss/tools_p.cpp @@ -69,8 +69,8 @@ static ContentFormat mapTypeToFormat(const TQString& modep, const TQString& type return HTML; if (type == TQString::fromUtf8("text") - || (type.startsWith(TQString::fromUtf8("text/"), false) - && !type.startsWith(TQString::fromUtf8("text/xml"), false)) + || (type.tqstartsWith(TQString::fromUtf8("text/"), false) + && !type.tqstartsWith(TQString::fromUtf8("text/xml"), false)) ) return Text; @@ -85,8 +85,8 @@ static ContentFormat mapTypeToFormat(const TQString& modep, const TQString& type if (xmltypes.tqcontains(type) - || type.endsWith(TQString::fromUtf8("+xml"), false) - || type.endsWith(TQString::fromUtf8("/xml"), false)) + || type.tqendsWith(TQString::fromUtf8("+xml"), false) + || type.tqendsWith(TQString::fromUtf8("/xml"), false)) return XML; return Binary; @@ -239,7 +239,7 @@ TQString parseItemAuthor(const TQDomElement& element, Format format, Version ver name = email; if (!email.isNull()) - return TQString("<a href=\"mailto:%1\">%2</a>").arg(email).arg(name); + return TQString("<a href=\"mailto:%1\">%2</a>").tqarg(email).tqarg(name); else return name; } diff --git a/akregator/src/listtabwidget.cpp b/akregator/src/listtabwidget.cpp index a5b28662e..a8c8f5d14 100644 --- a/akregator/src/listtabwidget.cpp +++ b/akregator/src/listtabwidget.cpp @@ -125,7 +125,7 @@ void ListTabWidget::slotRootNodeChanged(NodeListView* view, TreeNode* node) if (unread > 0) { //uncomment this to append unread count - //d->tabWidget->changeTab(view, TQString("<qt>%1 (%2)").arg(d->captions[view]).arg(node->unread())); + //d->tabWidget->changeTab(view, TQString("<qt>%1 (%2)").tqarg(d->captions[view]).tqarg(node->unread())); d->tabWidget->changeTab(view, d->captions[view]); } else diff --git a/akregator/src/mainwindow.cpp b/akregator/src/mainwindow.cpp index c6e8d09b1..3111cab44 100644 --- a/akregator/src/mainwindow.cpp +++ b/akregator/src/mainwindow.cpp @@ -55,14 +55,14 @@ #include <tqmetaobject.h> #include <tqpen.h> #include <tqpainter.h> -#include <private/qucomextra_p.h> +#include <private/tqucomextra_p.h> #include <tqtimer.h> namespace Akregator { BrowserInterface::BrowserInterface( MainWindow *shell, const char *name ) - : KParts::BrowserInterface( shell, name ) + : KParts::BrowserInterface( TQT_TQOBJECT(shell), name ) { m_shell = shell; } @@ -104,7 +104,7 @@ bool MainWindow::loadPart() { // now that the Part is loaded, we cast it to a Part to get // our hands on it - m_part = static_cast<Akregator::Part*>(factory->create(this, "akregator_part", "KParts::ReadOnlyPart" )); + m_part = static_cast<Akregator::Part*>(factory->create(TQT_TQOBJECT(this), "akregator_part", "KParts::ReadOnlyPart" )); if (m_part) { @@ -154,13 +154,13 @@ void MainWindow::setupActions() { connectActionCollection(actionCollection()); - KStdAction::quit(kapp, TQT_SLOT(quit()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(quit()), actionCollection()); setStandardToolBarMenuEnabled(true); createStandardStatusBarAction(); - KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection()); } void MainWindow::saveProperties(KConfig* config) diff --git a/akregator/src/notificationmanager.cpp b/akregator/src/notificationmanager.cpp index 6220e97c0..ce4251b87 100644 --- a/akregator/src/notificationmanager.cpp +++ b/akregator/src/notificationmanager.cpp @@ -76,7 +76,7 @@ void NotificationManager::slotNotifyFeeds(const TQStringList& feeds) if (feeds.count() == 1) { KNotifyClient::Instance inst(m_instance); - KNotifyClient::event(m_widget->winId(), "feed_added", i18n("Feed added:\n %1").arg(feeds[0])); + KNotifyClient::event(m_widget->winId(), "feed_added", i18n("Feed added:\n %1").tqarg(feeds[0])); } else if (feeds.count() > 1) { @@ -84,7 +84,7 @@ void NotificationManager::slotNotifyFeeds(const TQStringList& feeds) for (TQStringList::ConstIterator it = feeds.begin(); it != feeds.end(); ++it) message += *it + "\n"; KNotifyClient::Instance inst(m_instance); - KNotifyClient::event(m_widget->winId(), "feed_added", i18n("Feeds added:\n %1").arg(message)); + KNotifyClient::event(m_widget->winId(), "feed_added", i18n("Feeds added:\n %1").tqarg(message)); } } @@ -99,7 +99,7 @@ void NotificationManager::doNotify() if (feedTitle != (*it).feed()->title()) { feedTitle = (*it).feed()->title(); - message += TQString("<p><b>%1:</b></p>").arg(feedTitle); + message += TQString("<p><b>%1:</b></p>").tqarg(feedTitle); } message += (*it).title() + "<br>"; } diff --git a/akregator/src/pageviewer.cpp b/akregator/src/pageviewer.cpp index 64169225f..477575906 100644 --- a/akregator/src/pageviewer.cpp +++ b/akregator/src/pageviewer.cpp @@ -53,7 +53,7 @@ #include <tqscrollview.h> #include <tqstring.h> #include <tqvaluelist.h> -#include <private/qucomextra_p.h> +#include <private/tqucomextra_p.h> #include <cstdlib> using std::abs; @@ -356,13 +356,13 @@ void PageViewer::slotCancelled( const TQString & /*errMsg*/ ) void PageViewer::urlSelected(const TQString &url, int button, int state, const TQString &_target, KParts::URLArgs args) { - if (url.startsWith(TQString::tqfromLatin1( "javascript:" ), /*case-sensitive=*/false) ) + if (url.tqstartsWith(TQString::tqfromLatin1( "javascript:" ), /*case-sensitive=*/false) ) { KHTMLPart::urlSelected(url,button,state,_target,args); } else { - if (button == LeftButton) + if (button == Qt::LeftButton) { m_url = completeURL(url); browserExtension()->setURLArgs(args); @@ -390,7 +390,7 @@ void PageViewer::slotPaletteOrFontChanged() if ( !obj ) // not all views have a browser extension ! return; - int id = obj->tqmetaObject()->findSlot("reparseConfiguration()"); + int id = obj->tqmetaObject()->tqfindSlot("reparseConfiguration()"); if (id == -1) return; TQUObject o[1]; @@ -430,7 +430,7 @@ void PageViewer::slotPopupMenu(KXMLGUIClient*, const TQPoint& p, const KURL& kur if (isLink) { idNewWindow = popup.insertItem(SmallIcon("tab_new"),i18n("Open Link in New &Tab"), this, TQT_SLOT(slotOpenLinkInForegroundTab())); - popup.setWhatsThis(idNewWindow, i18n("<b>Open Link in New Tab</b><p>Opens current link in a new tab.")); + popup.tqsetWhatsThis(idNewWindow, i18n("<b>Open Link in New Tab</b><p>Opens current link in a new tab.")); popup.insertItem(SmallIcon("window_new"), i18n("Open Link in External &Browser"), this, TQT_SLOT(slotOpenLinkInBrowser())); popup.insertSeparator(); diff --git a/akregator/src/pluginmanager.cpp b/akregator/src/pluginmanager.cpp index d12016d45..108fcf9b1 100644 --- a/akregator/src/pluginmanager.cpp +++ b/akregator/src/pluginmanager.cpp @@ -92,8 +92,8 @@ PluginManager::createFromService( const KService::Ptr service ) if ( !lib ) { KMessageBox::error( 0, i18n( "<p>KLibLoader could not load the plugin:<br/><i>%1</i></p>" "<p>Error message:<br/><i>%2</i></p>" ) - .arg( service->library() ) - .arg( loader->lastErrorMessage() ) ); + .tqarg( service->library() ) + .tqarg( loader->lastErrorMessage() ) ); return 0; } //look up address of init function and cast it to pointer-to-function @@ -167,12 +167,12 @@ PluginManager::showAbout( const TQString &constraint ) TQString str = "<html><body><table width=\"100%\" border=\"1\">"; - str += body.arg( i18n( "Name" ), s->name() ); - str += body.arg( i18n( "Library" ), s->library() ); - str += body.arg( i18n( "Authors" ), s->property( "X-KDE-akregator-authors" ).toStringList().join( "\n" ) ); - str += body.arg( i18n( "Email" ), s->property( "X-KDE-akregator-email" ).toStringList().join( "\n" ) ); - str += body.arg( i18n( "Version" ), s->property( "X-KDE-akregator-version" ).toString() ); - str += body.arg( i18n( "Framework Version" ), s->property( "X-KDE-akregator-framework-version" ).toString() ); + str += body.tqarg( i18n( "Name" ), s->name() ); + str += body.tqarg( i18n( "Library" ), s->library() ); + str += body.tqarg( i18n( "Authors" ), s->property( "X-KDE-akregator-authors" ).toStringList().join( "\n" ) ); + str += body.tqarg( i18n( "Email" ), s->property( "X-KDE-akregator-email" ).toStringList().join( "\n" ) ); + str += body.tqarg( i18n( "Version" ), s->property( "X-KDE-akregator-version" ).toString() ); + str += body.tqarg( i18n( "Framework Version" ), s->property( "X-KDE-akregator-framework-version" ).toString() ); str += "</table></body></html>"; diff --git a/akregator/src/propertiesdialog.cpp b/akregator/src/propertiesdialog.cpp index 658051f9a..e3ce7b1e9 100644 --- a/akregator/src/propertiesdialog.cpp +++ b/akregator/src/propertiesdialog.cpp @@ -102,7 +102,7 @@ void FeedPropertiesDialog::slotSetCaption(const TQString& c) if(c.isEmpty()) setCaption(i18n("Feed Properties")); else - setCaption(i18n("Properties of %1").arg(c)); + setCaption(i18n("Properties of %1").tqarg(c)); } diff --git a/akregator/src/tabwidget.cpp b/akregator/src/tabwidget.cpp index 7ae02ba9f..60ba42b3f 100644 --- a/akregator/src/tabwidget.cpp +++ b/akregator/src/tabwidget.cpp @@ -166,8 +166,8 @@ void TabWidget::removeFrame(Frame *f) uint TabWidget::tabBarWidthForMaxChars( uint maxLength ) { int hframe, overlap; - hframe = tabBar()->style().tqpixelMetric( TQStyle::PM_TabBarTabHSpace, this ); - overlap = tabBar()->style().tqpixelMetric( TQStyle::PM_TabBarTabOverlap, this ); + hframe = tabBar()->tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabHSpace, this ); + overlap = tabBar()->tqstyle().tqpixelMetric( TQStyle::PM_TabBarTabOverlap, this ); TQFontMetrics fm = tabBar()->fontMetrics(); int x = 0; @@ -183,7 +183,7 @@ uint TabWidget::tabBarWidthForMaxChars( uint maxLength ) if ( tab->iconSet() ) iw = tab->iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4; - x += ( tabBar()->style().sizeFromContents( TQStyle::CT_TabBarTab, this, TQSize( TQMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ), TQStyleOption( tab ) ) ).width(); + x += ( tabBar()->tqstyle().tqsizeFromContents( TQStyle::CT_TabBarTab, this, TQSize( TQMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ), TQStyleOption( tab ) ) ).width(); } return x; } @@ -288,8 +288,8 @@ void TabWidget::slotCopyLinkAddress() url = view->part()->url(); - kapp->clipboard()->setText(url.prettyURL(), TQClipboard::Selection); - kapp->clipboard()->setText(url.prettyURL(), TQClipboard::Clipboard); + kapp->tqclipboard()->setText(url.prettyURL(), TQClipboard::Selection); + kapp->tqclipboard()->setText(url.prettyURL(), TQClipboard::Clipboard); } void TabWidget::slotCloseTab() diff --git a/akregator/src/trayicon.cpp b/akregator/src/trayicon.cpp index 963e60294..e48593354 100644 --- a/akregator/src/trayicon.cpp +++ b/akregator/src/trayicon.cpp @@ -74,7 +74,7 @@ TrayIcon::~TrayIcon() void TrayIcon::mousePressEvent(TQMouseEvent *e) { - if (e->button() == LeftButton) { + if (e->button() == Qt::LeftButton) { emit showPart(); } @@ -116,7 +116,7 @@ TQPixmap TrayIcon::takeScreenshot() const // Paint the border const int BORDER = 1; TQPixmap finalShot(w + 2*BORDER, h + 2*BORDER); - finalShot.fill(KApplication::palette().active().foreground()); + finalShot.fill(KApplication::tqpalette().active().foreground()); painter.begin(&finalShot); painter.drawPixmap(BORDER, BORDER, shot); painter.end(); @@ -177,7 +177,7 @@ void TrayIcon::slotSetUnread(int unread) void TrayIcon::viewButtonClicked() { - TQWidget *p=static_cast<TQWidget*>(tqparent()); + TQWidget *p=TQT_TQWIDGET(tqparent()); KWin::forceActiveWindow(p->winId()); } diff --git a/akregator/src/treenode.cpp b/akregator/src/treenode.cpp index 58e4ae8ea..27ee2ecae 100644 --- a/akregator/src/treenode.cpp +++ b/akregator/src/treenode.cpp @@ -96,7 +96,7 @@ TreeNode* TreeNode::nextSibling() const TQValueList<TreeNode*> tqchildren = d->tqparent->tqchildren(); TreeNode* me = (TreeNode*)this; - int idx = tqchildren.findIndex(me); + int idx = tqchildren.tqfindIndex(me); return idx+1 < tqchildren.size() ? *(tqchildren.at(idx+1)) : 0L; } @@ -108,7 +108,7 @@ TreeNode* TreeNode::prevSibling() const TQValueList<TreeNode*> tqchildren = d->tqparent->tqchildren(); TreeNode* me = (TreeNode*)this; - int idx = tqchildren.findIndex(me); + int idx = tqchildren.tqfindIndex(me); return idx > 0 ? *(d->tqparent->tqchildren().at(idx-1)) : 0L; } diff --git a/akregator/src/viewer.cpp b/akregator/src/viewer.cpp index 2c52cf433..989ff8ae5 100644 --- a/akregator/src/viewer.cpp +++ b/akregator/src/viewer.cpp @@ -130,7 +130,7 @@ void Viewer::urlSelected(const TQString &url, int button, int state, const TQStr { m_url = completeURL(url); browserExtension()->setURLArgs(args); - if (button == LeftButton) + if (button == Qt::LeftButton) { switch (Settings::lMBBehaviour()) { @@ -146,7 +146,7 @@ void Viewer::urlSelected(const TQString &url, int button, int state, const TQStr } return; } - else if (button == MidButton) + else if (button == Qt::MidButton) { switch (Settings::mMBBehaviour()) { @@ -203,7 +203,7 @@ void Viewer::slotCopy() { TQString text = selectedText(); text.tqreplace( TQChar( 0xa0 ), ' ' ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); disconnect( cb, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotClearSelection() ) ); cb->setText(text); connect( cb, TQT_SIGNAL( selectionChanged() ), this, TQT_SLOT( slotClearSelection() ) ); @@ -212,7 +212,7 @@ void Viewer::slotCopy() void Viewer::slotCopyLinkAddress() { if(m_url.isEmpty()) return; - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); cb->setText(m_url.prettyURL(), TQClipboard::Clipboard); cb->setText(m_url.prettyURL(), TQClipboard::Selection); } diff --git a/certmanager/certificateinfowidgetimpl.cpp b/certmanager/certificateinfowidgetimpl.cpp index 8ce43aa53..9067672e2 100644 --- a/certmanager/certificateinfowidgetimpl.cpp +++ b/certmanager/certificateinfowidgetimpl.cpp @@ -126,7 +126,7 @@ void CertificateInfoWidgetImpl::setKey( const GpgME::Key & key ) { TQListViewItem * item = 0; item = new TQListViewItem( listView, item, i18n("Valid"), TQString("From %1 to %2") - .arg( time_t2string( key.subkey(0).creationTime() ), + .tqarg( time_t2string( key.subkey(0).creationTime() ), time_t2string( key.subkey(0).expirationTime() ) ) ); item = new TQListViewItem( listView, item, i18n("Can be used for signing"), key.canSign() ? i18n("Yes") : i18n("No") ); @@ -187,7 +187,7 @@ static void showChainListError( TQWidget * tqparent, const GpgME::Error & err, c const TQString msg = i18n("<qt><p>An error occurred while fetching " "the certificate <b>%1</b> from the backend:</p>" "<p><b>%2</b></p></qt>") - .arg( subject ? TQString::fromUtf8( subject ) : TQString(), + .tqarg( subject ? TQString::fromUtf8( subject ) : TQString(), TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n("Certificate Listing Failed" ) ); } @@ -253,7 +253,7 @@ void CertificateInfoWidgetImpl::startCertificateChainListing() { } void CertificateInfoWidgetImpl::startCertificateDump() { - KProcess* proc = new KProcess( this ); + KProcess* proc = new KProcess( TQT_TQOBJECT(this) ); (*proc) << "gpgsm"; // must be in the PATH (*proc) << "--dump-keys"; (*proc) << mChain.front().primaryFingerprint(); @@ -266,7 +266,7 @@ void CertificateInfoWidgetImpl::startCertificateDump() { this, TQT_SLOT( slotDumpProcessExited(KProcess*) ) ); if ( !proc->start( KProcess::NotifyOnExit, (KProcess::Communication)(KProcess::Stdout | KProcess::Stderr) ) ) { - TQString wmsg = i18n("Failed to execute gpgsm:\n%1").arg( i18n( "program not found" ) ); + TQString wmsg = i18n("Failed to execute gpgsm:\n%1").tqarg( i18n( "program not found" ) ); dumpView->setText( TQStyleSheet::escape( wmsg ) ); delete proc; } @@ -294,9 +294,9 @@ void CertificateInfoWidgetImpl::slotDumpProcessExited(KProcess* proc) { { TQString wmsg = i18n("Failed to execute gpgsm:\n%1"); if ( rc == -1 ) - wmsg = wmsg.arg( i18n( "program cannot be executed" ) ); + wmsg = wmsg.tqarg( i18n( "program cannot be executed" ) ); else - wmsg = wmsg.arg( strerror(rc) ); + wmsg = wmsg.tqarg( strerror(rc) ); dumpView->setText( TQStyleSheet::escape( wmsg ) ); } } @@ -328,7 +328,7 @@ void CertificateInfoWidgetImpl::updateChainView() { item = new TQListViewItem( pathView, Kleo::DN( (*it++).userID(0).id() ).prettyDN() ); else { item = new TQListViewItem( pathView, i18n("Issuer certificate not found ( %1)") - .arg( Kleo::DN( (*it).issuerName() ).prettyDN() ) ); + .tqarg( Kleo::DN( (*it).issuerName() ).prettyDN() ) ); item->setOpen( true ); // TQt bug: doesn't open after setEnabled( false ) :/ item->setEnabled( false ); } diff --git a/certmanager/certificatewizardimpl.cpp b/certmanager/certificatewizardimpl.cpp index 3c618e738..89f4d66eb 100644 --- a/certmanager/certificatewizardimpl.cpp +++ b/certmanager/certificatewizardimpl.cpp @@ -88,10 +88,10 @@ static TQString attributeLabel( const TQString & attr, bool required ) { if ( !label.isEmpty() ) if ( required ) return i18n("Format string for the labels in the \"Your Personal Data\" page - required field", - "*%1 (%2):").arg( label, attr ); + "*%1 (%2):").tqarg( label, attr ); else return i18n("Format string for the labels in the \"Your Personal Data\" page", - "%1 (%2):").arg( label, attr ); + "%1 (%2):").tqarg( label, attr ); else if ( required ) return '*' + attr + ':'; @@ -196,7 +196,7 @@ void CertificateWizardImpl::slotGenerateCertificate() TQString certParms; certParms += "<GnupgKeyParms format=\"internal\">\n"; certParms += "Key-Type: RSA\n"; - certParms += TQString( "Key-Length: %1\n" ).arg( keyLengths[keyLengthCB->currentItem()] ); + certParms += TQString( "Key-Length: %1\n" ).tqarg( keyLengths[keyLengthCB->currentItem()] ); certParms += "Key-Usage: "; if ( signOnlyCB->isChecked() ) certParms += "Sign"; @@ -255,7 +255,7 @@ void CertificateWizardImpl::slotGenerateCertificate() if ( err ) KMessageBox::error( this, i18n( "Could not start certificate generation: %1" ) - .arg( TQString::fromLocal8Bit( err.asString() ) ), + .tqarg( TQString::fromLocal8Bit( err.asString() ) ), i18n( "Certificate Manager Error" ) ); else { generatePB->setEnabled( false ); @@ -278,7 +278,7 @@ void CertificateWizardImpl::slotResult( const GpgME::KeyGenerationResult & res, if ( !res.error().isCanceled() ) KMessageBox::error( this, i18n( "Could not generate certificate: %1" ) - .arg( TQString::tqfromLatin1( res.error().asString() ) ), + .tqarg( TQString::tqfromLatin1( res.error().asString() ) ), i18n( "Certificate Manager Error" ) ); } else { // next will stay enabled until the user clicks Generate @@ -362,7 +362,7 @@ void CertificateWizardImpl::createPersonalDataPage() if ( config.entryIsImmutable( attr ) ) le->setEnabled( false ); - _attrPairList.append(qMakePair(key, le)); + _attrPairList.append(tqMakePair(key, le)); connect( le, TQT_SIGNAL(textChanged(const TQString&)), TQT_SLOT(slotEnablePersonalDataPageExit()) ); @@ -391,7 +391,7 @@ void CertificateWizardImpl::slotURLSelected( const TQString& _url ) // The application/pkcs10 mimetype didn't have a native extension, // so the filedialog didn't have the checkbox for auto-adding it. TQString fileName = url.fileName(); - int pos = fileName.findRev( '.' ); + int pos = fileName.tqfindRev( '.' ); if ( pos < 0 ) // no extension url.setFileName( fileName + ".p10" ); #endif @@ -434,7 +434,7 @@ void CertificateWizardImpl::sendCertificate( const TQString& email, const TQByte if ( result != 0 ) { kdDebug() << "Couldn't connect to KMail\n"; KMessageBox::error( this, - i18n( "DCOP Communication Error, unable to send certificate using KMail.\n%1" ).arg( error ) ); + i18n( "DCOP Communication Error, unable to send certificate using KMail.\n%1" ).tqarg( error ) ); return; } @@ -481,7 +481,7 @@ void CertificateWizardImpl::accept() if ( KMessageBox::Cancel == KMessageBox::warningContinueCancel( this, i18n( "A file named \"%1\" already exists. " - "Are you sure you want to overwrite it?" ).arg( url.prettyURL() ), + "Are you sure you want to overwrite it?" ).tqarg( url.prettyURL() ), i18n( "Overwrite File?" ), i18n( "&Overwrite" ) ) ) return; diff --git a/certmanager/certmanager.cpp b/certmanager/certmanager.cpp index 59fc73766..5f70bc220 100644 --- a/certmanager/certmanager.cpp +++ b/certmanager/certmanager.cpp @@ -2,7 +2,7 @@ certmanager.cpp This file is part of Kleopatra, the KDE keymanager - Copyright (c) 2001,2002,2004 Klarälvdalens Datakonsult AB + Copyright (c) 2001,2002,2004 Klar�lvdalens Datakonsult AB Kleopatra is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -252,23 +252,23 @@ static inline void connectEnableOperationSignal( TQObject * s, TQObject * d ) { void CertManager::createActions() { KAction * action = 0; - (void)KStdAction::quit( this, TQT_SLOT(close()), actionCollection() ); + (void)KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection() ); - action = KStdAction::redisplay( this, TQT_SLOT(slotRedisplay()), actionCollection() ); + action = KStdAction::redisplay( TQT_TQOBJECT(this), TQT_SLOT(slotRedisplay()), actionCollection() ); // work around the fact that the stdaction has no shortcut KShortcut reloadShortcut = KStdAccel::shortcut(KStdAccel::Reload); reloadShortcut.append(KKey(CTRL + Key_R)); action->setShortcut( reloadShortcut ); - connectEnableOperationSignal( this, action ); + connectEnableOperationSignal( TQT_TQOBJECT(this), action ); action = new KAction( i18n("Stop Operation"), "stop", Key_Escape, - this, TQT_SIGNAL(stopOperations()), + TQT_TQOBJECT(this), TQT_SIGNAL(stopOperations()), actionCollection(), "view_stop_operations" ); action->setEnabled( false ); (void) new KAction( i18n("New Key Pair..."), "filenew", 0, - this, TQT_SLOT(newCertificate()), + TQT_TQOBJECT(this), TQT_SLOT(newCertificate()), actionCollection(), "file_new_certificate" ); connect( new KToggleAction( i18n("Hierarchical Key List"), 0, @@ -276,100 +276,100 @@ void CertManager::createActions() { TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotToggleHierarchicalView(bool)) ); action = new KAction( i18n("Expand All"), 0, CTRL+Key_Period, - this, TQT_SLOT(slotExpandAll()), + TQT_TQOBJECT(this), TQT_SLOT(slotExpandAll()), actionCollection(), "view_expandall" ); action = new KAction( i18n("Collapse All"), 0, CTRL+Key_Comma, - this, TQT_SLOT(slotCollapseAll()), + TQT_TQOBJECT(this), TQT_SLOT(slotCollapseAll()), actionCollection(), "view_collapseall" ); (void) new KAction( i18n("Refresh CRLs"), 0, 0, - this, TQT_SLOT(slotRefreshKeys()), + TQT_TQOBJECT(this), TQT_SLOT(slotRefreshKeys()), actionCollection(), "certificates_refresh_clr" ); #ifdef NOT_IMPLEMENTED_ANYWAY mRevokeCertificateAction = new KAction( i18n("Revoke"), 0, - this, TQT_SLOT(revokeCertificate()), + TQT_TQOBJECT(this), TQT_SLOT(revokeCertificate()), actionCollection(), "edit_revoke_certificate" ); connectEnableOperationSignal( this, mRevokeCertificateAction ); mExtendCertificateAction = new KAction( i18n("Extend"), 0, - this, TQT_SLOT(extendCertificate()), + TQT_TQOBJECT(this), TQT_SLOT(extendCertificate()), actionCollection(), "edit_extend_certificate" ); connectEnableOperationSignal( this, mExtendCertificateAction ); #endif mDeleteCertificateAction = new KAction( i18n("Delete"), "editdelete", Key_Delete, - this, TQT_SLOT(slotDeleteCertificate()), + TQT_TQOBJECT(this), TQT_SLOT(slotDeleteCertificate()), actionCollection(), "edit_delete_certificate" ); - connectEnableOperationSignal( this, mDeleteCertificateAction ); + connectEnableOperationSignal( TQT_TQOBJECT(this), mDeleteCertificateAction ); mValidateCertificateAction = new KAction( i18n("Validate"), "reload", SHIFT + Key_F5, - this, TQT_SLOT(slotValidate()), + TQT_TQOBJECT(this), TQT_SLOT(slotValidate()), actionCollection(), "certificates_validate" ); - connectEnableOperationSignal( this, mValidateCertificateAction ); + connectEnableOperationSignal( TQT_TQOBJECT(this), mValidateCertificateAction ); mImportCertFromFileAction = new KAction( i18n("Import Certificates..."), 0, - this, TQT_SLOT(slotImportCertFromFile()), + TQT_TQOBJECT(this), TQT_SLOT(slotImportCertFromFile()), actionCollection(), "file_import_certificates" ); - connectEnableOperationSignal( this, mImportCertFromFileAction ); + connectEnableOperationSignal( TQT_TQOBJECT(this), mImportCertFromFileAction ); mImportCRLFromFileAction = new KAction( i18n("Import CRLs..."), 0, - this, TQT_SLOT(importCRLFromFile()), + TQT_TQOBJECT(this), TQT_SLOT(importCRLFromFile()), actionCollection(), "file_import_crls" ); - connectEnableOperationSignal( this, mImportCRLFromFileAction ); + connectEnableOperationSignal( TQT_TQOBJECT(this), mImportCRLFromFileAction ); mExportCertificateAction = new KAction( i18n("Export Certificates..."), "export", 0, - this, TQT_SLOT(slotExportCertificate()), + TQT_TQOBJECT(this), TQT_SLOT(slotExportCertificate()), actionCollection(), "file_export_certificate" ); mExportSecretKeyAction = new KAction( i18n("Export Secret Key..."), "export", 0, - this, TQT_SLOT(slotExportSecretKey()), + TQT_TQOBJECT(this), TQT_SLOT(slotExportSecretKey()), actionCollection(), "file_export_secret_keys" ); - connectEnableOperationSignal( this, mExportSecretKeyAction ); + connectEnableOperationSignal( TQT_TQOBJECT(this), mExportSecretKeyAction ); mViewCertDetailsAction = new KAction( i18n("Certificate Details..."), 0, 0, - this, TQT_SLOT(slotViewDetails()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(slotViewDetails()), actionCollection(), "view_certificate_details" ); mDownloadCertificateAction = new KAction( i18n( "Download"), 0, 0, - this, TQT_SLOT(slotDownloadCertificate()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(slotDownloadCertificate()), actionCollection(), "download_certificate" ); const TQString dirmngr = KStandardDirs::findExe( "gpgsm" ); mDirMngrFound = !dirmngr.isEmpty(); action = new KAction( i18n("Dump CRL Cache..."), 0, - this, TQT_SLOT(slotViewCRLs()), + TQT_TQOBJECT(this), TQT_SLOT(slotViewCRLs()), actionCollection(), "crl_dump_crl_cache" ); action->setEnabled( mDirMngrFound ); // we also need dirmngr for this action = new KAction( i18n("Clear CRL Cache..."), 0, - this, TQT_SLOT(slotClearCRLs()), + TQT_TQOBJECT(this), TQT_SLOT(slotClearCRLs()), actionCollection(), "crl_clear_crl_cache" ); action->setEnabled( mDirMngrFound ); // we also need dirmngr for this - action = new KAction( i18n("GnuPG Log Viewer..."), "pgp-keys", 0, this, + action = new KAction( i18n("GnuPG Log Viewer..."), "pgp-keys", 0, TQT_TQOBJECT(this), TQT_SLOT(slotStartWatchGnuPG()), actionCollection(), "tools_start_kwatchgnupg"); // disable action if no kwatchgnupg binary is around if (KStandardDirs::findExe("kwatchgnupg").isEmpty()) action->setEnabled(false); (void)new LabelAction( i18n("Search:"), actionCollection(), "label_action" ); - mLineEditAction = new LineEditAction( TQString(), actionCollection(), this, + mLineEditAction = new LineEditAction( TQString(), actionCollection(), TQT_TQOBJECT(this), TQT_SLOT(slotSearch()), "query_lineedit_action"); TQStringList lst; lst << i18n("In Local Certificates") << i18n("In External Certificates"); - mComboAction = new ComboAction( lst, actionCollection(), this, TQT_SLOT( slotToggleRemote(int) ), + mComboAction = new ComboAction( lst, actionCollection(), TQT_TQOBJECT(this), TQT_SLOT( slotToggleRemote(int) ), "location_combo_action", mNextFindRemote? 1 : 0 ); - mFindAction = new KAction( i18n("Find"), "tqfind", 0, this, TQT_SLOT(slotSearch()), + mFindAction = new KAction( i18n("Find"), "tqfind", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSearch()), actionCollection(), "tqfind" ); - KStdAction::keyBindings( this, TQT_SLOT(slotEditKeybindings()), actionCollection() ); - KStdAction::preferences( this, TQT_SLOT(slotShowConfigurationDialog()), actionCollection() ); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT(slotEditKeybindings()), actionCollection() ); + KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT(slotShowConfigurationDialog()), actionCollection() ); - new KAction( i18n( "Configure &GpgME Backend" ), 0, 0, this, TQT_SLOT(slotConfigureGpgME()), + new KAction( i18n( "Configure &GpgME Backend" ), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(slotConfigureGpgME()), actionCollection(), "configure_gpgme" ); createStandardStatusBarAction(); @@ -523,7 +523,7 @@ void CertManager::slotRefreshKeysResult( const GpgME::Error & err ) { return; if ( err ) KMessageBox::error( this, i18n("An error occurred while trying to refresh " - "keys:\n%1").arg( TQString::fromLocal8Bit( err.asString() ) ), + "keys:\n%1").tqarg( TQString::fromLocal8Bit( err.asString() ) ), i18n("Refreshing Keys Failed") ); } @@ -532,7 +532,7 @@ static void showKeyListError( TQWidget * tqparent, const GpgME::Error & err ) { const TQString msg = i18n( "<qt><p>An error occurred while fetching " "the certificates from the backend:</p>" "<p><b>%1</b></p></qt>" ) - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n( "Certificate Listing Failed" ) ); } @@ -592,7 +592,7 @@ static void selectKeys( Kleo::KeyListView * lv, const std::set<std::string> & fp for ( TQListViewItemIterator it( lv ) ; it.current() ; ++it ) if ( Kleo::KeyListViewItem * item = Kleo::lvi_cast<Kleo::KeyListViewItem>( it.current() ) ) { const char * fpr = item->key().primaryFingerprint(); - item->setSelected( fpr && fprs.tqfind( fpr ) != fprs.end() ); + item->setSelected( fpr && fprs.find( fpr ) != fprs.end() ); } } @@ -705,8 +705,8 @@ static void showCertificateDownloadError( TQWidget * tqparent, const GpgME::Erro const TQString msg = i18n( "<qt><p>An error occurred while trying " "to download the certificate %1:</p>" "<p><b>%2</b></p></qt>" ) - .arg( certDisplayName ) - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( certDisplayName ) + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n( "Certificate Download Failed" ) ); } @@ -773,8 +773,8 @@ static void showCertificateImportError( TQWidget * tqparent, const GpgME::Error const TQString msg = i18n( "<qt><p>An error occurred while trying " "to import the certificate %1:</p>" "<p><b>%2</b></p></qt>" ) - .arg( certDisplayName ) - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( certDisplayName ) + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n( "Certificate Import Failed" ) ); } @@ -810,50 +810,50 @@ void CertManager::slotCertificateImportResult( const GpgME::ImportResult & res ) const TQString boldLine = i18n("<tr><td align=\"right\"><b>%1</b></td><td>%2</td></tr>"); TQStringList lines; - lines.push_back( normalLine.arg( i18n("Total number processed:"), + lines.push_back( normalLine.tqarg( i18n("Total number processed:"), TQString::number( res.numConsidered() ) ) ); - lines.push_back( normalLine.arg( i18n("Imported:"), + lines.push_back( normalLine.tqarg( i18n("Imported:"), TQString::number( res.numImported() ) ) ); if ( res.newSignatures() ) - lines.push_back( normalLine.arg( i18n("New signatures:"), + lines.push_back( normalLine.tqarg( i18n("New signatures:"), TQString::number( res.newSignatures() ) ) ); if ( res.newUserIDs() ) - lines.push_back( normalLine.arg( i18n("New user IDs:"), + lines.push_back( normalLine.tqarg( i18n("New user IDs:"), TQString::number( res.newUserIDs() ) ) ); if ( res.numKeysWithoutUserID() ) - lines.push_back( normalLine.arg( i18n("Keys without user IDs:"), + lines.push_back( normalLine.tqarg( i18n("Keys without user IDs:"), TQString::number( res.numKeysWithoutUserID() ) ) ); if ( res.newSubkeys() ) - lines.push_back( normalLine.arg( i18n("New subkeys:"), + lines.push_back( normalLine.tqarg( i18n("New subkeys:"), TQString::number( res.newSubkeys() ) ) ); if ( res.newRevocations() ) - lines.push_back( boldLine.arg( i18n("Newly revoked:"), + lines.push_back( boldLine.tqarg( i18n("Newly revoked:"), TQString::number( res.newRevocations() ) ) ); if ( res.notImported() ) - lines.push_back( boldLine.arg( i18n("Not imported:"), + lines.push_back( boldLine.tqarg( i18n("Not imported:"), TQString::number( res.notImported() ) ) ); if ( res.numUnchanged() ) - lines.push_back( normalLine.arg( i18n("Unchanged:"), + lines.push_back( normalLine.tqarg( i18n("Unchanged:"), TQString::number( res.numUnchanged() ) ) ); if ( res.numSecretKeysConsidered() ) - lines.push_back( normalLine.arg( i18n("Secret keys processed:"), + lines.push_back( normalLine.tqarg( i18n("Secret keys processed:"), TQString::number( res.numSecretKeysConsidered() ) ) ); if ( res.numSecretKeysImported() ) - lines.push_back( normalLine.arg( i18n("Secret keys imported:"), + lines.push_back( normalLine.tqarg( i18n("Secret keys imported:"), TQString::number( res.numSecretKeysImported() ) ) ); if ( res.numSecretKeysConsidered() - res.numSecretKeysImported() - res.numSecretKeysUnchanged() > 0 ) - lines.push_back( boldLine.arg( i18n("Secret keys <em>not</em> imported:"), + lines.push_back( boldLine.tqarg( i18n("Secret keys <em>not</em> imported:"), TQString::number( res.numSecretKeysConsidered() - res.numSecretKeysImported() - res.numSecretKeysUnchanged() ) ) ); if ( res.numSecretKeysUnchanged() ) - lines.push_back( normalLine.arg( i18n("Secret keys unchanged:"), + lines.push_back( normalLine.tqarg( i18n("Secret keys unchanged:"), TQString::number( res.numSecretKeysUnchanged() ) ) ); KMessageBox::information( this, i18n( "<qt><p>Detailed results of importing %1:</p>" "<table>%2</table></qt>" ) - .arg( displayName ).arg( lines.join( TQString() ) ), + .tqarg( displayName ).tqarg( lines.join( TQString() ) ), i18n( "Certificate Import Result" ) ); disconnectJobFromStatusBarProgress( res.error() ); @@ -875,7 +875,7 @@ void CertManager::slotDirmngrExited() { if ( !mDirmngrProc->normalExit() ) KMessageBox::error( this, i18n( "The GpgSM process that tried to import the CRL file ended prematurely because of an unexpected error." ), i18n( "Certificate Manager Error" ) ); else if ( mDirmngrProc->exitStatus() ) - KMessageBox::error( this, i18n( "An error occurred when trying to import the CRL file. The output from GpgSM was:\n%1").arg( mErrorbuffer ), i18n( "Certificate Manager Error" ) ); + KMessageBox::error( this, i18n( "An error occurred when trying to import the CRL file. The output from GpgSM was:\n%1").tqarg( mErrorbuffer ), i18n( "Certificate Manager Error" ) ); else KMessageBox::information( this, i18n( "CRL file imported successfully." ), i18n( "Certificate Manager Information" ) ); @@ -935,7 +935,7 @@ bool CertManager::connectAndStartDirmngr( const char * slot, const char * proces this, TQT_SLOT(slotStderr(KProcess*,char*,int)) ); if( !mDirmngrProc->start( KProcess::NotifyOnExit, KProcess::Stderr ) ) { delete mDirmngrProc; mDirmngrProc = 0; - KMessageBox::error( this, i18n( "Unable to start %1 process. Please check your installation." ).arg( processname ), i18n( "Certificate Manager Error" ) ); + KMessageBox::error( this, i18n( "Unable to start %1 process. Please check your installation." ).tqarg( processname ), i18n( "Certificate Manager Error" ) ); return false; } return true; @@ -992,7 +992,7 @@ void CertManager::slotClearCRLsResult() { if ( !mDirmngrProc->normalExit() ) KMessageBox::error( this, i18n( "The DirMngr process that tried to clear the CRL cache ended prematurely because of an unexpected error." ), i18n( "Certificate Manager Error" ) ); else if ( mDirmngrProc->exitStatus() ) - KMessageBox::error( this, i18n( "An error occurred when trying to clear the CRL cache. The output from DirMngr was:\n%1").arg( mErrorbuffer ), i18n( "Certificate Manager Error" ) ); + KMessageBox::error( this, i18n( "An error occurred when trying to clear the CRL cache. The output from DirMngr was:\n%1").tqarg( mErrorbuffer ), i18n( "Certificate Manager Error" ) ); else KMessageBox::information( this, i18n( "CRL cache cleared successfully." ), i18n( "Certificate Manager Information" ) ); delete mDirmngrProc; mDirmngrProc = 0; @@ -1003,7 +1003,7 @@ static void showDeleteError( TQWidget * tqparent, const GpgME::Error & err ) { const TQString msg = i18n("<qt><p>An error occurred while trying to delete " "the certificates:</p>" "<p><b>%1</b></p></qt>") - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n("Certificate Deletion Failed") ); } @@ -1031,7 +1031,7 @@ void CertManager::slotDeleteCertificate() { return; if ( !mHierarchyAnalyser ) { - mHierarchyAnalyser = new HierarchyAnalyser( this, "mHierarchyAnalyser" ); + mHierarchyAnalyser = new HierarchyAnalyser( TQT_TQOBJECT(this), "mHierarchyAnalyser" ); Kleo::KeyListJob * job = Kleo::CryptoBackendFactory::instance()->smime()->keyListJob(); assert( job ); connect( job, TQT_SIGNAL(nextKey(const GpgME::Key&)), @@ -1076,7 +1076,7 @@ void CertManager::slotDeleteCertificate() { const TQString msg = keysToDelete.size() > keys.size() ? i18n("Do you really want to delete this certificate and the %1 certificates it certified?", "Do you really want to delete these %n certificates and the %1 certificates they certified?", - keys.size() ).arg( keysToDelete.size() - keys.size() ) + keys.size() ).tqarg( keysToDelete.size() - keys.size() ) : i18n("Do you really want to delete this certificate?", "Do you really want to delete these %n certificates?", keys.size() ) ; @@ -1098,7 +1098,7 @@ void CertManager::slotDeleteCertificate() { "the certificates:</p>" "<p><b>%1</b><p></qt>" ); KMessageBox::error( this, - str.arg( i18n("Operation not supported by the backend.") ), + str.tqarg( i18n("Operation not supported by the backend.") ), i18n("Certificate Deletion Failed") ); } @@ -1206,7 +1206,7 @@ static void showCertificateExportError( TQWidget * tqparent, const GpgME::Error const TQString msg = i18n("<qt><p>An error occurred while trying to export " "the certificate:</p>" "<p><b>%1</b></p></qt>") - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n("Certificate Export Failed") ); } @@ -1239,7 +1239,7 @@ static bool checkOverwrite( const KURL& url, bool& overwrite, TQWidget* w ) KMessageBox::warningContinueCancel( w, i18n( "A file named \"%1\" already exists. " - "Are you sure you want to overwrite it?" ).arg( url.prettyURL() ), + "Are you sure you want to overwrite it?" ).tqarg( url.prettyURL() ), i18n( "Overwrite File?" ), i18n( "&Overwrite" ) ) ) return false; @@ -1301,7 +1301,7 @@ static void showSecretKeyExportError( TQWidget * tqparent, const GpgME::Error & const TQString msg = i18n("<qt><p>An error occurred while trying to export " "the secret key:</p>" "<p><b>%1</b></p></qt>") - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n("Secret-Key Export Failed") ); } diff --git a/certmanager/conf/appearanceconfigwidgetbase.ui b/certmanager/conf/appearanceconfigwidgetbase.ui index 9fb7af203..0d059cf64 100644 --- a/certmanager/conf/appearanceconfigwidgetbase.ui +++ b/certmanager/conf/appearanceconfigwidgetbase.ui @@ -162,9 +162,9 @@ </connection> <connection> <sender>categoriesLV</sender> - <signal>selectionChanged(QListViewItem*)</signal> + <signal>selectionChanged(TQListViewItem*)</signal> <receiver>AppearanceConfigWidgetBase</receiver> - <slot>slotSelectionChanged(QListViewItem*)</slot> + <slot>slotSelectionChanged(TQListViewItem*)</slot> </connection> <connection> <sender>defaultLookPB</sender> @@ -205,7 +205,7 @@ <slot access="protected">slotForegroundClicked()</slot> <slot access="protected">slotBackgroundClicked()</slot> <slot access="protected">slotFontClicked()</slot> - <slot access="protected">slotSelectionChanged( QListViewItem * )</slot> + <slot access="protected">slotSelectionChanged( TQListViewItem * )</slot> <slot access="protected">slotDefaultClicked()</slot> <slot access="protected">slotItalicClicked()</slot> <slot access="protected">slotBoldClicked()</slot> diff --git a/certmanager/conf/dirservconfigpage.cpp b/certmanager/conf/dirservconfigpage.cpp index fb367fd32..9647f6b81 100644 --- a/certmanager/conf/dirservconfigpage.cpp +++ b/certmanager/conf/dirservconfigpage.cpp @@ -283,11 +283,11 @@ Kleo::CryptoConfigEntry* DirectoryServicesConfigurationPage::configEntry( const { Kleo::CryptoConfigEntry* entry = mConfig->entry( componentName, groupName, entryName ); if ( !entry ) { - KMessageBox::error( this, i18n( "Backend error: gpgconf does not seem to know the entry for %1/%2/%3" ).arg( componentName, groupName, entryName ) ); + KMessageBox::error( this, i18n( "Backend error: gpgconf does not seem to know the entry for %1/%2/%3" ).tqarg( componentName, groupName, entryName ) ); return 0; } if( entry->argType() != argType || entry->isList() != isList ) { - KMessageBox::error( this, i18n( "Backend error: gpgconf has wrong type for %1/%2/%3: %4 %5" ).arg( componentName, groupName, entryName ).arg( entry->argType() ).arg( entry->isList() ) ); + KMessageBox::error( this, i18n( "Backend error: gpgconf has wrong type for %1/%2/%3: %4 %5" ).tqarg( componentName, groupName, entryName ).tqarg( entry->argType() ).tqarg( entry->isList() ) ); return 0; } return entry; diff --git a/certmanager/hierarchyanalyser.cpp b/certmanager/hierarchyanalyser.cpp index 96979adf4..39322abce 100644 --- a/certmanager/hierarchyanalyser.cpp +++ b/certmanager/hierarchyanalyser.cpp @@ -63,7 +63,7 @@ void HierarchyAnalyser::slotNextKey( const GpgME::Key & key ) { const std::vector<GpgME::Key> & HierarchyAnalyser::subjectsForIssuer( const char * issuer_dn ) const { static const std::vector<GpgME::Key> empty; std::map< TQCString, std::vector<GpgME::Key> >::const_iterator it = - mSubjectsByIssuer.tqfind( issuer_dn ); + mSubjectsByIssuer.find( issuer_dn ); return it == mSubjectsByIssuer.end() ? empty : it->second ; } diff --git a/certmanager/kwatchgnupg/kwatchgnupgmainwin.cpp b/certmanager/kwatchgnupg/kwatchgnupgmainwin.cpp index 01340ecd2..4c6ecbfb5 100644 --- a/certmanager/kwatchgnupg/kwatchgnupgmainwin.cpp +++ b/certmanager/kwatchgnupg/kwatchgnupgmainwin.cpp @@ -90,20 +90,20 @@ KWatchGnuPGMainWindow::~KWatchGnuPGMainWindow() void KWatchGnuPGMainWindow::slotClear() { mCentralWidget->clear(); - mCentralWidget->append( tr("[%1] Log cleared").arg( TQDateTime::tqcurrentDateTime().toString(TQt::ISODate) ) ); + mCentralWidget->append( tqtr("[%1] Log cleared").tqarg( TQDateTime::tqcurrentDateTime().toString(Qt::ISODate) ) ); } void KWatchGnuPGMainWindow::createActions() { (void)new KAction( i18n("C&lear History"), "history_clear", CTRL+Key_L, - this, TQT_SLOT( slotClear() ), + TQT_TQOBJECT(this), TQT_SLOT( slotClear() ), actionCollection(), "clear_log" ); - (void)KStdAction::saveAs( this, TQT_SLOT(slotSaveAs()), actionCollection() ); - (void)KStdAction::close( this, TQT_SLOT(close()), actionCollection() ); - (void)KStdAction::quit( this, TQT_SLOT(slotQuit()), actionCollection() ); - (void)KStdAction::preferences( this, TQT_SLOT(slotConfigure()), actionCollection() ); - ( void )KStdAction::keyBindings(this, TQT_SLOT(configureShortcuts()), actionCollection()); - ( void )KStdAction::configureToolbars(this, TQT_SLOT(slotConfigureToolbars()), actionCollection()); + (void)KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT(slotSaveAs()), actionCollection() ); + (void)KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection() ); + (void)KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), actionCollection() ); + (void)KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT(slotConfigure()), actionCollection() ); + (void)KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(configureShortcuts()), actionCollection()); + (void)KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotConfigureToolbars()), actionCollection()); #if 0 (void)new KAction( i18n("Configure KWatchGnuPG..."), TQString::tqfromLatin1("configure"), @@ -134,8 +134,8 @@ void KWatchGnuPGMainWindow::startWatcher() while( mWatcher->isRunning() ) { kapp->eventLoop()->processEvents(TQEventLoop::ExcludeUserInput); } - mCentralWidget->append(tr("[%1] Log stopped") - .arg( TQDateTime::tqcurrentDateTime().toString(TQt::ISODate))); + mCentralWidget->append(tqtr("[%1] Log stopped") + .tqarg( TQDateTime::tqcurrentDateTime().toString(Qt::ISODate))); } mWatcher->clearArguments(); KConfig* config = kapp->config(); @@ -147,8 +147,8 @@ void KWatchGnuPGMainWindow::startWatcher() if( !mWatcher->start() ) { KMessageBox::sorry( this, i18n("The watchgnupg logging process could not be started.\nPlease install watchgnupg somewhere in your $PATH.\nThis log window is now completely useless." ) ); } else { - mCentralWidget->append( tr("[%1] Log started") - .arg( TQDateTime::tqcurrentDateTime().toString(TQt::ISODate) ) ); + mCentralWidget->append( tqtr("[%1] Log started") + .tqarg( TQDateTime::tqcurrentDateTime().toString(Qt::ISODate) ) ); } connect( mWatcher, TQT_SIGNAL( processExited(KProcess*) ), this, TQT_SLOT( slotWatcherExited() ) ); @@ -176,7 +176,7 @@ void KWatchGnuPGMainWindow::setGnuPGConfig() entry->setStringValue( TQString("socket://")+ config->readEntry("Socket", WATCHGNUPGSOCKET )); - logclients << TQString("%1 (%2)").arg(*it).arg(comp->description()); + logclients << TQString("%1 (%2)").tqarg(*it).tqarg(comp->description()); } entry = group->entry("debug-level"); if( entry ) { @@ -237,7 +237,7 @@ void KWatchGnuPGMainWindow::slotSaveAs() if( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("The file named \"%1\" already " "exists. Are you sure you want " - "to overwrite it?").arg(filename), + "to overwrite it?").tqarg(filename), i18n("Overwrite File"), i18n("Overwrite"), KStdGuiItem::cancel() ) ) { return; } diff --git a/certmanager/lib/backends/chiasmus/chiasmusbackend.cpp b/certmanager/lib/backends/chiasmus/chiasmusbackend.cpp index 5ce7f617f..f27dad3b6 100644 --- a/certmanager/lib/backends/chiasmus/chiasmusbackend.cpp +++ b/certmanager/lib/backends/chiasmus/chiasmusbackend.cpp @@ -432,13 +432,13 @@ Kleo::CryptoBackend::Protocol * Kleo::ChiasmusBackend::protocol( const char * na bool Kleo::ChiasmusBackend::checkForOpenPGP( TQString * reason ) const { if ( reason ) - *reason = i18n( "Unsupported protocol \"%1\"" ).arg( "OpenPGP" ); + *reason = i18n( "Unsupported protocol \"%1\"" ).tqarg( "OpenPGP" ); return false; } bool Kleo::ChiasmusBackend::checkForSMIME( TQString * reason ) const { if ( reason ) - *reason = i18n( "Unsupported protocol \"%1\"" ).arg( "SMIME" ); + *reason = i18n( "Unsupported protocol \"%1\"" ).tqarg( "SMIME" ); return false; } @@ -454,7 +454,7 @@ bool Kleo::ChiasmusBackend::checkForChiasmus( TQString * reason ) const { const TQFileInfo fi( KShell::tildeExpand( chiasmus ) ); if ( !fi.isExecutable() ) { if ( reason ) - *reason = i18n( "File \"%1\" does not exist or is not executable." ).arg( chiasmus ); + *reason = i18n( "File \"%1\" does not exist or is not executable." ).tqarg( chiasmus ); return false; } @@ -467,7 +467,7 @@ bool Kleo::ChiasmusBackend::checkForProtocol( const char * name, TQString * reas if ( qstricmp( name, "Chiasmus" ) == 0 ) return checkForChiasmus( reason ); if ( reason ) - *reason = i18n( "Unsupported protocol \"%1\"" ).arg( name ); + *reason = i18n( "Unsupported protocol \"%1\"" ).tqarg( name ); return 0; } diff --git a/certmanager/lib/backends/chiasmus/chiasmusjob.cpp b/certmanager/lib/backends/chiasmus/chiasmusjob.cpp index c6b718ca8..eb5a5ea38 100644 --- a/certmanager/lib/backends/chiasmus/chiasmusjob.cpp +++ b/certmanager/lib/backends/chiasmus/chiasmusjob.cpp @@ -208,9 +208,9 @@ void Kleo::ChiasmusJob::showErrorDialog( TQWidget * tqparent, const TQString & c const TQString msg = ( mMode == Encrypt ? i18n( "Encryption failed: %1" ) : i18n( "Decryption failed: %1" ) ) - .arg( TQString::fromLocal8Bit( mError.asString() ) ); + .tqarg( TQString::fromLocal8Bit( mError.asString() ) ); if ( !mStderr.isEmpty() ) { - const TQString details = i18n( "The following was received on stderr:\n%1" ).arg( mStderr ); + const TQString details = i18n( "The following was received on stderr:\n%1" ).tqarg( mStderr ); KMessageBox::detailedError( tqparent, msg, details, caption ); } else { KMessageBox::error( tqparent, msg, caption ); diff --git a/certmanager/lib/backends/chiasmus/chiasmuslibrary.cpp b/certmanager/lib/backends/chiasmus/chiasmuslibrary.cpp index 002bf0182..a57685f28 100644 --- a/certmanager/lib/backends/chiasmus/chiasmuslibrary.cpp +++ b/certmanager/lib/backends/chiasmus/chiasmuslibrary.cpp @@ -71,7 +71,7 @@ Kleo::ChiasmusLibrary::main_func Kleo::ChiasmusLibrary::chiasmus( TQString * rea if ( !mXiaLibrary ) { if ( reason ) *reason = i18n( "Failed to load %1: %2" ) - .arg( libfile,KLibLoader::self()->lastErrorMessage() ); + .tqarg( libfile,KLibLoader::self()->lastErrorMessage() ); kdDebug(5150) << "ChiasmusLibrary: loading \"" << libfile << "\" failed: " << KLibLoader::self()->lastErrorMessage() << endl; return 0; @@ -79,7 +79,7 @@ Kleo::ChiasmusLibrary::main_func Kleo::ChiasmusLibrary::chiasmus( TQString * rea if ( !mXiaLibrary->hasSymbol( "Chiasmus" ) ) { if ( reason ) *reason = i18n( "Failed to load %1: %2" ) - .arg( libfile, i18n( "Library does not contain the symbol \"Chiasmus\"." ) ); + .tqarg( libfile, i18n( "Library does not contain the symbol \"Chiasmus\"." ) ); kdDebug(5150) << "ChiasmusLibrary: loading \"" << libfile << "\" failed: " << "Library does not contain the symbol \"Chiasmus\"." << endl; return 0; diff --git a/certmanager/lib/backends/chiasmus/obtainkeysjob.cpp b/certmanager/lib/backends/chiasmus/obtainkeysjob.cpp index fe0b19b1e..497a5a54d 100644 --- a/certmanager/lib/backends/chiasmus/obtainkeysjob.cpp +++ b/certmanager/lib/backends/chiasmus/obtainkeysjob.cpp @@ -96,7 +96,7 @@ void Kleo::ObtainKeysJob::slotPerform( bool async ) { return; } - emit progress( i18n( "Scanning directory %1..." ).arg( mKeyPaths[mIndex] ), + emit progress( i18n( "Scanning directory %1..." ).tqarg( mKeyPaths[mIndex] ), mIndex, mKeyPaths.size() ); const TQDir dir( KShell::tildeExpand( mKeyPaths[mIndex] ) ); diff --git a/certmanager/lib/backends/qgpgme/qgpgmebackend.cpp b/certmanager/lib/backends/qgpgme/qgpgmebackend.cpp index 27680585b..9594edfa2 100644 --- a/certmanager/lib/backends/qgpgme/qgpgmebackend.cpp +++ b/certmanager/lib/backends/qgpgme/qgpgmebackend.cpp @@ -88,15 +88,15 @@ static bool check( GpgME::Context::Protocol proto, TQString * reason ) { // error, check why: const GpgME::EngineInfo ei = GpgME::engineInfo( proto ); if ( ei.isNull() ) - *reason = i18n("GPGME was compiled without support for %1.").arg( proto == GpgME::Context::CMS ? "S/MIME" : "OpenPGP" ); + *reason = i18n("GPGME was compiled without support for %1.").tqarg( proto == GpgME::Context::CMS ? "S/MIME" : "OpenPGP" ); else if ( ei.fileName() && !ei.version() ) - *reason = i18n("Engine %1 is not installed properly.").arg( TQFile::decodeName( ei.fileName() ) ); + *reason = i18n("Engine %1 is not installed properly.").tqarg( TQFile::decodeName( ei.fileName() ) ); else if ( ei.fileName() && ei.version() && ei.requiredVersion() ) *reason = i18n("Engine %1 version %2 installed, " "but at least version %3 is required.") - .arg( TQFile::decodeName( ei.fileName() ), ei.version(), ei.requiredVersion() ); + .tqarg( TQFile::decodeName( ei.fileName() ), ei.version(), ei.requiredVersion() ); else - *reason = i18n("Unknown problem with engine for protocol %1.").arg( proto == GpgME::Context::CMS ? "S/MIME" : "OpenPGP" ); + *reason = i18n("Unknown problem with engine for protocol %1.").tqarg( proto == GpgME::Context::CMS ? "S/MIME" : "OpenPGP" ); return false; } @@ -114,7 +114,7 @@ bool Kleo::QGpgMEBackend::checkForProtocol( const char * name, TQString * reason if ( qstricmp( name, SMIME ) == 0 ) return check( GpgME::Context::CMS, reason ); if ( reason ) - *reason = i18n( "Unsupported protocol \"%1\"" ).arg( name ); + *reason = i18n( "Unsupported protocol \"%1\"" ).tqarg( name ); return false; } diff --git a/certmanager/lib/backends/qgpgme/qgpgmecryptoconfig.cpp b/certmanager/lib/backends/qgpgme/qgpgmecryptoconfig.cpp index 3aa3b336b..312246851 100644 --- a/certmanager/lib/backends/qgpgme/qgpgmecryptoconfig.cpp +++ b/certmanager/lib/backends/qgpgme/qgpgmecryptoconfig.cpp @@ -89,11 +89,11 @@ void QGpgMECryptoConfig::runGpgConf( bool showErrors ) if ( showErrors && rc != 0 ) { TQString wmsg = i18n("<qt>Failed to execute gpgconf:<br>%1</qt>"); if ( rc == -1 ) - wmsg = wmsg.arg( i18n( "program not found" ) ); + wmsg = wmsg.tqarg( i18n( "program not found" ) ); else if ( rc == -2 ) - wmsg = wmsg.arg( i18n( "program cannot be executed" ) ); + wmsg = wmsg.tqarg( i18n( "program cannot be executed" ) ); else - wmsg = wmsg.arg( strerror(rc) ); + wmsg = wmsg.tqarg( strerror(rc) ); kdWarning(5150) << wmsg << endl; // to see it from test_cryptoconfig.cpp KMessageBox::error(0, wmsg); } @@ -306,7 +306,7 @@ void QGpgMECryptoConfigComponent::sync( bool runtime ) } else if( rc != 0 ) // Happens due to bugs in gpgconf (e.g. issues 104/115) { - TQString wmsg = i18n( "Error from gpgconf while saving configuration: %1" ).arg( TQString::fromLocal8Bit( strerror( rc ) ) ); + TQString wmsg = i18n( "Error from gpgconf while saving configuration: %1" ).tqarg( TQString::fromLocal8Bit( strerror( rc ) ) ); kdWarning(5150) << k_funcinfo << ":" << strerror( rc ) << endl; KMessageBox::error(0, wmsg); } diff --git a/certmanager/lib/backends/qgpgme/qgpgmejob.cpp b/certmanager/lib/backends/qgpgme/qgpgmejob.cpp index 61da793ed..e55f237dc 100644 --- a/certmanager/lib/backends/qgpgme/qgpgmejob.cpp +++ b/certmanager/lib/backends/qgpgme/qgpgmejob.cpp @@ -276,21 +276,21 @@ char * Kleo::QGpgMEJob::getPassphrase( const char * useridHint, const char * /*d TQString msg = previousWasBad ? i18n( "You need a passphrase to unlock the secret key for user:<br/> %1 (retry)" ) : i18n( "You need a passphrase to unlock the secret key for user:<br/> %1" ); - msg = msg.arg( TQString::fromUtf8( useridHint ) ) + "<br/><br/>"; + msg = msg.tqarg( TQString::fromUtf8( useridHint ) ) + "<br/><br/>"; msg.prepend( "<qt>" ); msg += i18n( "This dialog will reappear every time the passphrase is needed. For a more secure solution that also allows caching the passphrase, use gpg-agent." ) + "<br/>"; const TQString gpgAgent = KStandardDirs::findExe( "gpg-agent" ); if ( !gpgAgent.isEmpty() ) { msg += i18n( "gpg-agent was found in %1, but does not appear to be running." ) - .arg( gpgAgent ); + .tqarg( gpgAgent ); } else { msg += i18n( "gpg-agent is part of gnupg-%1, which you can download from %2" ) - .arg( "1.9" ) - .arg( "http://www.gnupg.org/download" ); // add #gnupg2 if you can make this a real link + .tqarg( "1.9" ) + .tqarg( "http://www.gnupg.org/download" ); // add #gnupg2 if you can make this a real link } msg += "<br/>"; msg += i18n( "For information on how to set up gpg-agent, see %1" ) - .arg( "http://kmail.kde.org/kmail-pgpmime-howto.html" ); + .tqarg( "http://kmail.kde.org/kmail-pgpmime-howto.html" ); msg += "<br/><br/>"; msg += i18n( "Enter passphrase:" ); Kleo::PassphraseDialog dlg( msg, i18n("Passphrase Dialog") ); diff --git a/certmanager/lib/backends/qgpgme/qgpgmekeylistjob.cpp b/certmanager/lib/backends/qgpgme/qgpgmekeylistjob.cpp index 2634579f2..57afed412 100644 --- a/certmanager/lib/backends/qgpgme/qgpgmekeylistjob.cpp +++ b/certmanager/lib/backends/qgpgme/qgpgmekeylistjob.cpp @@ -196,7 +196,7 @@ void Kleo::QGpgMEKeyListJob::showErrorDialog( TQWidget * tqparent, const TQStrin const TQString msg = i18n( "<qt><p>An error occurred while fetching " "the keys from the backend:</p>" "<p><b>%1</b></p></qt>" ) - .arg( TQString::fromLocal8Bit( mResult.error().asString() ) ); + .tqarg( TQString::fromLocal8Bit( mResult.error().asString() ) ); KMessageBox::error( tqparent, msg, caption ); } diff --git a/certmanager/lib/backends/qgpgme/qgpgmeprogresstokenmapper.cpp b/certmanager/lib/backends/qgpgme/qgpgmeprogresstokenmapper.cpp index 5f6296781..de673faf1 100644 --- a/certmanager/lib/backends/qgpgme/qgpgmeprogresstokenmapper.cpp +++ b/certmanager/lib/backends/qgpgme/qgpgmeprogresstokenmapper.cpp @@ -140,20 +140,20 @@ TQString Kleo::QGpgMEProgressTokenMapper::map( const TQString & token, int subto static const Map & tokenMap = makeMap(); - const Map::const_iterator it1 = tokenMap.tqfind( token.lower() ); + const Map::const_iterator it1 = tokenMap.find( token.lower() ); if ( it1 == tokenMap.end() ) return token; - std::map<int,Desc>::const_iterator it2 = it1->second.tqfind( subtoken ); + std::map<int,Desc>::const_iterator it2 = it1->second.find( subtoken ); if ( it2 == it1->second.end() ) - it2 = it1->second.tqfind( 0 ); + it2 = it1->second.find( 0 ); if ( it2 == it1->second.end() ) return token; const Desc & desc = it2->second; TQString result = i18n( desc.display ); if ( desc.useCur ) - result = result.arg( cur ); + result = result.tqarg( cur ); if ( desc.useTot ) - result = result.arg( tot ); + result = result.tqarg( tot ); return result; } diff --git a/certmanager/lib/cryptplugwrapper.cpp b/certmanager/lib/cryptplugwrapper.cpp index f15ab747d..1d35f1c1b 100644 --- a/certmanager/lib/cryptplugwrapper.cpp +++ b/certmanager/lib/cryptplugwrapper.cpp @@ -522,7 +522,7 @@ bool CryptPlugWrapper::initialize( InitqStatus* initqStatus, TQString* errorMsg if( !_cp->initialize() ) { _initqStatus = IniStatus_InitError; kdDebug(5150) << "Error while executing function 'initialize' on plugin " << _libName << endl; - _lastError = i18n("Error while initializing plugin \"%1\"").arg( _libName ); + _lastError = i18n("Error while initializing plugin \"%1\"").tqarg( _libName ); if ( errorMsg ) *errorMsg = _lastError; delete _cp; _cp = 0; diff --git a/certmanager/lib/kleo/cryptobackendfactory.cpp b/certmanager/lib/kleo/cryptobackendfactory.cpp index c6ce40fd8..f4db77ea3 100644 --- a/certmanager/lib/kleo/cryptobackendfactory.cpp +++ b/certmanager/lib/kleo/cryptobackendfactory.cpp @@ -111,7 +111,7 @@ Kleo::CryptoBackendFactory * Kleo::CryptoBackendFactory::instance() { // } const Kleo::CryptoBackend::Protocol * Kleo::CryptoBackendFactory::smime() const { - const BackendMap::const_iterator it = mBackends.tqfind( "SMIME" ); + const BackendMap::const_iterator it = mBackends.find( "SMIME" ); if ( it == mBackends.end() ) return 0; if ( !it->second ) @@ -120,7 +120,7 @@ const Kleo::CryptoBackend::Protocol * Kleo::CryptoBackendFactory::smime() const } const Kleo::CryptoBackend::Protocol * Kleo::CryptoBackendFactory::openpgp() const { - const BackendMap::const_iterator it = mBackends.tqfind( "OpenPGP" ); + const BackendMap::const_iterator it = mBackends.find( "OpenPGP" ); if ( it == mBackends.end() ) return 0; if ( !it->second ) @@ -129,7 +129,7 @@ const Kleo::CryptoBackend::Protocol * Kleo::CryptoBackendFactory::openpgp() cons } const Kleo::CryptoBackend::Protocol * Kleo::CryptoBackendFactory::protocol( const char * name ) const { - const BackendMap::const_iterator it = mBackends.tqfind( name ); + const BackendMap::const_iterator it = mBackends.find( name ); if ( it == mBackends.end() ) return 0; if ( !it->second ) @@ -154,7 +154,7 @@ void Kleo::CryptoBackendFactory::scanForBackends( TQStringList * reasons ) { if ( (*it)->supportsProtocol( protocol ) && !(*it)->checkForProtocol( protocol, &reason ) ) { if ( reasons ) { reasons->push_back( i18n("While scanning for %1 support in backend %2:") - .arg( protocol, (*it)->displayName() ) ); + .tqarg( protocol, (*it)->displayName() ) ); reasons->push_back( " " + reason ); } } @@ -267,7 +267,7 @@ namespace { } bool Kleo::CryptoBackendFactory::knowsAboutProtocol( const char * name ) const { - return std::tqfind( mAvailableProtocols.begin(), mAvailableProtocols.end(), + return std::find( mAvailableProtocols.begin(), mAvailableProtocols.end(), CaseInsensitiveString( name ) ) != mAvailableProtocols.end(); } diff --git a/certmanager/lib/kleo/dn.cpp b/certmanager/lib/kleo/dn.cpp index e82b02dee..0f0c357d2 100644 --- a/certmanager/lib/kleo/dn.cpp +++ b/certmanager/lib/kleo/dn.cpp @@ -507,7 +507,7 @@ const Kleo::DNAttributeMapper * Kleo::DNAttributeMapper::instance() { TQString Kleo::DNAttributeMapper::name2label( const TQString & s ) const { const std::map<const char*,const char*,ltstr>::const_iterator it - = d->map.tqfind( s.stripWhiteSpace().upper().latin1() ); + = d->map.find( s.stripWhiteSpace().upper().latin1() ); if ( it == d->map.end() ) return TQString(); return i18n( it->second ); diff --git a/certmanager/lib/kleo/hierarchicalkeylistjob.cpp b/certmanager/lib/kleo/hierarchicalkeylistjob.cpp index e94f97005..a5944315a 100644 --- a/certmanager/lib/kleo/hierarchicalkeylistjob.cpp +++ b/certmanager/lib/kleo/hierarchicalkeylistjob.cpp @@ -93,7 +93,7 @@ void Kleo::HierarchicalKeyListJob::slotNextKey( const GpgME::Key & key ) { if ( const char * chain_id = key.chainID() ) mNextSet.insert( chain_id ); if ( const char * fpr = key.primaryFingerprint() ) - if ( mSentSet.tqfind( fpr ) == mSentSet.end() ) { + if ( mSentSet.find( fpr ) == mSentSet.end() ) { mSentSet.insert( fpr ); emit nextKey( key ); } @@ -131,7 +131,7 @@ void Kleo::HierarchicalKeyListJob::slotResult( const GpgME::KeyListResult & res #if 0 // FIXME const int current = mIt - mKeys.begin(); const int total = mKeys.size(); - emit progress( i18n("progress info: \"%1 of %2\"","%1/%2").arg( current ).arg( total ), current, total ); + emit progress( i18n("progress info: \"%1 of %2\"","%1/%2").tqarg( current ).tqarg( total ), current, total ); #endif } diff --git a/certmanager/lib/kleo/multideletejob.cpp b/certmanager/lib/kleo/multideletejob.cpp index 7d1a27302..e83f923ee 100644 --- a/certmanager/lib/kleo/multideletejob.cpp +++ b/certmanager/lib/kleo/multideletejob.cpp @@ -92,7 +92,7 @@ void Kleo::MultiDeleteJob::slotResult( const GpgME::Error & err ) { const int current = mIt - mKeys.begin(); const int total = mKeys.size(); - emit progress( i18n("progress info: \"%1 of %2\"","%1/%2").arg( current ).arg( total ), current, total ); + emit progress( i18n("progress info: \"%1 of %2\"","%1/%2").tqarg( current ).tqarg( total ), current, total ); } GpgME::Error Kleo::MultiDeleteJob::startAJob() { diff --git a/certmanager/lib/tests/test_keygen.cpp b/certmanager/lib/tests/test_keygen.cpp index 090c3f3ae..b95ad74bd 100644 --- a/certmanager/lib/tests/test_keygen.cpp +++ b/certmanager/lib/tests/test_keygen.cpp @@ -137,7 +137,7 @@ void KeyGenerator::slotResult( const GpgME::KeyGenerationResult & res, const TQB if ( res.error() ) showError( res.error() ); else - KMessageBox::information( this, TQString("Key generated successfully, %1 bytes long").arg( keyData.size() ), + KMessageBox::information( this, TQString("Key generated successfully, %1 bytes long").tqarg( keyData.size() ), "Key Generation Finished" ); } diff --git a/certmanager/lib/tests/test_keylister.cpp b/certmanager/lib/tests/test_keylister.cpp index 212d0228f..6667b2e7c 100644 --- a/certmanager/lib/tests/test_keylister.cpp +++ b/certmanager/lib/tests/test_keylister.cpp @@ -104,7 +104,7 @@ void CertListView::slotResult( const GpgME::KeyListResult & result ) { TQMessageBox::information( this, "Key Listing Result", "KeyListResult is null!" ); else if ( result.error() ) TQMessageBox::critical( this, "Key Listing Result", - TQString("KeyListResult Error: %1").arg( result.error().asString() ) ); + TQString("KeyListResult Error: %1").tqarg( result.error().asString() ) ); else if ( result.isTruncated() ) TQMessageBox::information( this, "Key Listing Result", "KeyListResult is truncated!" ); else diff --git a/certmanager/lib/ui/adddirectoryservicedialogimpl.cpp b/certmanager/lib/ui/adddirectoryservicedialogimpl.cpp index a6210cabe..a8d48a007 100644 --- a/certmanager/lib/ui/adddirectoryservicedialogimpl.cpp +++ b/certmanager/lib/ui/adddirectoryservicedialogimpl.cpp @@ -49,7 +49,7 @@ AddDirectoryServiceDialogImpl::AddDirectoryServiceDialogImpl( TQWidget* tqparent, const char* name, bool modal, WFlags fl ) : AddDirectoryServiceDialog( tqparent, name, modal, fl ) { - portED->setValidator( new TQIntValidator( 0, 65535, portED ) ); + portED->setValidator( new TQIntValidator( 0, 65535, TQT_TQOBJECT(portED) ) ); } /* diff --git a/certmanager/lib/ui/backendconfigwidget.cpp b/certmanager/lib/ui/backendconfigwidget.cpp index b1a135a9f..d257cc6a8 100644 --- a/certmanager/lib/ui/backendconfigwidget.cpp +++ b/certmanager/lib/ui/backendconfigwidget.cpp @@ -150,7 +150,7 @@ private: // second one is implementation name (gpg, gpgsm...) const TQString impName = protocol ? protocol->displayName() : i18n( "failed" ); return i18n( "Items in Kleo::BackendConfigWidget listview (1: protocol; 2: implementation name)", - "%1 (%2)" ).arg( protoName, impName ); + "%1 (%2)" ).tqarg( protoName, impName ); } const CryptoBackend::Protocol* mProtocol; // can be 0 diff --git a/certmanager/lib/ui/cryptoconfigmodule.cpp b/certmanager/lib/ui/cryptoconfigmodule.cpp index dd92b1604..c5ed43b1c 100644 --- a/certmanager/lib/ui/cryptoconfigmodule.cpp +++ b/certmanager/lib/ui/cryptoconfigmodule.cpp @@ -124,7 +124,7 @@ Kleo::CryptoConfigModule::CryptoConfigModule( Kleo::CryptoConfig* config, TQWidg dialogHeight = 400; TQSize sz = scrollView->tqsizeHint(); scrollView->setMinimumSize( sz.width() - + scrollView->style().tqpixelMetric(TQStyle::PM_ScrollBarExtent), + + scrollView->tqstyle().tqpixelMetric(TQStyle::PM_ScrollBarExtent), TQMIN( compGUI->tqsizeHint().height(), dialogHeight ) ); } if ( mComponentGUIs.empty() ) { @@ -134,7 +134,7 @@ Kleo::CryptoConfigModule::CryptoConfigModule( Kleo::CryptoConfig* config, TQWidg "properly. It did not return any components. " "Try running \"%1\" on the command line for more " "information.") - .arg( components.empty() ? "gpgconf --list-components" : "gpgconf --list-options gpg" ); + .tqarg( components.empty() ? "gpgconf --list-components" : "gpgconf --list-options gpg" ); TQLabel * label = new TQLabel( msg, vbox ); label->tqsetAlignment( TQt::WordBreak ); label->setMinimumHeight( fontMetrics().lineSpacing() * 5 ); @@ -356,7 +356,7 @@ TQString Kleo::CryptoConfigEntryGUI::description() const { TQString descr = mEntry->description(); if ( descr.isEmpty() ) // shouldn't happen - descr = TQString( "<%1>" ).arg( mName ); + descr = TQString( "<%1>" ).tqarg( mName ); return descr; } diff --git a/certmanager/lib/ui/directoryserviceswidgetbase.ui b/certmanager/lib/ui/directoryserviceswidgetbase.ui index 9ecc87f1b..e35e2bb26 100644 --- a/certmanager/lib/ui/directoryserviceswidgetbase.ui +++ b/certmanager/lib/ui/directoryserviceswidgetbase.ui @@ -295,21 +295,21 @@ By clicking this button, you can remove the currently selected directory service </connection> <connection> <sender>x500LV</sender> - <signal>returnPressed(QListViewItem*)</signal> + <signal>returnPressed(TQListViewItem*)</signal> <receiver>DirectoryServicesWidgetBase</receiver> - <slot>slotServiceSelected(QListViewItem*)</slot> + <slot>slotServiceSelected(TQListViewItem*)</slot> </connection> <connection> <sender>x500LV</sender> - <signal>doubleClicked(QListViewItem*)</signal> + <signal>doubleClicked(TQListViewItem*)</signal> <receiver>DirectoryServicesWidgetBase</receiver> - <slot>slotServiceSelected(QListViewItem*)</slot> + <slot>slotServiceSelected(TQListViewItem*)</slot> </connection> <connection> <sender>x500LV</sender> - <signal>selectionChanged(QListViewItem*)</signal> + <signal>selectionChanged(TQListViewItem*)</signal> <receiver>DirectoryServicesWidgetBase</receiver> - <slot>slotServiceChanged(QListViewItem*)</slot> + <slot>slotServiceChanged(TQListViewItem*)</slot> </connection> <connection> <sender>addServicePB</sender> @@ -333,8 +333,8 @@ By clicking this button, you can remove the currently selected directory service <Q_SLOTS> <slot access="protected">slotAddService()</slot> <slot access="protected">slotDeleteService()</slot> - <slot access="protected">slotServiceChanged( QListViewItem* )</slot> - <slot access="protected">slotServiceSelected( QListViewItem* )</slot> + <slot access="protected">slotServiceChanged( TQListViewItem* )</slot> + <slot access="protected">slotServiceSelected( TQListViewItem* )</slot> <slot access="protected">slotMoveUp()</slot> <slot access="protected">slotMoveDown()</slot> </Q_SLOTS> diff --git a/certmanager/lib/ui/kdhorizontalline.cpp b/certmanager/lib/ui/kdhorizontalline.cpp index 4f212517f..ee809df77 100644 --- a/certmanager/lib/ui/kdhorizontalline.cpp +++ b/certmanager/lib/ui/kdhorizontalline.cpp @@ -97,7 +97,7 @@ void KDHorizontalLine::calculateFrame() { qDebug( "mLenVisible = %d (of %d)", mLenVisible, mTitle.length() ); if ( mLenVisible ) { // but do we also have a visible label? TQRect r = rect(); - const int va = style().tqstyleHint( TQStyle::SH_GroupBox_TextLabelVerticalAlignment, this ); + const int va = tqstyle().tqstyleHint( TQStyle::SH_GroupBox_TextLabelVerticalAlignment, this ); if( va & AlignVCenter ) r.setTop( fm.height() / 2 ); // frame rect should be else if( va & AlignTop ) @@ -147,13 +147,13 @@ void KDHorizontalLine::paintEvent( TQPaintEvent * e ) { x = 0; } TQRect r( x, 0, tw, h ); - int va = style().tqstyleHint( TQStyle::SH_GroupBox_TextLabelVerticalAlignment, this ); + int va = tqstyle().tqstyleHint( TQStyle::SH_GroupBox_TextLabelVerticalAlignment, this ); if ( va & AlignTop ) r.moveBy( 0, fm.descent() ); - const TQColor pen( (TQRgb) style().tqstyleHint( TQStyle::SH_GroupBox_TextLabelColor, this ) ); - if ( !style().tqstyleHint( TQStyle::SH_UnderlineAccelerator, this ) ) + const TQColor pen( (TQRgb) tqstyle().tqstyleHint( TQStyle::SH_GroupBox_TextLabelColor, this ) ); + if ( !tqstyle().tqstyleHint( TQStyle::SH_UnderlineAccelerator, this ) ) va |= NoAccel; - style().drawItem( &paint, r, ShowPrefix | AlignHCenter | va, tqcolorGroup(), + tqstyle().drawItem( &paint, r, ShowPrefix | AlignHCenter | va, tqcolorGroup(), isEnabled(), 0, mTitle, -1, ownPalette() ? 0 : &pen ); paint.setClipRegion( e->region().subtract( r ) ); // clip everything but title } diff --git a/certmanager/lib/ui/keyapprovaldialog.cpp b/certmanager/lib/ui/keyapprovaldialog.cpp index 5bdadfd0c..e81adc438 100644 --- a/certmanager/lib/ui/keyapprovaldialog.cpp +++ b/certmanager/lib/ui/keyapprovaldialog.cpp @@ -139,7 +139,7 @@ Kleo::KeyApprovalDialog::KeyApprovalDialog( const std::vector<Item> & recipients d->selfRequester->setKeys( sender ); glay->addWidget( d->selfRequester, row, 1 ); ++row; - glay->addMultiCellWidget( new KSeparator( Horizontal, view ), row, row, 0, 1 ); + glay->addMultiCellWidget( new KSeparator( Qt::Horizontal, view ), row, row, 0, 1 ); } const TQStringList prefs = preferencesStrings(); diff --git a/certmanager/lib/ui/keylistview.cpp b/certmanager/lib/ui/keylistview.cpp index 7519f7e81..f1641339d 100644 --- a/certmanager/lib/ui/keylistview.cpp +++ b/certmanager/lib/ui/keylistview.cpp @@ -261,7 +261,7 @@ void Kleo::KeyListView::deregisterItem( const KeyListViewItem * item ) { if ( !item ) return; std::map<TQCString,KeyListViewItem*>::iterator it - = d->itemMap.tqfind( item->key().primaryFingerprint() ); + = d->itemMap.find( item->key().primaryFingerprint() ); if ( it == d->itemMap.end() ) return; Q_ASSERT( it->second == item ); @@ -324,7 +324,7 @@ void Kleo::KeyListView::scatterGathered( TQListViewItem * start ) { Kleo::KeyListViewItem * Kleo::KeyListView::itemByFingerprint( const TQCString & s ) const { if ( s.isEmpty() ) return 0; - const std::map<TQCString,KeyListViewItem*>::const_iterator it = d->itemMap.tqfind( s ); + const std::map<TQCString,KeyListViewItem*>::const_iterator it = d->itemMap.find( s ); if ( it == d->itemMap.end() ) return 0; return it->second; diff --git a/certmanager/lib/ui/keyrequester.cpp b/certmanager/lib/ui/keyrequester.cpp index 7a56ab5af..16efbd46f 100644 --- a/certmanager/lib/ui/keyrequester.cpp +++ b/certmanager/lib/ui/keyrequester.cpp @@ -231,7 +231,7 @@ static void showKeyListError( TQWidget * tqparent, const GpgME::Error & err ) { const TQString msg = i18n( "<qt><p>An error occurred while fetching " "the keys from the backend:</p>" "<p><b>%1</b></p></qt>" ) - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n( "Key Listing Failed" ) ); } diff --git a/certmanager/lib/ui/keyselectiondialog.cpp b/certmanager/lib/ui/keyselectiondialog.cpp index 22737199e..141e9e989 100644 --- a/certmanager/lib/ui/keyselectiondialog.cpp +++ b/certmanager/lib/ui/keyselectiondialog.cpp @@ -248,7 +248,7 @@ namespace { "Created: %2\n" "Expiry: %3\n" "Fingerprint: %4" ) - .arg( uid ? TQString::fromUtf8( uid ) : i18n("unknown"), + .tqarg( uid ? TQString::fromUtf8( uid ) : i18n("unknown"), creation, expiry, fpr ? TQString::tqfromLatin1( fpr ) : i18n("unknown") ); else @@ -257,10 +257,10 @@ namespace { "Expiry: %3\n" "Fingerprint: %4\n" "Issuer: %5" ) - .arg( uid ? Kleo::DN( uid ).prettyDN() : i18n("unknown"), + .tqarg( uid ? Kleo::DN( uid ).prettyDN() : i18n("unknown"), creation, expiry, fpr ? TQString::tqfromLatin1( fpr ) : i18n("unknown") ) - .arg( issuer ? Kleo::DN( issuer ).prettyDN() : i18n("unknown") ); + .tqarg( issuer ? Kleo::DN( issuer ).prettyDN() : i18n("unknown") ); } const TQPixmap * ColumnStrategy::pixmap( const GpgME::Key & key, int col ) const { @@ -567,7 +567,7 @@ static void showKeyListError( TQWidget * tqparent, const GpgME::Error & err ) { const TQString msg = i18n( "<qt><p>An error occurred while fetching " "the keys from the backend:</p>" "<p><b>%1</b></p></qt>" ) - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( tqparent, msg, i18n( "Key Listing Failed" ) ); } diff --git a/certmanager/lib/ui/messagebox.cpp b/certmanager/lib/ui/messagebox.cpp index 824600f17..0cef145b2 100644 --- a/certmanager/lib/ui/messagebox.cpp +++ b/certmanager/lib/ui/messagebox.cpp @@ -127,7 +127,7 @@ private: if ( const int err = file.status() ) KMessageBox::error( this, i18n("Couldn't save to file \"%1\": %2") - .arg( file.name(), TQString::fromLocal8Bit( strerror( err ) ) ), + .tqarg( file.name(), TQString::fromLocal8Bit( strerror( err ) ) ), i18n("File Save Error") ); } void slotUser2() { @@ -159,7 +159,7 @@ void MessageBox::auditLog( TQWidget * tqparent, const Job * job, const TQString if ( err.code() != GPG_ERR_NO_DATA ) { KMessageBox::information( tqparent, i18n("An error occurred while trying to retrieve the GnuPG Audit Log:\n%1") - .arg( TQString::fromLocal8Bit( err.asString() ) ), + .tqarg( TQString::fromLocal8Bit( err.asString() ) ), i18n("GnuPG Audit Log Error") ); return; } @@ -194,7 +194,7 @@ void MessageBox::auditLog( TQWidget * tqparent, const TQString & log ) { static TQString to_information_string( const SigningResult & result ) { return result.error() - ? i18n("Signing failed: %1").arg( TQString::fromLocal8Bit( result.error().asString() ) ) + ? i18n("Signing failed: %1").tqarg( TQString::fromLocal8Bit( result.error().asString() ) ) : i18n("Signing successful") ; } @@ -204,7 +204,7 @@ static TQString to_error_string( const SigningResult & result ) { static TQString to_information_string( const EncryptionResult & result ) { return result.error() - ? i18n("Encryption failed: %1").arg( TQString::fromLocal8Bit( result.error().asString() ) ) + ? i18n("Encryption failed: %1").tqarg( TQString::fromLocal8Bit( result.error().asString() ) ) : i18n("Encryption successful") ; } diff --git a/certmanager/lib/ui/progressdialog.cpp b/certmanager/lib/ui/progressdialog.cpp index d6552922c..e0149b8f3 100644 --- a/certmanager/lib/ui/progressdialog.cpp +++ b/certmanager/lib/ui/progressdialog.cpp @@ -83,7 +83,7 @@ void Kleo::ProgressDialog::slotProgress( const TQString & what, int current, int else if ( what.isEmpty() ) setLabelText( mBaseText ); else - setLabelText( i18n( "%1: %2" ).arg( mBaseText, what ) ); + setLabelText( i18n( "%1: %2" ).tqarg( mBaseText, what ) ); setProgress( current, total ); } diff --git a/certmanager/storedtransferjob.cpp b/certmanager/storedtransferjob.cpp index fd9e601b8..b111b081f 100644 --- a/certmanager/storedtransferjob.cpp +++ b/certmanager/storedtransferjob.cpp @@ -49,7 +49,7 @@ void StoredTransferJob::slotData( KIO::Job *, const TQByteArray &data ) if ( data.size() == 0 ) return; unsigned int oldSize = m_data.size(); - m_data.resize( oldSize + data.size(), TQGArray::SpeedOptim ); + m_data.tqresize( oldSize + data.size(), TQGArray::SpeedOptim ); memcpy( m_data.data() + oldSize, data.data(), data.size() ); } diff --git a/dependency-graph.dot b/dependency-graph.dot index 787125fea..d6b774b29 100644 --- a/dependency-graph.dot +++ b/dependency-graph.dot @@ -1,4 +1,4 @@ -# to create a ps file use 'dot -Tps -o dependency-graph.ps dependency-graph.dot' (dot it part of the graphviz package) +# to create a ps file use 'dot -Tps -o dependency-graph.ps dependency-graph.dot' (dot is part of the graphviz package) digraph "inter-dependency graph for kdepim" { "akregator" -> "kaddressbook"; "akregator" -> "kontact"; diff --git a/kaddressbook/addresseditwidget.cpp b/kaddressbook/addresseditwidget.cpp index 4f6168446..60c1f2a6f 100644 --- a/kaddressbook/addresseditwidget.cpp +++ b/kaddressbook/addresseditwidget.cpp @@ -273,7 +273,7 @@ AddressEditDialog::AddressEditDialog( const KABC::Address::List &list, mTypeCombo = new AddressTypeCombo( mAddressList, page ); topLayout->addMultiCellWidget( mTypeCombo, 0, 0, 0, 1 ); - TQLabel *label = new TQLabel( i18n( "<streetLabel>:", "%1:" ).arg( KABC::Address::streetLabel() ), page ); + TQLabel *label = new TQLabel( i18n( "<streetLabel>:", "%1:" ).tqarg( KABC::Address::streetLabel() ), page ); label->tqsetAlignment( TQt::AlignTop | TQt::AlignLeft ); topLayout->addWidget( label, 1, 0 ); mStreetTextEdit = new TQTextEdit( page ); @@ -281,34 +281,34 @@ AddressEditDialog::AddressEditDialog( const KABC::Address::List &list, label->setBuddy( mStreetTextEdit ); topLayout->addWidget( mStreetTextEdit, 1, 1 ); - TabPressEater *eater = new TabPressEater( this ); + TabPressEater *eater = new TabPressEater( TQT_TQOBJECT(this) ); mStreetTextEdit->installEventFilter( eater ); - label = new TQLabel( i18n( "<postOfficeBoxLabel>:", "%1:" ).arg( KABC::Address::postOfficeBoxLabel() ), page ); + label = new TQLabel( i18n( "<postOfficeBoxLabel>:", "%1:" ).tqarg( KABC::Address::postOfficeBoxLabel() ), page ); topLayout->addWidget( label, 2 , 0 ); mPOBoxEdit = new KLineEdit( page ); label->setBuddy( mPOBoxEdit ); topLayout->addWidget( mPOBoxEdit, 2, 1 ); - label = new TQLabel( i18n( "<localityLabel>:", "%1:" ).arg( KABC::Address::localityLabel() ), page ); + label = new TQLabel( i18n( "<localityLabel>:", "%1:" ).tqarg( KABC::Address::localityLabel() ), page ); topLayout->addWidget( label, 3, 0 ); mLocalityEdit = new KLineEdit( page ); label->setBuddy( mLocalityEdit ); topLayout->addWidget( mLocalityEdit, 3, 1 ); - label = new TQLabel( i18n( "<regionLabel>:", "%1:" ).arg( KABC::Address::regionLabel() ), page ); + label = new TQLabel( i18n( "<regionLabel>:", "%1:" ).tqarg( KABC::Address::regionLabel() ), page ); topLayout->addWidget( label, 4, 0 ); mRegionEdit = new KLineEdit( page ); label->setBuddy( mRegionEdit ); topLayout->addWidget( mRegionEdit, 4, 1 ); - label = new TQLabel( i18n( "<postalCodeLabel>:", "%1:" ).arg( KABC::Address::postalCodeLabel() ), page ); + label = new TQLabel( i18n( "<postalCodeLabel>:", "%1:" ).tqarg( KABC::Address::postalCodeLabel() ), page ); topLayout->addWidget( label, 5, 0 ); mPostalCodeEdit = new KLineEdit( page ); label->setBuddy( mPostalCodeEdit ); topLayout->addWidget( mPostalCodeEdit, 5, 1 ); - label = new TQLabel( i18n( "<countryLabel>:", "%1:" ).arg( KABC::Address::countryLabel() ), page ); + label = new TQLabel( i18n( "<countryLabel>:", "%1:" ).tqarg( KABC::Address::countryLabel() ), page ); topLayout->addWidget( label, 6, 0 ); mCountryCombo = new KComboBox( page ); mCountryCombo->setEditable( true ); @@ -606,7 +606,7 @@ AddressTypeDialog::AddressTypeDialog( int type, TQWidget *tqparent ) TQWidget *page = plainPage(); TQVBoxLayout *tqlayout = new TQVBoxLayout( page ); - mGroup = new TQButtonGroup( 2, Horizontal, i18n( "street/postal", "Address Types" ), page ); + mGroup = new TQButtonGroup( 2, Qt::Horizontal, i18n( "street/postal", "Address Types" ), page ); tqlayout->addWidget( mGroup ); mTypeList = KABC::Address::typeList(); diff --git a/kaddressbook/addresseeeditordialog.cpp b/kaddressbook/addresseeeditordialog.cpp index 9fe487312..7b1276c83 100644 --- a/kaddressbook/addresseeeditordialog.cpp +++ b/kaddressbook/addresseeeditordialog.cpp @@ -147,7 +147,7 @@ void AddresseeEditorDialog::slotCancel() void AddresseeEditorDialog::setTitle( const KABC::Addressee &addr ) { if ( !addr.realName().isEmpty() ) - setCaption( i18n( "Edit Contact '%1'" ).arg( addr.realName() ) ); + setCaption( i18n( "Edit Contact '%1'" ).tqarg( addr.realName() ) ); } #include "addresseeeditordialog.moc" diff --git a/kaddressbook/addresseeeditorwidget.cpp b/kaddressbook/addresseeeditorwidget.cpp index 097f513b5..1ea2e77f8 100644 --- a/kaddressbook/addresseeeditorwidget.cpp +++ b/kaddressbook/addresseeeditorwidget.cpp @@ -181,7 +181,7 @@ void AddresseeEditorWidget::setupTab1() tqlayout->addWidget( button, 0, 1 ); tqlayout->addWidget( mNameEdit, 0, 2 ); tqlayout->addWidget( mNameLabel, 0, 2 ); - label = new TQLabel( i18n( "<roleLabel>:", "%1:" ).arg( KABC::Addressee::roleLabel() ), tab1 ); + label = new TQLabel( i18n( "<roleLabel>:", "%1:" ).tqarg( KABC::Addressee::roleLabel() ), tab1 ); mRoleEdit = new KLineEdit( tab1 ); connect( mRoleEdit, TQT_SIGNAL( textChanged( const TQString& ) ), TQT_SLOT( textChanged( const TQString& ) ) ); @@ -190,7 +190,7 @@ void AddresseeEditorWidget::setupTab1() tqlayout->addWidget( mRoleEdit, 1, 2 ); // Organization - label = new TQLabel( i18n( "<organizationLabel>:", "%1:" ).arg( KABC::Addressee::organizationLabel() ), tab1 ); + label = new TQLabel( i18n( "<organizationLabel>:", "%1:" ).tqarg( KABC::Addressee::organizationLabel() ), tab1 ); mOrgEdit = new KLineEdit( tab1 ); label->setBuddy( mOrgEdit ); connect( mOrgEdit, TQT_SIGNAL( textChanged( const TQString& ) ), @@ -256,7 +256,7 @@ void AddresseeEditorWidget::setupTab1() KIcon::SizeMedium ) ); homePageLayout->addWidget( label ); - label = new TQLabel( i18n( "<urlLabel>:", "%1:" ).arg( KABC::Addressee::urlLabel() ), tab1 ); + label = new TQLabel( i18n( "<urlLabel>:", "%1:" ).tqarg( KABC::Addressee::urlLabel() ), tab1 ); mURLEdit = new KLineEdit( tab1 ); connect( mURLEdit, TQT_SIGNAL( textChanged( const TQString& ) ), TQT_SLOT( textChanged( const TQString& ) ) ); @@ -369,7 +369,7 @@ void AddresseeEditorWidget::setupTab2() label->setBuddy( mAssistantEdit ); tqlayout->addMultiCellWidget( mAssistantEdit, 1, 1, 4, 5 ); - label = new TQLabel( i18n( "<titleLabel>:", "%1:" ).arg( KABC::Addressee::titleLabel() ), tab2 ); + label = new TQLabel( i18n( "<titleLabel>:", "%1:" ).tqarg( KABC::Addressee::titleLabel() ), tab2 ); tqlayout->addWidget( label, 2, 3 ); mTitleEdit = new KLineEdit( tab2 ); connect( mTitleEdit, TQT_SIGNAL( textChanged( const TQString& ) ), @@ -486,7 +486,7 @@ void AddresseeEditorWidget::setupCustomFieldsTabs() const TQStringList list = KGlobal::dirs()->findAllResources( "data", "kaddressbook/contacteditorpages/*.ui", true, true ); for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it ) { - if ( activePages.tqfind( (*it).mid( (*it).findRev('/') + 1 ) ) == activePages.end() ) + if ( activePages.tqfind( (*it).mid( (*it).tqfindRev('/') + 1 ) ) == activePages.end() ) continue; ContactEditorTabPage *page = new ContactEditorTabPage( mTabWidget ); @@ -558,7 +558,7 @@ void AddresseeEditorWidget::load() mBirthdayPicker->setDate( mAddressee.birthday().date() ); TQString anniversaryStr = mAddressee.custom( "KADDRESSBOOK", "X-Anniversary" ); - TQDate anniversary = (anniversaryStr.isEmpty() ? TQDate() : TQDate::fromString( anniversaryStr, TQt::ISODate )); + TQDate anniversary = (anniversaryStr.isEmpty() ? TQDate() : TQDate::fromString( anniversaryStr, Qt::ISODate )); mAnniversaryPicker->setDate( anniversary ); mNicknameEdit->setText( mAddressee.nickName() ); mCategoryEdit->setText( mAddressee.categories().join( "," ) ); @@ -652,7 +652,7 @@ void AddresseeEditorWidget::save() if ( mAnniversaryPicker->date().isValid() ) mAddressee.insertCustom( "KADDRESSBOOK", "X-Anniversary", - mAnniversaryPicker->date().toString( TQt::ISODate ) ); + mAnniversaryPicker->date().toString( Qt::ISODate ) ); else mAddressee.removeCustom( "KADDRESSBOOK", "X-Anniversary" ); diff --git a/kaddressbook/addviewdialog.cpp b/kaddressbook/addviewdialog.cpp index 4f3a58078..548990d16 100644 --- a/kaddressbook/addviewdialog.cpp +++ b/kaddressbook/addviewdialog.cpp @@ -57,7 +57,7 @@ AddViewDialog::AddViewDialog( TQDict<ViewFactory> *viewFactoryDict, TQT_SLOT( textChanged( const TQString& ) ) ); tqlayout->addWidget( mViewNameEdit, 0, 1 ); - mTypeGroup = new TQButtonGroup( 0, TQt::Horizontal, i18n( "View Type" ), page ); + mTypeGroup = new TQButtonGroup( 0, Qt::Horizontal, i18n( "View Type" ), page ); connect( mTypeGroup, TQT_SIGNAL( clicked( int ) ), this, TQT_SLOT( clicked( int ) ) ); tqlayout->addMultiCellWidget( mTypeGroup, 1, 1, 0, 1 ); TQGridLayout *groupLayout = new TQGridLayout( mTypeGroup->tqlayout(), 3, 2 ); diff --git a/kaddressbook/common/filter.cpp b/kaddressbook/common/filter.cpp index 932f6f108..910fc151e 100644 --- a/kaddressbook/common/filter.cpp +++ b/kaddressbook/common/filter.cpp @@ -147,7 +147,7 @@ void Filter::save( KConfig *config, const TQString &baseGroup, Filter::List &lis // remove the old filters uint count = config->readNumEntry( "Count" ); for ( uint i = 0; i < count; ++i ) - config->deleteGroup( TQString( "%1_%2" ).arg( baseGroup ).arg( i ) ); + config->deleteGroup( TQString( "%1_%2" ).tqarg( baseGroup ).tqarg( i ) ); } @@ -155,8 +155,8 @@ void Filter::save( KConfig *config, const TQString &baseGroup, Filter::List &lis Filter::List::Iterator iter; for ( iter = list.begin(); iter != list.end(); ++iter ) { if ( !(*iter).mInternal ) { - KConfigGroupSaver s( config, TQString( "%1_%2" ).arg( baseGroup ) - .arg( index ) ); + KConfigGroupSaver s( config, TQString( "%1_%2" ).tqarg( baseGroup ) + .tqarg( index ) ); (*iter).save( config ); index++; } @@ -179,7 +179,7 @@ Filter::List Filter::restore( KConfig *config, const TQString &baseGroup ) for ( int i = 0; i < count; i++ ) { { - KConfigGroupSaver s( config, TQString( "%1_%2" ).arg( baseGroup ).arg( i ) ); + KConfigGroupSaver s( config, TQString( "%1_%2" ).tqarg( baseGroup ).tqarg( i ) ); f.restore( config ); } diff --git a/kaddressbook/common/locationmap.cpp b/kaddressbook/common/locationmap.cpp index 716e1764b..c5de16adf 100644 --- a/kaddressbook/common/locationmap.cpp +++ b/kaddressbook/common/locationmap.cpp @@ -72,7 +72,7 @@ TQString LocationMap::createUrl( const KABC::Address &addr ) %c country (in ISO format) */ - TQString urlTemplate = KABPrefs::instance()->locationMapURL().arg( KGlobal::locale()->country() ); + TQString urlTemplate = KABPrefs::instance()->locationMapURL().tqarg( KGlobal::locale()->country() ); if ( urlTemplate.isEmpty() ) { KMessageBox::error( 0, i18n( "No service provider available for map lookup!\nPlease add one in the configuration dialog." ) ); return TQString(); diff --git a/kaddressbook/contacteditorwidgetmanager.cpp b/kaddressbook/contacteditorwidgetmanager.cpp index 8cee7a9bb..e0afc9d6a 100644 --- a/kaddressbook/contacteditorwidgetmanager.cpp +++ b/kaddressbook/contacteditorwidgetmanager.cpp @@ -76,7 +76,7 @@ void ContactEditorWidgetManager::reload() mFactories.clear(); kdDebug(5720) << "ContactEditorWidgetManager::reload()" << endl; const KTrader::OfferList plugins = KTrader::self()->query( "KAddressBook/ContactEditorWidget", - TQString( "[X-KDE-KAddressBook-CEWPluginVersion] == %1" ).arg( KAB_CEW_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KAddressBook-CEWPluginVersion] == %1" ).tqarg( KAB_CEW_PLUGIN_VERSION ) ); KTrader::OfferList::ConstIterator it; for ( it = plugins.begin(); it != plugins.end(); ++it ) { diff --git a/kaddressbook/customfieldswidget.cpp b/kaddressbook/customfieldswidget.cpp index 5ceac5dbe..f22160d7b 100644 --- a/kaddressbook/customfieldswidget.cpp +++ b/kaddressbook/customfieldswidget.cpp @@ -54,7 +54,7 @@ AddFieldDialog::AddFieldDialog( TQWidget *tqparent, const char *name ) tqlayout->addWidget( label, 0, 0 ); mTitle = new KLineEdit( page ); - mTitle->setValidator( new TQRegExpValidator( TQRegExp( "([a-zA-Z]|\\d|-)+" ), mTitle ) ); + mTitle->setValidator( new TQRegExpValidator( TQRegExp( "([a-zA-Z]|\\d|-)+" ), TQT_TQOBJECT(mTitle) ) ); label->setBuddy( mTitle ); tqlayout->addWidget( mTitle, 0, 1 ); @@ -276,13 +276,13 @@ void FieldWidget::loadContact( KABC::Addressee *addr ) wdg->setChecked( value == "true" || value == "1" ); } else if ( (*fieldIt).mWidget->isA( TQDATEEDIT_OBJECT_NAME_STRING ) ) { TQDateEdit *wdg = static_cast<TQDateEdit*>( (*fieldIt).mWidget ); - wdg->setDate( TQDate::fromString( value, TQt::ISODate ) ); + wdg->setDate( TQDate::fromString( value, Qt::ISODate ) ); } else if ( (*fieldIt).mWidget->isA( TQTIMEEDIT_OBJECT_NAME_STRING ) ) { TQTimeEdit *wdg = static_cast<TQTimeEdit*>( (*fieldIt).mWidget ); - wdg->setTime( TQTime::fromString( value, TQt::ISODate ) ); + wdg->setTime( TQTime::fromString( value, Qt::ISODate ) ); } else if ( (*fieldIt).mWidget->isA( TQDATETIMEEDIT_OBJECT_NAME_STRING ) ) { TQDateTimeEdit *wdg = static_cast<TQDateTimeEdit*>( (*fieldIt).mWidget ); - wdg->setDateTime( TQDateTime::fromString( value, TQt::ISODate ) ); + wdg->setDateTime( TQDateTime::fromString( value, Qt::ISODate ) ); } } } @@ -332,13 +332,13 @@ void FieldWidget::storeContact( KABC::Addressee *addr ) value = ( wdg->isChecked() ? "true" : "false" ); } else if ( (*it).mWidget->isA( TQDATEEDIT_OBJECT_NAME_STRING ) ) { TQDateEdit *wdg = static_cast<TQDateEdit*>( (*it).mWidget ); - value = wdg->date().toString( TQt::ISODate ); + value = wdg->date().toString( Qt::ISODate ); } else if ( (*it).mWidget->isA( TQTIMEEDIT_OBJECT_NAME_STRING ) ) { TQTimeEdit *wdg = static_cast<TQTimeEdit*>( (*it).mWidget ); - value = wdg->time().toString( TQt::ISODate ); + value = wdg->time().toString( Qt::ISODate ); } else if ( (*it).mWidget->isA( TQDATETIMEEDIT_OBJECT_NAME_STRING ) ) { TQDateTimeEdit *wdg = static_cast<TQDateTimeEdit*>( (*it).mWidget ); - value = wdg->dateTime().toString( TQt::ISODate ); + value = wdg->dateTime().toString( Qt::ISODate ); } if ( value.isEmpty() ) diff --git a/kaddressbook/distributionlisteditor.cpp b/kaddressbook/distributionlisteditor.cpp index 485b77975..2c6d39c95 100644 --- a/kaddressbook/distributionlisteditor.cpp +++ b/kaddressbook/distributionlisteditor.cpp @@ -159,7 +159,7 @@ KPIM::DistributionListEditor::EditorWidget::EditorWidget( KABC::AddressBook* boo d->addressBook = book; Q_ASSERT( d->addressBook ); d->lastLineId = 0; - d->mapper = new TQSignalMapper( this ); + d->mapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( d->mapper, TQT_SIGNAL( mapped( int ) ), this, TQT_SLOT( lineTextChanged( int ) ) ); setCaption( i18n( "Edit Distribution List" ) ); @@ -250,7 +250,7 @@ KPIM::DistributionListEditor::Line* KPIM::DistributionListEditor::EditorWidgetPr addressees.append( line ); TQObject::connect( line, TQT_SIGNAL( textChanged() ), mapper, TQT_SLOT( map() ) ); - mapper->setMapping( line, ++lastLineId ); + mapper->setMapping( TQT_TQOBJECT(line), ++lastLineId ); line->setShown( true ); return line; } @@ -261,7 +261,7 @@ void KPIM::DistributionListEditor::EditorWidget::slotOk() const KPIM::DistributionList existing = KPIM::DistributionList::findByName( d->addressBook, name ); if ( !existing.isEmpty() && existing.uid() != d->distListUid ) { - KMessageBox::error( this, i18n( "A distribution list with the name %1 already exists. Please choose another name." ).arg( name ), i18n( "Name in Use" ) ); + KMessageBox::error( this, i18n( "A distribution list with the name %1 already exists. Please choose another name." ).tqarg( name ), i18n( "Name in Use" ) ); return; } diff --git a/kaddressbook/distributionlistentryview.cpp b/kaddressbook/distributionlistentryview.cpp index 9ea49c3a0..7b515782f 100644 --- a/kaddressbook/distributionlistentryview.cpp +++ b/kaddressbook/distributionlistentryview.cpp @@ -106,10 +106,10 @@ void KAB::DistributionListEntryView::setEntry( const KPIM::DistributionList& lis TQPixmap pixmap; pixmap.convertFromImage( m_entry.addressee.photo().data() ); m_imageLabel->setPixmap( pixmap.isNull() ? KGlobal::iconLoader()->loadIcon( "personal", KIcon::Desktop ) : pixmap ); - m_addresseeLabel->setText( i18n( "Formatted name, role, organization", "<qt><h2>%1</h2><p>%2<br/>%3</p></qt>" ).arg( m_entry.addressee.formattedName(), m_entry.addressee.role(), m_entry.addressee.organization() ) ); + m_addresseeLabel->setText( i18n( "Formatted name, role, organization", "<qt><h2>%1</h2><p>%2<br/>%3</p></qt>" ).tqarg( m_entry.addressee.formattedName(), m_entry.addressee.role(), m_entry.addressee.organization() ) ); m_distListLabel->setURL( m_list.name() ); m_distListLabel->setText( m_list.name() ); - m_resourceLabel->setText( i18n( "<b>Address book:</b> %1" ).arg( m_entry.addressee.resource() ? m_entry.addressee.resource()->resourceName() : TQString() ) ); + m_resourceLabel->setText( i18n( "<b>Address book:</b> %1" ).tqarg( m_entry.addressee.resource() ? m_entry.addressee.resource()->resourceName() : TQString() ) ); m_resourceLabel->tqsetAlignment( TQt::SingleLine ); m_emailGroup = new TQVButtonGroup( this ); diff --git a/kaddressbook/distributionlistpicker.cpp b/kaddressbook/distributionlistpicker.cpp index fab91bc4c..5810276e6 100644 --- a/kaddressbook/distributionlistpicker.cpp +++ b/kaddressbook/distributionlistpicker.cpp @@ -107,12 +107,12 @@ void KPIM::DistributionListPickerDialog::slotUser1() m_book->insertAddressee( list ); m_listBox->insertItem( name ); - TQListBoxItem* item = m_listBox->findItem( name ); + TQListBoxItem* item = m_listBox->tqfindItem( name ); m_listBox->setSelected( item, true ); } else { - KMessageBox::error( this, i18n( "A distribution list with the the name %1 already exists. Please choose another name" ).arg( name ), i18n( "Name Exists" ) ); + KMessageBox::error( this, i18n( "A distribution list with the the name %1 already exists. Please choose another name" ).tqarg( name ), i18n( "Name Exists" ) ); } } while ( !validName ); diff --git a/kaddressbook/editors/imaddresswidget.cpp b/kaddressbook/editors/imaddresswidget.cpp index 1d64c5b98..aa3a9a484 100644 --- a/kaddressbook/editors/imaddresswidget.cpp +++ b/kaddressbook/editors/imaddresswidget.cpp @@ -50,7 +50,7 @@ IMAddressWidget::IMAddressWidget( TQWidget *tqparent, TQValueList<KPluginInfo *> mProtocols = protocols; populateProtocols(); - cmbProtocol->setCurrentItem( mProtocols.findIndex( protocol ) ); + cmbProtocol->setCurrentItem( mProtocols.tqfindIndex( protocol ) ); edtAddress->setText( address.section( TQChar( 0xE120 ), 0, 0 ) ); edtNetwork->setText( address.section( TQChar( 0xE120 ), 1 ) ); diff --git a/kaddressbook/editors/imeditorwidget.cpp b/kaddressbook/editors/imeditorwidget.cpp index 3e306a03b..aba21b65b 100644 --- a/kaddressbook/editors/imeditorwidget.cpp +++ b/kaddressbook/editors/imeditorwidget.cpp @@ -85,7 +85,7 @@ void IMAddressLVI::setAddress( const TQString &address ) else { TQString nickname = address.section( TQChar( 0xE120 ), 0, 0 ); setText( 1, i18n( "<nickname> on <server>","%1 on %2" ) - .arg( nickname ).arg( serverOrGroup ) ); + .tqarg( nickname ).tqarg( serverOrGroup ) ); } mAddress = address; diff --git a/kaddressbook/emaileditwidget.cpp b/kaddressbook/emaileditwidget.cpp index 21d21e52f..75677a698 100644 --- a/kaddressbook/emaileditwidget.cpp +++ b/kaddressbook/emaileditwidget.cpp @@ -302,7 +302,7 @@ void EmailEditDialog::remove() { TQString address = mEmailListBox->currentText(); - TQString text = i18n( "<qt>Are you sure that you want to remove the email address <b>%1</b>?</qt>" ).arg( address ); + TQString text = i18n( "<qt>Are you sure that you want to remove the email address <b>%1</b>?</qt>" ).tqarg( address ); TQString caption = i18n( "Confirm Remove" ); if ( KMessageBox::warningContinueCancel( this, text, caption, KGuiItem( i18n("&Delete"), "editdelete") ) == KMessageBox::Continue) { diff --git a/kaddressbook/extensionmanager.cpp b/kaddressbook/extensionmanager.cpp index 0f8100dbd..1496be517 100644 --- a/kaddressbook/extensionmanager.cpp +++ b/kaddressbook/extensionmanager.cpp @@ -52,7 +52,7 @@ ExtensionManager::ExtensionManager( TQWidget* extensionBar, TQWidgetStack* detai Q_ASSERT( mExtensionBar ); TQVBoxLayout* tqlayout = new TQVBoxLayout( mExtensionBar ); mSplitter = new TQSplitter( mExtensionBar ); - mSplitter->setOrientation( TQSplitter::Vertical ); + mSplitter->setOrientation( Qt::Vertical ); tqlayout->addWidget( mSplitter ); createExtensionWidgets(); @@ -217,7 +217,7 @@ void ExtensionManager::createExtensionWidgets() // load the other extensions const KTrader::OfferList plugins = KTrader::self()->query( "KAddressBook/Extension", - TQString( "[X-KDE-KAddressBook-ExtensionPluginVersion] == %1" ).arg( KAB_EXTENSIONWIDGET_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KAddressBook-ExtensionPluginVersion] == %1" ).tqarg( KAB_EXTENSIONWIDGET_PLUGIN_VERSION ) ); KTrader::OfferList::ConstIterator it; for ( it = plugins.begin(); it != plugins.end(); ++it ) { diff --git a/kaddressbook/features/distributionlistwidget.cpp b/kaddressbook/features/distributionlistwidget.cpp index 16277784e..7ce25beb7 100644 --- a/kaddressbook/features/distributionlistwidget.cpp +++ b/kaddressbook/features/distributionlistwidget.cpp @@ -343,7 +343,7 @@ void DistributionListWidget::editList() void DistributionListWidget::removeList() { int result = KMessageBox::warningContinueCancel( this, - i18n( "<qt>Delete distribution list <b>%1</b>?</qt>" ) .arg( mNameCombo->currentText() ), + i18n( "<qt>Delete distribution list <b>%1</b>?</qt>" ) .tqarg( mNameCombo->currentText() ), TQString(), KGuiItem( i18n("Delete"), "editdelete") ); if ( result != KMessageBox::Continue ) diff --git a/kaddressbook/features/resourceselection.cpp b/kaddressbook/features/resourceselection.cpp index 049f879b5..5fe18f5d3 100644 --- a/kaddressbook/features/resourceselection.cpp +++ b/kaddressbook/features/resourceselection.cpp @@ -241,13 +241,13 @@ void ResourceSelection::add() if ( !ok ) return; - TQString type = types[ descs.findIndex( desc ) ]; + TQString type = types[ descs.tqfindIndex( desc ) ]; // Create new resource KABC::Resource *resource = mManager->createResource( type ); if ( !resource ) { KMessageBox::error( this, i18n("<qt>Unable to create an address book of type <b>%1</b>.</qt>") - .arg( type ) ); + .tqarg( type ) ); return; } @@ -298,7 +298,7 @@ void ResourceSelection::remove() int result = KMessageBox::warningContinueCancel( this, i18n( "<qt>Do you really want to remove the address book <b>%1</b>?</qt>" ) - .arg( item->resource()->resourceName() ), "", + .tqarg( item->resource()->resourceName() ), "", KGuiItem( i18n( "&Remove" ), "editdelete" ) ); if ( result == KMessageBox::Cancel ) return; @@ -410,7 +410,7 @@ void ResourceSelection::slotSubresourceAdded( KPIM::ResourceABC *resource, const TQString& subResource ) { kdDebug(5720) << k_funcinfo << resource->resourceName() << " " << subResource << endl; - TQListViewItem *i = mListView->findItem( resource->resourceName(), 0 ); + TQListViewItem *i = mListView->tqfindItem( resource->resourceName(), 0 ); if ( !i ) // Not found return; diff --git a/kaddressbook/filtereditdialog.cpp b/kaddressbook/filtereditdialog.cpp index 60a67014c..7428b3638 100644 --- a/kaddressbook/filtereditdialog.cpp +++ b/kaddressbook/filtereditdialog.cpp @@ -265,11 +265,11 @@ void FilterDialog::initGUI() connect( mFilterListBox, TQT_SIGNAL( doubleClicked ( TQListBoxItem * ) ), TQT_SLOT( edit() ) ); - KButtonBox *buttonBox = new KButtonBox( page, Vertical ); - buttonBox->addButton( i18n( "&Add..." ), this, TQT_SLOT( add() ) ); - mEditButton = buttonBox->addButton( i18n( "&Edit..." ), this, TQT_SLOT( edit() ) ); + KButtonBox *buttonBox = new KButtonBox( page, Qt::Vertical ); + buttonBox->addButton( i18n( "&Add..." ), TQT_TQOBJECT(this), TQT_SLOT( add() ) ); + mEditButton = buttonBox->addButton( i18n( "&Edit..." ), TQT_TQOBJECT(this), TQT_SLOT( edit() ) ); mEditButton->setEnabled( false ); - mRemoveButton = buttonBox->addButton( i18n( "&Remove" ), this, TQT_SLOT( remove() ) ); + mRemoveButton = buttonBox->addButton( i18n( "&Remove" ), TQT_TQOBJECT(this), TQT_SLOT( remove() ) ); mRemoveButton->setEnabled( false ); buttonBox->tqlayout(); diff --git a/kaddressbook/geowidget.cpp b/kaddressbook/geowidget.cpp index 4837a1ef4..5dc432868 100644 --- a/kaddressbook/geowidget.cpp +++ b/kaddressbook/geowidget.cpp @@ -67,7 +67,7 @@ GeoWidget::GeoWidget( KABC::AddressBook *ab, TQWidget *tqparent, const char *nam mLatitudeBox = new KDoubleSpinBox( -90, 90, 1, 0, 6, this ); mLatitudeBox->setEnabled( false ); - mLatitudeBox->setSuffix( "°" ); + mLatitudeBox->setSuffix( "�" ); topLayout->addWidget( mLatitudeBox, 1, 2 ); label->setBuddy( mLatitudeBox ); @@ -76,7 +76,7 @@ GeoWidget::GeoWidget( KABC::AddressBook *ab, TQWidget *tqparent, const char *nam mLongitudeBox = new KDoubleSpinBox( -180, 180, 1, 0, 6, this ); mLongitudeBox->setEnabled( false ); - mLongitudeBox->setSuffix( "°" ); + mLongitudeBox->setSuffix( "�" ); topLayout->addWidget( mLongitudeBox, 2, 2 ); label->setBuddy( mLongitudeBox ); @@ -174,7 +174,7 @@ GeoDialog::GeoDialog( TQWidget *tqparent, const char *name ) mCityCombo = new KComboBox( page ); topLayout->addWidget( mCityCombo, 0, 1 ); - TQGroupBox *sexagesimalGroup = new TQGroupBox( 0, Vertical, i18n( "Sexagesimal" ), page ); + TQGroupBox *sexagesimalGroup = new TQGroupBox( 0, Qt::Vertical, i18n( "Sexagesimal" ), page ); TQGridLayout *sexagesimalLayout = new TQGridLayout( sexagesimalGroup->tqlayout(), 2, 5, spacingHint() ); @@ -182,7 +182,7 @@ GeoDialog::GeoDialog( TQWidget *tqparent, const char *name ) sexagesimalLayout->addWidget( label, 0, 0 ); mLatDegrees = new TQSpinBox( 0, 90, 1, sexagesimalGroup ); - mLatDegrees->setSuffix( "°" ); + mLatDegrees->setSuffix( "�" ); mLatDegrees->setWrapping( false ); label->setBuddy( mLatDegrees ); sexagesimalLayout->addWidget( mLatDegrees, 0, 1 ); @@ -204,7 +204,7 @@ GeoDialog::GeoDialog( TQWidget *tqparent, const char *name ) sexagesimalLayout->addWidget( label, 1, 0 ); mLongDegrees = new TQSpinBox( 0, 180, 1, sexagesimalGroup ); - mLongDegrees->setSuffix( "°" ); + mLongDegrees->setSuffix( "�" ); label->setBuddy( mLongDegrees ); sexagesimalLayout->addWidget( mLongDegrees, 1, 1 ); @@ -537,7 +537,7 @@ void GeoMapWidget::paintEvent( TQPaintEvent* ) TQPixmap pm( w, h ); TQPainter p; - p.begin( &pm, this ); + p.tqbegin( &pm, this ); p.setPen( TQColor( 255, 0, 0 ) ); p.setBrush( TQColor( 255, 0, 0 ) ); diff --git a/kaddressbook/imagewidget.cpp b/kaddressbook/imagewidget.cpp index 0dc83ae49..b4219322c 100644 --- a/kaddressbook/imagewidget.cpp +++ b/kaddressbook/imagewidget.cpp @@ -206,7 +206,7 @@ void ImageButton::mousePressEvent( TQMouseEvent *event ) void ImageButton::mouseMoveEvent( TQMouseEvent *event ) { - if ( (event->state() & LeftButton) && + if ( (event->state() & Qt::LeftButton) && (event->pos() - mDragStartPos).manhattanLength() > KGlobalSettings::dndEventDelay() ) { startDrag(); @@ -254,7 +254,7 @@ ImageBaseWidget::ImageBaseWidget( const TQString &title, TQVBoxLayout *topLayout = new TQVBoxLayout( this, KDialog::marginHint(), KDialog::spacingHint() ); - TQGroupBox *box = new TQGroupBox( 0, TQt::Vertical, title, this ); + TQGroupBox *box = new TQGroupBox( 0, Qt::Vertical, title, this ); TQVBoxLayout *tqlayout = new TQVBoxLayout( box->tqlayout(), KDialog::spacingHint() ); mImageButton = new ImageButton( i18n( "Picture" ), box ); diff --git a/kaddressbook/jumpbuttonbar.cpp b/kaddressbook/jumpbuttonbar.cpp index 4ef22bc57..1af942b2d 100644 --- a/kaddressbook/jumpbuttonbar.cpp +++ b/kaddressbook/jumpbuttonbar.cpp @@ -57,7 +57,7 @@ JumpButton::JumpButton( const TQString &firstChar, const TQString &lastChar, { setToggleButton( true ); if ( !lastChar.isEmpty() ) - setText( TQString( "%1 - %2" ).arg( firstChar.upper() ).arg( lastChar.upper() ) ); + setText( TQString( "%1 - %2" ).tqarg( firstChar.upper() ).tqarg( lastChar.upper() ) ); else setText( firstChar.upper() ); } @@ -72,7 +72,7 @@ JumpButtonBar::JumpButtonBar( KAB::Core *core, TQWidget *tqparent, const char *n tqlayout->setAutoAdd( true ); tqlayout->setResizeMode( TQLayout::FreeResize ); - mGroupBox = new TQButtonGroup( 1, TQt::Horizontal, this ); + mGroupBox = new TQButtonGroup( 1, Qt::Horizontal, this ); mGroupBox->setExclusive( true ); mGroupBox->tqlayout()->setSpacing( 0 ); mGroupBox->tqlayout()->setMargin( 0 ); @@ -98,7 +98,7 @@ void JumpButtonBar::updateButtons() TQFontMetrics fm = fontMetrics(); TQPushButton *btn = new TQPushButton( "", this ); btn->hide(); - TQSize buttonSize = style().sizeFromContents( TQStyle::CT_PushButton, btn, + TQSize buttonSize = tqstyle().tqsizeFromContents( TQStyle::CT_PushButton, btn, fm.size( ShowPrefix, "X - X") ). expandedTo( TQApplication::globalStrut() ); delete btn; diff --git a/kaddressbook/kabcore.cpp b/kaddressbook/kabcore.cpp index 14f9577a6..23ebc277b 100644 --- a/kaddressbook/kabcore.cpp +++ b/kaddressbook/kabcore.cpp @@ -94,7 +94,7 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, TQWidget *tqparent, const TQString &file, const char *name ) - : KAB::Core( client, tqparent, name ), mStatusBar( 0 ), mViewManager( 0 ), + : KAB::Core( client, TQT_TQOBJECT(tqparent), name ), mStatusBar( 0 ), mViewManager( 0 ), mExtensionManager( 0 ), mJumpButtonBar( 0 ), mCategorySelectDialog( 0 ), mCategoryEditDialog( 0 ), mLdapSearchDialog( 0 ), mReadWrite( readWrite ), mModified( false ) @@ -114,7 +114,7 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, TQWidget *tqparent, mAddressBook = new KABC::AddressBook; mAddressBook->addResource( new KABC::ResourceFile( file ) ); if ( !mAddressBook->load() ) { - KMessageBox::error( tqparent, i18n("Unable to load '%1'.").arg( file ) ); + KMessageBox::error( tqparent, i18n("Unable to load '%1'.").tqarg( file ) ); } } mAddressBook->setErrorHandler( new KABC::GuiErrorHandler( mWidget ) ); @@ -140,7 +140,7 @@ KABCore::KABCore( KXMLGUIClient *client, bool readWrite, TQWidget *tqparent, mAddressBook->addCustomField( i18n( "Blog" ), KABC::Field::Personal, "BlogFeed", "KADDRESSBOOK" ); - mSearchManager = new KAB::SearchManager( mAddressBook, tqparent ); + mSearchManager = new KAB::SearchManager( mAddressBook, TQT_TQOBJECT(tqparent) ); connect( mSearchManager, TQT_SIGNAL( contactsUpdated() ), this, TQT_SLOT( slotContactsUpdated() ) ); @@ -430,7 +430,7 @@ void KABCore::setContactSelected( const TQString &uid ) mActionMerge->setEnabled( ( list.size() == 2 ) && writable ); if ( mReadWrite ) { - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); #if defined(KABC_VCARD_ENCODING_FIX) const TQMimeSource *data = cb->data( TQClipboard::Clipboard ); list = AddresseeUtil::clipboardToAddressees( data->tqencodedData( "text/x-vcard" ) ); @@ -552,11 +552,11 @@ void KABCore::copyContacts() #if defined(KABC_VCARD_ENCODING_FIX) TQByteArray clipText = AddresseeUtil::addresseesToClipboard( addrList ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); cb->setText( TQString::fromUtf8( clipText.data() ) ); #else TQString clipText = AddresseeUtil::addresseesToClipboard( addrList ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); cb->setText( clipText ); #endif } @@ -575,7 +575,7 @@ void KABCore::cutContacts() void KABCore::pasteContacts() { - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); #if defined(KABC_VCARD_ENCODING_FIX) const TQMimeSource *data = cb->data( TQClipboard::Clipboard ); KABC::Addressee::List list = AddresseeUtil::clipboardToAddressees( data->tqencodedData( "text/x-vcard" ) ); @@ -640,7 +640,7 @@ void KABCore::setWhoAmI() } TQString text( i18n( "<qt>Do you really want to use <b>%1</b> as your new personal contact?</qt>" ) ); - if ( KMessageBox::questionYesNo( mWidget, text.arg( addrList[ 0 ].assembledName() ), TQString(), i18n("Use"), i18n("Do Not Use") ) == KMessageBox::Yes ) + if ( KMessageBox::questionYesNo( mWidget, text.tqarg( addrList[ 0 ].assembledName() ), TQString(), i18n("Use"), i18n("Do Not Use") ) == KMessageBox::Yes ) static_cast<KABC::StdAddressBook*>( KABC::StdAddressBook::self( true ) )->setWhoAmI( addrList[ 0 ] ); } @@ -661,7 +661,7 @@ void KABCore::incrementalJumpButtonSearch( const TQString& character ) KABC::AddresseeList::ConstIterator it; const KABC::AddresseeList::ConstIterator endIt( list.end() ); for ( it = list.begin(); it != endIt; ++it ) { - if ( field->value( *it ).startsWith( character, false ) ) { + if ( field->value( *it ).tqstartsWith( character, false ) ) { mViewManager->setSelected( (*it).uid(), true ); return; } @@ -720,7 +720,7 @@ void KABCore::newDistributionList() bool foundUnused = false; int i = 1; while ( !foundUnused ) { - name = i18n( "New Distribution List (%1)" ).arg( i++ ); + name = i18n( "New Distribution List (%1)" ).tqarg( i++ ); foundUnused = KPIM::DistributionList::findByName( addressBook(), name ).isEmpty(); } } @@ -897,7 +897,7 @@ void KABCore::save() if ( ticket ) { if ( !mAddressBook->save( ticket ) ) { KMessageBox::error( mWidget, - i18n( "<qt>Unable to save address book <b>%1</b>.</qt>" ).arg( it.current()->resourceName() ) ); + i18n( "<qt>Unable to save address book <b>%1</b>.</qt>" ).tqarg( it.current()->resourceName() ) ); mAddressBook->releaseSaveTicket( ticket ); } else { setModified( false ); @@ -905,7 +905,7 @@ void KABCore::save() } else { KMessageBox::error( mWidget, i18n( "<qt>Unable to get access for saving the address book <b>%1</b>.</qt>" ) - .arg( it.current()->resourceName() ) ); + .tqarg( it.current()->resourceName() ) ); } ++it; @@ -1205,7 +1205,7 @@ void KABCore::initGUI() mDetailsSplitter = new TQSplitter( mWidget ); mLeftSplitter = new TQSplitter( mDetailsSplitter ); - mLeftSplitter->setOrientation( KABPrefs::instance()->contactListAboveExtensions() ? TQt::Vertical : TQt::Horizontal ); + mLeftSplitter->setOrientation( KABPrefs::instance()->contactListAboveExtensions() ? Qt::Vertical : Qt::Horizontal ); topLayout->addWidget( searchTB ); topLayout->addWidget( mDetailsSplitter ); @@ -1292,7 +1292,7 @@ void KABCore::initGUI() topLayout->setStretchFactor( mDetailsSplitter, 1 ); - mXXPortManager = new XXPortManager( this, mWidget ); + mXXPortManager = new XXPortManager( this, TQT_TQOBJECT(mWidget) ); initActions(); } @@ -1311,7 +1311,7 @@ void KABCore::createJumpButtonBar() void KABCore::initActions() { - connect( TQApplication::clipboard(), TQT_SIGNAL( dataChanged() ), + connect( TQApplication::tqclipboard(), TQT_SIGNAL( dataChanged() ), TQT_SLOT( clipboardDataChanged() ) ); KAction *action; @@ -1432,7 +1432,7 @@ void KABCore::initActions() void KABCore::clipboardDataChanged() { if ( mReadWrite ) - mActionPaste->setEnabled( !TQApplication::clipboard()->text().isEmpty() ); + mActionPaste->setEnabled( !TQApplication::tqclipboard()->text().isEmpty() ); } void KABCore::updateIncSearchWidget() @@ -1634,7 +1634,7 @@ void KABCore::removeSelectedContactsFromDistList() "<b>Note:</b>The contacts will be not be removed from your addressbook nor from " "any other distribution list." "</qt>", - uids.count() ).arg( mSelectedDistributionList ), + uids.count() ).tqarg( mSelectedDistributionList ), names, TQString(), KStdGuiItem::del() ) == KMessageBox::Cancel ) { return; } @@ -1729,7 +1729,7 @@ void KABCore::setSelectedDistributionList( const TQString &name ) mSearchManager->setSelectedDistributionList( name ); mViewHeaderLabel->setText( name.isNull() ? i18n( "Contacts" ) : - i18n( "Distribution List: %1" ).arg( name ) ); + i18n( "Distribution List: %1" ).tqarg( name ) ); mDistListButtonWidget->setShown( !mSelectedDistributionList.isNull() ); if ( !name.isNull() ) { mDetailsStack->raiseWidget( mDistListEntryView ); diff --git a/kaddressbook/kabtools.cpp b/kaddressbook/kabtools.cpp index 0b98eab3c..31d7f3684 100644 --- a/kaddressbook/kabtools.cpp +++ b/kaddressbook/kabtools.cpp @@ -43,7 +43,7 @@ static TQString uniqueFileName( const KABC::Addressee &addressee, TQStringList & name.tqreplace( '/', '_' ); ++number; - uniquePart = TQString( "_%1" ).arg( number ); + uniquePart = TQString( "_%1" ).tqarg( number ); } while ( existingFiles.tqcontains( name ) ); existingFiles.append( name ); diff --git a/kaddressbook/kaddressbook_part.cpp b/kaddressbook/kaddressbook_part.cpp index a29380adf..6f0904b4a 100644 --- a/kaddressbook/kaddressbook_part.cpp +++ b/kaddressbook/kaddressbook_part.cpp @@ -51,7 +51,7 @@ KAddressbookPart::KAddressbookPart( TQWidget *tqparentWidget, const char *widget // create a canvas to insert our widget TQWidget *canvas = new TQWidget( tqparentWidget, widgetName ); - canvas->setFocusPolicy( TQWidget::ClickFocus ); + canvas->setFocusPolicy( Qt::ClickFocus ); setWidget( canvas ); TQVBoxLayout *topLayout = new TQVBoxLayout( canvas ); diff --git a/kaddressbook/kaddressbook_part.h b/kaddressbook/kaddressbook_part.h index 05e099d29..3991e7401 100644 --- a/kaddressbook/kaddressbook_part.h +++ b/kaddressbook/kaddressbook_part.h @@ -52,7 +52,11 @@ class KAddressbookPart: public KParts::ReadOnlyPart, virtual public KAddressBook virtual void addEmail( TQString addr ); virtual void importVCard( const KURL& url ); virtual void importVCardFromData( const TQString& vCard ); +#ifndef Q_MOC_RUN virtual ASYNC showContactEditor( TQString uid ); +#else // Q_MOC_RUN + virtual void showContactEditor( TQString uid ); +#endif // Q_MOC_RUN virtual void newContact(); virtual void newDistributionList(); virtual TQString getNameByPhone( TQString phone ); diff --git a/kaddressbook/kaddressbookmain.cpp b/kaddressbook/kaddressbookmain.cpp index 55f664a63..ee9de2f56 100644 --- a/kaddressbook/kaddressbookmain.cpp +++ b/kaddressbook/kaddressbookmain.cpp @@ -150,13 +150,13 @@ bool KAddressBookMain::queryClose() void KAddressBookMain::initActions() { - KStdAction::quit( this, TQT_SLOT( close() ), actionCollection() ); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() ); KAction *action; - action = KStdAction::keyBindings( this, TQT_SLOT( configureKeyBindings() ), actionCollection() ); + action = KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( configureKeyBindings() ), actionCollection() ); action->setWhatsThis( i18n( "You will be presented with a dialog, where you can configure the application wide shortcuts." ) ); - KStdAction::configureToolbars( this, TQT_SLOT( configureToolbars() ), actionCollection() ); + KStdAction::configureToolbars( TQT_TQOBJECT(this), TQT_SLOT( configureToolbars() ), actionCollection() ); } void KAddressBookMain::configureKeyBindings() diff --git a/kaddressbook/kaddressbookmain.h b/kaddressbook/kaddressbookmain.h index 0047f534a..7867634db 100644 --- a/kaddressbook/kaddressbookmain.h +++ b/kaddressbook/kaddressbookmain.h @@ -55,7 +55,11 @@ class KAddressBookMain : public KMainWindow, virtual public KAddressBookIface virtual void addEmail( TQString addr ); virtual void importVCard( const KURL& url ); virtual void importVCardFromData( const TQString& vCard ); +#ifndef Q_MOC_RUN virtual ASYNC showContactEditor( TQString uid ); +#else // QT_MOC_RUN + virtual void showContactEditor( TQString uid ); +#endif // QT_MOC_RUN virtual void newContact(); virtual void newDistributionList(); virtual TQString getNameByPhone( TQString phone ); diff --git a/kaddressbook/kcmconfigs/addresseewidget.cpp b/kaddressbook/kcmconfigs/addresseewidget.cpp index b68e96c67..f1a3f525d 100644 --- a/kaddressbook/kcmconfigs/addresseewidget.cpp +++ b/kaddressbook/kcmconfigs/addresseewidget.cpp @@ -46,7 +46,7 @@ NamePartWidget::NamePartWidget( const TQString &title, const TQString &label, { TQHBoxLayout *tqlayout = new TQHBoxLayout( this ); - TQGroupBox *group = new TQGroupBox( 0, TQt::Vertical, title, this ); + TQGroupBox *group = new TQGroupBox( 0, Qt::Vertical, title, this ); TQGridLayout *groupLayout = new TQGridLayout( group->tqlayout(), 2, 2, KDialog::spacingHint() ); @@ -55,11 +55,11 @@ NamePartWidget::NamePartWidget( const TQString &title, const TQString &label, TQT_SLOT( selectionChanged( TQListBoxItem* ) ) ); groupLayout->addWidget( mBox, 0, 0 ); - KButtonBox *bbox = new KButtonBox( group, TQt::Vertical ); - mAddButton = bbox->addButton( i18n( "Add..." ), this, TQT_SLOT( add() ) ); - mEditButton = bbox->addButton( i18n( "Edit..." ), this, TQT_SLOT( edit() ) ); + KButtonBox *bbox = new KButtonBox( group, Qt::Vertical ); + mAddButton = bbox->addButton( i18n( "Add..." ), TQT_TQOBJECT(this), TQT_SLOT( add() ) ); + mEditButton = bbox->addButton( i18n( "Edit..." ), TQT_TQOBJECT(this), TQT_SLOT( edit() ) ); mEditButton->setEnabled( false ); - mRemoveButton = bbox->addButton( i18n( "Remove" ), this, TQT_SLOT( remove() ) ); + mRemoveButton = bbox->addButton( i18n( "Remove" ), TQT_TQOBJECT(this), TQT_SLOT( remove() ) ); mRemoveButton->setEnabled( false ); bbox->tqlayout(); groupLayout->addWidget( bbox, 0, 1 ); diff --git a/kaddressbook/kcmconfigs/kabconfigwidget.cpp b/kaddressbook/kcmconfigs/kabconfigwidget.cpp index c65255db4..f2899ba35 100644 --- a/kaddressbook/kcmconfigs/kabconfigwidget.cpp +++ b/kaddressbook/kcmconfigs/kabconfigwidget.cpp @@ -59,7 +59,7 @@ KABConfigWidget::KABConfigWidget( TQWidget *tqparent, const char *name ) TQVBoxLayout *tqlayout = new TQVBoxLayout( generalPage, KDialog::marginHint(), KDialog::spacingHint() ); - TQGroupBox *groupBox = new TQGroupBox( 0, TQt::Vertical, i18n( "General" ), generalPage ); + TQGroupBox *groupBox = new TQGroupBox( 0, Qt::Vertical, i18n( "General" ), generalPage ); TQBoxLayout *boxLayout = new TQVBoxLayout( groupBox->tqlayout() ); boxLayout->tqsetAlignment( TQt::AlignTop ); @@ -96,7 +96,7 @@ KABConfigWidget::KABConfigWidget( TQWidget *tqparent, const char *name ) tqlayout->addWidget( groupBox ); - groupBox = new TQGroupBox( 0, TQt::Vertical, i18n( "Script-Hooks" ), generalPage ); + groupBox = new TQGroupBox( 0, Qt::Vertical, i18n( "Script-Hooks" ), generalPage ); TQGridLayout *grid = new TQGridLayout( groupBox->tqlayout(), 3, 2, KDialog::spacingHint() ); label = new TQLabel( i18n( "Phone:" ), groupBox ); @@ -126,7 +126,7 @@ KABConfigWidget::KABConfigWidget( TQWidget *tqparent, const char *name ) tqlayout->addWidget( groupBox ); - groupBox = new TQGroupBox( 0, TQt::Vertical, i18n( "Location Map" ), generalPage ); + groupBox = new TQGroupBox( 0, Qt::Vertical, i18n( "Location Map" ), generalPage ); boxLayout = new TQVBoxLayout( groupBox->tqlayout(), KDialog::spacingHint() ); boxLayout->tqsetAlignment( TQt::AlignTop ); @@ -171,7 +171,7 @@ void KABConfigWidget::restoreSettings() mFaxHook->setText( KABPrefs::instance()->faxHookApplication() ); mAddresseeWidget->restoreSettings(); mEditorCombo->setCurrentItem( KABPrefs::instance()->editorType() ); - mLocationMapURL->setCurrentText( KABPrefs::instance()->locationMapURL().arg( KGlobal::locale()->country() ) ); + mLocationMapURL->setCurrentText( KABPrefs::instance()->locationMapURL().tqarg( KGlobal::locale()->country() ) ); mLocationMapURL->lineEdit()->setCursorPosition( 0 ); KConfig config( "kabcrc", false, false ); diff --git a/kaddressbook/kcmconfigs/ldapoptionswidget.cpp b/kaddressbook/kcmconfigs/ldapoptionswidget.cpp index e0bbca236..996da4287 100644 --- a/kaddressbook/kcmconfigs/ldapoptionswidget.cpp +++ b/kaddressbook/kcmconfigs/ldapoptionswidget.cpp @@ -288,10 +288,10 @@ void LDAPOptionsWidget::initGUI() tqlayout->addWidget( groupBox ); KButtonBox *buttons = new KButtonBox( this ); - buttons->addButton( i18n( "&Add Host..." ), this, TQT_SLOT( slotAddHost() ) ); - mEditButton = buttons->addButton( i18n( "&Edit Host..." ), this, TQT_SLOT( slotEditHost() ) ); + buttons->addButton( i18n( "&Add Host..." ), TQT_TQOBJECT(this), TQT_SLOT( slotAddHost() ) ); + mEditButton = buttons->addButton( i18n( "&Edit Host..." ), TQT_TQOBJECT(this), TQT_SLOT( slotEditHost() ) ); mEditButton->setEnabled( false ); - mRemoveButton = buttons->addButton( i18n( "&Remove Host" ), this, TQT_SLOT( slotRemoveHost() ) ); + mRemoveButton = buttons->addButton( i18n( "&Remove Host" ), TQT_TQOBJECT(this), TQT_SLOT( slotRemoveHost() ) ); mRemoveButton->setEnabled( false ); buttons->tqlayout(); diff --git a/kaddressbook/keywidget.cpp b/kaddressbook/keywidget.cpp index 3949cd142..3541ddf1d 100644 --- a/kaddressbook/keywidget.cpp +++ b/kaddressbook/keywidget.cpp @@ -122,7 +122,7 @@ void KeyWidget::addKey() TQFile file( tmpFile ); if ( !file.open( IO_ReadOnly ) ) { TQString text( i18n( "<qt>Unable to open file <b>%1</b>.</qt>" ) ); - KMessageBox::error( this, text.arg( url.url() ) ); + KMessageBox::error( this, text.tqarg( url.url() ) ); return; } @@ -154,7 +154,7 @@ void KeyWidget::removeKey() TQString type = mKeyCombo->currentText(); TQString text = i18n( "<qt>Do you really want to remove the key <b>%1</b>?</qt>" ); - if ( KMessageBox::warningContinueCancel( this, text.arg( type ), "", KGuiItem( i18n("&Delete"), "editdelete") ) == KMessageBox::Cancel ) + if ( KMessageBox::warningContinueCancel( this, text.tqarg( type ), "", KGuiItem( i18n("&Delete"), "editdelete") ) == KMessageBox::Cancel ) return; mKeyList.remove( mKeyList.at( pos ) ); diff --git a/kaddressbook/ldapsearchdialog.cpp b/kaddressbook/ldapsearchdialog.cpp index f23049909..19b5dd6cf 100644 --- a/kaddressbook/ldapsearchdialog.cpp +++ b/kaddressbook/ldapsearchdialog.cpp @@ -152,7 +152,7 @@ LDAPSearchDialog::LDAPSearchDialog( KABC::AddressBook *ab, KABCore *core, page ); groupBox->setFrameShape( TQGroupBox::Box ); groupBox->setFrameShadow( TQGroupBox::Sunken ); - groupBox->setColumnLayout( 0, TQt::Vertical ); + groupBox->setColumnLayout( 0, Qt::Vertical ); TQGridLayout *boxLayout = new TQGridLayout( groupBox->tqlayout(), 2, 5, spacingHint() ); boxLayout->setColStretch( 1, 1 ); @@ -202,9 +202,9 @@ LDAPSearchDialog::LDAPSearchDialog( KABC::AddressBook *ab, KABCore *core, mResultListView->setShowSortIndicator( true ); topLayout->addWidget( mResultListView ); - KButtonBox *buttons = new KButtonBox( page, TQt::Horizontal ); - buttons->addButton( i18n( "Select All" ), this, TQT_SLOT( slotSelectAll() ) ); - buttons->addButton( i18n( "Unselect All" ), this, TQT_SLOT( slotUnselectAll() ) ); + KButtonBox *buttons = new KButtonBox( page, Qt::Horizontal ); + buttons->addButton( i18n( "Select All" ), TQT_TQOBJECT(this), TQT_SLOT( slotSelectAll() ) ); + buttons->addButton( i18n( "Unselect All" ), TQT_TQOBJECT(this), TQT_SLOT( slotUnselectAll() ) ); topLayout->addWidget( buttons ); @@ -264,7 +264,7 @@ void LDAPSearchDialog::restoreSettings() } else { mIsOK = true; for ( int j = 0; j < mNumHosts; ++j ) { - KPIM::LdapClient* ldapClient = new KPIM::LdapClient( 0, this, "ldapclient" ); + KPIM::LdapClient* ldapClient = new KPIM::LdapClient( 0, TQT_TQOBJECT(this), "ldapclient" ); KPIM::LdapServer ldapServer; KPIM::LdapSearch::readConfig( ldapServer, config, j, true ); ldapClient->setServer( ldapServer ); @@ -361,15 +361,15 @@ TQString LDAPSearchDialog::makeFilter( const TQString& query, const TQString& at if ( attr == i18n( "Name" ) ) { result += startsWith ? "|(cn=%1*)(sn=%2*)" : "|(cn=*%1*)(sn=*%2*)"; - result = result.arg( query ).arg( query ); + result = result.tqarg( query ).tqarg( query ); } else { result += (startsWith ? "%1=%2*" : "%1=*%2*"); if ( attr == i18n( "Email" ) ) { - result = result.arg( "mail" ).arg( query ); + result = result.tqarg( "mail" ).tqarg( query ); } else if ( attr == i18n( "Home Number" ) ) { - result = result.arg( "homePhone" ).arg( query ); + result = result.tqarg( "homePhone" ).tqarg( query ); } else if ( attr == i18n( "Work Number" ) ) { - result = result.arg( "telephoneNumber" ).arg( query ); + result = result.tqarg( "telephoneNumber" ).tqarg( query ); } else { // Error? result = TQString(); @@ -573,7 +573,7 @@ KABC::Addressee::List LDAPSearchDialog::importContactsUnlessTheyExist( const TQV if ( existing.isEmpty() ) { addr.setUid( KApplication::randomString( 10 ) ); - addr.setNote( i18n( "arguments are host name, datetime", "Imported from LDAP directory %1 on %2" ).arg( d->itemToServer[cli], KGlobal::locale()->formatDateTime( now ) ) ); + addr.setNote( i18n( "arguments are host name, datetime", "Imported from LDAP directory %1 on %2" ).tqarg( d->itemToServer[cli], KGlobal::locale()->formatDateTime( now ) ) ); addr.setResource( resource ); mCore->addressBook()->insertAddressee( addr ); TQString displayString; diff --git a/kaddressbook/phoneeditwidget.cpp b/kaddressbook/phoneeditwidget.cpp index 2587ad3e6..fc05df184 100644 --- a/kaddressbook/phoneeditwidget.cpp +++ b/kaddressbook/phoneeditwidget.cpp @@ -97,7 +97,7 @@ void PhoneTypeCombo::update() } } - setCurrentItem( mLastSelected = mTypeList.findIndex( mType ) ); + setCurrentItem( mLastSelected = mTypeList.tqfindIndex( mType ) ); blockSignals( blocked ); } @@ -183,7 +183,7 @@ PhoneEditWidget::PhoneEditWidget( TQWidget *tqparent, const char *name ) mRemoveButton->setMaximumSize( mRemoveButton->tqsizeHint() ); tqlayout->addWidget( mRemoveButton, 1, 1 ); - mMapper = new TQSignalMapper( this ); + mMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mMapper, TQT_SIGNAL( mapped( int ) ), TQT_SLOT( changed( int ) ) ); connect( mAddButton, TQT_SIGNAL( clicked() ), TQT_SLOT( add() ) ); @@ -271,7 +271,7 @@ void PhoneEditWidget::recreateNumberWidgets() PhoneNumberWidget *wdg = new PhoneNumberWidget( this ); wdg->setNumber( *it ); - mMapper->setMapping( wdg, counter ); + mMapper->setMapping( TQT_TQOBJECT(wdg), counter ); connect( wdg, TQT_SIGNAL( modified() ), mMapper, TQT_SLOT( map() ) ); mWidgetLayout->addWidget( wdg ); @@ -303,7 +303,7 @@ PhoneTypeDialog::PhoneTypeDialog( int type, TQWidget *tqparent ) mPreferredBox = new TQCheckBox( i18n( "This is the preferred phone number" ), page ); tqlayout->addWidget( mPreferredBox ); - mGroup = new TQButtonGroup( 2, Horizontal, i18n( "Types" ), page ); + mGroup = new TQButtonGroup( 2, Qt::Horizontal, i18n( "Types" ), page ); tqlayout->addWidget( mGroup ); // fill widgets diff --git a/kaddressbook/printing/mikesstyle.cpp b/kaddressbook/printing/mikesstyle.cpp index d7fb26b8d..63cfdcfd0 100644 --- a/kaddressbook/printing/mikesstyle.cpp +++ b/kaddressbook/printing/mikesstyle.cpp @@ -205,7 +205,7 @@ void MikesStyle::paintTagLine( TQPainter &p, const TQFont &font ) TQFontMetrics fm( font ); TQString text = i18n( "Printed on %1 by KAddressBook (http://www.kde.org)" ) - .arg( KGlobal::locale()->formatDateTime( TQDateTime::tqcurrentDateTime() ) ); + .tqarg( KGlobal::locale()->formatDateTime( TQDateTime::tqcurrentDateTime() ) ); p.setPen( TQt::black ); p.drawText( 0, fm.height(), text ); diff --git a/kaddressbook/printing/selectionpage.cpp b/kaddressbook/printing/selectionpage.cpp index bf0a49a08..516431a55 100644 --- a/kaddressbook/printing/selectionpage.cpp +++ b/kaddressbook/printing/selectionpage.cpp @@ -51,7 +51,7 @@ SelectionPage::SelectionPage( TQWidget* tqparent, const char* name ) mButtonGroup = new TQButtonGroup( this ); mButtonGroup->setFrameShape( TQButtonGroup::NoFrame ); - mButtonGroup->setColumnLayout( 0, TQt::Vertical ); + mButtonGroup->setColumnLayout( 0, Qt::Vertical ); mButtonGroup->tqlayout()->setSpacing( KDialog::spacingHint() ); mButtonGroup->tqlayout()->setMargin( KDialog::marginHint() ); diff --git a/kaddressbook/printing/stylepage.cpp b/kaddressbook/printing/stylepage.cpp index 721cffaa0..760f71d6c 100644 --- a/kaddressbook/printing/stylepage.cpp +++ b/kaddressbook/printing/stylepage.cpp @@ -121,7 +121,7 @@ void StylePage::initGUI() topLayout->addMultiCellWidget( label, 0, 0, 0, 1 ); TQButtonGroup *group = new TQButtonGroup( i18n( "Sorting" ), this ); - group->setColumnLayout( 0, TQt::Vertical ); + group->setColumnLayout( 0, Qt::Vertical ); TQGridLayout *sortLayout = new TQGridLayout( group->tqlayout(), 2, 2, KDialog::spacingHint() ); sortLayout->tqsetAlignment( TQt::AlignTop ); @@ -141,7 +141,7 @@ void StylePage::initGUI() topLayout->addWidget( group, 1, 0 ); group = new TQButtonGroup( i18n( "Print Style" ), this ); - group->setColumnLayout( 0, TQt::Vertical ); + group->setColumnLayout( 0, Qt::Vertical ); TQVBoxLayout *styleLayout = new TQVBoxLayout( group->tqlayout(), KDialog::spacingHint() ); diff --git a/kaddressbook/searchmanager.cpp b/kaddressbook/searchmanager.cpp index 462451f3e..32b898cd8 100644 --- a/kaddressbook/searchmanager.cpp +++ b/kaddressbook/searchmanager.cpp @@ -109,11 +109,11 @@ void SearchManager::search( const TQString &pattern, const KABC::Field::List &fi const KABC::Field::List::ConstIterator fieldEndIt( fieldList.end() ); for ( ; fieldIt != fieldEndIt; ++fieldIt ) { - if ( type == StartsWith && (*fieldIt)->value( *it ).startsWith( pattern, false ) ) { + if ( type == StartsWith && (*fieldIt)->value( *it ).tqstartsWith( pattern, false ) ) { mContacts.append( *it ); found = true; break; - } else if ( type == EndsWith && (*fieldIt)->value( *it ).endsWith( pattern, false ) ) { + } else if ( type == EndsWith && (*fieldIt)->value( *it ).tqendsWith( pattern, false ) ) { mContacts.append( *it ); found = true; break; @@ -138,10 +138,10 @@ void SearchManager::search( const TQString &pattern, const KABC::Field::List &fi int pos = (*customIt).tqfind( ':' ); if ( pos != -1 ) { const TQString value = (*customIt).mid( pos + 1 ); - if ( type == StartsWith && value.startsWith( pattern, false ) ) { + if ( type == StartsWith && value.tqstartsWith( pattern, false ) ) { mContacts.append( *it ); break; - } else if ( type == EndsWith && value.endsWith( pattern, false ) ) { + } else if ( type == EndsWith && value.tqendsWith( pattern, false ) ) { mContacts.append( *it ); break; } else if ( type == Contains && value.tqfind( pattern, 0, false ) != -1 ) { diff --git a/kaddressbook/typecombo.h b/kaddressbook/typecombo.h index 0648bf427..7280b5c7d 100644 --- a/kaddressbook/typecombo.h +++ b/kaddressbook/typecombo.h @@ -91,8 +91,8 @@ void TypeCombo<T>::updateTypes() } labelCount[ type ] = count; if ( count > 1 ) { - label = i18n("label (number)", "%1 (%2)").arg( label ) - .arg( TQString::number( count ) ); + label = i18n("label (number)", "%1 (%2)").tqarg( label ) + .tqarg( TQString::number( count ) ); } insertItem( label ); } diff --git a/kaddressbook/undocmds.cpp b/kaddressbook/undocmds.cpp index c0cd5a8a6..e05024bdc 100644 --- a/kaddressbook/undocmds.cpp +++ b/kaddressbook/undocmds.cpp @@ -261,7 +261,7 @@ void CutCommand::unexecute() mAddresseeList.clear(); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); kapp->processEvents(); cb->setText( mOldText ); } @@ -289,7 +289,7 @@ void CutCommand::execute() // Convert to clipboard mClipText = AddresseeUtil::addresseesToClipboard( mAddresseeList ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); mOldText = cb->text(); kapp->processEvents(); #if defined(KABC_VCARD_ENCODING_FIX) @@ -391,7 +391,7 @@ void MoveToCommand::moveContactTo( KABC::Resource *resource ) addressBook()->insertAddressee( newAddr ); mAddresseeList.append( newAddr ); mUIDList.append( uid ); - const bool inserted = addressBook()->tqfind( newAddr ) != addressBook()->end(); + const bool inserted = addressBook()->find( newAddr ) != addressBook()->end(); if ( inserted ) { if ( resourceExist( addr.resource() ) ) { KABLock::self( addressBook() )->lock( addr.resource() ); diff --git a/kaddressbook/viewmanager.cpp b/kaddressbook/viewmanager.cpp index e6d046450..23b1a4cc2 100644 --- a/kaddressbook/viewmanager.cpp +++ b/kaddressbook/viewmanager.cpp @@ -307,7 +307,7 @@ void ViewManager::editView() void ViewManager::deleteView() { TQString text = i18n( "<qt>Are you sure that you want to delete the view <b>%1</b>?</qt>" ) - .arg( mActiveView->caption() ); + .tqarg( mActiveView->caption() ); TQString caption = i18n( "Confirm Delete" ); if ( KMessageBox::warningContinueCancel( this, text, caption, KGuiItem( i18n("&Delete"), "editdelete") ) == KMessageBox::Continue ) { @@ -348,7 +348,7 @@ void ViewManager::addView() firstConflict = false; } - newName = TQString( "%1 <%2>" ).arg( newName ).arg( numTries ); + newName = TQString( "%1 <%2>" ).tqarg( newName ).tqarg( numTries ); numTries++; } @@ -363,7 +363,7 @@ void ViewManager::addView() // try to set the active view mActionSelectView->setItems( mViewNameList ); - mActionSelectView->setCurrentItem( mViewNameList.findIndex( newName ) ); + mActionSelectView->setCurrentItem( mViewNameList.tqfindIndex( newName ) ); setActiveView( newName ); editView(); @@ -387,7 +387,7 @@ void ViewManager::scrollDown() void ViewManager::createViewFactories() { const KTrader::OfferList plugins = KTrader::self()->query( "KAddressBook/View", - TQString( "[X-KDE-KAddressBook-ViewPluginVersion] == %1" ).arg( KAB_VIEW_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KAddressBook-ViewPluginVersion] == %1" ).tqarg( KAB_VIEW_PLUGIN_VERSION ) ); KTrader::OfferList::ConstIterator it; for ( it = plugins.begin(); it != plugins.end(); ++it ) { if ( !(*it)->hasServiceType( "KAddressBook/View" ) ) @@ -573,27 +573,27 @@ void ViewManager::initActions() KAction *action; - action = new KAction( i18n( "Modify View..." ), "configure", 0, this, + action = new KAction( i18n( "Modify View..." ), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT( editView() ), mCore->actionCollection(), "view_modify" ); action->setWhatsThis( i18n( "By pressing this button a dialog opens that allows you to modify the view of the addressbook. There you can add or remove fields that you want to be shown or hidden in the addressbook like the name for example." ) ); - action = new KAction( i18n( "Add View..." ), "window_new", 0, this, + action = new KAction( i18n( "Add View..." ), "window_new", 0, TQT_TQOBJECT(this), TQT_SLOT( addView() ), mCore->actionCollection(), "view_add" ); action->setWhatsThis( i18n( "You can add a new view by choosing one from the dialog that appears after pressing the button. You have to give the view a name, so that you can distinguish between the different views." ) ); mActionDeleteView = new KAction( i18n( "Delete View" ), "view_remove", 0, - this, TQT_SLOT( deleteView() ), + TQT_TQOBJECT(this), TQT_SLOT( deleteView() ), mCore->actionCollection(), "view_delete" ); mActionDeleteView->setWhatsThis( i18n( "By pressing this button you can delete the actual view, which you have added before." ) ); - action = new KAction( i18n( "Refresh View" ), "reload", 0, this, + action = new KAction( i18n( "Refresh View" ), "reload", 0, TQT_TQOBJECT(this), TQT_SLOT( refreshView() ), mCore->actionCollection(), "view_refresh" ); action->setWhatsThis( i18n( "The view will be refreshed by pressing this button." ) ); - action = new KAction( i18n( "Edit &Filters..." ), "filter", 0, this, + action = new KAction( i18n( "Edit &Filters..." ), "filter", 0, TQT_TQOBJECT(this), TQT_SLOT( configureFilters() ), mCore->actionCollection(), "options_edit_filters" ); action->setWhatsThis( i18n( "Edit the contact filters<p>You will be presented with a dialog, where you can add, remove and edit filters." ) ); diff --git a/kaddressbook/views/cardview.cpp b/kaddressbook/views/cardview.cpp index 9149c6536..110d3be84 100644 --- a/kaddressbook/views/cardview.cpp +++ b/kaddressbook/views/cardview.cpp @@ -61,7 +61,7 @@ class CardViewTip : public TQLabel }; // -// Warning: make sure you use findRef() instead of tqfind() to find an +// Warning: make sure you use tqfindRef() instead of tqfind() to find an // item! Only the pointer value is unique in the list. // class CardViewItemList : public TQPtrList<CardViewItem> @@ -316,7 +316,7 @@ void CardViewItem::paintCard( TQPainter *p, TQColorGroup &cg ) // if we are the current item and the view has focus, draw focus rect if ( mView->currentItem() == this && mView->hasFocus() ) { - mView->style().drawPrimitive( TQStyle::PE_FocusRect, p, + mView->tqstyle().tqdrawPrimitive( TQStyle::PE_FocusRect, p, TQRect( 0, 0, mView->itemWidth(), h + (2 * mg) ), cg, TQStyle::Style_FocusAtBorder, TQStyleOption( isSelected() ? cg.highlight() : cg.base() ) ); @@ -587,7 +587,7 @@ CardView::CardView( TQWidget *tqparent, const char *name ) viewport()->setMouseTracking( true ); viewport()->setFocusProxy( this ); - viewport()->setFocusPolicy( WheelFocus ); + viewport()->setFocusPolicy(Qt::WheelFocus ); viewport()->setBackgroundMode( PaletteBase ); connect( d->mTimer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( tryShowFullText() ) ); @@ -616,7 +616,7 @@ void CardView::takeItem( CardViewItem *item ) { if ( d->mCurrentItem == item ) d->mCurrentItem = item->nextItem(); - d->mItemList.take( d->mItemList.findRef( item ) ); + d->mItemList.take( d->mItemList.tqfindRef( item ) ); setLayoutDirty( true ); } @@ -843,7 +843,7 @@ void CardView::drawContents( TQPainter *p, int clipx, int clipy, calcLayout(); // allow setting costum colors in the viewport pale - TQColorGroup cg = viewport()->palette().active(); + TQColorGroup cg = viewport()->tqpalette().active(); TQRect clipRect( clipx, clipy, clipw, cliph ); TQRect cardRect; @@ -953,7 +953,7 @@ void CardView::calcLayout() CardViewItem *CardView::itemAfter( const CardViewItem *item ) const { - d->mItemList.findRef( item ); + d->mItemList.tqfindRef( item ); return d->mItemList.next(); } @@ -1022,7 +1022,7 @@ void CardView::contentsMousePressEvent( TQMouseEvent *e ) emit clicked( item ); // The RMB click - if ( e->button() & TQt::RightButton ) { + if ( e->button() & Qt::RightButton ) { // clear previous selection bool blocked = signalsBlocked(); blockSignals( true ); @@ -1056,7 +1056,7 @@ void CardView::contentsMousePressEvent( TQMouseEvent *e ) item->tqrepaintCard(); emit selectionChanged(); } else if ( d->mSelectionMode == CardView::Extended ) { - if ( (e->button() & TQt::LeftButton) && (e->state() & TQt::ShiftButton) ) { + if ( (e->button() & Qt::LeftButton) && (e->state() & TQt::ShiftButton) ) { if ( item == other ) return; @@ -1070,8 +1070,8 @@ void CardView::contentsMousePressEvent( TQMouseEvent *e ) } int from, to, a, b; - a = d->mItemList.findRef( item ); - b = d->mItemList.findRef( other ); + a = d->mItemList.tqfindRef( item ); + b = d->mItemList.tqfindRef( other ); from = a < b ? a : b; to = a > b ? a : b; @@ -1083,11 +1083,11 @@ void CardView::contentsMousePressEvent( TQMouseEvent *e ) } emit selectionChanged(); - } else if ( (e->button() & TQt::LeftButton) && (e->state() & TQt::ControlButton) ) { + } else if ( (e->button() & Qt::LeftButton) && (e->state() & TQt::ControlButton) ) { item->setSelected( !item->isSelected() ); item->tqrepaintCard(); emit selectionChanged(); - } else if ( e->button() & TQt::LeftButton ) { + } else if ( e->button() & Qt::LeftButton ) { bool b = signalsBlocked(); blockSignals( true ); selectAll( false ); @@ -1158,7 +1158,7 @@ void CardView::contentsMouseMoveEvent( TQMouseEvent *e ) return; } - if ( d->mLastClickOnItem && (e->state() & TQt::LeftButton) && + if ( d->mLastClickOnItem && (e->state() & Qt::LeftButton) && ((e->pos() - d->mLastClickPos).manhattanLength() > 4)) { startDrag(); @@ -1218,7 +1218,7 @@ void CardView::keyPressEvent( TQKeyEvent *e ) return; } - uint pos = d->mItemList.findRef( d->mCurrentItem ); + uint pos = d->mItemList.tqfindRef( d->mCurrentItem ); CardViewItem *aItem = 0; CardViewItem *old = d->mCurrentItem; @@ -1347,8 +1347,8 @@ void CardView::keyPressEvent( TQKeyEvent *e ) // otherwise, ?????? bool s = ! aItem->isSelected(); int from, to, a, b; - a = d->mItemList.findRef( aItem ); - b = d->mItemList.findRef( old ); + a = d->mItemList.tqfindRef( aItem ); + b = d->mItemList.tqfindRef( old ); from = a < b ? a : b; to = a > b ? a : b; diff --git a/kaddressbook/views/configurecardviewdialog.cpp b/kaddressbook/views/configurecardviewdialog.cpp index fdccd52f0..834431af9 100644 --- a/kaddressbook/views/configurecardviewdialog.cpp +++ b/kaddressbook/views/configurecardviewdialog.cpp @@ -201,7 +201,7 @@ void CardViewLookNFeelPage::initGUI() loTab->setSpacing( spacing ); loTab->setMargin( margin ); - TQGroupBox *gbGeneral = new TQGroupBox( 1, TQt::Horizontal, i18n("General"), loTab ); + TQGroupBox *gbGeneral = new TQGroupBox( 1, Qt::Horizontal, i18n("General"), loTab ); cbDrawSeps = new TQCheckBox( i18n("Draw &separators"), gbGeneral ); @@ -215,7 +215,7 @@ void CardViewLookNFeelPage::initGUI() sbSpacing = new TQSpinBox( 0, 100, 1, hbPadding ); lSpacing->setBuddy( sbSpacing ); - TQGroupBox *gbCards = new TQGroupBox( 1, TQt::Horizontal, i18n("Cards"), loTab ); + TQGroupBox *gbCards = new TQGroupBox( 1, Qt::Horizontal, i18n("Cards"), loTab ); TQHBox *hbMargin = new TQHBox( gbCards ); TQLabel *lMargin = new TQLabel( i18n("&Margin:"), hbMargin ); @@ -313,7 +313,7 @@ void CardViewLookNFeelPage::initGUI() void CardViewLookNFeelPage::updateFontLabel( TQFont fnt, TQLabel *l ) { l->setFont( fnt ); - l->setText( TQString( fnt.family() + " %1" ).arg( fnt.pointSize() ) ); + l->setText( TQString( fnt.family() + " %1" ).tqarg( fnt.pointSize() ) ); } #include "configurecardviewdialog.moc" diff --git a/kaddressbook/views/configuretableviewdialog.cpp b/kaddressbook/views/configuretableviewdialog.cpp index 309244e5d..179a819a9 100644 --- a/kaddressbook/views/configuretableviewdialog.cpp +++ b/kaddressbook/views/configuretableviewdialog.cpp @@ -113,7 +113,7 @@ void LookAndFeelPage::initGUI() { TQVBoxLayout *tqlayout = new TQVBoxLayout(this, 0, KDialogBase::spacingHint()); - TQButtonGroup *group = new TQButtonGroup(1, TQt::Horizontal, + TQButtonGroup *group = new TQButtonGroup(1, Qt::Horizontal, i18n("Row Separator"), this); tqlayout->addWidget(group); diff --git a/kaddressbook/views/contactlistview.cpp b/kaddressbook/views/contactlistview.cpp index 548ad5f98..31f0ac6ca 100644 --- a/kaddressbook/views/contactlistview.cpp +++ b/kaddressbook/views/contactlistview.cpp @@ -82,17 +82,17 @@ void DynamicTip::maybeTip( const TQPoint &pos ) if (a.isEmpty()) return; - s += i18n("label: value", "%1: %2").arg(a.formattedNameLabel()) - .arg(a.formattedName()); + s += i18n("label: value", "%1: %2").tqarg(a.formattedNameLabel()) + .tqarg(a.formattedName()); s += '\n'; - s += i18n("label: value", "%1: %2").arg(a.organizationLabel()) - .arg(a.organization()); + s += i18n("label: value", "%1: %2").tqarg(a.organizationLabel()) + .tqarg(a.organization()); TQString notes = a.note().stripWhiteSpace(); if ( !notes.isEmpty() ) { notes += '\n'; - s += '\n' + i18n("label: value", "%1: \n").arg(a.noteLabel()); + s += '\n' + i18n("label: value", "%1: \n").tqarg(a.noteLabel()); TQFontMetrics fm( font() ); // Begin word wrap code based on TQMultiLineEdit code @@ -314,7 +314,7 @@ void ContactListView::contentsMousePressEvent(TQMouseEvent* e) // To initiate a drag operation void ContactListView::contentsMouseMoveEvent( TQMouseEvent *e ) { - if ((e->state() & LeftButton) && (e->pos() - presspos).manhattanLength() > 4 ) { + if ((e->state() & Qt::LeftButton) && (e->pos() - presspos).manhattanLength() > 4 ) { emit startAddresseeDrag(); } else diff --git a/kaddressbook/xxport/csv_xxport.cpp b/kaddressbook/xxport/csv_xxport.cpp index 5fdc89a5c..fc9ac247c 100644 --- a/kaddressbook/xxport/csv_xxport.cpp +++ b/kaddressbook/xxport/csv_xxport.cpp @@ -50,7 +50,7 @@ bool CSVXXPort::exportContacts( const KABC::AddresseeList &list, const TQString& return true; if( TQFileInfo(url.path()).exists() ) { - if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").arg( url.path()) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").tqarg( url.path()) ) == KMessageBox::No) return false; } @@ -58,8 +58,8 @@ bool CSVXXPort::exportContacts( const KABC::AddresseeList &list, const TQString& KTempFile tmpFile; if ( tmpFile.status() != 0 ) { TQString txt = i18n( "<qt>Unable to open file <b>%1</b>.%2.</qt>" ); - KMessageBox::error( tqparentWidget(), txt.arg( url.url() ) - .arg( strerror( tmpFile.status() ) ) ); + KMessageBox::error( tqparentWidget(), txt.tqarg( url.url() ) + .tqarg( strerror( tmpFile.status() ) ) ); return false; } @@ -71,7 +71,7 @@ bool CSVXXPort::exportContacts( const KABC::AddresseeList &list, const TQString& TQFile file( url.path() ); if ( !file.open( IO_WriteOnly ) ) { TQString txt = i18n( "<qt>Unable to open file <b>%1</b>.</qt>" ); - KMessageBox::error( tqparentWidget(), txt.arg( url.path() ) ); + KMessageBox::error( tqparentWidget(), txt.tqarg( url.path() ) ); return false; } diff --git a/kaddressbook/xxport/csvimportdialog.cpp b/kaddressbook/xxport/csvimportdialog.cpp index 4356a5997..1120e4f06 100644 --- a/kaddressbook/xxport/csvimportdialog.cpp +++ b/kaddressbook/xxport/csvimportdialog.cpp @@ -383,7 +383,7 @@ void CSVImportDialog::initGUI() // Delimiter: comma, semicolon, tab, space, other mDelimiterBox = new TQButtonGroup( i18n( "Delimiter" ), mPage ); - mDelimiterBox->setColumnLayout( 0, TQt::Vertical ); + mDelimiterBox->setColumnLayout( 0, Qt::Vertical ); mDelimiterBox->tqlayout()->setSpacing( spacingHint() ); mDelimiterBox->tqlayout()->setMargin( marginHint() ); TQGridLayout *delimiterLayout = new TQGridLayout( mDelimiterBox->tqlayout() ); @@ -503,7 +503,7 @@ void CSVImportDialog::fillTable() else if ( code == Guess ) { TQTextCodec* codec = TQTextCodec::codecForContent( mFileArray.data(), mFileArray.size() ); if ( codec ) { - KMessageBox::information( this, i18n( "Using codec '%1'" ).arg( codec->name() ), i18n( "Encoding" ) ); + KMessageBox::information( this, i18n( "Using codec '%1'" ).tqarg( codec->name() ), i18n( "Encoding" ) ); inputStream.setCodec( codec ); } } @@ -663,7 +663,7 @@ void CSVImportDialog::reloadCodecs() for ( int i = 0; ( codec = TQTextCodec::codecForIndex( i ) ); i++ ) mCodecs.append( codec ); - mCodecCombo->insertItem( i18n( "Local (%1)" ).arg( TQTextCodec::codecForLocale()->name() ), Local ); + mCodecCombo->insertItem( i18n( "Local (%1)" ).tqarg( TQTextCodec::codecForLocale()->name() ), Local ); mCodecCombo->insertItem( i18n( "[guess]" ), Guess ); mCodecCombo->insertItem( i18n( "Latin1" ), Latin1 ); mCodecCombo->insertItem( i18n( "Unicode" ), Uni ); @@ -858,7 +858,7 @@ void CSVImportDialog::saveTemplate() fileName += ".desktop"; if( TQFileInfo(fileName).exists() ) { - if(KMessageBox::questionYesNo( this, i18n("Do you want to overwrite file \"%1\"").arg(fileName) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( this, i18n("Do you want to overwrite file \"%1\"").tqarg(fileName) ) == KMessageBox::No) return; } TQString name = KInputDialog::getText( i18n( "Template Name" ), i18n( "Please enter a name for the template:" ) ); diff --git a/kaddressbook/xxport/eudora_xxport.cpp b/kaddressbook/xxport/eudora_xxport.cpp index ca804fe30..9844b5507 100644 --- a/kaddressbook/xxport/eudora_xxport.cpp +++ b/kaddressbook/xxport/eudora_xxport.cpp @@ -152,9 +152,9 @@ TQString EudoraXXPort::email( const TQString& line ) const { int b; TQString result; - b = line.findRev( '\"' ); + b = line.tqfindRev( '\"' ); if ( b == -1 ) { - b = line.findRev( ' ' ); + b = line.tqfindRev( ' ' ); if ( b == -1 ) return result; } @@ -168,9 +168,9 @@ TQString EudoraXXPort::comment( const TQString& line ) const int b; TQString result; uint i; - b = line.findRev( '>' ); + b = line.tqfindRev( '>' ); if ( b == -1 ) { - b = line.findRev( '\"' ); + b = line.tqfindRev( '\"' ); if ( b == -1 ) return result; } diff --git a/kaddressbook/xxport/gnokii_xxport.cpp b/kaddressbook/xxport/gnokii_xxport.cpp index 343831a90..053a850e2 100644 --- a/kaddressbook/xxport/gnokii_xxport.cpp +++ b/kaddressbook/xxport/gnokii_xxport.cpp @@ -63,7 +63,7 @@ extern "C" { #define GNOKII_CHECK_ERROR(error) \ do { \ if (error) \ - kdError() << TQString("ERROR %1: %2\n").arg(error).arg(gn_error_print(error));\ + kdError() << TQString("ERROR %1: %2\n").tqarg(error).tqarg(gn_error_print(error));\ } while (0) // Locale conversion routines: @@ -126,8 +126,8 @@ static TQString businit(void) { GNOKII_DEBUG( "Using new gnokii version." ); - GNOKII_DEBUG( TQString("Compiled with libgnokii version 0x%1\n").arg(TQString::number(LIBGNOKII_VERSION,16)) ); - GNOKII_DEBUG( TQString("Using libgnokii runtime version 0x%1\n").arg(TQString::number(gn_lib_version(),16)) ); + GNOKII_DEBUG( TQString("Compiled with libgnokii version 0x%1\n").tqarg(TQString::number(LIBGNOKII_VERSION,16)) ); + GNOKII_DEBUG( TQString("Using libgnokii runtime version 0x%1\n").tqarg(TQString::number(gn_lib_version(),16)) ); gn_error error = gn_lib_phoneprofile_load(NULL, &state); if (error) @@ -142,7 +142,7 @@ static TQString businit(void) "You might try to run \"gnokii --identify\" on the command line to " "check any cable/transport issues and to verify if your gnokii " "configuration is correct.</center></qt>") - .arg(gn_error_print(error)); + .tqarg(gn_error_print(error)); } // identify phone @@ -152,7 +152,7 @@ static TQString businit(void) imei = gn_lib_get_phone_imei(state); GNOKII_DEBUG( TQString("Found mobile phone: %1 %2, Revision: %3, IMEI: %4\n") - .arg(manufacturer, model, revision, imei) ); + .tqarg(manufacturer, model, revision, imei) ); return TQString(); } @@ -166,7 +166,7 @@ static gn_error read_phone_memstat( const gn_memory_type memtype, gn_memory_stat error = gn_lib_addressbook_memstat(state, memtype, &memstat->used, &memstat->free); GNOKII_DEBUG( TQString("\n\nMobile phone memory status: Type: %1, used=%2, free=%3, total=%4\n\n") - .arg(memtype).arg(memstat->used).arg(memstat->free).arg(memstat->used+memstat->free) ); + .tqarg(memtype).tqarg(memstat->used).tqarg(memstat->free).tqarg(memstat->used+memstat->free) ); return error; } @@ -176,13 +176,13 @@ static TQString buildPhoneInfoString( const gn_memory_status &memstat ) TQString format = TQString::tqfromLatin1("<tr><td><b>%1</b></td><td>%2</td></tr>"); return TQString::tqfromLatin1("<b>%1</b><br><table>%2%3%4%5%6</table><br>") - .arg(i18n("Mobile Phone information:")) - .arg(format.arg(i18n("Manufacturer")).arg(GN_FROM(manufacturer))) - .arg(format.arg(i18n("Phone model")).arg(GN_FROM(model))) - .arg(format.arg(i18n("Revision")).arg(GN_FROM(revision))) - .arg(format.arg(i18n("IMEI")).arg(GN_FROM(imei))) - .arg(format.arg(i18n("Phonebook status")) - .arg(i18n("%1 out of %2 contacts used").arg(memstat.used).arg(memstat.used+memstat.free))); + .tqarg(i18n("Mobile Phone information:")) + .tqarg(format.tqarg(i18n("Manufacturer")).tqarg(GN_FROM(manufacturer))) + .tqarg(format.tqarg(i18n("Phone model")).tqarg(GN_FROM(model))) + .tqarg(format.tqarg(i18n("Revision")).tqarg(GN_FROM(revision))) + .tqarg(format.tqarg(i18n("IMEI")).tqarg(GN_FROM(imei))) + .tqarg(format.tqarg(i18n("Phonebook status")) + .tqarg(i18n("%1 out of %2 contacts used").tqarg(memstat.used).tqarg(memstat.used+memstat.free))); } // read and evaluate all phone entries @@ -209,9 +209,9 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty progress->setTotalSteps(memstat.used); m_progressDlg->setLabel(i18n("<qt>Importing <b>%1</b> contacts from <b>%2</b> of the Mobile Phone.<br><br>%3</qt>") - .arg(memstat.used) - .arg(gn_memory_type2str(memtype)) - .arg(buildPhoneInfoString(memstat)) ); + .tqarg(memstat.used) + .tqarg(gn_memory_type2str(memtype)) + .tqarg(buildPhoneInfoString(memstat)) ); int num_read = 0; @@ -233,10 +233,10 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty const char *name = gn_lib_get_pb_name(state); const char *number = gn_lib_get_pb_number(state); - GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").arg(i) - .arg(GN_FROM(name)).arg(GN_FROM(number)) - .arg(gn_lib_get_pb_location(state)).arg(gn_lib_get_pb_caller_group(state)) - .arg(subentries_count)); + GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").tqarg(i) + .tqarg(GN_FROM(name)).tqarg(GN_FROM(number)) + .tqarg(gn_lib_get_pb_location(state)).tqarg(gn_lib_get_pb_caller_group(state)) + .tqarg(subentries_count)); KABC::Addressee *a = new KABC::Addressee(); // try to split Name into FamilyName and GivenName @@ -263,10 +263,10 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty } a->insertCustom(APP, "X_GSM_CALLERGROUP", s.setNum(gn_lib_get_pb_caller_group(state))); - a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1%2").arg(memtypestr).arg(gn_lib_get_pb_location(state))); + a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1%2").tqarg(memtypestr).tqarg(gn_lib_get_pb_location(state))); // set ProductId - a->setProductId(TQString("%1-%2-%3-%4").arg(APP).arg(model).arg(revision).arg(imei)); + a->setProductId(TQString("%1-%2-%3-%4").tqarg(APP).tqarg(model).tqarg(revision).tqarg(imei)); // evaluate timestamp (ignore timezone) TQDateTime datetime; @@ -276,7 +276,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty else datetime = TQDateTime( TQDate(ts.year, ts.month, ts.day), TQTime(ts.hour, ts.minute, ts.second) ); - GNOKII_DEBUG(TQString(" date=%1\n").arg(datetime.toString())); + GNOKII_DEBUG(TQString(" date=%1\n").tqarg(datetime.toString())); a->setRevision(datetime); if (!subentries_count) @@ -295,7 +295,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty TQString s = GN_FROM(number).simplifyWhiteSpace(); GNOKII_DEBUG(TQString(" Subentry#%1, entry_type=%2, number_type=%3, number=%4\n") - .arg(n).arg(entry_type).arg(number_type).arg(s)); + .tqarg(n).tqarg(entry_type).tqarg(number_type).tqarg(s)); if (s.isEmpty()) continue; switch(entry_type) { @@ -362,7 +362,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty break; default: GNOKII_DEBUG(TQString(" Not handled id=%1, entry=%2\n") - .arg(entry_type).arg(s)); + .tqarg(entry_type).tqarg(s)); break; } // switch() } // if(subentry) @@ -425,8 +425,8 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem time.hour(), time.minute(), time.second(), 0 ); gn_lib_set_pb_date(state, ts); - GNOKII_DEBUG(TQString("Write #%1: name=%2, number=%3\n").arg(phone_location) - .arg(GN_FROM(gn_lib_get_pb_name(state))).arg(GN_FROM(gn_lib_get_pb_number(state)))); + GNOKII_DEBUG(TQString("Write #%1: name=%2, number=%3\n").tqarg(phone_location) + .tqarg(GN_FROM(gn_lib_get_pb_name(state))).tqarg(GN_FROM(gn_lib_get_pb_number(state)))); const KABC::Address homeAddr = addr->address(KABC::Address::Home); const KABC::Address workAddr = addr->address(KABC::Address::Work); @@ -467,7 +467,7 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem // only one email allowed if we have URLS, notes, addresses (to avoid phone limitations) if (n && !addr->url().isEmpty() && !addr->note().isEmpty() && addr->addresses().count()) { GNOKII_DEBUG(TQString(" DROPPED email %1 in favor of URLs, notes and addresses.\n") - .arg(s)); + .tqarg(s)); continue; } gn_lib_set_pb_subentry(state, -1 /* index to append entry */, @@ -507,8 +507,8 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem const char *number; gn_lib_get_pb_subentry(state, st, &entry_type, &number_type, &number); GNOKII_DEBUG(TQString(" SubTel #%1: entry_type=%2, number_type=%3, number=%4\n") - .arg(st).arg(entry_type) - .arg(number_type).arg(GN_FROM(number))); + .tqarg(st).tqarg(entry_type) + .tqarg(number_type).tqarg(GN_FROM(number))); } gn_error error = gn_lib_phonebook_write_entry(state, memtype, phone_location); @@ -656,9 +656,9 @@ bool GNOKIIXXPort::exportContacts( const KABC::AddresseeList &list, const TQStri m_progressDlg->setButtonText(i18n("&Stop Export")); m_progressDlg->setLabel(i18n("<qt>Exporting <b>%1</b> contacts to the <b>%2</b> " "of the Mobile Phone.<br><br>%3</qt>") - .arg(list.count()) - .arg(gn_memory_type2str(memtype)) - .arg(buildPhoneInfoString(memstat)) ); + .tqarg(list.count()) + .tqarg(gn_memory_type2str(memtype)) + .tqarg(buildPhoneInfoString(memstat)) ); // Now run the loop... phone_entry_no = 1; @@ -682,7 +682,7 @@ try_next_phone_entry: break; GNOKII_DEBUG(TQString("Try to write entry '%1' at phone_entry_no=%2, phone_count=%3\n") - .arg(addr->realName()).arg(phone_entry_no).arg(phone_count)); + .tqarg(addr->realName()).tqarg(phone_entry_no).tqarg(phone_count)); error = GN_ERR_NONE; @@ -755,7 +755,7 @@ finish: delete m_progressDlg; if (!failedList.isEmpty()) { - GNOKII_DEBUG(TQString("Failed to export: %1\n").arg(failedList.join(", "))); + GNOKII_DEBUG(TQString("Failed to export: %1\n").tqarg(failedList.join(", "))); KMessageBox::informationList(tqparentWidget(), i18n("<qt>The following contacts could not be exported to the Mobile Phone. " "Possible Reasons for this problem could be:<br><ul>" @@ -851,7 +851,7 @@ static TQString businit(void) "You might try to run \"gnokii --identify\" on the command line to " "check any cable/transport issues and to verify if your gnokii " "configuration is correct.</center></qt>") - .arg(gn_error_print(error)); + .tqarg(gn_error_print(error)); } // identify phone @@ -874,9 +874,9 @@ static TQString businit(void) GNOKII_CHECK_ERROR(error); GNOKII_DEBUG( TQString("Found mobile phone: %1 %2, Revision: %3, IMEI: %4\n") - .arg(manufacturer, model, revision, imei) ); + .tqarg(manufacturer, model, revision, imei) ); - PhoneProductId = TQString("%1-%2-%3-%4").arg(APP).arg(model).arg(revision).arg(imei); + PhoneProductId = TQString("%1-%2-%3-%4").tqarg(APP).tqarg(model).tqarg(revision).tqarg(imei); return TQString(); } @@ -908,7 +908,7 @@ static gn_error read_phone_memstat( const gn_memory_type memtype, gn_memory_stat } } GNOKII_DEBUG( TQString("\n\nMobile phone memory status: Type: %1, used=%2, free=%3, total=%4\n\n") - .arg(memtype).arg(memstat->used).arg(memstat->free).arg(memstat->used+memstat->free) ); + .tqarg(memtype).tqarg(memstat->used).tqarg(memstat->free).tqarg(memstat->used+memstat->free) ); return error; } @@ -946,13 +946,13 @@ static TQString buildPhoneInfoString( const gn_memory_status &memstat ) TQString format = TQString::tqfromLatin1("<tr><td><b>%1</b></td><td>%2</td></tr>"); return TQString::tqfromLatin1("<b>%1</b><br><table>%2%3%4%5%6</table><br>") - .arg(i18n("Mobile Phone information:")) - .arg(format.arg(i18n("Manufacturer")).arg(GN_FROM(manufacturer))) - .arg(format.arg(i18n("Phone model")).arg(GN_FROM(model))) - .arg(format.arg(i18n("Revision")).arg(GN_FROM(revision))) - .arg(format.arg(i18n("IMEI")).arg(GN_FROM(imei))) - .arg(format.arg(i18n("Phonebook status")) - .arg(i18n("%1 out of %2 contacts used").arg(memstat.used).arg(memstat.used+memstat.free))); + .tqarg(i18n("Mobile Phone information:")) + .tqarg(format.tqarg(i18n("Manufacturer")).tqarg(GN_FROM(manufacturer))) + .tqarg(format.tqarg(i18n("Phone model")).tqarg(GN_FROM(model))) + .tqarg(format.tqarg(i18n("Revision")).tqarg(GN_FROM(revision))) + .tqarg(format.tqarg(i18n("IMEI")).tqarg(GN_FROM(imei))) + .tqarg(format.tqarg(i18n("Phonebook status")) + .tqarg(i18n("%1 out of %2 contacts used").tqarg(memstat.used).tqarg(memstat.used+memstat.free))); } static TQString buildMemoryTypeString( gn_memory_type memtype ) @@ -989,9 +989,9 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty progress->setTotalSteps(memstat.used); m_progressDlg->setLabel(i18n("<qt>Importing <b>%1</b> contacts from <b>%2</b> of the Mobile Phone.<br><br>%3</qt>") - .arg(memstat.used) - .arg(buildMemoryTypeString(memtype)) - .arg(buildPhoneInfoString(memstat)) ); + .tqarg(memstat.used) + .tqarg(buildMemoryTypeString(memtype)) + .tqarg(buildPhoneInfoString(memstat)) ); int num_read = 0; @@ -1008,8 +1008,8 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty if (error == GN_ERR_INVALIDMEMORYTYPE) break; if (error == GN_ERR_NONE) { - GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").arg(i).arg(GN_FROM(entry.name)) - .arg(GN_FROM(entry.number)).arg(entry.location).arg(entry.caller_group).arg(entry.subentries_count)); + GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").tqarg(i).tqarg(GN_FROM(entry.name)) + .tqarg(GN_FROM(entry.number)).tqarg(entry.location).tqarg(entry.caller_group).tqarg(entry.subentries_count)); KABC::Addressee *a = new KABC::Addressee(); // try to split Name into FamilyName and GivenName @@ -1036,7 +1036,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty } a->insertCustom(APP, "X_GSM_CALLERGROUP", s.setNum(entry.caller_group)); - a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1%2").arg(memtypestr).arg(entry.location)); + a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1%2").tqarg(memtypestr).tqarg(entry.location)); // set ProductId a->setProductId(PhoneProductId); @@ -1048,7 +1048,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty else datetime = TQDateTime( TQDate(entry.date.year, entry.date.month, entry.date.day), TQTime(entry.date.hour, entry.date.minute, entry.date.second) ); - GNOKII_DEBUG(TQString(" date=%1\n").arg(datetime.toString())); + GNOKII_DEBUG(TQString(" date=%1\n").tqarg(datetime.toString())); a->setRevision(datetime); if (!entry.subentries_count) @@ -1059,8 +1059,8 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty for (int n=0; n<entry.subentries_count; n++) { TQString s = GN_FROM(entry.subentries[n].data.number).simplifyWhiteSpace(); GNOKII_DEBUG(TQString(" Subentry#%1, entry_type=%2, number_type=%3, number=%4\n") - .arg(n).arg(entry.subentries[n].entry_type) - .arg(entry.subentries[n].number_type).arg(s)); + .tqarg(n).tqarg(entry.subentries[n].entry_type) + .tqarg(entry.subentries[n].number_type).tqarg(s)); if (s.isEmpty()) continue; switch(entry.subentries[n].entry_type) { @@ -1127,7 +1127,7 @@ static gn_error read_phone_entries( const char *memtypestr, gn_memory_type memty break; default: GNOKII_DEBUG(TQString(" Not handled id=%1, entry=%2\n") - .arg(entry.subentries[n].entry_type).arg(s)); + .tqarg(entry.subentries[n].entry_type).tqarg(s)); break; } // switch() } // if(subentry) @@ -1191,8 +1191,8 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem entry.date.minute = time.minute(); entry.date.second = time.second(); - GNOKII_DEBUG(TQString("Write #%1: name=%2, number=%3\n").arg(phone_location) - .arg(GN_FROM(entry.name)).arg(GN_FROM(entry.number))); + GNOKII_DEBUG(TQString("Write #%1: name=%2, number=%3\n").tqarg(phone_location) + .tqarg(GN_FROM(entry.name)).tqarg(GN_FROM(entry.number))); const KABC::Address homeAddr = addr->address(KABC::Address::Home); const KABC::Address workAddr = addr->address(KABC::Address::Work); @@ -1244,7 +1244,7 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem // only one email allowed if we have URLS, notes, addresses (to avoid phone limitations) if (n && !addr->url().isEmpty() && !addr->note().isEmpty() && addr->addresses().count()) { GNOKII_DEBUG(TQString(" DROPPED email %1 in favor of URLs, notes and addresses.\n") - .arg(s)); + .tqarg(s)); continue; } subentry->entry_type = GN_PHONEBOOK_ENTRY_Email; @@ -1289,8 +1289,8 @@ static gn_error xxport_phone_write_entry( int phone_location, gn_memory_type mem for (int st=0; st<entry.subentries_count; st++) { gn_phonebook_subentry *subentry = &entry.subentries[st]; GNOKII_DEBUG(TQString(" SubTel #%1: entry_type=%2, number_type=%3, number=%4\n") - .arg(st).arg(subentry->entry_type) - .arg(subentry->number_type).arg(GN_FROM(subentry->data.number))); + .tqarg(st).tqarg(subentry->entry_type) + .tqarg(subentry->number_type).tqarg(GN_FROM(subentry->data.number))); } data.phonebook_entry = &entry; @@ -1309,7 +1309,7 @@ static gn_error xxport_phone_delete_entry( int phone_location, gn_memory_type me entry.memory_type = memtype; entry.location = phone_location; data.phonebook_entry = &entry; - GNOKII_DEBUG(TQString("Deleting entry %1\n").arg(phone_location)); + GNOKII_DEBUG(TQString("Deleting entry %1\n").tqarg(phone_location)); gn_error error = gn_sm_functions(GN_OP_WritePhonebook, &data, &state); GNOKII_CHECK_ERROR(error); return error; @@ -1447,9 +1447,9 @@ bool GNOKIIXXPort::exportContacts( const KABC::AddresseeList &list, const TQStri m_progressDlg->setButtonText(i18n("&Stop Export")); m_progressDlg->setLabel(i18n("<qt>Exporting <b>%1</b> contacts to the <b>%2</b> " "of the Mobile Phone.<br><br>%3</qt>") - .arg(list.count()) - .arg(buildMemoryTypeString(memtype)) - .arg(buildPhoneInfoString(memstat)) ); + .tqarg(list.count()) + .tqarg(buildMemoryTypeString(memtype)) + .tqarg(buildPhoneInfoString(memstat)) ); // Now run the loop... phone_entry_no = 1; @@ -1473,7 +1473,7 @@ try_next_phone_entry: break; GNOKII_DEBUG(TQString("Try to write entry '%1' at phone_entry_no=%2, phone_count=%3\n") - .arg(addr->realName()).arg(phone_entry_no).arg(phone_count)); + .tqarg(addr->realName()).tqarg(phone_entry_no).tqarg(phone_count)); error = GN_ERR_NONE; @@ -1546,7 +1546,7 @@ finish: delete m_progressDlg; if (!failedList.isEmpty()) { - GNOKII_DEBUG(TQString("Failed to export: %1\n").arg(failedList.join(", "))); + GNOKII_DEBUG(TQString("Failed to export: %1\n").tqarg(failedList.join(", "))); KMessageBox::informationList(tqparentWidget(), i18n("<qt>The following contacts could not be exported to the Mobile Phone. " "Possible Reasons for this problem could be:<br><ul>" diff --git a/kaddressbook/xxport/kde2_xxport.cpp b/kaddressbook/xxport/kde2_xxport.cpp index b0e44c3db..f5848d1ce 100644 --- a/kaddressbook/xxport/kde2_xxport.cpp +++ b/kaddressbook/xxport/kde2_xxport.cpp @@ -49,7 +49,7 @@ KABC::AddresseeList KDE2XXPort::importContacts( const TQString& ) const { TQString fileName = locateLocal( "data", "kabc/std.vcf" ); if ( !TQFile::exists( fileName ) ) { - KMessageBox::sorry( tqparentWidget(), i18n( "<qt>Could not find a KDE 2 address book <b>%1</b>.</qt>" ).arg( fileName ) ); + KMessageBox::sorry( tqparentWidget(), i18n( "<qt>Could not find a KDE 2 address book <b>%1</b>.</qt>" ).tqarg( fileName ) ); return KABC::AddresseeList(); } diff --git a/kaddressbook/xxport/ldif_xxport.cpp b/kaddressbook/xxport/ldif_xxport.cpp index 307fb6821..53ec7d996 100644 --- a/kaddressbook/xxport/ldif_xxport.cpp +++ b/kaddressbook/xxport/ldif_xxport.cpp @@ -71,7 +71,7 @@ KABC::AddresseeList LDIFXXPort::importContacts( const TQString& ) const TQFile file( fileName ); if ( !file.open( IO_ReadOnly ) ) { TQString msg = i18n( "<qt>Unable to open <b>%1</b> for reading.</qt>" ); - KMessageBox::error( tqparentWidget(), msg.arg( fileName ) ); + KMessageBox::error( tqparentWidget(), msg.tqarg( fileName ) ); return addrList; } @@ -97,7 +97,7 @@ bool LDIFXXPort::exportContacts( const KABC::AddresseeList &list, const TQString return true; if( TQFileInfo(url.path()).exists() ) { - if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").arg( url.path()) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").tqarg( url.path()) ) == KMessageBox::No) return false; } @@ -106,8 +106,8 @@ bool LDIFXXPort::exportContacts( const KABC::AddresseeList &list, const TQString KTempFile tmpFile; if ( tmpFile.status() != 0 ) { TQString txt = i18n( "<qt>Unable to open file <b>%1</b>.%2.</qt>" ); - KMessageBox::error( tqparentWidget(), txt.arg( url.url() ) - .arg( strerror( tmpFile.status() ) ) ); + KMessageBox::error( tqparentWidget(), txt.tqarg( url.url() ) + .tqarg( strerror( tmpFile.status() ) ) ); return false; } @@ -121,7 +121,7 @@ bool LDIFXXPort::exportContacts( const KABC::AddresseeList &list, const TQString if ( !file.open( IO_WriteOnly ) ) { TQString txt = i18n( "<qt>Unable to open file <b>%1</b>.</qt>" ); - KMessageBox::error( tqparentWidget(), txt.arg( filename ) ); + KMessageBox::error( tqparentWidget(), txt.tqarg( filename ) ); return false; } diff --git a/kaddressbook/xxport/opera_xxport.cpp b/kaddressbook/xxport/opera_xxport.cpp index 9ddbcb396..71b01e6e1 100644 --- a/kaddressbook/xxport/opera_xxport.cpp +++ b/kaddressbook/xxport/opera_xxport.cpp @@ -55,7 +55,7 @@ KABC::AddresseeList OperaXXPort::importContacts( const TQString& ) const TQFile file( fileName ); if ( !file.open( IO_ReadOnly ) ) { TQString msg = i18n( "<qt>Unable to open <b>%1</b> for reading.</qt>" ); - KMessageBox::error( tqparentWidget(), msg.arg( fileName ) ); + KMessageBox::error( tqparentWidget(), msg.tqarg( fileName ) ); return addrList; } diff --git a/kaddressbook/xxport/pab_pablib.cpp b/kaddressbook/xxport/pab_pablib.cpp index 344647f6f..198e683fd 100644 --- a/kaddressbook/xxport/pab_pablib.cpp +++ b/kaddressbook/xxport/pab_pablib.cpp @@ -46,7 +46,7 @@ adr_t A; bool ret; if (!in.isOpen()) {TQString msg; - msg=i18n("Cannot open %1 for reading").arg(pabfile); + msg=i18n("Cannot open %1 for reading").tqarg(pabfile); // info->alert(msg); return false; } @@ -243,7 +243,7 @@ bool pab::knownPAB(void) content_t id; id=go(0); if (id!=PAB_FILE_ID) {TQString msg; - msg=i18n("%1 has no PAB id that I know of, cannot convert this").arg(pabfile); + msg=i18n("%1 has no PAB id that I know of, cannot convert this").tqarg(pabfile); // info->alert(msg); return false; } diff --git a/kaddressbook/xxport/pab_xxport.cpp b/kaddressbook/xxport/pab_xxport.cpp index 1b5b3c6f7..7894e9c5b 100644 --- a/kaddressbook/xxport/pab_xxport.cpp +++ b/kaddressbook/xxport/pab_xxport.cpp @@ -55,7 +55,7 @@ KABC::AddresseeList PABXXPort::importContacts( const TQString& ) const if ( fileName.isEmpty() ) return addrList; if ( !TQFile::exists( fileName ) ) { - KMessageBox::sorry( tqparentWidget(), i18n( "<qt>Could not find a MS Exchange Personal Address Book <b>%1</b>.</qt>" ).arg( fileName ) ); + KMessageBox::sorry( tqparentWidget(), i18n( "<qt>Could not find a MS Exchange Personal Address Book <b>%1</b>.</qt>" ).tqarg( fileName ) ); return addrList; } diff --git a/kaddressbook/xxport/vcard_xxport.cpp b/kaddressbook/xxport/vcard_xxport.cpp index e66016a14..74b1e9dc8 100644 --- a/kaddressbook/xxport/vcard_xxport.cpp +++ b/kaddressbook/xxport/vcard_xxport.cpp @@ -250,15 +250,15 @@ KABC::AddresseeList VCardXXPort::importContacts( const TQString& ) const KIO::NetAccess::removeTempFile( fileName ); } else { TQString text = i18n( "<qt>When trying to read the vCard, there was an error opening the file '%1': %2</qt>" ); - text = text.arg( (*it).url() ); - text = text.arg( kapp->translate( "TQFile", - file.errorString().latin1() ) ); + text = text.tqarg( (*it).url() ); + text = text.tqarg( kapp->translate( "TQFile", + TQString(file.errorString()).latin1() ) ); KMessageBox::error( tqparentWidget(), text, caption ); anyFailures = true; } } else { TQString text = i18n( "<qt>Unable to access vCard: %1</qt>" ); - text = text.arg( KIO::NetAccess::lastErrorString() ); + text = text.tqarg( KIO::NetAccess::lastErrorString() ); KMessageBox::error( tqparentWidget(), text, caption ); anyFailures = true; } @@ -293,7 +293,7 @@ KABC::AddresseeList VCardXXPort::parseVCard( const TQByteArray &data ) const bool VCardXXPort::doExport( const KURL &url, const TQByteArray &data ) { if( TQFileInfo(url.path()).exists() ) { - if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").arg( url.path()) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").tqarg( url.path()) ) == KMessageBox::No) return false; } KTempFile tmpFile; @@ -315,7 +315,7 @@ KABC::AddresseeList VCardXXPort::parseVCard( const TQString &data ) const bool VCardXXPort::doExport( const KURL &url, const TQString &data ) { if( TQFileInfo(url.path()).exists() ) { - if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").arg( url.path()) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( tqparentWidget(), i18n("Do you want to overwrite file \"%1\"").tqarg( url.path()) ) == KMessageBox::No) return false; } KTempFile tmpFile; diff --git a/kaddressbook/xxportmanager.cpp b/kaddressbook/xxportmanager.cpp index 0f8332ed5..8eabc81c0 100644 --- a/kaddressbook/xxportmanager.cpp +++ b/kaddressbook/xxportmanager.cpp @@ -77,7 +77,7 @@ void XXPortManager::slotImport( const TQString &identifier, const TQString &data { KAB::XXPort *obj = mXXPortObjects[ identifier ]; if ( !obj ) { - KMessageBox::error( mCore->widget(), i18n( "<qt>No import plugin available for <b>%1</b>.</qt>" ).arg( identifier ) ); + KMessageBox::error( mCore->widget(), i18n( "<qt>No import plugin available for <b>%1</b>.</qt>" ).tqarg( identifier ) ); return; } @@ -101,7 +101,7 @@ void XXPortManager::slotExport( const TQString &identifier, const TQString &data { KAB::XXPort *obj = mXXPortObjects[ identifier ]; if ( !obj ) { - KMessageBox::error( mCore->widget(), i18n( "<qt>No export plugin available for <b>%1</b>.</qt>" ).arg( identifier ) ); + KMessageBox::error( mCore->widget(), i18n( "<qt>No export plugin available for <b>%1</b>.</qt>" ).tqarg( identifier ) ); return; } @@ -121,7 +121,7 @@ void XXPortManager::loadPlugins() mXXPortObjects.clear(); const KTrader::OfferList plugins = KTrader::self()->query( "KAddressBook/XXPort", - TQString( "[X-KDE-KAddressBook-XXPortPluginVersion] == %1" ).arg( KAB_XXPORT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KAddressBook-XXPortPluginVersion] == %1" ).tqarg( KAB_XXPORT_PLUGIN_VERSION ) ); KTrader::OfferList::ConstIterator it; for ( it = plugins.begin(); it != plugins.end(); ++it ) { if ( !(*it)->hasServiceType( "KAddressBook/XXPort" ) ) diff --git a/kaddressbook/xxportselectdialog.cpp b/kaddressbook/xxportselectdialog.cpp index f7badeaaf..f65348cfe 100644 --- a/kaddressbook/xxportselectdialog.cpp +++ b/kaddressbook/xxportselectdialog.cpp @@ -186,7 +186,7 @@ void XXPortSelectDialog::initGUI() topLayout->addWidget( label ); mButtonGroup = new TQButtonGroup( i18n( "Selection" ), page ); - mButtonGroup->setColumnLayout( 0, TQt::Vertical ); + mButtonGroup->setColumnLayout( 0, Qt::Vertical ); mButtonGroup->tqlayout()->setSpacing( KDialog::spacingHint() ); mButtonGroup->tqlayout()->setMargin( KDialog::marginHint() ); @@ -225,7 +225,7 @@ void XXPortSelectDialog::initGUI() topLayout->addWidget( mButtonGroup ); TQButtonGroup *sortingGroup = new TQButtonGroup( i18n( "Sorting" ), page ); - sortingGroup->setColumnLayout( 0, TQt::Vertical ); + sortingGroup->setColumnLayout( 0, Qt::Vertical ); TQGridLayout *sortLayout = new TQGridLayout( sortingGroup->tqlayout(), 2, 2, KDialog::spacingHint() ); sortLayout->tqsetAlignment( TQt::AlignTop ); diff --git a/kalarm/alarmcalendar.cpp b/kalarm/alarmcalendar.cpp index 2d4e962d5..8cbc7ceb7 100644 --- a/kalarm/alarmcalendar.cpp +++ b/kalarm/alarmcalendar.cpp @@ -61,7 +61,7 @@ using namespace KCal; TQString AlarmCalendar::icalProductId() { - return TQString::tqfromLatin1("-//K Desktop Environment//NONSGML " KALARM_NAME " %1//EN").arg(KAlarm::currentCalendarVersionString()); + return TQString::tqfromLatin1("-//K Desktop Environment//NONSGML " KALARM_NAME " %1//EN").tqarg(KAlarm::currentCalendarVersionString()); } static const KAEvent::tqStatus eventTypes[AlarmCalendar::NCALS] = { @@ -112,7 +112,7 @@ bool AlarmCalendar::initialiseCalendars() { kdError(5950) << "AlarmCalendar::initialiseCalendars(): '" << errorKey1 << "' calendar name = display calendar name\n"; TQString file = config->readPathEntry(errorKey1); - KAlarmApp::displayFatalError(i18n("%1: file name not permitted: %2").arg(errorKey1).arg(file)); + KAlarmApp::displayFatalError(i18n("%1: file name not permitted: %2").tqarg(errorKey1).tqarg(file)); return false; } if (activeCal == expiredCal) @@ -133,14 +133,14 @@ bool AlarmCalendar::initialiseCalendars() if (!errorKey1.isNull()) { kdError(5950) << "AlarmCalendar::initialiseCalendars(): calendar names clash: " << errorKey1 << ", " << errorKey2 << endl; - KAlarmApp::displayFatalError(i18n("%1, %2: file names must be different").arg(errorKey1).arg(errorKey2)); + KAlarmApp::displayFatalError(i18n("%1, %2: file names must be different").tqarg(errorKey1).tqarg(errorKey2)); return false; } if (!mCalendars[ACTIVE]->valid()) { TQString path = mCalendars[ACTIVE]->path(); kdError(5950) << "AlarmCalendar::initialiseCalendars(): invalid name: " << path << endl; - KAlarmApp::displayFatalError(i18n("Invalid calendar file name: %1").arg(path)); + KAlarmApp::displayFatalError(i18n("Invalid calendar file name: %1").tqarg(path)); return false; } return true; @@ -321,7 +321,7 @@ int AlarmCalendar::load() if (!KIO::NetAccess::download(mUrl, tmpFile, MainWindow::mainMainWindow())) { kdError(5950) << "AlarmCalendar::load(): Load failure" << endl; - KMessageBox::error(0, i18n("Cannot open calendar:\n%1").arg(mUrl.prettyURL())); + KMessageBox::error(0, i18n("Cannot open calendar:\n%1").tqarg(mUrl.prettyURL())); return -1; } kdDebug(5950) << "AlarmCalendar::load(): --- Downloaded to " << tmpFile << endl; @@ -338,7 +338,7 @@ int AlarmCalendar::load() if (!fi.size()) return 0; // file is zero length kdError(5950) << "AlarmCalendar::load(): Error loading calendar file '" << tmpFile << "'" << endl; - KMessageBox::error(0, i18n("Error loading calendar:\n%1\n\nPlease fix or delete the file.").arg(mUrl.prettyURL())); + KMessageBox::error(0, i18n("Error loading calendar:\n%1\n\nPlease fix or delete the file.").tqarg(mUrl.prettyURL())); // load() could have partially populated the calendar, so clear it out mCalendar->close(); delete mCalendar; @@ -383,7 +383,7 @@ bool AlarmCalendar::saveCal(const TQString& newFile) if (!mCalendar->save(saveFilename, new ICalFormat)) { kdError(5950) << "AlarmCalendar::saveCal(" << saveFilename << "): failed.\n"; - KMessageBox::error(0, i18n("Failed to save calendar to\n'%1'").arg(mICalUrl.prettyURL())); + KMessageBox::error(0, i18n("Failed to save calendar to\n'%1'").tqarg(mICalUrl.prettyURL())); return false; } @@ -392,7 +392,7 @@ bool AlarmCalendar::saveCal(const TQString& newFile) if (!KIO::NetAccess::upload(saveFilename, mICalUrl, MainWindow::mainMainWindow())) { kdError(5950) << "AlarmCalendar::saveCal(" << saveFilename << "): upload failed.\n"; - KMessageBox::error(0, i18n("Cannot upload calendar to\n'%1'").arg(mICalUrl.prettyURL())); + KMessageBox::error(0, i18n("Cannot upload calendar to\n'%1'").tqarg(mICalUrl.prettyURL())); return false; } } @@ -446,7 +446,7 @@ void AlarmCalendar::close() bool AlarmCalendar::importAlarms(TQWidget* tqparent) { KURL url = KFileDialog::getOpenURL(TQString::tqfromLatin1(":importalarms"), - TQString::tqfromLatin1("*.vcs *.ics|%1").arg(i18n("Calendar Files")), tqparent); + TQString::tqfromLatin1("*.vcs *.ics|%1").tqarg(i18n("Calendar Files")), tqparent); if (url.isEmpty()) { kdError(5950) << "AlarmCalendar::importAlarms(): Empty URL" << endl; @@ -468,7 +468,7 @@ bool AlarmCalendar::importAlarms(TQWidget* tqparent) if (!KStandardDirs::exists(filename)) { kdDebug(5950) << "AlarmCalendar::importAlarms(): File '" << url.prettyURL() << "' not found" << endl; - KMessageBox::error(tqparent, i18n("Could not load calendar '%1'.").arg(url.prettyURL())); + KMessageBox::error(tqparent, i18n("Could not load calendar '%1'.").tqarg(url.prettyURL())); return false; } } @@ -477,7 +477,7 @@ bool AlarmCalendar::importAlarms(TQWidget* tqparent) if (!KIO::NetAccess::download(url, filename, MainWindow::mainMainWindow())) { kdError(5950) << "AlarmCalendar::importAlarms(): Download failure" << endl; - KMessageBox::error(tqparent, i18n("Cannot download calendar:\n%1").arg(url.prettyURL())); + KMessageBox::error(tqparent, i18n("Cannot download calendar:\n%1").tqarg(url.prettyURL())); return false; } kdDebug(5950) << "--- Downloaded to " << filename << endl; @@ -490,7 +490,7 @@ bool AlarmCalendar::importAlarms(TQWidget* tqparent) if (!success) { kdDebug(5950) << "AlarmCalendar::importAlarms(): error loading calendar '" << filename << "'" << endl; - KMessageBox::error(tqparent, i18n("Could not load calendar '%1'.").arg(url.prettyURL())); + KMessageBox::error(tqparent, i18n("Could not load calendar '%1'.").tqarg(url.prettyURL())); } else { diff --git a/kalarm/alarmevent.cpp b/kalarm/alarmevent.cpp index 66534b694..54f60a3c4 100644 --- a/kalarm/alarmevent.cpp +++ b/kalarm/alarmevent.cpp @@ -913,7 +913,7 @@ TQString KAEvent::uid(const TQString& id, tqStatus status) else { oldtqStatus = ACTIVE; - i = result.findRev('-'); + i = result.tqfindRev('-'); len = 1; } if (status != oldtqStatus && i > 0) @@ -1000,7 +1000,7 @@ bool KAEvent::updateKCalEvent(Event& ev, bool checkUid, bool original, bool canc if (mEmailBcc) cats.append(EMAIL_BCC_CATEGORY); if (mKMailSerialNumber) - cats.append(TQString("%1%2").arg(KMAIL_SERNUM_CATEGORY).arg(mKMailSerialNumber)); + cats.append(TQString("%1%2").tqarg(KMAIL_SERNUM_CATEGORY).tqarg(mKMailSerialNumber)); if (mCopyToKOrganizer) cats.append(KORGANIZER_CATEGORY); if (mCommandXterm) @@ -1008,11 +1008,11 @@ bool KAEvent::updateKCalEvent(Event& ev, bool checkUid, bool original, bool canc else if (!mLogFile.isEmpty()) cats.append(LOG_CATEGORY + mLogFile); if (mLateCancel) - cats.append(TQString("%1%2").arg(mAutoClose ? AUTO_CLOSE_CATEGORY : LATE_CANCEL_CATEGORY).arg(mLateCancel)); + cats.append(TQString("%1%2").tqarg(mAutoClose ? AUTO_CLOSE_CATEGORY : LATE_CANCEL_CATEGORY).tqarg(mLateCancel)); if (mDeferDefaultMinutes) - cats.append(TQString("%1%2").arg(DEFER_CATEGORY).arg(mDeferDefaultMinutes)); + cats.append(TQString("%1%2").tqarg(DEFER_CATEGORY).tqarg(mDeferDefaultMinutes)); if (!mTemplateName.isEmpty() && mTemplateAfterTime >= 0) - cats.append(TQString("%1%2").arg(TEMPL_AFTER_TIME_CATEGORY).arg(mTemplateAfterTime)); + cats.append(TQString("%1%2").tqarg(TEMPL_AFTER_TIME_CATEGORY).tqarg(mTemplateAfterTime)); if (mArchive && !original) { TQStringList params; @@ -1032,7 +1032,7 @@ bool KAEvent::updateKCalEvent(Event& ev, bool checkUid, bool original, bool canc unit = 'H'; count /= 60; } - params += TQString("%1%2").arg(count).arg(unit); + params += TQString("%1%2").tqarg(count).tqarg(unit); } if (mArchiveRepeatAtLogin) params += AT_LOGIN_TYPE; @@ -1084,7 +1084,7 @@ bool KAEvent::updateKCalEvent(Event& ev, bool checkUid, bool original, bool canc { // Alarm repetition is normally held in the main alarm, but since // the main alarm has expired, store in a custom property. - TQString param = TQString("%1:%2").arg(mRepeatInterval).arg(mRepeatCount); + TQString param = TQString("%1:%2").tqarg(mRepeatInterval).tqarg(mRepeatCount); ev.setCustomProperty(APPNAME, REPEAT_PROPERTY, param); } @@ -1251,9 +1251,9 @@ Alarm* KAEvent::initKCalAlarm(Event& event, int startOffsetSecs, const TQStringL } if (!mAudioFile.isEmpty() && mSoundVolume >= 0) alarm->setCustomProperty(APPNAME, VOLUME_PROPERTY, - TQString::tqfromLatin1("%1;%2;%3").arg(TQString::number(mSoundVolume, 'f', 2)) - .arg(TQString::number(mFadeVolume, 'f', 2)) - .arg(mFadeSeconds)); + TQString::tqfromLatin1("%1;%2;%3").tqarg(TQString::number(mSoundVolume, 'f', 2)) + .tqarg(TQString::number(mFadeVolume, 'f', 2)) + .tqarg(mFadeSeconds)); break; case KAAlarm::PRE_ACTION_ALARM: setProcedureAlarm(alarm, mPreAction); @@ -1277,9 +1277,9 @@ Alarm* KAEvent::initKCalAlarm(Event& event, int startOffsetSecs, const TQStringL case T_MESSAGE: alarm->setDisplayAlarm(AlarmText::toCalendarText(mText)); alarm->setCustomProperty(APPNAME, FONT_COLOUR_PROPERTY, - TQString::tqfromLatin1("%1;%2;%3").arg(mBgColour.name()) - .arg(mFgColour.name()) - .arg(mDefaultFont ? TQString() : mFont.toString())); + TQString::tqfromLatin1("%1;%2;%3").tqarg(mBgColour.name()) + .tqarg(mFgColour.name()) + .tqarg(mDefaultFont ? TQString() : mFont.toString())); break; case T_COMMAND: if (mCommandScript) @@ -2093,7 +2093,7 @@ TQString KAEvent::recurrenceText(bool brief) const else { TQString mins; - return i18n("Hours and Minutes", "%1H %2M").arg(TQString::number(frequency/60)).arg(mins.sprintf("%02d", frequency%60)); + return i18n("Hours and Minutes", "%1H %2M").tqarg(TQString::number(frequency/60)).tqarg(mins.sprintf("%02d", frequency%60)); } case RecurrenceRule::rDaily: return i18n("1 Day", "%n Days", frequency); @@ -2125,7 +2125,7 @@ TQString KAEvent::repetitionText(bool brief) const if (mRepeatInterval % 60 == 0) return i18n("1 Hour", "%n Hours", mRepeatInterval/60); TQString mins; - return i18n("Hours and Minutes", "%1H %2M").arg(TQString::number(mRepeatInterval/60)).arg(mins.sprintf("%02d", mRepeatInterval%60)); + return i18n("Hours and Minutes", "%1H %2M").tqarg(TQString::number(mRepeatInterval/60)).tqarg(mins.sprintf("%02d", mRepeatInterval%60)); } if (mRepeatInterval % (7*1440)) return i18n("1 Day", "%n Days", mRepeatInterval/1440); @@ -2844,7 +2844,7 @@ void KAEvent::convertKCalEvents(KCal::Calendar& calendar, int version, bool adju Alarm* alarm = *alit; if (alarm->type() == Alarm::Display) alarm->setCustomProperty(APPNAME, FONT_COLOUR_PROPERTY, - TQString::tqfromLatin1("%1;;").arg(cats[0])); + TQString::tqfromLatin1("%1;;").tqarg(cats[0])); } cats.remove(cats.begin()); } @@ -2918,7 +2918,7 @@ void KAEvent::convertKCalEvents(KCal::Calendar& calendar, int version, bool adju while ((it = cats.tqfind(TEMPL_DEF_TIME_CAT)) != cats.end()) { cats.remove(it); - cats.append(TQString("%1%2").arg(TEMPL_AFTER_TIME_CATEGORY).arg(0)); + cats.append(TQString("%1%2").tqarg(TEMPL_AFTER_TIME_CATEGORY).tqarg(0)); } } @@ -2937,7 +2937,7 @@ void KAEvent::convertKCalEvents(KCal::Calendar& calendar, int version, bool adju } if (addLateCancel) - cats.append(TQString("%1%2").arg(LATE_CANCEL_CATEGORY).arg(1)); + cats.append(TQString("%1%2").tqarg(LATE_CANCEL_CATEGORY).tqarg(1)); event->setCategories(cats); @@ -3321,11 +3321,11 @@ void KAAlarmEventBase::dumpDebug() const kdDebug(5950) << "-- Attachments:" << mEmailAttachments.join(", ") << ":\n"; kdDebug(5950) << "-- Bcc:" << (mEmailBcc ? "true" : "false") << ":\n"; } - kdDebug(5950) << "-- mBgColour:" << mBgColour.name() << ":\n"; - kdDebug(5950) << "-- mFgColour:" << mFgColour.name() << ":\n"; + kdDebug(5950) << "-- mBgColour:" << TQString(mBgColour.name()) << ":\n"; + kdDebug(5950) << "-- mFgColour:" << TQString(mFgColour.name()) << ":\n"; kdDebug(5950) << "-- mDefaultFont:" << (mDefaultFont ? "true" : "false") << ":\n"; if (!mDefaultFont) - kdDebug(5950) << "-- mFont:" << mFont.toString() << ":\n"; + kdDebug(5950) << "-- mFont:" << TQString(mFont.toString()) << ":\n"; kdDebug(5950) << "-- mBeep:" << (mBeep ? "true" : "false") << ":\n"; kdDebug(5950) << "-- mSpeak:" << (mSpeak ? "true" : "false") << ":\n"; if (mActionType == T_AUDIO) diff --git a/kalarm/alarmlistview.cpp b/kalarm/alarmlistview.cpp index 4ef40f563..34eeffdab 100644 --- a/kalarm/alarmlistview.cpp +++ b/kalarm/alarmlistview.cpp @@ -348,7 +348,7 @@ TQString AlarmListView::whatsThisText(int column) const void AlarmListView::contentsMousePressEvent(TQMouseEvent* e) { TQListView::contentsMousePressEvent(e); - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) { TQPoint p(contentsToViewport(e->pos())); if (itemAt(p)) @@ -531,7 +531,7 @@ TQString AlarmListViewItem::timeToAlarmText(const TQDateTime& now) const if (dateTime.isDateOnly()) { int days = now.date().daysTo(dateTime.date()); - return i18n("n days", " %1d ").arg(days); + return i18n("n days", " %1d ").tqarg(days); } int mins = (now.secsTo(dateTime.dateTime()) + 59) / 60; if (mins < 0) @@ -540,10 +540,10 @@ TQString AlarmListViewItem::timeToAlarmText(const TQDateTime& now) const minutes[0] = (mins%60) / 10 + '0'; minutes[1] = (mins%60) % 10 + '0'; if (mins < 24*60) - return i18n("hours:minutes", " %1:%2 ").arg(mins/60).arg(minutes); + return i18n("hours:minutes", " %1:%2 ").tqarg(mins/60).tqarg(minutes); int days = mins / (24*60); mins = mins % (24*60); - return i18n("days hours:minutes", " %1d %2:%3 ").arg(days).arg(mins/60).arg(minutes); + return i18n("days hours:minutes", " %1d %2:%3 ").tqarg(days).tqarg(mins/60).tqarg(minutes); } /****************************************************************************** @@ -652,7 +652,7 @@ void AlarmListViewItem::paintCell(TQPainter* painter, const TQColorGroup& cg, in */ int AlarmListViewItem::typeIconWidth(AlarmListView* v) { - return iconWidth() + 2 * v->style().tqpixelMetric(TQStyle::PM_DefaultFrameWidth); + return iconWidth() + 2 * v->tqstyle().tqpixelMetric(TQStyle::PM_DefaultFrameWidth); } /****************************************************************************** diff --git a/kalarm/alarmtimewidget.cpp b/kalarm/alarmtimewidget.cpp index 4ce881485..4443ae2fc 100644 --- a/kalarm/alarmtimewidget.cpp +++ b/kalarm/alarmtimewidget.cpp @@ -104,7 +104,7 @@ void AlarmTimeWidget::init(int mode) connect(mDateEdit, TQT_SIGNAL(dateEntered(const TQDate&)), TQT_SLOT(dateTimeChanged())); static const TQString enterDateText = i18n("Enter the date to schedule the alarm."); TQWhatsThis::add(mDateEdit, ((mode & DEFER_TIME) ? enterDateText - : TQString("%1\n%2").arg(enterDateText).arg(recurText))); + : TQString("%1\n%2").tqarg(enterDateText).tqarg(recurText))); mAtTimeRadio->setFocusWidget(mDateEdit); // Time edit box and Any time checkbox @@ -115,8 +115,8 @@ void AlarmTimeWidget::init(int mode) connect(mTimeEdit, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(dateTimeChanged())); static const TQString enterTimeText = i18n("Enter the time to schedule the alarm."); TQWhatsThis::add(mTimeEdit, - ((mode & DEFER_TIME) ? TQString("%1\n\n%2").arg(enterTimeText).arg(TimeSpinBox::shiftWhatsThis()) - : TQString("%1\n%2\n\n%3").arg(enterTimeText).arg(recurText).arg(TimeSpinBox::shiftWhatsThis()))); + ((mode & DEFER_TIME) ? TQString("%1\n\n%2").tqarg(enterTimeText).tqarg(TimeSpinBox::shiftWhatsThis()) + : TQString("%1\n%2\n\n%3").tqarg(enterTimeText).tqarg(recurText).tqarg(TimeSpinBox::shiftWhatsThis()))); mAnyTime = -1; // current status is uninitialised if (mode & DEFER_TIME) @@ -147,8 +147,8 @@ void AlarmTimeWidget::init(int mode) mDelayTimeEdit->setFixedSize(mDelayTimeEdit->tqsizeHint()); connect(mDelayTimeEdit, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(delayTimeChanged(int))); TQWhatsThis::add(mDelayTimeEdit, - ((mode & DEFER_TIME) ? TQString("%1\n\n%2").arg(i18n_TimeAfterPeriod()).arg(TimeSpinBox::shiftWhatsThis()) - : TQString("%1\n%2\n\n%3").arg(i18n_TimeAfterPeriod()).arg(recurText).arg(TimeSpinBox::shiftWhatsThis()))); + ((mode & DEFER_TIME) ? TQString("%1\n\n%2").tqarg(i18n_TimeAfterPeriod()).tqarg(TimeSpinBox::shiftWhatsThis()) + : TQString("%1\n%2\n\n%3").tqarg(i18n_TimeAfterPeriod()).tqarg(recurText).tqarg(TimeSpinBox::shiftWhatsThis()))); mAfterTimeRadio->setFocusWidget(mDelayTimeEdit); // Set up the tqlayout, either narrow or wide @@ -182,7 +182,7 @@ void AlarmTimeWidget::init(int mode) setButton(id(mAtTimeRadio)); // Timeout every minute to update alarm time fields. - MinuteTimer::connect(this, TQT_SLOT(slotTimer())); + MinuteTimer::connect(TQT_TQOBJECT(this), TQT_SLOT(slotTimer())); } /****************************************************************************** @@ -266,7 +266,7 @@ DateTime AlarmTimeWidget::getDateTime(int* minsFromNow, bool checkExpired, bool else { result.set(mDateEdit->date(), mTimeEdit->time()); - if (checkExpired && result <= now.addSecs(1)) + if (checkExpired && result <= TQDateTime(now.addSecs(1))) { if (showErrorMessage) KMessageBox::sorry(const_cast<AlarmTimeWidget*>(this), i18n("Alarm time has already expired")); @@ -290,7 +290,7 @@ DateTime AlarmTimeWidget::getDateTime(int* minsFromNow, bool checkExpired, bool int delayMins = mDelayTimeEdit->value(); if (minsFromNow) *minsFromNow = delayMins; - return now.addSecs(delayMins * 60); + return TQDateTime(now.addSecs(delayMins * 60)); } } diff --git a/kalarm/birthdaydlg.cpp b/kalarm/birthdaydlg.cpp index 5ed43275e..16e8a4ac1 100644 --- a/kalarm/birthdaydlg.cpp +++ b/kalarm/birthdaydlg.cpp @@ -85,7 +85,7 @@ BirthdayDlg::BirthdayDlg(TQWidget* tqparent) mPrefixText = config->readEntry(TQString::tqfromLatin1("BirthdayPrefix"), i18n("Birthday: ")); mSuffixText = config->readEntry(TQString::tqfromLatin1("BirthdaySuffix")); - TQGroupBox* textGroup = new TQGroupBox(2, TQt::Horizontal, i18n("Alarm Text"), topWidget); + TQGroupBox* textGroup = new TQGroupBox(2, Qt::Horizontal, i18n("Alarm Text"), topWidget); topLayout->addWidget(textGroup); TQLabel* label = new TQLabel(i18n("Pre&fix:"), textGroup); mPrefix = new BLineEdit(mPrefixText, textGroup); @@ -105,7 +105,7 @@ BirthdayDlg::BirthdayDlg(TQWidget* tqparent) i18n("Enter text to appear after the person's name in the alarm message, " "including any necessary leading spaces.")); - TQGroupBox* group = new TQGroupBox(1, TQt::Horizontal, i18n("Select Birthdays"), topWidget); + TQGroupBox* group = new TQGroupBox(1, Qt::Horizontal, i18n("Select Birthdays"), topWidget); topLayout->addWidget(group); mAddresseeList = new BListView(group); mAddresseeList->setMultiSelection(true); @@ -421,7 +421,7 @@ BListView::BListView(TQWidget* tqparent, const char* name) : KListView(tqparent, name) { KAccel* accel = new KAccel(this); - accel->insert(KStdAccel::SelectAll, this, TQT_SLOT(slotSelectAll())); - accel->insert(KStdAccel::Deselect, this, TQT_SLOT(slotDeselect())); + accel->insert(KStdAccel::SelectAll, TQT_TQOBJECT(this), TQT_SLOT(slotSelectAll())); + accel->insert(KStdAccel::Deselect, TQT_TQOBJECT(this), TQT_SLOT(slotDeselect())); accel->readSettings(); } diff --git a/kalarm/daemon.cpp b/kalarm/daemon.cpp index f3a466ea7..f7e340f85 100644 --- a/kalarm/daemon.cpp +++ b/kalarm/daemon.cpp @@ -221,7 +221,7 @@ void Daemon::registrationResult(bool reregister, int result, int version) failed = true; kdError(5950) << "Daemon::registrationResult(" << reregister << "): kalarmd reports incompatible version " << version << endl; errmsg = i18n("Cannot enable alarms.\nInstallation or configuration error: Alarm Daemon (%1) version is incompatible.") - .arg(TQString::tqfromLatin1(DAEMON_APP_NAME)); + .tqarg(TQString::tqfromLatin1(DAEMON_APP_NAME)); } else { @@ -236,8 +236,8 @@ void Daemon::registrationResult(bool reregister, int result, int version) kdError(5950) << "Daemon::registrationResult(" << reregister << "): registerApp dcop call: " << kapp->aboutData()->appName() << " not found\n"; KMessageBox::error(0, i18n("Alarms will be disabled if you stop KAlarm.\n" "(Installation or configuration error: %1 cannot locate %2 executable.)") - .arg(TQString::tqfromLatin1(DAEMON_APP_NAME)) - .arg(kapp->aboutData()->appName())); + .tqarg(TQString::tqfromLatin1(DAEMON_APP_NAME)) + .tqarg(kapp->aboutData()->appName())); break; case KAlarmd::FAILURE: default: @@ -248,7 +248,7 @@ void Daemon::registrationResult(bool reregister, int result, int version) if (!reregister) { errmsg = i18n("Cannot enable alarms:\nFailed to register with Alarm Daemon (%1)") - .arg(TQString::tqfromLatin1(DAEMON_APP_NAME)); + .tqarg(TQString::tqfromLatin1(DAEMON_APP_NAME)); } break; } @@ -304,7 +304,7 @@ void Daemon::checkIfStarted() if (err) { kdError(5950) << "Daemon::checkIfStarted(): failed to start daemon" << endl; - KMessageBox::error(0, i18n("Cannot enable alarms:\nFailed to start Alarm Daemon (%1)").arg(TQString::tqfromLatin1(DAEMON_APP_NAME))); + KMessageBox::error(0, i18n("Cannot enable alarms:\nFailed to start Alarm Daemon (%1)").tqarg(TQString::tqfromLatin1(DAEMON_APP_NAME))); } } diff --git a/kalarm/dcophandler.cpp b/kalarm/dcophandler.cpp index 5f6e85074..c76f2a7fb 100644 --- a/kalarm/dcophandler.cpp +++ b/kalarm/dcophandler.cpp @@ -32,6 +32,7 @@ #include "karecurrence.h" #include "mainwindow.h" #include "preferences.h" +#include "dcophandler.h" #include "dcophandler.moc" static const char* DCOP_OBJECT_NAME = "request"; // DCOP name of KAlarm's request interface @@ -325,7 +326,7 @@ DateTime DcopHandler::convertStartDateTime(const TQString& startDateTime) if (startDateTime.length() > 10) { // Both a date and a time are specified - start = TQDateTime::fromString(startDateTime, TQt::ISODate); + start = TQDateTime::fromString(startDateTime, Qt::ISODate); } else { @@ -339,12 +340,12 @@ DateTime DcopHandler::convertStartDateTime(const TQString& startDateTime) if (t.isEmpty()) { // It's a date - start = TQDate::fromString(startDateTime, TQt::ISODate); + start = TQDate::fromString(startDateTime, Qt::ISODate); } else { // It's a time, so use today as the date - start.set(TQDate::tqcurrentDate(), TQTime::fromString(t, TQt::ISODate)); + start.set(TQDate::tqcurrentDate(), TQTime::fromString(t, Qt::ISODate)); } } if (!start.isValid()) @@ -426,7 +427,7 @@ bool DcopHandler::convertRecurrence(DateTime& start, KARecurrence& recurrence, c kdError(5950) << "DCOP call: alarm is date-only, but recurrence end is date/time" << endl; return false; } - end.setDate(TQDate::fromString(endDateTime, TQt::ISODate)); + end.setDate(TQDate::fromString(endDateTime, Qt::ISODate)); } else { @@ -435,7 +436,7 @@ bool DcopHandler::convertRecurrence(DateTime& start, KARecurrence& recurrence, c kdError(5950) << "DCOP call: alarm is timed, but recurrence end is date-only" << endl; return false; } - end = TQDateTime::fromString(endDateTime, TQt::ISODate); + end = TQDateTime::fromString(endDateTime, Qt::ISODate); } if (!end.isValid()) { diff --git a/kalarm/deferdlg.cpp b/kalarm/deferdlg.cpp index 75b95b8f5..4709f6a8f 100644 --- a/kalarm/deferdlg.cpp +++ b/kalarm/deferdlg.cpp @@ -107,7 +107,7 @@ void DeferAlarmDlg::slotOk() case KAEvent::LIMIT_NONE: break; // can't happen with a valid endTime } - KMessageBox::sorry(this, text.arg(endTime.formatLocale())); + KMessageBox::sorry(this, text.tqarg(endTime.formatLocale())); } else accept(); diff --git a/kalarm/editdlg.cpp b/kalarm/editdlg.cpp index b93f681e6..f4ea9e654 100644 --- a/kalarm/editdlg.cpp +++ b/kalarm/editdlg.cpp @@ -129,10 +129,10 @@ inline TQString recurText(const KAEvent& event) { TQString r; if (event.repeatCount()) - r = TQString::tqfromLatin1("%1 / %2").arg(event.recurrenceText()).arg(event.repetitionText()); + r = TQString::tqfromLatin1("%1 / %2").tqarg(event.recurrenceText()).tqarg(event.repetitionText()); else r = event.recurrenceText(); - return i18n("&Recurrence - [%1]").arg(r); + return i18n("&Recurrence - [%1]").tqarg(r); } // Collect these widget labels together to ensure consistent wording and @@ -273,7 +273,7 @@ EditAlarmDlg::EditAlarmDlg(bool Template, const TQString& caption, TQWidget* tqp tqlayout->addWidget(mEmailFrame); // Deferred date/time: visible only for a deferred recurring event. - mDeferGroup = new TQGroupBox(1, TQt::Vertical, i18n("Deferred Alarm"), mainPage, "deferGroup"); + mDeferGroup = new TQGroupBox(1, Qt::Vertical, i18n("Deferred Alarm"), mainPage, "deferGroup"); topLayout->addWidget(mDeferGroup); TQLabel* label = new TQLabel(i18n("Deferred to:"), mDeferGroup); label->setFixedSize(label->tqsizeHint()); @@ -318,8 +318,8 @@ EditAlarmDlg::EditAlarmDlg(bool Template, const TQString& caption, TQWidget* tqp mTemplateTime->setFixedSize(mTemplateTime->tqsizeHint()); mTemplateTime->setReadOnly(mReadOnly); TQWhatsThis::add(mTemplateTime, - TQString("%1\n\n%2").arg(i18n("Enter the start time for alarms based on this template.")) - .arg(TimeSpinBox::shiftWhatsThis())); + TQString("%1\n\n%2").tqarg(i18n("Enter the start time for alarms based on this template.")) + .tqarg(TimeSpinBox::shiftWhatsThis())); box->setStretchFactor(new TQWidget(box), 1); // left adjust the controls box->setFixedHeight(box->tqsizeHint().height()); grid->addWidget(box, 0, 1, tqalignment); @@ -328,7 +328,7 @@ EditAlarmDlg::EditAlarmDlg(bool Template, const TQString& caption, TQWidget* tqp mTemplateAnyTime->setFixedSize(mTemplateAnyTime->tqsizeHint()); mTemplateAnyTime->setReadOnly(mReadOnly); TQWhatsThis::add(mTemplateAnyTime, - i18n("Set the '%1' option for alarms based on this template.").arg(i18n("Any time"))); + i18n("Set the '%1' option for alarms based on this template.").tqarg(i18n("Any time"))); grid->addWidget(mTemplateAnyTime, 1, 0, tqalignment); box = new TQHBox(mTemplateTimeGroup); @@ -345,8 +345,8 @@ EditAlarmDlg::EditAlarmDlg(bool Template, const TQString& caption, TQWidget* tqp mTemplateTimeAfter->setFixedSize(mTemplateTimeAfter->tqsizeHint()); mTemplateTimeAfter->setReadOnly(mReadOnly); TQWhatsThis::add(mTemplateTimeAfter, - TQString("%1\n\n%2").arg(AlarmTimeWidget::i18n_TimeAfterPeriod()) - .arg(TimeSpinBox::shiftWhatsThis())); + TQString("%1\n\n%2").tqarg(AlarmTimeWidget::i18n_TimeAfterPeriod()) + .tqarg(TimeSpinBox::shiftWhatsThis())); box->setFixedHeight(box->tqsizeHint().height()); grid->addWidget(box, 1, 1, tqalignment); @@ -363,7 +363,7 @@ EditAlarmDlg::EditAlarmDlg(bool Template, const TQString& caption, TQWidget* tqp static const TQString reminderText = i18n("Enter how long in advance of the main alarm to display a reminder alarm."); mReminder = new Reminder(i18n("Rem&inder:"), i18n("Check to additionally display a reminder in advance of the main alarm time(s)."), - TQString("%1\n\n%2").arg(reminderText).arg(TimeSpinBox::shiftWhatsThis()), + TQString("%1\n\n%2").tqarg(reminderText).tqarg(TimeSpinBox::shiftWhatsThis()), true, true, mainPage); mReminder->setFixedSize(mReminder->tqsizeHint()); topLayout->addWidget(mReminder, 0, TQt::AlignAuto); @@ -517,7 +517,7 @@ void EditAlarmDlg::initCommand(TQWidget* tqparent) // Log file name edit box TQHBox* box = new TQHBox(mCmdOutputGroup); - (new TQWidget(box))->setFixedWidth(button->style().subRect(TQStyle::SR_RadioButtonIndicator, button).width()); // indent the edit box + (new TQWidget(box))->setFixedWidth(button->tqstyle().subRect(TQStyle::SR_RadioButtonIndicator, button).width()); // indent the edit box // (new TQWidget(box))->setFixedWidth(button->style().tqpixelMetric(TQStyle::PM_ExclusiveIndicatorWidth)); // indent the edit box mCmdLogFileEdit = new LineEdit(LineEdit::Url, box); mCmdLogFileEdit->setAcceptDrops(true); @@ -712,7 +712,7 @@ void EditAlarmDlg::initialise(const KAEvent* event) int afterTime = event->templateAfterTime(); if (afterTime >= 0) { - mTimeWidget->setDateTime(now.addSecs(afterTime * 60)); + mTimeWidget->setDateTime(TQDateTime(now.addSecs(afterTime * 60))); mTimeWidget->selectTimeFromNow(); } else @@ -1424,7 +1424,7 @@ void EditAlarmDlg::slotOk() mTabs->setCurrentPage(mMainPageIndex); mReminder->setFocusOnCount(); KMessageBox::sorry(this, i18n("Reminder period must be less than the recurrence interval, unless '%1' is checked." - ).arg(Reminder::i18n_first_recurrence_only())); + ).tqarg(Reminder::i18n_first_recurrence_only())); return; } } @@ -1479,15 +1479,15 @@ void EditAlarmDlg::slotTry() if (mCommandRadio->isOn() && mCmdOutputGroup->selectedId() != EXEC_IN_TERMINAL) { theApp()->commandMessage((ShellProcess*)proc, this); - KMessageBox::information(this, i18n("Command executed:\n%1").arg(text)); + KMessageBox::information(this, i18n("Command executed:\n%1").tqarg(text)); theApp()->commandMessage((ShellProcess*)proc, 0); } else if (mEmailRadio->isOn()) { TQString bcc; if (mEmailBcc->isChecked()) - bcc = i18n("\nBcc: %1").arg(Preferences::emailBccAddress()); - KMessageBox::information(this, i18n("Email sent to:\n%1%2").arg(mEmailAddresses.join("\n")).arg(bcc)); + bcc = i18n("\nBcc: %1").tqarg(Preferences::emailBccAddress()); + KMessageBox::information(this, i18n("Email sent to:\n%1%2").tqarg(mEmailAddresses.join("\n")).tqarg(bcc)); } } } @@ -1728,7 +1728,7 @@ bool EditAlarmDlg::checkEmailData() if (!bad.isEmpty()) { mEmailToEdit->setFocus(); - KMessageBox::error(this, i18n("Invalid email address:\n%1").arg(bad)); + KMessageBox::error(this, i18n("Invalid email address:\n%1").tqarg(bad)); return false; } } @@ -1752,7 +1752,7 @@ bool EditAlarmDlg::checkEmailData() break; // empty case -1: mEmailAttachList->setFocus(); - KMessageBox::error(this, i18n("Invalid email attachment:\n%1").arg(att)); + KMessageBox::error(this, i18n("Invalid email attachment:\n%1").tqarg(att)); return false; } } @@ -2012,7 +2012,7 @@ bool EditAlarmDlg::checkText(TQString& result, bool showErrorMessage) const default: break; } - if (KMessageBox::warningContinueCancel(const_cast<EditAlarmDlg*>(this), errmsg.arg(alarmtext)) + if (KMessageBox::warningContinueCancel(const_cast<EditAlarmDlg*>(this), errmsg.tqarg(alarmtext)) == KMessageBox::Cancel) return false; } diff --git a/kalarm/emailidcombo.cpp b/kalarm/emailidcombo.cpp index 20b0ad198..388fa4573 100644 --- a/kalarm/emailidcombo.cpp +++ b/kalarm/emailidcombo.cpp @@ -31,7 +31,7 @@ void EmailIdCombo::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == LeftButton) + if (e->button() == Qt::LeftButton) return; } KPIM::IdentityCombo::mousePressEvent(e); diff --git a/kalarm/find.cpp b/kalarm/find.cpp index 77e841407..e3732eaa0 100644 --- a/kalarm/find.cpp +++ b/kalarm/find.cpp @@ -113,7 +113,7 @@ void Find::display() "This option is only available if expired alarms are currently being displayed.")); grid->addWidget(mExpired, 1, 2, TQt::AlignAuto); - mActiveExpiredSep = new KSeparator(TQt::Horizontal, kalarmWidgets); + mActiveExpiredSep = new KSeparator(Qt::Horizontal, kalarmWidgets); grid->addMultiCellWidget(mActiveExpiredSep, 2, 2, 0, 2); // Alarm actions @@ -307,40 +307,40 @@ void Find::findNext(bool forward, bool sort, bool checkEnd, bool fromCurrent) if (!(mOptions & FIND_MESSAGE)) break; mFind->setData(event.cleanText()); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); break; case KAEvent::FILE: if (!(mOptions & FIND_FILE)) break; mFind->setData(event.cleanText()); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); break; case KAEvent::COMMAND: if (!(mOptions & FIND_COMMAND)) break; mFind->setData(event.cleanText()); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); break; case KAEvent::EMAIL: if (!(mOptions & FIND_EMAIL)) break; mFind->setData(event.emailAddresses(", ")); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); if (found) break; mFind->setData(event.emailSubject()); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); if (found) break; mFind->setData(event.emailAttachments().join(", ")); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); if (found) break; mFind->setData(event.cleanText()); - found = (mFind->tqfind() == KFind::Match); + found = (mFind->find() == KFind::Match); break; } if (found) diff --git a/kalarm/functions.cpp b/kalarm/functions.cpp index 97d046896..26b16d226 100644 --- a/kalarm/functions.cpp +++ b/kalarm/functions.cpp @@ -633,7 +633,7 @@ void outputAlarmWarnings(TQWidget* tqparent, const KAEvent* event) if (event && event->action() == KAEvent::EMAIL && Preferences::emailAddress().isEmpty()) KMessageBox::information(tqparent, i18n("Please set the 'From' email address...", - "%1\nPlease set it in the Preferences dialog.").arg(KAMail::i18n_NeedFromEmailAddress())); + "%1\nPlease set it in the Preferences dialog.").tqarg(KAMail::i18n_NeedFromEmailAddress())); if (!Daemon::monitoringAlarms()) { @@ -705,7 +705,7 @@ TQString runKMail(bool minimise) TQCString dcopName; TQString errmsg; if (!runProgram("kmail", (minimise ? KMAIL_DCOP_WINDOW : ""), dcopName, errmsg)) - return i18n("Unable to start KMail\n(%1)").arg(errmsg); + return i18n("Unable to start KMail\n(%1)").tqarg(errmsg); return TQString(); } @@ -747,9 +747,9 @@ bool readConfigWindowSize(const char* window, TQSize& result) { KConfig* config = KGlobal::config(); config->setGroup(TQString::tqfromLatin1(window)); - TQWidget* desktop = KApplication::desktop(); - TQSize s = TQSize(config->readNumEntry(TQString::tqfromLatin1("Width %1").arg(desktop->width()), 0), - config->readNumEntry(TQString::tqfromLatin1("Height %1").arg(desktop->height()), 0)); + TQWidget* desktop = TQT_TQWIDGET(KApplication::desktop()); + TQSize s = TQSize(config->readNumEntry(TQString::tqfromLatin1("Width %1").tqarg(desktop->width()), 0), + config->readNumEntry(TQString::tqfromLatin1("Height %1").tqarg(desktop->height()), 0)); if (s.isEmpty()) return false; result = s; @@ -764,9 +764,9 @@ void writeConfigWindowSize(const char* window, const TQSize& size) { KConfig* config = KGlobal::config(); config->setGroup(TQString::tqfromLatin1(window)); - TQWidget* desktop = KApplication::desktop(); - config->writeEntry(TQString::tqfromLatin1("Width %1").arg(desktop->width()), size.width()); - config->writeEntry(TQString::tqfromLatin1("Height %1").arg(desktop->height()), size.height()); + TQWidget* desktop = TQT_TQWIDGET(KApplication::desktop()); + config->writeEntry(TQString::tqfromLatin1("Width %1").tqarg(desktop->width()), size.width()); + config->writeEntry(TQString::tqfromLatin1("Height %1").tqarg(desktop->height()), size.height()); config->sync(); } diff --git a/kalarm/kalarm.h b/kalarm/kalarm.h index e0af27f57..f433b3ff0 100644 --- a/kalarm/kalarm.h +++ b/kalarm/kalarm.h @@ -33,7 +33,7 @@ #define AUTOSTART_BY_KALARMD // temporary fix for autostart before session restoration -#define OLD_DCOP // retain DCOP pre-1.2 compatibility +// #define OLD_DCOP // retain DCOP pre-1.2 compatibility #endif // KALARM_H diff --git a/kalarm/kalarmapp.cpp b/kalarm/kalarmapp.cpp index fd81aed47..d37e0dcda 100644 --- a/kalarm/kalarmapp.cpp +++ b/kalarm/kalarmapp.cpp @@ -109,7 +109,7 @@ KAlarmApp::KAlarmApp() mSpeechEnabled(false) { Preferences::initialise(); - Preferences::connect(TQT_SIGNAL(preferencesChanged()), this, TQT_SLOT(slotPreferencesChanged())); + Preferences::connect(TQT_SIGNAL(preferencesChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotPreferencesChanged())); KCal::CalFormat::setApplication(aboutData()->programName(), AlarmCalendar::icalProductId()); KARecurrence::setDefaultFeb29Type(Preferences::defaultFeb29Type()); @@ -329,9 +329,9 @@ int KAlarmApp::newInstance() if (args->isSet("triggerEvent")) { function = EVENT_TRIGGER; option = "triggerEvent"; ++count; } if (args->isSet("cancelEvent")) { function = EVENT_CANCEL; option = "cancelEvent"; ++count; } if (!count) - USAGE(i18n("%1 requires %2, %3 or %4").arg(TQString::tqfromLatin1("--calendarURL")).arg(TQString::tqfromLatin1("--handleEvent")).arg(TQString::tqfromLatin1("--triggerEvent")).arg(TQString::tqfromLatin1("--cancelEvent"))) + USAGE(i18n("%1 requires %2, %3 or %4").tqarg(TQString::tqfromLatin1("--calendarURL")).tqarg(TQString::tqfromLatin1("--handleEvent")).tqarg(TQString::tqfromLatin1("--triggerEvent")).tqarg(TQString::tqfromLatin1("--cancelEvent"))) if (count > 1) - USAGE(i18n("%1, %2, %3 mutually exclusive").arg(TQString::tqfromLatin1("--handleEvent")).arg(TQString::tqfromLatin1("--triggerEvent")).arg(TQString::tqfromLatin1("--cancelEvent"))); + USAGE(i18n("%1, %2, %3 mutually exclusive").tqarg(TQString::tqfromLatin1("--handleEvent")).tqarg(TQString::tqfromLatin1("--triggerEvent")).tqarg(TQString::tqfromLatin1("--cancelEvent"))); if (!initCheck(true)) // open the calendar, don't register with daemon yet { exitCode = 1; @@ -341,7 +341,7 @@ int KAlarmApp::newInstance() { TQString calendarUrl = args->getOption("calendarURL"); if (KURL(calendarUrl).url() != AlarmCalendar::activeCalendar()->urlString()) - USAGE(i18n("%1: wrong calendar file").arg(TQString::tqfromLatin1("--calendarURL"))) + USAGE(i18n("%1: wrong calendar file").tqarg(TQString::tqfromLatin1("--calendarURL"))) } TQString eventID = args->getOption(option); args->clear(); // free up memory @@ -369,7 +369,7 @@ int KAlarmApp::newInstance() } if (!KAlarm::edit(eventID)) { - USAGE(i18n("%1: Event %2 not found, or not editable").arg(TQString::tqfromLatin1("--edit")).arg(eventID)) + USAGE(i18n("%1: Event %2 not found, or not editable").tqarg(TQString::tqfromLatin1("--edit")).tqarg(eventID)) exitCode = 1; break; } @@ -401,11 +401,11 @@ int KAlarmApp::newInstance() { kdDebug(5950)<<"KAlarmApp::newInstance(): file\n"; if (args->isSet("exec")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--exec")).arg(TQString::tqfromLatin1("--file"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--exec")).tqarg(TQString::tqfromLatin1("--file"))) if (args->isSet("mail")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--mail")).arg(TQString::tqfromLatin1("--file"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--mail")).tqarg(TQString::tqfromLatin1("--file"))) if (args->count()) - USAGE(i18n("message incompatible with %1").arg(TQString::tqfromLatin1("--file"))) + USAGE(i18n("message incompatible with %1").tqarg(TQString::tqfromLatin1("--file"))) alMessage = args->getOption("file"); action = KAEvent::FILE; } @@ -413,7 +413,7 @@ int KAlarmApp::newInstance() { kdDebug(5950)<<"KAlarmApp::newInstance(): exec\n"; if (args->isSet("mail")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--mail")).arg(TQString::tqfromLatin1("--exec"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--mail")).tqarg(TQString::tqfromLatin1("--exec"))) alMessage = args->getOption("exec"); int n = args->count(); for (int i = 0; i < n; ++i) @@ -435,7 +435,7 @@ int KAlarmApp::newInstance() { TQString addr = TQString::fromLocal8Bit(*i); if (!KAMail::checkAddress(addr)) - USAGE(i18n("%1: invalid email address").arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1: invalid email address").tqarg(TQString::tqfromLatin1("--mail"))) alAddresses += KCal::Person(TQString(), addr); } params = args->getOptionList("attach"); @@ -453,13 +453,13 @@ int KAlarmApp::newInstance() if (action != KAEvent::EMAIL) { if (args->isSet("subject")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--subject")).arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--subject")).tqarg(TQString::tqfromLatin1("--mail"))) if (args->isSet("from-id")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--from-id")).arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--from-id")).tqarg(TQString::tqfromLatin1("--mail"))) if (args->isSet("attach")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--attach")).arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--attach")).tqarg(TQString::tqfromLatin1("--mail"))) if (args->isSet("bcc")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--bcc")).arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--bcc")).tqarg(TQString::tqfromLatin1("--mail"))) } bool alarmNoTime = false; @@ -478,7 +478,7 @@ int KAlarmApp::newInstance() colourText.tqreplace(0, 2, "#"); bgColour.setNamedColor(colourText); if (!bgColour.isValid()) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--color"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--color"))) } if (args->isSet("colorfg")) { @@ -489,14 +489,14 @@ int KAlarmApp::newInstance() colourText.tqreplace(0, 2, "#"); fgColour.setNamedColor(colourText); if (!fgColour.isValid()) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--colorfg"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--colorfg"))) } if (args->isSet("time")) { TQCString dateTime = args->getOption("time"); if (!convWakeTime(dateTime, alarmTime, alarmNoTime)) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--time"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--time"))) } else alarmTime = TQDateTime::tqcurrentDateTime(); @@ -505,9 +505,9 @@ int KAlarmApp::newInstance() if (haveRecurrence) { if (args->isSet("login")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--login")).arg(TQString::tqfromLatin1("--recurrence"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--login")).tqarg(TQString::tqfromLatin1("--recurrence"))) if (args->isSet("until")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--until")).arg(TQString::tqfromLatin1("--recurrence"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--until")).tqarg(TQString::tqfromLatin1("--recurrence"))) TQCString rule = args->getOption("recurrence"); recurrence.set(TQString::fromLocal8Bit(static_cast<const char*>(rule))); } @@ -516,24 +516,24 @@ int KAlarmApp::newInstance() // Repeat count is specified int count; if (args->isSet("login")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--login")).arg(TQString::tqfromLatin1("--interval"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--login")).tqarg(TQString::tqfromLatin1("--interval"))) bool ok; if (args->isSet("repeat")) { count = args->getOption("repeat").toInt(&ok); if (!ok || !count || count < -1 || (count < 0 && haveRecurrence)) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--repeat"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--repeat"))) } else if (haveRecurrence) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--interval")).arg(TQString::tqfromLatin1("--repeat"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--interval")).tqarg(TQString::tqfromLatin1("--repeat"))) else if (args->isSet("until")) { count = 0; TQCString dateTime = args->getOption("until"); if (!convWakeTime(dateTime, endTime, alarmNoTime)) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--until"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--until"))) if (endTime < alarmTime) - USAGE(i18n("%1 earlier than %2").arg(TQString::tqfromLatin1("--until")).arg(TQString::tqfromLatin1("--time"))) + USAGE(i18n("%1 earlier than %2").tqarg(TQString::tqfromLatin1("--until")).tqarg(TQString::tqfromLatin1("--time"))) } else count = -1; @@ -543,16 +543,16 @@ int KAlarmApp::newInstance() KARecurrence::Type recurType; if (!convInterval(args->getOption("interval"), recurType, interval, !haveRecurrence) || interval < 0) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--interval"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--interval"))) if (alarmNoTime && recurType == KARecurrence::MINUTELY) - USAGE(i18n("Invalid %1 parameter for date-only alarm").arg(TQString::tqfromLatin1("--interval"))) + USAGE(i18n("Invalid %1 parameter for date-only alarm").tqarg(TQString::tqfromLatin1("--interval"))) if (haveRecurrence) { // There is a also a recurrence specified, so set up a sub-repetition int longestInterval = recurrence.longestInterval(); if (count * interval > longestInterval) - USAGE(i18n("Invalid %1 and %2 parameters: repetition is longer than %3 interval").arg(TQString::tqfromLatin1("--interval")).arg(TQString::tqfromLatin1("--repeat")).arg(TQString::tqfromLatin1("--recurrence"))); + USAGE(i18n("Invalid %1 and %2 parameters: repetition is longer than %3 interval").tqarg(TQString::tqfromLatin1("--interval")).tqarg(TQString::tqfromLatin1("--repeat")).tqarg(TQString::tqfromLatin1("--recurrence"))); repeatCount = count; repeatInterval = interval; } @@ -566,9 +566,9 @@ int KAlarmApp::newInstance() else { if (args->isSet("repeat")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--repeat")).arg(TQString::tqfromLatin1("--interval"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--repeat")).tqarg(TQString::tqfromLatin1("--interval"))) if (args->isSet("until")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--until")).arg(TQString::tqfromLatin1("--interval"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--until")).tqarg(TQString::tqfromLatin1("--interval"))) } TQCString audioFile; @@ -582,11 +582,11 @@ int KAlarmApp::newInstance() { // Play a sound with the alarm if (audioRepeat && args->isSet("play")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--play")).arg(TQString::tqfromLatin1("--play-repeat"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--play")).tqarg(TQString::tqfromLatin1("--play-repeat"))) if (args->isSet("beep")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--beep")).arg(TQString::tqfromLatin1(audioRepeat ? "--play-repeat" : "--play"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--beep")).tqarg(TQString::tqfromLatin1(audioRepeat ? "--play-repeat" : "--play"))) if (args->isSet("speak")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--speak")).arg(TQString::tqfromLatin1(audioRepeat ? "--play-repeat" : "--play"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--speak")).tqarg(TQString::tqfromLatin1(audioRepeat ? "--play-repeat" : "--play"))) audioFile = args->getOption(audioRepeat ? "play-repeat" : "play"); #ifndef WITHOUT_ARTS if (args->isSet("volume")) @@ -594,21 +594,21 @@ int KAlarmApp::newInstance() bool ok; int volumepc = args->getOption("volume").toInt(&ok); if (!ok || volumepc < 0 || volumepc > 100) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("--volume"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("--volume"))) audioVolume = static_cast<float>(volumepc) / 100; } #endif } #ifndef WITHOUT_ARTS else if (args->isSet("volume")) - USAGE(i18n("%1 requires %2 or %3").arg(TQString::tqfromLatin1("--volume")).arg(TQString::tqfromLatin1("--play")).arg(TQString::tqfromLatin1("--play-repeat"))) + USAGE(i18n("%1 requires %2 or %3").tqarg(TQString::tqfromLatin1("--volume")).tqarg(TQString::tqfromLatin1("--play")).tqarg(TQString::tqfromLatin1("--play-repeat"))) #endif if (args->isSet("speak")) { if (args->isSet("beep")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--beep")).arg(TQString::tqfromLatin1("--speak"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--beep")).tqarg(TQString::tqfromLatin1("--speak"))) if (!mSpeechEnabled) - USAGE(i18n("%1 requires speech synthesis to be configured using KTTSD").arg(TQString::tqfromLatin1("--speak"))) + USAGE(i18n("%1 requires speech synthesis to be configured using KTTSD").tqarg(TQString::tqfromLatin1("--speak"))) } int reminderMinutes = 0; bool onceOnly = args->isSet("reminder-once"); @@ -616,18 +616,18 @@ int KAlarmApp::newInstance() { // Issue a reminder alarm in advance of the main alarm if (onceOnly && args->isSet("reminder")) - USAGE(i18n("%1 incompatible with %2").arg(TQString::tqfromLatin1("--reminder")).arg(TQString::tqfromLatin1("--reminder-once"))) + USAGE(i18n("%1 incompatible with %2").tqarg(TQString::tqfromLatin1("--reminder")).tqarg(TQString::tqfromLatin1("--reminder-once"))) TQString opt = onceOnly ? TQString::tqfromLatin1("--reminder-once") : TQString::tqfromLatin1("--reminder"); if (args->isSet("exec")) - USAGE(i18n("%1 incompatible with %2").arg(opt).arg(TQString::tqfromLatin1("--exec"))) + USAGE(i18n("%1 incompatible with %2").tqarg(opt).tqarg(TQString::tqfromLatin1("--exec"))) if (args->isSet("mail")) - USAGE(i18n("%1 incompatible with %2").arg(opt).arg(TQString::tqfromLatin1("--mail"))) + USAGE(i18n("%1 incompatible with %2").tqarg(opt).tqarg(TQString::tqfromLatin1("--mail"))) KARecurrence::Type recurType; TQString optval = args->getOption(onceOnly ? "reminder-once" : "reminder"); if (!convInterval(args->getOption(onceOnly ? "reminder-once" : "reminder"), recurType, reminderMinutes)) - USAGE(i18n("Invalid %1 parameter").arg(opt)) + USAGE(i18n("Invalid %1 parameter").tqarg(opt)) if (recurType == KARecurrence::MINUTELY && alarmNoTime) - USAGE(i18n("Invalid %1 parameter for date-only alarm").arg(opt)) + USAGE(i18n("Invalid %1 parameter for date-only alarm").tqarg(opt)) } int lateCancel = 0; @@ -636,10 +636,10 @@ int KAlarmApp::newInstance() KARecurrence::Type recurType; bool ok = convInterval(args->getOption("late-cancel"), recurType, lateCancel); if (!ok || lateCancel <= 0) - USAGE(i18n("Invalid %1 parameter").arg(TQString::tqfromLatin1("late-cancel"))) + USAGE(i18n("Invalid %1 parameter").tqarg(TQString::tqfromLatin1("late-cancel"))) } else if (args->isSet("auto-close")) - USAGE(i18n("%1 requires %2").arg(TQString::tqfromLatin1("--auto-close")).arg(TQString::tqfromLatin1("--late-cancel"))) + USAGE(i18n("%1 requires %2").tqarg(TQString::tqfromLatin1("--auto-close")).tqarg(TQString::tqfromLatin1("--late-cancel"))) int flags = KAEvent::DEFAULT_FONT; if (args->isSet("ack-confirm")) @@ -728,7 +728,7 @@ int KAlarmApp::newInstance() #endif if (!usage.isEmpty()) { - usage += i18n(": option(s) only valid with a message/%1/%2").arg(TQString::tqfromLatin1("--file")).arg(TQString::tqfromLatin1("--exec")); + usage += i18n(": option(s) only valid with a message/%1/%2").tqarg(TQString::tqfromLatin1("--file")).tqarg(TQString::tqfromLatin1("--exec")); break; } @@ -1759,7 +1759,7 @@ ShellProcess* KAlarmApp::doShellCommand(const TQString& command, const KAEvent& // Set up a logging process to write the command's output to. connect(proc, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)), TQT_SLOT(slotCommandOutput(KProcess*,char*,int))); connect(proc, TQT_SIGNAL(receivedStderr(KProcess*,char*,int)), TQT_SLOT(slotCommandOutput(KProcess*,char*,int))); - logproc = new ShellProcess(TQString::tqfromLatin1("cat >>%1").arg(event.logFile())); + logproc = new ShellProcess(TQString::tqfromLatin1("cat >>%1").tqarg(event.logFile())); connect(logproc, TQT_SIGNAL(shellExited(ShellProcess*)), TQT_SLOT(slotLogProcExited(ShellProcess*))); logproc->start(KProcess::Stdin); TQCString heading; diff --git a/kalarm/kalarmd/adcalendar.cpp b/kalarm/kalarmd/adcalendar.cpp index 2752a3689..e1f0823ae 100644 --- a/kalarm/kalarmd/adcalendar.cpp +++ b/kalarm/kalarmd/adcalendar.cpp @@ -51,7 +51,7 @@ ADCalendar::ADCalendar(const TQString& url, const TQCString& appname) kdError(5900) << "ADCalendar::ADCalendar(" << url << "): calendar already exists" << endl; assert(0); } - mUrlIndex = mCalendarUrls.findIndex(url); // get unique index for this URL + mUrlIndex = mCalendarUrls.tqfindIndex(url); // get unique index for this URL if (mUrlIndex < 0) { mUrlIndex = static_cast<int>(mCalendarUrls.count()); diff --git a/kalarm/kalarmd/adconfigdata.cpp b/kalarm/kalarmd/adconfigdata.cpp index 68344fa28..9f471e4da 100644 --- a/kalarm/kalarmd/adconfigdata.cpp +++ b/kalarm/kalarmd/adconfigdata.cpp @@ -104,7 +104,7 @@ void ADConfigData::writeClient(const TQCString& appName, const ClientInfo* cinfo KConfig* config = KGlobal::config(); config->setGroup(CLIENT_GROUP + TQString::fromLocal8Bit(appName)); config->writeEntry(TITLE_KEY, cinfo->title()); - config->writeEntry(DCOP_OBJECT_KEY, TQString::fromLocal8Bit(cinfo->dcopObject())); + config->writeEntry(DCOP_OBJECT_KEY, TQString(TQString::fromLocal8Bit(cinfo->dcopObject()))); config->writeEntry(START_CLIENT_KEY, cinfo->startClient()); config->writePathEntry(CALENDAR_KEY, cinfo->calendar()->urlString()); config->sync(); diff --git a/kalarm/kamail.cpp b/kalarm/kamail.cpp index 98647d93b..558406626 100644 --- a/kalarm/kamail.cpp +++ b/kalarm/kamail.cpp @@ -115,14 +115,14 @@ bool KAMail::send(const KAEvent& event, TQStringList& errmsgs, bool allowNotify) if (identity.isNull()) { kdError(5950) << "KAMail::send(): identity" << event.emailFromId() << "not found" << endl; - errmsgs = errors(i18n("Invalid 'From' email address.\nKMail identity '%1' not found.").arg(event.emailFromId())); + errmsgs = errors(i18n("Invalid 'From' email address.\nKMail identity '%1' not found.").tqarg(event.emailFromId())); return false; } from = identity.fullEmailAddr(); if (from.isEmpty()) { kdError(5950) << "KAMail::send(): identity" << identity.identityName() << "uoid" << identity.uoid() << ": no email address" << endl; - errmsgs = errors(i18n("Invalid 'From' email address.\nEmail identity '%1' has no email address").arg(identity.identityName())); + errmsgs = errors(i18n("Invalid 'From' email address.\nEmail identity '%1' has no email address").tqarg(identity.identityName())); return false; } } @@ -167,7 +167,7 @@ bool KAMail::send(const KAEvent& event, TQStringList& errmsgs, bool allowNotify) command = KStandardDirs::findExe(TQString::tqfromLatin1("mail")); if (command.isNull()) { - errmsgs = errors(i18n("%1 not found").arg(TQString::tqfromLatin1("sendmail"))); // give up + errmsgs = errors(i18n("%1 not found").tqarg(TQString::tqfromLatin1("sendmail"))); // give up return false; } @@ -387,14 +387,14 @@ TQString KAMail::initHeaders(const KAMailData& data, bool dateId) TQString from = data.from; from.tqreplace(TQRegExp("^.*<"), TQString()).tqreplace(TQRegExp(">.*$"), TQString()); message = TQString::tqfromLatin1(buff); - message += TQString::tqfromLatin1("\nMessage-Id: <%1.%2.%3>\n").arg(timenow).arg(tod.tv_usec).arg(from); + message += TQString::tqfromLatin1("\nMessage-Id: <%1.%2.%3>\n").tqarg(timenow).tqarg(tod.tv_usec).tqarg(from); } message += TQString::tqfromLatin1("From: ") + data.from; message += TQString::tqfromLatin1("\nTo: ") + data.event.emailAddresses(", "); if (!data.bcc.isEmpty()) message += TQString::tqfromLatin1("\nBcc: ") + data.bcc; message += TQString::tqfromLatin1("\nSubject: ") + data.event.emailSubject(); - message += TQString::tqfromLatin1("\nX-Mailer: %1/" KALARM_VERSION).arg(kapp->aboutData()->programName()); + message += TQString::tqfromLatin1("\nX-Mailer: %1/" KALARM_VERSION).tqarg(kapp->aboutData()->programName()); return message; } @@ -427,12 +427,12 @@ TQString KAMail::appendBodyAttachments(TQString& message, const KAEvent& event) TQCString boundary; boundary.sprintf("------------_%lu_-%lx=", 2*timenow, timenow); message += TQString::tqfromLatin1("\nMIME-Version: 1.0"); - message += TQString::tqfromLatin1("\nContent-Type: multipart/mixed;\n boundary=\"%1\"\n").arg(boundary); + message += TQString::tqfromLatin1("\nContent-Type: multipart/mixed;\n boundary=\"%1\"\n").tqarg(boundary.data()); if (!event.message().isEmpty()) { // There is a message body - message += TQString::tqfromLatin1("\n--%1\nContent-Type: text/plain\nContent-Transfer-Encoding: 8bit\n\n").arg(boundary); + message += TQString::tqfromLatin1("\n--%1\nContent-Type: text/plain\nContent-Transfer-Encoding: 8bit\n\n").tqarg(boundary.data()); message += event.message(); } @@ -446,12 +446,12 @@ TQString KAMail::appendBodyAttachments(TQString& message, const KAEvent& event) KIO::UDSEntry uds; if (!KIO::NetAccess::stat(url, uds, MainWindow::mainMainWindow())) { kdError(5950) << "KAMail::appendBodyAttachments(): not found: " << attachment << endl; - return i18n("Attachment not found:\n%1").arg(attachment); + return i18n("Attachment not found:\n%1").tqarg(attachment); } KFileItem fi(uds, url); if (fi.isDir() || !fi.isReadable()) { kdError(5950) << "KAMail::appendBodyAttachments(): not file/not readable: " << attachment << endl; - return attachError.arg(attachment); + return attachError.tqarg(attachment); } // Check if the attachment is a text file @@ -463,21 +463,21 @@ TQString KAMail::appendBodyAttachments(TQString& message, const KAEvent& event) text = (mimeType == textMimeTypes[i]); } - message += TQString::tqfromLatin1("\n--%1").arg(boundary); - message += TQString::tqfromLatin1("\nContent-Type: %2; name=\"%3\"").arg(mimeType).arg(fi.text()); - message += TQString::tqfromLatin1("\nContent-Transfer-Encoding: %1").arg(TQString::tqfromLatin1(text ? "8bit" : "BASE64")); - message += TQString::tqfromLatin1("\nContent-Disposition: attachment; filename=\"%4\"\n\n").arg(fi.text()); + message += TQString::tqfromLatin1("\n--%1").tqarg(boundary.data()); + message += TQString::tqfromLatin1("\nContent-Type: %2; name=\"%3\"").tqarg(mimeType).tqarg(fi.text()); + message += TQString::tqfromLatin1("\nContent-Transfer-Encoding: %1").tqarg(TQString::tqfromLatin1(text ? "8bit" : "BASE64")); + message += TQString::tqfromLatin1("\nContent-Disposition: attachment; filename=\"%4\"\n\n").tqarg(fi.text()); // Read the file contents TQString tmpFile; if (!KIO::NetAccess::download(url, tmpFile, MainWindow::mainMainWindow())) { kdError(5950) << "KAMail::appendBodyAttachments(): load failure: " << attachment << endl; - return attachError.arg(attachment); + return attachError.tqarg(attachment); } TQFile file(tmpFile); if (!file.open(IO_ReadOnly) ) { kdDebug(5950) << "KAMail::appendBodyAttachments() tmp load error: " << attachment << endl; - return attachError.arg(attachment); + return attachError.tqarg(attachment); } TQIODevice::Offset size = file.size(); char* contents = new char [size + 1]; @@ -509,9 +509,9 @@ TQString KAMail::appendBodyAttachments(TQString& message, const KAEvent& event) } delete[] contents; if (atterror) - return attachError.arg(attachment); + return attachError.tqarg(attachment); } - message += TQString::tqfromLatin1("\n--%1--\n.\n").arg(boundary); + message += TQString::tqfromLatin1("\n--%1--\n.\n").tqarg(boundary.data()); } return TQString(); } @@ -922,10 +922,10 @@ char* KAMail::base64Encode(const char* in, TQIODevice::Offset size, TQIODevice:: TQStringList KAMail::errors(const TQString& err, bool sendfail) { TQString error1 = sendfail ? i18n("Failed to send email") - : i18n("Error copying sent email to KMail %1 folder").arg(i18n_sent_mail()); + : i18n("Error copying sent email to KMail %1 folder").tqarg(i18n_sent_mail()); if (err.isEmpty()) return TQStringList(error1); - TQStringList errs(TQString::tqfromLatin1("%1:").arg(error1)); + TQStringList errs(TQString::tqfromLatin1("%1:").tqarg(error1)); errs += err; return errs; } diff --git a/kalarm/lib/checkbox.cpp b/kalarm/lib/checkbox.cpp index cff6cdb17..1d9cabffb 100644 --- a/kalarm/lib/checkbox.cpp +++ b/kalarm/lib/checkbox.cpp @@ -44,7 +44,7 @@ void CheckBox::setReadOnly(bool ro) if ((int)ro != (int)mReadOnly) { mReadOnly = ro; - setFocusPolicy(ro ? TQWidget::NoFocus : mFocusPolicy); + setFocusPolicy(ro ? Qt::NoFocus : mFocusPolicy); if (ro) clearFocus(); } @@ -86,7 +86,7 @@ void CheckBox::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQCheckBox::mousePressEvent(e); @@ -97,7 +97,7 @@ void CheckBox::mouseReleaseEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQCheckBox::mouseReleaseEvent(e); diff --git a/kalarm/lib/checkbox.h b/kalarm/lib/checkbox.h index 6b6985cd6..e535d4eab 100644 --- a/kalarm/lib/checkbox.h +++ b/kalarm/lib/checkbox.h @@ -80,7 +80,7 @@ class CheckBox : public TQCheckBox protected slots: void slotClicked(); private: - TQWidget::FocusPolicy mFocusPolicy; // default focus policy for the TQCheckBox + Qt::FocusPolicy mFocusPolicy; // default focus policy for the TQCheckBox TQWidget* mFocusWidget; // widget to receive focus when button is clicked on bool mFocusWidgetEnable; // enable focus widget before setting focus bool mReadOnly; // value cannot be changed diff --git a/kalarm/lib/colourcombo.cpp b/kalarm/lib/colourcombo.cpp index 769e6518b..5cea7fb83 100644 --- a/kalarm/lib/colourcombo.cpp +++ b/kalarm/lib/colourcombo.cpp @@ -41,7 +41,7 @@ ColourCombo::ColourCombo(TQWidget* tqparent, const char* name, const TQColor& de addColours(); connect(this, TQT_SIGNAL(activated(int)), TQT_SLOT(slotActivated(int))); connect(this, TQT_SIGNAL(highlighted(int)), TQT_SLOT(slotHighlighted(int))); - Preferences::connect(TQT_SIGNAL(preferencesChanged()), this, TQT_SLOT(slotPreferencesChanged())); + Preferences::connect(TQT_SIGNAL(preferencesChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotPreferencesChanged())); } void ColourCombo::setColour(const TQColor& colour) @@ -208,7 +208,7 @@ void ColourCombo::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQComboBox::mousePressEvent(e); diff --git a/kalarm/lib/colourlist.h b/kalarm/lib/colourlist.h index 7bee8d149..91fabaf92 100644 --- a/kalarm/lib/colourlist.h +++ b/kalarm/lib/colourlist.h @@ -95,7 +95,7 @@ class ColourList /** Returns the index to the first occurrence of colour @p c in the list. * Returns -1 if colour @p c is not in the list. */ - int findIndex(const TQColor& c) const { return mList.findIndex(c.rgb()); } + int findIndex(const TQColor& c) const { return mList.tqfindIndex(c.rgb()); } /** Returns the first colour in the list. If the list is empty, the result is undefined. */ TQColor first() const { return TQColor(mList.first()); } /** Returns the last colour in the list. If the list is empty, the result is undefined. */ diff --git a/kalarm/lib/combobox.cpp b/kalarm/lib/combobox.cpp index 0c526cae3..2acb5a442 100644 --- a/kalarm/lib/combobox.cpp +++ b/kalarm/lib/combobox.cpp @@ -47,7 +47,7 @@ void ComboBox::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQComboBox::mousePressEvent(e); diff --git a/kalarm/lib/dateedit.cpp b/kalarm/lib/dateedit.cpp index 38a6a5cba..0a916d9f6 100644 --- a/kalarm/lib/dateedit.cpp +++ b/kalarm/lib/dateedit.cpp @@ -81,7 +81,7 @@ void DateEdit::pastLimitMessage(const TQDate& limit, const TQString& error, cons errString = i18n("today"); else errString = KGlobal::locale()->formatDate(limit, true); - errString = defaultError.arg(errString); + errString = defaultError.tqarg(errString); } KMessageBox::sorry(this, errString); } @@ -91,7 +91,7 @@ void DateEdit::mousePressEvent(TQMouseEvent *e) if (isReadOnly()) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } KDateEdit::mousePressEvent(e); diff --git a/kalarm/lib/datetime.h b/kalarm/lib/datetime.h index 976bada90..bcfa434b1 100644 --- a/kalarm/lib/datetime.h +++ b/kalarm/lib/datetime.h @@ -169,7 +169,7 @@ class DateTime * If it is a date-time, both time and date are included in the output. * If it is date-only, only the date is included in the output. */ - TQString toString(TQt::DateFormat f = TQt::TextDate) const + TQString toString(Qt::DateFormat f = Qt::TextDate) const { if (mDateOnly) return mDateTime.date().toString(f); diff --git a/kalarm/lib/label.cpp b/kalarm/lib/label.cpp index d2b18ba10..d532b67e3 100644 --- a/kalarm/lib/label.cpp +++ b/kalarm/lib/label.cpp @@ -55,7 +55,7 @@ void Label::setBuddy(TQWidget* bud) if (w) { while (w->focusProxy()) - w = w->focusProxy(); + w = TQT_TQWIDGET(w->focusProxy()); if (!w->inherits(TQRADIOBUTTON_OBJECT_NAME_STRING)) w = 0; } @@ -106,7 +106,7 @@ void Label::activated() LabelFocusWidget::LabelFocusWidget(TQWidget* tqparent, const char* name) : TQWidget(tqparent, name) { - setFocusPolicy(ClickFocus); + setFocusPolicy(Qt::ClickFocus); setFixedSize(TQSize(1,1)); } diff --git a/kalarm/lib/lineedit.cpp b/kalarm/lib/lineedit.cpp index d85a99458..f19ed8066 100644 --- a/kalarm/lib/lineedit.cpp +++ b/kalarm/lib/lineedit.cpp @@ -78,11 +78,11 @@ void LineEdit::init() void LineEdit::focusInEvent(TQFocusEvent* e) { if (mNoSelect) - TQFocusEvent::setReason(TQFocusEvent::Other); + e->setReason(TQFocusEvent::Other); KLineEdit::focusInEvent(e); if (mNoSelect) { - TQFocusEvent::resetReason(); + e->resetReason(); mNoSelect = false; } } diff --git a/kalarm/lib/pushbutton.cpp b/kalarm/lib/pushbutton.cpp index e1e04099a..c251fa3c5 100644 --- a/kalarm/lib/pushbutton.cpp +++ b/kalarm/lib/pushbutton.cpp @@ -44,7 +44,7 @@ void PushButton::setReadOnly(bool ro) if ((int)ro != (int)mReadOnly) { mReadOnly = ro; - setFocusPolicy(ro ? TQWidget::NoFocus : mFocusPolicy); + setFocusPolicy(ro ? Qt::NoFocus : mFocusPolicy); if (ro) clearFocus(); } @@ -55,7 +55,7 @@ void PushButton::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQPushButton::mousePressEvent(e); @@ -66,7 +66,7 @@ void PushButton::mouseReleaseEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQPushButton::mouseReleaseEvent(e); diff --git a/kalarm/lib/pushbutton.h b/kalarm/lib/pushbutton.h index 615ea10cb..d0f4b0652 100644 --- a/kalarm/lib/pushbutton.h +++ b/kalarm/lib/pushbutton.h @@ -71,7 +71,7 @@ class PushButton : public TQPushButton virtual void keyPressEvent(TQKeyEvent*); virtual void keyReleaseEvent(TQKeyEvent*); private: - TQWidget::FocusPolicy mFocusPolicy; // default focus policy for the TQPushButton + Qt::FocusPolicy mFocusPolicy; // default focus policy for the TQPushButton bool mReadOnly; // value cannot be changed }; diff --git a/kalarm/lib/radiobutton.cpp b/kalarm/lib/radiobutton.cpp index d08097887..f34a574e3 100644 --- a/kalarm/lib/radiobutton.cpp +++ b/kalarm/lib/radiobutton.cpp @@ -44,7 +44,7 @@ void RadioButton::setReadOnly(bool ro) if ((int)ro != (int)mReadOnly) { mReadOnly = ro; - setFocusPolicy(ro ? TQWidget::NoFocus : mFocusPolicy); + setFocusPolicy(ro ? Qt::NoFocus : mFocusPolicy); if (ro) clearFocus(); } @@ -86,7 +86,7 @@ void RadioButton::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQRadioButton::mousePressEvent(e); @@ -97,7 +97,7 @@ void RadioButton::mouseReleaseEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQRadioButton::mouseReleaseEvent(e); diff --git a/kalarm/lib/radiobutton.h b/kalarm/lib/radiobutton.h index 9395be608..baa7cba39 100644 --- a/kalarm/lib/radiobutton.h +++ b/kalarm/lib/radiobutton.h @@ -80,7 +80,7 @@ class RadioButton : public TQRadioButton protected slots: void slotClicked(); private: - TQWidget::FocusPolicy mFocusPolicy; // default focus policy for the TQRadioButton + Qt::FocusPolicy mFocusPolicy; // default focus policy for the TQRadioButton TQWidget* mFocusWidget; // widget to receive focus when button is clicked on bool mFocusWidgetEnable; // enable focus widget before setting focus bool mReadOnly; // value cannot be changed diff --git a/kalarm/lib/shellprocess.cpp b/kalarm/lib/shellprocess.cpp index 09daf91db..c2f2e11bd 100644 --- a/kalarm/lib/shellprocess.cpp +++ b/kalarm/lib/shellprocess.cpp @@ -185,7 +185,7 @@ const TQCString& ShellProcess::shellPath() } // Get the shell filename with the path stripped off - int i = mShellPath.findRev('/'); + int i = mShellPath.tqfindRev('/'); if (i >= 0) mShellName = mShellPath.mid(i + 1); else diff --git a/kalarm/lib/slider.cpp b/kalarm/lib/slider.cpp index 0b30f744a..f901f6db1 100644 --- a/kalarm/lib/slider.cpp +++ b/kalarm/lib/slider.cpp @@ -54,7 +54,7 @@ void Slider::mousePressEvent(TQMouseEvent* e) if (mReadOnly) { // Swallow up the event if it's the left button - if (e->button() == TQt::LeftButton) + if (e->button() == Qt::LeftButton) return; } TQSlider::mousePressEvent(e); diff --git a/kalarm/lib/spinbox.cpp b/kalarm/lib/spinbox.cpp index 19608eabe..fc8e6b7c3 100644 --- a/kalarm/lib/spinbox.cpp +++ b/kalarm/lib/spinbox.cpp @@ -201,7 +201,7 @@ void SpinBox::updateDisplay() */ bool SpinBox::eventFilter(TQObject* obj, TQEvent* e) { - if (obj == editor()) + if (TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(editor())) { int step = 0; bool shift = false; @@ -263,7 +263,7 @@ bool SpinBox::eventFilter(TQObject* obj, TQEvent* e) case TQEvent::MouseButtonDblClick: { TQMouseEvent* me = (TQMouseEvent*)e; - if (me->button() == TQt::LeftButton) + if (me->button() == Qt::LeftButton) { // It's a left button press. Set normal or shift stepping as appropriate. if (mReadOnly) @@ -281,7 +281,7 @@ bool SpinBox::eventFilter(TQObject* obj, TQEvent* e) case TQEvent::MouseButtonRelease: { TQMouseEvent* me = (TQMouseEvent*)e; - if (me->button() == TQt::LeftButton && mShiftMouse) + if (me->button() == Qt::LeftButton && mShiftMouse) { setShiftStepping(false, mCurrentButton); // cancel shift stepping return false; // forward event to the destination widget @@ -291,7 +291,7 @@ bool SpinBox::eventFilter(TQObject* obj, TQEvent* e) case TQEvent::MouseMove: { TQMouseEvent* me = (TQMouseEvent*)e; - if (me->state() & TQt::LeftButton) + if (me->state() & Qt::LeftButton) { // The left button is down. Track which spin button it's in. if (mReadOnly) @@ -325,7 +325,7 @@ bool SpinBox::eventFilter(TQObject* obj, TQEvent* e) TQKeyEvent* ke = (TQKeyEvent*)e; int key = ke->key(); int state = ke->state(); - if ((state & TQt::LeftButton) + if ((state & Qt::LeftButton) && (key == TQt::Key_Shift || key == TQt::Key_Alt)) { // The left mouse button is down, and the Shift or Alt key has changed diff --git a/kalarm/lib/spinbox2.cpp b/kalarm/lib/spinbox2.cpp index 8627838b6..3d7cde021 100644 --- a/kalarm/lib/spinbox2.cpp +++ b/kalarm/lib/spinbox2.cpp @@ -85,9 +85,9 @@ void SpinBox2::init() mSpinbox->setSelectOnStep(false); // default mUpdown2->setSelectOnStep(false); // always false setFocusProxy(mSpinbox); - mUpdown2->setFocusPolicy(TQWidget::NoFocus); + mUpdown2->setFocusPolicy(Qt::NoFocus); mSpinMirror = new SpinMirror(mUpdown2, mUpdown2Frame, this); - if (!mirrorStyle(style())) + if (!mirrorStyle(tqstyle())) mSpinMirror->hide(); // hide mirrored spin buttons when they are inappropriate connect(mSpinbox, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(valueChange())); connect(mSpinbox, TQT_SIGNAL(valueChanged(int)), TQT_SIGNAL(valueChanged(int))); @@ -243,7 +243,7 @@ TQSize SpinBox2::tqminimumSizeHint() const void SpinBox2::styleChange(TQStyle&) { - if (mirrorStyle(style())) + if (mirrorStyle(tqstyle())) mSpinMirror->show(); // show rounded corners with Plastik etc. else mSpinMirror->hide(); // keep normal shading with other styles @@ -282,16 +282,16 @@ void SpinBox2::arrange() */ void SpinBox2::getMetrics() const { - TQRect rect = mUpdown2->style().querySubControlMetrics(TQStyle::CC_SpinWidget, mUpdown2, TQStyle::SC_SpinWidgetButtonField); - if (style().inherits("PlastikStyle")) + TQRect rect = mUpdown2->tqstyle().querySubControlMetrics(TQStyle::CC_SpinWidget, mUpdown2, TQStyle::SC_SpinWidgetButtonField); + if (tqstyle().inherits("PlastikStyle")) rect.setLeft(rect.left() - 1); // Plastik excludes left border from spin widget rectangle xUpdown2 = mReverseLayout ? 0 : rect.left(); wUpdown2 = mUpdown2->width() - rect.left(); - xSpinbox = mSpinbox->style().querySubControlMetrics(TQStyle::CC_SpinWidget, mSpinbox, TQStyle::SC_SpinWidgetEditField).left(); + xSpinbox = mSpinbox->tqstyle().querySubControlMetrics(TQStyle::CC_SpinWidget, mSpinbox, TQStyle::SC_SpinWidgetEditField).left(); wGap = 0; // Make style-specific adjustments for a better appearance - if (style().inherits(TQMOTIFPLUSSTYLE_OBJECT_NAME_STRING)) + if (tqstyle().inherits(TQMOTIFPLUSSTYLE_OBJECT_NAME_STRING)) { xSpinbox = 0; // show the edit control left border wGap = 2; // leave a space to the right of the left-hand pair of spin buttons @@ -422,7 +422,7 @@ void SpinMirror::redraw() void SpinMirror::redraw(const TQPixmap& px) { TQCanvas* c = canvas(); - c->setBackgroundPixmap(px); + c->tqsetBackgroundPixmap(px); c->setAllChanged(); c->update(); } diff --git a/kalarm/lib/timespinbox.cpp b/kalarm/lib/timespinbox.cpp index f8700a505..1a2a65008 100644 --- a/kalarm/lib/timespinbox.cpp +++ b/kalarm/lib/timespinbox.cpp @@ -31,7 +31,7 @@ class TimeSpinBox::TimeValidator : public TQValidator { public: TimeValidator(int minMin, int maxMin, TQWidget* tqparent, const char* name = 0) - : TQValidator(tqparent, name), + : TQValidator(TQT_TQOBJECT(tqparent), name), minMinute(minMin), maxMinute(maxMin), m12Hour(false), mPm(false) { } virtual State validate(TQString&, int&) const; int minMinute, maxMinute; diff --git a/kalarm/mainwindow.cpp b/kalarm/mainwindow.cpp index 07e976c6a..34b13e5ff 100644 --- a/kalarm/mainwindow.cpp +++ b/kalarm/mainwindow.cpp @@ -182,7 +182,7 @@ MainWindow::~MainWindow() else theApp()->trayWindow()->removeWindow(this); } - MinuteTimer::disconnect(this); + MinuteTimer::disconnect(TQT_TQOBJECT(this)); mMinuteTimerActive = false; // to ensure that setUpdateTimer() works correctly setUpdateTimer(); MainWindow* main = mainMainWindow(); @@ -294,7 +294,7 @@ void MainWindow::show() // Show error message now that the main window has been displayed. // Waiting until now lets the user easily associate the message with // the main window which is faulty. - KMessageBox::error(this, i18n("Failure to create menus\n(perhaps %1 missing or corrupted)").arg(TQString::tqfromLatin1(UI_FILE))); + KMessageBox::error(this, i18n("Failure to create menus\n(perhaps %1 missing or corrupted)").tqarg(TQString::tqfromLatin1(UI_FILE))); mMenuError = false; } } @@ -326,55 +326,55 @@ void MainWindow::columnsReordered() void MainWindow::initActions() { KActionCollection* actions = actionCollection(); - mActionTemplates = new KAction(i18n("&Templates..."), 0, this, TQT_SLOT(slotTemplates()), actions, "templates"); - mActionNew = KAlarm::createNewAlarmAction(i18n("&New..."), this, TQT_SLOT(slotNew()), actions, "new"); - mActionNewFromTemplate = KAlarm::createNewFromTemplateAction(i18n("New &From Template"), this, TQT_SLOT(slotNewFromTemplate(const KAEvent&)), actions, "newFromTempl"); - mActionCreateTemplate = new KAction(i18n("Create Tem&plate..."), 0, this, TQT_SLOT(slotNewTemplate()), actions, "createTemplate"); - mActionCopy = new KAction(i18n("&Copy..."), "editcopy", TQt::SHIFT+TQt::Key_Insert, this, TQT_SLOT(slotCopy()), actions, "copy"); - mActionModify = new KAction(i18n("&Edit..."), "edit", TQt::CTRL+TQt::Key_E, this, TQT_SLOT(slotModify()), actions, "modify"); - mActionDelete = new KAction(i18n("&Delete"), "editdelete", TQt::Key_Delete, this, TQT_SLOT(slotDelete()), actions, "delete"); - mActionReactivate = new KAction(i18n("Reac&tivate"), 0, TQt::CTRL+TQt::Key_R, this, TQT_SLOT(slotReactivate()), actions, "undelete"); - mActionEnable = new KAction(TQString(), 0, TQt::CTRL+TQt::Key_B, this, TQT_SLOT(slotEnable()), actions, "disable"); - mActionView = new KAction(i18n("&View"), "viewmag", TQt::CTRL+TQt::Key_W, this, TQT_SLOT(slotView()), actions, "view"); - mActionShowTime = new KToggleAction(i18n_a_ShowAlarmTimes(), TQt::CTRL+TQt::Key_M, this, TQT_SLOT(slotShowTime()), actions, "showAlarmTimes"); + mActionTemplates = new KAction(i18n("&Templates..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotTemplates()), actions, "templates"); + mActionNew = KAlarm::createNewAlarmAction(i18n("&New..."), TQT_TQOBJECT(this), TQT_SLOT(slotNew()), actions, "new"); + mActionNewFromTemplate = KAlarm::createNewFromTemplateAction(i18n("New &From Template"), TQT_TQOBJECT(this), TQT_SLOT(slotNewFromTemplate(const KAEvent&)), actions, "newFromTempl"); + mActionCreateTemplate = new KAction(i18n("Create Tem&plate..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotNewTemplate()), actions, "createTemplate"); + mActionCopy = new KAction(i18n("&Copy..."), "editcopy", TQt::SHIFT+TQt::Key_Insert, TQT_TQOBJECT(this), TQT_SLOT(slotCopy()), actions, "copy"); + mActionModify = new KAction(i18n("&Edit..."), "edit", TQt::CTRL+TQt::Key_E, TQT_TQOBJECT(this), TQT_SLOT(slotModify()), actions, "modify"); + mActionDelete = new KAction(i18n("&Delete"), "editdelete", TQt::Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotDelete()), actions, "delete"); + mActionReactivate = new KAction(i18n("Reac&tivate"), 0, TQt::CTRL+TQt::Key_R, TQT_TQOBJECT(this), TQT_SLOT(slotReactivate()), actions, "undelete"); + mActionEnable = new KAction(TQString(), 0, TQt::CTRL+TQt::Key_B, TQT_TQOBJECT(this), TQT_SLOT(slotEnable()), actions, "disable"); + mActionView = new KAction(i18n("&View"), "viewmag", TQt::CTRL+TQt::Key_W, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actions, "view"); + mActionShowTime = new KToggleAction(i18n_a_ShowAlarmTimes(), TQt::CTRL+TQt::Key_M, TQT_TQOBJECT(this), TQT_SLOT(slotShowTime()), actions, "showAlarmTimes"); mActionShowTime->setCheckedState(i18n("Hide &Alarm Times")); - mActionShowTimeTo = new KToggleAction(i18n_o_ShowTimeToAlarms(), TQt::CTRL+TQt::Key_I, this, TQT_SLOT(slotShowTimeTo()), actions, "showTimeToAlarms"); + mActionShowTimeTo = new KToggleAction(i18n_o_ShowTimeToAlarms(), TQt::CTRL+TQt::Key_I, TQT_TQOBJECT(this), TQT_SLOT(slotShowTimeTo()), actions, "showTimeToAlarms"); mActionShowTimeTo->setCheckedState(i18n("Hide Time t&o Alarms")); - mActionShowExpired = new KToggleAction(i18n_e_ShowExpiredAlarms(), "history", TQt::CTRL+TQt::Key_P, this, TQT_SLOT(slotShowExpired()), actions, "showExpiredAlarms"); + mActionShowExpired = new KToggleAction(i18n_e_ShowExpiredAlarms(), "history", TQt::CTRL+TQt::Key_P, TQT_TQOBJECT(this), TQT_SLOT(slotShowExpired()), actions, "showExpiredAlarms"); mActionShowExpired->setCheckedState(i18n_e_HideExpiredAlarms()); - mActionToggleTrayIcon = new KToggleAction(i18n("Show in System &Tray"), 0, this, TQT_SLOT(slotToggleTrayIcon()), actions, "showInSystemTray"); + mActionToggleTrayIcon = new KToggleAction(i18n("Show in System &Tray"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleTrayIcon()), actions, "showInSystemTray"); mActionToggleTrayIcon->setCheckedState(i18n("Hide From System &Tray")); - new KAction(i18n("Import &Alarms..."), 0, this, TQT_SLOT(slotImportAlarms()), actions, "importAlarms"); - new KAction(i18n("Import &Birthdays..."), 0, this, TQT_SLOT(slotBirthdays()), actions, "importBirthdays"); - new KAction(i18n("&Refresh Alarms"), "reload", 0, this, TQT_SLOT(slotResetDaemon()), actions, "refreshAlarms"); + new KAction(i18n("Import &Alarms..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotImportAlarms()), actions, "importAlarms"); + new KAction(i18n("Import &Birthdays..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotBirthdays()), actions, "importBirthdays"); + new KAction(i18n("&Refresh Alarms"), "reload", 0, TQT_TQOBJECT(this), TQT_SLOT(slotResetDaemon()), actions, "refreshAlarms"); Daemon::createAlarmEnableAction(actions, "alarmEnable"); if (undoText.isNull()) { // Get standard texts, etc., for Undo and Redo actions - KAction* act = KStdAction::undo(this, 0, actions); + KAction* act = KStdAction::undo(TQT_TQOBJECT(this), 0, actions); undoIcon = act->icon(); undoShortcut = act->shortcut(); undoText = act->text(); undoTextStripped = KAlarm::stripAccel(undoText); delete act; - act = KStdAction::redo(this, 0, actions); + act = KStdAction::redo(TQT_TQOBJECT(this), 0, actions); redoIcon = act->icon(); redoShortcut = act->shortcut(); redoText = act->text(); redoTextStripped = KAlarm::stripAccel(redoText); delete act; } - mActionUndo = new KToolBarPopupAction(undoText, undoIcon, undoShortcut, this, TQT_SLOT(slotUndo()), actions, "edit_undo"); - mActionRedo = new KToolBarPopupAction(redoText, redoIcon, redoShortcut, this, TQT_SLOT(slotRedo()), actions, "edit_redo"); - KStdAction::tqfind(mListView, TQT_SLOT(slotFind()), actions); - mActionFindNext = KStdAction::findNext(mListView, TQT_SLOT(slotFindNext()), actions); - mActionFindPrev = KStdAction::findPrev(mListView, TQT_SLOT(slotFindPrev()), actions); - KStdAction::selectAll(mListView, TQT_SLOT(slotSelectAll()), actions); - KStdAction::deselect(mListView, TQT_SLOT(slotDeselect()), actions); - KStdAction::quit(this, TQT_SLOT(slotQuit()), actions); - KStdAction::keyBindings(this, TQT_SLOT(slotConfigureKeys()), actions); - KStdAction::configureToolbars(this, TQT_SLOT(slotConfigureToolbar()), actions); - KStdAction::preferences(this, TQT_SLOT(slotPreferences()), actions); + mActionUndo = new KToolBarPopupAction(undoText, undoIcon, undoShortcut, TQT_TQOBJECT(this), TQT_SLOT(slotUndo()), actions, "edit_undo"); + mActionRedo = new KToolBarPopupAction(redoText, redoIcon, redoShortcut, TQT_TQOBJECT(this), TQT_SLOT(slotRedo()), actions, "edit_redo"); + KStdAction::find(TQT_TQOBJECT(mListView), TQT_SLOT(slotFind()), actions); + mActionFindNext = KStdAction::findNext(TQT_TQOBJECT(mListView), TQT_SLOT(slotFindNext()), actions); + mActionFindPrev = KStdAction::findPrev(TQT_TQOBJECT(mListView), TQT_SLOT(slotFindPrev()), actions); + KStdAction::selectAll(TQT_TQOBJECT(mListView), TQT_SLOT(slotSelectAll()), actions); + KStdAction::deselect(TQT_TQOBJECT(mListView), TQT_SLOT(slotDeselect()), actions); + KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), actions); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(slotConfigureKeys()), actions); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotConfigureToolbar()), actions); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actions); setStandardToolBarMenuEnabled(true); createGUI(UI_FILE); @@ -388,7 +388,7 @@ void MainWindow::initActions() connect(mActionRedo->popupMenu(), TQT_SIGNAL(activated(int)), TQT_SLOT(slotRedoItem(int))); connect(Undo::instance(), TQT_SIGNAL(changed(const TQString&, const TQString&)), TQT_SLOT(slotUndotqStatus(const TQString&, const TQString&))); connect(mListView, TQT_SIGNAL(findActive(bool)), TQT_SLOT(slotFindActive(bool))); - Preferences::connect(TQT_SIGNAL(preferencesChanged()), this, TQT_SLOT(slotPrefsChanged())); + Preferences::connect(TQT_SIGNAL(preferencesChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotPrefsChanged())); connect(theApp(), TQT_SIGNAL(trayIconToggled()), TQT_SLOT(updateTrayIconAction())); // Set menu item states @@ -485,13 +485,13 @@ void MainWindow::setUpdateTimer() { // Timeout every minute. needTimer->mMinuteTimerActive = true; - MinuteTimer::connect(needTimer, TQT_SLOT(slotUpdateTimeTo())); + MinuteTimer::connect(TQT_TQOBJECT(needTimer), TQT_SLOT(slotUpdateTimeTo())); kdDebug(5950) << "MainWindow::setUpdateTimer(): started timer" << endl; } else if (!needTimer && timerWindow) { timerWindow->mMinuteTimerActive = false; - MinuteTimer::disconnect(timerWindow); + MinuteTimer::disconnect(TQT_TQOBJECT(timerWindow)); kdDebug(5950) << "MainWindow::setUpdateTimer(): stopped timer" << endl; } } @@ -1023,8 +1023,8 @@ void MainWindow::initUndoMenu(KPopupMenu* menu, Undo::Type type) TQString actText = Undo::actionText(type, id); TQString descrip = Undo::description(type, id); TQString text = descrip.isEmpty() - ? i18n("Undo/Redo [action]", "%1 %2").arg(action).arg(actText) - : i18n("Undo [action]: message", "%1 %2: %3").arg(action).arg(actText).arg(descrip); + ? i18n("Undo/Redo [action]", "%1 %2").tqarg(action).tqarg(actText) + : i18n("Undo [action]: message", "%1 %2: %3").tqarg(action).tqarg(actText).tqarg(descrip); menu->insertItem(text, id); } } @@ -1043,7 +1043,7 @@ void MainWindow::slotUndotqStatus(const TQString& undo, const TQString& redo) else { mActionUndo->setEnabled(true); - mActionUndo->setText(TQString("%1 %2").arg(undoText).arg(undo)); + mActionUndo->setText(TQString("%1 %2").tqarg(undoText).tqarg(undo)); } if (redo.isNull()) { @@ -1053,7 +1053,7 @@ void MainWindow::slotUndotqStatus(const TQString& undo, const TQString& redo) else { mActionRedo->setEnabled(true); - mActionRedo->setText(TQString("%1 %2").arg(redoText).arg(redo)); + mActionRedo->setText(TQString("%1 %2").tqarg(redoText).tqarg(redo)); } } @@ -1088,7 +1088,7 @@ void MainWindow::slotConfigureToolbar() { saveMainWindowSettings(KGlobal::config(), WINDOW_NAME); KEditToolbar dlg(factory()); - connect(&dlg, TQT_SIGNAL(newToolbarConfig()), this, TQT_SLOT(slotNewToolbarConfig())); + connect(&dlg, TQT_SIGNAL(newToolbarConfig()), TQT_TQOBJECT(this), TQT_SLOT(slotNewToolbarConfig())); dlg.exec(); } @@ -1350,7 +1350,7 @@ void MainWindow::slotContextMenuRequested(TQListViewItem* item, const TQPoint& p */ void MainWindow::slotMouseClicked(int button, TQListViewItem* item, const TQPoint& pt, int) { - if (button != TQt::RightButton && !item) + if (button != Qt::RightButton && !item) { kdDebug(5950) << "MainWindow::slotMouseClicked(left)" << endl; mListView->clearSelection(); diff --git a/kalarm/messagewin.cpp b/kalarm/messagewin.cpp index c6a0916c8..7bf51b0a6 100644 --- a/kalarm/messagewin.cpp +++ b/kalarm/messagewin.cpp @@ -429,12 +429,12 @@ void MessageWin::initView() if (mDateTime.isDateOnly() || TQDate::tqcurrentDate().daysTo(mDateTime.date()) > 0) { setRemainingTextDay(); - MidnightTimer::connect(this, TQT_SLOT(setRemainingTextDay())); // update every day + MidnightTimer::connect(TQT_TQOBJECT(this), TQT_SLOT(setRemainingTextDay())); // update every day } else { setRemainingTextMinute(); - MinuteTimer::connect(this, TQT_SLOT(setRemainingTextMinute())); // update every minute + MinuteTimer::connect(TQT_TQOBJECT(this), TQT_SLOT(setRemainingTextMinute())); // update every minute } topLayout->addWidget(mRemainingText, 0, TQt::AlignHCenter); topLayout->addSpacing(KDialog::spacingHint()); @@ -510,7 +510,7 @@ void MessageWin::initView() mOkButton = new KPushButton(KStdGuiItem::close(), topWidget); // Prevent accidental acknowledgement of the message if the user is typing when the window appears mOkButton->clearFocus(); - mOkButton->setFocusPolicy(TQWidget::ClickFocus); // don't allow keyboard selection + mOkButton->setFocusPolicy(Qt::ClickFocus); // don't allow keyboard selection mOkButton->setFixedSize(mOkButton->tqsizeHint()); connect(mOkButton, TQT_SIGNAL(clicked()), TQT_SLOT(close())); grid->addWidget(mOkButton, 0, gridIndex++, AlignHCenter); @@ -520,7 +520,7 @@ void MessageWin::initView() { // Edit button mEditButton = new TQPushButton(i18n("&Edit..."), topWidget); - mEditButton->setFocusPolicy(TQWidget::ClickFocus); // don't allow keyboard selection + mEditButton->setFocusPolicy(Qt::ClickFocus); // don't allow keyboard selection mEditButton->setFixedSize(mEditButton->tqsizeHint()); connect(mEditButton, TQT_SIGNAL(clicked()), TQT_SLOT(slotEdit())); grid->addWidget(mEditButton, 0, gridIndex++, AlignHCenter); @@ -531,7 +531,7 @@ void MessageWin::initView() { // Defer button mDeferButton = new TQPushButton(i18n("&Defer..."), topWidget); - mDeferButton->setFocusPolicy(TQWidget::ClickFocus); // don't allow keyboard selection + mDeferButton->setFocusPolicy(Qt::ClickFocus); // don't allow keyboard selection mDeferButton->setFixedSize(mDeferButton->tqsizeHint()); connect(mDeferButton, TQT_SIGNAL(clicked()), TQT_SLOT(slotDefer())); grid->addWidget(mDeferButton, 0, gridIndex++, AlignHCenter); @@ -619,9 +619,9 @@ void MessageWin::setRemainingTextDay() if (days <= 0 && !mDateTime.isDateOnly()) { // The alarm is due today, so start refreshing every minute - MidnightTimer::disconnect(this, TQT_SLOT(setRemainingTextDay())); + MidnightTimer::disconnect(TQT_TQOBJECT(this), TQT_SLOT(setRemainingTextDay())); setRemainingTextMinute(); - MinuteTimer::connect(this, TQT_SLOT(setRemainingTextMinute())); // update every minute + MinuteTimer::connect(TQT_TQOBJECT(this), TQT_SLOT(setRemainingTextMinute())); // update every minute } else { @@ -650,7 +650,7 @@ void MessageWin::setRemainingTextMinute() else if (mins % 60 == 1) text = i18n("in 1 hour 1 minute's time", "in %n hours 1 minute's time", mins/60); else - text = i18n("in 1 hour %1 minutes' time", "in %n hours %1 minutes' time", mins/60).arg(mins%60); + text = i18n("in 1 hour %1 minutes' time", "in %n hours %1 minutes' time", mins/60).tqarg(mins%60); mRemainingText->setText(text); } @@ -859,7 +859,7 @@ void MessageWin::slotPlayAudio() kdError(5950) << "MessageWin::playAudio(): Open failure: " << mAudioFile << endl; if (!haveErrorMessage(ErrMsg_AudioFile)) { - KMessageBox::error(this, i18n("Cannot open audio file:\n%1").arg(mAudioFile)); + KMessageBox::error(this, i18n("Cannot open audio file:\n%1").tqarg(mAudioFile)); clearErrorMessage(ErrMsg_AudioFile); } return; @@ -882,7 +882,7 @@ void MessageWin::slotPlayAudio() kdWarning(5950) << "Unable to set master volume (KMix: " << mKMixError << ")\n"; if (!haveErrorMessage(ErrMsg_Volume)) { - KMessageBox::information(this, i18n("Unable to set master volume\n(Error accessing KMix:\n%1)").arg(mKMixError), + KMessageBox::information(this, i18n("Unable to set master volume\n(Error accessing KMix:\n%1)").tqarg(mKMixError), TQString(), TQString::tqfromLatin1("KMixError")); clearErrorMessage(ErrMsg_Volume); } @@ -1497,7 +1497,7 @@ void MessageWin::setDeferralLimit(const KAEvent& event) if (mDeferButton) { mDeferLimit = event.deferralLimit().dateTime(); - MidnightTimer::connect(this, TQT_SLOT(checkDeferralLimit())); // check every day + MidnightTimer::connect(TQT_TQOBJECT(this), TQT_SLOT(checkDeferralLimit())); // check every day mDisableDeferral = false; checkDeferralLimit(); } @@ -1519,7 +1519,7 @@ void MessageWin::checkDeferralLimit() int n = TQDate::tqcurrentDate().daysTo(mDeferLimit.date()); if (n > 0) return; - MidnightTimer::disconnect(this, TQT_SLOT(checkDeferralLimit())); + MidnightTimer::disconnect(TQT_TQOBJECT(this), TQT_SLOT(checkDeferralLimit())); if (n == 0) { // The deferral limit will be reached today @@ -1540,7 +1540,7 @@ void MessageWin::checkDeferralLimit() */ void MessageWin::slotDefer() { - mDeferDlg = new DeferAlarmDlg(i18n("Defer Alarm"), TQDateTime::tqcurrentDateTime().addSecs(60), + mDeferDlg = new DeferAlarmDlg(i18n("Defer Alarm"), TQDateTime(TQDateTime::tqcurrentDateTime().addSecs(60)), false, this, "deferDlg"); if (mDefaultDeferMinutes > 0) mDeferDlg->setDeferMinutes(mDefaultDeferMinutes); diff --git a/kalarm/prefdlg.cpp b/kalarm/prefdlg.cpp index ec6aa4837..90b48dd85 100644 --- a/kalarm/prefdlg.cpp +++ b/kalarm/prefdlg.cpp @@ -233,7 +233,7 @@ PrefsTabBase::PrefsTabBase(TQVBox* frame) mPage(frame) { if (!mIndentWidth) - mIndentWidth = style().subRect(TQStyle::SR_RadioButtonIndicator, this).width(); + mIndentWidth = tqstyle().subRect(TQStyle::SR_RadioButtonIndicator, this).width(); } void PrefsTabBase::apply(bool syncToDisc) @@ -310,7 +310,7 @@ MiscPrefTab::MiscPrefTab(TQVBox* frame) TQWhatsThis::add(mAutostartDaemon, i18n("Automatically start alarm monitoring whenever you start KDE, by running the alarm daemon (%1).\n\n" "This option should always be checked unless you intend to discontinue use of KAlarm.") - .arg(TQString::tqfromLatin1(DAEMON_APP_NAME))); + .tqarg(TQString::tqfromLatin1(DAEMON_APP_NAME))); grid->addMultiCellWidget(mAutostartDaemon, 6, 6, 0, 2, tqalignment); group->setFixedHeight(group->tqsizeHint().height()); @@ -325,7 +325,7 @@ MiscPrefTab::MiscPrefTab(TQVBox* frame) label->setBuddy(mStartOfDay); static const TQString startOfDayText = i18n("The earliest time of day at which a date-only alarm (i.e. " "an alarm with \"any time\" specified) will be triggered."); - TQWhatsThis::add(box, TQString("%1\n\n%2").arg(startOfDayText).arg(TimeSpinBox::shiftWhatsThis())); + TQWhatsThis::add(box, TQString("%1\n\n%2").tqarg(startOfDayText).tqarg(TimeSpinBox::shiftWhatsThis())); itemBox->setStretchFactor(new TQWidget(itemBox), 1); // left adjust the controls itemBox->setFixedHeight(box->tqsizeHint().height()); @@ -404,7 +404,7 @@ MiscPrefTab::MiscPrefTab(TQVBox* frame) cmd.tqreplace("%w", "<command; sleep>"); cmd.tqreplace("%C", "[command]"); cmd.tqreplace("%W", "[command; sleep]"); - TQWhatsThis::add(radio, whatsThis.arg(cmd)); + TQWhatsThis::add(radio, whatsThis.tqarg(cmd)); grid->addWidget(radio, (row = index/3 + 1), index % 3, TQt::AlignAuto); ++index; } @@ -470,7 +470,7 @@ void MiscPrefTab::apply(bool syncToDisc) if (KStandardDirs::findExe(cmd).isEmpty()) { mXtermCommand->setFocus(); - if (KMessageBox::warningContinueCancel(this, i18n("Command to invoke terminal window not found:\n%1").arg(cmd)) + if (KMessageBox::warningContinueCancel(this, i18n("Command to invoke terminal window not found:\n%1").tqarg(cmd)) != KMessageBox::Continue) return; } @@ -618,10 +618,10 @@ EmailPrefTab::EmailPrefTab(TQVBox* frame) "your system is configured to use sendmail or a sendmail compatible mail transport agent.")); box = new TQHBox(mPage); // this is to allow left adjustment - mEmailCopyToKMail = new TQCheckBox(i18n("Co&py sent emails into KMail's %1 folder").arg(KAMail::i18n_sent_mail()), box); + mEmailCopyToKMail = new TQCheckBox(i18n("Co&py sent emails into KMail's %1 folder").tqarg(KAMail::i18n_sent_mail()), box); mEmailCopyToKMail->setFixedSize(mEmailCopyToKMail->tqsizeHint()); TQWhatsThis::add(mEmailCopyToKMail, - i18n("After sending an email, store a copy in KMail's %1 folder").arg(KAMail::i18n_sent_mail())); + i18n("After sending an email, store a copy in KMail's %1 folder").tqarg(KAMail::i18n_sent_mail())); box->setStretchFactor(new TQWidget(box), 1); // left adjust the controls box->setFixedHeight(box->tqsizeHint().height()); @@ -793,18 +793,18 @@ TQString EmailPrefTab::validate() TQString EmailPrefTab::validateAddr(ButtonGroup* group, TQLineEdit* addr, const TQString& msg) { - TQString errmsg = i18n("%1\nAre you sure you want to save your changes?").arg(msg); + TQString errmsg = i18n("%1\nAre you sure you want to save your changes?").tqarg(msg); switch (group->selectedId()) { case Preferences::MAIL_FROM_CONTROL_CENTRE: if (!KAMail::controlCentreAddress().isEmpty()) return TQString(); - errmsg = i18n("No email address is currently set in the KDE Control Center. %1").arg(errmsg); + errmsg = i18n("No email address is currently set in the KDE Control Center. %1").tqarg(errmsg); break; case Preferences::MAIL_FROM_KMAIL: if (KAMail::identitiesExist()) return TQString(); - errmsg = i18n("No KMail identities currently exist. %1").arg(errmsg); + errmsg = i18n("No KMail identities currently exist. %1").tqarg(errmsg); break; case Preferences::MAIL_FROM_ADDR: if (!addr->text().stripWhiteSpace().isEmpty()) @@ -902,12 +902,12 @@ EditPrefTab::EditPrefTab(TQVBox* frame) mConfirmAck = new TQCheckBox(EditAlarmDlg::i18n_k_ConfirmAck(), group, "defConfAck"); mConfirmAck->setMinimumSize(mConfirmAck->tqsizeHint()); - TQWhatsThis::add(mConfirmAck, defsetting.arg(EditAlarmDlg::i18n_ConfirmAck())); + TQWhatsThis::add(mConfirmAck, defsetting.tqarg(EditAlarmDlg::i18n_ConfirmAck())); tqlayout->addWidget(mConfirmAck, 0, TQt::AlignAuto); mAutoClose = new TQCheckBox(LateCancelSelector::i18n_i_AutoCloseWinLC(), group, "defAutoClose"); mAutoClose->setMinimumSize(mAutoClose->tqsizeHint()); - TQWhatsThis::add(mAutoClose, defsetting.arg(LateCancelSelector::i18n_AutoCloseWin())); + TQWhatsThis::add(mAutoClose, defsetting.tqarg(LateCancelSelector::i18n_AutoCloseWin())); tqlayout->addWidget(mAutoClose, 0, TQt::AlignAuto); TQHBox* box = new TQHBox(group); @@ -942,14 +942,14 @@ EditPrefTab::EditPrefTab(TQVBox* frame) if (theApp()->speechEnabled()) mSound->insertItem(SoundPicker::i18n_Speak()); // index 3 mSound->setMinimumSize(mSound->tqsizeHint()); - TQWhatsThis::add(mSound, defsetting.arg(SoundPicker::i18n_Sound())); + TQWhatsThis::add(mSound, defsetting.tqarg(SoundPicker::i18n_Sound())); htqlayout->addWidget(mSound); htqlayout->addStretch(1); #ifndef WITHOUT_ARTS mSoundRepeat = new TQCheckBox(i18n("Repea&t sound file"), bgroup, "defRepeatSound"); mSoundRepeat->setMinimumSize(mSoundRepeat->tqsizeHint()); - TQWhatsThis::add(mSoundRepeat, i18n("sound file \"Repeat\" checkbox", "The default setting for sound file \"%1\" in the alarm edit dialog.").arg(SoundDlg::i18n_Repeat())); + TQWhatsThis::add(mSoundRepeat, i18n("sound file \"Repeat\" checkbox", "The default setting for sound file \"%1\" in the alarm edit dialog.").tqarg(SoundDlg::i18n_Repeat())); htqlayout->addWidget(mSoundRepeat); #endif @@ -978,13 +978,13 @@ EditPrefTab::EditPrefTab(TQVBox* frame) mCmdScript = new TQCheckBox(EditAlarmDlg::i18n_p_EnterScript(), group, "defCmdScript"); mCmdScript->setMinimumSize(mCmdScript->tqsizeHint()); - TQWhatsThis::add(mCmdScript, defsetting.arg(EditAlarmDlg::i18n_EnterScript())); + TQWhatsThis::add(mCmdScript, defsetting.tqarg(EditAlarmDlg::i18n_EnterScript())); tqlayout->addWidget(mCmdScript); tqlayout->addStretch(); mCmdXterm = new TQCheckBox(EditAlarmDlg::i18n_w_ExecInTermWindow(), group, "defCmdXterm"); mCmdXterm->setMinimumSize(mCmdXterm->tqsizeHint()); - TQWhatsThis::add(mCmdXterm, defsetting.arg(EditAlarmDlg::i18n_ExecInTermWindow())); + TQWhatsThis::add(mCmdXterm, defsetting.tqarg(EditAlarmDlg::i18n_ExecInTermWindow())); tqlayout->addWidget(mCmdXterm); // EMAIL ALARMS @@ -995,21 +995,21 @@ EditPrefTab::EditPrefTab(TQVBox* frame) // BCC email to sender mEmailBcc = new TQCheckBox(EditAlarmDlg::i18n_e_CopyEmailToSelf(), group, "defEmailBcc"); mEmailBcc->setMinimumSize(mEmailBcc->tqsizeHint()); - TQWhatsThis::add(mEmailBcc, defsetting.arg(EditAlarmDlg::i18n_CopyEmailToSelf())); + TQWhatsThis::add(mEmailBcc, defsetting.tqarg(EditAlarmDlg::i18n_CopyEmailToSelf())); tqlayout->addWidget(mEmailBcc, 0, TQt::AlignAuto); // MISCELLANEOUS // Show in KOrganizer mCopyToKOrganizer = new TQCheckBox(EditAlarmDlg::i18n_g_ShowInKOrganizer(), mPage, "defShowKorg"); mCopyToKOrganizer->setMinimumSize(mCopyToKOrganizer->tqsizeHint()); - TQWhatsThis::add(mCopyToKOrganizer, defsetting.arg(EditAlarmDlg::i18n_ShowInKOrganizer())); + TQWhatsThis::add(mCopyToKOrganizer, defsetting.tqarg(EditAlarmDlg::i18n_ShowInKOrganizer())); // Late cancellation box = new TQHBox(mPage); box->setSpacing(KDialog::spacingHint()); mLateCancel = new TQCheckBox(LateCancelSelector::i18n_n_CancelIfLate(), box, "defCancelLate"); mLateCancel->setMinimumSize(mLateCancel->tqsizeHint()); - TQWhatsThis::add(mLateCancel, defsetting.arg(LateCancelSelector::i18n_CancelIfLate())); + TQWhatsThis::add(mLateCancel, defsetting.tqarg(LateCancelSelector::i18n_CancelIfLate())); box->setStretchFactor(new TQWidget(box), 1); // left adjust the control // Recurrence @@ -1179,7 +1179,7 @@ TQString EditPrefTab::validate() if (mSound->currentItem() == SoundPicker::PLAY_FILE && mSoundFile->text().isEmpty()) { mSoundFile->setFocus(); - return i18n("You must enter a sound file when %1 is selected as the default sound type").arg(SoundPicker::i18n_File());; + return i18n("You must enter a sound file when %1 is selected as the default sound type").tqarg(SoundPicker::i18n_File());; } return TQString(); } diff --git a/kalarm/recurrenceedit.cpp b/kalarm/recurrenceedit.cpp index 5ac3c9bf5..e360ef49c 100644 --- a/kalarm/recurrenceedit.cpp +++ b/kalarm/recurrenceedit.cpp @@ -103,7 +103,7 @@ RecurrenceEdit::RecurrenceEdit(bool readOnly, TQWidget* tqparent, const char* na * selection of its corresponding radio button. */ - TQGroupBox* recurGroup = new TQGroupBox(1, TQt::Vertical, i18n("Recurrence Rule"), this, "recurGroup"); + TQGroupBox* recurGroup = new TQGroupBox(1, Qt::Vertical, i18n("Recurrence Rule"), this, "recurGroup"); topLayout->addWidget(recurGroup); TQFrame* ruleFrame = new TQFrame(recurGroup, "ruleFrame"); tqlayout = new TQVBoxLayout(ruleFrame, 0); @@ -111,7 +111,7 @@ RecurrenceEdit::RecurrenceEdit(bool readOnly, TQWidget* tqparent, const char* na tqlayout = new TQHBoxLayout(tqlayout, 0); TQBoxLayout* lay = new TQVBoxLayout(tqlayout, 0); - mRuleButtonGroup = new ButtonGroup(1, TQt::Horizontal, ruleFrame); + mRuleButtonGroup = new ButtonGroup(1, Qt::Horizontal, ruleFrame); mRuleButtonGroup->setInsideMargin(0); mRuleButtonGroup->setFrameStyle(TQFrame::NoFrame); lay->addWidget(mRuleButtonGroup); @@ -268,7 +268,7 @@ RecurrenceEdit::RecurrenceEdit(bool readOnly, TQWidget* tqparent, const char* na mEndTimeEdit->setFixedSize(mEndTimeEdit->tqsizeHint()); mEndTimeEdit->setReadOnly(mReadOnly); static const TQString lastTimeText = i18n("Enter the last time to repeat the alarm."); - TQWhatsThis::add(mEndTimeEdit, TQString("%1\n\n%2").arg(lastTimeText).arg(TimeSpinBox::shiftWhatsThis())); + TQWhatsThis::add(mEndTimeEdit, TQString("%1\n\n%2").tqarg(lastTimeText).tqarg(TimeSpinBox::shiftWhatsThis())); mEndAnyTimeCheckBox = new CheckBox(i18n("Any time"), mRangeButtonGroup); mEndAnyTimeCheckBox->setFixedSize(mEndAnyTimeCheckBox->tqsizeHint()); mEndAnyTimeCheckBox->setReadOnly(mReadOnly); @@ -619,7 +619,7 @@ void RecurrenceEdit::enableExceptionButtons() mChangeExceptionButton->setEnabled(enable); // Prevent the exceptions list box receiving keyboard focus is it's empty - mExceptionDateList->setFocusPolicy(mExceptionDateList->count() ? TQWidget::WheelFocus : TQWidget::NoFocus); + mExceptionDateList->setFocusPolicy(mExceptionDateList->count() ? Qt::WheelFocus : Qt::NoFocus); } /****************************************************************************** diff --git a/kalarm/sounddlg.cpp b/kalarm/sounddlg.cpp index 02d3af55b..feb53bd68 100644 --- a/kalarm/sounddlg.cpp +++ b/kalarm/sounddlg.cpp @@ -133,7 +133,7 @@ SoundDlg::SoundDlg(const TQString& file, float volume, float fadeVolume, int fad i18n("Select to choose the volume for playing the sound file.")); // Volume slider - mVolumeSlider = new Slider(0, 100, 10, 0, TQt::Horizontal, box); + mVolumeSlider = new Slider(0, 100, 10, 0, Qt::Horizontal, box); mVolumeSlider->setTickmarks(TQSlider::Below); mVolumeSlider->setTickInterval(10); mVolumeSlider->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed)); @@ -168,7 +168,7 @@ SoundDlg::SoundDlg(const TQString& file, float volume, float fadeVolume, int fad grid->addWidget(mFadeVolumeBox, 4, 2); label = new TQLabel(i18n("Initial volume:"), mFadeVolumeBox); label->setFixedSize(label->tqsizeHint()); - mFadeSlider = new Slider(0, 100, 10, 0, TQt::Horizontal, mFadeVolumeBox); + mFadeSlider = new Slider(0, 100, 10, 0, Qt::Horizontal, mFadeVolumeBox); mFadeSlider->setTickmarks(TQSlider::Below); mFadeSlider->setTickInterval(10); mFadeSlider->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed)); @@ -299,7 +299,7 @@ void SoundDlg::playSound() || !KIO::NetAccess::download(url, mLocalAudioFile, mmw)) { kdError(5950) << "SoundDlg::playAudio(): Open failure: " << mFileName << endl; - KMessageBox::error(this, i18n("Cannot open audio file:\n%1").arg(mFileName)); + KMessageBox::error(this, i18n("Cannot open audio file:\n%1").tqarg(mFileName)); return; } mPlayTimer = new TQTimer(this); diff --git a/kalarm/soundpicker.cpp b/kalarm/soundpicker.cpp index 25d871c41..c6915601b 100644 --- a/kalarm/soundpicker.cpp +++ b/kalarm/soundpicker.cpp @@ -114,9 +114,9 @@ void SoundPicker::showSpeak(bool show) if (show == mSpeakShowing) return; // no change TQString whatsThis = "<p>" + i18n("Choose a sound to play when the message is displayed.") - + "<br>" + i18n("%1: the message is displayed silently.").arg("<b>" + i18n_None() + "</b>") - + "<br>" + i18n("%1: a simple beep is sounded.").arg("<b>" + i18n_Beep() + "</b>") - + "<br>" + i18n("%1: an audio file is played. You will be prompted to choose the file and set play options.").arg("<b>" + i18n_File() + "</b>"); + + "<br>" + i18n("%1: the message is displayed silently.").tqarg("<b>" + i18n_None() + "</b>") + + "<br>" + i18n("%1: a simple beep is sounded.").tqarg("<b>" + i18n_Beep() + "</b>") + + "<br>" + i18n("%1: an audio file is played. You will be prompted to choose the file and set play options.").tqarg("<b>" + i18n_File() + "</b>"); if (!show && mTypeCombo->currentItem() == SPEAK) mTypeCombo->setCurrentItem(NONE); if (mTypeCombo->count() == SPEAK+1) @@ -124,7 +124,7 @@ void SoundPicker::showSpeak(bool show) if (show) { mTypeCombo->insertItem(i18n_Speak()); - whatsThis += "<br>" + i18n("%1: the message text is spoken.").arg("<b>" + i18n_Speak() + "</b>") + "</p>"; + whatsThis += "<br>" + i18n("%1: the message text is spoken.").tqarg("<b>" + i18n_Speak() + "</b>") + "</p>"; } TQWhatsThis::add(mTypeBox, whatsThis + "</p>"); mSpeakShowing = show; @@ -283,7 +283,7 @@ TQString SoundPicker::browseFile(TQString& defaultDir, const TQString& initialFi defaultDir = kdeSoundDir; } #ifdef WITHOUT_ARTS - TQString filter = TQString::tqfromLatin1("*.wav *.mp3 *.ogg|%1\n*|%2").arg(i18n("Sound Files")).arg(i18n("All Files")); + TQString filter = TQString::tqfromLatin1("*.wav *.mp3 *.ogg|%1\n*|%2").tqarg(i18n("Sound Files")).tqarg(i18n("All Files")); #else TQStringList filters = KDE::PlayObjectFactory::mimeTypes(); TQString filter = filters.join(" "); diff --git a/kalarm/templatedlg.cpp b/kalarm/templatedlg.cpp index 6e493b91e..64a247c7d 100644 --- a/kalarm/templatedlg.cpp +++ b/kalarm/templatedlg.cpp @@ -80,8 +80,8 @@ TemplateDlg::TemplateDlg(TQWidget* tqparent, const char* name) tqlayout->addWidget(mDeleteButton); KAccel* accel = new KAccel(this); - accel->insert(KStdAccel::SelectAll, mTemplateList, TQT_SLOT(slotSelectAll())); - accel->insert(KStdAccel::Deselect, mTemplateList, TQT_SLOT(slotDeselect())); + accel->insert(KStdAccel::SelectAll, TQT_TQOBJECT(mTemplateList), TQT_SLOT(slotSelectAll())); + accel->insert(KStdAccel::Deselect, TQT_TQOBJECT(mTemplateList), TQT_SLOT(slotDeselect())); accel->readSettings(); mTemplateList->refresh(); diff --git a/kalarm/traywindow.cpp b/kalarm/traywindow.cpp index 190cb5384..3dd686a9e 100644 --- a/kalarm/traywindow.cpp +++ b/kalarm/traywindow.cpp @@ -88,15 +88,15 @@ TrayWindow::TrayWindow(MainWindow* tqparent, const char* name) AlarmEnableAction* a = Daemon::createAlarmEnableAction(actcol, "tAlarmEnable"); a->plug(contextMenu()); connect(a, TQT_SIGNAL(switched(bool)), TQT_SLOT(setEnabledtqStatus(bool))); - KAlarm::createNewAlarmAction(i18n("&New Alarm..."), this, TQT_SLOT(slotNewAlarm()), actcol, "tNew")->plug(contextMenu()); - KAlarm::createNewFromTemplateAction(i18n("New Alarm From &Template"), this, TQT_SLOT(slotNewFromTemplate(const KAEvent&)), actcol, "tNewFromTempl")->plug(contextMenu()); - KStdAction::preferences(this, TQT_SLOT(slotPreferences()), actcol)->plug(contextMenu()); + KAlarm::createNewAlarmAction(i18n("&New Alarm..."), TQT_TQOBJECT(this), TQT_SLOT(slotNewAlarm()), actcol, "tNew")->plug(contextMenu()); + KAlarm::createNewFromTemplateAction(i18n("New Alarm From &Template"), TQT_TQOBJECT(this), TQT_SLOT(slotNewFromTemplate(const KAEvent&)), actcol, "tNewFromTempl")->plug(contextMenu()); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actcol)->plug(contextMenu()); // Replace the default handler for the Quit context menu item const char* quitName = KStdAction::name(KStdAction::Quit); actcol->remove(actcol->action(quitName)); actcol->accel()->remove(quitName); - KStdAction::quit(this, TQT_SLOT(slotQuit()), actcol); + KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), actcol); // Set icon to correspond with the alarms enabled menu status Daemon::checktqStatus(); @@ -173,12 +173,12 @@ void TrayWindow::setEnabledtqStatus(bool status) */ void TrayWindow::mousePressEvent(TQMouseEvent* e) { - if (e->button() == LeftButton && !theApp()->wantRunInSystemTray()) + if (e->button() == Qt::LeftButton && !theApp()->wantRunInSystemTray()) { // Left click: display/hide the first main window mAssocMainWindow = MainWindow::toggleWindow(mAssocMainWindow); } - else if (e->button() == MidButton) + else if (e->button() == Qt::MidButton) MainWindow::executeNew(); // display a New Alarm dialog else KSystemTray::mousePressEvent(e); @@ -191,7 +191,7 @@ void TrayWindow::mousePressEvent(TQMouseEvent* e) */ void TrayWindow::mouseReleaseEvent(TQMouseEvent* e) { - if (e->button() == LeftButton && mAssocMainWindow && mAssocMainWindow->isVisible()) + if (e->button() == Qt::LeftButton && mAssocMainWindow && mAssocMainWindow->isVisible()) { mAssocMainWindow->raise(); mAssocMainWindow->setActiveWindow(); @@ -266,9 +266,9 @@ void TrayWindow::tooltipAlarmText(TQString& text) const minutes[0] = (mins%60) / 10 + '0'; minutes[1] = (mins%60) % 10 + '0'; if (Preferences::showTooltipAlarmTime()) - item.text += i18n("prefix + hours:minutes", "(%1%2:%3)").arg(prefix).arg(mins/60).arg(minutes); + item.text += i18n("prefix + hours:minutes", "(%1%2:%3)").tqarg(prefix).tqarg(mins/60).tqarg(minutes); else - item.text += i18n("prefix + hours:minutes", "%1%2:%3").arg(prefix).arg(mins/60).arg(minutes); + item.text += i18n("prefix + hours:minutes", "%1%2:%3").tqarg(prefix).tqarg(mins/60).tqarg(minutes); item.text += ' '; space = true; } @@ -353,7 +353,7 @@ void TrayTooltip::maybeTip(const TQPoint&) if (Daemon::monitoringAlarms()) text = kapp->aboutData()->programName(); else - text = i18n("%1 - disabled").arg(kapp->aboutData()->programName()); + text = i18n("%1 - disabled").tqarg(kapp->aboutData()->programName()); kdDebug(5950) << "TrayTooltip::maybeTip(): " << text << endl; if (Preferences::tooltipAlarmCount()) tqparent->tooltipAlarmText(text); diff --git a/kalarm/undo.cpp b/kalarm/undo.cpp index c3b56612d..81d101c3f 100644 --- a/kalarm/undo.cpp +++ b/kalarm/undo.cpp @@ -207,7 +207,7 @@ Undo::List Undo::mRedoList; Undo* Undo::instance() { if (!mInstance) - mInstance = new Undo(kapp); + mInstance = new Undo(TQT_TQOBJECT(kapp)); return mInstance; } @@ -357,7 +357,7 @@ bool Undo::undo(Undo::Iterator it, Undo::Type type, TQWidget* tqparent, const TQ case UndoItem::ERR_PROG: err = i18n("Program error"); break; default: err = i18n("Unknown error"); break; } - KMessageBox::sorry(tqparent, i18n("Undo-action: message", "%1: %2").arg(action).arg(err)); + KMessageBox::sorry(tqparent, i18n("Undo-action: message", "%1: %2").tqarg(action).tqarg(err)); return false; } diff --git a/kandy/src/atcommand.cpp b/kandy/src/atcommand.cpp index e43814b43..d010bb0bd 100644 --- a/kandy/src/atcommand.cpp +++ b/kandy/src/atcommand.cpp @@ -306,7 +306,7 @@ void ATCommand::extractParameters() TQStringList::ConstIterator end = paraList.end(); int argNum = 1; while(it != end) { - addParameter(new ATParameter(*it,i18n("Arg %1").arg(TQString::number(argNum++)), + addParameter(new ATParameter(*it,i18n("Arg %1").tqarg(TQString::number(argNum++)), false)); ++it; } diff --git a/kandy/src/cmdpropertiesdialog_base.ui b/kandy/src/cmdpropertiesdialog_base.ui index 57359e3e2..4b768c364 100644 --- a/kandy/src/cmdpropertiesdialog_base.ui +++ b/kandy/src/cmdpropertiesdialog_base.ui @@ -147,9 +147,9 @@ <connections> <connection> <sender>mParameterList</sender> - <signal>rightButtonClicked(QListViewItem*,const QPoint&,int)</signal> + <signal>rightButtonClicked(TQListViewItem*,const QPoint&,int)</signal> <receiver>CmdPropertiesDialog_base</receiver> - <slot>editParameterName(QListViewItem*)</slot> + <slot>editParameterName(TQListViewItem*)</slot> </connection> <connection> <sender>buttonOk</sender> @@ -165,7 +165,7 @@ </connection> </connections> <Q_SLOTS> - <slot>editParameterName(QListViewItem *)</slot> + <slot>editParameterName(TQListViewItem *)</slot> <slot access="protected">slotAccept()</slot> </Q_SLOTS> <tqlayoutdefaults spacing="6" margin="11"/> diff --git a/kandy/src/kandy.cpp b/kandy/src/kandy.cpp index 4766947a2..5e68abe43 100644 --- a/kandy/src/kandy.cpp +++ b/kandy/src/kandy.cpp @@ -102,7 +102,7 @@ Kandy::~Kandy() void Kandy::load(const TQString& filename) { if (!mView->loadFile(filename)) { - KMessageBox::error(this,i18n("Could not load file %1").arg(filename)); + KMessageBox::error(this,i18n("Could not load file %1").tqarg(filename)); } mFilename = filename; @@ -113,7 +113,7 @@ void Kandy::save(const TQString & filename) { if (!filename.isEmpty()) { if (!mView->saveFile(filename)) { - KMessageBox::error(this,i18n("Could not save file %1.").arg(filename)); + KMessageBox::error(this,i18n("Could not save file %1.").tqarg(filename)); } else { mFilename = filename; setTitle(); @@ -123,25 +123,25 @@ void Kandy::save(const TQString & filename) void Kandy::setupActions() { - KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection()); - KStdAction::save(this, TQT_SLOT(fileSave()), actionCollection()); - KStdAction::saveAs(this, TQT_SLOT(fileSaveAs()), actionCollection()); -// KStdAction::print(this, TQT_SLOT(filePrint()), actionCollection()); - KStdAction::quit(this, TQT_SLOT(close()), actionCollection()); + KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(fileOpen()), actionCollection()); + KStdAction::save(TQT_TQOBJECT(this), TQT_SLOT(fileSave()), actionCollection()); + KStdAction::saveAs(TQT_TQOBJECT(this), TQT_SLOT(fileSaveAs()), actionCollection()); +// KStdAction::print(TQT_TQOBJECT(this), TQT_SLOT(filePrint()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection()); createStandardStatusBarAction(); setStandardToolBarMenuEnabled(true); - KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection()); - KStdAction::preferences(this, TQT_SLOT(optionsPreferences()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(optionsPreferences()), actionCollection()); - new KAction(i18n("Mobile GUI"),0,this,TQT_SLOT(showMobileGui()), + new KAction(i18n("Mobile GUI"),0,TQT_TQOBJECT(this),TQT_SLOT(showMobileGui()), actionCollection(),"show_mobilegui"); - mConnectAction = new KAction(i18n("Connect"),0,this,TQT_SLOT(modemConnect()), + mConnectAction = new KAction(i18n("Connect"),0,TQT_TQOBJECT(this),TQT_SLOT(modemConnect()), actionCollection(),"modem_connect"); - mDisconnectAction = new KAction(i18n("Disconnect"),0,this, + mDisconnectAction = new KAction(i18n("Disconnect"),0,TQT_TQOBJECT(this), TQT_SLOT(modemDisconnect()),actionCollection(), "modem_disconnect"); @@ -300,7 +300,7 @@ bool Kandy::queryClose() { if (mView->isModified()) { switch (KMessageBox::warningYesNoCancel(this, - i18n("Save changes to profile %1?").arg(mFilename), TQString(), KStdGuiItem::save(), KStdGuiItem::discard())) { + i18n("Save changes to profile %1?").tqarg(mFilename), TQString(), KStdGuiItem::save(), KStdGuiItem::discard())) { case KMessageBox::Yes : fileSave(); return true; @@ -319,7 +319,7 @@ void Kandy::modemConnect() if (!mScheduler->modem()->open()) { KMessageBox::sorry(this, i18n("Cannot open modem tqdevice %1.") - .arg(KandyPrefs::serialDevice()), i18n("Modem Error")); + .tqarg(KandyPrefs::serialDevice()), i18n("Modem Error")); return; } diff --git a/kandy/src/kandyview.cpp b/kandy/src/kandyview.cpp index 38fcb9cb1..6e76235be 100644 --- a/kandy/src/kandyview.cpp +++ b/kandy/src/kandyview.cpp @@ -65,7 +65,7 @@ KandyView::KandyView(CommandScheduler *scheduler,TQWidget *tqparent) TQBoxLayout *topLayout = new TQVBoxLayout( this ); - TQSplitter *mainSplitter = new TQSplitter( Horizontal, this ); + TQSplitter *mainSplitter = new TQSplitter( Qt::Horizontal, this ); topLayout->addWidget( mainSplitter ); TQWidget *commandBox = new TQWidget( mainSplitter ); @@ -99,7 +99,7 @@ KandyView::KandyView(CommandScheduler *scheduler,TQWidget *tqparent) commandLayout->addWidget( buttonExecute ); connect( buttonExecute, TQT_SIGNAL( clicked() ), TQT_SLOT( executeCommand() ) ); - TQSplitter *ioSplitter = new TQSplitter( Vertical, mainSplitter ); + TQSplitter *ioSplitter = new TQSplitter( Qt::Vertical, mainSplitter ); TQWidget *inBox = new TQWidget( ioSplitter ); @@ -250,7 +250,7 @@ void KandyView::executeCommand() if (p->userInput()) { bool ok = false; TQString value = KInputDialog::getText(TQString(), - i18n("Enter value for %1:").arg(p->name()),TQString(),&ok,this); + i18n("Enter value for %1:").tqarg(p->name()),TQString(),&ok,this); if (!ok) return; p->setValue(value); diff --git a/kandy/src/mobilemain.cpp b/kandy/src/mobilemain.cpp index 7b39d8d30..de3e2b3e8 100644 --- a/kandy/src/mobilemain.cpp +++ b/kandy/src/mobilemain.cpp @@ -71,17 +71,17 @@ MobileMain::~MobileMain() void MobileMain::setupActions() { - KStdAction::quit(this, TQT_SLOT(close()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection()); - new KAction(i18n("Terminal"),0,this,TQT_SLOT(showTerminal()), + new KAction(i18n("Terminal"),0,TQT_TQOBJECT(this),TQT_SLOT(showTerminal()), actionCollection(),"show_terminal"); createStandardStatusBarAction(); setStandardToolBarMenuEnabled(true); - KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection()); - KStdAction::preferences(this, TQT_SLOT(optionsPreferences()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(optionsPreferences()), actionCollection()); createGUI("kandymobileui.rc"); } @@ -169,7 +169,7 @@ bool MobileMain::queryClose() #if 0 if (m_view->isModified()) { switch (KMessageBox::warningYesNoCancel(this, - i18n("Save changes to profile %1?").arg(mFilename))) { + i18n("Save changes to profile %1?").tqarg(mFilename))) { case KMessageBox::Yes : fileSave(); return true; diff --git a/kandy/src/modem.cpp b/kandy/src/modem.cpp index 4b085de6a..113f2e4bc 100644 --- a/kandy/src/modem.cpp +++ b/kandy/src/modem.cpp @@ -196,7 +196,7 @@ bool Modem::open() if ( ( fd = ::open( fdev, O_RDWR | O_NOCTTY | O_NONBLOCK ) ) == -1 ) { emit errorMessage( i18n( "Unable to open tqdevice '%1'. " "Please check that you have sufficient permissions." ) - .arg( fdev ) ); + .tqarg( fdev ) ); return false; } @@ -204,7 +204,7 @@ bool Modem::open() if ( tcgetattr( fd, &init_tty ) == -1 ) { int errnumber = errno; emit errorMessage( i18n( "Communication setup failed (tcgetattr code: %1)" ) - .arg(strerror(errnumber)) ); + .tqarg(strerror(errnumber)) ); ::close( fd ); fd = 0; return false; @@ -279,7 +279,7 @@ bool Modem::lockDevice() #ifdef HAVE_LOCKDEV is_locked = !dev_lock( (*prefs).serialDevice().local8Bit() ); if (!is_locked) - emit errorMessage( i18n( "Unable to lock tqdevice '%1'." ).arg( + emit errorMessage( i18n( "Unable to lock tqdevice '%1'." ).tqarg( (*prefs).serialDevice() )); return is_locked; #else @@ -299,7 +299,7 @@ bool Modem::lockDevice() if ( ( lfd = ::open( TQFile::encodeName( fileName ), O_RDONLY ) ) < 0 ) { emit errorMessage( i18n( "Unable to open lock file '%1'.") - .arg( fileName ) ); + .tqarg( fileName ) ); return false; } @@ -307,7 +307,7 @@ bool Modem::lockDevice() if ( count < 0 ) { emit errorMessage( i18n( "Unable to read lock file '%1'.") - .arg( fileName ) ); + .tqarg( fileName ) ); ::close( lfd ); return false; } @@ -317,13 +317,13 @@ bool Modem::lockDevice() count = sscanf( buf, "%d", &pid ); if ( ( count != 1 ) || ( pid <= 0 ) ) { emit errorMessage( i18n( "Unable to get PID from file '%1'.") - .arg( fileName ) ); + .tqarg( fileName ) ); return false; } if ( !kill( (pid_t) pid, 0 ) ) { emit errorMessage( i18n( "Process with PID %1, which is locking the tqdevice, is still running.") - .arg( pid ) ); + .tqarg( pid ) ); return false; } @@ -336,7 +336,7 @@ bool Modem::lockDevice() if ( ( lfd = creat( TQFile::encodeName( fileName ).data(), 0644 ) ) == -1 ) { emit errorMessage( i18n( "Unable to create lock file '%1'. " "Please check that you have sufficient permissions.") - .arg( fileName ) ); + .tqarg( fileName ) ); return false; } diff --git a/karm/desktoptracker.cpp b/karm/desktoptracker.cpp index 3c9e5e846..773f6aea9 100644 --- a/karm/desktoptracker.cpp +++ b/karm/desktoptracker.cpp @@ -84,7 +84,7 @@ void DesktopTracker::registerForDesktops( Task* task, DesktopList desktopList) if (desktopList.size()==0) { for (int i=0; i<maxDesktops; i++) { TaskVector *v = &(desktopTracker[i]); - TaskVector::iterator tit = std::tqfind(v->begin(), v->end(), task); + TaskVector::iterator tit = std::find(v->begin(), v->end(), task); if (tit != v->end()) desktopTracker[i].erase(tit); // if the task was priviously tracking this desktop then @@ -102,9 +102,9 @@ void DesktopTracker::registerForDesktops( Task* task, DesktopList desktopList) if (desktopList.size()>0) { for (int i=0; i<maxDesktops; i++) { TaskVector& v = desktopTracker[i]; - TaskVector::iterator tit = std::tqfind(v.begin(), v.end(), task); + TaskVector::iterator tit = std::find(v.begin(), v.end(), task); // Is desktop i in the desktop list? - if ( std::tqfind( desktopList.begin(), desktopList.end(), i) + if ( std::find( desktopList.begin(), desktopList.end(), i) != desktopList.end()) { if (tit == v.end()) // not yet in start vector v.push_back(task); // track in desk i diff --git a/karm/edittaskdialog.cpp b/karm/edittaskdialog.cpp index a556550a9..8c1651546 100644 --- a/karm/edittaskdialog.cpp +++ b/karm/edittaskdialog.cpp @@ -1,7 +1,7 @@ /* * karm * This file only: Copyright (C) 1999 Espen Sand, espensa@online.no - * Modifications (see CVS log) Copyright (C) 2000 Klarälvdalens + * Modifications (see CVS log) Copyright (C) 2000 Klar�lvdalens * Datakonsult AB <kalle@dalheimer.de>, Jesper Pedersen <blackie@kde.org> * * @@ -173,7 +173,7 @@ EditTaskDialog::EditTaskDialog( TQString caption, bool editDlg, { int lines = (int)(desktopCount/2); if (lines*2 != desktopCount) lines++; - groupBox = new TQButtonGroup( lines, TQGroupBox::Horizontal, + groupBox = new TQButtonGroup( lines, Qt::Horizontal, i18n("In Desktop"), page, "_desktopsGB"); } lay1->addWidget(groupBox); diff --git a/karm/idletimedetector.cpp b/karm/idletimedetector.cpp index 46ae03e93..38ae04d7a 100644 --- a/karm/idletimedetector.cpp +++ b/karm/idletimedetector.cpp @@ -72,7 +72,7 @@ void IdleTimeDetector::informOverrun(int idleSeconds) int id = TQMessageBox::warning( 0, i18n("Idle Detection"), i18n("Desktop has been idle since %1." - " What should we do?").arg(idleStartTQString), + " What should we do?").tqarg(idleStartTQString), i18n("Revert && Stop"), i18n("Revert && Continue"), i18n("Continue Timing"),0,2); diff --git a/karm/kaccelmenuwatch.cpp b/karm/kaccelmenuwatch.cpp index 75e4854e7..18a0f5110 100644 --- a/karm/kaccelmenuwatch.cpp +++ b/karm/kaccelmenuwatch.cpp @@ -25,7 +25,7 @@ void KAccelMenuWatch::setMenu( TQPopupMenu *menu ) // we use _menuList to ensure that the signal is // connected only once per menu. - if ( !_menuList.findRef( menu ) ) { + if ( !_menuList.tqfindRef( menu ) ) { _menuList.append( menu ); connect( menu, TQT_SIGNAL(destroyed()), this, TQT_SLOT(removeDeadMenu()) ); } @@ -74,7 +74,7 @@ void KAccelMenuWatch::removeDeadMenu() TQPopupMenu *sdr = (TQPopupMenu *) sender(); assert( sdr ); - if ( !_menuList.findRef( sdr ) ) + if ( !_menuList.tqfindRef( sdr ) ) return; // remove all accels diff --git a/karm/karm_part.cpp b/karm/karm_part.cpp index d8982e2eb..abe8fed61 100644 --- a/karm/karm_part.cpp +++ b/karm/karm_part.cpp @@ -25,7 +25,7 @@ karmPart::karmPart( TQWidget *tqparentWidget, const char *widgetName, TQObject *tqparent, const char *name ) : DCOPObject ( "KarmDCOPIface" ), KParts::ReadWritePart(tqparent, name), _accel ( new KAccel( tqparentWidget ) ), - _watcher ( new KAccelMenuWatch( _accel, tqparentWidget ) ) + _watcher ( new KAccelMenuWatch( _accel, TQT_TQOBJECT(tqparentWidget) ) ) { // we need an instance setInstance( karmPartFactory::instance() ); @@ -117,109 +117,109 @@ void karmPart::makeMenus() (void) KStdAction::print( this, TQT_SLOT( print() ), actionCollection()); actionKeyBindings = KStdAction::keyBindings( this, TQT_SLOT( keyBindings() ), actionCollection() ); - actionPreferences = KStdAction::preferences(_preferences, + actionPreferences = KStdAction::preferences(TQT_TQOBJECT(_preferences), TQT_SLOT(showDialog()), actionCollection() ); (void) KStdAction::save( this, TQT_SLOT( save() ), actionCollection() ); KAction* actionStartNewSession = new KAction( i18n("Start &New Session"), 0, - this, + TQT_TQOBJECT(this), TQT_SLOT( startNewSession() ), actionCollection(), "start_new_session"); KAction* actionResetAll = new KAction( i18n("&Reset All Times"), 0, - this, + TQT_TQOBJECT(this), TQT_SLOT( resetAllTimes() ), actionCollection(), "reset_all_times"); actionStart = new KAction( i18n("&Start"), TQString::tqfromLatin1("1rightarrow"), Key_S, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( startCurrentTimer() ), actionCollection(), "start"); actionStop = new KAction( i18n("S&top"), TQString::tqfromLatin1("stop"), 0, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( stopCurrentTimer() ), actionCollection(), "stop"); actionStopAll = new KAction( i18n("Stop &All Timers"), Key_Escape, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( stopAllTimers() ), actionCollection(), "stopAll"); actionStopAll->setEnabled(false); actionNew = new KAction( i18n("&New..."), TQString::tqfromLatin1("filenew"), CTRL+Key_N, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( newTask() ), actionCollection(), "new_task"); actionNewSub = new KAction( i18n("New &Subtask..."), TQString::tqfromLatin1("kmultiple"), CTRL+ALT+Key_N, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( newSubTask() ), actionCollection(), "new_sub_task"); actionDelete = new KAction( i18n("&Delete"), TQString::tqfromLatin1("editdelete"), Key_Delete, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( deleteTask() ), actionCollection(), "delete_task"); actionEdit = new KAction( i18n("&Edit..."), TQString::tqfromLatin1("edit"), CTRL + Key_E, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( editTask() ), actionCollection(), "edit_task"); // actionAddComment = new KAction( i18n("&Add Comment..."), // TQString::tqfromLatin1("document"), // CTRL+ALT+Key_E, -// _taskView, +// TQT_TQOBJECT(_taskView), // TQT_SLOT( addCommentToTask() ), // actionCollection(), // "add_comment_to_task"); actionMarkAsComplete = new KAction( i18n("&Mark as Complete"), TQString::tqfromLatin1("document"), CTRL+Key_M, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( markTaskAsComplete() ), actionCollection(), "mark_as_complete"); actionMarkAsIncomplete = new KAction( i18n("&Mark as Incomplete"), TQString::tqfromLatin1("document"), CTRL+Key_M, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( markTaskAsIncomplete() ), actionCollection(), "mark_as_incomplete"); actionClipTotals = new KAction( i18n("&Copy Totals to Clipboard"), TQString::tqfromLatin1("klipper"), CTRL+Key_C, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( clipTotals() ), actionCollection(), "clip_totals"); actionClipHistory = new KAction( i18n("Copy &History to Clipboard"), TQString::tqfromLatin1("klipper"), CTRL+ALT+Key_C, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( clipHistory() ), actionCollection(), "clip_history"); new KAction( i18n("Import &Legacy Flat File..."), 0, - _taskView, TQT_SLOT(loadFromFlatFile()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(loadFromFlatFile()), actionCollection(), "import_flatfile"); new KAction( i18n("&Export to CSV File..."), 0, - _taskView, TQT_SLOT(exportcsvFile()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(exportcsvFile()), actionCollection(), "export_csvfile"); new KAction( i18n("Export &History to CSV File..."), 0, - this, TQT_SLOT(exportcsvHistory()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(exportcsvHistory()), actionCollection(), "export_csvhistory"); new KAction( i18n("Import Tasks From &Planner..."), 0, - _taskView, TQT_SLOT(importPlanner()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(importPlanner()), actionCollection(), "import_planner"); new KAction( i18n("Configure KArm..."), 0, - _preferences, TQT_SLOT(showDialog()), actionCollection(), + TQT_TQOBJECT(_preferences), TQT_SLOT(showDialog()), actionCollection(), "configure_karm"); /* @@ -544,10 +544,10 @@ int karmPart::bookTime // Parse datetime if ( !rval ) { - startDate = TQDate::fromString( datetime, TQt::ISODate ); + startDate = TQDate::fromString( datetime, Qt::ISODate ); if ( datetime.length() > 10 ) // "YYYY-MM-DD".length() = 10 { - startTime = TQTime::fromString( datetime, TQt::ISODate ); + startTime = TQTime::fromString( datetime, Qt::ISODate ); } else startTime = TQTime( 12, 0 ); if ( startDate.isValid() && startTime.isValid() ) @@ -576,7 +576,7 @@ int karmPart::bookTime TQString karmPart::getError( int mkb ) const { if ( mkb <= KARM_MAX_ERROR_NO ) return m_error[ mkb ]; - else return i18n( "Invalid error number: %1" ).arg( mkb ); + else return i18n( "Invalid error number: %1" ).tqarg( mkb ); } int karmPart::totalMinutesForTaskId( const TQString& taskId ) diff --git a/karm/karmstorage.cpp b/karm/karmstorage.cpp index 4a7dabc2a..7dc025c23 100644 --- a/karm/karmstorage.cpp +++ b/karm/karmstorage.cpp @@ -199,8 +199,8 @@ TQString KarmStorage::load (TaskView* view, const Preferences* preferences, TQSt // Complete the loading but return a message if ( !newParent ) err = i18n("Error loading \"%1\": could not find tqparent (uid=%2)") - .arg(task->name()) - .arg((*todo)->relatedToUid()); + .tqarg(task->name()) + .tqarg((*todo)->relatedToUid()); if (!err) task->move( newParent); } @@ -268,8 +268,8 @@ TQString KarmStorage::buildTaskView(KCal::ResourceCalendar *rc, TaskView *view) // Complete the loading but return a message if ( !newParent ) err = i18n("Error loading \"%1\": could not find tqparent (uid=%2)") - .arg(task->name()) - .arg((*todo)->relatedToUid()); + .tqarg(task->name()) + .tqarg((*todo)->relatedToUid()); if (!err) task->move( newParent); } @@ -391,12 +391,12 @@ TQString KarmStorage::loadFromFlatFile(TaskView* taskview, TQFile f(filename); if( !f.exists() ) - err = i18n("File \"%1\" not found.").arg(filename); + err = i18n("File \"%1\" not found.").tqarg(filename); if (!err) { if( !f.open( IO_ReadOnly ) ) - err = i18n("Could not open \"%1\".").arg(filename); + err = i18n("Could not open \"%1\".").tqarg(filename); } if (!err) @@ -667,7 +667,7 @@ TQString KarmStorage::exportcsvFile( TaskView *taskview, if (filename.isEmpty()) filename=rc.url.url(); TQFile f( filename ); if( !f.open( IO_WriteOnly ) ) { - err = i18n( "Could not open \"%1\"." ).arg( filename ); + err = i18n( "Could not open \"%1\"." ).tqarg( filename ); } if (!err) { @@ -809,13 +809,13 @@ long KarmStorage::printTaskHistory ( // write the time in seconds for the given task for the given day to s daykey = day.toString(TQString::tqfromLatin1("yyyyMMdd")); daytaskkey = TQString::tqfromLatin1("%1_%2") - .arg(daykey) - .arg(task->uid()); + .tqarg(daykey) + .tqarg(task->uid()); if (taskdaytotals.tqcontains(daytaskkey)) { cell.push_back(TQString::tqfromLatin1("%1") - .arg(formatTime(taskdaytotals[daytaskkey]/60, rc.decimalMinutes))); + .tqarg(formatTime(taskdaytotals[daytaskkey]/60, rc.decimalMinutes))); sum += taskdaytotals[daytaskkey]; // in seconds if (daytotals.tqcontains(daykey)) @@ -829,7 +829,7 @@ long KarmStorage::printTaskHistory ( } // Total for task - cell.push_back(TQString::tqfromLatin1("%1").arg(formatTime(sum/60, rc.decimalMinutes))); + cell.push_back(TQString::tqfromLatin1("%1").tqarg(formatTime(sum/60, rc.decimalMinutes))); // room for the recursive total time (that cannot be calculated now) cell.push_back(delim); @@ -865,7 +865,7 @@ long KarmStorage::printTaskHistory ( add += printTaskHistory( subTask, taskdaytotals, daytotals, from, to , level+1, matrix, rc ); } - cell[colrectot]=(TQString::tqfromLatin1("%1").arg(formatTime((add+sum)/60, rc.decimalMinutes ))); + cell[colrectot]=(TQString::tqfromLatin1("%1").tqarg(formatTime((add+sum)/60, rc.decimalMinutes ))); for (unsigned int i=0; i < cell.size(); i++) matrix[ownline]+=cell[i]; return add+sum; } @@ -917,11 +917,11 @@ TQString KarmStorage::exportcsvHistory ( TaskView *taskview, // header retval += i18n("Task History\n"); retval += i18n("From %1 to %2") - .arg(KGlobal::locale()->formatDate(from)) - .arg(KGlobal::locale()->formatDate(to)); + .tqarg(KGlobal::locale()->formatDate(from)) + .tqarg(KGlobal::locale()->formatDate(to)); retval += cr; retval += i18n("Printed on: %1") - .arg(KGlobal::locale()->formatDateTime(TQDateTime::tqcurrentDateTime())); + .tqarg(KGlobal::locale()->formatDateTime(TQDateTime::tqcurrentDateTime())); retval += cr; day=from; @@ -938,8 +938,8 @@ TQString KarmStorage::exportcsvHistory ( TaskView *taskview, { daykey = (*event).start().date().toString(TQString::tqfromLatin1("yyyyMMdd")); daytaskkey = TQString(TQString::tqfromLatin1("%1_%2")) - .arg(daykey) - .arg((*event).todoUid()); + .tqarg(daykey) + .tqarg((*event).todoUid()); if (taskdaytotals.tqcontains(daytaskkey)) taskdaytotals.tqreplace(daytaskkey, @@ -998,7 +998,7 @@ TQString KarmStorage::exportcsvHistory ( TaskView *taskview, if (daytotals.tqcontains(daykey)) { retval += TQString::tqfromLatin1("%1") - .arg(formatTime(daytotals[daykey]/60, rc.decimalMinutes)); + .tqarg(formatTime(daytotals[daykey]/60, rc.decimalMinutes)); sum += daytotals[daykey]; // in seconds } retval += delim; @@ -1006,9 +1006,9 @@ TQString KarmStorage::exportcsvHistory ( TaskView *taskview, } retval += TQString::tqfromLatin1("%1%2%3%4") - .arg( formatTime( sum/60, rc.decimalMinutes ) ) - .arg( delim ).arg( delim ) - .arg( i18n( "Total" ) ); + .tqarg( formatTime( sum/60, rc.decimalMinutes ) ) + .tqarg( delim ).tqarg( delim ) + .tqarg( i18n( "Total" ) ); } // above taken from timekard.cpp @@ -1021,7 +1021,7 @@ TQString KarmStorage::exportcsvHistory ( TaskView *taskview, if (filename.isEmpty()) filename=rc.url.url(); TQFile f( filename ); if( !f.open( IO_WriteOnly ) ) { - err = i18n( "Could not open \"%1\"." ).arg( filename ); + err = i18n( "Could not open \"%1\"." ).tqarg( filename ); } if (!err) { diff --git a/karm/ktimewidget.cpp b/karm/ktimewidget.cpp index b1f7790f6..e480dea40 100644 --- a/karm/ktimewidget.cpp +++ b/karm/ktimewidget.cpp @@ -17,7 +17,7 @@ class TimeValidator : public TQValidator { public: TimeValidator( ValidatorType tp, TQWidget *tqparent=0, const char *name=0) - : TQValidator(tqparent, name) + : TQValidator(TQT_TQOBJECT(tqparent), name) { _tp = tp; } diff --git a/karm/mainwindow.cpp b/karm/mainwindow.cpp index 2ab850aa6..6d1ce29ea 100644 --- a/karm/mainwindow.cpp +++ b/karm/mainwindow.cpp @@ -38,7 +38,7 @@ MainWindow::MainWindow( const TQString &icsfile ) : DCOPObject ( "KarmDCOPIface" ), KParts::MainWindow(0,TQt::WStyle_ContextHelp), _accel ( new KAccel( this ) ), - _watcher ( new KAccelMenuWatch( _accel, this ) ), + _watcher ( new KAccelMenuWatch( _accel, TQT_TQOBJECT(this) ) ), _totalSum ( 0 ), _sessionSum( 0 ) { @@ -202,10 +202,10 @@ void MainWindow::updateStatusBar( ) TQString time; time = formatTime( _sessionSum ); - statusBar()->changeItem( i18n("Session: %1").arg(time), 0 ); + statusBar()->changeItem( i18n("Session: %1").tqarg(time), 0 ); time = formatTime( _totalSum ); - statusBar()->changeItem( i18n("Total: %1" ).arg(time), 1); + statusBar()->changeItem( i18n("Total: %1" ).tqarg(time), 1); } void MainWindow::starStatusBar() @@ -251,88 +251,88 @@ void MainWindow::makeMenus() *actionNew, *actionNewSub; - (void) KStdAction::quit( this, TQT_SLOT( quit() ), actionCollection()); - (void) KStdAction::print( this, TQT_SLOT( print() ), actionCollection()); - actionKeyBindings = KStdAction::keyBindings( this, TQT_SLOT( keyBindings() ), + (void) KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( quit() ), actionCollection()); + (void) KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT( print() ), actionCollection()); + actionKeyBindings = KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( keyBindings() ), actionCollection() ); - actionPreferences = KStdAction::preferences(_preferences, + actionPreferences = KStdAction::preferences(TQT_TQOBJECT(_preferences), TQT_SLOT(showDialog()), actionCollection() ); - (void) KStdAction::save( this, TQT_SLOT( save() ), actionCollection() ); + (void) KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT( save() ), actionCollection() ); KAction* actionStartNewSession = new KAction( i18n("Start &New Session"), 0, - this, + TQT_TQOBJECT(this), TQT_SLOT( startNewSession() ), actionCollection(), "start_new_session"); KAction* actionResetAll = new KAction( i18n("&Reset All Times"), 0, - this, + TQT_TQOBJECT(this), TQT_SLOT( resetAllTimes() ), actionCollection(), "reset_all_times"); actionStart = new KAction( i18n("&Start"), TQString::tqfromLatin1("1rightarrow"), Key_S, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( startCurrentTimer() ), actionCollection(), "start"); actionStop = new KAction( i18n("S&top"), TQString::tqfromLatin1("stop"), Key_S, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( stopCurrentTimer() ), actionCollection(), "stop"); actionStopAll = new KAction( i18n("Stop &All Timers"), Key_Escape, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( stopAllTimers() ), actionCollection(), "stopAll"); actionStopAll->setEnabled(false); actionNew = new KAction( i18n("&New..."), TQString::tqfromLatin1("filenew"), CTRL+Key_N, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( newTask() ), actionCollection(), "new_task"); actionNewSub = new KAction( i18n("New &Subtask..."), TQString::tqfromLatin1("kmultiple"), CTRL+ALT+Key_N, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( newSubTask() ), actionCollection(), "new_sub_task"); actionDelete = new KAction( i18n("&Delete"), TQString::tqfromLatin1("editdelete"), Key_Delete, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( deleteTask() ), actionCollection(), "delete_task"); actionEdit = new KAction( i18n("&Edit..."), TQString::tqfromLatin1("edit"), CTRL + Key_E, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( editTask() ), actionCollection(), "edit_task"); // actionAddComment = new KAction( i18n("&Add Comment..."), // TQString::tqfromLatin1("document"), // CTRL+ALT+Key_E, -// _taskView, +// TQT_TQOBJECT(_taskView), // TQT_SLOT( addCommentToTask() ), // actionCollection(), // "add_comment_to_task"); actionMarkAsComplete = new KAction( i18n("&Mark as Complete"), TQString::tqfromLatin1("document"), CTRL+Key_M, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( markTaskAsComplete() ), actionCollection(), "mark_as_complete"); actionMarkAsIncomplete = new KAction( i18n("&Mark as Incomplete"), TQString::tqfromLatin1("document"), CTRL+Key_M, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( markTaskAsIncomplete() ), actionCollection(), "mark_as_incomplete"); actionClipTotals = new KAction( i18n("&Copy Totals to Clipboard"), TQString::tqfromLatin1("klipper"), CTRL+Key_C, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( clipTotals() ), actionCollection(), "clip_totals"); @@ -340,29 +340,29 @@ void MainWindow::makeMenus() actionClipTotals = new KAction( i18n("&Copy Session Time to Clipboard"), TQString::tqfromLatin1("klipper"), 0, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( clipSession() ), actionCollection(), "clip_session"); actionClipHistory = new KAction( i18n("Copy &History to Clipboard"), TQString::tqfromLatin1("klipper"), CTRL+ALT+Key_C, - _taskView, + TQT_TQOBJECT(_taskView), TQT_SLOT( clipHistory() ), actionCollection(), "clip_history"); new KAction( i18n("Import &Legacy Flat File..."), 0, - _taskView, TQT_SLOT(loadFromFlatFile()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(loadFromFlatFile()), actionCollection(), "import_flatfile"); new KAction( i18n("&Export to CSV File..."), 0, - _taskView, TQT_SLOT(exportcsvFile()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(exportcsvFile()), actionCollection(), "export_csvfile"); new KAction( i18n("Export &History to CSV File..."), 0, - this, TQT_SLOT(exportcsvHistory()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(exportcsvHistory()), actionCollection(), "export_csvhistory"); new KAction( i18n("Import Tasks From &Planner..."), 0, - _taskView, TQT_SLOT(importPlanner()), actionCollection(), + TQT_TQOBJECT(_taskView), TQT_SLOT(importPlanner()), actionCollection(), "import_planner"); /* @@ -578,10 +578,10 @@ int MainWindow::bookTime // Parse datetime if ( !rval ) { - startDate = TQDate::fromString( datetime, TQt::ISODate ); + startDate = TQDate::fromString( datetime, Qt::ISODate ); if ( datetime.length() > 10 ) // "YYYY-MM-DD".length() = 10 { - startTime = TQTime::fromString( datetime, TQt::ISODate ); + startTime = TQTime::fromString( datetime, Qt::ISODate ); } else startTime = TQTime( 12, 0 ); if ( startDate.isValid() && startTime.isValid() ) @@ -610,7 +610,7 @@ int MainWindow::bookTime TQString MainWindow::getError( int mkb ) const { if ( mkb <= KARM_MAX_ERROR_NO ) return m_error[ mkb ]; - else return i18n( "Invalid error number: %1" ).arg( mkb ); + else return i18n( "Invalid error number: %1" ).tqarg( mkb ); } int MainWindow::totalMinutesForTaskId( const TQString& taskId ) @@ -718,10 +718,10 @@ TQString MainWindow::exportcsvfile( TQString filename, TQString from, TQString t ReportCriteria rc; rc.url=filename; rc.from=TQDate::fromString( from ); - if ( rc.from.isNull() ) rc.from=TQDate::fromString( from, TQt::ISODate ); + if ( rc.from.isNull() ) rc.from=TQDate::fromString( from, Qt::ISODate ); kdDebug(5970) << "rc.from " << rc.from << endl; rc.to=TQDate::fromString( to ); - if ( rc.to.isNull() ) rc.to=TQDate::fromString( to, TQt::ISODate ); + if ( rc.to.isNull() ) rc.to=TQDate::fromString( to, Qt::ISODate ); kdDebug(5970) << "rc.to " << rc.to << endl; rc.reportType=(ReportCriteria::REPORTTYPE) type; // history report or totals report rc.decimalMinutes=decimalMinutes; diff --git a/karm/print.cpp b/karm/print.cpp index 891c06fe2..d045a6658 100644 --- a/karm/print.cpp +++ b/karm/print.cpp @@ -79,7 +79,7 @@ void MyPrinter::print() painter.drawText(xMargin, yoff, pageWidth, height, TQPainter::AlignCenter, - i18n("KArm - %1").arg(now)); + i18n("KArm - %1").tqarg(now)); painter.setFont(origFont); yoff += height + 10; diff --git a/karm/printdialog.cpp b/karm/printdialog.cpp index 6b3ca85b4..b8d05aceb 100644 --- a/karm/printdialog.cpp +++ b/karm/printdialog.cpp @@ -53,7 +53,7 @@ PrintDialog::PrintDialog() tqlayout->addStretch(1); // Date Range - TQGroupBox *rangeGroup = new TQGroupBox(1, Horizontal, i18n("Date Range"), + TQGroupBox *rangeGroup = new TQGroupBox(1, Qt::Horizontal, i18n("Date Range"), page); tqlayout->addWidget(rangeGroup); diff --git a/karm/taskview.cpp b/karm/taskview.cpp index 1ac108e01..6a8f6e051 100644 --- a/karm/taskview.cpp +++ b/karm/taskview.cpp @@ -131,7 +131,7 @@ void TaskView::contentsMousePressEvent ( TQMouseEvent * e ) int leftborder = treeStepSize() * ( task->depth() + ( rootIsDecorated() ? 1 : 0)) + itemMargin(); if ((leftborder < e->x()) && (e->x() < 19 + leftborder )) { - if ( e->button() == LeftButton ) + if ( e->button() == Qt::LeftButton ) if ( task->isComplete() ) task->setPercentComplete( 0, _storage ); else task->setPercentComplete( 100, _storage ); } @@ -154,7 +154,7 @@ void TaskView::contentsMouseDoubleClickEvent ( TQMouseEvent * e ) if ( e->pos().y() >= task->itemPos() && // doubleclick was onto current_item() e->pos().y() < task->itemPos()+task->height() ) { - if ( activeTasks.findRef(task) == -1 ) // task is active + if ( activeTasks.tqfindRef(task) == -1 ) // task is active { stopAllTimers(); startCurrentTimer(); @@ -388,7 +388,7 @@ void TaskView::startTimerFor(Task* task, TQDateTime startTime ) kdDebug(5970) << "Entering TaskView::startTimerFor" << endl; if (save()==TQString()) { - if (task != 0 && activeTasks.findRef(task) == -1) + if (task != 0 && activeTasks.tqfindRef(task) == -1) { _idleTimeDetector->startIdleDetection(); if (!task->isComplete()) @@ -462,7 +462,7 @@ void TaskView::resetTimeForAllTasks() void TaskView::stopTimerFor(Task* task) { kdDebug(5970) << "Entering stopTimerFor. task = " << task->name() << endl; - if ( task != 0 && activeTasks.findRef(task) != -1 ) { + if ( task != 0 && activeTasks.tqfindRef(task) != -1 ) { activeTasks.removeRef(task); task->setRunning(false, _storage); if ( activeTasks.count() == 0 ) { @@ -613,7 +613,7 @@ void TaskView::editTask() // bool ok; // TQString comment = KLineEditDlg::getText(i18n("Comment"), -// i18n("Log comment for task '%1':").arg(task->name()), +// i18n("Log comment for task '%1':").tqarg(task->name()), // TQString(), &ok, this); // if ( ok ) // task->addComment( comment, _storage ); @@ -651,7 +651,7 @@ void TaskView::deleteTask(bool markingascomplete) response = KMessageBox::warningContinueCancel( 0, i18n( "Are you sure you want to delete " "the task named\n\"%1\" and its entire history?") - .arg(task->name()), + .tqarg(task->name()), i18n( "Deleting Task"), KStdGuiItem::del()); } else { @@ -659,7 +659,7 @@ void TaskView::deleteTask(bool markingascomplete) i18n( "Are you sure you want to delete the task named" "\n\"%1\" and its entire history?\n" "NOTE: all its subtasks and their history will also " - "be deleted.").arg(task->name()), + "be deleted.").tqarg(task->name()), i18n( "Deleting Task"), KStdGuiItem::del()); } } @@ -820,16 +820,16 @@ void TaskView::clipTotals() i18n("Copy This Task"), i18n("Copy All Tasks") ); if (response == KMessageBox::Yes) // This task only { - KApplication::clipboard()->setText(t.totalsAsText(this, true, TimeKard::TotalTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, true, TimeKard::TotalTime)); } else // All tasks { - KApplication::clipboard()->setText(t.totalsAsText(this, false, TimeKard::TotalTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, false, TimeKard::TotalTime)); } } else { - KApplication::clipboard()->setText(t.totalsAsText(this, true, TimeKard::TotalTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, true, TimeKard::TotalTime)); } } @@ -844,16 +844,16 @@ void TaskView::clipSession() i18n("Copy This Task"), i18n("Copy All Tasks") ); if (response == KMessageBox::Yes) // this task only { - KApplication::clipboard()->setText(t.totalsAsText(this, true, TimeKard::SessionTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, true, TimeKard::SessionTime)); } else // only task { - KApplication::clipboard()->setText(t.totalsAsText(this, false, TimeKard::SessionTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, false, TimeKard::SessionTime)); } } else { - KApplication::clipboard()->setText(t.totalsAsText(this, true, TimeKard::SessionTime)); + KApplication::tqclipboard()->setText(t.totalsAsText(this, true, TimeKard::SessionTime)); } } @@ -863,7 +863,7 @@ void TaskView::clipHistory() if (dialog.exec()== TQDialog::Accepted) { TimeKard t; - KApplication::clipboard()-> + KApplication::tqclipboard()-> setText( t.historyAsText(this, dialog.from(), dialog.to(), !dialog.allTasks(), dialog.perWeek(), dialog.totalsOnly() ) ); } } diff --git a/karm/timekard.cpp b/karm/timekard.cpp index d7de48402..c50168574 100644 --- a/karm/timekard.cpp +++ b/karm/timekard.cpp @@ -62,8 +62,8 @@ TQString TimeKard::totalsAsText(TaskView* taskview, bool justThisTask, WhichTime retval += KGlobal::locale()->formatDateTime(TQDateTime::tqcurrentDateTime()); retval += cr + cr; retval += TQString(TQString::tqfromLatin1("%1 %2")) - .arg(i18n("Time"), timeWidth) - .arg(i18n("Task")); + .tqarg(i18n("Time"), timeWidth) + .tqarg(i18n("Task")); retval += cr; retval += line; @@ -92,10 +92,10 @@ TQString TimeKard::totalsAsText(TaskView* taskview, bool justThisTask, WhichTime // total buf.fill('-', reportWidth); - retval += TQString(TQString::tqfromLatin1("%1")).arg(buf, timeWidth) + cr; + retval += TQString(TQString::tqfromLatin1("%1")).tqarg(buf, timeWidth) + cr; retval += TQString(TQString::tqfromLatin1("%1 %2")) - .arg(formatTime(sum),timeWidth) - .arg(i18n("Total")); + .tqarg(formatTime(sum),timeWidth) + .tqarg(i18n("Total")); } else retval += i18n("No tasks."); @@ -110,8 +110,8 @@ void TimeKard::printTask(Task *task, TQString &s, int level, WhichTime which) s += buf.fill(' ', level); s += TQString(TQString::tqfromLatin1("%1 %2")) - .arg(formatTime(which == TotalTime?task->totalTime():task->totalSessionTime()), timeWidth) - .arg(task->name()); + .tqarg(formatTime(which == TotalTime?task->totalTime():task->totalSessionTime()), timeWidth) + .tqarg(task->name()); s += cr; for (Task* subTask = task->firstChild(); @@ -136,15 +136,15 @@ void TimeKard::printTaskHistory(const Task *task, { TQString daykey = day.toString(TQString::tqfromLatin1("yyyyMMdd")); TQString daytaskkey = TQString::tqfromLatin1("%1_%2") - .arg(daykey) - .arg(task->uid()); + .tqarg(daykey) + .tqarg(task->uid()); if (taskdaytotals.tqcontains(daytaskkey)) { if ( !totalsOnly ) { s += TQString::tqfromLatin1("%1") - .arg(formatTime(taskdaytotals[daytaskkey]/60), timeWidth); + .tqarg(formatTime(taskdaytotals[daytaskkey]/60), timeWidth); } sectionsum += taskdaytotals[daytaskkey]; // in seconds @@ -162,12 +162,12 @@ void TimeKard::printTaskHistory(const Task *task, } // Total for task this section (e.g. week) - s += TQString::tqfromLatin1("%1").arg(formatTime(sectionsum/60), totalTimeWidth); + s += TQString::tqfromLatin1("%1").tqarg(formatTime(sectionsum/60), totalTimeWidth); // Task name TQString buf; s += buf.fill(' ', level + 1); - s += TQString::tqfromLatin1("%1").arg(task->name()); + s += TQString::tqfromLatin1("%1").tqarg(task->name()); s += cr; for (Task* subTask = task->firstChild(); @@ -223,8 +223,8 @@ TQString TimeKard::sectionHistoryAsText( { TQString daykey = (*event).start().date().toString(TQString::tqfromLatin1("yyyyMMdd")); TQString daytaskkey = TQString::tqfromLatin1("%1_%2") - .arg(daykey) - .arg((*event).todoUid()); + .tqarg(daykey) + .tqarg((*event).todoUid()); if (taskdaytotals.tqcontains(daytaskkey)) taskdaytotals.tqreplace(daytaskkey, @@ -246,7 +246,7 @@ TQString TimeKard::sectionHistoryAsText( // day headings for (TQDate day = sectionFrom; day <= sectionTo; day = day.addDays(1)) { - retval += TQString::tqfromLatin1("%1").arg(day.day(), timeWidth); + retval += TQString::tqfromLatin1("%1").tqarg(day.day(), timeWidth); } retval += cr; retval += line; @@ -287,7 +287,7 @@ TQString TimeKard::sectionHistoryAsText( if ( !totalsOnly ) { retval += TQString::tqfromLatin1("%1") - .arg(formatTime(daytotals[daykey]/60), timeWidth); + .tqarg(formatTime(daytotals[daykey]/60), timeWidth); } sum += daytotals[daykey]; // in seconds } @@ -299,8 +299,8 @@ TQString TimeKard::sectionHistoryAsText( } retval += TQString::tqfromLatin1("%1 %2") - .arg(formatTime(sum/60), totalTimeWidth) - .arg(i18n("Total")); + .tqarg(formatTime(sum/60), totalTimeWidth) + .tqarg(i18n("Total")); } return retval; } @@ -313,11 +313,11 @@ TQString TimeKard::historyAsText(TaskView* taskview, const TQDate& from, retval += totalsOnly ? i18n("Task Totals") : i18n("Task History"); retval += cr; retval += i18n("From %1 to %2") - .arg(KGlobal::locale()->formatDate(from)) - .arg(KGlobal::locale()->formatDate(to)); + .tqarg(KGlobal::locale()->formatDate(from)) + .tqarg(KGlobal::locale()->formatDate(to)); retval += cr; retval += i18n("Printed on: %1") - .arg(KGlobal::locale()->formatDateTime(TQDateTime::tqcurrentDateTime())); + .tqarg(KGlobal::locale()->formatDateTime(TQDateTime::tqcurrentDateTime())); if ( perWeek ) { @@ -353,7 +353,7 @@ TQDate Week::end() const TQString Week::name() const { - return i18n("Week of %1").arg(KGlobal::locale()->formatDate(start())); + return i18n("Week of %1").tqarg(KGlobal::locale()->formatDate(start())); } TQValueList<Week> Week::weeksFromDateRange(const TQDate& from, const TQDate& to) diff --git a/karm/tray.cpp b/karm/tray.cpp index 3758dd7f8..20486b4b7 100644 --- a/karm/tray.cpp +++ b/karm/tray.cpp @@ -59,9 +59,9 @@ KarmTray::KarmTray(MainWindow* tqparent) // this are experiments/tests /* for (int i=0; i<30; i++) - _tray->insertTitle(i 18n("bla ").arg(i)); + _tray->insertTitle(i 18n("bla ").tqarg(i)); for (int i=0; i<30; i++) - _tray->insertTitle2(i 18n("bli ").arg(i)); + _tray->insertTitle2(i 18n("bli ").tqarg(i)); */ // experimenting with menus for the tray /* diff --git a/kdgantt/KDGanttMinimizeSplitter.cpp b/kdgantt/KDGanttMinimizeSplitter.cpp index da6744c89..35c3eb0fb 100644 --- a/kdgantt/KDGanttMinimizeSplitter.cpp +++ b/kdgantt/KDGanttMinimizeSplitter.cpp @@ -3,7 +3,7 @@ */ /**************************************************************************** - ** Copyright (C) 2002-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2002-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -73,7 +73,7 @@ void KDGanttSplitterHandle::setOrientation( Qt::Orientation o ) { orient = o; #ifndef TQT_NO_CURSOR - if ( o == KDGanttMinimizeSplitter::Horizontal ) + if ( o == Qt::Horizontal ) setCursor( splitHCursor ); else setCursor( splitVCursor ); @@ -84,7 +84,7 @@ void KDGanttSplitterHandle::setOrientation( Qt::Orientation o ) void KDGanttSplitterHandle::mouseMoveEvent( TQMouseEvent *e ) { updateCursor( e->pos() ); - if ( !(e->state()&LeftButton) ) + if ( !(e->state()&Qt::LeftButton) ) return; if ( _activeButton != 0) @@ -104,7 +104,7 @@ void KDGanttSplitterHandle::mouseMoveEvent( TQMouseEvent *e ) void KDGanttSplitterHandle::mousePressEvent( TQMouseEvent *e ) { - if ( e->button() == LeftButton ) { + if ( e->button() == Qt::LeftButton ) { _activeButton = onButton( e->pos() ); mouseOffset = s->pick(e->pos()); if ( _activeButton != 0) @@ -119,7 +119,7 @@ void KDGanttSplitterHandle::updateCursor( const TQPoint& p) setCursor( arrowCursor ); } else { - if ( orient == KDGanttMinimizeSplitter::Horizontal ) + if ( orient == Qt::Horizontal ) setCursor( splitHCursor ); else setCursor( splitVCursor ); @@ -158,7 +158,7 @@ void KDGanttSplitterHandle::mouseReleaseEvent( TQMouseEvent *e ) updateCursor( e->pos() ); } else { - if ( !opaque() && e->button() == LeftButton ) { + if ( !opaque() && e->button() == Qt::LeftButton ) { TQCOORD pos = s->pick(tqparentWidget()->mapFromGlobal(e->globalPos())) - mouseOffset; s->setRubberband( -1 ); @@ -241,7 +241,7 @@ void KDGanttSplitterHandle::paintEvent( TQPaintEvent * ) p.setBrush( tqcolorGroup().background() ); p.setPen( tqcolorGroup().foreground() ); p.drawRect( rect() ); - tqparentWidget()->style().drawPrimitive( TQStyle::PE_Panel, &p, rect(), + tqparentWidget()->tqstyle().tqdrawPrimitive( TQStyle::PE_Panel, &p, rect(), tqparentWidget()->tqcolorGroup()); int sw = 8; // Hardcoded, given I didn't use styles anymore, I didn't like to use their size @@ -256,13 +256,13 @@ void KDGanttSplitterHandle::paintEvent( TQPaintEvent * ) for ( TQValueList<TQPointArray>::Iterator it = list.begin(); it != list.end(); ++it ) { if ( index == _activeButton ) { p.save(); - p.translate( tqparentWidget()->style().tqpixelMetric( TQStyle::PM_ButtonShiftHorizontal ), - tqparentWidget()->style().tqpixelMetric( TQStyle::PM_ButtonShiftVertical ) ); - p.drawPolygon( *it, true ); + p.translate( tqparentWidget()->tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftHorizontal ), + tqparentWidget()->tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftVertical ) ); + p.tqdrawPolygon( *it, true ); p.restore(); } else { - p.drawPolygon( *it, true ); + p.tqdrawPolygon( *it, true ); } index++; } @@ -302,7 +302,7 @@ public: bool firstShow; }; -void kdganttGeomCalc( TQMemArray<QLayoutStruct> &chain, int start, int count, int pos, +void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, int pos, int space, int spacer ); #endif // DOXYGEN_SKIP_INTERNAL @@ -384,7 +384,7 @@ static TQSize minSizeHint( const TQWidget* w ) KDGanttMinimizeSplitter::KDGanttMinimizeSplitter( TQWidget *tqparent, const char *name ) :TQFrame(tqparent,name,WPaintUnclipped) { - orient = Horizontal; + orient = Qt::Horizontal; init(); } @@ -412,7 +412,7 @@ KDGanttMinimizeSplitter::~KDGanttMinimizeSplitter() void KDGanttMinimizeSplitter::init() { data = new TQSplitterData; - if ( orient == Horizontal ) + if ( orient == Qt::Horizontal ) tqsetSizePolicy( TQSizePolicy(TQSizePolicy::Expanding,TQSizePolicy::Minimum) ); else tqsetSizePolicy( TQSizePolicy(TQSizePolicy::Minimum,TQSizePolicy::Expanding) ); @@ -424,7 +424,7 @@ void KDGanttMinimizeSplitter::init() \brief the orientation of the splitter By default the orientation is horizontal (the widgets are side by side). - The possible orientations are TQt:Vertical and TQt::Horizontal (the default). + The possible orientations are TQt:Vertical and Qt::Horizontal (the default). */ void KDGanttMinimizeSplitter::setOrientation( Qt::Orientation o ) { @@ -432,7 +432,7 @@ void KDGanttMinimizeSplitter::setOrientation( Qt::Orientation o ) return; orient = o; - if ( orient == Horizontal ) + if ( orient == Qt::Horizontal ) tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Minimum ) ); else tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Expanding ) ); @@ -561,8 +561,8 @@ void KDGanttMinimizeSplitter::setRubberband( int p ) paint.setRasterOp( XorROP ); TQRect r = contentsRect(); const int rBord = 3; //Themable???? - int sw = style().tqpixelMetric(TQStyle::PM_SplitterWidth, this); - if ( orient == Horizontal ) { + int sw = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this); + if ( orient == Qt::Horizontal ) { if ( opaqueOldPos >= 0 ) paint.drawRect( opaqueOldPos + sw/2 - rBord , r.y(), 2*rBord, r.height() ); @@ -601,8 +601,8 @@ bool KDGanttMinimizeSplitter::event( TQEvent *e ) void KDGanttMinimizeSplitter::drawSplitter( TQPainter *p, TQCOORD x, TQCOORD y, TQCOORD w, TQCOORD h ) { - style().drawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), tqcolorGroup(), - (orientation() == TQt::Horizontal ? + tqstyle().tqdrawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), tqcolorGroup(), + (orientation() == Qt::Horizontal ? TQStyle::Style_Horizontal : 0)); } @@ -644,9 +644,9 @@ void KDGanttMinimizeSplitter::moveSplitter( TQCOORD p, int id ) p = adjustPos( p, id ); TQSplitterLayoutStruct *s = data->list.at(id); - int oldP = orient == Horizontal ? s->wid->x() : s->wid->y(); + int oldP = orient == Qt::Horizontal ? s->wid->x() : s->wid->y(); bool upLeft; - if ( TQApplication::reverseLayout() && orient == Horizontal ) { + if ( TQApplication::reverseLayout() && orient == Qt::Horizontal ) { p += s->wid->width(); upLeft = p > oldP; } else @@ -661,8 +661,8 @@ void KDGanttMinimizeSplitter::moveSplitter( TQCOORD p, int id ) void KDGanttMinimizeSplitter::setG( TQWidget *w, int p, int s, bool isSplitter ) { - if ( orient == Horizontal ) { - if ( TQApplication::reverseLayout() && orient == Horizontal && !isSplitter ) + if ( orient == Qt::Horizontal ) { + if ( TQApplication::reverseLayout() && orient == Qt::Horizontal && !isSplitter ) p = contentsRect().width() - p - s; w->setGeometry( p, contentsRect().y(), s, contentsRect().height() ); } else @@ -688,7 +688,7 @@ void KDGanttMinimizeSplitter::moveBefore( int pos, int id, bool upLeft ) } else if ( s->isSplitter ) { int pos1, pos2; int dd = s->sizer; - if( TQApplication::reverseLayout() && orient == Horizontal ) { + if( TQApplication::reverseLayout() && orient == Qt::Horizontal ) { pos1 = pos; pos2 = pos + dd; } else { @@ -704,7 +704,7 @@ void KDGanttMinimizeSplitter::moveBefore( int pos, int id, bool upLeft ) } } else { int dd, newLeft, nextPos; - if( TQApplication::reverseLayout() && orient == Horizontal ) { + if( TQApplication::reverseLayout() && orient == Qt::Horizontal ) { dd = w->tqgeometry().right() - pos; dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize()))); newLeft = pos+1; @@ -741,7 +741,7 @@ void KDGanttMinimizeSplitter::moveAfter( int pos, int id, bool upLeft ) } else if ( s->isSplitter ) { int dd = s->sizer; int pos1, pos2; - if( TQApplication::reverseLayout() && orient == Horizontal ) { + if( TQApplication::reverseLayout() && orient == Qt::Horizontal ) { pos2 = pos - dd; pos1 = pos2 + 1; } else { @@ -758,7 +758,7 @@ void KDGanttMinimizeSplitter::moveAfter( int pos, int id, bool upLeft ) } else { int left = pick( w->pos() ); int right, dd,/* newRight,*/ newLeft, nextPos; - if ( TQApplication::reverseLayout() && orient == Horizontal ) { + if ( TQApplication::reverseLayout() && orient == Qt::Horizontal ) { dd = pos - left + 1; dd = TQMAX( pick(minSize(w)), TQMIN(dd, pick(w->tqmaximumSize()))); newLeft = pos-dd+1; @@ -836,8 +836,8 @@ void KDGanttMinimizeSplitter::getRange( int id, int *min, int *max ) } } TQRect r = contentsRect(); - if ( orient == Horizontal && TQApplication::reverseLayout() ) { - int splitterWidth = style().tqpixelMetric(TQStyle::PM_SplitterWidth, this); + if ( orient == Qt::Horizontal && TQApplication::reverseLayout() ) { + int splitterWidth = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this); if ( min ) *min = pick(r.topRight()) - TQMIN( maxB, pick(r.size())-minA ) - splitterWidth; if ( max ) @@ -873,7 +873,7 @@ void KDGanttMinimizeSplitter::doResize() TQRect r = contentsRect(); int i; int n = data->list.count(); - TQMemArray<QLayoutStruct> a( n ); + TQMemArray<TQLayoutStruct> a( n ); for ( i = 0; i< n; i++ ) { a[i].init(); TQSplitterLayoutStruct *s = data->list.at(i); @@ -975,7 +975,7 @@ void KDGanttMinimizeSplitter::recalc( bool update ) if ( maxt < mint ) maxt = mint; - if ( orient == Horizontal ) { + if ( orient == Qt::Horizontal ) { setMaximumSize( maxl, maxt ); setMinimumSize( minl, mint ); } else { @@ -1110,9 +1110,9 @@ TQSize KDGanttMinimizeSplitter::tqsizeHint() const constPolish(); int l = 0; int t = 0; - if ( tqchildren() ) { - const TQObjectList * c = tqchildren(); - TQObjectListIt it( *c ); + if ( !childrenListObject().isEmpty() ) { + const TQObjectList c = childrenListObject(); + TQObjectListIt it( c ); TQObject * o; while( (o=it.current()) != 0 ) { @@ -1127,7 +1127,7 @@ TQSize KDGanttMinimizeSplitter::tqsizeHint() const } } } - return orientation() == Horizontal ? TQSize( l, t ) : TQSize( t, l ); + return orientation() == Qt::Horizontal ? TQSize( l, t ) : TQSize( t, l ); } @@ -1140,9 +1140,9 @@ TQSize KDGanttMinimizeSplitter::tqminimumSizeHint() const constPolish(); int l = 0; int t = 0; - if ( tqchildren() ) { - const TQObjectList * c = tqchildren(); - TQObjectListIt it( *c ); + if ( !childrenListObject().isEmpty() ) { + const TQObjectList c = childrenListObject(); + TQObjectListIt it( c ); TQObject * o; while( (o=it.current()) != 0 ) { @@ -1157,7 +1157,7 @@ TQSize KDGanttMinimizeSplitter::tqminimumSizeHint() const } } } - return orientation() == Horizontal ? TQSize( l, t ) : TQSize( t, l ); + return orientation() == Qt::Horizontal ? TQSize( l, t ) : TQSize( t, l ); } @@ -1309,7 +1309,7 @@ void KDGanttMinimizeSplitter::processChildEvents() void KDGanttMinimizeSplitter::styleChange( TQStyle& old ) { - int sw = style().tqpixelMetric(TQStyle::PM_SplitterWidth, this); + int sw = tqstyle().tqpixelMetric(TQStyle::PM_SplitterWidth, this); TQSplitterLayoutStruct *s = data->list.first(); while ( s ) { if ( s->isSplitter ) @@ -1348,7 +1348,7 @@ static inline int toFixed( int i ) { return i * 256; } static inline int fRound( int i ) { return ( i % 256 < 128 ) ? i / 256 : 1 + i / 256; } -void kdganttGeomCalc( TQMemArray<QLayoutStruct> &chain, int start, int count, int pos, +void kdganttGeomCalc( TQMemArray<TQLayoutStruct> &chain, int start, int count, int pos, int space, int spacer ) { typedef int fixed; diff --git a/kdgantt/KDGanttMinimizeSplitter.h b/kdgantt/KDGanttMinimizeSplitter.h index 86b5340d1..9137da064 100644 --- a/kdgantt/KDGanttMinimizeSplitter.h +++ b/kdgantt/KDGanttMinimizeSplitter.h @@ -3,7 +3,7 @@ */ /**************************************************************************** - ** Copyright (C) 2001-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2001-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -106,14 +106,14 @@ private: void setG( TQWidget *w, int p, int s, bool isSplitter = FALSE ); TQCOORD pick( const TQPoint &p ) const - { return orient == Horizontal ? p.x() : p.y(); } + { return orient == Qt::Horizontal ? p.x() : p.y(); } TQCOORD pick( const TQSize &s ) const - { return orient == Horizontal ? s.width() : s.height(); } + { return orient == Qt::Horizontal ? s.width() : s.height(); } TQCOORD trans( const TQPoint &p ) const - { return orient == Vertical ? p.x() : p.y(); } + { return orient == Qt::Vertical ? p.x() : p.y(); } TQCOORD trans( const TQSize &s ) const - { return orient == Vertical ? s.width() : s.height(); } + { return orient == Qt::Vertical ? s.width() : s.height(); } TQSplitterData *data; diff --git a/kdgantt/KDGanttSemiSizingControl.cpp b/kdgantt/KDGanttSemiSizingControl.cpp index e6258e907..08c1a004c 100644 --- a/kdgantt/KDGanttSemiSizingControl.cpp +++ b/kdgantt/KDGanttSemiSizingControl.cpp @@ -3,7 +3,7 @@ */ /**************************************************************************** - ** Copyright (C) 2002-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2002-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -65,7 +65,7 @@ KDGanttSemiSizingControl::KDGanttSemiSizingControl( TQWidget* tqparent, const char* name ) : - KDGanttSizingControl( tqparent, name ), _orient( Horizontal ), + KDGanttSizingControl( tqparent, name ), _orient( Qt::Horizontal ), _arrowPos( Before ), _minimizedWidget(0), _maximizedWidget(0) { init(); @@ -262,12 +262,12 @@ void KDGanttSemiSizingControl::setup() delete _tqlayout; TQBoxLayout* butLayout; // _tqlayout will delete me - if ( _orient == Horizontal || isMinimized() ) + if ( _orient == Qt::Horizontal || isMinimized() ) _tqlayout = new TQHBoxLayout( this ); else _tqlayout = new TQVBoxLayout( this ); - if ( _orient == Vertical && !isMinimized() ) + if ( _orient == Qt::Vertical && !isMinimized() ) butLayout = new TQHBoxLayout( _tqlayout ); else butLayout = new TQVBoxLayout( _tqlayout ); @@ -288,7 +288,7 @@ void KDGanttSemiSizingControl::setup() } //------------------------------ Setup the button at the correct possition - if ( _arrowPos == After && _orient == Vertical && !isMinimized() ) { + if ( _arrowPos == After && _orient == Qt::Vertical && !isMinimized() ) { butLayout->addStretch( 1 ); butLayout->addWidget( _but, 0, TQt::AlignLeft ); } @@ -305,7 +305,7 @@ void KDGanttSemiSizingControl::setup() else widget = _maximizedWidget; if( widget ) { - if ( _arrowPos == Before || _orient == Vertical && !isMinimized() ) + if ( _arrowPos == Before || _orient == Qt::Vertical && !isMinimized() ) _tqlayout->addWidget( widget, 1 ); else _tqlayout->insertWidget( 0, widget, 1 ); @@ -318,20 +318,20 @@ void KDGanttSemiSizingControl::setup() if ( isMinimized() ) { widget = _minimizedWidget; if( widget ) { - if ( _arrowPos == Before || _orient == Vertical && !isMinimized() ) + if ( _arrowPos == Before || _orient == Qt::Vertical && !isMinimized() ) _tqlayout->addWidget( widget, 1 ); else _tqlayout->insertWidget( 0, widget, 1 ); } } else { - if ( _arrowPos == Before || _orient == Vertical && !isMinimized() ) + if ( _arrowPos == Before || _orient == Qt::Vertical && !isMinimized() ) _tqlayout->addStretch( 1 ); else _tqlayout->insertStretch( 0, 1 ); widget = _maximizedWidget; // the following is only the special case - // arrowPos == Before and _orient == Vertical + // arrowPos == Before and _orient == Qt::Vertical //widget->move( 0+x(), _but->height()+y()); } } diff --git a/kdgantt/KDGanttView.cpp b/kdgantt/KDGanttView.cpp index f7eeeacd7..1c2667b37 100644 --- a/kdgantt/KDGanttView.cpp +++ b/kdgantt/KDGanttView.cpp @@ -81,7 +81,7 @@ */ KDGanttView::KDGanttView( TQWidget* tqparent, const char* name ) - : KDGanttMinimizeSplitter( TQt::Vertical, tqparent, name ), + : KDGanttMinimizeSplitter( Qt::Vertical, tqparent, name ), myCanvasView(0), myTimeHeaderScroll(0), mFixedHorizon( false ) @@ -458,11 +458,11 @@ void KDGanttView::slotmouseButtonClicked ( int button, TQListViewItem * item, //emit mouseButtonClicked ( button , gItem, pos, c ); { switch ( button ) { - case LeftButton: + case Qt::LeftButton: emit lvItemLeftClicked( gItem ); emit itemLeftClicked( gItem ); break; - case MidButton: + case Qt::MidButton: emit lvItemMidClicked( gItem ); emit itemMidClicked( gItem ); break; diff --git a/kdgantt/KDGanttViewItem.cpp b/kdgantt/KDGanttViewItem.cpp index eff5c26e8..9c9c1e98b 100644 --- a/kdgantt/KDGanttViewItem.cpp +++ b/kdgantt/KDGanttViewItem.cpp @@ -916,10 +916,10 @@ void KDGanttViewItem::createShape( KDCanvasPolygonItem* &itemShape, // items which don't have any tqshapes return; } - item->setBrush(TQt::SolidPattern); + item->setBrush(Qt::SolidPattern); item->setZ(5); itemShape = (KDCanvasPolygonItem*) item; - itemBack->setBrush(TQt::SolidPattern); + itemBack->setBrush(Qt::SolidPattern); itemBack->setZ(3); itemShapeBack = (KDCanvasPolygonItem*) itemBack; @@ -1306,11 +1306,11 @@ void KDGanttViewItem::updateCanvasItems() if (blockUpdating) return; TQPen p,pBack; TQBrush b; - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); if ( enabled() ) { textCanvas->setColor(myTextColor); if (isHighlighted) { - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); b.setColor(myStartColorHL); startShape->setBrush(b); b.setColor(myMiddleColorHL); @@ -1323,7 +1323,7 @@ void KDGanttViewItem::updateCanvasItems() p.setColor(myEndColorHL); endLine->setPen(p); } else { - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); b.setColor(myStartColor); // qDebug("update color %s %s", listViewText().latin1(),myStartColor.name().latin1() ); startShape->setBrush(b); @@ -1341,7 +1341,7 @@ void KDGanttViewItem::updateCanvasItems() //TQColor discol = TQt::lightGray; TQColor discol = TQColor(232,232,232); textCanvas->setColor( TQColor(150,150,150) ); - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); b.setColor(discol); startShape->setBrush(b); midShape->setBrush(b); diff --git a/kdgantt/KDGanttViewSubwidgets.cpp b/kdgantt/KDGanttViewSubwidgets.cpp index 197ba18ba..88591e887 100644 --- a/kdgantt/KDGanttViewSubwidgets.cpp +++ b/kdgantt/KDGanttViewSubwidgets.cpp @@ -59,13 +59,13 @@ #include <kdebug.h> KDTimeTableWidget:: KDTimeTableWidget( TQWidget* tqparent,KDGanttView* myGantt) - : TQCanvas (tqparent) + : TQCanvas (TQT_TQOBJECT(tqparent)) { myGanttView = myGantt; taskLinksVisible = true; flag_blockUpdating = false; int_blockUpdating = 0; - gridPen.setStyle(TQt::DotLine); + gridPen.setStyle(Qt::DotLine); gridPen.setColor(TQColor(100,100,100)); maximumComputedGridHeight = 0; denseLineCount = 0; @@ -229,8 +229,8 @@ void KDTimeTableWidget::computeVerticalGrid() itcol.current()->setPoints(i+(cw/2),0,i+(cw/2),h); */ - itcol.current()->setPen( TQPen::NoPen ); - itcol.current()->setBrush( TQBrush( colcol, SolidPattern) ); + itcol.current()->setPen( TQPen(TQPen::NoPen) ); + itcol.current()->setBrush( TQBrush( colcol, Qt::SolidPattern) ); itcol.current()->setSize(cw ,h ); itcol.current()->move( i, 0 ); itcol.current()->show(); @@ -243,8 +243,8 @@ void KDTimeTableWidget::computeVerticalGrid() templine->setPoints(i+(cw/2),0,i+(cw/2),h); */ temprect = new KDCanvasRectangle(this,0,Type_is_KDGanttGridItem); - temprect->setPen( TQPen::NoPen ); - temprect->setBrush( TQBrush( colcol, SolidPattern) ); + temprect->setPen( TQPen(TQPen::NoPen) ); + temprect->setBrush( TQBrush( colcol, Qt::SolidPattern) ); temprect->setSize(cw ,h ); temprect->move( i, 0 ); temprect->setZ(-20); @@ -275,16 +275,16 @@ void KDTimeTableWidget::computeVerticalGrid() itcol.current()->setPen(colPen); itcol.current()->setPoints(i+(cw/2),0,i+(cw/2),h); */ - itcol.current()->setPen( TQPen::NoPen ); - itcol.current()->setBrush( TQBrush( colcol, SolidPattern) ); + itcol.current()->setPen( TQPen(TQPen::NoPen) ); + itcol.current()->setBrush( TQBrush( colcol, Qt::SolidPattern) ); itcol.current()->setSize(cw ,h ); itcol.current()->move( i, 0 ); itcol.current()->show(); ++itcol; } else { temprect = new KDCanvasRectangle(this,0,Type_is_KDGanttGridItem); - temprect->setPen( TQPen::NoPen ); - temprect->setBrush( TQBrush( colcol, SolidPattern) ); + temprect->setPen( TQPen(TQPen::NoPen) ); + temprect->setBrush( TQBrush( colcol, Qt::SolidPattern) ); temprect->setSize(cw ,h ); temprect->move( i, 0 ); temprect->setZ(-20); @@ -331,16 +331,16 @@ void KDTimeTableWidget::computeVerticalGrid() itcol.current()->setPen(colPen); itcol.current()->setPoints(i+mid,0,mid,h); */ - itcol.current()->setPen( TQPen::NoPen ); - itcol.current()->setBrush( TQBrush( colcol, SolidPattern) ); + itcol.current()->setPen( TQPen(TQPen::NoPen) ); + itcol.current()->setBrush( TQBrush( colcol, Qt::SolidPattern) ); itcol.current()->setSize(mid ,h ); itcol.current()->move( left, 0 ); itcol.current()->show(); ++itcol; } else { temprect = new KDCanvasRectangle(this,0,Type_is_KDGanttGridItem); - temprect->setPen( TQPen::NoPen ); - temprect->setBrush( TQBrush( colcol, SolidPattern) ); + temprect->setPen( TQPen(TQPen::NoPen) ); + temprect->setBrush( TQBrush( colcol, Qt::SolidPattern) ); temprect->setSize(mid,h ); temprect->move( left, 0 ); temprect->setZ(-20); @@ -385,16 +385,16 @@ void KDTimeTableWidget::computeVerticalGrid() itcol.current()->setPen(colPen); itcol.current()->setPoints(i+mid,0,mid,h); */ - itcol.current()->setPen( TQPen::NoPen ); - itcol.current()->setBrush( TQBrush( colcol, SolidPattern) ); + itcol.current()->setPen( TQPen(TQPen::NoPen) ); + itcol.current()->setBrush( TQBrush( colcol, Qt::SolidPattern) ); itcol.current()->setSize(mid ,h ); itcol.current()->move( left, 0 ); itcol.current()->show(); ++itcol; } else { temprect = new KDCanvasRectangle(this,0,Type_is_KDGanttGridItem); - temprect->setPen( TQPen::NoPen ); - temprect->setBrush( TQBrush( colcol, SolidPattern) ); + temprect->setPen( TQPen(TQPen::NoPen) ); + temprect->setBrush( TQBrush( colcol, Qt::SolidPattern) ); temprect->setSize(mid ,h ); temprect->move( left, 0 ); temprect->setZ(-20); @@ -792,7 +792,7 @@ void KDTimeHeaderWidget::preparePopupMenu() if (flagZoomToFit) myPopupMenu->changeItem( 1, i18n("Zoom (Fit)")); else - myPopupMenu->changeItem( 1, i18n("Zoom (%1)").arg( TQString::number( zoomFactor(), 'f',3) ) ); + myPopupMenu->changeItem( 1, i18n("Zoom (%1)").tqarg( TQString::number( zoomFactor(), 'f',3) ) ); int i = 0; int id; while ( ( id = scalePopupMenu->idAt( i++ )) >= 0 ) { @@ -2447,16 +2447,16 @@ void KDTimeHeaderWidget::mousePressEvent ( TQMouseEvent * e ) { mouseDown = false; switch ( e->button() ) { - case LeftButton: + case Qt::LeftButton: mouseDown = true; beginMouseDown = e->pos().x(); endMouseDown = e->pos().x(); break; - case RightButton: + case Qt::RightButton: if (flagShowPopupMenu) myPopupMenu->popup(e->globalPos()); break; - case MidButton: + case Qt::MidButton: break; default: break; @@ -2539,7 +2539,7 @@ void KDTimeHeaderWidget::mouseMoveEvent ( TQMouseEvent * e ) ***************************************************************** */ KDLegendWidget:: KDLegendWidget( TQWidget* tqparent, KDGanttMinimizeSplitter* legendParent ) : - KDGanttSemiSizingControl ( KDGanttSemiSizingControl::Before, Vertical, + KDGanttSemiSizingControl ( KDGanttSemiSizingControl::Before, Qt::Vertical, tqparent) { myLegendParent = legendParent; @@ -2645,9 +2645,9 @@ void KDLegendWidget::clearLegend ( ) { if ( myLegend ) delete myLegend; if ( dock ) - myLegend = new TQGroupBox( 1, TQt::Horizontal, scroll->viewport() ); + myLegend = new TQGroupBox( 1, Qt::Horizontal, scroll->viewport() ); else - myLegend = new TQGroupBox( 1, TQt::Horizontal, i18n( "Legend" ), scroll->viewport() ); + myLegend = new TQGroupBox( 1, Qt::Horizontal, i18n( "Legend" ), scroll->viewport() ); myLegend->setBackgroundColor( TQt::white ); myLegend->setFont( font() ); scroll->addChild( myLegend ); @@ -2884,7 +2884,7 @@ void KDListView::drawAllContents(TQPainter * p, int cx, int cy, int cw, int ch) c = fc; // draw to last interesting column - const TQColorGroup &cg = ( palette().inactive() ); + const TQColorGroup &cg = ( tqpalette().inactive() ); while ( c < lc && !drawables.isEmpty() ) { int i = header()->mapToLogical( c ); @@ -3516,7 +3516,7 @@ void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e ) currentItem = 0; movingItem = 0; mouseDown = true; - if (e->button() == RightButton && mySignalSender->editable()) { + if (e->button() == Qt::RightButton && mySignalSender->editable()) { lastClickedItem = (KDGanttViewItem*) mySignalSender->myListView->itemAt( TQPoint(2,e->pos().y())); if ( lastClickedItem ) { if ( lastClickedItem->displaySubitemsAsGroup() && ! lastClickedItem->isOpen() ) { @@ -3537,7 +3537,7 @@ void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e ) TQCanvasItemList::Iterator it; for ( it = il.begin(); it != il.end(); ++it ) { switch ( e->button() ) { - case LeftButton: + case Qt::LeftButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: currentItem = getItem(*it); @@ -3590,7 +3590,7 @@ void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e ) break; } break; - case RightButton: + case Qt::RightButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: currentItem = getItem(*it); @@ -3602,7 +3602,7 @@ void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e ) break; } break; - case MidButton: + case Qt::MidButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: currentItem = getItem(*it); @@ -3618,10 +3618,10 @@ void KDGanttCanvasView::contentsMousePressEvent ( TQMouseEvent * e ) break; } } - if (e->button() == RightButton ) { + if (e->button() == Qt::RightButton ) { mySignalSender->gvContextMenuRequested( currentItem, e->globalPos() ); } - if (autoScrollEnabled && e->button() == LeftButton) { + if (autoScrollEnabled && e->button() == Qt::LeftButton) { myScrollTimer->start(50); } } @@ -3643,7 +3643,7 @@ void KDGanttCanvasView::contentsMouseReleaseEvent ( TQMouseEvent * e ) // if ( currentLink || currentItem ) { switch ( e->button() ) { - case LeftButton: + case Qt::LeftButton: myScrollTimer->stop(); { mySignalSender->itemLeftClicked( currentItem ); @@ -3675,7 +3675,7 @@ void KDGanttCanvasView::contentsMouseReleaseEvent ( TQMouseEvent * e ) movingGVItem = 0; } break; - case RightButton: + case Qt::RightButton: { mySignalSender->itemRightClicked( currentItem ); mySignalSender->gvItemRightClicked( currentItem ); @@ -3684,7 +3684,7 @@ void KDGanttCanvasView::contentsMouseReleaseEvent ( TQMouseEvent * e ) if ( currentLink ) mySignalSender->taskLinkRightClicked( currentLink ); break; - case MidButton: + case Qt::MidButton: { mySignalSender->itemMidClicked( currentItem ); mySignalSender->gvItemMidClicked( currentItem ); @@ -3713,7 +3713,7 @@ void KDGanttCanvasView::contentsMouseDoubleClickEvent ( TQMouseEvent * e ) { TQCanvasItemList il = canvas() ->collisions ( e->pos() ); - if ( il.isEmpty() && e->button() == LeftButton ) { + if ( il.isEmpty() && e->button() == Qt::LeftButton ) { //not directly sending a signal here (encapsulation and whatnot) mySignalSender->emptySpaceDoubleClicked(e); return; @@ -3722,7 +3722,7 @@ void KDGanttCanvasView::contentsMouseDoubleClickEvent ( TQMouseEvent * e ) TQCanvasItemList::Iterator it; for ( it = il.begin(); it != il.end(); ++it ) { switch ( e->button() ) { - case LeftButton: + case Qt::LeftButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: if ( getItem(*it)->enabled() ) @@ -3739,7 +3739,7 @@ void KDGanttCanvasView::contentsMouseDoubleClickEvent ( TQMouseEvent * e ) } break; /* - case RightButton: + case Qt::RightButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: mySignalSender->itemRightClicked(getItem(*it)); @@ -3751,7 +3751,7 @@ void KDGanttCanvasView::contentsMouseDoubleClickEvent ( TQMouseEvent * e ) break; } break; - case MidButton: + case Qt::MidButton: switch (getType(*it)) { case Type_is_KDGanttViewItem: mySignalSender->itemMidClicked(getItem(*it)); @@ -4024,8 +4024,8 @@ void KDIntervalColorRectangle::tqlayout( KDTimeHeaderWidget* timeHeader, int hei int right = timeHeader->getCoordX(mEnd); if ( right == left ) ++right; - setPen( TQPen::NoPen ); - setBrush( TQBrush(mColor, SolidPattern) ); + setPen( TQPen(TQPen::NoPen) ); + setBrush( TQBrush(mColor, Qt::SolidPattern) ); setSize( right - left, height ); move( left, 0 ); show(); diff --git a/kdgantt/KDGanttViewTaskLink.cpp b/kdgantt/KDGanttViewTaskLink.cpp index 4d21073e7..d0aa9bd00 100644 --- a/kdgantt/KDGanttViewTaskLink.cpp +++ b/kdgantt/KDGanttViewTaskLink.cpp @@ -3,7 +3,7 @@ KDGantt - a multi-platform charting engine */ /**************************************************************************** - ** Copyright (C) 2002-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2002-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -268,7 +268,7 @@ void KDGanttViewTaskLink::showMe( bool visible ) TQPen p; TQBrush b; p.setWidth(wid); - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); if (ishighlighted) { b.setColor(myColorHL); p.setColor(myColorHL); @@ -333,7 +333,7 @@ void KDGanttViewTaskLink::showMeType( bool visible ) TQPen p; TQBrush b; p.setWidth(wid); - b.setStyle(TQt::SolidPattern); + b.setStyle(Qt::SolidPattern); if (ishighlighted) { b.setColor(myColorHL); p.setColor(myColorHL); diff --git a/kdgantt/KDGanttXMLTools.cpp b/kdgantt/KDGanttXMLTools.cpp index 248829d3e..e6246138c 100644 --- a/kdgantt/KDGanttXMLTools.cpp +++ b/kdgantt/KDGanttXMLTools.cpp @@ -4,7 +4,7 @@ */ /**************************************************************************** - ** Copyright (C) 2002-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2002-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -266,20 +266,20 @@ void createTimeNode( TQDomDocument& doc, TQDomNode& tqparent, } -TQString penStyleToString( TQt::PenStyle style ) +TQString penStyleToString( Qt::PenStyle style ) { switch( style ) { - case TQt::NoPen: + case Qt::NoPen: return "NoPen"; - case TQt::SolidLine: + case Qt::SolidLine: return "SolidLine"; - case TQt::DashLine: + case Qt::DashLine: return "DashLine"; - case TQt::DotLine: + case Qt::DotLine: return "DotLine"; - case TQt::DashDotLine: + case Qt::DashDotLine: return "DashDotLine"; - case TQt::DashDotDotLine: + case Qt::DashDotDotLine: return "DashDotDotLine"; default: // should not happen return "SolidLine"; @@ -288,39 +288,39 @@ TQString penStyleToString( TQt::PenStyle style ) -TQString brushStyleToString( TQt::BrushStyle style ) +TQString brushStyleToString( Qt::BrushStyle style ) { // PENDING(kalle) Support custom patterns switch( style ) { - case TQt::NoBrush: + case Qt::NoBrush: return "NoBrush"; - case TQt::SolidPattern: + case Qt::SolidPattern: return "SolidPattern"; - case TQt::Dense1Pattern: + case Qt::Dense1Pattern: return "Dense1Pattern"; - case TQt::Dense2Pattern: + case Qt::Dense2Pattern: return "Dense2Pattern"; - case TQt::Dense3Pattern: + case Qt::Dense3Pattern: return "Dense3Pattern"; - case TQt::Dense4Pattern: + case Qt::Dense4Pattern: return "Dense4Pattern"; - case TQt::Dense5Pattern: + case Qt::Dense5Pattern: return "Dense5Pattern"; - case TQt::Dense6Pattern: + case Qt::Dense6Pattern: return "Dense6Pattern"; - case TQt::Dense7Pattern: + case Qt::Dense7Pattern: return "Dense7Pattern"; - case TQt::HorPattern: + case Qt::HorPattern: return "HorPattern"; - case TQt::VerPattern: + case Qt::VerPattern: return "VerPattern"; - case TQt::CrossPattern: + case Qt::CrossPattern: return "CrossPattern"; - case TQt::BDiagPattern: + case Qt::BDiagPattern: return "BDiagPattern"; - case TQt::FDiagPattern: + case Qt::FDiagPattern: return "FDiagPattern"; - case TQt::DiagCrossPattern: + case Qt::DiagCrossPattern: return "DiagCrossPattern"; default: // should not happen (but can for a custom pattern) return "SolidPattern"; @@ -399,7 +399,7 @@ bool readBrushNode( const TQDomElement& element, TQBrush& brush ) { bool ok = true; TQColor tempColor; - TQt::BrushStyle tempStyle; + Qt::BrushStyle tempStyle; TQPixmap tempPixmap; TQDomNode node = element.firstChild(); while( !node.isNull() ) { @@ -506,7 +506,7 @@ bool readPenNode( const TQDomElement& element, TQPen& pen ) bool ok = true; int tempWidth; TQColor tempColor; - TQt::PenStyle tempStyle; + Qt::PenStyle tempStyle; TQDomNode node = element.firstChild(); while( !node.isNull() ) { TQDomElement element = node.toElement(); @@ -705,60 +705,60 @@ bool readTimeNode( const TQDomElement& element, TQTime& value ) -TQt::PenStyle stringToPenStyle( const TQString& style ) +Qt::PenStyle stringToPenStyle( const TQString& style ) { if( style == "NoPen" ) - return TQt::NoPen; + return Qt::NoPen; else if( style == "SolidLine" ) - return TQt::SolidLine; + return Qt::SolidLine; else if( style == "DashLine" ) - return TQt::DashLine; + return Qt::DashLine; else if( style == "DotLine" ) - return TQt::DotLine; + return Qt::DotLine; else if( style == "DashDotLine" ) - return TQt::DashDotLine; + return Qt::DashDotLine; else if( style == "DashDotDotLine" ) - return TQt::DashDotDotLine; + return Qt::DashDotDotLine; else // should not happen - return TQt::SolidLine; + return Qt::SolidLine; } -TQt::BrushStyle stringToBrushStyle( const TQString& style ) +Qt::BrushStyle stringToBrushStyle( const TQString& style ) { // PENDING(kalle) Support custom patterns if( style == "NoBrush" ) - return TQt::NoBrush; + return Qt::NoBrush; else if( style == "SolidPattern" ) - return TQt::SolidPattern; + return Qt::SolidPattern; else if( style == "Dense1Pattern" ) - return TQt::Dense1Pattern; + return Qt::Dense1Pattern; else if( style == "Dense2Pattern" ) - return TQt::Dense2Pattern; + return Qt::Dense2Pattern; else if( style == "Dense3Pattern" ) - return TQt::Dense3Pattern; + return Qt::Dense3Pattern; else if( style == "Dense4Pattern" ) - return TQt::Dense4Pattern; + return Qt::Dense4Pattern; else if( style == "Dense5Pattern" ) - return TQt::Dense5Pattern; + return Qt::Dense5Pattern; else if( style == "Dense6Pattern" ) - return TQt::Dense6Pattern; + return Qt::Dense6Pattern; else if( style == "Dense7Pattern" ) - return TQt::Dense7Pattern; + return Qt::Dense7Pattern; else if( style == "HorPattern" ) - return TQt::HorPattern; + return Qt::HorPattern; else if( style == "VerPattern" ) - return TQt::VerPattern; + return Qt::VerPattern; else if( style == "CrossPattern" ) - return TQt::CrossPattern; + return Qt::CrossPattern; else if( style == "BDiagPattern" ) - return TQt::BDiagPattern; + return Qt::BDiagPattern; else if( style == "FDiagPattern" ) - return TQt::FDiagPattern; + return Qt::FDiagPattern; else if( style == "DiagCrossPattern" ) - return TQt::DiagCrossPattern; + return Qt::DiagCrossPattern; else // should not happen (but can with custom patterns) - return TQt::SolidPattern; + return Qt::SolidPattern; } } diff --git a/kdgantt/KDGanttXMLTools.h b/kdgantt/KDGanttXMLTools.h index 4d316f8b4..8ea81f464 100644 --- a/kdgantt/KDGanttXMLTools.h +++ b/kdgantt/KDGanttXMLTools.h @@ -4,7 +4,7 @@ */ /**************************************************************************** - ** Copyright (C) 2002-2004 Klarälvdalens Datakonsult AB. All rights reserved. + ** Copyright (C) 2002-2004 Klar�lvdalens Datakonsult AB. All rights reserved. ** ** This file is part of the KDGantt library. ** @@ -45,10 +45,10 @@ #include <tqdatetime.h> namespace KDGanttXML { - TQString penStyleToString( TQt::PenStyle style ); - TQt::PenStyle stringToPenStyle( const TQString& style ); - TQString brushStyleToString( TQt::BrushStyle style ); - TQt::BrushStyle stringToBrushStyle( const TQString& style ); + TQString penStyleToString( Qt::PenStyle style ); + Qt::PenStyle stringToPenStyle( const TQString& style ); + TQString brushStyleToString( Qt::BrushStyle style ); + Qt::BrushStyle stringToBrushStyle( const TQString& style ); void createBoolNode( TQDomDocument& doc, TQDomNode& tqparent, const TQString& elementName, bool value ); diff --git a/kfile-plugins/vcf/kfile_vcf.cpp b/kfile-plugins/vcf/kfile_vcf.cpp index 84b29696e..6edc1655e 100644 --- a/kfile-plugins/vcf/kfile_vcf.cpp +++ b/kfile-plugins/vcf/kfile_vcf.cpp @@ -58,7 +58,7 @@ bool KVcfPlugin::readInfo( KFileMetaInfo& info, uint /*what*/ ) if (!file.open(IO_ReadOnly)) { - kdDebug(7034) << "Couldn't open " << TQFile::encodeName(info.path()) << endl; + kdDebug(7034) << "Couldn't open " << TQString(TQFile::encodeName(info.path())) << endl; return false; } diff --git a/kgantt/kgantt/KGanttItem.cpp b/kgantt/kgantt/KGanttItem.cpp index 7939d49ca..35af0c7a0 100644 --- a/kgantt/kgantt/KGanttItem.cpp +++ b/kgantt/kgantt/KGanttItem.cpp @@ -90,7 +90,7 @@ KGanttRelation* KGanttItem::addRelation(KGanttItem* from, KGanttItem* to, const TQString& text) { - if(_subitems.containsRef(from) > 0 && _subitems.containsRef(to) >0) { + if(_subitems.tqcontainsRef(from) > 0 && _subitems.tqcontainsRef(to) >0) { KGanttRelation* rel = new KGanttRelation(from,to,text); _relations.append(rel); diff --git a/kgantt/kgantt/xQGanttBarView.cpp b/kgantt/kgantt/xQGanttBarView.cpp index dc9314996..f85fea6b4 100644 --- a/kgantt/kgantt/xQGanttBarView.cpp +++ b/kgantt/kgantt/xQGanttBarView.cpp @@ -100,7 +100,7 @@ xQGanttBarView::drawHeader() TQDate t = startDate.addDays(-startDate.dayOfWeek()+1); - tmp = _toplevelitem->getStart().secsTo(t)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(t))/60; a = _viewport->screenX(tmp) - contentsX(); p.fillRect(a, top, (int) (5. * dayWidth), height, TQBrush(TQColor(240,240,240))); @@ -110,7 +110,7 @@ xQGanttBarView::drawHeader() t = startDate.addDays(-startDate.day()+1); - tmp = _toplevelitem->getStart().secsTo(t)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(t))/60; a = _viewport->screenX(tmp) - contentsX(); e = t.daysInMonth(); @@ -124,7 +124,7 @@ xQGanttBarView::drawHeader() // draw snapgrid for first month - tmp = _toplevelitem->getStart().secsTo(startDate)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(startDate))/60; a = _viewport->screenX(tmp) - contentsX()+1; double dx = (double) ((_viewport->screenX(_viewport->_snapgrid*1000) - _viewport->screenX(0))/1000.); @@ -143,7 +143,7 @@ xQGanttBarView::drawHeader() for(int i=0; i<end; i++, t = t.addDays(1) ) { - tmp = _toplevelitem->getStart().secsTo(t)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(t))/60; a = _viewport->screenX(tmp) - contentsX(); p.setPen( TQPen(TQColor(black)) ); diff --git a/kgantt/kgantt/xQGanttBarViewPort.cpp b/kgantt/kgantt/xQGanttBarViewPort.cpp index c1dc60d6e..005ca5966 100644 --- a/kgantt/kgantt/xQGanttBarViewPort.cpp +++ b/kgantt/kgantt/xQGanttBarViewPort.cpp @@ -88,7 +88,7 @@ xQGanttBarViewPort::xQGanttBarViewPort(KGanttItem* toplevelitem, recalc(); adjustSize(); - setFocusPolicy(TQWidget::StrongFocus); + setFocusPolicy(Qt::StrongFocus); _mode = Init; } @@ -117,7 +117,7 @@ xQGanttBarViewPort::toolbar(TQMainWindow* mw) _toolbar->insertButton("ganttSelect.png", 0, TQT_SIGNAL(clicked()), - this, TQT_SLOT(setSelect()), + TQT_TQOBJECT(this), TQT_SLOT(setSelect()), true, i18n("Select") ); KPopupMenu *selectMenu = new KPopupMenu(_toolbar); @@ -128,7 +128,7 @@ xQGanttBarViewPort::toolbar(TQMainWindow* mw) */ TQPixmap pix = _iconloader->loadIcon("ganttSelecttask.png", KIcon::Toolbar , 16 ); if(pix.isNull()) printf("ganttSelecttask.png not found !\n"); - selectMenu->insertItem(pix, i18n("Select All"), this, TQT_SLOT(selectAll()) ); + selectMenu->insertItem(pix, i18n("Select All"), TQT_TQOBJECT(this), TQT_SLOT(selectAll()) ); /* @@ -136,7 +136,7 @@ xQGanttBarViewPort::toolbar(TQMainWindow* mw) */ pix = _iconloader->loadIcon("ganttUnselecttask", KIcon::Toolbar , 16 ); if(pix.isNull()) printf("ganttUnselecttask.png not found !\n"); - selectMenu->insertItem(pix, i18n("Unselect All"), this, TQT_SLOT(unselectAll()) ); + selectMenu->insertItem(pix, i18n("Unselect All"), TQT_TQOBJECT(this), TQT_SLOT(unselectAll()) ); KToolBarButton* b = _toolbar->getButton(0); @@ -145,30 +145,30 @@ xQGanttBarViewPort::toolbar(TQMainWindow* mw) _toolbar->insertButton("viewmag.png", 1, TQT_SIGNAL(clicked()), - this, TQT_SLOT(setZoom()), + TQT_TQOBJECT(this), TQT_SLOT(setZoom()), true, i18n("Zoom") ); KPopupMenu* zoomMenu = new KPopupMenu(_toolbar); pix = _iconloader->loadIcon("viewmag.png", KIcon::Toolbar , 16 ); if(pix.isNull()) printf("viewmag.png not found !\n"); - zoomMenu->insertItem(pix, i18n("Zoom All"), this, TQT_SLOT(zoomAll()) ); + zoomMenu->insertItem(pix, i18n("Zoom All"), TQT_TQOBJECT(this), TQT_SLOT(zoomAll()) ); zoomMenu->insertSeparator(); pix = _iconloader->loadIcon("viewmag+.png", KIcon::Toolbar , 16 ); if(pix.isNull()) printf("viewmag+.png not found !\n"); - zoomMenu->insertItem(pix, i18n("Zoom In +"), this, TQT_SLOT(zoomIn()) ); + zoomMenu->insertItem(pix, i18n("Zoom In +"), TQT_TQOBJECT(this), TQT_SLOT(zoomIn()) ); pix = _iconloader->loadIcon("viewmag-.png", KIcon::Toolbar , 16 ); if(pix.isNull()) printf("viewmag-.png not found !\n"); - zoomMenu->insertItem(pix, i18n("Zoom Out -"), this, TQT_SLOT(zoomOut()) ); + zoomMenu->insertItem(pix, i18n("Zoom Out -"), TQT_TQOBJECT(this), TQT_SLOT(zoomOut()) ); b = _toolbar->getButton(1); b->setDelayedPopup(zoomMenu); _toolbar->insertButton("move.png", 2, TQT_SIGNAL(clicked()), - this, TQT_SLOT(setMove()), + TQT_TQOBJECT(this), TQT_SLOT(setMove()), true, i18n("Move") ); return _toolbar; @@ -338,7 +338,7 @@ xQGanttBarViewPort::drawGrid(TQPainter* p, int x1, int y1, int x2, int y2) for(ptrDate = _holidays.first(); ptrDate != 0; ptrDate = _holidays.next() ) { if(*ptrDate > cmp) { - tmp = _toplevelitem->getStart().secsTo(*ptrDate)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(*ptrDate))/60; a = screenX( tmp ); p->fillRect( a, y1, w, y2, _hol ); } @@ -350,7 +350,7 @@ xQGanttBarViewPort::drawGrid(TQPainter* p, int x1, int y1, int x2, int y2) for(int i=0; i<=end; i++, start = start.addDays(1) ) { int dayOfWeek = start.dayOfWeek(); - tmp = _toplevelitem->getStart().secsTo(start)/60; + tmp = _toplevelitem->getStart().secsTo(TQDateTime(start))/60; a = screenX( tmp ); // draw saturday @@ -674,7 +674,7 @@ xQGanttBarViewPort::drawHeader(TQPainter* p, int /*x1*/, int /*y1*/, int /*x2*/, for(int i=0; i<=end; i++, t = t.addDays(1) ) { - tmp = itemstart.secsTo(t)/60; + tmp = itemstart.secsTo(TQDateTime(t))/60; a = screenX( tmp ); if(t.dayOfWeek() == 1) { diff --git a/kgantt/kgantt/xQGanttBarViewPort_Events.cpp b/kgantt/kgantt/xQGanttBarViewPort_Events.cpp index be6d38b54..d7542d1c2 100644 --- a/kgantt/kgantt/xQGanttBarViewPort_Events.cpp +++ b/kgantt/kgantt/xQGanttBarViewPort_Events.cpp @@ -43,7 +43,7 @@ xQGanttBarViewPort::mousePressEvent(TQMouseEvent* e) _itemTextEdit->hide(); // right mousebutton & control -> popup menu - if(e->button() == RightButton && e->state() == ControlButton ) { + if(e->button() == Qt::RightButton && e->state() == ControlButton ) { _menu->popup(e->globalPos()); return; } @@ -64,7 +64,7 @@ xQGanttBarViewPort::mousePressEvent(TQMouseEvent* e) /* * edit text */ - if(e->button() == MidButton && _mode == Select) { + if(e->button() == Qt::MidButton && _mode == Select) { xTQTaskPosition* tp = _gItemList.tqfind(_currentItem); TQPainter p(this); @@ -91,7 +91,7 @@ xQGanttBarViewPort::mousePressEvent(TQMouseEvent* e) /* * open/close item, move start, end, item */ - if(e->button() == LeftButton && _mode == Select) { + if(e->button() == Qt::LeftButton && _mode == Select) { _timediff = 0; @@ -210,21 +210,21 @@ xQGanttBarViewPort::mouseReleaseEvent(TQMouseEvent* e) if(!_Mousemoved) { - if(e->button() == LeftButton) + if(e->button() == Qt::LeftButton) zoom(1.4, e->x(), e->y() ); - if(e->button() == RightButton) + if(e->button() == Qt::RightButton) zoom(0.7, e->x(), e->y() ); - if(e->button() == MidButton) + if(e->button() == Qt::MidButton) zoomAll(); } else { - if(_currentMButton == LeftButton) { + if(_currentMButton == Qt::LeftButton) { TQPainter p(this); TQPen pen(DashLine); @@ -284,7 +284,7 @@ xQGanttBarViewPort::mouseMoveEvent(TQMouseEvent* e) case Select: { - if(_currentMButton == LeftButton && _currentItem) { + if(_currentMButton == Qt::LeftButton && _currentItem) { TQPainter p(this); p.setRasterOp(XorROP); @@ -442,7 +442,7 @@ xQGanttBarViewPort::mouseMoveEvent(TQMouseEvent* e) case Zoom: { - if(_currentMButton == LeftButton) { + if(_currentMButton == Qt::LeftButton) { static TQString strpos; diff --git a/kgantt/kgantt/xQGanttListViewPort.h b/kgantt/kgantt/xQGanttListViewPort.h index bb0d1b156..a2e97ca3b 100644 --- a/kgantt/kgantt/xQGanttListViewPort.h +++ b/kgantt/kgantt/xQGanttListViewPort.h @@ -114,7 +114,7 @@ protected: void mousePressEvent(TQMouseEvent* e) { - if(e->button() == RightButton && e->state() == ControlButton ) { + if(e->button() == Qt::RightButton && e->state() == ControlButton ) { _menu->popup(e->globalPos()); return; } diff --git a/kioslaves/imap4/imap4.cc b/kioslaves/imap4/imap4.cc index 29ab5980a..b04b5b60a 100644 --- a/kioslaves/imap4/imap4.cc +++ b/kioslaves/imap4/imap4.cc @@ -610,9 +610,9 @@ IMAP4Protocol::listDir (const KURL & _url) } if ( !selectInfo.alert().isNull() ) { if ( !myBox.isEmpty() ) { - warning( i18n( "Message from %1 while processing '%2': %3" ).arg( myHost, myBox, selectInfo.alert() ) ); + warning( i18n( "Message from %1 while processing '%2': %3" ).tqarg( myHost, myBox, selectInfo.alert() ) ); } else { - warning( i18n( "Message from %1: %2" ).arg( myHost, selectInfo.alert() ) ); + warning( i18n( "Message from %1: %2" ).tqarg( myHost, TQString(selectInfo.alert()) ) ); } selectInfo.setAlert( 0 ); } @@ -934,7 +934,7 @@ IMAP4Protocol::mkdir (const KURL & _url, int) if ( ask && messageBox(QuestionYesNo, i18n("The following folder will be created on the server: %1 " - "What do you want to store in this folder?").arg( aBox ), + "What do you want to store in this folder?").tqarg( aBox ), i18n("Create Folder"), i18n("&Messages"), i18n("&Subfolders")) == KMessageBox::No ) { @@ -979,7 +979,7 @@ IMAP4Protocol::copy (const KURL & src, const KURL & dest, int, bool overwrite) { KURL testDir = dest; - TQString subDir = dBox.right (dBox.length () - dBox.findRev ('/')); + TQString subDir = dBox.right (dBox.length () - dBox.tqfindRev ('/')); TQString topDir = dBox.left (sub); testDir.setPath ("/" + topDir); dType = @@ -1272,8 +1272,8 @@ IMAP4Protocol::special (const TQByteArray & aData) completeQueue.removeRef (cmd); error(ERR_SLAVE_DEFINED, i18n("Unsubscribe of folder %1 " "failed. The server returned: %2") - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef (cmd); @@ -1293,8 +1293,8 @@ IMAP4Protocol::special (const TQByteArray & aData) completeQueue.removeRef (cmd); error(ERR_SLAVE_DEFINED, i18n("Subscribe of folder %1 " "failed. The server returned: %2") - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef (cmd); @@ -1361,7 +1361,7 @@ IMAP4Protocol::special (const TQByteArray & aData) { completeQueue.removeRef (cmd); error(ERR_COULD_NOT_WRITE, i18n("Changing the flags of message %1 " - "failed.").arg(_url.prettyURL())); + "failed.").tqarg(_url.prettyURL())); return; } completeQueue.removeRef (cmd); @@ -1373,7 +1373,7 @@ IMAP4Protocol::special (const TQByteArray & aData) { completeQueue.removeRef (cmd); error(ERR_COULD_NOT_WRITE, i18n("Changing the flags of message %1 " - "failed.").arg(_url.prettyURL())); + "failed.").tqarg(_url.prettyURL())); return; } completeQueue.removeRef (cmd); @@ -1404,7 +1404,7 @@ IMAP4Protocol::special (const TQByteArray & aData) { completeQueue.removeRef (cmd); error(ERR_COULD_NOT_WRITE, i18n("Changing the flags of message %1 " - "failed.").arg(_url.prettyURL())); + "failed.").tqarg(_url.prettyURL())); return; } completeQueue.removeRef (cmd); @@ -1451,9 +1451,9 @@ IMAP4Protocol::specialACLCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Setting the Access Control List on folder %1 " "for user %2 failed. The server returned: %3") - .arg(_url.prettyURL()) - .arg(user) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(user) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef (cmd); @@ -1470,9 +1470,9 @@ IMAP4Protocol::specialACLCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Deleting the Access Control List on folder %1 " "for user %2 failed. The server returned: %3") - .arg(_url.prettyURL()) - .arg(user) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(user) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef (cmd); @@ -1487,8 +1487,8 @@ IMAP4Protocol::specialACLCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Retrieving the Access Control List on folder %1 " "failed. The server returned: %2") - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } // Returning information to the application from a special() command isn't easy. @@ -1514,8 +1514,8 @@ IMAP4Protocol::specialACLCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Retrieving the Access Control List on folder %1 " "failed. The server returned: %2") - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } TQStringList lst = getResults(); @@ -1548,8 +1548,8 @@ IMAP4Protocol::specialSearchCommand( TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Searching of folder %1 " "failed. The server returned: %2") - .arg(aBox) - .arg(cmd->resultInfo())); + .tqarg(aBox) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef(cmd); @@ -1582,9 +1582,9 @@ IMAP4Protocol::specialCustomCommand( TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Custom command %1:%2 " "failed. The server returned: %3") - .arg(command) - .arg(arguments) - .arg(cmd->resultInfo())); + .tqarg(command) + .tqarg(arguments) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef(cmd); @@ -1665,9 +1665,9 @@ IMAP4Protocol::specialAnnotateMoreCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Setting the annotation %1 on folder %2 " " failed. The server returned: %3") - .arg(entry) - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(entry) + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } completeQueue.removeRef (cmd); @@ -1689,9 +1689,9 @@ IMAP4Protocol::specialAnnotateMoreCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Retrieving the annotation %1 on folder %2 " "failed. The server returned: %3") - .arg(entry) - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(entry) + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } // Returning information to the application from a special() command isn't easy. @@ -1726,8 +1726,8 @@ IMAP4Protocol::specialQuotaCommand( int command, TQDataStream& stream ) { error(ERR_SLAVE_DEFINED, i18n("Retrieving the quota root information on folder %1 " "failed. The server returned: %2") - .arg(_url.prettyURL()) - .arg(cmd->resultInfo())); + .tqarg(_url.prettyURL()) + .tqarg(cmd->resultInfo())); return; } infoMessage(getResults().join( "\r" )); @@ -1816,7 +1816,7 @@ IMAP4Protocol::slave_status () { bool connected = (getState() != ISTATE_NO) && isConnectionValid(); kdDebug(7116) << "IMAP4::slave_status " << connected << endl; - slavetqStatus ( connected ? myHost : TQString(), connected ); + slaveStatus ( connected ? myHost : TQString(), connected ); } void @@ -2051,7 +2051,7 @@ bool IMAP4Protocol::makeLogin () { error(ERR_COULD_NOT_LOGIN, i18n("The server %1 supports neither " "IMAP4 nor IMAP4rev1.\nIt identified itself with: %2") - .arg(myHost).arg(greeting)); + .tqarg(myHost).tqarg(greeting)); closeConnection(); return false; } @@ -2102,7 +2102,7 @@ bool IMAP4Protocol::makeLogin () else { if (!hasCapability (TQString ("AUTH=") + myAuth)) { error (ERR_COULD_NOT_LOGIN, i18n("The authentication method %1 is not " - "supported by the server.").arg(myAuth)); + "supported by the server.").tqarg(myAuth)); closeConnection(); return false; } @@ -2144,14 +2144,14 @@ bool IMAP4Protocol::makeLogin () } if (!clientLogin (myUser, myPass, resultInfo)) error(KIO::ERR_COULD_NOT_AUTHENTICATE, i18n("Unable to login. Probably the " - "password is wrong.\nThe server %1 replied:\n%2").arg(myHost).arg(resultInfo)); + "password is wrong.\nThe server %1 replied:\n%2").tqarg(myHost).tqarg(resultInfo)); } else { #ifdef HAVE_LIBSASL2 if (!clientAuthenticate (this, authInfo, myHost, myAuth, mySSL, resultInfo)) error(KIO::ERR_COULD_NOT_AUTHENTICATE, i18n("Unable to authenticate via %1.\n" - "The server %2 replied:\n%3").arg(myAuth).arg(myHost).arg(resultInfo)); + "The server %2 replied:\n%3").tqarg(myAuth).tqarg(myHost).tqarg(resultInfo)); else { myUser = authInfo.username; myPass = authInfo.password; @@ -2574,7 +2574,7 @@ IMAP4Protocol::parseURL (const KURL & _url, TQString & _box, // we try to reconstruct it from the URL if (!_box.isEmpty()) { - int start = _url.path().findRev(_box); + int start = _url.path().tqfindRev(_box); if (start != -1) _hierarchyDelimiter = _url.path().mid(start-1, start); kdDebug(7116) << "IMAP4::parseURL - reconstructed delimiter:" << _hierarchyDelimiter @@ -2701,7 +2701,7 @@ IMAP4Protocol::assureBox (const TQString & aBox, bool readonly) // not allowed to enter this folder error(ERR_ACCESS_DENIED, cmdInfo); } else { - error(ERR_SLAVE_DEFINED, i18n("Unable to open folder %1. The server replied: %2").arg(aBox).arg(cmdInfo)); + error(ERR_SLAVE_DEFINED, i18n("Unable to open folder %1. The server replied: %2").tqarg(aBox).tqarg(cmdInfo)); } } else { error(KIO::ERR_DOES_NOT_EXIST, aBox); diff --git a/kioslaves/imap4/imapparser.cc b/kioslaves/imap4/imapparser.cc index 573665260..aa3916ff3 100644 --- a/kioslaves/imap4/imapparser.cc +++ b/kioslaves/imap4/imapparser.cc @@ -1407,7 +1407,7 @@ void imapParser::parseBody (parseString & inWords) { TQCString references = parseLiteralC(inWords, true); int start = references.tqfind ('<'); - int end = references.findRev ('>'); + int end = references.tqfindRev ('>'); if (start < end) references = references.mid (start, end - start + 1); envelope->setReferences(references.simplifyWhiteSpace()); @@ -1871,7 +1871,7 @@ imapParser::parseURL (const KURL & _url, TQString & _box, TQString & _section, int pt = temp.tqfind ('/'); if (pt > 0) { - if (temp.findRev ('"', pt) == -1 || temp.tqfind('"', pt) == -1) + if (temp.tqfindRev ('"', pt) == -1 || temp.tqfind('"', pt) == -1) { // if we have non-quoted '/' separator we'll just nuke it temp.truncate(pt); diff --git a/kioslaves/imap4/imapparser.h b/kioslaves/imap4/imapparser.h index 0552baf83..260f4b79f 100644 --- a/kioslaves/imap4/imapparser.h +++ b/kioslaves/imap4/imapparser.h @@ -69,23 +69,23 @@ public: void takeLeft(TQCString& dest, uint len) const { dest.resize(len + 1); - qmemmove(dest.data(), data.data() + pos, len); + tqmemmove(dest.data(), data.data() + pos, len); } // Warning: does not check for going past end of "data" void takeLeftNoResize(TQCString& dest, uint len) const { - qmemmove(dest.data(), data.data() + pos, len); + tqmemmove(dest.data(), data.data() + pos, len); } // Warning: does not check for going past end of "data" void takeMid(TQCString& dest, uint start, uint len) const { dest.resize(len + 1); - qmemmove(dest.data(), data.data() + pos + start, len); + tqmemmove(dest.data(), data.data() + pos + start, len); } // Warning: does not check for going past end of "data" void takeMidNoResize(TQCString& dest, uint start, uint len) const { - qmemmove(dest.data(), data.data() + pos + start, len); + tqmemmove(dest.data(), data.data() + pos + start, len); } void clear() { diff --git a/kioslaves/imap4/mailheader.cc b/kioslaves/imap4/mailheader.cc index 285bd325a..76e03ace9 100644 --- a/kioslaves/imap4/mailheader.cc +++ b/kioslaves/imap4/mailheader.cc @@ -37,7 +37,7 @@ mailHeader::addHdrLine (mimeHdrLine * inLine) mimeHdrLine *addLine = new mimeHdrLine (inLine); const TQCString label(addLine->getLabel()); - const TQCString value(addLine->getValue()); + TQCString value(addLine->getValue()); if (!qstricmp (label, "Return-Path")) { returnpathAdr.parseAddress (value.data ()); @@ -76,8 +76,8 @@ mailHeader::addHdrLine (mimeHdrLine * inLine) goto out; } if (!qstricmp (label.data (), "Message-ID")) { - int start = value.findRev ('<'); - int end = value.findRev ('>'); + int start = value.tqfindRev ('<'); + int end = value.tqfindRev ('>'); if (start < end) messageID = value.mid (start, end - start + 1); else { @@ -87,8 +87,8 @@ mailHeader::addHdrLine (mimeHdrLine * inLine) goto out; } if (!qstricmp (label.data (), "In-Reply-To")) { - int start = value.findRev ('<'); - int end = value.findRev ('>'); + int start = value.tqfindRev ('<'); + int end = value.tqfindRev ('>'); if (start < end) inReplyTo = value.mid (start, end - start + 1); goto out; diff --git a/kioslaves/imap4/mimehdrline.cc b/kioslaves/imap4/mimehdrline.cc index 56c9b2d74..4158e59d5 100644 --- a/kioslaves/imap4/mimehdrline.cc +++ b/kioslaves/imap4/mimehdrline.cc @@ -494,9 +494,9 @@ mimeHdrLine::truncateLine(TQCString aLine, unsigned int truncate) validStart += 2; } while (len > truncate) { - cutHere = aLine.findRev(' ', truncate); + cutHere = aLine.tqfindRev(' ', truncate); if (cutHere < 1 || cutHere < validStart) { - cutHere = aLine.findRev('\t', truncate); + cutHere = aLine.tqfindRev('\t', truncate); if (cutHere < 1) { cutHere = aLine.tqfind(' ', 1); if (cutHere < 1) { diff --git a/kioslaves/imap4/mimeheader.cc b/kioslaves/imap4/mimeheader.cc index c14fbb705..d32f7eaca 100644 --- a/kioslaves/imap4/mimeheader.cc +++ b/kioslaves/imap4/mimeheader.cc @@ -84,7 +84,7 @@ mimeHeader::addHdrLine (mimeHdrLine * aHdrLine) else { int skip; - char *aCStr = addLine->getValue ().data (); + const char *aCStr = addLine->getValue ().data (); TQDict < TQString > *aList = 0; skip = mimeHdrLine::parseSeparator (';', aCStr); diff --git a/kioslaves/imap4/mimeio.cc b/kioslaves/imap4/mimeio.cc index 971cd0a9c..9325df130 100644 --- a/kioslaves/imap4/mimeio.cc +++ b/kioslaves/imap4/mimeio.cc @@ -68,7 +68,7 @@ mimeIO::outputMimeLine (const TQCString & inLine) TQCString aLine = inLine; int len = inLine.length(); - int theLF = aLine.findRev ('\n'); + int theLF = aLine.tqfindRev ('\n'); if (theLF == len - 1 && theLF != -1) { //we have a trailing LF, now check for CR diff --git a/kioslaves/imap4/rfcdecoder.cc b/kioslaves/imap4/rfcdecoder.cc index 46500fad0..426911d0e 100644 --- a/kioslaves/imap4/rfcdecoder.cc +++ b/kioslaves/imap4/rfcdecoder.cc @@ -371,7 +371,7 @@ rfcDecoder::decodeRFC2047String (const TQString & _str, TQString & charset, else { charset = TQCString (beg, i - 1); // -2 + 1 for the zero - int pt = charset.findRev('*'); + int pt = charset.tqfindRev('*'); if (pt != -1) { // save language for later usage @@ -634,7 +634,7 @@ rfcDecoder::decodeRFC2231String (const TQString & _str) if (p < 0) return _str; - int l = _str.findRev ('\''); + int l = _str.tqfindRev ('\''); //second is language if (p >= l) @@ -653,13 +653,13 @@ rfcDecoder::decodeRFC2231String (const TQString & _str) { if (st.at (p) == 37) { - ch = st.at (p + 1).latin1 () - 48; + ch = st.tqat (p + 1).latin1 () - 48; if (ch > 16) ch -= 7; - ch2 = st.at (p + 2).latin1 () - 48; + ch2 = st.tqat (p + 2).latin1 () - 48; if (ch2 > 16) ch2 -= 7; - st.at (p) = ch * 16 + ch2; + st.tqat (p) = ch * 16 + ch2; st.remove (p + 1, 2); } p++; diff --git a/kioslaves/mbox/stat.cc b/kioslaves/mbox/stat.cc index 00285b149..093701e05 100644 --- a/kioslaves/mbox/stat.cc +++ b/kioslaves/mbox/stat.cc @@ -50,7 +50,7 @@ KIO::UDSEntry Stat::stat( ReadMBox& mbox, const UrlInfo& info ) Stat::addAtom( entry, KIO::UDS_FILE_TYPE, S_IFREG ); Stat::addAtom( entry, KIO::UDS_MIME_TYPE, "message/rfc822" ); - url = TQString( "mbox:%1/%2" ).arg( info.filename(), mbox.currentID() ); + url = TQString( "mbox:%1/%2" ).tqarg( info.filename(), mbox.currentID() ); Stat::addAtom( entry, KIO::UDS_URL, url ); if( mbox.currentID().isEmpty() ) Stat::addAtom( entry, KIO::UDS_NAME, "foobar" ); @@ -79,14 +79,14 @@ KIO::UDSEntry Stat::statMessage( const UrlInfo& info ) { kdDebug() << "statMessage( " << info.url() << " )" << endl; KIO::UDSEntry entry; - TQString url = TQString( "mbox:%1" ).arg( info.url() ); + TQString url = TQString( "mbox:%1" ).tqarg( info.url() ); //Specific things for a message Stat::addAtom( entry, KIO::UDS_FILE_TYPE, S_IFREG ); Stat::addAtom( entry, KIO::UDS_MIME_TYPE, "message/rfc822" ); Stat::addAtom( entry, KIO::UDS_URL, url ); - url = url.right( url.length() - url.findRev( "/" ) - 1 ); + url = url.right( url.length() - url.tqfindRev( "/" ) - 1 ); Stat::addAtom( entry, KIO::UDS_NAME, url ); return entry; diff --git a/kioslaves/mbox/urlinfo.cc b/kioslaves/mbox/urlinfo.cc index d59c77ac8..2a35ce2ea 100644 --- a/kioslaves/mbox/urlinfo.cc +++ b/kioslaves/mbox/urlinfo.cc @@ -111,7 +111,7 @@ bool UrlInfo::isMessage( const KURL& url ) { TQString path = url.path(); TQFileInfo info; - int cutindex = path.findRev( '/' ); + int cutindex = path.tqfindRev( '/' ); //Does it contain at least one /? if( cutindex < 0 ) diff --git a/kioslaves/sieve/sieve.cpp b/kioslaves/sieve/sieve.cpp index 802b3cdc8..781e37ca5 100644 --- a/kioslaves/sieve/sieve.cpp +++ b/kioslaves/sieve/sieve.cpp @@ -307,8 +307,8 @@ void kio_sieveProtocol::changeCheck( const KURL &url ) TQStringList::iterator it; for ( it = q.begin(); it != q.end(); ++it ) { - if ( ( (*it).section('=',0,0) ).lower() == "x-mech" ) { - auth = ( (*it).section('=',1) ).upper(); + if ( TQString( (*it).section('=',0,0) ).lower() == "x-mech" ) { + auth = TQString( (*it).section('=',1) ).upper(); break; } } @@ -340,7 +340,7 @@ bool kio_sieveProtocol::connect(bool useTLSIfAvailable) if (isConnectionValid()) return true; - infoMessage(i18n("Connecting to %1...").arg( m_sServer)); + infoMessage(i18n("Connecting to %1...").tqarg( m_sServer)); if (m_connMode == CONNECTION_ORIENTED && m_shouldBeConnected) { error(ERR_CONNECTION_BROKEN, i18n("The connection to the server was lost.")); @@ -626,7 +626,7 @@ void kio_sieveProtocol::put(const KURL& url, int /*permissions*/, bool /*overwri error(ERR_UNSUPPORTED_PROTOCOL, i18n("A protocol error occurred " "while trying to negotiate script uploading.\n" "The server responded:\n%1") - .arg(r.getAction().right(r.getAction().length() - 3))); + .tqarg(r.getAction().right(r.getAction().length() - 3))); return; } }*/ @@ -672,7 +672,7 @@ void kio_sieveProtocol::put(const KURL& url, int /*permissions*/, bool /*overwri error(ERR_INTERNAL_SERVER, i18n("The script did not upload successfully.\n" "This is probably due to errors in the script.\n" - "The server responded:\n%1").arg(errmsg)); + "The server responded:\n%1").tqarg(TQString(errmsg))); // clear the rest of the incoming data receiveData(); @@ -680,7 +680,7 @@ void kio_sieveProtocol::put(const KURL& url, int /*permissions*/, bool /*overwri error(ERR_INTERNAL_SERVER, i18n("The script did not upload successfully.\n" "This is probably due to errors in the script.\n" - "The server responded:\n%1").arg(r.getKey())); + "The server responded:\n%1").tqarg(TQString(r.getKey()))); } else error(ERR_INTERNAL_SERVER, i18n("The script did not upload successfully.\n" @@ -1016,7 +1016,7 @@ bool kio_sieveProtocol::saslInteract( void *in, AuthInfo &ai ) return true; } -#define SASLERROR error(ERR_COULD_NOT_AUTHENTICATE, i18n("An error occurred during authentication: %1").arg( \ +#define SASLERROR error(ERR_COULD_NOT_AUTHENTICATE, i18n("An error occurred during authentication: %1").tqarg( \ TQString::fromUtf8( sasl_errdetail( conn ) ))); bool kio_sieveProtocol::authenticate() @@ -1109,7 +1109,7 @@ bool kio_sieveProtocol::authenticate() sasl_dispose( &conn ); error(ERR_SLAVE_DEFINED, i18n("A protocol error occurred during authentication.\n" - "Choose a different authentication method to %1.").arg(mechusing)); + "Choose a different authentication method to %1.").tqarg(mechusing)); return false; } @@ -1121,7 +1121,7 @@ bool kio_sieveProtocol::authenticate() sasl_dispose( &conn ); error(ERR_UNSUPPORTED_PROTOCOL, i18n("A protocol error occurred during authentication.\n" - "Choose a different authentication method to %1.").arg(mechusing)); + "Choose a different authentication method to %1.").tqarg(mechusing)); return false; } @@ -1168,7 +1168,7 @@ bool kio_sieveProtocol::authenticate() return true; } else { // Authentication failed. - error(ERR_COULD_NOT_AUTHENTICATE, i18n("Authentication failed.\nMost likely the password is wrong.\nThe server responded:\n%1").arg( r.getAction() ) ); + error(ERR_COULD_NOT_AUTHENTICATE, i18n("Authentication failed.\nMost likely the password is wrong.\nThe server responded:\n%1").tqarg( TQString(r.getAction()) ) ); return false; } } diff --git a/kitchensync/libqopensync/group.cpp b/kitchensync/libqopensync/group.cpp index a3fd4f2a0..d716e1c4c 100644 --- a/kitchensync/libqopensync/group.cpp +++ b/kitchensync/libqopensync/group.cpp @@ -46,7 +46,7 @@ TQStringList GroupConfig::activeObjectTypes() const { Q_ASSERT( mGroup ); - const TQString fileName = TQString( "%1/filter.conf" ).arg( osync_group_get_configdir( mGroup ) ); + const TQString fileName = TQString( "%1/filter.conf" ).tqarg( osync_group_get_configdir( mGroup ) ); TQFile file( fileName ); if ( !file.open( IO_ReadOnly ) ) @@ -92,7 +92,7 @@ void GroupConfig::setActiveObjectTypes( const TQStringList &objectTypes ) element.appendChild( entry ); } - const TQString fileName = TQString( "%1/filter.conf" ).arg( osync_group_get_configdir( mGroup ) ); + const TQString fileName = TQString( "%1/filter.conf" ).tqarg( osync_group_get_configdir( mGroup ) ); TQFile file( fileName ); if ( !file.open( IO_WriteOnly ) ) diff --git a/kitchensync/opensyncdbus/dbusclient.cpp b/kitchensync/opensyncdbus/dbusclient.cpp index f53ee74e3..39cd1cc94 100644 --- a/kitchensync/opensyncdbus/dbusclient.cpp +++ b/kitchensync/opensyncdbus/dbusclient.cpp @@ -85,7 +85,7 @@ TQDBusMessage OpenSyncService::showMember( const TQDBusMessage &message ) if ( message.count() != 2 ) { return error( message, "arg_count", TQString("Wrong number of arguments. Expected 2, got %1.") - .arg( message.count() ) ); + .tqarg( message.count() ) ); } TQString groupName = message[ 0 ].toString(); @@ -111,14 +111,14 @@ TQDBusMessage OpenSyncService::showMember( const TQDBusMessage &message ) QSync::Group group = env.groupByName( groupName ); if ( !group.isValid() ) { return error( message, "group_name", TQString("Unknown group '%1'.") - .arg( groupName ) ); + .tqarg( groupName ) ); } QSync::Member member = group.memberById( memberId ); if ( !member.isValid() ) { return error( message, "member_id", - TQString("Unknown member id '%1' in group '%2'.").arg( groupName ) - .arg( memberId ) ); + TQString("Unknown member id '%1' in group '%2'.").tqarg( groupName ) + .tqarg( memberId ) ); } reply.append( memberId ); @@ -136,7 +136,7 @@ TQDBusMessage OpenSyncService::showGroup( const TQDBusMessage &message ) if ( message.count() != 1 ) { return error( message, "arg_count", TQString("Wrong number of arguments. Expected 1, got %1") - .arg( message.count() ) ); + .tqarg( message.count() ) ); } TQString groupName = message[ 0 ].toString(); @@ -156,7 +156,7 @@ TQDBusMessage OpenSyncService::showGroup( const TQDBusMessage &message ) QSync::Group group = env.groupByName( groupName ); if ( !group.isValid() ) { return error( message, "group_name", TQString("Unknown group '%1'") - .arg( groupName ) ); + .tqarg( groupName ) ); } QSync::Group::Iterator it( &group ); diff --git a/kitchensync/src/aboutpage.cpp b/kitchensync/src/aboutpage.cpp index 9d0503edb..1590338c2 100644 --- a/kitchensync/src/aboutpage.cpp +++ b/kitchensync/src/aboutpage.cpp @@ -55,11 +55,11 @@ AboutPage::AboutPage( TQWidget *tqparent ) TQString location = locate( "data", "kitchensync/about/main.html" ); TQString content = readFile( location ); - content = content.arg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); + content = content.tqarg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); if ( kapp->reverseLayout() ) - content = content.arg( "@import \"%1\";" ).arg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); + content = content.tqarg( "@import \"%1\";" ).tqarg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); else - content = content.arg( "" ); + content = content.tqarg( "" ); KHTMLPart *part = new KHTMLPart( this ); tqlayout->addWidget( part->view() ); @@ -70,8 +70,8 @@ AboutPage::AboutPage( TQWidget *tqparent ) TQString catchPhrase( i18n( "Get Synchronized!" ) ); TQString quickDescription( i18n( "The KDE Synchronization Tool" ) ); - part->write( content.arg( TQFont().pointSize() + 2 ).arg( appName ) - .arg( catchPhrase ).arg( quickDescription ).arg( htmlText() ) ); + part->write( content.tqarg( TQFont().pointSize() + 2 ).tqarg( appName ) + .tqarg( catchPhrase ).tqarg( quickDescription ).tqarg( htmlText() ) ); part->end(); connect( part->browserExtension(), @@ -111,29 +111,29 @@ TQString AboutPage::htmlText() const "<tr><td><a href=\"%1\"><img width=\"%1\" height=\"%1\" src=\"%1\" /></a></td>" "<td><a href=\"%1\">%1</a><br><span id=\"subtext\"><nobr>%1</td></tr>" "</table>" ) - .arg( kapp->aboutData()->version() ) - .arg( i18n( "KitchenSync synchronizes your e-mail, addressbook, calendar, to-do list and more." ) ) - .arg( "help:/kitchensync" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( handbook_icon_path ) - .arg( "help:/kitchensync" ) - .arg( i18n( "Read Manual" ) ) - .arg( i18n( "Learn more about KitchenSync and its components" ) ) - .arg( "http://pim.kde.org" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( html_icon_path ) - .arg( "http://pim.kde.org" ) - .arg( i18n( "Visit KitchenSync Website" ) ) - .arg( i18n( "Access online resources and tutorials" ) ) - .arg( "exec:/addGroup" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( wizard_icon_path ) - .arg( "exec:/addGroup" ) - .arg( i18n( "Add Synchronization Group" ) ) - .arg( i18n( "Create group of tqdevices for synchronization" ) ); + .tqarg( kapp->aboutData()->version() ) + .tqarg( i18n( "KitchenSync synchronizes your e-mail, addressbook, calendar, to-do list and more." ) ) + .tqarg( "help:/kitchensync" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( handbook_icon_path ) + .tqarg( "help:/kitchensync" ) + .tqarg( i18n( "Read Manual" ) ) + .tqarg( i18n( "Learn more about KitchenSync and its components" ) ) + .tqarg( "http://pim.kde.org" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( html_icon_path ) + .tqarg( "http://pim.kde.org" ) + .tqarg( i18n( "Visit KitchenSync Website" ) ) + .tqarg( i18n( "Access online resources and tutorials" ) ) + .tqarg( "exec:/addGroup" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( wizard_icon_path ) + .tqarg( "exec:/addGroup" ) + .tqarg( i18n( "Add Synchronization Group" ) ) + .tqarg( i18n( "Create group of tqdevices for synchronization" ) ); return info; } diff --git a/kitchensync/src/configguievo2.cpp b/kitchensync/src/configguievo2.cpp index 872e673fd..3a6db784e 100644 --- a/kitchensync/src/configguievo2.cpp +++ b/kitchensync/src/configguievo2.cpp @@ -60,9 +60,9 @@ TQString ConfigGuiEvo2::save() const { TQString config = "<config>\n"; - config += TQString( "<address_path>%1</address_path>\n" ).arg( mAddressPath->url() ); - config += TQString( "<calendar_path>%1</calendar_path>\n" ).arg( mCalendarPath->url() ); - config += TQString( "<tasks_path>%1</tasks_path>\n" ).arg( mTasksPath->url() ); + config += TQString( "<address_path>%1</address_path>\n" ).tqarg( mAddressPath->url() ); + config += TQString( "<calendar_path>%1</calendar_path>\n" ).tqarg( mCalendarPath->url() ); + config += TQString( "<tasks_path>%1</tasks_path>\n" ).tqarg( mTasksPath->url() ); config += "</config>"; diff --git a/kitchensync/src/configguigpe.cpp b/kitchensync/src/configguigpe.cpp index 34502d4d6..260552642 100644 --- a/kitchensync/src/configguigpe.cpp +++ b/kitchensync/src/configguigpe.cpp @@ -68,11 +68,11 @@ TQString ConfigGuiGpe::save() const { TQString config = "<config>"; - config += TQString( "<use_local>%1</use_local>" ).arg( mConnectionMode->currentItem() == 0 ); - config += TQString( "<use_ssh>%1</use_ssh>" ).arg( mConnectionMode->currentItem() == 1 ); - config += TQString( "<handheld_ip>%1</handheld_ip>" ).arg( mIP->text() ); - config += TQString( "<handheld_port>%1</handheld_port>" ).arg( mPort->value() ); - config += TQString( "<handheld_user>%1</handheld_user>" ).arg( mUser->text() ); + config += TQString( "<use_local>%1</use_local>" ).tqarg( mConnectionMode->currentItem() == 0 ); + config += TQString( "<use_ssh>%1</use_ssh>" ).tqarg( mConnectionMode->currentItem() == 1 ); + config += TQString( "<handheld_ip>%1</handheld_ip>" ).tqarg( mIP->text() ); + config += TQString( "<handheld_port>%1</handheld_port>" ).tqarg( mPort->value() ); + config += TQString( "<handheld_user>%1</handheld_user>" ).tqarg( mUser->text() ); config += "</config>"; diff --git a/kitchensync/src/configguijescs.cpp b/kitchensync/src/configguijescs.cpp index 552b49a39..e284c3e76 100644 --- a/kitchensync/src/configguijescs.cpp +++ b/kitchensync/src/configguijescs.cpp @@ -61,13 +61,13 @@ TQString ConfigGuiJescs::save() const int delNotifyState; TQString config = "<config>\n"; - config += TQString( "<url>%1</url>\n" ).arg( mUrl->text() ); - config += TQString( "<username>%1</username>\n" ).arg( mUsername->text() ); - config += TQString( "<password>%1</password>\n" ).arg( mPassword->text() ); + config += TQString( "<url>%1</url>\n" ).tqarg( mUrl->text() ); + config += TQString( "<username>%1</username>\n" ).tqarg( mUsername->text() ); + config += TQString( "<password>%1</password>\n" ).tqarg( mPassword->text() ); if ( mDelNotify->isChecked() ) { delNotifyState = 1; } else { delNotifyState = 0; } - config += TQString( "<del_notify>%1</del_notify>\n" ).arg( delNotifyState ); + config += TQString( "<del_notify>%1</del_notify>\n" ).tqarg( delNotifyState ); config += "</config>"; diff --git a/kitchensync/src/configguildap.cpp b/kitchensync/src/configguildap.cpp index 485b65994..b5ebd02ea 100644 --- a/kitchensync/src/configguildap.cpp +++ b/kitchensync/src/configguildap.cpp @@ -93,26 +93,26 @@ TQString ConfigGuiLdap::save() const { TQString config = "<config>\n"; - config += TQString( "<servername>%1</servername>\n" ).arg( mLdapWidget->host() ); - config += TQString( "<serverport>%1</serverport>\n" ).arg( mLdapWidget->port() ); - config += TQString( "<binddn>%1</binddn>\n" ).arg( mLdapWidget->bindDN() ); - config += TQString( "<password>%1</password>\n" ).arg( mLdapWidget->password() ); - config += TQString( "<anonymous>%1</anonymous>\n" ).arg( mLdapWidget->isAuthAnon() ? "1" : "0" ); - config += TQString( "<searchbase>%1</searchbase>\n" ).arg( mLdapWidget->dn() ); - config += TQString( "<searchfilter>%1</searchfilter>\n" ).arg( mLdapWidget->filter() ); - config += TQString( "<storebase>%1</storebase>\n" ).arg( mLdapWidget->dn() ); - config += TQString( "<keyattr>%1</keyattr>\n" ).arg( mKeyAttribute->text() ); + config += TQString( "<servername>%1</servername>\n" ).tqarg( mLdapWidget->host() ); + config += TQString( "<serverport>%1</serverport>\n" ).tqarg( mLdapWidget->port() ); + config += TQString( "<binddn>%1</binddn>\n" ).tqarg( mLdapWidget->bindDN() ); + config += TQString( "<password>%1</password>\n" ).tqarg( mLdapWidget->password() ); + config += TQString( "<anonymous>%1</anonymous>\n" ).tqarg( mLdapWidget->isAuthAnon() ? "1" : "0" ); + config += TQString( "<searchbase>%1</searchbase>\n" ).tqarg( mLdapWidget->dn() ); + config += TQString( "<searchfilter>%1</searchfilter>\n" ).tqarg( mLdapWidget->filter() ); + config += TQString( "<storebase>%1</storebase>\n" ).tqarg( mLdapWidget->dn() ); + config += TQString( "<keyattr>%1</keyattr>\n" ).tqarg( mKeyAttribute->text() ); TQStringList scopes; scopes << "base" << "one" << "sub"; - config += TQString( "<scope>%1</scope>\n" ).arg( scopes[ mSearchScope->currentItem() ] ); + config += TQString( "<scope>%1</scope>\n" ).tqarg( scopes[ mSearchScope->currentItem() ] ); config += TQString( "<authmech>SIMPLE</authmech>\n" ); - config += TQString( "<encryption>%1</encryption>\n" ).arg( mEncryption->isChecked() ? "1" : "0" ); + config += TQString( "<encryption>%1</encryption>\n" ).tqarg( mEncryption->isChecked() ? "1" : "0" ); - config += TQString( "<ldap_read>%1</ldap_read>\n" ).arg( mReadLdap->isChecked() ? "1" : "0" ); - config += TQString( "<ldap_write>%1</ldap_write>\n" ).arg( mWriteLdap->isChecked() ? "1" : "0" ); + config += TQString( "<ldap_read>%1</ldap_read>\n" ).tqarg( mReadLdap->isChecked() ? "1" : "0" ); + config += TQString( "<ldap_write>%1</ldap_write>\n" ).tqarg( mWriteLdap->isChecked() ? "1" : "0" ); config += "</config>"; diff --git a/kitchensync/src/configguimoto.cpp b/kitchensync/src/configguimoto.cpp index 3314dbef8..b9ec2342c 100644 --- a/kitchensync/src/configguimoto.cpp +++ b/kitchensync/src/configguimoto.cpp @@ -53,7 +53,7 @@ TQString ConfigGuiMoto::save() const { TQString config = "<config>\n"; - config += TQString( "<tqdevice>%1</tqdevice>\n" ).arg( mDeviceString->text() ); + config += TQString( "<tqdevice>%1</tqdevice>\n" ).tqarg( mDeviceString->text() ); config += "</config>"; diff --git a/kitchensync/src/configguipalm.cpp b/kitchensync/src/configguipalm.cpp index b07223d58..688e0cc0d 100644 --- a/kitchensync/src/configguipalm.cpp +++ b/kitchensync/src/configguipalm.cpp @@ -167,7 +167,7 @@ void ConfigGuiPalm::initGUI() gridLayout = new TQGridLayout( connectionLayout, 1, 2, KDialog::spacingHint() ); gridLayout->setMargin( KDialog::marginHint() ); - TQButtonGroup *buttonGroup = new TQButtonGroup( 1, TQt::Horizontal, connectionWidget ); + TQButtonGroup *buttonGroup = new TQButtonGroup( 1, Qt::Horizontal, connectionWidget ); buttonGroup->setExclusive( true ); buttonGroup->setFrameStyle( TQFrame::NoFrame ); mSyncAlways = new TQRadioButton( i18n( "Sync Anyway" ), buttonGroup ); diff --git a/kitchensync/src/configguisunbird.cpp b/kitchensync/src/configguisunbird.cpp index daa251b10..b77ce93ba 100644 --- a/kitchensync/src/configguisunbird.cpp +++ b/kitchensync/src/configguisunbird.cpp @@ -140,10 +140,10 @@ TQString ConfigGuiSunbird::save() const for ( uint i = 0; i < mLocalList.count(); ++i ) { LocalCalendar *lcal = mLocalList[ i ]; config += TQString( "<file " ); - config += TQString( "path=\"%1\" " ).arg( lcal->mPathRequester->url() ); + config += TQString( "path=\"%1\" " ).tqarg( lcal->mPathRequester->url() ); if ( lcal->mDaysCheckBox->isChecked() ) { - config += TQString( "deletedaysold=\"%1\" " ).arg( lcal->mDaysSpinBox->value() ); + config += TQString( "deletedaysold=\"%1\" " ).tqarg( lcal->mDaysSpinBox->value() ); } if ( lcal->mDefaultCheckBox->isChecked() ) { config += TQString( "default=\"1\" " ); @@ -154,12 +154,12 @@ TQString ConfigGuiSunbird::save() const for ( uint i = 0; i < mWebdavList.count(); ++i ) { WebdavCalendar *wcal = mWebdavList[ i ]; config += TQString( "<webdav " ); - config += TQString( "username=\"%1\" " ).arg( wcal->mUsername->text() ); - config += TQString( "password=\"%1\" " ).arg( wcal->mPassword->text() ); - config += TQString( "url=\"%1\" " ).arg( wcal->mUrl->text() ); + config += TQString( "username=\"%1\" " ).tqarg( wcal->mUsername->text() ); + config += TQString( "password=\"%1\" " ).tqarg( wcal->mPassword->text() ); + config += TQString( "url=\"%1\" " ).tqarg( wcal->mUrl->text() ); if ( wcal->mDaysCheckBox->isChecked() ) { - config += TQString( "deletedaysold=\"%1\" " ).arg( wcal->mDaysSpinBox->value() ); + config += TQString( "deletedaysold=\"%1\" " ).tqarg( wcal->mDaysSpinBox->value() ); } if ( wcal->mDefaultCheckBox->isChecked() ) { config += TQString( "default=\"1\" " ); diff --git a/kitchensync/src/configguisynce.cpp b/kitchensync/src/configguisynce.cpp index 64c171a83..5ff5aeacc 100644 --- a/kitchensync/src/configguisynce.cpp +++ b/kitchensync/src/configguisynce.cpp @@ -60,10 +60,10 @@ TQString ConfigGuiSynce::save() const { TQString config = "<config>\n"; - config += TQString( "<contact>%1</contact>\n" ).arg( mContacts->isChecked() ? "1" : "0" ); - config += TQString( "<todos>%1</todos>\n" ).arg( mTodos->isChecked() ? "1" : "0" ); - config += TQString( "<calendar>%1</calendar>\n" ).arg( mCalendar->isChecked() ? "1" : "0" ); - config += TQString( "<file>%1</file>\n" ).arg( mFile->text() ); + config += TQString( "<contact>%1</contact>\n" ).tqarg( mContacts->isChecked() ? "1" : "0" ); + config += TQString( "<todos>%1</todos>\n" ).tqarg( mTodos->isChecked() ? "1" : "0" ); + config += TQString( "<calendar>%1</calendar>\n" ).tqarg( mCalendar->isChecked() ? "1" : "0" ); + config += TQString( "<file>%1</file>\n" ).tqarg( mFile->text() ); config += "</config>"; diff --git a/kitchensync/src/configguisyncmlobex.cpp b/kitchensync/src/configguisyncmlobex.cpp index 1447f5698..024e72ede 100644 --- a/kitchensync/src/configguisyncmlobex.cpp +++ b/kitchensync/src/configguisyncmlobex.cpp @@ -246,7 +246,7 @@ TQString ConfigGuiSyncmlObex::save() const ConnectionTypeList::ConstIterator it; for ( it = mConnectionTypes.begin(); it != mConnectionTypes.end(); it++ ) { if ( mConnection->currentText() == (*it).second ) { - xml += "<type>" + TQString("%1").arg((*it).first) + "</type>\n"; + xml += "<type>" + TQString("%1").tqarg((*it).first) + "</type>\n"; break; } } @@ -264,7 +264,7 @@ TQString ConfigGuiSyncmlObex::save() const SyncmlVersionList::ConstIterator itVersion; for ( itVersion = mSyncmlVersions.begin(); itVersion != mSyncmlVersions.end(); itVersion++ ) { if ( mSyncmlVersion->currentText() == (*itVersion).second ) { - xml += "<version>" + TQString("%1").arg((*itVersion).first) + "</version>\n"; + xml += "<version>" + TQString("%1").tqarg((*itVersion).first) + "</version>\n"; break; } } diff --git a/kitchensync/src/genericdiffalgo.cpp b/kitchensync/src/genericdiffalgo.cpp index 67e49bab4..118f25a55 100644 --- a/kitchensync/src/genericdiffalgo.cpp +++ b/kitchensync/src/genericdiffalgo.cpp @@ -57,11 +57,11 @@ void GenericDiffAlgo::run() for ( uint i = 0; i < lines; ++i ) { if ( i < leftList.count() && i < rightList.count() ) { if ( !compareString( leftList[ i ], rightList[ i ] ) ) - conflictField( i18n( "Line %1" ).arg( i ), leftList[ i ], rightList[ i ] ); + conflictField( i18n( "Line %1" ).tqarg( i ), leftList[ i ], rightList[ i ] ); } else if ( i < leftList.count() && i >= rightList.count() ) { - additionalLeftField( i18n( "Line %1" ).arg( i ), leftList[ i ] ); + additionalLeftField( i18n( "Line %1" ).tqarg( i ), leftList[ i ] ); } else if ( i >= leftList.count() && i < rightList.count() ) { - additionalRightField( i18n( "Line %1" ).arg( i ), rightList[ i ] ); + additionalRightField( i18n( "Line %1" ).tqarg( i ), rightList[ i ] ); } } diff --git a/kitchensync/src/groupconfig.cpp b/kitchensync/src/groupconfig.cpp index eac5759c0..f8f16988c 100644 --- a/kitchensync/src/groupconfig.cpp +++ b/kitchensync/src/groupconfig.cpp @@ -131,7 +131,7 @@ void GroupConfig::updateMembers() QSync::Member member = *it; MemberInfo mi( member ); TQFrame *page = mMemberView->addPage( mi.name(), - TQString( "%1 (%2)" ).arg( mi.name() ).arg(member.pluginName()), mi.desktopIcon() ); + TQString( "%1 (%2)" ).tqarg( mi.name() ).tqarg(member.pluginName()), mi.desktopIcon() ); TQBoxLayout *pageLayout = new TQVBoxLayout( page ); mConfigPages.append( page ); @@ -165,7 +165,7 @@ void GroupConfig::addMember() QSync::Result result = SyncProcessManager::self()->addMember( mProcess, plugin ); if ( result.isError() ) { KMessageBox::error( this, i18n("Error adding member %1\n%2\nType: %3") - .arg( plugin.name() ).arg( result.message() ).arg( result.type() ) ); + .tqarg( plugin.name() ).tqarg( result.message() ).tqarg( result.type() ) ); } else { updateMembers(); diff --git a/kitchensync/src/groupitem.cpp b/kitchensync/src/groupitem.cpp index d708f6815..71a8deff9 100644 --- a/kitchensync/src/groupitem.cpp +++ b/kitchensync/src/groupitem.cpp @@ -102,7 +102,7 @@ GroupItem::GroupItem( KWidgetList *tqparent, SyncProcess *process ) tqlayout->setColStretch( 0, 1 ); tqlayout->setRowStretch( 3, 1 ); - setPaletteBackgroundColor( kapp->palette().active().base() ); + setPaletteBackgroundColor( kapp->tqpalette().active().base() ); connect( mCallbackHandler, TQT_SIGNAL( conflict( QSync::SyncMapping ) ), this, TQT_SLOT( conflict( QSync::SyncMapping ) ) ); @@ -139,11 +139,11 @@ void GroupItem::update() { clear(); - mGroupName->setText( i18n( "Group: %1" ).arg( mSyncProcess->group().name() ) ); + mGroupName->setText( i18n( "Group: %1" ).tqarg( mSyncProcess->group().name() ) ); TQDateTime dateTime = mSyncProcess->group().lastSynchronization(); if ( dateTime.isValid() ) - mTime->setText( i18n( "Last synchronized on: %1" ).arg( KGlobal::locale()->formatDateTime( dateTime ) ) ); + mTime->setText( i18n( "Last synchronized on: %1" ).tqarg( KGlobal::locale()->formatDateTime( dateTime ) ) ); else mTime->setText( i18n( "Not synchronized yet" ) ); @@ -189,14 +189,14 @@ void GroupItem::change( const QSync::SyncChangeUpdate &update ) switch ( update.type() ) { case QSync::SyncChangeUpdate::Received: mProcessedItems++; - mtqStatus->setText( i18n( "%1 entries read" ).arg( mProcessedItems ) ); + mtqStatus->setText( i18n( "%1 entries read" ).tqarg( mProcessedItems ) ); break; case QSync::SyncChangeUpdate::ReceivedInfo: mtqStatus->setText( i18n( "Receive information" ) ); break; case QSync::SyncChangeUpdate::Sent: mProcessedItems--; - mtqStatus->setText( i18n( "%1 entries written" ).arg( mMaxProcessedItems - mProcessedItems ) ); + mtqStatus->setText( i18n( "%1 entries written" ).tqarg( mMaxProcessedItems - mProcessedItems ) ); mProgressBar->show(); @@ -298,19 +298,19 @@ void GroupItem::member( const QSync::SyncMemberUpdate &update ) (*it)->seStatusMessage( i18n( "Disconnected" ) ); break; case QSync::SyncMemberUpdate::ConnectError: - (*it)->seStatusMessage( i18n( "Error: %1" ).arg( update.result().message() ) ); + (*it)->seStatusMessage( i18n( "Error: %1" ).tqarg( update.result().message() ) ); break; case QSync::SyncMemberUpdate::GetChangesError: - (*it)->seStatusMessage( i18n( "Error: %1" ).arg( update.result().message() ) ); + (*it)->seStatusMessage( i18n( "Error: %1" ).tqarg( update.result().message() ) ); break; case QSync::SyncMemberUpdate::CommittedAllError: - (*it)->seStatusMessage( i18n( "Error: %1" ).arg( update.result().message() ) ); + (*it)->seStatusMessage( i18n( "Error: %1" ).tqarg( update.result().message() ) ); break; case QSync::SyncMemberUpdate::SyncDoneError: - (*it)->seStatusMessage( i18n( "Error: %1" ).arg( update.result().message() ) ); + (*it)->seStatusMessage( i18n( "Error: %1" ).tqarg( update.result().message() ) ); break; case QSync::SyncMemberUpdate::DisconnectedError: - (*it)->seStatusMessage( i18n( "Error: %1" ).arg( update.result().message() ) ); + (*it)->seStatusMessage( i18n( "Error: %1" ).tqarg( update.result().message() ) ); break; default: break; diff --git a/kitchensync/src/htmldiffalgodisplay.cpp b/kitchensync/src/htmldiffalgodisplay.cpp index 06779c80b..9094216ee 100644 --- a/kitchensync/src/htmldiffalgodisplay.cpp +++ b/kitchensync/src/htmldiffalgodisplay.cpp @@ -45,13 +45,13 @@ void HTMLDiffAlgoDisplay::begin() mText.append( "<html>" ); mText.append( TQString( "<body text=\"%1\" bgcolor=\"%2\">" ) - .arg( KGlobalSettings::textColor().name() ) - .arg( KGlobalSettings::baseColor().name() ) ); + .tqarg( KGlobalSettings::textColor().name() ) + .tqarg( KGlobalSettings::baseColor().name() ) ); mText.append( "<center><table>" ); mText.append( TQString( "<tr><th></th><th align=\"center\">%1</th><td> </td><th align=\"center\">%2</th></tr>" ) - .arg( mLeftTitle ) - .arg( mRightTitle ) ); + .tqarg( mLeftTitle ) + .tqarg( mRightTitle ) ); } void HTMLDiffAlgoDisplay::end() @@ -76,22 +76,22 @@ void HTMLDiffAlgoDisplay::setRightSourceTitle( const TQString &title ) void HTMLDiffAlgoDisplay::additionalLeftField( const TQString &id, const TQString &value ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td bgcolor=\"#9cff83\">%2</td><td></td><td></td></tr>" ) - .arg( id ) - .arg( textToHTML( value ) ) ); + .tqarg( id ) + .tqarg( textToHTML( value ) ) ); } void HTMLDiffAlgoDisplay::additionalRightField( const TQString &id, const TQString &value ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td></td><td></td><td bgcolor=\"#9cff83\">%2</td></tr>" ) - .arg( id ) - .arg( textToHTML( value ) ) ); + .tqarg( id ) + .tqarg( textToHTML( value ) ) ); } void HTMLDiffAlgoDisplay::conflictField( const TQString &id, const TQString &leftValue, const TQString &rightValue ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td bgcolor=\"#ff8686\">%2</td><td></td><td bgcolor=\"#ff8686\">%3</td></tr>" ) - .arg( id ) - .arg( textToHTML( leftValue ) ) - .arg( textToHTML( rightValue ) ) ); + .tqarg( id ) + .tqarg( textToHTML( leftValue ) ) + .tqarg( textToHTML( rightValue ) ) ); } diff --git a/kitchensync/src/kwidgetlist.cpp b/kitchensync/src/kwidgetlist.cpp index 3869bc1dd..011b4c73b 100644 --- a/kitchensync/src/kwidgetlist.cpp +++ b/kitchensync/src/kwidgetlist.cpp @@ -46,7 +46,7 @@ KWidgetList::KWidgetList( TQWidget *tqparent, const char *name ) addChild( d->mBox ); setResizePolicy( AutoOneFit ); - setFocusPolicy( TQWidget::StrongFocus ); + setFocusPolicy( Qt::StrongFocus ); viewport()->setFocus(); } @@ -169,7 +169,7 @@ KWidgetListItem *KWidgetList::item( int index ) const int KWidgetList::index( KWidgetListItem *item ) const { - return d->mItems.findIndex( item ); + return d->mItems.tqfindIndex( item ); } void KWidgetList::clear() @@ -191,11 +191,11 @@ void KWidgetList::setFocus() bool KWidgetList::eventFilter( TQObject *object, TQEvent *event ) { if ( event->type() == TQEvent::MouseButtonPress ) { - TQMouseEvent *mouseEvent = static_cast<TQMouseEvent*>( event ); - if ( mouseEvent->button() & LeftButton ) { + TQMouseEvent *mouseEvent = TQT_TQMOUSEEVENT( event ); + if ( mouseEvent->button() & Qt::LeftButton ) { TQValueList<KWidgetListItem*>::Iterator it; for ( it = d->mItems.begin(); it != d->mItems.end(); ++it ) { - if ( *it == object ) { + if ( TQT_BASE_OBJECT(*it) == TQT_BASE_OBJECT(object) ) { if ( d->mItems.count() != 1 ) { setSelected( *it ); emit selectionChanged( *it ); @@ -207,7 +207,7 @@ bool KWidgetList::eventFilter( TQObject *object, TQEvent *event ) } else if ( event->type() == TQEvent::MouseButtonDblClick ) { TQValueList<KWidgetListItem*>::Iterator it; for ( it = d->mItems.begin(); it != d->mItems.end(); ++it ) { - if ( *it == object ) { + if ( TQT_BASE_OBJECT(*it) == TQT_BASE_OBJECT(object) ) { if ( d->mItems.count() != 1 ) { setSelected( *it ); emit doubleClicked( *it ); @@ -216,7 +216,7 @@ bool KWidgetList::eventFilter( TQObject *object, TQEvent *event ) } } } else if ( event->type() == TQEvent::KeyPress ) { - TQKeyEvent *keyEvent = static_cast<TQKeyEvent*>( event ); + TQKeyEvent *keyEvent = TQT_TQKEYEVENT( event ); if ( keyEvent->key() == TQt::Key_Up ) { if ( d->mSelectedItem == 0 ) { if ( !d->mItems.isEmpty() ) { @@ -264,7 +264,7 @@ KWidgetListItem::KWidgetListItem( KWidgetList *tqparent, const char *name ) mSelectionForegroundColor = KGlobalSettings::highlightedTextColor(); mSelectionBackgroundColor = KGlobalSettings::highlightColor(); - setFocusPolicy( TQWidget::StrongFocus ); + setFocusPolicy( Qt::StrongFocus ); } KWidgetListItem::~KWidgetListItem() diff --git a/kitchensync/src/mainwidget.cpp b/kitchensync/src/mainwidget.cpp index 63c5c8f98..8dbef8cab 100644 --- a/kitchensync/src/mainwidget.cpp +++ b/kitchensync/src/mainwidget.cpp @@ -102,13 +102,13 @@ void MainWidget::initGUI() void MainWidget::initActions() { - mActionSynchronize = new KAction( i18n("Synchronize"), "hotsync", 0, this, TQT_SLOT( sync() ), + mActionSynchronize = new KAction( i18n("Synchronize"), "hotsync", 0, TQT_TQOBJECT(this), TQT_SLOT( sync() ), mGUIClient->actionCollection(), "sync" ); - mActionAddGroup = new KAction( i18n("Add Group..."), "filenew", 0, this, TQT_SLOT( addGroup() ), + mActionAddGroup = new KAction( i18n("Add Group..."), "filenew", 0, TQT_TQOBJECT(this), TQT_SLOT( addGroup() ), mGUIClient->actionCollection(), "add_group" ); - mActionDeleteGroup = new KAction( i18n("Delete Group..."), "editdelete", 0, this, TQT_SLOT( deleteGroup() ), + mActionDeleteGroup = new KAction( i18n("Delete Group..."), "editdelete", 0, TQT_TQOBJECT(this), TQT_SLOT( deleteGroup() ), mGUIClient->actionCollection(), "delete_group" ); - mActionEditGroup = new KAction( i18n("Edit Group..."), "edit", 0, this, TQT_SLOT( editGroup() ), + mActionEditGroup = new KAction( i18n("Edit Group..."), "edit", 0, TQT_TQOBJECT(this), TQT_SLOT( editGroup() ), mGUIClient->actionCollection(), "edit_group" ); } @@ -141,7 +141,7 @@ void MainWidget::deleteGroup() SyncProcess *syncProcess = mGroupView->selectedSyncProcess(); if ( syncProcess ) { int result = KMessageBox::warningContinueCancel( this, - i18n("Delete synchronization group '%1'?").arg( syncProcess->group().name() ) ); + i18n("Delete synchronization group '%1'?").tqarg( syncProcess->group().name() ) ); if ( result == KMessageBox::Continue ) { SyncProcessManager::self()->remove( syncProcess ); enableActions(); diff --git a/kitchensync/src/mainwindow.cpp b/kitchensync/src/mainwindow.cpp index 4052cb0c1..7a0aa0653 100644 --- a/kitchensync/src/mainwindow.cpp +++ b/kitchensync/src/mainwindow.cpp @@ -55,7 +55,7 @@ MainWindow::~MainWindow() void MainWindow::initActions() { - KStdAction::quit( this, TQT_SLOT( close() ), actionCollection() ); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() ); } #include "mainwindow.moc" diff --git a/kitchensync/src/memberconfig.cpp b/kitchensync/src/memberconfig.cpp index 7687e4524..c6da7a3ab 100644 --- a/kitchensync/src/memberconfig.cpp +++ b/kitchensync/src/memberconfig.cpp @@ -51,7 +51,7 @@ void MemberConfig::loadData() if ( error ) { KMessageBox::error( this, i18n("Unable to read config from plugin '%1':\n%2") - .arg( mMember.pluginName() ).arg( error.message() ) ); + .tqarg( mMember.pluginName() ).tqarg( error.message() ) ); } else { TQString txt = TQString::fromUtf8( cfg.data(), cfg.size() ); mGui->load( txt ); @@ -65,7 +65,7 @@ void MemberConfig::saveData() TQString txt = mGui->save(); if ( txt.isEmpty() ) { - KMessageBox::sorry( this, i18n("Configuration of %1 is empty.").arg( mMember.pluginName() ) ); + KMessageBox::sorry( this, i18n("Configuration of %1 is empty.").tqarg( mMember.pluginName() ) ); } else { TQByteArray cfg = txt.utf8(); cfg.truncate(cfg.size() - 1); /* discard NUL terminator */ diff --git a/kitchensync/src/syncprocessmanager.cpp b/kitchensync/src/syncprocessmanager.cpp index fda111efd..67fe3095c 100644 --- a/kitchensync/src/syncprocessmanager.cpp +++ b/kitchensync/src/syncprocessmanager.cpp @@ -47,7 +47,7 @@ SyncProcessManager::SyncProcessManager() QSync::Result result = mEnvironment->initialize(); if ( result.isError() ) { KMessageBox::error( 0, i18n("Error initializing OpenSync.\n%1") - .arg( result.message() ) ); + .tqarg( result.message() ) ); } else { init( mEnvironment ); } diff --git a/kmail/CMakeLists.txt b/kmail/CMakeLists.txt index 0dddc98c2..c2edd2380 100644 --- a/kmail/CMakeLists.txt +++ b/kmail/CMakeLists.txt @@ -227,6 +227,7 @@ tde_add_kpart( libkmailpart AUTOMOC tde_add_kpart( libkmail_bodypartformatter_application_octetstream SOURCES app_octetstream.cpp + LINK ${TQT_LIBRARIES} DESTINATION ${PLUGIN_INSTALL_DIR} ) diff --git a/kmail/accountdialog.cpp b/kmail/accountdialog.cpp index 4dab221bc..2782bfa93 100644 --- a/kmail/accountdialog.cpp +++ b/kmail/accountdialog.cpp @@ -181,7 +181,7 @@ void ProcmailRCParser::processLocalLock(const TQString &s) { TQString val; - int colonPos = s.findRev(':'); + int colonPos = s.tqfindRev(':'); if (colonPos > 0) { // we don't care about the leading one val = s.mid(colonPos + 1).stripWhiteSpace(); @@ -357,7 +357,7 @@ void AccountDialog::makeLocalAccountPage() topLayout->addWidget( choose, 3, 2 ); TQButtonGroup *group = new TQButtonGroup(i18n("Locking Method"), page ); - group->setColumnLayout(0, TQt::Horizontal); + group->setColumnLayout(0, Qt::Horizontal); group->tqlayout()->setSpacing( 0 ); group->tqlayout()->setMargin( 0 ); TQGridLayout *groupLayout = new TQGridLayout( group->tqlayout() ); @@ -618,7 +618,7 @@ void AccountDialog::makePopAccountPage() label = new TQLabel( i18n("&Port:"), page1 ); grid->addWidget( label, 4, 0 ); mPop.portEdit = new KLineEdit( page1 ); - mPop.portEdit->setValidator( new TQIntValidator(this) ); + mPop.portEdit->setValidator( new TQIntValidator(TQT_TQOBJECT(this)) ); label->setBuddy( mPop.portEdit ); grid->addWidget( mPop.portEdit, 4, 1 ); @@ -778,7 +778,7 @@ void AccountDialog::makePopAccountPage() vlay->addSpacing( KDialog::spacingHint() ); - mPop.encryptionGroup = new TQButtonGroup( 1, TQt::Horizontal, + mPop.encryptionGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Encryption"), page2 ); mPop.encryptionNone = new TQRadioButton( i18n("&None"), mPop.encryptionGroup ); @@ -792,7 +792,7 @@ void AccountDialog::makePopAccountPage() TQT_SLOT(slotPopEncryptionChanged(int))); vlay->addWidget( mPop.encryptionGroup ); - mPop.authGroup = new TQButtonGroup( 1, TQt::Horizontal, + mPop.authGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Authentication Method"), page2 ); mPop.authUser = new TQRadioButton( i18n("Clear te&xt") , mPop.authGroup, "auth clear text" ); @@ -891,7 +891,7 @@ void AccountDialog::makeImapAccountPage( bool connected ) label = new TQLabel( i18n("&Port:"), page1 ); grid->addWidget( label, row, 0 ); mImap.portEdit = new KLineEdit( page1 ); - mImap.portEdit->setValidator( new TQIntValidator(this) ); + mImap.portEdit->setValidator( new TQIntValidator(TQT_TQOBJECT(this)) ); label->setBuddy( mImap.portEdit ); grid->addWidget( mImap.portEdit, row, 1 ); @@ -1093,7 +1093,7 @@ void AccountDialog::makeImapAccountPage( bool connected ) vlay->addSpacing( KDialog::spacingHint() ); - mImap.encryptionGroup = new TQButtonGroup( 1, TQt::Horizontal, + mImap.encryptionGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Encryption"), page2 ); mImap.encryptionNone = new TQRadioButton( i18n("&None"), mImap.encryptionGroup ); @@ -1107,7 +1107,7 @@ void AccountDialog::makeImapAccountPage( bool connected ) TQT_SLOT(slotImapEncryptionChanged(int))); vlay->addWidget( mImap.encryptionGroup ); - mImap.authGroup = new TQButtonGroup( 1, TQt::Horizontal, + mImap.authGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Authentication Method"), page2 ); mImap.authUser = new TQRadioButton( i18n("Clear te&xt"), mImap.authGroup ); mImap.authLogin = new TQRadioButton( i18n("Please translate this " @@ -1191,7 +1191,7 @@ void AccountDialog::setupSettings() mPop.loginEdit->setText( ap.login() ); mPop.passwordEdit->setText( ap.passwd()); mPop.hostEdit->setText( ap.host() ); - mPop.portEdit->setText( TQString("%1").arg( ap.port() ) ); + mPop.portEdit->setText( TQString("%1").tqarg( ap.port() ) ); mPop.usePipeliningCheck->setChecked( ap.usePipelining() ); mPop.storePasswordCheck->setChecked( ap.storePasswd() ); mPop.leaveOnServerCheck->setChecked( ap.leaveOnServer() ); @@ -1256,7 +1256,7 @@ void AccountDialog::setupSettings() mImap.loginEdit->setText( ai.login() ); mImap.passwordEdit->setText( ai.passwd()); mImap.hostEdit->setText( ai.host() ); - mImap.portEdit->setText( TQString("%1").arg( ai.port() ) ); + mImap.portEdit->setText( TQString("%1").tqarg( ai.port() ) ); mImap.autoExpungeCheck->setChecked( ai.autoExpunge() ); mImap.hiddenFoldersCheck->setChecked( ai.hiddenFolders() ); mImap.subscribedFoldersCheck->setChecked( ai.onlySubscribedFolders() ); @@ -1309,7 +1309,7 @@ void AccountDialog::setupSettings() mImap.loginEdit->setText( ai.login() ); mImap.passwordEdit->setText( ai.passwd()); mImap.hostEdit->setText( ai.host() ); - mImap.portEdit->setText( TQString("%1").arg( ai.port() ) ); + mImap.portEdit->setText( TQString("%1").tqarg( ai.port() ) ); #if 0 mImap.resourceCheck->setChecked( ai.resource() ); #endif @@ -2293,7 +2293,7 @@ NamespaceEditDialog::NamespaceEditDialog( TQWidget *tqparent, } else { ns = i18n("Shared"); } - setCaption( i18n("Edit Namespace '%1'").arg(ns) ); + setCaption( i18n("Edit Namespace '%1'").tqarg(ns) ); TQGrid* grid = new TQGrid( 2, page ); mBg = new TQButtonGroup( 0 ); diff --git a/kmail/accountmanager.cpp b/kmail/accountmanager.cpp index d62280fd1..40d95b296 100644 --- a/kmail/accountmanager.cpp +++ b/kmail/accountmanager.cpp @@ -100,7 +100,7 @@ void AccountManager::readConfig(void) acctType = "pop"; acctName = config->readEntry("Name"); id = config->readUnsignedNumEntry("Id", 0); - if (acctName.isEmpty()) acctName = i18n("Account %1").arg(i); + if (acctName.isEmpty()) acctName = i18n("Account %1").tqarg(i); acct = create(acctType, acctName, id); if (!acct) continue; add(acct); @@ -183,7 +183,7 @@ void AccountManager::processNextCheck( bool _newMail ) TQString tmp = i18n("Account %1 has no mailbox defined:\n" "mail checking aborted;\n" "check your account settings.") - .arg(curAccount->name()); + .tqarg(curAccount->name()); KMessageBox::information(0,tmp); emit checkedMail( false, mInteractive, mTotalNewInFolder ); mTotalNewMailsArrived = 0; @@ -223,7 +223,7 @@ void AccountManager::processNextCheck( bool _newMail ) this, TQT_SLOT( processNextCheck( bool ) ) ); KPIM::BroadcastqStatus::instance()->seStatusMsg( - i18n("Checking account %1 for new mail").arg(curAccount->name())); + i18n("Checking account %1 for new mail").tqarg(curAccount->name())); kdDebug(5006) << "processing next mail check for " << curAccount->name() << endl; diff --git a/kmail/accountwizard.cpp b/kmail/accountwizard.cpp index e4e8b8334..0ae07d6c1 100644 --- a/kmail/accountwizard.cpp +++ b/kmail/accountwizard.cpp @@ -516,7 +516,7 @@ void AccountWizard::checkPopCapabilities( const TQString &server, int port ) connect( mServerTest, TQT_SIGNAL( capabilities( const TQStringList&, const TQStringList& ) ), this, TQT_SLOT( popCapabilities( const TQStringList&, const TQStringList& ) ) ); - mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).arg( server ) ); + mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).tqarg( server ) ); } void AccountWizard::checkImapCapabilities( const TQString &server, int port ) @@ -527,7 +527,7 @@ void AccountWizard::checkImapCapabilities( const TQString &server, int port ) connect( mServerTest, TQT_SIGNAL( capabilities( const TQStringList&, const TQStringList& ) ), this, TQT_SLOT( imapCapabilities( const TQStringList&, const TQStringList& ) ) ); - mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).arg( server ) ); + mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).tqarg( server ) ); } void AccountWizard::checkSmtpCapabilities( const TQString &server, int port ) @@ -540,7 +540,7 @@ void AccountWizard::checkSmtpCapabilities( const TQString &server, int port ) this, TQT_SLOT( smtpCapabilities( const TQStringList&, const TQStringList&, const TQString&, const TQString&, const TQString& ) ) ); - mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).arg( server ) ); + mAuthInfoLabel = createInfoLabel( i18n( "Check for supported security capabilities of %1..." ).tqarg( server ) ); } void AccountWizard::popCapabilities( const TQStringList &capaNormalList, @@ -652,7 +652,7 @@ void AccountWizard::smtpCapabilities( const TQStringList &capaNormal, if ( authNone.isEmpty() && authSSL.isEmpty() && authTLS.isEmpty() ) { // slave doesn't seem to support "* AUTH METHODS" metadata (or server can't do AUTH) authBitsNone = authMethodsFromStringList( capaNormal ); - if ( capaNormal.findIndex( "STARTTLS" ) != -1 ) + if ( capaNormal.tqfindIndex( "STARTTLS" ) != -1 ) authBitsTLS = authBitsNone; else authBitsTLS = 0; @@ -664,7 +664,7 @@ void AccountWizard::smtpCapabilities( const TQStringList &capaNormal, } uint authBits = 0; - if ( capaNormal.findIndex( "STARTTLS" ) != -1 ) { + if ( capaNormal.tqfindIndex( "STARTTLS" ) != -1 ) { mTransportInfo->encryption = "TLS"; authBits = authBitsTLS; } else if ( !capaSSL.isEmpty() ) { diff --git a/kmail/actionscheduler.cpp b/kmail/actionscheduler.cpp index 77685ee4b..3d1c86880 100644 --- a/kmail/actionscheduler.cpp +++ b/kmail/actionscheduler.cpp @@ -625,7 +625,7 @@ void ActionScheduler::actionMessage(KMFilterAction::ReturnCode res) if (msg) { if ( FilterLog::instance()->isLogging() ) { TQString logText( i18n( "<b>Applying filter action:</b> %1" ) - .arg( mFilterAction->displayString() ) ); + .tqarg( mFilterAction->displayString() ) ); FilterLog::instance()->add( logText, FilterLog::appliedAction ); } KMFilterAction *action = mFilterAction; @@ -786,19 +786,19 @@ TQString ActionScheduler::debug() TQValueList<ActionScheduler*>::iterator it; int i = 1; for ( it = schedulerList->begin(); it != schedulerList->end(); ++it ) { - res.append( TQString( "ActionScheduler #%1.\n" ).arg( i ) ); - if ((*it)->mAccount && kmkernel->tqfind( (*it)->mAccountId )) { + res.append( TQString( "ActionScheduler #%1.\n" ).tqarg( i ) ); + if ((*it)->mAccount && kmkernel->find( (*it)->mAccountId )) { res.append( TQString( "Account %1, Name %2.\n" ) - .arg( (*it)->mAccountId ) - .arg( kmkernel->acctMgr()->tqfind( (*it)->mAccountId )->name() ) ); + .tqarg( (*it)->mAccountId ) + .tqarg( kmkernel->acctMgr()->tqfind( (*it)->mAccountId )->name() ) ); } - res.append( TQString( "mExecuting %1, " ).arg( (*it)->mExecuting ? "true" : "false" ) ); - res.append( TQString( "mExecutingLock %1, " ).arg( (*it)->mExecutingLock ? "true" : "false" ) ); - res.append( TQString( "mFetchExecuting %1.\n" ).arg( (*it)->mFetchExecuting ? "true" : "false" ) ); - res.append( TQString( "mOriginalSerNum %1.\n" ).arg( (*it)->mOriginalSerNum ) ); - res.append( TQString( "mMessageIt %1.\n" ).arg( ((*it)->mMessageIt != 0) ? *(*it)->mMessageIt : 0 ) ); - res.append( TQString( "mSerNums count %1, " ).arg( (*it)->mSerNums.count() ) ); - res.append( TQString( "mFetchSerNums count %1.\n" ).arg( (*it)->mFetchSerNums.count() ) ); + res.append( TQString( "mExecuting %1, " ).tqarg( (*it)->mExecuting ? "true" : "false" ) ); + res.append( TQString( "mExecutingLock %1, " ).tqarg( (*it)->mExecutingLock ? "true" : "false" ) ); + res.append( TQString( "mFetchExecuting %1.\n" ).tqarg( (*it)->mFetchExecuting ? "true" : "false" ) ); + res.append( TQString( "mOriginalSerNum %1.\n" ).tqarg( (*it)->mOriginalSerNum ) ); + res.append( TQString( "mMessageIt %1.\n" ).tqarg( ((*it)->mMessageIt != 0) ? *(*it)->mMessageIt : 0 ) ); + res.append( TQString( "mSerNums count %1, " ).tqarg( (*it)->mSerNums.count() ) ); + res.append( TQString( "mFetchSerNums count %1.\n" ).tqarg( (*it)->mFetchSerNums.count() ) ); res.append( TQString( "mResult " ) ); if ((*it)->mResult == ResultOk) res.append( TQString( "ResultOk.\n" ) ); diff --git a/kmail/antispamconfig.cpp b/kmail/antispamconfig.cpp index 384752c24..19198e11a 100644 --- a/kmail/antispamconfig.cpp +++ b/kmail/antispamconfig.cpp @@ -59,7 +59,7 @@ void AntiSpamConfig::readConfig() KConfigGroup general( &config, "General" ); unsigned int totalTools = general.readUnsignedNumEntry( "tools", 0 ); for ( unsigned int i = 1; i <= totalTools; ++i ) { - KConfigGroup tool( &config, TQString("Spamtool #%1").arg( i ) ); + KConfigGroup tool( &config, TQString("Spamtool #%1").tqarg( i ) ); if ( tool.hasKey( "ScoreHeader" ) ) { TQString name = tool.readEntry( "ScoreName" ); TQCString header = tool.readEntry( "ScoreHeader" ).latin1(); diff --git a/kmail/antispamwizard.cpp b/kmail/antispamwizard.cpp index af32ec486..1e5e912b8 100644 --- a/kmail/antispamwizard.cpp +++ b/kmail/antispamwizard.cpp @@ -495,7 +495,7 @@ void AntiSpamWizard::checkToolAvailability() bool found = false; for ( TQValueListIterator<SpamToolConfig> it = mToolList.begin(); it != mToolList.end(); ++it ) { - TQString text( i18n("Scanning for %1...").arg( (*it).getId() ) ); + TQString text( i18n("Scanning for %1...").tqarg( (*it).getId() ) ); mInfoPage->setScanProgressText( text ); if ( (*it).isSpamTool() && (*it).isServerBased() ) { // check the configured account for pattern in <server> @@ -517,7 +517,7 @@ void AntiSpamWizard::checkToolAvailability() } else { // check the availability of the application - KApplication::kApplication()->processEvents( 200 ); + KApplication::kApplication()->tqprocessEvents( 200 ); if ( !checkForProgram( (*it).getExecutable() ) ) { mInfoPage->addAvailableTool( (*it).getVisibleName() ); found = true; @@ -702,7 +702,7 @@ void AntiSpamWizard::ConfigReader::readAndMergeConfig() int registeredTools = general.readNumEntry( "tools", 0 ); for (int i = 1; i <= registeredTools; i++) { - KConfigGroup toolConfig( mConfig, groupName.arg( i ) ); + KConfigGroup toolConfig( mConfig, groupName.tqarg( i ) ); if( !toolConfig.readBoolEntry( "HeadersOnly", false ) ) mToolList.append( readToolConfig( toolConfig ) ); } @@ -714,7 +714,7 @@ void AntiSpamWizard::ConfigReader::readAndMergeConfig() int user_registeredTools = user_general.readNumEntry( "tools", 0 ); for (int i = 1; i <= user_registeredTools; i++) { - KConfigGroup toolConfig( mConfig, groupName.arg( i ) ); + KConfigGroup toolConfig( mConfig, groupName.tqarg( i ) ); if( !toolConfig.readBoolEntry( "HeadersOnly", false ) ) mergeToolConfig( readToolConfig( toolConfig ) ); } @@ -925,7 +925,7 @@ void ASWizInfoPage::addAvailableTool( const TQString &visibleName ) bool ASWizInfoPage::isProgramSelected( const TQString &visibleName ) { TQString listName = visibleName; - return mToolsList->isSelected( mToolsList->findItem( listName ) ); + return mToolsList->isSelected( mToolsList->tqfindItem( listName ) ); } diff --git a/kmail/archivefolderdialog.cpp b/kmail/archivefolderdialog.cpp index ca10bd449..b1422f476 100644 --- a/kmail/archivefolderdialog.cpp +++ b/kmail/archivefolderdialog.cpp @@ -46,7 +46,7 @@ static TQString standardArchivePath( const TQString &folderName ) } return currentPath + i18n( "Start of the filename for a mail archive file" , "Archive" ) + "_" + folderName + - "_" + TQDate::tqcurrentDate().toString( TQt::ISODate ) + ".tar.bz2"; + "_" + TQDate::tqcurrentDate().toString( Qt::ISODate ) + ".tar.bz2"; } ArchiveFolderDialog::ArchiveFolderDialog( TQWidget *tqparent ) @@ -194,7 +194,7 @@ void ArchiveFolderDialog::slotFixFileExtension() // First, try to find the extension of the file name and remove it for( int i = 0; i < numExtensions; i++ ) { - int index = fileName.lower().findRev( sortedExtensions[i] ); + int index = fileName.lower().tqfindRev( sortedExtensions[i] ); if ( index != -1 ) { fileName = fileName.left( fileName.length() - TQString( sortedExtensions[i] ).length() ); break; diff --git a/kmail/backupjob.cpp b/kmail/backupjob.cpp index 3953f3bcf..e3a2ac0dd 100644 --- a/kmail/backupjob.cpp +++ b/kmail/backupjob.cpp @@ -148,7 +148,7 @@ void BackupJob::abort( const TQString &errorMessage ) // The progressmanager will delete it } - TQString text = i18n( "Failed to archive the folder '%1'." ).arg( mRootFolder->name() ); + TQString text = i18n( "Failed to archive the folder '%1'." ).tqarg( mRootFolder->name() ); text += "\n" + errorMessage; KMessageBox::sorry( mParentWidget, text, i18n( "Archiving failed." ) ); deleteLater(); @@ -172,12 +172,12 @@ void BackupJob::finish() TQFileInfo archiveFileInfo( mMailArchivePath.path() ); TQString text = i18n( "Archiving folder '%1' successfully completed. " "The archive was written to the file '%2'." ) - .arg( mRootFolder->name() ).arg( mMailArchivePath.path() ); + .tqarg( mRootFolder->name() ).tqarg( mMailArchivePath.path() ); text += "\n" + i18n( "1 message of size %1 was archived.", "%n messages with the total size of %1 were archived.", mArchivedMessages ) - .arg( KIO::convertSize( mArchivedSize ) ); + .tqarg( KIO::convertSize( mArchivedSize ) ); text += "\n" + i18n( "The archive file has a size of %1." ) - .arg( KIO::convertSize( archiveFileInfo.size() ) ); + .tqarg( KIO::convertSize( archiveFileInfo.size() ) ); KMessageBox::information( mParentWidget, text, i18n( "Archiving finished." ) ); if ( mDeleteFoldersAfterCompletion ) { @@ -213,7 +213,7 @@ void BackupJob::archiveNextMessage() KMMsgDict::instance()->getLocation( serNum, &folder, &mMessageIndex ); if ( mMessageIndex == -1 ) { kdWarning(5006) << "Failed to get message location for sernum " << serNum << endl; - abort( i18n( "Unable to retrieve a message for folder '%1'." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Unable to retrieve a message for folder '%1'." ).tqarg( mCurrentFolder->name() ) ); return; } @@ -223,7 +223,7 @@ void BackupJob::archiveNextMessage() KMMessage *message = mCurrentFolder->getMsg( mMessageIndex ); if ( !message ) { kdWarning(5006) << "Failed to retrieve message with index " << mMessageIndex << endl; - abort( i18n( "Unable to retrieve a message for folder '%1'." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Unable to retrieve a message for folder '%1'." ).tqarg( mCurrentFolder->name() ) ); return; } @@ -249,7 +249,7 @@ void BackupJob::archiveNextMessage() kdWarning(5006) << "Message with subject " << mCurrentMessage->subject() << " is neither complete nor has a tqparent!" << endl; abort( i18n( "Internal error while trying to retrieve a message from folder '%1'." ) - .arg( mCurrentFolder->name() ) ); + .tqarg( mCurrentFolder->name() ) ); } mProgressItem->setProgress( ( mProgressItem->progress() + 5 ) ); @@ -318,7 +318,7 @@ void BackupJob::processCurrentMessage() if ( !mArchive->writeFile( fileName, user, group, messageSize, permissions, accessTime, modificationTime, creationTime, messageString ) ) { - abort( i18n( "Failed to write a message into the archive folder '%1'." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Failed to write a message into the archive folder '%1'." ).tqarg( mCurrentFolder->name() ) ); return; } @@ -357,7 +357,7 @@ void BackupJob::folderJobFinished( KMail::FolderJob *job ) if ( job->error() ) { if ( mCurrentFolder ) - abort( i18n( "Downloading a message in folder '%1' failed." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Downloading a message in folder '%1' failed." ).tqarg( mCurrentFolder->name() ) ); else abort( i18n( "Downloading a message in the current folder failed." ) ); } @@ -388,9 +388,9 @@ void BackupJob::archiveNextFolder() mCurrentFolder = mPendingFolders.take( 0 ); kdDebug(5006) << "===> Archiving next folder: " << mCurrentFolder->name() << endl; - mProgressItem->setqStatus( i18n( "Archiving folder %1" ).arg( mCurrentFolder->name() ) ); + mProgressItem->setqStatus( i18n( "Archiving folder %1" ).tqarg( mCurrentFolder->name() ) ); if ( mCurrentFolder->open( "BackupJob" ) != 0 ) { - abort( i18n( "Unable to open folder '%1'.").arg( mCurrentFolder->name() ) ); + abort( i18n( "Unable to open folder '%1'.").tqarg( mCurrentFolder->name() ) ); return; } mCurrentFolderOpen = true; @@ -411,7 +411,7 @@ void BackupJob::archiveNextFolder() success = false; if ( !success ) { abort( i18n( "Unable to create folder structure for folder '%1' within archive file." ) - .arg( mCurrentFolder->name() ) ); + .tqarg( mCurrentFolder->name() ) ); return; } @@ -423,7 +423,7 @@ void BackupJob::archiveNextFolder() << " at index " << i << "!" << endl; // TODO: handle error in a nicer way. this is _very_ bad abort( i18n( "Unable to backup messages in folder '%1', the index file is corrupted." ) - .arg( mCurrentFolder->name() ) ); + .tqarg( mCurrentFolder->name() ) ); return; } else diff --git a/kmail/bodypartformatterfactory.cpp b/kmail/bodypartformatterfactory.cpp index f11690d52..5f6feea7e 100644 --- a/kmail/bodypartformatterfactory.cpp +++ b/kmail/bodypartformatterfactory.cpp @@ -83,7 +83,7 @@ static void insertBodyPartFormatter( const char * type, const char * subtype, if ( !type || !*type || !subtype || !*subtype || !formatter || !all ) return; - TypeRegistry::iterator type_it = all->tqfind( type ); + TypeRegistry::iterator type_it = all->find( type ); if ( type_it == all->end() ) { kdDebug( 5006 ) << "BodyPartFormatterFactory: instantiating new Subtype Registry for \"" << type << "\"" << endl; @@ -92,7 +92,7 @@ static void insertBodyPartFormatter( const char * type, const char * subtype, } SubtypeRegistry & subtype_reg = type_it->second; - SubtypeRegistry::iterator subtype_it = subtype_reg.tqfind( subtype ); + SubtypeRegistry::iterator subtype_it = subtype_reg.find( subtype ); if ( subtype_it != subtype_reg.end() ) { kdDebug( 5006 ) << "BodyPartFormatterFactory: overwriting previously registered formatter for \"" << type << "/" << subtype << "\"" << endl; @@ -159,9 +159,9 @@ const KMail::Interface::BodyPartFormatter * KMail::BodyPartFormatterFactory::cre if ( all->empty() ) return 0; - TypeRegistry::const_iterator type_it = all->tqfind( type ); + TypeRegistry::const_iterator type_it = all->find( type ); if ( type_it == all->end() ) - type_it = all->tqfind( "*" ); + type_it = all->find( "*" ); if ( type_it == all->end() ) return 0; @@ -169,9 +169,9 @@ const KMail::Interface::BodyPartFormatter * KMail::BodyPartFormatterFactory::cre if ( subtype_reg.empty() ) return 0; - SubtypeRegistry::const_iterator subtype_it = subtype_reg.tqfind( subtype ); + SubtypeRegistry::const_iterator subtype_it = subtype_reg.find( subtype ); if ( subtype_it == subtype_reg.end() ) - subtype_it = subtype_reg.tqfind( "*" ); + subtype_it = subtype_reg.find( "*" ); if ( subtype_it == subtype_reg.end() ) return 0; diff --git a/kmail/cachedimapjob.cpp b/kmail/cachedimapjob.cpp index 2b9ab2a8e..ca95344c7 100644 --- a/kmail/cachedimapjob.cpp +++ b/kmail/cachedimapjob.cpp @@ -234,7 +234,7 @@ void CachedImapJob::slotDeleteNextMessages( KIO::Job* job ) KURL url = mAccount->getUrl(); url.setPath( mFolder->imapPath() + - TQString::tqfromLatin1(";UID=%1").arg(uids) ); + TQString::tqfromLatin1(";UID=%1").tqarg(uids) ); KIO::SimpleJob *simpleJob = KIO::file_delete( url, false ); KIO::Scheduler::assignJobToSlave( mAccount->slave(), simpleJob ); @@ -341,7 +341,7 @@ void CachedImapJob::slotGetNextMessage(KIO::Job * job) if( mfd.flags > 0 ) KMFolderImap::flagsTotqStatus(mMsg, mfd.flags, true, GlobalSettings::allowLocalFlags() ? mFolder->permanentFlags() : INT_MAX); KURL url = mAccount->getUrl(); - url.setPath(mFolder->imapPath() + TQString(";UID=%1;SECTION=BODY.PEEK[]").arg(mfd.uid)); + url.setPath(mFolder->imapPath() + TQString(";UID=%1;SECTION=BODY.PEEK[]").tqarg(mfd.uid)); ImapAccountBase::jobData jd( url.url(), mFolder->folder() ); jd.cancellable = true; @@ -408,10 +408,10 @@ void CachedImapJob::slotPutNextMessage() unsigned int i = 0; for( char *ch = cstr.data(); *ch; ch++ ) { if ( *ch == '\n' ) { - mData.at(i) = '\r'; + mData.tqat(i) = '\r'; i++; } - mData.at(i) = *ch; i++; + mData.tqat(i) = *ch; i++; } jd.data = mData; jd.msgList.append( mMsg ); @@ -539,7 +539,7 @@ void CachedImapJob::slotAddNextSubfolder( KIO::Job * job ) if ( job->error() && !silentUpload ) { TQString myError = "<p><b>" + i18n("Error while uploading folder") - + "</b></p><p>" + i18n("Could not make the folder <b>%1</b> on the server.").arg((*it).items[0]) + + "</b></p><p>" + i18n("Could not make the folder <b>%1</b> on the server.").tqarg((*it).items[0]) + "</p><p>" + i18n("This could be because you do not have permission to do this, or because the folder is already present on the server; the error message from the server communication is here:") + "</p>"; mAccount->handleJobError( job, myError ); } @@ -597,8 +597,8 @@ void CachedImapJob::slotAddNextSubfolder( KIO::Job * job ) TQDataStream stream( packedArgs, IO_WriteOnly ); const TQString command = TQString( "X-CREATE-SPECIAL" ); - const TQString argument = TQString( "%1 %2" ).arg( Scalix::Utils::contentsTypeToScalixId( folder->contentsType() ) ) - .arg( path ); + const TQString argument = TQString( "%1 %2" ).tqarg( Scalix::Utils::contentsTypeToScalixId( folder->contentsType() ) ) + .tqarg( path ); stream << (int) 'X' << 'N' << command << argument; @@ -626,7 +626,7 @@ void CachedImapJob::slotDeleteNextFolder( KIO::Job *job ) mAccount->removeDeletedFolder( (*it).path ); if( job->error() ) { - mAccount->handleJobError( job, i18n( "Error while deleting folder %1 on the server: " ).arg( (*it).path ) + '\n' ); + mAccount->handleJobError( job, i18n( "Error while deleting folder %1 on the server: " ).tqarg( (*it).path ) + '\n' ); delete this; return; } @@ -679,7 +679,7 @@ void CachedImapJob::slotCheckUidValidityResult(KIO::Job * job) if( job->error() ) { mErrorCode = job->error(); - mAccount->handleJobError( job, i18n( "Error while reading folder %1 on the server: " ).arg( (*it).tqparent->label() ) + '\n' ); + mAccount->handleJobError( job, i18n( "Error while reading folder %1 on the server: " ).tqarg( (*it).tqparent->label() ) + '\n' ); delete this; return; } @@ -813,7 +813,7 @@ void CachedImapJob::slotSubscribtionChange1Failed( const TQString &errorMessage "from the folder list after the next sync since it is unsubscribed on the server.\n" "You can try to manually subscribe to the folder yourself.\n\n" "%2" ) - .arg( mFolder->label() ).arg( errorMessage ) ); + .tqarg( mFolder->label() ).tqarg( errorMessage ) ); delete this; } @@ -854,7 +854,7 @@ void CachedImapJob::slotRenameFolderResult( KIO::Job *job ) if( job->error() ) { revertLabelChange(); - const TQString errorMessage = i18n( "Error while trying to rename folder %1" ).arg( mFolder->label() ); + const TQString errorMessage = i18n( "Error while trying to rename folder %1" ).tqarg( mFolder->label() ); mAccount->handleJobError( job, errorMessage ); delete this; } else { diff --git a/kmail/callback.cpp b/kmail/callback.cpp index 037f80900..923ff6be3 100644 --- a/kmail/callback.cpp +++ b/kmail/callback.cpp @@ -64,7 +64,7 @@ TQString Callback::askForTransport( bool nullIdentity ) const return transports.first(); const TQString defaultTransport = GlobalSettings::self()->defaultTransport(); - const int defaultIndex = TQMAX( 0, transports.findIndex( defaultTransport ) ); + const int defaultIndex = TQMAX( 0, transports.tqfindIndex( defaultTransport ) ); TQString text; if ( nullIdentity ) @@ -94,13 +94,13 @@ bool Callback::mailICal( const TQString& to, const TQString &iCal, msg->setSubject( subject ); if ( GlobalSettings::self()->exchangeCompatibleInvitations() ) { if ( status == TQString("cancel") ) - msg->setSubject( i18n( "Declined: %1" ).arg(subject).tqreplace("Answer: ","") ); + msg->setSubject( i18n( "Declined: %1" ).tqarg(subject).tqreplace("Answer: ","") ); else if ( status == TQString("tentative") ) - msg->setSubject( i18n( "Tentative: %1" ).arg(subject).tqreplace("Answer: ","") ); + msg->setSubject( i18n( "Tentative: %1" ).tqarg(subject).tqreplace("Answer: ","") ); else if ( status == TQString("accepted") ) - msg->setSubject( i18n( "Accepted: %1" ).arg(subject).tqreplace("Answer: ","") ); + msg->setSubject( i18n( "Accepted: %1" ).tqarg(subject).tqreplace("Answer: ","") ); else if ( status == TQString("delegated") ) - msg->setSubject( i18n( "Delegated: %1" ).arg(subject).tqreplace("Answer: ","") ); + msg->setSubject( i18n( "Delegated: %1" ).tqarg(subject).tqreplace("Answer: ","") ); } msg->setTo( to ); msg->setFrom( receiver() ); @@ -227,7 +227,7 @@ TQString Callback::receiver() const // select default identity by default const TQString defaultAddr = kmkernel->identityManager()->defaultIdentity().primaryEmailAddress(); - const int defaultIndex = TQMAX( 0, addrs.findIndex( defaultAddr ) ); + const int defaultIndex = TQMAX( 0, addrs.tqfindIndex( defaultAddr ) ); mReceiver = KInputDialog::getItem( i18n( "Select Address" ), diff --git a/kmail/chiasmuskeyselector.cpp b/kmail/chiasmuskeyselector.cpp index d88c3164b..9fde31bb9 100644 --- a/kmail/chiasmuskeyselector.cpp +++ b/kmail/chiasmuskeyselector.cpp @@ -21,7 +21,7 @@ ChiasmusKeySelector::ChiasmusKeySelector( TQWidget* tqparent, const TQString& ca mListBox = new KListBox( page ); mListBox->insertStringList( keys ); - const int current = keys.findIndex( currentKey ); + const int current = keys.tqfindIndex( currentKey ); mListBox->setSelected( TQMAX( 0, current ), true ); mListBox->ensureCurrentVisible(); tqlayout->addWidget( mListBox, 1 ); diff --git a/kmail/compactionjob.cpp b/kmail/compactionjob.cpp index 3d3dd6acc..5de762e96 100644 --- a/kmail/compactionjob.cpp +++ b/kmail/compactionjob.cpp @@ -96,7 +96,7 @@ int MboxCompactionJob::executeNow( bool silent ) if (!storage->compactable()) { kdDebug(5006) << storage->location() << " compaction skipped." << endl; if ( !mSilent ) { - TQString str = i18n( "For safety reasons, compaction has been disabled for %1" ).arg( mbox->label() ); + TQString str = i18n( "For safety reasons, compaction has been disabled for %1" ).tqarg( mbox->label() ); BroadcastqStatus::instance()->seStatusMsg( str ); } return 0; @@ -173,11 +173,11 @@ void MboxCompactionJob::done( int rc ) mbox->close("mboxcompact", true); mbox->setAutoCreateIndex( autoCreate ); mbox->setNeedsCompacting( false ); // We are clean now - str = i18n( "Folder \"%1\" successfully compacted" ).arg( mSrcFolder->label() ); + str = i18n( "Folder \"%1\" successfully compacted" ).tqarg( mSrcFolder->label() ); kdDebug(5006) << str << endl; } else { mbox->close("mboxcompact"); - str = i18n( "Error occurred while compacting \"%1\". Compaction aborted." ).arg( mSrcFolder->label() ); + str = i18n( "Error occurred while compacting \"%1\". Compaction aborted." ).tqarg( mSrcFolder->label() ); kdDebug(5006) << "Error occurred while compacting " << mbox->location() << endl; kdDebug(5006) << "Compaction aborted." << endl; TQFile::remove( mTempName ); @@ -256,9 +256,9 @@ void MaildirCompactionJob::done( int rc ) mCancellable = false; TQString str; if ( !rc ) { - str = i18n( "Folder \"%1\" successfully compacted" ).arg( mSrcFolder->label() ); + str = i18n( "Folder \"%1\" successfully compacted" ).tqarg( mSrcFolder->label() ); } else { - str = i18n( "Error occurred while compacting \"%1\". Compaction aborted." ).arg( mSrcFolder->label() ); + str = i18n( "Error occurred while compacting \"%1\". Compaction aborted." ).tqarg( mSrcFolder->label() ); } mErrorCode = rc; storage->setNeedsCompacting( false ); diff --git a/kmail/configuredialog.cpp b/kmail/configuredialog.cpp index bc415a888..993c6c74f 100644 --- a/kmail/configuredialog.cpp +++ b/kmail/configuredialog.cpp @@ -451,7 +451,7 @@ void IdentityPage::slotRemoveIdentity() if ( !item ) return; TQString msg = i18n("<qt>Do you really want to remove the identity named " - "<b>%1</b>?</qt>").arg( item->identity().identityName() ); + "<b>%1</b>?</qt>").tqarg( item->identity().identityName() ); if( KMessageBox::warningContinueCancel( this, msg, i18n("Remove Identity"), KGuiItem(i18n("&Remove"),"editdelete") ) == KMessageBox::Continue ) if ( im->removeIdentity( item->identity().identityName() ) ) { @@ -649,7 +649,7 @@ AccountsPageSendingTab::AccountsPageSendingTab( TQWidget * tqparent, const char btn_vlay->addStretch( 1 ); // spacer // "Common options" groupbox: - group = new TQGroupBox( 0, TQt::Vertical, + group = new TQGroupBox( 0, Qt::Vertical, i18n("Common Options"), this ); vlay->addWidget(group); @@ -742,7 +742,7 @@ static inline TQString uniqueName( const TQStringList & list, while ( list.tqfind( result ) != list.end() ) { result = i18n("%1: name; %2: number appended to it to make it unique " "among a list of names", "%1 %2") - .arg( name ).arg( suffix ); + .tqarg( name ).tqarg( suffix ); suffix++; } return result; @@ -830,7 +830,7 @@ void AccountsPage::SendingTab::slotAddTransport() "Configure->Accounts->Sending listview, \"type\" " "column, first row, to indicate that this is the " "default transport", "%1 (Default)") - .arg( transportInfo->type ); + .tqarg( transportInfo->type ); GlobalSettings::self()->setDefaultTransport( transportInfo->name ); } (void) new TQListViewItem( mTransportList, lastItem, transportInfo->name, @@ -1364,7 +1364,7 @@ void AccountsPage::ReceivingTab::slotRemoveSelectedAccount() { if ( !acct ) { // ### FIXME: see above KMessageBox::sorry( this, i18n("<qt>Unable to locate account <b>%1</b>.</qt>") - .arg(listItem->text(0)) ); + .tqarg(listItem->text(0)) ); return; } @@ -1444,7 +1444,7 @@ void AccountsPage::ReceivingTab::save() { kmkernel->acctMgr()->writeConfig( true ); if ( (*it) && !kmkernel->acctMgr()->remove(*it) ) KMessageBox::sorry( this, i18n("<qt>Unable to locate account <b>%1</b>.</qt>") - .arg( (*it)->name() ) ); + .tqarg( (*it)->name() ) ); } mAccountsToDelete.clear(); @@ -1667,7 +1667,7 @@ void AppearancePage::FontsTab::installProfile( KConfig * profile ) { needChange = true; mFont[i] = fonts.readFontEntry( fontNames[i].configName ); kdDebug(5006) << "got font \"" << fontNames[i].configName - << "\" thusly: \"" << mFont[i].toString() << "\"" << endl; + << "\" thusly: \"" << TQString(mFont[i].toString()) << "\"" << endl; } if ( needChange && mFontLocationCombo->currentItem() > 0 ) mFontChooser->setFont( mFont[ mFontLocationCombo->currentItem() ], @@ -1793,9 +1793,9 @@ void AppearancePage::ColorsTab::doLoadOther() { mCloseToQuotaThreshold->setValue( GlobalSettings::closeToQuotaThreshold() ); static const TQColor defaultColor[ numColorNames ] = { - kapp->palette().active().base(), // bg + kapp->tqpalette().active().base(), // bg KGlobalSettings::alternateBackgroundColor(), // alt bg - kapp->palette().active().text(), // fg + kapp->tqpalette().active().text(), // fg TQColor( 0x00, 0x80, 0x00 ), // quoted l1 TQColor( 0x00, 0x70, 0x00 ), // quoted l2 TQColor( 0x00, 0x60, 0x00 ), // quoted l3 @@ -2058,7 +2058,7 @@ AppearancePageHeadersTab::AppearancePageHeadersTab( TQWidget * tqparent, const c for ( int i = 0 ; i < numDateDisplayConfig ; i++ ) { TQString buttonLabel = i18n(dateDisplayConfig[i].displayName); if ( buttonLabel.tqcontains("%1") ) - buttonLabel = buttonLabel.arg( DateFormatter::formatCurrentDate( dateDisplayConfig[i].dateDisplay ) ); + buttonLabel = buttonLabel.tqarg( DateFormatter::formatCurrentDate( dateDisplayConfig[i].dateDisplay ) ); radio = new TQRadioButton( buttonLabel, mDateDisplay ); mDateDisplay->insert( radio, i ); if ( dateDisplayConfig[i].dateDisplay == DateFormatter::Custom ) { @@ -3304,7 +3304,7 @@ void ComposerPage::CharsetTab::slotVerifyCharset( TQString & charset ) { if ( charset.lower() == TQString::tqfromLatin1("locale") ) { charset = TQString::tqfromLatin1("%1 (locale)") - .arg( TQCString( kmkernel->networkCodec()->mimeName() ).lower() ); + .tqarg( TQString( kmkernel->networkCodec()->mimeName() ).lower() ); return; } @@ -3328,7 +3328,7 @@ void ComposerPage::CharsetTab::doLoadOther() { if ( (*it) == TQString::tqfromLatin1("locale") ) { TQCString cset = kmkernel->networkCodec()->mimeName(); KPIM::kAsciiToLower( cset.data() ); - (*it) = TQString("%1 (locale)").arg( cset ); + (*it) = TQString("%1 (locale)").tqarg( TQString(cset) ); } mCharsetListEditor->setStringList( charsets ); @@ -3376,7 +3376,7 @@ ComposerPageHeadersTab::ComposerPageHeadersTab( TQWidget * tqparent, const char mMessageIdSuffixEdit = new KLineEdit( this ); // only ASCII letters, digits, plus, minus and dots are allowed mMessageIdSuffixValidator = - new TQRegExpValidator( TQRegExp( "[a-zA-Z0-9+-]+(?:\\.[a-zA-Z0-9+-]+)*" ), this ); + new TQRegExpValidator( TQRegExp( "[a-zA-Z0-9+-]+(?:\\.[a-zA-Z0-9+-]+)*" ), TQT_TQOBJECT(this) ); mMessageIdSuffixEdit->setValidator( mMessageIdSuffixValidator ); label = new TQLabel( mMessageIdSuffixEdit, i18n("Custom message-&id suffix:"), this ); @@ -3815,7 +3815,7 @@ SecurityPageGeneralTab::SecurityPageGeneralTab( TQWidget * tqparent, const char "exploits. <a href=\"whatsthis:%1\">More about " "HTML mails...</a> <a href=\"whatsthis:%2\">More " "about external references...</a>") - .arg(htmlWhatsThis).arg(externalWhatsThis), + .tqarg(htmlWhatsThis).tqarg(externalWhatsThis), group ); vlay->addWidget( group ); @@ -3890,7 +3890,7 @@ SecurityPageGeneralTab::SecurityPageGeneralTab( TQWidget * tqparent, const char label = new KActiveLabel( i18n("<b>WARNING:</b> Unconditionally returning " "confirmations undermines your privacy. " "<a href=\"whatsthis:%1\">More...</a>") - .arg(receiptWhatsThis), + .tqarg(receiptWhatsThis), group ); vlay->addWidget( group ); @@ -4358,7 +4358,7 @@ void SecurityPage::SMimeTab::doLoadOther() { TQString systemProxy = TQString::fromLocal8Bit( getenv( "http_proxy" ) ); if ( systemProxy.isEmpty() ) systemProxy = i18n( "no proxy" ); - mWidget->systemHTTPProxy->setText( i18n( "(Current system setting: %1)" ).arg( systemProxy ) ); + mWidget->systemHTTPProxy->setText( i18n( "(Current system setting: %1)" ).tqarg( systemProxy ) ); bool honor = e.mHonorHTTPProxy && e.mHonorHTTPProxy->boolValue(); mWidget->honorHTTPProxyRB->setChecked( honor ); mWidget->useCustomHTTPProxyRB->setChecked( !honor ); @@ -4482,11 +4482,11 @@ Kleo::CryptoConfigEntry* SMIMECryptoConfigEntries::configEntry( const char* comp { Kleo::CryptoConfigEntry* entry = mConfig->entry( componentName, groupName, entryName ); if ( !entry ) { - kdWarning(5006) << TQString( "Backend error: gpgconf doesn't seem to know the entry for %1/%2/%3" ).arg( componentName, groupName, entryName ) << endl; + kdWarning(5006) << TQString( "Backend error: gpgconf doesn't seem to know the entry for %1/%2/%3" ).tqarg( componentName, groupName, entryName ) << endl; return 0; } if( entry->argType() != argType || entry->isList() != isList ) { - kdWarning(5006) << TQString( "Backend error: gpgconf has wrong type for %1/%2/%3: %4 %5" ).arg( componentName, groupName, entryName ).arg( entry->argType() ).arg( entry->isList() ) << endl; + kdWarning(5006) << TQString( "Backend error: gpgconf has wrong type for %1/%2/%3: %4 %5" ).tqarg( componentName, groupName, entryName ).tqarg( entry->argType() ).tqarg( entry->isList() ) << endl; return 0; } return entry; @@ -5135,7 +5135,7 @@ void MiscPage::GroupwareTab::save() { // Inbox folder of the selected account KMAccount* acct = mAccountCombo->currentAccount(); if ( acct ) { - folderId = TQString( ".%1.directory/INBOX" ).arg( acct->id() ); + folderId = TQString( ".%1.directory/INBOX" ).tqarg( acct->id() ); GlobalSettings::self()->setTheIMAPResourceAccount( acct->id() ); } } diff --git a/kmail/configuredialog_p.cpp b/kmail/configuredialog_p.cpp index ff473f668..098e90870 100644 --- a/kmail/configuredialog_p.cpp +++ b/kmail/configuredialog_p.cpp @@ -225,7 +225,7 @@ NewLanguageDialog::NewLanguageDialog( LanguageItemList & suppressedLangs, if ( suppressedAcronyms.tqfind( acronym ) == suppressedAcronyms.end() ) { // not found: TQString displayname = TQString::tqfromLatin1("%1 (%2)") - .arg( name ).arg( acronym ); + .tqarg( name ).tqarg( acronym ); TQPixmap flag( locate("locale", acronym + flagPng ) ); mComboBox->insertItem( flag, displayname ); } @@ -239,7 +239,7 @@ NewLanguageDialog::NewLanguageDialog( LanguageItemList & suppressedLangs, TQString NewLanguageDialog::language() const { TQString s = mComboBox->currentText(); - int i = s.findRev( '(' ); + int i = s.tqfindRev( '(' ); return s.mid( i + 1, s.length() - i - 2 ); } @@ -255,21 +255,21 @@ int LanguageComboBox::insertLanguage( const TQString & language ) KSimpleConfig entry( locate("locale", language + entryDesktop) ); entry.setGroup( "KCM Locale" ); TQString name = entry.readEntry( "Name" ); - TQString output = TQString::tqfromLatin1("%1 (%2)").arg( name ).arg( language ); + TQString output = TQString::tqfromLatin1("%1 (%2)").tqarg( name ).tqarg( language ); insertItem( TQPixmap( locate("locale", language + flagPng ) ), output ); - return listBox()->index( listBox()->findItem(output) ); + return listBox()->index( listBox()->tqfindItem(output) ); } TQString LanguageComboBox::language() const { TQString s = currentText(); - int i = s.findRev( '(' ); + int i = s.tqfindRev( '(' ); return s.mid( i + 1, s.length() - i - 2 ); } void LanguageComboBox::setLanguage( const TQString & language ) { - TQString tqparenthizedLanguage = TQString::tqfromLatin1("(%1)").arg( language ); + TQString tqparenthizedLanguage = TQString::tqfromLatin1("(%1)").tqarg( language ); for (int i = 0; i < count(); i++) // ### FIXME: use .endWith(): if ( text(i).tqfind( tqparenthizedLanguage ) >= 0 ) { diff --git a/kmail/csshelper.cpp b/kmail/csshelper.cpp index 3fe2fd78b..86166dbc2 100644 --- a/kmail/csshelper.cpp +++ b/kmail/csshelper.cpp @@ -77,7 +77,7 @@ namespace KMail { TQFont defaultFont = mBodyFont; defaultFont.setItalic( true ); for ( int i = 0 ; i < 3 ; ++i ) { - const TQString key = TQString( "quote%1-font" ).arg( i+1 ); + const TQString key = TQString( "quote%1-font" ).tqarg( i+1 ); mQuoteFont[i] = fonts.readFontEntry( key, &defaultFont ); } } diff --git a/kmail/customtemplates.cpp b/kmail/customtemplates.cpp index ef3668df4..4f1684907 100644 --- a/kmail/customtemplates.cpp +++ b/kmail/customtemplates.cpp @@ -117,7 +117,7 @@ CustomTemplates::CustomTemplates( TQWidget *tqparent, const char *name ) "<i>Universal</i> which can be used for all kind of operations. " "You cannot bind keyboard shortcut to <i>Universal</i> templates.</p>" "</qt>" ); - mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).arg( help ) ); + mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).tqarg( help ) ); const TQString toToolTip = i18n( "Additional recipients of the message when forwarding" ); const TQString ccToolTip = i18n( "Additional recipients who get a copy of the message when forwarding" ); diff --git a/kmail/distributionlistdialog.cpp b/kmail/distributionlistdialog.cpp index 62b4fcee4..6ee1492a2 100644 --- a/kmail/distributionlistdialog.cpp +++ b/kmail/distributionlistdialog.cpp @@ -196,7 +196,7 @@ void DistributionListDialog::slotUser1() #endif KMessageBox::information( this, i18n( "<qt>Distribution list with the given name <b>%1</b> " - "already exists. Please select a different name.</qt>" ).arg( name ) ); + "already exists. Please select a different name.</qt>" ).tqarg( name ) ); return; } diff --git a/kmail/expirejob.cpp b/kmail/expirejob.cpp index 6d634d8f8..30ab9cd7d 100644 --- a/kmail/expirejob.cpp +++ b/kmail/expirejob.cpp @@ -162,7 +162,7 @@ void ExpireJob::done() moving = true; str = i18n( "Removing 1 old message from folder %1...", "Removing %n old messages from folder %1...", count ) - .arg( mSrcFolder->label() ); + .tqarg( mSrcFolder->label() ); } else { // Expire by moving mMoveToFolder = @@ -170,7 +170,7 @@ void ExpireJob::done() if ( !mMoveToFolder ) { str = i18n( "Cannot expire messages from folder %1: destination " "folder %2 not found" ) - .arg( mSrcFolder->label(), mSrcFolder->expireToFolderId() ); + .tqarg( mSrcFolder->label(), mSrcFolder->expireToFolderId() ); kdWarning(5006) << str << endl; } else { kdDebug(5006) << "ExpireJob: finished expiring in folder " @@ -185,7 +185,7 @@ void ExpireJob::done() str = i18n( "Moving 1 old message from folder %1 to folder %2...", "Moving %n old messages from folder %1 to folder %2...", count ) - .arg( mSrcFolder->label(), mMoveToFolder->label() ); + .tqarg( mSrcFolder->label(), mMoveToFolder->label() ); } } } @@ -213,34 +213,34 @@ void ExpireJob::slotMessagesMoved( KMCommand *command ) msg = i18n( "Removed 1 old message from folder %1.", "Removed %n old messages from folder %1.", mRemovedMsgs.count() ) - .arg( mSrcFolder->label() ); + .tqarg( mSrcFolder->label() ); } else { msg = i18n( "Moved 1 old message from folder %1 to folder %2.", "Moved %n old messages from folder %1 to folder %2.", mRemovedMsgs.count() ) - .arg( mSrcFolder->label(), mMoveToFolder->label() ); + .tqarg( mSrcFolder->label(), mMoveToFolder->label() ); } break; case KMCommand::Failed: if ( mSrcFolder->expireAction() == KMFolder::ExpireDelete ) { msg = i18n( "Removing old messages from folder %1 failed." ) - .arg( mSrcFolder->label() ); + .tqarg( mSrcFolder->label() ); } else { msg = i18n( "Moving old messages from folder %1 to folder %2 failed." ) - .arg( mSrcFolder->label(), mMoveToFolder->label() ); + .tqarg( mSrcFolder->label(), mMoveToFolder->label() ); } break; case KMCommand::Canceled: if ( mSrcFolder->expireAction() == KMFolder::ExpireDelete ) { msg = i18n( "Removing old messages from folder %1 was canceled." ) - .arg( mSrcFolder->label() ); + .tqarg( mSrcFolder->label() ); } else { msg = i18n( "Moving old messages from folder %1 to folder %2 was " "canceled." ) - .arg( mSrcFolder->label(), mMoveToFolder->label() ); + .tqarg( mSrcFolder->label(), mMoveToFolder->label() ); } default: ; } diff --git a/kmail/favoritefolderview.cpp b/kmail/favoritefolderview.cpp index 7176cdebb..5c5cfa66f 100644 --- a/kmail/favoritefolderview.cpp +++ b/kmail/favoritefolderview.cpp @@ -405,13 +405,13 @@ TQString FavoriteFolderView::prettyName(KMFolderTreeItem * fti) if ( fti->protocol() == KFolderTreeItem::Local || fti->protocol() == KFolderTreeItem::NONE ) { name = i18n( "Local Inbox" ); } else { - name = i18n( "Inbox of %1" ).arg( accountFti->text( 0 ) ); + name = i18n( "Inbox of %1" ).tqarg( accountFti->text( 0 ) ); } } else { if ( fti->protocol() != KFolderTreeItem::Local && fti->protocol() != KFolderTreeItem::NONE ) { - name = i18n( "%1 on %2" ).arg( fti->text( 0 ) ).arg( accountFti->text( 0 ) ); + name = i18n( "%1 on %2" ).tqarg( fti->text( 0 ) ).tqarg( accountFti->text( 0 ) ); } else { - name = i18n( "%1 (local)" ).arg( fti->text( 0 ) ); + name = i18n( "%1 (local)" ).tqarg( fti->text( 0 ) ); } } return name; diff --git a/kmail/filehtmlwriter.cpp b/kmail/filehtmlwriter.cpp index 479e6d3e2..c4f2d214e 100644 --- a/kmail/filehtmlwriter.cpp +++ b/kmail/filehtmlwriter.cpp @@ -96,7 +96,7 @@ namespace KMail { if ( !mFile.open( IO_WriteOnly ) ) kdWarning( 5006 ) << "FileHtmlWriter: Cannot open file " << mFile.name() << endl; else - mStream.setDevice( &mFile ); + mStream.setDevice( &TQT_TQIODEVICE_OBJECT(mFile) ); } void FileHtmlWriter::embedPart( const TQCString & contentId, const TQString & url ) { diff --git a/kmail/filterlogdlg.cpp b/kmail/filterlogdlg.cpp index 441390fb5..c387b2e16 100644 --- a/kmail/filterlogdlg.cpp +++ b/kmail/filterlogdlg.cpp @@ -257,7 +257,7 @@ void FilterLogDialog::slotUser2() KMessageBox::error( this, i18n( "Could not write the file %1:\n" "\"%2\" is the detailed error description." ) - .arg( fileName, + .tqarg( fileName, TQString::fromLocal8Bit( strerror( errno ) ) ), i18n( "KMail Error" ) ); } diff --git a/kmail/folderdiaacltab.cpp b/kmail/folderdiaacltab.cpp index 90903fdb1..c850cf2ec 100644 --- a/kmail/folderdiaacltab.cpp +++ b/kmail/folderdiaacltab.cpp @@ -244,7 +244,7 @@ static TQString permissionsToUserString( unsigned int permissions, const TQStrin if ( internalRightsList.isEmpty() ) return i18n( "Custom Permissions" ); // not very helpful, but shouldn't happen else - return i18n( "Custom Permissions (%1)" ).arg( internalRightsList ); + return i18n( "Custom Permissions (%1)" ).tqarg( internalRightsList ); } void KMail::FolderDiaACLTab::ListViewItem::setPermissions( unsigned int permissions ) @@ -453,7 +453,7 @@ void KMail::FolderDiaACLTab::load() KMFolder* folder = mDlg->folder() ? mDlg->folder() : mDlg->tqparentFolder(); if ( folder && folder->storage() == mImapAccount->rootFolder() ) return; // nothing to be done for the (virtual) account folder - mLabel->setText( i18n( "Connecting to server %1, please wait..." ).arg( mImapAccount->host() ) ); + mLabel->setText( i18n( "Connecting to server %1, please wait..." ).tqarg( mImapAccount->host() ) ); ImapAccountBase::ConnectionState state = mImapAccount->makeConnection(); if ( state == ImapAccountBase::Error ) { // Cancelled by user, or slave can't start slotConnectionResult( -1, TQString() ); @@ -471,7 +471,7 @@ void KMail::FolderDiaACLTab::slotConnectionResult( int errorCode, const TQString this, TQT_SLOT( slotConnectionResult(int, const TQString&) ) ); if ( errorCode ) { if ( errorCode == -1 ) // unspecified error - mLabel->setText( i18n( "Error connecting to server %1" ).arg( mImapAccount->host() ) ); + mLabel->setText( i18n( "Error connecting to server %1" ).tqarg( mImapAccount->host() ) ); else // Connection error (error message box already shown by the account) mLabel->setText( KIO::buildErrorString( errorCode, errorMsg ) ); @@ -521,7 +521,7 @@ void KMail::FolderDiaACLTab::slotReceivedACL( KMFolder* folder, KIO::Job* job, c if ( job->error() == KIO::ERR_UNSUPPORTED_ACTION ) mLabel->setText( i18n( "This IMAP server does not have support for access control lists (ACL)" ) ); else - mLabel->setText( i18n( "Error retrieving access control list (ACL) from server\n%1" ).arg( job->errorString() ) ); + mLabel->setText( i18n( "Error retrieving access control list (ACL) from server\n%1" ).tqarg( job->errorString() ) ); return; } diff --git a/kmail/folderdiaquotatab.cpp b/kmail/folderdiaquotatab.cpp index 4215ba723..ac93431f8 100644 --- a/kmail/folderdiaquotatab.cpp +++ b/kmail/folderdiaquotatab.cpp @@ -117,7 +117,7 @@ void KMail::FolderDiaQuotaTab::load() KMFolder* folder = mDlg->folder() ? mDlg->folder() : mDlg->tqparentFolder(); if ( folder && folder->storage() == mImapAccount->rootFolder() ) return; // nothing to be done for the (virtual) account folder - mLabel->setText( i18n( "Connecting to server %1, please wait..." ).arg( mImapAccount->host() ) ); + mLabel->setText( i18n( "Connecting to server %1, please wait..." ).tqarg( mImapAccount->host() ) ); ImapAccountBase::ConnectionState state = mImapAccount->makeConnection(); if ( state == ImapAccountBase::Error ) { // Cancelled by user, or slave can't start slotConnectionResult( -1, TQString() ); @@ -136,7 +136,7 @@ void KMail::FolderDiaQuotaTab::slotConnectionResult( int errorCode, const TQStri this, TQT_SLOT( slotConnectionResult(int, const TQString&) ) ); if ( errorCode ) { if ( errorCode == -1 ) // unspecified error - mLabel->setText( i18n( "Error connecting to server %1" ).arg( mImapAccount->host() ) ); + mLabel->setText( i18n( "Error connecting to server %1" ).tqarg( mImapAccount->host() ) ); else // Connection error (error message box already shown by the account) mLabel->setText( KIO::buildErrorString( errorCode, errorMsg ) ); @@ -162,7 +162,7 @@ void KMail::FolderDiaQuotaTab::slotReceivedQuotaInfo( KMFolder* folder, if ( job->error() == KIO::ERR_UNSUPPORTED_ACTION ) mLabel->setText( i18n( "This account does not have support for quota information." ) ); else - mLabel->setText( i18n( "Error retrieving quota information from server\n%1" ).arg( job->errorString() ) ); + mLabel->setText( i18n( "Error retrieving quota information from server\n%1" ).tqarg( job->errorString() ) ); } else { mQuotaInfo = info; } diff --git a/kmail/folderpropertiesdialog.ui b/kmail/folderpropertiesdialog.ui index 984885c16..1966944a0 100644 --- a/kmail/folderpropertiesdialog.ui +++ b/kmail/folderpropertiesdialog.ui @@ -608,13 +608,13 @@ </connection> <connection> <sender>mNormalIconButton</sender> - <signal>iconChanged(QString)</signal> + <signal>iconChanged(TQString)</signal> <receiver>KMFolderDialogUI</receiver> - <slot>slotChangeIcon(QString)</slot> + <slot>slotChangeIcon(TQString)</slot> </connection> </connections> <includes> - <include location="global" impldecl="in declaration">qvaluelist.h</include> + <include location="global" impldecl="in declaration">tqvaluelist.h</include> <include location="local" impldecl="in implementation">kmfolderdir.h</include> <include location="local" impldecl="in implementation">kmfolder.h</include> <include location="global" impldecl="in implementation">kdialog.h</include> @@ -622,16 +622,16 @@ </includes> <forwards> <forward>class KMFolderDir;</forward> - <forward>template <typename T> class QGuardedPtr; </forward> + <forward>template <typename T> class TQGuardedPtr; </forward> <forward>class KMFolder; </forward> </forwards> <variables> <variable>KMFolder *mFolder;</variable> - <variable>QValueList<QGuardedPtr<KMFolder> > mFolders;</variable> + <variable>TQValueList<TQGuardedPtr<KMFolder> > mFolders;</variable> <variable>KMFolderDir *mFolderDIr;</variable> </variables> <Q_SLOTS> - <slot access="protected">slotChangeIcon( QString )</slot> + <slot access="protected">slotChangeIcon( TQString )</slot> </Q_SLOTS> <tqlayoutdefaults spacing="6" margin="11"/> <tqlayoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/> diff --git a/kmail/folderrequester.cpp b/kmail/folderrequester.cpp index 06374664f..b04022bbe 100644 --- a/kmail/folderrequester.cpp +++ b/kmail/folderrequester.cpp @@ -57,7 +57,7 @@ FolderRequester::FolderRequester( TQWidget *tqparent, KMFolderTree *tree ) tqsetSizePolicy( TQSizePolicy( TQSizePolicy::MinimumExpanding, TQSizePolicy::Fixed ) ); - setFocusPolicy( TQWidget::StrongFocus ); + setFocusPolicy( Qt::StrongFocus ); } //----------------------------------------------------------------------------- @@ -104,7 +104,7 @@ void FolderRequester::setFolder( const TQString &idString ) setFolder( folder ); } else { if ( !idString.isEmpty() ) { - edit->setText( i18n( "Unknown folder '%1'" ).arg( idString ) ); + edit->setText( i18n( "Unknown folder '%1'" ).tqarg( idString ) ); } else { edit->setText( i18n( "Please select a folder" ) ); } diff --git a/kmail/foldershortcutdialog.cpp b/kmail/foldershortcutdialog.cpp index b4897afec..f9bbed20d 100644 --- a/kmail/foldershortcutdialog.cpp +++ b/kmail/foldershortcutdialog.cpp @@ -56,7 +56,7 @@ FolderShortcutDialog::FolderShortcutDialog( KMFolder *folder, TQWidget *tqparent, const char *name ) : KDialogBase( tqparent, name, true, - i18n( "Shortcut for Folder %1" ).arg( folder->label() ), + i18n( "Shortcut for Folder %1" ).tqarg( folder->label() ), KDialogBase::Ok | KDialogBase::Cancel ), mFolder( folder ), mMainWidget( mainwidget ) { diff --git a/kmail/folderstorage.cpp b/kmail/folderstorage.cpp index e1a7f364e..72547d8d2 100644 --- a/kmail/folderstorage.cpp +++ b/kmail/folderstorage.cpp @@ -725,11 +725,11 @@ int FolderStorage::rename(const TQString& newName, KMFolderDir *newParent) // if the folder is being moved then move its node and, if necessary, also // the associated subfolder directory node to the new tqparent if (newParent) { - if (oldParent->findRef( folder() ) != -1) + if (oldParent->tqfindRef( folder() ) != -1) oldParent->take(); newParent->inSort( folder() ); if ( child ) { - if ( child->tqparent()->findRef( child ) != -1 ) + if ( child->tqparent()->tqfindRef( child ) != -1 ) child->tqparent()->take(); newParent->inSort( child ); child->setParent( newParent ); diff --git a/kmail/foldertreebase.cpp b/kmail/foldertreebase.cpp index 0397692aa..87084b7bb 100644 --- a/kmail/foldertreebase.cpp +++ b/kmail/foldertreebase.cpp @@ -108,9 +108,9 @@ void FolderTreeBase::readColorConfig() KConfig* conf = KMKernel::config(); // Custom/System color support KConfigGroupSaver saver(conf, "Reader"); - TQColor c1=TQColor(kapp->palette().active().text()); + TQColor c1=TQColor(kapp->tqpalette().active().text()); TQColor c2=TQColor("blue"); - TQColor c4=TQColor(kapp->palette().active().base()); + TQColor c4=TQColor(kapp->tqpalette().active().base()); TQColor c5=TQColor("red"); if (!conf->readBoolEntry("defaultColors",true)) { @@ -235,7 +235,7 @@ void FolderTreeBase::handleMailListDrop(TQDropEvent * event, KMFolder *destinati else action = dndMode(); if ( action == DRAG_COPY || action == DRAG_MOVE ) { - new MessageCopyHelper( serNums, destination, action == DRAG_MOVE, this ); + new MessageCopyHelper( serNums, destination, action == DRAG_MOVE, TQT_TQOBJECT(this) ); } } } diff --git a/kmail/folderutil.cpp b/kmail/folderutil.cpp index e5a604b8b..e227113db 100644 --- a/kmail/folderutil.cpp +++ b/kmail/folderutil.cpp @@ -92,7 +92,7 @@ void KMail::FolderUtil::deleteFolder( KMFolder *folderToDelete, TQWidget *tqpare KMessageBox::information(tqparent, i18n("<qt>The folder you deleted was associated with the account " "<b>%1</b> which delivered mail into it. The folder the account " - "delivers new mail into was reset to the main Inbox folder.</qt>").arg( (*it)->name())); + "delivers new mail into was reset to the main Inbox folder.</qt>").tqarg( (*it)->name())); } } if (folderToDelete->folderType() == KMFolderTypeImap) diff --git a/kmail/folderviewtooltip.h b/kmail/folderviewtooltip.h index 5ffac8d4a..a60e60c6c 100644 --- a/kmail/folderviewtooltip.h +++ b/kmail/folderviewtooltip.h @@ -32,15 +32,15 @@ class FolderViewToolTip : public TQToolTip item->updateCount(); TQString tipText = i18n("<qt><b>%1</b><br>Total: %2<br>Unread: %3<br>Size: %4" ) - .arg( item->folder()->prettyURL().tqreplace( " ", " " ) ) - .arg( item->totalCount() < 0 ? "-" : TQString::number( item->totalCount() ) ) - .arg( item->unreadCount() < 0 ? "-" : TQString::number( item->unreadCount() ) ) - .arg( KIO::convertSize( item->folderSize() ) ); + .tqarg( item->folder()->prettyURL().tqreplace( " ", " " ) ) + .tqarg( item->totalCount() < 0 ? "-" : TQString::number( item->totalCount() ) ) + .tqarg( item->unreadCount() < 0 ? "-" : TQString::number( item->unreadCount() ) ) + .tqarg( KIO::convertSize( item->folderSize() ) ); if ( KMFolderCachedImap* imap = dynamic_cast<KMFolderCachedImap*>( item->folder()->storage() ) ) { QuotaInfo info = imap->quotaInfo(); if ( info.isValid() && !info.isEmpty() ) - tipText += i18n("<br>Quota: %1").arg( info.toString() ); + tipText += i18n("<br>Quota: %1").tqarg( info.toString() ); } tip( TQRect( headerRect.left(), tqitemRect.top(), headerRect.width(), tqitemRect.height() ), tipText ); diff --git a/kmail/headeritem.cpp b/kmail/headeritem.cpp index 230b64999..7742e3ba6 100644 --- a/kmail/headeritem.cpp +++ b/kmail/headeritem.cpp @@ -458,7 +458,7 @@ TQString HeaderItem::generate_key( KMHeaders *headers, int column = sortOrder & ((1 << 5) - 1); TQString ret = TQChar( (char)sortOrder ); - TQString sortArrival = TQString( "%1" ).arg( msg->getMsgSerNum(), 0, 36 ); + TQString sortArrival = TQString( "%1" ).tqarg( msg->getMsgSerNum(), 0, 36 ); while (sortArrival.length() < 7) sortArrival = '0' + sortArrival; if (column == paintInfo->dateCol) { diff --git a/kmail/headerlistquicksearch.cpp b/kmail/headerlistquicksearch.cpp index 39df6dc9b..2ed869b61 100644 --- a/kmail/headerlistquicksearch.cpp +++ b/kmail/headerlistquicksearch.cpp @@ -57,7 +57,7 @@ HeaderListQuickSearch::HeaderListQuickSearch( TQWidget *tqparent, TQApplication::reverseLayout() ? "clear_left" : "locationbar_erase", - 0, this, + 0, TQT_TQOBJECT(this), TQT_SLOT( reset() ), actionCollection, "reset_quicksearch" ); @@ -112,12 +112,12 @@ HeaderListQuickSearch::~HeaderListQuickSearch() bool HeaderListQuickSearch::eventFilter( TQObject *watched, TQEvent *event ) { - if ( watched == mStatusCombo ) { + if ( TQT_BASE_OBJECT(watched) == TQT_BASE_OBJECT(mStatusCombo) ) { KMMainWidget *mainWidget = 0; // Travel up the tqparents list until we find the main widget for ( TQWidget *curWidget = tqparentWidget(); curWidget; curWidget = curWidget->tqparentWidget() ) { - mainWidget = ::qt_cast<KMMainWidget *>( curWidget ); + mainWidget = ::tqqt_cast<KMMainWidget *>( curWidget ); if ( mainWidget ) break; } diff --git a/kmail/headerstyle.cpp b/kmail/headerstyle.cpp index 0b728444f..6e459c7aa 100644 --- a/kmail/headerstyle.cpp +++ b/kmail/headerstyle.cpp @@ -82,10 +82,10 @@ namespace KMail { static TQString convertToHtmlBlock( const TQString & str, bool useSpan=false ) { TQString dir = directionOf( str ); TQString format = "<%1 dir=\"%3\">%4</%2>"; - return format.arg( useSpan ? "span" : "div" ) - .arg( useSpan ? "span" : "div" ) - .arg( dir ) - .arg( LinkLocator::convertToHtml( str ) ); + return format.tqarg( useSpan ? "span" : "div" ) + .tqarg( useSpan ? "span" : "div" ) + .tqarg( dir ) + .tqarg( LinkLocator::convertToHtml( str ) ); } #endif @@ -262,13 +262,13 @@ namespace KMail { return headerStr + "</div>"; } - headerStr = TQString("<div class=\"header\" dir=\"%1\">").arg(dir); + headerStr = TQString("<div class=\"header\" dir=\"%1\">").tqarg(dir); //case HdrLong: if ( strategy->showHeader( "subject" ) ) headerStr += TQString("<div dir=\"%1\"><b style=\"font-size:130%\">" + strToHtml(message->subject()) + "</b></div>\n") - .arg(subjectDir); + .tqarg(subjectDir); if ( strategy->showHeader( "date" ) ) headerStr.append(i18n("Date: ") + strToHtml(dateString)+"<br>\n"); @@ -408,9 +408,9 @@ namespace KMail { } } TQString titleText = i18n("%1% probability of being spam.\n\nFull report:\n%2") - .arg( TQString::number( percent ), filterHeader ); + .tqarg( TQString::number( percent ), filterHeader ); return TQString("<img src=\"%1\" width=\"%2\" height=\"%3\" style=\"border: 1px solid black;\" title=\"%4\"> ") - .arg( imgToDataUrl( meterBar, "PPM" ), TQString::number( 20 ), + .tqarg( imgToDataUrl( meterBar, "PPM" ), TQString::number( 20 ), TQString::number( 5 ), titleText ); } @@ -430,7 +430,7 @@ namespace KMail { // of the application tqlayout. TQString dir = ( TQApplication::reverseLayout() ? "rtl" : "ltr" ); - TQString headerStr = TQString("<div class=\"fancy header\" dir=\"%1\">\n").arg(dir); + TQString headerStr = TQString("<div class=\"fancy header\" dir=\"%1\">\n").tqarg(dir); // However, the direction of the message subject within the header is // determined according to the contents of the subject itself. Since @@ -494,7 +494,7 @@ namespace KMail { if ( !presence.isEmpty() ) { TQString presenceIcon = TQString::tqfromLatin1( " <img src=\"%1\"/>" ) - .arg( imgToDataUrl( imProxy->presenceIcon( kabcUid ).convertToImage() ) ); + .tqarg( imgToDataUrl( imProxy->presenceIcon( kabcUid ).convertToImage() ) ); presence += presenceIcon; } } @@ -585,26 +585,26 @@ namespace KMail { { //kdDebug( 5006 ) << "Got a photo: " << photoURL << endl; userHTML = TQString("<img src=\"%1\" width=\"%2\" height=\"%3\">") - .arg( photoURL ).arg( photoWidth ).arg( photoHeight ); + .tqarg( photoURL ).tqarg( photoWidth ).tqarg( photoHeight ); if ( presence.isEmpty() ) { userHTML = TQString("<div class=\"senderpic\">") + userHTML + "</div>"; } else { userHTML = TQString( "<div class=\"senderpic\">" "<a href=\"im:%1\">%2<div class=\"senderstatus\">" "<span name=\"presence-%3\">%4</span></div></a>" - "</div>" ).arg( kabcUid ) - .arg( userHTML ) - .arg( kabcUid ) - .arg( presence ); + "</div>" ).tqarg( kabcUid ) + .tqarg( userHTML ) + .tqarg( kabcUid ) + .tqarg( presence ); } } else { // we don't have a photo, just show presence, if we have it if ( !presence.isEmpty() ) userHTML = TQString( "<a href=\"im:%1\"><div class=\"senderstatus\">" "<span name=\"presence-%2\">%3</span></div></a>" ) - .arg( kabcUid ) - .arg( kabcUid ) - .arg( presence ); + .tqarg( kabcUid ) + .tqarg( kabcUid ) + .tqarg( presence ); } #if 0 // Disabled 'Launch IM' link in headers - Will @@ -646,7 +646,7 @@ namespace KMail { // kdDebug() << "FancyHeaderStyle::format() local zone offset (in minutes): " << lzone << endl; - TQTime currTime = TQTime::currentTime( TQt::UTC ); + TQTime currTime = TQTime::currentTime( Qt::UTC ); // kdDebug() << "FancyHeaderStyle::format() current time: " << currTime << endl; @@ -662,7 +662,7 @@ namespace KMail { color = "white"; bg_color = "#000B6B"; bg_image = "url(data:image/png;base64," - "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAIAAAASmSbdAAAAS0lETQVQI11WOsRGATQAzDOG/LHoz9" + "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAIAAAASmSbdAAAAS0lEQVQI11WOsRGAQAzDOG/LHoz9" "kikIcF+kSBxbPs7LoNGVapAI0Zn+O+8NUwldozn6io7G7kdS/5zi7i+BvUM/5uSXlIfzMHx/bmWR" "k++yj9rZAAAAAElFTkSuQmCC)"; } @@ -671,8 +671,8 @@ namespace KMail { color = "white"; bg_color = "#00A6FF"; bg_image = "url(data:image/png;base64," - "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAWklETQVQI122OQQ7DMAzDaP3/dfuO" - "pWSHJgva7iZIBk3m/Ew5hexCHVCilewzFHKEbFZqgxJTQWyzKhWKl9unqddJj8+L9sl0oR2gUim+o" + "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAWklEQVQI122OQQ7DMAzDaP3/dfuO" + "pWSHJgva7iZIBk3m/Ew5hexCHVCilewzFHKEbFZqgxJQWyzKhWKl9unqddJj8+L9sl0oR2gUim+o" "zu4uSh7kn67/DNv+C4tsZOtjAWEHAAAAAElFTkSuQmCC)"; } else if ( currTime > TQTime( 12, 0, 0 ) && currTime <= TQTime( 18, 0, 0 ) ) { @@ -680,8 +680,8 @@ namespace KMail { color = "black"; bg_color = "#00A6FF"; bg_image = "url(data:image/png;base64," - "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAPUlETQVQI132OwQ0AIAwCSfcfw91c" - "QsCfRm399HFwoWjdDhMICQhxHSWMTQPhkTCoqWRZU2h5i9tr4GZfmV5t3wWUI3h+NugAAAABJRU5E" + "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAPUlEQVQI132OwQ0AIAwCSfcfw91c" + "QsCfRm399HFwoWjdDhMICQhxHSWMQPhkTCoqWRZU2h5i9tr4GZfmV5t3wWUI3h+NugAAAABJRU5E" "rkJggg==)"; } else { @@ -689,8 +689,8 @@ namespace KMail { color = "white"; bg_color = "#0014CC"; bg_image = "url(data:image/png;base64," - "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAWklETQVQI11WOyRHAMAgDNQuUlBrS" - "fyFpAfKwje0PwyEt0vN+hVsJpzS6TQML2ziWcFI6mZBZNSVDXYehyUgI1XsLI9eimHDH6kW0ddVIO" + "iVBORw0KGgoAAAANSUhEUgAAAAEAAAAyCAYAAACd+7GKAAAAWklEQVQI11WOyRHAMAgDNQuUlBrS" + "fyFpAfKwje0PwyEt0vN+hVsJpzS6QML2ziWcFI6mZBZNSVDXYehyUgI1XsLI9eimHDH6kW0ddVIO" "xx7JjrtshlbXlLDSD+WhJ+hwqWo8AAAAAElFTkSuQmCC)"; } @@ -719,12 +719,12 @@ namespace KMail { "margin: 0px 0px 3px 0px;" "\" class=\"curtime\">%4<br />%5<br />%6</div>" ) - .arg( bg_color ) - .arg( color ) - .arg( bg_image ) - .arg( i18n( "Now:" ) ) - .arg( currTime.toString( tformat ) ) - .arg( timeofday ) + .tqarg( bg_color ) + .tqarg( color ) + .tqarg( bg_image ) + .tqarg( i18n( "Now:" ) ) + .tqarg( currTime.toString( tformat ) ) + .tqarg( timeofday ) ); } else { @@ -739,8 +739,8 @@ namespace KMail { ( GlobalSettings::self()->showEmoticons() ? LinkLocator::ReplaceSmileys : 0 ); headerStr += TQString("<div dir=\"%1\">%2</div>\n") - .arg(subjectDir) - .arg(message->subject().isEmpty()? + .tqarg(subjectDir) + .tqarg(message->subject().isEmpty()? i18n("No Subject") : strToHtml( message->subject(), flags )); } @@ -755,11 +755,11 @@ namespace KMail { fromStr = message->fromStrip(); // let's use that headerStr += TQString("<tr><th>%1</th>\n" "<td>") - .arg(i18n("From: ")) + .tqarg(i18n("From: ")) + KMMessage::emailAddrAsAnchor( fromStr, false ) + ( !message->headerField( "Resent-From" ).isEmpty() ? " " + i18n("(resent from %1)") - .arg( KMMessage::emailAddrAsAnchor( + .tqarg( KMMessage::emailAddrAsAnchor( message->headerField( "Resent-From" ),false) ) : TQString("") ) + ( !vCardName.isEmpty() ? " <a href=\"" + vCardName + "\">" @@ -781,37 +781,37 @@ namespace KMail { if ( strategy->showHeader( "to" ) ) headerStr.append(TQString("<tr><th>%1</th>\n" "<td>%2</td></tr>\n") - .arg(i18n("To: ")) - .arg(KMMessage::emailAddrAsAnchor(message->to(),false))); + .tqarg(i18n("To: ")) + .tqarg(KMMessage::emailAddrAsAnchor(message->to(),false))); // cc line, if any if ( strategy->showHeader( "cc" ) && !message->cc().isEmpty()) headerStr.append(TQString("<tr><th>%1</th>\n" "<td>%2</td></tr>\n") - .arg(i18n("CC: ")) - .arg(KMMessage::emailAddrAsAnchor(message->cc(),false))); + .tqarg(i18n("CC: ")) + .tqarg(KMMessage::emailAddrAsAnchor(message->cc(),false))); // Bcc line, if any if ( strategy->showHeader( "bcc" ) && !message->bcc().isEmpty()) headerStr.append(TQString("<tr><th>%1</th>\n" "<td>%2</td></tr>\n") - .arg(i18n("BCC: ")) - .arg(KMMessage::emailAddrAsAnchor(message->bcc(),false))); + .tqarg(i18n("BCC: ")) + .tqarg(KMMessage::emailAddrAsAnchor(message->bcc(),false))); if ( strategy->showHeader( "date" ) ) headerStr.append(TQString("<tr><th>%1</th>\n" "<td dir=\"%2\">%3</td></tr>\n") - .arg(i18n("Date: ")) - .arg( directionOf( message->dateStr() ) ) - .arg(strToHtml(dateString))); + .tqarg(i18n("Date: ")) + .tqarg( directionOf( message->dateStr() ) ) + .tqarg(strToHtml(dateString))); if ( GlobalSettings::self()->showUserAgent() ) { if ( strategy->showHeader( "user-agent" ) ) { if ( !message->headerField("User-Agent").isEmpty() ) { headerStr.append(TQString("<tr><th>%1</th>\n" "<td>%2</td></tr>\n") - .arg(i18n("User-Agent: ")) - .arg( strToHtml( message->headerField("User-Agent") ) ) ); + .tqarg(i18n("User-Agent: ")) + .tqarg( strToHtml( message->headerField("User-Agent") ) ) ); } } @@ -819,8 +819,8 @@ namespace KMail { if ( !message->headerField("X-Mailer").isEmpty() ) { headerStr.append(TQString("<tr><th>%1</th>\n" "<td>%2</td></tr>\n") - .arg(i18n("X-Mailer: ")) - .arg( strToHtml( message->headerField("X-Mailer") ) ) ); + .tqarg(i18n("X-Mailer: ")) + .tqarg( strToHtml( message->headerField("X-Mailer") ) ) ); } } } @@ -829,19 +829,19 @@ namespace KMail { /* if( strategy->showHeader( "status" ) ) headerStr.append( TQString( "<tr><th>%1</th>\n" "<td dir=\"%2\">%3</td></tr>\n") - .arg(i18n("Sender status: ")) - .arg( directionOf( onlinetqStatus ) ) - .arg(onlinetqStatus)); + .tqarg(i18n("Sender status: ")) + .tqarg( directionOf( onlinetqStatus ) ) + .tqarg(onlinetqStatus)); */ headerStr.append( TQString("<tr><td colspan=\"2\"><div id=\"attachmentInjectionPoint\"></div></td></tr>" ) ); headerStr.append( TQString( "</table></td><td align=\"center\" valign=\"top\">%1%2</td></tr></table>\n" ) - .arg(timeHTML) - .arg(userHTML) ); + .tqarg(timeHTML) + .tqarg(userHTML) ); if ( !spamHTML.isEmpty() ) headerStr.append( TQString( "<div class=\"spamheader\" dir=\"%1\"><b>%2</b> <span style=\"padding-left: 20px;\">%3</span></div>\n") - .arg( subjectDir, i18n("Spam tqStatus:"), spamHTML ) ); + .tqarg( subjectDir, i18n("Spam tqStatus:"), spamHTML ) ); headerStr += "</div>\n\n"; return headerStr; @@ -854,7 +854,7 @@ namespace KMail { buffer.open( IO_WriteOnly ); image.save( &buffer, fmt ); return TQString::tqfromLatin1("data:image/%1;base64,%2") - .arg( fmt, KCodecs::base64Encode( ba ) ); + .tqarg( fmt, KCodecs::base64Encode( ba ).data() ); } // ##################### @@ -901,7 +901,7 @@ namespace KMail { // colors depend on if its encapsulated or not TQColor fontColor(TQt::white); TQString linkColor = "class =\"white\""; - const TQColor activeColor = tqApp->palette().active().highlight(); + const TQColor activeColor = tqApp->tqpalette().active().highlight(); TQColor activeColorDark = activeColor.dark(130); // reverse colors for encapsulated if( !topLevel ){ diff --git a/kmail/identitydialog.cpp b/kmail/identitydialog.cpp index 1ec367eee..ca8fa8dca 100644 --- a/kmail/identitydialog.cpp +++ b/kmail/identitydialog.cpp @@ -527,7 +527,7 @@ void IdentityDialog::slotOk() { for ( TQStringList::const_iterator it = aliases.begin(), end = aliases.end() ; it != end ; ++it ) { if ( !isValidSimpleEmailAddress( *it ) ) { TQString errorMsg( simpleEmailAddressErrorMsg()); - KMessageBox::sorry( this, errorMsg, i18n("Invalid Email Alias \"%1\"").arg( *it ) ); + KMessageBox::sorry( this, errorMsg, i18n("Invalid Email Alias \"%1\"").tqarg( *it ) ); return; } } @@ -580,7 +580,7 @@ void IdentityDialog::slotOk() { } if ( err ) - if ( KMessageBox::warningContinueCancel( this, msg.arg( email ), + if ( KMessageBox::warningContinueCancel( this, msg.tqarg( email ), i18n("Email Address Not Found in Key/Certificates"), KStdGuiItem::cont(), "warn_email_not_in_certificate" ) != KMessageBox::Continue) @@ -612,7 +612,7 @@ void IdentityDialog::slotOk() { void IdentityDialog::setIdentity( KPIM::Identity & ident ) { - setCaption( i18n("Edit Identity \"%1\"").arg( ident.identityName() ) ); + setCaption( i18n("Edit Identity \"%1\"").tqarg( ident.identityName() ) ); // "General" tab: mNameEdit->setText( ident.fullName() ); @@ -641,7 +641,7 @@ void IdentityDialog::slotOk() { "\"%1\" does not exist (anymore); " "therefore, the default sent-mail folder " "will be used.") - .arg( ident.identityName() ) ) ) + .tqarg( ident.identityName() ) ) ) mFccCombo->setFolder( kmkernel->sentFolder() ); else mFccCombo->setFolder( ident.fcc() ); @@ -652,7 +652,7 @@ void IdentityDialog::slotOk() { "\"%1\" does not exist (anymore); " "therefore, the default drafts folder " "will be used.") - .arg( ident.identityName() ) ) ) + .tqarg( ident.identityName() ) ) ) mDraftsCombo->setFolder( kmkernel->draftsFolder() ); else mDraftsCombo->setFolder( ident.drafts() ); @@ -663,14 +663,14 @@ void IdentityDialog::slotOk() { "\"%1\" does not exist (anymore); " "therefore, the default templates folder " "will be used.") - .arg( ident.identityName() ) ) ) + .tqarg( ident.identityName() ) ) ) mTemplatesCombo->setFolder( kmkernel->templatesFolder() ); else mTemplatesCombo->setFolder( ident.templates() ); // "Templates" tab: uint identity = ident.uoid(); - TQString iid = TQString("IDENTITY_%1").arg( identity ); + TQString iid = TQString("IDENTITY_%1").tqarg( identity ); Templates t( iid ); mCustom->setChecked(t.useCustomTemplates()); mWidget->loadFromIdentity( identity ); @@ -709,7 +709,7 @@ void IdentityDialog::slotOk() { mTemplatesCombo->folder()->idString() : TQString() ); // "Templates" tab: uint identity = ident.uoid(); - TQString iid = TQString("IDENTITY_%1").arg( identity ); + TQString iid = TQString("IDENTITY_%1").tqarg( identity ); Templates t( iid ); kdDebug() << "use custom templates for identity " << identity << ": " << mCustom->isChecked() << endl; t.setUseCustomTemplates(mCustom->isChecked()); diff --git a/kmail/identitylistview.cpp b/kmail/identitylistview.cpp index 319bd32a8..695c8da7b 100644 --- a/kmail/identitylistview.cpp +++ b/kmail/identitylistview.cpp @@ -83,7 +83,7 @@ namespace KMail { setText( 0, i18n("%1: identity name. Used in the config " "dialog, section Identity, to indicate the " "default identity", "%1 (Default)") - .arg( ident.identityName() ) ); + .tqarg( ident.identityName() ) ); else setText( 0, ident.identityName() ); setText( 1, ident.fullEmailAddr() ); diff --git a/kmail/imapaccountbase.cpp b/kmail/imapaccountbase.cpp index 04dc29332..84da936e9 100644 --- a/kmail/imapaccountbase.cpp +++ b/kmail/imapaccountbase.cpp @@ -318,7 +318,7 @@ namespace KMail { mSlave = KIO::Scheduler::getConnectedSlave( getUrl(), slaveConfig() ); if ( !mSlave ) { KMessageBox::error(0, i18n("Could not start process for %1.") - .arg( getUrl().protocol() ) ); + .tqarg( getUrl().protocol() ) ); return Error; } if ( mSlave->isConnected() ) { @@ -400,7 +400,7 @@ namespace KMail { if (job->error()) { if ( !(*it).quiet ) - handleJobError( job, i18n( "Error while trying to subscribe to %1:" ).arg( path ) + '\n' ); + handleJobError( job, i18n( "Error while trying to subscribe to %1:" ).tqarg( path ) + '\n' ); emit subscriptionChangeFailed( job->errorString() ); // ## emit subscriptionChanged here in case anyone needs it to support continue/cancel } @@ -735,7 +735,7 @@ namespace KMail { if ( !done ) { TQString msg = i18n("KMail has detected a prefix entry in the " "configuration of the account \"%1\" which is obsolete with the " - "support of IMAP namespaces.").arg( name() ); + "support of IMAP namespaces.").tqarg( name() ); if ( list.tqcontains( "" ) ) { // replace empty entry with the old prefix list.remove( "" ); @@ -879,13 +879,13 @@ namespace KMail { KMMessage* msg = jd.msgList.first(); // Use double-quotes around the subject to keep the sentence readable, // but don't use double quotes around the sender since from() might return a double-quoted name already - const TQString subject = msg->subject().isEmpty() ? i18n( "<unknown>" ) : TQString("\"%1\"").arg( msg->subject() ); + const TQString subject = msg->subject().isEmpty() ? i18n( "<unknown>" ) : TQString("\"%1\"").tqarg( msg->subject() ); const TQString from = msg->from().isEmpty() ? i18n( "<unknown>" ) : msg->from(); TQString myError = "<p><b>" + i18n("Error while uploading message") + "</b></p><p>" - + i18n("Could not upload the message dated %1 from <i>%2</i> with subject <i>%3</i> to the server.").arg( msg->dateStr(), TQStyleSheet::escape( from ), TQStyleSheet::escape( subject ) ) + + i18n("Could not upload the message dated %1 from <i>%2</i> with subject <i>%3</i> to the server.").tqarg( msg->dateStr(), TQStyleSheet::escape( from ), TQStyleSheet::escape( subject ) ) + "</p><p>" - + i18n("The destination folder was: <b>%1</b>.").arg( TQStyleSheet::escape( folder->prettyURL() ) ) + + i18n("The destination folder was: <b>%1</b>.").tqarg( TQStyleSheet::escape( folder->prettyURL() ) ) + "</p><p>" + i18n("The server reported:") + "</p>"; return handleJobError( job, myError ); @@ -908,7 +908,7 @@ namespace KMail { } readOnly = folder->isReadOnly(); } - error = i18n("The folder is too close to its quota limit. (%1)").arg( quotaAsString ); + error = i18n("The folder is too close to its quota limit. (%1)").tqarg( quotaAsString ); if ( readOnly ) { error += i18n("\nSince you do not have write privileges on this folder, " "please ask the owner of the folder to free up some space in it."); @@ -958,19 +958,19 @@ namespace KMail { if ( errorCode == KIO::ERR_SERVER_TIMEOUT || errorCode == KIO::ERR_CONNECTION_BROKEN ) { msg = i18n("The connection to the server %1 was unexpectedly closed or timed out. It will be re-established automatically if possible."). arg( name() ); - KMessageBox::information( kapp->activeWindow(), msg, caption, "kmailConnectionBrokenErrorDialog" ); + KMessageBox::information( TQT_TQWIDGET(kapp->activeWindow()), msg, caption, "kmailConnectionBrokenErrorDialog" ); // Show it in the status bar, in case the user has ticked "don't show again" if ( errorCode == KIO::ERR_CONNECTION_BROKEN ) KPIM::BroadcastqStatus::instance()->seStatusMsg( - i18n( "The connection to account %1 was broken." ).arg( name() ) ); + i18n( "The connection to account %1 was broken." ).tqarg( name() ) ); else if ( errorCode == KIO::ERR_SERVER_TIMEOUT ) KPIM::BroadcastqStatus::instance()->seStatusMsg( - i18n( "The connection to account %1 timed out." ).arg( name() ) ); + i18n( "The connection to account %1 timed out." ).tqarg( name() ) ); } else { if ( !errors.isEmpty() ) - KMessageBox::detailedError( kapp->activeWindow(), msg, errors.join("\n").prepend("<qt>"), caption ); + KMessageBox::detailedError( TQT_TQWIDGET(kapp->activeWindow()), msg, errors.join("\n").prepend("<qt>"), caption ); else - KMessageBox::error( kapp->activeWindow(), msg, caption ); + KMessageBox::error( TQT_TQWIDGET(kapp->activeWindow()), msg, caption ); } } else { // i.e. we have a chance to continue, ask the user about it if ( errors.count() >= 3 ) { // there is no detailedWarningContinueCancel... (#86517) @@ -978,7 +978,7 @@ namespace KMail { msg = TQString( "<qt>") + context + error + '\n' + errors[2]; caption = errors[0]; } - int ret = KMessageBox::warningContinueCancel( kapp->activeWindow(), msg, caption ); + int ret = KMessageBox::warningContinueCancel( TQT_TQWIDGET(kapp->activeWindow()), msg, caption ); if ( ret == KMessageBox::Cancel ) { jobsKilled = true; killAllJobs( false ); @@ -1418,7 +1418,7 @@ namespace KMail { bool ImapAccountBase::locallySubscribedTo( const TQString& imapPath ) { - return mLocalSubscriptionBlackList.tqfind( imapPath ) == mLocalSubscriptionBlackList.end(); + return mLocalSubscriptionBlackList.find( imapPath ) == mLocalSubscriptionBlackList.end(); } void ImapAccountBase::changeLocalSubscription( const TQString& imapPath, bool subscribe ) diff --git a/kmail/imapjob.cpp b/kmail/imapjob.cpp index fe773a9dc..be94557de 100644 --- a/kmail/imapjob.cpp +++ b/kmail/imapjob.cpp @@ -140,10 +140,10 @@ void ImapJob::init( JobType jt, TQString sets, KMFolderImap* folder, for ( char *ch = cstr.data(); *ch; ch++ ) { if ( *ch == '\n' && (prevChar != '\r') ) { - jd.data.at( i ) = '\r'; + jd.data.tqat( i ) = '\r'; i++; } - jd.data.at( i ) = *ch; + jd.data.tqat( i ) = *ch; prevChar = *ch; i++; } @@ -191,7 +191,7 @@ void ImapJob::init( JobType jt, TQString sets, KMFolderImap* folder, "ImapJobCopyMove"+ProgressManager::getUniqueID(), i18n("Server operation"), i18n("Source folder: %1 - Destination folder: %2") - .arg( TQStyleSheet::escape( msg_tqparent->prettyURL() ), + .tqarg( TQStyleSheet::escape( msg_tqparent->prettyURL() ), TQStyleSheet::escape( mDestFolder->prettyURL() ) ), true, account->useSSL() || account->useTLS() ); @@ -598,7 +598,7 @@ void ImapJob::slotCopyMessageInfoData(KIO::Job * job, const TQString & data) for ( msg = (*it).msgList.first(); msg; msg = (*it).msgList.next() ) { ulong uid = msg->UID(); - index = olduids.findIndex(uid); + index = olduids.tqfindIndex(uid); if (index > -1) { // found, get the new uid diff --git a/kmail/importjob.cpp b/kmail/importjob.cpp index f7c44d19d..9aaf4b957 100644 --- a/kmail/importjob.cpp +++ b/kmail/importjob.cpp @@ -78,7 +78,7 @@ void KMail::ImportJob::finish() mProgressItem->setComplete(); mProgressItem = 0; TQString text = i18n( "Importing the archive file '%1' into the folder '%2' succeeded." ) - .arg( mArchiveFile.path() ).arg( mRootFolder->name() ); + .tqarg( mArchiveFile.path() ).tqarg( mRootFolder->name() ); text += "\n" + i18n( "1 message was imported.", "%n messages were imported.", mNumberOfImportedMessages ); KMessageBox::information( mParentWidget, text, i18n( "Import finished." ) ); deleteLater(); @@ -95,7 +95,7 @@ void KMail::ImportJob::abort( const TQString &errorMessage ) return; mAborted = true; - TQString text = i18n( "Failed to import the archive into folder '%1'." ).arg( mRootFolder->name() ); + TQString text = i18n( "Failed to import the archive into folder '%1'." ).tqarg( mRootFolder->name() ); text += "\n" + errorMessage; if ( mProgressItem ) { mProgressItem->setComplete(); @@ -111,7 +111,7 @@ KMFolder * KMail::ImportJob::createSubFolder( KMFolder *tqparent, const TQString KMFolder *newFolder = FolderUtil::createSubFolder( tqparent, tqparent->child(), folderName, TQString(), KMFolderTypeMaildir ); if ( !newFolder ) { - abort( i18n( "Unable to create subfolder for folder '%1'." ).arg( tqparent->name() ) ); + abort( i18n( "Unable to create subfolder for folder '%1'." ).tqarg( tqparent->name() ) ); return 0; } else { @@ -207,11 +207,11 @@ void KMail::ImportJob::importNextMessage() } mCurrentFolder = folder; if ( mCurrentFolder->open( "ImportJob" ) != 0 ) { - abort( i18n( "Unable to open folder '%1'." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Unable to open folder '%1'." ).tqarg( mCurrentFolder->name() ) ); return; } kdDebug(5006) << "importNextMessage(): Current folder of queue is now: " << mCurrentFolder->name() << endl; - mProgressItem->setqStatus( i18n( "Importing folder %1" ).arg( mCurrentFolder->name() ) ); + mProgressItem->setqStatus( i18n( "Importing folder %1" ).tqarg( mCurrentFolder->name() ) ); } mProgressItem->setProgress( ( mProgressItem->progress() + 5 ) ); @@ -231,7 +231,7 @@ void KMail::ImportJob::importNextMessage() // uploaded. if ( mCurrentFolder->folderType() != KMFolderTypeImap ) { if ( mCurrentFolder->addMsg( mCurrentMessage, &retIndex ) != 0 ) { - abort( i18n( "Failed to add a message to the folder '%1'." ).arg( mCurrentFolder->name() ) ); + abort( i18n( "Failed to add a message to the folder '%1'." ).tqarg( mCurrentFolder->name() ) ); return; } messageAdded(); @@ -284,7 +284,7 @@ KMFolder* KMail::ImportJob::getOrCreateSubFolder( KMFolder *tqparentFolder, cons mode_t subFolderPermissions ) { if ( !tqparentFolder->createChildFolder() ) { - abort( i18n( "Unable to create subfolder for folder '%1'." ).arg( tqparentFolder->name() ) ); + abort( i18n( "Unable to create subfolder for folder '%1'." ).tqarg( tqparentFolder->name() ) ); return 0; } @@ -334,7 +334,7 @@ void KMail::ImportJob::importNextDirectory() const TQString folderName = folderNameForDirectoryName( entry->name() ); if ( folderName.isEmpty() ) { - abort( i18n( "Unexpected subdirectory named '%1'." ).arg( entry->name() ) ); + abort( i18n( "Unexpected subdirectory named '%1'." ).tqarg( entry->name() ) ); return; } KMFolder *subFolder = getOrCreateSubFolder( currentFolder, folderName, entry->permissions() ); @@ -368,12 +368,12 @@ void KMail::ImportJob::start() else if ( !mimeType->patterns().grep( "zip", false ).isEmpty() ) mArchive = new KZip( mArchiveFile.path() ); else { - abort( i18n( "The file '%1' does not appear to be a valid archive." ).arg( mArchiveFile.path() ) ); + abort( i18n( "The file '%1' does not appear to be a valid archive." ).tqarg( mArchiveFile.path() ) ); return; } if ( !mArchive->open( IO_ReadOnly ) ) { - abort( i18n( "Unable to open archive file '%1'" ).arg( mArchiveFile.path() ) ); + abort( i18n( "Unable to open archive file '%1'" ).tqarg( mArchiveFile.path() ) ); return; } diff --git a/kmail/index.cpp b/kmail/index.cpp index f824880fc..a71d27e9c 100644 --- a/kmail/index.cpp +++ b/kmail/index.cpp @@ -219,9 +219,9 @@ void KMMsgIndex::setIndexingEnabled( KMFolder* folder, bool e ) { // create() will notice that folder is disabled break; case s_creating: - if ( std::tqfind( mPendingFolders.begin(), mPendingFolders.end(), folder ) != mPendingFolders.end() ) { + if ( std::find( mPendingFolders.begin(), mPendingFolders.end(), folder ) != mPendingFolders.end() ) { // easy: - mPendingFolders.erase( std::tqfind( mPendingFolders.begin(), mPendingFolders.end(), folder ) ); + mPendingFolders.erase( std::find( mPendingFolders.begin(), mPendingFolders.end(), folder ) ); break; } //else fall-through @@ -433,7 +433,7 @@ bool KMMsgIndex::startQuery( KMSearch* s ) { //} void KMMsgIndex::removeSearch( TQObject* destroyed ) { - mSearches.erase( std::tqfind( mSearches.begin(), mSearches.end(), destroyed ) ); + mSearches.erase( std::find( mSearches.begin(), mSearches.end(), destroyed ) ); } @@ -550,7 +550,7 @@ void KMMsgIndex::Search::act() { TQString terms; for ( KMSearchRule* rule = pat->first(); rule; rule = pat->next() ) { Q_ASSERT( rule->function() == KMSearchRule::FuncContains ); - terms += TQString::tqfromLatin1( " %1 " ).arg( rule->contents() ); + terms += TQString::tqfromLatin1( " %1 " ).tqarg( rule->contents() ); } mValues = kmkernel->msgIndex()->simpleSearch( terms, 0 ); diff --git a/kmail/interfaces/bodypart.h b/kmail/interfaces/bodypart.h index 251d61aff..434906321 100644 --- a/kmail/interfaces/bodypart.h +++ b/kmail/interfaces/bodypart.h @@ -34,8 +34,9 @@ #ifndef __KMAIL_INTERFACES_BODYPART_H__ #define __KMAIL_INTERFACES_BODYPART_H__ +#include <tqcstring.h> + template <typename T> class TQMemArray; -typedef TQMemArray<char> TQByteArray; class TQString; namespace KMail { diff --git a/kmail/keyresolver.cpp b/kmail/keyresolver.cpp index bd4d4a51d..2135a9e79 100644 --- a/kmail/keyresolver.cpp +++ b/kmail/keyresolver.cpp @@ -308,7 +308,7 @@ static std::vector<GpgME::Key> trustedOrConfirmed( const std::vector<GpgME::Key> "for encryption.") : i18n("One or more of the OpenPGP encryption keys or S/MIME " "certificates for recipient \"%1\" is not fully trusted " - "for encryption.").arg(address) ; + "for encryption.").tqarg(address) ; if ( !fishies.empty() ) { // certificates can't have marginal trust @@ -651,7 +651,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>expired less than a day ago.</p>", "<p>The OpenPGP key for</p><p align=center><b>%1</b> (KeyID 0x%2)</p>" "<p>expired %n days ago.</p>", - daysSinceExpiry ) ).arg( TQString::fromUtf8( key.userID(0).id() ), + daysSinceExpiry ) ).tqarg( TQString::fromUtf8( key.userID(0).id() ), key.shortKeyID() ) : ( ca ? ( key.isRoot() @@ -698,7 +698,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>The intermediate CA certificate</p><p align=center><b>%3</b></p>" "<p>for S/MIME certificate</p><p align=center><b>%1</b> (serial number %2)</p>" "<p>expired %n days ago.</p>", - daysSinceExpiry ) ) ).arg( Kleo::DN( orig.userID(0).id() ).prettyDN(), + daysSinceExpiry ) ) ).tqarg( Kleo::DN( orig.userID(0).id() ).prettyDN(), orig.issuerSerial(), Kleo::DN( key.userID(0).id() ).prettyDN() ) : ( mine ? sign @@ -716,7 +716,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>expired less than a day ago.</p>", "<p>The S/MIME certificate for</p><p align=center><b>%1</b> (serial number %2)</p>" "<p>expired %n days ago.</p>", - daysSinceExpiry ) ).arg( Kleo::DN( key.userID(0).id() ).prettyDN(), + daysSinceExpiry ) ).tqarg( Kleo::DN( key.userID(0).id() ).prettyDN(), key.issuerSerial() ) ); d->alreadyWarnedFingerprints.insert( subkey.fingerprint() ); if ( KMessageBox::warningContinueCancel( 0, msg, @@ -759,7 +759,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>expires in less than a day.</p>", "<p>The OpenPGP key for</p><p align=center><b>%1</b> (KeyID 0x%2)</p>" "<p>expires in less than %n days.</p>", - daysTillExpiry ) ).arg( TQString::fromUtf8( key.userID(0).id() ), + daysTillExpiry ) ).tqarg( TQString::fromUtf8( key.userID(0).id() ), key.shortKeyID() ) : ( ca ? ( key.isRoot() @@ -806,7 +806,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>The intermediate CA certificate</p><p align=center><b>%3</b></p>" "<p>for S/MIME certificate</p><p align=center><b>%1</b> (serial number %2)</p>" "<p>expires in less than %n days.</p>", - daysTillExpiry ) ) ).arg( Kleo::DN( orig.userID(0).id() ).prettyDN(), + daysTillExpiry ) ) ).tqarg( Kleo::DN( orig.userID(0).id() ).prettyDN(), orig.issuerSerial(), Kleo::DN( key.userID(0).id() ).prettyDN() ) : ( mine ? sign @@ -824,7 +824,7 @@ Kpgp::Result Kleo::KeyResolver::checkKeyNearExpiry( const GpgME::Key & key, cons "<p>expires in less than a day.</p>", "<p>The S/MIME certificate for</p><p align=center><b>%1</b> (serial number %2)</p>" "<p>expires in less than %n days.</p>", - daysTillExpiry ) ).arg( Kleo::DN( key.userID(0).id() ).prettyDN(), + daysTillExpiry ) ).tqarg( Kleo::DN( key.userID(0).id() ).prettyDN(), key.issuerSerial() ) ); d->alreadyWarnedFingerprints.insert( subkey.fingerprint() ); if ( KMessageBox::warningContinueCancel( 0, msg, @@ -1370,7 +1370,7 @@ void Kleo::KeyResolver::collapseAllSplitInfos() { dump(); for ( unsigned int i = 0 ; i < numConcreteCryptoMessageFormats ; ++i ) { std::map<CryptoMessageFormat,FormatInfo>::iterator pos = - d->mFormatInfoMap.tqfind( concreteCryptoMessageFormats[i] ); + d->mFormatInfoMap.find( concreteCryptoMessageFormats[i] ); if ( pos == d->mFormatInfoMap.end() ) continue; std::vector<SplitInfo> & v = pos->second.splitInfos; @@ -1394,7 +1394,7 @@ void Kleo::KeyResolver::addToAllSplitInfos( const std::vector<GpgME::Key> & keys if ( !( f & concreteCryptoMessageFormats[i] ) ) continue; std::map<CryptoMessageFormat,FormatInfo>::iterator pos = - d->mFormatInfoMap.tqfind( concreteCryptoMessageFormats[i] ); + d->mFormatInfoMap.find( concreteCryptoMessageFormats[i] ); if ( pos == d->mFormatInfoMap.end() ) continue; std::vector<SplitInfo> & v = pos->second.splitInfos; @@ -1422,7 +1422,7 @@ void Kleo::KeyResolver::dump() const { std::cerr << kit->shortKeyID() << " "; std::cerr << std::endl << " SplitInfo #" << i << " recipients: " - << sit->recipients.join(", ").utf8() << std::endl; + << sit->recipients.join(", ").utf8().data() << std::endl; } } #endif @@ -1560,14 +1560,14 @@ Kpgp::Result Kleo::KeyResolver::showKeyApprovalDialog() { std::vector<Kleo::KeyResolver::SplitInfo> Kleo::KeyResolver::encryptionItems( Kleo::CryptoMessageFormat f ) const { dump(); std::map<CryptoMessageFormat,FormatInfo>::const_iterator it = - d->mFormatInfoMap.tqfind( f ); + d->mFormatInfoMap.find( f ); return it != d->mFormatInfoMap.end() ? it->second.splitInfos : std::vector<SplitInfo>() ; } std::vector<GpgME::Key> Kleo::KeyResolver::signingKeys( CryptoMessageFormat f ) const { dump(); std::map<CryptoMessageFormat,FormatInfo>::const_iterator it = - d->mFormatInfoMap.tqfind( f ); + d->mFormatInfoMap.find( f ); return it != d->mFormatInfoMap.end() ? it->second.signKeys : std::vector<GpgME::Key>() ; } @@ -1628,7 +1628,7 @@ std::vector<GpgME::Key> Kleo::KeyResolver::getEncryptionKeys( const TQString & p "There is a problem with the " "encryption certificate(s) for \"%1\".\n\n" "Please re-select the certificate(s) which should " - "be used for this recipient.").arg(person), + "be used for this recipient.").tqarg(person), keys ); } bool canceled = false; @@ -1680,13 +1680,13 @@ std::vector<GpgME::Key> Kleo::KeyResolver::getEncryptionKeys( const TQString & p "Select the certificate(s) which should " "be used for this recipient. If there is no suitable certificate in the list " "you can also search for external certificates by clicking the button: search for external certificates.</qt>") - .arg( TQStyleSheet::escape(person) ) + .tqarg( TQStyleSheet::escape(person) ) : i18n("if in your language something like " "'certificate(s)' isn't possible please " "use the plural in the translation", "More than one certificate matches \"%1\".\n\n" "Select the certificate(s) which should " - "be used for this recipient.").arg( TQStyleSheet::escape(person) ), + "be used for this recipient.").tqarg( TQStyleSheet::escape(person) ), matchingKeys ), address, canceled ); // we can ignore 'canceled' here, since trustedOrConfirmed() returns // an empty vector when canceled == true, and we'd just do the same @@ -1765,7 +1765,7 @@ void Kleo::KeyResolver::addKeys( const std::vector<Item> & items ) { Kleo::KeyResolver::ContactPreferences Kleo::KeyResolver::lookupContactPreferences( const TQString& address ) const { const Private::ContactPreferencesMap::iterator it = - d->mContactPreferencesMap.tqfind( address ); + d->mContactPreferencesMap.find( address ); if ( it != d->mContactPreferencesMap.end() ) return it->second; @@ -1797,7 +1797,7 @@ void Kleo::KeyResolver::saveContactPreference( const TQString& email, const Cont KABC::Addressee addr; if ( res.isEmpty() ) { bool ok = true; - TQString fullName = KInputDialog::getText( i18n( "Name Selection" ), i18n( "Which name shall the contact '%1' have in your addressbook?" ).arg( email ), TQString(), &ok ); + TQString fullName = KInputDialog::getText( i18n( "Name Selection" ), i18n( "Which name shall the contact '%1' have in your addressbook?" ).tqarg( email ), TQString(), &ok ); if ( ok ) { addr.setNameFromString( fullName ); addr.insertEmail( email, true ); diff --git a/kmail/kmaccount.cpp b/kmail/kmaccount.cpp index eebe99f76..6c7950ae6 100644 --- a/kmail/kmaccount.cpp +++ b/kmail/kmaccount.cpp @@ -46,7 +46,7 @@ KMPrecommand::KMPrecommand(const TQString &precommand, TQObject *tqparent) : TQObject(tqparent), mPrecommand(precommand) { BroadcastqStatus::instance()->seStatusMsg( - i18n("Executing precommand %1").arg(precommand )); + i18n("Executing precommand %1").tqarg(precommand )); mPrecommandProcess.setUseShell(true); mPrecommandProcess << precommand; @@ -66,7 +66,7 @@ bool KMPrecommand::start() { bool ok = mPrecommandProcess.start( KProcess::NotifyOnExit ); if (!ok) KMessageBox::error(0, i18n("Could not execute precommand '%1'.") - .arg(mPrecommand)); + .tqarg(mPrecommand)); return ok; } @@ -77,7 +77,7 @@ void KMPrecommand::precommandExited(KProcess *p) int exitCode = p->normalExit() ? p->exitStatus() : -1; if (exitCode) KMessageBox::error(0, i18n("The precommand exited with code %1:\n%2") - .arg(exitCode).arg(strerror(exitCode))); + .tqarg(exitCode).tqarg(strerror(exitCode))); emit finished(!exitCode); } @@ -378,7 +378,7 @@ bool KMAccount::runPrecommand(const TQString &precommand) KMPrecommand precommandProcess(precommand, this); BroadcastqStatus::instance()->seStatusMsg( - i18n("Executing precommand %1").arg(precommand )); + i18n("Executing precommand %1").tqarg(precommand )); connect(&precommandProcess, TQT_SIGNAL(finished(bool)), TQT_SLOT(precommandExited(bool))); diff --git a/kmail/kmacctimap.cpp b/kmail/kmacctimap.cpp index 6942bab53..b16dc0b34 100644 --- a/kmail/kmacctimap.cpp +++ b/kmail/kmacctimap.cpp @@ -69,7 +69,7 @@ KMAcctImap::KMAcctImap(AccountManager* aOwner, const TQString& aAccountName, uin connect(&mErrorTimer, TQT_SIGNAL(timeout()), TQT_SLOT(slotResetConnectionError())); TQString serNumUri = locateLocal( "data", "kmail/unfiltered." + - TQString("%1").arg(KAccount::id()) ); + TQString("%1").tqarg(KAccount::id()) ); KConfig config( serNumUri ); TQStringList serNums = config.readListEntry( "unfiltered" ); mFilterSerNumsToSave.setAutoDelete( false ); @@ -88,7 +88,7 @@ KMAcctImap::~KMAcctImap() killAllJobs( true ); TQString serNumUri = locateLocal( "data", "kmail/unfiltered." + - TQString("%1").arg(KAccount::id()) ); + TQString("%1").tqarg(KAccount::id()) ); KConfig config( serNumUri ); TQStringList serNums; TQDictIterator<int> it( mFilterSerNumsToSave ); @@ -297,7 +297,7 @@ void KMAcctImap::processNewMail(bool interactive) mMailCheckProgressItem = ProgressManager::createProgressItem( "MailCheckAccount" + name(), - i18n("Checking account: %1" ).arg( TQStyleSheet::escape( name() ) ), + i18n("Checking account: %1" ).tqarg( TQStyleSheet::escape( name() ) ), TQString(), // status true, // can be canceled useSSL() || useTLS() ); @@ -434,7 +434,7 @@ void KMAcctImap::postProcessNewMail( KMFolder * folder ) // It's possible that the message has been deleted or moved into a // different folder, or that the serNum is stale if ( !folder ) { - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( *filterIt ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( *filterIt ) ); ++filterIt; continue; } @@ -443,7 +443,7 @@ void KMAcctImap::postProcessNewMail( KMFolder * folder ) if (!imapFolder || !imapFolder->folder()->isSystemFolder() || !(imapFolder->imapPath() == "/INBOX/") ) { // sanity checking - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( *filterIt ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( *filterIt ) ); ++filterIt; continue; } @@ -452,7 +452,7 @@ void KMAcctImap::postProcessNewMail( KMFolder * folder ) msg = folder->getMsg( idx ); if (!msg) { // sanity checking - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( *filterIt ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( *filterIt ) ); ++filterIt; continue; } @@ -473,7 +473,7 @@ void KMAcctImap::postProcessNewMail( KMFolder * folder ) TQT_SLOT(slotFilterMsg(KMMessage*))); job->start(); } else { - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( *filterIt ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( *filterIt ) ); if (slotFilterMsg(msg) == 2) break; } } @@ -498,7 +498,7 @@ void KMAcctImap::postProcessNewMail( KMFolder * folder ) //----------------------------------------------------------------------------- void KMAcctImap::slotFiltered(TQ_UINT32 serNum) { - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( serNum ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( serNum ) ); } //----------------------------------------------------------------------------- @@ -584,7 +584,7 @@ void KMAcctImap::execFilters(TQ_UINT32 serNum) if ( findIt != mFilterSerNums.end() ) return; mFilterSerNums.append( serNum ); - mFilterSerNumsToSave.insert( TQString( "%1" ).arg( serNum ), (const int *)1 ); + mFilterSerNumsToSave.insert( TQString( "%1" ).tqarg( serNum ), (const int *)1 ); } int KMAcctImap::slotFilterMsg( KMMessage *msg ) @@ -596,7 +596,7 @@ int KMAcctImap::slotFilterMsg( KMMessage *msg ) msg->setTransferInProgress(false); TQ_UINT32 serNum = msg->getMsgSerNum(); if ( serNum ) - mFilterSerNumsToSave.remove( TQString( "%1" ).arg( serNum ) ); + mFilterSerNumsToSave.remove( TQString( "%1" ).tqarg( serNum ) ); int filterResult = kmkernel->filterMgr()->process(msg, KMFilterMgr::Inbound, diff --git a/kmail/kmacctlocal.cpp b/kmail/kmacctlocal.cpp index 6062f3547..5c842b1d1 100644 --- a/kmail/kmacctlocal.cpp +++ b/kmail/kmacctlocal.cpp @@ -125,7 +125,7 @@ bool KMAcctLocal::preProcess() //BroadcastqStatus::instance()->reset(); BroadcastqStatus::instance()->seStatusMsg( - i18n("Preparing transmission from \"%1\"...").arg(mName)); + i18n("Preparing transmission from \"%1\"...").tqarg(mName)); Q_ASSERT( !mMailCheckProgressItem ); @@ -133,7 +133,7 @@ bool KMAcctLocal::preProcess() mMailCheckProgressItem = KPIM::ProgressManager::createProgressItem( "MailCheck" + mName, escapedName, - i18n("Preparing transmission from \"%1\"...").arg( escapedName ), + i18n("Preparing transmission from \"%1\"...").tqarg( escapedName ), false, // cannot be canceled false ); // no tls/ssl @@ -164,7 +164,7 @@ bool KMAcctLocal::preProcess() mMailFolder->close("acctlocalMail"); checkDone( mHasNewMail, CheckError ); TQString errMsg = i18n( "Transmission failed: Could not lock %1." ) - .arg( mMailFolder->location() ); + .tqarg( mMailFolder->location() ); BroadcastqStatus::instance()->seStatusMsg( errMsg ); return false; } @@ -177,7 +177,7 @@ bool KMAcctLocal::preProcess() // prepare the static parts of the status message: mStatusMsgStub = i18n("Moving message %3 of %2 from %1.") - .arg(mMailFolder->location()).arg( mNumMsgs ); + .tqarg(mMailFolder->location()).tqarg( mNumMsgs ); //BroadcastqStatus::instance()->seStatusProgressEnable( "L" + mName, true ); return true; @@ -192,7 +192,7 @@ bool KMAcctLocal::fetchMsg() /* This causes mail eating if (kmkernel->mailCheckAborted()) break; */ - const TQString statusMsg = mStatusMsgStub.arg( mMsgsFetched ); + const TQString statusMsg = mStatusMsgStub.tqarg( mMsgsFetched ); //BroadcastqStatus::instance()->seStatusMsg( statusMsg ); mMailCheckProgressItem->incCompletedItems(); mMailCheckProgressItem->updateProgress(); @@ -244,8 +244,8 @@ void KMAcctLocal::postProcess() KMessageBox::queuedMessageBox( 0, KMessageBox::Information, i18n( "<qt>Cannot remove mail from " "mailbox <b>%1</b>:<br>%2</qt>" ) - .arg( mMailFolder->location() ) - .arg( strerror( rc ) ) ); + .tqarg( mMailFolder->location() ) + .tqarg( strerror( rc ) ) ); } if( mMailCheckProgressItem ) { // do this only once... @@ -253,7 +253,7 @@ void KMAcctLocal::postProcess() mMailCheckProgressItem->setqStatus( i18n( "Fetched 1 message from mailbox %1.", "Fetched %n messages from mailbox %1.", - mNumMsgs ).arg( mMailFolder->location() ) ); + mNumMsgs ).tqarg( mMailFolder->location() ) ); mMailCheckProgressItem->setComplete(); mMailCheckProgressItem = 0; } diff --git a/kmail/kmacctmaildir.cpp b/kmail/kmacctmaildir.cpp index 7b83dcf89..07391a582 100644 --- a/kmail/kmacctmaildir.cpp +++ b/kmail/kmacctmaildir.cpp @@ -107,14 +107,14 @@ void KMAcctMaildir::processNewMail(bool) } BroadcastqStatus::instance()->seStatusMsg( - i18n("Preparing transmission from \"%1\"...").arg(mName)); + i18n("Preparing transmission from \"%1\"...").tqarg(mName)); Q_ASSERT( !mMailCheckProgressItem ); TQString escapedName = TQStyleSheet::escape( mName ); mMailCheckProgressItem = KPIM::ProgressManager::createProgressItem( "MailCheck" + mName, escapedName, - i18n("Preparing transmission from \"%1\"...").arg( escapedName ), + i18n("Preparing transmission from \"%1\"...").tqarg( escapedName ), false, // cannot be canceled false ); // no tls/ssl @@ -130,7 +130,7 @@ void KMAcctMaildir::processNewMail(bool) rc = mailFolder.open("acctmaildirMail"); if (rc) { - TQString aStr = i18n("<qt>Cannot open folder <b>%1</b>.</qt>").arg( mailFolder.location() ); + TQString aStr = i18n("<qt>Cannot open folder <b>%1</b>.</qt>").tqarg( mailFolder.location() ); KMessageBox::sorry(0, aStr); kdDebug(5006) << "cannot open folder " << mailFolder.location() << endl; checkDone( hasNewMail, CheckError ); @@ -148,7 +148,7 @@ void KMAcctMaildir::processNewMail(bool) // prepare the static parts of the status message: TQString statusMsgStub = i18n("Moving message %3 of %2 from %1.") - .arg(mailFolder.location()).arg(num); + .tqarg(mailFolder.location()).tqarg(num); mMailCheckProgressItem->setTotalItems( num ); @@ -162,7 +162,7 @@ void KMAcctMaildir::processNewMail(bool) } if (!addedOk) break; - TQString statusMsg = statusMsgStub.arg(i); + TQString statusMsg = statusMsgStub.tqarg(i); mMailCheckProgressItem->incCompletedItems(); mMailCheckProgressItem->updateProgress(); mMailCheckProgressItem->setqStatus( statusMsg ); @@ -192,7 +192,7 @@ void KMAcctMaildir::processNewMail(bool) mMailCheckProgressItem->setqStatus( i18n( "Fetched 1 message from maildir folder %1.", "Fetched %n messages from maildir folder %1.", - num ).arg(mailFolder.location() ) ); + num ).tqarg(mailFolder.location() ) ); mMailCheckProgressItem->setComplete(); mMailCheckProgressItem = 0; diff --git a/kmail/kmail.kcfg b/kmail/kmail.kcfg index 88370a456..52a30a4d8 100644 --- a/kmail/kmail.kcfg +++ b/kmail/kmail.kcfg @@ -3,7 +3,7 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.kde.org/standards/kcfg/1.0 http://www.kde.org/standards/kcfg/1.0/kcfg.xsd" > - <include>qtextcodec.h</include> + <include>tqtextcodec.h</include> <include>kapplication.h</include> <kcfgfile name="kmailrc"/> <group name="Behaviour"> @@ -561,13 +561,13 @@ <default>true</default> </entry> <entry name="ForegroundColor" type="Color" key="ForegroundColor"> - <default code="true">kapp->palette().active().text()</default> + <default code="true">kapp->tqpalette().active().text()</default> </entry> <entry name="BackgroundColor" type="Color" key="BackgroundColor"> - <default code="true">kapp->palette().active().base()</default> + <default code="true">kapp->tqpalette().active().base()</default> </entry> <entry name="FallbackCharacterEncoding" type="String" key="FallbackCharacterEncoding"> - <default code="true"> QCString(QTextCodec::codecForLocale()->name()).lower() == "eucjp"? QCString("jis7") : QCString(QTextCodec::codecForLocale()->name()).lower()</default> + <default code="true"> TQCString(TQTextCodec::codecForLocale()->name()).lower() == "eucjp"? TQCString("jis7") : TQCString(TQTextCodec::codecForLocale()->name()).lower()</default> <label></label> <whatsthis>Some emails, especially those generated automatically, do not specify the character encoding which needs to be used to properly display them. In such cases a fallback character encoding will be used, which you can configure here. Set it to the character encoding most commonly used in your part of the world. As a default the encoding configured for the whole system is used.</whatsthis> </entry> diff --git a/kmail/kmail_part.cpp b/kmail/kmail_part.cpp index 70c90cb00..0a895d9b9 100644 --- a/kmail/kmail_part.cpp +++ b/kmail/kmail_part.cpp @@ -100,7 +100,7 @@ KMailPart::KMailPart(TQWidget *tqparentWidget, const char *widgetName, // create a canvas to insert our widget TQWidget *canvas = new TQWidget(tqparentWidget, widgetName); - canvas->setFocusPolicy(TQWidget::ClickFocus); + canvas->setFocusPolicy(Qt::ClickFocus); setWidget(canvas); KGlobal::iconLoader()->addAppDir("kmail"); #if 0 @@ -125,7 +125,7 @@ KMailPart::KMailPart(TQWidget *tqparentWidget, const char *widgetName, kapp->config()); TQVBoxLayout *topLayout = new TQVBoxLayout(canvas); topLayout->addWidget(mainWidget); - mainWidget->setFocusPolicy(TQWidget::ClickFocus); + mainWidget->setFocusPolicy(Qt::ClickFocus); mStatusBar = new KMailStatusBarExtension(this); mStatusBar->addStatusBarItem( mainWidget->vacationScriptIndicator(), 2, false ); diff --git a/kmail/kmailicalifaceimpl.cpp b/kmail/kmailicalifaceimpl.cpp index 812374734..25a90fd74 100644 --- a/kmail/kmailicalifaceimpl.cpp +++ b/kmail/kmailicalifaceimpl.cpp @@ -682,8 +682,8 @@ static TQString subresourceLabelForPresentation( const KMFolder * folder ) remainder.pop_front(); remainder.pop_front(); label = i18n("%1's %2") - .arg( parts[2] ) - .arg( remainder.join( TQString::tqfromLatin1("/") ) ); + .tqarg( parts[2] ) + .tqarg( remainder.join( TQString::tqfromLatin1("/") ) ); } // Another special case is our own folders, under the imap INBOX, make // those prettier too @@ -698,15 +698,15 @@ static TQString subresourceLabelForPresentation( const KMFolder * folder ) // Fix kolab issue 2531 folder->storage() )->account() can be null if( folder->storage() && static_cast<const KMFolderCachedImap*>( folder->storage() )->account() ) { label = i18n( "My %1 (%2)") - .arg( remainder.join( TQString::tqfromLatin1("/") ), + .tqarg( remainder.join( TQString::tqfromLatin1("/") ), static_cast<const KMFolderCachedImap*>( folder->storage() )->account()->name() ); } else { label = i18n("My %1") - .arg( remainder.join( TQString::tqfromLatin1("/") ) ); + .tqarg( remainder.join( TQString::tqfromLatin1("/") ) ); } } else { label = i18n("My %1") - .arg( remainder.join( TQString::tqfromLatin1("/") ) ); + .tqarg( remainder.join( TQString::tqfromLatin1("/") ) ); } break; } @@ -1574,7 +1574,7 @@ void KMailICalIfaceImpl::triggerKolabFreeBusy( const KURL& folderURL ) kdWarning() << "KCal::ResourceKolab::fromKMailFolderSynced path is too short: " << path << endl; return; } - if ( path.startsWith( "/INBOX/", false ) ) { + if ( path.tqstartsWith( "/INBOX/", false ) ) { // If INBOX, replace it with the username (which is user@domain) path = path.mid( secondSlash ); path.prepend( folderURL.user() ); @@ -1776,7 +1776,7 @@ void KMailICalIfaceImpl::readConfig() // No subfolder was found, so ask if we can make them msg = i18n("KMail will now create the required groupware folders" " as subfolders of %1; if you do not want this, cancel" - " and the IMAP resource will be disabled").arg(tqparentFolderName); + " and the IMAP resource will be disabled").tqarg(tqparentFolderName); } else { // Some subfolders were found, be more precise TQString operations = "<ul>"; @@ -1784,17 +1784,17 @@ void KMailICalIfaceImpl::readConfig() if ( i != KMail::ContentsTypeMail ) { TQString typeName = localizedDefaultFolderName( static_cast<KMail::FolderContentsType>( i ) ); if ( results[i].found == StandardFolderSearchResult::NotFound ) - operations += "<li>" + i18n( "%1: no folder found. It will be created." ).arg( typeName ) + "</li>"; + operations += "<li>" + i18n( "%1: no folder found. It will be created." ).tqarg( typeName ) + "</li>"; else if ( results[i].found == StandardFolderSearchResult::FoundByType || results[i].found == StandardFolderSearchResult::FoundByName ) operations += "<li>" + i18n( "%1: found folder %2. It will be set as the main groupware folder." ). - arg( typeName ).arg( results[i].folder->label() ) + "</li>"; + tqarg( typeName ).tqarg( results[i].folder->label() ) + "</li>"; } } operations += "</ul>"; msg = i18n("<qt>KMail found the following groupware folders in %1 and needs to perform the following operations: %2" "<br>If you do not want this, cancel" - " and the IMAP resource will be disabled").arg(tqparentFolderName, operations); + " and the IMAP resource will be disabled").tqarg(tqparentFolderName, operations); } @@ -1991,9 +1991,9 @@ KMFolder* KMailICalIfaceImpl::initFolder( KMail::FolderContentsType contentsType labels << (*it)->prettyURL(); const TQString selected = KInputDialog::getItem( i18n("Default folder"), i18n("There are multiple %1 default folders, please choose one:") - .arg( localizedDefaultFolderName( contentsType ) ), labels ); + .tqarg( localizedDefaultFolderName( contentsType ) ), labels ); if ( !selected.isEmpty() ) - result.folder = result.folders[ labels.findIndex( selected ) ]; + result.folder = result.folders[ labels.tqfindIndex( selected ) ]; } KMFolder* folder = result.folder; @@ -2017,7 +2017,7 @@ KMFolder* KMailICalIfaceImpl::initFolder( KMail::FolderContentsType contentsType if( folder->canAccess() != 0 ) { KMessageBox::sorry(0, i18n("You do not have read/write permission to your %1 folder.") - .arg( folderName( itemType ) ) ); + .tqarg( folderName( itemType ) ) ); return 0; } folder->storage()->setContentsType( contentsType ); diff --git a/kmail/kmcommands.cpp b/kmail/kmcommands.cpp index 1473d3d6e..ba4a84e7a 100644 --- a/kmail/kmcommands.cpp +++ b/kmail/kmcommands.cpp @@ -586,7 +586,7 @@ KMUrlCopyCommand::KMUrlCopyCommand( const KURL &url, KMMainWidget *mainWidget ) KMCommand::Result KMUrlCopyCommand::execute() { - TQClipboard* clip = TQApplication::clipboard(); + TQClipboard* clip = TQApplication::tqclipboard(); if (mUrl.protocol() == "mailto") { // put the url into the mouse selection and the clipboard @@ -640,7 +640,7 @@ KMCommand::Result KMUrlSaveCommand::execute() { if (KMessageBox::warningContinueCancel(0, i18n("<qt>File <b>%1</b> exists.<br>Do you want to replace it?</qt>") - .arg(saveUrl.prettyURL()), i18n("Save to File"), i18n("&Replace")) + .tqarg(saveUrl.prettyURL()), i18n("Save to File"), i18n("&Replace")) != KMessageBox::Continue) return Canceled; } @@ -963,7 +963,7 @@ void KMSaveMsgCommand::slotSaveResult(KIO::Job *job) { if (KMessageBox::warningContinueCancel(0, i18n("File %1 exists.\nDo you want to replace it?") - .arg(mUrl.prettyURL()), i18n("Save to File"), i18n("&Replace")) + .tqarg(mUrl.prettyURL()), i18n("Save to File"), i18n("&Replace")) == KMessageBox::Continue) { mOffset = 0; @@ -1397,12 +1397,12 @@ KMCommand::Result KMForwardDigestCommand::execute() msgPartText += "--"; msgPartText += TQString::tqfromLatin1( boundary ); msgPartText += "\nContent-Type: MESSAGE/RFC822"; - msgPartText += TQString( "; CHARSET=%1" ).arg( msg->charset() ); + msgPartText += TQString( "; CHARSET=%1" ).tqarg( TQString(msg->charset()) ); msgPartText += '\n'; DwHeaders dwh; dwh.MessageId().CreateDefault(); - msgPartText += TQString( "Content-ID: %1\n" ).arg( dwh.MessageId().AsString().c_str() ); - msgPartText += TQString( "Content-Description: %1" ).arg( msg->subject() ); + msgPartText += TQString( "Content-ID: %1\n" ).tqarg( dwh.MessageId().AsString().c_str() ); + msgPartText += TQString( "Content-Description: %1" ).tqarg( msg->subject() ); if ( !msg->subject().tqcontains( "(fwd)" ) ) msgPartText += " (fwd)"; msgPartText += "\n\n"; @@ -1430,7 +1430,7 @@ KMCommand::Result KMForwardDigestCommand::execute() msgPart->setSubtypeStr( tmp ); msgPart->setName( "unnamed" ); msgPart->setCte( DwMime::kCte7bit ); // does it have to be 7bit? - msgPart->setContentDescription( TQString( "Digest of %1 messages." ).arg( msgCnt ) ); + msgPart->setContentDescription( TQString( "Digest of %1 messages." ).tqarg( msgCnt ) ); // THIS HAS TO BE AFTER setCte()!!!! msgPart->setBodyEncoded( TQCString( msgPartText.ascii() ) ); KCursorSaver busy( KBusyPtr::busy() ); @@ -1741,7 +1741,7 @@ KMCommand::Result KMFilterActionCommand::execute() if ( diff < 10 || !( msgCount % 20 ) || msgCount <= 10 ) { progressItem->updateProgress(); TQString statusMsg = i18n("Filtering message %1 of %2"); - statusMsg = statusMsg.arg( msgCount ).arg( msgCountToFilter ); + statusMsg = statusMsg.tqarg( msgCount ).tqarg( msgCountToFilter ); KPIM::BroadcastqStatus::instance()->seStatusMsg( statusMsg ); KApplication::kApplication()->eventLoop()->processEvents( TQEventLoop::ExcludeUserInput, 50 ); } @@ -1849,7 +1849,7 @@ void KMMenuCommand::folderToPopupMenu(bool move, { while ( menu->count() ) { - TQPopupMenu *popup = menu->findItem( menu->idAt( 0 ) )->popup(); + TQPopupMenu *popup = menu->tqfindItem( menu->idAt( 0 ) )->popup(); if (popup) delete popup; else @@ -1995,7 +1995,7 @@ KMCommand::Result KMCopyCommand::execute() // corrupt IMAP cache, see FolderStorage::getMsg() if ( msg == 0 ) { KMessageBox::error( tqparentWidget(), i18n("Corrupt IMAP cache detected in folder %1. " - "Copying of messages aborted.").arg( srcFolder->prettyURL() ) ); + "Copying of messages aborted.").tqarg( srcFolder->prettyURL() ) ); deleteLater(); return Failed; } @@ -2461,7 +2461,7 @@ KMCommand::Result KMUrlClickedCommand::execute() mime->name() == "application/x-shellscript" ) { if (KMessageBox::warningYesNo( 0, i18n( "<qt>Do you really want to execute <b>%1</b>?</qt>" ) - .arg( mUrl.prettyURL() ), TQString(), i18n("Execute"), KStdGuiItem::cancel() ) != KMessageBox::Yes) + .tqarg( mUrl.prettyURL() ), TQString(), i18n("Execute"), KStdGuiItem::cancel() ) != KMessageBox::Yes) return Canceled; } KRun * runner = new KRun( mUrl ); @@ -2605,7 +2605,7 @@ void KMSaveAttachmentsCommand::slotSaveAll() ++unnamedAtmCount; s = i18n("filename for the %1-th unnamed attachment", "attachment.%1") - .arg( unnamedAtmCount ); + .tqarg( unnamedAtmCount ); } curUrl.setFileName( s ); } else { @@ -2622,7 +2622,7 @@ void KMSaveAttachmentsCommand::slotSaveAll() while ( renameNumbering.tqcontains(file) ) { file = origFile; int num = renameNumbering[file] + 1; - int dotIdx = file.findRev('.'); + int dotIdx = file.tqfindRev('.'); file = file.insert( (dotIdx>=0) ? dotIdx : file.length(), TQString("_") + TQString::number(num) ); } curUrl.setFileName(file); @@ -2644,7 +2644,7 @@ void KMSaveAttachmentsCommand::slotSaveAll() if ( KIO::NetAccess::exists( curUrl, false, tqparentWidget() ) ) { if ( KMessageBox::warningContinueCancel( tqparentWidget(), i18n( "A file named %1 already exists. Do you want to overwrite it?" ) - .arg( curUrl.fileName() ), + .tqarg( curUrl.fileName() ), i18n( "File Already Exists" ), i18n("&Overwrite") ) == KMessageBox::Cancel) { continue; } @@ -2752,8 +2752,8 @@ KMCommand::Result KMSaveAttachmentsCommand::saveItem( partNode *node, KMessageBox::error( tqparentWidget(), i18n( "%2 is detailed error description", "Could not write the file %1:\n%2" ) - .arg( file.name() ) - .arg( TQString::fromLocal8Bit( strerror( errno ) ) ), + .tqarg( file.name() ) + .tqarg( TQString::fromLocal8Bit( strerror( errno ) ) ), i18n( "KMail Error" ) ); return Failed; } @@ -2777,7 +2777,7 @@ KMCommand::Result KMSaveAttachmentsCommand::saveItem( partNode *node, { KMessageBox::error( tqparentWidget(), i18n( "Could not write the file %1." ) - .arg( url.path() ), + .tqarg( url.path() ), i18n( "KMail Error" ) ); return Failed; } @@ -3012,7 +3012,7 @@ KMCommand::Result KMIMChatCommand::execute() nameList.append( (*it).realName() ); } TQString names = nameList.join( TQString::tqfromLatin1( ",\n" ) ); - apology = apology.arg( names ); + apology = apology.tqarg( names ); } KMessageBox::sorry( tqparentWidget(), apology ); @@ -3216,7 +3216,7 @@ void KMHandleAttachmentCommand::atmEncryptWithChiasmus() return; // FIXME: better detection of mimetype?? - if ( !mAtmName.endsWith( ".xia", false ) ) + if ( !mAtmName.tqendsWith( ".xia", false ) ) return; const Kleo::CryptoBackend::Protocol * chiasmus = @@ -3297,7 +3297,7 @@ void KMHandleAttachmentCommand::atmEncryptWithChiasmus() } static const TQString chomp( const TQString & base, const TQString & suffix, bool cs ) { - return base.endsWith( suffix, cs ) ? base.left( base.length() - suffix.length() ) : base ; + return base.tqendsWith( suffix, cs ) ? base.left( base.length() - suffix.length() ) : base ; } void KMHandleAttachmentCommand::slotAtmDecryptWithChiasmusResult( const GpgME::Error & err, const TQVariant & result ) @@ -3563,8 +3563,8 @@ KMCommand::Result CreateTodoCommand::execute() KMail::KorgHelper::ensureRunning(); - TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").arg( msg->from() ) - .arg( msg->to() ).arg( msg->subject() ); + TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").tqarg( msg->from() ) + .tqarg( msg->to() ).tqarg( msg->subject() ); KTempFile tf; tf.setAutoDelete( true ); @@ -3573,7 +3573,7 @@ KMCommand::Result CreateTodoCommand::execute() tf.close(); KCalendarIface_stub *iface = new KCalendarIface_stub( kapp->dcopClient(), "korganizer", "CalendarIface" ); - iface->openTodoEditor( i18n("Mail: %1").arg( msg->subject() ), txt, uri, + iface->openTodoEditor( i18n("Mail: %1").tqarg( msg->subject() ), txt, uri, tf.name(), TQStringList(), "message/rfc822", true ); delete iface; diff --git a/kmail/kmcomposewin.cpp b/kmail/kmcomposewin.cpp index 98a5c6e0a..ff4659c86 100644 --- a/kmail/kmcomposewin.cpp +++ b/kmail/kmcomposewin.cpp @@ -196,10 +196,10 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id ) setInstance( kmkernel->xmlGuiInstance() ); mMainWidget = new TQWidget(this); // splitter between the headers area and the actual editor - mHeadersToEditorSplitter = new TQSplitter( TQt::Vertical, mMainWidget, "mHeadersToEditorSplitter" ); + mHeadersToEditorSplitter = new TQSplitter( Qt::Vertical, mMainWidget, "mHeadersToEditorSplitter" ); mHeadersToEditorSplitter->setChildrenCollapsible( false ); mHeadersArea = new TQWidget( mHeadersToEditorSplitter ); - mHeadersArea->tqsetSizePolicy( mHeadersToEditorSplitter->sizePolicy().horData(), TQSizePolicy::Maximum ); + mHeadersArea->tqsetSizePolicy( mHeadersToEditorSplitter->tqsizePolicy().horData(), TQSizePolicy::Maximum ); TQVBoxLayout *v = new TQVBoxLayout( mMainWidget ); v->addWidget( mHeadersToEditorSplitter ); mIdentity = new KPIM::IdentityCombo(kmkernel->identityManager(), mHeadersArea); @@ -250,10 +250,10 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id ) TQToolTip::add( mBtnCc, tip ); TQToolTip::add( mBtnBcc, tip ); - mBtnTo->setFocusPolicy(TQWidget::NoFocus); - mBtnCc->setFocusPolicy(TQWidget::NoFocus); - mBtnBcc->setFocusPolicy(TQWidget::NoFocus); - //mBtnFrom->setFocusPolicy(TQWidget::NoFocus); + mBtnTo->setFocusPolicy(Qt::NoFocus); + mBtnCc->setFocusPolicy(Qt::NoFocus); + mBtnBcc->setFocusPolicy(Qt::NoFocus); + //mBtnFrom->setFocusPolicy(Qt::NoFocus); connect(mBtnTo,TQT_SIGNAL(clicked()),TQT_SLOT(slotAddrBookTo())); connect(mBtnCc,TQT_SIGNAL(clicked()),TQT_SLOT(slotAddrBookTo())); @@ -331,9 +331,9 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id ) mFixedFontAction = 0; mTempDir = 0; // the attachment view is separated from the editor by a splitter - mSplitter = new TQSplitter( TQt::Vertical, mHeadersToEditorSplitter, "mSplitter" ); + mSplitter = new TQSplitter( Qt::Vertical, mHeadersToEditorSplitter, "mSplitter" ); mSplitter->setChildrenCollapsible( false ); - mSnippetSplitter = new TQSplitter( TQt::Horizontal, mSplitter, "mSnippetSplitter"); + mSnippetSplitter = new TQSplitter( Qt::Horizontal, mSplitter, "mSnippetSplitter"); mSnippetSplitter->setChildrenCollapsible( false ); TQWidget *editorAndCryptoStateIndicators = new TQWidget( mSnippetSplitter ); @@ -386,10 +386,10 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id ) setCaption( i18n("Composer") ); setMinimumSize(200,200); - mBtnIdentity->setFocusPolicy(TQWidget::NoFocus); - mBtnFcc->setFocusPolicy(TQWidget::NoFocus); - mBtnTransport->setFocusPolicy(TQWidget::NoFocus); - mBtnDictionary->setFocusPolicy( TQWidget::NoFocus ); + mBtnIdentity->setFocusPolicy(Qt::NoFocus); + mBtnFcc->setFocusPolicy(Qt::NoFocus); + mBtnTransport->setFocusPolicy(Qt::NoFocus); + mBtnDictionary->setFocusPolicy( Qt::NoFocus ); mAtmListView = new AttachmentListView( this, mSplitter, "attachment list view" ); @@ -456,7 +456,7 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id ) connect(kmkernel->dimapFolderMgr(),TQT_SIGNAL(folderRemoved(KMFolder*)), TQT_SLOT(slotFolderRemoved(KMFolder*))); connect( kmkernel, TQT_SIGNAL( configChanged() ), - this, TQT_SLOT( slotConfigChanged() ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotConfigChanged() ) ); connect (mEditor, TQT_SIGNAL (spellcheck_done(int)), this, TQT_SLOT (slotSpellcheckDone (int))); @@ -648,8 +648,8 @@ bool KMComposeWin::event(TQEvent *e) void KMComposeWin::readColorConfig(void) { if ( GlobalSettings::self()->useDefaultColors() ) { - mForeColor = TQColor(kapp->palette().active().text()); - mBackColor = TQColor(kapp->palette().active().base()); + mForeColor = TQColor(kapp->tqpalette().active().text()); + mBackColor = TQColor(kapp->tqpalette().active().base()); } else { mForeColor = GlobalSettings::self()->foregroundColor(); mBackColor = GlobalSettings::self()->backgroundColor(); @@ -787,7 +787,7 @@ void KMComposeWin::writeConfig(void) mAutoSpellCheckingAction->isChecked() ); TQStringList transportHistory = GlobalSettings::self()->transportHistory(); transportHistory.remove(mTransport->currentText()); - if (KMTransportInfo::availableTransports().findIndex(mTransport + if (KMTransportInfo::availableTransports().tqfindIndex(mTransport ->currentText()) == -1) { transportHistory.prepend(mTransport->currentText()); } @@ -817,7 +817,7 @@ void KMComposeWin::autoSaveMessage() mAutoSaveTimer->stop(); connect( this, TQT_SIGNAL( applyChangesDone( bool ) ), - this, TQT_SLOT( slotContinueAutoSave() ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotContinueAutoSave() ) ); // This method is called when KMail crashed, so don't try signing/encryption // and don't disable controls because it is also called from a timer and // then the disabling is distracting. @@ -829,7 +829,7 @@ void KMComposeWin::autoSaveMessage() void KMComposeWin::slotContinueAutoSave() { disconnect( this, TQT_SIGNAL( applyChangesDone( bool ) ), - this, TQT_SLOT( slotContinueAutoSave() ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotContinueAutoSave() ) ); // Ok, it's done now - continue dead letter saving if ( mComposedMessages.isEmpty() ) { @@ -868,7 +868,7 @@ void KMComposeWin::slotContinueAutoSave() i18n("Autosaving the message as %1 " "failed.\n" "Reason: %2" ) - .arg( filename, strerror( status ) ), + .tqarg( filename, strerror( status ) ), i18n("Autosaving Failed") ); mLastAutoSaveErrno = status; } @@ -888,7 +888,7 @@ void KMComposeWin::slotView(void) //This sucks awfully, but no, I cannot get an activated(int id) from // actionContainer() - if (!sender()->isA("KToggleAction")) + if (!TQT_TQOBJECT(sender())->isA("KToggleAction")) return; KToggleAction *act = (KToggleAction *) sender(); @@ -1234,13 +1234,13 @@ void KMComposeWin::setupActions(void) { //default = send now, alternative = queue ( void ) new KAction( i18n("&Send Mail"), "mail_send", CTRL+Key_Return, - this, TQT_SLOT(slotSendNow()), actionCollection(),"send_default"); + TQT_TQOBJECT(this), TQT_SLOT(slotSendNow()), actionCollection(),"send_default"); // FIXME: change to mail_send_via icon when this exits. actActionNowMenu = new KActionMenu (i18n("&Send Mail Via"), "mail_send", actionCollection(), "send_default_via" ); - (void) new KAction (i18n("Send &Later"), "queue", 0, this, + (void) new KAction (i18n("Send &Later"), "queue", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSendLater()), actionCollection(),"send_alternative"); actActionLaterMenu = new KActionMenu (i18n("Send &Later Via"), "queue", actionCollection(), "send_alternative_via" ); @@ -1251,12 +1251,12 @@ void KMComposeWin::setupActions(void) //default = queue, alternative = send now (void) new KAction (i18n("Send &Later"), "queue", CTRL+Key_Return, - this, TQT_SLOT(slotSendLater()), actionCollection(),"send_default"); + TQT_TQOBJECT(this), TQT_SLOT(slotSendLater()), actionCollection(),"send_default"); actActionLaterMenu = new KActionMenu (i18n("Send &Later Via"), "queue", actionCollection(), "send_default_via" ); ( void ) new KAction( i18n("&Send Mail"), "mail_send", 0, - this, TQT_SLOT(slotSendNow()), actionCollection(),"send_alternative"); + TQT_TQOBJECT(this), TQT_SLOT(slotSendNow()), actionCollection(),"send_alternative"); // FIXME: change to mail_send_via icon when this exits. actActionNowMenu = new KActionMenu (i18n("&Send Mail Via"), "mail_send", @@ -1291,78 +1291,78 @@ void KMComposeWin::setupActions(void) (void) new KAction (i18n("Save as &Draft"), "filesave", 0, - this, TQT_SLOT(slotSaveDraft()), + TQT_TQOBJECT(this), TQT_SLOT(slotSaveDraft()), actionCollection(), "save_in_drafts"); (void) new KAction (i18n("Save as &Template"), "filesave", 0, - this, TQT_SLOT(slotSaveTemplate()), + TQT_TQOBJECT(this), TQT_SLOT(slotSaveTemplate()), actionCollection(), "save_in_templates"); (void) new KAction (i18n("&Insert File..."), "fileopen", 0, - this, TQT_SLOT(slotInsertFile()), + TQT_TQOBJECT(this), TQT_SLOT(slotInsertFile()), actionCollection(), "insert_file"); mRecentAction = new KRecentFilesAction (i18n("&Insert File Recent"), "fileopen", 0, - this, TQT_SLOT(slotInsertRecentFile(const KURL&)), + TQT_TQOBJECT(this), TQT_SLOT(slotInsertRecentFile(const KURL&)), actionCollection(), "insert_file_recent"); mRecentAction->loadEntries( KMKernel::config() ); (void) new KAction (i18n("&Address Book"), "contents",0, - this, TQT_SLOT(slotAddrBook()), + TQT_TQOBJECT(this), TQT_SLOT(slotAddrBook()), actionCollection(), "addressbook"); (void) new KAction (i18n("&New Composer"), "mail_new", KStdAccel::shortcut(KStdAccel::New), - this, TQT_SLOT(slotNewComposer()), + TQT_TQOBJECT(this), TQT_SLOT(slotNewComposer()), actionCollection(), "new_composer"); (void) new KAction (i18n("New Main &Window"), "window_new", 0, - this, TQT_SLOT(slotNewMailReader()), + TQT_TQOBJECT(this), TQT_SLOT(slotNewMailReader()), actionCollection(), "open_mailreader"); if ( !mClassicalRecipients ) { - new KAction( i18n("Select &Recipients..."), CTRL + Key_L, mRecipientsEditor, + new KAction( i18n("Select &Recipients..."), CTRL + Key_L, TQT_TQOBJECT(mRecipientsEditor), TQT_SLOT( selectRecipients() ), actionCollection(), "select_recipients" ); - new KAction( i18n("Save &Distribution List..."), 0, mRecipientsEditor, + new KAction( i18n("Save &Distribution List..."), 0, TQT_TQOBJECT(mRecipientsEditor), TQT_SLOT( saveDistributionList() ), actionCollection(), "save_distribution_list" ); } - //KStdAction::save(this, TQT_SLOT(), actionCollection(), "save_message"); - KStdAction::print (this, TQT_SLOT(slotPrint()), actionCollection()); - KStdAction::close (this, TQT_SLOT(slotClose()), actionCollection()); + //KStdAction::save(TQT_TQOBJECT(this), TQT_SLOT(), actionCollection(), "save_message"); + KStdAction::print (TQT_TQOBJECT(this), TQT_SLOT(slotPrint()), actionCollection()); + KStdAction::close (TQT_TQOBJECT(this), TQT_SLOT(slotClose()), actionCollection()); - KStdAction::undo (this, TQT_SLOT(slotUndo()), actionCollection()); - KStdAction::redo (this, TQT_SLOT(slotRedo()), actionCollection()); - KStdAction::cut (this, TQT_SLOT(slotCut()), actionCollection()); - KStdAction::copy (this, TQT_SLOT(slotCopy()), actionCollection()); - KStdAction::pasteText (this, TQT_SLOT(slotPasteClipboard()), actionCollection()); - KStdAction::selectAll (this, TQT_SLOT(slotMarkAll()), actionCollection()); + KStdAction::undo (TQT_TQOBJECT(this), TQT_SLOT(slotUndo()), actionCollection()); + KStdAction::redo (TQT_TQOBJECT(this), TQT_SLOT(slotRedo()), actionCollection()); + KStdAction::cut (TQT_TQOBJECT(this), TQT_SLOT(slotCut()), actionCollection()); + KStdAction::copy (TQT_TQOBJECT(this), TQT_SLOT(slotCopy()), actionCollection()); + KStdAction::pasteText (TQT_TQOBJECT(this), TQT_SLOT(slotPasteClipboard()), actionCollection()); + KStdAction::selectAll (TQT_TQOBJECT(this), TQT_SLOT(slotMarkAll()), actionCollection()); - KStdAction::tqfind (this, TQT_SLOT(slotFind()), actionCollection()); - KStdAction::findNext(this, TQT_SLOT(slotSearchAgain()), actionCollection()); + KStdAction::find (TQT_TQOBJECT(this), TQT_SLOT(slotFind()), actionCollection()); + KStdAction::findNext(TQT_TQOBJECT(this), TQT_SLOT(slotSearchAgain()), actionCollection()); - KStdAction::tqreplace (this, TQT_SLOT(slotReplace()), actionCollection()); - KStdAction::spelling (this, TQT_SLOT(slotSpellcheck()), actionCollection(), "spellcheck"); + KStdAction::replace (TQT_TQOBJECT(this), TQT_SLOT(slotReplace()), actionCollection()); + KStdAction::spelling (TQT_TQOBJECT(this), TQT_SLOT(slotSpellcheck()), actionCollection(), "spellcheck"); - mPasteQuotation = new KAction (i18n("Pa&ste as Quotation"),0,this,TQT_SLOT( slotPasteClipboardAsQuotation()), + mPasteQuotation = new KAction (i18n("Pa&ste as Quotation"),0,TQT_TQOBJECT(this),TQT_SLOT( slotPasteClipboardAsQuotation()), actionCollection(), "paste_quoted"); - (void) new KAction (i18n("Paste as Attac&hment"),0,this,TQT_SLOT( slotPasteClipboardAsAttachment()), + (void) new KAction (i18n("Paste as Attac&hment"),0,TQT_TQOBJECT(this),TQT_SLOT( slotPasteClipboardAsAttachment()), actionCollection(), "paste_att"); - KAction * addq = new KAction(i18n("Add &Quote Characters"), 0, this, + KAction * addq = new KAction(i18n("Add &Quote Characters"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddQuotes()), actionCollection(), "tools_quote"); connect( mEditor, TQT_SIGNAL(selectionAvailable(bool)), addq, TQT_SLOT(setEnabled(bool)) ); - KAction * remq = new KAction(i18n("Re&move Quote Characters"), 0, this, + KAction * remq = new KAction(i18n("Re&move Quote Characters"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotRemoveQuotes()), actionCollection(), "tools_unquote"); connect( mEditor, TQT_SIGNAL(selectionAvailable(bool)), remq, TQT_SLOT(setEnabled(bool)) ); - (void) new KAction (i18n("Cl&ean Spaces"), 0, this, TQT_SLOT(slotCleanSpace()), + (void) new KAction (i18n("Cl&ean Spaces"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotCleanSpace()), actionCollection(), "clean_spaces"); - mFixedFontAction = new KToggleAction( i18n("Use Fi&xed Font"), 0, this, + mFixedFontAction = new KToggleAction( i18n("Use Fi&xed Font"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotUpdateFont()), actionCollection(), "toggle_fixedfont" ); mFixedFontAction->setChecked( GlobalSettings::self()->useFixedFont() ); @@ -1376,7 +1376,7 @@ void KMComposeWin::setupActions(void) mRequestMDNAction->setChecked(GlobalSettings::self()->requestMDN()); //----- Message-Encoding Submenu mEncodingAction = new KSelectAction( i18n( "Se&t Encoding" ), "charset", - 0, this, TQT_SLOT(slotSetCharset() ), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetCharset() ), actionCollection(), "charsets" ); mWordWrapAction = new KToggleAction (i18n("&Wordwrap"), 0, actionCollection(), "wordwrap"); @@ -1396,7 +1396,7 @@ void KMComposeWin::setupActions(void) mAutoSpellCheckingAction->setChecked( !GlobalSettings::self()->useExternalEditor() && spellChecking ); slotAutoSpellCheckingToggled( !GlobalSettings::self()->useExternalEditor() && spellChecking ); connect( mAutoSpellCheckingAction, TQT_SIGNAL( toggled( bool ) ), - this, TQT_SLOT( slotAutoSpellCheckingToggled( bool ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotAutoSpellCheckingToggled( bool ) ) ); TQStringList encodings = KMMsgBase::supportedEncodings(true); encodings.prepend( i18n("Auto-Detect")); @@ -1404,84 +1404,84 @@ void KMComposeWin::setupActions(void) mEncodingAction->setCurrentItem( -1 ); //these are checkable!!! - markupAction = new KToggleAction (i18n("Formatting (HTML)"), 0, this, + markupAction = new KToggleAction (i18n("Formatting (HTML)"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleMarkup()), actionCollection(), "html"); - mAllFieldsAction = new KToggleAction (i18n("&All Fields"), 0, this, + mAllFieldsAction = new KToggleAction (i18n("&All Fields"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_all_fields"); - mIdentityAction = new KToggleAction (i18n("&Identity"), 0, this, + mIdentityAction = new KToggleAction (i18n("&Identity"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_identity"); - mDictionaryAction = new KToggleAction (i18n("&Dictionary"), 0, this, + mDictionaryAction = new KToggleAction (i18n("&Dictionary"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_dictionary"); - mFccAction = new KToggleAction (i18n("&Sent-Mail Folder"), 0, this, + mFccAction = new KToggleAction (i18n("&Sent-Mail Folder"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_fcc"); - mTransportAction = new KToggleAction (i18n("&Mail Transport"), 0, this, + mTransportAction = new KToggleAction (i18n("&Mail Transport"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_transport"); - mFromAction = new KToggleAction (i18n("&From"), 0, this, + mFromAction = new KToggleAction (i18n("&From"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_from"); - mReplyToAction = new KToggleAction (i18n("&Reply To"), 0, this, + mReplyToAction = new KToggleAction (i18n("&Reply To"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_reply_to"); if ( mClassicalRecipients ) { - mToAction = new KToggleAction (i18n("&To"), 0, this, + mToAction = new KToggleAction (i18n("&To"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_to"); - mCcAction = new KToggleAction (i18n("&CC"), 0, this, + mCcAction = new KToggleAction (i18n("&CC"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_cc"); - mBccAction = new KToggleAction (i18n("&BCC"), 0, this, + mBccAction = new KToggleAction (i18n("&BCC"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_bcc"); } - mSubjectAction = new KToggleAction (i18n("S&ubject"), 0, this, + mSubjectAction = new KToggleAction (i18n("S&ubject"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotView()), actionCollection(), "show_subject"); //end of checkable - mAppendSignatureAction = new KAction (i18n("Append S&ignature"), 0, this, + mAppendSignatureAction = new KAction (i18n("Append S&ignature"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAppendSignature()), actionCollection(), "append_signature"); - mPrependSignatureAction = new KAction (i18n("Prepend S&ignature"), 0, this, + mPrependSignatureAction = new KAction (i18n("Prepend S&ignature"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotPrependSignature()), actionCollection(), "prepend_signature"); - mInsertSignatureAction = new KAction (i18n("Insert Signature At C&ursor Position"), "edit", 0, this, + mInsertSignatureAction = new KAction (i18n("Insert Signature At C&ursor Position"), "edit", 0, TQT_TQOBJECT(this), TQT_SLOT(slotInsertSignatureAtCursor()), actionCollection(), "insert_signature_at_cursor_position"); - mAttachPK = new KAction (i18n("Attach &Public Key..."), 0, this, + mAttachPK = new KAction (i18n("Attach &Public Key..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotInsertPublicKey()), actionCollection(), "attach_public_key"); - mAttachMPK = new KAction (i18n("Attach &My Public Key"), 0, this, + mAttachMPK = new KAction (i18n("Attach &My Public Key"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotInsertMyPublicKey()), actionCollection(), "attach_my_public_key"); (void) new KAction (i18n("&Attach File..."), "attach", - 0, this, TQT_SLOT(slotAttachFile()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotAttachFile()), actionCollection(), "attach"); - mAttachRemoveAction = new KAction (i18n("&Remove Attachment"), 0, this, + mAttachRemoveAction = new KAction (i18n("&Remove Attachment"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAttachRemove()), actionCollection(), "remove"); mAttachSaveAction = new KAction (i18n("&Save Attachment As..."), "filesave",0, - this, TQT_SLOT(slotAttachSave()), + TQT_TQOBJECT(this), TQT_SLOT(slotAttachSave()), actionCollection(), "attach_save"); - mAttachPropertiesAction = new KAction (i18n("Attachment Pr&operties"), 0, this, + mAttachPropertiesAction = new KAction (i18n("Attachment Pr&operties"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAttachProperties()), actionCollection(), "attach_properties"); setStandardToolBarMenuEnabled(true); - KStdAction::keyBindings(this, TQT_SLOT(slotEditKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(slotEditToolbars()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(slotEditKeys()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotEditToolbars()), actionCollection()); KStdAction::preferences(kmkernel, TQT_SLOT(slotShowConfigurationDialog()), actionCollection()); - (void) new KAction (i18n("&Spellchecker..."), 0, this, TQT_SLOT(slotSpellcheckConfig()), + (void) new KAction (i18n("&Spellchecker..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotSpellcheckConfig()), actionCollection(), "setup_spellchecker"); if ( Kleo::CryptoBackendFactory::instance()->protocol( "Chiasmus" ) ) { @@ -1491,7 +1491,7 @@ void KMComposeWin::setupActions(void) a->setCheckedState( KGuiItem( i18n( "Encrypt Message with Chiasmus..." ), "chiencrypted" ) ); mEncryptChiasmusAction = a; connect( mEncryptChiasmusAction, TQT_SIGNAL(toggled(bool)), - this, TQT_SLOT(slotEncryptChiasmusToggled(bool)) ); + TQT_TQOBJECT(this), TQT_SLOT(slotEncryptChiasmusToggled(bool)) ); } else { mEncryptChiasmusAction = 0; } @@ -1547,7 +1547,7 @@ void KMComposeWin::setupActions(void) l.push_back( Kleo::cryptoMessageFormatToLabel( cryptoMessageFormats[i] ) ); mCryptoModuleAction = new KSelectAction( i18n( "&Cryptographic Message Format" ), 0, - this, TQT_SLOT(slotSelectCryptoModule()), + TQT_TQOBJECT(this), TQT_SLOT(slotSelectCryptoModule()), actionCollection(), "options_select_crypto" ); mCryptoModuleAction->setItems( l ); mCryptoModuleAction->setCurrentItem( format2cb( ident.preferredCryptoMessageFormat() ) ); @@ -1581,36 +1581,36 @@ void KMComposeWin::setupActions(void) TQT_SLOT( slotSizeAction( int ) ) ); alignLeftAction = new KToggleAction (i18n("Align Left"), "text_left", 0, - this, TQT_SLOT(slotAlignLeft()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(slotAlignLeft()), actionCollection(), "align_left"); alignLeftAction->setChecked( true ); alignRightAction = new KToggleAction (i18n("Align Right"), "text_right", 0, - this, TQT_SLOT(slotAlignRight()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(slotAlignRight()), actionCollection(), "align_right"); alignCenterAction = new KToggleAction (i18n("Align Center"), "text_center", 0, - this, TQT_SLOT(slotAlignCenter()), actionCollection(), + TQT_TQOBJECT(this), TQT_SLOT(slotAlignCenter()), actionCollection(), "align_center"); textBoldAction = new KToggleAction( i18n("&Bold"), "text_bold", CTRL+Key_B, - this, TQT_SLOT(slotTextBold()), + TQT_TQOBJECT(this), TQT_SLOT(slotTextBold()), actionCollection(), "text_bold"); textItalicAction = new KToggleAction( i18n("&Italic"), "text_italic", CTRL+Key_I, - this, TQT_SLOT(slotTextItalic()), + TQT_TQOBJECT(this), TQT_SLOT(slotTextItalic()), actionCollection(), "text_italic"); textUnderAction = new KToggleAction( i18n("&Underline"), "text_under", CTRL+Key_U, - this, TQT_SLOT(slotTextUnder()), + TQT_TQOBJECT(this), TQT_SLOT(slotTextUnder()), actionCollection(), "text_under"); actionFormatReset = new KAction( i18n( "Reset Font Settings" ), "eraser", 0, - this, TQT_SLOT( slotFormatReset() ), + TQT_TQOBJECT(this), TQT_SLOT( slotFormatReset() ), actionCollection(), "format_reset"); actionFormatColor = new KAction( i18n( "Text Color..." ), "colorize", 0, - this, TQT_SLOT( slotTextColor() ), + TQT_TQOBJECT(this), TQT_SLOT( slotTextColor() ), actionCollection(), "format_color"); // editorFocusChanged(false); createGUI("kmcomposerui.rc"); connect( toolBar("htmlToolBar"), TQT_SIGNAL( visibilityChanged(bool) ), - this, TQT_SLOT( htmlToolBarVisibilityChanged(bool) ) ); + TQT_TQOBJECT(this), TQT_SLOT( htmlToolBarVisibilityChanged(bool) ) ); // In Kontact, this entry would read "Configure Kontact", but bring // up KMail's config dialog. That's sensible, though, so fix the label. @@ -1625,9 +1625,9 @@ void KMComposeWin::setupStatusBar(void) statusBar()->insertItem("", 0, 1); statusBar()->setItemAlignment(0, AlignLeft | AlignVCenter); - statusBar()->insertItem(i18n( " Spellcheck: %1 ").arg( " " ), 3, 0, true ); - statusBar()->insertItem(i18n( " Column: %1 ").arg(" "), 2, 0, true); - statusBar()->insertItem(i18n( " Line: %1 ").arg(" "), 1, 0, true); + statusBar()->insertItem(i18n( " Spellcheck: %1 ").tqarg( " " ), 3, 0, true ); + statusBar()->insertItem(i18n( " Column: %1 ").tqarg(" "), 2, 0, true); + statusBar()->insertItem(i18n( " Line: %1 ").tqarg(" "), 1, 0, true); } @@ -1638,9 +1638,9 @@ void KMComposeWin::updateCursorPosition() TQString temp; line = mEditor->currentLine(); col = mEditor->currentColumn(); - temp = i18n(" Line: %1 ").arg(line+1); + temp = i18n(" Line: %1 ").tqarg(line+1); statusBar()->changeItem(temp,1); - temp = i18n(" Column: %1 ").arg(col+1); + temp = i18n(" Column: %1 ").tqarg(col+1); statusBar()->changeItem(temp,2); } @@ -1683,9 +1683,9 @@ void KMComposeWin::setupEditor(void) updateCursorPosition(); connect(mEditor,TQT_SIGNAL(CursorPositionChanged()),TQT_SLOT(updateCursorPosition())); connect( mEditor, TQT_SIGNAL( currentFontChanged( const TQFont & ) ), - this, TQT_SLOT( fontChanged( const TQFont & ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( fontChanged( const TQFont & ) ) ); connect( mEditor, TQT_SIGNAL( currentAlignmentChanged( int ) ), - this, TQT_SLOT( tqalignmentChanged( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( tqalignmentChanged( int ) ) ); } @@ -1876,14 +1876,14 @@ void KMComposeWin::setMsg(KMMessage* newMsg, bool mayAutoSign, // unless the identity is sticky if ( !stickyIdentity ) { disconnect(mIdentity,TQT_SIGNAL(identityChanged(uint)), - this, TQT_SLOT(slotIdentityChanged(uint))); + TQT_TQOBJECT(this), TQT_SLOT(slotIdentityChanged(uint))); } // load the mId into the gui, sticky or not, without emitting mIdentity->setCurrentIdentity( mId ); const uint idToApply = mId; if ( !stickyIdentity ) { connect(mIdentity,TQT_SIGNAL(identityChanged(uint)), - this, TQT_SLOT(slotIdentityChanged(uint))); + TQT_TQOBJECT(this), TQT_SLOT(slotIdentityChanged(uint))); } else { // load the message's state into the mId, without applying it to the gui // that's so we can detect that the id changed (because a sticky was set) @@ -2345,7 +2345,7 @@ void KMComposeWin::applyChanges( bool dontSignNorEncrypt, bool dontDisable ) // Make new job and execute it mComposer = new MessageComposer( this ); connect( mComposer, TQT_SIGNAL( done( bool ) ), - this, TQT_SLOT( slotComposerDone( bool ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotComposerDone( bool ) ) ); // TODO: Add a cancel button for the following operations? // Disable any input to the window, so that we have a snapshot of the @@ -2399,14 +2399,14 @@ bool KMComposeWin::addAttach(const KURL aUrl) if ( !aUrl.isValid() ) { KMessageBox::sorry( this, i18n( "<qt><p>KMail could not recognize the location of the attachment (%1);</p>" "<p>you have to specify the full path if you wish to attach a file.</p></qt>" ) - .arg( aUrl.prettyURL() ) ); + .tqarg( aUrl.prettyURL() ) ); return false; } const int maxAttachmentSize = GlobalSettings::maximumAttachmentSize(); const uint maximumAttachmentSizeInByte = maxAttachmentSize*1024*1024; if ( aUrl.isLocalFile() && TQFileInfo( aUrl.pathOrURL() ).size() > maximumAttachmentSizeInByte ) { - KMessageBox::sorry( this, i18n( "<qt><p>Your administrator has disallowed attaching files bigger than %1 MB.</p>" ).arg( maxAttachmentSize ) ); + KMessageBox::sorry( this, i18n( "<qt><p>Your administrator has disallowed attaching files bigger than %1 MB.</p>" ).tqarg( maxAttachmentSize ) ); return false; } @@ -2422,9 +2422,9 @@ bool KMComposeWin::addAttach(const KURL aUrl) mMapAtmLoadData.insert(job, ld); mAttachJobs[job] = aUrl; connect(job, TQT_SIGNAL(result(KIO::Job *)), - this, TQT_SLOT(slotAttachFileResult(KIO::Job *))); + TQT_TQOBJECT(this), TQT_SLOT(slotAttachFileResult(KIO::Job *))); connect(job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), - this, TQT_SLOT(slotAttachFileData(KIO::Job *, const TQByteArray &))); + TQT_TQOBJECT(this), TQT_SLOT(slotAttachFileData(KIO::Job *, const TQByteArray &))); return true; } @@ -2454,9 +2454,9 @@ void KMComposeWin::addAttach(const KMMessagePart* msgPart) } connect( lvi, TQT_SIGNAL( compress( int ) ), - this, TQT_SLOT( compressAttach( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( compressAttach( int ) ) ); connect( lvi, TQT_SIGNAL( uncompress( int ) ), - this, TQT_SLOT( uncompressAttach( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( uncompressAttach( int ) ) ); slotUpdateAttachActions(); } @@ -2847,7 +2847,7 @@ void KMComposeWin::slotAttachFileResult(KIO::Job *job) TQString ext; if( !patterns.isEmpty() ) { ext = patterns[0]; - int i = ext.findRev( '.' ); + int i = ext.tqfindRev( '.' ); if( i == -1 ) ext.prepend( '.' ); else if( i > 0 ) @@ -2998,7 +2998,7 @@ void KMComposeWin::slotInsertRecentFile(const KURL& u) KConfigGroupSaver saver( config, "Composer" ); TQStringList urls = config->readListEntry( "recent-urls" ); TQStringList encodings = config->readListEntry( "recent-encodings" ); - int index = urls.findIndex( u.prettyURL() ); + int index = urls.tqfindIndex( u.prettyURL() ); if (index != -1) { TQString encoding = encodings[ index ]; ld.encoding = encoding.latin1(); @@ -3006,9 +3006,9 @@ void KMComposeWin::slotInsertRecentFile(const KURL& u) } mMapAtmLoadData.insert(job, ld); connect(job, TQT_SIGNAL(result(KIO::Job *)), - this, TQT_SLOT(slotAttachFileResult(KIO::Job *))); + TQT_TQOBJECT(this), TQT_SLOT(slotAttachFileResult(KIO::Job *))); connect(job, TQT_SIGNAL(data(KIO::Job *, const TQByteArray &)), - this, TQT_SLOT(slotAttachFileData(KIO::Job *, const TQByteArray &))); + TQT_TQOBJECT(this), TQT_SLOT(slotAttachFileData(KIO::Job *, const TQByteArray &))); } @@ -3114,7 +3114,7 @@ static void showExportError( TQWidget * w, const GpgME::Error & err ) { const TQString msg = i18n("<qt><p>An error occurred while trying to export " "the key from the backend:</p>" "<p><b>%1</b></p></qt>") - .arg( TQString::fromLocal8Bit( err.asString() ) ); + .tqarg( TQString::fromLocal8Bit( err.asString() ) ); KMessageBox::error( w, msg, i18n("Key Export Failed") ); } @@ -3153,7 +3153,7 @@ void KMComposeWin::slotPublicKeyExportResult( const GpgME::Error & err, const TQ // create message part KMMessagePart * msgPart = new KMMessagePart(); - msgPart->setName( i18n("OpenPGP key 0x%1").arg( mFingerprint ) ); + msgPart->setName( i18n("OpenPGP key 0x%1").tqarg( mFingerprint ) ); msgPart->setTypeStr("application"); msgPart->setSubtypeStr("pgp-keys"); TQValueList<int> dummy; @@ -3291,7 +3291,7 @@ void KMComposeWin::compressAttach( int idx ) msgPart = mAtmList.at( i ); TQByteArray array; TQBuffer dev( array ); - KZip zip( &dev ); + KZip zip( &TQT_TQIODEVICE_OBJECT(dev) ); TQByteArray decoded = msgPart->bodyDecodedBinary(); if ( ! zip.open( IO_WriteOnly ) ) { KMessageBox::sorry(0, i18n("KMail could not compress the file.") ); @@ -3370,7 +3370,7 @@ void KMComposeWin::uncompressAttach( int idx ) msgPart = mAtmList.at( i ); TQBuffer dev( msgPart->bodyDecodedBinary() ); - KZip zip( &dev ); + KZip zip( &TQT_TQIODEVICE_OBJECT(dev) ); TQByteArray decoded; decoded = msgPart->bodyDecodedBinary(); @@ -3562,7 +3562,7 @@ void KMComposeWin::editAttach(int index, bool openWith) KMail::EditorWatcher *watcher = new KMail::EditorWatcher( KURL( atmTempFile->name() ), contentTypeStr, openWith, - this, this ); + TQT_TQOBJECT(this), this ); connect( watcher, TQT_SIGNAL(editDone(KMail::EditorWatcher*)), TQT_SLOT(slotEditDone(KMail::EditorWatcher*)) ); if ( watcher->start() ) { mEditorMap.insert( watcher, msgPart ); @@ -3633,7 +3633,7 @@ void KMComposeWin::slotSearchAgain() //----------------------------------------------------------------------------- void KMComposeWin::slotReplace() { - mEditor->tqreplace(); + mEditor->replace(); } //----------------------------------------------------------------------------- @@ -3665,7 +3665,7 @@ void KMComposeWin::slotPasteClipboardAsQuotation() { if( mEditor->hasFocus() && msg() ) { - TQString s = TQApplication::clipboard()->text(); + TQString s = TQApplication::tqclipboard()->text(); if (!s.isEmpty()) mEditor->insert(addQuotesToText(s)); } @@ -3673,13 +3673,13 @@ void KMComposeWin::slotPasteClipboardAsQuotation() void KMComposeWin::slotPasteClipboardAsAttachment() { - KURL url( TQApplication::clipboard()->text( TQClipboard::Clipboard ) ); + KURL url( TQApplication::tqclipboard()->text( TQClipboard::Clipboard ) ); if ( url.isValid() ) { - addAttach(TQApplication::clipboard()->text( TQClipboard::Clipboard ) ); + addAttach(TQApplication::tqclipboard()->text( TQClipboard::Clipboard ) ); return; } - TQMimeSource *mimeSource = TQApplication::clipboard()->data(); + TQMimeSource *mimeSource = TQApplication::tqclipboard()->data(); if ( TQImageDrag::canDecode(mimeSource) ) { slotAttachPNGImageData(mimeSource->tqencodedData("image/png")); } @@ -3691,7 +3691,7 @@ void KMComposeWin::slotPasteClipboardAsAttachment() KMMessagePart *msgPart = new KMMessagePart; msgPart->setName(attName); TQValueList<int> dummy; - msgPart->setBodyAndGuessCte(TQCString(TQApplication::clipboard()->text().latin1()), dummy, + msgPart->setBodyAndGuessCte(TQCString(TQApplication::tqclipboard()->text().latin1()), dummy, kmkernel->msgSender()->sendQuotedPrintable()); addAttach(msgPart); } @@ -3776,9 +3776,9 @@ void KMComposeWin::slotUndo() TQWidget* fw = tqfocusWidget(); if (!fw) return; - if ( ::qt_cast<KEdit*>(fw) ) + if ( ::tqqt_cast<KEdit*>(fw) ) static_cast<TQTextEdit*>(fw)->undo(); - else if (::qt_cast<TQLineEdit*>(fw)) + else if (::tqqt_cast<TQLineEdit*>(fw)) static_cast<TQLineEdit*>(fw)->undo(); } @@ -3787,9 +3787,9 @@ void KMComposeWin::slotRedo() TQWidget* fw = tqfocusWidget(); if (!fw) return; - if (::qt_cast<KEdit*>(fw)) + if (::tqqt_cast<KEdit*>(fw)) static_cast<KEdit*>(fw)->redo(); - else if (::qt_cast<TQLineEdit*>(fw)) + else if (::tqqt_cast<TQLineEdit*>(fw)) static_cast<TQLineEdit*>(fw)->redo(); } @@ -3799,9 +3799,9 @@ void KMComposeWin::slotCut() TQWidget* fw = tqfocusWidget(); if (!fw) return; - if (::qt_cast<KEdit*>(fw)) + if (::tqqt_cast<KEdit*>(fw)) static_cast<KEdit*>(fw)->cut(); - else if (::qt_cast<TQLineEdit*>(fw)) + else if (::tqqt_cast<TQLineEdit*>(fw)) static_cast<TQLineEdit*>(fw)->cut(); } @@ -3817,7 +3817,7 @@ void KMComposeWin::slotCopy() #endif TQKeyEvent k(TQEvent::KeyPress, Key_C, 0, ControlButton); - kapp->notify(fw, &k); + kapp->notify(TQT_TQOBJECT(fw), TQT_TQEVENT(&k)); } @@ -3832,7 +3832,7 @@ void KMComposeWin::paste( TQClipboard::Mode mode ) TQWidget* fw = tqfocusWidget(); if (!fw) return; - TQMimeSource *mimeSource = TQApplication::clipboard()->data( mode ); + TQMimeSource *mimeSource = TQApplication::tqclipboard()->data( mode ); if ( mimeSource->provides("image/png") ) { slotAttachPNGImageData(mimeSource->tqencodedData("image/png")); } else if ( KURLDrag::canDecode( mimeSource ) ) { @@ -3875,9 +3875,9 @@ void KMComposeWin::slotMarkAll() TQWidget* fw = tqfocusWidget(); if (!fw) return; - if (::qt_cast<TQLineEdit*>(fw)) + if (::tqqt_cast<TQLineEdit*>(fw)) static_cast<TQLineEdit*>(fw)->selectAll(); - else if (::qt_cast<KEdit*>(fw)) + else if (::tqqt_cast<KEdit*>(fw)) static_cast<KEdit*>(fw)->selectAll(); } @@ -4070,14 +4070,14 @@ void KMComposeWin::slotPrint() { mMessageWasModified = isModified(); connect( this, TQT_SIGNAL( applyChangesDone( bool ) ), - this, TQT_SLOT( slotContinuePrint( bool ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotContinuePrint( bool ) ) ); applyChanges( true ); } void KMComposeWin::slotContinuePrint( bool rc ) { disconnect( this, TQT_SIGNAL( applyChangesDone( bool ) ), - this, TQT_SLOT( slotContinuePrint( bool ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotContinuePrint( bool ) ) ); if( rc ) { if ( mComposedMessages.isEmpty() ) { @@ -4279,7 +4279,7 @@ bool KMComposeWin::saveDraftOrTemplate( const TQString &folderName, "identify \"%1\" does not exist (anymore); " "therefore, the default drafts or templates " "folder will be used.") - .arg( id.identityName() ) ); + .tqarg( id.identityName() ) ); } } if ( imapTheFolder && imapTheFolder->noContent() ) @@ -4321,7 +4321,7 @@ void KMComposeWin::slotContinueDoSend( bool sentOk ) kdDebug(5006) << "KMComposeWin::slotContinueDoSend( " << sentOk << " )" << endl; disconnect( this, TQT_SIGNAL( applyChangesDone( bool ) ), - this, TQT_SLOT( slotContinueDoSend( bool ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotContinueDoSend( bool ) ) ); if ( !sentOk ) { mDisableBreaking = false; @@ -4463,7 +4463,7 @@ bool KMComposeWin::checkRecipientNumber() const GlobalSettings::self()->tooManyRecipients() && mRecipientsEditor->recipients().count() > thresHold ) { if ( KMessageBox::questionYesNo( mMainWidget, - i18n("You are trying to send the mail to more than %1 recipients. Send message anyway?").arg(thresHold), + i18n("You are trying to send the mail to more than %1 recipients. Send message anyway?").tqarg(thresHold), i18n("Too many receipients"), i18n("&Send as Is"), i18n("&Edit Recipients")) == KMessageBox::No ) { @@ -4978,7 +4978,7 @@ void KMComposeWin::slotSpellcheckConfig() { KDialogBase dlg(KDialogBase::Plain, i18n("Spellchecker"), KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, - this, 0, true, true ); + TQT_TQWIDGET(this), 0, true, true ); KWin kwin; TQTabDialog qtd (this, "tabdialog", true); KSpellConfig mKSpellConfig (&qtd); @@ -5068,7 +5068,7 @@ void KMComposeWin::updateAutoSave() if ( !mAutoSaveTimer ) { mAutoSaveTimer = new TQTimer( this, "mAutoSaveTimer" ); connect( mAutoSaveTimer, TQT_SIGNAL( timeout() ), - this, TQT_SLOT( autoSaveMessage() ) ); + TQT_TQOBJECT(this), TQT_SLOT( autoSaveMessage() ) ); } mAutoSaveTimer->start( autoSaveInterval() ); } diff --git a/kmail/kmedit.cpp b/kmail/kmedit.cpp index 5442bef40..dbbb53808 100644 --- a/kmail/kmedit.cpp +++ b/kmail/kmedit.cpp @@ -241,7 +241,7 @@ KMEdit::KMEdit(TQWidget *tqparent, KMComposeWin* composer, void KMEdit::createSpellers() { delete mSpeller; - mSpeller = new KMSpell( this, TQT_SLOT( spellerReady( KSpell * ) ), mSpellConfig ); + mSpeller = new KMSpell( TQT_TQOBJECT(this), TQT_SLOT( spellerReady( KSpell * ) ), mSpellConfig ); } void KMEdit::initializeAutoSpellChecking() @@ -251,7 +251,7 @@ void KMEdit::initializeAutoSpellChecking() TQColor defaultColor1( 0x00, 0x80, 0x00 ); // defaults from kmreaderwin.cpp TQColor defaultColor2( 0x00, 0x70, 0x00 ); TQColor defaultColor3( 0x00, 0x60, 0x00 ); - TQColor defaultForeground( kapp->palette().active().text() ); + TQColor defaultForeground( kapp->tqpalette().active().text() ); TQColor c = TQt::red; KConfigGroup readerConfig( KMKernel::config(), "Reader" ); @@ -281,7 +281,7 @@ TQPopupMenu *KMEdit::createPopupMenu( const TQPoint& pos ) enum { IdUndo, IdRedo, IdSep1, IdCut, IdCopy, IdPaste, IdClear, IdSep2, IdSelectAll }; TQPopupMenu *menu = KEdit::createPopupMenu( pos ); - if ( !TQApplication::clipboard()->image().isNull() ) { + if ( !TQApplication::tqclipboard()->image().isNull() ) { int id = menu->idAt(0); menu->setItemEnabled( id - IdPaste, true); } @@ -413,7 +413,7 @@ void KMEdit::spellerReady( KSpell *spell ) bool KMEdit::eventFilter(TQObject*o, TQEvent* e) { - if (o == this) + if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this)) KCursor::autoHideEventFilter(o, e); if (e->type() == TQEvent::KeyPress) @@ -458,7 +458,7 @@ bool KMEdit::eventFilter(TQObject*o, TQEvent* e) i18n("Unable to start external editor.") ); killExternalEditor(); } else { - mExtEditorTempFileWatcher = new KDirWatch( this, "mExtEditorTempFileWatcher" ); + mExtEditorTempFileWatcher = new KDirWatch( TQT_TQOBJECT(this), "mExtEditorTempFileWatcher" ); connect( mExtEditorTempFileWatcher, TQT_SIGNAL(dirty(const TQString&)), TQT_SLOT(slotExternalEditorTempFileChanged(const TQString&)) ); mExtEditorTempFileWatcher->addFile( mExtEditorTempFile->name() ); @@ -497,7 +497,7 @@ bool KMEdit::eventFilter(TQObject*o, TQEvent* e) { //Get word right clicked on const TQRegExp wordBoundary( "[\\s\\W]" ); - firstSpace = paraText.findRev( wordBoundary, charPos ) + 1; + firstSpace = paraText.tqfindRev( wordBoundary, charPos ) + 1; lastSpace = paraText.tqfind( wordBoundary, charPos ); if( lastSpace == -1 ) lastSpace = paraText.length(); @@ -570,7 +570,7 @@ bool KMEdit::eventFilter(TQObject*o, TQEvent* e) } } } else if ( e->type() == TQEvent::FocusIn || e->type() == TQEvent::FocusOut ) { - TQFocusEvent *fe = static_cast<TQFocusEvent*>(e); + TQFocusEvent *fe = TQT_TQFOCUSEVENT(e); if(! (fe->reason() == TQFocusEvent::ActiveWindow || fe->reason() == TQFocusEvent::Popup) ) emit focusChanged( fe->gotFocus() ); } @@ -658,7 +658,7 @@ void KMEdit::spellcheck() // Don't use mSpellConfig here. Reason is that the spell dialog, KSpellDlg, uses its own // spell config, and therefore the two wouldn't be in sync. - mKSpellForDialog = new KSpell( this, i18n("Spellcheck - KMail"), this, + mKSpellForDialog = new KSpell( TQT_TQWIDGET(this), i18n("Spellcheck - KMail"), TQT_TQOBJECT(this), TQT_SLOT(slotSpellcheck2(KSpell*))/*, mSpellConfig*/ ); // } @@ -709,7 +709,7 @@ void KMEdit::paste() // Roll our own internal flag. void KMEdit::contentsMouseReleaseEvent( TQMouseEvent * e ) { - if( e->button() != TQt::MidButton ) + if( e->button() != Qt::MidButton ) return KEdit::contentsMouseReleaseEvent( e ); mPasteMode = TQClipboard::Selection; KEdit::contentsMouseReleaseEvent( e ); @@ -719,7 +719,7 @@ void KMEdit::contentsMouseReleaseEvent( TQMouseEvent * e ) void KMEdit::contentsMouseDoubleClickEvent( TQMouseEvent *e ) { bool handled = false; - if ( e->button() == TQt::LeftButton ) { + if ( e->button() == Qt::LeftButton ) { // Get the cursor position for the place where the user clicked to int paragraphPos; @@ -870,7 +870,7 @@ void KMEdit::slotSpellResult(const TQString &s) void KMEdit::slotSpellDone() { kdDebug(5006)<<" void KMEdit::slotSpellDone()\n"; - KSpell::spelltqStatus status = mKSpellForDialog->status(); + KSpell::spellStatus status = mKSpellForDialog->status(); delete mKSpellForDialog; mKSpellForDialog = 0; diff --git a/kmail/kmfilter.cpp b/kmail/kmfilter.cpp index 6d1f50c1d..2f6bbbd78 100644 --- a/kmail/kmfilter.cpp +++ b/kmail/kmfilter.cpp @@ -113,7 +113,7 @@ KMFilter::ReturnCode KMFilter::execActions( KMMessage* msg, bool& stopIt ) const if ( FilterLog::instance()->isLogging() ) { TQString logText( i18n( "<b>Applying filter action:</b> %1" ) - .arg( (*it)->displayString() ) ); + .tqarg( (*it)->displayString() ) ); FilterLog::instance()->add( logText, FilterLog::appliedAction ); } @@ -123,7 +123,7 @@ KMFilter::ReturnCode KMFilter::execActions( KMMessage* msg, bool& stopIt ) const case KMFilterAction::CriticalError: if ( FilterLog::instance()->isLogging() ) { TQString logText = TQString( "<font color=#FF0000>%1</font>" ) - .arg( i18n( "A critical error occurred. Processing stops here." ) ); + .tqarg( i18n( "A critical error occurred. Processing stops here." ) ); FilterLog::instance()->add( logText, FilterLog::appliedAction ); } // in case it's a critical error: return immediately! @@ -131,7 +131,7 @@ KMFilter::ReturnCode KMFilter::execActions( KMMessage* msg, bool& stopIt ) const case KMFilterAction::ErrorButGoOn: if ( FilterLog::instance()->isLogging() ) { TQString logText = TQString( "<font color=#FF0000>%1</font>" ) - .arg( i18n( "A problem was found while applying this action." ) ); + .tqarg( i18n( "A problem was found while applying this action." ) ); FilterLog::instance()->add( logText, FilterLog::appliedAction ); } default: @@ -262,7 +262,7 @@ void KMFilter::readConfig(KConfig* config) numActions = config->readNumEntry("actions",0); if (numActions > FILTER_MAX_ACTIONS) { numActions = FILTER_MAX_ACTIONS ; - KMessageBox::information( 0, i18n("<qt>Too many filter actions in filter rule <b>%1</b>.</qt>").arg( mPattern.name() ) ); + KMessageBox::information( 0, i18n("<qt>Too many filter actions in filter rule <b>%1</b>.</qt>").tqarg( mPattern.name() ) ); } for ( i=0 ; i < numActions ; i++ ) { @@ -287,7 +287,7 @@ void KMFilter::readConfig(KConfig* config) } else KMessageBox::information( 0 /* app-global modal dialog box */, i18n("<qt>Unknown filter action <b>%1</b><br>in filter rule <b>%2</b>.<br>Ignoring it.</qt>") - .arg( config->readEntry( actName ) ).arg( mPattern.name() ) ); + .tqarg( config->readEntry( actName ) ).tqarg( mPattern.name() ) ); } mAccounts = config->readIntListEntry( "accounts-set" ); diff --git a/kmail/kmfilteraction.cpp b/kmail/kmfilteraction.cpp index c23a5644a..5c45528eb 100644 --- a/kmail/kmfilteraction.cpp +++ b/kmail/kmfilteraction.cpp @@ -185,7 +185,7 @@ const TQString KMFilterActionWithUOID::argsAsString() const const TQString KMFilterActionWithUOID::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -236,7 +236,7 @@ const TQString KMFilterActionWithString::argsAsString() const const TQString KMFilterActionWithString::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -266,7 +266,7 @@ void KMFilterActionWithStringList::applyParamWidgetValue( TQWidget* paramWidget void KMFilterActionWithStringList::setParamWidgetValue( TQWidget* paramWidget ) const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); ((TQComboBox*)paramWidget)->setCurrentItem( idx >= 0 ? idx : 0 ); } @@ -277,7 +277,7 @@ void KMFilterActionWithStringList::clearParamWidget( TQWidget* paramWidget ) con void KMFilterActionWithStringList::argsFromString( const TQString argsStr ) { - int idx = mParameterList.findIndex( argsStr ); + int idx = mParameterList.tqfindIndex( argsStr ); if ( idx < 0 ) { mParameterList.append( argsStr ); idx = mParameterList.count() - 1; @@ -483,11 +483,11 @@ TQString KMFilterActionWithCommand::substituteCommandLineArgsFor( KMMessage *aMs } tf->close(); } - // TQString( "%0 and %1 and %1" ).arg( 0 ).arg( 1 ) + // TQString( "%0 and %1 and %1" ).tqarg( 0 ).tqarg( 1 ) // returns "0 and 1 and %1", so we must call .arg as // many times as there are %n's, regardless of their multiplicity. if ((*it) == -1) result.tqreplace( "%-1", tempFileName ); - else result = result.arg( tempFileName ); + else result = result.tqarg( tempFileName ); } // And finally, replace the %{foo} with the content of the foo @@ -495,7 +495,7 @@ TQString KMFilterActionWithCommand::substituteCommandLineArgsFor( KMMessage *aMs TQRegExp header_rx( "%\\{([a-z0-9-]+)\\}", false ); int idx = 0; while ( ( idx = header_rx.search( result, idx ) ) != -1 ) { - TQString replacement = KProcess::quote( aMsg->headerField( header_rx.cap(1).latin1() ) ); + TQString replacement = KProcess::quote( aMsg->headerField( TQString(header_rx.cap(1)).latin1() ) ); result.tqreplace( idx, header_rx.matchedLength(), replacement ); idx += replacement.length(); } @@ -806,7 +806,7 @@ KMFilterActionSetqStatus::KMFilterActionSetqStatus() KMFilterAction::ReturnCode KMFilterActionSetqStatus::process(KMMessage* msg) const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); if ( idx < 1 ) return ErrorButGoOn; KMMsgtqStatus status = stati[idx-1] ; @@ -833,7 +833,7 @@ void KMFilterActionSetqStatus::argsFromString( const TQString argsStr ) const TQString KMFilterActionSetqStatus::argsAsString() const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); if ( idx < 1 ) return TQString(); KMMsgtqStatus status = stati[idx-1]; @@ -843,7 +843,7 @@ const TQString KMFilterActionSetqStatus::argsAsString() const const TQString KMFilterActionSetqStatus::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -901,7 +901,7 @@ KMFilterActionFakeDisposition::KMFilterActionFakeDisposition() KMFilterAction::ReturnCode KMFilterActionFakeDisposition::process(KMMessage* msg) const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); if ( idx < 1 ) return ErrorButGoOn; if ( idx == 1 ) // ignore @@ -929,7 +929,7 @@ void KMFilterActionFakeDisposition::argsFromString( const TQString argsStr ) const TQString KMFilterActionFakeDisposition::argsAsString() const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); if ( idx < 1 ) return TQString(); return TQString( TQChar( idx < 2 ? 'I' : char(mdns[idx-2]) ) ); @@ -938,7 +938,7 @@ const TQString KMFilterActionFakeDisposition::argsAsString() const const TQString KMFilterActionFakeDisposition::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -996,7 +996,7 @@ void KMFilterActionRemoveHeader::setParamWidgetValue( TQWidget* paramWidget ) co TQComboBox * cb = dynamic_cast<TQComboBox*>(paramWidget); Q_ASSERT( cb ); - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); cb->clear(); cb->insertStringList( mParameterList ); if ( idx < 0 ) { @@ -1074,7 +1074,7 @@ TQWidget* KMFilterActionAddHeader::createParamWidget( TQWidget* tqparent ) const void KMFilterActionAddHeader::setParamWidgetValue( TQWidget* paramWidget ) const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); TQComboBox *cb = (TQComboBox*)paramWidget->child("combo"); Q_ASSERT( cb ); cb->clear(); @@ -1123,7 +1123,7 @@ const TQString KMFilterActionAddHeader::argsAsString() const const TQString KMFilterActionAddHeader::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -1139,7 +1139,7 @@ void KMFilterActionAddHeader::argsFromString( const TQString argsStr ) mValue = l[1]; } - int idx = mParameterList.findIndex( s ); + int idx = mParameterList.tqfindIndex( s ); if ( idx < 0 ) { mParameterList.append( s ); idx = mParameterList.count() - 1; @@ -1233,7 +1233,7 @@ TQWidget* KMFilterActionRewriteHeader::createParamWidget( TQWidget* tqparent ) c void KMFilterActionRewriteHeader::setParamWidgetValue( TQWidget* paramWidget ) const { - int idx = mParameterList.findIndex( mParameter ); + int idx = mParameterList.tqfindIndex( mParameter ); TQComboBox *cb = (TQComboBox*)paramWidget->child("combo"); Q_ASSERT( cb ); @@ -1299,7 +1299,7 @@ const TQString KMFilterActionRewriteHeader::argsAsString() const const TQString KMFilterActionRewriteHeader::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -1312,7 +1312,7 @@ void KMFilterActionRewriteHeader::argsFromString( const TQString argsStr ) mRegExp.setPattern( l[1] ); mReplacementString = l[2]; - int idx = mParameterList.findIndex( s ); + int idx = mParameterList.tqfindIndex( s ); if ( idx < 0 ) { mParameterList.append( s ); idx = mParameterList.count() - 1; @@ -1617,9 +1617,9 @@ const TQString KMFilterActionForward::argsAsString() const const TQString KMFilterActionForward::displayString() const { if ( mTemplate.isEmpty() ) - return i18n( "Forward to %1 with default template " ).arg( mParameter ); + return i18n( "Forward to %1 with default template " ).tqarg( mParameter ); else - return i18n( "Forward to %1 with template %2" ).arg( mParameter, mTemplate ); + return i18n( "Forward to %1 with template %2" ).tqarg( mParameter, mTemplate ); } //============================================================================= @@ -1732,7 +1732,7 @@ class PipeJob : public KPIM::ThreadWeaver::Job if (! fgets( buffer, len, p ) ) break; int oldsize = ba.size(); ba.resize( oldsize + strlen(buffer) ); - qmemmove( ba.begin() + oldsize, buffer, strlen(buffer) ); + tqmemmove( ba.begin() + oldsize, buffer, strlen(buffer) ); } pclose(p); if ( !ba.isEmpty() ) { @@ -1878,7 +1878,7 @@ const TQString KMFilterActionWithTest::argsAsString() const const TQString KMFilterActionWithTest::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } @@ -1955,7 +1955,7 @@ const TQString KMFilterActionWithUrl::argsAsString() const const TQString KMFilterActionWithUrl::displayString() const { // FIXME after string freeze: - // return i18n("").arg( ); + // return i18n("").tqarg( ); return label() + " \"" + TQStyleSheet::escape( argsAsString() ) + "\""; } diff --git a/kmail/kmfilterdlg.cpp b/kmail/kmfilterdlg.cpp index a83b6eec6..02abff7bf 100644 --- a/kmail/kmfilterdlg.cpp +++ b/kmail/kmfilterdlg.cpp @@ -185,11 +185,11 @@ KMFilterDlg::KMFilterDlg(TQWidget* tqparent, const char* name, bool popFilter, b vbl->addWidget( mGlobalsBox, 0, TQt::AlignTop ); } else { - TQGroupBox *agb = new TQGroupBox( 1 /*column*/, Vertical, i18n("Filter Actions"), page1 ); + TQGroupBox *agb = new TQGroupBox( 1 /*column*/, Qt::Vertical, i18n("Filter Actions"), page1 ); mActionLister = new KMFilterActionWidgetLister( agb ); vbl->addWidget( agb, 0, TQt::AlignTop ); - mAdvOptsGroup = new TQGroupBox ( 1 /*columns*/, Vertical, + mAdvOptsGroup = new TQGroupBox ( 1 /*columns*/, Qt::Vertical, i18n("Advanced Options"), page2); { TQWidget *adv_w = new TQWidget( mAdvOptsGroup ); @@ -558,7 +558,7 @@ void KMFilterDlg::slotUpdateAccountList() TQCheckListItem *listItem = new TQCheckListItem( mAccountList, top, a->name(), TQCheckListItem::CheckBox ); listItem->setText( 1, a->type() ); - listItem->setText( 2, TQString( "%1" ).arg( a->id() ) ); + listItem->setText( 2, TQString( "%1" ).tqarg( a->id() ) ); if ( mFilter ) listItem->setOn( mFilter->applyOnAccount( a->id() ) ); top = listItem; @@ -578,7 +578,7 @@ void KMFilterDlg::slotUpdateAccountList() //============================================================================= KMFilterListBox::KMFilterListBox( const TQString & title, TQWidget *tqparent, const char* name, bool popFilter ) - : TQGroupBox( 1, Horizontal, title, tqparent, name ), + : TQGroupBox( 1, Qt::Horizontal, title, tqparent, name ), bPopFilter(popFilter) { mFilterList.setAutoDelete( true ); @@ -682,7 +682,7 @@ void KMFilterListBox::createFilter( const TQCString & field, KMFilter *newFilter = new KMFilter(0, bPopFilter); newFilter->pattern()->append( newRule ); - newFilter->pattern()->setName( TQString("<%1>:%2").arg( field ).arg( value) ); + newFilter->pattern()->setName( TQString("<%1>:%2").tqarg( TQString(field) ).tqarg( TQString(value) ) ); KMFilterActionDesc *desc = (*kmkernel->filterActionDict())["transfer"]; if ( desc ) @@ -712,7 +712,7 @@ void KMFilterListBox::slotUpdateFilterName() if ( mFilterList.at(mIdxSelItem)->isAutoNaming() ) { // auto-naming of patterns if ( !p->isEmpty() && p->first() && !p->first()->field().stripWhiteSpace().isEmpty() ) - shouldBeName = TQString( "<%1>: %2" ).arg( p->first()->field() ).arg( p->first()->contents() ); + shouldBeName = TQString( "<%1>: %2" ).tqarg( TQString(p->first()->field()) ).tqarg( TQString(p->first()->contents()) ); else shouldBeName = "<" + i18n("unnamed") + ">"; p->setName( shouldBeName ); @@ -946,7 +946,7 @@ void KMFilterListBox::slotRename() ( i18n("Rename Filter"), i18n("Rename filter \"%1\" to:\n(leave the field empty for automatic naming)") - .arg( filter->pattern()->name() ) /*label*/, + .tqarg( filter->pattern()->name() ) /*label*/, filter->pattern()->name() /* initial value */, &okPressed, tqtopLevelWidget(), 0, validator ); diff --git a/kmail/kmfolder.cpp b/kmail/kmfolder.cpp index 307823c96..a1b53aee7 100644 --- a/kmail/kmfolder.cpp +++ b/kmail/kmfolder.cpp @@ -80,7 +80,7 @@ KMFolder::KMFolder( KMFolderDir* aParent, const TQString& aFolderName, dirinfo.setFile( mStorage->location() ); if ( !dirinfo.exists() ) { int rc = mStorage->create(); - TQString msg = i18n("<qt>Error while creating file <b>%1</b>:<br>%2</qt>").arg(aFolderName).arg(strerror(rc)); + TQString msg = i18n("<qt>Error while creating file <b>%1</b>:<br>%2</qt>").tqarg(aFolderName).tqarg(strerror(rc)); if ( rc ) { KMessageBox::information(0, msg); } @@ -272,7 +272,7 @@ KMFolderDir* KMFolder::createChildFolder() { if (mkdir(TQFile::encodeName(childDir), S_IRWXU) != 0 && chmod(TQFile::encodeName(childDir), S_IRWXU) != 0) { - TQString wmsg = TQString(" '%1': %2").arg(childDir).arg(strerror(errno)); + TQString wmsg = TQString(" '%1': %2").tqarg(childDir).tqarg(strerror(errno)); KMessageBox::information(0,i18n("Failed to create folder") + wmsg); return 0; } @@ -929,7 +929,7 @@ bool KMFolder::isValidName( const TQString &folderName, TQString &message ) } } if ( !delimiter.isEmpty() && folderName.tqfind( delimiter ) != -1 ) { - message = i18n( "Your IMAP server does not allow the character '%1'; please choose another folder name." ).arg( delimiter ); + message = i18n( "Your IMAP server does not allow the character '%1'; please choose another folder name." ).tqarg( delimiter ); return false; } } diff --git a/kmail/kmfoldercachedimap.cpp b/kmail/kmfoldercachedimap.cpp index f0b3f0cec..94bd09b20 100644 --- a/kmail/kmfoldercachedimap.cpp +++ b/kmail/kmfoldercachedimap.cpp @@ -215,7 +215,7 @@ KMFolderCachedImap::KMFolderCachedImap( KMFolder* folder, const char* aName ) KMessageBox::error( 0, i18n( "The UID cache file for folder %1 could not be read. There " "could be a problem with file system permission, or it is corrupted." - ).arg( folder->prettyURL() ) ); + ).tqarg( folder->prettyURL() ) ); // try to unlink it, in case it was corruped. If it couldn't be read // because of permissions, this will fail, which is fine unlink( TQFile::encodeName( uidCacheLocation() ) ); @@ -442,14 +442,14 @@ int KMFolderCachedImap::readUidCache() if( cacheVersion == UIDCACHE_VERSION ) { len = uidcache.readLine( buf, sizeof(buf) ); if( len > 0 ) { - setUidValidity( TQString::fromLocal8Bit(buf).stripWhiteSpace() ); + setUidValidity( TQString(TQString::fromLocal8Bit(buf)).stripWhiteSpace() ); len = uidcache.readLine( buf, sizeof(buf) ); if( len > 0 ) { #if MAIL_LOSS_DEBUGGING kdDebug(5006) << "Reading in last uid from cache: " << TQString::fromLocal8Bit(buf).stripWhiteSpace() << " in " << folder()->prettyURL() << endl; #endif // load the last known highest uid from the on disk cache - setLastUid( TQString::fromLocal8Bit(buf).stripWhiteSpace().toULong() ); + setLastUid( TQString(TQString::fromLocal8Bit(buf)).stripWhiteSpace().toULong() ); return 0; } } @@ -486,7 +486,7 @@ int KMFolderCachedImap::writeUidCache() } KMessageBox::error( 0, i18n( "The UID cache file for folder %1 could not be written. There " - "could be a problem with file system permission." ).arg( folder()->prettyURL() ) ); + "could be a problem with file system permission." ).tqarg( folder()->prettyURL() ) ); return -1; } @@ -739,7 +739,7 @@ void KMFolderCachedImap::slotTroubleshoot() TQString str = i18n("Are you sure you want to refresh the IMAP cache of " "the folder %1 and all its subfolders?\nThis will " "remove all changes you have done locally to your " - "folders.").arg( label() ); + "folders.").tqarg( label() ); TQString s1 = i18n("Refresh IMAP Cache"); TQString s2 = i18n("&Refresh"); if( KMessageBox::warningContinueCancel( 0, str, s1, s2 ) == @@ -774,7 +774,7 @@ void KMFolderCachedImap::slotTroubleshoot() void KMFolderCachedImap::serverSync( bool recurse, bool quotaOnly ) { if( mSyncState != SYNC_STATE_INITIAL ) { - if( KMessageBox::warningYesNo( 0, i18n("Folder %1 is not in initial sync state (state was %2). Do you want to reset it to initial sync state and sync anyway?" ).arg( imapPath() ).arg( mSyncState ), TQString(), i18n("Reset && Sync"), KStdGuiItem::cancel() ) == KMessageBox::Yes ) { + if( KMessageBox::warningYesNo( 0, i18n("Folder %1 is not in initial sync state (state was %2). Do you want to reset it to initial sync state and sync anyway?" ).tqarg( imapPath() ).tqarg( mSyncState ), TQString(), i18n("Reset && Sync"), KStdGuiItem::cancel() ) == KMessageBox::Yes ) { mSyncState = SYNC_STATE_INITIAL; } else return; } @@ -899,14 +899,14 @@ void KMFolderCachedImap::serverSyncInternal() // Cancelled by user, or slave can't start // kdDebug(5006) << "makeConnection said Error, aborting." << endl; // We stop here. We're already in SYNC_STATE_INITIAL for the next time. - newState( mProgress, i18n( "Error connecting to server %1" ).arg( mAccount->host() ) ); + newState( mProgress, i18n( "Error connecting to server %1" ).tqarg( mAccount->host() ) ); close("cachedimap"); emit folderComplete(this, false); break; } else if ( cs == ImapAccountBase::Connecting ) { mAccount->setAnnotationCheckPassed( false ); // kdDebug(5006) << "makeConnection said Connecting, waiting for signal." << endl; - newState( mProgress, i18n("Connecting to %1").arg( mAccount->host() ) ); + newState( mProgress, i18n("Connecting to %1").tqarg( mAccount->host() ) ); // We'll wait for the connectionResult signal from the account. connect( mAccount, TQT_SIGNAL( connectionResult(int, const TQString&) ), this, TQT_SLOT( slotConnectionResult(int, const TQString&) ) ); @@ -1478,7 +1478,7 @@ void KMFolderCachedImap::uploadNewMessages() && !(mUserRights & KMail::ACLJobs::Insert) ) { // write access revoked KMessageBox::information( 0, i18n("<p>Your access rights to folder <b>%1</b> have been restricted, " - "it will no longer be possible to add messages to this folder.</p>").arg( folder()->prettyURL() ), + "it will no longer be possible to add messages to this folder.</p>").tqarg( folder()->prettyURL() ), i18n("Acces rights revoked"), "KMailACLRevocationNotification" ); } } @@ -1511,7 +1511,7 @@ void KMFolderCachedImap::uploadFlags() if( !msg || msg->UID() == 0 ) // Either not a valid message or not one that is on the server yet continue; - if ( mUIDsOfLocallyChangedStatuses.tqfind( msg->UID() ) == mUIDsOfLocallyChangedStatuses.end() + if ( mUIDsOfLocallyChangedStatuses.find( msg->UID() ) == mUIDsOfLocallyChangedStatuses.end() && !mStatusChangedLocally ) { // This message has not had its status changed locally continue; @@ -1559,7 +1559,7 @@ void KMFolderCachedImap::uploadSeenFlags() // Either not a valid message or not one that is on the server yet continue; - if ( mUIDsOfLocallyChangedStatuses.tqfind( msg->UID() ) == mUIDsOfLocallyChangedStatuses.end() + if ( mUIDsOfLocallyChangedStatuses.find( msg->UID() ) == mUIDsOfLocallyChangedStatuses.end() && !mStatusChangedLocally ) { // This message has not had its status changed locally continue; @@ -1706,7 +1706,7 @@ bool KMFolderCachedImap::deleteMessages() if ( KMessageBox::warningYesNo( 0, i18n( "<qt><p>Mails on the server in folder <b>%1</b> were deleted. " "Do you want to delete them locally?<br>UIDs: %2</p></qt>" ) - .arg( folder()->prettyURL() ).arg( uids.join(",") ) ) == KMessageBox::Yes ) + .tqarg( folder()->prettyURL() ).tqarg( uids.join(",") ) ) == KMessageBox::Yes ) #endif removeMsg( msgsForDeletion ); } @@ -2055,7 +2055,7 @@ void KMFolderCachedImap::listNamespaces() mNamespacesToList.pop_front(); mSyncState = SYNC_STATE_LIST_SUBFOLDERS2; - newState( mProgress, i18n("Retrieving folders for namespace %1").arg(ns)); + newState( mProgress, i18n("Retrieving folders for namespace %1").tqarg(ns)); KMail::ListJob* job = new KMail::ListJob( mAccount, type, this, mAccount->addPathToNamespace( ns ) ); job->setNamespace( ns ); @@ -2184,7 +2184,7 @@ void KMFolderCachedImap::slotListResult( const TQStringList& folderNames, if (!node->isDir() ) { KMFolderCachedImap *f = static_cast<KMFolderCachedImap*>(static_cast<KMFolder*>(node)->storage()); - if ( mSubfolderNames.findIndex(node->name()) == -1 ) { + if ( mSubfolderNames.tqfindIndex(node->name()) == -1 ) { TQString name = node->name(); // as more than one namespace can be listed in the root folder we need to make sure // that the folder is within the current namespace @@ -2207,7 +2207,7 @@ void KMFolderCachedImap::slotListResult( const TQStringList& folderNames, /** * Store the folder attributes for every subfolder. */ - int index = mSubfolderNames.findIndex( node->name() ); + int index = mSubfolderNames.tqfindIndex( node->name() ); f->mFolderAttributes = folderAttributes[ index ]; } } else { @@ -2297,7 +2297,7 @@ void KMFolderCachedImap::listDirectory2() // (could be that the folder was deleted & recreated meanwhile from another client...) if ( !locallyDeleted && mAccount->isPreviouslyDeletedFolder( subfolderPath ) ) { locallyDeleted = KMessageBox::warningYesNo( - 0, i18n( "<qt><p>It seems that the folder <b>%1</b> was deleted. Do you want to delete it from the server?</p></qt>" ).arg( mSubfolderNames[i] ), TQString(), KStdGuiItem::del(), KStdGuiItem::cancel() ) == KMessageBox::Yes; + 0, i18n( "<qt><p>It seems that the folder <b>%1</b> was deleted. Do you want to delete it from the server?</p></qt>" ).tqarg( mSubfolderNames[i] ), TQString(), KStdGuiItem::del(), KStdGuiItem::cancel() ) == KMessageBox::Yes; } if ( locallyDeleted ) { @@ -2618,7 +2618,7 @@ void KMFolderCachedImap::newState( int progress, const TQString& synctqStatus ) if ( mAccount->imapFolder() == this ) str = synctqStatus; else - str = TQString( "%1: %2" ).arg( label() ).arg( synctqStatus ); + str = TQString( "%1: %2" ).tqarg( label() ).tqarg( synctqStatus ); if( progressItem ) progressItem->setqStatus( str ); emit statusMsg( str ); @@ -2809,7 +2809,7 @@ void KMFolderCachedImap::slotGetAnnotationResult( KIO::Job* job ) // that's when the imap server doesn't support annotations if ( GlobalSettings::self()->theIMAPResourceStorageFormat() == GlobalSettings::EnumTheIMAPResourceStorageFormat::XML && (uint)GlobalSettings::self()->theIMAPResourceAccount() == mAccount->id() ) - KMessageBox::error( 0, i18n( "The IMAP server %1 does not have support for IMAP annotations. The XML storage cannot be used on this server; please re-configure KMail differently." ).arg( mAccount->host() ) ); + KMessageBox::error( 0, i18n( "The IMAP server %1 does not have support for IMAP annotations. The XML storage cannot be used on this server; please re-configure KMail differently." ).tqarg( mAccount->host() ) ); mAccount->setHasNoAnnotationSupport(); } else @@ -2837,7 +2837,7 @@ void KMFolderCachedImap::slotMultiUrlGetAnnotationResult( KIO::Job* job ) // that's when the imap server doesn't support annotations if ( GlobalSettings::self()->theIMAPResourceStorageFormat() == GlobalSettings::EnumTheIMAPResourceStorageFormat::XML && (uint)GlobalSettings::self()->theIMAPResourceAccount() == mAccount->id() ) - KMessageBox::error( 0, i18n( "The IMAP server %1 doesn't have support for imap annotations. The XML storage cannot be used on this server, please re-configure KMail differently" ).arg( mAccount->host() ) ); + KMessageBox::error( 0, i18n( "The IMAP server %1 doesn't have support for imap annotations. The XML storage cannot be used on this server, please re-configure KMail differently" ).tqarg( mAccount->host() ) ); mAccount->setHasNoAnnotationSupport(); } else @@ -2856,7 +2856,7 @@ void KMFolderCachedImap::slotMultiUrlGetAnnotationResult( KIO::Job* job ) if ( dot != -1 ) type.truncate( dot ); type = type.simplifyWhiteSpace(); - const int idx = mSubfolderPaths.findIndex( folderPath ); + const int idx = mSubfolderPaths.tqfindIndex( folderPath ); const bool isNoContent = mSubfolderMimeTypes[idx] == "inode/directory"; if ( ( isNoContent && type.isEmpty() ) || ( !type.isEmpty() && type != KMailICalIfaceImpl::annotationForContentsType( ContentsTypeMail ) ) ) { @@ -3063,7 +3063,7 @@ KMCommand* KMFolderCachedImap::rescueUnsyncedMessages() bool manualMove = true; while ( GlobalSettings::autoLostFoundMove() ) { // find the inbox of this account - KMFolder *inboxFolder = kmkernel->findFolderById( TQString(".%1.directory/INBOX").arg( account()->id() ) ); + KMFolder *inboxFolder = kmkernel->findFolderById( TQString(".%1.directory/INBOX").tqarg( account()->id() ) ); if ( !inboxFolder ) { kdWarning(5006) << k_funcinfo << "inbox not found!" << endl; break; @@ -3119,7 +3119,7 @@ KMCommand* KMFolderCachedImap::rescueUnsyncedMessages() "on the server or you do not " "have sufficient access rights on the folder to upload them.</p>" "<p>All affected messages will therefore be moved to <b>%2</b> " - "to avoid data loss.</p>").arg( folder()->prettyURL() ).arg( dest->prettyURL() ), + "to avoid data loss.</p>").tqarg( folder()->prettyURL() ).tqarg( dest->prettyURL() ), i18n("Insufficient access rights") ); manualMove = false; break; @@ -3132,7 +3132,7 @@ KMCommand* KMFolderCachedImap::rescueUnsyncedMessages() "have sufficient access rights on the folder now to upload them. " "Please contact your administrator to allow upload of new messages " "to you, or move them out of this folder.</p> " - "<p>Do you want to move these messages to another folder now?</p>").arg( folder()->prettyURL() ) ); + "<p>Do you want to move these messages to another folder now?</p>").tqarg( folder()->prettyURL() ) ); if ( KMessageBox::warningYesNo( 0, msg, TQString(), i18n("Move"), i18n("Do Not Move") ) == KMessageBox::Yes ) { KMail::KMFolderSelDlg dlg( kmkernel->getKMMainWidget(), i18n("Move Messages to Folder"), true ); diff --git a/kmail/kmfoldercombobox.cpp b/kmail/kmfoldercombobox.cpp index 1135b25b7..e85144f0a 100644 --- a/kmail/kmfoldercombobox.cpp +++ b/kmail/kmfoldercombobox.cpp @@ -114,9 +114,9 @@ void KMFolderComboBox::setFolder( KMFolder *aFolder ) TQValueList<TQGuardedPtr<KMFolder> > folders; createFolderList( &names, &folders ); - int idx = folders.findIndex( aFolder ); + int idx = folders.tqfindIndex( aFolder ); if (idx == -1) - idx = folders.findIndex( kmkernel->draftsFolder() ); + idx = folders.tqfindIndex( kmkernel->draftsFolder() ); setCurrentItem( idx >= 0 ? idx : 0 ); mFolder = aFolder; diff --git a/kmail/kmfolderdir.cpp b/kmail/kmfolderdir.cpp index 1f6019b00..f6edcaf1b 100644 --- a/kmail/kmfolderdir.cpp +++ b/kmail/kmfolderdir.cpp @@ -206,7 +206,7 @@ bool KMFolderDir::reload(void) if (!dir.cd(fldPath, TRUE)) { - TQString msg = i18n("<qt>Cannot enter folder <b>%1</b>.</qt>").arg(fldPath); + TQString msg = i18n("<qt>Cannot enter folder <b>%1</b>.</qt>").tqarg(fldPath); KMessageBox::information(0, msg); return FALSE; } @@ -214,7 +214,7 @@ bool KMFolderDir::reload(void) TQFileInfoList* fiList=(TQFileInfoList*)dir.entryInfoList(); if (!fiList) { - TQString msg = i18n("<qt>Folder <b>%1</b> is unreadable.</qt>").arg(fldPath); + TQString msg = i18n("<qt>Folder <b>%1</b> is unreadable.</qt>").tqarg(fldPath); KMessageBox::information(0, msg); return FALSE; } @@ -258,7 +258,7 @@ bool KMFolderDir::reload(void) // For this to be a cached IMAP folder, it must be in the KMail dimap // subdir and must be have a uidcache file or be a maildir folder TQString maildir(fname + "/new"); - TQString imapcachefile = TQString::tqfromLatin1(".%1.uidcache").arg(fname); + TQString imapcachefile = TQString::tqfromLatin1(".%1.uidcache").tqarg(fname); if ( dir.exists( imapcachefile) || dir.exists( maildir ) ) { folder = new KMFolder( this, fname, KMFolderTypeCachedImap ); diff --git a/kmail/kmfolderimap.cpp b/kmail/kmfolderimap.cpp index 28ba493c2..38e025bc4 100644 --- a/kmail/kmfolderimap.cpp +++ b/kmail/kmfolderimap.cpp @@ -245,7 +245,7 @@ void KMFolderImap::remove() jd.progressItem = ProgressManager::createProgressItem( "ImapFolderRemove" + ProgressManager::getUniqueID(), i18n("Removing folder"), - i18n( "URL: %1" ).arg( TQStyleSheet::escape( folder()->prettyURL() ) ), + i18n( "URL: %1" ).tqarg( TQStyleSheet::escape( folder()->prettyURL() ) ), false, account()->useSSL() || account()->useTLS() ); account()->insertJob(job, jd); @@ -488,7 +488,7 @@ int KMFolderImap::addMsg(TQPtrList<KMMessage>& msgList, TQValueList<int>& aIndex mAddMessageProgressItem = ProgressManager::createProgressItem( "Uploading"+ProgressManager::getUniqueID(), i18n("Uploading message data"), - i18n("Destination folder: %1").arg( TQStyleSheet::escape( folder()->prettyURL() ) ), + i18n("Destination folder: %1").tqarg( TQStyleSheet::escape( folder()->prettyURL() ) ), true, account()->useSSL() || account()->useTLS() ); mAddMessageProgressItem->setTotalItems( msgList.count() ); @@ -544,8 +544,8 @@ void KMFolderImap::copyMsg(TQPtrList<KMMessage>& msgList) TQPtrList<KMMessage> KMFolderImap::splitMessageList(const TQString& set, TQPtrList<KMMessage>& msgList) { - int lastcomma = set.findRev(","); - int lastdub = set.findRev(":"); + int lastcomma = set.tqfindRev(","); + int lastdub = set.tqfindRev(":"); int last = 0; if (lastdub > lastcomma) last = lastdub; else last = lastcomma; @@ -946,7 +946,7 @@ void KMFolderImap::checkFolders( const TQStringList& subfolderNames, KMFolderNode *node = folder()->child()->first(); while ( node ) { - if ( !node->isDir() && subfolderNames.findIndex(node->name()) == -1 ) + if ( !node->isDir() && subfolderNames.tqfindIndex(node->name()) == -1 ) { KMFolder* fld = static_cast<KMFolder*>(node); KMFolderImap* imapFld = static_cast<KMFolderImap*>( fld->storage() ); @@ -1271,7 +1271,7 @@ void KMFolderImap::slotListFolderResult(KIO::Job * job) if (job->error()) { account()->handleJobError( job, - i18n("Error while listing the contents of the folder %1.").arg( label() ) ); + i18n("Error while listing the contents of the folder %1.").tqarg( label() ) ); account()->removeJob(it); finishMailCheck( "listfolder", imapNoInformation ); return; diff --git a/kmail/kmfolderindex.cpp b/kmail/kmfolderindex.cpp index 635afae52..d41f6bca1 100644 --- a/kmail/kmfolderindex.cpp +++ b/kmail/kmfolderindex.cpp @@ -369,7 +369,7 @@ bool KMFolderIndex::readIndexHeader(int *gv) "The mail index for '%1' is from an unknown version of KMail (%2).\n" "This index can be regenerated from your mail folder, but some " "information, including status flags, may be lost. Do you wish " - "to downgrade your index file?") .arg(name()) .arg(indexVersion), TQString(), i18n("Downgrade"), i18n("Do Not Downgrade") ); + "to downgrade your index file?") .tqarg(name()) .tqarg(indexVersion), TQString(), i18n("Downgrade"), i18n("Do Not Downgrade") ); kapp->restoreOverrideCursor(); if (r == KMessageBox::Yes) createIndexFromContents(); @@ -527,7 +527,7 @@ void KMFolderIndex::recreateIndex( bool readIndexAfterwards ) kapp->setOverrideCursor(KCursor::arrowCursor()); KMessageBox::information(0, i18n("The mail index for '%1' is corrupted and will be regenerated now, " - "but some information, like status flags, might get lost.").arg(name())); + "but some information, like status flags, might get lost.").tqarg(name())); kapp->restoreOverrideCursor(); createIndexFromContents(); if ( readIndexAfterwards ) { diff --git a/kmail/kmfoldermaildir.cpp b/kmail/kmfoldermaildir.cpp index ace5a6ddc..684af395d 100644 --- a/kmail/kmfoldermaildir.cpp +++ b/kmail/kmfoldermaildir.cpp @@ -87,11 +87,11 @@ int KMFolderMaildir::canAccess() KCursorSaver idle(KBusyPtr::idle()); if ( nRetVal == ENOENT ) KMessageBox::sorry(0, i18n("Error opening %1; this folder is missing.") - .arg(sBadFolderName)); + .tqarg(sBadFolderName)); else KMessageBox::sorry(0, i18n("Error opening %1; either this is not a valid " "maildir folder, or you do not have sufficient access permissions.") - .arg(sBadFolderName)); + .tqarg(sBadFolderName)); return nRetVal; } @@ -122,7 +122,7 @@ int KMFolderMaildir::open(const char *) TQString str; mIndexStream = 0; str = i18n("Folder `%1' changed; recreating index.") - .arg(name()); + .tqarg(name()); emit statusMsg(str); } else { mIndexStream = fopen(TQFile::encodeName(indexLocation()), "r+"); // index file @@ -605,7 +605,7 @@ void KMFolderMaildir::readFileHeaderIntern(const TQString& dir, const TQString& // open the file and get a pointer to it TQFile f(file); if ( f.open( IO_ReadOnly ) == false ) { - kdWarning(5006) << "The file '" << TQFile::encodeName(dir) << "/" << file + kdWarning(5006) << "The file '" << TQString(TQFile::encodeName(dir)) << "/" << file << "' could not be opened for reading the message. " "Please check ownership and permissions." << endl; @@ -652,7 +652,7 @@ void KMFolderMaildir::readFileHeaderIntern(const TQString& dir, const TQString& referencesStr = referencesStr.stripWhiteSpace(); if( !referencesStr.isEmpty() ) { int leftAngle, rightAngle; - leftAngle = referencesStr.findRev( '<' ); + leftAngle = referencesStr.tqfindRev( '<' ); if( ( leftAngle != -1 ) && ( replyToIdStr.isEmpty() || ( replyToIdStr[0] != '<' ) ) ) { // use the last reference, instead of missing In-Reply-To @@ -660,10 +660,10 @@ void KMFolderMaildir::readFileHeaderIntern(const TQString& dir, const TQString& } // find second last reference - leftAngle = referencesStr.findRev( '<', leftAngle - 1 ); + leftAngle = referencesStr.tqfindRev( '<', leftAngle - 1 ); if( leftAngle != -1 ) referencesStr = referencesStr.mid( leftAngle ); - rightAngle = referencesStr.findRev( '>' ); + rightAngle = referencesStr.tqfindRev( '>' ); if( rightAngle != -1 ) referencesStr.truncate( rightAngle + 1 ); @@ -729,7 +729,7 @@ void KMFolderMaildir::readFileHeaderIntern(const TQString& dir, const TQString& dateStr = dateStr.stripWhiteSpace(); if (!dateStr.isEmpty()) - mi->setDate(dateStr); + mi->setDate(dateStr.data()); if ( !uidStr.isEmpty() ) mi->setUID( uidStr.toULong() ); mi->setDirty(false); @@ -1046,7 +1046,7 @@ TQString KMFolderMaildir::constructValidFileName( const TQString & filename, if (!suffix_regex) suffix_regex_sd.setObject(suffix_regex, new TQRegExp(":2,?R?S?$")); - aFileName.truncate(aFileName.findRev(*suffix_regex)); + aFileName.truncate(aFileName.tqfindRev(*suffix_regex)); // only add status suffix if the message is neither new nor unread if (! ((status & KMMsgStatusNew) || (status & KMMsgStatusUnread)) ) @@ -1123,7 +1123,7 @@ TQ_INT64 KMFolderMaildir::doFolderSize() const item = new KFileItem( S_IFDIR, -1, location() + "/tmp" ); list.append( item ); s_DirSizeJobQueue.append( - qMakePair( TQGuardedPtr<const KMFolderMaildir>( this ), list ) ); + tqMakePair( TQGuardedPtr<const KMFolderMaildir>( this ), list ) ); // if there's only one entry in the queue then we can start // a dirSizeJob right away diff --git a/kmail/kmfoldermbox.cpp b/kmail/kmfoldermbox.cpp index 287ce5766..b9bbd1a67 100644 --- a/kmail/kmfoldermbox.cpp +++ b/kmail/kmfoldermbox.cpp @@ -109,7 +109,7 @@ int KMFolderMbox::open(const char *owner) if (!mStream) { KNotifyClient::event( 0, "warning", - i18n("Cannot open file \"%1\":\n%2").arg(location()).arg(strerror(errno))); + i18n("Cannot open file \"%1\":\n%2").tqarg(location()).tqarg(strerror(errno))); kdDebug(5006) << "Cannot open folder `" << location() << "': " << strerror(errno) << endl; mOpenCount = 0; return errno; @@ -137,8 +137,8 @@ int KMFolderMbox::open(const char *owner) "of KMail</a> for " "information about how to prevent this " "problem from happening again.</p></qt>") - .arg("help:/kmail/faq.html#faq-index-regeneration") - .arg(name()); + .tqarg("help:/kmail/faq.html#faq-index-regeneration") + .tqarg(name()); // When KMail is starting up we have to show a non-blocking message // box so that the initialization can continue. We don't show a // queued message box when KMail isn't starting up because queued @@ -164,7 +164,7 @@ int KMFolderMbox::open(const char *owner) TQString str; mIndexStream = 0; str = i18n("Folder `%1' changed. Recreating index.") - .arg(name()); + .tqarg(name()); emit statusMsg(str); } else { mIndexStream = fopen(TQFile::encodeName(indexLocation()), "r+"); // index file @@ -297,7 +297,7 @@ void KMFolderMbox::sync() if (mOpenCount > 0) if (!mStream || fsync(fileno(mStream)) || !mIndexStream || fsync(fileno(mIndexStream))) { - kmkernel->emergencyExit( i18n("Could not sync index file <b>%1</b>: %2").arg( indexLocation() ).arg(errno ? TQString::fromLocal8Bit(strerror(errno)) : i18n("Internal error. Please copy down the details and report a bug."))); + kmkernel->emergencyExit( i18n("Could not sync index file <b>%1</b>: %2").tqarg( indexLocation() ).tqarg(errno ? TQString::fromLocal8Bit(strerror(errno)) : i18n("Internal error. Please copy down the details and report a bug."))); } } @@ -625,7 +625,7 @@ int KMFolderMbox::createIndexFromContents() referencesStr = referencesStr.stripWhiteSpace(); if( !referencesStr.isEmpty() ) { int leftAngle, rightAngle; - leftAngle = referencesStr.findRev( '<' ); + leftAngle = referencesStr.tqfindRev( '<' ); if( ( leftAngle != -1 ) && ( replyToIdStr.isEmpty() || ( replyToIdStr[0] != '<' ) ) ) { // use the last reference, instead of missing In-Reply-To @@ -633,10 +633,10 @@ int KMFolderMbox::createIndexFromContents() } // find second last reference - leftAngle = referencesStr.findRev( '<', leftAngle - 1 ); + leftAngle = referencesStr.tqfindRev( '<', leftAngle - 1 ); if( leftAngle != -1 ) referencesStr = referencesStr.mid( leftAngle ); - rightAngle = referencesStr.findRev( '>' ); + rightAngle = referencesStr.tqfindRev( '>' ); if( rightAngle != -1 ) referencesStr.truncate( rightAngle + 1 ); @@ -683,7 +683,7 @@ int KMFolderMbox::createIndexFromContents() KMMsgEncryptionStateUnknown, KMMsgSignatureStateUnknown, KMMsgMDNStateUnknown, charset, offs, size, sizeServer, uid ); mi->setqStatus(status, xstatus); - mi->setDate( dateStr.stripWhiteSpace() ); + mi->setDate( dateStr.stripWhiteSpace().data() ); mi->setDirty(false); mMsgList.append(mi, mExportsSernums ); diff --git a/kmail/kmfoldermgr.cpp b/kmail/kmfoldermgr.cpp index 3d42a2d38..a37f9136d 100644 --- a/kmail/kmfoldermgr.cpp +++ b/kmail/kmfoldermgr.cpp @@ -146,7 +146,7 @@ void KMFolderMgr::setBasePath(const TQString& aBasePath) if ( !info.isDir() ) { KMessageBox::sorry(0, i18n("'%1' does not appear to be a folder.\n" "Please move the file out of the way.") - .arg( mBasePath ) ); + .tqarg( mBasePath ) ); ::exit(-1); } if ( !info.isReadable() || !info.isWritable() ) { @@ -154,7 +154,7 @@ void KMFolderMgr::setBasePath(const TQString& aBasePath) "incorrect;\n" "please make sure that you can view and modify " "the content of this folder.") - .arg( mBasePath ) ); + .tqarg( mBasePath ) ); ::exit(-1); } } else { @@ -163,7 +163,7 @@ void KMFolderMgr::setBasePath(const TQString& aBasePath) KMessageBox::sorry(0, i18n("KMail could not create folder '%1';\n" "please make sure that you can view and " "modify the content of the folder '%2'.") - .arg( mBasePath ).arg( TQDir::homeDirPath() ) ); + .tqarg( mBasePath ).tqarg( TQDir::homeDirPath() ) ); ::exit(-1); } } @@ -326,7 +326,7 @@ KMFolder* KMFolderMgr::findOrCreate(const TQString& aFolderName, bool sysFldr, folder = createFolder(aFolderName, sysFldr, type); if (!folder) { - KMessageBox::error(0,(i18n("Cannot create file `%1' in %2.\nKMail cannot start without it.").arg(aFolderName).arg(mBasePath))); + KMessageBox::error(0,(i18n("Cannot create file `%1' in %2.\nKMail cannot start without it.").tqarg(aFolderName).tqarg(mBasePath))); exit(-1); } if ( id > 0 ) diff --git a/kmail/kmfoldersearch.cpp b/kmail/kmfoldersearch.cpp index 5ebc8b2c4..fa36bde51 100644 --- a/kmail/kmfoldersearch.cpp +++ b/kmail/kmfoldersearch.cpp @@ -452,7 +452,7 @@ void KMFolderSearch::addSerNum(TQ_UINT32 serNum) << ": folder is " << aFolder << ", index is " << idx << endl; return; } - if(mFolders.findIndex(aFolder) == -1) { + if(mFolders.tqfindIndex(aFolder) == -1) { aFolder->open("foldersearch"); mFolders.append(aFolder); } @@ -856,7 +856,7 @@ bool KMFolderSearch::readIndex() return false; } mSerNums.push_back(serNum); - if(mFolders.findIndex(folder) == -1) { + if(mFolders.tqfindIndex(folder) == -1) { if (mInvalid) //exceptional case for when folder has invalid ids return false; folder->open("foldersearch"); diff --git a/kmail/kmfoldertree.cpp b/kmail/kmfoldertree.cpp index edd641cc9..c8bde2b63 100644 --- a/kmail/kmfoldertree.cpp +++ b/kmail/kmfoldertree.cpp @@ -918,7 +918,7 @@ bool KMFolderTree::checkUnreadFolder (KMFolderTreeItem* fti, bool confirm) // parameter (kept in the config file for kmail) if ( KMessageBox::questionYesNo( this, i18n( "<qt>Go to the next unread message in folder <b>%1</b>?</qt>" ) - .arg( fti->folder()->label() ), + .tqarg( fti->folder()->label() ), i18n( "Go to Next Unread Message" ), i18n("Go To"), i18n("Do Not Go To"), // defaults "AskNextFolder", @@ -1115,13 +1115,13 @@ void KMFolderTree::slotContextMenuRequested( TQListViewItem *lvi, // copy folder TQPopupMenu *copyMenu = new TQPopupMenu( folderMenu ); - folderToPopupMenu( CopyFolder, this, &mMenuToFolder, copyMenu ); + folderToPopupMenu( CopyFolder, TQT_TQOBJECT(this), &mMenuToFolder, copyMenu ); folderMenu->insertItem( i18n("&Copy Folder To"), copyMenu ); if ( fti->folder()->isMoveable() && fti->folder()->canDeleteMessages() ) { TQPopupMenu *moveMenu = new TQPopupMenu( folderMenu ); - folderToPopupMenu( MoveFolder, this, &mMenuToFolder, moveMenu ); + folderToPopupMenu( MoveFolder, TQT_TQOBJECT(this), &mMenuToFolder, moveMenu ); folderMenu->insertItem( i18n("&Move Folder To"), moveMenu ); } @@ -1230,7 +1230,7 @@ void KMFolderTree::contentsMouseReleaseEvent(TQMouseEvent* me) } // react on middle-button only - if (btn != TQt::MidButton) { + if (btn != Qt::MidButton) { KFolderTree::contentsMouseReleaseEvent(me); return; } @@ -1280,7 +1280,7 @@ void KMFolderTree::addChildFolder( KMFolder *folder, TQWidget * tqparent ) const TQString message = i18n( "<qt>Cannot create folder under <b>%1</b> because of insufficient " "permissions on the server. If you think you should be able to create " "subfolders here, ask your administrator to grant you rights to do so." - "</qt> " ).arg(aFolder->label()); + "</qt> " ).tqarg(aFolder->label()); KMessageBox::error( this, message ); return; } @@ -1753,10 +1753,10 @@ void KMFolderTree::slotToggleSizeColumn() bool KMFolderTree::eventFilter( TQObject *o, TQEvent *e ) { if ( e->type() == TQEvent::MouseButtonPress && - static_cast<TQMouseEvent*>(e)->button() == RightButton && + TQT_TQMOUSEEVENT(e)->button() == Qt::RightButton && o->isA(TQHEADER_OBJECT_NAME_STRING) ) { - mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() ); + mPopup->popup( TQT_TQMOUSEEVENT(e)->globalPos() ); return true; } return KFolderTree::eventFilter(o, e); @@ -1851,7 +1851,7 @@ void KMFolderTree::folderToPopupMenu( MenuAction action, TQObject *receiver, { while ( menu->count() ) { - TQPopupMenu *popup = menu->findItem( menu->idAt( 0 ) )->popup(); + TQPopupMenu *popup = menu->tqfindItem( menu->idAt( 0 ) )->popup(); if ( popup ) delete popup; else @@ -1987,7 +1987,7 @@ void KMFolderTree::moveOrCopyFolder( TQValueList<TQGuardedPtr<KMFolder> > source if ( tqparent->hasNamedFolder( sourceFolderName ) || sourceFolderNames.tqcontains( sourceFolderName ) ) { KMessageBox::error( this, i18n("<qt>Cannot move or copy folder <b>%1</b> here because a folder with the same name already exists.</qt>") - .arg( sourceFolderName ) ); + .tqarg( sourceFolderName ) ); setDragEnabled( true ); return; } @@ -1998,7 +1998,7 @@ void KMFolderTree::moveOrCopyFolder( TQValueList<TQGuardedPtr<KMFolder> > source while ( f ) { if ( f->moveInProgress() ) { KMessageBox::error( this, i18n("<qt>Cannot move or copy folder <b>%1</b> because it is not completely copied itself.</qt>") - .arg( sourceFolderName ) ); + .tqarg( sourceFolderName ) ); setDragEnabled( true ); return; } @@ -2016,7 +2016,7 @@ void KMFolderTree::moveOrCopyFolder( TQValueList<TQGuardedPtr<KMFolder> > source while ( folderDir && ( folderDir != &kmkernel->folderMgr()->dir() ) && ( folderDir != source->tqparent() ) ) { - if ( folderDir->findRef( source ) != -1 ) + if ( folderDir->tqfindRef( source ) != -1 ) { KMessageBox::error( this, message ); setDragEnabled( true ); @@ -2051,7 +2051,7 @@ void KMFolderTree::moveOrCopyFolder( TQValueList<TQGuardedPtr<KMFolder> > source continue; KMFolderDir *childDir = (*it2)->tqparent(); do { - if ( tqparentDir == childDir || tqparentDir->findRef( childDir->owner() ) != -1 ) { + if ( tqparentDir == childDir || tqparentDir->tqfindRef( childDir->owner() ) != -1 ) { KMessageBox::error( this, i18n("Moving the selected folders is not possible") ); setDragEnabled( true ); return; diff --git a/kmail/kmheaders.cpp b/kmail/kmheaders.cpp index f20ceb994..fc282fec3 100644 --- a/kmail/kmheaders.cpp +++ b/kmail/kmheaders.cpp @@ -144,7 +144,7 @@ KMHeaders::KMHeaders(KMMainWidget *aOwner, TQWidget *tqparent, connect(mPopup, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotToggleColumn(int))); setShowSortIndicator(true); - setFocusPolicy( WheelFocus ); + setFocusPolicy( Qt::WheelFocus ); if (!pixmapsLoaded) { @@ -236,7 +236,7 @@ KMHeaders::~KMHeaders () bool KMHeaders::eventFilter ( TQObject *o, TQEvent *e ) { if ( e->type() == TQEvent::MouseButtonPress && - static_cast<TQMouseEvent*>(e)->button() == RightButton && + TQT_TQMOUSEEVENT(e)->button() == Qt::RightButton && o->isA(TQHEADER_OBJECT_NAME_STRING) ) { // if we currently only show one of either sender/receiver column @@ -249,7 +249,7 @@ bool KMHeaders::eventFilter ( TQObject *o, TQEvent *e ) else mPopup->changeItem(KPaintInfo::COL_RECEIVER, i18n("Receiver")); - mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() ); + mPopup->popup( TQT_TQMOUSEEVENT(e)->globalPos() ); return true; } return KListView::eventFilter(o, e); @@ -429,10 +429,10 @@ void KMHeaders::readColorConfig (void) KConfig* config = KMKernel::config(); // Custom/System colors KConfigGroupSaver saver(config, "Reader"); - TQColor c1=TQColor(kapp->palette().active().text()); + TQColor c1=TQColor(kapp->tqpalette().active().text()); TQColor c2=TQColor("red"); TQColor c3=TQColor("blue"); - TQColor c4=TQColor(kapp->palette().active().base()); + TQColor c4=TQColor(kapp->tqpalette().active().base()); TQColor c5=TQColor(0,0x7F,0); TQColor c6=TQColor(0,0x98,0); TQColor c7=KGlobalSettings::alternateBackgroundColor(); @@ -1163,11 +1163,11 @@ void KMHeaders::msgRemoved(int id, TQString msgId ) } if ((!tqparent || sci->isImperfectlyThreaded()) - && !mImperfectlyThreadedList.containsRef(item)) + && !mImperfectlyThreadedList.tqcontainsRef(item)) mImperfectlyThreadedList.append(item); if (tqparent && !sci->isImperfectlyThreaded() - && mImperfectlyThreadedList.containsRef(item)) + && mImperfectlyThreadedList.tqcontainsRef(item)) mImperfectlyThreadedList.removeRef(item); } } @@ -1178,7 +1178,7 @@ void KMHeaders::msgRemoved(int id, TQString msgId ) mImperfectlyThreadedList.removeRef( removedItem ); #ifdef DEBUG // This should never happen, in this case the folders are inconsistent. - while ( mImperfectlyThreadedList.findRef( removedItem ) != -1 ) { + while ( mImperfectlyThreadedList.tqfindRef( removedItem ) != -1 ) { mImperfectlyThreadedList.remove(); kdDebug(5006) << "Remove doubled item from mImperfectlyThreadedList: " << removedItem << endl; } @@ -1371,10 +1371,10 @@ void KMHeaders::setStyleDependantFrameWidth() { // set the width of the frame to a reasonable value for the current GUI style int frameWidth; - if( style().isA("KeramikStyle") ) - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; + if( tqstyle().isA("KeramikStyle") ) + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; else - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); if ( frameWidth < 0 ) frameWidth = 0; if ( frameWidth != lineWidth() ) @@ -1399,10 +1399,10 @@ void KMHeaders::setFolderInfotqStatus () else str = unread ? i18n( "1 unread", "%n unread", unread ) : i18n( "0 unread" ); const int count = mFolder->count(); - str = count ? i18n( "1 message, %1.", "%n messages, %1.", count ).arg( str ) + str = count ? i18n( "1 message, %1.", "%n messages, %1.", count ).tqarg( str ) : i18n( "0 messages" ); // no need for "0 unread" to be added here if ( mFolder->isReadOnly() ) - str = i18n("%1 = n messages, m unread.", "%1 Folder is read-only.").arg( str ); + str = i18n("%1 = n messages, m unread.", "%1 Folder is read-only.").tqarg( str ); BroadcastqStatus::instance()->seStatusMsg(str); } @@ -1451,7 +1451,7 @@ void KMHeaders::applyFiltersOnMsg() if ( msgCountToFilter - msgCount < 10 || !( msgCount % 20 ) || msgCount <= 10 ) { progressItem->updateProgress(); TQString statusMsg = i18n("Filtering message %1 of %2"); - statusMsg = statusMsg.arg( msgCount ).arg( msgCountToFilter ); + statusMsg = statusMsg.tqarg( msgCount ).tqarg( msgCountToFilter ); KPIM::BroadcastqStatus::instance()->seStatusMsg( statusMsg ); KApplication::kApplication()->eventLoop()->processEvents( TQEventLoop::ExcludeUserInput, 50 ); } @@ -2333,12 +2333,12 @@ void KMHeaders::contentsMousePressEvent(TQMouseEvent* e) if ( e->state() & ControlButton ) setSelected( lvi, !wasSelected ); - if ((e->button() == LeftButton) ) + if ((e->button() == Qt::LeftButton) ) mMousePressed = true; } // check if we are on a status column and toggle it - if ( lvi && e->button() == LeftButton && !( e->state() & (ShiftButton | ControlButton | AltButton | MetaButton) ) ) { + if ( lvi && e->button() == Qt::LeftButton && !( e->state() & (ShiftButton | ControlButton | AltButton | MetaButton) ) ) { bool flagsToggleable = GlobalSettings::self()->allowLocalFlags() || !(mFolder ? mFolder->isReadOnly() : true); int section = header()->sectionAt( e->pos().x() ); HeaderItem *item = static_cast<HeaderItem*>( lvi ); @@ -2366,7 +2366,7 @@ void KMHeaders::contentsMousePressEvent(TQMouseEvent* e) //----------------------------------------------------------------------------- void KMHeaders::contentsMouseReleaseEvent(TQMouseEvent* e) { - if (e->button() != RightButton) + if (e->button() != Qt::RightButton) KListView::contentsMouseReleaseEvent(e); mMousePressed = false; @@ -2465,7 +2465,7 @@ void KMHeaders::slotRMB() menu->insertSeparator(); TQPopupMenu *msgCopyMenu = new TQPopupMenu(menu); - mOwner->folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, this, + mOwner->folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, TQT_TQOBJECT(this), &mMenuToFolder, msgCopyMenu ); menu->insertItem(i18n("&Copy To"), msgCopyMenu); @@ -2474,7 +2474,7 @@ void KMHeaders::slotRMB() menu->setItemEnabled( id, false ); } else { TQPopupMenu *msgMoveMenu = new TQPopupMenu(menu); - mOwner->folderTree()->folderToPopupMenu( KMFolderTree::MoveMessage, this, + mOwner->folderTree()->folderToPopupMenu( KMFolderTree::MoveMessage, TQT_TQOBJECT(this), &mMenuToFolder, msgMoveMenu ); menu->insertItem(i18n("&Move To"), msgMoveMenu); } @@ -2815,7 +2815,7 @@ bool KMHeaders::writeSortOrder() unlink(TQFile::encodeName(sortFile)); kdWarning(5006) << "Error: Failure modifying " << sortFile << " (No space left on tqdevice?)" << endl; kdWarning(5006) << __FILE__ << ":" << __LINE__ << endl; - kmkernel->emergencyExit( i18n("Failure modifying %1\n(No space left on tqdevice?)").arg( sortFile )); + kmkernel->emergencyExit( i18n("Failure modifying %1\n(No space left on tqdevice?)").tqarg( sortFile )); } fclose(sortStream); ::rename(TQFile::encodeName(tempName), TQFile::encodeName(sortFile)); @@ -2855,7 +2855,7 @@ void KMHeaders::appendItemToSortFile(HeaderItem *khi) unlink(TQFile::encodeName(sortFile)); kdWarning(5006) << "Error: Failure modifying " << sortFile << " (No space left on tqdevice?)" << endl; kdWarning(5006) << __FILE__ << ":" << __LINE__ << endl; - kmkernel->emergencyExit( i18n("Failure modifying %1\n(No space left on tqdevice?)").arg( sortFile )); + kmkernel->emergencyExit( i18n("Failure modifying %1\n(No space left on tqdevice?)").tqarg( sortFile )); } fclose(sortStream); } else { @@ -3557,7 +3557,7 @@ void KMHeaders::cutMessages() void KMHeaders::pasteMessages() { - new MessageCopyHelper( mCopiedMessages, folder(), mMoveMessages, this ); + new MessageCopyHelper( mCopiedMessages, folder(), mMoveMessages, TQT_TQOBJECT(this) ); if ( mMoveMessages ) { mCopiedMessages.clear(); updateActions(); diff --git a/kmail/kmkernel.cpp b/kmail/kmkernel.cpp index 0eb1a1166..1d302c261 100644 --- a/kmail/kmkernel.cpp +++ b/kmail/kmkernel.cpp @@ -207,7 +207,7 @@ bool KMKernel::handleCommandLine( bool noArgsOpensReader ) // process args: KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); - if (args->getOption("subject")) + if (!args->getOption("subject").isNull()) { subj = TQString::fromLocal8Bit(args->getOption("subject")); // if kmail is called with 'kmail -session abc' then this doesn't mean @@ -225,25 +225,25 @@ bool KMKernel::handleCommandLine( bool noArgsOpensReader ) mailto = true; } - if (args->getOption("cc")) + if (!args->getOption("cc").isNull()) { mailto = true; cc = TQString::fromLocal8Bit(args->getOption("cc")); } - if (args->getOption("bcc")) + if (!args->getOption("bcc").isNull()) { mailto = true; bcc = TQString::fromLocal8Bit(args->getOption("bcc")); } - if (args->getOption("msg")) + if (!args->getOption("msg").isNull()) { mailto = true; messageFile.setPath( TQString::fromLocal8Bit(args->getOption("msg")) ); } - if (args->getOption("body")) + if (!args->getOption("body").isNull()) { mailto = true; body = TQString::fromLocal8Bit(args->getOption("body")); @@ -266,7 +266,7 @@ bool KMKernel::handleCommandLine( bool noArgsOpensReader ) if (args->isSet("check")) checkMail = true; - if ( args->getOption( "view" ) ) { + if ( !args->getOption( "view" ).isNull() ) { viewOnly = true; const TQString filename = TQString::fromLocal8Bit( args->getOption( "view" ) ); @@ -404,7 +404,7 @@ int KMKernel::openComposer (const TQString &to, const TQString &cc, if (!messageFile.isEmpty() && messageFile.isLocalFile()) { TQCString str = KPIM::kFileToString( messageFile.path(), true, false ); if( !str.isEmpty() ) { - msg->setBody( TQString::fromLocal8Bit( str ).utf8() ); + msg->setBody( TQString(TQString::fromLocal8Bit( str )).utf8() ); } else { TemplateParser parser( msg, TemplateParser::NewMessage ); parser.process( NULL, NULL ); @@ -937,7 +937,7 @@ int KMKernel::dcopAddMessage( const TQString & foldername,const KURL & msgUrl, msgId += msg->dateStr(); } - int k = mAddMessageMsgIds.findIndex( msgId ); + int k = mAddMessageMsgIds.tqfindIndex( msgId ); //fprintf(stderr,"tqfind %s = %d\n",(const char *) msgId,k); if ( k == -1 ) { @@ -1211,9 +1211,9 @@ TQString KMKernel::debugSernum( TQ_UINT32 serialNumber ) msg = folder->getMsgBase( idx ); if (msg) { res.append( TQString( " subject %s,\n sender %s,\n date %s.\n" ) - .arg( msg->subject() ) - .arg( msg->fromStrip() ) - .arg( msg->dateStr() ) ); + .tqarg( msg->subject() ) + .tqarg( msg->fromStrip() ) + .tqarg( msg->dateStr() ) ); } else { res.append( TQString( "Invalid serial number." ) ); } @@ -1360,7 +1360,7 @@ void KMKernel::testDir(const char *_name) KMessageBox::sorry(0, i18n("KMail could not create folder '%1';\n" "please make sure that you can view and " "modify the content of the folder '%2'.") - .arg( foldersPath ).arg( TQDir::homeDirPath() ) ); + .tqarg( foldersPath ).tqarg( TQDir::homeDirPath() ) ); ::exit(-1); } } @@ -1369,7 +1369,7 @@ void KMKernel::testDir(const char *_name) "incorrect;\n" "please make sure that you can view and modify " "the content of this folder.") - .arg( foldersPath ) ); + .tqarg( foldersPath ) ); ::exit(-1); } } @@ -1673,7 +1673,7 @@ void KMKernel::cleanupImapFolders() cfld = static_cast<KMFolderCachedImap*>(the_dimapFolderMgr->createFolder(TQString::number(acct->id()), false, KMFolderTypeCachedImap)->storage()); if (!cfld) { - KMessageBox::error(0,(i18n("Cannot create file `%1' in %2.\nKMail cannot start without it.").arg(acct->name()).arg(the_dimapFolderMgr->basePath()))); + KMessageBox::error(0,(i18n("Cannot create file `%1' in %2.\nKMail cannot start without it.").tqarg(acct->name()).tqarg(the_dimapFolderMgr->basePath()))); exit(-1); } cfld->folder()->setId( acct->id() ); @@ -1884,8 +1884,8 @@ bool KMKernel::transferMail( TQString & destinationDir ) "the same name in <i>%7</i>.<p>" "<strong>Would you like %3 to move the mail " "files now?</strong></qt>" ) - .arg( kmailName, kmailName, kmailName ) - .arg( dir, destinationDir, dir, destinationDir ); + .tqarg( kmailName, kmailName, kmailName ) + .tqarg( dir, destinationDir, dir, destinationDir ); } else { msg = i18n( "%1-%3 is the application name, %4-%6 are folder path", "<qt>The <i>%4</i> folder exists. " @@ -1894,8 +1894,8 @@ bool KMKernel::transferMail( TQString & destinationDir ) "this folder for you.<p>" "<strong>Would you like %3 to move the mail " "files now?</strong></qt>" ) - .arg( kmailName, kmailName, kmailName ) - .arg( dir, destinationDir, dir ); + .tqarg( kmailName, kmailName, kmailName ) + .tqarg( dir, destinationDir, dir ); } TQString title = i18n( "Migrate Mail Files?" ); TQString buttonText = i18n( "Move" ); @@ -1968,7 +1968,7 @@ void KMKernel::dumpDeadLetters() return; for ( TQPtrListIterator<KMainWindow> it(*KMainWindow::memberList) ; it.current() != 0; ++it ) { - if ( KMail::Composer * win = ::qt_cast<KMail::Composer*>( it.current() ) ) { + if ( KMail::Composer * win = ::tqqt_cast<KMail::Composer*>( it.current() ) ) { win->autoSaveMessage(); // saving the message has to be finished right here, we are called from a dtor, // therefore we have no chance to finish this later @@ -2047,7 +2047,7 @@ void KMKernel::slotResult(KIO::Job *job) { if (KMessageBox::warningContinueCancel(0, i18n("File %1 exists.\nDo you want to replace it?") - .arg((*it).url.prettyURL()), i18n("Save to File"), i18n("&Replace")) + .tqarg((*it).url.prettyURL()), i18n("Save to File"), i18n("&Replace")) == KMessageBox::Continue) byteArrayToRemoteFile((*it).data, (*it).url, true); } @@ -2108,7 +2108,7 @@ bool KMKernel::haveSystemTrayApplet() bool KMKernel::registerSystemTrayApplet( const KSystemTray* applet ) { - if ( systemTrayApplets.findIndex( applet ) == -1 ) { + if ( systemTrayApplets.tqfindIndex( applet ) == -1 ) { systemTrayApplets.append( applet ); return true; } @@ -2135,7 +2135,7 @@ void KMKernel::emergencyExit( const TQString& reason ) mesg = i18n("KMail encountered a fatal error and will terminate now"); } else { mesg = i18n("KMail encountered a fatal error and will " - "terminate now.\nThe error was:\n%1").arg( reason ); + "terminate now.\nThe error was:\n%1").tqarg( reason ); } kdWarning() << mesg << endl; diff --git a/kmail/kmlineeditspell.cpp b/kmail/kmlineeditspell.cpp index de50cd782..86acaef78 100644 --- a/kmail/kmlineeditspell.cpp +++ b/kmail/kmlineeditspell.cpp @@ -132,7 +132,7 @@ void KMLineEdit::dropEvent( TQDropEvent *event ) KIO::NetAccess::removeTempFile( fileName ); } else { TQString caption( i18n( "vCard Import Failed" ) ); - TQString text = i18n( "<qt>Unable to access <b>%1</b>.</qt>" ).arg( (*it).url() ); + TQString text = i18n( "<qt>Unable to access <b>%1</b>.</qt>" ).tqarg( (*it).url() ); KMessageBox::error( tqparentWidget(), text, caption ); } } diff --git a/kmail/kmmainwidget.cpp b/kmail/kmmainwidget.cpp index e573af2a8..1311de1c9 100644 --- a/kmail/kmmainwidget.cpp +++ b/kmail/kmmainwidget.cpp @@ -204,7 +204,7 @@ KMMainWidget::KMMainWidget(TQWidget *tqparent, const char *name, activatePanners(); - TQTimer::singleShot( 0, this, TQT_SLOT( slotShowStartupFolder() )); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowStartupFolder() )); connect( kmkernel->acctMgr(), TQT_SIGNAL( checkedMail( bool, bool, const TQMap<TQString, int> & ) ), this, TQT_SLOT( slotMailChecked( bool, bool, const TQMap<TQString, int> & ) ) ); @@ -252,7 +252,7 @@ KMMainWidget::KMMainWidget(TQWidget *tqparent, const char *name, mVacationScriptIndicator->hide(); connect( mVacationScriptIndicator, TQT_SIGNAL(itemReleased(int)), TQT_SLOT(slotEditVacation()) ); if ( GlobalSettings::checkOutOfOfficeOnStartup() ) - TQTimer::singleShot( 0, this, TQT_SLOT(slotCheckVacation()) ); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT(slotCheckVacation()) ); } @@ -469,7 +469,7 @@ void KMMainWidget::readConfig(void) bool check = config->readBoolEntry("checkmail-startup", false); if (check) // do it after building the kmmainwin, so that the progressdialog is available - TQTimer::singleShot( 0, this, TQT_SLOT( slotCheckMail() ) ); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( slotCheckMail() ) ); } } @@ -559,9 +559,9 @@ void KMMainWidget::createWidgets(void) if ( mLongFolderList ) { // superior splitter: folder tree vs. rest // inferior splitter: headers vs. message vs. mime tree - mPanner1 = new TQSplitter( TQt::Horizontal, this, "panner 1" ); + mPanner1 = new TQSplitter( Qt::Horizontal, this, "panner 1" ); mPanner1->setOpaqueResize( opaqueResize ); - Qt::Orientation orientation = mReaderWindowBelow ? TQt::Vertical : TQt::Horizontal; + Qt::Orientation orientation = mReaderWindowBelow ? Qt::Vertical : Qt::Horizontal; mPanner2 = new TQSplitter( orientation, mPanner1, "panner 2" ); mPanner2->setOpaqueResize( opaqueResize ); mPanner2->setChildrenCollapsible( false ); @@ -570,10 +570,10 @@ void KMMainWidget::createWidgets(void) } else /* !mLongFolderList */ { // superior splitter: ( folder tree + headers ) vs. message vs. mime // inferior splitter: folder tree vs. headers - mPanner1 = new TQSplitter( TQt::Vertical, this, "panner 1" ); + mPanner1 = new TQSplitter( Qt::Vertical, this, "panner 1" ); mPanner1->setOpaqueResize( opaqueResize ); mPanner1->setChildrenCollapsible( false ); - mPanner2 = new TQSplitter( TQt::Horizontal, mPanner1, "panner 2" ); + mPanner2 = new TQSplitter( Qt::Horizontal, mPanner1, "panner 2" ); mPanner2->setOpaqueResize( opaqueResize ); headerParent = mFolderViewParent = mPanner2; mimeParent = messageParent = mPanner1; @@ -606,7 +606,7 @@ void KMMainWidget::createWidgets(void) mQuickSearchLine = new KListViewIndexedSearchLine( mSearchToolBar, mHeaders, actionCollection(), "headers quick search line" ); #else - mQuickSearchLine = new HeaderListQuickSearch( mSearchToolBar, mHeaders, + mQuickSearchLine = new HeaderListQuickSearch( mSearchToolBar, TQT_TQOBJECT(mHeaders), actionCollection(), "headers quick search line" ); #endif label->setBuddy( mQuickSearchLine ); @@ -632,7 +632,7 @@ void KMMainWidget::createWidgets(void) mHeaders, TQT_SLOT(selectNextMessage())); if (mReaderWindowActive) { - mMsgView = new KMReaderWin(messageParent, this, actionCollection(), 0 ); + mMsgView = new KMReaderWin(messageParent, TQT_TQWIDGET(this), actionCollection(), 0 ); if ( mMsgActions ) { mMsgActions->setMessageView( mMsgView ); } @@ -661,23 +661,23 @@ void KMMainWidget::createWidgets(void) KAction *action; - mMoveMsgToFolderAction = new KAction( i18n("Move Message to Folder"), Key_M, this, + mMoveMsgToFolderAction = new KAction( i18n("Move Message to Folder"), Key_M, TQT_TQOBJECT(this), TQT_SLOT(slotMoveMsg()), actionCollection(), "move_message_to_folder" ); mMoveMsgToFolderAction->plugAccel( actionCollection()->kaccel() ); - action = new KAction( i18n("Copy Message to Folder"), Key_C, this, + action = new KAction( i18n("Copy Message to Folder"), Key_C, TQT_TQOBJECT(this), TQT_SLOT(slotCopyMsg()), actionCollection(), "copy_message_to_folder" ); action->plugAccel( actionCollection()->kaccel() ); - action = new KAction( i18n("Jump to Folder"), Key_J, this, + action = new KAction( i18n("Jump to Folder"), Key_J, TQT_TQOBJECT(this), TQT_SLOT(slotJumpToFolder()), actionCollection(), "jump_to_folder" ); action->plugAccel( actionCollection()->kaccel() ); // create list of folders - mFolderViewSplitter = new TQSplitter( TQt::Vertical, mFolderViewParent ); + mFolderViewSplitter = new TQSplitter( Qt::Vertical, mFolderViewParent ); mFolderViewSplitter->setOpaqueResize( KGlobalSettings::opaqueResize() ); mFavoriteFolderView = new KMail::FavoriteFolderView( this, mFolderViewSplitter ); if ( mFavoritesCheckMailAction ) @@ -714,7 +714,7 @@ void KMMainWidget::createWidgets(void) //Commands not worthy of menu items, but that deserve configurable keybindings mRemoveDuplicatesAction = new KAction( - i18n("Remove Duplicate Messages"), CTRL+Key_Asterisk, this, + i18n("Remove Duplicate Messages"), CTRL+Key_Asterisk, TQT_TQOBJECT(this), TQT_SLOT(removeDuplicates()), actionCollection(), "remove_duplicate_messages"); action->plugAccel( actionCollection()->kaccel() ); @@ -724,32 +724,32 @@ void KMMainWidget::createWidgets(void) action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Focus on Next Folder"), CTRL+Key_Right, mFolderTree, + i18n("Focus on Next Folder"), CTRL+Key_Right, TQT_TQOBJECT(mFolderTree), TQT_SLOT(incCurrentFolder()), actionCollection(), "inc_current_folder"); action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Focus on Previous Folder"), CTRL+Key_Left, mFolderTree, + i18n("Focus on Previous Folder"), CTRL+Key_Left, TQT_TQOBJECT(mFolderTree), TQT_SLOT(decCurrentFolder()), actionCollection(), "dec_current_folder"); action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Select Folder with Focus"), CTRL+Key_Space, mFolderTree, + i18n("Select Folder with Focus"), CTRL+Key_Space, TQT_TQOBJECT(mFolderTree), TQT_SLOT(selectCurrentFolder()), actionCollection(), "select_current_folder"); action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Focus on Next Message"), ALT+Key_Right, mHeaders, + i18n("Focus on Next Message"), ALT+Key_Right, TQT_TQOBJECT(mHeaders), TQT_SLOT(incCurrentMessage()), actionCollection(), "inc_current_message"); action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Focus on Previous Message"), ALT+Key_Left, mHeaders, + i18n("Focus on Previous Message"), ALT+Key_Left, TQT_TQOBJECT(mHeaders), TQT_SLOT(decCurrentMessage()), actionCollection(), "dec_current_message"); action->plugAccel( actionCollection()->kaccel() ); action = new KAction( - i18n("Select Message with Focus"), ALT+Key_Space, mHeaders, + i18n("Select Message with Focus"), ALT+Key_Space, TQT_TQOBJECT(mHeaders), TQT_SLOT( selectCurrentMessage() ), actionCollection(), "select_current_message"); action->plugAccel( actionCollection()->kaccel() ); @@ -950,7 +950,7 @@ void KMMainWidget::slotMailChecked( bool newMail, bool sendOnCheck, summary += "<br>" + i18n( "1 new message in %1", "%n new messages in %1", newInFolder.tqfind( *it ).data() ) - .arg( folder->prettyURL() ); + .tqarg( folder->prettyURL() ); } } } @@ -965,7 +965,7 @@ void KMMainWidget::slotMailChecked( bool newMail, bool sendOnCheck, if ( GlobalSettings::self()->verboseNewMailNotification() ) { summary = i18n( "%1 is a list of the number of new messages per folder", "<b>New mail arrived</b><br>%1" ) - .arg( summary ); + .tqarg( summary ); } else { summary = i18n( "New mail arrived" ); @@ -1097,7 +1097,7 @@ void KMMainWidget::modifyFolder( KMFolderTreeItem* folderItem ) KMFolder* folder = folderItem->folder(); KMFolderTree* folderTree = static_cast<KMFolderTree *>( folderItem->listView() ); KMFolderDialog props( folder, folder->tqparent(), folderTree, - i18n("Properties of Folder %1").arg( folder->label() ) ); + i18n("Properties of Folder %1").tqarg( folder->label() ) ); props.exec(); updateFolderMenu(); //Kolab issue 2152 @@ -1129,7 +1129,7 @@ void KMMainWidget::slotExpireFolder() KConfigGroupSaver saver(config, "General"); if (config->readBoolEntry("warn-before-expire", true)) { - str = i18n("<qt>Are you sure you want to expire the folder <b>%1</b>?</qt>").arg(TQStyleSheet::escape( mFolder->label() )); + str = i18n("<qt>Are you sure you want to expire the folder <b>%1</b>?</qt>").tqarg(TQStyleSheet::escape( mFolder->label() )); if (KMessageBox::warningContinueCancel(this, str, i18n("Expire Folder"), i18n("&Expire")) != KMessageBox::Continue) return; @@ -1152,7 +1152,7 @@ void KMMainWidget::slotEmptyFolder() TQString text = (isTrash) ? i18n("Are you sure you want to empty the trash folder?") : i18n("<qt>Are you sure you want to move all messages from " - "folder <b>%1</b> to the trash?</qt>").arg( TQStyleSheet::escape( mFolder->label() ) ); + "folder <b>%1</b> to the trash?</qt>").tqarg( TQStyleSheet::escape( mFolder->label() ) ); if (KMessageBox::warningContinueCancel(this, text, title, KGuiItem( title, "edittrash")) != KMessageBox::Continue) return; @@ -1209,14 +1209,14 @@ void KMMainWidget::slotRemoveFolder() title = i18n("Delete Search"); str = i18n("<qt>Are you sure you want to delete the search <b>%1</b>?<br>" "Any messages it shows will still be available in their original folder.</qt>") - .arg( TQStyleSheet::escape( mFolder->label() ) ); + .tqarg( TQStyleSheet::escape( mFolder->label() ) ); } else { title = i18n("Delete Folder"); if ( mFolder->count() == 0 ) { if ( !mFolder->child() || mFolder->child()->isEmpty() ) { str = i18n("<qt>Are you sure you want to delete the empty folder " "<b>%1</b>?</qt>") - .arg( TQStyleSheet::escape( mFolder->label() ) ); + .tqarg( TQStyleSheet::escape( mFolder->label() ) ); } else { str = i18n("<qt>Are you sure you want to delete the empty folder " @@ -1224,7 +1224,7 @@ void KMMainWidget::slotRemoveFolder() "not be empty and their contents will be discarded as well. " "<p><b>Beware</b> that discarded messages are not saved " "into your Trash folder and are permanently deleted.</qt>") - .arg( TQStyleSheet::escape( mFolder->label() ) ); + .tqarg( TQStyleSheet::escape( mFolder->label() ) ); } } else { if ( !mFolder->child() || mFolder->child()->isEmpty() ) { @@ -1232,14 +1232,14 @@ void KMMainWidget::slotRemoveFolder() "<b>%1</b>, discarding its contents? " "<p><b>Beware</b> that discarded messages are not saved " "into your Trash folder and are permanently deleted.</qt>") - .arg( TQStyleSheet::escape( mFolder->label() ) ); + .tqarg( TQStyleSheet::escape( mFolder->label() ) ); } else { str = i18n("<qt>Are you sure you want to delete the folder <b>%1</b> " "and all its subfolders, discarding their contents? " "<p><b>Beware</b> that discarded messages are not saved " "into your Trash folder and are permanently deleted.</qt>") - .arg( TQStyleSheet::escape( mFolder->label() ) ); + .tqarg( TQStyleSheet::escape( mFolder->label() ) ); } } } @@ -1636,7 +1636,7 @@ void KMMainWidget::updateListFilterAction() mListFilterAction->setEnabled( false ); else { mListFilterAction->setEnabled( true ); - mListFilterAction->setText( i18n( "Filter on Mailing-List %1..." ).arg( lname ) ); + mListFilterAction->setText( i18n( "Filter on Mailing-List %1..." ).tqarg( lname ) ); } } @@ -1717,7 +1717,7 @@ void KMMainWidget::slotCheckVacation() if ( !kmkernel->askToGoOnline() ) return; - Vacation *vac = new Vacation( this, true /* check only */ ); + Vacation *vac = new Vacation( TQT_TQOBJECT(this), true /* check only */ ); connect( vac, TQT_SIGNAL(scriptActive(bool)), TQT_SLOT(updateVactionScriptqStatus(bool)) ); } @@ -1730,7 +1730,7 @@ void KMMainWidget::slotEditVacation() if ( mVacation ) return; - mVacation = new Vacation( this ); + mVacation = new Vacation( TQT_TQOBJECT(this) ); connect( mVacation, TQT_SIGNAL(scriptActive(bool)), TQT_SLOT(updateVactionScriptqStatus(bool)) ); if ( mVacation->isUsable() ) { connect( mVacation, TQT_SIGNAL(result(bool)), mVacation, TQT_SLOT(deleteLater()) ); @@ -1848,7 +1848,7 @@ void KMMainWidget::setupForwardActions() mForwardActionMenu->insert( mForwardAttachedAction, 1 ); mForwardInlineAction->setShortcut( Key_F ); mForwardAttachedAction->setShortcut( SHIFT+Key_F ); - connect( mForwardActionMenu, TQT_SIGNAL(activated()), this, + connect( mForwardActionMenu, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(slotForwardInlineMsg()) ); } else { @@ -1856,7 +1856,7 @@ void KMMainWidget::setupForwardActions() mForwardActionMenu->insert( mForwardInlineAction, 1 ); mForwardInlineAction->setShortcut( SHIFT+Key_F ); mForwardAttachedAction->setShortcut( Key_F ); - connect( mForwardActionMenu, TQT_SIGNAL(activated()), this, + connect( mForwardActionMenu, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(slotForwardAttachedMsg()) ); } } @@ -2060,7 +2060,7 @@ void KMMainWidget::folderSelected( KMFolder* aFolder, bool forceJumpToUnread ) // Set a timer to show a splash screen if fetching folder contents // takes more than the amount of seconds configured in the kmailrc (default 1000 msec) mShowBusySplashTimer = new TQTimer( this ); - connect( mShowBusySplashTimer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( slotShowBusySplash() ) ); + connect( mShowBusySplashTimer, TQT_SIGNAL( timeout() ), TQT_TQOBJECT(this), TQT_SLOT( slotShowBusySplash() ) ); mShowBusySplashTimer->start( GlobalSettings::self()->folderLoadingTimeout(), true ); return; } else { @@ -2191,7 +2191,7 @@ void KMMainWidget::slotReplaceMsgByUnencryptedVersion() TQString prefix("DecryptedMsg."); int oldIdx = msgId.tqfind(prefix, 0, false); if( -1 == oldIdx ) { - int leftAngle = msgId.findRev( '<' ); + int leftAngle = msgId.tqfindRev( '<' ); msgId = msgId.insert( (-1 == leftAngle) ? 0 : ++leftAngle, prefix ); } else { @@ -2508,26 +2508,26 @@ void KMMainWidget::updateCustomTemplateMenus() new KActionMenu( i18n("Forward With Custom Template"), "mail_custom_forward", actionCollection(), "custom_forward" ); - TQSignalMapper *mCustomForwardMapper = new TQSignalMapper( this ); + TQSignalMapper *mCustomForwardMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mCustomForwardMapper, TQT_SIGNAL( mapped( int ) ), - this, TQT_SLOT( slotCustomForwardMsg( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotCustomForwardMsg( int ) ) ); mForwardActionMenu->insert( mCustomForwardActionMenu ); mCustomReplyActionMenu = new KActionMenu( i18n("Reply With Custom Template"), "mail_custom_reply", actionCollection(), "custom_reply" ); - TQSignalMapper *mCustomReplyMapper = new TQSignalMapper( this ); + TQSignalMapper *mCustomReplyMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mCustomReplyMapper, TQT_SIGNAL( mapped( int ) ), - this, TQT_SLOT( slotCustomReplyToMsg( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotCustomReplyToMsg( int ) ) ); mMsgActions->replyMenu()->insert( mCustomReplyActionMenu ); mCustomReplyAllActionMenu = new KActionMenu( i18n("Reply to All With Custom Template"), "mail_custom_reply_all", actionCollection(), "custom_reply_all" ); - TQSignalMapper *mCustomReplyAllMapper = new TQSignalMapper( this ); + TQSignalMapper *mCustomReplyAllMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mCustomReplyAllMapper, TQT_SIGNAL( mapped( int ) ), - this, TQT_SLOT( slotCustomReplyAllToMsg( int ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotCustomReplyAllToMsg( int ) ) ); mMsgActions->replyMenu()->insert( mCustomReplyAllActionMenu ); mCustomTemplates.clear(); @@ -2644,21 +2644,21 @@ void KMMainWidget::setupActions() //----- File Menu mSaveAsAction = new KAction( i18n("Save &As..."), "filesave", KStdAccel::shortcut(KStdAccel::Save), - this, TQT_SLOT(slotSaveMsg()), actionCollection(), "file_save_as" ); + TQT_TQOBJECT(this), TQT_SLOT(slotSaveMsg()), actionCollection(), "file_save_as" ); - mOpenAction = KStdAction::open( this, TQT_SLOT( slotOpenMsg() ), + mOpenAction = KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT( slotOpenMsg() ), actionCollection() ); (void) new KAction( i18n("&Compact All Folders"), 0, - this, TQT_SLOT(slotCompactAll()), + TQT_TQOBJECT(this), TQT_SLOT(slotCompactAll()), actionCollection(), "compact_all_folders" ); (void) new KAction( i18n("&Expire All Folders"), 0, - this, TQT_SLOT(slotExpireAll()), + TQT_TQOBJECT(this), TQT_SLOT(slotExpireAll()), actionCollection(), "expire_all_folders" ); (void) new KAction( i18n("&Refresh Local IMAP Cache"), "refresh", - this, TQT_SLOT(slotInvalidateIMAPFolders()), + TQT_TQOBJECT(this), TQT_SLOT(slotInvalidateIMAPFolders()), actionCollection(), "file_tqinvalidate_imap_cache" ); (void) new KAction( i18n("Empty All &Trash Folders"), 0, @@ -2666,7 +2666,7 @@ void KMMainWidget::setupActions() actionCollection(), "empty_trash" ); (void) new KAction( i18n("Check &Mail"), "mail_get", CTRL+Key_L, - this, TQT_SLOT(slotCheckMail()), + TQT_TQOBJECT(this), TQT_SLOT(slotCheckMail()), actionCollection(), "check_mail" ); mFavoritesCheckMailAction = new KAction( i18n("Check Mail in Favorite Folders"), @@ -2686,10 +2686,10 @@ void KMMainWidget::setupActions() connect(mActMenu,TQT_SIGNAL(activated(int)),this,TQT_SLOT(slotCheckOneAccount(int))); connect(mActMenu,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(getAccountMenu())); - (void) new KAction( i18n("&Send Queued Messages"), "mail_send", 0, this, + (void) new KAction( i18n("&Send Queued Messages"), "mail_send", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSendQueued()), actionCollection(), "send_queued"); - (void) new KAction( i18n("Online tqStatus (unknown)"), "online_status", 0, this, + (void) new KAction( i18n("Online tqStatus (unknown)"), "online_status", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOnlinetqStatus()), actionCollection(), "online_status"); KActionMenu *sendActionMenu = new @@ -2698,165 +2698,165 @@ void KMMainWidget::setupActions() sendActionMenu->setDelayed(true); mSendMenu = sendActionMenu->popupMenu(); - connect(mSendMenu,TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotSendQueuedVia(int))); + connect(mSendMenu,TQT_SIGNAL(activated(int)), TQT_TQOBJECT(this), TQT_SLOT(slotSendQueuedVia(int))); connect(mSendMenu,TQT_SIGNAL(aboutToShow()),this,TQT_SLOT(getTransportMenu())); KAction *act; //----- Tools menu if (tqparent()->inherits("KMMainWin")) { - act = new KAction( i18n("&Address Book..."), "contents", 0, this, + act = new KAction( i18n("&Address Book..."), "contents", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddrBook()), actionCollection(), "addressbook" ); if (KStandardDirs::findExe("kaddressbook").isEmpty()) act->setEnabled(false); } - act = new KAction( i18n("Certificate Manager..."), "pgp-keys", 0, this, + act = new KAction( i18n("Certificate Manager..."), "pgp-keys", 0, TQT_TQOBJECT(this), TQT_SLOT(slotStartCertManager()), actionCollection(), "tools_start_certman"); // disable action if no certman binary is around if (KStandardDirs::findExe("kleopatra").isEmpty()) act->setEnabled(false); - act = new KAction( i18n("GnuPG Log Viewer..."), "pgp-keys", 0, this, + act = new KAction( i18n("GnuPG Log Viewer..."), "pgp-keys", 0, TQT_TQOBJECT(this), TQT_SLOT(slotStartWatchGnuPG()), actionCollection(), "tools_start_kwatchgnupg"); // disable action if no kwatchgnupg binary is around if (KStandardDirs::findExe("kwatchgnupg").isEmpty()) act->setEnabled(false); - act = new KAction( i18n("&Import Messages..."), "fileopen", 0, this, + act = new KAction( i18n("&Import Messages..."), "fileopen", 0, TQT_TQOBJECT(this), TQT_SLOT(slotImport()), actionCollection(), "import" ); if (KStandardDirs::findExe("kmailcvt").isEmpty()) act->setEnabled(false); #if !defined(NDEBUG) (void) new KAction( i18n("&Debug Sieve..."), - "idea", 0, this, TQT_SLOT(slotDebugSieve()), + "idea", 0, TQT_TQOBJECT(this), TQT_SLOT(slotDebugSieve()), actionCollection(), "tools_debug_sieve" ); #endif if ( GlobalSettings::allowOutOfOfficeSettings() ) { (void) new KAction( i18n("Edit \"Out of Office\" Replies..."), - "configure", 0, this, TQT_SLOT(slotEditVacation()), + "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotEditVacation()), actionCollection(), "tools_edit_vacation" ); } - (void) new KAction( i18n("Filter &Log Viewer..."), 0, this, + (void) new KAction( i18n("Filter &Log Viewer..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFilterLogViewer()), actionCollection(), "filter_log_viewer" ); - (void) new KAction( i18n("&Anti-Spam Wizard..."), 0, this, + (void) new KAction( i18n("&Anti-Spam Wizard..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAntiSpamWizard()), actionCollection(), "antiSpamWizard" ); - (void) new KAction( i18n("&Anti-Virus Wizard..."), 0, this, + (void) new KAction( i18n("&Anti-Virus Wizard..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAntiVirusWizard()), actionCollection(), "antiVirusWizard" ); //----- Edit Menu mTrashAction = new KAction( KGuiItem( i18n("&Move to Trash"), "edittrash", i18n("Move message to trashcan") ), - Key_Delete, this, TQT_SLOT(slotTrashMsg()), + Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotTrashMsg()), actionCollection(), "move_to_trash" ); /* The delete action is nowhere in the gui, by default, so we need to make * sure it is plugged into the KAccel now, since that won't happen on * XMLGui construction or manual ->plug(). This is only a problem when run * as a part, though. */ - mDeleteAction = new KAction( i18n("&Delete"), "editdelete", SHIFT+Key_Delete, this, + mDeleteAction = new KAction( i18n("&Delete"), "editdelete", SHIFT+Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotDeleteMsg()), actionCollection(), "delete" ); mDeleteAction->plugAccel( actionCollection()->kaccel() ); mTrashThreadAction = new KAction( KGuiItem( i18n("M&ove Thread to Trash"), "edittrash", i18n("Move thread to trashcan") ), - CTRL+Key_Delete, this, TQT_SLOT(slotTrashThread()), + CTRL+Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotTrashThread()), actionCollection(), "move_thread_to_trash" ); - mDeleteThreadAction = new KAction( i18n("Delete T&hread"), "editdelete", CTRL+SHIFT+Key_Delete, this, + mDeleteThreadAction = new KAction( i18n("Delete T&hread"), "editdelete", CTRL+SHIFT+Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotDeleteThread()), actionCollection(), "delete_thread" ); - (void) new KAction( i18n("&Find Messages..."), "mail_tqfind", Key_S, this, + (void) new KAction( i18n("&Find Messages..."), "mail_tqfind", Key_S, TQT_TQOBJECT(this), TQT_SLOT(slotRequestFullSearchFromQuickSearch()), actionCollection(), "search_messages" ); - mFindInMessageAction = new KAction( i18n("&Find in Message..."), "tqfind", KStdAccel::shortcut(KStdAccel::Find), this, + mFindInMessageAction = new KAction( i18n("&Find in Message..."), "tqfind", KStdAccel::shortcut(KStdAccel::Find), TQT_TQOBJECT(this), TQT_SLOT(slotFind()), actionCollection(), "find_in_messages" ); - (void) new KAction( i18n("Select &All Messages"), KStdAccel::selectAll(), this, + (void) new KAction( i18n("Select &All Messages"), KStdAccel::selectAll(), TQT_TQOBJECT(this), TQT_SLOT(slotMarkAll()), actionCollection(), "mark_all_messages" ); //----- Folder Menu - mNewFolderAction = new KAction( i18n("&New Folder..."), "folder_new", 0, mFolderTree, + mNewFolderAction = new KAction( i18n("&New Folder..."), "folder_new", 0, TQT_TQOBJECT(mFolderTree), TQT_SLOT(addChildFolder()), actionCollection(), "new_folder" ); - mModifyFolderAction = new KAction( i18n("&Properties"), "configure", 0, this, + mModifyFolderAction = new KAction( i18n("&Properties"), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotModifyFolder()), actionCollection(), "modify" ); mFolderMailingListPropertiesAction = new KAction( i18n("&Mailing List Management..."), - /*"folder_mailinglist_properties",*/ 0, this, TQT_SLOT( slotFolderMailingListProperties() ), + /*"folder_mailinglist_properties",*/ 0, TQT_TQOBJECT(this), TQT_SLOT( slotFolderMailingListProperties() ), actionCollection(), "folder_mailinglist_properties" ); mFolderShortCutCommandAction = new KAction( i18n("&Assign Shortcut..."), "configure_shortcuts", - 0, this, TQT_SLOT( slotFolderShortcutCommand() ), actionCollection(), + 0, TQT_TQOBJECT(this), TQT_SLOT( slotFolderShortcutCommand() ), actionCollection(), "folder_shortcut_command" ); - mMarkAllAsReadAction = new KAction( i18n("Mark All Messages as &Read"), "goto", 0, this, + mMarkAllAsReadAction = new KAction( i18n("Mark All Messages as &Read"), "goto", 0, TQT_TQOBJECT(this), TQT_SLOT(slotMarkAllAsRead()), actionCollection(), "mark_all_as_read" ); - mExpireFolderAction = new KAction(i18n("&Expiration Settings"), 0, this, TQT_SLOT(slotExpireFolder()), + mExpireFolderAction = new KAction(i18n("&Expiration Settings"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotExpireFolder()), actionCollection(), "expire"); - mCompactFolderAction = new KAction( i18n("&Compact Folder"), 0, this, + mCompactFolderAction = new KAction( i18n("&Compact Folder"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotCompactFolder()), actionCollection(), "compact" ); mRefreshFolderAction = new KAction( i18n("Check Mail &in This Folder"), "reload", - KStdAccel::shortcut( KStdAccel::Reload ), this, + KStdAccel::shortcut( KStdAccel::Reload ), TQT_TQOBJECT(this), TQT_SLOT(slotRefreshFolder()), actionCollection(), "refresh_folder" ); mTroubleshootFolderAction = 0; // set in initializeIMAPActions - mEmptyFolderAction = new KAction( "foo" /*set in updateFolderMenu*/, "edittrash", 0, this, + mEmptyFolderAction = new KAction( "foo" /*set in updateFolderMenu*/, "edittrash", 0, TQT_TQOBJECT(this), TQT_SLOT(slotEmptyFolder()), actionCollection(), "empty" ); - mRemoveFolderAction = new KAction( "foo" /*set in updateFolderMenu*/, "editdelete", 0, this, + mRemoveFolderAction = new KAction( "foo" /*set in updateFolderMenu*/, "editdelete", 0, TQT_TQOBJECT(this), TQT_SLOT(slotRemoveFolder()), actionCollection(), "delete_folder" ); - mArchiveFolderAction = new KAction( i18n( "&Archive Folder..." ), "filesave", 0, this, + mArchiveFolderAction = new KAction( i18n( "&Archive Folder..." ), "filesave", 0, TQT_TQOBJECT(this), TQT_SLOT( slotArchiveFolder() ), actionCollection(), "archive_folder" ); - mPreferHtmlAction = new KToggleAction( i18n("Prefer &HTML to Plain Text"), 0, this, + mPreferHtmlAction = new KToggleAction( i18n("Prefer &HTML to Plain Text"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotOverrideHtml()), actionCollection(), "prefer_html" ); - mPreferHtmlLoadExtAction = new KToggleAction( i18n("Load E&xternal References"), 0, this, + mPreferHtmlLoadExtAction = new KToggleAction( i18n("Load E&xternal References"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotOverrideHtmlLoadExt()), actionCollection(), "prefer_html_external_refs" ); - mThreadMessagesAction = new KToggleAction( i18n("&Thread Messages"), 0, this, + mThreadMessagesAction = new KToggleAction( i18n("&Thread Messages"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotOverrideThread()), actionCollection(), "thread_messages" ); - mThreadBySubjectAction = new KToggleAction( i18n("Thread Messages also by &Subject"), 0, this, + mThreadBySubjectAction = new KToggleAction( i18n("Thread Messages also by &Subject"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleSubjectThreading()), actionCollection(), "thread_messages_by_subject" ); - new KAction( i18n("Copy Folder"), "editcopy", SHIFT+CTRL+Key_C, folderTree(), + new KAction( i18n("Copy Folder"), "editcopy", SHIFT+CTRL+Key_C, TQT_TQOBJECT(folderTree()), TQT_SLOT(copyFolder()), actionCollection(), "copy_folder" ); - new KAction( i18n("Cut Folder"), "editcut", SHIFT+CTRL+Key_X, folderTree(), + new KAction( i18n("Cut Folder"), "editcut", SHIFT+CTRL+Key_X, TQT_TQOBJECT(folderTree()), TQT_SLOT(cutFolder()), actionCollection(), "cut_folder" ); - new KAction( i18n("Paste Folder"), "editpaste", SHIFT+CTRL+Key_V, folderTree(), + new KAction( i18n("Paste Folder"), "editpaste", SHIFT+CTRL+Key_V, TQT_TQOBJECT(folderTree()), TQT_SLOT(pasteFolder()), actionCollection(), "paste_folder" ); - new KAction( i18n("Copy Messages"), "editcopy", ALT+CTRL+Key_C, headers(), + new KAction( i18n("Copy Messages"), "editcopy", ALT+CTRL+Key_C, TQT_TQOBJECT(headers()), TQT_SLOT(copyMessages()), actionCollection(), "copy_messages" ); - new KAction( i18n("Cut Messages"), "editcut", ALT+CTRL+Key_X, headers(), + new KAction( i18n("Cut Messages"), "editcut", ALT+CTRL+Key_X, TQT_TQOBJECT(headers()), TQT_SLOT(cutMessages()), actionCollection(), "cut_messages" ); - new KAction( i18n("Paste Messages"), "editpaste", ALT+CTRL+Key_V, headers(), + new KAction( i18n("Paste Messages"), "editpaste", ALT+CTRL+Key_V, TQT_TQOBJECT(headers()), TQT_SLOT(pasteMessages()), actionCollection(), "paste_messages" ); //----- Message Menu - (void) new KAction( i18n("&New Message..."), "mail_new", KStdAccel::shortcut(KStdAccel::New), this, + (void) new KAction( i18n("&New Message..."), "mail_new", KStdAccel::shortcut(KStdAccel::New), TQT_TQOBJECT(this), TQT_SLOT(slotCompose()), actionCollection(), "new_message" ); mTemplateMenu = new KActionMenu( i18n("New Message From &Template"), "filenew", actionCollection(), "new_from_template" ); mTemplateMenu->setDelayed( true ); - connect( mTemplateMenu->popupMenu(), TQT_SIGNAL( aboutToShow() ), this, + connect( mTemplateMenu->popupMenu(), TQT_SIGNAL( aboutToShow() ), TQT_TQOBJECT(this), TQT_SLOT( slotShowNewFromTemplate() ) ); - connect( mTemplateMenu->popupMenu(), TQT_SIGNAL( activated(int) ), this, + connect( mTemplateMenu->popupMenu(), TQT_SIGNAL( activated(int) ), TQT_TQOBJECT(this), TQT_SLOT( slotNewFromTemplate(int) ) ); KAction* newToML = new KAction( i18n("New Message t&o Mailing-List..."), "mail_post_to", - CTRL+SHIFT+Key_N, this, + CTRL+SHIFT+Key_N, TQT_TQOBJECT(this), TQT_SLOT(slotPostToML()), actionCollection(), "post_message" ); newToML->plugAccel( actionCollection()->kaccel() ); @@ -2865,25 +2865,25 @@ void KMMainWidget::setupActions() "message_forward" ); mForwardInlineAction = new KAction( i18n("&Inline..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardInlineMsg()), actionCollection(), "message_forward_inline" ); mForwardAttachedAction = new KAction( i18n("Message->Forward->","As &Attachment..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardAttachedMsg()), actionCollection(), "message_forward_as_attachment" ); mForwardDigestAction = new KAction( i18n("Message->Forward->","As Di&gest..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardDigestMsg()), actionCollection(), "message_forward_as_digest" ); mRedirectAction = new KAction( i18n("Message->Forward->","&Redirect..."), - "mail_forward", Key_E, this, + "mail_forward", Key_E, TQT_TQOBJECT(this), TQT_SLOT(slotRedirectMsg()), actionCollection(), "message_forward_redirect" ); @@ -2894,38 +2894,38 @@ void KMMainWidget::setupActions() mForwardActionMenu->insert( mForwardDigestAction ); mForwardActionMenu->insert( mRedirectAction ); - mSendAgainAction = new KAction( i18n("Send A&gain..."), 0, this, + mSendAgainAction = new KAction( i18n("Send A&gain..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotResendMsg()), actionCollection(), "send_again" ); //----- Create filter actions mFilterMenu = new KActionMenu( i18n("&Create Filter"), "filter", actionCollection(), "create_filter" ); - connect( mFilterMenu, TQT_SIGNAL(activated()), this, + connect( mFilterMenu, TQT_SIGNAL(activated()), TQT_TQOBJECT(this), TQT_SLOT(slotFilter()) ); - mSubjectFilterAction = new KAction( i18n("Filter on &Subject..."), 0, this, + mSubjectFilterAction = new KAction( i18n("Filter on &Subject..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotSubjectFilter()), actionCollection(), "subject_filter"); mFilterMenu->insert( mSubjectFilterAction ); - mFromFilterAction = new KAction( i18n("Filter on &From..."), 0, this, + mFromFilterAction = new KAction( i18n("Filter on &From..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFromFilter()), actionCollection(), "from_filter"); mFilterMenu->insert( mFromFilterAction ); - mToFilterAction = new KAction( i18n("Filter on &To..."), 0, this, + mToFilterAction = new KAction( i18n("Filter on &To..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToFilter()), actionCollection(), "to_filter"); mFilterMenu->insert( mToFilterAction ); - mListFilterAction = new KAction( i18n("Filter on Mailing-&List..."), 0, this, + mListFilterAction = new KAction( i18n("Filter on Mailing-&List..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailingListFilter()), actionCollection(), "mlist_filter"); mFilterMenu->insert( mListFilterAction ); - mPrintAction = KStdAction::print (this, TQT_SLOT(slotPrintMsg()), actionCollection()); + mPrintAction = KStdAction::print (TQT_TQOBJECT(this), TQT_SLOT(slotPrintMsg()), actionCollection()); mUseAction = new KAction( i18n("New Message From &Template"), "filenew", - Key_N, this, TQT_SLOT( slotUseTemplate() ), + Key_N, TQT_TQOBJECT(this), TQT_SLOT( slotUseTemplate() ), actionCollection(), "use_template" ); mUseAction->plugAccel( actionCollection()->kaccel() ); @@ -2935,52 +2935,52 @@ void KMMainWidget::setupActions() mMarkThreadAsReadAction = new KAction(KGuiItem(i18n("Mark Thread as &Read"), "kmmsgread", i18n("Mark all messages in the selected thread as read")), - 0, this, TQT_SLOT(slotSetThreadStatusRead()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusRead()), actionCollection(), "thread_read"); mThreadStatusMenu->insert( mMarkThreadAsReadAction ); mMarkThreadAsNewAction = new KAction(KGuiItem(i18n("Mark Thread as &New"), "kmmsgnew", i18n("Mark all messages in the selected thread as new")), - 0, this, TQT_SLOT(slotSetThreadStatusNew()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusNew()), actionCollection(), "thread_new"); mThreadStatusMenu->insert( mMarkThreadAsNewAction ); mMarkThreadAsUnreadAction = new KAction(KGuiItem(i18n("Mark Thread as &Unread"), "kmmsgunseen", i18n("Mark all messages in the selected thread as unread")), - 0, this, TQT_SLOT(slotSetThreadStatusUnread()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusUnread()), actionCollection(), "thread_unread"); mThreadStatusMenu->insert( mMarkThreadAsUnreadAction ); - mThreadStatusMenu->insert( new KActionSeparator( this ) ); + mThreadStatusMenu->insert( new KActionSeparator( TQT_TQOBJECT(this) ) ); //----- "Mark Thread" toggle actions mToggleThreadFlagAction = new KToggleAction(i18n("Mark Thread as &Important"), "mail_flag", - 0, this, TQT_SLOT(slotSetThreadStatusFlag()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusFlag()), actionCollection(), "thread_flag"); mToggleThreadFlagAction->setCheckedState( i18n("Remove &Important Thread Mark") ); mThreadStatusMenu->insert( mToggleThreadFlagAction ); mToggleThreadTodoAction = new KToggleAction(i18n("Mark Thread as &Action Item"), "mail_todo", - 0, this, TQT_SLOT(slotSetThreadStatusTodo()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusTodo()), actionCollection(), "thread_todo"); mToggleThreadTodoAction->setCheckedState( i18n("Remove &Action Item Thread Mark") ); mThreadStatusMenu->insert( mToggleThreadTodoAction ); //------- "Watch and ignore thread" actions mWatchThreadAction = new KToggleAction(i18n("&Watch Thread"), "kmmsgwatched", - 0, this, TQT_SLOT(slotSetThreadStatusWatched()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusWatched()), actionCollection(), "thread_watched"); mIgnoreThreadAction = new KToggleAction(i18n("&Ignore Thread"), "mail_ignore", - 0, this, TQT_SLOT(slotSetThreadStatusIgnored()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetThreadStatusIgnored()), actionCollection(), "thread_ignored"); - mThreadStatusMenu->insert( new KActionSeparator( this ) ); + mThreadStatusMenu->insert( new KActionSeparator( TQT_TQOBJECT(this) ) ); mThreadStatusMenu->insert( mWatchThreadAction ); mThreadStatusMenu->insert( mIgnoreThreadAction ); mSaveAttachmentsAction = new KAction( i18n("Save A&ttachments..."), "attach", - 0, this, TQT_SLOT(slotSaveAttachments()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSaveAttachments()), actionCollection(), "file_save_attachments" ); mMoveActionMenu = new KActionMenu( i18n("&Move To" ), @@ -2990,7 +2990,7 @@ void KMMainWidget::setupActions() actionCollection(), "copy_to" ); mApplyAllFiltersAction = new KAction( i18n("Appl&y All Filters"), "filter", - CTRL+Key_J, this, + CTRL+Key_J, TQT_TQOBJECT(this), TQT_SLOT(slotApplyFilters()), actionCollection(), "apply_filters" ); @@ -3005,25 +3005,25 @@ void KMMainWidget::setupActions() actionCollection(), "view_unread" ); unreadMenu->setToolTip( i18n("Choose how to display the count of unread messages") ); - mUnreadColumnToggle = new KRadioAction( i18n("View->Unread Count", "View in &Separate Column"), 0, this, + mUnreadColumnToggle = new KRadioAction( i18n("View->Unread Count", "View in &Separate Column"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleUnread()), actionCollection(), "view_unread_column" ); mUnreadColumnToggle->setExclusiveGroup( "view_unread_group" ); unreadMenu->insert( mUnreadColumnToggle ); - mUnreadTextToggle = new KRadioAction( i18n("View->Unread Count", "View After &Folder Name"), 0, this, + mUnreadTextToggle = new KRadioAction( i18n("View->Unread Count", "View After &Folder Name"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleUnread()), actionCollection(), "view_unread_text" ); mUnreadTextToggle->setExclusiveGroup( "view_unread_group" ); unreadMenu->insert( mUnreadTextToggle ); // toggle for total column - mTotalColumnToggle = new KToggleAction( i18n("View->", "&Total Column"), 0, this, + mTotalColumnToggle = new KToggleAction( i18n("View->", "&Total Column"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleTotalColumn()), actionCollection(), "view_columns_total" ); mTotalColumnToggle->setToolTip( i18n("Toggle display of column showing the " "total number of messages in folders.") ); - mSizeColumnToggle = new KToggleAction( i18n("View->", "&Size Column"), 0, this, + mSizeColumnToggle = new KToggleAction( i18n("View->", "&Size Column"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleSizeColumn()), actionCollection(), "view_columns_size" ); mSizeColumnToggle->setToolTip( i18n("Toggle display of column showing the " @@ -3031,33 +3031,33 @@ void KMMainWidget::setupActions() (void)new KAction( KGuiItem( i18n("View->","&Expand Thread"), TQString(), i18n("Expand the current thread") ), - Key_Period, this, + Key_Period, TQT_TQOBJECT(this), TQT_SLOT(slotExpandThread()), actionCollection(), "expand_thread" ); (void)new KAction( KGuiItem( i18n("View->","&Collapse Thread"), TQString(), i18n("Collapse the current thread") ), - Key_Comma, this, + Key_Comma, TQT_TQOBJECT(this), TQT_SLOT(slotCollapseThread()), actionCollection(), "collapse_thread" ); (void)new KAction( KGuiItem( i18n("View->","Ex&pand All Threads"), TQString(), i18n("Expand all threads in the current folder") ), - CTRL+Key_Period, this, + CTRL+Key_Period, TQT_TQOBJECT(this), TQT_SLOT(slotExpandAllThreads()), actionCollection(), "expand_all_threads" ); (void)new KAction( KGuiItem( i18n("View->","C&ollapse All Threads"), TQString(), i18n("Collapse all threads in the current folder") ), - CTRL+Key_Comma, this, + CTRL+Key_Comma, TQT_TQOBJECT(this), TQT_SLOT(slotCollapseAllThreads()), actionCollection(), "collapse_all_threads" ); - mViewSourceAction = new KAction( i18n("&View Source"), Key_V, this, + mViewSourceAction = new KAction( i18n("&View Source"), Key_V, TQT_TQOBJECT(this), TQT_SLOT(slotShowMsgSrc()), actionCollection(), "view_source" ); - KAction* dukeOfMonmoth = new KAction( i18n("&Display Message"), Key_Return, this, + KAction* dukeOfMonmoth = new KAction( i18n("&Display Message"), Key_Return, TQT_TQOBJECT(this), TQT_SLOT( slotDisplayCurrentMessage() ), actionCollection(), "display_message" ); dukeOfMonmoth->plugAccel( actionCollection()->kaccel() ); @@ -3065,44 +3065,44 @@ void KMMainWidget::setupActions() //----- Go Menu new KAction( KGuiItem( i18n("&Next Message"), TQString(), i18n("Go to the next message") ), - "N;Right", this, TQT_SLOT(slotNextMessage()), + "N;Right", TQT_TQOBJECT(this), TQT_SLOT(slotNextMessage()), actionCollection(), "go_next_message" ); new KAction( KGuiItem( i18n("Next &Unread Message"), TQApplication::reverseLayout() ? "previous" : "next", i18n("Go to the next unread message") ), - Key_Plus, this, TQT_SLOT(slotNextUnreadMessage()), + Key_Plus, TQT_TQOBJECT(this), TQT_SLOT(slotNextUnreadMessage()), actionCollection(), "go_next_unread_message" ); /* ### needs better support from folders: new KAction( KGuiItem( i18n("Next &Important Message"), TQString(), i18n("Go to the next important message") ), - 0, this, TQT_SLOT(slotNextImportantMessage()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotNextImportantMessage()), actionCollection(), "go_next_important_message" ); */ new KAction( KGuiItem( i18n("&Previous Message"), TQString(), i18n("Go to the previous message") ), - "P;Left", this, TQT_SLOT(slotPrevMessage()), + "P;Left", TQT_TQOBJECT(this), TQT_SLOT(slotPrevMessage()), actionCollection(), "go_prev_message" ); new KAction( KGuiItem( i18n("Previous Unread &Message"), TQApplication::reverseLayout() ? "next" : "previous", i18n("Go to the previous unread message") ), - Key_Minus, this, TQT_SLOT(slotPrevUnreadMessage()), + Key_Minus, TQT_TQOBJECT(this), TQT_SLOT(slotPrevUnreadMessage()), actionCollection(), "go_prev_unread_message" ); /* needs better support from folders: new KAction( KGuiItem( i18n("Previous I&mportant Message"), TQString(), i18n("Go to the previous important message") ), - 0, this, TQT_SLOT(slotPrevImportantMessage()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotPrevImportantMessage()), actionCollection(), "go_prev_important_message" ); */ KAction *action = new KAction( KGuiItem( i18n("Next Unread &Folder"), TQString(), i18n("Go to the next folder with unread messages") ), - ALT+Key_Plus, this, TQT_SLOT(slotNextUnreadFolder()), + ALT+Key_Plus, TQT_TQOBJECT(this), TQT_SLOT(slotNextUnreadFolder()), actionCollection(), "go_next_unread_folder" ); KShortcut shortcut = action->shortcut(); shortcut.append( KKey( CTRL+Key_Plus ) ); @@ -3111,7 +3111,7 @@ void KMMainWidget::setupActions() action = new KAction( KGuiItem( i18n("Previous Unread F&older"), TQString(), i18n("Go to the previous folder with unread messages") ), - ALT+Key_Minus, this, TQT_SLOT(slotPrevUnreadFolder()), + ALT+Key_Minus, TQT_TQOBJECT(this), TQT_SLOT(slotPrevUnreadFolder()), actionCollection(), "go_prev_unread_folder" ); shortcut = action->shortcut(); shortcut.append( KKey( CTRL+Key_Minus ) ); @@ -3122,33 +3122,33 @@ void KMMainWidget::setupActions() i18n("Scroll down current message. " "If at end of current message, " "go to next unread message.") ), - Key_Space, this, TQT_SLOT(slotReadOn()), + Key_Space, TQT_TQOBJECT(this), TQT_SLOT(slotReadOn()), actionCollection(), "go_next_unread_text" ); //----- Settings Menu mToggleShowQuickSearchAction = new KToggleAction(i18n("Show Quick Search"), TQString(), - 0, this, TQT_SLOT(slotToggleShowQuickSearch()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotToggleShowQuickSearch()), actionCollection(), "show_quick_search"); mToggleShowQuickSearchAction->setChecked( GlobalSettings::self()->quickSearchActive() ); mToggleShowQuickSearchAction->setWhatsThis( i18n( GlobalSettings::self()->quickSearchActiveItem()->whatsThis().utf8() ) ); - (void) new KAction( i18n("Configure &Filters..."), 0, this, + (void) new KAction( i18n("Configure &Filters..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFilter()), actionCollection(), "filter" ); - (void) new KAction( i18n("Configure &POP Filters..."), 0, this, + (void) new KAction( i18n("Configure &POP Filters..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotPopFilter()), actionCollection(), "popFilter" ); - (void) new KAction( i18n("Manage &Sieve Scripts..."), 0, this, + (void) new KAction( i18n("Manage &Sieve Scripts..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotManageSieveScripts()), actionCollection(), "sieveFilters" ); (void) new KAction( KGuiItem( i18n("KMail &Introduction"), 0, i18n("Display KMail's Welcome Page") ), - 0, this, TQT_SLOT(slotIntro()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotIntro()), actionCollection(), "help_kmail_welcomepage" ); // ----- Standard Actions // KStdAction::configureNotifications(this, TQT_SLOT(slotEditNotifications()), actionCollection()); (void) new KAction( i18n("Configure &Notifications..."), - "knotify", 0, this, + "knotify", 0, TQT_TQOBJECT(this), TQT_SLOT(slotEditNotifications()), actionCollection(), "kmail_configure_notifications" ); // KStdAction::preferences(this, TQT_SLOT(slotSettings()), actionCollection()); @@ -3157,14 +3157,14 @@ void KMMainWidget::setupActions() TQT_SLOT(slotShowConfigurationDialog()), actionCollection(), "kmail_configure_kmail" ); - KStdAction::undo(this, TQT_SLOT(slotUndo()), actionCollection(), "kmail_undo"); + KStdAction::undo(TQT_TQOBJECT(this), TQT_SLOT(slotUndo()), actionCollection(), "kmail_undo"); - KStdAction::tipOfDay( this, TQT_SLOT( slotShowTip() ), actionCollection() ); + KStdAction::tipOfDay( TQT_TQOBJECT(this), TQT_SLOT( slotShowTip() ), actionCollection() ); menutimer = new TQTimer( this, "menutimer" ); connect( menutimer, TQT_SIGNAL( timeout() ), TQT_SLOT( updateMessageActions() ) ); connect( kmkernel->undoStack(), - TQT_SIGNAL( undoStackChanged() ), this, TQT_SLOT( slotUpdateUndo() )); + TQT_SIGNAL( undoStackChanged() ), TQT_TQOBJECT(this), TQT_SLOT( slotUpdateUndo() )); initializeIMAPActions( false ); // don't set state, config not read yet updateMessageActions(); @@ -3287,9 +3287,9 @@ void KMMainWidget::copySelectedToFolder(int menuId ) void KMMainWidget::updateMessageMenu() { mMenuToFolder.clear(); - folderTree()->folderToPopupMenu( KMFolderTree::MoveMessage, this, + folderTree()->folderToPopupMenu( KMFolderTree::MoveMessage, TQT_TQOBJECT(this), &mMenuToFolder, mMoveActionMenu->popupMenu() ); - folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, this, + folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, TQT_TQOBJECT(this), &mMenuToFolder, mCopyActionMenu->popupMenu() ); updateMessageActions(); } @@ -3514,8 +3514,8 @@ void KMMainWidget::slotMemInfo() { "Memory allocated, not used: %3\n" "Memory total allocated : %4\n" "Max. freeable memory : %5\n") - .arg(mi.hblks).arg(fmt(mi.uordblks)).arg(fmt(mi.fordblks)) - .arg(fmt(mi.arena)).arg(fmt(mi.keepcost)); + .tqarg(mi.hblks).tqarg(fmt(mi.uordblks)).tqarg(fmt(mi.fordblks)) + .tqarg(fmt(mi.arena)).tqarg(fmt(mi.keepcost)); KMessageBox::information(0, s, "Malloc information", s); #endif } @@ -3712,13 +3712,13 @@ void KMMainWidget::initializeFilterActions() TQValueListConstIterator<KMFilter*> it = kmkernel->filterMgr()->filters().constBegin(); for ( ;it != kmkernel->filterMgr()->filters().constEnd(); ++it ) { if (!(*it)->isEmpty() && (*it)->configureShortcut()) { - filterName = TQString("Filter %1").arg((*it)->name()); + filterName = TQString("Filter %1").tqarg((*it)->name()); normalizedName = filterName.tqreplace(" ", "_"); if (action(normalizedName.utf8())) continue; filterCommand = new KMMetaFilterActionCommand(*it, mHeaders, this); mFilterCommands.append(filterCommand); - TQString as = i18n("Filter %1").arg((*it)->name()); + TQString as = i18n("Filter %1").tqarg((*it)->name()); TQString icon = (*it)->icon(); if ( icon.isEmpty() ) icon = "gear"; @@ -3769,7 +3769,7 @@ void KMMainWidget::initializeIMAPActions( bool setState /* false the first time, if ( !mTroubleshootFolderAction ) { mTroubleshootFolderAction = new KAction( i18n("&Troubleshoot IMAP Cache..."), "wizard", 0, - this, TQT_SLOT(slotTroubleshootFolder()), actionCollection(), "troubleshoot_folder" ); + TQT_TQOBJECT(this), TQT_SLOT(slotTroubleshootFolder()), actionCollection(), "troubleshoot_folder" ); if ( setState ) updateFolderMenu(); // set initial state of the action } else { @@ -3801,8 +3801,8 @@ void KMMainWidget::slotShortcutChanged( KMFolder *folder ) FolderShortcutCommand *c = new FolderShortcutCommand( this, folder ); mFolderShortcutCommands.insert( folder->idString(), c ); - TQString actionlabel = TQString( "FolderShortcut %1").arg( folder->prettyURL() ); - TQString actionname = TQString( "FolderShortcut %1").arg( folder->idString() ); + TQString actionlabel = TQString( "FolderShortcut %1").tqarg( folder->prettyURL() ); + TQString actionname = TQString( "FolderShortcut %1").tqarg( folder->idString() ); TQString normalizedName = actionname.tqreplace(" ", "_"); KAction* action = new KAction(actionlabel, folder->shortcut(), c, TQT_SLOT(start()), diff --git a/kmail/kmmainwin.cpp b/kmail/kmmainwin.cpp index 21879c55e..fb2b28b27 100644 --- a/kmail/kmmainwin.cpp +++ b/kmail/kmmainwin.cpp @@ -36,10 +36,10 @@ KMMainWin::KMMainWin(TQWidget *) kapp->ref(); (void) new KAction( i18n("New &Window"), "window_new", 0, - this, TQT_SLOT(slotNewMailReader()), + TQT_TQOBJECT(this), TQT_SLOT(slotNewMailReader()), actionCollection(), "new_mail_client" ); - mKMMainWidget = new KMMainWidget( this, "KMMainWidget", this, actionCollection() ); + mKMMainWidget = new KMMainWidget( TQT_TQWIDGET(this), "KMMainWidget", this, actionCollection() ); mKMMainWidget->resize( 450, 600 ); setCentralWidget(mKMMainWidget); setupStatusBar(); @@ -51,13 +51,13 @@ KMMainWin::KMMainWin(TQWidget *) setStandardToolBarMenuEnabled(true); - KStdAction::configureToolbars(this, TQT_SLOT(slotEditToolbars()), + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotEditToolbars()), actionCollection()); - KStdAction::keyBindings(mKMMainWidget, TQT_SLOT(slotEditKeys()), + KStdAction::keyBindings(TQT_TQOBJECT(mKMMainWidget), TQT_SLOT(slotEditKeys()), actionCollection()); - KStdAction::quit( this, TQT_SLOT(slotQuit()), actionCollection()); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), actionCollection()); createGUI( "kmmainwin.rc", false ); // Don't use conserveMemory() because this renders dynamic plugging // of actions unusable! @@ -96,7 +96,7 @@ KMMainWin::~KMMainWin() if ( !it.current()->isHidden() && it.current()->isTopLevel() && it.current() != this && - ::qt_cast<KMMainWin *>( it.current() ) + ::tqqt_cast<KMMainWin *>( it.current() ) ) not_withdrawn++; } diff --git a/kmail/kmmessage.cpp b/kmail/kmmessage.cpp index 6501c9e5e..04af3d65b 100644 --- a/kmail/kmmessage.cpp +++ b/kmail/kmmessage.cpp @@ -201,7 +201,7 @@ KMMessage::~KMMessage() //----------------------------------------------------------------------------- void KMMessage::setReferences(const TQCString& aStr) { - if (!aStr) return; + if (aStr.isNull()) return; mMsg->Headers().References().FromString(aStr); mNeedsAssembly = true; } @@ -413,7 +413,7 @@ void KMMessage::fromDwString(const DwString& str, bool aSetqStatus) setqStatus(headerField("tqStatus").latin1(), headerField("X-tqStatus").latin1()); setEncryptionStateChar( headerField("X-KMail-EncryptionState").at(0) ); setSignatureStateChar( headerField("X-KMail-SignatureState").at(0) ); - setMDNSentState( static_cast<KMMsgMDNSentState>( headerField("X-KMail-MDN-Sent").at(0).latin1() ) ); + setMDNSentState( static_cast<KMMsgMDNSentState>( headerField("X-KMail-MDN-Sent").tqat(0).latin1() ) ); } if ( invitationState() == KMMsgInvitationUnknown && readyToShow() ) updateInvitationState(); @@ -641,9 +641,9 @@ static bool flushPart(TQString &msg, TQStringList &part, static TQString stripSignature( const TQString & msg, bool clearSigned ) { if ( clearSigned ) - return msg.left( msg.findRev( TQRegExp( "\n--\\s?\n" ) ) ); + return msg.left( msg.tqfindRev( TQRegExp( "\n--\\s?\n" ) ) ); else - return msg.left( msg.findRev( "\n-- \n" ) ); + return msg.left( msg.tqfindRev( "\n-- \n" ) ); } TQString KMMessage::smartQuote( const TQString & msg, int maxLineLength ) @@ -846,7 +846,7 @@ TQString KMMessage::asQuotedString( const TQString& aHeaderStr, // Remove blank lines at the beginning: const int firstNonWS = content.tqfind( TQRegExp( "\\S" ) ); - const int lineStart = content.findRev( '\n', firstNonWS ); + const int lineStart = content.tqfindRev( '\n', firstNonWS ); if ( lineStart >= 0 ) content.remove( 0, static_cast<unsigned int>( lineStart ) ); @@ -1114,8 +1114,8 @@ TQCString KMMessage::getRefStr() const if (!firstRef.isEmpty()) retRefStr = firstRef + ' '; - i = refStr.findRev('<'); - j = refStr.findRev('>'); + i = refStr.tqfindRev('<'); + j = refStr.tqfindRev('>'); lastRef = refStr.mid(i, j-i+1); if (!lastRef.isEmpty() && lastRef != firstRef) @@ -1141,14 +1141,14 @@ KMMessage* KMMessage::createRedirect( const TQString &toStr ) // X-KMail-Redirect-From: content TQString strByWayOf = TQString("%1 (by way of %2 <%3>)") - .arg( from() ) - .arg( ident.fullName() ) - .arg( ident.primaryEmailAddress() ); + .tqarg( from() ) + .tqarg( ident.fullName() ) + .tqarg( ident.primaryEmailAddress() ); // Resent-From: content TQString strFrom = TQString("%1 <%2>") - .arg( ident.fullName() ) - .arg( ident.primaryEmailAddress() ); + .tqarg( ident.fullName() ) + .tqarg( ident.primaryEmailAddress() ); // format the current date to be used in Resent-Date: TQString origDate = msg->headerField( "Date" ); @@ -1623,7 +1623,7 @@ TQString KMMessage::replaceHeadersInString( const TQString & s ) const { idx = 0; while ( ( idx = rx.search( result, idx ) ) != -1 ) { - TQString replacement = headerField( rx.cap(1).latin1() ); + TQString replacement = headerField( TQString(rx.cap(1)).latin1() ); result.tqreplace( idx, rx.matchedLength(), replacement ); idx += replacement.length(); } @@ -2085,7 +2085,7 @@ TQString KMMessage::replyToId() const if (rightAngle != -1) replyTo.truncate( rightAngle + 1 ); // now search the start of the message id - leftAngle = replyTo.findRev( '<' ); + leftAngle = replyTo.tqfindRev( '<' ); if (leftAngle != -1) replyTo = replyTo.mid( leftAngle ); @@ -2098,7 +2098,7 @@ TQString KMMessage::replyToId() const return replyTo; references = headerField("References"); - leftAngle = references.findRev( '<' ); + leftAngle = references.tqfindRev( '<' ); if (leftAngle != -1) references = references.mid( leftAngle ); rightAngle = references.tqfind( '>' ); @@ -2126,11 +2126,11 @@ TQString KMMessage::references() const TQString references = headerField( "References" ); // keep the last two entries for threading - leftAngle = references.findRev( '<' ); - leftAngle = references.findRev( '<', leftAngle - 1 ); + leftAngle = references.tqfindRev( '<' ); + leftAngle = references.tqfindRev( '<', leftAngle - 1 ); if( leftAngle != -1 ) references = references.mid( leftAngle ); - rightAngle = references.findRev( '>' ); + rightAngle = references.tqfindRev( '>' ); if( rightAngle != -1 ) references.truncate( rightAngle + 1 ); @@ -2186,7 +2186,7 @@ TQString KMMessage::msgId() const if (rightAngle != -1) msgId.truncate( rightAngle + 1 ); // now search the start of the message id - const int leftAngle = msgId.findRev( '<' ); + const int leftAngle = msgId.tqfindRev( '<' ); if (leftAngle != -1) msgId = msgId.mid( leftAngle ); return msgId; @@ -2367,11 +2367,11 @@ void KMMessage::setHeaderField( const TQCString& aName, const TQString& bValue, kdDebug(5006) << "aValue: \"" << aValue << "\"" << endl; #endif } - str = aName; + str = TQString(aName); if (str[str.length()-1] != ':') str += ": "; else str += ' '; if ( !aValue.isEmpty() ) - str += aValue; + str += TQString(aValue); if (str[str.length()-1] != '\n') str += '\n'; field = new DwField(str, mMsg); @@ -3160,7 +3160,7 @@ void KMMessage::bodyPart(int aIdx, KMMessagePart* aPart) const if ( DwBodyPart *part = dwBodyPart( aIdx ) ) { KMMessage::bodyPart(part, aPart); if( aPart->name().isEmpty() ) - aPart->setName( i18n("Attachment: %1").arg( aIdx ) ); + aPart->setName( i18n("Attachment: %1").tqarg( aIdx ) ); } } @@ -3193,7 +3193,7 @@ bool KMMessage::deleteBodyPart( int partIndex ) dummyPart.duplicate( part ); TQString comment = i18n("This attachment has been deleted."); if ( !part.fileName().isEmpty() ) - comment = i18n( "The attachment '%1' has been deleted." ).arg( part.fileName() ); + comment = i18n( "The attachment '%1' has been deleted." ).tqarg( part.fileName() ); dummyPart.setContentDescription( comment ); dummyPart.setBodyEncodedBinary( TQByteArray() ); TQCString cd = dummyPart.contentDisposition(); @@ -3261,8 +3261,8 @@ DwBodyPart* KMMessage::createDWBodyPart(const KMMessagePart* aPart) iM = parAV.tqfind('='); if( -1 < iM ) { - parA = parAV.left( iM ); - parV = parAV.right( parAV.length() - iM - 1 ); + parA = TQString(parAV.left( iM )); + parV = TQString(parAV.right( parAV.length() - iM - 1 )); if( ('"' == parV.at(0)) && ('"' == parV.at(parV.length()-1)) ) { parV.erase( 0, 1); @@ -3271,7 +3271,7 @@ DwBodyPart* KMMessage::createDWBodyPart(const KMMessagePart* aPart) } else { - parA = parAV; + parA = TQString(parAV); parV = ""; } DwParameter *param; @@ -3495,7 +3495,7 @@ TQCString KMMessage::stripEmailAddr( const TQCString& aStr ) bool inQuotedString = false; int commentLevel = 0; - for ( char* p = aStr.data(); *p; ++p ) { + for ( const char* p = aStr.data(); *p; ++p ) { switch ( context ) { case TopLevel : { switch ( *p ) { @@ -4037,7 +4037,7 @@ void KMMessage::readConfig() int languageNr = config->readNumEntry("reply-current-language",0); { // area for config group "KMMessage #n" - KConfigGroupSaver saver(config, TQString("KMMessage #%1").arg(languageNr)); + KConfigGroupSaver saver(config, TQString("KMMessage #%1").tqarg(languageNr)); sReplyLanguage = config->readEntry("language",KGlobal::locale()->language()); sReplyStr = config->readEntry("phrase-reply", i18n("On %D, you wrote:")); diff --git a/kmail/kmmimeparttree.cpp b/kmail/kmmimeparttree.cpp index c0b791892..730ad54d5 100644 --- a/kmail/kmmimeparttree.cpp +++ b/kmail/kmmimeparttree.cpp @@ -213,10 +213,10 @@ void KMMimePartTree::setStyleDependantFrameWidth() { // set the width of the frame to a reasonable value for the current GUI style int frameWidth; - if( style().isA("KeramikStyle") ) - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; + if( tqstyle().isA("KeramikStyle") ) + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; else - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); if ( frameWidth < 0 ) frameWidth = 0; if ( frameWidth != lineWidth() ) @@ -309,7 +309,7 @@ void KMMimePartTree::slotCopy() if ( !url.isValid() ) return; urls.append( url ); KURLDrag* drag = new KURLDrag( urls, this ); - TQApplication::clipboard()->setData( drag, TQClipboard::Clipboard ); + TQApplication::tqclipboard()->setData( drag, TQClipboard::Clipboard ); } //============================================================================= diff --git a/kmail/kmmsgbase.cpp b/kmail/kmmsgbase.cpp index aed324580..eb8ed59e0 100644 --- a/kmail/kmmsgbase.cpp +++ b/kmail/kmmsgbase.cpp @@ -587,8 +587,8 @@ TQCString KMMsgBase::toUsAscii(const TQString& _str, bool *ok) TQString result = _str; int len = result.length(); for (int i = 0; i < len; i++) - if (result.at(i).tqunicode() >= 128) { - result.at(i) = '?'; + if (result.tqat(i).tqunicode() >= 128) { + result.tqat(i) = '?'; all_ok = false; } if (ok) @@ -800,7 +800,7 @@ TQCString KMMsgBase::encodeRFC2047String(const TQString& _str, unsigned int nonAscii = 0; unsigned int strLength(_str.length()); for (unsigned int i = 0; i < strLength; i++) - if (_str.at(i).tqunicode() >= 128) nonAscii++; + if (_str.tqat(i).tqunicode() >= 128) nonAscii++; bool useBase64 = (nonAscii * 6 > strLength); unsigned int start, stop, p, pos = 0, encLength; @@ -813,17 +813,17 @@ TQCString KMMsgBase::encodeRFC2047String(const TQString& _str, start = pos; p = pos; while (p < strLength) { - if (!breakLine && (_str.at(p) == ' ' || dontQuote.tqfind(_str.at(p)) != -1)) + if (!breakLine && (_str.tqat(p) == ' ' || dontQuote.tqfind(_str.tqat(p)) != -1)) start = p + 1; - if (_str.at(p).tqunicode() >= 128 || _str.at(p).tqunicode() < 32) + if (_str.tqat(p).tqunicode() >= 128 || _str.tqat(p).tqunicode() < 32) break; p++; } if (breakLine || p < strLength) { - while (dontQuote.tqfind(_str.at(start)) != -1) start++; + while (dontQuote.tqfind(_str.tqat(start)) != -1) start++; stop = start; - while (stop < strLength && dontQuote.tqfind(_str.at(stop)) == -1) + while (stop < strLength && dontQuote.tqfind(_str.tqat(stop)) == -1) stop++; result += _str.mid(pos, start - pos).latin1(); encLength = encodeRFC2047Quoted(codec->fromUnicode(_str. @@ -843,13 +843,13 @@ TQCString KMMsgBase::encodeRFC2047String(const TQString& _str, stop = start + dif; } p = stop; - while (p > start && _str.at(p) != ' ') p--; + while (p > start && _str.tqat(p) != ' ') p--; if (p > start) stop = p; if (result.right(3) == "?= ") start--; if (result.right(5) == "?=\n ") { start--; result.truncate(result.length() - 1); } - int lastNewLine = result.findRev("\n "); + int lastNewLine = result.tqfindRev("\n "); if (!result.mid(lastNewLine).stripWhiteSpace().isEmpty() && result.length() - lastNewLine + encLength + 2 > maxLen) result += "\n "; @@ -951,18 +951,18 @@ TQString KMMsgBase::decodeRFC2231String(const TQCString& _str) TQCString charset = _str.left(p); - TQCString st = _str.mid(_str.findRev('\'') + 1); + TQCString st = _str.mid(_str.tqfindRev('\'') + 1); char ch, ch2; p = 0; while (p < (int)st.length()) { - if (st.at(p) == 37) + if (st.tqat(p) == 37) { - ch = st.at(p+1) - 48; + ch = st.tqat(p+1) - 48; if (ch > 16) ch -= 7; - ch2 = st.at(p+2) - 48; + ch2 = st.tqat(p+2) - 48; if (ch2 > 16) ch2 -= 7; - st.at(p) = ch * 16 + ch2; + st.tqat(p) = ch * 16 + ch2; st.remove( p+1, 2 ); } p++; @@ -1477,7 +1477,7 @@ TQString KMMsgBase::replacePrefixes( const TQString& str, // 1. is anchored to the beginning of str (sans whitespace) // 2. matches at least one of the part regexps in prefixRegExps TQString bigRegExp = TQString::tqfromLatin1("^(?:\\s+|(?:%1))+\\s*") - .arg( prefixRegExps.join(")|(?:") ); + .tqarg( prefixRegExps.join(")|(?:") ); TQRegExp rx( bigRegExp, false /*case insens.*/ ); if ( !rx.isValid() ) { kdWarning(5006) << "KMMessage::replacePrefixes(): bigRegExp = \"" diff --git a/kmail/kmmsginfo.cpp b/kmail/kmmsginfo.cpp index 2d678bf19..8ce5f7cf3 100644 --- a/kmail/kmmsginfo.cpp +++ b/kmail/kmmsginfo.cpp @@ -707,7 +707,7 @@ void KMMsgInfo::setTo( const TQString &to ) //--- For compatability with old index files void KMMsgInfo::compat_fromOldIndexString(const TQCString& str, bool toUtf8) { - char *start, *offset; + const char *start, *offset; if(!kd) kd = new KMMsgInfoPrivate; diff --git a/kmail/kmmsgpartdlg.cpp b/kmail/kmmsgpartdlg.cpp index 386f4af60..a56bee17d 100644 --- a/kmail/kmmsgpartdlg.cpp +++ b/kmail/kmmsgpartdlg.cpp @@ -71,7 +71,7 @@ KMMsgPartDialog::KMMsgPartDialog( const TQString & caption, // row 0: Type combobox: mMimeType = new KComboBox( true, plainPage() ); mMimeType->setInsertionPolicy( TQComboBox::NoInsertion ); - mMimeType->setValidator( new KMimeTypeValidator( mMimeType ) ); + mMimeType->setValidator( new KMimeTypeValidator( TQT_TQOBJECT(mMimeType) ) ); mMimeType->insertStringList( TQStringList() << TQString::tqfromLatin1("text/html") << TQString::tqfromLatin1("text/plain") @@ -89,7 +89,7 @@ KMMsgPartDialog::KMMsgPartDialog( const TQString & caption, "<p>normally, you do not need to touch this setting, since the " "type of the file is automatically checked; but, sometimes, %1 " "may not detect the type correctly -- here is where you can fix " - "that.</p></qt>").arg( kapp->aboutData()->programName() ); + "that.</p></qt>").tqarg( kapp->aboutData()->programName() ); TQWhatsThis::add( mMimeType, msg ); // row 1: Size label: @@ -102,7 +102,7 @@ KMMsgPartDialog::KMMsgPartDialog( const TQString & caption, "because calculating the exact size would take too much time; " "when this is the case, it will be made visible by adding " "\"(est.)\" to the size displayed.</p></qt>") - .arg( kapp->aboutData()->programName() ); + .tqarg( kapp->aboutData()->programName() ); TQWhatsThis::add( mSize, msg ); // row 2: "Name" lineedit and label: @@ -148,7 +148,7 @@ KMMsgPartDialog::KMMsgPartDialog( const TQString & caption, "binary data, but consists of pure text -- in this case, choosing " "\"quoted-printable\" over the default \"base64\" will save up " "to 25% in resulting message size.</p></qt>") - .arg( kapp->aboutData()->programName() ); + .tqarg( kapp->aboutData()->programName() ); TQWhatsThis::add( label, msg ); TQWhatsThis::add( mEncoding, msg ); @@ -210,7 +210,7 @@ void KMMsgPartDialog::setMimeType( const TQString & mimeType ) { void KMMsgPartDialog::setMimeType( const TQString & type, const TQString & subtype ) { - setMimeType( TQString::tqfromLatin1("%1/%2").arg(type).arg(subtype) ); + setMimeType( TQString::tqfromLatin1("%1/%2").tqarg(type).tqarg(subtype) ); } void KMMsgPartDialog::setMimeTypeList( const TQStringList & mimeTypes ) { @@ -221,7 +221,7 @@ void KMMsgPartDialog::setSize( KIO::filesize_t size, bool estimated ) { TQString text = KIO::convertSize( size ); if ( estimated ) text = i18n("%1: a filesize incl. unit (e.g. \"1.3 KB\")", - "%1 (est.)").arg( text ); + "%1 (est.)").tqarg( text ); mSize->setText( text ); } diff --git a/kmail/kmpopfiltercnfrmdlg.cpp b/kmail/kmpopfiltercnfrmdlg.cpp index 0936df8a2..987485969 100644 --- a/kmail/kmpopfiltercnfrmdlg.cpp +++ b/kmail/kmpopfiltercnfrmdlg.cpp @@ -292,7 +292,7 @@ KMPopFilterCnfrmDlg::KMPopFilterCnfrmDlg(TQPtrList<KMPopHeaders> *aHeaders, cons TQLabel *l = new TQLabel(i18n("Messages to filter found on POP Account: <b>%1</b><p>" "The messages shown exceed the maximum size limit you defined for this account.<br>You can select " - "what you want to do with them by checking the appropriate button.").arg(aAccount), w); + "what you want to do with them by checking the appropriate button.").tqarg(aAccount), w); vbl->addWidget(l); TQVGroupBox *upperBox = new TQVGroupBox(i18n("Messages Exceeding Size"), w); @@ -360,7 +360,7 @@ KMPopFilterCnfrmDlg::KMPopFilterCnfrmDlg(TQPtrList<KMPopHeaders> *aHeaders, cons } if(rulesetCount) - lowerBox->setTitle(i18n("Ruleset Filtered Messages: %1").arg(rulesetCount)); + lowerBox->setTitle(i18n("Ruleset Filtered Messages: %1").tqarg(rulesetCount)); // connect signals and slots connect(lv, TQT_SIGNAL(pressed(TQListViewItem*, const TQPoint&, int)), diff --git a/kmail/kmreadermainwin.cpp b/kmail/kmreadermainwin.cpp index 840608178..f07ba8fe3 100644 --- a/kmail/kmreadermainwin.cpp +++ b/kmail/kmreadermainwin.cpp @@ -348,29 +348,29 @@ void KMReaderMainWin::setupAccel() // this, TQT_SLOT( slotSaveMsg() ), // actionCollection(), "file_save_as" ); - mSaveAsAction = KStdAction::saveAs( mReaderWin, TQT_SLOT( slotSaveMsg() ), + mSaveAsAction = KStdAction::saveAs( TQT_TQOBJECT(mReaderWin), TQT_SLOT( slotSaveMsg() ), actionCollection() ); mSaveAsAction->setShortcut( KStdAccel::shortcut( KStdAccel::Save ) ); - mPrintAction = KStdAction::print( this, TQT_SLOT( slotPrintMsg() ), + mPrintAction = KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT( slotPrintMsg() ), actionCollection() ); - KAction *closeAction = KStdAction::close( this, TQT_SLOT( close() ), actionCollection() ); + KAction *closeAction = KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() ); KShortcut closeShortcut = closeAction->shortcut(); closeShortcut.append( KKey(Key_Escape)); closeAction->setShortcut(closeShortcut); //----- Edit Menu - KStdAction::copy( this, TQT_SLOT( slotCopy() ), actionCollection() ); - KStdAction::selectAll( this, TQT_SLOT( slotMarkAll() ), actionCollection() ); - KStdAction::tqfind( this, TQT_SLOT(slotFind()), actionCollection() ); - KStdAction::findNext( this, TQT_SLOT( slotFindNext() ), actionCollection() ); + KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT( slotCopy() ), actionCollection() ); + KStdAction::selectAll( TQT_TQOBJECT(this), TQT_SLOT( slotMarkAll() ), actionCollection() ); + KStdAction::find( TQT_TQOBJECT(this), TQT_SLOT(slotFind()), actionCollection() ); + KStdAction::findNext( TQT_TQOBJECT(this), TQT_SLOT( slotFindNext() ), actionCollection() ); mTrashAction = new KAction( KGuiItem( i18n( "&Move to Trash" ), "edittrash", i18n( "Move message to trashcan" ) ), - Key_Delete, this, TQT_SLOT( slotTrashMsg() ), + Key_Delete, TQT_TQOBJECT(this), TQT_SLOT( slotTrashMsg() ), actionCollection(), "move_to_trash" ); //----- View Menu - mViewSourceAction = new KAction( i18n("&View Source"), Key_V, this, + mViewSourceAction = new KAction( i18n("&View Source"), Key_V, TQT_TQOBJECT(this), TQT_SLOT(slotShowMsgSrc()), actionCollection(), "view_source" ); @@ -379,25 +379,25 @@ void KMReaderMainWin::setupAccel() "mail_forward", actionCollection(), "message_forward" ); mForwardInlineAction = new KAction( i18n("&Inline..."), - "mail_forward", SHIFT+Key_F, this, + "mail_forward", SHIFT+Key_F, TQT_TQOBJECT(this), TQT_SLOT(slotForwardInlineMsg()), actionCollection(), "message_forward_inline" ); mForwardAttachedAction = new KAction( i18n("Message->Forward->","As &Attachment..."), - "mail_forward", Key_F, this, + "mail_forward", Key_F, TQT_TQOBJECT(this), TQT_SLOT(slotForwardAttachedMsg()), actionCollection(), "message_forward_as_attachment" ); mForwardDigestAction = new KAction( i18n("Message->Forward->","As Di&gest..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardDigestMsg()), actionCollection(), "message_forward_as_digest" ); mRedirectAction = new KAction( i18n("Message->Forward->","&Redirect..."), - "mail_forward", Key_E, this, + "mail_forward", Key_E, TQT_TQOBJECT(this), TQT_SLOT(slotRedirectMsg()), actionCollection(), "message_forward_redirect" ); @@ -435,7 +435,7 @@ void KMReaderMainWin::setupAccel() mReaderWin, TQT_SLOT(slotUrlClicked())); setStandardToolBarMenuEnabled(true); - KStdAction::configureToolbars(this, TQT_SLOT(slotEditToolbars()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotEditToolbars()), actionCollection()); } @@ -503,7 +503,7 @@ void KMReaderMainWin::slotMsgPopup(KMMessage &aMsg, const KURL &aUrl, const TQPo TQPopupMenu* copyMenu = new TQPopupMenu(menu); KMMainWidget* mainwin = kmkernel->getKMMainWidget(); if ( mainwin ) - mainwin->folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, this, + mainwin->folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, TQT_TQOBJECT(this), &mMenuToFolder, copyMenu ); menu->insertItem( i18n("&Copy To" ), copyMenu ); menu->insertSeparator(); diff --git a/kmail/kmreaderwin.cpp b/kmail/kmreaderwin.cpp index a6b3c1d51..5b80dc0ab 100644 --- a/kmail/kmreaderwin.cpp +++ b/kmail/kmreaderwin.cpp @@ -150,7 +150,7 @@ NewByteArray& NewByteArray::appendNULL() { TQByteArray::detach(); uint len1 = size(); - if ( !TQByteArray::resize( len1 + 1 ) ) + if ( !TQByteArray::tqresize( len1 + 1 ) ) return *this; *(data() + len1) = '\0'; return *this; @@ -162,7 +162,7 @@ NewByteArray& NewByteArray::operator+=( const char * newData ) TQByteArray::detach(); uint len1 = size(); uint len2 = tqstrlen( newData ); - if ( !TQByteArray::resize( len1 + len2 ) ) + if ( !TQByteArray::tqresize( len1 + len2 ) ) return *this; memcpy( data() + len1, newData, len2 ); return *this; @@ -174,7 +174,7 @@ NewByteArray& NewByteArray::operator+=( const TQByteArray & newData ) TQByteArray::detach(); uint len1 = size(); uint len2 = newData.size(); - if ( !TQByteArray::resize( len1 + len2 ) ) + if ( !TQByteArray::tqresize( len1 + len2 ) ) return *this; memcpy( data() + len1, newData.data(), len2 ); return *this; @@ -186,7 +186,7 @@ NewByteArray& NewByteArray::operator+=( const TQCString & newData ) TQByteArray::detach(); uint len1 = size(); uint len2 = newData.length(); // forget about the trailing 0x00 ! - if ( !TQByteArray::resize( len1 + len2 ) ) + if ( !TQByteArray::tqresize( len1 + len2 ) ) return *this; memcpy( data() + len1, newData.data(), len2 ); return *this; @@ -207,7 +207,7 @@ void KMReaderWin::objectTreeToDecryptedMsg( partNode* node, int recCount ) { kdDebug(5006) << TQString("-------------------------------------------------" ) << endl; - kdDebug(5006) << TQString("KMReaderWin::objectTreeToDecryptedMsg( %1 ) START").arg( recCount ) << endl; + kdDebug(5006) << TQString("KMReaderWin::objectTreeToDecryptedMsg( %1 ) START").tqarg( recCount ) << endl; if( node ) { kdDebug(5006) << node->typeString() << '/' << node->subTypeString() << endl; @@ -360,7 +360,7 @@ kdDebug(5006) << " Root node will NOT be replaced." << endl recCount + 1 ); } } - kdDebug(5006) << TQString("\nKMReaderWin::objectTreeToDecryptedMsg( %1 ) END").arg( recCount ) << endl; + kdDebug(5006) << TQString("\nKMReaderWin::objectTreeToDecryptedMsg( %1 ) END").tqarg( recCount ) << endl; } @@ -386,7 +386,7 @@ kdDebug(5006) << " Root node will NOT be replaced." << endl void KMReaderWin::createWidgets() { TQVBoxLayout * vlay = new TQVBoxLayout( this ); - mSplitter = new TQSplitter( TQt::Vertical, this, "mSplitter" ); + mSplitter = new TQSplitter( Qt::Vertical, this, "mSplitter" ); vlay->addWidget( mSplitter ); mMimePartTree = new KMMimePartTree( this, mSplitter, "mMimePartTree" ); mBox = new TQHBox( mSplitter, "mBox" ); @@ -467,11 +467,11 @@ KMReaderWin::KMReaderWin(TQWidget *aParent, mLevelQuote = GlobalSettings::self()->collapseQuoteLevelSpin() - 1; connect( &mUpdateReaderWinTimer, TQT_SIGNAL(timeout()), - this, TQT_SLOT(updateReaderWin()) ); + TQT_TQOBJECT(this), TQT_SLOT(updateReaderWin()) ); connect( &mResizeTimer, TQT_SIGNAL(timeout()), - this, TQT_SLOT(slotDelayedResize()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotDelayedResize()) ); connect( &mDelayedMarkTimer, TQT_SIGNAL(timeout()), - this, TQT_SLOT(slotTouchMessage()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotTouchMessage()) ); } @@ -487,45 +487,45 @@ void KMReaderWin::createActions( KActionCollection * ac ) { headerMenu->setToolTip( i18n("Choose display style of message headers") ); connect( headerMenu, TQT_SIGNAL(activated()), - this, TQT_SLOT(slotCycleHeaderStyles()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotCycleHeaderStyles()) ); raction = new KRadioAction( i18n("View->headers->", "&Enterprise Headers"), 0, - this, TQT_SLOT(slotEnterpriseHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotEnterpriseHeaders()), ac, "view_headers_enterprise" ); raction->setToolTip( i18n("Show the list of headers in Enterprise style") ); raction->setExclusiveGroup( "view_headers_group" ); headerMenu->insert(raction); raction = new KRadioAction( i18n("View->headers->", "&Fancy Headers"), 0, - this, TQT_SLOT(slotFancyHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotFancyHeaders()), ac, "view_headers_fancy" ); raction->setToolTip( i18n("Show the list of headers in a fancy format") ); raction->setExclusiveGroup( "view_headers_group" ); headerMenu->insert( raction ); raction = new KRadioAction( i18n("View->headers->", "&Brief Headers"), 0, - this, TQT_SLOT(slotBriefHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotBriefHeaders()), ac, "view_headers_brief" ); raction->setToolTip( i18n("Show brief list of message headers") ); raction->setExclusiveGroup( "view_headers_group" ); headerMenu->insert( raction ); raction = new KRadioAction( i18n("View->headers->", "&Standard Headers"), 0, - this, TQT_SLOT(slotStandardHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotStandardHeaders()), ac, "view_headers_standard" ); raction->setToolTip( i18n("Show standard list of message headers") ); raction->setExclusiveGroup( "view_headers_group" ); headerMenu->insert( raction ); raction = new KRadioAction( i18n("View->headers->", "&Long Headers"), 0, - this, TQT_SLOT(slotLongHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotLongHeaders()), ac, "view_headers_long" ); raction->setToolTip( i18n("Show long list of message headers") ); raction->setExclusiveGroup( "view_headers_group" ); headerMenu->insert( raction ); raction = new KRadioAction( i18n("View->headers->", "&All Headers"), 0, - this, TQT_SLOT(slotAllHeaders()), + TQT_TQOBJECT(this), TQT_SLOT(slotAllHeaders()), ac, "view_headers_all" ); raction->setToolTip( i18n("Show all message headers") ); raction->setExclusiveGroup( "view_headers_group" ); @@ -536,38 +536,38 @@ void KMReaderWin::createActions( KActionCollection * ac ) { new KActionMenu( i18n("View->", "&Attachments"), ac, "view_attachments" ); attachmentMenu->setToolTip( i18n("Choose display style of attachments") ); connect( attachmentMenu, TQT_SIGNAL(activated()), - this, TQT_SLOT(slotCycleAttachmentStrategy()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotCycleAttachmentStrategy()) ); raction = new KRadioAction( i18n("View->attachments->", "&As Icons"), 0, - this, TQT_SLOT(slotIconicAttachments()), + TQT_TQOBJECT(this), TQT_SLOT(slotIconicAttachments()), ac, "view_attachments_as_icons" ); raction->setToolTip( i18n("Show all attachments as icons. Click to see them.") ); raction->setExclusiveGroup( "view_attachments_group" ); attachmentMenu->insert( raction ); raction = new KRadioAction( i18n("View->attachments->", "&Smart"), 0, - this, TQT_SLOT(slotSmartAttachments()), + TQT_TQOBJECT(this), TQT_SLOT(slotSmartAttachments()), ac, "view_attachments_smart" ); raction->setToolTip( i18n("Show attachments as suggested by sender.") ); raction->setExclusiveGroup( "view_attachments_group" ); attachmentMenu->insert( raction ); raction = new KRadioAction( i18n("View->attachments->", "&Inline"), 0, - this, TQT_SLOT(slotInlineAttachments()), + TQT_TQOBJECT(this), TQT_SLOT(slotInlineAttachments()), ac, "view_attachments_inline" ); raction->setToolTip( i18n("Show all attachments inline (if possible)") ); raction->setExclusiveGroup( "view_attachments_group" ); attachmentMenu->insert( raction ); raction = new KRadioAction( i18n("View->attachments->", "&Hide"), 0, - this, TQT_SLOT(slotHideAttachments()), + TQT_TQOBJECT(this), TQT_SLOT(slotHideAttachments()), ac, "view_attachments_hide" ); raction->setToolTip( i18n("Do not show attachments in the message viewer") ); raction->setExclusiveGroup( "view_attachments_group" ); attachmentMenu->insert( raction ); mHeaderOnlyAttachmentsAction = new KRadioAction( i18n( "View->attachments->", "In Header &Only" ), 0, - this, TQT_SLOT( slotHeaderOnlyAttachments() ), + TQT_TQOBJECT(this), TQT_SLOT( slotHeaderOnlyAttachments() ), ac, "view_attachments_headeronly" ); mHeaderOnlyAttachmentsAction->setToolTip( i18n( "Show Attachments only in the header of the mail" ) ); mHeaderOnlyAttachmentsAction->setExclusiveGroup( "view_attachments_group" ); @@ -575,7 +575,7 @@ void KMReaderWin::createActions( KActionCollection * ac ) { // Set Encoding submenu mSelectEncodingAction = new KSelectAction( i18n( "&Set Encoding" ), "charset", 0, - this, TQT_SLOT( slotSetEncoding() ), + TQT_TQOBJECT(this), TQT_SLOT( slotSetEncoding() ), ac, "encoding" ); TQStringList encodings = KMMsgBase::supportedEncodings( false ); encodings.prepend( i18n( "Auto" ) ); @@ -583,39 +583,39 @@ void KMReaderWin::createActions( KActionCollection * ac ) { mSelectEncodingAction->setCurrentItem( 0 ); mMailToComposeAction = new KAction( i18n("New Message To..."), "mail_new", - 0, this, TQT_SLOT(slotMailtoCompose()), ac, + 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailtoCompose()), ac, "mailto_compose" ); mMailToReplyAction = new KAction( i18n("Reply To..."), "mail_reply", - 0, this, TQT_SLOT(slotMailtoReply()), ac, + 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailtoReply()), ac, "mailto_reply" ); mMailToForwardAction = new KAction( i18n("Forward To..."), "mail_forward", - 0, this, TQT_SLOT(slotMailtoForward()), ac, + 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailtoForward()), ac, "mailto_forward" ); mAddAddrBookAction = new KAction( i18n("Add to Address Book"), - 0, this, TQT_SLOT(slotMailtoAddAddrBook()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailtoAddAddrBook()), ac, "add_addr_book" ); mOpenAddrBookAction = new KAction( i18n("Open in Address Book"), - 0, this, TQT_SLOT(slotMailtoOpenAddrBook()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotMailtoOpenAddrBook()), ac, "openin_addr_book" ); - mCopyAction = KStdAction::copy( this, TQT_SLOT(slotCopySelectedText()), ac, "kmail_copy"); - mSelectAllAction = new KAction( i18n("Select All Text"), CTRL+SHIFT+Key_A, this, + mCopyAction = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(slotCopySelectedText()), ac, "kmail_copy"); + mSelectAllAction = new KAction( i18n("Select All Text"), CTRL+SHIFT+Key_A, TQT_TQOBJECT(this), TQT_SLOT(selectAll()), ac, "mark_all_text" ); - mCopyURLAction = new KAction( i18n("Copy Link Address"), 0, this, + mCopyURLAction = new KAction( i18n("Copy Link Address"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotUrlCopy()), ac, "copy_url" ); - mUrlOpenAction = new KAction( i18n("Open URL"), 0, this, + mUrlOpenAction = new KAction( i18n("Open URL"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotUrlOpen()), ac, "open_url" ); mAddBookmarksAction = new KAction( i18n("Bookmark This Link"), "bookmark_add", - 0, this, TQT_SLOT(slotAddBookmarks()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddBookmarks()), ac, "add_bookmarks" ); - mUrlSaveAsAction = new KAction( i18n("Save Link As..."), 0, this, + mUrlSaveAsAction = new KAction( i18n("Save Link As..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotUrlSave()), ac, "saveas_url" ); mToggleFixFontAction = new KToggleAction( i18n("Use Fi&xed Font"), - Key_X, this, TQT_SLOT(slotToggleFixedFont()), + Key_X, TQT_TQOBJECT(this), TQT_SLOT(slotToggleFixedFont()), ac, "toggle_fixedfont" ); - mStartIMChatAction = new KAction( i18n("Chat &With..."), 0, this, + mStartIMChatAction = new KAction( i18n("Chat &With..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotIMChat()), ac, "start_im_chat" ); } @@ -988,7 +988,7 @@ void KMReaderWin::writeConfig( bool sync ) const { //----------------------------------------------------------------------------- void KMReaderWin::initHtmlWidget(void) { - mViewer->widget()->setFocusPolicy(WheelFocus); + mViewer->widget()->setFocusPolicy(Qt::WheelFocus); // Let's better be paranoid and disable plugins (it defaults to enabled): mViewer->setPluginsEnabled(false); mViewer->setJScriptEnabled(false); // just make this explicit @@ -1017,9 +1017,9 @@ void KMReaderWin::initHtmlWidget(void) connect(mViewer,TQT_SIGNAL(popupMenu(const TQString &, const TQPoint &)), TQT_SLOT(slotUrlPopup(const TQString &, const TQPoint &))); connect( kmkernel->imProxy(), TQT_SIGNAL( sigContactPresenceChanged( const TQString & ) ), - this, TQT_SLOT( contacStatusChanged( const TQString & ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( contacStatusChanged( const TQString & ) ) ); connect( kmkernel->imProxy(), TQT_SIGNAL( sigPresenceInfoExpired() ), - this, TQT_SLOT( updateReaderWin() ) ); + TQT_TQOBJECT(this), TQT_SLOT( updateReaderWin() ) ); } void KMReaderWin::contacStatusChanged( const TQString &uid) @@ -1285,11 +1285,11 @@ void KMReaderWin::displaySplashPage( const TQString &info ) TQString location = locate("data", "kmail/about/main.html"); TQString content = KPIM::kFileToString(location); - content = content.arg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); + content = content.tqarg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); if ( kapp->reverseLayout() ) - content = content.arg( "@import \"%1\";" ).arg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); + content = content.tqarg( "@import \"%1\";" ).tqarg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); else - content = content.arg( "" ); + content = content.tqarg( "" ); mViewer->begin(KURL( location )); @@ -1297,7 +1297,7 @@ void KMReaderWin::displaySplashPage( const TQString &info ) TQString appTitle = i18n("KMail"); TQString catchPhrase = ""; //not enough space for a catch phrase at default window size i18n("Part of the Kontact Suite"); TQString quickDescription = i18n("The email client for the K Desktop Environment."); - mViewer->write(content.arg(fontSize).arg(appTitle).arg(catchPhrase).arg(quickDescription).arg(info)); + mViewer->write(content.tqarg(fontSize).tqarg(appTitle).tqarg(catchPhrase).tqarg(quickDescription).tqarg(info)); mViewer->end(); } @@ -1345,41 +1345,41 @@ void KMReaderWin::displayAboutPage() "<p>We hope that you will enjoy KMail.</p>\n" "<p>Thank you,</p>\n" "<p style='margin-bottom: 0px'> The KMail Team</p>") - .arg(KMAIL_VERSION) // KMail version - .arg("help:/kmail/index.html") // KMail help:// URL - .arg("http://kontact.kde.org/kmail/") // KMail homepage URL - .arg("1.8").arg("3.4"); // prior KMail and KDE version + .tqarg(KMAIL_VERSION) // KMail version + .tqarg("help:/kmail/index.html") // KMail help:// URL + .tqarg("http://kontact.kde.org/kmail/") // KMail homepage URL + .tqarg("1.8").tqarg("3.4"); // prior KMail and KDE version TQString featureItems; for ( int i = 0 ; i < numKMailNewFeatures ; i++ ) - featureItems += i18n("<li>%1</li>\n").arg( i18n( kmailNewFeatures[i] ) ); + featureItems += i18n("<li>%1</li>\n").tqarg( i18n( kmailNewFeatures[i] ) ); - info = info.arg( featureItems ); + info = info.tqarg( featureItems ); if( kmkernel->firstStart() ) { - info = info.arg( i18n("<p>Please take a moment to fill in the KMail " + info = info.tqarg( i18n("<p>Please take a moment to fill in the KMail " "configuration panel at Settings->Configure " "KMail.\n" "You need to create at least a default identity and " "an incoming as well as outgoing mail account." "</p>\n") ); } else { - info = info.arg( TQString() ); + info = info.tqarg( TQString() ); } if ( ( numKMailChanges > 1 ) || ( numKMailChanges == 1 && strlen(kmailChanges[0]) > 0 ) ) { TQString changesText = i18n("<p><span style='font-size:125%; font-weight:bold;'>" "Important changes</span> (compared to KMail %1):</p>\n") - .arg("1.8"); + .tqarg("1.8"); changesText += "<ul>\n"; for ( int i = 0 ; i < numKMailChanges ; i++ ) - changesText += i18n("<li>%1</li>\n").arg( i18n( kmailChanges[i] ) ); + changesText += i18n("<li>%1</li>\n").tqarg( i18n( kmailChanges[i] ) ); changesText += "</ul>\n"; - info = info.arg( changesText ); + info = info.tqarg( changesText ); } else - info = info.arg(""); // remove the %8 + info = info.tqarg(""); // remove the %8 displaySplashPage( info ); } @@ -1480,7 +1480,7 @@ void KMReaderWin::displayMessage() { htmlWriter()->queue("</body></html>"); htmlWriter()->flush(); - TQTimer::singleShot( 1, this, TQT_SLOT(injectAttachments()) ); + TQTimer::singleShot( 1, TQT_TQOBJECT(this), TQT_SLOT(injectAttachments()) ); } static bool message_was_saved_decrypted_before( const KMMessage * msg ) { @@ -1694,7 +1694,7 @@ TQString KMReaderWin::writeMessagePartToTempFile( KMMessagePart* aMsgPart, return TQString(); // strip off a leading path - int slashPos = fileName.findRev( '/' ); + int slashPos = fileName.tqfindRev( '/' ); if( -1 != slashPos ) fileName = fileName.mid( slashPos + 1 ); if( fileName.isEmpty() ) @@ -1764,8 +1764,8 @@ int KMReaderWin::msgPartFromUrl(const KURL &aUrl) if (!aUrl.isLocalFile()) return -1; TQString path = aUrl.path(); - uint right = path.findRev('/'); - uint left = path.findRev('.', right); + uint right = path.tqfindRev('/'); + uint left = path.tqfindRev('.', right); bool ok; int res = path.mid(left + 1, right - left - 1).toInt(&ok); @@ -1916,7 +1916,7 @@ void KMReaderWin::slotUrlOpen(const KURL &aUrl, const KParts::URLArgs &) return; kdWarning( 5006 ) << "KMReaderWin::slotOpenUrl(): Unhandled URL click!" << endl; - emit urlClicked( aUrl, TQt::LeftButton ); + emit urlClicked( aUrl, Qt::LeftButton ); } //----------------------------------------------------------------------------- @@ -1955,8 +1955,8 @@ static bool hasParentDivWithId( const DOM::Node &start, const TQString &id ) } } - if ( !start.tqparentNode().isNull() ) - return hasParentDivWithId( start.tqparentNode(), id ); + if ( !start.parentNode().isNull() ) + return hasParentDivWithId( start.parentNode(), id ); else return false; } @@ -1976,7 +1976,7 @@ void KMReaderWin::showAttachmentPopup( int id, const TQString & name, const TQPo menu->insertItem(SmallIcon("edit"), i18n("Edit Attachment"), 8 ); if ( GlobalSettings::self()->allowAttachmentDeletion() && canChange ) menu->insertItem(SmallIcon("editdelete"), i18n("Delete Attachment"), 7 ); - if ( name.endsWith( ".xia", false ) && + if ( name.tqendsWith( ".xia", false ) && Kleo::CryptoBackendFactory::instance()->protocol( "Chiasmus" ) ) menu->insertItem( i18n( "Decrypt With Chiasmus..." ), 6 ); menu->insertItem(i18n("Properties"), 5); @@ -1987,7 +1987,7 @@ void KMReaderWin::showAttachmentPopup( int id, const TQString & name, const TQPo menu->insertItem( i18n("Scroll To"), 10 ); } - connect(menu, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotHandleAttachment(int))); + connect(menu, TQT_SIGNAL(activated(int)), TQT_TQOBJECT(this), TQT_SLOT(slotHandleAttachment(int))); menu->exec( p ,0 ); delete menu; } @@ -1999,10 +1999,10 @@ void KMReaderWin::setStyleDependantFrameWidth() return; // set the width of the frame to a reasonable value for the current GUI style int frameWidth; - if( style().isA("KeramikStyle") ) - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; + if( tqstyle().isA("KeramikStyle") ) + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; else - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); if ( frameWidth < 0 ) frameWidth = 0; if ( frameWidth != mBox->lineWidth() ) @@ -2028,7 +2028,7 @@ void KMReaderWin::slotHandleAttachment( int choice ) node, message(), mAtmCurrent, mAtmCurrentName, KMHandleAttachmentCommand::AttachmentAction( choice ), 0, this ); connect( command, TQT_SIGNAL( showAttachment( int, const TQString& ) ), - this, TQT_SLOT( slotAtmView( int, const TQString& ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotAtmView( int, const TQString& ) ) ); command->start(); } else if ( choice == 7 ) { slotDeleteAttachment( node ); @@ -2041,7 +2041,7 @@ void KMReaderWin::slotHandleAttachment( int choice ) if (!url.isValid() ) return; urls.append( url ); KURLDrag* drag = new KURLDrag( urls, this ); - TQApplication::clipboard()->setData( drag, TQClipboard::Clipboard ); + TQApplication::tqclipboard()->setData( drag, TQClipboard::Clipboard ); } else if ( choice == 10 ) { // Scroll To scrollToAttachment( node ); } @@ -2142,7 +2142,7 @@ void KMReaderWin::setMsgPart( KMMessagePart* aMsgPart, bool aHTML, } htmlWriter()->queue("</body></html>"); htmlWriter()->flush(); - mMainWindow->setCaption(i18n("View Attachment: %1").arg(pname)); + mMainWindow->setCaption(i18n("View Attachment: %1").tqarg(pname)); } else if (kasciistricmp(aMsgPart->typeStr(), "image")==0 || (kasciistricmp(aMsgPart->typeStr(), "application")==0 && kasciistricmp(aMsgPart->subtypeStr(), "postscript")==0)) @@ -2178,7 +2178,7 @@ void KMReaderWin::setMsgPart( KMMessagePart* aMsgPart, bool aHTML, "\" border=\"0\">\n" "</body></html>\n" ); htmlWriter()->end(); - setCaption( i18n("View Attachment: %1").arg( pname ) ); + setCaption( i18n("View Attachment: %1").tqarg( pname ) ); show(); delete iio; } else { @@ -2198,7 +2198,7 @@ void KMReaderWin::setMsgPart( KMMessagePart* aMsgPart, bool aHTML, htmlWriter()->queue( "</pre>" ); htmlWriter()->queue("</body></html>"); htmlWriter()->flush(); - mMainWindow->setCaption(i18n("View Attachment: %1").arg(pname)); + mMainWindow->setCaption(i18n("View Attachment: %1").tqarg(pname)); } // ---Sven's view text, html and image attachments in html widget end --- } @@ -2287,14 +2287,14 @@ void KMReaderWin::openAttachment( int id, const TQString & name ) if ( filenameText.isEmpty() ) filenameText = msgPart.name(); if ( offer ) { - open_text = i18n("&Open with '%1'").arg( offer->name() ); + open_text = i18n("&Open with '%1'").tqarg( offer->name() ); } else { open_text = i18n("&Open With..."); } const TQString text = i18n("Open attachment '%1'?\n" "Note that opening an attachment may compromise " "your system's security.") - .arg( filenameText ); + .tqarg( filenameText ); const int choice = KMessageBox::questionYesNoCancel( this, text, i18n("Open Attachment?"), KStdGuiItem::saveAs(), open_text, TQString::tqfromLatin1("askSave") + mimetype->name() ); // dontAskAgainName @@ -2305,7 +2305,7 @@ void KMReaderWin::openAttachment( int id, const TQString & name ) message(), mAtmCurrent, mAtmCurrentName, KMHandleAttachmentCommand::Save, offer, this ); connect( command, TQT_SIGNAL( showAttachment( int, const TQString& ) ), - this, TQT_SLOT( slotAtmView( int, const TQString& ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotAtmView( int, const TQString& ) ) ); command->start(); } else if( choice == KMessageBox::No ) { // Open @@ -2315,7 +2315,7 @@ void KMReaderWin::openAttachment( int id, const TQString & name ) KMHandleAttachmentCommand* command = new KMHandleAttachmentCommand( node, message(), mAtmCurrent, mAtmCurrentName, action, offer, this ); connect( command, TQT_SIGNAL( showAttachment( int, const TQString& ) ), - this, TQT_SLOT( slotAtmView( int, const TQString& ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( slotAtmView( int, const TQString& ) ) ); command->start(); } else { // Cancel kdDebug(5006) << "Canceled opening attachment" << endl; @@ -2577,8 +2577,8 @@ KURL KMReaderWin::tempFileUrlFromPartNode( const partNode * node ) while ( it != end ) { TQString path = *it; it++; - uint right = path.findRev('/'); - uint left = path.findRev('.', right); + uint right = path.tqfindRev('/'); + uint left = path.tqfindRev('.', right); bool ok; int res = path.mid(left + 1, right - left - 1).toInt(&ok); @@ -2636,8 +2636,8 @@ static TQString linkForNode( const DOM::Node &node ) return href.nodeValue().string(); } } - if ( !node.tqparentNode().isNull() ) { - return linkForNode( node.tqparentNode() ); + if ( !node.parentNode().isNull() ) { + return linkForNode( node.parentNode() ); } else { return TQString(); } @@ -2651,14 +2651,14 @@ static TQString linkForNode( const DOM::Node &node ) bool KMReaderWin::eventFilter( TQObject *, TQEvent *e ) { if ( e->type() == TQEvent::MouseButtonPress ) { - TQMouseEvent* me = static_cast<TQMouseEvent*>(e); - if ( me->button() == LeftButton && ( me->state() & ShiftButton ) ) { + TQMouseEvent* me = TQT_TQMOUSEEVENT(e); + if ( me->button() == Qt::LeftButton && ( me->state() & ShiftButton ) ) { // special processing for shift+click URLHandlerManager::instance()->handleShiftClick( mHoveredUrl, this ); return true; } - if ( me->button() == LeftButton ) { + if ( me->button() == Qt::LeftButton ) { TQString imagePath; const DOM::Node nodeUnderMouse = mViewer->nodeUnderMouse(); @@ -2683,7 +2683,7 @@ bool KMReaderWin::eventFilter( TQObject *, TQEvent *e ) } if ( e->type() == TQEvent::MouseMove ) { - TQMouseEvent* me = static_cast<TQMouseEvent*>( e ); + TQMouseEvent* me = TQT_TQMOUSEEVENT( e ); // Handle this ourselves instead of connecting to mViewer::onURL(), since KHTML misses some // notifications in case we started a drag ourselves @@ -2698,8 +2698,8 @@ bool KMReaderWin::eventFilter( TQObject *, TQEvent *e ) // HACK: Send a mouse release event to the KHTMLView, as otherwise that will be missed in // case we started a drag. If the event is missed, the HTML view gets into a wrong // state, in which funny things like unsolicited drags start to happen. - TQMouseEvent mouseEvent( TQEvent::MouseButtonRelease, me->pos(), TQt::NoButton, TQt::NoButton ); - static_cast<TQObject*>( mViewer->view() )->eventFilter( mViewer->view()->viewport(), + TQMouseEvent mouseEvent( TQEvent::MouseButtonRelease, me->pos(), Qt::NoButton, Qt::NoButton ); + TQT_TQOBJECT( mViewer->view() )->eventFilter( mViewer->view()->viewport(), &mouseEvent ); return true; } @@ -2751,9 +2751,9 @@ void KMReaderWin::slotDeleteAttachment(partNode * node) KMDeleteAttachmentCommand* command = new KMDeleteAttachmentCommand( nodeId, msg, this ); command->start(); connect( command, TQT_SIGNAL( completed( KMCommand * ) ), - this, TQT_SLOT( updateReaderWin() ) ); + TQT_TQOBJECT(this), TQT_SLOT( updateReaderWin() ) ); connect( command, TQT_SIGNAL( completed( KMCommand * ) ), - this, TQT_SLOT( disconnectMsgAdded() ) ); + TQT_TQOBJECT(this), TQT_SLOT( disconnectMsgAdded() ) ); // ### HACK: Since the command will do delete + add, a new message will arrive. However, we don't // want the selection to change. Therefore, as soon as a new message arrives, select it, and then @@ -2762,7 +2762,7 @@ void KMReaderWin::slotDeleteAttachment(partNode * node) // And it won't work properly with multiple main windows const KMHeaders * const headers = KMKernel::self()->getKMMainWidget()->headers(); connect( headers, TQT_SIGNAL( msgAddedToListView( TQListViewItem* ) ), - this, TQT_SLOT( msgAdded( TQListViewItem* ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( msgAdded( TQListViewItem* ) ) ); } // If we are operating on a copy of parts of the message, make sure to update the copy as well. @@ -2788,7 +2788,7 @@ void KMReaderWin::disconnectMsgAdded() { const KMHeaders *const headers = KMKernel::self()->getKMMainWidget()->headers(); disconnect( headers, TQT_SIGNAL( msgAddedToListView( TQListViewItem* ) ), - this, TQT_SLOT( msgAdded( TQListViewItem* ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( msgAdded( TQListViewItem* ) ) ); } void KMReaderWin::slotEditAttachment(partNode * node) @@ -2828,12 +2828,12 @@ void KMReaderWin::scrollToAttachment( const partNode *node ) DOM::Document doc = mViewer->htmlDocument(); // The anchors for this are created in ObjectTreeParser::parseObjectTree() - mViewer->gotoAnchor( TQString::tqfromLatin1( "att%1" ).arg( node->nodeId() ) ); + mViewer->gotoAnchor( TQString::tqfromLatin1( "att%1" ).tqarg( node->nodeId() ) ); // Remove any old color markings which might be there const partNode *root = node->topLevelParent(); for ( int i = 0; i <= root->totalChildCount() + 1; i++ ) { - DOM::Element attachmentDiv = doc.getElementById( TQString( "attachmentDiv%1" ).arg( i + 1 ) ); + DOM::Element attachmentDiv = doc.getElementById( TQString( "attachmentDiv%1" ).tqarg( i + 1 ) ); if ( !attachmentDiv.isNull() ) attachmentDiv.removeAttribute( "style" ); } @@ -2845,14 +2845,14 @@ void KMReaderWin::scrollToAttachment( const partNode *node ) // Now, color the div of the attachment in yellow, so that the user sees what happened. // We created a special marked div for this in writeAttachmentMarkHeader() in ObjectTreeParser, // find and modify that now. - DOM::Element attachmentDiv = doc.getElementById( TQString( "attachmentDiv%1" ).arg( node->nodeId() ) ); + DOM::Element attachmentDiv = doc.getElementById( TQString( "attachmentDiv%1" ).tqarg( node->nodeId() ) ); if ( attachmentDiv.isNull() ) { kdWarning( 5006 ) << "Could not find attachment div for attachment " << node->nodeId() << endl; return; } attachmentDiv.setAttribute( "style", TQString( "border:2px solid %1" ) - .arg( cssHelper()->pgpWarnColor().name() ) ); + .tqarg( cssHelper()->pgpWarnColor().name() ) ); // Update rendering, otherwise the rendering is not updated when the user clicks on an attachment // that causes scrolling and the open attachment dialog @@ -2880,7 +2880,7 @@ void KMReaderWin::injectAttachments() imgSrc.append( "attachmentQuicklistOpened.png" ); } - TQString html = renderAttachments( mRootNode, TQApplication::palette().active().background() ); + TQString html = renderAttachments( mRootNode, TQApplication::tqpalette().active().background() ); if ( html.isEmpty() ) return; @@ -2931,8 +2931,8 @@ TQString KMReaderWin::renderAttachments(partNode * node, const TQColor &bgColor align = "right"; if ( node->msgPart().typeStr().lower() == "message" || node == mRootNode ) html += TQString::tqfromLatin1("<div style=\"background:%1; %2" - "vertical-align:middle; float:%3; %4\">").arg( bgColor.name() ).arg( margin ) - .arg( align ).arg( visibility ); + "vertical-align:middle; float:%3; %4\">").tqarg( bgColor.name() ).tqarg( margin ) + .tqarg( align ).tqarg( visibility ); html += subHtml; if ( node->msgPart().typeStr().lower() == "message" || node == mRootNode ) html += "</div>"; @@ -2941,7 +2941,7 @@ TQString KMReaderWin::renderAttachments(partNode * node, const TQColor &bgColor partNode::AttachmentDisplayInfo info = node->attachmentDisplayInfo(); if ( info.displayInHeader ) { html += "<div style=\"float:left;\">"; - html += TQString::tqfromLatin1( "<span style=\"white-space:nowrap; border-width: 0px; border-left-width: 5px; border-color: %1; 2px; border-left-style: solid;\">" ).arg( bgColor.name() ); + html += TQString::tqfromLatin1( "<span style=\"white-space:nowrap; border-width: 0px; border-left-width: 5px; border-color: %1; 2px; border-left-style: solid;\">" ).tqarg( bgColor.name() ); TQString fileName = writeMessagePartToTempFile( &node->msgPart(), node->nodeId() ); TQString href = node->asHREF( "header" ); html += TQString::tqfromLatin1( "<a href=\"" ) + href + @@ -3000,7 +3000,7 @@ void KMReaderWin::setBodyPartMemento( const partNode * node, const TQCString & w BodyPartMemento * KMReaderWin::bodyPartMemento( const partNode * node, const TQCString & which ) const { const TQCString index = node->path() + ':' + which.lower(); - const std::map<TQCString,BodyPartMemento*>::const_iterator it = mBodyPartMementoMap.tqfind( index ); + const std::map<TQCString,BodyPartMemento*>::const_iterator it = mBodyPartMementoMap.find( index ); if ( it == mBodyPartMementoMap.end() ) { return 0; } diff --git a/kmail/kmsearchpatternedit.cpp b/kmail/kmsearchpatternedit.cpp index 84005f2b7..55df4d5eb 100644 --- a/kmail/kmsearchpatternedit.cpp +++ b/kmail/kmsearchpatternedit.cpp @@ -86,7 +86,7 @@ void KMSearchRuleWidget::setHeadersOnly( bool headersOnly ) if (( currentText != "<message>") && ( currentText != "<body>")) - mRuleField->changeItem( TQString::fromAscii( currentText ), 0 ); + mRuleField->changeItem( TQString(TQString::fromAscii( currentText )), 0 ); else mRuleField->changeItem( TQString(), 0 ); } @@ -117,7 +117,7 @@ void KMSearchRuleWidget::initWidget() RuleWidgetHandlerManager::instance()->createWidgets( mFunctionStack, mValueStack, - this ); + TQT_TQOBJECT(this) ); // redirect focus to the header field combo box setFocusProxy( mRuleField ); @@ -392,14 +392,14 @@ void KMSearchRuleWidgetLister::regenerateRuleListFromWidgets() //============================================================================= KMSearchPatternEdit::KMSearchPatternEdit(TQWidget *tqparent, const char *name, bool headersOnly, bool absoluteDates ) - : TQGroupBox( 1/*columns*/, Horizontal, tqparent, name ) + : TQGroupBox( 1/*columns*/, Qt::Horizontal, tqparent, name ) { setTitle( i18n("Search Criteria") ); initLayout( headersOnly, absoluteDates ); } KMSearchPatternEdit::KMSearchPatternEdit(const TQString & title, TQWidget *tqparent, const char *name, bool headersOnly, bool absoluteDates) - : TQGroupBox( 1/*column*/, Horizontal, title, tqparent, name ) + : TQGroupBox( 1/*column*/, Qt::Horizontal, title, tqparent, name ) { initLayout( headersOnly, absoluteDates ); } diff --git a/kmail/kmsender.cpp b/kmail/kmsender.cpp index 1d267d88c..add465642 100644 --- a/kmail/kmsender.cpp +++ b/kmail/kmsender.cpp @@ -387,7 +387,7 @@ void KMSender::doSendMsg() "\"outbox\" to the \"sent-mail\" folder failed.\n" "Possible reasons are lack of disk space or write permission. " "Please try to fix the problem and move the message manually.") - .arg(mCurrentMsg->subject())); + .tqarg(mCurrentMsg->subject())); cleanup(); return; } @@ -435,7 +435,7 @@ void KMSender::doSendMsg() "identity '%1' in the Identities " "section of the configuration dialog " "and then try again." ) - .arg( id.identityName() ) ); + .tqarg( id.identityName() ) ); mOutboxFolder->unGetMsg( mFailedMessages ); mCurrentMsg = 0; } @@ -455,7 +455,7 @@ void KMSender::doSendMsg() mSentMessages)); } else { seStatusMsg(i18n("%1 of %2 queued messages successfully sent.") - .arg(mSentMessages).arg( mTotalMessages )); + .tqarg(mSentMessages).tqarg( mTotalMessages )); } } cleanup(); @@ -536,7 +536,7 @@ void KMSender::doSendMsg() } bool KMSender::runPrecommand( const TQString & cmd ) { - seStatusMsg( i18n("Executing precommand %1").arg( cmd ) ); + seStatusMsg( i18n("Executing precommand %1").tqarg( cmd ) ); mPrecommand = new KMPrecommand( cmd ); connect( mPrecommand, TQT_SIGNAL(finished(bool)), TQT_SLOT(slotPrecommandFinished(bool)) ); @@ -596,8 +596,8 @@ void KMSender::doSendMsgAux() // start sending the current message seStatusMsg(i18n("%3: subject of message","Sending message %1 of %2: %3") - .arg(mSentMessages+mFailedMessages+1).arg(mTotalMessages) - .arg(mCurrentMsg->subject())); + .tqarg(mSentMessages+mFailedMessages+1).tqarg(mTotalMessages) + .tqarg(mCurrentMsg->subject())); TQStringList to, cc, bcc; TQString sender; extractSenderToCCAndBcc( mCurrentMsg, &sender, &to, &cc, &bcc ); @@ -696,8 +696,8 @@ void KMSender::slotIdle() "fix the problem (e.g. a broken address) or remove the message " "from the 'outbox' folder.\n" "The following transport protocol was used:\n %2") - .arg(errString) - .arg(mMethodStr); + .tqarg(errString) + .tqarg(mMethodStr); if (!errString.isEmpty()) KMessageBox::error(0,msg); seStatusMsg( i18n( "Sending aborted." ) ); } else { @@ -724,8 +724,8 @@ void KMSender::slotIdle() "from the 'outbox' folder.</p>" "<p>The following transport protocol was used: %2</p>" "<p>Do you want me to continue sending the remaining messages?</p>") - .arg(errString) - .arg(mMethodStr); + .tqarg(errString) + .tqarg(mMethodStr); res = KMessageBox::warningYesNo( 0 , msg , i18n( "Continue Sending" ), i18n( "&Continue Sending" ), i18n("&Abort Sending") ); @@ -735,8 +735,8 @@ void KMSender::slotIdle() "fix the problem (e.g. a broken address) or remove the message " "from the 'outbox' folder.\n" "The following transport protocol was used:\n %2") - .arg(errString) - .arg(mMethodStr); + .tqarg(errString) + .tqarg(mMethodStr); KMessageBox::error(0,msg); } if (res == KMessageBox::Yes) { @@ -934,8 +934,8 @@ bool KMSendSendmail::doStart() { "Please remove it from there if you do not want the message to " "be resent.\n" "The following transport protocol was used:\n %2") - .arg(str + "\n") - .arg("sendmail://"); + .tqarg(str + "\n") + .tqarg("sendmail://"); KMessageBox::information(0,msg); return false; } @@ -978,7 +978,7 @@ bool KMSendSendmail::doSend( const TQString & sender, const TQStringList & to, c if ( !mMailerProc->start( KProcess::NotifyOnExit, KProcess::All ) ) { KMessageBox::information( 0, i18n("Failed to execute mailer program %1") - .arg( mSender->transportInfo()->host ) ); + .tqarg( mSender->transportInfo()->host ) ); return false; } mMsgPos = mMsgStr.data(); diff --git a/kmail/kmservertest.cpp b/kmail/kmservertest.cpp index b99e1cc95..67dc0f2d5 100644 --- a/kmail/kmservertest.cpp +++ b/kmail/kmservertest.cpp @@ -166,7 +166,7 @@ void KMServerTest::slotSlaveResult(KIO::Slave *aSlave, int error, if ( error ) { mJob = 0; - KMessageBox::error( kapp->activeWindow(), + KMessageBox::error( TQT_TQWIDGET(kapp->activeWindow()), KIO::buildErrorString( error, errorText ), i18n("Error") ); emit capabilities( mListNormal, mListSSL ); diff --git a/kmail/kmstartup.cpp b/kmail/kmstartup.cpp index 943a3a2d7..fd3d7bd7e 100644 --- a/kmail/kmstartup.cpp +++ b/kmail/kmstartup.cpp @@ -165,7 +165,7 @@ void lockOrDie() { // On linux with /proc we can even check that it's really kmail and not something else char path_buffer[MAXPATHLEN + 1]; path_buffer[MAXPATHLEN] = 0; - const TQString procPath = TQString("/proc/%1/exe").arg(oldPid); + const TQString procPath = TQString("/proc/%1/exe").tqarg(oldPid); const int length = readlink (procPath.latin1(), path_buffer, MAXPATHLEN); if ( length == -1 ) // not such pid first_instance = true; @@ -173,7 +173,7 @@ void lockOrDie() { path_buffer[length] = '\0'; const TQString path = TQFile::decodeName(path_buffer); kdDebug() << k_funcinfo << path << endl; - const int pos = path.findRev('/'); + const int pos = path.tqfindRev('/'); const TQString fileName = path.mid(pos+1); kdDebug() << "Found process " << oldPid << " running. It's: " << fileName << endl; first_instance = fileName != "kmail" && fileName != "kontact"; @@ -199,17 +199,17 @@ void lockOrDie() { "this machine. Running %2 more than once " "can cause the loss of mail. You should not start %1 " "unless you are sure that it is not already running.") - .arg( programName, programName ); + .tqarg( programName, programName ); // TQString::arg( st ) only replaces the first occurrence of %1 // with st while TQString::arg( s1, s2 ) replacess all occurrences // of %1 with s1 and all occurrences of %2 with s2. So don't - // even think about changing the above to .arg( programName ). + // even think about changing the above to .tqarg( programName ). else msg = i18n("%1 seems to be running on another display on this " "machine. Running %1 and %2 at the same " "time can cause the loss of mail. You should not start %2 " "unless you are sure that %1 is not running.") - .arg( oldProgramName, programName ); + .tqarg( oldProgramName, programName ); } else { if ( oldAppName == appName ) @@ -217,19 +217,19 @@ void lockOrDie() { "than once can cause the loss of mail. You should not " "start %1 on this computer unless you are sure that it is " "not already running on %2.") - .arg( programName, oldHostName ); + .tqarg( programName, oldHostName ); else msg = i18n("%1 seems to be running on %3. Running %1 and %2 at the " "same time can cause the loss of mail. You should not " "start %2 on this computer unless you are sure that %1 is " "not running on %3.") - .arg( oldProgramName, programName, oldHostName ); + .tqarg( oldProgramName, programName, oldHostName ); } KCursorSaver idle( KBusyPtr::idle() ); if ( KMessageBox::No == KMessageBox::warningYesNo( 0, msg, TQString(), - i18n("Start %1").arg( programName ), + i18n("Start %1").tqarg( programName ), i18n("Exit") ) ) { exit(1); } diff --git a/kmail/kmsystemtray.cpp b/kmail/kmsystemtray.cpp index 3a5840a85..a066fc86e 100644 --- a/kmail/kmsystemtray.cpp +++ b/kmail/kmsystemtray.cpp @@ -133,7 +133,7 @@ void KMSystemTray::buildPopupMenu() action->plug( mPopupMenu ); mPopupMenu->insertSeparator(); - KMainWindow *mainWin = ::qt_cast<KMainWindow*>(kmkernel->getKMMainWidget()->tqtopLevelWidget()); + KMainWindow *mainWin = ::tqqt_cast<KMainWindow*>(kmkernel->getKMMainWidget()->tqtopLevelWidget()); mPopupMenu->insertItem( SmallIcon("exit"), i18n("&Quit"), this, TQT_SLOT(maybeQuit()) ); } @@ -305,7 +305,7 @@ void KMSystemTray::foldersChanged() void KMSystemTray::mousePressEvent(TQMouseEvent *e) { // switch to kmail on left mouse button - if( e->button() == LeftButton ) + if( e->button() == Qt::LeftButton ) { if( mParentVisible && mainWindowIsOnCurrentDesktop() ) hideKMail(); @@ -314,7 +314,7 @@ void KMSystemTray::mousePressEvent(TQMouseEvent *e) } // open popup menu on right mouse button - if( e->button() == RightButton ) + if( e->button() == Qt::RightButton ) { mPopupFolders.clear(); mPopupFolders.reserve( mFoldersWithUnread.count() ); diff --git a/kmail/kmtransport.cpp b/kmail/kmtransport.cpp index 335025b7d..46ed0efc9 100644 --- a/kmail/kmtransport.cpp +++ b/kmail/kmtransport.cpp @@ -145,7 +145,7 @@ void KMTransportInfo::writeConfig(int id) "but should not be considered secure from decryption efforts " "if access to the configuration file is obtained.\n" "Do you want to store the password for account '%1' in the " - "configuration file?").arg( name ), + "configuration file?").tqarg( name ), i18n("KWallet Not Available"), KGuiItem( i18n("Store Password") ), KGuiItem( i18n("Do Not Store Password") ) ) @@ -401,7 +401,7 @@ void KMTransportDialog::makeSmtpPage() label = new TQLabel( i18n("&Port:"), page1 ); grid->addWidget( label, 4, 0 ); mSmtp.portEdit = new KLineEdit( page1 ); - mSmtp.portEdit->setValidator( new TQIntValidator(this) ); + mSmtp.portEdit->setValidator( new TQIntValidator(TQT_TQOBJECT(this)) ); TQWhatsThis::add(mSmtp.portEdit, i18n("The port number that the SMTP server " "is listening on. The default port is 25.")); @@ -498,7 +498,7 @@ void KMTransportDialog::makeSmtpPage() TQWidget *page2 = new TQWidget( tabWidget ); tabWidget->addTab( page2, i18n("S&ecurity") ); TQVBoxLayout *vlay = new TQVBoxLayout( page2, spacingHint() ); - mSmtp.encryptionGroup = new TQButtonGroup( 1, TQt::Horizontal, + mSmtp.encryptionGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Encryption"), page2 ); mSmtp.encryptionNone = new TQRadioButton( i18n("&None"), mSmtp.encryptionGroup ); @@ -510,7 +510,7 @@ void KMTransportDialog::makeSmtpPage() TQT_SLOT(slotSmtpEncryptionChanged(int))); vlay->addWidget( mSmtp.encryptionGroup ); - mSmtp.authGroup = new TQButtonGroup( 1, TQt::Horizontal, + mSmtp.authGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Authentication Method"), page2 ); mSmtp.authLogin = new TQRadioButton( i18n("Please translate this " "authentication method only if you have a good reason", "&LOGIN"), @@ -756,7 +756,7 @@ void KMTransportDialog::slotSmtpCapabilities( const TQStringList & capaNormal, << authNone << ", " << authSSL << ", " << authTLS << " )" << endl; mSmtp.encryptionNone->setEnabled( !capaNormal.isEmpty() ); mSmtp.encryptionSSL->setEnabled( !capaSSL.isEmpty() ); - mSmtp.encryptionTLS->setEnabled( capaNormal.findIndex("STARTTLS") != -1 ); + mSmtp.encryptionTLS->setEnabled( capaNormal.tqfindIndex("STARTTLS") != -1 ); if ( authNone.isEmpty() && authSSL.isEmpty() && authTLS.isEmpty() ) { // slave doesn't seem to support "* AUTH METHODS" metadata (or server can't do AUTH) mAuthNone = authMethodsFromStringList( capaNormal ); diff --git a/kmail/listjob.cpp b/kmail/listjob.cpp index 3c1e1304a..e126f3e56 100644 --- a/kmail/listjob.cpp +++ b/kmail/listjob.cpp @@ -174,7 +174,7 @@ void ListJob::slotListResult( KIO::Job* job ) if ( job->error() ) { mAccount->handleJobError( job, - i18n( "Error while listing folder %1: " ).arg((*it).path), + i18n( "Error while listing folder %1: " ).tqarg((*it).path), true ); } else { @@ -230,7 +230,7 @@ void ListJob::slotListEntries( KIO::Job* job, const KIO::UDSEntryList& uds ) // Some servers send _lots_ of duplicates // This check is too slow for huge lists if ( mSubfolderPaths.count() > 100 || - mSubfolderPaths.findIndex(url.path()) == -1 ) + mSubfolderPaths.tqfindIndex(url.path()) == -1 ) { mSubfolderNames.append( name ); mSubfolderPaths.append( url.path() ); diff --git a/kmail/mailinglistpropertiesdialog.cpp b/kmail/mailinglistpropertiesdialog.cpp index d05d64135..2fb6203db 100644 --- a/kmail/mailinglistpropertiesdialog.cpp +++ b/kmail/mailinglistpropertiesdialog.cpp @@ -59,13 +59,13 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* "topLayout" ); TQGroupBox *mlGroup = new TQGroupBox( i18n("Associated Mailing List" ), this ); - mlGroup->setColumnLayout( 0, TQt::Vertical ); + mlGroup->setColumnLayout( 0, Qt::Vertical ); TQGridLayout *groupLayout = new TQGridLayout( mlGroup->tqlayout(), 6, 3, spacingHint() ); topLayout->addWidget( mlGroup ); setMainWidget( mlGroup ); mHoldsMailingList = new TQCheckBox( i18n("&Folder holds a mailing list"), mlGroup ); - TQObject::connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), + connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotHoldsML(bool)) ); groupLayout->addMultiCellWidget( mHoldsMailingList, 0, 0, 0, 2 ); @@ -73,14 +73,14 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* mDetectButton = new TQPushButton( i18n("Detect Automatically"), mlGroup ); mDetectButton->setEnabled( false ); - TQObject::connect( mDetectButton, TQT_SIGNAL(pressed()), TQT_SLOT(slotDetectMailingList()) ); + connect( mDetectButton, TQT_SIGNAL(pressed()), TQT_SLOT(slotDetectMailingList()) ); groupLayout->addWidget( mDetectButton, 2, 1 ); groupLayout->addItem( new TQSpacerItem( 0, 10 ), 3, 0 ); label = new TQLabel( i18n("Mailing list description:"), mlGroup ); label->setEnabled( false ); - TQObject::connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), + connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), label, TQT_SLOT(setEnabled(bool)) ); groupLayout->addWidget( label, 4, 0 ); mMLId = new TQLabel( label, "", mlGroup ); @@ -90,7 +90,7 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* //FIXME: add TQWhatsThis label = new TQLabel( i18n("Preferred handler:"), mlGroup ); label->setEnabled(false); - TQObject::connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), + connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), label, TQT_SLOT(setEnabled(bool)) ); groupLayout->addWidget( label, 5, 0 ); mMLHandlerCombo = new TQComboBox( mlGroup ); @@ -98,13 +98,13 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* mMLHandlerCombo->insertItem( i18n("Browser"), MailingList::Browser ); mMLHandlerCombo->setEnabled( false ); groupLayout->addMultiCellWidget( mMLHandlerCombo, 5, 5, 1, 2 ); - TQObject::connect( mMLHandlerCombo, TQT_SIGNAL(activated(int)), + connect( mMLHandlerCombo, TQT_SIGNAL(activated(int)), TQT_SLOT(slotMLHandling(int)) ); label->setBuddy( mMLHandlerCombo ); label = new TQLabel( i18n("&Address type:"), mlGroup ); label->setEnabled(false); - TQObject::connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), + connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), label, TQT_SLOT(setEnabled(bool)) ); groupLayout->addWidget( label, 6, 0 ); mAddressCombo = new TQComboBox( mlGroup ); @@ -119,9 +119,9 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* handleButton->setEnabled( false ); if( mFolder) { - TQObject::connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), + connect( mHoldsMailingList, TQT_SIGNAL(toggled(bool)), handleButton, TQT_SLOT(setEnabled(bool)) ); - TQObject::connect( handleButton, TQT_SIGNAL(clicked()), + connect( handleButton, TQT_SIGNAL(clicked()), TQT_SLOT(slotInvokeHandler()) ); } groupLayout->addWidget( handleButton, 6, 2 ); @@ -140,7 +140,7 @@ MailingListFolderPropertiesDialog::MailingListFolderPropertiesDialog( TQWidget* << i18n( "List Archives" ) << i18n( "List Help" ); mAddressCombo->insertStringList( el ); - TQObject::connect( mAddressCombo, TQT_SIGNAL(activated(int)), + connect( mAddressCombo, TQT_SIGNAL(activated(int)), TQT_SLOT(slotAddressChanged(int)) ); load(); diff --git a/kmail/mailserviceimpl.h b/kmail/mailserviceimpl.h index 0fbb415a9..9e25a4278 100644 --- a/kmail/mailserviceimpl.h +++ b/kmail/mailserviceimpl.h @@ -30,13 +30,12 @@ #ifndef MAILSERVICEIMPL_H #define MAILSERVICEIMPL_H +#include <tqcstring.h> + #include "interfaces/MailTransportServiceIface.h" class TQString; class KURL; -template <typename T> class TQMemArray; -typedef TQMemArray<char> TQByteArray; - namespace KMail { diff --git a/kmail/managesievescriptsdialog.cpp b/kmail/managesievescriptsdialog.cpp index b3018fea8..e306c7772 100644 --- a/kmail/managesievescriptsdialog.cpp +++ b/kmail/managesievescriptsdialog.cpp @@ -253,7 +253,7 @@ void KMail::ManageSieveScriptsDialog::slotDeleteScript() { u.setFileName( mContextMenuItem->text( 0 ) ); - if ( KMessageBox::warningContinueCancel( this, i18n( "Really delete script \"%1\" from the server?" ).arg( u.fileName() ), + if ( KMessageBox::warningContinueCancel( this, i18n( "Really delete script \"%1\" from the server?" ).tqarg( u.fileName() ), i18n( "Delete Sieve Script Confirmation" ), KStdGuiItem::del() ) != KMessageBox::Continue ) diff --git a/kmail/messagecomposer.cpp b/kmail/messagecomposer.cpp index 897b03e67..c7c4af6ed 100644 --- a/kmail/messagecomposer.cpp +++ b/kmail/messagecomposer.cpp @@ -599,7 +599,7 @@ void MessageComposer::chiasmusEncryptAllAttachments() { for ( TQValueVector<Attachment>::iterator it = mAttachments.begin(), end = mAttachments.end() ; it != end ; ++it ) { KMMessagePart * part = it->part; const TQString filename = part->fileName(); - if ( filename.endsWith( ".xia", false ) ) + if ( filename.tqendsWith( ".xia", false ) ) continue; // already encrypted const TQByteArray body = part->bodyDecodedBinary(); TQByteArray resultData; @@ -1855,7 +1855,7 @@ void MessageComposer::addBodyAndAttachments( KMMessage* msg, (void)msg->asDwMessage(); // Assemble the message. One gets a completely empty message otherwise :/ } } else { // no attachments in the final message - if( ourFineBodyPart.originalContentTypeStr() ) { + if( !ourFineBodyPart.originalContentTypeStr().isNull() ) { msg->headers().ContentType().FromString( ourFineBodyPart.originalContentTypeStr() ); msg->headers().ContentType().Parse(); kdDebug(5006) << "MessageComposer::addBodyAndAttachments() : set top level Content-Type from originalContentTypeStr()=" << ourFineBodyPart.originalContentTypeStr() << endl; @@ -1952,7 +1952,7 @@ bool MessageComposer::processStructuringInfo( const TQString bugURL, //kdDebug(5006) << "processStructuringInfo: mainHeader=" << mainHeader << endl; DwString mainDwStr; - mainDwStr = mainHeader + "\n\n"; + mainDwStr = TQString(mainHeader + "\n\n"); DwBodyPart mainDwPa( mainDwStr, 0 ); mainDwPa.Parse(); KMMessage::bodyPart( &mainDwPa, &resultingPart ); @@ -2038,7 +2038,7 @@ bool MessageComposer::processStructuringInfo( const TQString bugURL, i18n( "<qt><p>Error: The backend did not return " "any encoded data.</p>" "<p>Please report this bug:<br>%2</p></qt>" ) - .arg( bugURL ) ); + .tqarg( bugURL ) ); bOk = false; } resultingPart.setBodyEncodedBinary( resultingBody ); diff --git a/kmail/networkaccount.cpp b/kmail/networkaccount.cpp index b0d56a509..b400b52a6 100644 --- a/kmail/networkaccount.cpp +++ b/kmail/networkaccount.cpp @@ -224,7 +224,7 @@ namespace KMail { "but should not be considered secure from decryption efforts " "if access to the configuration file is obtained.\n" "Do you want to store the password for account '%1' in the " - "configuration file?").arg( name() ), + "configuration file?").tqarg( name() ), i18n("KWallet Not Available"), KGuiItem( i18n("Store Password") ), KGuiItem( i18n("Do Not Store Password") ) ) diff --git a/kmail/newfolderdialog.cpp b/kmail/newfolderdialog.cpp index 6d1de7cda..d1e7de22f 100644 --- a/kmail/newfolderdialog.cpp +++ b/kmail/newfolderdialog.cpp @@ -66,7 +66,7 @@ NewFolderDialog::NewFolderDialog( TQWidget* tqparent, KMFolder *folder ) { setWFlags( getWFlags() | WDestructiveClose ); if ( mFolder ) { - setCaption( i18n("New Subfolder of %1").arg( mFolder->prettyURL() ) ); + setCaption( i18n("New Subfolder of %1").tqarg( mFolder->prettyURL() ) ); } TQWidget* privateLayoutWidget = new TQWidget( this, "mTopLevelLayout" ); privateLayoutWidget->setGeometry( TQRect( 10, 10, 260, 80 ) ); @@ -213,14 +213,14 @@ void NewFolderDialog::slotOk() && ( selectedFolderDir == mFolder->tqparent() ) && ( mFolder->storage()->name() == fldName ) ) ) ) { - const TQString message = i18n( "<qt>Failed to create folder <b>%1</b>, folder already exists.</qt>" ).arg(fldName); + const TQString message = i18n( "<qt>Failed to create folder <b>%1</b>, folder already exists.</qt>" ).tqarg(fldName); KMessageBox::error( this, message ); return; } /* Ok, obvious errors caught, let's try creating it for real. */ const TQString message = i18n( "<qt>Failed to create folder <b>%1</b>." - "</qt> " ).arg(fldName); + "</qt> " ).tqarg(fldName); TQString namespaceName; if ( mNamespacesComboBox ) { diff --git a/kmail/objecttreeparser.cpp b/kmail/objecttreeparser.cpp index 80c182d98..2cb44ab9b 100644 --- a/kmail/objecttreeparser.cpp +++ b/kmail/objecttreeparser.cpp @@ -272,7 +272,7 @@ namespace KMail { ProcessResult processResult; if ( mReader ) { - htmlWriter()->queue( TQString::tqfromLatin1("<a name=\"att%1\"/>").arg( node->nodeId() ) ); + htmlWriter()->queue( TQString::tqfromLatin1("<a name=\"att%1\"/>").tqarg( node->nodeId() ) ); } if ( const Interface::BodyPartFormatter * formatter @@ -686,11 +686,11 @@ namespace KMail { switch ( cryptPlugError ) { case NOT_INITIALIZED: errorMsg = i18n( "Crypto plug-in \"%1\" is not initialized." ) - .arg( cryptPlugLibName ); + .tqarg( cryptPlugLibName ); break; case CANT_VERIFY_SIGNATURES: errorMsg = i18n( "Crypto plug-in \"%1\" cannot verify signatures." ) - .arg( cryptPlugLibName ); + .tqarg( cryptPlugLibName ); break; case NO_PLUGIN: if ( cryptPlugDisplayName.isEmpty() ) @@ -698,14 +698,14 @@ namespace KMail { else errorMsg = i18n( "%1 is either 'OpenPGP' or 'S/MIME'", "No %1 plug-in was found." ) - .arg( cryptPlugDisplayName ); + .tqarg( cryptPlugDisplayName ); break; } messagePart.errorText = i18n( "The message is signed, but the " "validity of the signature cannot be " "verified.<br />" "Reason: %1" ) - .arg( errorMsg ); + .tqarg( errorMsg ); } if ( mReader ) @@ -887,9 +887,9 @@ bool ObjectTreeParser::okDecryptMIME( partNode& data, + "</div>"; if ( !passphraseError ) aErrorText = i18n("Crypto plug-in \"%1\" could not decrypt the data.") - .arg( cryptPlugLibName ) + .tqarg( cryptPlugLibName ) + "<br />" - + i18n("Error: %1").arg( aErrorText ); + + i18n("Error: %1").tqarg( aErrorText ); } } } @@ -901,11 +901,11 @@ bool ObjectTreeParser::okDecryptMIME( partNode& data, switch ( cryptPlugError ) { case NOT_INITIALIZED: aErrorText = i18n( "Crypto plug-in \"%1\" is not initialized." ) - .arg( cryptPlugLibName ); + .tqarg( cryptPlugLibName ); break; case CANT_DECRYPT: aErrorText = i18n( "Crypto plug-in \"%1\" cannot decrypt messages." ) - .arg( cryptPlugLibName ); + .tqarg( cryptPlugLibName ); break; case NO_PLUGIN: aErrorText = i18n( "No appropriate crypto plug-in was found." ); @@ -944,7 +944,7 @@ bool ObjectTreeParser::okDecryptMIME( partNode& data, while ( httpPos >= 0 ) { // look backwards for "href" if ( httpPos > 5 ) { - int hrefPos = str.findRev( "href", httpPos - 5, true ); + int hrefPos = str.tqfindRev( "href", httpPos - 5, true ); // if no 'href' is found or the distance between 'href' and '"http[s]:' // is larger than 7 (7 is the distance in 'href = "http[s]:') then // we assume that we have found an external reference @@ -979,12 +979,12 @@ bool ObjectTreeParser::okDecryptMIME( partNode& data, // We must fo this, or else we will see only 1st inlined html // attachment. It is IMHO enough to search only for </BODY> and // put \0 there. - int i = cstr.findRev("</body>", -1, false); //case insensitive + int i = cstr.tqfindRev("</body>", -1, false); //case insensitive if ( 0 <= i ) cstr.truncate(i); else // just in case - search for </html> { - i = cstr.findRev("</html>", -1, false); //case insensitive + i = cstr.tqfindRev("</html>", -1, false); //case insensitive if ( 0 <= i ) cstr.truncate(i); } // ---Sven's strip </BODY> and </HTML> from end of attachment end- @@ -1047,21 +1047,21 @@ namespace KMail { const TQCString delimZ2("--__--__--\n\n_____________"); const TQCString delimZ1("--__--__--\r\n\r\n_____________"); TQCString partStr, digestHeaderStr; - int thisDelim = cstr.tqfind(delim1, 0, false); + int thisDelim = cstr.tqfind(TQString(delim1), 0, false); if ( thisDelim == -1 ) - thisDelim = cstr.tqfind(delim2, 0, false); + thisDelim = cstr.tqfind(TQString(delim2), 0, false); if ( thisDelim == -1 ) { kdDebug(5006) << " Sorry: Old style Mailman message but no delimiter found." << endl; return false; } - int nextDelim = cstr.tqfind(delim1, thisDelim+1, false); + int nextDelim = cstr.tqfind(TQString(delim1), thisDelim+1, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delim2, thisDelim+1, false); + nextDelim = cstr.tqfind(TQString(delim2), thisDelim+1, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delimZ1, thisDelim+1, false); + nextDelim = cstr.tqfind(TQString(delimZ1), thisDelim+1, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delimZ2, thisDelim+1, false); + nextDelim = cstr.tqfind(TQString(delimZ2), thisDelim+1, false); if ( nextDelim < 0) return false; @@ -1101,7 +1101,7 @@ namespace KMail { partStr += cstr.mid( thisDelim, nextDelim-thisDelim ); TQCString subject("embedded message"); TQCString subSearch("\nSubject:"); - int subPos = partStr.tqfind(subSearch, 0, false); + int subPos = partStr.tqfind(TQString(subSearch), 0, false); if ( -1 < subPos ){ subject = partStr.mid(subPos+subSearch.length()); thisEoL = subject.tqfind('\n'); @@ -1114,13 +1114,13 @@ namespace KMail { subject, true ); //mReader->queueHtml("<br><hr><br>"); thisDelim = nextDelim+1; - nextDelim = cstr.tqfind(delim1, thisDelim, false); + nextDelim = cstr.tqfind(TQString(delim1), thisDelim, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delim2, thisDelim, false); + nextDelim = cstr.tqfind(TQString(delim2), thisDelim, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delimZ1, thisDelim, false); + nextDelim = cstr.tqfind(TQString(delimZ1), thisDelim, false); if ( -1 == nextDelim ) - nextDelim = cstr.tqfind(delimZ2, thisDelim, false); + nextDelim = cstr.tqfind(TQString(delimZ2), thisDelim, false); } // reset curent node's Content-Type curNode->setType( DwMime::kTypeText ); @@ -1656,7 +1656,7 @@ namespace KMail { const GpgME::ImportResult res = import->exec( certData ); if ( res.error() ) { htmlWriter()->queue( i18n( "Sorry, certificate could not be imported.<br>" - "Reason: %1").arg( TQString::fromLocal8Bit( res.error().asString() ) ) ); + "Reason: %1").tqarg( TQString::fromLocal8Bit( res.error().asString() ) ) ); return true; } @@ -1696,14 +1696,14 @@ namespace KMail { for ( std::vector<GpgME::Import>::const_iterator it = imports.begin() ; it != imports.end() ; ++it ) { if ( (*it).error() ) htmlWriter()->queue( i18n( "Failed: %1 (%2)" ) - .arg( (*it).fingerprint(), + .tqarg( (*it).fingerprint(), TQString::fromLocal8Bit( (*it).error().asString() ) ) ); else if ( (*it).status() & ~GpgME::Import::ContainedSecretKey ) { if ( (*it).status() & GpgME::Import::ContainedSecretKey ) { - htmlWriter()->queue( i18n( "New or changed: %1 (secret key available)" ).arg( (*it).fingerprint() ) ); + htmlWriter()->queue( i18n( "New or changed: %1 (secret key available)" ).tqarg( (*it).fingerprint() ) ); } else { - htmlWriter()->queue( i18n( "New or changed: %1" ).arg( (*it).fingerprint() ) ); + htmlWriter()->queue( i18n( "New or changed: %1" ).tqarg( (*it).fingerprint() ) ); } } htmlWriter()->queue( "<br>" ); @@ -2054,7 +2054,7 @@ bool ObjectTreeParser::processApplicationMsTnefSubtype( partNode *node, ProcessR TQString fileName = mReader->writeMessagePartToTempFile( msgPart, partNum ); - TQString href = TQString( "attachment:%1?place=body" ).arg( partNum ); + TQString href = TQString( "attachment:%1?place=body" ).tqarg( partNum ); TQString iconName; if( inlineImage ) @@ -2280,7 +2280,7 @@ static TQString writeSimpleSigstatHeader( const PartMetaData &block ) if ( addr.isEmpty() ) { html += i18n( "Signature is valid." ); } else { - html += i18n( "Signed by <a href=\"mailto:%1\">%2</a>." ).arg( addr, name ); + html += i18n( "Signed by <a href=\"mailto:%1\">%2</a>." ).tqarg( addr, name ); } } else { // should not happen @@ -2307,7 +2307,7 @@ static TQString makeShowAuditLogLink( const GpgME::Error & err, const TQString & //kdDebug(5006) << "makeShowAuditLogLink: not showing link (not available)" << endl; return i18n("No Audit Log available"); } else { - return i18n("Error Retrieving Audit Log: %1").arg( TQString::fromLocal8Bit( err.asString() ) ); + return i18n("Error Retrieving Audit Log: %1").tqarg( TQString::fromLocal8Bit( err.asString() ) ); } } @@ -2371,7 +2371,7 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, else { htmlStr += i18n("Encrypted message (decryption not possible)"); if( !block.errorText.isEmpty() ) - htmlStr += "<br />" + i18n("Reason: %1").arg( block.errorText ); + htmlStr += "<br />" + i18n("Reason: %1").tqarg( block.errorText ); } htmlStr += "</td></tr><tr class=\"encrB\"><td>"; } @@ -2428,13 +2428,13 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, if( isSMIME ) startKeyHREF = TQString("<a href=\"kmail:showCertificate#%1 ### %2 ### %3\">") - .arg( cryptProto->displayName(), + .tqarg( cryptProto->displayName(), cryptProto->name(), block.keyId ); TQString keyWithWithoutURL = isSMIME ? TQString("%1%2</a>") - .arg( startKeyHREF, + .tqarg( startKeyHREF, cannotCheckSignature ? i18n("[Details]") : ("0x" + block.keyId) ) : "0x" + TQString::fromUtf8( block.keyId ); @@ -2486,7 +2486,7 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, i18n("Warning:") + "</u> " + i18n("Sender's mail address is not stored " - "in the %1 used for signing.").arg(certificate) + + "in the %1 used for signing.").tqarg(certificate) + "<br />" + i18n("sender: ") + msgFrom + @@ -2512,7 +2512,7 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, "</u> " + i18n("No mail address is stored in the %1 used for signing, " "so we cannot compare it to the sender's address %2.") - .arg(certificate,msgFrom); + .tqarg(certificate,msgFrom); } if( !greenCaseWarning.isEmpty() ) { if( !statusStr.isEmpty() ) @@ -2535,7 +2535,7 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, if( cannotCheckSignature ) { htmlStr += i18n( "Not enough information to check " "signature. %1" ) - .arg( keyWithWithoutURL ); + .tqarg( keyWithWithoutURL ); } else { @@ -2553,26 +2553,26 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, htmlStr += i18n( "Message was signed with unknown key." ); else htmlStr += i18n( "Message was signed by %1." ) - .arg( signer ); + .tqarg( signer ); } else { TQDateTime created = block.creationTime; if( created.isValid() ) { if( signer.isEmpty() ) { if( onlyShowKeyURL ) htmlStr += i18n( "Message was signed with key %1." ) - .arg( keyWithWithoutURL ); + .tqarg( keyWithWithoutURL ); else htmlStr += i18n( "Message was signed on %1 with key %2." ) - .arg( KGlobal::locale()->formatDateTime( created ), + .tqarg( KGlobal::locale()->formatDateTime( created ), keyWithWithoutURL ); } else { if( onlyShowKeyURL ) htmlStr += i18n( "Message was signed with key %1." ) - .arg( keyWithWithoutURL ); + .tqarg( keyWithWithoutURL ); else htmlStr += i18n( "Message was signed by %3 on %1 with key %2" ) - .arg( KGlobal::locale()->formatDateTime( created ), + .tqarg( KGlobal::locale()->formatDateTime( created ), keyWithWithoutURL, signer ); } @@ -2580,10 +2580,10 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, else { if( signer.isEmpty() || onlyShowKeyURL ) htmlStr += i18n( "Message was signed with key %1." ) - .arg( keyWithWithoutURL ); + .tqarg( keyWithWithoutURL ); else htmlStr += i18n( "Message was signed by %2 with key %1." ) - .arg( keyWithWithoutURL, + .tqarg( keyWithWithoutURL, signer ); } } @@ -2621,11 +2621,11 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, TQDateTime created = block.creationTime; if ( created.isValid() ) htmlStr += i18n( "Message was signed on %1 with unknown key %2." ) - .arg( KGlobal::locale()->formatDateTime( created ), + .tqarg( KGlobal::locale()->formatDateTime( created ), keyWithWithoutURL ); else htmlStr += i18n( "Message was signed with unknown key %1." ) - .arg( keyWithWithoutURL ); + .tqarg( keyWithWithoutURL ); } else htmlStr += i18n( "Message was signed with unknown key." ); @@ -2663,10 +2663,10 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, simpleHtmlStr += writeSimpleSigstatHeader( block ); if( !block.keyId.isEmpty() ) htmlStr += i18n( "Message was signed by %2 (Key ID: %1)." ) - .arg( keyWithWithoutURL, + .tqarg( keyWithWithoutURL, signer ); else - htmlStr += i18n( "Message was signed by %1." ).arg( signer ); + htmlStr += i18n( "Message was signed by %1." ).tqarg( signer ); htmlStr += "<br />"; switch( block.keyTrust ) @@ -2707,10 +2707,10 @@ TQString ObjectTreeParser::writeSigstatHeader( PartMetaData & block, simpleHtmlStr += writeSimpleSigstatHeader( block ); if( !block.keyId.isEmpty() ) htmlStr += i18n( "Message was signed by %2 (Key ID: %1)." ) - .arg( keyWithWithoutURL, + .tqarg( keyWithWithoutURL, signer ); else - htmlStr += i18n( "Message was signed by %1." ).arg( signer ); + htmlStr += i18n( "Message was signed by %1." ).tqarg( signer ); htmlStr += "<br />"; htmlStr += i18n("Warning: The signature is bad."); frame = "</td></tr>" @@ -2763,7 +2763,7 @@ void ObjectTreeParser::writeAttachmentMarkHeader( partNode *node ) if ( !mReader ) return; - htmlWriter()->queue( TQString( "<div id=\"attachmentDiv%1\">\n" ).arg( node->nodeId() ) ); + htmlWriter()->queue( TQString( "<div id=\"attachmentDiv%1\">\n" ).tqarg( node->nodeId() ) ); } //----------------------------------------------------------------------------- @@ -2798,7 +2798,7 @@ void ObjectTreeParser::writeBodyStr( const TQCString& aStr, const TQTextCodec *a bool isPgpMessage = false; // true if the message contains at least one // PGP MESSAGE or one PGP SIGNED MESSAGE block TQString dir = ( TQApplication::reverseLayout() ? "rtl" : "ltr" ); - TQString headerStr = TQString("<div dir=\"%1\">").arg(dir); + TQString headerStr = TQString("<div dir=\"%1\">").tqarg(dir); inlineSignatureState = KMMsgNotSigned; inlineEncryptionState = KMMsgNotEncrypted; @@ -2970,7 +2970,7 @@ TQString ObjectTreeParser::quotedHTML( const TQString& s, bool decorate ) const unsigned int length = s.length(); // skip leading empty lines - for ( pos = 0; pos < length && s[pos] <= ' '; pos++ ) { ; } + for ( pos = 0; pos < length && s.tqat(pos) <= TQChar(' '); pos++ ) { ; } while (pos > 0 && (s[pos-1] == ' ' || s[pos-1] == '\t')) pos--; beg = pos; @@ -3051,8 +3051,8 @@ TQString ObjectTreeParser::quotedHTML( const TQString& s, bool decorate ) htmlStr += "<div class=\"quotelevelmark\" >" ; htmlStr += TQString( "<a href=\"kmail:levelquote?%1 \">" "<img src=\"%2\" alt=\"\" title=\"\"/></a>" ) - .arg(-1) - .arg( mExpandIcon ); + .tqarg(-1) + .tqarg( mExpandIcon ); htmlStr += "</div><br/>"; htmlStr += quoteEnd; } @@ -3060,8 +3060,8 @@ TQString ObjectTreeParser::quotedHTML( const TQString& s, bool decorate ) htmlStr += "<div class=\"quotelevelmark\" >" ; htmlStr += TQString( "<a href=\"kmail:levelquote?%1 \">" "<img src=\"%2\" alt=\"\" title=\"\"/></a>" ) - .arg(actQuoteLevel) - .arg( mCollapseIcon); + .tqarg(actQuoteLevel) + .tqarg( mCollapseIcon); htmlStr += "</div>"; if ( actQuoteLevel < 3 ) htmlStr += quoteFontTag[actQuoteLevel]; @@ -3085,7 +3085,7 @@ TQString ObjectTreeParser::quotedHTML( const TQString& s, bool decorate ) // ignore ^M DOS linebreaks if( !line.tqreplace('\015', "").isEmpty() ) { - htmlStr +=TQString( "<div dir=\"%1\">" ).arg( line.isRightToLeft() ? "rtl":"ltr" ); + htmlStr +=TQString( "<div dir=\"%1\">" ).tqarg( line.isRightToLeft() ? "rtl":"ltr" ); htmlStr += LinkLocator::convertToHtml( line, convertFlags ); htmlStr += TQString( "</div>" ); } diff --git a/kmail/partNode.cpp b/kmail/partNode.cpp index 96bb32c59..de5e2d89e 100644 --- a/kmail/partNode.cpp +++ b/kmail/partNode.cpp @@ -2,7 +2,7 @@ partNode.cpp A node in a MIME tree. This file is part of KMail, the KDE mail client. - Copyright (c) 2002 Klarälvdalens Datakonsult AB + Copyright (c) 2002 Klar�lvdalens Datakonsult AB KMail is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2, as @@ -167,7 +167,7 @@ partNode::~partNode() { #ifndef NDEBUG void partNode::dump( int chars ) const { - kdDebug(5006) << nodeId() << " " << TQString().fill( ' ', chars ) << "+ " + kdDebug(5006) << nodeId() << " " << TQString(TQString().fill( ' ', chars )) << "+ " << typeString() << '/' << subTypeString() << " embedded:" << mDisplayedEmbedded << " address:" << this << endl; if ( mChild ) @@ -693,7 +693,7 @@ KMail::Interface::BodyPartMemento * partNode::internalBodyPartMemento( const TQC { assert( !reader() ); - const std::map<TQCString,KMail::Interface::BodyPartMemento*>::const_iterator it = mBodyPartMementoMap.tqfind( which.lower() ); + const std::map<TQCString,KMail::Interface::BodyPartMemento*>::const_iterator it = mBodyPartMementoMap.find( which.lower() ); return it != mBodyPartMementoMap.end() ? it->second : 0 ; } @@ -746,7 +746,7 @@ void partNode::setDisplayedHidden( bool displayedHidden ) TQString partNode::asHREF( const TQString &place ) const { - return TQString( "attachment:%1?place=%2" ).arg( nodeId() ).arg( place ); + return TQString( "attachment:%1?place=%2" ).tqarg( nodeId() ).tqarg( place ); } partNode::AttachmentDisplayInfo partNode::attachmentDisplayInfo() const diff --git a/kmail/partnodebodypart.cpp b/kmail/partnodebodypart.cpp index 45ce28620..d7e6c95d0 100644 --- a/kmail/partnodebodypart.cpp +++ b/kmail/partnodebodypart.cpp @@ -49,8 +49,8 @@ TQString KMail::PartNodeBodyPart::makeLink( const TQString & path ) const { static const int utf8 = 106; // FIXME: use a PRNG for the first arg, instead of a serial number return TQString( "x-kmail:/bodypart/%1/%2/%3" ) - .arg( serial++ ).arg( mPartNode.nodeId() ) - .arg( KURL::encode_string_no_slash( path, utf8 ) ); + .tqarg( serial++ ).tqarg( mPartNode.nodeId() ) + .tqarg( KURL::encode_string_no_slash( path, utf8 ) ); } TQString KMail::PartNodeBodyPart::asText() const { diff --git a/kmail/popaccount.cpp b/kmail/popaccount.cpp index b2f55528f..99befb43b 100644 --- a/kmail/popaccount.cpp +++ b/kmail/popaccount.cpp @@ -167,7 +167,7 @@ void PopAccount::processNewMail(bool _interactive) } TQString seenUidList = locateLocal( "data", "kmail/" + mLogin + ":" + "@" + - mHost + ":" + TQString("%1").arg(mPort) ); + mHost + ":" + TQString("%1").tqarg(mPort) ); KConfig config( seenUidList ); TQStringList uidsOfSeenMsgs = config.readListEntry( "seenUidList" ); TQValueList<int> timeOfSeenMsgs = config.readIntListEntry( "seenUidTimeList" ); @@ -370,7 +370,7 @@ void PopAccount::startJob() if (!runPrecommand(precommand())) { KMessageBox::sorry(0, - i18n("Could not execute precommand: %1").arg(precommand()), + i18n("Could not execute precommand: %1").tqarg(precommand()), i18n("KMail Error Message")); checkDone( false, CheckError ); return; @@ -401,7 +401,7 @@ void PopAccount::startJob() mMailCheckProgressItem = KPIM::ProgressManager::createProgressItem( "MailCheck" + mName, escapedName, - i18n("Preparing transmission from \"%1\"...").arg( escapedName ), + i18n("Preparing transmission from \"%1\"...").tqarg( escapedName ), true, // can be canceled useSSL() || useTLS() ); connect( mMailCheckProgressItem, TQT_SIGNAL( progressItemCanceled( KPIM::ProgressItem* ) ), @@ -496,7 +496,7 @@ void PopAccount::slotJobFinished() { "the UIDL command: this command is required to determine, in a reliable way, " "which of the mails on the server KMail has already seen before;\n" "the feature to leave the mails on the server will therefore not " - "work properly.").arg(NetworkAccount::name()) ); + "work properly.").tqarg(NetworkAccount::name()) ); // An attempt to work around buggy pop servers, these seem to be popular. mUidsOfNextSeenMsgsDict = mUidsOfSeenMsgsDict; } @@ -751,7 +751,7 @@ void PopAccount::slotJobFinished() { i18n( "Fetched 1 message from %1. Deleting messages from server...", "Fetched %n messages from %1. Deleting messages from server...", numMsgs ) - .arg( mHost ) ); + .tqarg( mHost ) ); url.setPath("/remove/" + idsOfMsgsToDelete.join(",")); kdDebug(5006) << "url: " << url.prettyURL() << endl; } else { @@ -761,7 +761,7 @@ void PopAccount::slotJobFinished() { i18n( "Fetched 1 message from %1. Terminating transmission...", "Fetched %n messages from %1. Terminating transmission...", numMsgs ) - .arg( mHost ) ); + .tqarg( mHost ) ); url.setPath(TQString("/commit")); kdDebug(5006) << "url: " << url.prettyURL() << endl; } @@ -781,7 +781,7 @@ void PopAccount::slotJobFinished() { i18n( "Fetched 1 message from %1. Terminating transmission...", "Fetched %n messages from %1. Terminating transmission...", numMsgs ) - .arg( mHost ) ); + .tqarg( mHost ) ); KURL url = getUrl(); url.setPath(TQString("/commit")); job = KIO::get( url, false, false ); @@ -841,7 +841,7 @@ void PopAccount::saveUidList() seenUidTimeList.append( mTimeOfNextSeenMsgsMap[it.currentKey()] ); } TQString seenUidList = locateLocal( "data", "kmail/" + mLogin + ":" + "@" + - mHost + ":" + TQString("%1").arg(mPort) ); + mHost + ":" + TQString("%1").tqarg(mPort) ); KConfig config( seenUidList ); config.writeEntry( "seenUidList", uidsOfNextSeenMsgs ); config.writeEntry( "seenUidTimeList", seenUidTimeList ); @@ -867,7 +867,7 @@ void PopAccount::slotGetNextMsg() curMsgStrm = new TQDataStream( curMsgData, IO_WriteOnly ); curMsgLen = nextLen; ++indexOfCurrentMsg; - kdDebug(5006) << TQString("Length of message about to get %1").arg( nextLen ) << endl; + kdDebug(5006) << TQString("Length of message about to get %1").tqarg( nextLen ) << endl; mMsgsPendingDownload.remove( next.key() ); } } @@ -904,14 +904,14 @@ void PopAccount::slotData( KIO::Job* job, const TQByteArray &data) { msg = i18n("Fetching message %1 of %2 (%3 of %4 KB) for %5@%6 " "(%7 KB remain on the server).") - .arg(indexOfCurrentMsg+1).arg(numMsgs).arg(numBytesRead/1024) - .arg(numBytesToRead/1024).arg(mLogin).arg(mHost).arg(numBytes/1024); + .tqarg(indexOfCurrentMsg+1).tqarg(numMsgs).tqarg(numBytesRead/1024) + .tqarg(numBytesToRead/1024).tqarg(mLogin).tqarg(mHost).tqarg(numBytes/1024); } else { msg = i18n("Fetching message %1 of %2 (%3 of %4 KB) for %5@%6.") - .arg(indexOfCurrentMsg+1).arg(numMsgs).arg(numBytesRead/1024) - .arg(numBytesToRead/1024).arg(mLogin).arg(mHost); + .tqarg(indexOfCurrentMsg+1).tqarg(numMsgs).tqarg(numBytesRead/1024) + .tqarg(numBytesToRead/1024).tqarg(mLogin).tqarg(mHost); } mMailCheckProgressItem->setqStatus( msg ); mMailCheckProgressItem->setProgress( diff --git a/kmail/quotajobs.h b/kmail/quotajobs.h index e53a4f18e..58b2af575 100644 --- a/kmail/quotajobs.h +++ b/kmail/quotajobs.h @@ -73,8 +73,8 @@ class QuotaInfo { if ( isValid() && !isEmpty() ) { readConfig(); int factor = static_cast<int> ( pow( 1000, mFactor ) ); - return i18n("%1 of %2 %3 used").arg( mCurrent.toInt() / factor ) - .arg( mMax.toInt() / factor ).arg( mUnits ); + return i18n("%1 of %2 %3 used").tqarg( mCurrent.toInt() / factor ) + .tqarg( mMax.toInt() / factor ).tqarg( mUnits ); } return TQString(); } diff --git a/kmail/recipientseditor.cpp b/kmail/recipientseditor.cpp index 273ba923c..5e8175dcf 100644 --- a/kmail/recipientseditor.cpp +++ b/kmail/recipientseditor.cpp @@ -915,8 +915,8 @@ void RecipientsEditor::setRecipientString( const TQString &str, if ( count++ > GlobalSettings::self()->maximumRecipients() ) { KMessageBox::sorry( this, i18n("Truncating recipients list to %1 of %2 entries.") - .arg( GlobalSettings::self()->maximumRecipients() ) - .arg( r.count() ) ); + .tqarg( GlobalSettings::self()->maximumRecipients() ) + .tqarg( r.count() ) ); break; } addRecipient( *it, type ); diff --git a/kmail/recipientspicker.cpp b/kmail/recipientspicker.cpp index 38b00d14b..0bbacbeae 100644 --- a/kmail/recipientspicker.cpp +++ b/kmail/recipientspicker.cpp @@ -103,7 +103,7 @@ void RecipientItem::setAddressee( const KABC::Addressee &a, TQImage img = a.photo().data(); if ( !img.isNull() ) - mIcon = img.smoothScale( 20, 20, TQImage::ScaleMin ); + mIcon = img.smoothScale( 20, 20, TQ_ScaleMin ); else mIcon = KGlobal::iconLoader()->loadIcon( "personal", KIcon::Small ); @@ -783,7 +783,7 @@ void RecipientsPicker::pick( Recipient::Type type ) "recipients is %1. Please adapt the selection.", "You selected %n recipients. The maximum supported number of " "recipients is %1. Please adapt the selection.", count) - .arg( GlobalSettings::self()->maximumRecipients() ) ); + .tqarg( GlobalSettings::self()->maximumRecipients() ) ); return; } diff --git a/kmail/regexplineedit.cpp b/kmail/regexplineedit.cpp index 97aef16f3..1d4d3b992 100644 --- a/kmail/regexplineedit.cpp +++ b/kmail/regexplineedit.cpp @@ -120,7 +120,7 @@ namespace KMail { void RegExpLineEdit::slotEditRegExp() { if ( !mRegExpEditDialog ) - mRegExpEditDialog = KParts::ComponentFactory::createInstanceFromQuery<TQDialog>( "KRegExpEditor/KRegExpEditor", TQString(), this ); + mRegExpEditDialog = KParts::ComponentFactory::createInstanceFromQuery<TQDialog>( "KRegExpEditor/KRegExpEditor", TQString(), TQT_TQOBJECT(this) ); KRegExpEditorInterface *iface = static_cast<KRegExpEditorInterface *>( mRegExpEditDialog->qt_cast( "KRegExpEditorInterface" ) ); diff --git a/kmail/rulewidgethandlermanager.cpp b/kmail/rulewidgethandlermanager.cpp index b3e211fa0..18a848149 100644 --- a/kmail/rulewidgethandlermanager.cpp +++ b/kmail/rulewidgethandlermanager.cpp @@ -251,7 +251,7 @@ void KMail::RuleWidgetHandlerManager::createWidgets( TQWidgetStack *functionStac for ( int i = 0; ( w = (*it)->createFunctionWidget( i, functionStack, receiver ) ); ++i ) { - if ( childCount( functionStack, w->name() ) < 2 ) { + if ( childCount( TQT_TQOBJECT(functionStack), w->name() ) < 2 ) { // there wasn't already a widget with this name, so add this widget functionStack->addWidget( w ); } @@ -266,7 +266,7 @@ void KMail::RuleWidgetHandlerManager::createWidgets( TQWidgetStack *functionStac for ( int i = 0; ( w = (*it)->createValueWidget( i, valueStack, receiver ) ); ++i ) { - if ( childCount( valueStack, w->name() ) < 2 ) { + if ( childCount( TQT_TQOBJECT(valueStack), w->name() ) < 2 ) { // there wasn't already a widget with this name, so add this widget valueStack->addWidget( w ); } @@ -360,15 +360,15 @@ namespace { TQObject* TQObject_child_const( const TQObject *tqparent, const char *objName ) { - const TQObjectList *list = tqparent->tqchildren(); - if ( !list ) + const TQObjectList list = tqparent->childrenListObject(); + if ( list.isEmpty() ) return 0; - TQObjectListIterator it( *list ); + TQObjectListIterator it( list ); TQObject *obj; while ( ( obj = it.current() ) ) { ++it; - if ( !objName || qstrcmp( objName, obj->name() ) == 0 ) + if ( !objName || tqstrcmp( objName, obj->name() ) == 0 ) break; } return obj; @@ -472,7 +472,7 @@ namespace { KMSearchRule::Function TextRuleWidgetHandler::currentFunction( const TQWidgetStack *functionStack ) const { const TQComboBox *funcCombo = - dynamic_cast<TQComboBox*>( TQObject_child_const( functionStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(functionStack), "textRuleFuncCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( functionStack->child( "textRuleFuncCombo", @@ -503,7 +503,7 @@ namespace { if ( func == KMSearchRule::FuncIsInCategory || func == KMSearchRule::FuncIsNotInCategory ) { const TQComboBox *combo= - dynamic_cast<TQComboBox*>( TQObject_child_const( valueStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(valueStack), "categoryCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( valueStack->child( "categoryCombo", @@ -520,7 +520,7 @@ namespace { //in other cases of func it is a lineedit const RegExpLineEdit *lineEdit = - dynamic_cast<RegExpLineEdit*>( TQObject_child_const( valueStack, + dynamic_cast<RegExpLineEdit*>( TQObject_child_const( TQT_TQOBJECT_CONST(valueStack), "regExpLineEdit" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<RegExpLineEdit*>( valueStack->child( "regExpLineEdit", @@ -646,15 +646,15 @@ namespace { if ( func == KMSearchRule::FuncIsInAddressbook || func == KMSearchRule::FuncIsNotInAddressbook ) { TQWidget *w = - static_cast<TQWidget*>( valueStack->child( "textRuleValueHider", + TQT_TQWIDGET( valueStack->child( "textRuleValueHider", 0, false ) ); valueStack->raiseWidget( w ); } else if ( func == KMSearchRule::FuncIsInCategory || func == KMSearchRule::FuncIsNotInCategory) { TQComboBox *combo = - static_cast<TQComboBox*>( valueStack->child( "categoryCombo", - 0, false ) ); + static_cast<TQComboBox*>( TQT_TQWIDGET(valueStack->child( "categoryCombo", + 0, false )) ); combo->blockSignals( true ); for ( i = 0; i < combo->count(); ++i ) if ( rule->contents() == combo->text( i ) ) { @@ -692,7 +692,7 @@ namespace { { // raise the correct function widget functionStack->raiseWidget( - static_cast<TQWidget*>( functionStack->child( "textRuleFuncCombo", + TQT_TQWIDGET( functionStack->child( "textRuleFuncCombo", 0, false ) ) ); // raise the correct value widget @@ -700,13 +700,13 @@ namespace { if ( func == KMSearchRule::FuncIsInAddressbook || func == KMSearchRule::FuncIsNotInAddressbook ) { valueStack->raiseWidget( - static_cast<TQWidget*>( valueStack->child( "textRuleValueHider", + TQT_TQWIDGET( valueStack->child( "textRuleValueHider", 0, false ) ) ); } else if ( func == KMSearchRule::FuncIsInCategory || func == KMSearchRule::FuncIsNotInCategory) { valueStack->raiseWidget( - static_cast<TQWidget*>( valueStack->child( "categoryCombo", + TQT_TQWIDGET( valueStack->child( "categoryCombo", 0, false ) ) ); } else { @@ -794,7 +794,7 @@ namespace { KMSearchRule::Function MessageRuleWidgetHandler::currentFunction( const TQWidgetStack *functionStack ) const { const TQComboBox *funcCombo = - dynamic_cast<TQComboBox*>( TQObject_child_const( functionStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(functionStack), "messageRuleFuncCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( functionStack->child( "messageRuleFuncCombo", @@ -825,7 +825,7 @@ namespace { KMSearchRule::Function ) const { const RegExpLineEdit *lineEdit = - dynamic_cast<RegExpLineEdit*>( TQObject_child_const( valueStack, + dynamic_cast<RegExpLineEdit*>( TQObject_child_const( TQT_TQOBJECT_CONST(valueStack), "regExpLineEdit" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<RegExpLineEdit*>( valueStack->child( "regExpLineEdit", @@ -947,7 +947,7 @@ namespace { if ( func == KMSearchRule::FuncHasAttachment || func == KMSearchRule::FuncHasNoAttachment ) { TQWidget *w = - static_cast<TQWidget*>( valueStack->child( "textRuleValueHider", + TQT_TQWIDGET( valueStack->child( "textRuleValueHider", 0, false ) ); valueStack->raiseWidget( w ); } @@ -978,7 +978,7 @@ namespace { return false; // raise the correct function widget functionStack->raiseWidget( - static_cast<TQWidget*>( functionStack->child( "messageRuleFuncCombo", + TQT_TQWIDGET( functionStack->child( "messageRuleFuncCombo", 0, false ) ) ); // raise the correct value widget @@ -986,7 +986,7 @@ namespace { if ( func == KMSearchRule::FuncHasAttachment || func == KMSearchRule::FuncHasNoAttachment ) { TQWidget *w = - static_cast<TQWidget*>( valueStack->child( "textRuleValueHider", + TQT_TQWIDGET( valueStack->child( "textRuleValueHider", 0, false ) ); valueStack->raiseWidget( w ); } @@ -1068,7 +1068,7 @@ namespace { KMSearchRule::Function StatusRuleWidgetHandler::currentFunction( const TQWidgetStack *functionStack ) const { const TQComboBox *funcCombo = - dynamic_cast<TQComboBox*>( TQObject_child_const( functionStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(functionStack), "statusRuleFuncCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( functionStack->child( "statusRuleFuncCombo", @@ -1098,7 +1098,7 @@ namespace { int StatusRuleWidgetHandler::currenStatusValue( const TQWidgetStack *valueStack ) const { const TQComboBox *statusCombo = - dynamic_cast<TQComboBox*>( TQObject_child_const( valueStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(valueStack), "statusRuleValueCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( valueStack->child( "statusRuleValueCombo", @@ -1249,12 +1249,12 @@ namespace { // raise the correct function widget functionStack->raiseWidget( - static_cast<TQWidget*>( functionStack->child( "statusRuleFuncCombo", + TQT_TQWIDGET( functionStack->child( "statusRuleFuncCombo", 0, false ) ) ); // raise the correct value widget valueStack->raiseWidget( - static_cast<TQWidget*>( valueStack->child( "statusRuleValueCombo", + TQT_TQWIDGET( valueStack->child( "statusRuleValueCombo", 0, false ) ) ); return true; } @@ -1323,7 +1323,7 @@ namespace { KMSearchRule::Function NumericRuleWidgetHandler::currentFunction( const TQWidgetStack *functionStack ) const { const TQComboBox *funcCombo = - dynamic_cast<TQComboBox*>( TQObject_child_const( functionStack, + dynamic_cast<TQComboBox*>( TQObject_child_const( TQT_TQOBJECT_CONST(functionStack), "numericRuleFuncCombo" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<TQComboBox*>( functionStack->child( "numericRuleFuncCombo", @@ -1353,7 +1353,7 @@ namespace { TQString NumericRuleWidgetHandler::currentValue( const TQWidgetStack *valueStack ) const { const KIntNumInput *numInput = - dynamic_cast<KIntNumInput*>( TQObject_child_const( valueStack, + dynamic_cast<KIntNumInput*>( TQObject_child_const( TQT_TQOBJECT_CONST(valueStack), "KIntNumInput" ) ); // FIXME (TQt >= 4.0): Use the following when TQObject::child() is const. // dynamic_cast<KIntNumInput*>( valueStack->child( "KIntNumInput", @@ -1502,7 +1502,7 @@ namespace { // raise the correct function widget functionStack->raiseWidget( - static_cast<TQWidget*>( functionStack->child( "numericRuleFuncCombo", + TQT_TQWIDGET( functionStack->child( "numericRuleFuncCombo", 0, false ) ) ); // raise the correct value widget diff --git a/kmail/searchjob.cpp b/kmail/searchjob.cpp index cabae0fd5..a9eb35365 100644 --- a/kmail/searchjob.cpp +++ b/kmail/searchjob.cpp @@ -252,7 +252,7 @@ void SearchJob::slotSearchFolder() // so we need to download all messages and check TQString question = i18n("To execute your search all messages of the folder %1 " "have to be downloaded from the server. This may take some time. " - "Do you want to continue your search?").arg( mFolder->label() ); + "Do you want to continue your search?").tqarg( mFolder->label() ); if ( KMessageBox::warningContinueCancel( 0, question, i18n("Continue Search"), i18n("&Search"), "continuedownloadingforsearch" ) != KMessageBox::Continue ) @@ -267,7 +267,7 @@ void SearchJob::slotSearchFolder() mProgress = ProgressManager::createProgressItem( "ImapSearchDownload" + ProgressManager::getUniqueID(), i18n("Downloading emails from IMAP server"), - i18n( "URL: %1" ).arg( TQStyleSheet::escape( mFolder->folder()->prettyURL() ) ), + i18n( "URL: %1" ).tqarg( TQStyleSheet::escape( mFolder->folder()->prettyURL() ) ), true, mAccount->useSSL() || mAccount->useTLS() ); mProgress->setTotalItems( numMsgs ); diff --git a/kmail/searchwindow.cpp b/kmail/searchwindow.cpp index ee7e090bf..24d08a069 100644 --- a/kmail/searchwindow.cpp +++ b/kmail/searchwindow.cpp @@ -188,8 +188,8 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, if ( list ) object = list->first(); delete list; - if (!searchFolder && object && ::qt_cast<TQComboBox*>(object)) - static_cast<TQComboBox*>(object)->setCurrentText("Subject"); + if (!searchFolder && object && ::tqqt_cast<TQComboBox*>(object)) + static_cast<TQComboBox*>(TQT_TQWIDGET(object))->setCurrentText("Subject"); vbl->addWidget( mPatternEdit ); @@ -199,7 +199,7 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, connect( mChkbxSpecificFolders, TQT_SIGNAL(toggled(bool)), mChkSubFolders, TQT_SLOT(setEnabled(bool)) ); connect( mChkbxAllFolders, TQT_SIGNAL(toggled(bool)), - this, TQT_SLOT(setEnabledSearchButton(bool)) ); + TQT_TQOBJECT(this), TQT_SLOT(setEnabledSearchButton(bool)) ); mLbxMatches = new MatchListView(searchWidget, this, "Find Messages"); @@ -237,13 +237,13 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, mLbxMatches->setDragEnabled( true ); connect( mLbxMatches, TQT_SIGNAL(clicked(TQListViewItem *)), - this, TQT_SLOT(slotShowMsg(TQListViewItem *)) ); + TQT_TQOBJECT(this), TQT_SLOT(slotShowMsg(TQListViewItem *)) ); connect( mLbxMatches, TQT_SIGNAL(doubleClicked(TQListViewItem *)), - this, TQT_SLOT(slotViewMsg(TQListViewItem *)) ); + TQT_TQOBJECT(this), TQT_SLOT(slotViewMsg(TQListViewItem *)) ); connect( mLbxMatches, TQT_SIGNAL(currentChanged(TQListViewItem *)), - this, TQT_SLOT(slotCurrentChanged(TQListViewItem *)) ); + TQT_TQOBJECT(this), TQT_SLOT(slotCurrentChanged(TQListViewItem *)) ); connect( mLbxMatches, TQT_SIGNAL(contextMenuRequested(TQListViewItem *,const TQPoint &,int)), - this, TQT_SLOT(slotContextMenuRequested(TQListViewItem *,const TQPoint &,int)) ); + TQT_TQOBJECT(this), TQT_SLOT(slotContextMenuRequested(TQListViewItem *,const TQPoint &,int)) ); vbl->addWidget( mLbxMatches ); TQHBoxLayout *hbl2 = new TQHBoxLayout( vbl, spacingHint(), "kmfs_hbl2" ); @@ -261,16 +261,16 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, mSearchFolderOpenBtn->setEnabled(false); hbl2->addWidget(mSearchFolderOpenBtn); connect( mSearchFolderEdt, TQT_SIGNAL( textChanged( const TQString &)), - this, TQT_SLOT( scheduleRename( const TQString & ))); + TQT_TQOBJECT(this), TQT_SLOT( scheduleRename( const TQString & ))); connect( &mRenameTimer, TQT_SIGNAL( timeout() ), - this, TQT_SLOT( renameSearchFolder() )); + TQT_TQOBJECT(this), TQT_SLOT( renameSearchFolder() )); connect( mSearchFolderOpenBtn, TQT_SIGNAL( clicked() ), - this, TQT_SLOT( openSearchFolder() )); + TQT_TQOBJECT(this), TQT_SLOT( openSearchFolder() )); mSearchResultOpenBtn = new TQPushButton(i18n("Open &Message"), searchWidget); mSearchResultOpenBtn->setEnabled(false); hbl2->addWidget(mSearchResultOpenBtn); connect( mSearchResultOpenBtn, TQT_SIGNAL( clicked() ), - this, TQT_SLOT( slotViewSelectedMsg() )); + TQT_TQOBJECT(this), TQT_SLOT( slotViewSelectedMsg() )); mStatusBar = new KStatusBar(searchWidget); mStatusBar->insertFixedItem(i18n("AMiddleLengthText..."), 0, true); mStatusBar->changeItem(i18n("Ready."), 0); @@ -286,7 +286,7 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, resize(mainWidth, mainHeight); setMainWidget(searchWidget); - setButtonBoxOrientation(TQWidget::Vertical); + setButtonBoxOrientation(Qt::Vertical); mBtnSearch = actionButton(KDialogBase::User1); mBtnStop = actionButton(KDialogBase::User2); @@ -294,12 +294,12 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, connect(this, TQT_SIGNAL(user1Clicked()), TQT_SLOT(slotSearch())); connect(this, TQT_SIGNAL(user2Clicked()), TQT_SLOT(slotStop())); - connect(this, TQT_SIGNAL(finished()), this, TQT_SLOT(deleteLater())); + connect(this, TQT_SIGNAL(finished()), TQT_TQOBJECT(this), TQT_SLOT(deleteLater())); // give focus to the value field of the first search rule object = mPatternEdit->child( "regExpLineEdit" ); if ( object && object->isWidgetType() ) { - static_cast<TQWidget*>(object)->setFocus(); + TQT_TQWIDGET(object)->setFocus(); //kdDebug(5006) << "SearchWindow: focus has been given to widget " // << object->name() << endl; } @@ -309,13 +309,13 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, //set up actions KActionCollection *ac = actionCollection(); ac->setWidget( this ); - mReplyAction = new KAction( i18n("&Reply..."), "mail_reply", 0, this, + mReplyAction = new KAction( i18n("&Reply..."), "mail_reply", 0, TQT_TQOBJECT(this), TQT_SLOT(slotReplyToMsg()), ac, "search_reply" ); mReplyAllAction = new KAction( i18n("Reply to &All..."), "mail_replyall", - 0, this, TQT_SLOT(slotReplyAllToMsg()), + 0, TQT_TQOBJECT(this), TQT_SLOT(slotReplyAllToMsg()), ac, "search_reply_all" ); mReplyListAction = new KAction( i18n("Reply to Mailing-&List..."), - "mail_replylist", 0, this, + "mail_replylist", 0, TQT_TQOBJECT(this), TQT_SLOT(slotReplyListToMsg()), ac, "search_reply_list" ); mForwardActionMenu = new KActionMenu( i18n("Message->","&Forward"), @@ -324,11 +324,11 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, connect( mForwardActionMenu, TQT_SIGNAL(activated()), this, TQT_SLOT(slotForwardInlineMsg()) ); mForwardAttachedAction = new KAction( i18n("Message->Forward->","As &Attachment..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardAttachedMsg()), ac, "search_message_forward_as_attachment" ); mForwardInlineAction = new KAction( i18n("&Inline..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardInlineMsg()), ac, "search_message_forward_inline" ); if ( GlobalSettings::self()->forwardingInlineByDefault() ) { @@ -340,32 +340,32 @@ SearchWindow::SearchWindow(KMMainWidget* w, const char* name, } mForwardDigestAction = new KAction( i18n("Message->Forward->","As Di&gest..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotForwardDigestMsg()), ac, "search_message_forward_as_digest" ); mForwardActionMenu->insert( mForwardDigestAction ); mRedirectAction = new KAction( i18n("Message->Forward->","&Redirect..."), - "mail_forward", 0, this, + "mail_forward", 0, TQT_TQOBJECT(this), TQT_SLOT(slotRedirectMsg()), ac, "search_message_forward_redirect" ); mForwardActionMenu->insert( mRedirectAction ); - mSaveAsAction = KStdAction::saveAs( this, TQT_SLOT(slotSaveMsg()), ac, "search_file_save_as" ); + mSaveAsAction = KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT(slotSaveMsg()), ac, "search_file_save_as" ); mSaveAtchAction = new KAction( i18n("Save Attachments..."), "attach", 0, - this, TQT_SLOT(slotSaveAttachments()), ac, "search_save_attachments" ); + TQT_TQOBJECT(this), TQT_SLOT(slotSaveAttachments()), ac, "search_save_attachments" ); - mPrintAction = KStdAction::print( this, TQT_SLOT(slotPrintMsg()), ac, "search_print" ); - mClearAction = new KAction( i18n("Clear Selection"), 0, 0, this, + mPrintAction = KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT(slotPrintMsg()), ac, "search_print" ); + mClearAction = new KAction( i18n("Clear Selection"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(slotClearSelection()), ac, "search_clear_selection" ); - mCopyAction = KStdAction::copy( this, TQT_SLOT(slotCopyMsgs()), ac, "search_copy_messages" ); - mCutAction = KStdAction::cut( this, TQT_SLOT(slotCutMsgs()), ac, "search_cut_messages" ); + mCopyAction = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(slotCopyMsgs()), ac, "search_copy_messages" ); + mCutAction = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT(slotCutMsgs()), ac, "search_cut_messages" ); - connect(mTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(updtqStatus())); + connect(mTimer, TQT_SIGNAL(timeout()), TQT_TQOBJECT(this), TQT_SLOT(updtqStatus())); connect(kmkernel->searchFolderMgr(), TQT_SIGNAL(folderInvalidated(KMFolder*)), - this, TQT_SLOT(folderInvalidated(KMFolder*))); + TQT_TQOBJECT(this), TQT_SLOT(folderInvalidated(KMFolder*))); connect(mCbxFolders, TQT_SIGNAL(folderChanged(KMFolder*)), - this, TQT_SLOT(slotFolderActivated())); + TQT_TQOBJECT(this), TQT_SLOT(slotFolderActivated())); } @@ -418,17 +418,17 @@ void SearchWindow::updtqStatus(void) if(!mStopped) { genMsg = i18n("Done."); detailMsg = i18n("%n match in %1", "%n matches in %1", - numMatches).arg(procMsg); + numMatches).tqarg(procMsg); } else { genMsg = i18n("Search canceled."); detailMsg = i18n("%n match so far in %1", "%n matches so far in %1", - numMatches).arg(procMsg); + numMatches).tqarg(procMsg); } } else { procMsg = i18n("%n message", "%n messages", numProcessed); genMsg = i18n("%n match", "%n matches", numMatches); detailMsg = i18n("Searching in %1. %2 searched so far") - .arg(folderName).arg(procMsg); + .tqarg(folderName).tqarg(procMsg); } mStatusBar->changeItem(genMsg, 0); @@ -497,7 +497,7 @@ void SearchWindow::slotSearch() while ((folder = mgr->tqfind(fullName))) { if (folder->storage()->inherits("KMFolderSearch")) break; - fullName = TQString("%1 %2").arg(baseName).arg(++count); + fullName = TQString("%1 %2").tqarg(baseName).tqarg(++count); } if (!folder) @@ -508,17 +508,17 @@ void SearchWindow::slotSearch() } mFolder->stopSearch(); disconnect(mFolder, TQT_SIGNAL(msgAdded(int)), - this, TQT_SLOT(slotAddMsg(int))); + TQT_TQOBJECT(this), TQT_SLOT(slotAddMsg(int))); disconnect(mFolder, TQT_SIGNAL(msgRemoved(KMFolder*, TQ_UINT32)), - this, TQT_SLOT(slotRemoveMsg(KMFolder*, TQ_UINT32))); + TQT_TQOBJECT(this), TQT_SLOT(slotRemoveMsg(KMFolder*, TQ_UINT32))); connect(mFolder, TQT_SIGNAL(msgAdded(int)), - this, TQT_SLOT(slotAddMsg(int))); + TQT_TQOBJECT(this), TQT_SLOT(slotAddMsg(int))); connect(mFolder, TQT_SIGNAL(msgRemoved(KMFolder*, TQ_UINT32)), - this, TQT_SLOT(slotRemoveMsg(KMFolder*, TQ_UINT32))); + TQT_TQOBJECT(this), TQT_SLOT(slotRemoveMsg(KMFolder*, TQ_UINT32))); mSearchFolderEdt->setEnabled(false); KMSearch *search = new KMSearch(); connect(search, TQT_SIGNAL(finished(bool)), - this, TQT_SLOT(searchDone())); + TQT_TQOBJECT(this), TQT_SLOT(searchDone())); if (mChkbxAllFolders->isChecked()) { search->setRecursive(true); } else { @@ -543,7 +543,7 @@ void SearchWindow::searchDone() mTimer->stop(); updtqStatus(); - TQTimer::singleShot(0, this, TQT_SLOT(enableGUI())); + TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(enableGUI())); if(mLastFocus) mLastFocus->setFocus(); if (mCloseRequested) @@ -623,7 +623,7 @@ void SearchWindow::closeEvent(TQCloseEvent *e) //Cancel search in progress by setting the search folder search to //the null search mFolder->setSearch(new KMSearch()); - TQTimer::singleShot(0, this, TQT_SLOT(slotClose())); + TQTimer::singleShot(0, TQT_TQOBJECT(this), TQT_SLOT(slotClose())); } else { KDialogBase::closeEvent(e); } @@ -677,7 +677,7 @@ void SearchWindow::folderInvalidated(KMFolder *folder) mLbxMatches->clear(); if (mFolder->search()) connect(mFolder->search(), TQT_SIGNAL(finished(bool)), - this, TQT_SLOT(searchDone())); + TQT_TQOBJECT(this), TQT_SLOT(searchDone())); mTimer->start(200); enableGUI(); } @@ -840,10 +840,10 @@ void SearchWindow::slotContextMenuRequested( TQListViewItem *lvi, const TQPoint mMenuToFolder.clear(); TQPopupMenu *msgMoveMenu = new TQPopupMenu(menu); mKMMainWidget->folderTree()->folderToPopupMenu( KMFolderTree::MoveMessage, - this, &mMenuToFolder, msgMoveMenu ); + TQT_TQOBJECT(this), &mMenuToFolder, msgMoveMenu ); TQPopupMenu *msgCopyMenu = new TQPopupMenu(menu); mKMMainWidget->folderTree()->folderToPopupMenu( KMFolderTree::CopyMessage, - this, &mMenuToFolder, msgCopyMenu ); + TQT_TQOBJECT(this), &mMenuToFolder, msgCopyMenu ); // show most used actions mReplyAction->plug(menu); diff --git a/kmail/sievedebugdialog.cpp b/kmail/sievedebugdialog.cpp index d29b732d5..75d07495d 100644 --- a/kmail/sievedebugdialog.cpp +++ b/kmail/sievedebugdialog.cpp @@ -253,7 +253,7 @@ void SieveDebugDialog::slotDiagNextAccount() KMAccount *acc = mAccountList.first(); mAccountList.pop_front(); - mEdit->append( i18n( "Collecting data for account '%1'...\n" ).arg( acc->name() ) ); + mEdit->append( i18n( "Collecting data for account '%1'...\n" ).tqarg( acc->name() ) ); mEdit->append( i18n( "------------------------------------------------------------\n" ) ); mAccountBase = dynamic_cast<KMail::ImapAccountBase *>( acc ); if ( mAccountBase ) @@ -295,7 +295,7 @@ void SieveDebugDialog::slotDiagNextScript() TQString scriptFile = mScriptList.first(); mScriptList.pop_front(); - mEdit->append( i18n( "Contents of script '%1':\n" ).arg( scriptFile ) ); + mEdit->append( i18n( "Contents of script '%1':\n" ).tqarg( scriptFile ) ); mUrl = urlFromAccount( mAccountBase ); mUrl.setFileName( scriptFile ); @@ -324,7 +324,7 @@ void SieveDebugDialog::slotGetScript( SieveJob * /* job */, bool success, mEdit->append( i18n( "------------------------------------------------------------\n" "%1\n" - "------------------------------------------------------------\n\n" ).arg( script ) ); + "------------------------------------------------------------\n\n" ).tqarg( script ) ); } // Fetch next script @@ -363,7 +363,7 @@ void SieveDebugDialog::slotGetScriptList( SieveJob *job, bool success, for ( TQStringList::const_iterator it = scriptList.begin(); it != scriptList.end(); ++it ) mEdit->append( "* " + *it + "\n" ); mEdit->append( "\n" ); - mEdit->append( i18n( "Active script: %1\n\n" ).arg( activeScript ) ); + mEdit->append( i18n( "Active script: %1\n\n" ).tqarg( activeScript ) ); } // Handle next job: dump scripts for this server diff --git a/kmail/snippetwidget.cpp b/kmail/snippetwidget.cpp index ac8d0ebf4..12da05014 100644 --- a/kmail/snippetwidget.cpp +++ b/kmail/snippetwidget.cpp @@ -145,9 +145,9 @@ void SnippetWidget::slotAdd() SnippetItem* SnippetWidget::makeItem( SnippetItem* tqparent, const TQString& name, const TQString& text, const KShortcut& shortcut ) { SnippetItem * item = new SnippetItem(tqparent, name, text); - const TQString actionName = i18n("Snippet %1").arg(name); + const TQString actionName = i18n("Snippet %1").tqarg(name); const TQString normalizedName = TQString(actionName).tqreplace(" ", "_"); - if ( !mActionCollection->action(normalizedName.utf8() ) ) { + if ( !mActionCollection->action(normalizedName.utf8().data() ) ) { KAction * action = new KAction( actionName, shortcut, item, TQT_SLOT( slotExecute() ), mActionCollection, normalizedName.utf8() ); @@ -352,8 +352,8 @@ void SnippetWidget::writeConfig() SnippetGroup * group = dynamic_cast<SnippetGroup*>(item); if (group) { //kdDebug(5006) << "-->GROUP " << item->getName() << group->getId() << " " << iGroupCount<< endl; - strKeyName=TQString("snippetGroupName_%1").arg(iGroupCount); - strKeyId=TQString("snippetGroupId_%1").arg(iGroupCount); + strKeyName=TQString("snippetGroupName_%1").tqarg(iGroupCount); + strKeyId=TQString("snippetGroupId_%1").tqarg(iGroupCount); _cfg->writeEntry(strKeyName, group->getName()); _cfg->writeEntry(strKeyId, group->getId()); @@ -361,9 +361,9 @@ void SnippetWidget::writeConfig() iGroupCount++; } else if (dynamic_cast<SnippetItem*>(item)) { //kdDebug(5006) << "-->ITEM " << item->getName() << item->getParent() << " " << iSnipCount << endl; - strKeyName=TQString("snippetName_%1").arg(iSnipCount); - strKeyText=TQString("snippetText_%1").arg(iSnipCount); - strKeyId=TQString("snippetParent_%1").arg(iSnipCount); + strKeyName=TQString("snippetName_%1").tqarg(iSnipCount); + strKeyText=TQString("snippetText_%1").tqarg(iSnipCount); + strKeyId=TQString("snippetParent_%1").tqarg(iSnipCount); _cfg->writeEntry(strKeyName, item->getName()); _cfg->writeEntry(strKeyText, item->getText()); @@ -373,7 +373,7 @@ void SnippetWidget::writeConfig() assert( action ); const KShortcut& sc = action->shortcut(); if (!sc.isNull() ) { - _cfg->writeEntry( TQString("snippetShortcut_%1").arg(iSnipCount), sc.toString() ); + _cfg->writeEntry( TQString("snippetShortcut_%1").tqarg(iSnipCount), sc.toString() ); } iSnipCount++; } else { @@ -389,8 +389,8 @@ void SnippetWidget::writeConfig() for ( it = _mapSaved.begin(); it != _mapSaved.end(); ++it ) { //write the saved variable values if (it.data().length()<=0) continue; //is the saved value has no length -> no need to save it - strKeyName=TQString("snippetSavedName_%1").arg(iCount); - strKeyText=TQString("snippetSavedVal_%1").arg(iCount); + strKeyName=TQString("snippetSavedName_%1").tqarg(iCount); + strKeyText=TQString("snippetSavedVal_%1").tqarg(iCount); _cfg->writeEntry(strKeyName, it.key()); _cfg->writeEntry(strKeyText, it.data()); @@ -434,8 +434,8 @@ void SnippetWidget::initConfig() int iCount = _cfg->readNumEntry("snippetGroupCount", -1); for ( int i=0; i<iCount; i++) { //read the group-list - strKeyName=TQString("snippetGroupName_%1").arg(i); - strKeyId=TQString("snippetGroupId_%1").arg(i); + strKeyName=TQString("snippetGroupName_%1").tqarg(i); + strKeyId=TQString("snippetGroupId_%1").tqarg(i); TQString strNameVal=""; int iIdVal=-1; @@ -460,9 +460,9 @@ void SnippetWidget::initConfig() if (iCount != -1) { iCount = _cfg->readNumEntry("snippetCount", 0); for ( int i=0; i<iCount; i++) { //read the snippet-list - strKeyName=TQString("snippetName_%1").arg(i); - strKeyText=TQString("snippetText_%1").arg(i); - strKeyId=TQString("snippetParent_%1").arg(i); + strKeyName=TQString("snippetName_%1").tqarg(i); + strKeyText=TQString("snippetText_%1").tqarg(i); + strKeyId=TQString("snippetParent_%1").tqarg(i); TQString strNameVal=""; TQString strTextVal=""; @@ -474,7 +474,7 @@ void SnippetWidget::initConfig() //kdDebug(5006) << "Read item " << strNameVal << " " << iParentVal << endl; if (strNameVal != "" && strTextVal != "" && iParentVal != -1) { - KShortcut shortcut( _cfg->readEntry( TQString("snippetShortcut_%1").arg(i), TQString() ) ); + KShortcut shortcut( _cfg->readEntry( TQString("snippetShortcut_%1").tqarg(i), TQString() ) ); item = makeItem( SnippetItem::findGroupById(iParentVal, _list), strNameVal, strTextVal, shortcut ); //kdDebug(5006) << "Created item " << item->getName() << " " << item->getParent() << endl; _list.append(item); @@ -487,8 +487,8 @@ void SnippetWidget::initConfig() iCount = _cfg->readNumEntry("snippetSavedCount", 0); for ( int i=1; i<=iCount; i++) { //read the saved-values and store in TQMap - strKeyName=TQString("snippetSavedName_%1").arg(i); - strKeyText=TQString("snippetSavedVal_%1").arg(i); + strKeyName=TQString("snippetSavedName_%1").tqarg(i); + strKeyText=TQString("snippetSavedVal_%1").tqarg(i); TQString strNameVal=""; TQString strTextVal=""; @@ -586,7 +586,7 @@ TQString SnippetWidget::parseText(TQString text, TQString del) if ( strName != del+del ) { //if not doubel-delimiter if (iInMeth == 0) { //if input-method "single" is selected if ( mapVar[strName].length() <= 0 ) { // and not already in map - strMsg=i18n("Please enter the value for <b>%1</b>:").arg(strName); + strMsg=i18n("Please enter the value for <b>%1</b>:").tqarg(strName); strNew = showSingleVarDialog( strName, &_mapSaved, rSingle ); if (strNew=="") return ""; //user clicked Cancle @@ -799,7 +799,7 @@ TQString SnippetWidget::showSingleVarDialog(TQString var, TQMap<TQString, TQStri labTop = new TQLabel( &dlg, "label" ); tqlayoutTop->addWidget(labTop, 0, 0); - labTop->setText(i18n("Enter the replacement values for %1:").arg( var )); + labTop->setText(i18n("Enter the replacement values for %1:").tqarg( var )); tqlayout->addMultiCellLayout( tqlayoutTop, 0, 0, 0, 1 ); diff --git a/kmail/subscriptiondialog.cpp b/kmail/subscriptiondialog.cpp index 346cfa8c8..e476749e6 100644 --- a/kmail/subscriptiondialog.cpp +++ b/kmail/subscriptiondialog.cpp @@ -374,7 +374,7 @@ void SubscriptionDialog::doSave() if( !a->onlySubscribedFolders() ) { int result = KMessageBox::questionYesNoCancel( this, i18n("Currently subscriptions are not used for server. %1\nDo you want to enable subscriptions?") - .arg( a->name() ), + .tqarg( a->name() ), i18n("Enable Subscriptions?"), i18n("Enable"), i18n("Do Not Enable")); switch(result) { case KMessageBox::Yes: diff --git a/kmail/templateparser.cpp b/kmail/templateparser.cpp index d497f1846..8e167f5fd 100644 --- a/kmail/templateparser.cpp +++ b/kmail/templateparser.cpp @@ -261,7 +261,7 @@ void TemplateParser::processWithTemplate( const TQString &tmpl ) } else if ( mDebug ) { KMessageBox::error( 0, i18n( "Cannot insert content from file %1: %2" ). - arg( path ).arg( file.errorString() ) ); + tqarg( path ).tqarg( file.errorString() ) ); } } else if ( cmd.startsWith( "SYSTEM=" ) ) { @@ -294,7 +294,7 @@ void TemplateParser::processWithTemplate( const TQString &tmpl ) } else if ( mDebug ) { KMessageBox::error( 0, i18n( "Cannot insert content from file %1: %2"). - arg( path ).arg(file.errorString() )); + tqarg( path ).tqarg(file.errorString() )); } } else if ( cmd.startsWith( "TQUOTEPIPE=" ) ) { @@ -396,7 +396,7 @@ void TemplateParser::processWithTemplate( const TQString &tmpl ) kdDebug() << "Command: OTEXTSIZE" << endl; i += strlen( "OTEXTSIZE" ); if ( mOrigMsg ) { - TQString str = TQString( "%1" ).arg( mOrigMsg->body().length() ); + TQString str = TQString( "%1" ).tqarg( mOrigMsg->body().length() ); body.append( str ); } @@ -967,7 +967,7 @@ void TemplateParser::addProcessedBodyToMessage( const TQString &body ) DwParameter *nameParameter = new DwParameter; nameParameter->SetAttribute( "name" ); nameParameter->SetValue( Util::dwString( KMMsgBase::encodeRFC2231StringAutoDetectCharset( - i18n( "Attachment %1" ).arg( attachmentNumber ) ) ) ); + i18n( "Attachment %1" ).tqarg( attachmentNumber ) ) ) ); ct.AddParameter( nameParameter ); } } @@ -1059,7 +1059,7 @@ TQString TemplateParser::findTemplate() TQString iid; if ( mIdentity ) { - iid = TQString("IDENTITY_%1").arg( mIdentity ); // templates ID for that identity + iid = TQString("IDENTITY_%1").tqarg( mIdentity ); // templates ID for that identity } else { iid = "IDENTITY_NO_IDENTITY"; // templates ID for no identity @@ -1148,11 +1148,11 @@ TQString TemplateParser::pipe( const TQString &cmd, const TQString &buf ) if ( mPipeErr.isEmpty() ) { KMessageBox::error( 0, i18n( "Pipe command exit with status %1: %2"). - arg( mPipeRc ).arg( cmd ) ); + tqarg( mPipeRc ).tqarg( cmd ) ); } else { KMessageBox::detailedError( 0, i18n( "Pipe command exit with status %1: %2" ). - arg( mPipeRc ).arg( cmd ), mPipeErr ); + tqarg( mPipeRc ).tqarg( cmd ), mPipeErr ); } } @@ -1163,11 +1163,11 @@ TQString TemplateParser::pipe( const TQString &cmd, const TQString &buf ) if ( mPipeErr.isEmpty() ) { KMessageBox::error( 0, i18n( "Pipe command killed by signal %1: %2" ). - arg( -(mPipeRc) ).arg( cmd ) ); + tqarg( -(mPipeRc) ).tqarg( cmd ) ); } else { KMessageBox::detailedError( 0, i18n( "Pipe command killed by signal %1: %2" ). - arg( -(mPipeRc) ).arg( cmd ), mPipeErr ); + tqarg( -(mPipeRc) ).tqarg( cmd ), mPipeErr ); } } } @@ -1179,7 +1179,7 @@ TQString TemplateParser::pipe( const TQString &cmd, const TQString &buf ) if ( mDebug ) { KMessageBox::error( 0, i18n( "Pipe command did not finish within %1 seconds: %2" ). - arg( PipeTimeout ).arg( cmd ) ); + tqarg( PipeTimeout ).tqarg( cmd ) ); } } @@ -1190,11 +1190,11 @@ TQString TemplateParser::pipe( const TQString &cmd, const TQString &buf ) if ( mDebug ) { if ( mPipeErr.isEmpty() ) { KMessageBox::error( 0, - i18n( "Cannot write to process stdin: %1" ).arg( cmd ) ); + i18n( "Cannot write to process stdin: %1" ).tqarg( cmd ) ); } else { KMessageBox::detailedError( 0, i18n( "Cannot write to process stdin: %1" ). - arg( cmd ), mPipeErr ); + tqarg( cmd ), mPipeErr ); } } } @@ -1202,7 +1202,7 @@ TQString TemplateParser::pipe( const TQString &cmd, const TQString &buf ) } else if ( mDebug ) { KMessageBox::error( 0, i18n( "Cannot start pipe command from template: %1" ). - arg( cmd ) ); + tqarg( cmd ) ); } return mPipeOut; diff --git a/kmail/templatesconfiguration.cpp b/kmail/templatesconfiguration.cpp index 0e52599c4..00bf87d90 100644 --- a/kmail/templatesconfiguration.cpp +++ b/kmail/templatesconfiguration.cpp @@ -102,7 +102,7 @@ TemplatesConfiguration::TemplatesConfiguration( TQWidget *tqparent, const char * "if they are specified.</p>" "</qt>" ); } - mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).arg( help ) ); + mHelp->setText( i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).tqarg( help ) ); } void TemplatesConfiguration::slotTextChanged() @@ -163,7 +163,7 @@ void TemplatesConfiguration::saveToGlobal() void TemplatesConfiguration::loadFromIdentity( uint id ) { - Templates t( TQString("IDENTITY_%1").arg( id ) ); + Templates t( TQString("IDENTITY_%1").tqarg( id ) ); TQString str; @@ -215,7 +215,7 @@ void TemplatesConfiguration::loadFromIdentity( uint id ) void TemplatesConfiguration::saveToIdentity( uint id ) { - Templates t( TQString("IDENTITY_%1").arg( id ) ); + Templates t( TQString("IDENTITY_%1").tqarg( id ) ); t.setTemplateNewMessage( strOrBlank( textEdit_new->text() ) ); t.setTemplateReply( strOrBlank( textEdit_reply->text() ) ); @@ -231,7 +231,7 @@ void TemplatesConfiguration::loadFromFolder( TQString id, uint identity ) Templates* tid = 0; if ( identity ) { - tid = new Templates( TQString("IDENTITY_%1").arg( identity ) ); + tid = new Templates( TQString("IDENTITY_%1").tqarg( identity ) ); } TQString str; @@ -344,7 +344,7 @@ void TemplatesConfiguration::loadFromPhrases() "---------- %1 ----------\n" "%TEXT\n" "-------------------------------------------------------\n" - ) ).arg( convertPhrases( str ) ) ); + ) ).tqarg( convertPhrases( str ) ) ); } else { textEdit_forward->setText( defaultForward() ); @@ -400,7 +400,7 @@ void TemplatesConfiguration::importFromPhrases() "\n" "%TEXT\n" "-------------------------------------------------------\n" - ) ).arg( convertPhrases( str ) ) ); + ) ).tqarg( convertPhrases( str ) ) ); } else { GlobalSettings::self()->setTemplateForward( defaultForward() ); diff --git a/kmail/templatesinsertcommand.cpp b/kmail/templatesinsertcommand.cpp index 2a33f3aaf..90a143731 100644 --- a/kmail/templatesinsertcommand.cpp +++ b/kmail/templatesinsertcommand.cpp @@ -41,11 +41,11 @@ TemplatesInsertCommand::TemplatesInsertCommand( TQWidget *tqparent, KAction *action; KActionMenu *menu; - TQSignalMapper *mapper = new TQSignalMapper( this ); + TQSignalMapper *mapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mapper, TQT_SIGNAL( mapped(int) ), this, TQT_SLOT( slotMapped(int) ) ); - mMenu = new KActionMenu( i18n( "Insert Command..." ), this ); + mMenu = new KActionMenu( i18n( "Insert Command..." ), TQT_TQOBJECT(this) ); // ****************************************************** menu = new KActionMenu( i18n( "Original Message" ), mMenu ); diff --git a/kmail/urlhandlermanager.cpp b/kmail/urlhandlermanager.cpp index e1707b1ba..0ef6bfd24 100644 --- a/kmail/urlhandlermanager.cpp +++ b/kmail/urlhandlermanager.cpp @@ -53,7 +53,7 @@ #include <algorithm> using std::for_each; using std::remove; -using std::tqfind; +using std::find; KMail::URLHandlerManager * KMail::URLHandlerManager::self = 0; @@ -561,7 +561,7 @@ namespace { TQString displayName, libName, keyId; if ( !foundSMIMEData( url.path() + '#' + url.ref(), displayName, libName, keyId ) ) return TQString(); - return i18n("Show certificate 0x%1").arg( keyId ); + return i18n("Show certificate 0x%1").tqarg( keyId ); } } @@ -689,8 +689,8 @@ namespace { if ( name.isEmpty() ) name = msgPart.name(); if ( !name.isEmpty() ) - return i18n( "Attachment: %1" ).arg( name ); - return i18n( "Attachment #%1 (unnamed)" ).arg( KMReaderWin::msgPartFromUrl( url ) ); + return i18n( "Attachment: %1" ).tqarg( name ); + return i18n( "Attachment #%1 (unnamed)" ).tqarg( KMReaderWin::msgPartFromUrl( url ) ); } } @@ -752,7 +752,7 @@ namespace { namespace { bool FallBackURLHandler::handleClick( const KURL & url, KMReaderWin * w ) const { if ( w ) - w->emitUrlClicked( url, TQt::LeftButton ); + w->emitUrlClicked( url, Qt::LeftButton ); return true; } diff --git a/kmail/util.cpp b/kmail/util.cpp index 9586f70d1..d153e9d37 100644 --- a/kmail/util.cpp +++ b/kmail/util.cpp @@ -146,7 +146,7 @@ void KMail::Util::append( TQByteArray& that, const TQByteArray& str ) that.detach(); uint len1 = that.size(); uint len2 = str.size(); - if ( that.resize( len1 + len2, TQByteArray::SpeedOptim ) ) + if ( that.tqresize( len1 + len2, TQGArray::SpeedOptim ) ) memcpy( that.data() + len1, str.data(), len2 ); } @@ -157,7 +157,7 @@ void KMail::Util::append( TQByteArray& that, const char* str ) that.detach(); uint len1 = that.size(); uint len2 = tqstrlen(str); - if ( that.resize( len1 + len2, TQByteArray::SpeedOptim ) ) + if ( that.tqresize( len1 + len2, TQGArray::SpeedOptim ) ) memcpy( that.data() + len1, str, len2 ); } @@ -166,7 +166,7 @@ void KMail::Util::append( TQByteArray& that, const TQCString& str ) that.detach(); uint len1 = that.size(); uint len2 = str.size() - 1; - if ( that.resize( len1 + len2, TQByteArray::SpeedOptim ) ) + if ( that.tqresize( len1 + len2, TQGArray::SpeedOptim ) ) memcpy( that.data() + len1, str.data(), len2 ); } @@ -180,13 +180,13 @@ void KMail::Util::insert( TQByteArray& that, uint index, const char* s ) int nlen = olen + len; if ( index >= olen ) { // insert after end of string that.detach(); - if ( that.resize(nlen+index-olen, TQByteArray::SpeedOptim ) ) { + if ( that.tqresize(nlen+index-olen, TQGArray::SpeedOptim ) ) { memset( that.data()+olen, ' ', index-olen ); memcpy( that.data()+index, s, len ); } } else { that.detach(); - if ( that.resize(nlen, TQByteArray::SpeedOptim ) ) { // normal insert + if ( that.tqresize(nlen, TQGArray::SpeedOptim ) ) { // normal insert memmove( that.data()+index+len, that.data()+index, olen-index ); memcpy( that.data()+index, s, len ); } diff --git a/kmail/util.h b/kmail/util.h index 9f291a2e0..0d1e263f7 100644 --- a/kmail/util.h +++ b/kmail/util.h @@ -206,7 +206,7 @@ namespace Util { KMessageBox::warningContinueCancel( w, i18n( "A file named \"%1\" already exists. " - "Are you sure you want to overwrite it?" ).arg( url.prettyURL() ), + "Are you sure you want to overwrite it?" ).tqarg( url.prettyURL() ), i18n( "Overwrite File?" ), i18n( "&Overwrite" ) ) ) return false; diff --git a/kmail/vacation.cpp b/kmail/vacation.cpp index edce8d854..d3440a975 100644 --- a/kmail/vacation.cpp +++ b/kmail/vacation.cpp @@ -475,12 +475,12 @@ namespace KMail { " { keep; stop; }\n" ); // FIXME? if ( !domain.isEmpty() ) // FIXME - script += TQString::tqfromLatin1( "if not address :domain :tqcontains \"from\" \"%1\" { keep; stop; }\n" ).arg( domain ); + script += TQString::tqfromLatin1( "if not address :domain :tqcontains \"from\" \"%1\" { keep; stop; }\n" ).tqarg( domain ); script += "vacation "; script += addressesArgument; if ( notificationInterval > 0 ) - script += TQString::tqfromLatin1(":days %1 ").arg( notificationInterval ); + script += TQString::tqfromLatin1(":days %1 ").tqarg( notificationInterval ); script += TQString::tqfromLatin1("text:\n"); script += dotstuff( messageText.isEmpty() ? defaultMessageText() : messageText ); script += TQString::tqfromLatin1( "\n.\n;\n" ); @@ -573,7 +573,7 @@ namespace KMail { "\n" "Yours sincerely,\n" "-- <enter your name and email address here>\n") - .arg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate().addDays( 1 ) ) ); + .tqarg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate().addDays( 1 ) ) ); } int Vacation::defaultNotificationInterval() { diff --git a/kmail/vacationdialog.cpp b/kmail/vacationdialog.cpp index 9e782adf7..e2ca8e0c0 100644 --- a/kmail/vacationdialog.cpp +++ b/kmail/vacationdialog.cpp @@ -96,7 +96,7 @@ namespace KMail { mDomainCheck->setChecked( false ); mDomainEdit = new TQLineEdit( plainPage(), "mDomainEdit" ); mDomainEdit->setEnabled( false ); - mDomainEdit->setValidator( new TQRegExpValidator( TQRegExp( "[a-zA-Z0-9+-]+(?:\\.[a-zA-Z0-9+-]+)*" ), mDomainEdit ) ); + mDomainEdit->setValidator( new TQRegExpValidator( TQRegExp( "[a-zA-Z0-9+-]+(?:\\.[a-zA-Z0-9+-]+)*" ), TQT_TQOBJECT(mDomainEdit) ) ); glay->addWidget( mDomainCheck, row, 0 ); glay->addWidget( mDomainEdit, row, 1 ); connect( mDomainCheck, TQT_SIGNAL(toggled(bool)), diff --git a/kmail/xfaceconfigurator.cpp b/kmail/xfaceconfigurator.cpp index 1110641d5..b49394dc7 100644 --- a/kmail/xfaceconfigurator.cpp +++ b/kmail/xfaceconfigurator.cpp @@ -266,7 +266,7 @@ namespace KMail { TQString str = mTextEdit->text(); if ( !str.isEmpty() ) { - if ( str.startsWith("x-face:", false) ) + if ( str.tqstartsWith("x-face:", false) ) { str = str.remove("x-face:", false); mTextEdit->setText(str); diff --git a/kmailcvt/filter_evolution.cxx b/kmailcvt/filter_evolution.cxx index f1d9eaff1..e2d0ff50e 100644 --- a/kmailcvt/filter_evolution.cxx +++ b/kmailcvt/filter_evolution.cxx @@ -73,7 +73,7 @@ void FilterEvolution::import(FilterInfo *info) info->setOverall((int) ((float) currentDir / numSubDirs * 100)); } } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); info->setCurrent(100); info->setOverall(100); } @@ -121,7 +121,7 @@ void FilterEvolution::importMBox(FilterInfo *info, const TQString& mboxName, con bool first_msg = true; TQString tmp_from = mboxName; if (!mbox.open(IO_ReadOnly)) { - info->alert(i18n("Unable to open %1, skipping").arg(mboxName)); + info->alert(i18n("Unable to open %1, skipping").tqarg(mboxName)); } else { TQFileInfo filenameInfo(mboxName); @@ -142,7 +142,7 @@ void FilterEvolution::importMBox(FilterInfo *info, const TQString& mboxName, con } else info->setTo(targetDir); - info->addLog(i18n("Importing emails from %1...").arg(tmp_from)); + info->addLog(i18n("Importing emails from %1...").tqarg(tmp_from)); TQByteArray input(MAX_LINE); long l = 0; diff --git a/kmailcvt/filter_evolution_v2.cxx b/kmailcvt/filter_evolution_v2.cxx index b8842e961..55a4817e9 100644 --- a/kmailcvt/filter_evolution_v2.cxx +++ b/kmailcvt/filter_evolution_v2.cxx @@ -87,7 +87,7 @@ void FilterEvolution_v2::import(FilterInfo *info) /** import last but not least all archives from the root-dir */ importDirContents(info, true, mailDir, TQString(), TQString()); - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if(count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } @@ -121,7 +121,7 @@ void FilterEvolution_v2::importDirContents(FilterInfo *info, bool root, if (temp_mailfile.endsWith(".cmeta") || temp_mailfile.endsWith(".ev-summary") || temp_mailfile.endsWith(".ev-summary-meta") || temp_mailfile.endsWith(".ibex.index") || temp_mailfile.endsWith(".ibex.index.data") ) {} else { - info->addLog( i18n("Start import file %1...").arg( temp_mailfile ) ); + info->addLog( i18n("Start import file %1...").tqarg( temp_mailfile ) ); if (!root) importMBox(info, (dirName + "/" + temp_mailfile) , KMailRootDir, KMailSubDir); else @@ -157,7 +157,7 @@ void FilterEvolution_v2::importMBox(FilterInfo *info, const TQString& mboxName, TQFile mbox(mboxName); bool first_msg = true; if (!mbox.open(IO_ReadOnly)) { - info->alert(i18n("Unable to open %1, skipping").arg(mboxName)); + info->alert(i18n("Unable to open %1, skipping").tqarg(mboxName)); } else { TQFileInfo filenameInfo(mboxName); diff --git a/kmailcvt/filter_kmail_maildir.cxx b/kmailcvt/filter_kmail_maildir.cxx index 081a2fda3..4648c04b0 100644 --- a/kmailcvt/filter_kmail_maildir.cxx +++ b/kmailcvt/filter_kmail_maildir.cxx @@ -80,7 +80,7 @@ void FilterKMail_maildir::import( FilterInfo *info ) } } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } @@ -125,7 +125,7 @@ TQString FilterKMail_maildir::getMessageFlags( FilterInfo *info, const TQString& TQFile mailfile( fileName ); if (! mailfile.open( IO_ReadOnly ) ) { - info->alert( i18n("Unable to open %1, skipping").arg( fileName ) ); + info->alert( i18n("Unable to open %1, skipping").tqarg( fileName ) ); return status_flag; } else { @@ -193,7 +193,7 @@ void FilterKMail_maildir::importFiles( FilterInfo *info, const TQString& dirName if(_path.endsWith("cur")) _path.remove(_path.length() - 4 , 4); TQString _info = _path; - info->addLog(i18n("Import folder %1...").arg(_info.remove(0,12))); + info->addLog(i18n("Import folder %1...").tqarg(_info.remove(0,12))); info->setFrom(_info); info->setTo(_path); generatedPath = true; @@ -203,12 +203,12 @@ void FilterKMail_maildir::importFiles( FilterInfo *info, const TQString& dirName if(info->removeDupMsg) { if(! addMessage( info, _path, dir.filePath(*mailFile), msg_flag )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } info->setCurrent((int) ((float) currentFile / numFiles * 100)); } else { if(! addMessage_fastImport( info, _path, dir.filePath(*mailFile), msg_flag )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } info->setCurrent((int) ((float) currentFile / numFiles * 100)); } diff --git a/kmailcvt/filter_lnotes.cxx b/kmailcvt/filter_lnotes.cxx index c14d32adf..0fcb345ea 100644 --- a/kmailcvt/filter_lnotes.cxx +++ b/kmailcvt/filter_lnotes.cxx @@ -61,7 +61,7 @@ void FilterLNotes::import(FilterInfo *info) { for ( TQStringList::Iterator filename = filenames.begin(); filename != filenames.end(); ++filename ) { ++currentFile; - info->addLog( i18n("Importing emails from %1").arg(*filename) ); + info->addLog( i18n("Importing emails from %1").tqarg(*filename) ); ImportLNotes( *filename ); inf->setOverall( 100 * currentFile / totalFiles ); if ( info->shouldTerminate() ) @@ -85,7 +85,7 @@ void FilterLNotes::ImportLNotes(const TQString& file) { TQFile f(file); if (! f.open( IO_ReadOnly ) ) { - inf->alert( i18n("Unable to open %1, skipping").arg( file ) ); + inf->alert( i18n("Unable to open %1, skipping").tqarg( file ) ); } else { int ch = 0; @@ -106,7 +106,7 @@ void FilterLNotes::ImportLNotes(const TQString& file) { // open temp output file tempfile = new KTempFile; state = 1; - inf->setCurrent(i18n("Message %1").arg(n++)); + inf->setCurrent(i18n("Message %1").tqarg(n++)); if ( inf->shouldTerminate() ) return; // fall through diff --git a/kmailcvt/filter_mailapp.cxx b/kmailcvt/filter_mailapp.cxx index f1c3bc727..d50f28c8a 100644 --- a/kmailcvt/filter_mailapp.cxx +++ b/kmailcvt/filter_mailapp.cxx @@ -59,7 +59,7 @@ void FilterMailApp::import(FilterInfo *info) if ( info->shouldTerminate() ) break; TQFile mbox( *filename ); if (! mbox.open( IO_ReadOnly ) ) { - info->alert( i18n("Unable to open %1, skipping").arg( *filename ) ); + info->alert( i18n("Unable to open %1, skipping").tqarg( *filename ) ); } else { TQFileInfo filenameInfo( *filename ); kdDebug() << "importing filename " << *filename << endl; @@ -67,7 +67,7 @@ void FilterMailApp::import(FilterInfo *info) TQString folderName(name[name.count() - 2]); info->setCurrent(0); - info->addLog( i18n("Importing emails from %1...").arg( *filename ) ); + info->addLog( i18n("Importing emails from %1...").tqarg( *filename ) ); info->setFrom( *filename ); info->setTo( folderName ); @@ -123,10 +123,10 @@ void FilterMailApp::import(FilterInfo *info) if ( info->shouldTerminate() ) break; } - info->addLog( i18n("Finished importing emails from %1").arg( *filename ) ); + info->addLog( i18n("Finished importing emails from %1").tqarg( *filename ) ); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported to folder %1 in KMail", - "%n duplicate messages not imported to folder %1 in KMail", count_duplicates).arg(folderName)); + "%n duplicate messages not imported to folder %1 in KMail", count_duplicates).tqarg(folderName)); } count_duplicates = 0; mbox.close(); diff --git a/kmailcvt/filter_mbox.cxx b/kmailcvt/filter_mbox.cxx index 0a7b08ff1..f456b1084 100644 --- a/kmailcvt/filter_mbox.cxx +++ b/kmailcvt/filter_mbox.cxx @@ -51,13 +51,13 @@ void FilterMBox::import(FilterInfo *info) for ( TQStringList::Iterator filename = filenames.begin(); filename != filenames.end(); ++filename, ++currentFile) { TQFile mbox( *filename ); if (! mbox.open( IO_ReadOnly ) ) { - info->alert( i18n("Unable to open %1, skipping").arg( *filename ) ); + info->alert( i18n("Unable to open %1, skipping").tqarg( *filename ) ); } else { TQFileInfo filenameInfo( *filename ); TQString folderName( "MBOX-" + filenameInfo.baseName(TRUE) ); info->setCurrent(0); - info->addLog( i18n("Importing emails from %1...").arg( *filename ) ); + info->addLog( i18n("Importing emails from %1...").tqarg( *filename ) ); info->setFrom( *filename ); info->setTo( folderName ); @@ -129,11 +129,11 @@ void FilterMBox::import(FilterInfo *info) if ( info->shouldTerminate() ) break; } - info->addLog( i18n("Finished importing emails from %1").arg( *filename )); + info->addLog( i18n("Finished importing emails from %1").tqarg( *filename )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported to folder %1 in KMail", "%n duplicate messages not imported to folder %1 in KMail", - count_duplicates).arg(folderName)); + count_duplicates).tqarg(folderName)); } if (info->shouldTerminate()) info->addLog( i18n("Finished import, canceled by user.")); count_duplicates = 0; diff --git a/kmailcvt/filter_oe.cxx b/kmailcvt/filter_oe.cxx index fb9d552a3..40f3da26d 100644 --- a/kmailcvt/filter_oe.cxx +++ b/kmailcvt/filter_oe.cxx @@ -64,7 +64,7 @@ void FilterOE::import(FilterInfo *info) TQDir dir (mailDir); TQStringList files = dir.entryList("*.[dDmM][bB][xX]", TQDir::Files, TQDir::Name); if (files.isEmpty()) { - info->alert(i18n("No Outlook Express mailboxes found in directory %1.").arg(mailDir)); + info->alert(i18n("No Outlook Express mailboxes found in directory %1.").tqarg(mailDir)); return; } @@ -116,7 +116,7 @@ void FilterOE::importMailBox( FilterInfo *info, const TQString& fileName) info->setFrom(mailfileinfo.fileName()); if (!mailfile.open(IO_ReadOnly)) { - info->addLog(i18n("Unable to open mailbox %1").arg(fileName)); + info->addLog(i18n("Unable to open mailbox %1").tqarg(fileName)); return; } TQDataStream mailbox(&mailfile); @@ -127,7 +127,7 @@ void FilterOE::importMailBox( FilterInfo *info, const TQString& fileName) mailbox >> sig_block1 >> sig_block2; if (sig_block1 == OE4_SIG_1 && sig_block2 == OE4_SIG_2) { folderName = "OE-Import/" + mailfileinfo.baseName(TRUE); - info->addLog(i18n("Importing OE4 Mailbox %1").arg( "../" + _nameOfFile)); + info->addLog(i18n("Importing OE4 Mailbox %1").tqarg( "../" + _nameOfFile)); info->setTo(folderName); mbxImport(info, mailbox); return; @@ -141,13 +141,13 @@ void FilterOE::importMailBox( FilterInfo *info, const TQString& fileName) TQString _tmpFolder = getFolderName(_nameOfFile); if(!_tmpFolder.isEmpty()) folderName = "OE-Import/" + _tmpFolder; } - info->addLog(i18n("Importing OE5+ Mailbox %1").arg( "../" + _nameOfFile)); + info->addLog(i18n("Importing OE5+ Mailbox %1").tqarg( "../" + _nameOfFile)); info->setTo(folderName); dbxImport(info, mailbox); return; } else if (sig_block2 == OE5_FOLDER_SIG_2) { if(!parsedFolder) { - info->addLog(i18n("Importing OE5+ Folder file %1").arg( "../" + _nameOfFile)); + info->addLog(i18n("Importing OE5+ Folder file %1").tqarg( "../" + _nameOfFile)); currentIsFolderFile = true; dbxImport(info, mailbox); currentIsFolderFile = false; @@ -156,7 +156,7 @@ void FilterOE::importMailBox( FilterInfo *info, const TQString& fileName) } } } - // info->addLog(i18n("File %1 does not seem to be an Outlook Express mailbox").arg("../" + _nameOfFile)); + // info->addLog(i18n("File %1 does not seem to be an Outlook Express mailbox").tqarg("../" + _nameOfFile)); } /* ------------------- MBX support ------------------- */ diff --git a/kmailcvt/filter_opera.cxx b/kmailcvt/filter_opera.cxx index d584263d5..b0f362474 100644 --- a/kmailcvt/filter_opera.cxx +++ b/kmailcvt/filter_opera.cxx @@ -84,9 +84,9 @@ void FilterOpera::import(FilterInfo *info) info->setCurrent(0); TQFile operaArchiv( importDir.filePath(*mailFile) ); if (! operaArchiv.open( IO_ReadOnly ) ) { - info->alert( i18n("Unable to open %1, skipping").arg( *mailFile ) ); + info->alert( i18n("Unable to open %1, skipping").tqarg( *mailFile ) ); } else { - info->addLog( i18n("Importing emails from %1...").arg( *mailFile ) ); + info->addLog( i18n("Importing emails from %1...").tqarg( *mailFile ) ); TQFileInfo filenameInfo( importDir.filePath(*mailFile) ); TQString folderName( "OPERA-" + importDir.dirName() ); @@ -138,7 +138,7 @@ void FilterOpera::import(FilterInfo *info) if ( info->shouldTerminate() ) break; } - info->addLog( i18n("Finished importing emails from %1").arg( *mailFile )); + info->addLog( i18n("Finished importing emails from %1").tqarg( *mailFile )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } diff --git a/kmailcvt/filter_outlook.cxx b/kmailcvt/filter_outlook.cxx index bbb32de79..f222d88c7 100644 --- a/kmailcvt/filter_outlook.cxx +++ b/kmailcvt/filter_outlook.cxx @@ -54,8 +54,8 @@ void FilterOutlook::import(FilterInfo *info) TQDir importDir (outlookDir); TQStringList files = importDir.entryList("*.[pP][sS][tT]", TQDir::Files, TQDir::Name); for ( TQStringList::Iterator pstFile = files.begin(); pstFile != files.end(); ++pstFile) { - info->addLog( i18n("Importing emails from %1...").arg( *pstFile ) ); + info->addLog( i18n("Importing emails from %1...").tqarg( *pstFile ) ); info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); - info->alert( i18n("Unable to open %1, skipping").arg( *pstFile ) ); + info->alert( i18n("Unable to open %1, skipping").tqarg( *pstFile ) ); } } diff --git a/kmailcvt/filter_plain.cxx b/kmailcvt/filter_plain.cxx index 45cdbf88f..2b3a3e823 100644 --- a/kmailcvt/filter_plain.cxx +++ b/kmailcvt/filter_plain.cxx @@ -64,11 +64,11 @@ void FilterPlain::import(FilterInfo *info) */ if(info->removeDupMsg) { if(! addMessage( info, "PLAIN-" + dir.dirName(), dir.filePath(*mailFile) )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } } else { if( ! addMessage_fastImport( info, "PLAIN-" + dir.dirName(), dir.filePath(*mailFile) )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } } @@ -77,7 +77,7 @@ void FilterPlain::import(FilterInfo *info) if ( info->shouldTerminate() ) break; } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } diff --git a/kmailcvt/filter_pmail.cxx b/kmailcvt/filter_pmail.cxx index f0386d902..bc412f345 100644 --- a/kmailcvt/filter_pmail.cxx +++ b/kmailcvt/filter_pmail.cxx @@ -76,7 +76,7 @@ void FilterPMail::import(FilterInfo *info) info->addLog(i18n("Importing 'UNIX' mail folders ('.mbx')...")); processFiles("*.[mM][bB][xX]", &FilterPMail::importUnixMailFolder); - info->addLog( i18n("Finished importing emails from %1").arg( chosenDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( chosenDir )); info->setCurrent(100); info->setOverall(100); } @@ -162,7 +162,7 @@ void FilterPMail::importMailFolder(const TQString& file) long l = 0; TQFile f(file); if (!f.open(IO_ReadOnly)) { - inf->alert(i18n("Unable to open %1, skipping").arg(file)); + inf->alert(i18n("Unable to open %1, skipping").tqarg(file)); } else { // Get folder name l = f.readBlock((char *) &pmm_head, sizeof(pmm_head)); @@ -172,7 +172,7 @@ void FilterPMail::importMailFolder(const TQString& file) else folder.append(pmm_head.folder); inf->setTo(folder); - inf->addLog(i18n("Importing %1").arg("../" + TQString(pmm_head.folder))); + inf->addLog(i18n("Importing %1").tqarg("../" + TQString(pmm_head.folder))); TQByteArray input(MAX_LINE); bool first_msg = true; @@ -232,7 +232,7 @@ void FilterPMail::importUnixMailFolder(const TQString& file) s.tqreplace( TQRegExp("MBX$"), "PMG"); f.setName(s); if (! f.open( IO_ReadOnly ) ) { - inf->alert( i18n("Unable to open %1, skipping").arg( s ) ); + inf->alert( i18n("Unable to open %1, skipping").tqarg( s ) ); return; } else { f.readBlock((char *) &pmg_head, sizeof(pmg_head)); @@ -250,9 +250,9 @@ void FilterPMail::importUnixMailFolder(const TQString& file) /** Read in the mbox */ f.setName(file); if (! f.open( IO_ReadOnly ) ) { - inf->alert( i18n("Unable to open %1, skipping").arg( s ) ); + inf->alert( i18n("Unable to open %1, skipping").tqarg( s ) ); } else { - inf->addLog(i18n("Importing %1").arg("../" + TQString(pmg_head.folder))); + inf->addLog(i18n("Importing %1").tqarg("../" + TQString(pmg_head.folder))); l = f.readLine( line.data(),MAX_LINE); // read the first line which is unneeded while ( ! f.atEnd() ) { KTempFile tempfile; @@ -276,7 +276,7 @@ void FilterPMail::importUnixMailFolder(const TQString& file) tempfile.unlink(); n++; - inf->setCurrent(i18n("Message %1").arg(n)); + inf->setCurrent(i18n("Message %1").tqarg(n)); inf->setCurrent( (int) ( ( (float) f.at() / f.size() ) * 100 ) ); } } @@ -291,7 +291,7 @@ bool FilterPMail::parseFolderMatrix() TQFile hierarch(chosenDir + "/hierarch.pm"); if (! hierarch.open( IO_ReadOnly ) ) { - inf->alert( i18n("Unable to open %1, skipping").arg( chosenDir + "hierarch.pm" ) ); + inf->alert( i18n("Unable to open %1, skipping").tqarg( chosenDir + "hierarch.pm" ) ); return false; } else { TQStringList tmpList; diff --git a/kmailcvt/filter_sylpheed.cxx b/kmailcvt/filter_sylpheed.cxx index 9d6b219ae..47c134b47 100644 --- a/kmailcvt/filter_sylpheed.cxx +++ b/kmailcvt/filter_sylpheed.cxx @@ -75,7 +75,7 @@ void FilterSylpheed::import( FilterInfo *info ) } } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } @@ -137,7 +137,7 @@ void FilterSylpheed::importFiles( FilterInfo *info, const TQString& dirName) _tmp = _tmp.remove(_tmp.length() - _mfile.length() -1, _mfile.length()+1); _path += _tmp.remove( mailDir ,TRUE); TQString _info = _path; - info->addLog(i18n("Import folder %1...").arg(_info.remove(0,15))); + info->addLog(i18n("Import folder %1...").tqarg(_info.remove(0,15))); info->setFrom(_info); info->setTo(_path); @@ -150,12 +150,12 @@ void FilterSylpheed::importFiles( FilterInfo *info, const TQString& dirName) if(info->removeDupMsg) { if(! addMessage( info, _path, dir.filePath(*mailFile), flags )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } info->setCurrent((int) ((float) currentFile / numFiles * 100)); } else { if(! addMessage_fastImport( info, _path, dir.filePath(*mailFile), flags )) { - info->addLog( i18n("Could not import %1").arg( *mailFile ) ); + info->addLog( i18n("Could not import %1").tqarg( *mailFile ) ); } info->setCurrent((int) ((float) currentFile / numFiles * 100)); } diff --git a/kmailcvt/filter_thebat.cxx b/kmailcvt/filter_thebat.cxx index b2e737dad..1ec747789 100644 --- a/kmailcvt/filter_thebat.cxx +++ b/kmailcvt/filter_thebat.cxx @@ -81,7 +81,7 @@ void FilterTheBat::import( FilterInfo *info ) } } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if (count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } @@ -148,7 +148,7 @@ void FilterTheBat::importFiles( FilterInfo *info, const TQString& FileName) TQValueList<long> offsets; if (!tbb.open(IO_ReadOnly)) { - info->alert(i18n("Unable to open %1, skipping").arg(FileName)); + info->alert(i18n("Unable to open %1, skipping").tqarg(FileName)); } else { // BUILD the index of messages : // We need this really ugly way, because read with tbb.readLine() @@ -171,7 +171,7 @@ void FilterTheBat::importFiles( FilterInfo *info, const TQString& FileName) iFound = _tmp.tqcontains(regexp); if(!iFound) { - iFound = _tmp.findRev("!"); + iFound = _tmp.tqfindRev("!"); if (iFound >= 0 && ((l-iFound) < 5) ) { int _i = tbb.at(); tbb.at((_i - iFound)); @@ -182,7 +182,7 @@ void FilterTheBat::importFiles( FilterInfo *info, const TQString& FileName) offsets.append(endOfEmail); } } - // info->addLog(i18n("--COUNTED: %1").arg(count)); + // info->addLog(i18n("--COUNTED: %1").tqarg(count)); // IMPORT the messages: if(!offsets.empty() || (offsets.empty() && (tbb.size() > 3128))) { @@ -196,7 +196,7 @@ void FilterTheBat::importFiles( FilterInfo *info, const TQString& FileName) _tmp = _tmp.remove(_tmp.length() - 13, 13); _path += _tmp.remove( mailDir ,TRUE); TQString _info = _path; - info->addLog(i18n("Import folder %1...").arg(_info.remove(0,14))); + info->addLog(i18n("Import folder %1...").tqarg(_info.remove(0,14))); info->setTo(_path); info->setFrom("../" + _info + "/messages.tbb"); diff --git a/kmailcvt/filter_thunderbird.cxx b/kmailcvt/filter_thunderbird.cxx index a058e28d3..e0c4060eb 100644 --- a/kmailcvt/filter_thunderbird.cxx +++ b/kmailcvt/filter_thunderbird.cxx @@ -91,12 +91,12 @@ void FilterThunderbird::import(FilterInfo *info) TQString temp_mailfile = *mailFile; if (temp_mailfile.endsWith(".msf") || temp_mailfile.endsWith("msgFilterRules.dat")) {} else { - info->addLog( i18n("Start import file %1...").arg( temp_mailfile ) ); + info->addLog( i18n("Start import file %1...").tqarg( temp_mailfile ) ); importMBox(info, mailDir + temp_mailfile , temp_mailfile, TQString()); } } - info->addLog( i18n("Finished importing emails from %1").arg( mailDir )); + info->addLog( i18n("Finished importing emails from %1").tqarg( mailDir )); if(count_duplicates > 0) { info->addLog( i18n("1 duplicate message not imported", "%n duplicate messages not imported", count_duplicates)); } @@ -126,7 +126,7 @@ void FilterThunderbird::importDirContents(FilterInfo *info, const TQString& dirN TQString temp_mailfile = *mailFile; if (temp_mailfile.endsWith(".msf") || temp_mailfile.endsWith("msgFilterRules.dat")) {} else { - info->addLog( i18n("Start import file %1...").arg( temp_mailfile ) ); + info->addLog( i18n("Start import file %1...").tqarg( temp_mailfile ) ); importMBox(info, (dirName + "/" + temp_mailfile) , KMailRootDir, KMailSubDir); } } @@ -158,7 +158,7 @@ void FilterThunderbird::importMBox(FilterInfo *info, const TQString& mboxName, c TQFile mbox(mboxName); bool first_msg = true; if (!mbox.open(IO_ReadOnly)) { - info->alert(i18n("Unable to open %1, skipping").arg(mboxName)); + info->alert(i18n("Unable to open %1, skipping").tqarg(mboxName)); } else { TQFileInfo filenameInfo(mboxName); diff --git a/kmailcvt/filters.cxx b/kmailcvt/filters.cxx index 02f83097a..aaaaa6da8 100644 --- a/kmailcvt/filters.cxx +++ b/kmailcvt/filters.cxx @@ -150,16 +150,16 @@ bool Filter::addMessage( FilterInfo* info, const TQString& folderName, switch ( int( reply ) ) { case -1: - info->alert( i18n( "Cannot make folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Cannot make folder %1 in KMail" ).tqarg( folderName ) ); return false; case -2: - info->alert( i18n( "Cannot add message to folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Cannot add message to folder %1 in KMail" ).tqarg( folderName ) ); return false; case -4: count_duplicates++; return false; case 0: - info->alert( i18n( "Error while adding message to folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Error while adding message to folder %1 in KMail" ).tqarg( folderName ) ); return false; } return true; @@ -185,13 +185,13 @@ bool Filter::addMessage_fastImport( FilterInfo* info, const TQString& folderName switch ( int( reply ) ) { case -1: - info->alert( i18n( "Cannot make folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Cannot make folder %1 in KMail" ).tqarg( folderName ) ); return false; case -2: - info->alert( i18n( "Cannot add message to folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Cannot add message to folder %1 in KMail" ).tqarg( folderName ) ); return false; case 0: - info->alert( i18n( "Error while adding message to folder %1 in KMail" ).arg( folderName ) ); + info->alert( i18n( "Error while adding message to folder %1 in KMail" ).tqarg( folderName ) ); return false; } return true; diff --git a/kmailcvt/kselfilterpage.cpp b/kmailcvt/kselfilterpage.cpp index e8a7ce32d..daac374fe 100644 --- a/kmailcvt/kselfilterpage.cpp +++ b/kmailcvt/kselfilterpage.cpp @@ -75,7 +75,7 @@ void KSelFilterPage::filterSelected(int i) TQString info = mFilterList.at(i)->info(); TQString author = mFilterList.at(i)->author(); if(!author.isEmpty()) - info += i18n("<p><i>Written by %1.</i></p>").arg(author); + info += i18n("<p><i>Written by %1.</i></p>").tqarg(author); mDesc->setText(info); } diff --git a/kmobile/devices/gnokii/gnokii_mobile.cpp b/kmobile/devices/gnokii/gnokii_mobile.cpp index dabccb89b..7ceb5ea7c 100644 --- a/kmobile/devices/gnokii/gnokii_mobile.cpp +++ b/kmobile/devices/gnokii/gnokii_mobile.cpp @@ -48,7 +48,7 @@ #define GNOKII_CHECK_ERROR(error) \ do { \ if (error) \ - PRINT_DEBUG << TQString("ERROR %1: %2\n").arg(error).arg(gn_error_print(error));\ + PRINT_DEBUG << TQString("ERROR %1: %2\n").tqarg(error).tqarg(gn_error_print(error));\ } while (0) @@ -103,8 +103,8 @@ KMobileGnokii::KMobileGnokii(TQObject *obj, const char *name, const TQStringList m_baud = "9600"; } - PRINT_DEBUG << TQString("Using GNOKII configuration: %1 %2 %3 %4\n").arg(m_modelnr) - .arg(m_connection).arg(m_port).arg(m_baud); + PRINT_DEBUG << TQString("Using GNOKII configuration: %1 %2 %3 %4\n").tqarg(m_modelnr) + .tqarg(m_connection).tqarg(m_port).tqarg(m_baud); saveDeviceConfiguration(); saveGnokiiConfiguration(); @@ -237,7 +237,7 @@ static TQString businit(void) state.config.require_dcd = old_dcd; if (error != GN_ERR_NONE) { busterminate(); - return i18n("Mobile phone interface initialization failed:\n%1").arg(gn_error_print(error)); + return i18n("Mobile phone interface initialization failed:\n%1").tqarg(gn_error_print(error)); } // model @@ -265,9 +265,9 @@ static TQString businit(void) data.imei = NULL; GNOKII_DEBUG( TQString("Found mobile phone: Model: %1, Revision: %2, IMEI: %3\n") - .arg(model).arg(revision).arg(imei) ); + .tqarg(model).tqarg(revision).tqarg(imei) ); - PhoneProductId = TQString("%1-%2-%3-%4").arg(APP).arg(model).arg(revision).arg(imei); + PhoneProductId = TQString("%1-%2-%3-%4").tqarg(APP).tqarg(model).tqarg(revision).tqarg(imei); return TQString(); } @@ -299,7 +299,7 @@ static gn_error read_phone_memstat( gn_memory_type memtype, gn_memory_status *me } } GNOKII_DEBUG( TQString("\n\nMobile phone memory status: Type: %1, used=%2, free=%3, total=%4\n\n") - .arg(memtype).arg(memstat->used).arg(memstat->free).arg(memstat->used+memstat->free) ); + .tqarg(memtype).tqarg(memstat->used).tqarg(memstat->free).tqarg(memstat->used+memstat->free) ); return error; } @@ -372,8 +372,8 @@ static gn_error read_phone_entry_highlevel( int index, const gn_memory_type memt if (error != GN_ERR_NONE) return error; - GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").arg(index).arg(entry.name) - .arg(entry.number).arg(entry.location).arg(entry.caller_group).arg(entry.subentries_count)); + GNOKII_DEBUG(TQString("%1: %2, num=%3, location=%4, group=%5, count=%6\n").tqarg(index).tqarg(entry.name) + .tqarg(entry.number).tqarg(entry.location).tqarg(entry.caller_group).tqarg(entry.subentries_count)); // try to split Name into FamilyName and GivenName s = TQString(entry.name).simplifyWhiteSpace(); @@ -395,7 +395,7 @@ static gn_error read_phone_entry_highlevel( int index, const gn_memory_type memt } a->insertCustom(APP, "X_GSM_CALLERGROUP", s.setNum(entry.caller_group)); - a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1_%2").arg(GN_MT_ME).arg(entry.location)); + a->insertCustom(APP, "X_GSM_STORE_AT", TQString("%1_%2").tqarg(GN_MT_ME).tqarg(entry.location)); // set ProductId a->setProductId(PhoneProductId); @@ -407,7 +407,7 @@ static gn_error read_phone_entry_highlevel( int index, const gn_memory_type memt else datetime = TQDateTime( TQDate(entry.date.year, entry.date.month, entry.date.day), TQTime(entry.date.hour, entry.date.minute, entry.date.second) ); - GNOKII_DEBUG(TQString(" date=%1\n").arg(datetime.toString())); + GNOKII_DEBUG(TQString(" date=%1\n").tqarg(datetime.toString())); a->setRevision(datetime); if (!entry.subentries_count) @@ -418,8 +418,8 @@ static gn_error read_phone_entry_highlevel( int index, const gn_memory_type memt for (int n=0; n<entry.subentries_count; n++) { TQString s = TQString(entry.subentries[n].data.number).simplifyWhiteSpace(); GNOKII_DEBUG(TQString(" Subentry#%1, entry_type=%2, number_type=%3, number=%4\n") - .arg(n).arg(entry.subentries[n].entry_type) - .arg(entry.subentries[n].number_type).arg(s)); + .tqarg(n).tqarg(entry.subentries[n].entry_type) + .tqarg(entry.subentries[n].number_type).tqarg(s)); if (s.isEmpty()) continue; switch(entry.subentries[n].entry_type) { @@ -478,7 +478,7 @@ static gn_error read_phone_entry_highlevel( int index, const gn_memory_type memt break; default: GNOKII_DEBUG(TQString(" Not handled id=%1, entry=%2\n") - .arg(entry.subentries[n].entry_type).arg(s)); + .tqarg(entry.subentries[n].entry_type).tqarg(s)); break; } // switch() } // for(subentry) @@ -501,7 +501,7 @@ bool KMobileGnokii::connectDevice(TQWidget * /*tqparent*/) TQString err = businit(); m_connected = err.isEmpty(); - PRINT_DEBUG << TQString("connectDevice() : %1\n").arg(m_connected ? "Ok" : err); + PRINT_DEBUG << TQString("connectDevice() : %1\n").tqarg(m_connected ? "Ok" : err); return m_connected; } @@ -512,7 +512,7 @@ bool KMobileGnokii::disconnectDevice(TQWidget * /*tqparent*/) return true; busterminate(); m_connected = false; - PRINT_DEBUG << TQString("disconnectDevice() : %1\n").arg("done"); + PRINT_DEBUG << TQString("disconnectDevice() : %1\n").tqarg("done"); return true; } @@ -547,7 +547,7 @@ TQString KMobileGnokii::iconFileName() const // this String is used to have a unique identification for syncronisation. TQString KMobileGnokii::tqdeviceUniqueID() { - return TQString("GNOKII-IMEI-%1").arg(TQString::fromLocal8Bit(imei)); + return TQString("GNOKII-IMEI-%1").tqarg(TQString::fromLocal8Bit(imei)); } @@ -587,7 +587,7 @@ int KMobileGnokii::numAddresses() int KMobileGnokii::readAddress( int index, KABC::Addressee &addr ) { - PRINT_DEBUG << TQString("############ GET ADDRESS #%1\n").arg(index); + PRINT_DEBUG << TQString("############ GET ADDRESS #%1\n").tqarg(index); // index is zero-based, but in gnokii the first address starts at 1 if (index<0 || index>=numAddresses()) return KIO::ERR_DOES_NOT_EXIST; @@ -870,8 +870,8 @@ int KMobileGnokii::readNote( int index, TQString ¬e ) "DeviceClassName: %3\n" "Device Driver : %4\n" "Device Revision: %5\n") - .arg(index).arg(index) - .arg(tqdeviceClassName()).arg(tqdeviceName()).arg(revision()); + .tqarg(index).tqarg(index) + .tqarg(tqdeviceClassName()).tqarg(tqdeviceName()).tqarg(revision()); return 0; } diff --git a/kmobile/devices/skeleton/skeleton.cpp b/kmobile/devices/skeleton/skeleton.cpp index c027baaeb..c1bcd4929 100644 --- a/kmobile/devices/skeleton/skeleton.cpp +++ b/kmobile/devices/skeleton/skeleton.cpp @@ -64,7 +64,7 @@ KMobileSkeleton::~KMobileSkeleton() bool KMobileSkeleton::connectDevice(TQWidget *tqparent) { if (KMessageBox::Continue != KMessageBox::warningContinueCancel(tqparent, - i18n("Please turn on your %1 on now and press continue to proceed.").arg(m_tqdeviceName), + i18n("Please turn on your %1 on now and press continue to proceed.").tqarg(m_tqdeviceName), m_tqdeviceClassName ) ) return false; // connect it now... @@ -112,7 +112,7 @@ int KMobileSkeleton::readAddress( int index, KABC::Addressee &addr ) return KIO::ERR_DOES_NOT_EXIST; // now build our own sample name - addr.setFamilyName(TQString("Meyer_%1").arg(index+1)); + addr.setFamilyName(TQString("Meyer_%1").tqarg(index+1)); addr.setGivenName("Peter"); addr.setFormattedName("Peter "+addr.familyName()); addr.setNickName("PeterM"); @@ -156,8 +156,8 @@ int KMobileSkeleton::readNote( int index, TQString ¬e ) "DeviceClassName: %3\n" "Device Driver : %4\n" "Device Revision: %5\n") - .arg(index).arg(index) - .arg(tqdeviceClassName()).arg(tqdeviceName()).arg(revision()); + .tqarg(index).tqarg(index) + .tqarg(tqdeviceClassName()).tqarg(tqdeviceName()).tqarg(revision()); return 0; } diff --git a/kmobile/kioslave/kio_mobile.cpp b/kmobile/kioslave/kio_mobile.cpp index b22930e2b..94d803306 100644 --- a/kmobile/kioslave/kio_mobile.cpp +++ b/kmobile/kioslave/kio_mobile.cpp @@ -84,7 +84,7 @@ int KMobileProtocol::getDeviceAndRessource(const TQString &_path, TQString &devName, TQString &resource, TQString &devPath, KMobileDevice::Capabilities &devCaps) { -// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").arg(_path); +// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").tqarg(_path); TQStringList path = TQStringList::split('/', _path, false); devName = resource = devPath = TQString(); @@ -140,7 +140,7 @@ void createDirEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& addAtom(entry, KIO::UDS_URL, 0, url); addAtom(entry, KIO::UDS_USER, 0, getenv("USER")); addAtom(entry, KIO::UDS_GROUP, 0, getenv("USER")); - PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").arg(name).arg(mime).arg(url); + PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").tqarg(name).tqarg(mime).tqarg(url); // addAtom(entry, KIO::UDS_SIZE, 0); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); } @@ -159,7 +159,7 @@ void createFileEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& addAtom(entry, KIO::UDS_MIME_TYPE, 0, mime); if (size) addAtom(entry, KIO::UDS_SIZE, size); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); - PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").arg(name).arg(size).arg(mime); + PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").tqarg(name).tqarg(size).tqarg(mime); } @@ -169,7 +169,7 @@ void createFileEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& void KMobileProtocol::get(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("get(%1)\n").arg(url.path()); + PRINT_DEBUG << TQString("get(%1)\n").tqarg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -231,7 +231,7 @@ void KMobileProtocol::get(const KURL &url) */ void KMobileProtocol::listRoot(const KURL& url) { - PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").arg(url.path()).arg(url.protocol()); + PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").tqarg(url.path()).tqarg(url.protocol()); KIO::UDSEntry entry; @@ -312,7 +312,7 @@ TQString KMobileProtocol::entryMimeType(int cap) void KMobileProtocol::listTopDeviceDir(const TQString &devName) { - PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").arg(devName); + PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").tqarg(devName); KIO::UDSEntry entry; unsigned int caps = m_dev.capabilities(devName); @@ -325,7 +325,7 @@ void KMobileProtocol::listTopDeviceDir(const TQString &devName) TQString filename = m_dev.nameForCap(devName, cap); TQString mimetype = folderMimeType(cap); - createDirEntry(entry, filename, TQString("mobile:/%1/%2/").arg(devName).arg(filename), mimetype); + createDirEntry(entry, filename, TQString("mobile:/%1/%2/").tqarg(devName).tqarg(filename), mimetype); listEntry(entry, false); } listEntry(entry, true); @@ -340,7 +340,7 @@ void KMobileProtocol::listEntries(const TQString &devName, const TQString &resource, const TQString &devPath, const KMobileDevice::Capabilities devCaps) { - PRINT_DEBUG << TQString("listEntries(%1,%2,%3)\n").arg(devName).arg(resource).arg(devPath); + PRINT_DEBUG << TQString("listEntries(%1,%2,%3)\n").tqarg(devName).tqarg(resource).tqarg(devPath); switch (devCaps) { case KMobileDevice::hasAddressBook: listAddressBook(devName, resource); break; @@ -351,7 +351,7 @@ void KMobileProtocol::listEntries(const TQString &devName, case KMobileDevice::hasFileStorage: listFileStorage(devName, resource, devPath); break; default: error( ERR_CANNOT_ENTER_DIRECTORY, - TQString("/%1/%2").arg(devName).arg(resource) ); + TQString("/%1/%2").tqarg(devName).tqarg(resource) ); } } @@ -360,7 +360,7 @@ void KMobileProtocol::listEntries(const TQString &devName, */ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listAddressBook(%1)\n").arg(devName); + PRINT_DEBUG << TQString("listAddressBook(%1)\n").tqarg(devName); KIO::UDSEntry entry; @@ -382,11 +382,11 @@ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &r name = "_" + rx.cap(1); #endif - TQString filename = TQString("%1%2.vcf").arg(i,fieldwidth).arg(name); + TQString filename = TQString("%1%2.vcf").tqarg(i,fieldwidth).tqarg(name); for (int p=0; p<fieldwidth; p++) { if (filename[p]==' ') filename[p]='0'; else break; } - TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); + TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasAddressBook), 400 /*content.utf8().length()*/ ); @@ -403,7 +403,7 @@ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &r */ int KMobileProtocol::getVCard( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ) { - PRINT_DEBUG << TQString("getVCard(%1)\n").arg(path); + PRINT_DEBUG << TQString("getVCard(%1)\n").tqarg(path); int index = path.tqfind('.'); if (index>0) @@ -425,7 +425,7 @@ int KMobileProtocol::getVCard( const TQString &devName, TQCString &result, TQStr */ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listCalendar(%1)\n").arg(devName); + PRINT_DEBUG << TQString("listCalendar(%1)\n").tqarg(devName); KIO::UDSEntry entry; @@ -433,8 +433,8 @@ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &res totalSize(entries); for (int i=0; i<entries; i++) { - TQString filename = TQString("%1_%2.vcs").arg(i).arg(i18n("calendar")); - TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); + TQString filename = TQString("%1_%2.vcs").tqarg(i).tqarg(i18n("calendar")); + TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasCalendar)); listEntry(entry, false); @@ -450,7 +450,7 @@ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &res */ int KMobileProtocol::getCalendar( const TQString &devName, TQCString &result, TQString &mime, const TQString &path) { - PRINT_DEBUG << TQString("getCalendar(%1, #%2)\n").arg(devName).arg(path); + PRINT_DEBUG << TQString("getCalendar(%1, #%2)\n").tqarg(devName).tqarg(path); /* TODO */ Q_UNUSED(result); @@ -464,7 +464,7 @@ int KMobileProtocol::getCalendar( const TQString &devName, TQCString &result, TQ */ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listNotes(%1)\n").arg(devName); + PRINT_DEBUG << TQString("listNotes(%1)\n").tqarg(devName); KIO::UDSEntry entry; @@ -474,8 +474,8 @@ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resour TQString note /*= m_dev.readNote(devName, i)*/; - TQString filename = TQString("%1_%2.txt").arg(i).arg(i18n("note")); - TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); + TQString filename = TQString("%1_%2.txt").tqarg(i).tqarg(i18n("note")); + TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasNotes), 0 /*note.utf8().length()*/); @@ -492,7 +492,7 @@ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resour */ int KMobileProtocol::getNote( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ) { - PRINT_DEBUG << TQString("getNote(%1)\n").arg(path); + PRINT_DEBUG << TQString("getNote(%1)\n").tqarg(path); int index = path.tqfind('_'); if (index>0) @@ -514,10 +514,10 @@ int KMobileProtocol::getNote( const TQString &devName, TQCString &result, TQStri */ void KMobileProtocol::listFileStorage(const TQString &devName, const TQString &resource, const TQString &devPath) { - PRINT_DEBUG << TQString("listFileStorage(%1,%2)\n").arg(devName).arg(devPath); + PRINT_DEBUG << TQString("listFileStorage(%1,%2)\n").tqarg(devName).tqarg(devPath); /* TODO */ - error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").arg(devName).arg(resource).arg(devPath) ); + error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(devPath) ); } /* @@ -525,7 +525,7 @@ void KMobileProtocol::listFileStorage(const TQString &devName, const TQString &r */ int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, TQString &mime, const TQString &path) { - PRINT_DEBUG << TQString("getFileStorage(%1)\n").arg(path); + PRINT_DEBUG << TQString("getFileStorage(%1)\n").tqarg(path); /* TODO */ Q_UNUSED(devName); @@ -541,7 +541,7 @@ int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, void KMobileProtocol::stat( const KURL &url ) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("stat(%1)\n").arg(url.path()); + PRINT_DEBUG << TQString("stat(%1)\n").tqarg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -555,7 +555,7 @@ void KMobileProtocol::stat( const KURL &url ) TQStringList path = TQStringList::split('/', url.path(), false); TQString filename = (path.count()>0) ? path[path.count()-1] : "/"; TQString fullPath = path.join("/"); - TQString fullUrl = TQString("mobile:/%1").arg(fullPath); + TQString fullUrl = TQString("mobile:/%1").tqarg(fullPath); UDSEntry entry; @@ -577,7 +577,7 @@ void KMobileProtocol::stat( const KURL &url ) void KMobileProtocol::mimetype(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("mimetype(%1)\n").arg(url.path()); + PRINT_DEBUG << TQString("mimetype(%1)\n").tqarg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -599,7 +599,7 @@ void KMobileProtocol::mimetype(const KURL &url) void KMobileProtocol::listDir(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("listDir(%1)\n").arg(url.path()); + PRINT_DEBUG << TQString("listDir(%1)\n").tqarg(url.path()); if (!m_dev.isKMobileAvailable()) { error( KIO::ERR_CONNECTION_BROKEN, i18n("KDE Mobile Device Manager") ); @@ -622,7 +622,7 @@ void KMobileProtocol::listDir(const KURL &url) #if 0 if (!dev) { - error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1").arg(devName) ); + error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1").tqarg(devName) ); return; } #endif diff --git a/kmobile/kmobile.cpp b/kmobile/kmobile.cpp index a34215e4a..db2e1cd11 100644 --- a/kmobile/kmobile.cpp +++ b/kmobile/kmobile.cpp @@ -93,29 +93,29 @@ KMobile::~KMobile() void KMobile::setupActions() { - KStdAction::close(this, TQT_SLOT(dockApplication()), actionCollection()); - KStdAction::quit(kapp, TQT_SLOT(quit()), actionCollection()); + KStdAction::close(TQT_TQOBJECT(this), TQT_SLOT(dockApplication()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(quit()), actionCollection()); - m_toolbarAction = KStdAction::showToolbar(this, TQT_SLOT(optionsShowToolbar()), actionCollection()); + m_toolbarAction = KStdAction::showToolbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowToolbar()), actionCollection()); optionsShowToolbar(); - m_statusbarAction = KStdAction::showStatusbar(this, TQT_SLOT(optionsShowStatusbar()), actionCollection()); + m_statusbarAction = KStdAction::showStatusbar(TQT_TQOBJECT(this), TQT_SLOT(optionsShowStatusbar()), actionCollection()); - KStdAction::keyBindings(this, TQT_SLOT(optionsConfigureKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), actionCollection()); - KStdAction::preferences(this, TQT_SLOT(optionsPreferences()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(optionsPreferences()), actionCollection()); new KAction(i18n("&Add Device..."), "folder_new", 0, - this, TQT_SLOT(addDevice()), actionCollection(), "tqdevice_add"); + TQT_TQOBJECT(this), TQT_SLOT(addDevice()), actionCollection(), "tqdevice_add"); new KAction( KGuiItem( i18n("&Remove Device"), "edittrash", i18n("Remove this tqdevice") ), - "Delete", this, TQT_SLOT(removeDevice()), actionCollection(), "tqdevice_remove"); + "Delete", TQT_TQOBJECT(this), TQT_SLOT(removeDevice()), actionCollection(), "tqdevice_remove"); new KAction(i18n("Re&name Device..."), 0, Key_F2, - this, TQT_SLOT(renameDevice()), actionCollection(), "tqdevice_rename"); + TQT_TQOBJECT(this), TQT_SLOT(renameDevice()), actionCollection(), "tqdevice_rename"); new KAction(i18n("&Configure Device..."), "configure", 0, - this, TQT_SLOT(configDevice()), actionCollection(), "tqdevice_configure"); + TQT_TQOBJECT(this), TQT_SLOT(configDevice()), actionCollection(), "tqdevice_configure"); createGUI(); - connect( kapp, TQT_SIGNAL(aboutToQuit()), this, TQT_SLOT(saveAll()) ); + connect( kapp, TQT_SIGNAL(aboutToQuit()), TQT_TQOBJECT(this), TQT_SLOT(saveAll()) ); } @@ -273,7 +273,7 @@ void KMobile::addDevice() for ( it = list.begin(); it != list.end(); ++it ) { ptr = *it; kdDebug() << TQString("LIBRARY: '%1', NAME: '%2', ICON: '%3', COMMENT: '%4'\n") - .arg(ptr->library()).arg(ptr->name()).arg(ptr->icon()).arg(ptr->comment()); + .tqarg(ptr->library()).tqarg(ptr->name()).tqarg(ptr->icon()).tqarg(ptr->comment()); TQString iconName = ptr->icon(); if (iconName.isEmpty()) @@ -303,7 +303,7 @@ void KMobile::addDevice() TQString("<qt>KMobile could not load the <b>%1</b> Device Driver.<p>" "Please use the Skeleton- or Gnokii Device Driver during development.<p>" "This driver will still be visible, but you won't be able to access it " - "from Konqueror or any other application.</qt>").arg(ptr->name()), + "from Konqueror or any other application.</qt>").tqarg(ptr->name()), kapp->name()); } @@ -357,7 +357,7 @@ KMobileDevice * KMobileFactory::chooseDeviceDialog( TQWidget *tqparent, continue; // kdDebug() << TQString("LIBRARY: '%1', NAME: '%2', ICON: '%3', COMMENT: '%4' #%5\n") - // .arg(ptr->library()).arg(ptr->name()).arg(ptr->icon()).arg(ptr->comment()).arg(i); + // .tqarg(ptr->library()).tqarg(ptr->name()).tqarg(ptr->icon()).tqarg(ptr->comment()).tqarg(i); TQString iconName = ptr->icon(); if (iconName.isEmpty()) diff --git a/kmobile/kmobileclient.cpp b/kmobile/kmobileclient.cpp index 518185534..f587ee2c7 100644 --- a/kmobile/kmobileclient.cpp +++ b/kmobile/kmobileclient.cpp @@ -36,10 +36,10 @@ KMobileClient::KMobileClient() m_kmobileObj = "kmobileIface"; bool ok = attach(); - PRINT_DEBUG << TQString("attached to DCOP server %1\n").arg(ok?"sucessful.":"failed."); + PRINT_DEBUG << TQString("attached to DCOP server %1\n").tqarg(ok?"sucessful.":"failed."); // m_clientAppId = registerAs("kmobileclient"); -// PRINT_DEBUG << TQString("registered as DCOP client %1\n").arg(m_clientAppId); +// PRINT_DEBUG << TQString("registered as DCOP client %1\n").tqarg(m_clientAppId); isKMobileAvailable(); } @@ -54,7 +54,7 @@ KMobileClient::~KMobileClient() bool KMobileClient::isKMobileAvailable() { bool available = isApplicationRegistered(m_kmobileApp); - PRINT_DEBUG << TQString("KMobile DCOP server: %1\n").arg(available?"available.":"not available"); + PRINT_DEBUG << TQString("KMobile DCOP server: %1\n").tqarg(available?"available.":"not available"); if (!available) { startKMobileApplication(); // check again... @@ -73,7 +73,7 @@ bool KMobileClient::startKMobileApplication() TQCString replyType; TQByteArray replyData; bool ok = call("klauncher", "klauncher", "kdeinit_exec_wait(TQString,TQStringList)", data, replyType, replyData); - PRINT_DEBUG << TQString("DCOP-CALL to klauncher: %1\n").arg(ok?"ok.":"failed."); + PRINT_DEBUG << TQString("DCOP-CALL to klauncher: %1\n").tqarg(ok?"ok.":"failed."); return ok; } @@ -93,7 +93,7 @@ bool KMobileClient::startKMobileApplication() TQCString replyType; \ TQByteArray replyData; \ bool ok = call(m_kmobileApp, m_kmobileObj, FUNC, data, replyType, replyData, KMOBILECLIENT_USE_EVENTLOOP, KMOBILECLIENT_TIMEOUT); \ - PRINT_DEBUG << TQString("DCOP-CALL to %1: %2\n").arg(FUNC).arg(ok?"ok.":"FAILED.") + PRINT_DEBUG << TQString("DCOP-CALL to %1: %2\n").tqarg(FUNC).tqarg(ok?"ok.":"FAILED.") #define RETURN_TYPE( FUNC, PARAMS, RETURN_TYPE ) \ PREPARE( FUNC, PARAMS ); \ diff --git a/kmobile/kmobiledevice.cpp b/kmobile/kmobiledevice.cpp index 9fdddf6fa..cc25c3664 100644 --- a/kmobile/kmobiledevice.cpp +++ b/kmobile/kmobiledevice.cpp @@ -63,7 +63,7 @@ KMobileDevice::KMobileDevice(TQObject *obj, const char *name, const TQStringList m_config = new KConfig(); else m_config = new KConfig(m_configFileName); - PRINT_DEBUG << TQString("name of config file is %1\n").arg(m_configFileName); + PRINT_DEBUG << TQString("name of config file is %1\n").tqarg(m_configFileName); } KMobileDevice::~KMobileDevice() @@ -260,7 +260,7 @@ void KMobileDevice::createDirEntry(KIO::UDSEntry& entry, const TQString& name, c addAtom(entry, KIO::UDS_ACCESS, 0500); addAtom(entry, KIO::UDS_MIME_TYPE, 0, mime); addAtom(entry, KIO::UDS_URL, 0, url); - PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").arg(name).arg(mime).arg(url); + PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").tqarg(name).tqarg(mime).tqarg(url); // addAtom(entry, KIO::UDS_SIZE, 0); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); } @@ -276,7 +276,7 @@ void KMobileDevice::createFileEntry(KIO::UDSEntry& entry, const TQString& name, addAtom(entry, KIO::UDS_MIME_TYPE, 0, mime); if (size) addAtom(entry, KIO::UDS_SIZE, size); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); - PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").arg(name).arg(size).arg(mime); + PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").tqarg(name).tqarg(size).tqarg(mime); } @@ -385,7 +385,7 @@ bool KMobileDevice::lockDevice(const TQString &tqdevice, TQString &err_reason) int pid = -1; TQStringList all = TQStringList::split('/', tqdevice); if (!all.count()) { - err_reason = i18n("Invalid tqdevice (%1)").arg(tqdevice); + err_reason = i18n("Invalid tqdevice (%1)").tqarg(tqdevice); return false; } TQString lockName = DEVICE_LOCK_PATH_PREFIX + all[all.count()-1]; @@ -393,7 +393,7 @@ bool KMobileDevice::lockDevice(const TQString &tqdevice, TQString &err_reason) if (file.exists() && file.open(IO_ReadOnly)) { if (file.size() == 0) { err_reason = i18n("Unable to read lockfile %s. Please check for reason and " - "remove the lockfile by hand.").arg(lockName); + "remove the lockfile by hand.").tqarg(lockName); PRINT_DEBUG << err_reason; return false; } @@ -406,16 +406,16 @@ bool KMobileDevice::lockDevice(const TQString &tqdevice, TQString &err_reason) file.close(); if (pid > 0 && kill((pid_t)pid, 0) < 0 && errno == ESRCH) { - PRINT_DEBUG << TQString("Lockfile %1 is stale. Overriding it..\n").arg(lockName); + PRINT_DEBUG << TQString("Lockfile %1 is stale. Overriding it..\n").tqarg(lockName); sleep(1); if (!file.remove()) { PRINT_DEBUG << TQString("Overriding failed, please check the permissions\n"); - PRINT_DEBUG << TQString("Cannot lock tqdevice %1\n").arg(tqdevice); - err_reason = i18n("Lockfile %1 is stale. Please check permissions.").arg(lockName); + PRINT_DEBUG << TQString("Cannot lock tqdevice %1\n").tqarg(tqdevice); + err_reason = i18n("Lockfile %1 is stale. Please check permissions.").tqarg(lockName); return false; } } else { - err_reason = i18n("Device %1 already locked.").arg(tqdevice); + err_reason = i18n("Device %1 already locked.").tqarg(tqdevice); return false; } } @@ -424,22 +424,22 @@ bool KMobileDevice::lockDevice(const TQString &tqdevice, TQString &err_reason) int fd = open(lockName.local8Bit(), O_CREAT | O_EXCL | O_WRONLY, 0644); if (fd == -1) { if (errno == EEXIST) - err_reason = i18n("Device %1 seems to be locked by unknown process.").arg(tqdevice); + err_reason = i18n("Device %1 seems to be locked by unknown process.").tqarg(tqdevice); else if (errno == EACCES) err_reason = i18n("Please check permission on lock directory."); else if (errno == ENOENT) - err_reason = i18n("Cannot create lockfile %1. Please check for existence of path.").arg(lockName); + err_reason = i18n("Cannot create lockfile %1. Please check for existence of path.").tqarg(lockName); else - err_reason = i18n("Could not create lockfile %1. Error-Code is %2.").arg(lockName).arg(errno); + err_reason = i18n("Could not create lockfile %1. Error-Code is %2.").tqarg(lockName).tqarg(errno); return false; } TQString lockText; - lockText = TQString("%1 kmobile\n").arg(getpid(),10); + lockText = TQString("%1 kmobile\n").tqarg(getpid(),10); write(fd, lockText.utf8(), lockText.utf8().length()); close(fd); PRINT_DEBUG << TQString("%1: Device %2 locked with lockfile %3.\n") - .arg(tqdeviceName()).arg(tqdevice).arg(lockName); + .tqarg(tqdeviceName()).tqarg(tqdevice).tqarg(lockName); err_reason = TQString(); diff --git a/kmobile/kmobiledevice.h b/kmobile/kmobiledevice.h index 16e12aad5..d89e3f2d8 100644 --- a/kmobile/kmobiledevice.h +++ b/kmobile/kmobiledevice.h @@ -38,7 +38,7 @@ class KConfig; #define KMOBILE_MIMETYPE_DEVICE "kdetqdevice/mobiletqdevice" -#define KMOBILE_MIMETYPE_DEVICE_KONTQUEROR(name) TQString("kdetqdevice/kmobile_%1").arg(name) +#define KMOBILE_MIMETYPE_DEVICE_KONTQUEROR(name) TQString("kdetqdevice/kmobile_%1").tqarg(name) #define KMOBILE_MIMETYPE_INODE "inode/" #define KMOBILE_ICON_UNKNOWN "mobile_unknown" @@ -64,8 +64,8 @@ class KConfig; class KDE_EXPORT KMobileDevice : public KLibFactory { -Q_OBJECT - TQ_OBJECT + Q_OBJECT + TQ_OBJECT friend class KMobileView; public: @@ -428,9 +428,10 @@ signals: */ void finished(); - +#ifndef Q_MOC_RUN enum MessageBoxType { QuestionYesNo = 1, WarningYesNo = 2, WarningContinueCancel = 3, WarningYesNoCancel = 4, Information = 5, SSLMessageBox = 6 }; +#endif // Q_MOC_RUN /** * Call this to show a message box from the slave (it will in fact be handled diff --git a/kmobile/kmobileitem.cpp b/kmobile/kmobileitem.cpp index 0ea93353f..cb4473f80 100644 --- a/kmobile/kmobileitem.cpp +++ b/kmobile/kmobileitem.cpp @@ -38,7 +38,7 @@ KMobileItem::KMobileItem(TQIconView *tqparent, KConfig *_config, KService::Ptr s if (service) { setText(service->name()); m_tqdeviceDesktopFile = service->desktopEntryName(); - m_tqdeviceConfigFile = TQString("kmobile_%1_rc").arg(text()); + m_tqdeviceConfigFile = TQString("kmobile_%1_rc").tqarg(text()); m_tqdeviceConfigFile = m_tqdeviceConfigFile.tqreplace(' ', ""); m_iconName = service->icon(); }; @@ -104,7 +104,7 @@ TQPixmap KMobileItem::getIcon() const TQString KMobileItem::config_SectionName(int idx) const { if (idx == -1) idx = index(); - return TQString("MobileDevice_%1").arg(idx); + return TQString("MobileDevice_%1").tqarg(idx); } /* this MimeType is used by konqueror */ @@ -118,7 +118,7 @@ void KMobileItem::writeKonquMimeFile() const { // strip path and file extension of icon name TQString icon = m_iconName; - int p = icon.findRev('/'); + int p = icon.tqfindRev('/'); if (p>=0) icon = icon.mid(p+1); p = icon.tqfind('.'); if (p>=0) icon = icon.left(p); @@ -162,7 +162,7 @@ KService::Ptr KMobileItem::getServicePtr() const return ptr; } PRINT_DEBUG << TQString("Service for library '%1' not found in KService list\n") - .arg(m_tqdeviceDesktopFile); + .tqarg(m_tqdeviceDesktopFile); return 0L; } @@ -178,7 +178,7 @@ bool KMobileItem::driverAvailable() if (!ptr) return false; - PRINT_DEBUG << TQString("Loading library %1\n").arg(ptr->library()); + PRINT_DEBUG << TQString("Loading library %1\n").tqarg(ptr->library()); KLibFactory *factory = KLibLoader::self()->factory( ptr->library().utf8() ); if (!factory) return false; @@ -186,7 +186,7 @@ bool KMobileItem::driverAvailable() m_dev = static_cast<KMobileDevice *>(factory->create(this, ptr->name().utf8(), "KMobileDevice", TQStringList(m_tqdeviceConfigFile))); PRINT_DEBUG << TQString("Got KMobileDevice object at 0x%1, configfile=%2\n") - .arg((unsigned long)m_dev, 0, 16).arg(m_tqdeviceConfigFile); + .tqarg((unsigned long)m_dev, 0, 16).tqarg(m_tqdeviceConfigFile); return (m_dev != 0); } diff --git a/kmobile/kmobileview.cpp b/kmobile/kmobileview.cpp index 7a83f52ef..32fb916ae 100644 --- a/kmobile/kmobileview.cpp +++ b/kmobile/kmobileview.cpp @@ -51,8 +51,8 @@ bool KMobileView::addNewDevice(KConfig *config, KService::Ptr service) { kdDebug() << "New mobile tqdevice item:\n"; kdDebug() << TQString("LIBRARY: '%1', NAME: '%2', ICON: '%3', COMMENT: '%4'\n") - .arg(service->library()).arg(service->name()).arg(service->icon()) - .arg(service->comment()); + .tqarg(service->library()).tqarg(service->name()).tqarg(service->icon()) + .tqarg(service->comment()); KMobileItem *it; it = new KMobileItem(this, config, service); @@ -131,7 +131,7 @@ TQStringList KMobileView::tqdeviceNames() void KMobileView::removeDevice( TQString tqdeviceName ) { delete findDevice(tqdeviceName); - emit signalChangeStatusbar( i18n("%1 removed").arg(tqdeviceName) ); + emit signalChangeStatusbar( i18n("%1 removed").tqarg(tqdeviceName) ); } void KMobileView::configDevice( TQString tqdeviceName ) @@ -155,8 +155,8 @@ bool KMobileView::connectDevice( TQString tqdeviceName ) connected = dev->m_dev->connectDevice(); MUTEX_UNLOCK(dev->m_dev); emit signalChangeStatusbar( - connected ? i18n("Connection to %1 established").arg(tqdeviceName) - : i18n("Connection to %1 failed").arg(tqdeviceName) ); + connected ? i18n("Connection to %1 established").tqarg(tqdeviceName) + : i18n("Connection to %1 failed").tqarg(tqdeviceName) ); return connected; } @@ -170,8 +170,8 @@ bool KMobileView::disconnectDevice( TQString tqdeviceName ) disconnected = dev->m_dev->disconnectDevice(); MUTEX_UNLOCK(dev->m_dev); emit signalChangeStatusbar( - disconnected ? i18n("%1 disconnected").arg(tqdeviceName) - : i18n("Disconnection of %1 failed").arg(tqdeviceName) ); + disconnected ? i18n("%1 disconnected").tqarg(tqdeviceName) + : i18n("Disconnection of %1 failed").tqarg(tqdeviceName) ); return disconnected; } @@ -304,7 +304,7 @@ TQString KMobileView::readAddress( TQString tqdeviceName, int index ) return TQString(); emit signalChangeStatusbar( i18n("Read addressbook entry %1 from %2") - .arg(index).arg(tqdeviceName) ); + .tqarg(index).tqarg(tqdeviceName) ); return str; } @@ -325,8 +325,8 @@ bool KMobileView::storeAddress( TQString tqdeviceName, int index, TQString vcard err = dev->m_dev->storeAddress(index, adr, append); MUTEX_UNLOCK(dev->m_dev); emit signalChangeStatusbar( - err ? i18n("Storing contact %1 on %2 failed").arg(index).arg(tqdeviceName) - : i18n("Contact %1 stored on %2").arg(index).arg(tqdeviceName) ); + err ? i18n("Storing contact %1 on %2 failed").tqarg(index).tqarg(tqdeviceName) + : i18n("Contact %1 stored on %2").tqarg(index).tqarg(tqdeviceName) ); return (err == 0); } @@ -368,7 +368,7 @@ TQString KMobileView::readNote( TQString tqdeviceName, int index ) if (err) return TQString(); emit signalChangeStatusbar( i18n("Read note %1 from %2") - .arg(index).arg(tqdeviceName) ); + .tqarg(index).tqarg(tqdeviceName) ); return note; } @@ -385,7 +385,7 @@ bool KMobileView::storeNote( TQString tqdeviceName, int index, TQString note ) if (err) return false; emit signalChangeStatusbar( i18n("Stored note %1 to %2") - .arg(index).arg(tqdeviceName) ); + .tqarg(index).tqarg(tqdeviceName) ); return true; } @@ -425,7 +425,7 @@ TQStringList KMobileView::kio_tqdevices_tqdeviceInfo(TQString tqdeviceName) mountList << name; mountList << " "; - mountList << TQString("mobile:/%1").arg(name); // KIO::encodeFileName() + mountList << TQString("mobile:/%1").tqarg(name); // KIO::encodeFileName() mountList << mime; mountList << "true"; // mountState mountList << "---"; diff --git a/kmobile/systemtray.cpp b/kmobile/systemtray.cpp index e40dff642..76546cce0 100644 --- a/kmobile/systemtray.cpp +++ b/kmobile/systemtray.cpp @@ -60,7 +60,7 @@ SystemTray::~SystemTray() void SystemTray::contextMenuAboutToShow(KPopupMenu *menu) { - KMobile *main = static_cast<KMobile *>(tqparent()); + KMobile *main = static_cast<KMobile *>(TQT_TQWIDGET(tqparent())); const int pos = 3; while (menu->idAt(pos)>=SYSTEMTRAY_STARTID && @@ -84,7 +84,7 @@ void SystemTray::menuItemSelected() if (m_menuID<SYSTEMTRAY_STARTID || m_menuID>SYSTEMTRAY_STARTID+1000) return; TQString devName = contextMenu()->text(m_menuID); - KMobile *main = static_cast<KMobile *>(tqparent()); + KMobile *main = static_cast<KMobile *>(TQT_TQWIDGET(tqparent())); main->mainView()->startKonqueror(devName); } diff --git a/kmobile/testlibkmobile.cpp b/kmobile/testlibkmobile.cpp index 5d6d17527..774a191e7 100644 --- a/kmobile/testlibkmobile.cpp +++ b/kmobile/testlibkmobile.cpp @@ -31,10 +31,10 @@ int main(int argc, char **argv) TQStringList tqdeviceNames; reply >> tqdeviceNames; - kdDebug() << TQString("%1\n").arg(ok?"Ok":"Failure"); - kdDebug() << TQString("Number of currently registered drivers: %1\n").arg(tqdeviceNames.count()); + kdDebug() << TQString("%1\n").tqarg(ok?"Ok":"Failure"); + kdDebug() << TQString("Number of currently registered drivers: %1\n").tqarg(tqdeviceNames.count()); for (int i=0; i<tqdeviceNames.count(); i++) - kdDebug() << TQString("Device %1: %2\n").arg(i+1).arg(tqdeviceNames[i]); + kdDebug() << TQString("Device %1: %2\n").tqarg(i+1).tqarg(tqdeviceNames[i]); // return app.exec(); } diff --git a/knode/articlewidget.cpp b/knode/articlewidget.cpp index 301c9bb58..30af3f603 100644 --- a/knode/articlewidget.cpp +++ b/knode/articlewidget.cpp @@ -98,13 +98,13 @@ ArticleWidget::ArticleWidget( TQWidget *tqparent, TQHBoxLayout *box = new TQHBoxLayout( this ); mViewer = new KHTMLPart( this, "mViewer" ); box->addWidget( mViewer->widget() ); - mViewer->widget()->setFocusPolicy( WheelFocus ); + mViewer->widget()->setFocusPolicy( Qt::WheelFocus ); mViewer->setPluginsEnabled( false ); mViewer->setJScriptEnabled( false ); mViewer->setJavaEnabled( false ); mViewer->setMetaRefreshEnabled( false ); mViewer->setOnlyLocalReferences( true ); - mViewer->view()->setFocusPolicy( TQWidget::WheelFocus ); + mViewer->view()->setFocusPolicy( Qt::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&)), @@ -134,58 +134,58 @@ ArticleWidget::~ArticleWidget() void ArticleWidget::initActions() { - mSaveAction = KStdAction::save( this, TQT_SLOT(slotSave()), mActionCollection ); + mSaveAction = KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT(slotSave()), mActionCollection ); mSaveAction->setText( KStdGuiItem::saveAs().text() ); - 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::tqfind( this, TQT_SLOT(slotFind()), mActionCollection, "find_in_article" ); + mPrintAction = KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT(slotPrint()), mActionCollection ); + mCopySelectionAction = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(slotCopySelection()), mActionCollection ); + mSelectAllAction = KStdAction::selectAll( TQT_TQOBJECT(this), TQT_SLOT(slotSelectAll()), mActionCollection ); + mFindAction = KStdAction::find( TQT_TQOBJECT(this), TQT_SLOT(slotFind()), mActionCollection, "find_in_article" ); mFindAction->setText( i18n("F&ind in Article...") ); - mViewSourceAction = new KAction( i18n("&View Source"), Key_V , this, + mViewSourceAction = new KAction( i18n("&View Source"), Key_V , TQT_TQOBJECT(this), TQT_SLOT(slotViewSource()), mActionCollection, "article_viewSource" ); mReplyAction = new KAction( i18n("&Followup to Newsgroup..."), "message_reply", - Key_R, this, TQT_SLOT(slotReply()), mActionCollection, "article_postReply" ); + Key_R, TQT_TQOBJECT(this), TQT_SLOT(slotReply()), mActionCollection, "article_postReply" ); mRemailAction = new KAction( i18n("Reply by E&mail..."), "mail_reply", - Key_A, this, TQT_SLOT(slotRemail()), mActionCollection, "article_mailReply" ); + Key_A, TQT_TQOBJECT(this), TQT_SLOT(slotRemail()), mActionCollection, "article_mailReply" ); mForwardAction = new KAction( i18n("Forw&ard by Email..."), "mail_forward", - Key_F, this, TQT_SLOT(slotForward()), mActionCollection, "article_forward" ); + Key_F, TQT_TQOBJECT(this), TQT_SLOT(slotForward()), mActionCollection, "article_forward" ); mCancelAction = new KAction( i18n("article","&Cancel Article"), - 0, this, TQT_SLOT(slotCancel()), mActionCollection, "article_cancel" ); + 0, TQT_TQOBJECT(this), TQT_SLOT(slotCancel()), mActionCollection, "article_cancel" ); mSupersedeAction = new KAction(i18n("S&upersede Article"), - 0, this, TQT_SLOT(slotSupersede()), mActionCollection, "article_supersede" ); + 0, TQT_TQOBJECT(this), TQT_SLOT(slotSupersede()), mActionCollection, "article_supersede" ); mFixedFontToggle = new KToggleAction( i18n("U&se Fixed Font"), - Key_X ,this, TQT_SLOT(slotToggleFixedFont()), mActionCollection, "view_useFixedFont" ); + Key_X ,TQT_TQOBJECT(this), TQT_SLOT(slotToggleFixedFont()), mActionCollection, "view_useFixedFont" ); mFancyToggle = new KToggleAction( i18n("Fancy Formating"), - Key_Y, this, TQT_SLOT(slotToggleFancyFormating()), mActionCollection, "view_fancyFormating" ); - mRot13Toggle = new KToggleAction( i18n("&Unscramble (Rot 13)"), "decrypted", 0 , this, + Key_Y, TQT_TQOBJECT(this), TQT_SLOT(slotToggleFancyFormating()), mActionCollection, "view_fancyFormating" ); + mRot13Toggle = new KToggleAction( i18n("&Unscramble (Rot 13)"), "decrypted", 0 , TQT_TQOBJECT(this), 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, TQT_SLOT(slotFancyHeaders()), + ra = new KRadioAction( i18n("&Fancy Headers"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFancyHeaders()), mActionCollection, "view_headers_fancy" ); ra->setExclusiveGroup( "view_headers" ); mHeaderStyleMenu->insert( ra ); - ra = new KRadioAction( i18n("&Standard Headers"), 0, this, TQT_SLOT(slotStandardHeaders()), + ra = new KRadioAction( i18n("&Standard Headers"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotStandardHeaders()), mActionCollection, "view_headers_standard" ); ra->setExclusiveGroup( "view_headers" ); mHeaderStyleMenu->insert( ra ); - ra = new KRadioAction( i18n("&All Headers"), 0, this, TQT_SLOT(slotAllHeaders()), + ra = new KRadioAction( i18n("&All Headers"), 0, TQT_TQOBJECT(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, TQT_SLOT(slotIconAttachments()), + ra = new KRadioAction( i18n("&As Icon"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotIconAttachments()), mActionCollection, "view_attachments_icon" ); ra->setExclusiveGroup( "view_attachments" ); mAttachmentStyleMenu->insert( ra ); - ra = new KRadioAction( i18n("&Inline"), 0, this, TQT_SLOT(slotInlineAttachments()), + ra = new KRadioAction( i18n("&Inline"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotInlineAttachments()), mActionCollection, "view_attachments_inline" ); ra->setExclusiveGroup( "view_attachments" ); mAttachmentStyleMenu->insert( ra ); - ra = new KRadioAction( i18n("&Hide"), 0, this, TQT_SLOT(slotHideAttachments()), + ra = new KRadioAction( i18n("&Hide"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotHideAttachments()), mActionCollection, "view_attachments_hide" ); ra->setExclusiveGroup( "view_attachments" ); mAttachmentStyleMenu->insert( ra ); @@ -197,22 +197,22 @@ void ArticleWidget::initActions() mCharsetSelect->setItems( cs ); mCharsetSelect->setCurrentItem( 0 ); connect( mCharsetSelect, TQT_SIGNAL(activated(const TQString&)),TQT_SLOT(slotSetCharset(const TQString&)) ); - mCharsetSelectKeyb = new KAction( i18n("Charset"), Key_C, this, + mCharsetSelectKeyb = new KAction( i18n("Charset"), Key_C, TQT_TQOBJECT(this), TQT_SLOT(slotSetCharsetKeyboard()), mActionCollection, "set_charset_keyboard" ); - new KAction( i18n("&Open URL"), "fileopen", 0, this, TQT_SLOT(slotOpenURL()), + new KAction( i18n("&Open URL"), "fileopen", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOpenURL()), mActionCollection, "open_url" ); - new KAction( i18n("&Copy Link Address"), "editcopy", 0, this, TQT_SLOT( slotCopyURL()), + new KAction( i18n("&Copy Link Address"), "editcopy", 0, TQT_TQOBJECT(this), TQT_SLOT( slotCopyURL()), mActionCollection, "copy_url" ); - new KAction( i18n("&Bookmark This Link"), "bookmark_add", 0, this, TQT_SLOT(slotAddBookmark()), + new KAction( i18n("&Bookmark This Link"), "bookmark_add", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddBookmark()), mActionCollection, "add_bookmark" ); - new KAction( i18n("&Add to Address Book"), 0, this, TQT_SLOT(slotAddToAddressBook()), + new KAction( i18n("&Add to Address Book"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAddToAddressBook()), mActionCollection, "add_addr_book" ); - new KAction( i18n("&Open in Address Book"), 0, this, TQT_SLOT(slotOpenInAddressBook()), + new KAction( i18n("&Open in Address Book"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotOpenInAddressBook()), mActionCollection, "openin_addr_book" ); - new KAction( i18n("&Open Attachment"), "fileopen", 0, this, TQT_SLOT(slotOpenAttachment()), + new KAction( i18n("&Open Attachment"), "fileopen", 0, TQT_TQOBJECT(this), TQT_SLOT(slotOpenAttachment()), mActionCollection, "open_attachment" ); - new KAction( i18n("&Save Attachment As..."), "filesaveas", 0, this, TQT_SLOT(slotSaveAttachment()), + new KAction( i18n("&Save Attachment As..."), "filesaveas", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSaveAttachment()), mActionCollection, "save_attachment" ); } @@ -290,9 +290,9 @@ void ArticleWidget::readConfig() mAttachmentStyle = conf->readEntry( "attachmentStyle", "inline" ); mHeaderStyle = conf->readEntry( "headerStyle", "fancy" ); KRadioAction *ra = 0; - ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_attachments_%1").arg(mAttachmentStyle).latin1() ) ); + ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_attachments_%1").tqarg(mAttachmentStyle).latin1() ) ); ra->setChecked( true ); - ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_headers_%1").arg(mHeaderStyle).latin1() ) ); + ra = static_cast<KRadioAction*>( mActionCollection->action( TQString("view_headers_%1").tqarg(mHeaderStyle).latin1() ) ); ra->setChecked( true ); delete mCSSHelper; @@ -402,7 +402,7 @@ void ArticleWidget::displayArticle() // check if codec is available if ( text && !canDecodeText( text->contentType()->charset() ) ) { html += TQString("<table width=\"100%\" border=\"0\"><tr><td bgcolor=\"#FF0000\">%1</td></tr></table>") - .arg( i18n("Unknown charset. Default charset is used instead.") ); + .tqarg( i18n("Unknown charset. Default charset is used instead.") ); kdDebug(5003) << k_funcinfo << "unknown charset = " << text->contentType()->charset() << endl; } @@ -473,7 +473,7 @@ void ArticleWidget::displayArticle() text->decodedText( htmlTxt, true, cfgMgr->readNewsViewer()->removeTrailingNewlines() ); if ( mShowHtml ) { // strip </html> & </body> - int i = kMin( htmlTxt.findRev( "</html>", -1, false ), htmlTxt.findRev( "</body>", -1, false ) ); + int i = kMin( htmlTxt.tqfindRev( "</html>", -1, false ), htmlTxt.tqfindRev( "</body>", -1, false ) ); if ( i >= 0 ) htmlTxt.truncate( i ); html += htmlTxt; @@ -560,8 +560,8 @@ void ArticleWidget::displayHeader() if ( header ) { headerHtml += "<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 ) ); + .tqarg( toHtmlString( header->type(), None ) + ": " ) + .tqarg( toHtmlString( header->asUnicodeString() , ParseURL ) ); delete header; } } @@ -597,8 +597,8 @@ void ArticleWidget::displayHeader() if ( hb->is("From") ) { headerHtml += TQString( "<a href=\"mailto:%1\">%2</a>") - .arg( KPIM::getEmailAddress( hb->asUnicodeString() ) ) - .arg( toHtmlString( hb->asUnicodeString(), None ) ); + .tqarg( KPIM::getEmailAddress( hb->asUnicodeString() ) ) + .tqarg( toHtmlString( hb->asUnicodeString(), None ) ); KMime::Headers::Base *orgHdr = mArticle->getHeaderByType( "Organization" ); if ( orgHdr && !orgHdr->isEmpty() ) { headerHtml += " ("; @@ -636,7 +636,7 @@ void ArticleWidget::displayHeader() if ( !xfhead.isEmpty() ) { KPIM::KXFace xf; xface = TQString::tqfromLatin1( "<div class=\"senderpic\"><img src=\"%1\" width=\"48\" height=\"48\"/></div>" ) - .arg( imgToDataUrl( xf.toImage( xfhead ), "PNG" ) ); + .tqarg( imgToDataUrl( xf.toImage( xfhead ), "PNG" ) ); } // fancy header style @@ -660,7 +660,7 @@ void ArticleWidget::displayHeader() int refCnt = refs->count(), i = 1; TQCString id = refs->first(); id = id.mid( 1, id.length() - 2 ); // remove <> - html += TQString( "<b>%1</b>" ).arg( i18n("References:") ); + html += TQString( "<b>%1</b>" ).tqarg( i18n("References:") ); while ( i <= refCnt ) { html += " <a href=\"news:" + TQString::tqfromLatin1( id ) + "\">" + TQString::number( i ) + "</a>"; @@ -748,7 +748,7 @@ TQString ArticleWidget::displaySigHeader( Kpgp::Block* block ) TQString message; if ( signer.isEmpty() ) { message = i18n( "Message was signed with unknown key 0x%1." ) - .arg( signerKey ); + .tqarg( TQString(signerKey) ); message += "<br/>"; message += i18n( "The validity of the signature cannot be verified." ); signClass = "signWarn"; @@ -769,10 +769,10 @@ TQString ArticleWidget::displaySigHeader( Kpgp::Block* block ) if( !signerKey.isEmpty() ) message += i18n( "Message was signed by %1 (Key ID: 0x%2)." ) - .arg( signer ) - .arg( signerKey ); + .tqarg( signer ) + .tqarg( TQString(signerKey) ); else - message += i18n( "Message was signed by %1." ).arg( signer ); + message += i18n( "Message was signed by %1." ).tqarg( signer ); message += "<br/>"; if( block->goodSignature() ) { @@ -916,7 +916,7 @@ TQString ArticleWidget::imgToDataUrl( const TQImage &image, const char* fmt ) buffer.open( IO_WriteOnly ); image.save( &buffer, fmt ); return TQString::tqfromLatin1("data:image/%1;base64,%2") - .arg( fmt, KCodecs::base64Encode( ba ) ); + .tqarg( fmt, TQString(KCodecs::base64Encode( ba )) ); } @@ -989,7 +989,7 @@ TQString ArticleWidget::writeAttachmentToTempFile( KMime::Content *att, int part // strip off a leading path KMime::Headers::ContentType* ct = att->contentType(); TQString attName = ct->name(); - int slashPos = attName.findRev( '/' ); + int slashPos = attName.tqfindRev( '/' ); if( -1 != slashPos ) attName = attName.mid( slashPos + 1 ); if( attName.isEmpty() ) @@ -1030,7 +1030,7 @@ void ArticleWidget::processJob( KNJobData * job ) if ( !job->canceled() ) { if ( !job->success() ) KMessageBox::error( this, i18n("An error occurred while downloading the article source:\n") - .arg( job->errorString() ) ); + .tqarg( job->errorString() ) ); else new KNSourceViewWindow( a->head() + "\n" + a->body() ); } @@ -1408,8 +1408,8 @@ void ArticleWidget::slotCopyURL() address = mCurrentURL.path(); else address = mCurrentURL.url(); - TQApplication::clipboard()->setText( address, TQClipboard::Clipboard ); - TQApplication::clipboard()->setText( address, TQClipboard::Selection ); + TQApplication::tqclipboard()->setText( address, TQClipboard::Clipboard ); + TQApplication::tqclipboard()->setText( address, TQClipboard::Selection ); } void ArticleWidget::slotAddBookmark() @@ -1472,7 +1472,7 @@ void ArticleWidget::focusOutEvent( TQFocusEvent *e ) bool ArticleWidget::eventFilter( TQObject *o, TQEvent *e ) { - if ( e->type() == TQEvent::KeyPress && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab) ) { + if ( e->type() == TQEvent::KeyPress && (TQT_TQKEYEVENT(e)->key() == Key_Tab) ) { emit focusChangeRequest( this ); if ( !hasFocus() ) // focusChangeRequest was successful return true; diff --git a/knode/headerview.cpp b/knode/headerview.cpp index 0007ffe67..998d6893b 100644 --- a/knode/headerview.cpp +++ b/knode/headerview.cpp @@ -540,7 +540,7 @@ void KNHeaderView::slotSizeChanged( int section, int, int newSize ) bool KNHeaderView::eventFilter(TQObject *o, TQEvent *e) { - if ((e->type() == TQEvent::KeyPress) && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab)) { + if ((e->type() == TQEvent::KeyPress) && (TQT_TQKEYEVENT(e)->key() == Key_Tab)) { emit(focusChangeRequest(this)); if (!hasFocus()) // focusChangeRequest was successful return true; @@ -548,10 +548,10 @@ bool KNHeaderView::eventFilter(TQObject *o, TQEvent *e) // right click on header if ( e->type() == TQEvent::MouseButtonPress && - static_cast<TQMouseEvent*>(e)->button() == RightButton && + TQT_TQMOUSEEVENT(e)->button() == Qt::RightButton && o->isA(TQHEADER_OBJECT_NAME_STRING) ) { - mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() ); + mPopup->popup( TQT_TQMOUSEEVENT(e)->globalPos() ); return true; } diff --git a/knode/knaccountmanager.cpp b/knode/knaccountmanager.cpp index af319731f..b62679a2f 100644 --- a/knode/knaccountmanager.cpp +++ b/knode/knaccountmanager.cpp @@ -127,12 +127,12 @@ bool KNAccountManager::newAccount(KNNntpAccount *a) TQStringList entries(d.entryList("nntp.*", TQDir::Dirs)); int id = 1; - while (entries.findIndex(TQString("nntp.%1").arg(id))!=-1) + while (entries.tqfindIndex(TQString("nntp.%1").tqarg(id))!=-1) ++id; a->setId(id); - dir = locateLocal("data",TQString("knode/nntp.%1/").arg(a->id())); + dir = locateLocal("data",TQString("knode/nntp.%1/").tqarg(a->id())); if (!dir.isNull()) { mAccounts.append(a); emit(accountAdded(a)); @@ -177,7 +177,7 @@ bool KNAccountManager::removeAccount(KNNntpAccount *a) } } dir.cdUp(); // directory should now be empty, deleting it - dir.rmdir(TQString("nntp.%1/").arg(a->id())); + dir.rmdir(TQString("nntp.%1/").tqarg(a->id())); } if(c_urrentAccount==a) setCurrentAccount(0); diff --git a/knode/knarticlefactory.cpp b/knode/knarticlefactory.cpp index 1421b405e..37c1b4961 100644 --- a/knode/knarticlefactory.cpp +++ b/knode/knarticlefactory.cpp @@ -306,7 +306,7 @@ void KNArticleFactory::createForward(KNArticle *a) //--------------------------- <Body> ----------------------------- - TQString fwd = TQString("\n--------------- %1\n\n").arg(i18n("Forwarded message (begin)")); + TQString fwd = TQString("\n--------------- %1\n\n").tqarg(i18n("Forwarded message (begin)")); fwd+=( i18n("Subject") + ": " + a->subject()->asUnicodeString() + "\n" ); fwd+=( i18n("From") + ": " + a->from()->asUnicodeString() + "\n" ); @@ -321,7 +321,7 @@ void KNArticleFactory::createForward(KNArticle *a) fwd += (*it) + "\n"; } - fwd += TQString("\n--------------- %1\n").arg(i18n("Forwarded message (end)")); + fwd += TQString("\n--------------- %1\n").tqarg(i18n("Forwarded message (end)")); //--------------------------- </Body> ---------------------------- @@ -601,7 +601,7 @@ void KNArticleFactory::edit(KNLocalArticle *a) KMessageBox::information(knGlobals.topWidget, i18n("<qt>The signature generator program produced the " "following output:<br><br>%1</qt>") - .arg(id->getSigGeneratorStdErr())); + .tqarg(id->getSigGeneratorStdErr())); mCompList.append( com ); connect(com, TQT_SIGNAL(composerDone(KNComposer*)), this, TQT_SLOT(slotComposerDone(KNComposer*))); @@ -895,7 +895,7 @@ KNLocalArticle* KNArticleFactory::newArticle(KNCollection *col, TQString &sig, T KMessageBox::information(knGlobals.topWidget, i18n("<qt>The signature generator program produced the " "following output:<br><br>%1</qt>") - .arg(id->getSigGeneratorStdErr())); + .tqarg(id->getSigGeneratorStdErr())); } else sig=TQString(); @@ -1070,8 +1070,8 @@ KNSendErrorDialog::KNSendErrorDialog() TQVBox *page = makeVBoxMainWidget(); - 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); + new TQLabel(TQString("<b>%1</b><br>%2").tqarg(i18n("Errors occurred while sending these articles:")) + .tqarg(i18n("The unsent articles are stored in the \"Outbox\" folder.")), page); j_obs=new KNDialogListBox(true, page); e_rror=new TQLabel(TQString(), page); diff --git a/knode/knarticlefilter.cpp b/knode/knarticlefilter.cpp index 56460a34f..359985198 100644 --- a/knode/knarticlefilter.cpp +++ b/knode/knarticlefilter.cpp @@ -74,7 +74,7 @@ KNArticleFilter::~KNArticleFilter() bool KNArticleFilter::loadInfo() { if (i_d!=-1) { - TQString fname(locate("data",TQString( "knode/filters/%1.fltr" ).arg(i_d) ) ); + TQString fname(locate("data",TQString( "knode/filters/%1.fltr" ).tqarg(i_d) ) ); if (fname.isNull()) return false; @@ -94,7 +94,7 @@ bool KNArticleFilter::loadInfo() void KNArticleFilter::load() { - TQString fname(locate("data",TQString( "knode/filters/%1.fltr").arg(i_d) ) ); + TQString fname(locate("data",TQString( "knode/filters/%1.fltr").tqarg(i_d) ) ); if (fname.isNull()) return; @@ -141,7 +141,7 @@ void KNArticleFilter::save() KNHelper::displayInternalFileError(); return; } - KSimpleConfig conf(dir+TQString("%1.fltr").arg(i_d)); + KSimpleConfig conf(dir+TQString("%1.fltr").tqarg(i_d)); conf.setGroup("GENERAL"); conf.writeEntry("name", TQString(n_ame)); diff --git a/knode/knarticlemanager.cpp b/knode/knarticlemanager.cpp index 4e97c2d2b..625f22f06 100644 --- a/knode/knarticlemanager.cpp +++ b/knode/knarticlemanager.cpp @@ -992,10 +992,10 @@ void KNArticleManager::updateStatusString() name += i18n(" (moderated)"); knGlobals.seStatusMsg(i18n(" %1: %2 new , %3 displayed") - .arg(name).arg(g_roup->newCount()).arg(displCnt),SB_GROUP); + .tqarg(name).tqarg(g_roup->newCount()).tqarg(displCnt),SB_GROUP); if(f_ilter) - knGlobals.seStatusMsg(i18n(" Filter: %1").arg(f_ilter->translatedName()), SB_FILTER); + knGlobals.seStatusMsg(i18n(" Filter: %1").tqarg(f_ilter->translatedName()), SB_FILTER); else knGlobals.seStatusMsg(TQString(), SB_FILTER); } @@ -1005,7 +1005,7 @@ void KNArticleManager::updateStatusString() else displCnt=f_older->count(); knGlobals.seStatusMsg(i18n(" %1: %2 displayed") - .arg(f_older->name()).arg(displCnt), SB_GROUP); + .tqarg(f_older->name()).tqarg(displCnt), SB_GROUP); knGlobals.seStatusMsg(TQString(), SB_FILTER); } else { knGlobals.seStatusMsg(TQString(), SB_GROUP); diff --git a/knode/knarticlewindow.cpp b/knode/knarticlewindow.cpp index 05b4f83ae..aef3aab0c 100644 --- a/knode/knarticlewindow.cpp +++ b/knode/knarticlewindow.cpp @@ -101,10 +101,10 @@ KNArticleWindow::KNArticleWindow(KNArticle *art) mInstances.append( this ); // file menu - KStdAction::close( this, TQT_SLOT(close()), actionCollection() ); + KStdAction::close( TQT_TQOBJECT(this), TQT_SLOT(close()), actionCollection() ); // settings menu - KStdAction::preferences(knGlobals.top, TQT_SLOT(slotSettings()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(knGlobals.top), TQT_SLOT(slotSettings()), actionCollection()); KAccel *accel = new KAccel( this ); artW->setCharsetKeyboardAction()->plugAccel( accel ); diff --git a/knode/kncleanup.cpp b/knode/kncleanup.cpp index 3e79b4a62..28993e7ce 100644 --- a/knode/kncleanup.cpp +++ b/knode/kncleanup.cpp @@ -56,13 +56,13 @@ void KNCleanUp::start() 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() ) ); + d_lg->showMessage( i18n("Deleting expired articles in <b>%1</b>").tqarg( (*it)->name() ) ); kapp->processEvents(); expireGroup( static_cast<KNGroup*>( (*it) ) ); d_lg->doProgress(); } else if ( (*it)->type() == KNCollection::CTfolder ) { - d_lg->showMessage( i18n("Compacting folder <b>%1</b>").arg( (*it)->name() ) ); + d_lg->showMessage( i18n("Compacting folder <b>%1</b>").tqarg( (*it)->name() ) ); kapp->processEvents(); compactFolder( static_cast<KNFolder*>( (*it) ) ); d_lg->doProgress(); @@ -187,7 +187,7 @@ void KNCleanUp::expireGroup( KNGroup *g, bool showResult ) if(showResult) KMessageBox::information(knGlobals.topWidget, - i18n("<b>%1</b><br>expired: %2<br>left: %3").arg(g->groupname()).arg(delCnt).arg(leftCnt)); + i18n("<b>%1</b><br>expired: %2<br>left: %3").tqarg(g->groupname()).tqarg(delCnt).tqarg(leftCnt)); } diff --git a/knode/kncollectionview.cpp b/knode/kncollectionview.cpp index ef97c653e..1026e642d 100644 --- a/knode/kncollectionview.cpp +++ b/knode/kncollectionview.cpp @@ -421,7 +421,7 @@ void KNCollectionView::updatePopup() const bool KNCollectionView::eventFilter(TQObject *o, TQEvent *e) { - if ((e->type() == TQEvent::KeyPress) && (static_cast<TQKeyEvent*>(e)->key() == Key_Tab)) { + if ((e->type() == TQEvent::KeyPress) && (TQT_TQKEYEVENT(e)->key() == Key_Tab)) { emit(focusChangeRequest(this)); if (!hasFocus()) // focusChangeRequest was successful return true; @@ -429,10 +429,10 @@ bool KNCollectionView::eventFilter(TQObject *o, TQEvent *e) // header popup menu if ( e->type() == TQEvent::MouseButtonPress && - static_cast<TQMouseEvent*>(e)->button() == RightButton && + TQT_TQMOUSEEVENT(e)->button() == Qt::RightButton && o->isA(TQHEADER_OBJECT_NAME_STRING) ) { - mPopup->popup( static_cast<TQMouseEvent*>(e)->globalPos() ); + mPopup->popup( TQT_TQMOUSEEVENT(e)->globalPos() ); return true; } diff --git a/knode/kncomposer.cpp b/knode/kncomposer.cpp index 4e928a495..160ab38e5 100644 --- a/knode/kncomposer.cpp +++ b/knode/kncomposer.cpp @@ -205,70 +205,70 @@ KNComposer::KNComposer(KNLocalArticle *a, const TQString &text, const TQString & //------------------------------- <Actions> -------------------------------------- //file menu - new KAction(i18n("&Send Now"),"mail_send", CTRL + Key_Return , this, + new KAction(i18n("&Send Now"),"mail_send", CTRL + Key_Return , TQT_TQOBJECT(this), TQT_SLOT(slotSendNow()), actionCollection(), "send_now"); - new KAction(i18n("Send &Later"), "queue", 0, this, + new KAction(i18n("Send &Later"), "queue", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSendLater()), actionCollection(), "send_later"); - new KAction(i18n("Save as &Draft"),"filesave", 0 , this, + new KAction(i18n("Save as &Draft"),"filesave", 0 , TQT_TQOBJECT(this), TQT_SLOT(slotSaveAsDraft()), actionCollection(), "save_as_draft"); - new KAction(i18n("D&elete"),"editdelete", 0 , this, + new KAction(i18n("D&elete"),"editdelete", 0 , TQT_TQOBJECT(this), TQT_SLOT(slotArtDelete()), actionCollection(), "art_delete"); - KStdAction::close(this, TQT_SLOT(close()),actionCollection()); + KStdAction::close(TQT_TQOBJECT(this), TQT_SLOT(close()),actionCollection()); //edit menu - KStdAction::undo(this, TQT_SLOT(slotUndo()), actionCollection()); - KStdAction::redo(this, TQT_SLOT(slotRedo()), actionCollection()); + KStdAction::undo(TQT_TQOBJECT(this), TQT_SLOT(slotUndo()), actionCollection()); + KStdAction::redo(TQT_TQOBJECT(this), TQT_SLOT(slotRedo()), actionCollection()); - KStdAction::cut(this, TQT_SLOT(slotCut()), actionCollection()); + KStdAction::cut(TQT_TQOBJECT(this), TQT_SLOT(slotCut()), actionCollection()); - KStdAction::copy(this, TQT_SLOT(slotCopy()), actionCollection()); + KStdAction::copy(TQT_TQOBJECT(this), TQT_SLOT(slotCopy()), actionCollection()); - KStdAction::pasteText(this, TQT_SLOT(slotPaste()), actionCollection()); + KStdAction::pasteText(TQT_TQOBJECT(this), TQT_SLOT(slotPaste()), actionCollection()); - new KAction(i18n("Paste as &Quotation"), 0, v_iew->e_dit, + new KAction(i18n("Paste as &Quotation"), 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotPasteAsQuotation()), actionCollection(), "paste_quoted"); - KStdAction::selectAll(this, TQT_SLOT(slotSelectAll()), actionCollection()); + KStdAction::selectAll(TQT_TQOBJECT(this), TQT_SLOT(slotSelectAll()), actionCollection()); - KStdAction::tqfind(v_iew->e_dit, TQT_SLOT(slotFind()), actionCollection()); - KStdAction::findNext(v_iew->e_dit, TQT_SLOT(slotSearchAgain()), actionCollection()); + KStdAction::find(TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotFind()), actionCollection()); + KStdAction::findNext(TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotSearchAgain()), actionCollection()); - KStdAction::tqreplace(v_iew->e_dit, TQT_SLOT(slotReplace()), actionCollection()); + KStdAction::replace(TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotReplace()), actionCollection()); //attach menu - new KAction(i18n("Append &Signature"), 0 , this, TQT_SLOT(slotAppendSig()), + new KAction(i18n("Append &Signature"), 0 , TQT_TQOBJECT(this), TQT_SLOT(slotAppendSig()), actionCollection(), "append_signature"); - new KAction(i18n("&Insert File..."), 0, this, TQT_SLOT(slotInsertFile()), + new KAction(i18n("&Insert File..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotInsertFile()), actionCollection(), "insert_file"); - new KAction(i18n("Insert File (in a &box)..."), 0, this, TQT_SLOT(slotInsertFileBoxed()), + new KAction(i18n("Insert File (in a &box)..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotInsertFileBoxed()), actionCollection(), "insert_file_boxed"); - new KAction(i18n("Attach &File..."), "attach", 0, this, TQT_SLOT(slotAttachFile()), + new KAction(i18n("Attach &File..."), "attach", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAttachFile()), actionCollection(), "attach_file"); a_ctPGPsign = new KToggleAction(i18n("Sign Article with &PGP"), "signature", 0, actionCollection(), "sign_article"); - a_ctRemoveAttachment = new KAction(i18n("&Remove"), 0, this, + a_ctRemoveAttachment = new KAction(i18n("&Remove"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotRemoveAttachment()), actionCollection(), "remove_attachment"); - a_ctAttachmentProperties = new KAction(i18n("&Properties"), 0, this, + a_ctAttachmentProperties = new KAction(i18n("&Properties"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAttachmentProperties()), actionCollection(), "attachment_properties"); //options menu - a_ctDoPost = new KToggleAction(i18n("Send &News Article"), "filenew", 0 , this, + a_ctDoPost = new KToggleAction(i18n("Send &News Article"), "filenew", 0 , TQT_TQOBJECT(this), TQT_SLOT(slotToggleDoPost()), actionCollection(), "send_news"); - a_ctDoMail = new KToggleAction(i18n("Send E&mail"), "mail_generic" , 0 , this, + a_ctDoMail = new KToggleAction(i18n("Send E&mail"), "mail_generic" , 0 , TQT_TQOBJECT(this), TQT_SLOT(slotToggleDoMail()), actionCollection(), "send_mail"); a_ctSetCharset = new KSelectAction(i18n("Set &Charset"), 0, actionCollection(), "set_charset"); @@ -277,50 +277,50 @@ KNComposer::KNComposer(KNLocalArticle *a, const TQString &text, const TQString & connect(a_ctSetCharset, TQT_SIGNAL(activated(const TQString&)), this, TQT_SLOT(slotSetCharset(const TQString&))); - a_ctSetCharsetKeyb = new KAction(i18n("Set Charset"), 0, this, + a_ctSetCharsetKeyb = new KAction(i18n("Set Charset"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotSetCharsetKeyboard()), actionCollection(), "set_charset_keyboard"); - a_ctWordWrap = new KToggleAction(i18n("&Word Wrap"), 0 , this, + a_ctWordWrap = new KToggleAction(i18n("&Word Wrap"), 0 , TQT_TQOBJECT(this), TQT_SLOT(slotToggleWordWrap()), actionCollection(), "toggle_wordwrap"); //tools menu - new KAction(i18n("Add &Quote Characters"), 0, v_iew->e_dit, + new KAction(i18n("Add &Quote Characters"), 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotAddQuotes()), actionCollection(), "tools_quote"); - new KAction(i18n("&Remove Quote Characters"), 0, v_iew->e_dit, + new KAction(i18n("&Remove Quote Characters"), 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotRemoveQuotes()), actionCollection(), "tools_unquote"); - new KAction(i18n("Add &Box"), 0, v_iew->e_dit, + new KAction(i18n("Add &Box"), 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotAddBox()), actionCollection(), "tools_box"); - new KAction(i18n("Re&move Box"), 0, v_iew->e_dit, + new KAction(i18n("Re&move Box"), 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotRemoveBox()), actionCollection(), "tools_unbox"); - KAction *undoRewrap = new KAction(i18n("Get &Original Text (not re-wrapped)"), 0, this, + KAction *undoRewrap = new KAction(i18n("Get &Original Text (not re-wrapped)"), 0, TQT_TQOBJECT(this), 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, + KAction *rot13 = new KAction(i18n("S&cramble (Rot 13)"), "encrypted", 0, TQT_TQOBJECT(v_iew->e_dit), TQT_SLOT(slotRot13()), actionCollection(), "tools_rot13"); rot13->setEnabled(false); 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, + a_ctExternalEditor = new KAction(i18n("Start &External Editor"), "run", 0, TQT_TQOBJECT(this), TQT_SLOT(slotExternalEditor()), actionCollection(), "external_editor"); - a_ctSpellCheck = KStdAction::spelling (this, TQT_SLOT(slotSpellcheck()), actionCollection()); + a_ctSpellCheck = KStdAction::spelling (TQT_TQOBJECT(this), TQT_SLOT(slotSpellcheck()), actionCollection()); //settings menu createStandardStatusBarAction(); setStandardToolBarMenuEnabled(true); - KStdAction::keyBindings(this, TQT_SLOT(slotConfKeys()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(slotConfKeys()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(slotConfToolbar()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotConfToolbar()), actionCollection()); - KStdAction::preferences(knGlobals.top, TQT_SLOT(slotSettings()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(knGlobals.top), TQT_SLOT(slotSettings()), actionCollection()); a_ccel=new KAccel(this); a_ctSetCharsetKeyb->plugAccel(a_ccel); @@ -969,7 +969,7 @@ void KNComposer::insertFile(TQFile *file, bool clear, bool box, TQString boxTitl ts.setCodec(codec); if (box) - temp = TQString::tqfromLatin1(",----[ %1 ]\n").arg(boxTitle); + temp = TQString::tqfromLatin1(",----[ %1 ]\n").tqarg(boxTitle); if (box && (v_iew->e_dit->wordWrap()!=TQMultiLineEdit::NoWrap)) { int wrapAt = v_iew->e_dit->wrapColumnOrWidth(); @@ -1327,7 +1327,7 @@ void KNComposer::slotSpellcheck() a_ctExternalEditor->setEnabled(false); a_ctSpellCheck->setEnabled(false); - s_pellChecker = new KSpell(this, i18n("Spellcheck"), this, TQT_SLOT(slotSpellStarted(KSpell *))); + s_pellChecker = new KSpell(TQT_TQWIDGET(this), i18n("Spellcheck"), TQT_TQOBJECT(this), TQT_SLOT(slotSpellStarted(KSpell *))); TQStringList l = KSpellingHighlighter::personalWords(); for ( TQStringList::Iterator it = l.begin(); it != l.end(); ++it ) { s_pellChecker->addPersonal( *it ); @@ -1374,18 +1374,18 @@ void KNComposer::slotUpdateStatusBar() else overwriteDesc = i18n(" INS "); - statusBar()->changeItem(i18n(" Type: %1 ").arg(typeDesc), 1); - statusBar()->changeItem(i18n(" Charset: %1 ").arg(c_harset), 2); + statusBar()->changeItem(i18n(" Type: %1 ").tqarg(typeDesc), 1); + statusBar()->changeItem(i18n(" Charset: %1 ").tqarg(TQString(c_harset)), 2); statusBar()->changeItem(overwriteDesc, 3); - statusBar()->changeItem(i18n(" Column: %1 ").arg(v_iew->e_dit->currentColumn() + 1), 4); - statusBar()->changeItem(i18n(" Line: %1 ").arg(v_iew->e_dit->currentLine() + 1), 5); + statusBar()->changeItem(i18n(" Column: %1 ").tqarg(v_iew->e_dit->currentColumn() + 1), 4); + statusBar()->changeItem(i18n(" Line: %1 ").tqarg(v_iew->e_dit->currentLine() + 1), 5); } void KNComposer::slotUpdateCursorPos() { - statusBar()->changeItem(i18n(" Column: %1 ").arg(v_iew->e_dit->currentColumn() + 1), 4); - statusBar()->changeItem(i18n(" Line: %1 ").arg(v_iew->e_dit->currentLine() + 1), 5); + statusBar()->changeItem(i18n(" Column: %1 ").tqarg(v_iew->e_dit->currentColumn() + 1), 4); + statusBar()->changeItem(i18n(" Line: %1 ").tqarg(v_iew->e_dit->currentLine() + 1), 5); } @@ -1643,7 +1643,7 @@ void KNComposer::slotSpellFinished() { a_ctExternalEditor->setEnabled(true); a_ctSpellCheck->setEnabled(true); - KSpell::spelltqStatus status=s_pellChecker->status(); + KSpell::spellStatus status=s_pellChecker->status(); delete s_pellChecker; s_pellChecker=0; @@ -1725,7 +1725,7 @@ TQPopupMenu * KNComposer::popupMenu( const TQString& name ) KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n) - : TQSplitter(TQSplitter::Vertical, composer, n), a_ttWidget(0), a_ttView(0), v_iewOpen(false) + : TQSplitter(Qt::Vertical, composer, n), a_ttWidget(0), a_ttView(0), v_iewOpen(false) { TQWidget *main=new TQWidget(this); @@ -1781,10 +1781,10 @@ KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n) KConfig *config = knGlobals.config(); KConfigGroupSaver saver(config, "VISUAL_APPEARANCE"); - 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 defaultColor1( kapp->tqpalette().active().text()); // defaults from kmreaderwin.cpp + TQColor defaultColor2( kapp->tqpalette().active().text() ); + TQColor defaultColor3( kapp->tqpalette().active().text() ); + TQColor defaultForeground( kapp->tqpalette().active().text() ); TQColor col1 = config->readColorEntry( "ForegroundColor", &defaultForeground ); TQColor col2 = config->readColorEntry( "quote3Color", &defaultColor3 ); TQColor col3 = config->readColorEntry( "quote2Color", &defaultColor2 ); @@ -1798,7 +1798,7 @@ KNComposer::ComposerView::ComposerView(KNComposer *composer, const char *n) TQVBoxLayout *notL=new TQVBoxLayout(e_dit); notL->addStretch(1); - n_otification=new TQGroupBox(2, TQt::Horizontal, e_dit); + 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); @@ -2011,7 +2011,7 @@ KNComposer::Editor::~Editor() //----------------------------------------------------------------------------- bool KNComposer::Editor::eventFilter(TQObject*o, TQEvent* e) { - if (o == this) + if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this)) KCursor::autoHideEventFilter(o, e); if (e->type() == TQEvent::KeyPress) @@ -2046,7 +2046,7 @@ bool KNComposer::Editor::eventFilter(TQObject*o, TQEvent* e) if( !paraText.at(charPos).isSpace() ) { //Get word right clicked on - firstSpace = paraText.findRev( m_bound, charPos ) + 1; + firstSpace = paraText.tqfindRev( m_bound, charPos ) + 1; lastSpace = paraText.tqfind( m_bound, charPos ); if( lastSpace == -1 ) lastSpace = paraText.length(); @@ -2152,7 +2152,7 @@ TQStringList KNComposer::Editor::processedText() void KNComposer::Editor::slotPasteAsQuotation() { - TQString s = TQApplication::clipboard()->text(); + TQString s = TQApplication::tqclipboard()->text(); if (!s.isEmpty()) { for (int i=0; (uint)i<s.length(); i++) { if ( s[i] < ' ' && s[i] != '\n' && s[i] != '\t' ) @@ -2177,7 +2177,7 @@ void KNComposer::Editor::slotSearchAgain() void KNComposer::Editor::slotReplace() { - tqreplace(); + replace(); } @@ -2233,7 +2233,7 @@ void KNComposer::Editor::slotAddBox() } else { int l = currentLine(); int c = currentColumn(); - TQString s = TQString::tqfromLatin1(",----[ ]\n| %1\n`----").arg(textLine(l)); + TQString s = TQString::tqfromLatin1(",----[ ]\n| %1\n`----").tqarg(textLine(l)); insertLine(s,l); removeLine(l+3); setCursorPosition(l+1,c+2); @@ -2398,7 +2398,7 @@ void KNComposer::Editor::contentsContextMenuEvent( TQContextMenuEvent */*e*/ ) } else { - spell = new KSpell(this, i18n("Spellcheck"), this, TQT_SLOT(slotSpellStarted(KSpell *))); + spell = new KSpell(this, i18n("Spellcheck"), TQT_TQOBJECT(this), TQT_SLOT(slotSpellStarted(KSpell *))); TQStringList l = KSpellingHighlighter::personalWords(); for ( TQStringList::Iterator it = l.begin(); it != l.end(); ++it ) { spell->addPersonal( *it ); @@ -2423,7 +2423,7 @@ void KNComposer::Editor::slotSpellDone(const TQString &/*newtext*/) void KNComposer::Editor::slotSpellFinished() { - KSpell::spelltqStatus status=spell->status(); + KSpell::spellStatus status=spell->status(); delete spell; spell=0; @@ -2560,7 +2560,7 @@ KNComposer::AttachmentPropertiesDlg::AttachmentPropertiesDlg(KNAttachment *a, TQ fileL->addRowSpacing(0, fontMetrics().lineSpacing()-9); fileL->addWidget(new TQLabel(i18n("Name:"), fileGB) ,1,0); - fileL->addWidget(new TQLabel(TQString("<b>%1</b>").arg(a->name()), fileGB), 1,1, TQt::AlignLeft); + fileL->addWidget(new TQLabel(TQString("<b>%1</b>").tqarg(a->name()), fileGB), 1,1, TQt::AlignLeft); fileL->addWidget(new TQLabel(i18n("Size:"), fileGB), 2,0); fileL->addWidget(new TQLabel(a->contentSize(), fileGB), 2,1, TQt::AlignLeft); diff --git a/knode/knconfig.cpp b/knode/knconfig.cpp index a75343867..608e625a9 100644 --- a/knode/knconfig.cpp +++ b/knode/knconfig.cpp @@ -452,7 +452,7 @@ TQColor KNConfig::Appearance::defaultColor(int i) const switch(i) { case background: - return kapp->palette().active().base(); + return kapp->tqpalette().active().base(); case alternateBackground: return KGlobalSettings::alternateBackgroundColor(); @@ -466,13 +466,13 @@ TQColor KNConfig::Appearance::defaultColor(int i) const case normalText: case unreadThread: - return kapp->palette().active().text(); + return kapp->tqpalette().active().text(); case url: return KGlobalSettings::linkColor(); case readThread: - return kapp->palette().disabled().text(); + return kapp->tqpalette().disabled().text(); case unreadArticle: return TQColor( 183, 154, 11 ); @@ -492,7 +492,7 @@ TQColor KNConfig::Appearance::defaultColor(int i) const return TQColor( 0xFF, 0x40, 0x40 ); } - return kapp->palette().disabled().text(); + return kapp->tqpalette().disabled().text(); } @@ -801,7 +801,7 @@ void KNConfig::DisplayedHeaders::remove(KNDisplayedHeader *h) void KNConfig::DisplayedHeaders::up(KNDisplayedHeader *h) { - int idx = mHeaderList.findIndex( h ); + int idx = mHeaderList.tqfindIndex( h ); if ( idx != -1 ) { mHeaderList.remove( mHeaderList.at( idx ) ); mHeaderList.insert( mHeaderList.at( idx - 1 ), h ); @@ -812,7 +812,7 @@ void KNConfig::DisplayedHeaders::up(KNDisplayedHeader *h) void KNConfig::DisplayedHeaders::down(KNDisplayedHeader *h) { - int idx = mHeaderList.findIndex( h ); + int idx = mHeaderList.tqfindIndex( h ); if ( idx != -1 ) { mHeaderList.remove( mHeaderList.at( idx ) ); mHeaderList.insert( mHeaderList.at( idx + 1 ), h ); @@ -1175,10 +1175,10 @@ bool KNConfig::Cleanup::expireToday() return false; TQDate today = TQDate::tqcurrentDate(); - if (mLastExpDate == today) + if (mLastExpDate == TQDateTime(today)) return false; - return (mLastExpDate.daysTo( today ) >= e_xpireInterval); + return (mLastExpDate.daysTo( TQDateTime(today) ) >= e_xpireInterval); } @@ -1194,10 +1194,10 @@ bool KNConfig::Cleanup::compactToday() return false; TQDate today = TQDate::tqcurrentDate(); - if (mLastCompDate == today) + if (mLastCompDate == TQDateTime(today)) return false; - return (mLastCompDate.daysTo( today ) >= c_ompactInterval); + return (mLastCompDate.daysTo( TQDateTime(today) ) >= c_ompactInterval); } diff --git a/knode/knconfigwidgets.cpp b/knode/knconfigwidgets.cpp index e02338fa6..dd7012c2c 100644 --- a/knode/knconfigwidgets.cpp +++ b/knode/knconfigwidgets.cpp @@ -294,7 +294,7 @@ KNConfig::NntpAccountListWidget::NntpAccountListWidget(TQWidget *p, const char * topL->addMultiCellWidget(l_box, 0,4, 0,0); // info box - TQGroupBox *gb = new TQGroupBox(2,TQt::Vertical,TQString(),this); + TQGroupBox *gb = new TQGroupBox(2,Qt::Vertical,TQString(),this); topL->addWidget(gb,5,0); s_erverInfo = new TQLabel(gb); @@ -395,8 +395,8 @@ void KNConfig::NntpAccountListWidget::slotSelectionChanged() LBoxItem *it = static_cast<LBoxItem*>(l_box->item(curr)); if(it) { - s_erverInfo->setText(i18n("Server: %1").arg(it->account->server())); - p_ortInfo->setText(i18n("Port: %1").arg(it->account->port())); + s_erverInfo->setText(i18n("Server: %1").tqarg(it->account->server())); + p_ortInfo->setText(i18n("Port: %1").tqarg(it->account->port())); } else { s_erverInfo->setText(i18n("Server: ")); @@ -461,7 +461,7 @@ void KNConfig::NntpAccountListWidget::slotSubBtnClicked() 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"), + : KDialogBase(Tabbed, (a->id()!=-1)? i18n("Properties of %1").tqarg(a->name()):i18n("New Account"), Ok|Cancel|Help, Ok, p, n), a_ccount(a) { @@ -773,7 +773,7 @@ int KNConfig::AppearanceWidget::ColorListItem::width(const TQListBox *lb ) const KNConfig::AppearanceWidget::FontListItem::FontListItem( const TQString &name, const TQFont &font ) : TQListBoxText(name), f_ont(font) { - fontInfo = TQString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); + fontInfo = TQString("[%1 %2]").tqarg(f_ont.family()).tqarg(f_ont.pointSize()); } @@ -785,7 +785,7 @@ KNConfig::AppearanceWidget::FontListItem::~FontListItem() void KNConfig::AppearanceWidget::FontListItem::setFont(const TQFont &font) { f_ont = font; - fontInfo = TQString("[%1 %2]").arg(f_ont.family()).arg(f_ont.pointSize()); + fontInfo = TQString("[%1 %2]").tqarg(f_ont.family()).tqarg(f_ont.pointSize()); } @@ -2158,7 +2158,7 @@ TQString KNConfig::XHeaderConfDialog::result() TQString value = v_alue->text(); // just in case someone pastes a newline value.tqreplace( '\n', ' ' ); - return TQString( "X-%1: %2" ).arg( n_ame->text() ).arg( value ); + return TQString( "X-%1: %2" ).tqarg( n_ame->text() ).tqarg( value ); } @@ -2372,7 +2372,7 @@ KNConfig::GroupCleanupWidget::GroupCleanupWidget( Cleanup *data, TQWidget *tqpar } mExpGroup = new TQGroupBox( i18n("Newsgroup Cleanup Settings"), this ); - mExpGroup->setColumnLayout(0, TQt::Vertical ); + mExpGroup->setColumnLayout(0, Qt::Vertical ); mExpGroup->tqlayout()->setSpacing( KDialog::spacingHint() ); mExpGroup->tqlayout()->setMargin( KDialog::marginHint() ); top->addWidget( mExpGroup ); @@ -2481,7 +2481,7 @@ KNConfig::CleanupWidget::CleanupWidget( TQWidget *p, const char *n ) : // === folders ========================================================= TQGroupBox *foldersB=new TQGroupBox(i18n("Folders"), this); - foldersB->setColumnLayout(0, TQt::Vertical ); + foldersB->setColumnLayout(0, Qt::Vertical ); foldersB->tqlayout()->setSpacing( KDialog::spacingHint() ); foldersB->tqlayout()->setMargin( KDialog::marginHint() ); diff --git a/knode/knconvert.cpp b/knode/knconvert.cpp index e925c26d4..da039f54a 100644 --- a/knode/knconvert.cpp +++ b/knode/knconvert.cpp @@ -73,7 +73,7 @@ KNConvert::KNConvert(const TQString &version) 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 \ 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); +will be created before the conversion starts.").tqarg(KNODE_VERSION), w_1); w1L->addMultiCellWidget(l1, 0,0, 0,2); c_reateBkup=new TQCheckBox(i18n("Create backup of old data"), w_1); @@ -224,7 +224,7 @@ void KNConvert::slotTarExited(KProcess *proc) delete t_ar; t_ar = 0; if(success) - l_og.append(i18n("created backup of the old data-files in %1").arg(b_ackupPath->text())); + l_og.append(i18n("created backup of the old data-files in %1").tqarg(b_ackupPath->text())); else l_og.append(i18n("backup failed.")); @@ -402,7 +402,7 @@ int KNConvert::Converter04::convertFolder(TQString srcPrefix, TQString dstPrefix TQCString buff(size+10); srcMBox.at(oldIdx.so); int readBytes=srcMBox.readBlock(buff.data(), size); - buff.at(readBytes)='\0'; //terminate string; + buff.tqat(readBytes)='\0'; //terminate string; //remove "X-KNode-Overview" int pos=buff.tqfind('\n'); diff --git a/knode/knfilterdialog.cpp b/knode/knfilterdialog.cpp index 0cd0b2ad6..399c0078b 100644 --- a/knode/knfilterdialog.cpp +++ b/knode/knfilterdialog.cpp @@ -31,7 +31,7 @@ KNFilterDialog::KNFilterDialog(KNArticleFilter *f, TQWidget *tqparent, const char *name) - : KDialogBase(Plain, (f->id()==-1)? i18n("New Filter"):i18n("Properties of %1").arg(f->name()), + : KDialogBase(Plain, (f->id()==-1)? i18n("New Filter"):i18n("Properties of %1").tqarg(f->name()), Ok|Cancel|Help, Ok, tqparent, name), fltr(f) { diff --git a/knode/knfiltermanager.cpp b/knode/knfiltermanager.cpp index 0d01698e1..70f00b711 100644 --- a/knode/knfiltermanager.cpp +++ b/knode/knfiltermanager.cpp @@ -369,7 +369,7 @@ void KNFilterManager::slotShowFilterChooser() int currentItem=0; if (currFilter) - currentItem=ids.findIndex(currFilter->id()); + currentItem=ids.tqfindIndex(currFilter->id()); if (currentItem==-1) currentItem=0; diff --git a/knode/knfolder.cpp b/knode/knfolder.cpp index 0044abc8b..4984b69a2 100644 --- a/knode/knfolder.cpp +++ b/knode/knfolder.cpp @@ -44,7 +44,7 @@ KNFolder::KNFolder() KNFolder::KNFolder(int id, const TQString &name, KNFolder *tqparent) : KNArticleCollection(tqparent), i_d(id), i_ndexDirty(false), w_asOpen(true) { - TQString fname=path()+TQString("custom_%1").arg(i_d); + TQString fname=path()+TQString("custom_%1").tqarg(i_d); n_ame = name; m_boxFile.setName(fname+".mbox"); @@ -63,7 +63,7 @@ KNFolder::KNFolder(int id, const TQString &name, KNFolder *tqparent) KNFolder::KNFolder(int id, const TQString &name, const TQString &prefix, KNFolder *tqparent) : KNArticleCollection(tqparent), i_d(id), i_ndexDirty(false), w_asOpen(true) { - TQString fname=path()+TQString("%1_%2").arg(prefix).arg(i_d); + TQString fname=path()+TQString("%1_%2").tqarg(prefix).tqarg(i_d); n_ame = name; m_boxFile.setName(fname+".mbox"); @@ -356,7 +356,7 @@ bool KNFolder::loadArticle(KNLocalArticle *a) } //set content - buff.at(readBytes)='\0'; //terminate string + buff.tqat(readBytes)='\0'; //terminate string a->setContent(buff); a->parse(); diff --git a/knode/knfoldermanager.cpp b/knode/knfoldermanager.cpp index bdcbed4a2..c1c2d2e8a 100644 --- a/knode/knfoldermanager.cpp +++ b/knode/knfoldermanager.cpp @@ -326,7 +326,7 @@ void KNFolderManager::importFromMBox(KNFolder *f) int readBytes=file->readBlock(buff.data(), size); if (readBytes != -1) { - buff.at(readBytes)='\0'; //terminate string + buff.tqat(readBytes)='\0'; //terminate string art = new KNLocalArticle(0); art->setEditDisabled(true); art->setContent(buff); @@ -345,7 +345,7 @@ void KNFolderManager::importFromMBox(KNFolder *f) int readBytes=file->readBlock(buff.data(), size); if (readBytes != -1) { - buff.at(readBytes)='\0'; //terminate string + buff.tqat(readBytes)='\0'; //terminate string art = new KNLocalArticle(0); art->setEditDisabled(true); art->setContent(buff); diff --git a/knode/kngroup.cpp b/knode/kngroup.cpp index 1815027c0..aad26b8b3 100644 --- a/knode/kngroup.cpp +++ b/knode/kngroup.cpp @@ -453,14 +453,14 @@ void KNGroup::insortNewHeaders(TQStrList *hdrs, TQStrList *hdrfmt, KNProtocolCli // optinal additional headers mOptionalHeaders = *hdrfmt; - for (hdr = hdrfmt->first(); hdr; hdr = hdrfmt->next()) { + for (hdr = hdrfmt->first(); !hdr.isNull(); hdr = hdrfmt->next()) { if (!split.next()) break; data = split.string(); int pos = hdr.tqfind(':'); hdrName = hdr.left( pos ); // if the header format is 'full' we have to strip the header name - if (hdr.findRev("full") == (int)(hdr.length() - 4)) + if (hdr.tqfindRev("full") == (int)(hdr.length() - 4)) data = data.right( data.length() - (hdrName.length() + 2) ); // add header @@ -557,7 +557,7 @@ int KNGroup::saveStaticData(int cnt,bool ovr) // optional headers ts << mOptionalHeaders.count() << '\n'; - for (TQCString hdrName = mOptionalHeaders.first(); hdrName; hdrName = mOptionalHeaders.next()) { + for (TQCString hdrName = mOptionalHeaders.first(); !hdrName.isNull(); hdrName = mOptionalHeaders.next()) { hdrName = hdrName.left( hdrName.tqfind(':') ); KMime::Headers::Base *hdr = art->getHeaderByType( hdrName ); if ( hdr ) @@ -701,7 +701,7 @@ void KNGroup::buildThreads(int cnt, KNProtocolClient *client) art=at(idx); if(art->threadingLevel()>1) { oldRef=art->idRef(); - ref=findReference(art); + ref=tqfindReference(art); if(ref) { // this method is called from the nntp-thread!!! #ifndef NDEBUG @@ -720,7 +720,7 @@ void KNGroup::buildThreads(int cnt, KNProtocolClient *client) if(art->idRef()==-1 && !art->references()->isEmpty() ){ //hdr has references refCnt++; - if(findReference(art)) + if(tqfindReference(art)) foundCnt++; } else { @@ -866,7 +866,7 @@ void KNGroup::buildThreads(int cnt, KNProtocolClient *client) } -KNRemoteArticle* KNGroup::findReference(KNRemoteArticle *a) +KNRemoteArticle* KNGroup::tqfindReference(KNRemoteArticle *a) { int found=false; TQCString ref_mid; @@ -1052,7 +1052,7 @@ TQString KNGroup::prepareForExecution() if (knGlobals.groupManager()->loadHeaders(this)) return TQString(); else - return i18n("Cannot load saved headers: %1").arg(groupname()); + return i18n("Cannot load saved headers: %1").tqarg(groupname()); } //*************************************************************************** diff --git a/knode/kngroup.h b/knode/kngroup.h index 387ff0f6e..b0c31f93f 100644 --- a/knode/kngroup.h +++ b/knode/kngroup.h @@ -134,7 +134,7 @@ class KNGroup : public KNArticleCollection , public KNJobItem { protected: void buildThreads(int cnt, KNProtocolClient *client=0); - KNRemoteArticle* findReference(KNRemoteArticle *a); + KNRemoteArticle* tqfindReference(KNRemoteArticle *a); int n_ewCount, l_astFetchCount, diff --git a/knode/kngroupbrowser.cpp b/knode/kngroupbrowser.cpp index d28e9ed92..c3ab27d98 100644 --- a/knode/kngroupbrowser.cpp +++ b/knode/kngroupbrowser.cpp @@ -358,7 +358,7 @@ void KNGroupBrowser::slotFilter(const TQString &txt) lastFilter = filtertxt; incrementalFilter = !isRegexp; - leftLabel->setText(i18n("Groups on %1: (%2 displayed)").arg(a_ccount->name()).arg(matchList->count())); + leftLabel->setText(i18n("Groups on %1: (%2 displayed)").tqarg(a_ccount->name()).tqarg(matchList->count())); arrowBtn1->setEnabled(false); arrowBtn2->setEnabled(false); diff --git a/knode/kngroupdialog.cpp b/knode/kngroupdialog.cpp index eadaf06b9..4d86178fb 100644 --- a/knode/kngroupdialog.cpp +++ b/knode/kngroupdialog.cpp @@ -177,17 +177,17 @@ void KNGroupDialog::setButtonDirection(arrowButton b, arrowDirection d) void KNGroupDialog::slotItemSelected(TQListViewItem *it) { - const TQObject *s=sender(); + const TQObject *s=TQT_TQOBJECT(sender()); - if(s==subView) { + if(TQT_BASE_OBJECT_CONST(s)==TQT_BASE_OBJECT(subView)) { unsubView->clearSelection(); groupView->clearSelection(); arrowBtn2->setEnabled(false); arrowBtn1->setEnabled(true); setButtonDirection(btn1, left); } - else if(s==unsubView) { + else if(TQT_BASE_OBJECT_CONST(s)==TQT_BASE_OBJECT(unsubView)) { subView->clearSelection(); groupView->clearSelection(); arrowBtn1->setEnabled(false); diff --git a/knode/kngroupmanager.cpp b/knode/kngroupmanager.cpp index 48cfc117c..151efa0f0 100644 --- a/knode/kngroupmanager.cpp +++ b/knode/kngroupmanager.cpp @@ -449,7 +449,7 @@ bool KNGroupManager::unsubscribeGroup(KNGroup *g) if(!g) return false; if((g->isLocked()) || (g->lockedArticles()>0)) { - KMessageBox::sorry(knGlobals.topWidget, i18n("The group \"%1\" is being updated currently.\nIt is not possible to unsubscribe from it at the moment.").arg(g->groupname())); + KMessageBox::sorry(knGlobals.topWidget, i18n("The group \"%1\" is being updated currently.\nIt is not possible to unsubscribe from it at the moment.").tqarg(g->groupname())); return false; } diff --git a/knode/kngrouppropdlg.cpp b/knode/kngrouppropdlg.cpp index ef8e28700..d5cd71755 100644 --- a/knode/kngrouppropdlg.cpp +++ b/knode/kngrouppropdlg.cpp @@ -30,7 +30,7 @@ KNGroupPropDlg::KNGroupPropDlg(KNGroup *group, TQWidget *tqparent, const char *name ) - : KDialogBase(Tabbed, i18n("Properties of %1").arg(group->groupname()), + : KDialogBase(Tabbed, i18n("Properties of %1").tqarg(group->groupname()), Ok|Cancel|Help, Ok, tqparent, name), g_rp(group), n_ickChanged(false) { diff --git a/knode/kngroupselectdialog.cpp b/knode/kngroupselectdialog.cpp index d5188ad1f..0476442b3 100644 --- a/knode/kngroupselectdialog.cpp +++ b/knode/kngroupselectdialog.cpp @@ -114,9 +114,9 @@ TQString KNGroupSelectDialog::selectedGroups()const void KNGroupSelectDialog::slotItemSelected(TQListViewItem *it) { - const TQObject *s=sender(); + const TQObject *s=TQT_TQOBJECT(sender()); - if(s==groupView) { + if(TQT_BASE_OBJECT_CONST(s)==TQT_BASE_OBJECT(groupView)) { selView->clearSelection(); arrowBtn2->setEnabled(false); if(it) diff --git a/knode/knhdrviewitem.cpp b/knode/knhdrviewitem.cpp index 748bcb4f5..207d22ba4 100644 --- a/knode/knhdrviewitem.cpp +++ b/knode/knhdrviewitem.cpp @@ -159,7 +159,7 @@ void KNHdrViewItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column, TQString t2; TQFont f2; if (countUnreadInThread() > 0 && column == paintInfo->subCol && !isOpen()) { - t2 = TQString( " (%1)" ).arg( countUnreadInThread() ); + t2 = TQString( " (%1)" ).tqarg( countUnreadInThread() ); f2 = p->font(); f2.setBold( true ); cntWidth = TQFontMetrics( f2 ).width( t2, -1 ); diff --git a/knode/knmainwidget.cpp b/knode/knmainwidget.cpp index 8da3b97ee..45738c37a 100644 --- a/knode/knmainwidget.cpp +++ b/knode/knmainwidget.cpp @@ -550,113 +550,113 @@ void KNMainWidget::initActions() //navigation a_ctNavNextArt = new KAction( KGuiItem(i18n("&Next Article"), "next", - i18n("Go to next article")), "N;Right", h_drView, + i18n("Go to next article")), "N;Right", TQT_TQOBJECT(h_drView), TQT_SLOT(nextArticle()), actionCollection(), "go_nextArticle" ); a_ctNavPrevArt = new KAction( KGuiItem(i18n("&Previous Article"), "previous", - i18n("Go to previous article")), "P;Left" , h_drView, + i18n("Go to previous article")), "P;Left" , TQT_TQOBJECT(h_drView), TQT_SLOT(prevArticle()), actionCollection(), "go_prevArticle" ); - a_ctNavNextUnreadArt = new KAction(i18n("Next Unread &Article"), "1rightarrow", ALT+SHIFT+Key_Space , this, + a_ctNavNextUnreadArt = new KAction(i18n("Next Unread &Article"), "1rightarrow", ALT+SHIFT+Key_Space , TQT_TQOBJECT(this), TQT_SLOT(slotNavNextUnreadArt()), actionCollection(), "go_nextUnreadArticle"); - a_ctNavNextUnreadThread = new KAction(i18n("Next Unread &Thread"),"2rightarrow", SHIFT+Key_Space , this, + a_ctNavNextUnreadThread = new KAction(i18n("Next Unread &Thread"),"2rightarrow", SHIFT+Key_Space , TQT_TQOBJECT(this), TQT_SLOT(slotNavNextUnreadThread()), actionCollection(), "go_nextUnreadThread"); - a_ctNavNextGroup = new KAction(i18n("Ne&xt Group"), "down", Key_Plus , c_olView, + a_ctNavNextGroup = new KAction(i18n("Ne&xt Group"), "down", Key_Plus , TQT_TQOBJECT(c_olView), TQT_SLOT(nextGroup()), actionCollection(), "go_nextGroup"); - a_ctNavPrevGroup = new KAction(i18n("Pre&vious Group"), "up", Key_Minus , c_olView, + a_ctNavPrevGroup = new KAction(i18n("Pre&vious Group"), "up", Key_Minus , TQT_TQOBJECT(c_olView), TQT_SLOT(prevGroup()), actionCollection(), "go_prevGroup"); - a_ctNavReadThrough = new KAction(i18n("Read &Through Articles"), Key_Space , this, + a_ctNavReadThrough = new KAction(i18n("Read &Through Articles"), Key_Space , TQT_TQOBJECT(this), TQT_SLOT(slotNavReadThrough()), actionCollection(), "go_readThrough"); a_ctNavReadThrough->plugAccel(a_ccel); TQAccel *accel = new TQAccel( this ); - new KAction( i18n("Focus on Next Folder"), CTRL+Key_Right, c_olView, + new KAction( i18n("Focus on Next Folder"), CTRL+Key_Right, TQT_TQOBJECT(c_olView), TQT_SLOT(incCurrentFolder()), actionCollection(), "inc_current_folder" ); accel->connectItem(accel->insertItem(CTRL+Key_Right), c_olView, TQT_SLOT(incCurrentFolder())); - new KAction( i18n("Focus on Previous Folder"), CTRL+Key_Left, c_olView, + new KAction( i18n("Focus on Previous Folder"), CTRL+Key_Left, TQT_TQOBJECT(c_olView), TQT_SLOT(decCurrentFolder()), actionCollection(), "dec_current_folder" ); accel->connectItem(accel->insertItem(CTRL+Key_Left), c_olView, TQT_SLOT(decCurrentFolder())); - new KAction( i18n("Select Folder with Focus"), CTRL+Key_Space, c_olView, + new KAction( i18n("Select Folder with Focus"), CTRL+Key_Space, TQT_TQOBJECT(c_olView), TQT_SLOT(selectCurrentFolder()), actionCollection(), "select_current_folder" ); accel->connectItem(accel->insertItem(CTRL+Key_Space), c_olView, TQT_SLOT(selectCurrentFolder())); - new KAction( i18n("Focus on Next Article"), ALT+Key_Right, h_drView, + new KAction( i18n("Focus on Next Article"), ALT+Key_Right, TQT_TQOBJECT(h_drView), TQT_SLOT(incCurrentArticle()), actionCollection(), "inc_current_article" ); accel->connectItem( accel->insertItem(ALT+Key_Right), - h_drView, TQT_SLOT(incCurrentArticle()) ); - new KAction( i18n("Focus on Previous Article"), ALT+Key_Left, h_drView, + TQT_TQOBJECT(h_drView), TQT_SLOT(incCurrentArticle()) ); + new KAction( i18n("Focus on Previous Article"), ALT+Key_Left, TQT_TQOBJECT(h_drView), TQT_SLOT(decCurrentArticle()), actionCollection(), "dec_current_article" ); accel->connectItem( accel->insertItem(ALT+Key_Left), - h_drView, TQT_SLOT(decCurrentArticle()) ); - new KAction( i18n("Select Article with Focus"), ALT+Key_Space, h_drView, + TQT_TQOBJECT(h_drView), TQT_SLOT(decCurrentArticle()) ); + new KAction( i18n("Select Article with Focus"), ALT+Key_Space, TQT_TQOBJECT(h_drView), TQT_SLOT(selectCurrentArticle()), actionCollection(), "select_current_article" ); accel->connectItem( accel->insertItem(ALT+Key_Space), - h_drView, TQT_SLOT(selectCurrentArticle()) ); + TQT_TQOBJECT(h_drView), TQT_SLOT(selectCurrentArticle()) ); //collection-view - accounts - a_ctAccProperties = new KAction(i18n("Account &Properties"), "configure", 0, this, + a_ctAccProperties = new KAction(i18n("Account &Properties"), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccProperties()), actionCollection(), "account_properties"); - a_ctAccRename = new KAction(i18n("&Rename Account"), "text", 0, this, + a_ctAccRename = new KAction(i18n("&Rename Account"), "text", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccRename()), actionCollection(), "account_rename"); - a_ctAccSubscribe = new KAction(i18n("&Subscribe to Newsgroups..."), "news_subscribe", 0, this, + a_ctAccSubscribe = new KAction(i18n("&Subscribe to Newsgroups..."), "news_subscribe", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccSubscribe()), actionCollection(), "account_subscribe"); - a_ctAccExpireAll = new KAction(i18n("&Expire All Groups"), 0, this, + a_ctAccExpireAll = new KAction(i18n("&Expire All Groups"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccExpireAll()), actionCollection(), "account_expire_all"); - a_ctAccGetNewHdrs = new KAction(i18n("&Get New Articles in All Groups"), "mail_get", 0, this, + a_ctAccGetNewHdrs = new KAction(i18n("&Get New Articles in All Groups"), "mail_get", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccGetNewHdrs()), actionCollection(), "account_dnlHeaders"); - a_ctAccGetNewHdrsAll = new KAction(i18n("&Get New Articles in All Accounts"), "mail_get_all", 0, this, + a_ctAccGetNewHdrsAll = new KAction(i18n("&Get New Articles in All Accounts"), "mail_get_all", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccGetNewHdrsAll()), actionCollection(), "account_dnlAllHeaders"); - a_ctAccDelete = new KAction(i18n("&Delete Account"), "editdelete", 0, this, + a_ctAccDelete = new KAction(i18n("&Delete Account"), "editdelete", 0, TQT_TQOBJECT(this), TQT_SLOT(slotAccDelete()), actionCollection(), "account_delete"); - a_ctAccPostNewArticle = new KAction(i18n("&Post to Newsgroup..."), "mail_new", CTRL+Key_N, this, + a_ctAccPostNewArticle = new KAction(i18n("&Post to Newsgroup..."), "mail_new", CTRL+Key_N, TQT_TQOBJECT(this), TQT_SLOT(slotAccPostNewArticle()), actionCollection(), "article_postNew"); //collection-view - groups - a_ctGrpProperties = new KAction(i18n("Group &Properties"), "configure", 0, this, + a_ctGrpProperties = new KAction(i18n("Group &Properties"), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpProperties()), actionCollection(), "group_properties"); - a_ctGrpRename = new KAction(i18n("Rename &Group"), "text", 0, this, + a_ctGrpRename = new KAction(i18n("Rename &Group"), "text", 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpRename()), actionCollection(), "group_rename"); - a_ctGrpGetNewHdrs = new KAction(i18n("&Get New Articles"), "mail_get" , 0, this, + a_ctGrpGetNewHdrs = new KAction(i18n("&Get New Articles"), "mail_get" , 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpGetNewHdrs()), actionCollection(), "group_dnlHeaders"); - a_ctGrpExpire = new KAction(i18n("E&xpire Group"), "wizard", 0, this, + a_ctGrpExpire = new KAction(i18n("E&xpire Group"), "wizard", 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpExpire()), actionCollection(), "group_expire"); - a_ctGrpReorganize = new KAction(i18n("Re&organize Group"), 0, this, + a_ctGrpReorganize = new KAction(i18n("Re&organize Group"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpReorganize()), actionCollection(), "group_reorg"); - a_ctGrpUnsubscribe = new KAction(i18n("&Unsubscribe From Group"), "news_unsubscribe", 0, this, + a_ctGrpUnsubscribe = new KAction(i18n("&Unsubscribe From Group"), "news_unsubscribe", 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpUnsubscribe()), actionCollection(), "group_unsubscribe"); - a_ctGrpSetAllRead = new KAction(i18n("Mark All as &Read"), "goto", 0, this, + a_ctGrpSetAllRead = new KAction(i18n("Mark All as &Read"), "goto", 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpSetAllRead()), actionCollection(), "group_allRead"); - a_ctGrpSetAllUnread = new KAction(i18n("Mark All as U&nread"), 0, this, + a_ctGrpSetAllUnread = new KAction(i18n("Mark All as U&nread"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpSetAllUnread()), actionCollection(), "group_allUnread"); - a_ctGrpSetUnread = new KAction(i18n("Mark Last as Unr&ead..."), 0, this, + a_ctGrpSetUnread = new KAction(i18n("Mark Last as Unr&ead..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotGrpSetUnread()), actionCollection(), "group_unread"); (void) new KAction( i18n("&Configure KNode..."), - "configure", 0, this, + "configure", 0, TQT_TQOBJECT(this), TQT_SLOT(slotSettings()), actionCollection(), "knode_configure_knode" ); //collection-view - folder - a_ctFolNew = new KAction(i18n("&New Folder"), "folder_new", 0, this, + a_ctFolNew = new KAction(i18n("&New Folder"), "folder_new", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolNew()), actionCollection(), "folder_new"); - a_ctFolNewChild = new KAction(i18n("New &Subfolder"), "folder_new", 0, this, + a_ctFolNewChild = new KAction(i18n("New &Subfolder"), "folder_new", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolNewChild()), actionCollection(), "folder_newChild"); - a_ctFolDelete = new KAction(i18n("&Delete Folder"), "editdelete", 0, this, + a_ctFolDelete = new KAction(i18n("&Delete Folder"), "editdelete", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolDelete()), actionCollection(), "folder_delete"); - a_ctFolRename = new KAction(i18n("&Rename Folder"), "text", 0, this, + a_ctFolRename = new KAction(i18n("&Rename Folder"), "text", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolRename()), actionCollection(), "folder_rename"); - a_ctFolCompact = new KAction(i18n("C&ompact Folder"), "wizard", 0, this, + a_ctFolCompact = new KAction(i18n("C&ompact Folder"), "wizard", 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolCompact()), actionCollection(), "folder_compact"); - a_ctFolCompactAll = new KAction(i18n("Co&mpact All Folders"), 0, this, + a_ctFolCompactAll = new KAction(i18n("Co&mpact All Folders"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolCompactAll()), actionCollection(), "folder_compact_all"); - a_ctFolEmpty = new KAction(i18n("&Empty Folder"), 0, this, + a_ctFolEmpty = new KAction(i18n("&Empty Folder"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolEmpty()), actionCollection(), "folder_empty"); - a_ctFolMboxImport = new KAction(i18n("&Import MBox Folder..."), 0, this, + a_ctFolMboxImport = new KAction(i18n("&Import MBox Folder..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolMBoxImport()), actionCollection(), "folder_MboxImport"); - a_ctFolMboxExport = new KAction(i18n("E&xport as MBox Folder..."), 0, this, + a_ctFolMboxExport = new KAction(i18n("E&xport as MBox Folder..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFolMBoxExport()), actionCollection(), "folder_MboxExport"); //header-view - list-handling @@ -670,7 +670,7 @@ void KNMainWidget::initActions() a_ctArtSortHeaders->setItems(items); a_ctArtSortHeaders->setShortcutConfigurable(false); connect(a_ctArtSortHeaders, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotArtSortHeaders(int))); - a_ctArtSortHeadersKeyb = new KAction(i18n("Sort"), TQString(), Key_F7 , this, + a_ctArtSortHeadersKeyb = new KAction(i18n("Sort"), TQString(), Key_F7 , TQT_TQOBJECT(this), TQT_SLOT(slotArtSortHeadersKeyb()), actionCollection(), "view_Sort_Keyb"); a_ctArtSortHeadersKeyb->plugAccel(a_ccel); a_ctArtFilter = new KNFilterSelectAction(i18n("&Filter"), "filter", @@ -678,86 +678,86 @@ void KNMainWidget::initActions() a_ctArtFilter->setShortcutConfigurable(false); 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_tqfind" , Key_F4 , this, + a_ctArtSearch = new KAction(i18n("&Search Articles..."),"mail_tqfind" , Key_F4 , TQT_TQOBJECT(this), TQT_SLOT(slotArtSearch()), actionCollection(), "article_search"); - a_ctArtRefreshList = new KAction(i18n("&Refresh List"),"reload", KStdAccel::shortcut(KStdAccel::Reload), this, + a_ctArtRefreshList = new KAction(i18n("&Refresh List"),"reload", KStdAccel::shortcut(KStdAccel::Reload), TQT_TQOBJECT(this), TQT_SLOT(slotArtRefreshList()), actionCollection(), "view_Refresh"); - a_ctArtCollapseAll = new KAction(i18n("&Collapse All Threads"), 0 , this, + a_ctArtCollapseAll = new KAction(i18n("&Collapse All Threads"), 0 , TQT_TQOBJECT(this), TQT_SLOT(slotArtCollapseAll()), actionCollection(), "view_CollapseAll"); - a_ctArtExpandAll = new KAction(i18n("E&xpand All Threads"), 0 , this, + a_ctArtExpandAll = new KAction(i18n("E&xpand All Threads"), 0 , TQT_TQOBJECT(this), TQT_SLOT(slotArtExpandAll()), actionCollection(), "view_ExpandAll"); - a_ctArtToggleThread = new KAction(i18n("&Toggle Subthread"), Key_T, this, + a_ctArtToggleThread = new KAction(i18n("&Toggle Subthread"), Key_T, TQT_TQOBJECT(this), TQT_SLOT(slotArtToggleThread()), actionCollection(), "thread_toggle"); - a_ctArtToggleShowThreads = new KToggleAction(i18n("Show T&hreads"), 0 , this, + a_ctArtToggleShowThreads = new KToggleAction(i18n("Show T&hreads"), 0 , TQT_TQOBJECT(this), 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, + a_ctArtSetArtRead = new KAction(i18n("Mark as &Read"), Key_D , TQT_TQOBJECT(this), TQT_SLOT(slotArtSetArtRead()), actionCollection(), "article_read"); - a_ctArtSetArtUnread = new KAction(i18n("Mar&k as Unread"), Key_U , this, + a_ctArtSetArtUnread = new KAction(i18n("Mar&k as Unread"), Key_U , TQT_TQOBJECT(this), TQT_SLOT(slotArtSetArtUnread()), actionCollection(), "article_unread"); - a_ctArtSetThreadRead = new KAction(i18n("Mark &Thread as Read"), CTRL+Key_D , this, + a_ctArtSetThreadRead = new KAction(i18n("Mark &Thread as Read"), CTRL+Key_D , TQT_TQOBJECT(this), TQT_SLOT(slotArtSetThreadRead()), actionCollection(), "thread_read"); - a_ctArtSetThreadUnread = new KAction(i18n("Mark T&hread as Unread"), CTRL+Key_U , this, + a_ctArtSetThreadUnread = new KAction(i18n("Mark T&hread as Unread"), CTRL+Key_U , TQT_TQOBJECT(this), TQT_SLOT(slotArtSetThreadUnread()), actionCollection(), "thread_unread"); - a_ctArtOpenNewWindow = new KAction(i18n("Open in Own &Window"), "window_new", Key_O , this, + a_ctArtOpenNewWindow = new KAction(i18n("Open in Own &Window"), "window_new", Key_O , TQT_TQOBJECT(this), TQT_SLOT(slotArtOpenNewWindow()), actionCollection(), "article_ownWindow"); // scoring - a_ctScoresEdit = new KAction(i18n("&Edit Scoring Rules..."), "edit", CTRL+Key_E, this, + a_ctScoresEdit = new KAction(i18n("&Edit Scoring Rules..."), "edit", CTRL+Key_E, TQT_TQOBJECT(this), TQT_SLOT(slotScoreEdit()), actionCollection(), "scoreedit"); - a_ctReScore = new KAction(i18n("Recalculate &Scores"), 0, this, + a_ctReScore = new KAction(i18n("Recalculate &Scores"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotReScore()),actionCollection(),"rescore"); - a_ctScoreLower = new KAction(i18n("&Lower Score for Author..."), CTRL+Key_L, this, + a_ctScoreLower = new KAction(i18n("&Lower Score for Author..."), CTRL+Key_L, TQT_TQOBJECT(this), TQT_SLOT(slotScoreLower()), actionCollection(), "scorelower"); - a_ctScoreRaise = new KAction(i18n("&Raise Score for Author..."), CTRL+Key_I, this, + a_ctScoreRaise = new KAction(i18n("&Raise Score for Author..."), CTRL+Key_I, TQT_TQOBJECT(this), TQT_SLOT(slotScoreRaise()),actionCollection(),"scoreraise"); - a_ctArtToggleIgnored = new KAction(i18n("&Ignore Thread"), "bottom", Key_I , this, + a_ctArtToggleIgnored = new KAction(i18n("&Ignore Thread"), "bottom", Key_I , TQT_TQOBJECT(this), TQT_SLOT(slotArtToggleIgnored()), actionCollection(), "thread_ignore"); - a_ctArtToggleWatched = new KAction(i18n("&Watch Thread"), "top", Key_W , this, + a_ctArtToggleWatched = new KAction(i18n("&Watch Thread"), "top", Key_W , TQT_TQOBJECT(this), TQT_SLOT(slotArtToggleWatched()), actionCollection(), "thread_watch"); //header-view local articles - a_ctArtSendOutbox = new KAction(i18n("Sen&d Pending Messages"), "mail_send", 0, this, + a_ctArtSendOutbox = new KAction(i18n("Sen&d Pending Messages"), "mail_send", 0, TQT_TQOBJECT(this), TQT_SLOT(slotArtSendOutbox()), actionCollection(), "net_sendPending"); - a_ctArtDelete = new KAction(i18n("&Delete Article"), "editdelete", Key_Delete, this, + a_ctArtDelete = new KAction(i18n("&Delete Article"), "editdelete", Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(slotArtDelete()), actionCollection(), "article_delete"); - a_ctArtSendNow = new KAction(i18n("Send &Now"),"mail_send", 0 , this, + a_ctArtSendNow = new KAction(i18n("Send &Now"),"mail_send", 0 , TQT_TQOBJECT(this), TQT_SLOT(slotArtSendNow()), actionCollection(), "article_sendNow"); - a_ctArtEdit = new KAction(i18n("edit article","&Edit Article..."), "edit", Key_E , this, + a_ctArtEdit = new KAction(i18n("edit article","&Edit Article..."), "edit", Key_E , TQT_TQOBJECT(this), TQT_SLOT(slotArtEdit()), actionCollection(), "article_edit"); //network - a_ctNetCancel = new KAction(i18n("Stop &Network"),"stop",0, this, + a_ctNetCancel = new KAction(i18n("Stop &Network"),"stop",0, TQT_TQOBJECT(this), TQT_SLOT(slotNetCancel()), actionCollection(), "net_stop"); a_ctNetCancel->setEnabled(false); - a_ctFetchArticleWithID = new KAction(i18n("&Fetch Article with ID..."), 0, this, + a_ctFetchArticleWithID = new KAction(i18n("&Fetch Article with ID..."), 0, TQT_TQOBJECT(this), TQT_SLOT(slotFetchArticleWithID()), actionCollection(), "fetch_article_with_id"); a_ctFetchArticleWithID->setEnabled(false); - a_ctToggleGroupView = new KToggleAction(i18n("Show &Group View"), CTRL+Key_G, this, + a_ctToggleGroupView = new KToggleAction(i18n("Show &Group View"), CTRL+Key_G, TQT_TQOBJECT(this), 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, + a_ctToggleHeaderView = new KToggleAction(i18n("Show &Header View"), CTRL+Key_H, TQT_TQOBJECT(this), 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, + a_ctToggleArticleViewer = new KToggleAction(i18n("Show &Article Viewer"), CTRL+Key_J, TQT_TQOBJECT(this), TQT_SLOT(slotToggleArticleViewer()), actionCollection(), "settings_show_articleViewer"); a_ctToggleArticleViewer->setCheckedState(i18n("Hide &Article Viewer")); - a_ctToggleQuickSearch = new KToggleAction(i18n("Show Quick Search"), TQString(), this, + a_ctToggleQuickSearch = new KToggleAction(i18n("Show Quick Search"), TQString(), TQT_TQOBJECT(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, + a_ctSwitchToGroupView = new KAction(i18n("Switch to Group View"), Key_G , TQT_TQOBJECT(this), 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, + a_ctSwitchToHeaderView = new KAction(i18n("Switch to Header View"), Key_H , TQT_TQOBJECT(this), 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, + a_ctSwitchToArticleViewer = new KAction(i18n("Switch to Article Viewer"), Key_J , TQT_TQOBJECT(this), TQT_SLOT(slotSwitchToArticleViewer()), actionCollection(), "switch_to_article_viewer"); a_ctSwitchToArticleViewer->plugAccel(a_ccel); } @@ -775,7 +775,7 @@ bool KNMainWidget::firstStart() emailConf.setGroup("Defaults"); TQString group = emailConf.readEntry("Profile","Default"); - emailConf.setGroup(TQString("PROFILE_%1").arg(group)); + emailConf.setGroup(TQString("PROFILE_%1").tqarg(group)); KNConfig::Identity *id=knGlobals.configManager()->identity(); id->setName(emailConf.readEntry("FullName")); id->setEmail(emailConf.readEntry("EmailAddress").latin1()); @@ -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()), TQString(), i18n("Unsubscribe"), KStdGuiItem::cancel())) + i18n("Do you really want to unsubscribe from %1?").tqarg(g_rpManager->currentGroup()->groupname()), TQString(), i18n("Unsubscribe"), KStdGuiItem::cancel())) if (g_rpManager->unsubscribeGroup(g_rpManager->currentGroup())) slotCollectionSelected(0); } @@ -1639,7 +1639,7 @@ void KNMainWidget::slotFolEmpty() return; } if( KMessageBox::Continue == KMessageBox::warningContinueCancel( - this, i18n("Do you really want to delete all articles in %1?").arg(f_olManager->currentFolder()->name()),"",KGuiItem(i18n("&Delete"),"editdelete")) ) + this, i18n("Do you really want to delete all articles in %1?").tqarg(f_olManager->currentFolder()->name()),"",KGuiItem(i18n("&Delete"),"editdelete")) ) f_olManager->emptyFolder(f_olManager->currentFolder()); } } @@ -1948,7 +1948,7 @@ void KNMainWidget::slotFetchArticleWithID() TQString id = dlg->messageId().simplifyWhiteSpace(); if (id.tqfind(TQRegExp("*@*",false,true))!=-1) { if (id.tqfind(TQRegExp("<*>",false,true))==-1) // add "<>" when necessary - id = TQString("<%1>").arg(id); + id = TQString("<%1>").tqarg(id); if(!KNArticleWindow::raiseWindowForArticle(id.latin1())) { //article not yet opened KNRemoteArticle *a=new KNRemoteArticle(g_rpManager->currentGroup()); diff --git a/knode/knnntpaccount.cpp b/knode/knnntpaccount.cpp index 0e685531e..1795cbc58 100644 --- a/knode/knnntpaccount.cpp +++ b/knode/knnntpaccount.cpp @@ -174,7 +174,7 @@ void KNNntpAccount::saveInfo() TQString KNNntpAccount::path() { - TQString dir(locateLocal("data","knode/")+TQString("nntp.%1/").arg(i_d)); + TQString dir(locateLocal("data","knode/")+TQString("nntp.%1/").tqarg(i_d)); if (dir.isNull()) KNHelper::displayInternalFileError(); return (dir); diff --git a/knode/knnntpclient.cpp b/knode/knnntpclient.cpp index a6b1e566c..b81f13485 100644 --- a/knode/knnntpclient.cpp +++ b/knode/knnntpclient.cpp @@ -336,7 +336,7 @@ void KNNntpClient::doFetchNewHeaders() sendSignal(TSdownloadNew); errorPrefix=i18n("No new articles could be retrieved for\n%1/%2.\nThe following error occurred:\n") - .arg(account.server()).arg(target->groupname()); + .tqarg(account.server()).tqarg(target->groupname()); cmd="GROUP "; cmd+=target->groupname().utf8(); @@ -401,7 +401,7 @@ void KNNntpClient::doFetchNewHeaders() if ( sendCommand( cmd, rep ) && rep == 215 ) { TQStrList tmp; if (getMsg(tmp)) { - for(TQCString s = tmp.first(); s; s = tmp.next()) { + for(TQCString s = tmp.first(); !s.isNull(); s = tmp.next()) { s = s.stripWhiteSpace(); // remove the mandatory xover header if (s == "Subject:" || s == "From:" || s == "Date:" || s == "Message-ID:" @@ -482,7 +482,7 @@ void KNNntpClient::doFetchArticle() job->setErrorString( errorPrefix + getCurrentLine() + i18n("<br><br>The article you requested is not available on your news server." "<br>You could try to get it from <a href=\"http://groups.google.com/groups?selm=%1\">groups.google.com</a>.") - .arg( msgId ) ); + .tqarg( msgId ) ); } return; } @@ -523,7 +523,7 @@ void KNNntpClient::doPostArticle() if (art->messageID(false)==0) { // article has no message ID => search for a ID in the response TQCString s = getCurrentLine(); - int start = s.findRev(TQRegExp("<[^\\s]*@[^\\s]*>")); + int start = s.tqfindRev(TQRegExp("<[^\\s]*@[^\\s]*>")); if (start != -1) { // post response includes a recommended id int end = s.tqfind('>',start); art->messageID()->from7BitString(s.mid(start,end-start+1)); @@ -638,7 +638,7 @@ bool KNNntpClient::openConnection() #ifndef NDEBUG qDebug("knode: Authorization failed"); #endif - job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").arg(getCurrentLine())); + job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").tqarg(getCurrentLine())); job->setAuthError(true); closeConnection(); return false; @@ -695,7 +695,7 @@ bool KNNntpClient::sendCommand(const TQCString &cmd, int &rep) //qDebug("knode: Password required"); if (!account.pass().length()) { - job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").arg(getCurrentLine())); + job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").tqarg(getCurrentLine())); job->setAuthError(true); closeConnection(); return false; @@ -716,7 +716,7 @@ bool KNNntpClient::sendCommand(const TQCString &cmd, int &rep) if (!KNProtocolClient::sendCommand(cmd,rep)) // retry the original command return false; } else { - job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").arg(getCurrentLine())); + job->setErrorString(i18n("Authentication failed.\nCheck your username and password.\n\n%1").tqarg(getCurrentLine())); job->setAuthError(true); closeConnection(); return false; @@ -729,7 +729,7 @@ bool KNNntpClient::sendCommand(const TQCString &cmd, int &rep) void KNNntpClient::handleErrors() { if (errorPrefix.isEmpty()) - job->setErrorString(i18n("An error occurred:\n%1").arg(getCurrentLine())); + job->setErrorString(i18n("An error occurred:\n%1").tqarg(getCurrentLine())); else job->setErrorString(errorPrefix + getCurrentLine()); diff --git a/knode/knode.cpp b/knode/knode.cpp index 188851cfe..48748ddff 100644 --- a/knode/knode.cpp +++ b/knode/knode.cpp @@ -46,9 +46,9 @@ KNMainWindow::KNMainWindow( TQWidget* pWidget ) setStandardToolBarMenuEnabled(true); //config stuff - KStdAction::quit(kapp, TQT_SLOT(closeAllWindows()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(slotConfToolbar()), actionCollection()); - KStdAction::keyBindings(this, TQT_SLOT(slotConfKeys()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(closeAllWindows()), actionCollection()); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotConfToolbar()), actionCollection()); + KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(slotConfKeys()), actionCollection()); m_mainWidget = new KNMainWidget( this, true, this, 0 ); connect( m_mainWidget, TQT_SIGNAL(signalCaptionChangeRequest(const TQString&)), diff --git a/knode/knode_part.cpp b/knode/knode_part.cpp index 0dc09d460..ad01aef7d 100644 --- a/knode/knode_part.cpp +++ b/knode/knode_part.cpp @@ -68,13 +68,13 @@ KNodePart::KNodePart(TQWidget *tqparentWidget, const char *widgetName, // create a canvas to insert our widget TQWidget *canvas = new TQWidget(tqparentWidget, widgetName); - canvas->setFocusPolicy(TQWidget::ClickFocus); + canvas->setFocusPolicy(Qt::ClickFocus); setWidget(canvas); mainWidget = new KNMainWidget( this, false, canvas, "knode_widget" ); TQVBoxLayout *topLayout = new TQVBoxLayout(canvas); topLayout->addWidget(mainWidget); - mainWidget->setFocusPolicy(TQWidget::ClickFocus); + mainWidget->setFocusPolicy(Qt::ClickFocus); kapp->dcopClient()->resume(); // Ok. We are ready for DCOP requests. diff --git a/knode/knprotocolclient.cpp b/knode/knprotocolclient.cpp index 4b9137a5e..c1b52a77f 100644 --- a/knode/knprotocolclient.cpp +++ b/knode/knprotocolclient.cpp @@ -201,11 +201,11 @@ bool KNProtocolClient::openConnection() if (ks.status() == IO_LookupError) { job->setErrorString(i18n("Unable to resolve hostname")); } else if (ks.status() == IO_ConnectError) { - job->setErrorString(i18n("Unable to connect:\n%1").arg(KExtendedSocket::strError(ks.status(), errno))); + job->setErrorString(i18n("Unable to connect:\n%1").tqarg(KExtendedSocket::strError(ks.status(), errno))); } else if (ks.status() == IO_TimeOutError) job->setErrorString(i18n("A delay occurred which exceeded the\ncurrent timeout limit.")); else - job->setErrorString(i18n("Unable to connect:\n%1").arg(KExtendedSocket::strError(ks.status(), errno))); + job->setErrorString(i18n("Unable to connect:\n%1").tqarg(KExtendedSocket::strError(ks.status(), errno))); closeSocket(); return false; @@ -432,7 +432,7 @@ bool KNProtocolClient::checkNextResponse(int code) void KNProtocolClient::handleErrors() { if (errorPrefix.isEmpty()) - job->setErrorString(i18n("An error occurred:\n%1").arg(thisLine)); + job->setErrorString(i18n("An error occurred:\n%1").tqarg(thisLine)); else job->setErrorString(errorPrefix + thisLine); diff --git a/knode/knserverinfo.cpp b/knode/knserverinfo.cpp index 0a2598159..5b7dc407c 100644 --- a/knode/knserverinfo.cpp +++ b/knode/knserverinfo.cpp @@ -111,7 +111,7 @@ void KNServerInfo::saveConf(KConfig *conf) "but should not be considered secure from decryption efforts " "if access to the configuration file is obtained.\n" "Do you want to store the password for server '%1' in the " - "configuration file?").arg( server() ), + "configuration file?").tqarg( server() ), i18n("KWallet Not Available"), KGuiItem( i18n("Store Password") ), KGuiItem( i18n("Do Not Store Password") ) ) diff --git a/knode/knwidgets.cpp b/knode/knwidgets.cpp index 0bf4fcc26..53feed61d 100644 --- a/knode/knwidgets.cpp +++ b/knode/knwidgets.cpp @@ -143,7 +143,7 @@ void KNDockWidgetHeaderDrag::paintEvent(TQPaintEvent* ev) paint.begin(&drawBuffer); paint.fillRect(drawBuffer.rect(), TQBrush(tqcolorGroup().brush(TQColorGroup::Background))); - paint.setPen(palette().active().highlight()); + paint.setPen(tqpalette().active().highlight()); paint.drawLine(1, 2, width(), 2); paint.drawLine(1, 3, width(), 3); paint.drawLine(1, 5, width(), 5); diff --git a/knode/utilities.cpp b/knode/utilities.cpp index d634b7dfa..5fd418fe4 100644 --- a/knode/utilities.cpp +++ b/knode/utilities.cpp @@ -167,7 +167,7 @@ TQFile* KNSaveHelper::getFile(const TQString &dialogTitle) if (url.isLocalFile()) { 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()), + i18n("<qt>A file named <b>%1</b> already exists.<br>Do you want to replace it?</qt>").tqarg(url.path()), dialogTitle, i18n("&Replace")) != KMessageBox::Continue)) { return 0; } @@ -410,7 +410,7 @@ TQString KNHelper::rewrapStringList(TQStringList text, int wrapAt, TQChar quoteC if (!alwaysSpace && (thisLine[0]==quoteChar)) thisLine.prepend(quoteChar); // second quote level without space else - thisLine.prepend(quoteChar+' '); + thisLine.prepend(quoteChar+TQString(' ')); thisPrefix=TQString(); TQChar c; diff --git a/knotes/knote.cpp b/knotes/knote.cpp index 0f0ec426c..4281f713d 100644 --- a/knotes/knote.cpp +++ b/knotes/knote.cpp @@ -77,8 +77,6 @@ using namespace KCal; -extern Time qt_x_time; - int KNote::s_ppOffset = 0; KNote::KNote( TQDomDocument buildDoc, Journal *j, TQWidget *tqparent, const char *name ) @@ -107,47 +105,47 @@ KNote::KNote( TQDomDocument buildDoc, Journal *j, TQWidget *tqparent, const char // create the menu items for the note - not the editor... // rename, mail, print, save as, insert date, alarm, close, delete, new note new KAction( i18n("New"), "filenew", 0, - this,TQT_SLOT(slotRequestNewNote()) , actionCollection(), "new_note" ); + TQT_TQOBJECT(this),TQT_SLOT(slotRequestNewNote()) , actionCollection(), "new_note" ); new KAction( i18n("Rename..."), "text", 0, - this, TQT_SLOT(slotRename()), actionCollection(), "rename_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotRename()), actionCollection(), "rename_note" ); m_readOnly = new KToggleAction( i18n("Lock"), "lock" , 0, - this, TQT_SLOT(slotUpdateReadOnly()), actionCollection(), "lock_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotUpdateReadOnly()), actionCollection(), "lock_note" ); m_readOnly->setCheckedState( KGuiItem( i18n("Unlock"), "unlock" ) ); new KAction( i18n("Hide"), "fileclose" , Key_Escape, - this, TQT_SLOT(slotClose()), actionCollection(), "hide_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotClose()), actionCollection(), "hide_note" ); new KAction( i18n("Delete"), "knotes_delete", 0, - this, TQT_SLOT(slotKill()), actionCollection(), "delete_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotKill()), actionCollection(), "delete_note" ); new KAction( i18n("Insert Date"), "knotes_date", 0 , - this, TQT_SLOT(slotInsDate()), actionCollection(), "insert_date" ); + TQT_TQOBJECT(this), TQT_SLOT(slotInsDate()), actionCollection(), "insert_date" ); new KAction( i18n("Set Alarm..."), "knotes_alarm", 0 , - this, TQT_SLOT(slotSetAlarm()), actionCollection(), "set_alarm" ); + TQT_TQOBJECT(this), TQT_SLOT(slotSetAlarm()), actionCollection(), "set_alarm" ); new KAction( i18n("Send..."), "network", 0, - this, TQT_SLOT(slotSend()), actionCollection(), "send_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotSend()), actionCollection(), "send_note" ); new KAction( i18n("Mail..."), "mail_send", 0, - this, TQT_SLOT(slotMail()), actionCollection(), "mail_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotMail()), actionCollection(), "mail_note" ); new KAction( i18n("Save As..."), "filesaveas", 0, - this, TQT_SLOT(slotSaveAs()), actionCollection(), "save_note" ); - KStdAction::print( this, TQT_SLOT(slotPrint()), actionCollection(), "print_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotSaveAs()), actionCollection(), "save_note" ); + KStdAction::print( TQT_TQOBJECT(this), TQT_SLOT(slotPrint()), actionCollection(), "print_note" ); new KAction( i18n("Preferences..."), "configure", 0, - this, TQT_SLOT(slotPreferences()), actionCollection(), "configure_note" ); + TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actionCollection(), "configure_note" ); m_keepAbove = new KToggleAction( i18n("Keep Above Others"), "up", 0, - this, TQT_SLOT(slotUpdateKeepAboveBelow()), actionCollection(), "keep_above" ); + TQT_TQOBJECT(this), TQT_SLOT(slotUpdateKeepAboveBelow()), actionCollection(), "keep_above" ); m_keepAbove->setExclusiveGroup( "keepAB" ); m_keepBelow = new KToggleAction( i18n("Keep Below Others"), "down", 0, - this, TQT_SLOT(slotUpdateKeepAboveBelow()), actionCollection(), "keep_below" ); + TQT_TQOBJECT(this), TQT_SLOT(slotUpdateKeepAboveBelow()), actionCollection(), "keep_below" ); m_keepBelow->setExclusiveGroup( "keepAB" ); m_toDesktop = new KListAction( i18n("To Desktop"), 0, - this, TQT_SLOT(slotPopupActionToDesktop(int)), actionCollection(), "to_desktop" ); - connect( m_toDesktop->popupMenu(), TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(slotUpdateDesktopActions()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotPopupActionToDesktop(int)), actionCollection(), "to_desktop" ); + connect( m_toDesktop->popupMenu(), TQT_SIGNAL(aboutToShow()), TQT_TQOBJECT(this), TQT_SLOT(slotUpdateDesktopActions()) ); // invisible action to walk through the notes to make this configurable new KAction( i18n("Walk Through Notes"), 0, SHIFT+Key_BackTab, - this, TQT_SIGNAL(sigShowNextNote()), actionCollection(), "walk_notes" ); + TQT_TQOBJECT(this), TQT_SIGNAL(sigShowNextNote()), actionCollection(), "walk_notes" ); // create the note header, button and label... m_label = new TQLabel( this ); @@ -157,17 +155,17 @@ KNote::KNote( TQDomDocument buildDoc, Journal *j, TQWidget *tqparent, const char setName( m_journal->summary() ); // don't worry, no signals are connected at this stage yet m_button = new KNoteButton( "knotes_close", this ); - connect( m_button, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotClose()) ); + connect( m_button, TQT_SIGNAL(clicked()), TQT_TQOBJECT(this), TQT_SLOT(slotClose()) ); // create the note editor m_editor = new KNoteEdit( actionCollection(), this ); m_editor->setNote( this ); m_editor->installEventFilter( this ); // receive events (for modified) m_editor->viewport()->installEventFilter( this ); - connect( m_editor, TQT_SIGNAL(contentsMoving( int, int )), this, TQT_SLOT(slotUpdateViewport( int, int ))); + connect( m_editor, TQT_SIGNAL(contentsMoving( int, int )), TQT_TQOBJECT(this), TQT_SLOT(slotUpdateViewport( int, int ))); KXMLGUIBuilder builder( this ); - KXMLGUIFactory factory( &builder, this ); + KXMLGUIFactory factory( &builder, TQT_TQOBJECT(this) ); factory.addClient( this ); m_menu = dynamic_cast<KPopupMenu*>(factory.container( "note_context", this )); @@ -395,7 +393,7 @@ void KNote::slotKill( bool force ) m_blockEmitDataChanged = true; if ( !force && KMessageBox::warningContinueCancel( this, - i18n("<qt>Do you really want to delete note <b>%1</b>?</qt>").arg( m_label->text() ), + i18n("<qt>Do you really want to delete note <b>%1</b>?</qt>").tqarg( m_label->text() ), i18n("Confirm Delete"), KGuiItem( i18n("&Delete"), "editdelete" ), "ConfirmDeleteNote" ) @@ -583,8 +581,8 @@ void KNote::tqfind( const TQString& pattern, long options ) m_tqfind = new KFind( pattern, options, this ); connect( m_tqfind, TQT_SIGNAL(highlight( const TQString &, int, int )), - this, TQT_SLOT(slotHighlight( const TQString &, int, int )) ); - connect( m_tqfind, TQT_SIGNAL(findNext()), this, TQT_SLOT(slotFindNext()) ); + TQT_TQOBJECT(this), TQT_SLOT(slotHighlight( const TQString &, int, int )) ); + connect( m_tqfind, TQT_SIGNAL(findNext()), TQT_TQOBJECT(this), TQT_SLOT(slotFindNext()) ); m_tqfind->setData( plainText() ); slotFindNext(); @@ -596,7 +594,7 @@ void KNote::slotFindNext() // TODO: dialogClosed() -> delete m_tqfind // Let KFind inspect the text fragment, and display a dialog if a match is found - KFind::Result res = m_tqfind->tqfind(); + KFind::Result res = m_tqfind->find(); if ( res == KFind::NoMatch ) // i.e. at end-pos { @@ -798,7 +796,7 @@ void KNote::slotPreferences() // create a new preferences dialog... KNoteConfigDlg *dialog = new KNoteConfigDlg( m_config, name(), this, noteId().utf8() ); - connect( dialog, TQT_SIGNAL(settingsChanged()), this, TQT_SLOT(slotApplyConfig()) ); + connect( dialog, TQT_SIGNAL(settingsChanged()), TQT_TQOBJECT(this), TQT_SLOT(slotApplyConfig()) ); connect( this, TQT_SIGNAL(sigNameChanged()), dialog, TQT_SLOT(slotUpdateCaption()) ); dialog->show(); } @@ -806,7 +804,7 @@ void KNote::slotPreferences() void KNote::slotSend() { // pop up dialog to get the IP - KNoteHostDlg hostDlg( i18n("Send \"%1\"").arg( name() ), this ); + KNoteHostDlg hostDlg( i18n("Send \"%1\"").tqarg( name() ), this ); aboutToEnterEventLoop(); bool ok = (hostDlg.exec() == TQDialog::Accepted); eventLoopLeft(); @@ -893,7 +891,7 @@ void KNote::slotSaveAs() if ( file.exists() && KMessageBox::warningContinueCancel( this, i18n("<qt>A file named <b>%1</b> already exists.<br>" - "Are you sure you want to overwrite it?</qt>").arg( TQFileInfo(file).fileName() ) ) + "Are you sure you want to overwrite it?</qt>").tqarg( TQFileInfo(file).fileName() ) ) != KMessageBox::Continue ) { m_blockEmitDataChanged = false; @@ -988,7 +986,7 @@ void KNote::slotUpdateDesktopActions() int count = wm_root.numberOfDesktops(); for ( int n = 1; n <= count; n++ ) - desktops.append( TQString("&%1 %2").arg( n ).arg( TQString::fromUtf8(wm_root.desktopName( n )) ) ); + desktops.append( TQString("&%1 %2").tqarg( n ).tqarg( TQString::fromUtf8(wm_root.desktopName( n )) ) ); m_toDesktop->setItems( desktops ); @@ -1022,7 +1020,7 @@ void KNote::createFold() TQPixmap fold( 15, 15 ); TQPainter foldp( &fold ); foldp.setPen( TQt::NoPen ); - foldp.setBrush( palette().active().dark() ); + foldp.setBrush( tqpalette().active().dark() ); TQPointArray foldpoints( 3 ); foldpoints.putPoints( 0, 3, 0, 0, 14, 0, 0, 14 ); foldp.drawPolygon( foldpoints ); @@ -1044,7 +1042,7 @@ void KNote::updateFocus() { if ( hasFocus() ) { - m_label->setBackgroundColor( palette().active().shadow() ); + m_label->setBackgroundColor( tqpalette().active().shadow() ); m_button->show(); if ( !m_editor->isReadOnly() ) @@ -1080,11 +1078,11 @@ void KNote::updateFocus() if ( s_ppOffset ) { - m_label->setBackgroundColor( palette().active().midlight() ); + m_label->setBackgroundColor( tqpalette().active().midlight() ); m_fold->show(); } else - m_label->setBackgroundColor( palette().active().background() ); + m_label->setBackgroundColor( tqpalette().active().background() ); } } @@ -1137,7 +1135,7 @@ void KNote::updateBackground( int y_offset ) TQImage grad_img( w, h, 32 ); TQRgb rgbcol; - TQColor bg = palette().active().background(); + TQColor bg = tqpalette().active().background(); for ( int i = 0; i < h; ++i ) { @@ -1171,7 +1169,7 @@ void KNote::updateLayout() if ( s_ppOffset ) { if ( !m_editor->paper().pixmap() ) // just changed the style - setColor( palette().active().foreground(), palette().active().background() ); + setColor( tqpalette().active().foreground(), tqpalette().active().background() ); m_pushpin->show(); setFrameStyle( Panel | Raised ); @@ -1184,7 +1182,7 @@ void KNote::updateLayout() else { if ( m_editor->paper().pixmap() ) // just changed the style - setColor( palette().active().foreground(), palette().active().background() ); + setColor( tqpalette().active().foreground(), tqpalette().active().background() ); setFrameStyle( WinPanel | Raised ); m_pushpin->hide(); @@ -1318,7 +1316,7 @@ bool KNote::eventFilter( TQObject *o, TQEvent *ev ) return true; } - if ( o == m_label ) + if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_label) ) { TQMouseEvent *e = (TQMouseEvent *)ev; @@ -1328,12 +1326,12 @@ bool KNote::eventFilter( TQObject *o, TQEvent *ev ) slotRename(); } if ( ev->type() == TQEvent::MouseButtonPress && - (e->button() == LeftButton || e->button() == MidButton)) + (e->button() == Qt::LeftButton || e->button() == Qt::MidButton)) { - e->button() == LeftButton ? KWin::raiseWindow( winId() ) + e->button() == Qt::LeftButton ? KWin::raiseWindow( winId() ) : KWin::lowerWindow( winId() ); - XUngrabPointer( qt_xdisplay(), qt_x_time ); + XUngrabPointer( qt_xdisplay(), GET_QT_X_TIME() ); NETRootInfo wm_root( qt_xdisplay(), NET::WMMoveResize ); wm_root.moveResizeRequest( winId(), e->globalX(), e->globalY(), NET::Move ); return true; @@ -1349,7 +1347,7 @@ bool KNote::eventFilter( TQObject *o, TQEvent *ev ) #endif if ( m_menu && ( ev->type() == TQEvent::MouseButtonPress ) - && ( e->button() == RightButton ) ) + && ( e->button() == Qt::RightButton ) ) { m_menu->popup( TQCursor::pos() ); return true; @@ -1358,9 +1356,9 @@ bool KNote::eventFilter( TQObject *o, TQEvent *ev ) return false; } - if ( o == m_editor ) { + if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_editor) ) { if ( ev->type() == TQEvent::FocusOut ) { - TQFocusEvent *fe = static_cast<TQFocusEvent *>(ev); + TQFocusEvent *fe = TQT_TQFOCUSEVENT(ev); if ( fe->reason() != TQFocusEvent::Popup && fe->reason() != TQFocusEvent::Mouse ) { updateFocus(); @@ -1377,11 +1375,11 @@ bool KNote::eventFilter( TQObject *o, TQEvent *ev ) return false; } - if ( o == m_editor->viewport() ) + if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_editor->viewport()) ) { if ( m_edit_menu && ev->type() == TQEvent::MouseButtonPress && - ((TQMouseEvent *)ev)->button() == RightButton ) + ((TQMouseEvent *)ev)->button() == Qt::RightButton ) { m_edit_menu->popup( TQCursor::pos() ); return true; diff --git a/knotes/knotealarmdlg.cpp b/knotes/knotealarmdlg.cpp index ca4d74e84..6ce39e4a0 100644 --- a/knotes/knotealarmdlg.cpp +++ b/knotes/knotealarmdlg.cpp @@ -49,7 +49,7 @@ KNoteAlarmDlg::KNoteAlarmDlg( const TQString& caption, TQWidget *tqparent, const : KDialogBase( tqparent, name, true, caption, Ok|Cancel, Ok ) { TQVBox *page = makeVBoxMainWidget(); - TQGroupBox *group = new TQGroupBox( 3, Vertical, i18n("Scheduled Alarm"), page ); + TQGroupBox *group = new TQGroupBox( 3, Qt::Vertical, i18n("Scheduled Alarm"), page ); m_buttons = new TQButtonGroup( page ); m_buttons->hide(); diff --git a/knotes/knotebutton.cpp b/knotes/knotebutton.cpp index d9a6205e9..846dc503e 100644 --- a/knotes/knotebutton.cpp +++ b/knotes/knotebutton.cpp @@ -33,7 +33,7 @@ KNoteButton::KNoteButton( const TQString& icon, TQWidget *tqparent, const char *name ) : TQPushButton( tqparent, name ) { - setFocusPolicy( NoFocus ); + setFocusPolicy( Qt::NoFocus ); tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Fixed, TQSizePolicy::Fixed ) ); m_flat = true; @@ -78,7 +78,7 @@ void KNoteButton::drawButton( TQPainter* p ) if ( !m_flat ) flags |= TQStyle::Style_MouseOver; - style().drawPrimitive( TQStyle::PE_ButtonTool, p, rect(), tqcolorGroup(), flags ); + tqstyle().tqdrawPrimitive( TQStyle::PE_ButtonTool, p, rect(), tqcolorGroup(), flags ); drawButtonLabel( p ); } @@ -102,8 +102,8 @@ void KNoteButton::drawButtonLabel( TQPainter* p ) // Shift button contents if pushed. if ( isOn() || isDown() ) { - dx += style().tqpixelMetric( TQStyle::PM_ButtonShiftHorizontal, this ); - dy += style().tqpixelMetric( TQStyle::PM_ButtonShiftVertical, this ); + dx += tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftHorizontal, this ); + dy += tqstyle().tqpixelMetric( TQStyle::PM_ButtonShiftVertical, this ); } p->drawPixmap( dx, dy, pix ); diff --git a/knotes/knoteconfigdlg.cpp b/knotes/knoteconfigdlg.cpp index 950b9a9b1..abb379a03 100644 --- a/knotes/knoteconfigdlg.cpp +++ b/knotes/knoteconfigdlg.cpp @@ -81,7 +81,7 @@ KNoteConfigDlg::~KNoteConfigDlg() void KNoteConfigDlg::slotUpdateCaption() { - KNote *note = ::qt_cast<KNote *>(sender()); + KNote *note = ::tqqt_cast<KNote *>(sender()); if ( note ) setCaption( note->name() ); } diff --git a/knotes/knoteedit.cpp b/knotes/knoteedit.cpp index 2796c2975..55f1c6ff0 100644 --- a/knotes/knoteedit.cpp +++ b/knotes/knoteedit.cpp @@ -45,27 +45,27 @@ KNoteEdit::KNoteEdit( KActionCollection *actions, TQWidget *tqparent, const char setLinkUnderline( true ); setCheckSpellingEnabled(false); // create the actions for the RMB menu - undo = KStdAction::undo( this, TQT_SLOT(undo()), actions ); - redo = KStdAction::redo( this, TQT_SLOT(redo()), actions ); + undo = KStdAction::undo( TQT_TQOBJECT(this), TQT_SLOT(undo()), actions ); + redo = KStdAction::redo( TQT_TQOBJECT(this), TQT_SLOT(redo()), actions ); undo->setEnabled( isUndoAvailable() ); redo->setEnabled( isRedoAvailable() ); - m_cut = KStdAction::cut( this, TQT_SLOT(cut()), actions ); - m_copy = KStdAction::copy( this, TQT_SLOT(copy()), actions ); - m_paste = KStdAction::paste( this, TQT_SLOT(paste()), actions ); + m_cut = KStdAction::cut( TQT_TQOBJECT(this), TQT_SLOT(cut()), actions ); + m_copy = KStdAction::copy( TQT_TQOBJECT(this), TQT_SLOT(copy()), actions ); + m_paste = KStdAction::paste( TQT_TQOBJECT(this), TQT_SLOT(paste()), actions ); m_cut->setEnabled( false ); m_copy->setEnabled( false ); m_paste->setEnabled( true ); - connect( this, TQT_SIGNAL(undoAvailable(bool)), this, TQT_SLOT(setEnabledUndo(bool)) ); - connect( this, TQT_SIGNAL(redoAvailable(bool)), this, TQT_SLOT(setEnabledRedo(bool)) ); + connect( this, TQT_SIGNAL(undoAvailable(bool)), TQT_TQOBJECT(this), TQT_SLOT(setEnabledUndo(bool)) ); + connect( this, TQT_SIGNAL(redoAvailable(bool)), TQT_TQOBJECT(this), TQT_SLOT(setEnabledRedo(bool)) ); - connect( this, TQT_SIGNAL(copyAvailable(bool)), this, TQT_SLOT( slotCutEnabled( bool ) ) ); + connect( this, TQT_SIGNAL(copyAvailable(bool)), TQT_TQOBJECT(this), TQT_SLOT( slotCutEnabled( bool ) ) ); connect( this, TQT_SIGNAL(copyAvailable(bool)), m_copy, TQT_SLOT(setEnabled(bool)) ); - new KAction( KStdGuiItem::clear(), 0, this, TQT_SLOT(clear()), actions, "edit_clear" ); - KStdAction::selectAll( this, TQT_SLOT(selectAll()), actions ); + new KAction( KStdGuiItem::clear(), 0, TQT_TQOBJECT(this), TQT_SLOT(clear()), actions, "edit_clear" ); + KStdAction::selectAll( TQT_TQOBJECT(this), TQT_SLOT(selectAll()), actions ); // create the actions modifying the text format m_textBold = new KToggleAction( i18n("Bold"), "text_bold", CTRL + Key_B, 0, 0, @@ -83,17 +83,17 @@ KNoteEdit::KNoteEdit( KActionCollection *actions, TQWidget *tqparent, const char connect( m_textStrikeOut, TQT_SIGNAL(toggled(bool)), TQT_SLOT(textStrikeOut(bool)) ); m_textAlignLeft = new KToggleAction( i18n("Align Left"), "text_left", ALT + Key_L, - this, TQT_SLOT(textAlignLeft()), + TQT_TQOBJECT(this), TQT_SLOT(textAlignLeft()), actions, "format_alignleft" ); m_textAlignLeft->setChecked( true ); // just a dummy, will be updated later m_textAlignCenter = new KToggleAction( i18n("Align Center"), "text_center", ALT + Key_C, - this, TQT_SLOT(textAlignCenter()), + TQT_TQOBJECT(this), TQT_SLOT(textAlignCenter()), actions, "format_aligncenter" ); m_textAlignRight = new KToggleAction( i18n("Align Right"), "text_right", ALT + Key_R, - this, TQT_SLOT(textAlignRight()), + TQT_TQOBJECT(this), TQT_SLOT(textAlignRight()), actions, "format_alignright" ); m_textAlignBlock = new KToggleAction( i18n("Align Block"), "text_block", ALT + Key_B, - this, TQT_SLOT(textAlignBlock()), + TQT_TQOBJECT(this), TQT_SLOT(textAlignBlock()), actions, "format_alignblock" ); m_textAlignLeft->setExclusiveGroup( "align" ); @@ -102,16 +102,16 @@ KNoteEdit::KNoteEdit( KActionCollection *actions, TQWidget *tqparent, const char m_textAlignBlock->setExclusiveGroup( "align" ); m_textList = new KToggleAction( i18n("List"), "enum_list", 0, - this, TQT_SLOT(textList()), + TQT_TQOBJECT(this), TQT_SLOT(textList()), actions, "format_list" ); m_textList->setExclusiveGroup( "style" ); m_textSuper = new KToggleAction( i18n("Superscript"), "text_super", 0, - this, TQT_SLOT(textSuperScript()), + TQT_TQOBJECT(this), TQT_SLOT(textSuperScript()), actions, "format_super" ); m_textSub = new KToggleAction( i18n("Subscript"), "text_sub", 0, - this, TQT_SLOT(textSubScript()), + TQT_TQOBJECT(this), TQT_SLOT(textSubScript()), actions, "format_sub" ); m_textSuper->setExclusiveGroup( "valign" ); @@ -120,38 +120,38 @@ KNoteEdit::KNoteEdit( KActionCollection *actions, TQWidget *tqparent, const char // There is no easy possibility to implement text indenting with TQTextEdit // // m_textIncreaseIndent = new KAction( i18n("Increase Indent"), "format_increaseindent", 0, -// this, TQT_SLOT(textIncreaseIndent()), +// TQT_TQOBJECT(this), TQT_SLOT(textIncreaseIndent()), // actions, "format_increaseindent" ); // // m_textDecreaseIndent = new KAction( i18n("Decrease Indent"), "format_decreaseindent", 0, -// this, TQT_SLOT(textDecreaseIndent()), +// TQT_TQOBJECT(this), TQT_SLOT(textDecreaseIndent()), // actions, "format_decreaseindent" ); TQPixmap pix( ICON_SIZE, ICON_SIZE ); pix.fill( black ); // just a dummy, gets updated before widget is shown - m_textColor = new KAction( i18n("Text Color..."), pix, 0, this, + m_textColor = new KAction( i18n("Text Color..."), pix, 0, TQT_TQOBJECT(this), TQT_SLOT(textColor()), actions, "format_color" ); m_textFont = new KFontAction( i18n("Text Font"), "text", KKey(), actions, "format_font" ); connect( m_textFont, TQT_SIGNAL(activated( const TQString & )), - this, TQT_SLOT(setFamily( const TQString & )) ); + TQT_TQOBJECT(this), TQT_SLOT(setFamily( const TQString & )) ); m_textSize = new KFontSizeAction( i18n("Text Size"), KKey(), actions, "format_size" ); connect( m_textSize, TQT_SIGNAL(fontSizeChanged( int )), - this, TQT_SLOT(setPointSize( int )) ); + TQT_TQOBJECT(this), TQT_SLOT(setPointSize( int )) ); // TQTextEdit connections connect( this, TQT_SIGNAL(returnPressed()), TQT_SLOT(slotReturnPressed()) ); connect( this, TQT_SIGNAL(currentFontChanged( const TQFont & )), - this, TQT_SLOT(fontChanged( const TQFont & )) ); + TQT_TQOBJECT(this), TQT_SLOT(fontChanged( const TQFont & )) ); connect( this, TQT_SIGNAL(currentColorChanged( const TQColor & )), - this, TQT_SLOT(colorChanged( const TQColor & )) ); + TQT_TQOBJECT(this), TQT_SLOT(colorChanged( const TQColor & )) ); connect( this, TQT_SIGNAL(currentAlignmentChanged( int )), - this, TQT_SLOT(tqalignmentChanged( int )) ); + TQT_TQOBJECT(this), TQT_SLOT(tqalignmentChanged( int )) ); connect( this, TQT_SIGNAL(currentVerticalAlignmentChanged( VerticalAlignment )), - this, TQT_SLOT(verticalAlignmentChanged( VerticalAlignment )) ); + TQT_TQOBJECT(this), TQT_SLOT(verticalAlignmentChanged( VerticalAlignment )) ); } KNoteEdit::~KNoteEdit() @@ -541,7 +541,7 @@ TQPopupMenu *KNoteEdit::createPopupMenu( const TQPoint &pos ) menu->insertSeparator(); id = menu->insertItem( SmallIconSet( "spellcheck" ), i18n( "Check Spelling..." ), - this, TQT_SLOT( checkSpelling() ) ); + TQT_TQOBJECT(this), TQT_SLOT( checkSpelling() ) ); if( text().isEmpty() ) menu->setItemEnabled( id, false ); diff --git a/knotes/knoteprinter.cpp b/knotes/knoteprinter.cpp index 69ddb35b5..6b2868174 100644 --- a/knotes/knoteprinter.cpp +++ b/knotes/knoteprinter.cpp @@ -117,7 +117,7 @@ void KNotePrinter::printNote( const TQString& name, const TQString& content ) co KPrinter printer; printer.setFullPage( true ); - if ( !printer.setup( 0, i18n("Print %1").arg(name) ) ) + if ( !printer.setup( 0, i18n("Print %1").tqarg(name) ) ) return; TQPainter painter; painter.begin( &printer ); diff --git a/knotes/knotesapp.cpp b/knotes/knotesapp.cpp index 79a3ca994..3423e7cd8 100644 --- a/knotes/knotesapp.cpp +++ b/knotes/knotesapp.cpp @@ -112,25 +112,25 @@ KNotesApp::KNotesApp() // create the GUI... new KAction( i18n("New Note"), "filenew", 0, - this, TQT_SLOT(newNote()), actionCollection(), "new_note" ); + TQT_TQOBJECT(this), TQT_SLOT(newNote()), actionCollection(), "new_note" ); new KAction( i18n("New Note From Clipboard"), "editpaste", 0, - this, TQT_SLOT(newNoteFromClipboard()), actionCollection(), "new_note_clipboard" ); + TQT_TQOBJECT(this), TQT_SLOT(newNoteFromClipboard()), actionCollection(), "new_note_clipboard" ); new KAction( i18n("Show All Notes"), "knotes", 0, - this, TQT_SLOT(showAllNotes()), actionCollection(), "show_all_notes" ); + TQT_TQOBJECT(this), TQT_SLOT(showAllNotes()), actionCollection(), "show_all_notes" ); new KAction( i18n("Hide All Notes"), "fileclose", 0, - this, TQT_SLOT(hideAllNotes()), actionCollection(), "hide_all_notes" ); + TQT_TQOBJECT(this), TQT_SLOT(hideAllNotes()), actionCollection(), "hide_all_notes" ); new KHelpMenu( this, kapp->aboutData(), false, actionCollection() ); - m_findAction = KStdAction::tqfind( this, TQT_SLOT(slotOpenFindDialog()), actionCollection() ); - KStdAction::preferences( this, TQT_SLOT(slotPreferences()), actionCollection() ); - KStdAction::keyBindings( this, TQT_SLOT(slotConfigureAccels()), actionCollection() ); + m_findAction = KStdAction::find( TQT_TQOBJECT(this), TQT_SLOT(slotOpenFindDialog()), actionCollection() ); + KStdAction::preferences( TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actionCollection() ); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT(slotConfigureAccels()), actionCollection() ); //FIXME: no shortcut removing!? - KStdAction::quit( this, TQT_SLOT(slotQuit()), actionCollection() )->setShortcut( 0 ); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT(slotQuit()), actionCollection() )->setShortcut( 0 ); setXMLFile( instance()->instanceName() + "appui.rc" ); m_guiBuilder = new KXMLGUIBuilder( this ); - m_guiFactory = new KXMLGUIFactory( m_guiBuilder, this ); + m_guiFactory = new KXMLGUIFactory( m_guiBuilder, TQT_TQOBJECT(this) ); m_guiFactory->addClient( this ); m_context_menu = static_cast<KPopupMenu*>(m_guiFactory->container( "knotes_context", this )); @@ -147,19 +147,19 @@ KNotesApp::KNotesApp() m_noteGUI.setContent( doc ); // create accels for global shortcuts - m_globalAccel = new KGlobalAccel( this, "global accel" ); + m_globalAccel = new KGlobalAccel( TQT_TQOBJECT(this), "global accel" ); m_globalAccel->insert( "global_new_note", i18n("New Note"), "", ALT+SHIFT+Key_N, ALT+SHIFT+Key_N , - this, TQT_SLOT(newNote()), true, true ); + TQT_TQOBJECT(this), TQT_SLOT(newNote()), true, true ); m_globalAccel->insert( "global_new_note_clipboard", i18n("New Note From Clipboard"), "", ALT+SHIFT+Key_C, ALT+SHIFT+Key_C, - this, TQT_SLOT(newNoteFromClipboard()), true, true ); + TQT_TQOBJECT(this), TQT_SLOT(newNoteFromClipboard()), true, true ); m_globalAccel->insert( "global_hide_all_notes", i18n("Hide All Notes"), "", ALT+SHIFT+Key_H, ALT+SHIFT+Key_H , - this, TQT_SLOT(hideAllNotes()), true, true ); + TQT_TQOBJECT(this), TQT_SLOT(hideAllNotes()), true, true ); m_globalAccel->insert( "global_show_all_notes", i18n("Show All Notes"), "", ALT+SHIFT+Key_S, ALT+SHIFT+Key_S, - this, TQT_SLOT(showAllNotes()), true, true ); + TQT_TQOBJECT(this), TQT_SLOT(showAllNotes()), true, true ); m_globalAccel->readSettings(); @@ -196,7 +196,7 @@ KNotesApp::KNotesApp() // set up the alarm reminder - do it after loading the notes because this // is used as a check if updateNoteActions has to be called for a new note - m_alarm = new KNotesAlarm( m_manager, this ); + m_alarm = new KNotesAlarm( m_manager, TQT_TQOBJECT(this) ); // create the socket and possibly start listening for connections m_listener = new KServerSocket(); @@ -266,7 +266,7 @@ TQString KNotesApp::newNote( const TQString& name, const TQString& text ) TQString KNotesApp::newNoteFromClipboard( const TQString& name ) { - const TQString& text = KApplication::clipboard()->text(); + const TQString& text = KApplication::tqclipboard()->text(); return newNote( name, text ); } @@ -460,12 +460,12 @@ bool KNotesApp::isModified( const TQString& app, const TQString& id ) const void KNotesApp::mousePressEvent( TQMouseEvent* e ) { - if ( !rect().tqcontains( e->pos() ) ) + if ( !rect().contains( e->pos() ) ) return; switch ( e->button() ) { - case LeftButton: + case Qt::LeftButton: if ( m_noteList.count() == 1 ) { TQDictIterator<KNote> it( m_noteList ); @@ -474,10 +474,10 @@ void KNotesApp::mousePressEvent( TQMouseEvent* e ) else if ( m_note_menu->count() > 0 ) m_note_menu->popup( e->globalPos() ); break; - case MidButton: + case Qt::MidButton: newNote(); break; - case RightButton: + case Qt::RightButton: m_context_menu->popup( e->globalPos() ); default: break; } @@ -488,7 +488,7 @@ void KNotesApp::mousePressEvent( TQMouseEvent* e ) void KNotesApp::slotShowNote() { // tell the WM to give this note focus - showNote( TQString::fromUtf8( sender()->name() ) ); + showNote( TQString::fromUtf8( TQT_TQOBJECT(sender())->name() ) ); } void KNotesApp::slotWalkThroughNotes() @@ -554,8 +554,8 @@ void KNotesApp::slotPreferences() // create a new preferences dialog... KNoteConfigDlg *dialog = new KNoteConfigDlg( 0, i18n("Settings"), this, "KNotes Settings" ); - connect( dialog, TQT_SIGNAL(settingsChanged()), this, TQT_SLOT(updateNetworkListener()) ); - connect( dialog, TQT_SIGNAL(settingsChanged()), this, TQT_SLOT(updateStyle()) ); + connect( dialog, TQT_SIGNAL(settingsChanged()), TQT_TQOBJECT(this), TQT_SLOT(updateNetworkListener()) ); + connect( dialog, TQT_SIGNAL(settingsChanged()), TQT_TQOBJECT(this), TQT_SLOT(updateStyle()) ); dialog->show(); } @@ -673,7 +673,7 @@ void KNotesApp::acceptConnection() { KNotesNetworkReceiver *recv = new KNotesNetworkReceiver( s ); connect( recv, TQT_SIGNAL(sigNoteReceived( const TQString &, const TQString & )), - this, TQT_SLOT(newNote( const TQString &, const TQString & )) ); + TQT_TQOBJECT(this), TQT_SLOT(newNote( const TQString &, const TQString & )) ); } } @@ -704,7 +704,7 @@ void KNotesApp::updateNoteActions() for ( TQDictIterator<KNote> it( m_noteList ); it.current(); ++it ) { KAction *action = new KAction( it.current()->name().tqreplace("&", "&&"), - KShortcut(), this, TQT_SLOT(slotShowNote()), + KShortcut(), TQT_TQOBJECT(this), TQT_SLOT(slotShowNote()), (TQObject *)0, it.current()->noteId().utf8() ); KIconEffect effect; diff --git a/knotes/knotesnetrecv.cpp b/knotes/knotesnetrecv.cpp index ce4aafa42..829398ba0 100644 --- a/knotes/knotesnetrecv.cpp +++ b/knotes/knotesnetrecv.cpp @@ -66,8 +66,8 @@ KNotesNetworkReceiver::KNotesNetworkReceiver( KBufferedSocket *s ) // Add the remote IP or hostname and the date to the title, to help the // user guess who wrote it. m_titleAddon = TQString(" [%1, %2]") - .arg( m_sock->peerAddress().nodeName() ) - .arg( date ); + .tqarg( m_sock->peerAddress().nodeName() ) + .tqarg( date ); // Setup the communications connect( m_sock, TQT_SIGNAL(readyRead()), TQT_SLOT(slotDataAvailable()) ); @@ -145,7 +145,7 @@ void KNotesNetworkReceiver::slotConnectionClosed() void KNotesNetworkReceiver::slotError( int err ) { kdWarning() << k_funcinfo - << m_sock->errorString( static_cast<KSocketBase::SocketError>(err) ) + << m_sock->KNetwork::KSocketBase::errorString( static_cast<KSocketBase::SocketError>(err) ) << endl; } diff --git a/knotes/knotesnetsend.cpp b/knotes/knotesnetsend.cpp index fafcebac1..ca3005d6a 100644 --- a/knotes/knotesnetsend.cpp +++ b/knotes/knotesnetsend.cpp @@ -48,11 +48,11 @@ KNotesNetworkSender::KNotesNetworkSender( const TQString& hostname, int port ) // TQObject:: prefix needed, otherwise the KStreamSocket::connect() // mehtod is called!!! - TQObject::connect( this, TQT_SIGNAL(connected( const KResolverEntry& )), + QObject::connect( TQT_TQOBJECT(this), TQT_SIGNAL(connected( const KResolverEntry& )), TQT_SLOT(slotConnected( const KResolverEntry& )) ); - TQObject::connect( this, TQT_SIGNAL(gotError( int )), TQT_SLOT(slotError( int )) ); - TQObject::connect( this, TQT_SIGNAL(closed()), TQT_SLOT(slotClosed()) ); - TQObject::connect( this, TQT_SIGNAL(readyWrite()), TQT_SLOT(slotReadyWrite()) ); + QObject::connect( TQT_TQOBJECT(this), TQT_SIGNAL(gotError( int )), TQT_SLOT(slotError( int )) ); + QObject::connect( TQT_TQOBJECT(this), TQT_SIGNAL(closed()), TQT_SLOT(slotClosed()) ); + QObject::connect( TQT_TQOBJECT(this), TQT_SIGNAL(readyWrite()), TQT_SLOT(slotReadyWrite()) ); } void KNotesNetworkSender::setSenderId( const TQString& sender ) @@ -91,7 +91,7 @@ void KNotesNetworkSender::slotReadyWrite() void KNotesNetworkSender::slotError( int err ) { KMessageBox::sorry( 0, i18n("Communication error: %1") - .arg( errorString( static_cast<KSocketBase::SocketError>(err) ) ) + .tqarg( TQString(KNetwork::KSocketBase::errorString( static_cast<KSocketBase::SocketError>(err) )) ) ); slotClosed(); } diff --git a/knotes/resourcelocal.cpp b/knotes/resourcelocal.cpp index 960362127..aed70e236 100644 --- a/knotes/resourcelocal.cpp +++ b/knotes/resourcelocal.cpp @@ -89,7 +89,7 @@ bool ResourceLocal::save() i18n("<qt>Unable to save the notes to <b>%1</b>. " "Check that there is sufficient disk space." "<br>There should be a backup in the same directory " - "though.</qt>").arg( mURL.path() ) ); + "though.</qt>").tqarg( mURL.path() ) ); return false; } diff --git a/kode/enum.cpp b/kode/enum.cpp index 64bf8f790..8a41f58b6 100644 --- a/kode/enum.cpp +++ b/kode/enum.cpp @@ -41,9 +41,9 @@ TQString Enum::declaration() const for ( it = mEnums.begin(); it != mEnums.end(); ++it, ++value ) { if ( mCombinable ) { if ( it == mEnums.begin() ) - retval += TQString( " %1 = %2" ).arg( *it ).arg( 1 << value ); + retval += TQString( " %1 = %2" ).tqarg( *it ).tqarg( 1 << value ); else - retval += TQString( ", %1 = %2" ).arg( *it ).arg( 1 << value ); + retval += TQString( ", %1 = %2" ).tqarg( *it ).tqarg( 1 << value ); } else { if ( it == mEnums.begin() ) retval += " " + *it; diff --git a/kode/kodemain.cpp b/kode/kodemain.cpp index 5d01cefa6..dcc073edc 100644 --- a/kode/kodemain.cpp +++ b/kode/kodemain.cpp @@ -140,7 +140,7 @@ int addProperty( KCmdLineArgs *args ) TQFile headerFile( headerFileName ); if ( !headerFile.open( IO_ReadOnly ) ) { - std::cerr << "Unable to open file '" << headerFileName.utf8() << "'" << + std::cerr << "Unable to open file '" << headerFileName.utf8().data() << "'" << std::endl; return 1; } @@ -185,7 +185,7 @@ int addProperty( KCmdLineArgs *args ) { TQRegExp re( "(\\w+)\\s*\\(" ); if ( re.search( line ) >= 0 ) { - TQString function = re.cap( 1 ).lower(); + TQString function = TQString(re.cap( 1 )).lower(); if ( !function.isEmpty() ) { kdDebug() << "Function: " << function << endl; if ( function == className || function == "~" + className ) { @@ -269,8 +269,8 @@ int addProperty( KCmdLineArgs *args ) TQString headerFileNameOut = headerFileName + ".kodeorig" ; KProcess proc; - proc << "cp" << TQFile::encodeName( headerFileName ) << - TQFile::encodeName( headerFileNameOut ); + proc << "cp" << TQFile::encodeName( headerFileName ).data() << + TQFile::encodeName( headerFileNameOut ).data(); if ( !proc.start( KProcess::Block ) ) { kdError() << "Copy failed" << endl; @@ -285,7 +285,7 @@ int addProperty( KCmdLineArgs *args ) o << out << endl; } } else { - std::cout << out.utf8() << std::endl; + std::cout << out.utf8().data() << std::endl; } return 0; @@ -313,7 +313,7 @@ int codify( KCmdLineArgs *args ) line.tqreplace( "\"", "\\\"" ); line = "code += \"" + line; line.append( "\";" ); - std::cout << line.local8Bit() << std::endl; + std::cout << line.local8Bit().data() << std::endl; } } diff --git a/kode/kwsdl/compiler.cpp b/kode/kwsdl/compiler.cpp index e3ccf4f8c..507e8bd52 100644 --- a/kode/kwsdl/compiler.cpp +++ b/kode/kwsdl/compiler.cpp @@ -39,7 +39,7 @@ Compiler::Compiler() void Compiler::setWSDLUrl( const TQString &wsdlUrl ) { mWSDLUrl = wsdlUrl; - mWSDLBaseUrl = mWSDLUrl.left( mWSDLUrl.findRev( '/' ) ); + mWSDLBaseUrl = mWSDLUrl.left( mWSDLUrl.tqfindRev( '/' ) ); mParser.setSchemaBaseUrl( mWSDLBaseUrl ); } diff --git a/kode/kwsdl/kung/binaryinputfield.cpp b/kode/kwsdl/kung/binaryinputfield.cpp index f517c7af8..ef7988125 100644 --- a/kode/kwsdl/kung/binaryinputfield.cpp +++ b/kode/kwsdl/kung/binaryinputfield.cpp @@ -131,7 +131,7 @@ void BinaryWidget::setData( const TQByteArray &data ) part->openURL( KURL( file.name() ) ); mMainWidget = part->widget(); } else { - mMainWidget = new TQLabel( i18n( "No part found for visualization of mimetype %1" ).arg( mimetype ), this ); + mMainWidget = new TQLabel( i18n( "No part found for visualization of mimetype %1" ).tqarg( mimetype ), this ); } mData = data; @@ -154,7 +154,7 @@ void BinaryWidget::load() if ( KIO::NetAccess::download( url, tempFile, this ) ) { TQFile file( tempFile ); if ( !file.open( IO_ReadOnly ) ) { - KMessageBox::error( this, i18n( "Unable to open file %1" ).arg( url.url() ) ); + KMessageBox::error( this, i18n( "Unable to open file %1" ).tqarg( url.url() ) ); return; } diff --git a/kode/kwsdl/kung/inputfield.cpp b/kode/kwsdl/kung/inputfield.cpp index 7bdd4cdeb..a8a1c66f3 100644 --- a/kode/kwsdl/kung/inputfield.cpp +++ b/kode/kwsdl/kung/inputfield.cpp @@ -25,7 +25,7 @@ #include "inputfield.h" InputField::InputField( const TQString &name ) - : TQObject( 0, TQString( "InputField( %1 )" ).arg( name ).latin1() ), + : TQObject( 0, TQString( "InputField( %1 )" ).tqarg( name ).latin1() ), mName( name ) { } diff --git a/kode/kwsdl/kung/loader.cpp b/kode/kwsdl/kung/loader.cpp index 8b0281ac8..41f965bc2 100644 --- a/kode/kwsdl/kung/loader.cpp +++ b/kode/kwsdl/kung/loader.cpp @@ -35,7 +35,7 @@ Loader::Loader() void Loader::setWSDLUrl( const TQString &wsdlUrl ) { mWSDLUrl = wsdlUrl; - mWSDLBaseUrl = mWSDLUrl.left( mWSDLUrl.findRev( '/' ) ); + mWSDLBaseUrl = mWSDLUrl.left( mWSDLUrl.tqfindRev( '/' ) ); mParser.setSchemaBaseUrl( mWSDLBaseUrl ); } diff --git a/kode/kxml_compiler/kxml_compiler.cpp b/kode/kxml_compiler/kxml_compiler.cpp index e2e529e22..a4f8178b3 100644 --- a/kode/kxml_compiler/kxml_compiler.cpp +++ b/kode/kxml_compiler/kxml_compiler.cpp @@ -83,7 +83,7 @@ int main( int argc, char **argv ) TQString dtdFilename = args->url( 0 ).path(); TQString baseName = args->url( 0 ).fileName(); - int pos = baseName.findRev( '.' ); + int pos = baseName.tqfindRev( '.' ); if ( pos > 0 ) baseName = baseName.left( pos ); diff --git a/kode/kxml_compiler/parser.cpp b/kode/kxml_compiler/parser.cpp index 0d5ddf154..3a0c7c3f7 100644 --- a/kode/kxml_compiler/parser.cpp +++ b/kode/kxml_compiler/parser.cpp @@ -229,7 +229,7 @@ void Parser::doIndent( int cols ) void Parser::dumpPattern( Pattern pattern ) { - std::cout << pattern.asString().utf8(); + std::cout << pattern.asString().utf8().data(); } void Parser::dumpReferences( const Reference::List &references, int indent ) @@ -238,7 +238,7 @@ void Parser::dumpReferences( const Reference::List &references, int indent ) for( it = references.begin(); it != references.end(); ++it ) { Reference *r = *it; doIndent( indent ); - std::cout << "REFERENCE " << r->name.utf8(); + std::cout << "REFERENCE " << r->name.utf8().data(); dumpPattern( r->pattern ); std::cout << std::endl; } @@ -250,7 +250,7 @@ void Parser::dumpAttributes( const Attribute::List &attributes, int indent ) for( it = attributes.begin(); it != attributes.end(); ++it ) { Attribute *a = *it; doIndent( indent ); - std::cout << "ATTRIBUTE " << a->name.utf8(); + std::cout << "ATTRIBUTE " << a->name.utf8().data(); dumpPattern( a->pattern ); std::cout << std::endl; } @@ -268,7 +268,7 @@ void Parser::dumpElements( const Element::List &elements, int indent ) void Parser::dumpElement( Element *e, int indent ) { doIndent( indent ); - std::cout << "ELEMENT " << e->name.utf8(); + std::cout << "ELEMENT " << e->name.utf8().data(); dumpPattern( e->pattern ); std::cout << std::endl; @@ -284,7 +284,7 @@ void Parser::dumpElement( Element *e, int indent ) void Parser::dumpTree( Element *s ) { - std::cout << "START " << s->name.utf8() << std::endl; + std::cout << "START " << s->name.utf8().data() << std::endl; dumpElements( s->elements, 2 ); dumpReferences( s->references, 2 ); } diff --git a/konsolekalendar/konsolekalendar.cpp b/konsolekalendar/konsolekalendar.cpp index f8c5fa998..3fbb5aed2 100644 --- a/konsolekalendar/konsolekalendar.cpp +++ b/konsolekalendar/konsolekalendar.cpp @@ -3,7 +3,8 @@ * * * KonsoleKalendar is a command line interface to KDE calendars * * Copyright (C) 2002-2004 Tuukka Pasanen <illuusio@mailcity.com> * - * Copyright (C) 2003-2005 Allen Winter <winter@kde.org> + * Copyright (C) 2003-2005 Allen Winter <winter@kde.org> * + * Copyright (C) 2010-2011 Timothy Pearson <kb9vqf@pearsoncomputing.net> * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * @@ -20,8 +21,8 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * * * * As a special exception, permission is given to link this program * - * with any edition of TQt, and distribute the resulting executable, * - * without including the source code for TQt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ******************************************************************************/ /** @@ -83,17 +84,17 @@ bool KonsoleKalendar::createCalendar() if ( m_variables->isDryRun() ) { cout << i18n( "Create Calendar <Dry Run>: %1" ). - arg( m_variables->getCalendarFile() ).local8Bit() + tqarg( m_variables->getCalendarFile() ).local8Bit().data() << endl; } else { kdDebug() << "konsolekalendar.cpp::createCalendar() | " << "Creating calendar file: " - << m_variables->getCalendarFile().local8Bit() + << m_variables->getCalendarFile().local8Bit().data() << endl; if ( m_variables->isVerbose() ) { cout << i18n( "Create Calendar <Verbose>: %1" ). - arg( m_variables->getCalendarFile() ).local8Bit() + tqarg( m_variables->getCalendarFile() ).local8Bit().data() << endl; } @@ -113,7 +114,7 @@ bool KonsoleKalendar::showInstance() Event *event; if ( m_variables->isDryRun() ) { - cout << i18n( "View Events <Dry Run>:" ).local8Bit() + cout << i18n( "View Events <Dry Run>:" ).local8Bit().data() << endl; printSpecs(); } else { @@ -141,7 +142,7 @@ bool KonsoleKalendar::showInstance() << endl; if ( m_variables->isVerbose() ) { - cout << i18n( "View Event <Verbose>:" ).local8Bit() + cout << i18n( "View Event <Verbose>:" ).local8Bit().data() << endl; printSpecs(); } @@ -244,7 +245,7 @@ bool KonsoleKalendar::showInstance() kdDebug() << "konsolekalendar.cpp::showInstance() | " << "HTML view events by uid list" << endl; cout << i18n("Sorry, export to HTML by UID is not supported yet") - .local8Bit() << endl; + .local8Bit().data() << endl; return( false ); } else { kdDebug() << "konsolekalendar.cpp::showInstance() | " @@ -271,11 +272,11 @@ bool KonsoleKalendar::showInstance() } else { if ( firstdate == lastdate ) { title = i18n( "Events: %1" ) - .arg( firstdate.toString( TQt::TextDate ) ); + .tqarg( firstdate.toString( Qt::TextDate ) ); } else { title = i18n( "Events: %1 - %2" ) - .arg( firstdate.toString( TQt::TextDate ) ) - .arg( lastdate.toString( TQt::TextDate ) ); + .tqarg( firstdate.toString( Qt::TextDate ) ) + .tqarg( lastdate.toString( Qt::TextDate ) ); } htmlSettings.setEventView( true ); } @@ -434,27 +435,27 @@ bool KonsoleKalendar::isEvent( TQDateTime startdate, void KonsoleKalendar::printSpecs() { cout << i18n( " What: %1" ). - arg( m_variables->getSummary() ).local8Bit() + tqarg( m_variables->getSummary() ).local8Bit().data() << endl; cout << i18n( " Begin: %1" ). - arg( m_variables->getStartDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getStartDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " End: %1" ). - arg( m_variables->getEndDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getEndDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; if ( m_variables->getFloating() == true ) { - cout << i18n( " No Time Associated with Event" ).local8Bit() + cout << i18n( " No Time Associated with Event" ).local8Bit().data() << endl; } cout << i18n( " Desc: %1" ). - arg( m_variables->getDescription() ).local8Bit() + tqarg( m_variables->getDescription() ).local8Bit().data() << endl; cout << i18n( " Location: %1" ). - arg( m_variables->getLocation() ).local8Bit() + tqarg( m_variables->getLocation() ).local8Bit().data() << endl; } diff --git a/konsolekalendar/konsolekalendaradd.cpp b/konsolekalendar/konsolekalendaradd.cpp index bd1980733..6b18ba20f 100644 --- a/konsolekalendar/konsolekalendaradd.cpp +++ b/konsolekalendar/konsolekalendaradd.cpp @@ -70,12 +70,12 @@ bool KonsoleKalendarAdd::addEvent() kdDebug() << "konsolekalendaradd.cpp::addEvent()" << endl; if ( m_variables->isDryRun() ) { - cout << i18n( "Insert Event <Dry Run>:" ).local8Bit() + cout << i18n( "Insert Event <Dry Run>:" ).local8Bit().data() << endl; printSpecs(); } else { if ( m_variables->isVerbose() ) { - cout << i18n( "Insert Event <Verbose>:" ).local8Bit() + cout << i18n( "Insert Event <Verbose>:" ).local8Bit().data() << endl; printSpecs(); } @@ -91,14 +91,14 @@ bool KonsoleKalendarAdd::addEvent() if ( m_variables->getCalendar()->addEvent( event ) ) { cout << i18n( "Success: \"%1\" inserted" ). - arg( m_variables->getSummary() ).local8Bit() + tqarg( m_variables->getSummary() ).local8Bit().data() << endl; m_variables->getCalendar()->save(); } else { cout << i18n( "Failure: \"%1\" not inserted" ). - arg( m_variables->getSummary() ).local8Bit() + tqarg( m_variables->getSummary() ).local8Bit().data() << endl; status = false; } @@ -142,27 +142,27 @@ bool KonsoleKalendarAdd::addImportedCalendar() void KonsoleKalendarAdd::printSpecs() { cout << i18n( " What: %1" ). - arg( m_variables->getSummary() ).local8Bit() + tqarg( m_variables->getSummary() ).local8Bit().data() << endl; cout << i18n( " Begin: %1" ). - arg( m_variables->getStartDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getStartDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " End: %1" ). - arg( m_variables->getEndDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getEndDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; if ( m_variables->getFloating() == true ) { - cout << i18n( " No Time Associated with Event" ).local8Bit() + cout << i18n( " No Time Associated with Event" ).local8Bit().data() << endl; } cout << i18n( " Desc: %1" ). - arg( m_variables->getDescription() ).local8Bit() + tqarg( m_variables->getDescription() ).local8Bit().data() << endl; cout << i18n( " Location: %1" ). - arg( m_variables->getLocation() ).local8Bit() + tqarg( m_variables->getLocation() ).local8Bit().data() << endl; } diff --git a/konsolekalendar/konsolekalendarchange.cpp b/konsolekalendar/konsolekalendarchange.cpp index 067c05e21..5ba9d2769 100644 --- a/konsolekalendar/konsolekalendarchange.cpp +++ b/konsolekalendar/konsolekalendarchange.cpp @@ -62,11 +62,11 @@ bool KonsoleKalendarChange::changeEvent() Event *event = m_variables->getCalendar()->event( m_variables->getUID() ); if ( event ) { if ( m_variables->isDryRun() ) { - cout << i18n( "Change Event <Dry Run>:" ).local8Bit() + cout << i18n( "Change Event <Dry Run>:" ).local8Bit().data() << endl; printSpecs( event ); - cout << i18n( "To Event <Dry Run>:" ).local8Bit() + cout << i18n( "To Event <Dry Run>:" ).local8Bit().data() << endl; printSpecs(); } else { @@ -75,11 +75,11 @@ bool KonsoleKalendarChange::changeEvent() << endl; if ( m_variables->isVerbose() ) { - cout << i18n( "Change Event <Verbose>:" ).local8Bit() + cout << i18n( "Change Event <Verbose>:" ).local8Bit().data() << endl; printSpecs( event ); - cout << i18n( "To Event <Dry Run>:" ).local8Bit() + cout << i18n( "To Event <Dry Run>:" ).local8Bit().data() << endl; printSpecs(); } @@ -108,14 +108,14 @@ bool KonsoleKalendarChange::changeEvent() if ( m_variables->getCalendar()->addEvent( event ) ) { cout << i18n( "Success: \"%1\" changed" ) - .arg( event->summary() ).local8Bit() + .tqarg( event->summary() ).local8Bit().data() << endl; m_variables->getCalendar()->save(); status = true; } else { cout << i18n( "Failure: \"%1\" not changed" ) - .arg( event->summary() ).local8Bit() + .tqarg( event->summary() ).local8Bit().data() << endl; } } @@ -128,53 +128,53 @@ bool KonsoleKalendarChange::changeEvent() void KonsoleKalendarChange::printSpecs( Event *event ) { cout << i18n( " UID: %1" ). - arg( event->uid() ).local8Bit() + tqarg( event->uid() ).local8Bit().data() << endl; cout << i18n( " What: %1" ). - arg( event->summary() ).local8Bit() + tqarg( event->summary() ).local8Bit().data() << endl; cout << i18n( " Begin: %1" ). - arg( event->dtStart().toString( TQt::TextDate ) ).local8Bit() + tqarg( event->dtStart().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " End: %1" ). - arg( event->dtEnd().toString( TQt::TextDate ) ).local8Bit() + tqarg( event->dtEnd().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " Desc: %1" ). - arg( event->description() ).local8Bit() + tqarg( event->description() ).local8Bit().data() << endl; cout << i18n( " Location: %1" ). - arg( event->location() ).local8Bit() + tqarg( event->location() ).local8Bit().data() << endl; } void KonsoleKalendarChange::printSpecs() { cout << i18n( " UID: %1" ). - arg( m_variables->getUID() ).local8Bit() + tqarg( m_variables->getUID() ).local8Bit().data() << endl; cout << i18n( " What: %1" ). - arg( m_variables->getSummary() ).local8Bit() + tqarg( m_variables->getSummary() ).local8Bit().data() << endl; cout << i18n( " Begin: %1" ). - arg( m_variables->getStartDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getStartDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " End: %1" ). - arg( m_variables->getEndDateTime().toString( TQt::TextDate ) ).local8Bit() + tqarg( m_variables->getEndDateTime().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " Desc: %1" ). - arg( m_variables->getDescription() ).local8Bit() + tqarg( m_variables->getDescription() ).local8Bit().data() << endl; cout << i18n( " Location: %1" ). - arg( m_variables->getLocation() ).local8Bit() + tqarg( m_variables->getLocation() ).local8Bit().data() << endl; } diff --git a/konsolekalendar/konsolekalendardelete.cpp b/konsolekalendar/konsolekalendardelete.cpp index b3f27650e..160e87e1a 100644 --- a/konsolekalendar/konsolekalendardelete.cpp +++ b/konsolekalendar/konsolekalendardelete.cpp @@ -62,7 +62,7 @@ bool KonsoleKalendarDelete::deleteEvent() Event *event = m_variables->getCalendar()->event( m_variables->getUID() ); if ( event ) { if ( m_variables->isDryRun() ) { - cout << i18n( "Delete Event <Dry Run>:" ).local8Bit() + cout << i18n( "Delete Event <Dry Run>:" ).local8Bit().data() << endl; printSpecs( event ); } else { @@ -71,14 +71,14 @@ bool KonsoleKalendarDelete::deleteEvent() << endl; if ( m_variables->isVerbose() ) { - cout << i18n( "Delete Event <Verbose>:" ).local8Bit() + cout << i18n( "Delete Event <Verbose>:" ).local8Bit().data() << endl; printSpecs( event ); } m_variables->getCalendar()->deleteEvent( event ); cout << i18n( "Success: \"%1\" deleted" ) - .arg( event->summary() ).local8Bit() + .tqarg( event->summary() ).local8Bit().data() << endl; m_variables->getCalendar()->save(); @@ -93,26 +93,26 @@ bool KonsoleKalendarDelete::deleteEvent() void KonsoleKalendarDelete::printSpecs( Event *event ) { cout << i18n( " UID: %1" ). - arg( m_variables->getUID() ).local8Bit() + tqarg( m_variables->getUID() ).local8Bit().data() << endl; cout << i18n( " What: %1" ). - arg( event->summary() ).local8Bit() + tqarg( event->summary() ).local8Bit().data() << endl; cout << i18n( " Begin: %1" ). - arg( event->dtStart().toString( TQt::TextDate ) ).local8Bit() + tqarg( event->dtStart().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " End: %1" ). - arg( event->dtEnd().toString( TQt::TextDate ) ).local8Bit() + tqarg( event->dtEnd().toString( Qt::TextDate ) ).local8Bit().data() << endl; cout << i18n( " Desc: %1" ). - arg( event->description() ).local8Bit() + tqarg( event->description() ).local8Bit().data() << endl; cout << i18n( " Location: %1" ). - arg( event->location() ).local8Bit() + tqarg( event->location() ).local8Bit().data() << endl; } diff --git a/konsolekalendar/konsolekalendarepoch.cpp b/konsolekalendar/konsolekalendarepoch.cpp index e314bde7c..ec59d7a3f 100644 --- a/konsolekalendar/konsolekalendarepoch.cpp +++ b/konsolekalendar/konsolekalendarepoch.cpp @@ -53,7 +53,7 @@ KonsoleKalendarEpoch::~KonsoleKalendarEpoch() TQDateTime KonsoleKalendarEpoch::epoch2TQDateTime( uint epoch ) { TQDateTime dt; - dt.setTime_t( epoch, TQt::UTC ); + dt.setTime_t( epoch, Qt::UTC ); return( dt ); } @@ -64,8 +64,8 @@ uint KonsoleKalendarEpoch::TQDateTime2epoch( TQDateTime dt ) // SORRY QT DOESN'T HANDLE DAYLIGHT SAVINGS TIME. // Compute #seconds to subtract for local timezone difference from UTC. - int offset = TQDateTime::tqcurrentDateTime( TQt::UTC ).toTime_t() - - TQDateTime::tqcurrentDateTime( TQt::LocalTime ).toTime_t(); + int offset = TQDateTime::tqcurrentDateTime( Qt::UTC ).toTime_t() + - TQDateTime::tqcurrentDateTime( Qt::LocalTime ).toTime_t(); return( dt.toTime_t() - offset ); } diff --git a/konsolekalendar/main.cpp b/konsolekalendar/main.cpp index 14b892052..0fc5bf72c 100644 --- a/konsolekalendar/main.cpp +++ b/konsolekalendar/main.cpp @@ -241,22 +241,22 @@ int main( int argc, char *argv[] ) if ( args->isSet( "export-list" ) ) { cout << endl; cout << i18n( "%1 supports these export formats:" ). - arg( progDisplay ).local8Bit() + tqarg( progDisplay ).local8Bit().data() << endl; cout << i18n( " %1 [Default]" ). - arg( "Text" ).local8Bit() + tqarg( "Text" ).local8Bit().data() << endl; cout << i18n( " %1 (like %2, but more compact)" ). - arg( "Short", "Text" ).local8Bit() + tqarg( "Short", "Text" ).local8Bit().data() << endl; cout << i18n( " %1" ). - arg( "HTML" ).local8Bit() + tqarg( "HTML" ).local8Bit().data() << endl; cout << i18n( " %1 (like %2, but in a month view)" ). - arg( "HTMLmonth", "HTML" ).local8Bit() + tqarg( "HTMLmonth", "HTML" ).local8Bit().data() << endl; cout << i18n( " %1 (Comma-Separated Values)" ). - arg( "CSV" ).local8Bit() + tqarg( "CSV" ).local8Bit().data() << endl; cout << endl; return 0; @@ -272,14 +272,14 @@ int main( int argc, char *argv[] ) if ( args->isSet( "todo" ) ) { variables.setUseTodos( true ); kdDebug() << "main | parse options | use To-dos" << endl; - cout << i18n( "Sorry, To-dos are not working yet." ).local8Bit() + cout << i18n( "Sorry, To-dos are not working yet." ).local8Bit().data() << endl; return 1; } if ( args->isSet( "journal" ) ) { variables.setUseJournals( true ); kdDebug() << "main | parse options | use Journals" << endl; - cout << i18n( "Sorry, Journals are not working yet." ).local8Bit() + cout << i18n( "Sorry, Journals are not working yet." ).local8Bit().data() << endl; return 1; } @@ -315,7 +315,7 @@ int main( int argc, char *argv[] ) variables.setExportType( ExportTypeTextShort ); } else { cout << i18n( "Invalid Export Type Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } @@ -472,16 +472,16 @@ int main( int argc, char *argv[] ) << "(" << option << ")" << endl; - startdate = TQDate::fromString( option, TQt::ISODate ); + startdate = TQDate::fromString( option, Qt::ISODate ); if ( !startdate.isValid() ) { cout << i18n( "Invalid Start Date Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } kdDebug() << "main | parse options | " << "Start date after conversion: " - << "(" << startdate.toString() << ")" + << "(" << TQString(startdate.toString()) << ")" << endl; } @@ -497,16 +497,16 @@ int main( int argc, char *argv[] ) << endl; if ( option.upper() != "FLOAT" ) { - starttime = TQTime::fromString( option, TQt::ISODate ); + starttime = TQTime::fromString( option, Qt::ISODate ); if ( !starttime.isValid() ) { cout << i18n( "Invalid Start Time Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } kdDebug() << "main | parse options | " << "Start time after conversion: " - << "(" << starttime.toString() << ")" + << "(" << TQString(starttime.toString()) << ")" << endl; } else { variables.setFloating( true ); @@ -527,16 +527,16 @@ int main( int argc, char *argv[] ) << "(" << option << ")" << endl; - enddate = TQDate::fromString( option, TQt::ISODate ); + enddate = TQDate::fromString( option, Qt::ISODate ); if ( !enddate.isValid() ) { cout << i18n( "Invalid End Date Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } kdDebug() << "main | parse options | " << "End date after conversion: " - << "(" << enddate.toString() << ")" + << "(" << TQString(enddate.toString()) << ")" << endl; } @@ -554,7 +554,7 @@ int main( int argc, char *argv[] ) if ( !ok ) { cout << i18n( "Invalid Date Count Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } @@ -563,7 +563,7 @@ int main( int argc, char *argv[] ) enddate = enddate.addDays( variables.getDaysCount() ); kdDebug() << "main | parse options | " << "End date after conversion: " - << "(" << enddate.toString() << ")" + << "(" << TQString(enddate.toString()) << ")" << endl; } @@ -579,17 +579,17 @@ int main( int argc, char *argv[] ) << endl; if ( option.upper() != "FLOAT" ) { - endtime = TQTime::fromString( option, TQt::ISODate ); + endtime = TQTime::fromString( option, Qt::ISODate ); if ( !endtime.isValid() ) { cout << i18n( "Invalid End Time Specified: %1" ). - arg( option ).local8Bit() + tqarg( option ).local8Bit().data() << endl; return 1; } kdDebug() << "main | parse options | " << "End time after conversion: " - << "(" << endtime.toString() << ")" + << "(" << TQString(endtime.toString()) << ")" << endl; } else { variables.setFloating( true ); @@ -682,12 +682,12 @@ int main( int argc, char *argv[] ) if ( remote ) { cout << i18n( "Attempting to create a remote file %1" ). - arg( variables.getCalendarFile() ).local8Bit() << endl; + tqarg( variables.getCalendarFile() ).local8Bit().data() << endl; return 1; } else { if ( exists ) { cout << i18n( "Calendar %1 already exists" ). - arg( variables.getCalendarFile() ).local8Bit() + tqarg( variables.getCalendarFile() ).local8Bit().data() << endl; return 1; } @@ -695,12 +695,12 @@ int main( int argc, char *argv[] ) if ( konsolekalendar->createCalendar() ) { cout << i18n( "Calendar %1 successfully created" ). - arg( variables.getCalendarFile() ).local8Bit() + tqarg( variables.getCalendarFile() ).local8Bit().data() << endl; return 0; } else { cout << i18n( "Unable to create calendar: %1" ). - arg( variables.getCalendarFile() ).local8Bit() + tqarg( variables.getCalendarFile() ).local8Bit().data() << endl; return 1; } @@ -708,9 +708,9 @@ int main( int argc, char *argv[] ) if ( !exists ) { cout << i18n( "Calendar file not found %1" ). - arg( variables.getCalendarFile() ).local8Bit() + tqarg( variables.getCalendarFile() ).local8Bit().data() << endl; - cout << i18n( "Try --create to create new calendar file" ).local8Bit() + cout << i18n( "Try --create to create new calendar file" ).local8Bit().data() << endl; return 1; } @@ -854,10 +854,10 @@ int main( int argc, char *argv[] ) // Some more debug prints kdDebug() << "main | datetimestamp | StartDate=" - << startdatetime.toString( TQt::TextDate ) + << startdatetime.toString( Qt::TextDate ) << endl; kdDebug() << "main | datetimestamp | EndDate=" - << enddatetime.toString( TQt::TextDate ) + << enddatetime.toString( Qt::TextDate ) << endl; /*************************************************************************** @@ -870,7 +870,7 @@ int main( int argc, char *argv[] ) "Only 1 operation mode " "(view, add, change, delete, create) " "permitted at any one time" - ).local8Bit() << endl; + ).local8Bit().data() << endl; return 1; } @@ -878,7 +878,7 @@ int main( int argc, char *argv[] ) if ( startdatetime > enddatetime ) { cout << i18n( "Ending Date/Time occurs before the Starting Date/Time" - ).local8Bit() << endl; + ).local8Bit().data() << endl; return 1; } @@ -894,17 +894,17 @@ int main( int argc, char *argv[] ) */ TQString prodId = "-//K Desktop Environment//NONSGML %1 %2//EN"; CalFormat::setApplication( progDisplay, - prodId.arg( progDisplay ).arg( progVersion ) ); + prodId.tqarg( progDisplay ).tqarg( progVersion ) ); if ( importFile ) { if ( konsolekalendar->importCalendar() ) { cout << i18n( "Calendar %1 successfully imported" ). - arg( variables.getImportFile() ).local8Bit() + tqarg( variables.getImportFile() ).local8Bit().data() << endl; return 0; } else { cout << i18n( "Unable to import calendar: %1" ). - arg( variables.getImportFile() ).local8Bit() + tqarg( variables.getImportFile() ).local8Bit().data() << endl; return 1; } @@ -920,7 +920,7 @@ int main( int argc, char *argv[] ) } else { cout << i18n( "Attempting to insert an event that already exists" - ).local8Bit() << endl; + ).local8Bit().data() << endl; return 1; } } @@ -931,12 +931,12 @@ int main( int argc, char *argv[] ) << endl; if ( !variables.isUID() ) { cout << i18n( "Missing event UID: " - "use --uid command line option" ).local8Bit() + "use --uid command line option" ).local8Bit().data() << endl; return 1; } if ( konsolekalendar->changeEvent() != true ) { - cout << i18n( "No such event UID: change event failed" ).local8Bit() + cout << i18n( "No such event UID: change event failed" ).local8Bit().data() << endl; return 1; } @@ -951,12 +951,12 @@ int main( int argc, char *argv[] ) << endl; if ( !variables.isUID() ) { cout << i18n( "Missing event UID: " - "use --uid command line option" ).local8Bit() + "use --uid command line option" ).local8Bit().data() << endl; return 1; } if ( konsolekalendar->deleteEvent() != true ) { - cout << i18n( "No such event UID: delete event failed").local8Bit() + cout << i18n( "No such event UID: delete event failed").local8Bit().data() << endl; return 1; } @@ -971,7 +971,7 @@ int main( int argc, char *argv[] ) << endl; if ( !konsolekalendar->showInstance() ) { cout << i18n( "Cannot open specified export file: %1" ). - arg( variables.getExportFile() ).local8Bit() + tqarg( variables.getExportFile() ).local8Bit().data() << endl; return 1; } diff --git a/kontact/interfaces/core.cpp b/kontact/interfaces/core.cpp index b77fabd25..d47058276 100644 --- a/kontact/interfaces/core.cpp +++ b/kontact/interfaces/core.cpp @@ -66,12 +66,12 @@ KParts::ReadOnlyPart *Core::createPart( const char *libname ) KParts::ReadOnlyPart *part = KParts::ComponentFactory:: createPartInstanceFromLibrary<KParts::ReadOnlyPart> - ( libname, this, 0, this, "kontact", TQStringList(), &error ); + ( libname, this, 0, TQT_TQOBJECT(this), "kontact", TQStringList(), &error ); KParts::ReadOnlyPart *pimPart = dynamic_cast<KParts::ReadOnlyPart*>( part ); if ( pimPart ) { mParts.insert( libname, pimPart ); - TQObject::connect( pimPart, TQT_SIGNAL( destroyed( TQObject * ) ), + QObject::connect( pimPart, TQT_SIGNAL( destroyed( TQObject * ) ), TQT_SLOT( slotPartDestroyed( TQObject * ) ) ); } else { // TODO move to KParts::ComponentFactory @@ -86,10 +86,10 @@ KParts::ReadOnlyPart *Core::createPart( const char *libname ) d->lastErrorMessage = KLibLoader::self()->lastErrorMessage(); break; case KParts::ComponentFactory::ErrNoFactory: - d->lastErrorMessage = i18n( "Program error: the library %1 does not provide a factory." ).arg( libname ); + d->lastErrorMessage = i18n( "Program error: the library %1 does not provide a factory." ).tqarg( libname ); break; case KParts::ComponentFactory::ErrNoComponent: - d->lastErrorMessage = i18n( "Program error: the library %1 does not support creating components of the specified type" ).arg( libname ); + d->lastErrorMessage = i18n( "Program error: the library %1 does not support creating components of the specified type" ).tqarg( libname ); break; } kdWarning(5601) << d->lastErrorMessage << endl; diff --git a/kontact/interfaces/summary.cpp b/kontact/interfaces/summary.cpp index 0f4c048cd..4fa495bf1 100644 --- a/kontact/interfaces/summary.cpp +++ b/kontact/interfaces/summary.cpp @@ -82,14 +82,14 @@ void Summary::mousePressEvent( TQMouseEvent *event ) void Summary::mouseMoveEvent( TQMouseEvent *event ) { - if ( (event->state() & LeftButton) && + if ( (event->state() & Qt::LeftButton) && (event->pos() - mDragStartPoint).manhattanLength() > 4 ) { TQDragObject *drag = new TQTextDrag( "", this, "SummaryWidgetDrag" ); TQPixmap pm = TQPixmap::grabWidget( this ); if ( pm.width() > 300 ) - pm = pm.convertToImage().smoothScale( 300, 300, TQImage::ScaleMin ); + pm = pm.convertToImage().smoothScale( 300, 300, TQ_ScaleMin ); TQPainter painter; painter.begin( &pm ); diff --git a/kontact/plugins/akregator/akregator_plugin.cpp b/kontact/plugins/akregator/akregator_plugin.cpp index d0ef181f9..37b85be08 100644 --- a/kontact/plugins/akregator/akregator_plugin.cpp +++ b/kontact/plugins/akregator/akregator_plugin.cpp @@ -49,7 +49,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_akregator, PluginFactory( "kontact_akregator" ) ) Plugin::Plugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "akregator" ), m_stub(0) + : Kontact::Plugin( core, TQT_TQOBJECT(core), "akregator" ), m_stub(0) { setInstance( PluginFactory::instance() ); diff --git a/kontact/plugins/kaddressbook/kaddressbook_plugin.cpp b/kontact/plugins/kaddressbook/kaddressbook_plugin.cpp index 8fafeb984..db1d80caf 100644 --- a/kontact/plugins/kaddressbook/kaddressbook_plugin.cpp +++ b/kontact/plugins/kaddressbook/kaddressbook_plugin.cpp @@ -52,7 +52,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_kaddressbookplugin, KAddressbookPluginFactory( "kontact_kaddressbookplugin" ) ) KAddressbookPlugin::KAddressbookPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "kaddressbook" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "kaddressbook" ), mStub( 0 ) { setInstance( KAddressbookPluginFactory::instance() ); @@ -171,7 +171,7 @@ void KAddressbookPlugin::processDropEvent( TQDropEvent *event ) } KMessageBox::sorry( core(), i18n( "Cannot handle drop events of type '%1'." ) - .arg( event->format() ) ); + .tqarg( event->format() ) ); } diff --git a/kontact/plugins/karm/karm_plugin.cpp b/kontact/plugins/karm/karm_plugin.cpp index 0f3fa946d..5e5ecbb67 100644 --- a/kontact/plugins/karm/karm_plugin.cpp +++ b/kontact/plugins/karm/karm_plugin.cpp @@ -37,7 +37,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_karm, KarmPluginFactory( "kontact_karm" ) ) KarmPlugin::KarmPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "KArm" ) + : Kontact::Plugin( core, TQT_TQOBJECT(core), "KArm" ) { setInstance( KarmPluginFactory::instance() ); (void)dcopClient(); diff --git a/kontact/plugins/kitchensync/kitchensync_plugin.cpp b/kontact/plugins/kitchensync/kitchensync_plugin.cpp index 90ce22db5..677972d30 100644 --- a/kontact/plugins/kitchensync/kitchensync_plugin.cpp +++ b/kontact/plugins/kitchensync/kitchensync_plugin.cpp @@ -43,7 +43,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_kitchensync, KitchenSyncPluginFactory( "kontact_kitchensync" ) ) KitchenSyncPlugin::KitchenSyncPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "KitchenSync" ) + : Kontact::Plugin( core, TQT_TQOBJECT(core), "KitchenSync" ) { setInstance( KitchenSyncPluginFactory::instance() ); } diff --git a/kontact/plugins/kmail/kcmkmailsummary.cpp b/kontact/plugins/kmail/kcmkmailsummary.cpp index ae7765553..1c1812cec 100644 --- a/kontact/plugins/kmail/kcmkmailsummary.cpp +++ b/kontact/plugins/kmail/kcmkmailsummary.cpp @@ -113,7 +113,7 @@ void KCMKMailSummary::initFolders() mFolderMap.insert( *it, new TQListViewItem( mFolderView, displayName ) ); } else { - const int pos = (*it).findRev( '/' ); + const int pos = (*it).tqfindRev( '/' ); const TQString tqparentFolder = (*it).left( pos ); mFolderMap.insert( *it, new TQCheckListItem( mFolderMap[ tqparentFolder ], diff --git a/kontact/plugins/kmail/kmail_plugin.cpp b/kontact/plugins/kmail/kmail_plugin.cpp index 55a192e3e..51fceaa61 100644 --- a/kontact/plugins/kmail/kmail_plugin.cpp +++ b/kontact/plugins/kmail/kmail_plugin.cpp @@ -56,7 +56,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_kmailplugin, KMailPluginFactory( "kontact_kmailplugin" ) ) KMailPlugin::KMailPlugin(Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "kmail" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "kmail" ), mStub( 0 ) { setInstance( KMailPluginFactory::instance() ); diff --git a/kontact/plugins/kmail/summarywidget.cpp b/kontact/plugins/kmail/summarywidget.cpp index b72283421..2f67846ac 100644 --- a/kontact/plugins/kmail/summarywidget.cpp +++ b/kontact/plugins/kmail/summarywidget.cpp @@ -142,7 +142,7 @@ void SummaryWidget::updateFolderList( const TQStringList& folders ) TQLabel *label = new TQLabel( TQString( i18n("%1: number of unread messages " "%2: total number of messages", "%1 / %2") ) - .arg( numUnreadMsg ).arg( numMsg ), this ); + .tqarg( numUnreadMsg ).tqarg( numMsg ), this ); label->tqsetAlignment( AlignLeft ); label->show(); mLayout->addWidget( label, counter, 2 ); @@ -164,9 +164,9 @@ void SummaryWidget::updateFolderList( const TQStringList& folders ) bool SummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) - emit message( i18n( "Open Folder: \"%1\"" ).arg( label->text() ) ); + emit message( i18n( "Open Folder: \"%1\"" ).tqarg( label->text() ) ); if ( e->type() == TQEvent::Leave ) emit message( TQString() ); } diff --git a/kontact/plugins/knode/knode_plugin.cpp b/kontact/plugins/knode/knode_plugin.cpp index d78e1e29b..365e30d09 100644 --- a/kontact/plugins/knode/knode_plugin.cpp +++ b/kontact/plugins/knode/knode_plugin.cpp @@ -45,7 +45,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_knodeplugin, KNodePlugin::KNodePlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "knode" ), mStub(0) + : Kontact::Plugin( core, TQT_TQOBJECT(core), "knode" ), mStub(0) { setInstance( KNodePluginFactory::instance() ); diff --git a/kontact/plugins/knotes/knotes_part.cpp b/kontact/plugins/knotes/knotes_part.cpp index a7864c423..b4b0f7786 100644 --- a/kontact/plugins/knotes/knotes_part.cpp +++ b/kontact/plugins/knotes/knotes_part.cpp @@ -201,7 +201,7 @@ TQString KNotesPart::newNote( const TQString& name, const TQString& text ) TQString KNotesPart::newNoteFromClipboard( const TQString& name ) { - const TQString& text = KApplication::clipboard()->text(); + const TQString& text = KApplication::tqclipboard()->text(); return newNote( name, text ); } diff --git a/kontact/plugins/knotes/knotes_part_p.h b/kontact/plugins/knotes/knotes_part_p.h index 7665426c6..9f8a4bb83 100644 --- a/kontact/plugins/knotes/knotes_part_p.h +++ b/kontact/plugins/knotes/knotes_part_p.h @@ -144,7 +144,7 @@ class KNoteEditDlg : public KDialogBase, virtual public KXMLGUIClient mNoteEdit->setFocus(); KXMLGUIBuilder builder( page ); - KXMLGUIFactory factory( &builder, this ); + KXMLGUIFactory factory( &builder, TQT_TQOBJECT(this) ); factory.addClient( this ); mTool = static_cast<KToolBar *>(factory.container( "note_tool", this )); diff --git a/kontact/plugins/knotes/knotes_plugin.cpp b/kontact/plugins/knotes/knotes_plugin.cpp index 0fe265524..a72f14b7e 100644 --- a/kontact/plugins/knotes/knotes_plugin.cpp +++ b/kontact/plugins/knotes/knotes_plugin.cpp @@ -39,7 +39,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_knotesplugin, KNotesPlugin::KNotesPlugin( Kontact::Core *core, const char *, const TQStringList & ) - : Kontact::Plugin( core, core, "knotes" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "knotes" ), mAboutData( 0 ) { setInstance( KNotesPluginFactory::instance() ); diff --git a/kontact/plugins/knotes/knotetip.cpp b/kontact/plugins/knotes/knotetip.cpp index afa21fb40..9e2609fc2 100644 --- a/kontact/plugins/knotes/knotetip.cpp +++ b/kontact/plugins/knotes/knotetip.cpp @@ -75,7 +75,7 @@ void KNoteTip::setNote( KNotesIconViewItem *item ) mNoteIVI = item; if ( !mNoteIVI ) { - killTimers(); + TQT_TQOBJECT(this)->killTimers(); if ( isVisible() ) { setFilter( false ); hide(); @@ -104,7 +104,7 @@ void KNoteTip::setNote( KNotesIconViewItem *item ) resize( w, TQMIN( h, desk.height() / 2 - 20 ) ); hide(); - killTimers(); + TQT_TQOBJECT(this)->killTimers(); setFilter( true ); startTimer( 600 ); // delay showing the tooltip for 0.7 sec } @@ -121,7 +121,7 @@ void KNoteTip::resizeEvent( TQResizeEvent *ev ) void KNoteTip::timerEvent( TQTimerEvent * ) { - killTimers(); + TQT_TQOBJECT(this)->killTimers(); if ( !isVisible() ) { startTimer( 15000 ); // show the tooltip for 15 sec @@ -144,7 +144,7 @@ bool KNoteTip::eventFilter( TQObject *, TQEvent *e ) case TQEvent::FocusIn: case TQEvent::FocusOut: case TQEvent::Wheel: - killTimers(); + TQT_TQOBJECT(this)->killTimers(); setFilter( false ); hide(); default: diff --git a/kontact/plugins/knotes/summarywidget.cpp b/kontact/plugins/knotes/summarywidget.cpp index 611425b9d..c0e1ef402 100644 --- a/kontact/plugins/knotes/summarywidget.cpp +++ b/kontact/plugins/knotes/summarywidget.cpp @@ -138,9 +138,9 @@ void KNotesSummaryWidget::urlClicked( const TQString &/*uid*/ ) bool KNotesSummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) - emit message( i18n( "Read Note: \"%1\"" ).arg( label->text() ) ); + emit message( i18n( "Read Note: \"%1\"" ).tqarg( label->text() ) ); if ( e->type() == TQEvent::Leave ) emit message( TQString() ); } diff --git a/kontact/plugins/korganizer/journalplugin.cpp b/kontact/plugins/korganizer/journalplugin.cpp index a14785a7e..87347f189 100644 --- a/kontact/plugins/korganizer/journalplugin.cpp +++ b/kontact/plugins/korganizer/journalplugin.cpp @@ -43,7 +43,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_journalplugin, JournalPluginFactory( "kontact_journalplugin" ) ) JournalPlugin::JournalPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "korganizer" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "korganizer" ), mIface( 0 ) { setInstance( JournalPluginFactory::instance() ); diff --git a/kontact/plugins/korganizer/kcmkorgsummary.cpp b/kontact/plugins/korganizer/kcmkorgsummary.cpp index e07bd4411..9e698a2bd 100644 --- a/kontact/plugins/korganizer/kcmkorgsummary.cpp +++ b/kontact/plugins/korganizer/kcmkorgsummary.cpp @@ -92,7 +92,7 @@ void KCMKOrgSummary::initGUI() { TQVBoxLayout *tqlayout = new TQVBoxLayout( this, 0, KDialog::spacingHint() ); - mCalendarGroup = new TQButtonGroup( 0, Vertical, i18n( "Appointments" ), this ); + mCalendarGroup = new TQButtonGroup( 0, Qt::Vertical, i18n( "Appointments" ), this ); TQVBoxLayout *boxLayout = new TQVBoxLayout( mCalendarGroup->tqlayout(), KDialog::spacingHint() ); @@ -124,7 +124,7 @@ void KCMKOrgSummary::initGUI() tqlayout->addWidget( mCalendarGroup ); - mTodoGroup = new TQButtonGroup( 2, Horizontal, i18n( "To-dos" ), this ); + mTodoGroup = new TQButtonGroup( 2, Qt::Horizontal, i18n( "To-dos" ), this ); new TQRadioButton( i18n( "Show all to-dos" ), mTodoGroup ); new TQRadioButton( i18n( "Show today's to-dos only" ), mTodoGroup ); diff --git a/kontact/plugins/korganizer/korganizerplugin.cpp b/kontact/plugins/korganizer/korganizerplugin.cpp index 2a712c8cc..d626c9519 100644 --- a/kontact/plugins/korganizer/korganizerplugin.cpp +++ b/kontact/plugins/korganizer/korganizerplugin.cpp @@ -57,7 +57,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_korganizerplugin, KOrganizerPluginFactory( "kontact_korganizerplugin" ) ) KOrganizerPlugin::KOrganizerPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "korganizer" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "korganizer" ), mIface( 0 ) { @@ -195,7 +195,7 @@ void KOrganizerPlugin::processDropEvent( TQDropEvent *event ) KCal::Incidence *i = incidences.first(); TQString summary; if ( dynamic_cast<KCal::Journal*>( i ) ) - summary = i18n( "Note: %1" ).arg( i->summary() ); + summary = i18n( "Note: %1" ).tqarg( i->summary() ); else summary = i->summary(); interface()->openEventEditor( summary, i->description(), TQString() ); @@ -219,22 +219,22 @@ void KOrganizerPlugin::processDropEvent( TQDropEvent *event ) i18n("Drops of multiple mails are not supported." ) ); } else { KPIM::MailSummary mail = mails.first(); - TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").arg( mail.from() ) - .arg( mail.to() ).arg( mail.subject() ); + TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").tqarg( mail.from() ) + .tqarg( mail.to() ).tqarg( mail.subject() ); KTempFile tf; tf.setAutoDelete( true ); TQString uri = TQString::tqfromLatin1("kmail:") + TQString::number( mail.serialNumber() ); tf.file()->writeBlock( event->tqencodedData( "message/rfc822" ) ); tf.close(); - interface()->openEventEditor( i18n("Mail: %1").arg( mail.subject() ), txt, + interface()->openEventEditor( i18n("Mail: %1").tqarg( mail.subject() ), txt, uri, tf.name(), TQStringList(), "message/rfc822" ); } return; } KMessageBox::sorry( core(), i18n("Cannot handle drop events of type '%1'.") - .arg( event->format() ) ); + .tqarg( event->format() ) ); } bool KOrganizerPlugin::queryClose() const { diff --git a/kontact/plugins/korganizer/summarywidget.cpp b/kontact/plugins/korganizer/summarywidget.cpp index 1409c37b3..649f366c9 100644 --- a/kontact/plugins/korganizer/summarywidget.cpp +++ b/kontact/plugins/korganizer/summarywidget.cpp @@ -191,7 +191,7 @@ void SummaryWidget::updateView() // Fill Event Summary Field TQString newtext = ev->summary(); if ( ev->isMultiDay() && !ev->doesFloat() ) { - newtext.append( TQString(" (%1/%2)").arg( dayof ).arg( span ) ); + newtext.append( TQString(" (%1/%2)").tqarg( dayof ).tqarg( span ) ); } KURLLabel *urlLabel = new KURLLabel( this ); @@ -225,8 +225,8 @@ void SummaryWidget::updateView() } } datestr = i18n( "Time from - to", "%1 - %2" ) - .arg( KGlobal::locale()->formatTime( sST ) ) - .arg( KGlobal::locale()->formatTime( sET ) ); + .tqarg( KGlobal::locale()->formatTime( sST ) ) + .tqarg( KGlobal::locale()->formatTime( sET ) ); label = new TQLabel( datestr, this ); label->tqsetAlignment( AlignLeft | AlignVCenter ); mLayout->addWidget( label, counter, 3 ); @@ -286,9 +286,9 @@ void SummaryWidget::popupMenu( const TQString &uid ) bool SummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) - emit message( i18n( "Edit Appointment: \"%1\"" ).arg( label->text() ) ); + emit message( i18n( "Edit Appointment: \"%1\"" ).tqarg( label->text() ) ); if ( e->type() == TQEvent::Leave ) emit message( TQString() ); } diff --git a/kontact/plugins/korganizer/todoplugin.cpp b/kontact/plugins/korganizer/todoplugin.cpp index cefd8bbe7..6b6238bfe 100644 --- a/kontact/plugins/korganizer/todoplugin.cpp +++ b/kontact/plugins/korganizer/todoplugin.cpp @@ -55,7 +55,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_todoplugin, TodoPluginFactory( "kontact_todoplugin" ) ) TodoPlugin::TodoPlugin( Kontact::Core *core, const char *, const TQStringList& ) - : Kontact::Plugin( core, core, "korganizer" ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), "korganizer" ), mIface( 0 ) { setInstance( TodoPluginFactory::instance() ); @@ -187,7 +187,7 @@ void TodoPlugin::processDropEvent( TQDropEvent *event ) KCal::Incidence *i = incidences.first(); TQString summary; if ( dynamic_cast<KCal::Journal*>( i ) ) - summary = i18n( "Note: %1" ).arg( i->summary() ); + summary = i18n( "Note: %1" ).tqarg( i->summary() ); else summary = i->summary(); interface()->openTodoEditor( summary, i->description(), TQString() ); @@ -210,8 +210,8 @@ void TodoPlugin::processDropEvent( TQDropEvent *event ) i18n("Drops of multiple mails are not supported." ) ); } else { KPIM::MailSummary mail = mails.first(); - TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").arg( mail.from() ) - .arg( mail.to() ).arg( mail.subject() ); + TQString txt = i18n("From: %1\nTo: %2\nSubject: %3").tqarg( mail.from() ) + .tqarg( mail.to() ).tqarg( mail.subject() ); KTempFile tf; tf.setAutoDelete( true ); @@ -219,14 +219,14 @@ void TodoPlugin::processDropEvent( TQDropEvent *event ) mail.messageId(); tf.file()->writeBlock( event->tqencodedData( "message/rfc822" ) ); tf.close(); - interface()->openTodoEditor( i18n("Mail: %1").arg( mail.subject() ), + interface()->openTodoEditor( i18n("Mail: %1").tqarg( mail.subject() ), txt, uri, tf.name(), TQStringList(), "message/rfc822", false ); } return; } KMessageBox::sorry( core(), i18n("Cannot handle drop events of type '%1'.") - .arg( event->format() ) ); + .tqarg( event->format() ) ); } #include "todoplugin.moc" diff --git a/kontact/plugins/korganizer/todosummarywidget.cpp b/kontact/plugins/korganizer/todosummarywidget.cpp index 7bd1be11a..1109f314a 100644 --- a/kontact/plugins/korganizer/todosummarywidget.cpp +++ b/kontact/plugins/korganizer/todosummarywidget.cpp @@ -211,7 +211,7 @@ void TodoSummaryWidget::removeTodo( const TQString &uid ) void TodoSummaryWidget::completeTodo( const TQString &uid ) { KCal::Todo *todo = mCalendar->todo( uid ); - IncidenceChanger *changer = new IncidenceChanger( mCalendar, this ); + IncidenceChanger *changer = new IncidenceChanger( mCalendar, TQT_TQOBJECT(this) ); if ( !todo->isReadOnly() && changer->beginChange( todo, 0, TQString() ) ) { KCal::Todo *oldTodo = todo->clone(); todo->setCompleted( TQDateTime::tqcurrentDateTime() ); @@ -251,9 +251,9 @@ void TodoSummaryWidget::popupMenu( const TQString &uid ) bool TodoSummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) - emit message( i18n( "Edit To-do: \"%1\"" ).arg( label->text() ) ); + emit message( i18n( "Edit To-do: \"%1\"" ).tqarg( label->text() ) ); if ( e->type() == TQEvent::Leave ) emit message( TQString() ); } diff --git a/kontact/plugins/kpilot/kpilot_plugin.cpp b/kontact/plugins/kpilot/kpilot_plugin.cpp index 88e9d7886..402d1e21a 100644 --- a/kontact/plugins/kpilot/kpilot_plugin.cpp +++ b/kontact/plugins/kpilot/kpilot_plugin.cpp @@ -35,7 +35,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_kpilotplugin, KPilotPluginFactory( "kontact_kpilotplugin" ) ) KPilotPlugin::KPilotPlugin( Kontact::Core *core, const char *name, const TQStringList& ) - : Kontact::Plugin( core, core, "kpilot" ), mAboutData( 0 ) + : Kontact::Plugin( core, TQT_TQOBJECT(core), "kpilot" ), mAboutData( 0 ) { setInstance( KPilotPluginFactory::instance() ); // TODO: Make sure kpilotDaemon is running! diff --git a/kontact/plugins/kpilot/summarywidget.cpp b/kontact/plugins/kpilot/summarywidget.cpp index 3e7577132..a0dafaa29 100644 --- a/kontact/plugins/kpilot/summarywidget.cpp +++ b/kontact/plugins/kpilot/summarywidget.cpp @@ -202,7 +202,7 @@ void SummaryWidget::showSyncLog( const TQString &filename ) TQFile f(filename); if ( !f.open( IO_ReadOnly ) ) { - KMessageBox::error( this, i18n( "Unable to open Hotsync log %1." ).arg( filename ) ); + KMessageBox::error( this, i18n( "Unable to open Hotsync log %1." ).tqarg( filename ) ); return; } diff --git a/kontact/plugins/newsticker/kcmkontactknt.cpp b/kontact/plugins/newsticker/kcmkontactknt.cpp index 07a8aebd0..18a8871e6 100644 --- a/kontact/plugins/newsticker/kcmkontactknt.cpp +++ b/kontact/plugins/newsticker/kcmkontactknt.cpp @@ -356,7 +356,7 @@ void KCMKontactKNT::initGUI() mSelectedNews->setFullWidth( true ); tqlayout->addWidget( mSelectedNews, 0, 2 ); - TQGroupBox *box = new TQGroupBox( 0, TQt::Vertical, + TQGroupBox *box = new TQGroupBox( 0, Qt::Vertical, i18n( "News Feed Settings" ), this ); TQGridLayout *boxLayout = new TQGridLayout( box->tqlayout(), 2, 3, diff --git a/kontact/plugins/newsticker/newsticker_plugin.cpp b/kontact/plugins/newsticker/newsticker_plugin.cpp index 24f30a851..4b187ea47 100644 --- a/kontact/plugins/newsticker/newsticker_plugin.cpp +++ b/kontact/plugins/newsticker/newsticker_plugin.cpp @@ -32,7 +32,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_newstickerplugin, NewsTickerPluginFactory( "kontact_newstickerplugin" ) ) NewsTickerPlugin::NewsTickerPlugin( Kontact::Core *core, const char *name, const TQStringList& ) - : Kontact::Plugin( core, core, name ) + : Kontact::Plugin( core, TQT_TQOBJECT(core), name ) { setInstance( NewsTickerPluginFactory::instance() ); } diff --git a/kontact/plugins/newsticker/summarywidget.cpp b/kontact/plugins/newsticker/summarywidget.cpp index adfc65fb6..3667d402c 100644 --- a/kontact/plugins/newsticker/summarywidget.cpp +++ b/kontact/plugins/newsticker/summarywidget.cpp @@ -300,13 +300,13 @@ void SummaryWidget::rmbMenu( const TQString& url ) menu.insertItem( i18n( "Copy URL to Clipboard" ) ); int id = menu.exec( TQCursor::pos() ); if ( id != -1 ) - kapp->clipboard()->setText( url, TQClipboard::Clipboard ); + kapp->tqclipboard()->setText( url, TQClipboard::Clipboard ); } bool SummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) emit message( label->url() ); if ( e->type() == TQEvent::Leave ) diff --git a/kontact/plugins/specialdates/kcmsdsummary.cpp b/kontact/plugins/specialdates/kcmsdsummary.cpp index b3a671277..3c3420820 100644 --- a/kontact/plugins/specialdates/kcmsdsummary.cpp +++ b/kontact/plugins/specialdates/kcmsdsummary.cpp @@ -87,7 +87,7 @@ void KCMSDSummary::initGUI() { TQGridLayout *tqlayout = new TQGridLayout( this, 3, 2, KDialog::spacingHint() ); - mDaysGroup = new TQButtonGroup( 0, Vertical, i18n( "Special Dates Summary" ), this ); + mDaysGroup = new TQButtonGroup( 0, Qt::Vertical, i18n( "Special Dates Summary" ), this ); TQVBoxLayout *boxLayout = new TQVBoxLayout( mDaysGroup->tqlayout(), KDialog::spacingHint() ); @@ -119,7 +119,7 @@ void KCMSDSummary::initGUI() tqlayout->addMultiCellWidget( mDaysGroup, 0, 0, 0, 1 ); - mCalendarGroup = new TQButtonGroup( 1, Horizontal, i18n( "Special Dates From Calendar" ), this ); + mCalendarGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Special Dates From Calendar" ), this ); mShowBirthdaysFromCal = new TQCheckBox( i18n( "Show birthdays" ), mCalendarGroup ); mShowAnniversariesFromCal = new TQCheckBox( i18n( "Show anniversaries" ), mCalendarGroup ); @@ -127,7 +127,7 @@ void KCMSDSummary::initGUI() mShowSpecialsFromCal = new TQCheckBox( i18n( "Show special occasions" ), mCalendarGroup ); - mContactGroup = new TQButtonGroup( 1, Horizontal, i18n( "Special Dates From Contact List" ), this ); + mContactGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Special Dates From Contact List" ), this ); mShowBirthdaysFromKAB = new TQCheckBox( i18n( "Show birthdays" ), mContactGroup ); mShowAnniversariesFromKAB = new TQCheckBox( i18n( "Show anniversaries" ), mContactGroup ); diff --git a/kontact/plugins/specialdates/sdsummarywidget.cpp b/kontact/plugins/specialdates/sdsummarywidget.cpp index cd4e40d76..136454adf 100644 --- a/kontact/plugins/specialdates/sdsummarywidget.cpp +++ b/kontact/plugins/specialdates/sdsummarywidget.cpp @@ -250,7 +250,7 @@ void SDSummaryWidget::updateView() TQString anniversaryAsString = (*it).custom( "KADDRESSBOOK" , "X-Anniversary" ); if ( !anniversaryAsString.isEmpty() ) { - TQDate anniversary = TQDate::fromString( anniversaryAsString, TQt::ISODate ); + TQDate anniversary = TQDate::fromString( anniversaryAsString, Qt::ISODate ); if ( anniversary.isValid() && mShowAnniversariesFromKAB ) { SDEntry entry; entry.type = IncidenceTypeContact; @@ -593,9 +593,9 @@ void SDSummaryWidget::popupMenu( const TQString &uid ) bool SDSummaryWidget::eventFilter( TQObject *obj, TQEvent* e ) { if ( obj->inherits( "KURLLabel" ) ) { - KURLLabel* label = static_cast<KURLLabel*>( obj ); + KURLLabel* label = static_cast<KURLLabel*>( TQT_TQWIDGET(obj) ); if ( e->type() == TQEvent::Enter ) - emit message( i18n( "Mail to:\"%1\"" ).arg( label->text() ) ); + emit message( i18n( "Mail to:\"%1\"" ).tqarg( label->text() ) ); if ( e->type() == TQEvent::Leave ) emit message( TQString() ); } diff --git a/kontact/plugins/specialdates/specialdates_plugin.cpp b/kontact/plugins/specialdates/specialdates_plugin.cpp index 9d0b60cf5..316f94a77 100644 --- a/kontact/plugins/specialdates/specialdates_plugin.cpp +++ b/kontact/plugins/specialdates/specialdates_plugin.cpp @@ -38,7 +38,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_specialdatesplugin, SpecialdatesPluginFactory( "kontact_specialdatesplugin" ) ) SpecialdatesPlugin::SpecialdatesPlugin( Kontact::Core *core, const char *name, const TQStringList& ) - : Kontact::Plugin( core, core, name ), + : Kontact::Plugin( core, TQT_TQOBJECT(core), name ), mAboutData( 0 ) { setInstance( SpecialdatesPluginFactory::instance() ); diff --git a/kontact/plugins/summary/kcmkontactsummary.cpp b/kontact/plugins/summary/kcmkontactsummary.cpp index ba78c226a..1f7164f80 100644 --- a/kontact/plugins/summary/kcmkontactsummary.cpp +++ b/kontact/plugins/summary/kcmkontactsummary.cpp @@ -120,7 +120,7 @@ void KCMKontactSummary::load() { KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); TQStringList activeSummaries; diff --git a/kontact/plugins/summary/summaryview_part.cpp b/kontact/plugins/summary/summaryview_part.cpp index f28ce79ec..5b53b8b6b 100644 --- a/kontact/plugins/summary/summaryview_part.cpp +++ b/kontact/plugins/summary/summaryview_part.cpp @@ -136,8 +136,8 @@ void SummaryViewPart::updateWidgets() KPIM::IdentityManager idm( true, this ); const KPIM::Identity &id = idm.defaultIdentity(); - TQString currentUser = i18n( "Summary for %1" ).arg( id.fullName() ); - mUsernameLabel->setText( TQString::tqfromLatin1( "<b>%1</b>" ).arg( currentUser ) ); + TQString currentUser = i18n( "Summary for %1" ).tqarg( id.fullName() ); + mUsernameLabel->setText( TQString::tqfromLatin1( "<b>%1</b>" ).tqarg( currentUser ) ); mSummaries.clear(); @@ -247,18 +247,18 @@ void SummaryViewPart::summaryWidgetMoved( TQWidget *target, TQWidget *widget, in return; if ( target == mFrame ) { - if ( mLeftColumn->findWidget( widget ) == -1 && mRightColumn->findWidget( widget ) == -1 ) + if ( mLeftColumn->tqfindWidget( widget ) == -1 && mRightColumn->tqfindWidget( widget ) == -1 ) return; } else { - if ( mLeftColumn->findWidget( target ) == -1 && mRightColumn->findWidget( target ) == -1 || - mLeftColumn->findWidget( widget ) == -1 && mRightColumn->findWidget( widget ) == -1 ) + if ( mLeftColumn->tqfindWidget( target ) == -1 && mRightColumn->tqfindWidget( target ) == -1 || + mLeftColumn->tqfindWidget( widget ) == -1 && mRightColumn->tqfindWidget( widget ) == -1 ) return; } - if ( mLeftColumn->findWidget( widget ) != -1 ) { + if ( mLeftColumn->tqfindWidget( widget ) != -1 ) { mLeftColumn->remove( widget ); mLeftColumnSummaries.remove( widgetName( widget ) ); - } else if ( mRightColumn->findWidget( widget ) != -1 ) { + } else if ( mRightColumn->tqfindWidget( widget ) != -1 ) { mRightColumn->remove( widget ); mRightColumnSummaries.remove( widgetName( widget ) ); } @@ -286,7 +286,7 @@ void SummaryViewPart::summaryWidgetMoved( TQWidget *target, TQWidget *widget, in return; } - int targetPos = mLeftColumn->findWidget( target ); + int targetPos = mLeftColumn->tqfindWidget( target ); if ( targetPos != -1 ) { if ( tqalignment == TQt::AlignBottom ) targetPos++; @@ -294,7 +294,7 @@ void SummaryViewPart::summaryWidgetMoved( TQWidget *target, TQWidget *widget, in mLeftColumn->insertWidget( targetPos, widget ); mLeftColumnSummaries.insert( mLeftColumnSummaries.at( targetPos ), widgetName( widget ) ); } else { - targetPos = mRightColumn->findWidget( target ); + targetPos = mRightColumn->tqfindWidget( target ); if ( tqalignment == TQt::AlignBottom ) targetPos++; @@ -311,13 +311,13 @@ void SummaryViewPart::slotTextChanged() void SummaryViewPart::slotAdjustPalette() { - mMainWidget->setPaletteBackgroundColor( kapp->palette().active().base() ); + mMainWidget->setPaletteBackgroundColor( kapp->tqpalette().active().base() ); } void SummaryViewPart::setDate( const TQDate& newDate ) { TQString date( "<b>%1</b>" ); - date = date.arg( KGlobal::locale()->formatDate( newDate ) ); + date = date.tqarg( KGlobal::locale()->formatDate( newDate ) ); mDateLabel->setText( date ); } @@ -364,7 +364,7 @@ void SummaryViewPart::initGUI( Kontact::Core *core ) mMainWidget = new TQFrame( sv->viewport() ); sv->addChild( mMainWidget ); mMainWidget->setFrameStyle( TQFrame::Panel | TQFrame::Sunken ); - sv->setFocusPolicy( TQWidget::StrongFocus ); + sv->setFocusPolicy( Qt::StrongFocus ); setWidget( sv ); mMainLayout = new TQVBoxLayout( mMainWidget,KDialog::marginHint(), diff --git a/kontact/plugins/summary/summaryview_plugin.cpp b/kontact/plugins/summary/summaryview_plugin.cpp index 555d79544..74b8e3d76 100644 --- a/kontact/plugins/summary/summaryview_plugin.cpp +++ b/kontact/plugins/summary/summaryview_plugin.cpp @@ -34,7 +34,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_summaryplugin, SummaryViewFactory( "kontact_summaryplugin" ) ) SummaryView::SummaryView( Kontact::Core *core, const char *name, const TQStringList& ) - : Kontact::Plugin( core, core, name), + : Kontact::Plugin( core, TQT_TQOBJECT(core), name), mAboutData( 0 ), mPart( 0 ) { setInstance( SummaryViewFactory::instance() ); diff --git a/kontact/plugins/test/test_plugin.cpp b/kontact/plugins/test/test_plugin.cpp index 4e033fcd1..bf5d00577 100644 --- a/kontact/plugins/test/test_plugin.cpp +++ b/kontact/plugins/test/test_plugin.cpp @@ -35,7 +35,7 @@ typedef KGenericFactory< TestPlugin, Kontact::Core > TestPluginFactory; K_EXPORT_COMPONENT_FACTORY( libkptestplugin, TestPluginFactory( "kptestplugin" ) ) TestPlugin::TestPlugin(Kontact::Core *_core, const char *name, const TQStringList &) - : Kontact::Plugin(_core, _core, name) + : Kontact::Plugin(_core, TQT_TQOBJECT(_core), name) { setInstance(TestPluginFactory::instance()); diff --git a/kontact/plugins/weather/summarywidget.cpp b/kontact/plugins/weather/summarywidget.cpp index bc468e844..926f70a73 100644 --- a/kontact/plugins/weather/summarywidget.cpp +++ b/kontact/plugins/weather/summarywidget.cpp @@ -101,7 +101,7 @@ void SummaryWidget::updateView() for ( it = dataList.begin(); it != dataList.end(); ++it ) { TQString cover; for ( uint i = 0; i < (*it).cover().count(); ++i ) - cover += TQString( "- %1\n" ).arg( (*it).cover()[ i ] ); + cover += TQString( "- %1\n" ).tqarg( (*it).cover()[ i ] ); TQImage img; img = (*it).icon(); @@ -121,7 +121,7 @@ void SummaryWidget::updateView() this, TQT_SLOT( showReport( const TQString& ) ) ); TQLabel* label = new TQLabel( this ); - label->setText( TQString( "%1 (%2)" ).arg( (*it).name() ).arg( (*it).temperature() ) ); + label->setText( TQString( "%1 (%2)" ).tqarg( (*it).name() ).tqarg( (*it).temperature() ) ); TQFont font = label->font(); font.setBold( true ); label->setFont( font ); @@ -133,12 +133,12 @@ void SummaryWidget::updateView() labelText = TQString( "<b>%1:</b> %2<br>" "<b>%3:</b> %4<br>" "<b>%5:</b> %6" ) - .arg( i18n( "Last updated on" ) ) - .arg( (*it).date() ) - .arg( i18n( "Wind Speed" ) ) - .arg( (*it).windSpeed() ) - .arg( i18n( "Rel. Humidity" ) ) - .arg( (*it).relativeHumidity() ); + .tqarg( i18n( "Last updated on" ) ) + .tqarg( (*it).date() ) + .tqarg( i18n( "Wind Speed" ) ) + .tqarg( (*it).windSpeed() ) + .tqarg( i18n( "Rel. Humidity" ) ) + .tqarg( (*it).relativeHumidity() ); TQToolTip::add( label, labelText.tqreplace( " ", " " ) ); diff --git a/kontact/plugins/weather/weather_plugin.cpp b/kontact/plugins/weather/weather_plugin.cpp index d42a24f61..9d9f5dfde 100644 --- a/kontact/plugins/weather/weather_plugin.cpp +++ b/kontact/plugins/weather/weather_plugin.cpp @@ -32,7 +32,7 @@ K_EXPORT_COMPONENT_FACTORY( libkontact_weatherplugin, WeatherPluginFactory( "kontact_weatherplugin" ) ) WeatherPlugin::WeatherPlugin( Kontact::Core *core, const char *name, const TQStringList& ) - : Kontact::Plugin( core, core, name ), mAboutData( 0 ) + : Kontact::Plugin( core, TQT_TQOBJECT(core), name ), mAboutData( 0 ) { setInstance( WeatherPluginFactory::instance() ); } diff --git a/kontact/src/aboutdialog.cpp b/kontact/src/aboutdialog.cpp index e7fef654a..02e48e771 100644 --- a/kontact/src/aboutdialog.cpp +++ b/kontact/src/aboutdialog.cpp @@ -81,7 +81,7 @@ void AboutDialog::addAboutData( const TQString &title, const TQString &icon, text += "<p><b>" + about->programName() + "</b><br>"; - text += i18n( "Version %1</p>" ).arg( about->version() ); + text += i18n( "Version %1</p>" ).tqarg( about->version() ); if ( !about->shortDescription().isEmpty() ) { text += "<p>" + about->shortDescription() + "<br>" + @@ -163,13 +163,13 @@ void AboutDialog::addLicenseText( const KAboutData *about ) TQPixmap pixmap = KGlobal::iconLoader()->loadIcon( "signature", KIcon::Desktop, 48 ); - TQString title = i18n( "%1 License" ).arg( about->programName() ); + TQString title = i18n( "%1 License" ).tqarg( about->programName() ); TQFrame *topFrame = addPage( title, TQString(), pixmap ); TQBoxLayout *topLayout = new TQVBoxLayout( topFrame ); KTextBrowser *textBrowser = new KTextBrowser( topFrame ); - textBrowser->setText( TQString( "<pre>%1</pre>" ).arg( about->license() ) ); + textBrowser->setText( TQString( "<pre>%1</pre>" ).tqarg( about->license() ) ); topLayout->addWidget( textBrowser ); } diff --git a/kontact/src/iconsidepane.cpp b/kontact/src/iconsidepane.cpp index 7e4d027ed..fa19c1f7c 100644 --- a/kontact/src/iconsidepane.cpp +++ b/kontact/src/iconsidepane.cpp @@ -175,7 +175,7 @@ void EntryItem::paint( TQPainter *p ) if ( isCurrent() || isSelected() || mPaintActive ) brush = box->tqcolorGroup().brush( TQColorGroup::Highlight ); else - brush = box->tqcolorGroup().highlight().light( 115 ); + brush = TQBrush(box->tqcolorGroup().highlight().light( 115 )); p->fillRect( 1, 0, w - 2, h - 1, brush ); TQPen pen = p->pen(); TQPen oldPen = pen; @@ -223,7 +223,7 @@ void EntryItem::paint( TQPainter *p ) } if ( plugin()->disabled() ) { - p->setPen( box->palette().disabled().text( ) ); + p->setPen( box->tqpalette().disabled().text( ) ); } else if ( isCurrent() || isSelected() || mHasHover ) { p->setPen( box->tqcolorGroup().highlight().dark(115) ); p->drawText( x + ( TQApplication::reverseLayout() ? -1 : 1), @@ -265,7 +265,7 @@ Navigator::Navigator( IconSidePane *tqparent, const char *name ) setHScrollBarMode( TQScrollView::AlwaysOff ); setAcceptDrops( true ); - setFocusPolicy( NoFocus ); + setFocusPolicy( Qt::NoFocus ); connect( this, TQT_SIGNAL( selectionChanged( TQListBoxItem* ) ), TQT_SLOT( slotExecuted( TQListBoxItem* ) ) ); @@ -275,7 +275,7 @@ Navigator::Navigator( IconSidePane *tqparent, const char *name ) TQT_SLOT( slotMouseOn( TQListBoxItem * ) ) ); connect( this, TQT_SIGNAL( onViewport() ), TQT_SLOT( slotMouseOff() ) ); - mMapper = new TQSignalMapper( this ); + mMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); connect( mMapper, TQT_SIGNAL( mapped( int ) ), TQT_SLOT( shortCutSelected( int ) ) ); TQToolTip::remove( this ); diff --git a/kontact/src/kcmkontact.cpp b/kontact/src/kcmkontact.cpp index 2e7c61f83..fbdd4a045 100644 --- a/kontact/src/kcmkontact.cpp +++ b/kontact/src/kcmkontact.cpp @@ -115,7 +115,7 @@ void PluginSelection::readConfig() { const KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); int activeComponent = 0; mPluginCombo->clear(); diff --git a/kontact/src/main.cpp b/kontact/src/main.cpp index 760ea846e..8d2f3623f 100644 --- a/kontact/src/main.cpp +++ b/kontact/src/main.cpp @@ -77,7 +77,7 @@ static void listPlugins() KInstance instance( "kontact" ); // Can't use KontactApp since it's too late for adding cmdline options KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); for ( KService::List::Iterator it = offers.begin(); it != offers.end(); ++it ) { KService::Ptr service = (*it); // skip summary only plugins diff --git a/kontact/src/mainwindow.cpp b/kontact/src/mainwindow.cpp index 0e56f918a..df9631405 100644 --- a/kontact/src/mainwindow.cpp +++ b/kontact/src/mainwindow.cpp @@ -96,7 +96,7 @@ class SettingsDialogWrapper : public KSettings::Dialog void fixButtonLabel( TQWidget *widget ) { TQObject *object = widget->child( "KJanusWidget::buttonBelowList" ); - TQPushButton *button = static_cast<TQPushButton*>( object ); + TQPushButton *button = static_cast<TQPushButton*>( TQT_TQWIDGET(object) ); if ( button ) button->setText( i18n( "Select Components ..." ) ); } @@ -125,7 +125,7 @@ void MainWindow::initGUI() KTrader::OfferList offers = KTrader::self()->query( TQString::tqfromLatin1( "Kontact/Plugin" ), - TQString( "[X-KDE-KontactPluginVersion] == %1" ).arg( KONTACT_PLUGIN_VERSION ) ); + TQString( "[X-KDE-KontactPluginVersion] == %1" ).tqarg( KONTACT_PLUGIN_VERSION ) ); mPluginInfos = KPluginInfo::fromServices( offers, Prefs::self()->config(), "Plugins" ); KPluginInfo::List::Iterator it; @@ -133,10 +133,10 @@ void MainWindow::initGUI() (*it)->load(); KAction *action = new KAction( (*it)->name(), (*it)->icon(), KShortcut(), - this, TQT_SLOT(slotActionTriggered()), + TQT_TQOBJECT(this), TQT_SLOT(slotActionTriggered()), actionCollection(), (*it)->pluginName().latin1() ); action->setName( (*it)->pluginName().latin1() ); - action->setWhatsThis( i18n( "Switch to plugin %1" ).arg( (*it)->name() ) ); + action->setWhatsThis( i18n( "Switch to plugin %1" ).tqarg( (*it)->name() ) ); TQVariant hasPartProp = (*it)->property( "X-KDE-KontactPluginHasPart" ); if ( !hasPartProp.isValid() || hasPartProp.toBool() ) { @@ -144,8 +144,8 @@ void MainWindow::initGUI() } } - KStdAction::keyBindings( this, TQT_SLOT( configureShortcuts() ), actionCollection() ); - KStdAction::configureToolbars( this, TQT_SLOT( configureToolbars() ), actionCollection() ); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( configureShortcuts() ), actionCollection() ); + KStdAction::configureToolbars( TQT_TQOBJECT(this), TQT_SLOT( configureToolbars() ), actionCollection() ); setXMLFile( "kontactui.rc" ); setStandardToolBarMenuEnabled( true ); @@ -175,7 +175,7 @@ void MainWindow::initObject() mSidePane->updatePlugins(); } - KSettings::Dispatcher::self()->registerInstance( instance(), this, + KSettings::Dispatcher::self()->registerInstance( instance(), TQT_TQOBJECT(this), TQT_SLOT( updateConfig() ) ); loadSettings(); @@ -267,7 +267,7 @@ void MainWindow::initWidgets() initAboutScreen(); TQString loading = i18n( "<h2 style='text-align:center; margin-top: 0px; margin-bottom: 0px'>%1</h2>" ) - .arg( i18n("Loading Kontact...") ); + .tqarg( i18n("Loading Kontact...") ); paintAboutScreen( loading ); @@ -290,11 +290,11 @@ void MainWindow::paintAboutScreen( const TQString& msg ) { TQString location = locate( "data", "kontact/about/main.html" ); TQString content = KPIM::kFileToString( location ); - content = content.arg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); + content = content.tqarg( locate( "data", "libkdepim/about/kde_infopage.css" ) ); if ( kapp->reverseLayout() ) - content = content.arg( "@import \"%1\";" ).arg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); + content = content.tqarg( "@import \"%1\";" ).tqarg( locate( "data", "libkdepim/about/kde_infopage_rtl.css" ) ); else - content = content.arg( "" ); + content = content.tqarg( "" ); mIntroPart->begin( KURL( location ) ); @@ -302,8 +302,8 @@ void MainWindow::paintAboutScreen( const TQString& msg ) TQString catchPhrase( i18n( "Get Organized!" ) ); TQString quickDescription( i18n( "The KDE Personal Information Management Suite" ) ); - mIntroPart->write( content.arg( TQFont().pointSize() + 2 ).arg( appName ) - .arg( catchPhrase ).arg( quickDescription ).arg( msg ) ); + mIntroPart->write( content.tqarg( TQFont().pointSize() + 2 ).tqarg( appName ) + .tqarg( catchPhrase ).tqarg( quickDescription ).tqarg( msg ) ); mIntroPart->end(); } @@ -313,7 +313,7 @@ void MainWindow::initAboutScreen() mPartsStack->addWidget( introbox ); mPartsStack->raiseWidget( introbox ); mIntroPart = new KHTMLPart( introbox ); - mIntroPart->widget()->setFocusPolicy( WheelFocus ); + mIntroPart->widget()->setFocusPolicy( Qt::WheelFocus ); // Let's better be paranoid and disable plugins (it defaults to enabled): mIntroPart->setPluginsEnabled( false ); mIntroPart->setJScriptEnabled( false ); // just make this explicit @@ -333,9 +333,9 @@ void MainWindow::initAboutScreen() void MainWindow::setupActions() { - KStdAction::quit( this, TQT_SLOT( slotQuit() ), actionCollection() ); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( slotQuit() ), actionCollection() ); mNewActions = new KToolBarPopupAction( KGuiItem( i18n( "New" ), "" ), - KStdAccel::shortcut(KStdAccel::New), this, TQT_SLOT( slotNewClicked() ), + KStdAccel::shortcut(KStdAccel::New), TQT_TQOBJECT(this), TQT_SLOT( slotNewClicked() ), actionCollection(), "action_new" ); KConfig* const cfg = Prefs::self()->config(); @@ -344,18 +344,18 @@ void MainWindow::setupActions() if ( mSyncActionsEnabled ) { mSyncActions = new KToolBarPopupAction( KGuiItem( i18n( "Synchronize" ), "kitchensync" ), - KStdAccel::shortcut(KStdAccel::Reload), this, TQT_SLOT( slotSyncClicked() ), + KStdAccel::shortcut(KStdAccel::Reload), TQT_TQOBJECT(this), TQT_SLOT( slotSyncClicked() ), actionCollection(), "action_sync" ); } - new KAction( i18n( "Configure Kontact..." ), "configure", 0, this, TQT_SLOT( slotPreferences() ), + new KAction( i18n( "Configure Kontact..." ), "configure", 0, TQT_TQOBJECT(this), TQT_SLOT( slotPreferences() ), actionCollection(), "settings_configure_kontact" ); - new KAction( i18n( "Configure &Profiles..." ), 0, this, TQT_SLOT( slotConfigureProfiles() ), + new KAction( i18n( "Configure &Profiles..." ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotConfigureProfiles() ), actionCollection(), "settings_configure_kontact_profiles" ); - new KAction( i18n( "&Kontact Introduction" ), 0, this, TQT_SLOT( slotShowIntroduction() ), + new KAction( i18n( "&Kontact Introduction" ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowIntroduction() ), actionCollection(), "help_introduction" ); - new KAction( i18n( "&Tip of the Day" ), 0, this, TQT_SLOT( slotShowTip() ), + new KAction( i18n( "&Tip of the Day" ), 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowTip() ), actionCollection(), "help_tipofday" ); KWidgetAction* spacerAction = new KWidgetAction( new TQWidget( this ), "SpacerAction", "", 0, 0, actionCollection(), "navigator_spacer_item" ); @@ -543,7 +543,7 @@ void MainWindow::loadPlugins() kdDebug(5600) << "Loading Plugin: " << (*it)->name() << endl; Kontact::Plugin *plugin = KParts::ComponentFactory::createInstanceFromService<Kontact::Plugin>( - (*it)->service(), this ); + (*it)->service(), TQT_TQOBJECT(this) ); if ( !plugin ) continue; @@ -629,7 +629,7 @@ void MainWindow::updateShortcuts() ++it; if ( isPluginLoadedByAction( action ) ) { loadedActions.append( action ); - TQString shortcut = TQString( "CTRL+%1" ).arg( i ); + TQString shortcut = TQString( "CTRL+%1" ).tqarg( i ); action->setShortcut( KShortcut( shortcut ) ); i++; } else { @@ -763,7 +763,7 @@ void MainWindow::slotSyncClicked() KToolBar* Kontact::MainWindow::findToolBar(const char* name) { // like KMainWindow::toolBar, but which doesn't create the toolbar if not found - return static_cast<KToolBar *>(child(name, "KToolBar")); + return static_cast<KToolBar *>(TQT_TQWIDGET(child(name, "KToolBar"))); } void MainWindow::slotActionTriggered() @@ -794,7 +794,7 @@ void MainWindow::selectPlugin( Kontact::Plugin *plugin ) if ( !part ) { KApplication::restoreOverrideCursor(); KMessageBox::error( this, i18n( "Cannot load part for %1." ) - .arg( plugin->title() ) + .tqarg( plugin->title() ) + "\n" + lastErrorMessage() ); plugin->setDisabled( true ); mSidePane->updatePlugins(); @@ -848,7 +848,7 @@ void MainWindow::selectPlugin( Kontact::Plugin *plugin ) topDock()->moveDockWindow( navigatorToolBar, -1 ); } - setCaption( i18n( "Plugin dependent window title" ,"%1 - Kontact" ).arg( plugin->title() ) ); + setCaption( i18n( "Plugin dependent window title" ,"%1 - Kontact" ).tqarg( plugin->title() ) ); if ( newAction ) { mNewActions->setIcon( newAction->icon() ); @@ -1178,30 +1178,30 @@ TQString MainWindow::introductionString() "<td><a href=\"%1\">%1</a><br><span id=\"subtext\"><nobr>%1</td></tr>" "</table>" "<p style=\"margin-bottom: 0px\"> <a href=\"%1\">Skip this introduction</a></p>" ) - .arg( kapp->aboutData()->version() ) - .arg( i18n( "Kontact handles your e-mail, addressbook, calendar, to-do list and more." ) ) - .arg( "exec:/help?kontact" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( handbook_icon_path ) - .arg( "exec:/help?kontact" ) - .arg( i18n( "Read Manual" ) ) - .arg( i18n( "Learn more about Kontact and its components" ) ) - .arg( "http://kontact.org" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( html_icon_path ) - .arg( "http://kontact.org" ) - .arg( i18n( "Visit Kontact Website" ) ) - .arg( i18n( "Access online resources and tutorials" ) ) - .arg( "exec:/gwwizard" ) - .arg( iconSize ) - .arg( iconSize ) - .arg( wizard_icon_path ) - .arg( "exec:/gwwizard" ) - .arg( i18n( "Configure Kontact as Groupware Client" ) ) - .arg( i18n( "Prepare Kontact for use in corporate networks" ) ) - .arg( "exec:/switch" ); + .tqarg( kapp->aboutData()->version() ) + .tqarg( i18n( "Kontact handles your e-mail, addressbook, calendar, to-do list and more." ) ) + .tqarg( "exec:/help?kontact" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( handbook_icon_path ) + .tqarg( "exec:/help?kontact" ) + .tqarg( i18n( "Read Manual" ) ) + .tqarg( i18n( "Learn more about Kontact and its components" ) ) + .tqarg( "http://kontact.org" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( html_icon_path ) + .tqarg( "http://kontact.org" ) + .tqarg( i18n( "Visit Kontact Website" ) ) + .tqarg( i18n( "Access online resources and tutorials" ) ) + .tqarg( "exec:/gwwizard" ) + .tqarg( iconSize ) + .tqarg( iconSize ) + .tqarg( wizard_icon_path ) + .tqarg( "exec:/gwwizard" ) + .tqarg( i18n( "Configure Kontact as Groupware Client" ) ) + .tqarg( i18n( "Prepare Kontact for use in corporate networks" ) ) + .tqarg( "exec:/switch" ); return info; } diff --git a/kontact/src/profiledialog.cpp b/kontact/src/profiledialog.cpp index cb28d1194..bc3bff990 100644 --- a/kontact/src/profiledialog.cpp +++ b/kontact/src/profiledialog.cpp @@ -140,7 +140,7 @@ void Kontact::ProfileDialog::profileLoaded( const TQString& id ) const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( id ); if ( profile.isNull() ) return; - KMessageBox::information( this, i18n("The profile \"%1\" was successfully loaded. Some profile settings require a restart to get activated.").arg( profile.name() ), i18n("Profile Loaded") ); + KMessageBox::information( this, i18n("The profile \"%1\" was successfully loaded. Some profile settings require a restart to get activated.").tqarg( profile.name() ), i18n("Profile Loaded") ); } void Kontact::ProfileDialog::saveToSelectedProfile() @@ -148,7 +148,7 @@ void Kontact::ProfileDialog::saveToSelectedProfile() const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( selectedProfile() ); if ( profile.isNull() ) return; - if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("The profile \"%1\" will be overwritten with the current settings. Are you sure?").arg( profile.name() ), i18n("Save to Profile"), KStdGuiItem::overwrite(), KStdGuiItem::cancel() ) ) + if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("The profile \"%1\" will be overwritten with the current settings. Are you sure?").tqarg( profile.name() ), i18n("Save to Profile"), KStdGuiItem::overwrite(), KStdGuiItem::cancel() ) ) return; Kontact::ProfileManager::self()->saveToProfile( profile.id() ); } @@ -158,7 +158,7 @@ void Kontact::ProfileDialog::deleteSelectedProfile() const Kontact::Profile profile = Kontact::ProfileManager::self()->profileById( selectedProfile() ); if ( profile.isNull() ) return; - if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("Do you really want to delete the profile \"%1\"? All profile settings will be lost!").arg( profile.name() ), i18n("Delete Profile"), KStdGuiItem::del(), KStdGuiItem::cancel() ) ) + if ( KMessageBox::Yes != KMessageBox::warningYesNo( this, i18n("Do you really want to delete the profile \"%1\"? All profile settings will be lost!").tqarg( profile.name() ), i18n("Delete Profile"), KStdGuiItem::del(), KStdGuiItem::cancel() ) ) return; Kontact::ProfileManager::self()->removeProfile( profile ); } @@ -175,7 +175,7 @@ void Kontact::ProfileDialog::exportSelectedProfile() const Kontact::ProfileManager::ExportError error = Kontact::ProfileManager::self()->exportProfileToDirectory( id, path ); if ( error == Kontact::ProfileManager::SuccessfulExport ) { - KMessageBox::information( this, i18n("The profile \"%1\" was successfully exported.").arg( profile.name() ), i18n("Profile Exported") ); + KMessageBox::information( this, i18n("The profile \"%1\" was successfully exported.").tqarg( profile.name() ), i18n("Profile Exported") ); } else { diff --git a/kontact/src/profilemanager.cpp b/kontact/src/profilemanager.cpp index deed6f37a..005779414 100644 --- a/kontact/src/profilemanager.cpp +++ b/kontact/src/profilemanager.cpp @@ -152,7 +152,7 @@ void Kontact::ProfileManager::writeConfig() const Kontact::Profile Kontact::ProfileManager::readFromConfiguration( const TQString& configFile, bool isLocal ) { KConfig profileCfg( configFile, true /*read-only*/, false /*no KDE global*/ ); - const TQString configDir = configFile.left( configFile.findRev( TQDir::separator(), -1 ) ); + const TQString configDir = configFile.left( configFile.tqfindRev( TQDir::separator(), -1 ) ); profileCfg.setGroup( "Kontact Profile" ); const TQString id = profileCfg.readEntry( "Identifier" ); Kontact::Profile profile( id ); diff --git a/korganizer/actionmanager.cpp b/korganizer/actionmanager.cpp index 09b5c6f45..ad6c7e36f 100644 --- a/korganizer/actionmanager.cpp +++ b/korganizer/actionmanager.cpp @@ -127,7 +127,7 @@ void ActionManager::init() mWindowList = new KOWindowList; // Show tip of the day, when the first calendar is shown. if ( !mIsPart ) - TQTimer::singleShot( 0, this, TQT_SLOT( showTipOnStart() ) ); + TQTimer::singleShot( 0, TQT_TQOBJECT(this), TQT_SLOT( showTipOnStart() ) ); } // Note: We need this ActionManager to be fully constructed, and // tqparent() to have a valid reference to it before the following @@ -156,9 +156,9 @@ void ActionManager::init() connect( mCalendarView, TQT_SIGNAL( configChanged() ), TQT_SLOT( updateConfig() ) ); connect( mCalendarView, TQT_SIGNAL( incidenceSelected( Incidence *,const TQDate & ) ), - this, TQT_SLOT( processIncidenceSelection( Incidence *,const TQDate & ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( processIncidenceSelection( Incidence *,const TQDate & ) ) ); connect( mCalendarView, TQT_SIGNAL( exportHTML( HTMLExportSettings * ) ), - this, TQT_SLOT( exportHTML( HTMLExportSettings * ) ) ); + TQT_TQOBJECT(this), TQT_SLOT( exportHTML( HTMLExportSettings * ) ) ); processIncidenceSelection( 0, TQDate() ); @@ -227,58 +227,58 @@ void ActionManager::initActions() //~~~~~~~~~~~~~~~~~~~~~~~ LOADING / SAVING ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ if ( mIsPart ) { if ( mMainWindow->hasDocument() ) { - KStdAction::openNew( this, TQT_SLOT(file_new()), mACollection, "korganizer_openNew" ); - KStdAction::open( this, TQT_SLOT( file_open() ), mACollection, "korganizer_open" ); - mRecent = KStdAction::openRecent( this, TQT_SLOT( file_open( const KURL& ) ), + KStdAction::openNew( TQT_TQOBJECT(this), TQT_SLOT(file_new()), mACollection, "korganizer_openNew" ); + KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT( file_open() ), mACollection, "korganizer_open" ); + mRecent = KStdAction::openRecent( TQT_TQOBJECT(this), TQT_SLOT( file_open( const KURL& ) ), mACollection, "korganizer_openRecent" ); KStdAction::revert( this,TQT_SLOT( file_revert() ), mACollection, "korganizer_revert" ); - KStdAction::saveAs( this, TQT_SLOT( file_saveas() ), mACollection, + KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT( file_saveas() ), mACollection, "korganizer_saveAs" ); - KStdAction::save( this, TQT_SLOT( file_save() ), mACollection, "korganizer_save" ); + KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT( file_save() ), mACollection, "korganizer_save" ); } - KStdAction::print( mCalendarView, TQT_SLOT( print() ), mACollection, "korganizer_print" ); + KStdAction::print( TQT_TQOBJECT(mCalendarView), TQT_SLOT( print() ), mACollection, "korganizer_print" ); } else { - KStdAction::openNew( this, TQT_SLOT( file_new() ), mACollection ); - KStdAction::open( this, TQT_SLOT( file_open() ), mACollection ); - mRecent = KStdAction::openRecent( this, TQT_SLOT( file_open( const KURL& ) ), + KStdAction::openNew( TQT_TQOBJECT(this), TQT_SLOT( file_new() ), mACollection ); + KStdAction::open( TQT_TQOBJECT(this), TQT_SLOT( file_open() ), mACollection ); + mRecent = KStdAction::openRecent( TQT_TQOBJECT(this), TQT_SLOT( file_open( const KURL& ) ), mACollection ); if ( mMainWindow->hasDocument() ) { KStdAction::revert( this,TQT_SLOT( file_revert() ), mACollection ); - KStdAction::save( this, TQT_SLOT( file_save() ), mACollection ); - KStdAction::saveAs( this, TQT_SLOT( file_saveas() ), mACollection ); + KStdAction::save( TQT_TQOBJECT(this), TQT_SLOT( file_save() ), mACollection ); + KStdAction::saveAs( TQT_TQOBJECT(this), TQT_SLOT( file_saveas() ), mACollection ); } - KStdAction::print( mCalendarView, TQT_SLOT( print() ), mACollection ); + KStdAction::print( TQT_TQOBJECT(mCalendarView), TQT_SLOT( print() ), mACollection ); } //~~~~~~~~~~~~~~~~~~~~~~~~ IMPORT / EXPORT ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - new KAction( i18n("Import &Event/Calendar (ICS-/VCS-File)..."), 0, this, TQT_SLOT( file_merge() ), + new KAction( i18n("Import &Event/Calendar (ICS-/VCS-File)..."), 0, TQT_TQOBJECT(this), TQT_SLOT( file_merge() ), mACollection, "import_icalendar" ); - new KAction( i18n("&Import From UNIX Ical tool (.calendar-File)"), 0, this, TQT_SLOT( file_icalimport() ), + new KAction( i18n("&Import From UNIX Ical tool (.calendar-File)"), 0, TQT_TQOBJECT(this), TQT_SLOT( file_icalimport() ), mACollection, "import_ical" ); new KAction( i18n("Get &Hot New Stuff..."), 0, this, TQT_SLOT( downloadNewStuff() ), mACollection, "downloadnewstuff" ); new KAction( i18n("Export &Web Page..."), "webexport", 0, - mCalendarView, TQT_SLOT( exportWeb() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( exportWeb() ), mACollection, "export_web" ); new KAction( i18n("&iCalendar..."), 0, - mCalendarView, TQT_SLOT( exportICalendar() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( exportICalendar() ), mACollection, "export_icalendar" ); new KAction( i18n("&vCalendar..."), 0, - mCalendarView, TQT_SLOT( exportVCalendar() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( exportVCalendar() ), mACollection, "export_vcalendar" ); - new KAction( i18n("Upload &Hot New Stuff..."), 0, this, + new KAction( i18n("Upload &Hot New Stuff..."), 0, TQT_TQOBJECT(this), TQT_SLOT( uploadNewStuff() ), mACollection, "uploadnewstuff" ); - new KAction( i18n("Archive O&ld Entries..."), 0, this, TQT_SLOT( file_archive() ), + new KAction( i18n("Archive O&ld Entries..."), 0, TQT_TQOBJECT(this), TQT_SLOT( file_archive() ), mACollection, "file_archive" ); new KAction( i18n("delete completed to-dos", "Pur&ge Completed To-dos"), 0, - mCalendarView, TQT_SLOT( purgeCompleted() ), mACollection, + TQT_TQOBJECT(mCalendarView), TQT_SLOT( purgeCompleted() ), mACollection, "purge_completed" ); @@ -289,34 +289,34 @@ void ActionManager::initActions() KOrg::History *h = mCalendarView->history(); if ( mIsPart ) { // edit menu - mCutAction = KStdAction::cut( mCalendarView, TQT_SLOT( edit_cut() ), + mCutAction = KStdAction::cut( TQT_TQOBJECT(mCalendarView), TQT_SLOT( edit_cut() ), mACollection, "korganizer_cut" ); - mCopyAction = KStdAction::copy( mCalendarView, TQT_SLOT( edit_copy() ), + mCopyAction = KStdAction::copy( TQT_TQOBJECT(mCalendarView), TQT_SLOT( edit_copy() ), mACollection, "korganizer_copy" ); - pasteAction = KStdAction::paste( mCalendarView, TQT_SLOT( edit_paste() ), + pasteAction = KStdAction::paste( TQT_TQOBJECT(mCalendarView), TQT_SLOT( edit_paste() ), mACollection, "korganizer_paste" ); mUndoAction = KStdAction::undo( h, TQT_SLOT( undo() ), mACollection, "korganizer_undo" ); mRedoAction = KStdAction::redo( h, TQT_SLOT( redo() ), mACollection, "korganizer_redo" ); } else { - mCutAction = KStdAction::cut( mCalendarView,TQT_SLOT( edit_cut() ), + mCutAction = KStdAction::cut( TQT_TQOBJECT(mCalendarView),TQT_SLOT( edit_cut() ), mACollection ); - mCopyAction = KStdAction::copy( mCalendarView,TQT_SLOT( edit_copy() ), + mCopyAction = KStdAction::copy( TQT_TQOBJECT(mCalendarView),TQT_SLOT( edit_copy() ), mACollection ); - pasteAction = KStdAction::paste( mCalendarView,TQT_SLOT( edit_paste() ), + pasteAction = KStdAction::paste( TQT_TQOBJECT(mCalendarView),TQT_SLOT( edit_paste() ), mACollection ); - mUndoAction = KStdAction::undo( h, TQT_SLOT( undo() ), mACollection ); - mRedoAction = KStdAction::redo( h, TQT_SLOT( redo() ), mACollection ); + mUndoAction = KStdAction::undo( TQT_TQOBJECT(h), TQT_SLOT( undo() ), mACollection ); + mRedoAction = KStdAction::redo( TQT_TQOBJECT(h), TQT_SLOT( redo() ), mACollection ); } mDeleteAction = new KAction( i18n("&Delete"), "editdelete", 0, - mCalendarView, TQT_SLOT( appointment_delete() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( appointment_delete() ), mACollection, "edit_delete" ); if ( mIsPart ) { - KStdAction::tqfind( mCalendarView->dialogManager(), TQT_SLOT( showSearchDialog() ), + KStdAction::find( mCalendarView->dialogManager(), TQT_SLOT( showSearchDialog() ), mACollection, "korganizer_tqfind" ); } else { - KStdAction::tqfind( mCalendarView->dialogManager(), TQT_SLOT( showSearchDialog() ), + KStdAction::find( mCalendarView->dialogManager(), TQT_SLOT( showSearchDialog() ), mACollection ); } pasteAction->setEnabled( false ); @@ -381,7 +381,7 @@ void ActionManager::initActions() //~~~~~~~~~~~~~~~~~~~~~~~~~~~ FILTERS ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ new KAction( i18n("&Refresh"), 0, - mCalendarView, TQT_SLOT( updateView() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( updateView() ), mACollection, "update" ); // TODO: // new KAction( i18n("Hide &Completed To-dos"), 0, @@ -398,7 +398,7 @@ void ActionManager::initActions() connect( mCalendarView, TQT_SIGNAL( selectFilterSignal( int ) ), mFilterAction, TQT_SLOT( setCurrentItem( int ) ) ); connect( mCalendarView, TQT_SIGNAL( filterChanged() ), - this, TQT_SLOT( setTitle() ) ); + TQT_TQOBJECT(this), TQT_SLOT( setTitle() ) ); //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ZOOM ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -422,11 +422,11 @@ void ActionManager::initActions() //************************** Actions MENU ********************************* new KAction( i18n("Go to &Today"), "today", 0, - mCalendarView,TQT_SLOT( goToday() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( goToday() ), mACollection, "go_today" ); bool isRTL = TQApplication::reverseLayout(); action = new KAction( i18n("Go &Backward"), isRTL ? "forward" : "back", 0, - mCalendarView,TQT_SLOT( goPrevious() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( goPrevious() ), mACollection, "go_previous" ); // Changing the action text by setText makes the toolbar button disappear. @@ -435,10 +435,10 @@ void ActionManager::initActions() connect( mCalendarView, TQT_SIGNAL( changeNavStringPrev( const TQString & ) ), action, TQT_SLOT( setText( const TQString & ) ) ); connect( mCalendarView, TQT_SIGNAL( changeNavStringPrev( const TQString & ) ), - this, TQT_SLOT( dumpText( const TQString & ) ) );*/ + TQT_TQOBJECT(this), TQT_SLOT( dumpText( const TQString & ) ) );*/ action = new KAction( i18n("Go &Forward"), isRTL ? "back" : "forward", 0, - mCalendarView,TQT_SLOT( goNext() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( goNext() ), mACollection, "go_next" ); /* connect( mCalendarView,TQT_SIGNAL( changeNavStringNext( const TQString & ) ), @@ -449,35 +449,35 @@ void ActionManager::initActions() //************************** Actions MENU ********************************* new KAction( i18n("New E&vent..."), KOGlobals::self()->smallIcon( "newappointment" ), 0, - mCalendarView, TQT_SLOT(newEvent()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(newEvent()), mACollection, "new_event" ); new KAction( i18n("New &To-do..."), KOGlobals::self()->smallIcon( "newtodo" ), 0, - mCalendarView, TQT_SLOT(newTodo()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(newTodo()), mACollection, "new_todo" ); action = new KAction( i18n("New Su&b-to-do..."), 0, - mCalendarView,TQT_SLOT( newSubTodo() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( newSubTodo() ), mACollection, "new_subtodo" ); action->setEnabled( false ); connect( mCalendarView,TQT_SIGNAL( todoSelected( bool ) ), action,TQT_SLOT( setEnabled( bool ) ) ); new KAction( i18n("New &Journal..."), KOGlobals::self()->smallIcon( "newjournal" ), 0, - mCalendarView, TQT_SLOT(newJournal()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(newJournal()), mACollection, "new_journal" ); mShowIncidenceAction = new KAction( i18n("&Show"), 0, - mCalendarView,TQT_SLOT( showIncidence() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( showIncidence() ), mACollection, "show_incidence" ); mEditIncidenceAction = new KAction( i18n("&Edit..."), 0, - mCalendarView,TQT_SLOT( editIncidence() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( editIncidence() ), mACollection, "edit_incidence" ); mDeleteIncidenceAction = new KAction( i18n("&Delete"), Key_Delete, - mCalendarView,TQT_SLOT( deleteIncidence()), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( deleteIncidence()), mACollection, "delete_incidence" ); action = new KAction( i18n("&Make Sub-to-do Independent"), 0, - mCalendarView,TQT_SLOT( todo_unsub() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( todo_unsub() ), mACollection, "unsub_todo" ); action->setEnabled( false ); connect( mCalendarView,TQT_SIGNAL( subtodoSelected( bool ) ), @@ -496,27 +496,27 @@ void ActionManager::initActions() //************************** SCHEDULE MENU ******************************** mPublishEvent = new KAction( i18n("&Publish Item Information..."), "mail_send", 0, - mCalendarView, TQT_SLOT( schedule_publish() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( schedule_publish() ), mACollection, "schedule_publish" ); mPublishEvent->setEnabled( false ); mSendInvitation = new KAction( i18n( "Send &Invitation to Attendees" ), "mail_generic", 0, - mCalendarView, TQT_SLOT(schedule_request()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(schedule_request()), mACollection, "schedule_request" ); mSendInvitation->setEnabled( false ); connect( mCalendarView, TQT_SIGNAL(organizerEventsSelected(bool)), mSendInvitation, TQT_SLOT(setEnabled(bool)) ); mRequestUpdate = new KAction( i18n( "Re&quest Update" ), 0, - mCalendarView, TQT_SLOT(schedule_refresh()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(schedule_refresh()), mACollection, "schedule_refresh" ); mRequestUpdate->setEnabled( false ); connect( mCalendarView, TQT_SIGNAL(groupEventsSelected(bool)), mRequestUpdate, TQT_SLOT(setEnabled(bool)) ); mSendCancel = new KAction( i18n( "Send &Cancelation to Attendees" ), 0, - mCalendarView, TQT_SLOT(schedule_cancel()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(schedule_cancel()), mACollection, "schedule_cancel" ); mSendCancel->setEnabled( false ); connect( mCalendarView, TQT_SIGNAL(organizerEventsSelected(bool)), @@ -524,37 +524,37 @@ void ActionManager::initActions() mSendStatusUpdate = new KAction( i18n( "Send tqStatus &Update" ), "mail_reply", 0, - mCalendarView,TQT_SLOT(schedule_reply()), + TQT_TQOBJECT(mCalendarView),TQT_SLOT(schedule_reply()), mACollection, "schedule_reply" ); mSendStatusUpdate->setEnabled( false ); connect( mCalendarView, TQT_SIGNAL(groupEventsSelected(bool)), mSendStatusUpdate, TQT_SLOT(setEnabled(bool)) ); mRequestChange = new KAction( i18n( "counter proposal", "Request Chan&ge" ), 0, - mCalendarView, TQT_SLOT(schedule_counter()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(schedule_counter()), mACollection, "schedule_counter" ); mRequestChange->setEnabled( false ); connect( mCalendarView, TQT_SIGNAL(groupEventsSelected(bool)), mRequestChange, TQT_SLOT(setEnabled(bool)) ); mForwardEvent = new KAction( i18n("&Send as iCalendar..."), "mail_forward", 0, - mCalendarView, TQT_SLOT(schedule_forward()), + TQT_TQOBJECT(mCalendarView), TQT_SLOT(schedule_forward()), mACollection, "schedule_forward" ); mForwardEvent->setEnabled( false ); action = new KAction( i18n("&Mail Free Busy Information..."), 0, - mCalendarView, TQT_SLOT( mailFreeBusy() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( mailFreeBusy() ), mACollection, "mail_freebusy" ); action->setEnabled( true ); action = new KAction( i18n("&Upload Free Busy Information"), 0, - mCalendarView, TQT_SLOT( uploadFreeBusy() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( uploadFreeBusy() ), mACollection, "upload_freebusy" ); action->setEnabled( true ); if ( !mIsPart ) { action = new KAction( i18n("&Addressbook"),"contents",0, - mCalendarView,TQT_SLOT( openAddressbook() ), + TQT_TQOBJECT(mCalendarView),TQT_SLOT( openAddressbook() ), mACollection,"addressbook" ); } @@ -565,13 +565,13 @@ void ActionManager::initActions() //~~~~~~~~~~~~~~~~~~~~~~~~~~~~ SIDEBAR ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ mDateNavigatorShowAction = new KToggleAction( i18n("Show Date Navigator"), 0, - this, TQT_SLOT( toggleDateNavigator() ), + TQT_TQOBJECT(this), TQT_SLOT( toggleDateNavigator() ), mACollection, "show_datenavigator" ); mTodoViewShowAction = new KToggleAction ( i18n("Show To-do View"), 0, - this, TQT_SLOT( toggleTodoView() ), + TQT_TQOBJECT(this), TQT_SLOT( toggleTodoView() ), mACollection, "show_todoview" ); mEventViewerShowAction = new KToggleAction ( i18n("Show Item Viewer"), 0, - this, TQT_SLOT( toggleEventViewer() ), + TQT_TQOBJECT(this), TQT_SLOT( toggleEventViewer() ), mACollection, "show_eventviewer" ); KConfig *config = KOGlobals::self()->config(); config->setGroup( "Settings" ); @@ -590,10 +590,10 @@ void ActionManager::initActions() if ( !mMainWindow->hasDocument() ) { mResourceViewShowAction = new KToggleAction ( i18n("Show Resource View"), 0, - this, TQT_SLOT( toggleResourceView() ), + TQT_TQOBJECT(this), TQT_SLOT( toggleResourceView() ), mACollection, "show_resourceview" ); mResourceButtonsAction = new KToggleAction( i18n("Show &Resource Buttons"), 0, - this, TQT_SLOT( toggleResourceButtons() ), + TQT_TQOBJECT(this), TQT_SLOT( toggleResourceButtons() ), mACollection, "show_resourcebuttons" ); mResourceViewShowAction->setChecked( config->readBoolEntry( "ResourceViewVisible", true ) ); @@ -608,35 +608,35 @@ void ActionManager::initActions() //~~~~~~~~~~~~~~~~~~~~~~~~~~~~ SIDEBAR ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ new KAction( i18n("Configure &Date && Time..."), 0, - this, TQT_SLOT( configureDateTime() ), + TQT_TQOBJECT(this), TQT_SLOT( configureDateTime() ), mACollection, "conf_datetime" ); // TODO: Add an item to show the resource management dlg // new KAction( i18n("Manage &Resources..."), 0, -// this, TQT_SLOT( manageResources() ), +// TQT_TQOBJECT(this), TQT_SLOT( manageResources() ), // mACollection, "conf_resources" ); new KAction( i18n("Manage View &Filters..."), "configure", 0, - mCalendarView, TQT_SLOT( editFilters() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( editFilters() ), mACollection, "edit_filters" ); new KAction( i18n("Manage C&ategories..."), 0, - mCalendarView->dialogManager(), TQT_SLOT( showCategoryEditDialog() ), + TQT_TQOBJECT(mCalendarView->dialogManager()), TQT_SLOT( showCategoryEditDialog() ), mACollection, "edit_categories" ); if ( mIsPart ) { new KAction( i18n("&Configure Calendar..."), "configure", 0, - mCalendarView, TQT_SLOT( edit_options() ), + TQT_TQOBJECT(mCalendarView), TQT_SLOT( edit_options() ), mACollection, "korganizer_configure" ); - KStdAction::keyBindings( this, TQT_SLOT( keyBindings() ), + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( keyBindings() ), mACollection, "korganizer_configure_shortcuts" ); } else { - KStdAction::preferences( mCalendarView, TQT_SLOT( edit_options() ), + KStdAction::preferences( TQT_TQOBJECT(mCalendarView), TQT_SLOT( edit_options() ), mACollection ); - KStdAction::keyBindings( this, TQT_SLOT( keyBindings() ), mACollection ); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( keyBindings() ), mACollection ); } //**************************** HELP MENU ********************************** - KStdAction::tipOfDay( this, TQT_SLOT( showTip() ), mACollection, + KStdAction::tipOfDay( TQT_TQOBJECT(this), TQT_SLOT( showTip() ), mACollection, "help_tipofday" ); // new KAction( i18n("Show Intro Page"), 0, // mCalendarView,TQT_SLOT( showIntro() ), @@ -872,7 +872,7 @@ bool ActionManager::openURL( const KURL &url,bool merge ) mFile = url.path(); if ( !KStandardDirs::exists( mFile ) ) { mMainWindow->showStatusMessage( i18n("New calendar '%1'.") - .arg( url.prettyURL() ) ); + .tqarg( url.prettyURL() ) ); mCalendarView->setModified(); } else { bool success = mCalendarView->openCalendar( mFile, merge ); @@ -906,7 +906,7 @@ bool ActionManager::openURL( const KURL &url,bool merge ) return success; } else { TQString msg; - msg = i18n("Cannot download calendar from '%1'.").arg( url.prettyURL() ); + msg = i18n("Cannot download calendar from '%1'.").tqarg( url.prettyURL() ); KMessageBox::error( dialogParent(), msg ); return false; } @@ -945,7 +945,7 @@ bool ActionManager::addResource( const KURL &mUrl ) resource->setResourceName( name ); manager->add( resource ); mMainWindow->showStatusMessage( i18n( "Added calendar resource for URL '%1'." ) - .arg( name ) ); + .tqarg( name ) ); // we have to call resourceAdded manually, because for in-process changes // the dcop signals are not connected, so the resource's signals would not // be connected otherwise @@ -953,7 +953,7 @@ bool ActionManager::addResource( const KURL &mUrl ) mCalendarResources->resourceAdded( resource ); } else { TQString msg = i18n("Unable to create calendar resource '%1'.") - .arg( name ); + .tqarg( name ); KMessageBox::error( dialogParent(), msg ); } return true; @@ -964,10 +964,10 @@ void ActionManager::showStatusMessageOpen( const KURL &url, bool merge ) { if ( merge ) { mMainWindow->showStatusMessage( i18n("Merged calendar '%1'.") - .arg( url.prettyURL() ) ); + .tqarg( url.prettyURL() ) ); } else { mMainWindow->showStatusMessage( i18n("Opened calendar '%1'.") - .arg( url.prettyURL() ) ); + .tqarg( url.prettyURL() ) ); } } @@ -1018,7 +1018,7 @@ bool ActionManager::saveURL() if ( !mURL.isLocalFile() ) { if ( !KIO::NetAccess::upload( mFile, mURL, view() ) ) { TQString msg = i18n("Cannot upload calendar to '%1'") - .arg( mURL.prettyURL() ); + .tqarg( mURL.prettyURL() ); KMessageBox::error( dialogParent() ,msg ); return false; } @@ -1030,7 +1030,7 @@ bool ActionManager::saveURL() mAutoSaveTimer->start( 1000*60*KOPrefs::instance()->mAutoSaveInterval ); } - mMainWindow->showStatusMessage( i18n("Saved calendar '%1'.").arg( mURL.prettyURL() ) ); + mMainWindow->showStatusMessage( i18n("Saved calendar '%1'.").tqarg( mURL.prettyURL() ) ); return true; } @@ -1061,7 +1061,7 @@ void ActionManager::exportHTML( HTMLExportSettings *settings ) return; kdDebug()<<" settings->outputFile() :"<<settings->outputFile()<<endl; if ( TQFileInfo( settings->outputFile() ).exists() ) { - if(KMessageBox::questionYesNo( dialogParent(), i18n("Do you want to overwrite file \"%1\"").arg( settings->outputFile()) ) == KMessageBox::No) + if(KMessageBox::questionYesNo( dialogParent(), i18n("Do you want to overwrite file \"%1\"").tqarg( settings->outputFile()) ) == KMessageBox::No) return; } settings->setEMail( KOPrefs::instance()->email() ); @@ -1136,7 +1136,7 @@ bool ActionManager::saveAsURL( const KURL &url ) setTitle(); if ( mRecent ) mRecent->addURL( mURL ); } else { - KMessageBox::sorry( dialogParent(), i18n("Unable to save calendar to the file %1.").arg( mFile ), i18n("Error") ); + KMessageBox::sorry( dialogParent(), i18n("Unable to save calendar to the file %1.").tqarg( mFile ), i18n("Error") ); kdDebug(5850) << "ActionManager::saveAsURL() failed" << endl; mURL = URLOrig; mFile = fileOrig; @@ -1558,7 +1558,7 @@ TQPair<ResourceCalendar *, TQString> ActionManager::viewSubResourceCalendar() cV = mCalendarView->viewManager()->multiAgendaView()->selectedAgendaView(); } if ( cV ) { - p = qMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); + p = tqMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); } return p; } @@ -1892,7 +1892,7 @@ void ActionManager::updateUndoAction( const TQString &text ) } else { mUndoAction->setEnabled( true ); if ( text.isEmpty() ) mUndoAction->setText( i18n("Undo") ); - else mUndoAction->setText( i18n("Undo (%1)").arg( text ) ); + else mUndoAction->setText( i18n("Undo (%1)").tqarg( text ) ); } } @@ -1904,7 +1904,7 @@ void ActionManager::updateRedoAction( const TQString &text ) } else { mRedoAction->setEnabled( true ); if ( text.isEmpty() ) mRedoAction->setText( i18n("Redo") ); - else mRedoAction->setText( i18n( "Redo (%1)" ).arg( text ) ); + else mRedoAction->setText( i18n( "Redo (%1)" ).tqarg( text ) ); } } @@ -1983,7 +1983,7 @@ bool ActionManager::saveResourceCalendar() int result = KMessageBox::warningContinueCancel( view(), i18n( "Saving of '%1' failed. Check that the resource is " "properly configured.\nIgnore problem and continue without " - "saving or cancel save?" ).arg( (*it)->resourceName() ), + "saving or cancel save?" ).tqarg( (*it)->resourceName() ), i18n("Save Error"), KStdGuiItem::dontSave() ); if ( result == KMessageBox::Cancel ) return false; } @@ -2006,7 +2006,7 @@ void ActionManager::importCalendar( const KURL &url ) { if ( !url.isValid() ) { KMessageBox::error( dialogParent(), - i18n("URL '%1' is invalid.").arg( url.prettyURL() ) ); + i18n("URL '%1' is invalid.").tqarg( url.prettyURL() ) ); return; } diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 84199bfe4..bdf334014 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp @@ -131,18 +131,18 @@ CalendarView::CalendarView( TQWidget *tqparent, const char *name ) mExtensions.setAutoDelete( true ); - mDateNavigator = new DateNavigator( this ); - mDateChecker = new DateChecker( this ); + mDateNavigator = new DateNavigator( TQT_TQOBJECT(this) ); + mDateChecker = new DateChecker( TQT_TQOBJECT(this) ); TQBoxLayout *topLayout = new TQVBoxLayout( this ); #ifndef KORG_NOSPLITTER // create the main tqlayout frames. - mPanner = new TQSplitter( TQSplitter::Horizontal, this, + mPanner = new TQSplitter( Qt::Horizontal, this, "CalendarView::Panner" ); topLayout->addWidget( mPanner ); - mLeftSplitter = new TQSplitter( TQSplitter::Vertical, mPanner, + mLeftSplitter = new TQSplitter( Qt::Vertical, mPanner, "CalendarView::LeftFrame" ); // mPanner->setResizeMode( mLeftSplitter, TQSplitter::Stretch ); @@ -277,7 +277,7 @@ CalendarView::CalendarView( TQWidget *tqparent, const char *name ) KOGlobals::self()-> setHolidays( new KHolidays( KOPrefs::instance()->mHolidays ) ); - connect( TQApplication::clipboard(), TQT_SIGNAL( dataChanged() ), + connect( TQApplication::tqclipboard(), TQT_SIGNAL( dataChanged() ), TQT_SLOT( checkClipboard() ) ); connect( mTodoList, TQT_SIGNAL( incidenceSelected( Incidence *,const TQDate & ) ), @@ -311,7 +311,7 @@ void CalendarView::setCalendar( Calendar *cal ) connect( mHistory, TQT_SIGNAL( redone() ), TQT_SLOT( updateView() ) ); if ( mChanger ) delete mChanger; - setIncidenceChanger( new IncidenceChanger( mCalendar, this ) ); + setIncidenceChanger( new IncidenceChanger( mCalendar, TQT_TQOBJECT(this) ) ); mCalendar->registerObserver( this ); @@ -357,7 +357,7 @@ TQPair<ResourceCalendar *, TQString> CalendarView::viewSubResourceCalendar() cV = mViewManager->multiAgendaView()->selectedAgendaView(); } if ( cV ) { - p = qMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); + p = tqMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); } return p; } @@ -487,7 +487,7 @@ bool CalendarView::openCalendar(const TQString& filename, bool merge) // have become partially populated. Clear it out. if ( !merge ) mCalendar->close(); - KMessageBox::error(this,i18n("Could not load calendar '%1'.").arg(filename)); + KMessageBox::error(this,i18n("Could not load calendar '%1'.").tqarg(filename)); return false; } @@ -631,7 +631,7 @@ void CalendarView::readFilterSettings( KConfig *config ) } config->setGroup( "General" ); - int pos = filterList.findIndex( currentFilter ); + int pos = filterList.tqfindIndex( currentFilter ); mCurrentFilter = 0; if ( pos>=0 ) { mCurrentFilter = mFilters.at( pos ); @@ -776,8 +776,8 @@ void CalendarView::incidenceChanged( Incidence *oldIncidence, if ( todo->isCompleted() || modification == KOGlobals::COMPLETION_MODIFIED_WITH_RECURRENCE ) { TQString timeStr = KGlobal::locale()->formatTime( TQTime::currentTime() ); - TQString description = i18n( "To-do completed: %1 (%2)" ).arg( - newIncidence->summary() ).arg( timeStr ); + TQString description = i18n( "To-do completed: %1 (%2)" ).tqarg( + newIncidence->summary() ).tqarg( timeStr ); Journal::List journals = calendar()->journals( TQDate::tqcurrentDate() ); Journal *journal; @@ -787,7 +787,7 @@ void CalendarView::incidenceChanged( Incidence *oldIncidence, journal->setDtStart( TQDateTime::tqcurrentDateTime() ); TQString dateStr = KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ); - journal->setSummary( i18n("Journal of %1").arg( dateStr ) ); + journal->setSummary( i18n("Journal of %1").tqarg( dateStr ) ); journal->setDescription( description ); //TODO: recorded to-dos should save into the standard resource always @@ -844,7 +844,7 @@ void CalendarView::checkForFilteredChange( Incidence *incidence ) // user so that he isn't surprised if his new event doesn't show up KMessageBox::information( this, i18n("The item \"%1\" is filtered by " "your current filter rules, so it will be hidden and not " - "appear in the view.").arg( incidence->summary() ), + "appear in the view.").tqarg( incidence->summary() ), i18n("Filter Applied"), "ChangedIncidenceFiltered" ); } } @@ -901,7 +901,7 @@ void CalendarView::updateUnmanagedViews() int CalendarView::msgItemDelete( Incidence *incidence ) { return KMessageBox::warningContinueCancel(this, - i18n("The item \"%1\" will be permanently deleted.").arg( incidence->summary() ), + i18n("The item \"%1\" will be permanently deleted.").tqarg( incidence->summary() ), i18n("KOrganizer Confirmation"), KGuiItem(i18n("&Delete"),"editdelete")); } @@ -925,7 +925,7 @@ void CalendarView::edit_cut() "Do you want to cut just this item and " "make all its sub-to-dos independent, or " "cut the to-do with all its sub-to-dos?" - ).arg( incidence->summary() ), + ).tqarg( incidence->summary() ), i18n("KOrganizer Confirmation"), i18n("Cut Only This"), i18n("Cut All")); @@ -962,7 +962,7 @@ void CalendarView::edit_copy() i18n("The item \"%1\" has sub-to-dos. " "Do you want to copy just this item or " "copy the to-do with all its sub-to-dos?" - ).arg( incidence->summary() ), + ).tqarg( incidence->summary() ), i18n("KOrganizer Confirmation"), i18n("Copy Only This"), i18n("Copy All")); @@ -1585,7 +1585,7 @@ void CalendarView::schedule_publish(Incidence *incidence) KMessageBox::information( this, i18n("The item information was successfully sent."), i18n("Publishing"), "IncidencePublishSuccess" ); } else { - KMessageBox::error( this, i18n("Unable to publish the item '%1'").arg( incidence->summary() ) ); + KMessageBox::error( this, i18n("Unable to publish the item '%1'").tqarg( incidence->summary() ) ); } } delete publishdlg; @@ -1661,7 +1661,7 @@ void CalendarView::schedule_forward( Incidence *incidence ) } else { KMessageBox::error( this, - i18n( "Unable to forward the item '%1'" ).arg( incidence->summary() ), + i18n( "Unable to forward the item '%1'" ).tqarg( incidence->summary() ), i18n( "Forwarding Error" ) ); } } @@ -1727,16 +1727,16 @@ void CalendarView::schedule(Scheduler::Method method, Incidence *incidence) if ( scheduler.performTransaction( incidence, method ) ) { KMessageBox::information( this, i18n("The groupware message for item '%1'" "was successfully sent.\nMethod: %2") - .arg( incidence->summary() ) - .arg( Scheduler::methodName( method ) ), + .tqarg( incidence->summary() ) + .tqarg( Scheduler::methodName( method ) ), i18n("Sending Free/Busy"), "FreeBusyPublishSuccess" ); } else { KMessageBox::error( this, i18n("Groupware message sending failed. " "%2 is request/reply/add/cancel/counter/etc.", "Unable to send the item '%1'.\nMethod: %2") - .arg( incidence->summary() ) - .arg( Scheduler::methodName( method ) ) ); + .tqarg( incidence->summary() ) + .tqarg( Scheduler::methodName( method ) ) ); } } @@ -1817,7 +1817,7 @@ void CalendarView::exportICalendar() if ( TQFile( filename ).exists() ) { if ( KMessageBox::No == KMessageBox::warningYesNo( this, - i18n( "Do you want to overwrite %1?").arg(filename) ) ) { + i18n( "Do you want to overwrite %1?").tqarg(filename) ) ) { return; } } @@ -1845,7 +1845,7 @@ void CalendarView::exportVCalendar() if ( TQFile( filename ).exists() ) { if ( KMessageBox::No == KMessageBox::warningYesNo( this, - i18n( "Do you want to overwrite %1?").arg(filename ) ) ) { + i18n( "Do you want to overwrite %1?").tqarg(filename ) ) ) { return; } } @@ -1934,7 +1934,7 @@ void CalendarView::processIncidenceSelection( Incidence *incidence, const TQDate void CalendarView::checkClipboard() { #ifndef KORG_NODND - if (ICalDrag::canDecode(TQApplication::clipboard()->data())) { + if (ICalDrag::canDecode(TQApplication::tqclipboard()->data())) { kdDebug(5850) << "CalendarView::checkClipboard() true" << endl; emit pasteEnabled(true); } else { @@ -2334,7 +2334,7 @@ void CalendarView::deleteTodoIncidence ( Todo *todo, bool force ) "Do you want to delete just this item and " "make all its sub-to-dos independent, or " "delete the to-do with all its sub-to-dos?" - ).arg( todo->summary() ), + ).tqarg( todo->summary() ), i18n("KOrganizer Confirmation"), i18n("Delete Only This"), i18n("Delete All")); @@ -2367,7 +2367,7 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force) KMessageBox::information( this, i18n("The item \"%1\" is marked read-only " "and cannot be deleted; it probably belongs to " "a read-only calendar resource.") - .arg(incidence->summary()), + .tqarg(incidence->summary()), i18n("Removing not possible"), "deleteReadOnlyIncidence" ); } @@ -2389,7 +2389,7 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force) if ( incidence->doesRecur() ) { TQDate itemDate = mViewManager->currentSelectionDate(); - kdDebug(5850) << "Recurrence-Date: " << itemDate.toString() << endl; + kdDebug(5850) << "Recurrence-Date: " << TQString(itemDate.toString()) << endl; int km = KMessageBox::Ok; if ( !force ) { if ( !itemDate.isValid() ) { @@ -2397,15 +2397,15 @@ void CalendarView::deleteIncidence(Incidence *incidence, bool force) km = KMessageBox::warningContinueCancel(this, i18n("The calendar item \"%1\" recurs over multiple dates; " "are you sure you want to delete it " - "and all its recurrences?").arg( incidence->summary() ), + "and all its recurrences?").tqarg( incidence->summary() ), i18n("KOrganizer Confirmation"), i18n("Delete All") ); } else { km = KOMessageBox::fourBtnMsgBox( this, TQMessageBox::Warning, i18n("The calendar item \"%1\" recurs over multiple dates. " "Do you want to delete only the current one on %2, only all " "future recurrences, or all its recurrences?" ) - .arg( incidence->summary() ) - .arg( KGlobal::locale()->formatDate(itemDate)), + .tqarg( incidence->summary() ) + .tqarg( KGlobal::locale()->formatDate(itemDate)), i18n("KOrganizer Confirmation"), i18n("Delete C&urrent"), i18n("Delete &Future"), i18n("Delete &All")); @@ -2577,7 +2577,7 @@ void CalendarView::addIncidenceOn( Incidence *incadd, const TQDate &dt ) { if ( !incadd || !mChanger ) { KMessageBox::sorry(this, i18n("Unable to copy the item to %1.") - .arg( dt.toString() ), i18n("Copying Failed") ); + .tqarg( dt.toString() ), i18n("Copying Failed") ); return; } Incidence *incidence = mCalendar->incidence( incadd->uid() ); @@ -2621,7 +2621,7 @@ void CalendarView::moveIncidenceTo( Incidence *incmove, const TQDate &dt ) { if ( !incmove || !mChanger ) { KMessageBox::sorry( this, i18n("Unable to move the item to %1.") - .arg( dt.toString() ), i18n("Moving Failed") ); + .tqarg( dt.toString() ), i18n("Moving Failed") ); return; } Incidence *incidence = mCalendar->incidence( incmove->uid() ); diff --git a/korganizer/datenavigatorcontainer.cpp b/korganizer/datenavigatorcontainer.cpp index 462920c5f..055111acf 100644 --- a/korganizer/datenavigatorcontainer.cpp +++ b/korganizer/datenavigatorcontainer.cpp @@ -332,7 +332,7 @@ TQPair<TQDate,TQDate> DateNavigatorContainer::dateLimits( int offset ) TQPair<TQDate,TQDate> firstMonthBoundary = KODayMatrix::matrixLimits( firstMonth ); TQPair<TQDate,TQDate> lastMonthBoundary = KODayMatrix::matrixLimits( lastMonth ); - return qMakePair( firstMonthBoundary.first, lastMonthBoundary.second ); + return tqMakePair( firstMonthBoundary.first, lastMonthBoundary.second ); } #include "datenavigatorcontainer.moc" diff --git a/korganizer/eventarchiver.cpp b/korganizer/eventarchiver.cpp index 300b975e2..0f7dfc33c 100644 --- a/korganizer/eventarchiver.cpp +++ b/korganizer/eventarchiver.cpp @@ -99,7 +99,7 @@ void EventArchiver::run( Calendar* calendar, const TQDate& limitDate, TQWidget* KMessageBox::information( widget, i18n( "Unable to archive to-do \"%1\" because at least one of its " - "sub-to-dos does not meet the archival requirements." ).arg( (*it)->summary() ), + "sub-to-dos does not meet the archival requirements." ).tqarg( (*it)->summary() ), i18n( "Archive To-do" ), "UncompletedChildrenArchiveTodos" ); } else if ( todoComplete ) { @@ -118,7 +118,7 @@ void EventArchiver::run( Calendar* calendar, const TQDate& limitDate, TQWidget* KMessageBox::information( widget, i18n( "There are no incidences available to archive before the specified cut-off date %1. " - "Archiving will not be performed." ).arg( KGlobal::locale()->formatDate( limitDate ) ), + "Archiving will not be performed." ).tqarg( KGlobal::locale()->formatDate( limitDate ) ), "ArchiverNoIncidences" ); } return; @@ -147,7 +147,7 @@ void EventArchiver::deleteIncidences( Calendar* calendar, const TQDate& limitDat int result = KMessageBox::warningContinueCancelList( widget, i18n("Delete all items before %1 without saving?\n" "The following items will be deleted:") - .arg(KGlobal::locale()->formatDate(limitDate)), incidenceStrs, + .tqarg(KGlobal::locale()->formatDate(limitDate)), incidenceStrs, i18n("Delete Old Items"),KStdGuiItem::del()); if (result != KMessageBox::Continue) return; @@ -216,7 +216,7 @@ void EventArchiver::archiveIncidences( Calendar* calendar, const TQDate& /*limit // Save archive calendar if ( !archiveStore.save() ) { - KMessageBox::error(widget,i18n("Cannot write archive file %1.").arg( archiveStore.fileName() )); + KMessageBox::error(widget,i18n("Cannot write archive file %1.").tqarg( archiveStore.fileName() )); return; } diff --git a/korganizer/filtereditdialog.cpp b/korganizer/filtereditdialog.cpp index cf6bf2ffe..02e6053e1 100644 --- a/korganizer/filtereditdialog.cpp +++ b/korganizer/filtereditdialog.cpp @@ -186,7 +186,7 @@ void FilterEdit::filterSelected(CalFilter *filter) } void FilterEdit::bNewPressed() { - CalFilter *newFilter = new CalFilter( i18n("New Filter %1").arg(mFilters->count()) ); + CalFilter *newFilter = new CalFilter( i18n("New Filter %1").tqarg(mFilters->count()) ); mFilters->append( newFilter ); updateFilterList(); mRulesList->setSelected(mRulesList->count()-1, true); diff --git a/korganizer/freebusymanager.cpp b/korganizer/freebusymanager.cpp index 546952177..5309050ec 100644 --- a/korganizer/freebusymanager.cpp +++ b/korganizer/freebusymanager.cpp @@ -245,7 +245,7 @@ void FreeBusyManager::publishFreeBusy() if ( !targetURL.isValid() ) { KMessageBox::sorry( 0, i18n( "<qt>The target URL '%1' provided is invalid." - "</qt>" ).arg( targetURL.prettyURL() ), i18n("Invalid URL") ); + "</qt>" ).tqarg( targetURL.prettyURL() ), i18n("Invalid URL") ); mBrokenUrl = true; return; } @@ -353,8 +353,8 @@ void FreeBusyManager::slotUploadFreeBusyResult(KIO::Job *_job) "URL '%1'. There might be a problem with the access rights, or " "you specified an incorrect URL. The system said: <em>%2</em>." "<br>Please check the URL or contact your system administrator." - "</qt>" ).arg( job->destURL().prettyURL() ) - .arg( job->errorString() ) ); + "</qt>" ).tqarg( job->destURL().prettyURL() ) + .tqarg( job->errorString() ) ); // Delete temp file KURL src = job->srcURL(); Q_ASSERT( src.isLocalFile() ); @@ -557,7 +557,7 @@ KURL FreeBusyManager::freeBusyUrl( const TQString &email ) // This means that if the trailing slash is not entered, we can treat this as a custom, non-Kolab URL! // In that case, just pass it on through with substitution for %u and %d // TODO: May want an explicit configuration option in kogroupwareprefspage.ui for this - if ((fullpathURL.url().endsWith("/", true) == false) || (fullpathURL.url().tqcontains("%25u", true)) || (fullpathURL.url().tqcontains("%25d", true))) { + if ((fullpathURL.url().tqendsWith("/", true) == false) || (fullpathURL.url().tqcontains("%25u", true)) || (fullpathURL.url().tqcontains("%25d", true))) { // A generic URL, substitute %u and %d fullpathURL = fullpathURL.url().tqreplace("%25u", emailName, true); fullpathURL = fullpathURL.url().tqreplace("%25d", emailHost, true); diff --git a/korganizer/freebusyurldialog.cpp b/korganizer/freebusyurldialog.cpp index b98335812..15dece944 100644 --- a/korganizer/freebusyurldialog.cpp +++ b/korganizer/freebusyurldialog.cpp @@ -66,7 +66,7 @@ FreeBusyUrlWidget::FreeBusyUrlWidget( KCal::Attendee *attendee, TQWidget *tqpare TQLabel *label = new TQLabel( i18n("Location of Free/Busy information for %1 <%2>:") - .arg( mAttendee->name() ).arg( mAttendee->email() ), this ); + .tqarg( mAttendee->name() ).tqarg( mAttendee->email() ), this ); topLayout->addWidget( label ); mUrlEdit = new KLineEdit( this ); diff --git a/korganizer/history.cpp b/korganizer/history.cpp index c01aed912..002f84a6b 100644 --- a/korganizer/history.cpp +++ b/korganizer/history.cpp @@ -182,7 +182,7 @@ void History::EntryDelete::redo() TQString History::EntryDelete::text() { - return i18n("Delete %1").arg(mIncidence->type()); + return i18n("Delete %1").tqarg(mIncidence->type().data()); } @@ -211,7 +211,7 @@ void History::EntryAdd::redo() TQString History::EntryAdd::text() { - return i18n("Add %1").arg(mIncidence->type()); + return i18n("Add %1").tqarg(mIncidence->type().data()); } @@ -248,7 +248,7 @@ void History::EntryEdit::redo() TQString History::EntryEdit::text() { - return i18n("Edit %1").arg(mNewIncidence->type()); + return i18n("Edit %1").tqarg(mNewIncidence->type().data()); } History::MultiEntry::MultiEntry( Calendar *calendar, const TQString &text ) diff --git a/korganizer/importdialog.cpp b/korganizer/importdialog.cpp index 9d5735101..aa93e34f8 100644 --- a/korganizer/importdialog.cpp +++ b/korganizer/importdialog.cpp @@ -46,11 +46,11 @@ ImportDialog::ImportDialog( const KURL &url, TQWidget *tqparent, bool isPart ) TQVBoxLayout *topLayout = new TQVBoxLayout( topFrame, 0, spacingHint() ); TQString txt = i18n("Import calendar/event at '%1' into KOrganizer.") - .arg( mUrl.prettyURL() ); + .tqarg( mUrl.prettyURL() ); topLayout->addWidget( new TQLabel( txt, topFrame ) ); - TQButtonGroup *radioBox = new TQButtonGroup( 1, Horizontal, topFrame ); + TQButtonGroup *radioBox = new TQButtonGroup( 1, Qt::Horizontal, topFrame ); radioBox->setFlat( true ); topLayout->addWidget( radioBox ); diff --git a/korganizer/interfaces/korganizer/part.h b/korganizer/interfaces/korganizer/part.h index a7093e28f..38763c3af 100644 --- a/korganizer/interfaces/korganizer/part.h +++ b/korganizer/interfaces/korganizer/part.h @@ -39,7 +39,7 @@ class Part : public KParts::Part typedef TQPtrList<Part> List; Part( MainWindow *tqparent, const char *name ) - : KParts::Part( tqparent?(tqparent->tqtopLevelWidget()):0, name ), mMainWindow( tqparent ) {} + : KParts::Part( tqparent?(TQT_TQOBJECT(tqparent->tqtopLevelWidget())):0, name ), mMainWindow( tqparent ) {} virtual ~Part() {} diff --git a/korganizer/journalentry.cpp b/korganizer/journalentry.cpp index 5af3a320e..ee83b1f52 100644 --- a/korganizer/journalentry.cpp +++ b/korganizer/journalentry.cpp @@ -86,7 +86,7 @@ JournalDateEntry::~JournalDateEntry() void JournalDateEntry::setDate(const TQDate &date) { TQString dtstring = TQString( "<qt><center><b><i>%1</i></b> " ) - .arg( KGlobal::locale()->formatDate(date) ); + .tqarg( KGlobal::locale()->formatDate(date) ); dtstring += " <font size=\"-1\"><a href=\"#\">" + i18n("[Add Journal Entry]") + @@ -259,8 +259,8 @@ void JournalEntry::deleteItem() { /* KMessageBox::ButtonCode *code = KMessageBox::warningContinueCancel(this, i18n("The journal \"%1\" on %2 will be permanently deleted.") - .arg( mJournal->summary() ) - .arg( mJournal->dtStartStr() ), + .tqarg( mJournal->summary() ) + .tqarg( mJournal->dtStartStr() ), i18n("KOrganizer Confirmation"), KStdGuiItem::del() ); if ( code == KMessageBox::Yes ) {*/ if ( mJournal ) diff --git a/korganizer/kdatenavigator.cpp b/korganizer/kdatenavigator.cpp index abdd8acdf..9ee1f20c0 100644 --- a/korganizer/kdatenavigator.cpp +++ b/korganizer/kdatenavigator.cpp @@ -188,7 +188,7 @@ void KDateNavigator::updateDates() if ( weeknumstart != weeknumend ) { weeknum = i18n("start/end week number of line in date picker", "%1/%2") - .arg( weeknumstart ).arg( weeknumend ); + .tqarg( weeknumstart ).tqarg( weeknumend ); } else { weeknum.setNum( weeknumstart ); } @@ -288,7 +288,7 @@ bool KDateNavigator::eventFilter( TQObject *o, TQEvent *e ) if ( e->type() == TQEvent::MouseButtonPress ) { int i; for( i = 0; i < 6; ++i ) { - if ( o == mWeeknos[ i ] ) { + if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(mWeeknos[ i ]) ) { TQDate weekstart = mDayMatrix->getDate( i * 7 ); emit weekClicked( weekstart ); break; diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp index bf25165b3..7172e01ff 100644 --- a/korganizer/koagenda.cpp +++ b/korganizer/koagenda.cpp @@ -255,7 +255,7 @@ void KOAgenda::init() // Grab key strokes for keyboard navigation of agenda. Seems to have no // effect. Has to be fixed. - setFocusPolicy( WheelFocus ); + setFocusPolicy( Qt::WheelFocus ); connect( &mScrollUpTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( scrollUp() ) ); connect( &mScrollDownTimer, TQT_SIGNAL( timeout() ), TQT_SLOT( scrollDown() ) ); @@ -274,7 +274,7 @@ void KOAgenda::init() mClickedItem = 0; mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mActionType = NOP; mItemMoved = false; @@ -291,7 +291,7 @@ void KOAgenda::init() viewport()->update(); viewport()->setBackgroundMode( NoBackground ); - viewport()->setFocusPolicy( WheelFocus ); + viewport()->setFocusPolicy( Qt::WheelFocus ); setMinimumSize( 30, int( mGridSpacingY + 1 ) ); // setMaximumHeight(mGridSpacingY * mRows + 5); @@ -384,19 +384,19 @@ bool KOAgenda::eventFilter ( TQObject *object, TQEvent *event ) case TQEvent::MouseButtonDblClick: case TQEvent::MouseButtonRelease: case TQEvent::MouseMove: - return eventFilter_mouse( object, static_cast<TQMouseEvent *>( event ) ); + return eventFilter_mouse( object, TQT_TQMOUSEEVENT( event ) ); #ifndef TQT_NO_WHEELEVENT case TQEvent::Wheel: - return eventFilter_wheel( object, static_cast<TQWheelEvent *>( event ) ); + return eventFilter_wheel( object, TQT_TQWHEELEVENT( event ) ); #endif case TQEvent::KeyPress: case TQEvent::KeyRelease: - return eventFilter_key( object, static_cast<TQKeyEvent *>( event ) ); + return eventFilter_key( object, TQT_TQKEYEVENT( event ) ); case ( TQEvent::Leave ): if ( !mActionItem ) setCursor( arrowCursor ); - if ( object == viewport() ) + if ( TQT_BASE_OBJECT(object) == TQT_BASE_OBJECT(viewport()) ) emit leaveAgenda(); return true; @@ -422,8 +422,8 @@ bool KOAgenda::eventFilter_drag( TQObject *object, TQDropEvent *de ) { #ifndef KORG_NODND TQPoint viewportPos; - if ( object != viewport() && object != this ) { - viewportPos = static_cast<TQWidget *>( object )->mapToParent( de->pos() ); + if ( TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport()) && TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(this) ) { + viewportPos = TQT_TQWIDGET( object )->mapToParent( de->pos() ); } else { viewportPos = de->pos(); } @@ -462,7 +462,7 @@ bool KOAgenda::eventFilter_drag( TQObject *object, TQDropEvent *de ) // FIXME: This is a bad hack, as the viewportToContents seems to be off by // 2000 (which is the left upper corner of the viewport). It works correctly // for agendaItems. - if ( object == this ) { + if ( TQT_BASE_OBJECT(object) == TQT_BASE_OBJECT(this) ) { pos = viewportPos + TQPoint( contentsX(), contentsY() ); } else { pos = viewportToContents( viewportPos ); @@ -526,10 +526,10 @@ bool KOAgenda::eventFilter_key( TQObject *, TQKeyEvent *ke ) case Key_Alt: break; default: - mTypeAheadEvents.append( new TQKeyEvent( ke->type(), ke->key(), + mTypeAheadEvents.append( TQT_TQEVENT( new TQKeyEvent( ke->type(), ke->key(), ke->ascii(), ke->state(), ke->text(), ke->isAutoRepeat(), - ke->count() ) ); + ke->count() ) ) ); if ( !mTypeAhead ) { mTypeAhead = true; emitNewEventForSelection(); @@ -565,7 +565,7 @@ bool KOAgenda::eventFilter_wheel ( TQObject *object, TQWheelEvent *e ) TQPoint viewportPos; bool accepted=false; if ( ( e->state() & ShiftButton) == ShiftButton ) { - if ( object != viewport() ) { + if ( TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport()) ) { viewportPos = ( (TQWidget *) object )->mapToParent( e->pos() ); } else { viewportPos = e->pos(); @@ -574,19 +574,19 @@ bool KOAgenda::eventFilter_wheel ( TQObject *object, TQWheelEvent *e ) // e->type()<<" delta: "<< e->delta()<< endl; emit zoomView( -e->delta() , contentsToGrid( viewportToContents( viewportPos ) ), - TQt::Horizontal ); + Qt::Horizontal ); accepted=true; } if ( ( e->state() & ControlButton ) == ControlButton ){ - if ( object != viewport() ) { + if ( TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport()) ) { viewportPos = ( (TQWidget *)object )->mapToParent( e->pos() ); } else { viewportPos = e->pos(); } emit zoomView( -e->delta() , contentsToGrid( viewportToContents( viewportPos ) ), - TQt::Vertical ); + Qt::Vertical ); emit mousePosSignal(gridToContents(contentsToGrid(viewportToContents( viewportPos )))); accepted=true; } @@ -597,7 +597,7 @@ bool KOAgenda::eventFilter_wheel ( TQObject *object, TQWheelEvent *e ) bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) { TQPoint viewportPos; - if (object != viewport()) { + if (TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport())) { viewportPos = ((TQWidget *)object)->mapToParent(me->pos()); } else { viewportPos = me->pos(); @@ -606,8 +606,8 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) switch (me->type()) { case TQEvent::MouseButtonPress: // kdDebug(5850) << "koagenda: filtered button press" << endl; - if (object != viewport()) { - if (me->button() == RightButton) { + if (TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport())) { + if (me->button() == Qt::RightButton) { mClickedItem = dynamic_cast<KOAgendaItem *>(object); if (mClickedItem) { selectItem(mClickedItem); @@ -615,7 +615,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) mClickedItem->incidence(), mClickedItem->itemDate() ); } else { - return TQScrollView::eventFilter( object, me ); // pass through for use by multiagenda + return TQScrollView::eventFilter( TQT_TQOBJECT(object), TQT_TQEVENT(me) ); // pass through for use by multiagenda } } else { KOAgendaItem* item = dynamic_cast<KOAgendaItem *>(object); @@ -623,7 +623,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) Incidence *incidence = item->incidence(); if ( incidence->isReadOnly() ) { mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); } else { mActionItem = item; mResPair = CalHelper::incSubResourceCalendar( mCalendar, incidence ); @@ -635,11 +635,11 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) // null. selectItem( item ); } else { - return TQScrollView::eventFilter( object, me ); // pass through for use by multiagenda + return TQScrollView::eventFilter( TQT_TQOBJECT(object), TQT_TQEVENT(me) ); // pass through for use by multiagenda } } } else { - if ( me->button() == RightButton ) { + if ( me->button() == Qt::RightButton ) { // if mouse pointer is not in selection, select the cell below the cursor TQPoint gpos = contentsToGrid( viewportToContents( viewportPos ) ); if ( !ptInSelection( gpos ) ) { @@ -657,12 +657,12 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) if ( !ptInSelection( gpos ) ) { selectItem(0); mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); setCursor(arrowCursor); startSelectAction(viewportPos); } } - return TQScrollView::eventFilter( object, me ); // pass through for use by multiagenda + return TQScrollView::eventFilter( TQT_TQOBJECT(object), TQT_TQEVENT(me) ); // pass through for use by multiagenda } break; @@ -683,7 +683,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) // avoid an offset of a few pixels. Don't ask me why... TQPoint indicatorPos = gridToContents(contentsToGrid( viewportToContents( viewportPos ))); - if (object != viewport()) { + if (TQT_BASE_OBJECT(object) != TQT_BASE_OBJECT(viewport())) { KOAgendaItem *moveItem = dynamic_cast<KOAgendaItem *>(object); if (moveItem && !moveItem->incidence()->isReadOnly() ) { if (!mActionItem) @@ -722,7 +722,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me) break; } case TQEvent::MouseButtonDblClick: - if (object == viewport()) { + if (TQT_BASE_OBJECT(object) == TQT_BASE_OBJECT(viewport())) { selectItem(0); TQPair<ResourceCalendar *, TQString>p = mCalendarView->viewSubResourceCalendar(); emit newEventSignal( p.first, p.second ); @@ -918,7 +918,7 @@ void KOAgenda::performItemAction(const TQPoint& viewportPos) emit startDragSignal( mActionItem->incidence() ); setCursor( arrowCursor ); mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mActionType = NOP; mItemMoved = false; return; @@ -952,7 +952,7 @@ void KOAgenda::performItemAction(const TQPoint& viewportPos) placeSubCells( mActionItem ); setCursor( arrowCursor ); mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mActionType = NOP; mItemMoved = false; return; @@ -1192,7 +1192,7 @@ void KOAgenda::endItemAction() } mActionItem = 0; - mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); + mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mItemMoved = false; if ( multiModify ) { @@ -1557,7 +1557,7 @@ TQMemArray<int> KOAgenda::minContentsY() int ymin = item->cellYTop(); int index = item->cellXLeft(); if ( index>=0 && index<(int)(mSelectedDates.count()) ) { - if ( ymin < minArray[index] && mItemsToDelete.findRef( item ) == -1 ) + if ( ymin < minArray[index] && mItemsToDelete.tqfindRef( item ) == -1 ) minArray[index] = ymin; } } @@ -1574,7 +1574,7 @@ TQMemArray<int> KOAgenda::maxContentsY() int ymax = item->cellYBottom(); int index = item->cellXLeft(); if ( index>=0 && index<(int)(mSelectedDates.count()) ) { - if ( ymax > maxArray[index] && mItemsToDelete.findRef( item ) == -1 ) + if ( ymax > maxArray[index] && mItemsToDelete.tqfindRef( item ) == -1 ) maxArray[index] = ymax; } } @@ -1708,7 +1708,7 @@ void KOAgenda::insertMultiItem( Event *event, const TQDate &qd, int XBegin, int cellYBottom = rows() - 1; } - newtext = TQString("(%1/%2): ").arg( count ).arg( width ); + newtext = TQString("(%1/%2): ").tqarg( count ).tqarg( width ); newtext.append( event->summary() ); current = insertItem( event, qd, cellX, cellYTop, cellYBottom, count, width ); @@ -1769,7 +1769,7 @@ void KOAgenda::showAgendaItem( KOAgendaItem *agendaItem ) agendaItem->hide(); addChild( agendaItem ); - if ( !mItems.containsRef( agendaItem ) ) { + if ( !mItems.tqcontainsRef( agendaItem ) ) { mItems.append( agendaItem ); } placeSubCells( agendaItem ); diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp index a7ba07d0c..1304ef5d2 100644 --- a/korganizer/koagendaitem.cpp +++ b/korganizer/koagendaitem.cpp @@ -562,7 +562,7 @@ void KOAgendaItem::addAttendee( const TQString &newAttendee ) KPIM::getNameAndMail( newAttendee, name, email ); if ( !( name.isEmpty() && email.isEmpty() ) ) { mIncidence->addAttendee(new Attendee(name,email)); - KMessageBox::information( this, i18n("Attendee \"%1\" added to the calendar item \"%2\"").arg(KPIM::normalizedAddress(name, email, TQString())).arg(text()), i18n("Attendee added"), "AttendeeDroppedAdded" ); + KMessageBox::information( this, i18n("Attendee \"%1\" added to the calendar item \"%2\"").tqarg(KPIM::normalizedAddress(name, email, TQString())).tqarg(text()), i18n("Attendee added"), "AttendeeDroppedAdded" ); } } @@ -838,8 +838,8 @@ void KOAgendaItem::paintEvent( TQPaintEvent *ev ) if ( !isMultiItem() ) { shortH = KGlobal::locale()->formatTime(mIncidence->dtStart().time()); if (mIncidence->type() != "Todo") - longH = i18n("%1 - %2").arg(shortH) - .arg(KGlobal::locale()->formatTime(mIncidence->dtEnd().time())); + longH = i18n("%1 - %2").tqarg(shortH) + .tqarg(KGlobal::locale()->formatTime(mIncidence->dtEnd().time())); else longH = shortH; } else if ( !mMultiItemInfo->mFirstMultiItem ) { @@ -847,7 +847,7 @@ void KOAgendaItem::paintEvent( TQPaintEvent *ev ) longH = shortH; } else { shortH = KGlobal::locale()->formatTime(mIncidence->dtEnd().time()); - longH = i18n("- %1").arg(shortH); + longH = i18n("- %1").tqarg(shortH); } KWordWrap *ww = KWordWrap::formatText( fm, @@ -937,8 +937,8 @@ void KOAgendaItem::paintEvent( TQPaintEvent *ev ) (mIncidence->dtStart() != mIncidence->dtEnd()) ) { // multi days shortH = longH = i18n("%1 - %2") - .arg(KGlobal::locale()->formatDate(mIncidence->dtStart().date())) - .arg(KGlobal::locale()->formatDate(mIncidence->dtEnd().date())); + .tqarg(KGlobal::locale()->formatDate(mIncidence->dtStart().date())) + .tqarg(KGlobal::locale()->formatDate(mIncidence->dtEnd().date())); // paint headline p.fillRect( 0, 0, width(), (ft/2) + margin + hlHeight, diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index 49a21acf7..526f1f619 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp @@ -284,7 +284,7 @@ KOAgendaView::KOAgendaView( Calendar *cal, // Create agenda splitter #ifndef KORG_NOSPLITTER - mSplitterAgenda = new TQSplitter(Vertical,this); + mSplitterAgenda = new TQSplitter(Qt::Vertical,this); topLayout->addWidget(mSplitterAgenda); #if KDE_IS_VERSION( 3, 1, 93 ) @@ -569,7 +569,7 @@ void KOAgendaView::zoomView( const int delta, const TQPoint &pos, //Zoom to the selected incidence, on the other way // zoom to the date on screen after the first mousewheel move. - if ( orient == TQt::Horizontal ) { + if ( orient == Qt::Horizontal ) { TQDate date=mAgenda->selectedIncidenceDate(); if ( date.isValid() ) zoomDate=date; @@ -584,7 +584,7 @@ void KOAgendaView::zoomView( const int delta, const TQPoint &pos, else zoomInHorizontally( zoomDate ); } else { - // Vertical zoom + // Qt::Vertical zoom TQPoint posConstentsOld = mAgenda->gridToContents(pos); if ( delta > 0 ) { zoomOutVertically(); @@ -627,8 +627,8 @@ void KOAgendaView::createDayLabels( bool force ) int dW = calsys->dayOfWeek(date); TQString veryLongStr = KGlobal::locale()->formatDate( date ); TQString longstr = i18n( "short_weekday date (e.g. Mon 13)","%1 %2" ) - .arg( calsys->weekDayName( dW, true ) ) - .arg( calsys->day(date) ); + .tqarg( calsys->weekDayName( dW, true ) ) + .tqarg( calsys->day(date) ); TQString shortstr = TQString::number(calsys->day(date)); KOAlternateLabel *dayLabel = new KOAlternateLabel(shortstr, diff --git a/korganizer/koagendaview.h b/korganizer/koagendaview.h index 25c1dd159..b55e92b9c 100644 --- a/korganizer/koagendaview.h +++ b/korganizer/koagendaview.h @@ -196,7 +196,8 @@ class KOAgendaView : public KOrg::AgendaView, public KCal::Calendar::Observer void zoomOutVertically( ); void zoomView( const int delta, const TQPoint &pos, - const Qt::Orientation orient=TQt::Horizontal ); + + const Qt::Orientation orient=Qt::Horizontal ); void clearTimeSpanSelection(); diff --git a/korganizer/koapp.cpp b/korganizer/koapp.cpp index ffa9e4c08..6b15af08d 100644 --- a/korganizer/koapp.cpp +++ b/korganizer/koapp.cpp @@ -57,7 +57,7 @@ using namespace std; KOrganizerApp::KOrganizerApp() : KUniqueApplication() { TQString prodId = "-//K Desktop Environment//NONSGML KOrganizer %1//EN"; - CalFormat::setApplication( "KOrganizer", prodId.arg( korgVersion ) ); + CalFormat::setApplication( "KOrganizer", prodId.tqarg( korgVersion ) ); } KOrganizerApp::~KOrganizerApp() diff --git a/korganizer/koattendeeeditor.cpp b/korganizer/koattendeeeditor.cpp index d24a8812b..51f838576 100644 --- a/korganizer/koattendeeeditor.cpp +++ b/korganizer/koattendeeeditor.cpp @@ -309,7 +309,7 @@ void KOAttendeeEditor::readEvent(KCal::Incidence * incidence) delete mOrganizerCombo; mOrganizerCombo = 0; } - mOrganizerLabel->setText( i18n( "Organizer: %1" ).arg( incidence->organizer().fullName() ) ); + mOrganizerLabel->setText( i18n( "Organizer: %1" ).tqarg( incidence->organizer().fullName() ) ); } Attendee::List al = incidence->attendees(); @@ -477,9 +477,9 @@ void KOAttendeeEditor::fillAttendeeInput( KCal::Attendee *a ) if ( a->status() == Attendee::Delegated ) { if ( !a->delegate().isEmpty() ) - mDelegateLabel->setText( i18n( "Delegated to %1" ).arg( a->delegate() ) ); + mDelegateLabel->setText( i18n( "Delegated to %1" ).tqarg( a->delegate() ) ); else if ( !a->delegator().isEmpty() ) - mDelegateLabel->setText( i18n( "Delegated from %1" ).arg( a->delegator() ) ); + mDelegateLabel->setText( i18n( "Delegated from %1" ).tqarg( a->delegator() ) ); else mDelegateLabel->setText( i18n( "Not delegated" ) ); } @@ -537,7 +537,7 @@ void KOAttendeeEditor::declineForMe() bool KOAttendeeEditor::eventFilter(TQObject *watched, TQEvent *ev) { - if ( watched && watched == mNameEdit && ev->type() == TQEvent::FocusIn && + if ( watched && TQT_BASE_OBJECT(watched) == TQT_BASE_OBJECT(mNameEdit) && ev->type() == TQEvent::FocusIn && currentAttendee() == 0 ) { addNewAttendee(); } diff --git a/korganizer/kocore.cpp b/korganizer/kocore.cpp index 6313dd2fa..51e436283 100644 --- a/korganizer/kocore.cpp +++ b/korganizer/kocore.cpp @@ -67,7 +67,7 @@ KTrader::OfferList KOCore::availablePlugins( const TQString &type, int version ) TQString constraint; if ( version >= 0 ) { constraint = TQString("[X-KDE-PluginInterfaceVersion] == %1") - .arg( TQString::number( version ) ); + .tqarg( TQString::number( version ) ); } return KTrader::self()->query( type, constraint ); diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp index cb172e9ce..89e869164 100644 --- a/korganizer/kodaymatrix.cpp +++ b/korganizer/kodaymatrix.cpp @@ -562,9 +562,9 @@ void KODayMatrix::paintEvent( TQPaintEvent * ) int selw, selh; bool isRTL = KOGlobals::self()->reverseLayout(); - TQColorGroup cg = palette().active(); + TQColorGroup cg = tqpalette().active(); - p.begin( &pm, this ); + p.tqbegin( &pm, this ); pm.fill( cg.base() ); // draw topleft frame @@ -725,5 +725,5 @@ TQPair<TQDate,TQDate> KODayMatrix::matrixLimits( const TQDate &month ) d = d.addDays( -7 ); // Start on the second line } - return qMakePair( d, d.addDays( NUMDAYS-1 ) ); + return tqMakePair( d, d.addDays( NUMDAYS-1 ) ); } diff --git a/korganizer/kodialogmanager.cpp b/korganizer/kodialogmanager.cpp index ff26d005a..cae637613 100644 --- a/korganizer/kodialogmanager.cpp +++ b/korganizer/kodialogmanager.cpp @@ -111,8 +111,8 @@ KODialogManager::~KODialogManager() void KODialogManager::errorSaveIncidence( TQWidget *tqparent, Incidence *incidence ) { KMessageBox::sorry( tqparent, i18n("Unable to save %1 \"%2\".") - .arg( i18n( incidence->type() ) ) - .arg( incidence->summary() ) ); + .tqarg( i18n( incidence->type() ) ) + .tqarg( incidence->summary() ) ); } void KODialogManager::showOptionsDialog() diff --git a/korganizer/koeditoralarms.cpp b/korganizer/koeditoralarms.cpp index d45495783..8c4168516 100644 --- a/korganizer/koeditoralarms.cpp +++ b/korganizer/koeditoralarms.cpp @@ -167,13 +167,13 @@ void AlarmListViewItem::construct() if ( offset % (24*60) == 0 && offset>0 ) { // divides evenly into days? useoffset = offset / (24*60); - offsetstr = offsetstr.arg( i18n("1 day", "%n days", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 day", "%n days", useoffset ) ); } else if (offset % 60 == 0 && offset>0 ) { // divides evenly into hours? useoffset = offset / 60; - offsetstr = offsetstr.arg( i18n("1 hour", "%n hours", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 hour", "%n hours", useoffset ) ); } else { useoffset = offset; - offsetstr = offsetstr.arg( i18n("1 minute", "%n minutes", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 minute", "%n minutes", useoffset ) ); } setText( ColAlarmOffset, offsetstr ); diff --git a/korganizer/koeditorattachments.cpp b/korganizer/koeditorattachments.cpp index ddade8815..0672ba092 100644 --- a/korganizer/koeditorattachments.cpp +++ b/korganizer/koeditorattachments.cpp @@ -189,7 +189,7 @@ AttachmentEditDialog::AttachmentEditDialog( AttachmentListItem *item, i18n( "Type any string you desire here for the name of the attachment" ) ); grid->addMultiCellWidget( mLabelEdit, 0, 0, 1, 2 ); - KSeparator *sep = new KSeparator( TQt::Horizontal, topFrame ); + KSeparator *sep = new KSeparator( Qt::Horizontal, topFrame ); grid->addMultiCellWidget( sep, 1, 1, 0, 2 ); TQLabel *label = new TQLabel( i18n( "Type:" ), topFrame ); @@ -490,29 +490,29 @@ KOEditorAttachments::KOEditorAttachments( int spacing, TQWidget *tqparent, mContextMenu = new KPopupMenu( this ); - KActionCollection* ac = new KActionCollection( this, this ); + KActionCollection* ac = new KActionCollection( TQT_TQWIDGET(this), TQT_TQOBJECT(this) ); - mOpenAction = new KAction( i18n("Open"), 0, this, TQT_SLOT(slotShow()), ac ); + mOpenAction = new KAction( i18n("Open"), 0, TQT_TQOBJECT(this), TQT_SLOT(slotShow()), ac ); mOpenAction->plug( mContextMenu ); - mSaveAsAction = new KAction( i18n( "Save As..." ), 0, this, TQT_SLOT(slotSaveAs()), ac ); + mSaveAsAction = new KAction( i18n( "Save As..." ), 0, TQT_TQOBJECT(this), TQT_SLOT(slotSaveAs()), ac ); mSaveAsAction->plug( mContextMenu ); mContextMenu->insertSeparator(); - mCopyAction = KStdAction::copy(this, TQT_SLOT(slotCopy()), ac ); + mCopyAction = KStdAction::copy(TQT_TQOBJECT(this), TQT_SLOT(slotCopy()), ac ); mCopyAction->plug( mContextMenu ); - mCutAction = KStdAction::cut(this, TQT_SLOT(slotCut()), ac ); + mCutAction = KStdAction::cut(TQT_TQOBJECT(this), TQT_SLOT(slotCut()), ac ); mCutAction->plug( mContextMenu ); - KAction *action = KStdAction::paste(this, TQT_SLOT(slotPaste()), ac ); + KAction *action = KStdAction::paste(TQT_TQOBJECT(this), TQT_SLOT(slotPaste()), ac ); action->plug( mContextMenu ); mContextMenu->insertSeparator(); - mDeleteAction = new KAction( i18n( "&Remove" ), 0, this, TQT_SLOT(slotRemove()), ac ); + mDeleteAction = new KAction( i18n( "&Remove" ), 0, TQT_TQOBJECT(this), TQT_SLOT(slotRemove()), ac ); mDeleteAction->plug( mContextMenu ); mDeleteAction->setShortcut( Key_Delete ); mContextMenu->insertSeparator(); - mEditAction = new KAction( i18n( "&Properties..." ), 0, this, TQT_SLOT(slotEdit()), ac ); + mEditAction = new KAction( i18n( "&Properties..." ), 0, TQT_TQOBJECT(this), TQT_SLOT(slotEdit()), ac ); mEditAction->plug( mContextMenu ); selectionChanged(); @@ -606,7 +606,7 @@ void KOEditorAttachments::handlePasteOrDrop( TQMimeSource* source ) for ( KURL::List::ConstIterator it = urls.constBegin(); it != urls.constEnd(); ++it ) { TQString label = (*jt++); - if ( mAttachments->findItem( label ) ) { + if ( mAttachments->tqfindItem( label ) ) { label += '~' + randomString( 3 ); } addUriAttachment( (*it).url(), TQString(), label, true ); @@ -619,7 +619,7 @@ void KOEditorAttachments::handlePasteOrDrop( TQMimeSource* source ) if ( label.isEmpty() ) { label = (*it).prettyURL(); } - if ( mAttachments->findItem( label ) ) { + if ( mAttachments->tqfindItem( label ) ) { label += '~' + randomString( 3 ); } addUriAttachment( (*it).url(), TQString(), label, true ); @@ -718,7 +718,7 @@ void KOEditorAttachments::slotRemove() if ( KMessageBox::questionYesNo( this, - i18n( "<qt>Do you really want to remove these attachments?<p>%1</qt>" ).arg( labelsStr ), + i18n( "<qt>Do you really want to remove these attachments?<p>%1</qt>" ).tqarg( labelsStr ), i18n( "Remove Attachment?" ), KStdGuiItem::yes(), KStdGuiItem::no(), "calendarRemoveAttachments" ) != KMessageBox::Yes ) { @@ -874,7 +874,7 @@ void KOEditorAttachments::writeIncidence( KCal::Incidence *i ) void KOEditorAttachments::slotCopy() { - TQApplication::clipboard()->setData( mAttachments->mimeData(), TQClipboard::Clipboard ); + TQApplication::tqclipboard()->setData( mAttachments->mimeData(), TQClipboard::Clipboard ); } void KOEditorAttachments::slotCut() @@ -885,7 +885,7 @@ void KOEditorAttachments::slotCut() void KOEditorAttachments::slotPaste() { - handlePasteOrDrop( TQApplication::clipboard()->data() ); + handlePasteOrDrop( TQApplication::tqclipboard()->data() ); } void KOEditorAttachments::selectionChanged() diff --git a/korganizer/koeditordetails.cpp b/korganizer/koeditordetails.cpp index 9d31182c0..40b0168dc 100644 --- a/korganizer/koeditordetails.cpp +++ b/korganizer/koeditordetails.cpp @@ -329,7 +329,7 @@ void KOEditorDetails::writeEvent(Incidence *event) bool skip = false; if ( attendee->email().endsWith( "example.net" ) ) { if ( KMessageBox::warningYesNo( this, i18n("%1 does not look like a valid email address. " - "Are you sure you want to invite this participant?").arg( attendee->email() ), + "Are you sure you want to invite this participant?").tqarg( attendee->email() ), i18n("Invalid email address") ) != KMessageBox::Yes ) { skip = true; } diff --git a/korganizer/koeditorfreebusy.cpp b/korganizer/koeditorfreebusy.cpp index da7f36f04..fab937190 100644 --- a/korganizer/koeditorfreebusy.cpp +++ b/korganizer/koeditorfreebusy.cpp @@ -699,7 +699,7 @@ void KOEditorFreeBusy::updateStatusSummary() mStatusSummaryLabel->setText( i18n( "Of the %1 participants, %2 have accepted, %3" " have tentatively accepted, and %4 have declined.") - .arg( total ).arg( accepted ).arg( tentative ).arg( declined ) ); + .tqarg( total ).tqarg( accepted ).tqarg( tentative ).tqarg( declined ) ); } else { mStatusSummaryLabel->hide(); } @@ -783,7 +783,7 @@ void KOEditorFreeBusy::writeEvent(KCal::Event * event) bool skip = false; if ( attendee->email().endsWith( "example.net" ) ) { if ( KMessageBox::warningYesNo( this, i18n("%1 does not look like a valid email address. " - "Are you sure you want to invite this participant?").arg( attendee->email() ), + "Are you sure you want to invite this participant?").tqarg( attendee->email() ), i18n("Invalid email address") ) != KMessageBox::Yes ) { skip = true; } @@ -920,7 +920,7 @@ void KOEditorFreeBusy::showAttendeeStatusMenu() void KOEditorFreeBusy::listViewClicked(int button, KDGanttViewItem * item) { - if ( button == TQt::LeftButton && item == 0 ) + if ( button == Qt::LeftButton && item == 0 ) addNewAttendee(); } @@ -980,7 +980,7 @@ void KOEditorFreeBusy::slotOrganizerChanged(const TQString & newOrganizer) bool KOEditorFreeBusy::eventFilter( TQObject *watched, TQEvent *event ) { - if ( watched == mGanttView->timeHeaderWidget() && + if ( TQT_BASE_OBJECT(watched) == TQT_BASE_OBJECT(mGanttView->timeHeaderWidget()) && event->type() >= TQEvent::MouseButtonPress && event->type() <= TQEvent::MouseMove ) { return true; } else { diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp index 3a15188ab..afbda6156 100644 --- a/korganizer/koeditorgeneral.cpp +++ b/korganizer/koeditorgeneral.cpp @@ -426,7 +426,7 @@ void KOEditorGeneral::updateAlarmWidgets( Incidence *incidence ) remStr = remStr.left( maxLen ); remStr += etc; } - mAlarmInfoLabel->setText( i18n( "Triggers %1" ).arg( remStr ) ); + mAlarmInfoLabel->setText( i18n( "Triggers %1" ).tqarg( remStr ) ); } } else { // alarm count is 1 Alarm *alarm = mAlarmList.first(); @@ -465,7 +465,7 @@ void KOEditorGeneral::updateAlarmWidgets( Incidence *incidence ) mSimpleAlarmBox->hide(); if ( incidence ) { TQString remStr = IncidenceFormatter::reminderStringList( incidence ).first(); - mAlarmInfoLabel->setText( i18n( "Triggers %1" ).arg( remStr ) ); + mAlarmInfoLabel->setText( i18n( "Triggers %1" ).tqarg( remStr ) ); } } } @@ -497,7 +497,7 @@ void KOEditorGeneral::readIncidence( Incidence *incidence, Calendar *calendar ) TQString resLabel = IncidenceFormatter::resourceString( calendar, incidence ); if ( !resLabel.isEmpty() ) { - mResourceLabel->setText( i18n( "Calendar: %1" ).arg( resLabel ) ); + mResourceLabel->setText( i18n( "Calendar: %1" ).tqarg( resLabel ) ); mResourceLabel->show(); } } @@ -573,7 +573,7 @@ void KOEditorGeneral::setDescription( const TQString &text ) TQObject *KOEditorGeneral::typeAheadReceiver() const { - return mSummaryEdit; + return TQT_TQOBJECT(mSummaryEdit); } void KOEditorGeneral::updateAttendeeSummary(int count) diff --git a/korganizer/koeditorgeneralevent.cpp b/korganizer/koeditorgeneralevent.cpp index 123632f36..e09007508 100644 --- a/korganizer/koeditorgeneralevent.cpp +++ b/korganizer/koeditorgeneralevent.cpp @@ -95,7 +95,7 @@ void KOEditorGeneralEvent::initTime(TQWidget *tqparent,TQBoxLayout *topLayout) { TQBoxLayout *timeLayout = new TQVBoxLayout(topLayout); - TQGroupBox *timeGroupBox = new TQGroupBox(1,TQGroupBox::Horizontal, + TQGroupBox *timeGroupBox = new TQGroupBox(1,Qt::Horizontal, i18n("Date && Time"),tqparent); TQWhatsThis::add( timeGroupBox, i18n("Sets options related to the date and time of the " @@ -253,7 +253,7 @@ void KOEditorGeneralEvent::setDateTimes( const TQDateTime &start, const TQDateTi void KOEditorGeneralEvent::startTimeChanged( TQTime newtime ) { - kdDebug(5850) << "KOEditorGeneralEvent::startTimeChanged() " << newtime.toString() << endl; + kdDebug(5850) << "KOEditorGeneralEvent::startTimeChanged() " << TQString(newtime.toString()) << endl; int secsep = mCurrStartDateTime.secsTo(mCurrEndDateTime); @@ -479,8 +479,8 @@ void KOEditorGeneralEvent::emitDateTimeStr() to = l->formatDateTime(mCurrEndDateTime); } - TQString str = i18n("From: %1 To: %2 %3").arg(from).arg(to) - .arg(mDurationLabel->text()); + TQString str = i18n("From: %1 To: %2 %3").tqarg(from).tqarg(to) + .tqarg(mDurationLabel->text()); emit dateTimeStrChanged(str); } @@ -493,14 +493,14 @@ bool KOEditorGeneralEvent::validateInput() if (!mStartTimeEdit->inputIsValid()) { KMessageBox::sorry( 0, i18n("Please specify a valid start time, for example '%1'.") - .arg( KGlobal::locale()->formatTime( TQTime::currentTime() ) ) ); + .tqarg( KGlobal::locale()->formatTime( TQTime::currentTime() ) ) ); return false; } if (!mEndTimeEdit->inputIsValid()) { KMessageBox::sorry( 0, i18n("Please specify a valid end time, for example '%1'.") - .arg( KGlobal::locale()->formatTime( TQTime::currentTime() ) ) ); + .tqarg( KGlobal::locale()->formatTime( TQTime::currentTime() ) ) ); return false; } } @@ -508,14 +508,14 @@ bool KOEditorGeneralEvent::validateInput() if (!mStartDateEdit->date().isValid()) { KMessageBox::sorry( 0, i18n("Please specify a valid start date, for example '%1'.") - .arg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); + .tqarg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); return false; } if (!mEndDateEdit->date().isValid()) { KMessageBox::sorry( 0, i18n("Please specify a valid end date, for example '%1'.") - .arg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); + .tqarg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); return false; } diff --git a/korganizer/koeditorgeneraljournal.cpp b/korganizer/koeditorgeneraljournal.cpp index 274c58b90..2211c97da 100644 --- a/korganizer/koeditorgeneraljournal.cpp +++ b/korganizer/koeditorgeneraljournal.cpp @@ -47,7 +47,7 @@ KOEditorGeneralJournal::KOEditorGeneralJournal( TQWidget *tqparent, const char *name ) - : KOEditorGeneral( tqparent, name ) + : KOEditorGeneral( TQT_TQOBJECT(tqparent), name ) { setType( "Journal" ); } @@ -110,7 +110,7 @@ void KOEditorGeneralJournal::setDate( const TQDate &date ) void KOEditorGeneralJournal::setTime( const TQTime &time ) { -kdDebug()<<"KOEditorGeneralJournal::setTime, time="<<time.toString()<<endl; +kdDebug()<<"KOEditorGeneralJournal::setTime, time="<<TQString(time.toString())<<endl; bool validTime = time.isValid(); mTimeCheckBox->setChecked( validTime ); mTimeEdit->setEnabled( validTime ); @@ -142,7 +142,7 @@ void KOEditorGeneralJournal::readJournal( Journal *journal, const TQDate &, bool if ( !tmpl ) { setDate( journal->dtStart().date() ); if ( !journal->doesFloat() ) { -kdDebug()<<"KOEditorGeneralJournal::readJournal, does not float, time="<<(journal->dtStart().time().toString())<<endl; +kdDebug()<<"KOEditorGeneralJournal::readJournal, does not float, time="<<TQString(journal->dtStart().time().toString())<<endl; setTime( journal->dtStart().time() ); } else { kdDebug()<<"KOEditorGeneralJournal::readJournal, does float"<<endl; @@ -196,7 +196,7 @@ bool KOEditorGeneralJournal::validateInput() if (!mDateEdit->date().isValid()) { KMessageBox::sorry( 0, i18n("Please specify a valid date, for example '%1'.") - .arg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); + .tqarg( KGlobal::locale()->formatDate( TQDate::tqcurrentDate() ) ) ); return false; } diff --git a/korganizer/koeditorgeneraltodo.cpp b/korganizer/koeditorgeneraltodo.cpp index 93caec36f..d5856dd63 100644 --- a/korganizer/koeditorgeneraltodo.cpp +++ b/korganizer/koeditorgeneraltodo.cpp @@ -96,7 +96,7 @@ void KOEditorGeneralTodo::initTime(TQWidget *tqparent,TQBoxLayout *topLayout) kdDebug(5850) << k_funcinfo << endl; TQBoxLayout *timeLayout = new TQVBoxLayout(topLayout); - TQGroupBox *timeGroupBox = new TQGroupBox(1,TQGroupBox::Horizontal, + TQGroupBox *timeGroupBox = new TQGroupBox(1,Qt::Horizontal, i18n("Date && Time"),tqparent); timeLayout->addWidget(timeGroupBox); @@ -206,7 +206,7 @@ void KOEditorGeneralTodo::initCompletion( TQWidget *tqparent, TQBoxLayout *topLa i18n( "Use this combobox to set the completion percentage of the to-do." ) ); for ( int i = 0; i <= 100; i+=10 ) { // xgettext:no-c-format - TQString label = i18n( "Percent complete", "%1 %" ).arg( i ); + TQString label = i18n( "Percent complete", "%1 %" ).tqarg( i ); mCompletedCombo->insertItem( label ); } connect( mCompletedCombo, TQT_SIGNAL(activated(int)), TQT_SLOT(completedChanged(int)) ); @@ -569,18 +569,18 @@ void KOEditorGeneralTodo::dateChanged() TQString dateTimeStr = ""; if ( mStartCheck->isChecked() ) { - dateTimeStr += i18n("Start: %1").arg( + dateTimeStr += i18n("Start: %1").tqarg( l->formatDate( mStartDateEdit->date() ) ); if ( mTimeButton->isChecked() ) - dateTimeStr += TQString(" %1").arg( + dateTimeStr += TQString(" %1").tqarg( l->formatTime( mStartTimeEdit->getTime() ) ); } if ( mDueCheck->isChecked() ) { - dateTimeStr += i18n(" Due: %1").arg( + dateTimeStr += i18n(" Due: %1").tqarg( l->formatDate( mDueDateEdit->date() ) ); if ( mTimeButton->isChecked() ) - dateTimeStr += TQString(" %1").arg( + dateTimeStr += TQString(" %1").tqarg( l->formatTime( mDueTimeEdit->getTime() ) ); } diff --git a/korganizer/koeditorrecurrence.cpp b/korganizer/koeditorrecurrence.cpp index 834ea1ce2..21deaeed6 100644 --- a/korganizer/koeditorrecurrence.cpp +++ b/korganizer/koeditorrecurrence.cpp @@ -578,7 +578,7 @@ ExceptionsWidget::ExceptionsWidget( TQWidget *tqparent, const char *name ) : { TQBoxLayout *topLayout = new TQVBoxLayout( this ); - TQGroupBox *groupBox = new TQGroupBox( 1, Horizontal, i18n("E&xceptions"), + TQGroupBox *groupBox = new TQGroupBox( 1, Qt::Horizontal, i18n("E&xceptions"), this ); topLayout->addWidget( groupBox ); @@ -632,7 +632,7 @@ void ExceptionsWidget::addException() { TQDate date = mExceptionDateEdit->date(); TQString dateStr = KGlobal::locale()->formatDate( date ); - if( !mExceptionList->findItem( dateStr ) ) { + if( !mExceptionList->tqfindItem( dateStr ) ) { mExceptionDates.append( date ); mExceptionList->insertItem( dateStr ); } @@ -700,7 +700,7 @@ RecurrenceRangeWidget::RecurrenceRangeWidget( TQWidget *tqparent, { TQBoxLayout *topLayout = new TQVBoxLayout( this ); - mRangeGroupBox = new TQGroupBox( 1, Horizontal, i18n("Recurrence Range"), + mRangeGroupBox = new TQGroupBox( 1, Qt::Horizontal, i18n("Recurrence Range"), this ); TQWhatsThis::add( mRangeGroupBox, i18n("Sets a range for which these recurrence rules will " @@ -824,7 +824,7 @@ void RecurrenceRangeWidget::setDateTimes( const TQDateTime &start, const TQDateTime & ) { mStartDateLabel->setText( i18n("Begins on: %1") - .arg( KGlobal::locale()->formatDate( start.date() ) ) ); + .tqarg( KGlobal::locale()->formatDate( start.date() ) ) ); } ///////////////////////// RecurrenceRangeDialog /////////////////////////// @@ -891,7 +891,7 @@ RecurrenceChooser::RecurrenceChooser( TQWidget *tqparent, const char *name ) : } else { mTypeCombo = 0; - TQButtonGroup *ruleButtonGroup = new TQButtonGroup( 1, Horizontal, this ); + TQButtonGroup *ruleButtonGroup = new TQButtonGroup( 1, Qt::Horizontal, this ); ruleButtonGroup->setFrameStyle( TQFrame::NoFrame ); topLayout->addWidget( ruleButtonGroup ); @@ -980,7 +980,7 @@ KOEditorRecurrence::KOEditorRecurrence( TQWidget* tqparent, const char *name ) : topLayout->addMultiCellWidget( mEnabledCheck, 0, 0, 0, 1 ); - mTimeGroupBox = new TQGroupBox( 1, Horizontal, i18n("Appointment Time "), + mTimeGroupBox = new TQGroupBox( 1, Qt::Horizontal, i18n("Appointment Time "), this ); TQWhatsThis::add( mTimeGroupBox, i18n("Displays appointment time information.") ); @@ -999,8 +999,8 @@ KOEditorRecurrence::KOEditorRecurrence( TQWidget* tqparent, const char *name ) : // tqlayoutTimeFrame->addWidget( mDateTimeLabel ); Qt::Orientation orientation; - if ( KOPrefs::instance()->mCompactDialogs ) orientation = Horizontal; - else orientation = Vertical; + if ( KOPrefs::instance()->mCompactDialogs ) orientation = Qt::Horizontal; + else orientation = Qt::Vertical; mRuleBox = new TQGroupBox( 1, orientation, i18n("Recurrence Rule"), this ); TQWhatsThis::add( mRuleBox, @@ -1394,8 +1394,8 @@ bool KOEditorRecurrence::validateInput() mEventStartDt.isValid() && ((mRecurrenceRange->endDate())<mEventStartDt.date()) ) { KMessageBox::sorry( 0, i18n("The end date '%1' of the recurrence must be after the start date '%2' of the event.") - .arg( KGlobal::locale()->formatDate( mRecurrenceRange->endDate() ) ) - .arg( KGlobal::locale()->formatDate( mEventStartDt.date() ) ) ); + .tqarg( KGlobal::locale()->formatDate( mRecurrenceRange->endDate() ) ) + .tqarg( KGlobal::locale()->formatDate( mEventStartDt.date() ) ) ); return false; } int recurrenceType = mRecurrenceChooser->type(); diff --git a/korganizer/koeventeditor.cpp b/korganizer/koeventeditor.cpp index 3373778a4..73857fd64 100644 --- a/korganizer/koeventeditor.cpp +++ b/korganizer/koeventeditor.cpp @@ -116,7 +116,7 @@ void KOEventEditor::reload() void KOEventEditor::setupGeneral() { - mGeneral = new KOEditorGeneralEvent( this ); + mGeneral = new KOEditorGeneralEvent( TQT_TQOBJECT(this) ); if( KOPrefs::instance()->mCompactDialogs ) { TQFrame *topFrame = addPage(i18n("General")); @@ -285,7 +285,7 @@ bool KOEventEditor::processInput() // add dummy event at the position of the counter proposal Event *event = mEvent->clone(); event->clearAttendees(); - event->setSummary( i18n("My counter proposal for: %1").arg( mEvent->summary() ) ); + event->setSummary( i18n("My counter proposal for: %1").tqarg( mEvent->summary() ) ); mChanger->addIncidence( event, mResource, mSubResource, this ); } else { if ( mRecurIncidence && mRecurIncidenceAfterDissoc ) { diff --git a/korganizer/koeventviewer.cpp b/korganizer/koeventviewer.cpp index 8cd16faad..391ad42ac 100644 --- a/korganizer/koeventviewer.cpp +++ b/korganizer/koeventviewer.cpp @@ -62,7 +62,7 @@ void KOEventViewer::message( const TQString &link ) if ( link.startsWith( "kmail:" ) ) { ttStr = i18n( "Open the message in KMail" ); } else if ( link.startsWith( "mailto:" ) ) { - ttStr = i18n( "Send an email message to %1" ).arg( link.mid( 7 ) ); + ttStr = i18n( "Send an email message to %1" ).tqarg( link.mid( 7 ) ); } else if ( link.startsWith( "uid:" ) ) { ttStr = i18n( "Lookup the contact in KAddressbook" ); } else if ( link.startsWith( "ATTACH:" ) ) { @@ -70,7 +70,7 @@ void KOEventViewer::message( const TQString &link ) tmp.remove( TQRegExp( "^ATTACH://" ) ); TQString uid = tmp.section( ':', 0, 0 ); TQString name = tmp.section( ':', -1, -1 ); - ttStr = i18n( "View attachment \"%1\"" ).arg( name ); + ttStr = i18n( "View attachment \"%1\"" ).tqarg( name ); mAttachLink = link; } else { // no special URI, let KDE handle it ttStr = i18n( "Launch a viewer on the link" ); @@ -85,7 +85,7 @@ void KOEventViewer::readSettings( KConfig * config ) // With each restart of KOrganizer the font site gets halfed. What should this // be good for? #if 0 - config->setGroup( TQString("EventViewer-%1").arg( name() ) ); + config->setGroup( TQString("EventViewer-%1").tqarg( name() ) ); int zoomFactor = config->readNumEntry("ZoomFactor", pointSize() ); zoomTo( zoomFactor/2 ); kdDebug(5850) << " KOEventViewer: restoring the pointSize: "<< pointSize() @@ -98,7 +98,7 @@ void KOEventViewer::writeSettings( KConfig * config ) { if ( config ) { kdDebug(5850) << " KOEventViewer: saving the zoomFactor: "<< pointSize() << endl; - config->setGroup( TQString("EventViewer-%1").arg( name() ) ); + config->setGroup( TQString("EventViewer-%1").tqarg( name() ) ); config->writeEntry("ZoomFactor", pointSize() ); } } diff --git a/korganizer/kogroupware.cpp b/korganizer/kogroupware.cpp index 5bf8d8fb4..e5e174e48 100644 --- a/korganizer/kogroupware.cpp +++ b/korganizer/kogroupware.cpp @@ -163,7 +163,7 @@ void KOGroupware::incomingDirChanged( const TQString& path ) if ( !message ) { TQString errorMessage; if (mFormat.exception()) - errorMessage = i18n( "Error message: %1" ).arg( mFormat.exception()->message() ); + errorMessage = i18n( "Error message: %1" ).tqarg( mFormat.exception()->message() ); kdDebug(5850) << "MailScheduler::retrieveTransactions() Error parsing " << errorMessage << endl; KMessageBox::detailedError( mView, @@ -401,7 +401,7 @@ void KOGroupware::sendCounterProposal(KCal::Calendar *calendar, KCal::Event * ol return; if ( KOPrefs::instance()->outlookCompatCounterProposals() ) { Incidence* tmp = oldEvent->clone(); - tmp->setSummary( i18n("Counter proposal: %1").arg( newEvent->summary() ) ); + tmp->setSummary( i18n("Counter proposal: %1").tqarg( newEvent->summary() ) ); tmp->setDescription( newEvent->description() ); tmp->addComment( i18n("Proposed new meeting time: %1 - %2"). arg( IncidenceFormatter::dateToString( newEvent->dtStart() ), diff --git a/korganizer/koincidenceeditor.cpp b/korganizer/koincidenceeditor.cpp index 9047cff95..9d321221c 100644 --- a/korganizer/koincidenceeditor.cpp +++ b/korganizer/koincidenceeditor.cpp @@ -172,12 +172,12 @@ void KOIncidenceEditor::slotLoadTemplate( const TQString& templateName ) if ( fileName.isEmpty() ) { KMessageBox::error( this, i18n("Unable to find template '%1'.") - .arg( fileName ) ); + .tqarg( fileName ) ); } else { ICalFormat format; if ( !format.load( &cal, fileName ) ) { KMessageBox::error( this, i18n("Error loading template file '%1'.") - .arg( fileName ) ); + .tqarg( fileName ) ); return; } } @@ -196,7 +196,7 @@ void KOIncidenceEditor::setupDesignerTabs( const TQString &type ) TQStringList list = KGlobal::dirs()->findAllResources( "data", "korganizer/designer/" + type + "/*.ui", true, true ); for ( TQStringList::iterator it = list.begin(); it != list.end(); ++it ) { - const TQString &fn = (*it).mid( (*it).findRev('/') + 1 ); + const TQString &fn = (*it).mid( (*it).tqfindRev('/') + 1 ); if ( activePages.tqfind( fn ) != activePages.end() ) { addDesignerTab( *it ); } diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index 973550d65..ce75b6543 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp @@ -135,9 +135,9 @@ bool KOListView::ListItemVisitor::visit( Event *e ) TQString endDateTime; mItem->setText( StartDateTime_Column, IncidenceFormatter::dateTimeToString( e->dtStart(), e->doesFloat() ) ); - mItem->setSortKey( StartDateTime_Column, e->dtStart().toString( TQt::ISODate ) ); + mItem->setSortKey( StartDateTime_Column, e->dtStart().toString( Qt::ISODate ) ); mItem->setText( EndDateTime_Column, IncidenceFormatter::dateTimeToString( e->dtEnd(), e->doesFloat() ) ); - mItem->setSortKey( EndDateTime_Column, e->dtEnd().toString( TQt::ISODate ) ); + mItem->setSortKey( EndDateTime_Column, e->dtEnd().toString( Qt::ISODate ) ); mItem->setText( Categories_Column, e->categoriesStr() ); return true; @@ -167,14 +167,14 @@ bool KOListView::ListItemVisitor::visit( Todo *t ) if ( t->hasStartDate() ) { mItem->setText( StartDateTime_Column, IncidenceFormatter::dateTimeToString( t->dtStart(), t->doesFloat() ) ); - mItem->setSortKey( StartDateTime_Column, t->dtStart().toString( TQt::ISODate ) ); + mItem->setSortKey( StartDateTime_Column, t->dtStart().toString( Qt::ISODate ) ); } else { mItem->setText( StartDateTime_Column, "---" ); } if ( t->hasDueDate() ) { mItem->setText( EndDateTime_Column, IncidenceFormatter::dateTimeToString( t->dtDue(), t->doesFloat() ) ); - mItem->setSortKey( EndDateTime_Column, t->dtDue().toString( TQt::ISODate ) ); + mItem->setSortKey( EndDateTime_Column, t->dtDue().toString( Qt::ISODate ) ); } else { mItem->setText( EndDateTime_Column, "---" ); } @@ -190,7 +190,7 @@ bool KOListView::ListItemVisitor::visit( Journal *j ) // Just use the first line mItem->setText( Summary_Column, j->description().section( "\n", 0, 0 ) ); mItem->setText( StartDateTime_Column, IncidenceFormatter::dateTimeToString( j->dtStart(), j->doesFloat() ) ); - mItem->setSortKey( StartDateTime_Column, j->dtStart().toString( TQt::ISODate ) ); + mItem->setSortKey( StartDateTime_Column, j->dtStart().toString( Qt::ISODate ) ); return true; } @@ -232,15 +232,15 @@ KOListView::KOListView( Calendar *calendar, TQT_SLOT(hideDates())); */ - TQObject::connect( mListView, TQT_SIGNAL( doubleClicked( TQListViewItem * ) ), + connect( mListView, TQT_SIGNAL( doubleClicked( TQListViewItem * ) ), TQT_SLOT( defaultItemAction( TQListViewItem * ) ) ); - TQObject::connect( mListView, TQT_SIGNAL( returnPressed( TQListViewItem * ) ), + connect( mListView, TQT_SIGNAL( returnPressed( TQListViewItem * ) ), TQT_SLOT( defaultItemAction( TQListViewItem * ) ) ); - TQObject::connect( mListView, TQT_SIGNAL( rightButtonClicked ( TQListViewItem *, + connect( mListView, TQT_SIGNAL( rightButtonClicked ( TQListViewItem *, const TQPoint &, int ) ), TQT_SLOT( popupMenu( TQListViewItem *, const TQPoint &, int ) ) ); - TQObject::connect( mListView, TQT_SIGNAL( selectionChanged() ), + connect( mListView, TQT_SIGNAL( selectionChanged() ), TQT_SLOT( processSelectionChange() ) ); // setMinimumSize(100,100); @@ -502,6 +502,6 @@ void KOListView::clear() TQSize KOListView::tqsizeHint() const { const TQSize s = KOEventView::tqsizeHint(); - return TQSize( s.width() + style().tqpixelMetric( TQStyle::PM_ScrollBarExtent ) + 1, + return TQSize( s.width() + tqstyle().tqpixelMetric( TQStyle::PM_ScrollBarExtent ) + 1, s.height() ); } diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index ad03aec43..5ed6664f0 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp @@ -168,7 +168,7 @@ void KNoScrollListBox::mousePressEvent( TQMouseEvent *e ) { TQListBox::mousePressEvent( e ); - if ( e->button() == RightButton ) { + if ( e->button() == Qt::RightButton ) { emit rightClick(); } } @@ -425,8 +425,8 @@ void MonthViewCell::setDate( const TQDate &date ) TQString text; if ( KOGlobals::self()->calendarSystem()->day( date ) == 1 ) { text = i18n("'Month day' for month view cells", "%1 %2") - .arg( KOGlobals::self()->calendarSystem()->monthName( date, true ) ) - .arg( KOGlobals::self()->calendarSystem()->day(mDate) ); + .tqarg( KOGlobals::self()->calendarSystem()->monthName( date, true ) ) + .tqarg( KOGlobals::self()->calendarSystem()->day(mDate) ); TQFontMetrics fm( mLabel->font() ); mLabel->resize( mLabelSize + TQSize( fm.width( text ), 0 ) ); } else { @@ -546,7 +546,7 @@ class MonthViewCell::CreateItemVisitor : TQDateTime dt( mDate ); // take the time 0:00 into account, which is non-inclusive TQDate dtEnd = event->dtEnd().addSecs( event->doesFloat() ? 0 : -1).date(); - int length = event->dtStart().daysTo( dtEnd ); + int length = event->dtStart().daysTo( TQDateTime(dtEnd) ); if ( event->isMultiDay() ) { if ( mDate == event->dtStart().date() || ( mMultiDay == 0 && event->recursOn( mDate ) ) ) { @@ -976,8 +976,8 @@ void KOMonthView::showDates( const TQDate &start, const TQDate & ) mStartDate = mStartDate.addDays( -weekdayCol ); mLabel->setText( i18n( "monthname year", "%1 %2" ) - .arg( calSys->monthName( start ) ) - .arg( calSys->year( start ) ) ); + .tqarg( calSys->monthName( start ) ) + .tqarg( calSys->year( start ) ) ); showLabel( !KOPrefs::instance()->fullViewMonth() ); @@ -1087,7 +1087,7 @@ void KOMonthView::changeIncidenceDisplayAdded( Incidence *incidence, MonthViewCe if ( incidence->recursOn( mCells[i]->date(), calendar() ) ) { // handle multiday events - int length = gdv.startDate().daysTo( gdv.endDate().addSecs( floats ? 0 : -1 ).date() ); + int length = gdv.startDate().daysTo( TQDateTime(gdv.endDate().addSecs( floats ? 0 : -1 ).date()) ); for ( int j = 0; j <= length && i+j < mCells.count(); ++j ) { mCells[i+j]->addIncidence( incidence, v, j ); } diff --git a/korganizer/koprefs.cpp b/korganizer/koprefs.cpp index 66dd686df..dc52c312c 100644 --- a/korganizer/koprefs.cpp +++ b/korganizer/koprefs.cpp @@ -300,7 +300,7 @@ TQColor* KOPrefs::resourceColor( const TQString &cal ) defColor = TQColor( defaultResourceColors()[defaultResourceColorSeed()-1] ); } else { int h, s, v; - defColor.getHsv( h, s, v ); + defColor.getHsv( &h, &s, &v ); h = ( defaultResourceColorSeed() % 12 ) * 30; s -= s * ( (defaultResourceColorSeed() / 12) % 2 ) * 0.5; defColor.setHsv( h, s, v ); @@ -364,7 +364,7 @@ TQStringList KOPrefs::fullEmails() { TQStringList fullEmails; // The user name and email from the config dialog: - fullEmails << TQString("%1 <%2>").arg( fullName() ).arg( email() ); + fullEmails << TQString("%1 <%2>").tqarg( fullName() ).tqarg( email() ); TQStringList::Iterator it; // Grab emails from the email identities @@ -377,7 +377,7 @@ TQStringList KOPrefs::fullEmails() // Add emails configured in korganizer lst = mAdditionalMails; for ( it = lst.begin(); it != lst.end(); ++it ) { - fullEmails << TQString("%1 <%2>").arg( fullName() ).arg( *it ); + fullEmails << TQString("%1 <%2>").tqarg( fullName() ).tqarg( *it ); } // Add emails from the user's kaddressbook entry KABC::Addressee me = KABC::StdAddressBook::self()->whoAmI(); diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index d074ae91d..d454cdfef 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp @@ -100,7 +100,7 @@ KOPrefsDialogMain::KOPrefsDialogMain( TQWidget *tqparent, const char *name ) addWidString( KOPrefs::instance()->userNameItem(), mUserEmailSettings ); addWidString( KOPrefs::instance()->userEmailItem(), mUserEmailSettings ); - TQGroupBox *saveGroup = new TQGroupBox(1,Horizontal,i18n("Saving Calendar"), + TQGroupBox *saveGroup = new TQGroupBox(1,Qt::Horizontal,i18n("Saving Calendar"), topFrame); addWidBool( KOPrefs::instance()->htmlWithSaveItem(), saveGroup ); @@ -319,7 +319,7 @@ class KOPrefsDialogTime : public KPrefsModule topLayout->addWidget( defaultDuration->label(), 4, 0 ); topLayout->addWidget( defaultDuration->timeEdit(), 4, 1 ); - TQGroupBox *remindersGroupBox = new TQGroupBox( 1, Horizontal, + TQGroupBox *remindersGroupBox = new TQGroupBox( 1, Qt::Horizontal, i18n( "Reminders" ), topFrame ); topLayout->addMultiCellWidget( remindersGroupBox, 5, 5, 0, 1 ); @@ -367,7 +367,7 @@ class KOPrefsDialogTime : public KPrefsModule connect( mAlarmTimeDefaultCheckBox, TQT_SIGNAL( toggled( bool ) ), TQT_SLOT( slotWidChanged() ) ); - TQGroupBox *workingHoursGroup = new TQGroupBox(1,Horizontal, + TQGroupBox *workingHoursGroup = new TQGroupBox(1,Qt::Horizontal, i18n("Working Hours"), topFrame); topLayout->addMultiCellWidget( workingHoursGroup, 7, 7, 0, 1 ); @@ -454,7 +454,7 @@ class KOPrefsDialogTime : public KPrefsModule const TQStringList *tags = 0 ) { if (tags) { - int i = tags->findIndex(text); + int i = tags->tqfindIndex(text); if (i > 0) combo->setCurrentItem(i); } else { for(int i=0;i<combo->count();++i) { @@ -510,7 +510,7 @@ class KOPrefsDialogViews : public KPrefsModule topLayout->addWidget( showTodosAgenda->checkBox() ); /*** Date Navigator Group ***/ - TQGroupBox *dateNavGroup = new TQGroupBox( 1, Horizontal, + TQGroupBox *dateNavGroup = new TQGroupBox( 1, Qt::Horizontal, i18n("Date Navigator"), topFrame ); addWidBool( KOPrefs::instance()->dailyRecurItem(), dateNavGroup ); @@ -520,7 +520,7 @@ class KOPrefsDialogViews : public KPrefsModule /*** Agenda View Group ***/ - TQGroupBox *agendaGroup = new TQGroupBox( 1, Horizontal, + TQGroupBox *agendaGroup = new TQGroupBox( 1, Qt::Horizontal, i18n("Agenda View"), topFrame ); @@ -554,7 +554,7 @@ class KOPrefsDialogViews : public KPrefsModule topLayout->addWidget( agendaGroup ); /*** Month View Group ***/ - TQGroupBox *monthGroup = new TQGroupBox( 1, Horizontal, + TQGroupBox *monthGroup = new TQGroupBox( 1, Qt::Horizontal, i18n("Month View"), topFrame ); addWidBool( KOPrefs::instance()->enableMonthScrollItem(), monthGroup ); @@ -564,7 +564,7 @@ class KOPrefsDialogViews : public KPrefsModule /*** Todo View Group ***/ - TQGroupBox *todoGroup = new TQGroupBox( 1, Horizontal, + TQGroupBox *todoGroup = new TQGroupBox( 1, Qt::Horizontal, i18n("To-do View"), topFrame ); addWidBool( KOPrefs::instance()->fullViewTodoItem(), todoGroup ); @@ -700,7 +700,7 @@ KOPrefsDialogColors::KOPrefsDialogColors( TQWidget *tqparent, const char *name ) topLayout->addWidget( unsetCategoryColor->button(), 6, 1 ); // categories colors - TQGroupBox *categoryGroup = new TQGroupBox(1,Horizontal,i18n("Categories"), + TQGroupBox *categoryGroup = new TQGroupBox(1,Qt::Horizontal,i18n("Categories"), topFrame); topLayout->addMultiCellWidget(categoryGroup,7,7,0,1); @@ -721,7 +721,7 @@ KOPrefsDialogColors::KOPrefsDialogColors( TQWidget *tqparent, const char *name ) updateCategoryColor(); // resources colors - TQGroupBox *resourceGroup = new TQGroupBox(1,Horizontal,i18n("Resources"), + TQGroupBox *resourceGroup = new TQGroupBox(1,Qt::Horizontal,i18n("Resources"), topFrame); topLayout->addMultiCellWidget(resourceGroup,8,8,0,1); diff --git a/korganizer/korgac/alarmdialog.cpp b/korganizer/korgac/alarmdialog.cpp index e095950a4..1a6c4dbee 100644 --- a/korganizer/korgac/alarmdialog.cpp +++ b/korganizer/korgac/alarmdialog.cpp @@ -122,7 +122,7 @@ AlarmDialog::AlarmDialog( KCal::CalendarResources *calendar, TQWidget *tqparent, TQLabel *label = new TQLabel( i18n("The following items triggered reminders:"), topBox ); topLayout->addWidget( label ); - mSplitter = new TQSplitter( TQt::Vertical, topBox ); + mSplitter = new TQSplitter( Qt::Vertical, topBox ); mSplitter->setOpaqueResize( KGlobalSettings::opaqueResize() ); topLayout->addWidget( mSplitter ); @@ -506,7 +506,7 @@ void AlarmDialog::eventNotification() // FIXME: Add a message box asking whether the procedure should really be executed kdDebug(5890) << "Starting program: '" << alarm->programFile() << "'" << endl; KProcess proc; - proc << TQFile::encodeName(alarm->programFile()); + proc << TQFile::encodeName(alarm->programFile()).data(); proc.start(KProcess::DontCare); } else if (alarm->type() == Alarm::Audio) { @@ -566,7 +566,7 @@ void AlarmDialog::slotSave() if ( !incidence ) { continue; } - config->setGroup( TQString("Incidence-%1").arg(numReminders + 1) ); + config->setGroup( TQString("Incidence-%1").tqarg(numReminders + 1) ); config->writeEntry( "UID", incidence->uid() ); config->writeEntry( "RemindAt", item->mRemindAt ); ++numReminders; diff --git a/korganizer/korgac/alarmdockwindow.cpp b/korganizer/korgac/alarmdockwindow.cpp index 27badddbb..85673ef03 100644 --- a/korganizer/korgac/alarmdockwindow.cpp +++ b/korganizer/korgac/alarmdockwindow.cpp @@ -177,7 +177,7 @@ void AlarmDockWindow::enableAutostart( bool enable ) void AlarmDockWindow::mousePressEvent( TQMouseEvent *e ) { - if ( e->button() == LeftButton ) { + if ( e->button() == Qt::LeftButton ) { kapp->startServiceByDesktopName( "korganizer", TQString() ); } else { KSystemTray::mousePressEvent( e ); diff --git a/korganizer/korgac/koalarmclient.cpp b/korganizer/korgac/koalarmclient.cpp index c1254f12c..f0837c65d 100644 --- a/korganizer/korgac/koalarmclient.cpp +++ b/korganizer/korgac/koalarmclient.cpp @@ -71,7 +71,7 @@ KOAlarmClient::KOAlarmClient( TQObject *tqparent, const char *name ) config->setGroup( "General" ); int numReminders = config->readNumEntry( "Reminders", 0 ); for ( int i = 1; i <= numReminders; ++i ) { - TQString group( TQString( "Incidence-%1" ).arg( i ) ); + TQString group( TQString( "Incidence-%1" ).tqarg( i ) ); config->setGroup( group ); TQString uid = config->readEntry( "UID" ); TQDateTime dt = config->readDateTimeEntry( "RemindAt" ); diff --git a/korganizer/korganizer.cpp b/korganizer/korganizer.cpp index 96a458200..eb6552ebd 100644 --- a/korganizer/korganizer.cpp +++ b/korganizer/korganizer.cpp @@ -101,8 +101,8 @@ KOrganizer::KOrganizer( const char *name ) mCalendarView = new CalendarView( this, "KOrganizer::CalendarView" ); setCentralWidget(mCalendarView); - mActionManager = new ActionManager( this, mCalendarView, this, this, false ); - (void)new KOrganizerIfaceImpl( mActionManager, this, "IfaceImpl" ); + mActionManager = new ActionManager( this, mCalendarView, TQT_TQOBJECT(this), this, false ); + (void)new KOrganizerIfaceImpl( mActionManager, TQT_TQOBJECT(this), "IfaceImpl" ); } KOrganizer::~KOrganizer() @@ -209,8 +209,8 @@ void KOrganizer::initActions() createStandardStatusBarAction(); KStdAction::keyBindings(guiFactory(), TQT_SLOT(configureShortcuts()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(configureToolbars() ), actionCollection()); - KStdAction::quit( this, TQT_SLOT( close() ), actionCollection() ); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(configureToolbars() ), actionCollection()); + KStdAction::quit( TQT_TQOBJECT(this), TQT_SLOT( close() ), actionCollection() ); setAutoSaveSettings(); createGUI( 0 ); diff --git a/korganizer/korganizer_part.cpp b/korganizer/korganizer_part.cpp index 064c4f12a..f933d47fe 100644 --- a/korganizer/korganizer_part.cpp +++ b/korganizer/korganizer_part.cpp @@ -81,7 +81,7 @@ KOrganizerPart::KOrganizerPart( TQWidget *tqparentWidget, const char *widgetName // create a canvas to insert our widget TQWidget *canvas = new TQWidget( tqparentWidget, widgetName ); - canvas->setFocusPolicy( TQWidget::ClickFocus ); + canvas->setFocusPolicy( Qt::ClickFocus ); setWidget( canvas ); mView = new CalendarView( canvas ); diff --git a/korganizer/kotodoeditor.cpp b/korganizer/kotodoeditor.cpp index f996321ea..cbf15d28d 100644 --- a/korganizer/kotodoeditor.cpp +++ b/korganizer/kotodoeditor.cpp @@ -94,7 +94,7 @@ void KOTodoEditor::reload() void KOTodoEditor::setupGeneral() { - mGeneral = new KOEditorGeneralTodo(this); + mGeneral = new KOEditorGeneralTodo(TQT_TQOBJECT(this)); if (KOPrefs::instance()->mCompactDialogs) { TQFrame *topFrame = addPage(i18n("General")); diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp index 475a2f636..bb4b2ba4f 100644 --- a/korganizer/kotodoview.cpp +++ b/korganizer/kotodoview.cpp @@ -299,7 +299,7 @@ void KOTodoListView::contentsMousePressEvent(TQMouseEvent* e) treeStepSize() * (i->depth() + (rootIsDecorated() ? 1 : 0)) + itemMargin() || p.x() < header()->sectionPos(header()->mapToIndex(0))) { - if (e->button()==TQt::LeftButton) { + if (e->button()==Qt::LeftButton) { mPressPos = e->pos(); mMousePressed = true; } @@ -1065,7 +1065,7 @@ void KOTodoView::itemStateChanged( TQListViewItem *item ) void KOTodoView::setNewPercentageDelayed( KOTodoViewItem *item, int percentage ) { - mPercentChangedMap.append( qMakePair( item, percentage ) ); + mPercentChangedMap.append( tqMakePair( item, percentage ) ); TQTimer::singleShot( 0, this, TQT_SLOT( processDelayedNewPercentage() ) ); } diff --git a/korganizer/kotodoviewitem.cpp b/korganizer/kotodoviewitem.cpp index 02369d91a..47aeb02b0 100644 --- a/korganizer/kotodoviewitem.cpp +++ b/korganizer/kotodoviewitem.cpp @@ -168,7 +168,7 @@ void KOTodoViewItem::construct() // Find sort id in description. It's the text behind the last '#' character // found in the description. White spaces are removed from beginning and end // of sort id. - int pos = mTodo->description().findRev('#'); + int pos = mTodo->description().tqfindRev('#'); if (pos < 0) { setText( KOTodoView::eDescriptionColumn, "" ); } else { diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp index 4f3b3dc2d..4f7c52fea 100644 --- a/korganizer/kowhatsnextview.cpp +++ b/korganizer/kowhatsnextview.cpp @@ -106,8 +106,8 @@ void KOWhatsNextView::updateView() mText += KGlobal::locale()->formatDate( mStartDate ); } else { mText += i18n("Date from - to", "%1 - %2") - .arg( KGlobal::locale()->formatDate( mStartDate ) ) - .arg( KGlobal::locale()->formatDate( mEndDate ) ); + .tqarg( KGlobal::locale()->formatDate( mStartDate ) ) + .tqarg( KGlobal::locale()->formatDate( mEndDate ) ); } mText+="</h2>\n"; @@ -281,14 +281,14 @@ void KOWhatsNextView::appendEvent( Incidence *ev, const TQDateTime &start, if ( starttime.date().daysTo( endtime.date() ) >= 1 ) { mText += i18n("date from - to", "%1 - %2") - .arg( KGlobal::locale()->formatDateTime( starttime ) ) - .arg( KGlobal::locale()->formatDateTime( endtime ) ); + .tqarg( KGlobal::locale()->formatDateTime( starttime ) ) + .tqarg( KGlobal::locale()->formatDateTime( endtime ) ); } else { /*if (reply) */ mText += i18n("date, from - to", "%1, %2 - %3") - .arg( KGlobal::locale()->formatDate( starttime.date(), true ) ) - .arg( KGlobal::locale()->formatTime( starttime.time() ) ) - .arg( KGlobal::locale()->formatTime( endtime.time() ) ); + .tqarg( KGlobal::locale()->formatDate( starttime.date(), true ) ) + .tqarg( KGlobal::locale()->formatTime( starttime.time() ) ) + .tqarg( KGlobal::locale()->formatTime( endtime.time() ) ); } } // } diff --git a/korganizer/mailscheduler.cpp b/korganizer/mailscheduler.cpp index 5176ca22a..b7b5ba69d 100644 --- a/korganizer/mailscheduler.cpp +++ b/korganizer/mailscheduler.cpp @@ -86,7 +86,7 @@ bool MailScheduler::performTransaction( IncidenceBase *incidence, TQString subject; Incidence *inc = dynamic_cast<Incidence*>( incidence ); if ( inc && method == Counter ) - subject = i18n( "Counter proposal: %1" ).arg( inc->summary() ); + subject = i18n( "Counter proposal: %1" ).tqarg( inc->summary() ); status = mailer.mailOrganizer( incidence, messageText, subject ); } return status; diff --git a/korganizer/multiagendaview.cpp b/korganizer/multiagendaview.cpp index d613941c4..4b7da9e26 100644 --- a/korganizer/multiagendaview.cpp +++ b/korganizer/multiagendaview.cpp @@ -57,7 +57,7 @@ MultiAgendaView::MultiAgendaView( Calendar * cal, CalendarView *calendarView, TQVBox *topSideBox = new TQVBox( this ); mLeftTopSpacer = new TQWidget( topSideBox ); mLeftTopSpacer->setFixedHeight( topLabelHeight ); - mLeftSplitter = new TQSplitter( TQt::Vertical, topSideBox ); + mLeftSplitter = new TQSplitter( Qt::Vertical, topSideBox ); mLeftSplitter->setOpaqueResize( KGlobalSettings::opaqueResize() ); TQLabel *label = new TQLabel( i18n("All Day"), mLeftSplitter ); label->tqsetAlignment( TQt::AlignRight | TQt::AlignVCenter | TQt::WordBreak ); @@ -81,14 +81,14 @@ MultiAgendaView::MultiAgendaView( Calendar * cal, CalendarView *calendarView, topSideBox = new TQVBox( this ); mRightTopSpacer = new TQWidget( topSideBox ); mRightTopSpacer->setFixedHeight( topLabelHeight ); - mRightSplitter = new TQSplitter( TQt::Vertical, topSideBox ); + mRightSplitter = new TQSplitter( Qt::Vertical, topSideBox ); mRightSplitter->setOpaqueResize( KGlobalSettings::opaqueResize() ); new TQWidget( mRightSplitter ); sideBox = new TQVBox( mRightSplitter ); eiSpacer = new EventIndicator( EventIndicator::Top, sideBox ); eiSpacer->setFixedHeight( eiSpacer->minimumHeight() ); eiSpacer->changeColumns( 0 ); - mScrollBar = new TQScrollBar( TQt::Vertical, sideBox ); + mScrollBar = new TQScrollBar( Qt::Vertical, sideBox ); eiSpacer = new EventIndicator( EventIndicator::Bottom, sideBox ); eiSpacer->setFixedHeight( eiSpacer->minimumHeight() ); eiSpacer->changeColumns( 0 ); @@ -464,12 +464,12 @@ bool MultiAgendaView::eventFilter(TQObject * obj, TQEvent * event) if ( (event->type() == TQEvent::MouseMove && KGlobalSettings::opaqueResize()) || event->type() == TQEvent::MouseButtonRelease ) { FOREACH_VIEW( agenda ) { - if ( agenda->splitter() == obj->tqparent() ) + if ( TQT_BASE_OBJECT(agenda->splitter()) == TQT_BASE_OBJECT(obj->tqparent()) ) mLastMovedSplitter = agenda->splitter(); } - if ( mLeftSplitter == obj->tqparent() ) + if ( TQT_BASE_OBJECT(mLeftSplitter )== TQT_BASE_OBJECT(obj->tqparent()) ) mLastMovedSplitter = mLeftSplitter; - else if ( mRightSplitter == obj->tqparent() ) + else if ( TQT_BASE_OBJECT(mRightSplitter) == TQT_BASE_OBJECT(obj->tqparent()) ) mLastMovedSplitter = mRightSplitter; TQTimer::singleShot( 0, this, TQT_SLOT(resizeSplitters()) ); } @@ -522,7 +522,7 @@ void MultiAgendaView::resizeSpacers( int newY ) void MultiAgendaView::zoomView( const int delta, const TQPoint & pos, const Qt::Orientation ori ) { - if ( ori == TQt::Vertical ) { + if ( ori == Qt::Vertical ) { if ( delta > 0 ) { if ( KOPrefs::instance()->mHourSize > 4 ) KOPrefs::instance()->mHourSize--; diff --git a/korganizer/navigatorbar.cpp b/korganizer/navigatorbar.cpp index b22b3f709..342d6bb49 100644 --- a/korganizer/navigatorbar.cpp +++ b/korganizer/navigatorbar.cpp @@ -174,8 +174,8 @@ void NavigatorBar::selectDates( const KCal::DateList &dateList ) mHasMinWidth = true; // set the label text at the top of the navigator - mMonth->setText( i18n( "monthname", "%1" ).arg( calSys->monthName( mDate ) ) ); - mYear->setText( i18n( "4 digit year", "%1" ).arg( calSys->yearString( mDate, false ) ) ); + mMonth->setText( i18n( "monthname", "%1" ).tqarg( calSys->monthName( mDate ) ) ); + mYear->setText( i18n( "4 digit year", "%1" ).tqarg( calSys->yearString( mDate, false ) ) ); } } diff --git a/korganizer/plugins/datenums/datenums.cpp b/korganizer/plugins/datenums/datenums.cpp index a8c8fbd98..32fc953e7 100644 --- a/korganizer/plugins/datenums/datenums.cpp +++ b/korganizer/plugins/datenums/datenums.cpp @@ -56,8 +56,8 @@ TQString Datenums::shortText(const TQDate &date) return TQString::number( KOGlobals::self()->calendarSystem()->daysInYear(date) - doy ); break; case 2: // both day of year and days till end of year - return i18n("dayOfYear / daysTillEndOfYear", "%1 / %2").arg( doy ) - .arg(KOGlobals::self()->calendarSystem()->daysInYear(date) - doy); + return i18n("dayOfYear / daysTillEndOfYear", "%1 / %2").tqarg( doy ) + .tqarg(KOGlobals::self()->calendarSystem()->daysInYear(date) - doy); break; case 0: // only day of year default: diff --git a/korganizer/plugins/hebrew/hebrew.cpp b/korganizer/plugins/hebrew/hebrew.cpp index ce0d96966..240e9a3f7 100644 --- a/korganizer/plugins/hebrew/hebrew.cpp +++ b/korganizer/plugins/hebrew/hebrew.cpp @@ -81,8 +81,8 @@ TQString Hebrew::shortText(const TQDate & date) hebrew_day_number, hebrew_year); KCalendarSystem *cal = KCalendarSystemFactory::create("hebrew"); - label_text = TQString("%1 %2").arg(cal->dayString(date, false)) - .arg(cal->monthName(date)); + label_text = TQString("%1 %2").tqarg(cal->dayString(date, false)) + .tqarg(cal->monthName(date)); if (holidays.count()) { diff --git a/korganizer/plugins/printing/year/yearprint.cpp b/korganizer/plugins/printing/year/yearprint.cpp index 0c124bbeb..5c36772fb 100644 --- a/korganizer/plugins/printing/year/yearprint.cpp +++ b/korganizer/plugins/printing/year/yearprint.cpp @@ -177,8 +177,8 @@ void CalPrintYear::print( TQPainter &p, int width, int height ) title = i18n("date from -\nto", "%1 -\n%2"); } drawHeader( p, title - .arg( locale->formatDate( start ) ) - .arg( locale->formatDate( end ) ), + .tqarg( locale->formatDate( start ) ) + .tqarg( locale->formatDate( end ) ), calsys->addMonths( start, -1), calsys->addMonths( start, monthsPerPage ), headerBox ); diff --git a/korganizer/printing/calprintdefaultplugins.cpp b/korganizer/printing/calprintdefaultplugins.cpp index c5f69dd09..6fe3a5e39 100644 --- a/korganizer/printing/calprintdefaultplugins.cpp +++ b/korganizer/printing/calprintdefaultplugins.cpp @@ -346,13 +346,13 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height ) if ( offset % (24*60) == 0 && offset>0 ) { // divides evenly into days? useoffset = offset / (24*60); - offsetstr = offsetstr.arg( i18n("1 day", "%n days", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 day", "%n days", useoffset ) ); } else if (offset % 60 == 0 && offset>0 ) { // divides evenly into hours? useoffset = offset / 60; - offsetstr = offsetstr.arg( i18n("1 hour", "%n hours", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 hour", "%n hours", useoffset ) ); } else { useoffset = offset; - offsetstr = offsetstr.arg( i18n("1 minute", "%n minutes", useoffset ) ); + offsetstr = offsetstr.tqarg( i18n("1 minute", "%n minutes", useoffset ) ); } alarmStrings << offsetstr; } @@ -481,24 +481,24 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height ) datesString = ""; if ( (*rit)->dtStart().isValid() ) { datesString += i18n( - "Start Date: %1\n").arg( + "Start Date: %1\n").tqarg( KGlobal::locale()->formatDate( (*rit)->dtStart().date(), true ) ); if ( !(*rit)->doesFloat() ) { datesString += i18n( - "Start Time: %1\n").arg( + "Start Time: %1\n").tqarg( KGlobal::locale()->formatTime((*rit)->dtStart().time(), false, false) ); } } if ( (*rit)->dtEnd().isValid() ) { subitemString += i18n( - "Due Date: %1\n").arg( + "Due Date: %1\n").tqarg( KGlobal::locale()->formatDate( (*rit)->dtEnd().date(), true ) ); if ( !(*rit)->doesFloat() ) { subitemString += i18n( - "subitem due time", "Due Time: %1\n").arg( + "subitem due time", "Due Time: %1\n").tqarg( KGlobal::locale()->formatTime((*rit)->dtEnd().time(), false, false) ); } @@ -511,12 +511,12 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height ) subitemString += "\n"; } subitemString += i18n( "subitem tqStatus: statusString", - "tqStatus: %1\n").arg( statusString ); + "tqStatus: %1\n").tqarg( statusString ); subitemString += IncidenceFormatter::recurrenceString((*rit)) + "\n"; subitemString += i18n( "subitem Priority: N", - "Priority: %1\n").arg( (*rit)->priority() ); + "Priority: %1\n").tqarg( (*rit)->priority() ); subitemString += i18n( "subitem Secrecy: secrecyString", - "Secrecy: %1\n").arg( (*rit)->secrecyStr() ); + "Secrecy: %1\n").tqarg( (*rit)->secrecyStr() ); subitemString += "\n"; } drawBoxWithCaption( p, notesBox, i18n("Subitems:"), @@ -562,8 +562,8 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height ) "'Name (Role): tqStatus', e.g. 'Reinhold Kainhofer " "<reinhold@kainhofer.com> (Participant): Awaiting Response'", "%1 (%2): %3") - .arg( (*ait)->fullName() ) - .arg( (*ait)->roleStr() ).arg( (*ait)->statusStr() ); + .tqarg( (*ait)->fullName() ) + .tqarg( (*ait)->roleStr() ).tqarg( (*ait)->statusStr() ); } drawBoxWithCaption( p, attendeesBox, i18n("Attendees:"), attendeeString, /*sameLine=*/false, /*expand=*/false, captionFont, textFont ); @@ -572,11 +572,11 @@ void CalPrintIncidence::print( TQPainter &p, int width, int height ) if ( mShowOptions ) { TQString optionsString; if ( !(*it)->statusStr().isEmpty() ) { - optionsString += i18n("tqStatus: %1").arg( (*it)->statusStr() ); + optionsString += i18n("tqStatus: %1").tqarg( (*it)->statusStr() ); optionsString += "\n"; } if ( !(*it)->secrecyStr().isEmpty() ) { - optionsString += i18n("Secrecy: %1").arg( (*it)->secrecyStr() ); + optionsString += i18n("Secrecy: %1").tqarg( (*it)->secrecyStr() ); optionsString += "\n"; } if ( (*it)->type() == "Event" ) { @@ -936,7 +936,7 @@ void CalPrintWeek::print( TQPainter &p, int width, int height ) } else { title = i18n("date from-\nto", "%1 -\n%2");; } - title = title.arg( line1 ).arg( line2 ); + title = title.tqarg( line1 ).tqarg( line2 ); drawHeader( p, title, curWeek.addDays( -6 ), TQDate(), headerBox ); drawWeek( p, curWeek, weekBox ); @@ -959,7 +959,7 @@ void CalPrintWeek::print( TQPainter &p, int width, int height ) } else { title = i18n("date from -\nto (week number)", "%1 -\n%2 (Week %3)"); } - title = title.arg( line1 ).arg( line2 ).arg( curWeek.weekNumber() ); + title = title.tqarg( line1 ).tqarg( line2 ).tqarg( curWeek.weekNumber() ); drawHeader( p, title, curWeek, TQDate(), headerBox ); TQRect weekBox( headerBox ); @@ -1121,8 +1121,8 @@ void CalPrintMonth::print( TQPainter &p, int width, int height ) do { TQString title( i18n("monthname year", "%1 %2") ); - title = title.arg( calSys->monthName( curMonth ) ) - .arg( curMonth.year() ); + title = title.tqarg( calSys->monthName( curMonth ) ) + .tqarg( curMonth.year() ); TQDate tmp( fromMonth ); int weekdayCol = weekdayColumn( tmp.dayOfWeek() ); tmp = tmp.addDays( -weekdayCol ); diff --git a/korganizer/printing/calprinter.cpp b/korganizer/printing/calprinter.cpp index 0b2c098cf..54aacd18c 100644 --- a/korganizer/printing/calprinter.cpp +++ b/korganizer/printing/calprinter.cpp @@ -174,7 +174,7 @@ CalPrintDialog::CalPrintDialog( KOrg::PrintPlugin::List plugins, TQVBox *page = makeVBoxMainWidget(); TQSplitter *splitter = new TQSplitter( page ); - splitter->setOrientation( TQSplitter::Horizontal ); + splitter->setOrientation( Qt::Horizontal ); mTypeGroup = new TQVButtonGroup( i18n("Print Style"), splitter, "buttonGroup" ); // use the minimal width possible = max width of the radio buttons, not extensible diff --git a/korganizer/printing/calprintpluginbase.cpp b/korganizer/printing/calprintpluginbase.cpp index 3d330efe0..3df996528 100644 --- a/korganizer/printing/calprintpluginbase.cpp +++ b/korganizer/printing/calprintpluginbase.cpp @@ -560,7 +560,7 @@ int CalPrintPluginBase::drawFooter( TQPainter &p, TQRect &footbox ) TQFontMetrics fm( p.font() ); TQString dateStr = KGlobal::locale()->formatDateTime( TQDateTime::tqcurrentDateTime(), false ); p.drawText( footbox, TQt::AlignCenter | TQt::AlignVCenter | TQt::SingleLine, - i18n( "print date: formatted-datetime", "printed: %1" ).arg( dateStr ) ); + i18n( "print date: formatted-datetime", "printed: %1" ).tqarg( dateStr ) ); p.setFont( oldfont ); return footbox.bottom(); @@ -933,9 +933,9 @@ void CalPrintPluginBase::drawDayBox( TQPainter &p, const TQDate &qd, if ( fullDate && mCalSys ) { dayNumStr = i18n("weekday month date", "%1 %2 %3") - .arg( mCalSys->weekDayName( qd ) ) - .arg( mCalSys->monthName( qd ) ) - .arg( qd.day() ); + .tqarg( mCalSys->weekDayName( qd ) ) + .tqarg( mCalSys->monthName( qd ) ) + .tqarg( qd.day() ); // dayNumStr = local->formatDate(qd); } else { dayNumStr = TQString::number( qd.day() ); @@ -984,7 +984,7 @@ void CalPrintPluginBase::drawDayBox( TQPainter &p, const TQDate &qd, TQString str; if ( !currEvent->location().isEmpty() ) { str = i18n( "summary, location", "%1, %2" ). - arg( currEvent->summary() ).arg( currEvent->location() ); + tqarg( currEvent->summary() ).tqarg( currEvent->location() ); } else { str = currEvent->summary(); } @@ -1008,7 +1008,7 @@ void CalPrintPluginBase::drawDayBox( TQPainter &p, const TQDate &qd, TQString summaryStr; if ( !todo->location().isEmpty() ) { summaryStr = i18n( "summary, location", "%1, %2" ). - arg( todo->summary() ).arg( todo->location() ); + tqarg( todo->summary() ).tqarg( todo->location() ); } else { summaryStr = todo->summary(); } @@ -1026,7 +1026,7 @@ void CalPrintPluginBase::drawDayBox( TQPainter &p, const TQDate &qd, } else { str = summaryStr; } - drawIncidence( p, box, timeText, i18n("To-do: %1").arg( str ), textY ); + drawIncidence( p, box, timeText, i18n("To-do: %1").tqarg( str ), textY ); } } @@ -1572,7 +1572,7 @@ void CalPrintPluginBase::drawTodo( int &count, Todo *todo, TQPainter &p, } //now, write the percentage - outStr = i18n( "%1%" ).arg( todo->percentComplete() ); + outStr = i18n( "%1%" ).tqarg( todo->percentComplete() ); rect = p.boundingRect( posPercentComplete+lwidth+3, y, x + width, -1, TQt::AlignTop | TQt::AlignLeft, outStr ); p.drawText( rect, TQt::AlignTop | TQt::AlignLeft, outStr ); @@ -1648,7 +1648,7 @@ void CalPrintPluginBase::drawJournalField( TQPainter &p, TQString field, TQStrin { if ( text.isEmpty() ) return; - TQString entry( field.arg( text ) ); + TQString entry( field.tqarg( text ) ); TQRect rect( p.boundingRect( x, y, width, -1, TQt::WordBreak, entry) ); if ( rect.bottom() > pageHeight) { @@ -1677,8 +1677,8 @@ void CalPrintPluginBase::drawJournal( Journal * journal, TQPainter &p, int x, in headerText = dateText; } else { headerText = i18n("Description - date", "%1 - %2") - .arg( journal->summary() ) - .arg( dateText ); + .tqarg( journal->summary() ) + .tqarg( dateText ); } TQRect rect( p.boundingRect( x, y, width, -1, TQt::WordBreak, headerText) ); @@ -1717,15 +1717,15 @@ void CalPrintPluginBase::drawSplitHeaderRight( TQPainter &p, const TQDate &fd, if ( mCalSys ) { if ( fd.month() == td.month() ) { title = i18n("Date range: Month dayStart - dayEnd", "%1 %2 - %3") - .arg( mCalSys->monthName( fd.month(), false ) ) - .arg( mCalSys->dayString( fd, false ) ) - .arg( mCalSys->dayString( td, false ) ); + .tqarg( mCalSys->monthName( fd.month(), false ) ) + .tqarg( mCalSys->dayString( fd, false ) ) + .tqarg( mCalSys->dayString( td, false ) ); } else { title = i18n("Date range: monthStart dayStart - monthEnd dayEnd", "%1 %2 - %3 %4") - .arg( mCalSys->monthName( fd.month(), false ) ) - .arg( mCalSys->dayString( fd, false ) ) - .arg( mCalSys->monthName( td.month(), false ) ) - .arg( mCalSys->dayString( td, false ) ); + .tqarg( mCalSys->monthName( fd.month(), false ) ) + .tqarg( mCalSys->dayString( fd, false ) ) + .tqarg( mCalSys->monthName( td.month(), false ) ) + .tqarg( mCalSys->dayString( td, false ) ); } } diff --git a/korganizer/resourceview.cpp b/korganizer/resourceview.cpp index 7b00a4611..cc6a8af9b 100644 --- a/korganizer/resourceview.cpp +++ b/korganizer/resourceview.cpp @@ -70,12 +70,12 @@ static TQString labelFromSubResName( ResourceCalendar *resource, const TQString TQString label; if ( (int)reply > 1 ) { if( resource && !resource->resourceName().isEmpty() ) { - label = i18n( "My %1 (%2)" ).arg( subRes, resource->resourceName() ); + label = i18n( "My %1 (%2)" ).tqarg( subRes, resource->resourceName() ); } else { - label = i18n( "My %1" ).arg( subRes ); + label = i18n( "My %1" ).tqarg( subRes ); } } else { - label = i18n( "My %1" ).arg( subRes ); + label = i18n( "My %1" ).tqarg( subRes ); } return label; } @@ -376,7 +376,7 @@ void ResourceView::addResource() if ( !item->resource()->addSubresource( folderName, tqparentId ) ) { KMessageBox::error( this, - i18n( "<qt>Unable to create subresource <b>%1</b>.</qt>" ).arg( folderName ) ); + i18n( "<qt>Unable to create subresource <b>%1</b>.</qt>" ).tqarg( folderName ) ); } return; } @@ -391,14 +391,14 @@ void ResourceView::addResource() return; } - TQString type = types[ descs.findIndex( desc ) ]; + TQString type = types[ descs.tqfindIndex( desc ) ]; // Create new resource ResourceCalendar *resource = manager->createResource( type ); if( !resource ) { KMessageBox::error( this, - i18n( "<qt>Unable to create resource of type <b>%1</b>.</qt>" ).arg( type ) ); + i18n( "<qt>Unable to create resource of type <b>%1</b>.</qt>" ).tqarg( type ) ); return; } @@ -414,7 +414,7 @@ void ResourceView::addResource() if ( resource->isActive() && ( !resource->open() || !resource->load() ) ) { // ### There is a resourceLoadError() signal declared in ResourceCalendar // but no subclass seems to make use of it. We could do better. - KMessageBox::error( this, i18n("Unable to create the resource.").arg( type ) ); + KMessageBox::error( this, i18n("Unable to create the resource.").tqarg( type ) ); success = false; } } @@ -477,7 +477,7 @@ void ResourceView::slotSubresourceAdded( ResourceCalendar *resource, { Q_UNUSED( type ); - TQListViewItem *lvitem = mListView->findItem( resource->resourceName(), 0 ); + TQListViewItem *lvitem = mListView->tqfindItem( resource->resourceName(), 0 ); if ( !lvitem ) // Not found return; @@ -573,7 +573,7 @@ void ResourceView::removeResource() i18n ("<qt>Failed to remove the subresource <b>%1</b>. The " "reason could be that it is a built-in one which cannot " "be removed, or that the removal of the underlying storage " - "folder failed.</qt>").arg( item->resource()->name() ) ); + "folder failed.</qt>").tqarg( item->resource()->name() ) ); return; } else { mCalendar->resourceManager()->remove( item->resource() ); @@ -632,7 +632,7 @@ void ResourceView::editResource() } else { KMessageBox::sorry( this, - i18n ("<qt>Cannot edit the subresource <b>%1</b>.</qt>").arg( item->resource()->name() ) ); + i18n ("<qt>Cannot edit the subresource <b>%1</b>.</qt>").tqarg( item->resource()->name() ) ); } } else { KRES::ConfigDialog dlg( this, TQString("calendar"), resource, "KRES::ConfigDialog" ); diff --git a/korganizer/searchdialog.cpp b/korganizer/searchdialog.cpp index 8b79bda1c..03079cc90 100644 --- a/korganizer/searchdialog.cpp +++ b/korganizer/searchdialog.cpp @@ -76,7 +76,7 @@ SearchDialog::SearchDialog(Calendar *calendar,TQWidget *tqparent) mTodosCheck->setChecked( true ); // Date range - TQGroupBox *rangeGroup = new TQGroupBox( 1, Horizontal, i18n( "Date Range" ), + TQGroupBox *rangeGroup = new TQGroupBox( 1, Qt::Horizontal, i18n( "Date Range" ), topFrame ); tqlayout->addWidget( rangeGroup ); @@ -197,9 +197,9 @@ void SearchDialog::search( const TQRegExp &re ) for (it=alltodos.begin(); it!=alltodos.end(); ++it) { todo = *it; if ( (!todo->hasStartDate() && !todo->hasDueDate() ) || // undated - ( todo->hasStartDate() && (todo->dtStart()>=startDt) && (todo->dtStart()<=endDt) ) || // start dt in range - ( todo->hasDueDate() && (todo->dtDue().date()>=startDt) && (todo->dtDue()<=endDt) ) || // due dt in range - ( todo->hasCompletedDate() && (todo->completed().date()>=startDt) && (todo->completed()<=endDt) ) ) { // completed dt in range + ( todo->hasStartDate() && (todo->dtStart()>=TQDateTime(startDt)) && (todo->dtStart()<=TQDateTime(endDt)) ) || // start dt in range + ( todo->hasDueDate() && (todo->dtDue().date()>=startDt) && (todo->dtDue()<=TQDateTime(endDt)) ) || // due dt in range + ( todo->hasCompletedDate() && (todo->completed().date()>=startDt) && (todo->completed()<=TQDateTime(endDt)) ) ) { // completed dt in range todos.append( todo ); } } diff --git a/korn/account_input.cpp b/korn/account_input.cpp index e10f66598..e3cb48f91 100644 --- a/korn/account_input.cpp +++ b/korn/account_input.cpp @@ -65,7 +65,7 @@ TextInput::TextInput( TQWidget *tqparent, const TQString& title, int min, int ma { _left = new TQLabel( title, tqparent, "label" ); _right = new KLineEdit( "", tqparent, "edit" ); - _right->setValidator( new TQIntValidator( min, max, _right, "validator" ) ); + _right->setValidator( new TQIntValidator( min, max, TQT_TQOBJECT(_right), "validator" ) ); setValue( defaul ); } @@ -137,7 +137,7 @@ TQString ComboInput::value() const void ComboInput::setValue( const TQString& value ) { if( _list->tqcontains( value ) ) - _right->setCurrentItem( _list->keys().findIndex( value ) ); + _right->setCurrentItem( _list->keys().tqfindIndex( value ) ); else _right->setCurrentItem( -1 ); } diff --git a/korn/accountmanager.cpp b/korn/accountmanager.cpp index 9c2d3fd4d..5a93ec679 100644 --- a/korn/accountmanager.cpp +++ b/korn/accountmanager.cpp @@ -53,14 +53,14 @@ AccountManager::~AccountManager() void AccountManager::readConfig( KConfig* config, const int index ) { - KConfigGroup *masterGroup = new KConfigGroup( config, TQString( "korn-%1" ).arg( index ) ); + KConfigGroup *masterGroup = new KConfigGroup( config, TQString( "korn-%1" ).tqarg( index ) ); TQStringList dcop = masterGroup->readListEntry( "dcop", ',' ); KConfigGroup *accountGroup; int counter = 0; - while( config->hasGroup( TQString( "korn-%1-%2" ).arg( index ).arg( counter ) ) ) + while( config->hasGroup( TQString( "korn-%1-%2" ).tqarg( index ).tqarg( counter ) ) ) { - accountGroup = new KConfigGroup( config, TQString( "korn-%1-%2" ).arg( index ).arg( counter ) ); + accountGroup = new KConfigGroup( config, TQString( "korn-%1-%2" ).tqarg( index ).tqarg( counter ) ); const Protocol *proto = Protocols::getProto( accountGroup->readEntry( "protocol" ) ); if( !proto ) @@ -144,7 +144,7 @@ void AccountManager::writeConfig( KConfig* config, const int index ) TQMap< KMailDrop*, Dropinfo* >::Iterator it; for( it = _dropInfo->begin(); it != _dropInfo->end(); ++it ) { - config->setGroup( TQString( "korn-%1-%2" ).arg( index ).arg( it.data()->index ) ); + config->setGroup( TQString( "korn-%1-%2" ).tqarg( index ).tqarg( it.data()->index ) ); config->writeEntry( "reset", it.data()->reset ); } } @@ -155,9 +155,9 @@ TQString AccountManager::getTooltip() const TQMap< KMailDrop*, Dropinfo* >::Iterator it; for( it = _dropInfo->begin(); it != _dropInfo->end(); ++it ) if( it.key()->valid() ) - result.append( TQString( "%1: %2" ).arg( it.key()->realName() ).arg( it.data()->msgnr - it.data()->reset )); + result.append( TQString( "%1: %2" ).tqarg( it.key()->realName() ).tqarg( it.data()->msgnr - it.data()->reset )); else - result.append( TQString( "%1: invalid" ).arg( it.key()->realName() ) ); + result.append( TQString( "%1: invalid" ).tqarg( it.key()->realName() ) ); result.sort(); return result.join( TQChar( '\n' ) ); } diff --git a/korn/boxcontainer.cpp b/korn/boxcontainer.cpp index e8649d13a..4f8312177 100644 --- a/korn/boxcontainer.cpp +++ b/korn/boxcontainer.cpp @@ -39,9 +39,9 @@ BoxContainer::~BoxContainer() void BoxContainer::readConfig( KConfig* config ) { int counter = 0; - while( config->hasGroup( TQString( "korn-%1" ).arg( counter ) ) ) + while( config->hasGroup( TQString( "korn-%1" ).tqarg( counter ) ) ) { - config->setGroup( TQString( "korn-%1" ).arg( counter ) ); + config->setGroup( TQString( "korn-%1" ).tqarg( counter ) ); BoxContainerItem *item = newBoxInstance(); item->readConfig( config, counter ); addItem( item ); diff --git a/korn/boxcontaineritem.cpp b/korn/boxcontaineritem.cpp index c357fd4f4..1f4be46a2 100644 --- a/korn/boxcontaineritem.cpp +++ b/korn/boxcontaineritem.cpp @@ -81,7 +81,7 @@ BoxContainerItem::~BoxContainerItem() void BoxContainerItem::readConfig( KConfig* config, const int index ) { //Read information about how the thing have to look like - config->setGroup( TQString( "korn-%1" ).arg( index ) ); + config->setGroup( TQString( "korn-%1" ).tqarg( index ) ); if( config->readBoolEntry( "hasnormalicon", false ) ) _icons[ 0 ] = new TQString( config->readEntry( "normalicon", "" ) ); else @@ -171,11 +171,11 @@ void BoxContainerItem::runCommand( const TQString& cmd ) void BoxContainerItem::mouseButtonPressed( TQt::ButtonState state ) { int button; - if( state & TQt::LeftButton ) + if( state & Qt::LeftButton ) button = 0; - else if( state & TQt::RightButton ) + else if( state & Qt::RightButton ) button = 2; - else if( state & TQt::MidButton ) + else if( state & Qt::MidButton ) button = 1; else return; //Invalid mouse button @@ -216,8 +216,8 @@ void BoxContainerItem::showPassivePopup( TQWidget* tqparent, TQPtrList< KornMail { KPassivePopup *popup = new KPassivePopup( tqparent, "Passive popup" ); - TQVBox *mainvtqlayout = popup->standardView( i18n( "KOrn - %1/%2 (total: %3)" ).arg( objId() ).arg( accountName ) - .arg( total ), "", TQPixmap(), 0 ); + TQVBox *mainvtqlayout = popup->standardView( i18n( "KOrn - %1/%2 (total: %3)" ).tqarg( TQString(objId()) ).tqarg( accountName ) + .tqarg( total ), "", TQPixmap(), 0 ); TQGrid *maingtqlayout = new TQGrid( date ? 3 : 2 ,mainvtqlayout, "Grid-Layout" ); TQLabel *title = new TQLabel( i18n("From"), maingtqlayout, "from_label" ); @@ -339,7 +339,7 @@ TQPixmap BoxContainerItem::calcComplexPixmap( const TQPixmap &icon, const TQColo //Make a transparent number; first make a white number on a black background. //This pixmap also is the base alpha-channel, the foreground colour is added later. numberPixmap.fill( TQt::black ); - p.begin( &numberPixmap, false ); + p.tqbegin( &numberPixmap, false ); p.setPen( TQt::white ); if( font ) p.setFont( *font ); diff --git a/korn/dcopdrop.cpp b/korn/dcopdrop.cpp index 03c0db430..9cc4a9f05 100644 --- a/korn/dcopdrop.cpp +++ b/korn/dcopdrop.cpp @@ -159,7 +159,7 @@ int DCOPDrop::addMessage( const TQString& subject, const TQString& message ) ++_counter; mailsubject->setSubject( subject ); - mailsubject->setSender( TQString( "DCOP: %1" ).arg( *_name ) ); + mailsubject->setSender( TQString( "DCOP: %1" ).tqarg( *_name ) ); mailsubject->setHeader( message, true ); mailsubject->setSize( message.length() ); mailsubject->setDate( TQDateTime::tqcurrentDateTime().toTime_t() ); diff --git a/korn/dockeditem.cpp b/korn/dockeditem.cpp index 9849155f1..dc55b3c08 100644 --- a/korn/dockeditem.cpp +++ b/korn/dockeditem.cpp @@ -37,7 +37,7 @@ #include <tqmovie.h> DockedItem::DockedItem( TQWidget * tqparent, const char * name ) - : BoxContainerItem( tqparent, name ), + : BoxContainerItem( TQT_TQOBJECT(tqparent), name ), _systemtray( new SystemTray( tqparent, "System tray" ) ) { this->fillKPopupMenu( _systemtray->contextMenu(), _systemtray->actionCollection() ); @@ -81,7 +81,7 @@ void DockedItem::slotShowPassivePopup( TQPtrList< KornMailSubject >* list, int t void DockedItem::slotShowPassivePopup( const TQString& message, const TQString& name ) { - KPassivePopup::message( i18n( "Korn - %1/%2" ).arg( objId() ).arg( name ), message, _systemtray, "Passive error message" ); + KPassivePopup::message( i18n( "Korn - %1/%2" ).tqarg( TQString(objId()) ).tqarg( name ), message, _systemtray, "Passive error message" ); } void DockedItem::doPopup() diff --git a/korn/hvcontainer.cpp b/korn/hvcontainer.cpp index 991f66eb0..636a9a8fc 100644 --- a/korn/hvcontainer.cpp +++ b/korn/hvcontainer.cpp @@ -28,7 +28,7 @@ HVContainer::HVContainer( Qt::Orientation orientation, TQObject * tqparent, cons : BoxContainer( tqparent, name ), box( 0 ) { - if( orientation == TQt::Horizontal ) + if( orientation == Qt::Horizontal ) box = new TQHBox( 0, "hbox" ); else box = new TQVBox( 0, "vbox" ); diff --git a/korn/hvitem.cpp b/korn/hvitem.cpp index 36551ae11..bc47e9e77 100644 --- a/korn/hvitem.cpp +++ b/korn/hvitem.cpp @@ -39,7 +39,7 @@ HVItem::HVItem( TQWidget *tqparent, const char *name ) _popup->insertTitle( kapp->miniIcon(), kapp->caption() ); this->fillKPopupMenu( _popup, _actions ); _popup->insertSeparator(); - KStdAction::quit( kapp, TQT_SLOT( quit() ), _actions )->plug( _popup ); + KStdAction::quit( TQT_TQOBJECT(kapp), TQT_SLOT( quit() ), _actions )->plug( _popup ); connect( _label, TQT_SIGNAL( mouseButtonPressed( TQt::ButtonState ) ), this, TQT_SLOT( mouseButtonPressed( TQt::ButtonState ) ) ); } @@ -71,7 +71,7 @@ void HVItem::slotShowPassivePopup( TQPtrList< KornMailSubject >* list, int total void HVItem::slotShowPassivePopup( const TQString& errorMessage, const TQString& name ) { - KPassivePopup::message( TQString( "korn-%1-%2" ).arg( objId() ).arg( name ), errorMessage, _label, "Passive error message" ); + KPassivePopup::message( TQString( "korn-%1-%2" ).tqarg( TQString(objId()) ).tqarg( name ), errorMessage, _label, "Passive error message" ); } void HVItem::doPopup() diff --git a/korn/imap_proto.cpp b/korn/imap_proto.cpp index 78a42b685..7d0f9873a 100644 --- a/korn/imap_proto.cpp +++ b/korn/imap_proto.cpp @@ -68,9 +68,9 @@ void Imap_Protocol::readEntries( TQMap< TQString, TQString >* map, TQMap< TQStri if( map->tqcontains( "ssl" ) && *map->tqfind( "ssl" ) == "true" ) map->insert( "encryption", "ssl" ); if( metadata->tqcontains( "tls" ) ) - map->insert( "encryption", TQString( "tls=%1" ).arg( *metadata->tqfind( "tls" ) ) ); + map->insert( "encryption", TQString( "tls=%1" ).tqarg( *metadata->tqfind( "tls" ) ) ); if( metadata->tqcontains( "auth" ) ) - map->insert( "auth", TQString( "auth=%1" ).arg( *metadata->tqfind( "auth" ) ) ); + map->insert( "auth", TQString( "auth=%1" ).tqarg( *metadata->tqfind( "auth" ) ) ); } void Imap_Protocol::writeEntries( TQMap< TQString, TQString >* map ) const diff --git a/korn/kconf_update/korn-3-4-config_change.cpp b/korn/kconf_update/korn-3-4-config_change.cpp index 0cea4577d..4d0c46679 100644 --- a/korn/kconf_update/korn-3-4-config_change.cpp +++ b/korn/kconf_update/korn-3-4-config_change.cpp @@ -175,8 +175,8 @@ int main( int, char** ) { if( numboxes > -1 && interesting_group.cap( 1 ).toInt() < numboxes ) { - currentGroup1 = TQString( "[korn-%1]" ).arg( interesting_group.cap( 1 ) ); - currentGroup2 = TQString( "[korn-%1-0]" ).arg( interesting_group.cap( 1 ) ); + currentGroup1 = TQString( "[korn-%1]" ).tqarg( interesting_group.cap( 1 ) ); + currentGroup2 = TQString( "[korn-%1-0]" ).tqarg( interesting_group.cap( 1 ) ); } tobe_deleted.append( line ); continue; diff --git a/korn/keditlistboxman.cpp b/korn/keditlistboxman.cpp index cb3066727..44ef514c4 100644 --- a/korn/keditlistboxman.cpp +++ b/korn/keditlistboxman.cpp @@ -109,9 +109,9 @@ void KEditListBoxManager::readNames() int number = 0; this->clear(); - while( _config->hasGroup( _groupName->arg( number ) ) ) + while( _config->hasGroup( _groupName->tqarg( number ) ) ) { - _config->setGroup( _groupName->arg( number ) ); + _config->setGroup( _groupName->tqarg( number ) ); this->insertItem( _config->readEntry( "name", TQString() ) ); ++number; } @@ -138,7 +138,7 @@ void KEditListBoxManager::slotChanged() //First check if the item was moved up - _config->setGroup( _groupName->arg( this->currentItem() ) ); + _config->setGroup( _groupName->tqarg( this->currentItem() ) ); if( this->currentItem() > 0 && this->text( this->currentItem() - 1 ) == _config->readEntry( "name", TQString() ) ) changeItem( this->currentItem() - 1, this->currentItem() ); //moved down @@ -158,10 +158,10 @@ void KEditListBoxManager::slotAdded( const TQString& name ) return; int number = 0; - while( _config->hasGroup( _groupName->arg( number ) ) ) + while( _config->hasGroup( _groupName->tqarg( number ) ) ) ++number; - _config->setGroup( _groupName->arg( number ) ); + _config->setGroup( _groupName->tqarg( number ) ); _config->writeEntry( "name", name ); emit setDefaults( name, number, _config ); @@ -180,12 +180,12 @@ void KEditListBoxManager::slotRemoved( const TQString& name ) int subnumber = 0; while( true ) { - if( !_config->hasGroup( _groupName->arg( number ) ) ) + if( !_config->hasGroup( _groupName->tqarg( number ) ) ) { number = -1; //not found break; } - _config->setGroup( _groupName->arg( number ) ); + _config->setGroup( _groupName->tqarg( number ) ); if( name == _config->readEntry( "name", TQString() ) ) break; //found @@ -195,16 +195,16 @@ void KEditListBoxManager::slotRemoved( const TQString& name ) if( number < 0 ) //failure return; //do nothing - _config->deleteGroup( _groupName->arg( number ), true, false ); + _config->deleteGroup( _groupName->tqarg( number ), true, false ); emit elementDeleted( number ); - while( _subGroupName && _config->hasGroup( _subGroupName->arg( number ).arg( subnumber ) ) ) + while( _subGroupName && _config->hasGroup( _subGroupName->tqarg( number ).tqarg( subnumber ) ) ) { - _config->deleteGroup( _subGroupName->arg( number ).arg( subnumber ) ); + _config->deleteGroup( _subGroupName->tqarg( number ).tqarg( subnumber ) ); ++subnumber; } //rotate groups - while( _config->hasGroup( _groupName->arg( number + 1 ) ) ) + while( _config->hasGroup( _groupName->tqarg( number + 1 ) ) ) { moveItem( number + 1, number ); @@ -224,17 +224,17 @@ void KEditListBoxManager::moveItem( int src, int dest ) TQMap<TQString, TQString>::iterator it; int subnumber = 0; - *srcList = _config->entryMap( _groupName->arg( src ) ); - _config->deleteGroup( _groupName->arg( src ) ); + *srcList = _config->entryMap( _groupName->tqarg( src ) ); + _config->deleteGroup( _groupName->tqarg( src ) ); - _config->setGroup( _groupName->arg( dest ) ); + _config->setGroup( _groupName->tqarg( dest ) ); for( it = srcList->begin(); it != srcList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); - while( _subGroupName && _config->hasGroup( _subGroupName->arg( src ).arg( subnumber ) ) ) + while( _subGroupName && _config->hasGroup( _subGroupName->tqarg( src ).tqarg( subnumber ) ) ) { - _config->deleteGroup( _subGroupName->arg( dest ).arg( subnumber ) ); - _config->setGroup( _subGroupName->arg( dest ).arg( subnumber ) ); + _config->deleteGroup( _subGroupName->tqarg( dest ).tqarg( subnumber ) ); + _config->setGroup( _subGroupName->tqarg( dest ).tqarg( subnumber ) ); for( it = srcList->begin(); it != srcList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); @@ -253,33 +253,33 @@ void KEditListBoxManager::changeItem( int first, int last ) TQMap<TQString, TQString>::iterator it; int subnumber = 0; - *firstList = _config->entryMap( _groupName->arg( first ) ); - *lastList = _config->entryMap( _groupName->arg( last ) ); - _config->deleteGroup( _groupName->arg( first ) ); - _config->deleteGroup( _groupName->arg( last ) ); + *firstList = _config->entryMap( _groupName->tqarg( first ) ); + *lastList = _config->entryMap( _groupName->tqarg( last ) ); + _config->deleteGroup( _groupName->tqarg( first ) ); + _config->deleteGroup( _groupName->tqarg( last ) ); - _config->setGroup( _groupName->arg( last ) ); + _config->setGroup( _groupName->tqarg( last ) ); for( it = firstList->begin(); it != firstList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); - _config->setGroup( _groupName->arg( first ) ); + _config->setGroup( _groupName->tqarg( first ) ); for( it = lastList->begin(); it != lastList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); while( _subGroupName && ( - _config->hasGroup( _subGroupName->arg( first ).arg( subnumber ) ) || - _config->hasGroup( _subGroupName->arg( last ).arg( subnumber ) ) ) ) + _config->hasGroup( _subGroupName->tqarg( first ).tqarg( subnumber ) ) || + _config->hasGroup( _subGroupName->tqarg( last ).tqarg( subnumber ) ) ) ) { - *firstList = _config->entryMap( _subGroupName->arg( first ).arg( subnumber ) ); - *lastList = _config->entryMap( _subGroupName->arg( last ).arg( subnumber ) ); - _config->deleteGroup( _subGroupName->arg( first ).arg( subnumber ) ); - _config->deleteGroup( _subGroupName->arg( last ).arg( subnumber ) ); + *firstList = _config->entryMap( _subGroupName->tqarg( first ).tqarg( subnumber ) ); + *lastList = _config->entryMap( _subGroupName->tqarg( last ).tqarg( subnumber ) ); + _config->deleteGroup( _subGroupName->tqarg( first ).tqarg( subnumber ) ); + _config->deleteGroup( _subGroupName->tqarg( last ).tqarg( subnumber ) ); - _config->setGroup( _subGroupName->arg( last ).arg( subnumber ) ); + _config->setGroup( _subGroupName->tqarg( last ).tqarg( subnumber ) ); for( it = firstList->begin(); it != firstList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); - _config->setGroup( _subGroupName->arg( first ).arg( subnumber ) ); + _config->setGroup( _subGroupName->tqarg( first ).tqarg( subnumber ) ); for( it = lastList->begin(); it != lastList->end(); ++it ) _config->writeEntry( it.key(), it.data() ); @@ -294,7 +294,7 @@ void KEditListBoxManager::changeItem( int first, int last ) void KEditListBoxManager::changedText() { - _config->setGroup( _groupName->arg( this->currentItem() ) ); + _config->setGroup( _groupName->tqarg( this->currentItem() ) ); _config->writeEntry( "name", this->currentText() ); } diff --git a/korn/kio_count.cpp b/korn/kio_count.cpp index 683f88291..faac9390b 100644 --- a/korn/kio_count.cpp +++ b/korn/kio_count.cpp @@ -86,8 +86,8 @@ void KIO_Count::count( KKioDrop *drop ) if( ! ( _slave = KIO::Scheduler::getConnectedSlave( kurl, metadata ) ) ) //Forcing reload { - kdWarning() << i18n( "Not able to open a kio slave for %1." ).arg( _protocol->configName() ) << endl; - _kio->emitShowPassivePopup( i18n( "Not able to open a kio slave for %1." ).arg( _protocol->configName() ) ); + kdWarning() << i18n( "Not able to open a kio slave for %1." ).tqarg( _protocol->configName() ) << endl; + _kio->emitShowPassivePopup( i18n( "Not able to open a kio slave for %1." ).tqarg( _protocol->configName() ) ); _valid = false; _kio->emitValidChanged(); _slave = 0; @@ -207,8 +207,8 @@ void KIO_Count::result( KIO::Job* job ) //This could be very useful by resolving bugs. if( job->error() ) { - kdError() << i18n( "The next KIO-error occurred by counting: %1" ).arg( job->errorString() ) << endl; - _kio->emitShowPassivePopup( i18n( "The next KIO-error occurred by counting: %1" ).arg( job->errorString() ) ); + kdError() << i18n( "The next KIO-error occurred by counting: %1" ).tqarg( job->errorString() ) << endl; + _kio->emitShowPassivePopup( i18n( "The next KIO-error occurred by counting: %1" ).tqarg( job->errorString() ) ); _valid = false; _kio->emitValidChanged(); } diff --git a/korn/kio_delete.cpp b/korn/kio_delete.cpp index fa31ad750..b506f0b2c 100644 --- a/korn/kio_delete.cpp +++ b/korn/kio_delete.cpp @@ -182,7 +182,7 @@ void KIO_Delete::slotResult( KIO::Job* job ) { if( job->error() ) { - kdWarning() << i18n( "An error occurred when deleting email: %1." ).arg( job->errorString() ) << endl; + kdWarning() << i18n( "An error occurred when deleting email: %1." ).tqarg( job->errorString() ) << endl; _valid = false; } diff --git a/korn/kio_read.cpp b/korn/kio_read.cpp index e87fa822e..840c09f27 100644 --- a/korn/kio_read.cpp +++ b/korn/kio_read.cpp @@ -77,7 +77,7 @@ void KIO_Read::slotResult( KIO::Job* job ) kdWarning() << i18n( "Unknown job returned; I will try if this one will do... " ) << endl; if( job->error() ) - kdWarning() << i18n( "An error occurred when fetching the requested email: %1." ).arg( job->errorString() ) << endl; + kdWarning() << i18n( "An error occurred when fetching the requested email: %1." ).tqarg( job->errorString() ) << endl; _kio->emitReadMailReady( _message ); diff --git a/korn/kio_single_subject.cpp b/korn/kio_single_subject.cpp index 782b1bde9..7d6e87987 100644 --- a/korn/kio_single_subject.cpp +++ b/korn/kio_single_subject.cpp @@ -138,7 +138,7 @@ void KIO_Single_Subject::slotResult( KIO::Job *job ) if( job->error() ) { - kdWarning() << i18n( "Error when fetching %1: %2" ).arg( *_name ).arg( job->errorString() ) << endl; + kdWarning() << i18n( "Error when fetching %1: %2" ).tqarg( *_name ).tqarg( job->errorString() ) << endl; } else { KornMailSubject * mailSubject = new KornMailSubject( new KornStringId( *_name ), 0 ); parseMail( _message, mailSubject, _protocol->fullMessage() ); diff --git a/korn/kio_single_subject.h b/korn/kio_single_subject.h index 9057a09e1..800638cb6 100644 --- a/korn/kio_single_subject.h +++ b/korn/kio_single_subject.h @@ -22,6 +22,7 @@ //This function reads a single subject #include <tqobject.h> +#include <tqcstring.h> class KornMailSubject; @@ -30,8 +31,6 @@ namespace KIO { class MetaData; class Job; class TransferJob; class Slave; } class KIO_Protocol; class TQString; -template<class T> class TQMemArray; -typedef TQMemArray<char> TQByteArray; class KIO_Single_Subject : public TQObject { Q_OBJECT diff --git a/korn/kio_subjects.cpp b/korn/kio_subjects.cpp index ae0ab8fd2..91da7a823 100644 --- a/korn/kio_subjects.cpp +++ b/korn/kio_subjects.cpp @@ -101,8 +101,8 @@ void KIO_Subjects::getConnection( ) if( ! ( _slave = KIO::Scheduler::getConnectedSlave( kurl, metadata ) ) ) { - kdWarning() << i18n( "Not able to open a kio-slave for %1." ).arg( _protocol->configName() ); - _kio->emitShowPassivePopup( i18n( "Not able to open a kio-slave for %1." ).arg( _protocol->configName() ) ); + kdWarning() << i18n( "Not able to open a kio-slave for %1." ).tqarg( _protocol->configName() ); + _kio->emitShowPassivePopup( i18n( "Not able to open a kio-slave for %1." ).tqarg( _protocol->configName() ) ); _valid = false; _kio->emitValidChanged(); _slave = 0; diff --git a/korn/kmail_proto.cpp b/korn/kmail_proto.cpp index fb6166c31..1ff68213b 100644 --- a/korn/kmail_proto.cpp +++ b/korn/kmail_proto.cpp @@ -99,7 +99,7 @@ TQMap< TQString, TQString > * KMail_Protocol::createConfig( KConfigGroup* config { //Construct metadata if( kmailconfig.hasKey( "auth" ) ) - metadata += TQString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) ); + metadata += TQString( "auth=%1," ).tqarg( kmailconfig.readEntry( "auth" ) ); if( !kmailconfig.hasKey( "use-tls" ) ) metadata += "tls=auto"; else @@ -124,7 +124,7 @@ TQMap< TQString, TQString > * KMail_Protocol::createConfig( KConfigGroup* config { //Constructing metadata if( kmailconfig.hasKey( "auth" ) ) - metadata += TQString( "auth=%1," ).arg( kmailconfig.readEntry( "auth" ) ); + metadata += TQString( "auth=%1," ).tqarg( kmailconfig.readEntry( "auth" ) ); if( !kmailconfig.hasKey( "use-tls" ) ) metadata += "tls=auto"; else @@ -185,9 +185,9 @@ void KMail_Protocol::configFields( TQPtrVector< TQWidget >* vector, const TQObje int nummer = kmailFirstGroup - 1; KConfig kmailconfig( "kmailrc", true, false ); - while( kmailconfig.hasGroup( TQString( kmailGroupName ).arg( ++nummer ) ) ) + while( kmailconfig.hasGroup( TQString( kmailGroupName ).tqarg( ++nummer ) ) ) { - kmailconfig.setGroup( TQString( kmailGroupName ).arg( nummer ) ); + kmailconfig.setGroup( TQString( kmailGroupName ).tqarg( nummer ) ); type = kmailconfig.readEntry( kmailKeyType, TQString() ); name = kmailconfig.readEntry( kmailKeyName, TQString() ); if( type == "imap" || type == "cachedimap" || type == "pop" || type == "local" ) @@ -224,9 +224,9 @@ TQString KMail_Protocol::getTypeAndConfig( const TQString& kmailname, KConfig &k id = -1; - while( kmailconfig.hasGroup( TQString( kmailGroupName ).arg( ++nummer ) ) ) + while( kmailconfig.hasGroup( TQString( kmailGroupName ).tqarg( ++nummer ) ) ) { - kmailconfig.setGroup( TQString( kmailGroupName ).arg( nummer ) ); + kmailconfig.setGroup( TQString( kmailGroupName ).tqarg( nummer ) ); if( kmailconfig.readEntry( kmailKeyName, TQString() ) == kmailname ) { id = kmailconfig.readNumEntry( kmailKeyId, 0 ); diff --git a/korn/kornaccountcfgimpl.cpp b/korn/kornaccountcfgimpl.cpp index 0346f3e8a..149fd55b0 100644 --- a/korn/kornaccountcfgimpl.cpp +++ b/korn/kornaccountcfgimpl.cpp @@ -195,7 +195,7 @@ void KornAccountCfgImpl::slotProtocolChanged( const TQString& proto ) delete groupBoxes; AccountInput *input; - protocol->configFields( _groupBoxes, this, _accountinput ); + protocol->configFields( _groupBoxes, TQT_TQOBJECT(this), _accountinput ); for( unsigned int groupCounter = 0; groupCounter < _groupBoxes->count(); ++groupCounter ) { @@ -205,14 +205,14 @@ void KornAccountCfgImpl::slotProtocolChanged( const TQString& proto ) grid->setMargin( 15 ); for( input = _accountinput->first(); input; input = _accountinput->next() ) { - if( input->leftWidget() && _groupBoxes->at( groupCounter ) == input->leftWidget()->tqparent() ) + if( input->leftWidget() && TQT_BASE_OBJECT(_groupBoxes->at( groupCounter )) == TQT_BASE_OBJECT(input->leftWidget()->tqparent()) ) { grid->addWidget( input->leftWidget(), counter, 0 ); - if( input->rightWidget() && _groupBoxes->at( groupCounter ) == input->rightWidget()->tqparent() ) + if( input->rightWidget() && TQT_BASE_OBJECT(_groupBoxes->at( groupCounter )) == TQT_BASE_OBJECT(input->rightWidget()->tqparent()) ) grid->addWidget( input->rightWidget(), counter, 1 ); ++counter; } else { - if( input->rightWidget() && _groupBoxes->at( groupCounter ) == input->rightWidget()->tqparent() ) + if( input->rightWidget() && TQT_BASE_OBJECT(_groupBoxes->at( groupCounter )) == TQT_BASE_OBJECT(input->rightWidget()->tqparent()) ) { grid->addWidget( input->rightWidget(), counter, 1 ); ++counter; diff --git a/korn/kornboxcfgimpl.cpp b/korn/kornboxcfgimpl.cpp index 58ffd4daf..ff6b034fd 100644 --- a/korn/kornboxcfgimpl.cpp +++ b/korn/kornboxcfgimpl.cpp @@ -78,7 +78,7 @@ void KornBoxCfgImpl::readConfig( KConfig * config, const int index ) _config = config; _index = index; - _config->setGroup( TQString( "korn-%1" ).arg( index ) ); + _config->setGroup( TQString( "korn-%1" ).tqarg( index ) ); readViewConfig(); readEventConfig(); @@ -88,7 +88,7 @@ void KornBoxCfgImpl::readConfig( KConfig * config, const int index ) void KornBoxCfgImpl::writeConfig( KConfig * config, const int index ) { - config->setGroup( TQString( "korn-%1" ).arg( index ) ); + config->setGroup( TQString( "korn-%1" ).tqarg( index ) ); writeViewConfig( config ); writeEventConfig( config ); @@ -155,7 +155,7 @@ void KornBoxCfgImpl::readEventConfig() void KornBoxCfgImpl::readAccountsConfig() { - elbAccounts->setGroupName( TQString( "korn-%1-%2" ).arg( _index ) ); + elbAccounts->setGroupName( TQString( "korn-%1-%2" ).tqarg( _index ) ); elbAccounts->setConfig( _config ); } @@ -250,10 +250,10 @@ void KornBoxCfgImpl::slotEditBox() connect( _base, TQT_SIGNAL( finished() ), this, TQT_SLOT( slotDialogDestroyed() ) ); _group = new KConfigGroup( _config, TQString( "korn-%1-%2" ). - arg( _index ).arg(elbAccounts->listBox()->currentItem() ) ); + tqarg( _index ).tqarg(elbAccounts->listBox()->currentItem() ) ); TQMap< TQString, TQString > *map = new TQMap< TQString, TQString >( _config->entryMap( TQString( "korn-%1-%2" ). - arg( _index ).arg(elbAccounts->listBox()->currentItem() ) ) ); + tqarg( _index ).tqarg(elbAccounts->listBox()->currentItem() ) ) ); widget->readConfig( _group, map, _index, elbAccounts->listBox()->currentItem() ); delete map; diff --git a/korn/korncfgimpl.cpp b/korn/korncfgimpl.cpp index 487c48ba2..219cbcc0f 100644 --- a/korn/korncfgimpl.cpp +++ b/korn/korncfgimpl.cpp @@ -91,10 +91,10 @@ void KornCfgImpl::slotDialogDestroyed() void KornCfgImpl::slotElementsSwapped( int box1, int box2 ) { int accountnumber1 = 0, accountnumber2 = 0; - while( _config->hasGroup( TQString( "korn-%1-%2" ).arg( box1 ).arg( accountnumber1 ) ) ) + while( _config->hasGroup( TQString( "korn-%1-%2" ).tqarg( box1 ).tqarg( accountnumber1 ) ) ) ++accountnumber1; - while( _config->hasGroup( TQString( "korn-%1-%2" ).arg( box2 ).arg( accountnumber2 ) ) ) + while( _config->hasGroup( TQString( "korn-%1-%2" ).tqarg( box2 ).tqarg( accountnumber2 ) ) ) ++accountnumber2; KOrnPassword::swapKOrnWalletPasswords( box1, accountnumber1, box2, accountnumber2 ); @@ -103,7 +103,7 @@ void KornCfgImpl::slotElementsSwapped( int box1, int box2 ) void KornCfgImpl::slotElementDeleted( int box ) { int accountnumber = 0; - while( _config->hasGroup( TQString( "korn-%1-%2" ).arg( box ).arg( accountnumber ) ) ) + while( _config->hasGroup( TQString( "korn-%1-%2" ).tqarg( box ).tqarg( accountnumber ) ) ) { KOrnPassword::deleteKOrnPassword( box, accountnumber ); ++accountnumber; @@ -161,7 +161,7 @@ void KornCfgImpl::slotSetDefaults( const TQString& name, const int index, KConfi config->writeEntry( "passivedate", false ); config->writeEntry( "numaccounts", 1 ); config->writeEntry( "dcop", TQStringList() ); - config->setGroup( TQString( "korn-%1-0" ).arg( index ) ); + config->setGroup( TQString( "korn-%1-0" ).tqarg( index ) ); config->writeEntry( "name", name ); config->writeEntry( "protocol", "mbox" ); config->writeEntry( "server", TQString() ); @@ -236,12 +236,12 @@ void KornCfgImpl::rewritePasswords() int account = 0 - 1; KConfigGroup *group; - while( _config->hasGroup( TQString( "korn-%1" ).arg( ++box ) ) ) + while( _config->hasGroup( TQString( "korn-%1" ).tqarg( ++box ) ) ) { account = 0 - 1; - while( _config->hasGroup( TQString( "korn-%1-%2" ).arg( box ).arg( ++account ) ) ) + while( _config->hasGroup( TQString( "korn-%1-%2" ).tqarg( box ).tqarg( ++account ) ) ) { - group = new KConfigGroup( _config, TQString( "korn-%1-%2" ).arg( box ).arg( account ) ); + group = new KConfigGroup( _config, TQString( "korn-%1-%2" ).tqarg( box ).tqarg( account ) ); KOrnPassword::rewritePassword( box, account, *group, chUseWallet->isChecked() ); delete group; } diff --git a/korn/kornshell.cpp b/korn/kornshell.cpp index f7d30358f..78db0b256 100644 --- a/korn/kornshell.cpp +++ b/korn/kornshell.cpp @@ -99,11 +99,11 @@ void KornShell::readConfig() KOrnPassword::setUseWallet( _config->readBoolEntry( "usewallet", false ) ); if( tqlayout == 'H' ) - _box = new HVContainer( TQt::Horizontal, this, "horizontal container" ); + _box = new HVContainer( Qt::Horizontal, TQT_TQOBJECT(this), "horizontal container" ); else if( tqlayout == 'V' ) - _box = new HVContainer( TQt::Vertical, this, "vertical container" ); + _box = new HVContainer( Qt::Vertical, TQT_TQOBJECT(this), "vertical container" ); else - _box = new DockedContainer( this, "docked container" ); + _box = new DockedContainer( TQT_TQOBJECT(this), "docked container" ); connect( _box, TQT_SIGNAL( showConfiguration() ), this, TQT_SLOT( optionDlg() ) ); diff --git a/korn/maildrop.cpp b/korn/maildrop.cpp index 9d2f12f67..d0818962c 100644 --- a/korn/maildrop.cpp +++ b/korn/maildrop.cpp @@ -40,10 +40,10 @@ KMailDrop::KMailDrop() connect(this, TQT_SIGNAL(changed( int, KMailDrop* )), TQT_SLOT(setCount( int, KMailDrop* ))); //Set default colours; this prevents black (TQColor::invalid) boxes after creating a new box. - _bgColour = TQApplication::palette().active().background(); - _fgColour = TQApplication::palette().active().text(); - _nbgColour = TQApplication::palette().active().background(); - _nfgColour = TQApplication::palette().active().text(); + _bgColour = TQApplication::tqpalette().active().background(); + _fgColour = TQApplication::tqpalette().active().text(); + _nbgColour = TQApplication::tqpalette().active().background(); + _nfgColour = TQApplication::tqpalette().active().text(); } KMailDrop::~KMailDrop() @@ -87,10 +87,10 @@ bool KMailDrop::readConfigGroup(const KConfigBase & c) _caption = c.readEntry(fu(CaptionConfigKey)); _clickCmd = c.readPathEntry(fu(ClickConfigKey)); _style = Style(c.readUnsignedNumEntry(fu(DisplayStyleConfigKey), Plain)); - _bgColour = c.readColorEntry(fu(BgColourConfigKey), &TQApplication::palette().active().background()); - _fgColour = c.readColorEntry(fu(FgColourConfigKey), &TQApplication::palette().active().text()); - _nbgColour = c.readColorEntry(fu(NBgColourConfigKey), &TQApplication::palette().active().background()); - _nfgColour = c.readColorEntry(fu(NFgColourConfigKey), &TQApplication::palette().active().text()); + _bgColour = c.readColorEntry(fu(BgColourConfigKey), &TQApplication::tqpalette().active().background()); + _fgColour = c.readColorEntry(fu(FgColourConfigKey), &TQApplication::tqpalette().active().text()); + _nbgColour = c.readColorEntry(fu(NBgColourConfigKey), &TQApplication::tqpalette().active().background()); + _nfgColour = c.readColorEntry(fu(NFgColourConfigKey), &TQApplication::tqpalette().active().text()); _icon = c.readEntry(fu(IconConfigKey)); _nIcon = c.readEntry(fu(NewMailIconConfigKey)); _realName = c.readEntry(fu(RealNameConfigKey)); diff --git a/korn/mailsubject.cpp b/korn/mailsubject.cpp index b71205b14..ee675906f 100644 --- a/korn/mailsubject.cpp +++ b/korn/mailsubject.cpp @@ -54,7 +54,7 @@ TQString KornMailSubject::toString() const date.setTime_t(_date); return TQString("KornMailSubject, Id: ") + (_id?_id->toString():TQString("NULL")) + ", " + i18n("Subject:") + " " + _subject + ", " + i18n("Sender:") + " " + _sender + ", " + i18n("Size:") + " " + TQString::number(_size) - + ", " + i18n("Date:") + " " + date.toString(TQt::ISODate); + + ", " + i18n("Date:") + " " + date.toString(Qt::ISODate); } TQString KornMailSubject::decodeRFC2047String(const TQCString& aStr) diff --git a/korn/password.cpp b/korn/password.cpp index f0ae5d8f3..bc997d51a 100644 --- a/korn/password.cpp +++ b/korn/password.cpp @@ -52,7 +52,7 @@ TQString KOrnPassword::readKMailPassword( int accountnr, const KConfigBase& fall return KMailDecrypt( fallbackConfig.readEntry( "pass" )); m_wallet->setFolder( "kmail" ); - if( m_wallet->readPassword( TQString( "account-%1" ).arg( accountnr ), password ) != 0 ) + if( m_wallet->readPassword( TQString( "account-%1" ).tqarg( accountnr ), password ) != 0 ) return fallbackConfig.readEntry( "password" ); return password; @@ -95,7 +95,7 @@ bool KOrnPassword::deleteKOrnPassword( int box, int account ) m_wallet->setFolder( "korn" ); //Write to wallet - if( m_wallet->removeEntry( TQString( "account-%1-%2" ).arg( box ).arg( account ) ) != 0 ) + if( m_wallet->removeEntry( TQString( "account-%1-%2" ).tqarg( box ).tqarg( account ) ) != 0 ) //Writing failed return false; @@ -201,7 +201,7 @@ bool KOrnPassword::readKOrnPassword( int box, int account, TQString& password ) return false; m_wallet->setFolder( "korn" ); - if( m_wallet->readPassword( TQString( "account-%1-%2" ).arg( box ).arg( account ), password ) != 0 ) + if( m_wallet->readPassword( TQString( "account-%1-%2" ).tqarg( box ).tqarg( account ), password ) != 0 ) //Error during reading the password: use the one in the config file return false; @@ -228,7 +228,7 @@ bool KOrnPassword::writeKOrnPassword( int box, int account, const TQString& pass m_wallet->setFolder( "korn" ); //Write to wallet - if( m_wallet->writePassword( TQString( "account-%1-%2" ).arg( box ).arg( account ), password ) != 0 ) + if( m_wallet->writePassword( TQString( "account-%1-%2" ).tqarg( box ).tqarg( account ), password ) != 0 ) //Writing failed return false; diff --git a/korn/pop3_proto.cpp b/korn/pop3_proto.cpp index e97fd82ce..c42076426 100644 --- a/korn/pop3_proto.cpp +++ b/korn/pop3_proto.cpp @@ -67,7 +67,7 @@ void Pop3_Protocol::readEntries( TQMap< TQString, TQString >* map, TQMap< TQStri if( map->tqcontains( "ssl" ) && *map->tqfind( "ssl" ) == "true" ) map->insert( "encryption", "ssl" ); if( metadata->tqcontains( "tls" ) ) - map->insert( "encryption", TQString( "tls=%1" ).arg( *metadata->tqfind( "tls" ) ) ); + map->insert( "encryption", TQString( "tls=%1" ).tqarg( *metadata->tqfind( "tls" ) ) ); if( metadata->tqcontains( "auth" ) ) map->insert( "auth", TQString( "auth=APOP" ) ); } diff --git a/korn/subjectsdlg.cpp b/korn/subjectsdlg.cpp index f770d0750..333021c52 100644 --- a/korn/subjectsdlg.cpp +++ b/korn/subjectsdlg.cpp @@ -204,7 +204,7 @@ void KornSubjectsDlg::showMessage(TQListViewItem * item ) void KornSubjectsDlg::showSubjectsDlg( const TQString& name ) { - setCaption( i18n("Mails in Box: %1").arg( name ) ); + setCaption( i18n("Mails in Box: %1").tqarg( name ) ); // load the subjects reloadSubjects(); diff --git a/kresources/birthdays/resourcekabc.cpp b/kresources/birthdays/resourcekabc.cpp index 815df5ca9..f3be66d83 100644 --- a/kresources/birthdays/resourcekabc.cpp +++ b/kresources/birthdays/resourcekabc.cpp @@ -163,13 +163,13 @@ bool ResourceKABC::doLoad() TQDate birthdate = (*it).birthday().date(); TQString name_1, email_1, uid_1; if ( birthdate.isValid() ) { - kdDebug(5800) << "found a birthday " << birthdate.toString() << endl; + kdDebug(5800) << "found a birthday " << TQString(birthdate.toString()) << endl; name_1 = (*it).nickName(); email_1 = (*it).fullEmail(); uid_1 = (*it).uid(); if (name_1.isEmpty()) name_1 = (*it).realName(); - summary = i18n("%1's birthday").arg( name_1 ); + summary = i18n("%1's birthday").tqarg( name_1 ); Event *ev = new Event(); @@ -214,13 +214,13 @@ bool ResourceKABC::doLoad() ev->setReadOnly( true ); mCalendar.addEvent(ev); - kdDebug(5800) << "imported " << birthdate.toString() << endl; + kdDebug(5800) << "imported " << TQString(birthdate.toString()) << endl; } TQString anniversary_string = (*it).custom( "KADDRESSBOOK", "X-Anniversary" ); if (anniversary_string.isEmpty() ) continue; - TQDateTime anniversary = TQDate::fromString( anniversary_string, TQt::ISODate ); + TQDateTime anniversary = TQDate::fromString( anniversary_string, Qt::ISODate ); if ( !anniversary.isValid() ) continue; @@ -232,8 +232,8 @@ bool ResourceKABC::doLoad() for ( addrIt = anniversaries.begin(); addrIt != anniversaries.end(); ++addrIt ) { if ( name == (*addrIt).realName() ) { TQDate spouseAnniversary = - TQDate::fromString( (*addrIt).custom( "KADDRESSBOOK", "X-Anniversary" ), TQt::ISODate ); - if ( anniversary == spouseAnniversary ) { + TQDate::fromString( (*addrIt).custom( "KADDRESSBOOK", "X-Anniversary" ), Qt::ISODate ); + if ( anniversary == TQDateTime(spouseAnniversary) ) { found = true; break; @@ -247,8 +247,8 @@ bool ResourceKABC::doLoad() } for ( addrIt = anniversaries.begin(); addrIt != anniversaries.end(); ++addrIt ) { - TQDate anniversary = TQDate::fromString( (*addrIt).custom( "KADDRESSBOOK", "X-Anniversary" ), TQt::ISODate ); - kdDebug(5800) << "found a anniversary " << anniversary.toString() << endl; + TQDate anniversary = TQDate::fromString( (*addrIt).custom( "KADDRESSBOOK", "X-Anniversary" ), Qt::ISODate ); + kdDebug(5800) << "found a anniversary " << TQString(anniversary.toString()) << endl; TQString name; TQString name_1 = (*addrIt).nickName(); TQString uid_1 = (*addrIt).uid(); @@ -276,10 +276,10 @@ bool ResourceKABC::doLoad() name_2 = spouse.realName(); } summary = i18n("insert names of both spouses", - "%1's & %2's anniversary").arg( name_1 ).arg( name_2 ); + "%1's & %2's anniversary").tqarg( name_1 ).tqarg( name_2 ); } else { summary = i18n("only one spouse in addressbook, insert the name", - "%1's anniversary").arg( name_1 ); + "%1's anniversary").tqarg( name_1 ); } Event *ev = new Event(); @@ -328,7 +328,7 @@ bool ResourceKABC::doLoad() ev->setReadOnly( true ); mCalendar.addEvent(ev); - kdDebug(5800) << "imported " << anniversary.toString() << endl; + kdDebug(5800) << "imported " << TQString(anniversary.toString()) << endl; } return true; diff --git a/kresources/blogging/xmlrpcjob.cpp b/kresources/blogging/xmlrpcjob.cpp index e2a3adc32..f20dff875 100644 --- a/kresources/blogging/xmlrpcjob.cpp +++ b/kresources/blogging/xmlrpcjob.cpp @@ -171,14 +171,14 @@ kdDebug() << m_str_response << endl; // TODO: Set the error of the job m_response.clear(); m_response << TQVariant( i18n( "Unknown type of XML markup received. " - "Markup: \n %1" ).arg( m_str_response ) ); + "Markup: \n %1" ).tqarg( m_str_response ) ); m_responseType = XMLRPCUnknownResponse; } } else { // TODO: if we can't parse the XML response, set the correct error message! // emit fault( -1, i18n( "Received invalid XML markup: %1 at %2:%3" ) -// .arg( errMsg ).arg( errLine ).arg( errCol ), m_id ); +// .tqarg( errMsg ).tqarg( errLine ).tqarg( errCol ), m_id ); } TransferJob::slotFinished(); diff --git a/kresources/caldav/configwidgets.cpp b/kresources/caldav/configwidgets.cpp index e986c3380..e84eb2eb2 100644 --- a/kresources/caldav/configwidgets.cpp +++ b/kresources/caldav/configwidgets.cpp @@ -113,7 +113,7 @@ CalDavReloadConfig::CalDavReloadConfig( TQWidget *tqparent ) d->mIntervalSpin->setRange( 1, 900 ); d->mIntervalSpin->setEnabled( false ); - groupBox->setColumnLayout(1, TQt::Vertical); + groupBox->setColumnLayout(1, Qt::Vertical); TQVBoxLayout *vbox = new TQVBoxLayout(groupBox->tqlayout()); vbox->addWidget(intervalRadio); vbox->addWidget(intervalBox); @@ -206,7 +206,7 @@ CalDavSaveConfig::CalDavSaveConfig( TQWidget *tqparent ) intervalRadio->hide(); intervalBox->hide(); - groupBox->setColumnLayout(1, TQt::Vertical); + groupBox->setColumnLayout(1, Qt::Vertical); TQVBoxLayout *vbox = new TQVBoxLayout(groupBox->tqlayout()); vbox->addWidget(delay); vbox->addWidget(every); diff --git a/kresources/caldav/job.cpp b/kresources/caldav/job.cpp index f32864f63..a7a4af54a 100644 --- a/kresources/caldav/job.cpp +++ b/kresources/caldav/job.cpp @@ -82,7 +82,7 @@ void CalDavJob::processError(const caldav_error* err) { if (-401 == code) { // unauthorized error_string = i18n("Unauthorized. Username or password incorrect."); } else if (-599 <= code && code <= -300) { - error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").arg(-code); + error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").tqarg(-code); } else { error_string = err->str; } @@ -98,7 +98,7 @@ void CalDavJob::processTasksError(const caldav_error* err) { if (-401 == code) { // unauthorized error_string = i18n("Unauthorized. Username or password incorrect."); } else if (-599 <= code && code <= -300) { - error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").arg(-code); + error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").tqarg(-code); } else { error_string = err->str; } @@ -114,7 +114,7 @@ void CalDavJob::processJournalsError(const caldav_error* err) { if (-401 == code) { // unauthorized error_string = i18n("Unauthorized. Username or password incorrect."); } else if (-599 <= code && code <= -300) { - error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").arg(-code); + error_string = i18n("HTTP error %1. Please ensure that the URL is a valid CalDAV resource.").tqarg(-code); } else { error_string = err->str; } diff --git a/kresources/caldav/resource.cpp b/kresources/caldav/resource.cpp index 7d7e2a484..d828037bf 100644 --- a/kresources/caldav/resource.cpp +++ b/kresources/caldav/resource.cpp @@ -105,7 +105,7 @@ ResourceCalDav::~ResourceCalDav() { while ((mWriter->running() == true) || (mWritingQueue.isEmpty() == false) || !mWritingQueueReady) { readLockout = true; sleep(1); - tqApp->processEvents(TQEventLoop::ExcludeUserInput); + tqApp->tqprocessEvents(TQEventLoop::ExcludeUserInput); } if (mWriter) { @@ -147,7 +147,7 @@ bool ResourceCalDav::doLoad() { return true; // Silently fail; the user has obviously not responded to a dialog and we don't need to pop up more of them! } - log(TQString("doLoad(%1)").arg(syncCache)); + log(TQString("doLoad(%1)").tqarg(syncCache)); clearCache(); @@ -168,7 +168,7 @@ bool ResourceCalDav::doLoad() { bool ResourceCalDav::doSave() { bool syncCache = true; - log(TQString("doSave(%1)").arg(syncCache)); + log(TQString("doSave(%1)").tqarg(syncCache)); if (!hasChanges()) { log("no changes"); @@ -378,7 +378,7 @@ void ResourceCalDav::loadFinished() { TQCString newpass; if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { log("load error: " + loader->errorString() ); - loadError(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } else { // Set new password and try again @@ -388,12 +388,12 @@ void ResourceCalDav::loadFinished() { } else { log("load error: " + loader->errorString() ); - loadError(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } } else { log("load error: " + loader->errorString() ); - loadError(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } } else { log("successful event load"); @@ -426,7 +426,7 @@ void ResourceCalDav::loadFinished() { // TQCString newpass; // if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { // log("load error: " + loader->tasksErrorString() ); -// loadError(TQString("[%1] ").arg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); +// loadError(TQString("[%1] ").tqarg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); // } // else { // // Set new password and try again @@ -436,12 +436,12 @@ void ResourceCalDav::loadFinished() { } else { log("load error: " + loader->tasksErrorString() ); - loadError(TQString("[%1] ").arg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); } } else { log("load error: " + loader->tasksErrorString() ); - loadError(TQString("[%1] ").arg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->tasksErrorNumber())) + loader->tasksErrorString()); } } else { log("successful tasks load"); @@ -474,7 +474,7 @@ void ResourceCalDav::loadFinished() { // TQCString newpass; // if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { // log("load error: " + loader->journalsErrorString() ); -// loadError(TQString("[%1] ").arg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); +// loadError(TQString("[%1] ").tqarg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); // } // else { // // Set new password and try again @@ -484,12 +484,12 @@ void ResourceCalDav::loadFinished() { } else { log("load error: " + loader->journalsErrorString() ); - loadError(TQString("[%1] ").arg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); } } else { log("load error: " + loader->journalsErrorString() ); - loadError(TQString("[%1] ").arg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); + loadError(TQString("[%1] ").tqarg(abs(loader->journalsErrorNumber())) + loader->journalsErrorString()); } } else { log("successful journals load"); @@ -741,7 +741,7 @@ TQString ResourceCalDav::getICalString(const Incidence::List& inc) { // Remove any line feeds/carriage returns/white spaces from the UID field as they WILL break libcaldav int uidPos = data.tqfind("UID:", 0) + 4; - int nextPos = data.findRev("\n", data.tqfind(":", uidPos)); + int nextPos = data.tqfindRev("\n", data.tqfind(":", uidPos)); TQString uidField = data.mid(uidPos, nextPos-uidPos); data.remove(uidPos, nextPos-uidPos); uidField.tqreplace("\n", ""); @@ -971,7 +971,7 @@ void ResourceCalDav::writingFinished() { TQCString newpass; if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { log("write error: " + mWriter->errorString()); - saveError(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + saveError(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } else { // Set new password and try again @@ -981,12 +981,12 @@ void ResourceCalDav::writingFinished() { } else { log("write error: " + mWriter->errorString()); - saveError(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + saveError(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } } else { log("write error: " + mWriter->errorString()); - saveError(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + saveError(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } } else { log("success"); diff --git a/kresources/carddav/configwidgets.cpp b/kresources/carddav/configwidgets.cpp index 84d97938d..fbc19c7e3 100644 --- a/kresources/carddav/configwidgets.cpp +++ b/kresources/carddav/configwidgets.cpp @@ -112,7 +112,7 @@ CardDavReloadConfig::CardDavReloadConfig( TQWidget *tqparent ) d->mIntervalSpin->setRange( 1, 900 ); d->mIntervalSpin->setEnabled( false ); - groupBox->setColumnLayout(1, TQt::Vertical); + groupBox->setColumnLayout(1, Qt::Vertical); TQVBoxLayout *vbox = new TQVBoxLayout(groupBox->tqlayout()); vbox->addWidget(intervalRadio); vbox->addWidget(intervalBox); @@ -205,7 +205,7 @@ CardDavSaveConfig::CardDavSaveConfig( TQWidget *tqparent ) intervalRadio->hide(); intervalBox->hide(); - groupBox->setColumnLayout(1, TQt::Vertical); + groupBox->setColumnLayout(1, Qt::Vertical); TQVBoxLayout *vbox = new TQVBoxLayout(groupBox->tqlayout()); vbox->addWidget(delay); vbox->addWidget(every); diff --git a/kresources/carddav/job.cpp b/kresources/carddav/job.cpp index d2795d68b..4d3fd3d43 100644 --- a/kresources/carddav/job.cpp +++ b/kresources/carddav/job.cpp @@ -69,7 +69,7 @@ void CardDavJob::processError(const carddav_error* err) { if (-401 == code) { // unauthorized error_string = i18n("Unauthorized. Username or password incorrect."); } else if (-599 <= code && code <= -300) { - error_string = i18n("HTTP error %1. Maybe, URL is not a CardDAV resource.").arg(-code); + error_string = i18n("HTTP error %1. Maybe, URL is not a CardDAV resource.").tqarg(-code); } else { error_string = err->str; } diff --git a/kresources/carddav/resource.cpp b/kresources/carddav/resource.cpp index 5cd95c3f5..9570d2b3c 100644 --- a/kresources/carddav/resource.cpp +++ b/kresources/carddav/resource.cpp @@ -105,7 +105,7 @@ ResourceCardDav::~ResourceCardDav() { while ((mWriter->running() == true) || (mWritingQueue.isEmpty() == false) || !mWritingQueueReady) { readLockout = true; sleep(1); - tqApp->processEvents(TQEventLoop::ExcludeUserInput); + tqApp->tqprocessEvents(TQEventLoop::ExcludeUserInput); } if (mWriter) { @@ -144,7 +144,7 @@ bool ResourceCardDav::load() { return true; // Silently fail; the user has obviously not responded to a dialog and we don't need to pop up more of them! } - log(TQString("doLoad(%1)").arg(syncCache)); + log(TQString("doLoad(%1)").tqarg(syncCache)); // FIXME KABC //clearCache(); @@ -166,7 +166,7 @@ bool ResourceCardDav::load() { bool ResourceCardDav::doSave() { bool syncCache = true; - log(TQString("doSave(%1)").arg(syncCache)); + log(TQString("doSave(%1)").tqarg(syncCache)); if (!hasChanges()) { log("no changes"); @@ -372,7 +372,7 @@ void ResourceCardDav::loadFinished() { TQCString newpass; if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { log("load error: " + loader->errorString() ); - addressBook()->error(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } else { // Set new password and try again @@ -382,12 +382,12 @@ void ResourceCardDav::loadFinished() { } else { log("load error: " + loader->errorString() ); - addressBook()->error(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } } else { log("load error: " + loader->errorString() ); - addressBook()->error(TQString("[%1] ").arg(abs(loader->errorNumber())) + loader->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(loader->errorNumber())) + loader->errorString()); } } else { log("successful load"); @@ -641,7 +641,7 @@ void ResourceCardDav::writingFinished() { TQCString newpass; if (KPasswordDialog::getPassword (newpass, TQString("<b>") + i18n("Remote authorization required") + TQString("</b><p>") + i18n("Please input the password for") + TQString(" ") + mPrefs->getusername(), NULL) != 1) { log("write error: " + mWriter->errorString()); - addressBook()->error(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } else { // Set new password and try again @@ -651,12 +651,12 @@ void ResourceCardDav::writingFinished() { } else { log("write error: " + mWriter->errorString()); - addressBook()->error(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } } else { log("write error: " + mWriter->errorString()); - addressBook()->error(TQString("[%1] ").arg(abs(mWriter->errorNumber())) + mWriter->errorString()); + addressBook()->error(TQString("[%1] ").tqarg(abs(mWriter->errorNumber())) + mWriter->errorString()); } } else { log("success"); diff --git a/kresources/egroupware/kabc_resourcexmlrpc.cpp b/kresources/egroupware/kabc_resourcexmlrpc.cpp index ae789ef62..2e5053240 100644 --- a/kresources/egroupware/kabc_resourcexmlrpc.cpp +++ b/kresources/egroupware/kabc_resourcexmlrpc.cpp @@ -393,7 +393,7 @@ void ResourceXMLRPC::deleteContactFinished( const TQValueList<TQVariant>&, void ResourceXMLRPC::fault( int error, const TQString &errorMsg, const TQVariant& ) { - TQString msg = i18n( "<qt>Server sent error %1: <b>%2</b></qt>" ).arg( error ).arg( errorMsg ); + TQString msg = i18n( "<qt>Server sent error %1: <b>%2</b></qt>" ).tqarg( error ).tqarg( errorMsg ); if ( addressBook() ) addressBook()->error( msg ); @@ -408,7 +408,7 @@ void ResourceXMLRPC::addContactFault( int, const TQString &errorMsg, mAddrMap.remove( addr.uid() ); TQString msg = i18n( "Unable to add contact %1 to server. (%2)" ); - addressBook()->error( msg.arg( addr.formattedName(), errorMsg ) ); + addressBook()->error( msg.tqarg( addr.formattedName(), errorMsg ) ); } void ResourceXMLRPC::updateContactFault( int, const TQString &errorMsg, @@ -417,7 +417,7 @@ void ResourceXMLRPC::updateContactFault( int, const TQString &errorMsg, KABC::Addressee addr = mAddrMap[ id.toString() ]; TQString msg = i18n( "Unable to update contact %1 on server. (%2)" ); - addressBook()->error( msg.arg( addr.formattedName(), errorMsg ) ); + addressBook()->error( msg.tqarg( addr.formattedName(), errorMsg ) ); } void ResourceXMLRPC::deleteContactFault( int, const TQString &errorMsg, @@ -437,7 +437,7 @@ void ResourceXMLRPC::deleteContactFault( int, const TQString &errorMsg, mAddrMap.insert( addr.uid(), addr ); TQString msg = i18n( "Unable to delete contact %1 from server. (%2)" ); - addressBook()->error( msg.arg( addr.formattedName(), errorMsg ) ); + addressBook()->error( msg.tqarg( addr.formattedName(), errorMsg ) ); } TQString ResourceXMLRPC::addrTypesToTypeStr( int typeMask ) diff --git a/kresources/egroupware/kcal_resourcexmlrpc.cpp b/kresources/egroupware/kcal_resourcexmlrpc.cpp index 6bbdc2342..b15a5a395 100644 --- a/kresources/egroupware/kcal_resourcexmlrpc.cpp +++ b/kresources/egroupware/kcal_resourcexmlrpc.cpp @@ -946,7 +946,7 @@ void ResourceXMLRPC::writeEvent( Event *event, TQMap<TQString, TQVariant> &args // handle all day events if ( event->doesFloat() ) - args.insert( "end", event->dtEnd().addDays( 1 ) ); + args.insert( "end", TQDateTime(event->dtEnd().addDays( 1 )) ); else args.insert( "end", event->dtEnd() ); diff --git a/kresources/egroupware/todostatemapper.cpp b/kresources/egroupware/todostatemapper.cpp index 0793bd609..2539d23aa 100644 --- a/kresources/egroupware/todostatemapper.cpp +++ b/kresources/egroupware/todostatemapper.cpp @@ -153,7 +153,7 @@ TQString TodoStateMapper::toRemote( int localState ) else if ( localState == 100 ) return "done"; else - return TQString( "%1%" ).arg( localState ); + return TQString( "%1%" ).tqarg( localState ); } TQString TodoStateMapper::filename() diff --git a/kresources/egroupware/xmlrpciface.cpp b/kresources/egroupware/xmlrpciface.cpp index bd31a194a..4a46a37eb 100644 --- a/kresources/egroupware/xmlrpciface.cpp +++ b/kresources/egroupware/xmlrpciface.cpp @@ -113,7 +113,7 @@ void Query::slotResult( KIO::Job *job ) if ( !doc.setContent( data, false, &errMsg, &errLine, &errCol ) ) { emit fault( -1, i18n( "Received invalid XML markup: %1 at %2:%3" ) - .arg( errMsg ).arg( errLine ).arg( errCol ), m_id ); + .tqarg( errMsg ).tqarg( errLine ).tqarg( errCol ), m_id ); emit finished( this ); return ; } @@ -222,7 +222,7 @@ TQString Query::marshal( const TQVariant &arg ) const case TQVariant::ByteArray: return "<value><base64>" + KCodecs::base64Encode( arg.toByteArray() ) + "</base64></value>\r\n"; case TQVariant::DateTime: - return "<value><datetime.iso8601>" + arg.toDateTime().toString( TQt::ISODate ) + "</datetime.iso8601></value>\r\n"; + return "<value><datetime.iso8601>" + arg.toDateTime().toString( Qt::ISODate ) + "</datetime.iso8601></value>\r\n"; case TQVariant::List: { TQString markup = "<value><array><data>\r\n"; @@ -277,9 +277,9 @@ TQVariant Query::demarshal( const TQDomElement &elem ) const return TQVariant( false ); } else if ( typeName == "base64" ) - return TQVariant( KCodecs::base64Decode( typeElement.text().latin1() ) ); + return TQVariant( KCodecs::base64Decode( TQCString(typeElement.text().latin1()) ) ); else if ( typeName == "datetime" || typeName == "datetime.iso8601" ) - return TQVariant( TQDateTime::fromString( typeElement.text(), TQt::ISODate ) ); + return TQVariant( TQDateTime::fromString( typeElement.text(), Qt::ISODate ) ); else if ( typeName == "array" ) { TQValueList<TQVariant> values; diff --git a/kresources/exchange/dateset.cpp b/kresources/exchange/dateset.cpp index d28409a9c..e6393afa0 100644 --- a/kresources/exchange/dateset.cpp +++ b/kresources/exchange/dateset.cpp @@ -232,9 +232,9 @@ void DateSet::print() TQDate start = mDates->at( i )->first; TQDate end = mDates->at( i )->second; if (start == end) - kdDebug() << start.toString() << endl; + kdDebug() << TQString(start.toString()) << endl; else - kdDebug() << "(" << start.toString() << " , " << end.toString() << ")" << endl; + kdDebug() << "(" << TQString(start.toString()) << " , " << TQString(end.toString()) << ")" << endl; } } diff --git a/kresources/exchange/resourceexchange.cpp b/kresources/exchange/resourceexchange.cpp index 234907fcb..de9158755 100644 --- a/kresources/exchange/resourceexchange.cpp +++ b/kresources/exchange/resourceexchange.cpp @@ -495,7 +495,7 @@ Event::List ResourceExchange::rawEventsForDate( const TQDate &qd, // FIXME: This is needed for the hack below: Event::List eventsBefore = mCache->rawEvents(); - kdDebug() << "Reading events for month of " << start.toString() << endl; + kdDebug() << "Reading events for month of " << TQString(start.toString()) << endl; mClient->downloadSynchronous( mCache, start, end, true ); // Show progress dialog // FIXME: This is a terrible hack! We need to install the observer for diff --git a/kresources/groupwise/kabc_resourcegroupwise.cpp b/kresources/groupwise/kabc_resourcegroupwise.cpp index d1300f9c9..6ac8a880a 100644 --- a/kresources/groupwise/kabc_resourcegroupwise.cpp +++ b/kresources/groupwise/kabc_resourcegroupwise.cpp @@ -287,7 +287,7 @@ bool ResourceGroupwise::asyncLoad() if ( !mProgress ) { mProgress = KPIM::ProgressManager::instance()->createProgressItem( - KPIM::ProgressManager::getUniqueID(), i18n( "Loading GroupWise resource %1" ).arg( resourceName() ), TQString(), true /*CanBeCancelled*/, mPrefs->url().startsWith("https" ) ); + KPIM::ProgressManager::getUniqueID(), i18n( "Loading GroupWise resource %1" ).tqarg( resourceName() ), TQString(), true /*CanBeCancelled*/, mPrefs->url().startsWith("https" ) ); connect( mProgress, TQT_SIGNAL( progressItemCanceled( KPIM::ProgressItem * ) ), TQT_SLOT( cancelLoad() ) ); } @@ -708,7 +708,7 @@ KURL ResourceGroupwise::createAccessUrl( BookType bookType, AccessMode mode, uns if ( mode == Update && lastSequenceNumber > 0 && lastPORebuildTime > 0 ) { - query += TQString::tqfromLatin1( "&update=true&lastSeqNo=%1&PORebuildTime=%2" ).arg( lastSequenceNumber ).arg( lastPORebuildTime );; + query += TQString::tqfromLatin1( "&update=true&lastSeqNo=%1&PORebuildTime=%2" ).tqarg( lastSequenceNumber ).tqarg( lastPORebuildTime );; } url.setQuery( query ); return url; diff --git a/kresources/groupwise/kabc_resourcegroupwiseconfig.cpp b/kresources/groupwise/kabc_resourcegroupwiseconfig.cpp index 91b0380a9..a5ccb74fc 100644 --- a/kresources/groupwise/kabc_resourcegroupwiseconfig.cpp +++ b/kresources/groupwise/kabc_resourcegroupwiseconfig.cpp @@ -202,7 +202,7 @@ void ResourceGroupwiseConfig::updateAddressBookView() mWriteAddressBookIds.append( (*abIt).id ); } - int index = mWriteAddressBookIds.findIndex( mResource->prefs()->writeAddressBook() ); + int index = mWriteAddressBookIds.tqfindIndex( mResource->prefs()->writeAddressBook() ); mAddressBookBox->setCurrentItem( index ); } diff --git a/kresources/groupwise/kcal_resourcegroupwiseconfig.cpp b/kresources/groupwise/kcal_resourcegroupwiseconfig.cpp index 8e579f8cd..e02cf2c52 100644 --- a/kresources/groupwise/kcal_resourcegroupwiseconfig.cpp +++ b/kresources/groupwise/kcal_resourcegroupwiseconfig.cpp @@ -123,7 +123,7 @@ void ResourceGroupwiseConfig::slotViewUserSettings() if ( s ) { - KDialogBase * dialog = new KDialogBase( ::qt_cast<TQWidget*>(tqparent() ), "gwsettingswidget", true, i18n( "GroupWise Settings" ) ); + KDialogBase * dialog = new KDialogBase( ::tqqt_cast<TQWidget*>(tqparent() ), "gwsettingswidget", true, i18n( "GroupWise Settings" ) ); // TQVBoxLayout * tqlayout = new TQVBoxLayout( dialog ); GroupWiseSettingsWidget * settingsWidget = new GroupWiseSettingsWidget( dialog ); dialog->setMainWidget( settingsWidget ); diff --git a/kresources/groupwise/kioslave/groupwise.cpp b/kresources/groupwise/kioslave/groupwise.cpp index c535e5689..8689309b4 100644 --- a/kresources/groupwise/kioslave/groupwise.cpp +++ b/kresources/groupwise/kioslave/groupwise.cpp @@ -117,7 +117,7 @@ void Groupwise::get( const KURL &url ) getAddressbook( url ); } else { TQString error = i18n("Unknown path. Known paths are '/freebusy/', " - "'/calendar/' and '/addressbook/'.") + TQString(" path was %1" ).arg( url.url() ); + "'/calendar/' and '/addressbook/'.") + TQString(" path was %1" ).tqarg( url.url() ); errorMessage( error ); } @@ -419,7 +419,7 @@ void Groupwise::slotReadAddressBookProcessedSize( int size ) void Groupwise::slotServerErrorMessage( const TQString & serverErrorMessage, bool fatal ) { kdDebug() << "Groupwise::slotJobErrorMessage()" << serverErrorMessage << ( fatal ? ", FATAL!" : ", proceeding" ) << endl; - errorMessage( i18n( "An error occurred while communicating with the GroupWise server:\n%1" ).arg( serverErrorMessage ) ); + errorMessage( i18n( "An error occurred while communicating with the GroupWise server:\n%1" ).tqarg( serverErrorMessage ) ); } #include "groupwise.moc" diff --git a/kresources/groupwise/soap/contactconverter.cpp b/kresources/groupwise/soap/contactconverter.cpp index 97aff84f2..605d14d69 100644 --- a/kresources/groupwise/soap/contactconverter.cpp +++ b/kresources/groupwise/soap/contactconverter.cpp @@ -70,7 +70,7 @@ ngwt__Contact* ContactConverter::convertToContact( const KABC::Addressee &addr ) std::vector<ngwt__ContainerRef*>* container = soap_new_std__vectorTemplateOfPointerTongwt__ContainerRef( soap(), -1 ); ngwt__ContainerRef* containerRef = soap_new_ngwt__ContainerRef( soap(), -1 ); containerRef->deleted = 0; - containerRef->__item = addr.custom( "GWRESOURCE", "CONTAINER" ).utf8(); + containerRef->__item = addr.custom( "GWRESOURCE", "CONTAINER" ).utf8().data(); container->push_back( containerRef ); contact->container = *container; @@ -402,7 +402,7 @@ KABC::Addressee ContactConverter::convertFromContact( ngwt__Contact* contact ) // TODO: map protocol to KDE's set of known protocol names (need to know the set of services in use elsewhere) if ( protocol == "nov" ) protocol = "groupwise"; - addr.insertCustom( TQString::tqfromLatin1("messaging/%1").arg( protocol ), + addr.insertCustom( TQString::tqfromLatin1("messaging/%1").tqarg( protocol ), TQString::tqfromLatin1( "All" ), addresses.join( TQChar( 0xE000 ) ) ); } @@ -456,7 +456,7 @@ ngwt__PhoneNumber* ContactConverter::convertPhoneNumber( const KABC::PhoneNumber return 0; ngwt__PhoneNumber* phoneNumber = soap_new_ngwt__PhoneNumber( soap(), -1 ); - phoneNumber->__item = number.number().utf8(); + phoneNumber->__item = number.number().utf8().data(); if ( number.type() & KABC::PhoneNumber::Fax ) { phoneNumber->type = Fax; diff --git a/kresources/groupwise/soap/groupwiseserver.cpp b/kresources/groupwise/soap/groupwiseserver.cpp index bd908c442..3aee84877 100644 --- a/kresources/groupwise/soap/groupwiseserver.cpp +++ b/kresources/groupwise/soap/groupwiseserver.cpp @@ -132,7 +132,7 @@ int GroupwiseServer::gSoapOpen( struct soap *soap, const char *, errorMessage = TQString::tqfromLatin1( strerror( errno ) ); perror( 0 ); soap->error = SOAP_TCP_ERROR; - mErrorText = i18n("Connect failed: %1.").arg( errorMessage ); + mErrorText = i18n("Connect failed: %1.").tqarg( errorMessage ); return SOAP_INVALID_SOCKET; } @@ -149,7 +149,7 @@ int GroupwiseServer::gSoapOpen( struct soap *soap, const char *, if ( rc == -3 ) errorMessage = TQString::tqfromLatin1( "Connection timed out. Check host and port number" ); } - mErrorText = i18n("Connect failed: %1.").arg( errorMessage ); + mErrorText = i18n("Connect failed: %1.").tqarg( errorMessage ); soap->error =SOAP_TCP_ERROR; return SOAP_INVALID_SOCKET; } @@ -315,7 +315,7 @@ bool GroupwiseServer::login() ngwt__PlainText pt; - pt.username = mUser.utf8(); + pt.username = mUser.utf8().data(); pt.password = conv.qStringToString( mPassword ); loginReq.auth = &pt; mSoap->userid = strdup( mUser.utf8() ); @@ -1370,7 +1370,7 @@ bool GroupwiseServer::readFreeBusy( const TQString &email, // Get free/busy data _ngwm__getFreeBusyRequest getFreeBusyRequest; - getFreeBusyRequest.freeBusySessionId = TQString::number( fbSessionId ).utf8(); + getFreeBusyRequest.freeBusySessionId = TQString::number( fbSessionId ).utf8().data(); _ngwm__getFreeBusyResponse getFreeBusyResponse; diff --git a/kresources/groupwise/soap/gwconverter.cpp b/kresources/groupwise/soap/gwconverter.cpp index 5ca7c332f..3cd61f60b 100644 --- a/kresources/groupwise/soap/gwconverter.cpp +++ b/kresources/groupwise/soap/gwconverter.cpp @@ -67,8 +67,8 @@ char* GWConverter::qStringToChar( const TQString &string ) TQDate GWConverter::charToTQDate( const char *str ) { - if ( !str ) return TQDate(); // FIXME: TQt::ISODate is probably no good here because it expects yyyy-MM-dd not yyyyMMdd - return TQDate::fromString( TQString::fromUtf8( str ), TQt::ISODate ); + if ( !str ) return TQDate(); // FIXME: Qt::ISODate is probably no good here because it expects yyyy-MM-dd not yyyyMMdd + return TQDate::fromString( TQString::fromUtf8( str ), Qt::ISODate ); } char *GWConverter::qDateTimeToChar( const TQDateTime &dt, @@ -94,7 +94,7 @@ std::string* GWConverter::qDateTimeToString( const TQDateTime &dt ) TQDateTime GWConverter::stringToTQDateTime( const std::string* str ) { - TQDateTime dt = TQDateTime::fromString( TQString::fromUtf8( str->c_str() ), TQt::ISODate ); + TQDateTime dt = TQDateTime::fromString( TQString::fromUtf8( str->c_str() ), Qt::ISODate ); return dt; } @@ -111,15 +111,15 @@ std::string* GWConverter::qDateToString( const TQDate &date ) TQDate GWConverter::stringToTQDate( std::string* str ) { //NB this ISODate may become unnecessary, if GW stops sending in yyyy-mm-dd format again - return TQDate::fromString( TQString::tqfromLatin1( str->c_str() ), TQt::ISODate ); + return TQDate::fromString( TQString::tqfromLatin1( str->c_str() ), Qt::ISODate ); } TQDateTime GWConverter::charToTQDateTime( const char *str ) { if ( !str ) return TQDateTime(); // kdDebug() << "charToTQDateTime(): " << str << endl; - // as above re TQt::ISODate - TQDateTime dt = TQDateTime::fromString( TQString::fromUtf8( str ), TQt::ISODate ); + // as above re Qt::ISODate + TQDateTime dt = TQDateTime::fromString( TQString::fromUtf8( str ), Qt::ISODate ); // kdDebug() << " " << dt.toString() << endl; return dt; } diff --git a/kresources/groupwise/soap/gwjobs.cpp b/kresources/groupwise/soap/gwjobs.cpp index bd2f908e4..7a95cf6e8 100644 --- a/kresources/groupwise/soap/gwjobs.cpp +++ b/kresources/groupwise/soap/gwjobs.cpp @@ -121,7 +121,7 @@ void ReadAddressBooksJob::readAddressBook( std::string &id ) &itemsRequest, &itemsResponse ); if ( result != 0 ) { soap_print_fault( mSoap, stderr ); - mServer->emitErrorMessage( i18n("Unable to read GroupWise address book: %1" ).arg( id.c_str() ), false ); + mServer->emitErrorMessage( i18n("Unable to read GroupWise address book: %1" ).tqarg( id.c_str() ), false ); return; } @@ -192,7 +192,7 @@ void ReadAddressBooksJob::readAddressBook( std::string &id ) cursorRequest.container = id; cursorRequest.view = 0; - if ( id.tqfind( "GroupWiseSystemAddressBook" ) == 0 ) + if ( id.find( "GroupWiseSystemAddressBook" ) == 0 ) { kdDebug() << " Book: " << id.c_str() << " is a SAB " << endl; // filter for Contacts until we support Groups @@ -613,7 +613,7 @@ void ReadCalendarJob::readCalendarFolder( const std::string &id, ReadItemCounts else { kdDebug() << " readCursor got no Items in Response!" << endl; - mServer->emitErrorMessage( i18n("Unable to read GroupWise address book: reading %1 returned no items." ).arg( id.c_str() ), false ); + mServer->emitErrorMessage( i18n("Unable to read GroupWise address book: reading %1 returned no items." ).tqarg( id.c_str() ), false ); break; } } diff --git a/kresources/groupwise/soap/incidenceconverter.cpp b/kresources/groupwise/soap/incidenceconverter.cpp index b7a360ee3..7888ff50a 100644 --- a/kresources/groupwise/soap/incidenceconverter.cpp +++ b/kresources/groupwise/soap/incidenceconverter.cpp @@ -370,7 +370,7 @@ bool IncidenceConverter::convertToCalendarItem( KCal::Incidence* incidence, ngwt std::vector<ngwt__ContainerRef*>* container = soap_new_std__vectorTemplateOfPointerTongwt__ContainerRef( soap(), -1 ); ngwt__ContainerRef* containerRef = soap_new_ngwt__ContainerRef( soap(), -1 ); containerRef->deleted = 0; - containerRef->__item = incidence->customProperty( "GWRESOURCE", "CONTAINER" ).utf8(); + containerRef->__item = incidence->customProperty( "GWRESOURCE", "CONTAINER" ).utf8().data(); container->push_back( containerRef ); item->container = *container; @@ -470,7 +470,7 @@ void IncidenceConverter::setAttendees( KCal::Incidence *incidence, KCal::Attendee::List::ConstIterator it; for( it = attendees.begin(); it != attendees.end(); ++it ) { if ( !to.isEmpty() ) - to += TQString::tqfromLatin1( "; %1" ).arg( (*it)->name() ); + to += TQString::tqfromLatin1( "; %1" ).tqarg( (*it)->name() ); kdDebug() << "IncidenceConverter::setAttendees(), adding " << (*it)->fullName() << endl; TQString uuid; @@ -543,7 +543,7 @@ bool IncidenceConverter::convertFromCalendarItem( ngwt__CalendarItem* item, std::vector<xsd__date>::const_iterator it; for ( it = dateList->begin(); it != dateList->end(); ++it ) { - TQDate date = TQDate::fromString( s2q( *it ), TQt::ISODate ); + TQDate date = TQDate::fromString( s2q( *it ), Qt::ISODate ); if ( date.isValid() ) } } @@ -689,7 +689,7 @@ void IncidenceConverter::setRecurrence( KCal::Incidence * incidence, ngwt__Calen // recurrence date - try setting it using the recurrence start date - didn't help /* std::string startDate; - startDate.append( recur->recurStart().date().toString( TQt::ISODate ).utf8() ); + startDate.append( recur->recurStart().date().toString( Qt::ISODate ).utf8() ); item->rdate = soap_new_ngwt__RecurrenceDateType( soap(), -1 ); item->rdate->date.push_back( startDate );*/ // exceptions list - try sending empty list even if no exceptions @@ -704,7 +704,7 @@ void IncidenceConverter::setRecurrence( KCal::Incidence * incidence, ngwt__Calen for ( KCal::DateList::ConstIterator it = exceptions.begin(); it != exceptions.end(); ++it ) { std::string startDate; - startDate.append( (*it).toString( TQt::ISODate ).utf8() ); + startDate.append( TQString((*it).toString( Qt::ISODate )).utf8() ); item->exdate->date.push_back( startDate ); } } diff --git a/kresources/groupwise/soap/ksslsocket.cpp b/kresources/groupwise/soap/ksslsocket.cpp index eef6a5bf1..e9e05c26e 100644 --- a/kresources/groupwise/soap/ksslsocket.cpp +++ b/kresources/groupwise/soap/ksslsocket.cpp @@ -325,7 +325,7 @@ int KSSLSocket::verifyCertificate() "does not match the one the " "certificate was issued to."); result = messageBox( KIO::SlaveBase::WarningYesNoCancel, - msg.arg(ourHost), + msg.tqarg(ourHost), i18n("Server Authentication"), i18n("&Details"), KStdGuiItem::cont().text() ); @@ -335,7 +335,7 @@ int KSSLSocket::verifyCertificate() TQString msg = i18n("The server certificate failed the " "authenticity test (%1)."); result = messageBox( KIO::SlaveBase::WarningYesNoCancel, - msg.arg(ourHost), + msg.tqarg(ourHost), i18n("Server Authentication"), i18n("&Details"), KStdGuiItem::cont().text() ); diff --git a/kresources/kolab/kcal/incidence.cpp b/kresources/kolab/kcal/incidence.cpp index 0d99780a4..602321795 100644 --- a/kresources/kolab/kcal/incidence.cpp +++ b/kresources/kolab/kcal/incidence.cpp @@ -1030,7 +1030,7 @@ void Incidence::loadAttachments() TQString Incidence::productID() const { - return TQString( "KOrganizer %1, Kolab resource" ).arg( korgVersion ); + return TQString( "KOrganizer %1, Kolab resource" ).tqarg( korgVersion ); } // Unhandled KCal::Incidence fields: diff --git a/kresources/kolab/kcal/resourcekolab.cpp b/kresources/kolab/kcal/resourcekolab.cpp index 59f6a3558..da2cee412 100644 --- a/kresources/kolab/kcal/resourcekolab.cpp +++ b/kresources/kolab/kcal/resourcekolab.cpp @@ -423,7 +423,7 @@ void ResourceKolab::resolveConflict( KCal::Incidence* inc, const TQString& subre addedIncidence = inc; } else if ( result == 0 ) { // take both addedIncidence = inc; - addedIncidence->setSummary( i18n("Copy of: %1").arg( addedIncidence->summary() ) ); + addedIncidence->setSummary( i18n("Copy of: %1").tqarg( addedIncidence->summary() ) ); addedIncidence->setUid( CalFormat::createUniqueId() ); localIncidence = local; } @@ -604,24 +604,24 @@ bool ResourceKolab::addIncidence( KCal::Incidence* incidence, const TQString& _s } text += "<font></b><br>"; if ( !incidence->summary().isEmpty() ) - text += i18n( "<b>Summary:</b> %1" ).arg( incidence->summary() ) + "<br>"; + text += i18n( "<b>Summary:</b> %1" ).tqarg( incidence->summary() ) + "<br>"; if ( !incidence->location().isEmpty() ) - text += i18n( "<b>Location:</b> %1" ).arg( incidence->location() ); + text += i18n( "<b>Location:</b> %1" ).tqarg( incidence->location() ); text += "<br>"; if ( !incidence->doesFloat() ) text += i18n( "<b>Start:</b> %1, %2" ) - .arg( incidence->dtStartDateStr(), incidence->dtStartTimeStr() ); + .tqarg( incidence->dtStartDateStr(), incidence->dtStartTimeStr() ); else - text += i18n( "<b>Start:</b> %1" ).arg( incidence->dtStartDateStr() ); + text += i18n( "<b>Start:</b> %1" ).tqarg( incidence->dtStartDateStr() ); text += "<br>"; if ( incidence->type() == "Event" ) { Event* event = static_cast<Event*>( incidence ); if ( event->hasEndDate() ) { if ( !event->doesFloat() ) { text += i18n( "<b>End:</b> %1, %2" ) - .arg( event->dtEndDateStr(), event->dtEndTimeStr() ); + .tqarg( event->dtEndDateStr(), event->dtEndTimeStr() ); } else { - text += i18n( "<b>End:</b> %1" ).arg( event->dtEndDateStr() ); + text += i18n( "<b>End:</b> %1" ).tqarg( event->dtEndDateStr() ); } } text += "<br>"; @@ -711,7 +711,7 @@ bool ResourceKolab::addIncidence( KCal::Incidence* incidence, const TQString& _s /* Will be needed when kmail triggers a delete, so we don't delete the inocent * incidence that's sharing the uid with this one */ - mOriginalUID2fakeUID[qMakePair( incidence->schedulingID(), subResource )] = uid; + mOriginalUID2fakeUID[tqMakePair( incidence->schedulingID(), subResource )] = uid; } } /* Add to the cache if the add didn't come from KOrganizer, in which case diff --git a/kresources/kolab/knotes/note.cpp b/kresources/kolab/knotes/note.cpp index e456e43be..ea5f6b285 100644 --- a/kresources/kolab/knotes/note.cpp +++ b/kresources/kolab/knotes/note.cpp @@ -225,5 +225,5 @@ void Note::saveTo( KCal::Journal* journal ) TQString Note::productID() const { - return TQString( "KNotes %1, Kolab resource" ).arg( KNOTES_VERSION ); + return TQString( "KNotes %1, Kolab resource" ).tqarg( KNOTES_VERSION ); } diff --git a/kresources/kolab/shared/kolabbase.cpp b/kresources/kolab/shared/kolabbase.cpp index cb04d12be..3341ee35f 100644 --- a/kresources/kolab/shared/kolabbase.cpp +++ b/kresources/kolab/shared/kolabbase.cpp @@ -409,12 +409,12 @@ TQDomDocument KolabBase::domTree() TQString KolabBase::dateTimeToString( const TQDateTime& time ) { - return time.toString( TQt::ISODate ) + 'Z'; + return time.toString( Qt::ISODate ) + 'Z'; } TQString KolabBase::dateToString( const TQDate& date ) { - return date.toString( TQt::ISODate ); + return date.toString( Qt::ISODate ); } TQDateTime KolabBase::stringToDateTime( const TQString& _date ) @@ -423,15 +423,15 @@ TQDateTime KolabBase::stringToDateTime( const TQString& _date ) //Deal with data from some clients that always append a Z to dates. if ( date.endsWith( "ZZ" ) ) date.truncate( date.length() - 2 ); - //In TQt3, TQt::ISODate cannot handle a trailing Z for UTC, so remove if found. + //In TQt3, Qt::ISODate cannot handle a trailing Z for UTC, so remove if found. else if ( date.endsWith( "Z" ) ) date.truncate( date.length() - 1 ); - return TQDateTime::fromString( date, TQt::ISODate ); + return TQDateTime::fromString( date, Qt::ISODate ); } TQDate KolabBase::stringToDate( const TQString& date ) { - return TQDate::fromString( date, TQt::ISODate ); + return TQDate::fromString( date, Qt::ISODate ); } TQString KolabBase::sensitivityToString( Sensitivity s ) diff --git a/kresources/kolab/shared/resourcekolabbase.cpp b/kresources/kolab/shared/resourcekolabbase.cpp index cf81f4518..90464b6b0 100644 --- a/kresources/kolab/shared/resourcekolabbase.cpp +++ b/kresources/kolab/shared/resourcekolabbase.cpp @@ -126,8 +126,8 @@ static TQString plainTextBody() " Groupware format.\nFor a list of such email clients please" " visit\n%1" ); const char * url = "http://www.kolab.org/kolab2-clients.html"; - TQString firstPartTextUntranslated = TQString::tqfromLatin1( firstPartTextToTranslate ).arg( url ); - TQString firstPartText = i18n( firstPartTextToTranslate ).arg( url ); + TQString firstPartTextUntranslated = TQString::tqfromLatin1( firstPartTextToTranslate ).tqarg( url ); + TQString firstPartText = i18n( firstPartTextToTranslate ).tqarg( url ); if ( firstPartText != firstPartTextUntranslated ) { firstPartText.append("\n\n-----------------------------------------------------\n\n"); firstPartText.append( firstPartTextUntranslated ); @@ -190,7 +190,7 @@ bool ResourceKolabBase::kmailUpdate( const TQString& resource, TQString ResourceKolabBase::configFile( const TQString& type ) const { return locateLocal( "config", - TQString( "kresources/kolab/%1rc" ).arg( type ) ); + TQString( "kresources/kolab/%1rc" ).tqarg( type ) ); } bool ResourceKolabBase::connectToKMail() const diff --git a/kresources/lib/folderconfig.cpp b/kresources/lib/folderconfig.cpp index 06d9f9fc2..f8feb456f 100644 --- a/kresources/lib/folderconfig.cpp +++ b/kresources/lib/folderconfig.cpp @@ -47,7 +47,7 @@ FolderConfig::FolderConfig( TQWidget *tqparent ) TQBoxLayout *topLayout = new TQVBoxLayout( this ); topLayout->addSpacing( KDialog::spacingHint() ); - TQGroupBox *topBox = new TQGroupBox( 1, Horizontal, i18n("Folder Selection"), + TQGroupBox *topBox = new TQGroupBox( 1, Qt::Horizontal, i18n("Folder Selection"), this ); topLayout->addWidget( topBox ); diff --git a/kresources/lib/folderlister.cpp b/kresources/lib/folderlister.cpp index a0ef5f0e2..9436a6f92 100644 --- a/kresources/lib/folderlister.cpp +++ b/kresources/lib/folderlister.cpp @@ -137,7 +137,7 @@ void FolderLister::readConfig( KPIM::GroupwarePrefsBase *newprefs ) for ( int i=0; i<nr; ++i ) { TQStringList l( newprefs->folder( i ) ); -// TQStringList l( cfgg.readListEntry( TQString("Folder%1").arg( i ) ) ); +// TQStringList l( cfgg.readListEntry( TQString("Folder%1").tqarg( i ) ) ); Entry e; if ( l.count()>0 ) { e.id = l.first(); @@ -186,7 +186,7 @@ void FolderLister::writeConfig( GroupwarePrefsBase *newprefs ) lst << (*it).name; lst += contentTypeToStrings( (*it).type ); newprefs->setFolder( nr, lst ); -// cfgg.writeEntry( TQString("Folder%1").arg( nr ), lst ); +// cfgg.writeEntry( TQString("Folder%1").tqarg( nr ), lst ); if ( (*it).active ) active.append( (*it).id ); nr++; } diff --git a/kresources/lib/folderlistview.cpp b/kresources/lib/folderlistview.cpp index 23e115c0a..c6b34cbd2 100644 --- a/kresources/lib/folderlistview.cpp +++ b/kresources/lib/folderlistview.cpp @@ -147,10 +147,10 @@ void FolderListView::slotPopupHandler( int z ) void FolderListView::slotMousePressed(int btn, TQListViewItem* i, const TQPoint& pos, int c) { if ( dynamic_cast<FolderListItem*>(i) ) { - if ( btn == TQt::RightButton ) { + if ( btn == Qt::RightButton ) { showPopupMenu( (FolderListItem*)i, /*mapToGlobal(*/pos/*)*/ ); } - else if ( btn == TQt::LeftButton && c > 0 ) { + else if ( btn == Qt::LeftButton && c > 0 ) { // map pos to item/column and call FolderListItem::activate(col, pos) ((FolderListItem*)i)->activate( c, viewport()->mapFromGlobal( pos ) - TQPoint( 0, tqitemRect(i).top() ) ); // } else { diff --git a/kresources/lib/kcal_resourcegroupwarebase.cpp b/kresources/lib/kcal_resourcegroupwarebase.cpp index 11db0e81e..2f48362d9 100644 --- a/kresources/lib/kcal_resourcegroupwarebase.cpp +++ b/kresources/lib/kcal_resourcegroupwarebase.cpp @@ -217,7 +217,7 @@ void qt_leave_modal( TQWidget *widget ); void ResourceGroupwareBase::enter_loop() { TQWidget dummy(0,0,WType_Dialog | WShowModal); - dummy.setFocusPolicy( TQWidget::NoFocus ); + dummy.setFocusPolicy( Qt::NoFocus ); qt_enter_modal(&dummy); tqApp->enter_loop(); qt_leave_modal(&dummy); diff --git a/kresources/lib/webdavhandler.cpp b/kresources/lib/webdavhandler.cpp index 0eb2144fa..9ae500e52 100644 --- a/kresources/lib/webdavhandler.cpp +++ b/kresources/lib/webdavhandler.cpp @@ -120,7 +120,7 @@ bool WebdavHandler::extractDateTime( const TQDomElement &node, const TQString &e { TQDomElement element = node.namedItem( entry ).toElement(); if ( !element.isNull() && !element.text().isEmpty() ) { - value = TQDateTime::fromString( element.text(), TQt::ISODate ); + value = TQDateTime::fromString( element.text(), Qt::ISODate ); return true; } return false; diff --git a/kresources/newexchange/exchangeconvertercalendar.cpp b/kresources/newexchange/exchangeconvertercalendar.cpp index d28e8b1cf..3ff05eef0 100644 --- a/kresources/newexchange/exchangeconvertercalendar.cpp +++ b/kresources/newexchange/exchangeconvertercalendar.cpp @@ -410,7 +410,7 @@ kdDebug()<<"ExchangeConverterCalendar::readIncidence: ERROR: No UID given"<<endl TQStringList::Iterator it = tmplst.begin(); KCal::DateList exdates; for ( ; it != tmplst.end(); ++it ) { - exdates.append( /*utcAsZone(*/ TQDateTime::fromString( *it, TQt::ISODate )/*, + exdates.append( /*utcAsZone(*/ TQDateTime::fromString( *it, Qt::ISODate )/*, localTimeZoneId )*/.date() ); } event->recurrence()->setExDates( exdates ); @@ -593,7 +593,7 @@ class ExchangeConverterCalendar::createWebDAVVisitor : public IncidenceBase::Vis void addDateProp( TQDomElement &el ) { el.setAttribute( "b:dt", "dateTime.tz" ); } void addFloatProp( TQDomElement &el ) { el.setAttribute( "b:dt", "float" ); } void addIntProp( TQDomElement &el ) { el.setAttribute( "b:dt", "int" ); } - TQString timePropString( const TQDateTime &dt ) { return dt.toString( TQt::ISODate )+"Z"; } + TQString timePropString( const TQDateTime &dt ) { return dt.toString( Qt::ISODate )+"Z"; } bool visitIncidence( Incidence *incidence ) { @@ -730,8 +730,8 @@ class ExchangeConverterCalendar::createWebDAVVisitor : public IncidenceBase::Vis /* FIXME: domCalendarProperty( "uid", todo->uid() ); - domCalendarProperty( "created", todo->created().toString( TQt::ISODate ) ); - domCalendarProperty( "lastmodified", todo->lastModified().toString( TQt::ISODate ) );*/ + domCalendarProperty( "created", todo->created().toString( Qt::ISODate ) ); + domCalendarProperty( "lastmodified", todo->lastModified().toString( Qt::ISODate ) );*/ // TODO /*propertyTask1( TaskProp_Owner ); propertyTask2( TaskProp_ContactNames ); @@ -758,8 +758,8 @@ class ExchangeConverterCalendar::createWebDAVVisitor : public IncidenceBase::Vis "outlookmessageclass", "IPM.Journal" ); /* FIXME: domCalendarProperty( "uid", todo->uid() ); - domCalendarProperty( "created", todo->created().toString( TQt::ISODate ) ); - domCalendarProperty( "lastmodified", todo->lastModified().toString( TQt::ISODate ) );*/ + domCalendarProperty( "created", todo->created().toString( Qt::ISODate ) ); + domCalendarProperty( "lastmodified", todo->lastModified().toString( Qt::ISODate ) );*/ // TODO return true; } diff --git a/kresources/remote/resourceremote.cpp b/kresources/remote/resourceremote.cpp index 229dd86bf..18b8782e1 100644 --- a/kresources/remote/resourceremote.cpp +++ b/kresources/remote/resourceremote.cpp @@ -330,7 +330,7 @@ void ResourceRemote::dump() const void ResourceRemote::addInfoText( TQString &txt ) const { txt += "<br>"; - txt += i18n("URL: %1").arg( mDownloadUrl.prettyURL() ); + txt += i18n("URL: %1").tqarg( mDownloadUrl.prettyURL() ); } bool ResourceRemote::setValue( const TQString &key, const TQString &value ) diff --git a/kresources/scalix/kabc/contact.cpp b/kresources/scalix/kabc/contact.cpp index b8abb42aa..f9a02d448 100644 --- a/kresources/scalix/kabc/contact.cpp +++ b/kresources/scalix/kabc/contact.cpp @@ -71,7 +71,7 @@ TQString Contact::toXml( const KABC::Addressee &addr ) xml += "<reminder_set>" + custom( "reminder_set", addr, "false" ) + "</reminder_set>\n"; xml += "<send_rich_info>" + custom( "send_rich_info", addr, "false" ) + "</send_rich_info>\n"; xml += "<subject>" + addr.formattedName() + "</subject>\n"; - xml += "<last_modification_time>" + addr.revision().toString( TQt::ISODate ) + "</last_modification_time>\n"; + xml += "<last_modification_time>" + addr.revision().toString( Qt::ISODate ) + "</last_modification_time>\n"; xml += "<display_name_prefix>" + addr.prefix() + "</display_name_prefix>\n"; xml += "<first_name>" + addr.givenName() + "</first_name>\n"; @@ -103,19 +103,19 @@ TQString Contact::toXml( const KABC::Addressee &addr ) comment = addr.formattedName(); display = emails[ i ]; } else { - comment = custom( TQString( "email%1_address_with_comment" ).arg( i + 1 ), addr ); - display = custom( TQString( "email%1_display_name" ).arg( i + 1 ), addr ); + comment = custom( TQString( "email%1_address_with_comment" ).tqarg( i + 1 ), addr ); + display = custom( TQString( "email%1_display_name" ).tqarg( i + 1 ), addr ); } } - xml += TQString( "<email%1_address_type>" ).arg( i + 1 ) + type + - TQString( "</email%1_address_type>" ).arg( i + 1 ) +"\n"; - xml += TQString( "<email%1_address>" ).arg( i + 1 ) + address + - TQString( "</email%1_address>" ).arg( i + 1 ) +"\n"; - xml += TQString( "<email%1_address_with_comment>" ).arg( i + 1 ) + comment + - TQString( "</email%1_address_with_comment>" ).arg( i + 1 ) + "\n"; - xml += TQString( "<email%1_display_name>" ).arg( i + 1 ) + display + - TQString( "</email%1_display_name>" ).arg( i + 1 ) + "\n"; + xml += TQString( "<email%1_address_type>" ).tqarg( i + 1 ) + type + + TQString( "</email%1_address_type>" ).tqarg( i + 1 ) +"\n"; + xml += TQString( "<email%1_address>" ).tqarg( i + 1 ) + address + + TQString( "</email%1_address>" ).tqarg( i + 1 ) +"\n"; + xml += TQString( "<email%1_address_with_comment>" ).tqarg( i + 1 ) + comment + + TQString( "</email%1_address_with_comment>" ).tqarg( i + 1 ) + "\n"; + xml += TQString( "<email%1_display_name>" ).tqarg( i + 1 ) + display + + TQString( "</email%1_display_name>" ).tqarg( i + 1 ) + "\n"; } KABC::PhoneNumber phone = addr.phoneNumber( KABC::PhoneNumber::Home ); @@ -166,7 +166,7 @@ TQString Contact::toXml( const KABC::Addressee &addr ) xml += "<office_location>" + addr.custom( "KADDRESSBOOK", "X-Office" ) + "</office_location>\n"; xml += "<spouse>" + addr.custom( "KADDRESSBOOK", "X-SpousesName" ) + "</spouse>\n"; - xml += "<bday>" + addr.birthday().toString( TQt::ISODate ) + "</bday>\n"; + xml += "<bday>" + addr.birthday().toString( Qt::ISODate ) + "</bday>\n"; xml += "<anniversary>" + addr.custom( "KADDRESSBOOK", "X-Anniversary" ) + "</anniversary>\n"; xml += "<mapi_charset>" + custom( "mapi_charset", addr, "UTF8" ) + "</mapi_charset>"; @@ -235,7 +235,7 @@ KABC::Addressee Contact::fromXml( const TQString &xml ) else if ( element.tagName() == "send_rich_info" ) setCustom( "send_rich_info", element.text(), addr ); else if ( element.tagName() == "last_modification_time" ) - addr.setRevision( TQDateTime::fromString( element.text(), TQt::ISODate ) ); + addr.setRevision( TQDateTime::fromString( element.text(), Qt::ISODate ) ); // name else if ( element.tagName() == "display_name_prefix" ) @@ -352,7 +352,7 @@ KABC::Addressee Contact::fromXml( const TQString &xml ) addr.insertCustom( "KADDRESSBOOK", "X-SpousesName", element.text() ); else if ( element.tagName() == "bday" ) - addr.setBirthday( TQDateTime::fromString( element.text(), TQt::ISODate ) ); + addr.setBirthday( TQDateTime::fromString( element.text(), Qt::ISODate ) ); else if ( element.tagName() == "anniversary" ) addr.insertCustom( "KADDRESSBOOK", "X-Anniversary", element.text() ); else diff --git a/kresources/scalix/kcal/resourcescalix.cpp b/kresources/scalix/kcal/resourcescalix.cpp index 8c84977a8..a67585ee0 100644 --- a/kresources/scalix/kcal/resourcescalix.cpp +++ b/kresources/scalix/kcal/resourcescalix.cpp @@ -325,7 +325,7 @@ void ResourceScalix::resolveConflict( KCal::Incidence* inc, const TQString& subr } else if ( result == 0 ) { // take both localIncidence = local->clone(); localIncidence->recreate(); - localIncidence->setSummary( i18n("Copy of: %1").arg(localIncidence->summary()) ); + localIncidence->setSummary( i18n("Copy of: %1").tqarg(localIncidence->summary()) ); addedIncidence = inc; } bool silent = mSilent; diff --git a/kresources/scalix/kioslave/scalix.cpp b/kresources/scalix/kioslave/scalix.cpp index c3a8f99b0..d5603af92 100644 --- a/kresources/scalix/kioslave/scalix.cpp +++ b/kresources/scalix/kioslave/scalix.cpp @@ -104,14 +104,14 @@ void Scalix::retrieveFreeBusy( const KURL &url ) TQByteArray packedArgs; TQDataStream stream( packedArgs, IO_WriteOnly ); - const TQString argument = TQString( "BEGIN:VFREEBUSY\nATTENDEE:MAILTO:%1\nEND:VFREEBUSY" ).arg( requestUser ); - const TQString command = TQString( "X-GET-ICAL-FREEBUSY {%1}" ).arg( argument.length() ); + const TQString argument = TQString( "BEGIN:VFREEBUSY\nATTENDEE:MAILTO:%1\nEND:VFREEBUSY" ).tqarg( requestUser ); + const TQString command = TQString( "X-GET-ICAL-FREEBUSY {%1}" ).tqarg( argument.length() ); stream << (int) 'X' << 'E' << command << argument; - TQString imapUrl = TQString( "imap://%1@%3/" ).arg( url.pass().isEmpty() ? + TQString imapUrl = TQString( "imap://%1@%3/" ).tqarg( url.pass().isEmpty() ? url.user() : url.user() + ":" + url.pass() ) - .arg( url.host() ); + .tqarg( url.host() ); mFreeBusyData = TQString(); @@ -134,7 +134,7 @@ void Scalix::publishFreeBusy( const KURL &url ) TQString path = url.path(); // extract user name - int lastSlash = path.findRev( '/' ); + int lastSlash = path.tqfindRev( '/' ); if ( lastSlash != -1 ) requestUser = path.mid( lastSlash + 1 ); @@ -173,13 +173,13 @@ void Scalix::publishFreeBusy( const KURL &url ) TQDataStream stream( packedArgs, IO_WriteOnly ); const TQString argument = TQString::fromUtf8( data ); - const TQString command = TQString( "X-PUT-ICAL-FREEBUSY Calendar {%1}" ).arg( argument.length() ); + const TQString command = TQString( "X-PUT-ICAL-FREEBUSY Calendar {%1}" ).tqarg( argument.length() ); stream << (int) 'X' << 'E' << command << argument; - TQString imapUrl = TQString( "imap://%1@%3/" ).arg( url.pass().isEmpty() ? + TQString imapUrl = TQString( "imap://%1@%3/" ).tqarg( url.pass().isEmpty() ? url.user() : url.user() + ":" + url.pass() ) - .arg( url.host() ); + .tqarg( url.host() ); KIO::SimpleJob *job = KIO::special( imapUrl, packedArgs, false ); connect( job, TQT_SIGNAL( result( KIO::Job* ) ), diff --git a/kresources/scalix/scalixadmin/jobs.cpp b/kresources/scalix/scalixadmin/jobs.cpp index f1bce9f2c..2d6823918 100644 --- a/kresources/scalix/scalixadmin/jobs.cpp +++ b/kresources/scalix/scalixadmin/jobs.cpp @@ -73,7 +73,7 @@ SetPasswordJob* Scalix::setPassword( KIO::Slave* slave, const KURL& url, TQByteArray packedArgs; TQDataStream stream( packedArgs, IO_WriteOnly ); stream << (int)'X' << (int)'N' - << TQString( "X-SCALIX-PASSWORD" ) << TQString( "%1 %2" ).arg( oldPassword ).arg( newPassword ); + << TQString( "X-SCALIX-PASSWORD" ) << TQString( "%1 %2" ).tqarg( oldPassword ).tqarg( newPassword ); SetPasswordJob* job = new SetPasswordJob( url, packedArgs, false ); KIO::Scheduler::assignJobToSlave( slave, job ); @@ -95,7 +95,7 @@ SetDelegateJob* Scalix::setDelegate( KIO::Slave* slave, const KURL& url, const T TQByteArray packedArgs; TQDataStream stream( packedArgs, IO_WriteOnly ); stream << (int)'X' << (int)'N' - << TQString( "X-SET-DELEGATE" ) << TQString( "%1 %2" ).arg( email ).arg( types.join( " " ) ); + << TQString( "X-SET-DELEGATE" ) << TQString( "%1 %2" ).tqarg( email ).tqarg( types.join( " " ) ); SetDelegateJob* job = new SetDelegateJob( url, packedArgs, false ); KIO::Scheduler::assignJobToSlave( slave, job ); @@ -164,9 +164,9 @@ GetOtherUsersJob* Scalix::getOtherUsers( KIO::Slave* slave, const KURL& url ) SetOutOfOfficeJob* Scalix::setOutOfOffice( KIO::Slave* slave, const KURL& url, bool enabled, const TQString& msg ) { const TQString argument = msg; - const TQString command = TQString( "X-SET-OUT-OF-OFFICE %1 %2 {%3}" ).arg( enabled ? "ENABLED" : "DISABLED" ) - .arg( "UTF-8" ) - .arg( msg.utf8().length() ); + const TQString command = TQString( "X-SET-OUT-OF-OFFICE %1 %2 {%3}" ).tqarg( enabled ? "ENABLED" : "DISABLED" ) + .tqarg( "UTF-8" ) + .tqarg( msg.utf8().length() ); TQByteArray packedArgs; TQDataStream stream( packedArgs, IO_WriteOnly ); diff --git a/kresources/scalix/scalixadmin/ldapview.cpp b/kresources/scalix/scalixadmin/ldapview.cpp index 04351395e..bade9e16b 100644 --- a/kresources/scalix/scalixadmin/ldapview.cpp +++ b/kresources/scalix/scalixadmin/ldapview.cpp @@ -85,8 +85,8 @@ void LdapView::setQuery( const TQString &query ) void LdapView::entryAdded( const KABC::LdapObject &obj ) { - const TQString text = TQString( "%1 (%2)" ).arg( obj.attrs[ "surname" ].first() ) - .arg( obj.attrs[ "mail" ].first() ); + const TQString text = TQString( "%1 (%2)" ).tqarg( TQString(obj.attrs[ "surname" ].first()) ) + .tqarg( TQString(obj.attrs[ "mail" ].first()) ); new LdapItem( this, text, obj.attrs[ "mail" ].first() ); } diff --git a/kresources/scalix/scalixadmin/outofofficepage.cpp b/kresources/scalix/scalixadmin/outofofficepage.cpp index d56e8954e..7b2f2ac60 100644 --- a/kresources/scalix/scalixadmin/outofofficepage.cpp +++ b/kresources/scalix/scalixadmin/outofofficepage.cpp @@ -38,7 +38,7 @@ OutOfOfficePage::OutOfOfficePage( TQWidget *tqparent ) { TQGridLayout *tqlayout = new TQGridLayout( this, 4, 2, 11, 6 ); - TQButtonGroup *group = new TQButtonGroup( 1, TQt::Vertical, this ); + TQButtonGroup *group = new TQButtonGroup( 1, Qt::Vertical, this ); mDisabled = new TQRadioButton( i18n( "I am in the office" ), group ); mDisabled->setChecked( true ); diff --git a/kresources/scalix/scalixadmin/passwordpage.cpp b/kresources/scalix/scalixadmin/passwordpage.cpp index 53a163b83..0781e3a41 100644 --- a/kresources/scalix/scalixadmin/passwordpage.cpp +++ b/kresources/scalix/scalixadmin/passwordpage.cpp @@ -179,7 +179,7 @@ void PasswordPage::finished( KIO::Job* job ) group.writeEntry( "pass", KStringHandler::obscure( newPassword ) ); } - KConfigGroup fileGroup( &config, TQString( "Folder-%1" ).arg( group.readNumEntry( "Folder" ) ) ); + KConfigGroup fileGroup( &config, TQString( "Folder-%1" ).tqarg( group.readNumEntry( "Folder" ) ) ); fileGroup.writeEntry( "pass", KStringHandler::obscure( newPassword ) ); } } diff --git a/kresources/scalix/scalixadmin/settings.cpp b/kresources/scalix/scalixadmin/settings.cpp index 52f72296f..d5c5cdb1c 100644 --- a/kresources/scalix/scalixadmin/settings.cpp +++ b/kresources/scalix/scalixadmin/settings.cpp @@ -92,8 +92,8 @@ TQString Settings::rulesWizardUrl() const TQString url = group.readEntry( "rulesWizardUrl" ); if ( url.isEmpty() ) { KConfigGroup group( &config, "Account" ); - url = TQString( "http://%1/Scalix/rw/?username=%2" ).arg( group.readEntry( "host" ) ) - .arg( group.readEntry( "user" ) ); + url = TQString( "http://%1/Scalix/rw/?username=%2" ).tqarg( group.readEntry( "host" ) ) + .tqarg( group.readEntry( "user" ) ); } return url; diff --git a/kresources/scalix/shared/resourcescalixbase.cpp b/kresources/scalix/shared/resourcescalixbase.cpp index c9c7ee11d..c9bfca350 100644 --- a/kresources/scalix/shared/resourcescalixbase.cpp +++ b/kresources/scalix/shared/resourcescalixbase.cpp @@ -130,7 +130,7 @@ bool ResourceScalixBase::kmailUpdate( const TQString& resource, TQString ResourceScalixBase::configFile( const TQString& type ) const { return locateLocal( "config", - TQString( "kresources/scalix/%1rc" ).arg( type ) ); + TQString( "kresources/scalix/%1rc" ).tqarg( type ) ); } bool ResourceScalixBase::connectToKMail() const diff --git a/kresources/scalix/shared/scalixbase.cpp b/kresources/scalix/shared/scalixbase.cpp index 64400e4f8..337899035 100644 --- a/kresources/scalix/shared/scalixbase.cpp +++ b/kresources/scalix/shared/scalixbase.cpp @@ -372,12 +372,12 @@ TQDomDocument ScalixBase::domTree() TQString ScalixBase::dateTimeToString( const TQDateTime& time ) { - return time.toString( TQt::ISODate ) + 'Z'; + return time.toString( Qt::ISODate ) + 'Z'; } TQString ScalixBase::dateToString( const TQDate& date ) { - return date.toString( TQt::ISODate ); + return date.toString( Qt::ISODate ); } TQDateTime ScalixBase::stringToDateTime( const TQString& _date ) @@ -385,12 +385,12 @@ TQDateTime ScalixBase::stringToDateTime( const TQString& _date ) TQString date( _date ); if ( date.endsWith( "Z" ) ) date.truncate( date.length() - 1 ); - return TQDateTime::fromString( date, TQt::ISODate ); + return TQDateTime::fromString( date, Qt::ISODate ); } TQDate ScalixBase::stringToDate( const TQString& date ) { - return TQDate::fromString( date, TQt::ISODate ); + return TQDate::fromString( date, Qt::ISODate ); } TQString ScalixBase::sensitivityToString( Sensitivity s ) diff --git a/kresources/slox/kabcresourceslox.cpp b/kresources/slox/kabcresourceslox.cpp index 76e233ce8..82d5c60a5 100644 --- a/kresources/slox/kabcresourceslox.cpp +++ b/kresources/slox/kabcresourceslox.cpp @@ -401,7 +401,7 @@ void ResourceSlox::parseContactAttribute( const TQDomElement &e, Addressee &a ) a.insertCustom( "KADDRESSBOOK", "X-SpousesName", text ); } else if ( tag == fieldName( Anniversary ) ) { TQDateTime dt = WebdavHandler::sloxToTQDateTime( text ); - a.insertCustom( "KADDRESSBOOK", "X-Anniversary", dt.toString( TQt::ISODate ) ); + a.insertCustom( "KADDRESSBOOK", "X-Anniversary", dt.toString( Qt::ISODate ) ); } else if ( tag == fieldName( Categories ) ) { a.setCategories( TQStringList::split( TQRegExp(",\\s*"), text ) ); } else if ( type() == "ox" ) { // FIXME: Address reading is missing for SLOX @@ -576,7 +576,7 @@ void ResourceSlox::createAddresseeFields( TQDomDocument &doc, TQDomElement &prop TQString anniversary = a.custom( "KADDRESSBOOK", "X-Anniversary" ); if ( !anniversary.isEmpty() ) WebdavHandler::addSloxElement( this, doc, prop, fieldName( Anniversary ), - WebdavHandler::qDateTimeToSlox( TQDateTime::fromString( anniversary, TQt::ISODate ).date() ) ); + WebdavHandler::qDateTimeToSlox( TQDateTime::fromString( anniversary, Qt::ISODate ).date() ) ); else WebdavHandler::addSloxElement( this, doc, prop, fieldName( Anniversary ) ); } diff --git a/kresources/slox/kcalresourceslox.cpp b/kresources/slox/kcalresourceslox.cpp index 40afcd7e8..132f19ca1 100644 --- a/kresources/slox/kcalresourceslox.cpp +++ b/kresources/slox/kcalresourceslox.cpp @@ -177,7 +177,7 @@ bool KCalResourceSlox::doLoad() TQString p = KURL( mPrefs->url() ).protocol(); if ( p != "http" && p != "https" && p != "webdav" && p != "webdavs" ) { - TQString err = i18n("Non-http protocol: '%1'").arg( p ); + TQString err = i18n("Non-http protocol: '%1'").tqarg( p ); kdDebug() << "KCalResourceSlox::load(): " << err << endl; loadError( err ); return false; diff --git a/kresources/slox/webdavhandler.cpp b/kresources/slox/webdavhandler.cpp index b010e0e92..4bd588c4b 100644 --- a/kresources/slox/webdavhandler.cpp +++ b/kresources/slox/webdavhandler.cpp @@ -199,7 +199,7 @@ TQDateTime WebdavHandler::sloxToTQDateTime( const TQString &str ) TQDateTime dt; if (preEpoch) { - dt.setTime_t( 0, TQt::UTC ); + dt.setTime_t( 0, Qt::UTC ); if (ticks > INT_MAX) { dt = dt.addSecs(-INT_MAX); ticks -= INT_MAX; @@ -208,7 +208,7 @@ TQDateTime WebdavHandler::sloxToTQDateTime( const TQString &str ) } else { - dt.setTime_t( ticks, TQt::UTC ); + dt.setTime_t( ticks, Qt::UTC ); } return dt; diff --git a/ktnef/gui/attachpropertydialog.cpp b/ktnef/gui/attachpropertydialog.cpp index 7fd6cacf5..fcc1a8a0a 100644 --- a/ktnef/gui/attachpropertydialog.cpp +++ b/ktnef/gui/attachpropertydialog.cpp @@ -178,7 +178,7 @@ TQPixmap loadRenderingPixmap( KTNEFPropertySet *pSet, const TQColor& bgColor ) { pix.resize( w, h ); pix.fill( bgColor ); - wmfLoader.paint( &pix ); + wmfLoader.paint( &TQT_TQPAINTDEVICE_OBJECT(pix) ); } wmfBuffer.close(); } diff --git a/ktnef/gui/ktnefmain.cpp b/ktnef/gui/ktnefmain.cpp index fd9438e6c..d6781770e 100644 --- a/ktnef/gui/ktnefmain.cpp +++ b/ktnef/gui/ktnefmain.cpp @@ -85,19 +85,19 @@ KTNEFMain::~KTNEFMain() void KTNEFMain::setupActions() { // File menu - KStdAction::open(this, TQT_SLOT(openFile()), actionCollection()); - KStdAction::quit(kapp, TQT_SLOT(quit()), actionCollection()); + KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(openFile()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(quit()), actionCollection()); // Action menu - new KAction(i18n("View"), TQString("viewmag"), 0, this, TQT_SLOT(viewFile()), actionCollection(), "view_file"); - new KAction(i18n("View With..."), TQString("package_applications"), 0, this, TQT_SLOT(viewFileAs()), actionCollection(), "view_file_as"); - new KAction(i18n("Extract"), 0, this, TQT_SLOT(extractFile()), actionCollection(), "extract_file"); - new KAction(i18n("Extract To..."), TQString("ktnef_extract_to"), 0, this, TQT_SLOT(extractFileTo()), actionCollection(), "extract_file_to"); - new KAction(i18n("Extract All To..."), TQString("ktnef_extract_all_to"), 0, this, TQT_SLOT(extractAllFiles()), actionCollection(), "extract_all_files"); - new KAction( i18n( "Message Properties" ), "help", 0, this, TQT_SLOT( slotShowMessageProperties() ), actionCollection(), "msg_properties" ); - new KAction(i18n("Properties"), TQString("contents"), 0, this, TQT_SLOT(propertiesFile()), actionCollection(), "properties_file"); - new KAction( i18n( "Show Message Text" ), "mail_generic", 0, this, TQT_SLOT( slotShowMessageText() ), actionCollection(), "msg_text" ); - new KAction( i18n( "Save Message Text As..." ), "filesave", 0, this, TQT_SLOT( slotSaveMessageText() ), actionCollection(), "msg_save" ); + new KAction(i18n("View"), TQString("viewmag"), 0, TQT_TQOBJECT(this), TQT_SLOT(viewFile()), actionCollection(), "view_file"); + new KAction(i18n("View With..."), TQString("package_applications"), 0, TQT_TQOBJECT(this), TQT_SLOT(viewFileAs()), actionCollection(), "view_file_as"); + new KAction(i18n("Extract"), 0, TQT_TQOBJECT(this), TQT_SLOT(extractFile()), actionCollection(), "extract_file"); + new KAction(i18n("Extract To..."), TQString("ktnef_extract_to"), 0, TQT_TQOBJECT(this), TQT_SLOT(extractFileTo()), actionCollection(), "extract_file_to"); + new KAction(i18n("Extract All To..."), TQString("ktnef_extract_all_to"), 0, TQT_TQOBJECT(this), TQT_SLOT(extractAllFiles()), actionCollection(), "extract_all_files"); + new KAction( i18n( "Message Properties" ), "help", 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowMessageProperties() ), actionCollection(), "msg_properties" ); + new KAction(i18n("Properties"), TQString("contents"), 0, TQT_TQOBJECT(this), TQT_SLOT(propertiesFile()), actionCollection(), "properties_file"); + new KAction( i18n( "Show Message Text" ), "mail_generic", 0, TQT_TQOBJECT(this), TQT_SLOT( slotShowMessageText() ), actionCollection(), "msg_text" ); + new KAction( i18n( "Save Message Text As..." ), "filesave", 0, TQT_TQOBJECT(this), TQT_SLOT( slotSaveMessageText() ), actionCollection(), "msg_save" ); actionCollection()->action("view_file")->setEnabled(false); actionCollection()->action("view_file_as")->setEnabled(false); actionCollection()->action("extract_file")->setEnabled(false); @@ -106,12 +106,12 @@ void KTNEFMain::setupActions() actionCollection()->action("properties_file")->setEnabled(false); // Option menu - new KAction(i18n("Default Folder..."), TQString("folder_open"), 0, this, TQT_SLOT(optionDefaultDir()), actionCollection(), "options_default_dir"); + new KAction(i18n("Default Folder..."), TQString("folder_open"), 0, TQT_TQOBJECT(this), TQT_SLOT(optionDefaultDir()), actionCollection(), "options_default_dir"); createStandardStatusBarAction(); setStandardToolBarMenuEnabled(true); - KStdAction::configureToolbars(this, TQT_SLOT(slotEditToolbars()), actionCollection()); - KStdAction::keyBindings( this, TQT_SLOT( slotConfigureKeys() ), actionCollection() ); + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(slotEditToolbars()), actionCollection()); + KStdAction::keyBindings( TQT_TQOBJECT(this), TQT_SLOT( slotConfigureKeys() ), actionCollection() ); createGUI(); } @@ -230,7 +230,7 @@ void KTNEFMain::extractAllFiles() for (;it.current();++it) if (!parser_->extractFileTo(it.current()->name(), dir)) { - TQString msg = i18n( "Unable to extract file \"%1\"" ).arg( it.current()->name() ); + TQString msg = i18n( "Unable to extract file \"%1\"" ).tqarg( it.current()->name() ); TQMessageBox::critical(this,i18n("Error"),msg,TQMessageBox::Ok|TQMessageBox::Default,0); return; } @@ -301,7 +301,7 @@ void KTNEFMain::extractTo(const TQString& dirname) for (;it.current();++it) if (!parser_->extractFileTo(it.current()->name(), dir)) { - TQString msg = i18n("Unable to extract file \"%1\"").arg( it.current()->name() ); + TQString msg = i18n("Unable to extract file \"%1\"").tqarg( it.current()->name() ); TQMessageBox::critical(this,i18n("Error"),msg,TQMessageBox::Ok|TQMessageBox::Default,0); return; } diff --git a/ktnef/gui/qwmf.cpp b/ktnef/gui/qwmf.cpp index 8f8cd4d28..d60d661d3 100644 --- a/ktnef/gui/qwmf.cpp +++ b/ktnef/gui/qwmf.cpp @@ -136,13 +136,13 @@ bool TQWinMetaFile::load( const TQString &filename ) if ( !file.exists() ) { - kdDebug() << "File " << TQFile::encodeName(filename) << " does not exist" << endl; + kdDebug() << TQString("File ") << TQString(TQFile::encodeName(filename)) << TQString(" does not exist") << endl; return false; } if ( !file.open( IO_ReadOnly ) ) { - kdDebug() << "Cannot open file " << TQFile::encodeName(filename) << endl; + kdDebug() << TQString("Cannot open file ") << TQString(TQFile::encodeName(filename)) << endl; return false; } @@ -348,7 +348,7 @@ bool TQWinMetaFile::paint( const TQPaintDevice* aTarget, bool absolute ) mWinding = false; mAbsoluteCoord = absolute; - mPainter.begin( aTarget ); + mPainter.begin( TQT_TQPAINTDEVICE(const_cast<TQPaintDevice*>(aTarget)) ); if ( TQWMF_DEBUG ) { kdDebug() << "Bounding box : " << mBBox.left() << " " << mBBox.top() << " " << mBBox.right() << " " << mBBox.bottom() << endl; @@ -482,7 +482,7 @@ void TQWinMetaFile::polygon( long, short* parm ) TQPointArray* pa; pa = pointArray( parm[ 0 ], &parm[ 1 ] ); - mPainter.drawPolygon( *pa, mWinding ); + mPainter.tqdrawPolygon( *pa, mWinding ); } @@ -620,8 +620,8 @@ void TQWinMetaFile::setBkColor( long, short* parm ) //----------------------------------------------------------------------------- void TQWinMetaFile::setBkMode( long, short* parm ) { - if ( parm[ 0 ]==1 ) mPainter.setBackgroundMode( TQt::TransparentMode ); - else mPainter.setBackgroundMode( TQt::OpaqueMode ); + if ( parm[ 0 ]==1 ) mPainter.setBackgroundMode( Qt::TransparentMode ); + else mPainter.setBackgroundMode( Qt::OpaqueMode ); } @@ -925,26 +925,26 @@ void TQWinMetaFile::createEmptyObject( long, short* ) //----------------------------------------------------------------------------- void TQWinMetaFile::createBrushIndirect( long, short* parm ) { - static TQt::BrushStyle hatchedStyleTab[] = + static Qt::BrushStyle hatchedStyleTab[] = { - TQt::HorPattern, - TQt::FDiagPattern, - TQt::BDiagPattern, - TQt::CrossPattern, - TQt::DiagCrossPattern + Qt::HorPattern, + Qt::FDiagPattern, + Qt::BDiagPattern, + Qt::CrossPattern, + Qt::DiagCrossPattern }; - static TQt::BrushStyle styleTab[] = - { TQt::SolidPattern, - TQt::NoBrush, - TQt::FDiagPattern, /* hatched */ - TQt::Dense4Pattern, /* should be custom bitmap pattern */ - TQt::HorPattern, /* should be BS_INDEXED (?) */ - TQt::VerPattern, /* should be tqdevice-independent bitmap */ - TQt::Dense6Pattern, /* should be tqdevice-independent packed-bitmap */ - TQt::Dense2Pattern, /* should be BS_PATTERN8x8 */ - TQt::Dense3Pattern /* should be tqdevice-independent BS_DIBPATTERN8x8 */ + static Qt::BrushStyle styleTab[] = + { Qt::SolidPattern, + Qt::NoBrush, + Qt::FDiagPattern, /* hatched */ + Qt::Dense4Pattern, /* should be custom bitmap pattern */ + Qt::HorPattern, /* should be BS_INDEXED (?) */ + Qt::VerPattern, /* should be tqdevice-independent bitmap */ + Qt::Dense6Pattern, /* should be tqdevice-independent packed-bitmap */ + Qt::Dense2Pattern, /* should be BS_PATTERN8x8 */ + Qt::Dense3Pattern /* should be tqdevice-independent BS_DIBPATTERN8x8 */ }; - TQt::BrushStyle style; + Qt::BrushStyle style; short arg; WinObjBrushHandle* handle = new WinObjBrushHandle; addHandle( handle ); @@ -957,7 +957,7 @@ void TQWinMetaFile::createBrushIndirect( long, short* parm ) else { kdDebug() << "TQWinMetaFile::createBrushIndirect: invalid hatched brush " << arg << endl; - style = TQt::SolidPattern; + style = Qt::SolidPattern; } } else if ( arg>=0 && arg<9 ) @@ -965,7 +965,7 @@ void TQWinMetaFile::createBrushIndirect( long, short* parm ) else { kdDebug() << "TQWinMetaFile::createBrushIndirect: invalid brush " << arg << endl; - style = TQt::SolidPattern; + style = Qt::SolidPattern; } handle->brush.setStyle( style ); handle->brush.setColor( color( parm+1 ) ); @@ -975,10 +975,10 @@ void TQWinMetaFile::createBrushIndirect( long, short* parm ) //----------------------------------------------------------------------------- void TQWinMetaFile::createPenIndirect( long, short* parm ) { - static TQt::PenStyle styleTab[] = - { TQt::SolidLine, TQt::DashLine, TQt::DotLine, TQt::DashDotLine, TQt::DashDotDotLine, - TQt::NoPen, TQt::SolidLine }; - TQt::PenStyle style; + static Qt::PenStyle styleTab[] = + { Qt::SolidLine, Qt::DashLine, Qt::DotLine, Qt::DashDotLine, Qt::DashDotDotLine, + Qt::NoPen, Qt::SolidLine }; + Qt::PenStyle style; WinObjPenHandle* handle = new WinObjPenHandle; addHandle( handle ); @@ -986,12 +986,12 @@ void TQWinMetaFile::createPenIndirect( long, short* parm ) else { kdDebug() << "TQWinMetaFile::createPenIndirect: invalid pen " << parm[ 0 ] << endl; - style = TQt::SolidLine; + style = Qt::SolidLine; } handle->pen.setStyle( style ); handle->pen.setColor( color( parm+3 ) ); - handle->pen.setCapStyle( TQt::RoundCap ); + handle->pen.setCapStyle( Qt::RoundCap ); //int width = 0; // TODO : width of pen proportional to tqdevice context width diff --git a/ktnef/lib/ktnefmessage.cpp b/ktnef/lib/ktnefmessage.cpp index 8a8bf0655..202f080a1 100644 --- a/ktnef/lib/ktnefmessage.cpp +++ b/ktnef/lib/ktnefmessage.cpp @@ -76,7 +76,7 @@ TQString KTNEFMessage::rtfString() TQByteArray rtf; TQBuffer input( prop.asByteArray() ), output( rtf ); if ( input.open( IO_ReadOnly ) && output.open( IO_WriteOnly ) ) - lzfu_decompress( &input, &output ); + lzfu_decompress( &TQT_TQIODEVICE_OBJECT(input), &TQT_TQIODEVICE_OBJECT(output) ); return TQString( rtf ); } } diff --git a/ktnef/lib/ktnefparser.cpp b/ktnef/lib/ktnefparser.cpp index cd0063466..41bb2b687 100644 --- a/ktnef/lib/ktnefparser.cpp +++ b/ktnef/lib/ktnefparser.cpp @@ -162,7 +162,7 @@ bool KTNEFParser::decodeMessage() readMAPIProperties( d->message_->properties(), 0 ); d->tqdevice_->at( i2 ); kdDebug() << "Properties: " << d->message_->properties().count() << endl; - value = TQString( "< %1 properties >" ).arg( d->message_->properties().count() - nProps ); + value = TQString( "< %1 properties >" ).tqarg( d->message_->properties().count() - nProps ); } break; case attTNEFVERSION: @@ -275,7 +275,7 @@ bool KTNEFParser::decodeAttachment() d->current_->setSize( i ); d->current_->setOffset( d->tqdevice_->at() ); d->tqdevice_->at( d->tqdevice_->at() + i ); - value = TQString( "< size=%1 >" ).arg( i ); + value = TQString( "< size=%1 >" ).tqarg( i ); kdDebug() << "Attachment Data: size=" << i << endl; break; case attATTACHMENT: // try to get attachment info @@ -292,7 +292,7 @@ bool KTNEFParser::decodeAttachment() if ( !str.isEmpty() ) d->current_->setMimeTag( str ); d->current_->setExtension( d->current_->property( MAPI_TAG_EXTENSION ).toString() ); - value = TQString( "< %1 properties >" ).arg( d->current_->properties().count() ); + value = TQString( "< %1 properties >" ).tqarg( d->current_->properties().count() ); break; case attATTACHMODDATE: value = readTNEFDate( d->stream_ ); @@ -304,7 +304,7 @@ bool KTNEFParser::decodeAttachment() break; case attATTACHMETAFILE: kdDebug() << "Attachment Metafile: size=" << i << endl; - //value = TQString( "< size=%1 >" ).arg( i ); + //value = TQString( "< size=%1 >" ).tqarg( i ); //d->tqdevice_->at( d->tqdevice_->at()+i ); value = readTNEFData( d->stream_, i ); break; @@ -447,7 +447,7 @@ bool KTNEFParser::openFile(const TQString& filename) deleteDevice(); delete d->message_; d->message_ = new KTNEFMessage(); - d->tqdevice_ = new TQFile( filename ); + d->tqdevice_ = TQT_TQIODEVICE(new TQFile( filename )); d->deleteDevice_ = true; return parseDevice(); } @@ -814,7 +814,7 @@ bool KTNEFParser::readMAPIProperties( TQMap<int,KTNEFProperty*>& props, KTNEFAtt ALIGN( len, 4 ) attach->setSize( len ); attach->setOffset( d->tqdevice_->at() - len ); - attach->addAttribute( attATTACHDATA, atpBYTE, TQString( "< size=%1 >" ).arg( len ), false ); + attach->addAttribute( attATTACHDATA, atpBYTE, TQString( "< size=%1 >" ).tqarg( len ), false ); } } kdDebug().form( "MAPI data: size=%d\n", mapi.value.toByteArray().size() ); @@ -827,7 +827,7 @@ bool KTNEFParser::readMAPIProperties( TQMap<int,KTNEFProperty*>& props, KTNEFAtt if ( mapi.name.type == 0 ) mapiname = TQString().sprintf( " [name = 0x%04x]", mapi.name.value.toUInt() ); else - mapiname = TQString( " [name = %1]" ).arg( mapi.name.value.toString() ); + mapiname = TQString( " [name = %1]" ).tqarg( mapi.name.value.toString() ); } switch ( mapi.type & 0x0FFF ) { diff --git a/libemailfunctions/email.cpp b/libemailfunctions/email.cpp index c97bebaf9..f5c35c17f 100644 --- a/libemailfunctions/email.cpp +++ b/libemailfunctions/email.cpp @@ -132,7 +132,7 @@ KPIM::EmailParseResult splitAddressInternal( const TQCString& address, int commentLevel = 0; bool stop = false; - for ( char* p = address.data(); *p && !stop; ++p ) { + for ( const char* p = address.data(); *p && !stop; ++p ) { switch ( context ) { case TopLevel : { switch ( *p ) { @@ -524,7 +524,7 @@ bool KPIM::isValidSimpleEmailAddress( const TQString& aStr ) return false; } - int atChar = aStr.findRev( '@' ); + int atChar = aStr.tqfindRev( '@' ); TQString domainPart = aStr.mid( atChar + 1); TQString localPart = aStr.left( atChar ); bool tooManyAtsFlag = false; @@ -832,7 +832,7 @@ TQString KPIM::normalizedAddress( const TQString & displayName, //----------------------------------------------------------------------------- TQString KPIM::decodeIDN( const TQString & addrSpec ) { - const int atPos = addrSpec.findRev( '@' ); + const int atPos = addrSpec.tqfindRev( '@' ); if ( atPos == -1 ) return addrSpec; @@ -847,7 +847,7 @@ TQString KPIM::decodeIDN( const TQString & addrSpec ) //----------------------------------------------------------------------------- TQString KPIM::encodeIDN( const TQString & addrSpec ) { - const int atPos = addrSpec.findRev( '@' ); + const int atPos = addrSpec.tqfindRev( '@' ); if ( atPos == -1 ) return addrSpec; diff --git a/libkcal/attachmenthandler.cpp b/libkcal/attachmenthandler.cpp index eb0fc2b77..4922cb12d 100644 --- a/libkcal/attachmenthandler.cpp +++ b/libkcal/attachmenthandler.cpp @@ -70,7 +70,7 @@ Attachment *AttachmentHandler::tqfind( TQWidget *tqparent, const TQString &attac if ( !a ) { KMessageBox::error( tqparent, - i18n( "No attachment named \"%1\" found in the incidence." ).arg( attachmentName ) ); + i18n( "No attachment named \"%1\" found in the incidence." ).tqarg( attachmentName ) ); return 0; } @@ -101,7 +101,7 @@ Attachment *AttachmentHandler::tqfind( TQWidget *tqparent, KMessageBox::error( tqparent, i18n( "The incidence that owns the attachment named \"%1\" could not be found. " - "Perhaps it was removed from your calendar?" ).arg( attachmentName ) ); + "Perhaps it was removed from your calendar?" ).tqarg( attachmentName ) ); return 0; } diff --git a/libkcal/calformat.cpp b/libkcal/calformat.cpp index 12ba30696..be26c3fcf 100644 --- a/libkcal/calformat.cpp +++ b/libkcal/calformat.cpp @@ -70,9 +70,9 @@ TQString CalFormat::createUniqueId() TQTime::currentTime().minute() + TQTime::currentTime().second() + TQTime::currentTime().msec(); TQString uidStr = TQString("%1-%2.%3") - .arg(mApplication) - .arg(KApplication::random()) - .arg(hashTime); + .tqarg(mApplication) + .tqarg(KApplication::random()) + .tqarg(hashTime); return uidStr; } diff --git a/libkcal/calhelper.cpp b/libkcal/calhelper.cpp index bb1442f53..73940b5d8 100644 --- a/libkcal/calhelper.cpp +++ b/libkcal/calhelper.cpp @@ -162,6 +162,6 @@ TQPair<ResourceCalendar *, TQString> CalHelper::incSubResourceCalendar( Calendar if ( res && res->canHaveSubresources() ) { subRes = res->subresourceIdentifier( incidence ); } - p = qMakePair( res, subRes ); + p = tqMakePair( res, subRes ); return p; } diff --git a/libkcal/confirmsavedialog.cpp b/libkcal/confirmsavedialog.cpp index 0d9edf1e9..b1e32f32e 100644 --- a/libkcal/confirmsavedialog.cpp +++ b/libkcal/confirmsavedialog.cpp @@ -40,7 +40,7 @@ ConfirmSaveDialog::ConfirmSaveDialog( const TQString &destination, TQLabel *label = new TQLabel( i18n("You have requested to save the following objects to '%1':") - .arg( destination ), topFrame ); + .tqarg( destination ), topFrame ); topLayout->addWidget( label ); mListView = new KListView( topFrame ); diff --git a/libkcal/convertqtopia.cpp b/libkcal/convertqtopia.cpp index 0e4b4352c..4af6affa7 100644 --- a/libkcal/convertqtopia.cpp +++ b/libkcal/convertqtopia.cpp @@ -105,7 +105,7 @@ int main(int argc,char **argv) } else { bool success = icalendarFormat.save( &cal, outputFile ); if ( !success ) { - std::cerr << i18n( "Error saving to '%1'." ).arg( outputFile ).local8Bit() + std::cerr << i18n( "Error saving to '%1'." ).tqarg( outputFile ).local8Bit() << std::endl; return 1; } diff --git a/libkcal/dndfactory.cpp b/libkcal/dndfactory.cpp index 913036d36..fd1ef20d3 100644 --- a/libkcal/dndfactory.cpp +++ b/libkcal/dndfactory.cpp @@ -178,7 +178,7 @@ bool DndFactory::cutIncidences( const Incidence::List &incidences ) bool DndFactory::copyIncidences( const Incidence::List &incidences ) { - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); CalendarLocal cal( mCalendar->timeZoneId() ); Incidence::List::ConstIterator it; @@ -206,7 +206,7 @@ bool DndFactory::copyIncidence( Incidence *selectedInc ) Incidence::List DndFactory::pasteIncidences( const TQDate &newDate, const TQTime *newTime ) { CalendarLocal cal( mCalendar->timeZoneId() ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); Incidence::List list; if ( !ICalDrag::decode( cb->data(), &cal ) && @@ -249,7 +249,7 @@ Incidence::List DndFactory::pasteIncidences( const TQDate &newDate, const TQTime Incidence *DndFactory::pasteIncidence( const TQDate &newDate, const TQTime *newTime ) { CalendarLocal cal( mCalendar->timeZoneId() ); - TQClipboard *cb = TQApplication::clipboard(); + TQClipboard *cb = TQApplication::tqclipboard(); if ( !ICalDrag::decode( cb->data(), &cal ) && !VCalDrag::decode( cb->data(), &cal ) ) { diff --git a/libkcal/exceptions.cpp b/libkcal/exceptions.cpp index 99c804ddf..0394a4003 100644 --- a/libkcal/exceptions.cpp +++ b/libkcal/exceptions.cpp @@ -38,7 +38,7 @@ Exception::~Exception() TQString Exception::message() { if ( mMessage.isEmpty() ) { - return i18n( "%1 Error" ).arg( CalFormat::application() ); + return i18n( "%1 Error" ).tqarg( CalFormat::application() ); } else { return mMessage; } diff --git a/libkcal/htmlexport.cpp b/libkcal/htmlexport.cpp index 387ba1730..cbe3f6d7e 100644 --- a/libkcal/htmlexport.cpp +++ b/libkcal/htmlexport.cpp @@ -147,8 +147,8 @@ void HtmlExport::createMonthView(TQTextStream *ts) while ( start < toDate() ) { // Write header - *ts << "<h2>" << (i18n("month_year","%1 %2").arg(KGlobal::locale()->calendar()->monthName(start)) - .arg(start.year())) << "</h2>\n"; + *ts << "<h2>" << (i18n("month_year","%1 %2").tqarg(KGlobal::locale()->calendar()->monthName(start)) + .tqarg(start.year())) << "</h2>\n"; if ( KGlobal::locale()->weekStartDay() == 1 ) { start = start.addDays(1 - start.dayOfWeek()); } else { @@ -244,7 +244,7 @@ void HtmlExport::createEventList (TQTextStream *ts) *ts << " </tr>\n"; for ( TQDate dt = fromDate(); dt <= toDate(); dt = dt.addDays(1) ) { - kdDebug(5850) << "Getting events for " << dt.toString() << endl; + kdDebug(5850) << "Getting events for " << TQString(dt.toString()) << endl; Event::List events = mCalendar->events(dt, EventSortStartDate, SortDirectionAscending ); @@ -459,7 +459,7 @@ void HtmlExport::createTodo (TQTextStream *ts,Todo *todo) *ts << " <td"; if (completed) *ts << " class=\"done\""; *ts << ">\n"; - *ts << " " << i18n("%1 %").arg(todo->percentComplete()) << "\n"; + *ts << " " << i18n("%1 %").tqarg(todo->percentComplete()) << "\n"; *ts << " </td>\n"; if ( mSettings->taskDueDate() ) { @@ -618,20 +618,20 @@ void HtmlExport::createFooter( TQTextStream *ts ) TQString mail, name, credit, creditURL;*/ if (!mSettings->eMail().isEmpty()) { if (!mSettings->name().isEmpty()) - trailer += i18n("by <a href=\"mailto:%1\">%2</a> ").arg( mSettings->eMail() ).arg( mSettings->name() ); + trailer += i18n("by <a href=\"mailto:%1\">%2</a> ").tqarg( mSettings->eMail() ).tqarg( mSettings->name() ); else - trailer += i18n("by <a href=\"mailto:%1\">%2</a> ").arg( mSettings->eMail() ).arg( mSettings->eMail() ); + trailer += i18n("by <a href=\"mailto:%1\">%2</a> ").tqarg( mSettings->eMail() ).tqarg( mSettings->eMail() ); } else { if (!mSettings->name().isEmpty()) - trailer += i18n("by %1 ").arg( mSettings->name() ); + trailer += i18n("by %1 ").tqarg( mSettings->name() ); } if (!mSettings->creditName().isEmpty()) { if (!mSettings->creditURL().isEmpty()) trailer += i18n("with <a href=\"%1\">%2</a>") - .arg( mSettings->creditURL() ) - .arg( mSettings->creditName() ); + .tqarg( mSettings->creditURL() ) + .tqarg( mSettings->creditName() ); else - trailer += i18n("with %1").arg( mSettings->creditName() ); + trailer += i18n("with %1").tqarg( mSettings->creditName() ); } *ts << "<p>" << trailer << "</p>\n"; } @@ -706,7 +706,7 @@ void HtmlExport::addHoliday( const TQDate &date, const TQString &name) if ( mHolidayMap[date].isEmpty() ) { mHolidayMap[date] = name; } else { - mHolidayMap[date] = i18n("list of holidays", "%1, %2").arg(mHolidayMap[date]).arg(name); + mHolidayMap[date] = i18n("list of holidays", "%1, %2").tqarg(mHolidayMap[date]).tqarg(name); } } diff --git a/libkcal/icalformat.cpp b/libkcal/icalformat.cpp index 8c1cd3b0b..ce3f8002f 100644 --- a/libkcal/icalformat.cpp +++ b/libkcal/icalformat.cpp @@ -117,7 +117,7 @@ bool ICalFormat::save( Calendar *calendar, const TQString &fileName ) kdDebug(5800) << "ICalFormat::save() errno: " << strerror( file.status() ) << endl; setException( new ErrorFormat( ErrorFormat::SaveError, - i18n( "Error saving to '%1'." ).arg( fileName ) ) ); + i18n( "Error saving to '%1'." ).tqarg( fileName ) ) ); return false; } @@ -128,7 +128,7 @@ bool ICalFormat::save( Calendar *calendar, const TQString &fileName ) if ( !file.close() ) { kdDebug(5800) << "KSaveFile: close: status was " << file.status() << ". See errno.h." << endl; setException(new ErrorFormat(ErrorFormat::SaveError, - i18n("Could not save '%1'").arg(fileName))); + i18n("Could not save '%1'").tqarg(fileName))); return false; } diff --git a/libkcal/icalformatimpl.cpp b/libkcal/icalformatimpl.cpp index 297118b59..f53ec1e16 100644 --- a/libkcal/icalformatimpl.cpp +++ b/libkcal/icalformatimpl.cpp @@ -1133,11 +1133,11 @@ FreeBusy *ICalFormatImpl::readFreeBusy(icalcomponent *vfreebusy) while ( param ) { if ( strncmp( icalparameter_get_xname( param ), "X-SUMMARY", 9 ) == 0 ) { period.setSummary( TQString::fromUtf8( - KCodecs::base64Decode( icalparameter_get_xvalue( param ) ) ) ); + KCodecs::base64Decode( TQByteArray( icalparameter_get_xvalue( param ) ) ) ) ); } if ( strncmp( icalparameter_get_xname( param ), "X-LOCATION", 10 ) == 0 ) { period.setLocation( TQString::fromUtf8( - KCodecs::base64Decode( icalparameter_get_xvalue( param ) ) ) ); + KCodecs::base64Decode( TQByteArray( icalparameter_get_xvalue( param ) ) ) ) ); } param = icalproperty_get_next_parameter( p, ICAL_X_PARAMETER ); } @@ -1171,7 +1171,7 @@ Attendee *ICalFormatImpl::readAttendee(icalproperty *attendee) icalparameter *p = 0; TQString email = TQString::fromUtf8(icalproperty_get_attendee(attendee)); - if ( email.startsWith( "mailto:", false ) ) { + if ( email.tqstartsWith( "mailto:", false ) ) { email = email.mid( 7 ); } @@ -1267,7 +1267,7 @@ Attendee *ICalFormatImpl::readAttendee(icalproperty *attendee) Person ICalFormatImpl::readOrganizer( icalproperty *organizer ) { TQString email = TQString::fromUtf8(icalproperty_get_organizer(organizer)); - if ( email.startsWith( "mailto:", false ) ) { + if ( email.tqstartsWith( "mailto:", false ) ) { email = email.mid( 7 ); } TQString cn; @@ -1855,7 +1855,7 @@ void ICalFormatImpl::readAlarm(icalcomponent *alarm,Incidence *incidence) // Only in EMAIL alarm case ICAL_ATTENDEE_PROPERTY: { TQString email = TQString::fromUtf8(icalproperty_get_attendee(p)); - if ( email.startsWith("mailto:", false ) ) { + if ( email.tqstartsWith("mailto:", false ) ) { email = email.mid( 7 ); } TQString name; @@ -2166,7 +2166,7 @@ bool ICalFormatImpl::populate( Calendar *cal, icalcomponent *calendar ) if (todo) { if (todo->hasRecurrenceID()) { TQString originalUid = todo->uid(); - todo->setUid(originalUid + TQString("-recur-%1").arg(todo->recurrenceID().toTime_t())); + todo->setUid(originalUid + TQString("-recur-%1").tqarg(todo->recurrenceID().toTime_t())); if (!cal->todo(todo->uid())) { if ( !cal->addTodo( todo ) ) { cal->endBatchAdding(); @@ -2208,7 +2208,7 @@ bool ICalFormatImpl::populate( Calendar *cal, icalcomponent *calendar ) if (event) { if (event->hasRecurrenceID()) { TQString originalUid = event->uid(); - event->setUid(originalUid + TQString("-recur-%1").arg(event->recurrenceID().toTime_t())); + event->setUid(originalUid + TQString("-recur-%1").tqarg(event->recurrenceID().toTime_t())); if (!cal->event(event->uid())) { cal->addEvent(event); if (!cal->event(originalUid)) { @@ -2246,7 +2246,7 @@ bool ICalFormatImpl::populate( Calendar *cal, icalcomponent *calendar ) if (journal) { if (journal->hasRecurrenceID()) { TQString originalUid = journal->uid(); - journal->setUid(originalUid + TQString("-recur-%1").arg(journal->recurrenceID().toTime_t())); + journal->setUid(originalUid + TQString("-recur-%1").tqarg(journal->recurrenceID().toTime_t())); if (!cal->journal(journal->uid())) { cal->addJournal(journal); if (!cal->event(originalUid)) { diff --git a/libkcal/incidencebase.cpp b/libkcal/incidencebase.cpp index bddfcb5a7..52e08080f 100644 --- a/libkcal/incidencebase.cpp +++ b/libkcal/incidencebase.cpp @@ -174,7 +174,7 @@ void IncidenceBase::setOrganizer( const Person &o ) void IncidenceBase::setOrganizer(const TQString &o) { TQString mail( o ); - if ( mail.startsWith("MAILTO:", false) ) + if ( mail.tqstartsWith("MAILTO:", false) ) mail = mail.remove( 0, 7 ); // split the string into full name plus email. Person organizer( mail ); diff --git a/libkcal/incidenceformatter.cpp b/libkcal/incidenceformatter.cpp index d7dd97e4d..36f988752 100644 --- a/libkcal/incidenceformatter.cpp +++ b/libkcal/incidenceformatter.cpp @@ -248,10 +248,10 @@ static TQString displayViewFormatAttendeeRoleList( Incidence *incidence, Attende } tmpStr += displayViewLinkPerson( a->email(), a->name(), a->uid() ); if ( !a->delegator().isEmpty() ) { - tmpStr += i18n(" (delegated by %1)" ).arg( a->delegator() ); + tmpStr += i18n(" (delegated by %1)" ).tqarg( a->delegator() ); } if ( !a->delegate().isEmpty() ) { - tmpStr += i18n(" (delegated to %1)" ).arg( a->delegate() ); + tmpStr += i18n(" (delegated to %1)" ).tqarg( a->delegate() ); } tmpStr += "<br>"; } @@ -359,7 +359,7 @@ static TQString displayViewFormatCategories( Incidence *incidence ) static TQString displayViewFormatCreationDate( Incidence *incidence ) { return i18n( "Creation date: %1" ). - arg( IncidenceFormatter::dateTimeToString( incidence->created(), false, true ) ); + tqarg( IncidenceFormatter::dateTimeToString( incidence->created(), false, true ) ); } static TQString displayViewFormatBirthday( Event *event ) @@ -502,14 +502,14 @@ static TQString displayViewFormatEvent( Calendar *calendar, Event *event, tmpStr += "<td><b>" + i18n( "Date:" ) + "</b></td>"; tmpStr += "<td>" + i18n("<beginDate> - <endDate>","%1 - %2"). - arg( IncidenceFormatter::dateToString( startDt, false ) ). - arg( IncidenceFormatter::dateToString( endDt, false ) ) + + tqarg( IncidenceFormatter::dateToString( startDt, false ) ). + tqarg( IncidenceFormatter::dateToString( endDt, false ) ) + "</td>"; } else { tmpStr += "<td><b>" + i18n( "Date:" ) + "</b></td>"; tmpStr += "<td>" + i18n("date as string","%1"). - arg( IncidenceFormatter::dateToString( startDt, false ) ) + + tqarg( IncidenceFormatter::dateToString( startDt, false ) ) + "</td>"; } } else { @@ -517,14 +517,14 @@ static TQString displayViewFormatEvent( Calendar *calendar, Event *event, tmpStr += "<td><b>" + i18n( "Date:" ) + "</b></td>"; tmpStr += "<td>" + i18n("<beginDate> - <endDate>","%1 - %2"). - arg( IncidenceFormatter::dateToString( startDt, false ) ). - arg( IncidenceFormatter::dateToString( endDt, false ) ) + + tqarg( IncidenceFormatter::dateToString( startDt, false ) ). + tqarg( IncidenceFormatter::dateToString( endDt, false ) ) + "</td>"; } else { tmpStr += "<td><b>" + i18n( "Date:" ) + "</b></td>"; tmpStr += "<td>" + i18n("date as string","%1"). - arg( IncidenceFormatter::dateToString( startDt, false ) ) + + tqarg( IncidenceFormatter::dateToString( startDt, false ) ) + "</td>"; tmpStr += "</tr><tr>"; @@ -532,8 +532,8 @@ static TQString displayViewFormatEvent( Calendar *calendar, Event *event, if ( event->hasEndDate() && startDt != endDt ) { tmpStr += "<td>" + i18n("<beginTime> - <endTime>","%1 - %2"). - arg( IncidenceFormatter::timeToString( startDt, true ) ). - arg( IncidenceFormatter::timeToString( endDt, true ) ) + + tqarg( IncidenceFormatter::timeToString( startDt, true ) ). + tqarg( IncidenceFormatter::timeToString( endDt, true ) ) + "</td>"; } else { tmpStr += "<td>" + @@ -750,7 +750,7 @@ static TQString displayViewFormatTodo( Calendar *calendar, Todo *todo, } else { tmpStr += "<td><b>" + i18n( "Percent Done:" ) + "</b></td>"; tmpStr += "<td>"; - tmpStr += i18n( "%1%" ).arg( todo->percentComplete() ); + tmpStr += i18n( "%1%" ).tqarg( todo->percentComplete() ); } tmpStr += "</td>"; tmpStr += "</tr>"; @@ -833,11 +833,11 @@ static TQString displayViewFormatFreeBusy( Calendar * /*calendar*/, FreeBusy *fb TQString tmpStr = htmlAddTag( "h2", htmlAddTag( "b", i18n("Free/Busy information for %1"). - arg( fb->organizer().fullName() ) ) ); + tqarg( fb->organizer().fullName() ) ) ); tmpStr += htmlAddTag( "h4", i18n("Busy times in date range %1 - %2:"). - arg( IncidenceFormatter::dateToString( fb->dtStart(), true ) ). - arg( IncidenceFormatter::dateToString( fb->dtEnd(), true ) ) ); + tqarg( IncidenceFormatter::dateToString( fb->dtStart(), true ) ). + tqarg( IncidenceFormatter::dateToString( fb->dtEnd(), true ) ) ); TQValueList<Period> periods = fb->busyPeriods(); @@ -860,19 +860,19 @@ static TQString displayViewFormatFreeBusy( Calendar * /*calendar*/, FreeBusy *fb cont += i18n("1 second", "%n seconds", dur); } text += i18n("startDate for duration", "%1 for %2"). - arg( IncidenceFormatter::dateTimeToString( per.start(), false, true ) ). - arg( cont ); + tqarg( IncidenceFormatter::dateTimeToString( per.start(), false, true ) ). + tqarg( cont ); text += "<br>"; } else { if ( per.start().date() == per.end().date() ) { text += i18n("date, fromTime - toTime ", "%1, %2 - %3"). - arg( IncidenceFormatter::dateToString( per.start().date(), true ) ). - arg( IncidenceFormatter::timeToString( per.start(), true ) ). - arg( IncidenceFormatter::timeToString( per.end(), true ) ); + tqarg( IncidenceFormatter::dateToString( per.start().date(), true ) ). + tqarg( IncidenceFormatter::timeToString( per.start(), true ) ). + tqarg( IncidenceFormatter::timeToString( per.end(), true ) ); } else { text += i18n("fromDateTime - toDateTime", "%1 - %2"). - arg( IncidenceFormatter::dateTimeToString( per.start(), false, true ) ). - arg( IncidenceFormatter::dateTimeToString( per.end(), false, true ) ); + tqarg( IncidenceFormatter::dateTimeToString( per.start(), false, true ) ). + tqarg( IncidenceFormatter::dateTimeToString( per.end(), false, true ) ); } text += "<br>"; } @@ -969,11 +969,11 @@ static TQString eventStartTimeStr( Event *event ) TQString tmp; if ( !event->doesFloat() ) { tmp = i18n( "%1: Start Date, %2: Start Time", "%1 %2" ). - arg( IncidenceFormatter::dateToString( event->dtStart(), true ), + tqarg( IncidenceFormatter::dateToString( event->dtStart(), true ), IncidenceFormatter::timeToString( event->dtStart(), true ) ); } else { tmp = i18n( "%1: Start Date", "%1 (all day)" ). - arg( IncidenceFormatter::dateToString( event->dtStart(), true ) ); + tqarg( IncidenceFormatter::dateToString( event->dtStart(), true ) ); } return tmp; } @@ -984,11 +984,11 @@ static TQString eventEndTimeStr( Event *event ) if ( event->hasEndDate() && event->dtEnd().isValid() ) { if ( !event->doesFloat() ) { tmp = i18n( "%1: End Date, %2: End Time", "%1 %2" ). - arg( IncidenceFormatter::dateToString( event->dtEnd(), true ), + tqarg( IncidenceFormatter::dateToString( event->dtEnd(), true ), IncidenceFormatter::timeToString( event->dtEnd(), true ) ); } else { tmp = i18n( "%1: End Date", "%1 (all day)" ). - arg( IncidenceFormatter::dateToString( event->dtEnd(), true ) ); + tqarg( IncidenceFormatter::dateToString( event->dtEnd(), true ) ); } } return tmp; @@ -1106,13 +1106,13 @@ static TQString rsvpRequestedStr( bool rsvpRequested, const TQString &role ) if ( role.isEmpty() ) { return i18n( "Your response is requested" ); } else { - return i18n( "Your response as <b>%1</b> is requested" ).arg( role ); + return i18n( "Your response as <b>%1</b> is requested" ).tqarg( role ); } } else { if ( role.isEmpty() ) { return i18n( "No response is necessary" ); } else { - return i18n( "No response as <b>%1</b> is necessary" ).arg( role ); + return i18n( "No response as <b>%1</b> is necessary" ).tqarg( role ); } } } @@ -1124,7 +1124,7 @@ static TQString myStatusStr( Incidence *incidence ) if ( a && a->status() != Attendee::NeedsAction && a->status() != Attendee::Delegated ) { ret = i18n( "(<b>Note</b>: the Organizer preset your response to <b>%1</b>)" ). - arg( Attendee::statusName( a->status() ) ); + tqarg( Attendee::statusName( a->status() ) ); } return ret; } @@ -1302,7 +1302,7 @@ static TQString invitationDetailsEvent( Event* event, bool noHtmlMode ) } TQString dir = ( TQApplication::reverseLayout() ? "rtl" : "ltr" ); - TQString html = TQString("<div dir=\"%1\">\n").arg(dir); + TQString html = TQString("<div dir=\"%1\">\n").tqarg(dir); html += "<table border=\"0\" cellpadding=\"1\" cellspacing=\"1\">\n"; @@ -1413,7 +1413,7 @@ static TQString invitationDetailsTodo( Todo *todo, bool noHtmlMode ) } TQString dir = ( TQApplication::reverseLayout() ? "rtl" : "ltr" ); - TQString html = TQString("<div dir=\"%1\">\n").arg(dir); + TQString html = TQString("<div dir=\"%1\">\n").tqarg(dir); html += "<table border=\"0\" cellpadding=\"1\" cellspacing=\"1\">\n"; // Invitation summary & location rows @@ -1511,19 +1511,19 @@ static TQString invitationDetailsFreeBusy( FreeBusy *fb, bool /*noHtmlMode*/ ) cont += i18n("1 second", "%n seconds", dur); } html += invitationRow( TQString(), i18n("startDate for duration", "%1 for %2") - .arg( KGlobal::locale()->formatDateTime( per.start(), false ) ) - .arg(cont) ); + .tqarg( KGlobal::locale()->formatDateTime( per.start(), false ) ) + .tqarg(cont) ); } else { TQString cont; if ( per.start().date() == per.end().date() ) { cont = i18n("date, fromTime - toTime ", "%1, %2 - %3") - .arg( KGlobal::locale()->formatDate( per.start().date() ) ) - .arg( KGlobal::locale()->formatTime( per.start().time() ) ) - .arg( KGlobal::locale()->formatTime( per.end().time() ) ); + .tqarg( KGlobal::locale()->formatDate( per.start().date() ) ) + .tqarg( KGlobal::locale()->formatTime( per.start().time() ) ) + .tqarg( KGlobal::locale()->formatTime( per.end().time() ) ); } else { cont = i18n("fromDateTime - toDateTime", "%1 - %2") - .arg( KGlobal::locale()->formatDateTime( per.start(), false ) ) - .arg( KGlobal::locale()->formatDateTime( per.end(), false ) ); + .tqarg( KGlobal::locale()->formatDateTime( per.start(), false ) ) + .tqarg( KGlobal::locale()->formatDateTime( per.end(), false ) ); } html += invitationRow( TQString(), cont ); @@ -1565,7 +1565,7 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc case Scheduler::Request: if ( existingIncidence && event->revision() > 0 ) { return i18n( "This invitation has been updated by the organizer %1" ). - arg( event->organizer().fullName() ); + tqarg( event->organizer().fullName() ); } if ( iamOrganizer( event ) ) { return i18n( "I created this invitation" ); @@ -1578,17 +1578,17 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc } if ( senderIsOrganizer( event, sender ) ) { if ( !orgStr.isEmpty() ) { - return i18n( "You received an invitation from %1" ).arg( orgStr ); + return i18n( "You received an invitation from %1" ).tqarg( orgStr ); } else { return i18n( "You received an invitation" ); } } else { if ( !orgStr.isEmpty() ) { return i18n( "You received an invitation from %1 as a representative of %2" ). - arg( sender, orgStr ); + tqarg( sender, orgStr ); } else { return i18n( "You received an invitation from %1 as the organizer's representative" ). - arg( sender ); + tqarg( sender ); } } } @@ -1602,7 +1602,7 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc { if ( replyMeansCounter( event ) ) { return i18n( "%1 makes this counter proposal" ). - arg( firstAttendeeName( event, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( event, i18n( "Sender" ) ) ); } Attendee::List attendees = event->attendees(); @@ -1625,36 +1625,36 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc switch( attendee->status() ) { case Attendee::NeedsAction: - return i18n( "%1 indicates this invitation still needs some action" ).arg( attendeeName ); + return i18n( "%1 indicates this invitation still needs some action" ).tqarg( attendeeName ); case Attendee::Accepted: if ( event->revision() > 0 ) { if ( !sender.isEmpty() ) { - return i18n( "This invitation has been updated by attendee %1" ).arg( sender ); + return i18n( "This invitation has been updated by attendee %1" ).tqarg( sender ); } else { return i18n( "This invitation has been updated by an attendee" ); } } else { if ( delegatorName.isEmpty() ) { - return i18n( "%1 accepts this invitation" ).arg( attendeeName ); + return i18n( "%1 accepts this invitation" ).tqarg( attendeeName ); } else { return i18n( "%1 accepts this invitation on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } } case Attendee::Tentative: if ( delegatorName.isEmpty() ) { return i18n( "%1 tentatively accepts this invitation" ). - arg( attendeeName ); + tqarg( attendeeName ); } else { return i18n( "%1 tentatively accepts this invitation on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } case Attendee::Declined: if ( delegatorName.isEmpty() ) { - return i18n( "%1 declines this invitation" ).arg( attendeeName ); + return i18n( "%1 declines this invitation" ).tqarg( attendeeName ); } else { return i18n( "%1 declines this invitation on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } case Attendee::Delegated: { TQString delegate, dummy; @@ -1664,16 +1664,16 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc } if ( !delegate.isEmpty() ) { return i18n( "%1 has delegated this invitation to %2" ). - arg( attendeeName ) .arg( delegate ); + tqarg( attendeeName ) .tqarg( delegate ); } else { - return i18n( "%1 has delegated this invitation" ).arg( attendeeName ); + return i18n( "%1 has delegated this invitation" ).tqarg( attendeeName ); } } case Attendee::Completed: return i18n( "This invitation is now completed" ); case Attendee::InProcess: return i18n( "%1 is still processing the invitation" ). - arg( attendeeName ); + tqarg( attendeeName ); default: return i18n( "Unknown response to this invitation" ); } @@ -1682,15 +1682,15 @@ static TQString invitationHeaderEvent( Event *event, Incidence *existingIncidenc case Scheduler::Counter: return i18n( "%1 makes this counter proposal" ). - arg( firstAttendeeName( event, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( event, i18n( "Sender" ) ) ); case Scheduler::Declinecounter: return i18n( "%1 declines the counter proposal" ). - arg( firstAttendeeName( event, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( event, i18n( "Sender" ) ) ); case Scheduler::NoMethod: return i18n("Error: iMIP message with unknown method: '%1'"). - arg( msg->method() ); + tqarg( msg->method() ); } return TQString(); } @@ -1708,7 +1708,7 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, case Scheduler::Request: if ( existingIncidence && todo->revision() > 0 ) { return i18n( "This task has been updated by the organizer %1" ). - arg( todo->organizer().fullName() ); + tqarg( todo->organizer().fullName() ); } else { if ( iamOrganizer( todo ) ) { return i18n( "I created this task" ); @@ -1721,17 +1721,17 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, } if ( senderIsOrganizer( todo, sender ) ) { if ( !orgStr.isEmpty() ) { - return i18n( "You have been assigned this task by %1" ).arg( orgStr ); + return i18n( "You have been assigned this task by %1" ).tqarg( orgStr ); } else { return i18n( "You have been assigned this task" ); } } else { if ( !orgStr.isEmpty() ) { return i18n( "You have been assigned this task by %1 as a representative of %2" ). - arg( sender, orgStr ); + tqarg( sender, orgStr ); } else { return i18n( "You have been assigned this task by %1 as the organizer's representative" ). - arg( sender ); + tqarg( sender ); } } } @@ -1746,7 +1746,7 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, { if ( replyMeansCounter( todo ) ) { return i18n( "%1 makes this counter proposal" ). - arg( firstAttendeeName( todo, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( todo, i18n( "Sender" ) ) ); } Attendee::List attendees = todo->attendees(); @@ -1769,14 +1769,14 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, switch( attendee->status() ) { case Attendee::NeedsAction: - return i18n( "%1 indicates this task assignment still needs some action" ).arg( attendeeName ); + return i18n( "%1 indicates this task assignment still needs some action" ).tqarg( attendeeName ); case Attendee::Accepted: if ( todo->revision() > 0 ) { if ( !sender.isEmpty() ) { if ( todo->isCompleted() ) { - return i18n( "This task has been completed by assignee %1" ).arg( sender ); + return i18n( "This task has been completed by assignee %1" ).tqarg( sender ); } else { - return i18n( "This task has been updated by assignee %1" ).arg( sender ); + return i18n( "This task has been updated by assignee %1" ).tqarg( sender ); } } else { if ( todo->isCompleted() ) { @@ -1787,26 +1787,26 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, } } else { if ( delegatorName.isEmpty() ) { - return i18n( "%1 accepts this task" ).arg( attendeeName ); + return i18n( "%1 accepts this task" ).tqarg( attendeeName ); } else { return i18n( "%1 accepts this task on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } } case Attendee::Tentative: if ( delegatorName.isEmpty() ) { return i18n( "%1 tentatively accepts this task" ). - arg( attendeeName ); + tqarg( attendeeName ); } else { return i18n( "%1 tentatively accepts this task on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } case Attendee::Declined: if ( delegatorName.isEmpty() ) { - return i18n( "%1 declines this task" ).arg( attendeeName ); + return i18n( "%1 declines this task" ).tqarg( attendeeName ); } else { return i18n( "%1 declines this task on behalf of %2" ). - arg( attendeeName ).arg( delegatorName ); + tqarg( attendeeName ).tqarg( delegatorName ); } case Attendee::Delegated: { TQString delegate, dummy; @@ -1816,17 +1816,17 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, } if ( !delegate.isEmpty() ) { return i18n( "%1 has delegated this request for the task to %2" ). - arg( attendeeName ).arg( delegate ); + tqarg( attendeeName ).tqarg( delegate ); } else { return i18n( "%1 has delegated this request for the task" ). - arg( attendeeName ); + tqarg( attendeeName ); } } case Attendee::Completed: return i18n( "The request for this task is now completed" ); case Attendee::InProcess: return i18n( "%1 is still processing the task" ). - arg( attendeeName ); + tqarg( attendeeName ); default: return i18n( "Unknown response to this task" ); } @@ -1835,15 +1835,15 @@ static TQString invitationHeaderTodo( Todo *todo, Incidence *existingIncidence, case Scheduler::Counter: return i18n( "%1 makes this counter proposal" ). - arg( firstAttendeeName( todo, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( todo, i18n( "Sender" ) ) ); case Scheduler::Declinecounter: return i18n( "%1 declines the counter proposal" ). - arg( firstAttendeeName( todo, i18n( "Sender" ) ) ); + tqarg( firstAttendeeName( todo, i18n( "Sender" ) ) ); case Scheduler::NoMethod: return i18n( "Error: iMIP message with unknown method: '%1'" ). - arg( msg->method() ); + tqarg( msg->method() ); } return TQString(); } @@ -1908,7 +1908,7 @@ static TQString invitationHeaderJournal( Journal *journal, ScheduleMessage *msg return i18n( "Sender declines the counter proposal" ); case Scheduler::NoMethod: return i18n("Error: iMIP message with unknown method: '%1'"). - arg( msg->method() ); + tqarg( msg->method() ); } return TQString(); } @@ -1933,7 +1933,7 @@ static TQString invitationHeaderFreeBusy( FreeBusy *fb, ScheduleMessage *msg ) case Scheduler::NoMethod: default: return i18n("Error: Free/Busy iMIP message with unknown method: '%1'"). - arg( msg->method() ); + tqarg( msg->method() ); } } @@ -1967,10 +1967,10 @@ static TQString invitationAttendees( Incidence *incidence ) tmpStr += "<td>"; tmpStr += invitationPerson( a->email(), a->name(), TQString() ); if ( !a->delegator().isEmpty() ) { - tmpStr += i18n(" (delegated by %1)" ).arg( a->delegator() ); + tmpStr += i18n(" (delegated by %1)" ).tqarg( a->delegator() ); } if ( !a->delegate().isEmpty() ) { - tmpStr += i18n(" (delegated to %1)" ).arg( a->delegate() ); + tmpStr += i18n(" (delegated to %1)" ).tqarg( a->delegate() ); } tmpStr += "</td>"; tmpStr += "<td>" + a->statusStr() + "</td>"; @@ -2156,10 +2156,10 @@ class IncidenceFormatter::IncidenceCompareVisitor return; if ( oldEvent->dtStart() != newEvent->dtStart() || oldEvent->doesFloat() != newEvent->doesFloat() ) mChanges += i18n( "The invitation starting time has been changed from %1 to %2" ) - .arg( eventStartTimeStr( oldEvent ) ).arg( eventStartTimeStr( newEvent ) ); + .tqarg( eventStartTimeStr( oldEvent ) ).tqarg( eventStartTimeStr( newEvent ) ); if ( oldEvent->dtEnd() != newEvent->dtEnd() || oldEvent->doesFloat() != newEvent->doesFloat() ) mChanges += i18n( "The invitation ending time has been changed from %1 to %2" ) - .arg( eventEndTimeStr( oldEvent ) ).arg( eventEndTimeStr( newEvent ) ); + .tqarg( eventEndTimeStr( oldEvent ) ).tqarg( eventEndTimeStr( newEvent ) ); } void compareTodos( Todo *newTodo, Todo *oldTodo ) @@ -2175,10 +2175,10 @@ class IncidenceFormatter::IncidenceCompareVisitor mChanges += i18n( "The task is no longer completed" ); } if ( oldTodo->percentComplete() != newTodo->percentComplete() ) { - const TQString oldPer = i18n( "%1%" ).arg( oldTodo->percentComplete() ); - const TQString newPer = i18n( "%1%" ).arg( newTodo->percentComplete() ); + const TQString oldPer = i18n( "%1%" ).tqarg( oldTodo->percentComplete() ); + const TQString newPer = i18n( "%1%" ).tqarg( newTodo->percentComplete() ); mChanges += i18n( "The task completed percentage has changed from %1 to %2" ). - arg( oldPer, newPer ); + tqarg( oldPer, newPer ); } if ( !oldTodo->hasStartDate() && newTodo->hasStartDate() ) { @@ -2190,7 +2190,7 @@ class IncidenceFormatter::IncidenceCompareVisitor if ( oldTodo->hasStartDate() && newTodo->hasStartDate() && oldTodo->dtStart() != newTodo->dtStart() ) { mChanges += i18n( "The task starting time has been changed from %1 to %2" ). - arg( dateTimeToString( oldTodo->dtStart(), oldTodo->doesFloat(), false ), + tqarg( dateTimeToString( oldTodo->dtStart(), oldTodo->doesFloat(), false ), dateTimeToString( newTodo->dtStart(), newTodo->doesFloat(), false ) ); } @@ -2203,7 +2203,7 @@ class IncidenceFormatter::IncidenceCompareVisitor if ( oldTodo->hasDueDate() && newTodo->hasDueDate() && oldTodo->dtDue() != newTodo->dtDue() ) { mChanges += i18n( "The task due time has been changed from %1 to %2" ). - arg( dateTimeToString( oldTodo->dtDue(), oldTodo->doesFloat(), false ), + tqarg( dateTimeToString( oldTodo->dtDue(), oldTodo->doesFloat(), false ), dateTimeToString( newTodo->dtDue(), newTodo->doesFloat(), false ) ); } } @@ -2213,22 +2213,22 @@ class IncidenceFormatter::IncidenceCompareVisitor if ( !oldInc || !newInc ) return; if ( oldInc->summary() != newInc->summary() ) - mChanges += i18n( "The summary has been changed to: \"%1\"" ).arg( newInc->summary() ); + mChanges += i18n( "The summary has been changed to: \"%1\"" ).tqarg( newInc->summary() ); if ( oldInc->location() != newInc->location() ) - mChanges += i18n( "The location has been changed to: \"%1\"" ).arg( newInc->location() ); + mChanges += i18n( "The location has been changed to: \"%1\"" ).tqarg( newInc->location() ); if ( oldInc->description() != newInc->description() ) - mChanges += i18n( "The description has been changed to: \"%1\"" ).arg( newInc->description() ); + mChanges += i18n( "The description has been changed to: \"%1\"" ).tqarg( newInc->description() ); Attendee::List oldAttendees = oldInc->attendees(); Attendee::List newAttendees = newInc->attendees(); for ( Attendee::List::ConstIterator it = newAttendees.constBegin(); it != newAttendees.constEnd(); ++it ) { Attendee *oldAtt = oldInc->attendeeByMail( (*it)->email() ); if ( !oldAtt ) { - mChanges += i18n( "Attendee %1 has been added" ).arg( (*it)->fullName() ); + mChanges += i18n( "Attendee %1 has been added" ).tqarg( (*it)->fullName() ); } else { if ( oldAtt->status() != (*it)->status() ) mChanges += i18n( "The status of attendee %1 has been changed to: %2" ). - arg( (*it)->fullName() ).arg( (*it)->statusStr() ); + tqarg( (*it)->fullName() ).tqarg( (*it)->statusStr() ); } } if ( method == Scheduler::Request ) { @@ -2237,7 +2237,7 @@ class IncidenceFormatter::IncidenceCompareVisitor if ( (*it)->email() != oldInc->organizer().email() ) { Attendee *newAtt = newInc->attendeeByMail( (*it)->email() ); if ( !newAtt ) { - mChanges += i18n( "Attendee %1 has been removed" ).arg( (*it)->fullName() ); + mChanges += i18n( "Attendee %1 has been removed" ).tqarg( (*it)->fullName() ); } } } @@ -2255,12 +2255,12 @@ TQString InvitationFormatterHelper::makeLink( const TQString &id, const TQString { if ( !id.startsWith( "ATTACH:" ) ) { TQString res = TQString( "<a href=\"%1\"><b>%2</b></a>" ). - arg( generateLinkURL( id ), text ); + tqarg( generateLinkURL( id ), text ); return res; } else { // draw the attachment links in non-bold face TQString res = TQString( "<a href=\"%1\">%2</a>" ). - arg( generateLinkURL( id ), text ); + tqarg( generateLinkURL( id ), text ); return res; } } @@ -2431,7 +2431,7 @@ TQString IncidenceFormatter::formatICalInvitationHelper( TQString invitation, TQString tableHead = TQString::tqfromLatin1( "<div align=\"center\">" "<table width=\"80%\" cellpadding=\"1\" cellspacing=\"0\" %1>" - "<tr><td>").arg(tableStyle); + "<tr><td>").tqarg(tableStyle); html += tableHead; InvitationHeaderVisitor headerVisitor; @@ -2459,7 +2459,7 @@ TQString IncidenceFormatter::formatICalInvitationHelper( TQString invitation, if ( compareVisitor.act( incBase, existingIncidence, msg->method() ) ) { html += "<p align=\"left\">"; if ( !sender.isEmpty() ) { - html += i18n( "The following changes have been made by %1:" ).arg( sender ); + html += i18n( "The following changes have been made by %1:" ).tqarg( sender ); } else { html += i18n( "The following changes have been made by an attendee:" ); } @@ -2514,10 +2514,10 @@ TQString IncidenceFormatter::formatICalInvitationHelper( TQString invitation, if ( rsvpRec && inc ) { if ( inc->revision() == 0 ) { html += i18n( "Your <b>%1</b> response has already been recorded" ). - arg( ea->statusStr() ); + tqarg( ea->statusStr() ); } else { html += i18n( "Your status for this invitation is <b>%1</b>" ). - arg( ea->statusStr() ); + tqarg( ea->statusStr() ); } rsvpReq = false; } else if ( msg->method() == Scheduler::Cancel ) { @@ -2627,7 +2627,7 @@ TQString IncidenceFormatter::formatICalInvitationHelper( TQString invitation, if ( ea && ( ea->status() != Attendee::NeedsAction ) && ( ea->status() == a->status() ) ) { if ( inc && inc->revision() > 0 ) { html += "<br><u><i>"; - html += i18n( "The response has been recorded [%1]" ).arg( ea->statusStr() ); + html += i18n( "The response has been recorded [%1]" ).tqarg( ea->statusStr() ); html += "</i></u>"; } } else { @@ -2837,7 +2837,7 @@ TQString IncidenceFormatter::msTNEFToVPart( const TQByteArray& tnef ) ICalFormat calFormat; Event* event = new Event(); - if( parser.openDevice( &buf ) ) { + if( parser.openDevice( &TQT_TQIODEVICE_OBJECT(buf) ) ) { KTNEFMessage* tnefMsg = parser.message(); //TQMap<int,KTNEFProperty*> props = parser.message()->properties(); @@ -3218,20 +3218,20 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Event *event, const tmp = "<br>" + i18n("Event start", "<i>From:</i> %1"); if (event->doesFloat()) - ret += tmp.arg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); + ret += tmp.tqarg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); else - ret += tmp.arg( IncidenceFormatter::dateToString( startDt ).tqreplace(" ", " ") ); + ret += tmp.tqarg( IncidenceFormatter::dateToString( startDt ).tqreplace(" ", " ") ); tmp = "<br>" + i18n("Event end","<i>To:</i> %1"); if (event->doesFloat()) - ret += tmp.arg( IncidenceFormatter::dateToString( endDt, false ).tqreplace(" ", " ") ); + ret += tmp.tqarg( IncidenceFormatter::dateToString( endDt, false ).tqreplace(" ", " ") ); else - ret += tmp.arg( IncidenceFormatter::dateToString( endDt ).tqreplace(" ", " ") ); + ret += tmp.tqarg( IncidenceFormatter::dateToString( endDt ).tqreplace(" ", " ") ); } else { ret += "<br>"+i18n("<i>Date:</i> %1"). - arg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); + tqarg( IncidenceFormatter::dateToString( startDt, false ).tqreplace(" ", " ") ); if ( !event->doesFloat() ) { const TQString dtStartTime = IncidenceFormatter::timeToString( startDt, true ).tqreplace( " ", " " ); @@ -3240,11 +3240,11 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Event *event, const if ( dtStartTime == dtEndTime ) { // to prevent 'Time: 17:00 - 17:00' tmp = "<br>" + i18n("time for event, to prevent ugly line breaks", "<i>Time:</i> %1"). - arg( dtStartTime ); + tqarg( dtStartTime ); } else { tmp = "<br>" + i18n("time range for event, to prevent ugly line breaks", "<i>Time:</i> %1 - %2"). - arg( dtStartTime, dtEndTime ); + tqarg( dtStartTime, dtEndTime ); } ret += tmp; } @@ -3267,7 +3267,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ } ret += "<br>" + i18n("<i>Start:</i> %1"). - arg( IncidenceFormatter::dateTimeToString( startDt, floats, false ). + tqarg( IncidenceFormatter::dateTimeToString( startDt, floats, false ). tqreplace( " ", " " ) ); } @@ -3282,7 +3282,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ } ret += "<br>" + i18n("<i>Due:</i> %1"). - arg( IncidenceFormatter::dateTimeToString( dueDt, floats, false ). + tqarg( IncidenceFormatter::dateTimeToString( dueDt, floats, false ). tqreplace( " ", " " ) ); } @@ -3300,7 +3300,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Todo *todo, const TQ ret += todo->completedStr().tqreplace( " ", " " ); } else { ret += "<i>" + i18n( "Percent Done:" ) + "</i>" + " "; - ret += i18n( "%1%" ).arg( todo->percentComplete() ); + ret += i18n( "%1%" ).tqarg( todo->percentComplete() ); } return ret; @@ -3312,7 +3312,7 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Journal*journal ) if (journal->dtStart().isValid() ) { ret += "<br>" + i18n("<i>Date:</i> %1"). - arg( IncidenceFormatter::dateToString( journal->dtStart(), false ) ); + tqarg( IncidenceFormatter::dateToString( journal->dtStart(), false ) ); } return ret; } @@ -3320,9 +3320,9 @@ TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( Journal*journal ) TQString IncidenceFormatter::ToolTipVisitor::dateRangeText( FreeBusy *fb ) { TQString tmp( "<br>" + i18n("<i>Period start:</i> %1") ); - TQString ret = tmp.arg( KGlobal::locale()->formatDateTime( fb->dtStart() ) ); + TQString ret = tmp.tqarg( KGlobal::locale()->formatDateTime( fb->dtStart() ) ); tmp = "<br>" + i18n("<i>Period start:</i> %1"); - ret += tmp.arg( KGlobal::locale()->formatDateTime( fb->dtEnd() ) ); + ret += tmp.tqarg( KGlobal::locale()->formatDateTime( fb->dtEnd() ) ); return ret; } @@ -3349,7 +3349,7 @@ bool IncidenceFormatter::ToolTipVisitor::visit( Journal *journal ) bool IncidenceFormatter::ToolTipVisitor::visit( FreeBusy *fb ) { mResult = "<qt><b>" + i18n("Free/Busy information for %1") - .arg(fb->organizer().fullName()) + "</b>"; + .tqarg(fb->organizer().fullName()) + "</b>"; mResult += dateRangeText( fb ); mResult += "</qt>"; return !mResult.isEmpty(); @@ -3405,10 +3405,10 @@ static TQString tooltipFormatAttendeeRoleList( Incidence *incidence, Attendee::R } tmpStr += tooltipPerson( a->email(), a->name() ); if ( !a->delegator().isEmpty() ) { - tmpStr += i18n(" (delegated by %1)" ).arg( a->delegator() ); + tmpStr += i18n(" (delegated by %1)" ).tqarg( a->delegator() ); } if ( !a->delegate().isEmpty() ) { - tmpStr += i18n(" (delegated to %1)" ).arg( a->delegate() ); + tmpStr += i18n(" (delegated to %1)" ).tqarg( a->delegate() ); } tmpStr += sep; i++; @@ -3588,13 +3588,13 @@ static TQString mailBodyIncidence( Incidence *incidence ) { TQString body; if ( !incidence->summary().isEmpty() ) { - body += i18n("Summary: %1\n").arg( incidence->summary() ); + body += i18n("Summary: %1\n").tqarg( incidence->summary() ); } if ( !incidence->organizer().isEmpty() ) { - body += i18n("Organizer: %1\n").arg( incidence->organizer().fullName() ); + body += i18n("Organizer: %1\n").tqarg( incidence->organizer().fullName() ); } if ( !incidence->location().isEmpty() ) { - body += i18n("Location: %1\n").arg( incidence->location() ); + body += i18n("Location: %1\n").tqarg( incidence->location() ); } return body; } @@ -3608,26 +3608,26 @@ bool IncidenceFormatter::MailBodyVisitor::visit( Event *event ) mResult = mailBodyIncidence( event ); mResult += i18n("Start Date: %1\n"). - arg( IncidenceFormatter::dateToString( event->dtStart(), true ) ); + tqarg( IncidenceFormatter::dateToString( event->dtStart(), true ) ); if ( !event->doesFloat() ) { mResult += i18n("Start Time: %1\n"). - arg( IncidenceFormatter::timeToString( event->dtStart(), true ) ); + tqarg( IncidenceFormatter::timeToString( event->dtStart(), true ) ); } if ( event->dtStart() != event->dtEnd() ) { mResult += i18n("End Date: %1\n"). - arg( IncidenceFormatter::dateToString( event->dtEnd(), true ) ); + tqarg( IncidenceFormatter::dateToString( event->dtEnd(), true ) ); } if ( !event->doesFloat() ) { mResult += i18n("End Time: %1\n"). - arg( IncidenceFormatter::timeToString( event->dtEnd(), true ) ); + tqarg( IncidenceFormatter::timeToString( event->dtEnd(), true ) ); } if ( event->doesRecur() ) { Recurrence *recur = event->recurrence(); // TODO: Merge these two to one of the form "Recurs every 3 days" mResult += i18n("Recurs: %1\n") - .arg( recurrence[ recur->recurrenceType() ] ); + .tqarg( recurrence[ recur->recurrenceType() ] ); mResult += i18n("Frequency: %1\n") - .arg( event->recurrence()->frequency() ); + .tqarg( event->recurrence()->frequency() ); if ( recur->duration() > 0 ) { mResult += i18n ("Repeats once", "Repeats %n times", recur->duration()); @@ -3641,7 +3641,7 @@ bool IncidenceFormatter::MailBodyVisitor::visit( Event *event ) } else { endstr = KGlobal::locale()->formatDateTime( recur->endDateTime() ); } - mResult += i18n("Repeat until: %1\n").arg( endstr ); + mResult += i18n("Repeat until: %1\n").tqarg( endstr ); } else { mResult += i18n("Repeats forever\n"); } @@ -3652,13 +3652,13 @@ bool IncidenceFormatter::MailBodyVisitor::visit( Event *event ) mResult += i18n("This recurring meeting has been cancelled on the following days:\n"); DateList::ConstIterator ex_iter; for ( ex_iter = exceptions.begin(); ex_iter != exceptions.end(); ++ex_iter ) { - mResult += i18n(" %1\n").arg( KGlobal::locale()->formatDate(* ex_iter ) ); + mResult += i18n(" %1\n").tqarg( KGlobal::locale()->formatDate(* ex_iter ) ); } } } TQString details = event->description(); if ( !details.isEmpty() ) { - mResult += i18n("Details:\n%1\n").arg( details ); + mResult += i18n("Details:\n%1\n").tqarg( details ); } return !mResult.isEmpty(); } @@ -3669,23 +3669,23 @@ bool IncidenceFormatter::MailBodyVisitor::visit( Todo *todo ) if ( todo->hasStartDate() ) { mResult += i18n("Start Date: %1\n"). - arg( IncidenceFormatter::dateToString( todo->dtStart( false ), true ) ); + tqarg( IncidenceFormatter::dateToString( todo->dtStart( false ), true ) ); if ( !todo->doesFloat() ) { mResult += i18n("Start Time: %1\n"). - arg( IncidenceFormatter::timeToString( todo->dtStart( false ),true ) ); + tqarg( IncidenceFormatter::timeToString( todo->dtStart( false ),true ) ); } } if ( todo->hasDueDate() ) { mResult += i18n("Due Date: %1\n"). - arg( IncidenceFormatter::dateToString( todo->dtDue(), true ) ); + tqarg( IncidenceFormatter::dateToString( todo->dtDue(), true ) ); if ( !todo->doesFloat() ) { mResult += i18n("Due Time: %1\n"). - arg( IncidenceFormatter::timeToString( todo->dtDue(), true ) ); + tqarg( IncidenceFormatter::timeToString( todo->dtDue(), true ) ); } } TQString details = todo->description(); if ( !details.isEmpty() ) { - mResult += i18n("Details:\n%1\n").arg( details ); + mResult += i18n("Details:\n%1\n").tqarg( details ); } return !mResult.isEmpty(); } @@ -3694,13 +3694,13 @@ bool IncidenceFormatter::MailBodyVisitor::visit( Journal *journal ) { mResult = mailBodyIncidence( journal ); mResult += i18n("Date: %1\n"). - arg( IncidenceFormatter::dateToString( journal->dtStart(), true ) ); + tqarg( IncidenceFormatter::dateToString( journal->dtStart(), true ) ); if ( !journal->doesFloat() ) { mResult += i18n("Time: %1\n"). - arg( IncidenceFormatter::timeToString( journal->dtStart(), true ) ); + tqarg( IncidenceFormatter::timeToString( journal->dtStart(), true ) ); } if ( !journal->description().isEmpty() ) - mResult += i18n("Text of the journal:\n%1\n").arg( journal->description() ); + mResult += i18n("Text of the journal:\n%1\n").tqarg( journal->description() ); return !mResult.isEmpty(); } @@ -3813,9 +3813,9 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) case Recurrence::rMinutely: recurStr = i18n( "Recurs every minute", "Recurs every %n minutes", recur->frequency() ); if ( recur->duration() != -1 ) { - txt = i18n( "%1 until %2" ).arg( recurStr ).arg( recurEnd( incidence ) ); + txt = i18n( "%1 until %2" ).tqarg( recurStr ).tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } @@ -3824,9 +3824,9 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) case Recurrence::rHourly: recurStr = i18n( "Recurs hourly", "Recurs every %n hours", recur->frequency() ); if ( recur->duration() != -1 ) { - txt = i18n( "%1 until %2" ).arg( recurStr ).arg( recurEnd( incidence ) ); + txt = i18n( "%1 until %2" ).tqarg( recurStr ).tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } @@ -3836,9 +3836,9 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) recurStr = i18n( "Recurs daily", "Recurs every %n days", recur->frequency() ); if ( recur->duration() != -1 ) { - txt = i18n( "%1 until %2" ).arg( recurStr ).arg( recurEnd( incidence ) ); + txt = i18n( "%1 until %2" ).tqarg( recurStr ).tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } @@ -3863,13 +3863,13 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) } if ( recur->duration() != -1 ) { txt = i18n( "%1 on %2 until %3" ). - arg( recurStr ).arg( dayNames ).arg( recurEnd( incidence ) ); + tqarg( recurStr ).tqarg( dayNames ).tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } - txt = i18n( "%1 on %2" ).arg( recurStr ).arg( dayNames ); + txt = i18n( "%1 on %2" ).tqarg( recurStr ).tqarg( dayNames ); return txt; } case Recurrence::rMonthlyPos: @@ -3880,19 +3880,19 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) KCal::RecurrenceRule::WDayPos rule = recur->monthPositions()[0]; if ( recur->duration() != -1 ) { txt = i18n( "%1 on the %2 %3 until %4" ). - arg( recurStr ). - arg( dayList[rule.pos() + 31] ). - arg( calSys->weekDayName( rule.day(), false ) ). - arg( recurEnd( incidence ) ); + tqarg( recurStr ). + tqarg( dayList[rule.pos() + 31] ). + tqarg( calSys->weekDayName( rule.day(), false ) ). + tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } txt = i18n( "%1 on the %2 %3" ). - arg( recurStr ). - arg( dayList[rule.pos() + 31] ). - arg( calSys->weekDayName( rule.day(), false ) ); + tqarg( recurStr ). + tqarg( dayList[rule.pos() + 31] ). + tqarg( calSys->weekDayName( rule.day(), false ) ); return txt; } else { return recurStr; @@ -3907,15 +3907,15 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) int days = recur->monthDays()[0]; if ( recur->duration() != -1 ) { txt = i18n( "%1 on the %2 day until %3" ). - arg( recurStr ). - arg( dayList[days + 31] ). - arg( recurEnd( incidence ) ); + tqarg( recurStr ). + tqarg( dayList[days + 31] ). + tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } - txt = i18n( "%1 on the %2 day" ).arg( recurStr ).arg( dayList[days + 31] ); + txt = i18n( "%1 on the %2 day" ).tqarg( recurStr ).tqarg( dayList[days + 31] ); return txt; } else { return recurStr; @@ -3929,33 +3929,33 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) if ( recur->duration() != -1 ) { if ( !recur->yearDates().isEmpty() ) { txt = i18n( "%1 on %2 %3 until %4" ). - arg( recurStr ). - arg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). - arg( dayList[ recur->yearDates()[0] + 31 ] ). - arg( recurEnd( incidence ) ); + tqarg( recurStr ). + tqarg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). + tqarg( dayList[ recur->yearDates()[0] + 31 ] ). + tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } } if ( !recur->yearDates().isEmpty() ) { txt = i18n( "%1 on %2 %3" ). - arg( recurStr ). - arg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). - arg( dayList[ recur->yearDates()[0] + 31 ] ); + tqarg( recurStr ). + tqarg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). + tqarg( dayList[ recur->yearDates()[0] + 31 ] ); return txt; } else { if ( !recur->yearMonths().isEmpty() ) { txt = i18n( "Recurs yearly on %1 %2" ). - arg( calSys->monthName( recur->yearMonths()[0], + tqarg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). - arg( dayList[ recur->startDate().day() + 31 ] ); + tqarg( dayList[ recur->startDate().day() + 31 ] ); } else { txt = i18n( "Recurs yearly on %1 %2" ). - arg( calSys->monthName( recur->startDate().month(), + tqarg( calSys->monthName( recur->startDate().month(), recur->startDate().year() ) ). - arg( dayList[ recur->startDate().day() + 31 ] ); + tqarg( dayList[ recur->startDate().day() + 31 ] ); } return txt; } @@ -3967,15 +3967,15 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) if ( !recur->yearDays().isEmpty() ) { if ( recur->duration() != -1 ) { txt = i18n( "%1 on day %2 until %3" ). - arg( recurStr ). - arg( recur->yearDays()[0] ). - arg( recurEnd( incidence ) ); + tqarg( recurStr ). + tqarg( recur->yearDays()[0] ). + tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } - txt = i18n( "%1 on day %2" ).arg( recurStr ).arg( recur->yearDays()[0] ); + txt = i18n( "%1 on day %2" ).tqarg( recurStr ).tqarg( recur->yearDays()[0] ); return txt; } else { return recurStr; @@ -3989,21 +3989,21 @@ TQString IncidenceFormatter::recurrenceString( Incidence *incidence ) KCal::RecurrenceRule::WDayPos rule = recur->yearPositions()[0]; if ( recur->duration() != -1 ) { txt = i18n( "%1 on the %2 %3 of %4 until %5" ). - arg( recurStr ). - arg( dayList[rule.pos() + 31] ). - arg( calSys->weekDayName( rule.day(), false ) ). - arg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). - arg( recurEnd( incidence ) ); + tqarg( recurStr ). + tqarg( dayList[rule.pos() + 31] ). + tqarg( calSys->weekDayName( rule.day(), false ) ). + tqarg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ). + tqarg( recurEnd( incidence ) ); if ( recur->duration() > 0 ) { - txt += i18n( " (%1 occurrences)" ).arg( recur->duration() ); + txt += i18n( " (%1 occurrences)" ).tqarg( recur->duration() ); } return txt; } txt = i18n( "%1 on the %2 %3 of %4" ). - arg( recurStr ). - arg( dayList[rule.pos() + 31] ). - arg( calSys->weekDayName( rule.day(), false ) ). - arg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ); + tqarg( recurStr ). + tqarg( dayList[rule.pos() + 31] ). + tqarg( calSys->weekDayName( rule.day(), false ) ). + tqarg( calSys->monthName( recur->yearMonths()[0], recur->startDate().year() ) ); return txt; } else { return recurStr; @@ -4184,18 +4184,18 @@ TQStringList IncidenceFormatter::reminderStringList( Incidence *incidence, bool } if ( offset == 0 ) { if ( !atStr.isEmpty() ) { - remStr = i18n( "reminder occurs at datetime", "at %1" ).arg( atStr ); + remStr = i18n( "reminder occurs at datetime", "at %1" ).tqarg( atStr ); } } else { - remStr = offsetStr.arg( secs2Duration( offset ) ); + remStr = offsetStr.tqarg( secs2Duration( offset ) ); } if ( alarm->repeatCount() > 0 ) { TQString countStr = i18n( "repeats once", "repeats %n times", alarm->repeatCount() ); TQString intervalStr = i18n( "interval is N days/hours/minutes", "interval is %1" ). - arg( secs2Duration( alarm->snoozeTime().asSeconds() ) ); + tqarg( secs2Duration( alarm->snoozeTime().asSeconds() ) ); TQString repeatStr = i18n( "(repeat string, interval string)", "(%1, %2)" ). - arg( countStr, intervalStr ); + tqarg( countStr, intervalStr ); remStr = remStr + ' ' + repeatStr; } diff --git a/libkcal/person.cpp b/libkcal/person.cpp index 3d7c2b42d..c5e15c15f 100644 --- a/libkcal/person.cpp +++ b/libkcal/person.cpp @@ -88,7 +88,7 @@ void Person::setName(const TQString &name) void Person::setEmail(const TQString &email) { - if ( email.startsWith( "mailto:", false ) ) { + if ( email.tqstartsWith( "mailto:", false ) ) { mEmail = email.mid(7); } else { mEmail = email; diff --git a/libkcal/qtopiaformat.cpp b/libkcal/qtopiaformat.cpp index 964e48c52..b7f13fd54 100644 --- a/libkcal/qtopiaformat.cpp +++ b/libkcal/qtopiaformat.cpp @@ -294,7 +294,7 @@ bool TQtopiaFormat::save( Calendar *calendar, const TQString &fileName ) TQFile file( fileName ); if (!file.open( IO_WriteOnly ) ) { setException(new ErrorFormat(ErrorFormat::SaveError, - i18n("Could not open file '%1'").arg(fileName))); + i18n("Could not open file '%1'").tqarg(fileName))); return false; } TQTextStream ts( &file ); diff --git a/libkcal/recurrencerule.h b/libkcal/recurrencerule.h index a93062d08..14335a0b6 100644 --- a/libkcal/recurrencerule.h +++ b/libkcal/recurrencerule.h @@ -30,7 +30,7 @@ #include "libkcal_export.h" template <class T> -Q_INLINE_TEMPLATES void qSortUnique( TQValueList<T> &lst ) +TQ_INLINE_TEMPLATES void qSortUnique( TQValueList<T> &lst ) { qHeapSort( lst ); if ( lst.isEmpty() ) return; @@ -51,7 +51,7 @@ Q_INLINE_TEMPLATES void qSortUnique( TQValueList<T> &lst ) } template <class T> -Q_INLINE_TEMPLATES int findGE( const TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int findGE( const TQValueList<T> &lst, const T &value, int start ) { // Do a binary search to find the first item >= value int st = start - 1; @@ -69,7 +69,7 @@ Q_INLINE_TEMPLATES int findGE( const TQValueList<T> &lst, const T &value, int st } template <class T> -Q_INLINE_TEMPLATES int findGT( const TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int findGT( const TQValueList<T> &lst, const T &value, int start ) { // Do a binary search to find the first item > value int st = start - 1; @@ -87,7 +87,7 @@ Q_INLINE_TEMPLATES int findGT( const TQValueList<T> &lst, const T &value, int st } template <class T> -Q_INLINE_TEMPLATES int findLE( const TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int findLE( const TQValueList<T> &lst, const T &value, int start ) { // Do a binary search to find the last item <= value int st = start - 1; @@ -104,7 +104,7 @@ Q_INLINE_TEMPLATES int findLE( const TQValueList<T> &lst, const T &value, int st } template <class T> -Q_INLINE_TEMPLATES int findLT( const TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int findLT( const TQValueList<T> &lst, const T &value, int start ) { // Do a binary search to find the last item < value int st = start - 1; @@ -121,7 +121,7 @@ Q_INLINE_TEMPLATES int findLT( const TQValueList<T> &lst, const T &value, int st } template <class T> -Q_INLINE_TEMPLATES int findSorted( const TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int findSorted( const TQValueList<T> &lst, const T &value, int start ) { // Do a binary search to find the item == value int st = start - 1; @@ -138,7 +138,7 @@ Q_INLINE_TEMPLATES int findSorted( const TQValueList<T> &lst, const T &value, in } template <class T> -Q_INLINE_TEMPLATES int removeSorted( TQValueList<T> &lst, const T &value, int start ) +TQ_INLINE_TEMPLATES int removeSorted( TQValueList<T> &lst, const T &value, int start ) { int i = findSorted( lst, value, start ); if ( i >= 0 ) { @@ -148,7 +148,7 @@ Q_INLINE_TEMPLATES int removeSorted( TQValueList<T> &lst, const T &value, int st } template <class T> -Q_INLINE_TEMPLATES bool containsSorted( const TQValueList<T> &lst, const T &value ) +TQ_INLINE_TEMPLATES bool containsSorted( const TQValueList<T> &lst, const T &value ) { return findSorted( lst, value, 0 ) >= 0; } diff --git a/libkcal/resourcecached.cpp b/libkcal/resourcecached.cpp index 0e2d8d56d..09d1eef7b 100644 --- a/libkcal/resourcecached.cpp +++ b/libkcal/resourcecached.cpp @@ -689,12 +689,12 @@ void ResourceCached::addInfoText( TQString &txt ) const if ( mLastLoad.isValid() ) { txt += "<br>"; txt += i18n("Last loaded: %1") - .arg( KGlobal::locale()->formatDateTime( mLastLoad ) ); + .tqarg( KGlobal::locale()->formatDateTime( mLastLoad ) ); } if ( mLastSave.isValid() ) { txt += "<br>"; txt += i18n("Last saved: %1") - .arg( KGlobal::locale()->formatDateTime( mLastSave ) ); + .tqarg( KGlobal::locale()->formatDateTime( mLastSave ) ); } } diff --git a/libkcal/resourcecachedconfig.cpp b/libkcal/resourcecachedconfig.cpp index 5224ff8b2..b230f5bb9 100644 --- a/libkcal/resourcecachedconfig.cpp +++ b/libkcal/resourcecachedconfig.cpp @@ -41,7 +41,7 @@ ResourceCachedReloadConfig::ResourceCachedReloadConfig( TQWidget *tqparent, { TQBoxLayout *topLayout = new TQVBoxLayout( this ); - mGroup = new TQButtonGroup( 1, Horizontal, i18n("Automatic Reload"), this ); + mGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Automatic Reload"), this ); topLayout->addWidget( mGroup ); new TQRadioButton( i18n("Never"), mGroup ); new TQRadioButton( i18n("On startup"), mGroup ); @@ -81,7 +81,7 @@ ResourceCachedSaveConfig::ResourceCachedSaveConfig( TQWidget *tqparent, { TQBoxLayout *topLayout = new TQVBoxLayout( this ); - mGroup = new TQButtonGroup( 1, Horizontal, i18n("Automatic Save"), this ); + mGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n("Automatic Save"), this ); topLayout->addWidget( mGroup ); new TQRadioButton( i18n("Never"), mGroup ); new TQRadioButton( i18n("On exit"), mGroup ); diff --git a/libkcal/resourcecalendar.cpp b/libkcal/resourcecalendar.cpp index 9f611e75e..d398357d7 100644 --- a/libkcal/resourcecalendar.cpp +++ b/libkcal/resourcecalendar.cpp @@ -74,7 +74,7 @@ TQString ResourceCalendar::infoText() const KRES::Factory *factory = KRES::Factory::self( "calendar" ); TQString t = factory->typeName( type() ); - txt += i18n("Type: %1").arg( t ); + txt += i18n("Type: %1").tqarg( t ); addInfoText( txt ); @@ -172,7 +172,7 @@ void ResourceCalendar::loadError( const TQString &err ) mReceivedLoadError = true; - TQString msg = i18n("Error while loading %1.\n") .arg( resourceName() ); + TQString msg = i18n("Error while loading %1.\n") .tqarg( resourceName() ); if ( !err.isEmpty() ) { msg += err; } @@ -209,7 +209,7 @@ void ResourceCalendar::saveError( const TQString &err ) mReceivedSaveError = true; - TQString msg = i18n("Error while saving %1.\n") .arg( resourceName() ); + TQString msg = i18n("Error while saving %1.\n") .tqarg( resourceName() ); if ( !err.isEmpty() ) { msg += err; } diff --git a/libkcal/resourcelocalconfig.cpp b/libkcal/resourcelocalconfig.cpp index 65b3cfe76..29d879da5 100644 --- a/libkcal/resourcelocalconfig.cpp +++ b/libkcal/resourcelocalconfig.cpp @@ -51,7 +51,7 @@ ResourceLocalConfig::ResourceLocalConfig( TQWidget* tqparent, const char* name mainLayout->addWidget( label, 1, 0 ); mainLayout->addWidget( mURL, 1, 1 ); - formatGroup = new TQButtonGroup( 1, Horizontal, i18n( "Calendar Format" ), this ); + formatGroup = new TQButtonGroup( 1, Qt::Horizontal, i18n( "Calendar Format" ), this ); icalButton = new TQRadioButton( i18n("iCalendar"), formatGroup ); vcalButton = new TQRadioButton( i18n("vCalendar"), formatGroup ); @@ -88,7 +88,7 @@ void ResourceLocalConfig::saveSettings( KRES::Resource *resource ) for( int i = 0; file.exists(); ++i ) file.setName( saveFolder + "/std" + TQString::number(i) + ".ics" ); - KMessageBox::information( this, i18n( "You did not specify a URL for this resource. Therefore, the resource will be saved in %1. It is still possible to change this location by editing the resource properties." ).arg( file.name() ) ); + KMessageBox::information( this, i18n( "You did not specify a URL for this resource. Therefore, the resource will be saved in %1. It is still possible to change this location by editing the resource properties." ).tqarg( file.name() ) ); url = file.name(); } diff --git a/libkcal/scheduler.cpp b/libkcal/scheduler.cpp index 54709eb49..481a33a6a 100644 --- a/libkcal/scheduler.cpp +++ b/libkcal/scheduler.cpp @@ -60,7 +60,7 @@ TQString ScheduleMessage::statusName(ScheduleMessage::tqStatus status) case RequestUpdate: return i18n("Updated Request"); default: - return i18n("Unknown tqStatus: %1").arg(TQString::number(status)); + return i18n("Unknown tqStatus: %1").tqarg(TQString::number(status)); } } @@ -590,12 +590,12 @@ bool Scheduler::acceptReply(IncidenceBase *incidence,ScheduleMessage::tqStatus / bool attendeeAdded = false; for ( Attendee::List::ConstIterator it = attendeesNew.constBegin(); it != attendeesNew.constEnd(); ++it ) { Attendee* attNew = *it; - TQString msg = i18n("%1 wants to attend %2 but was not invited.").arg( attNew->fullName() ) - .arg( ev ? ev->summary() : to->summary() ); + TQString msg = i18n("%1 wants to attend %2 but was not invited.").tqarg( attNew->fullName() ) + .tqarg( ev ? ev->summary() : to->summary() ); if ( !attNew->delegator().isEmpty() ) - msg = i18n("%1 wants to attend %2 on behalf of %3.").arg( attNew->fullName() ) - .arg( ev ? ev->summary() : to->summary() ) - .arg( attNew->delegator() ); + msg = i18n("%1 wants to attend %2 on behalf of %3.").tqarg( attNew->fullName() ) + .tqarg( ev ? ev->summary() : to->summary() ) + .tqarg( attNew->delegator() ); if ( KMessageBox::questionYesNo( 0, msg, i18n("Uninvited attendee"), KGuiItem(i18n("Accept Attendance")), KGuiItem(i18n("Reject Attendance")) ) != KMessageBox::Yes ) diff --git a/libkcal/vcalformat.cpp b/libkcal/vcalformat.cpp index 40736a906..973f8c227 100644 --- a/libkcal/vcalformat.cpp +++ b/libkcal/vcalformat.cpp @@ -703,7 +703,7 @@ Todo *VCalFormat::VTodoToEvent(VObject *vtodo) int emailPos1, emailPos2; if ((emailPos1 = tmpStr.tqfind('<')) > 0) { // both email address and name - emailPos2 = tmpStr.findRev('>'); + emailPos2 = tmpStr.tqfindRev('>'); a = new Attendee(tmpStr.left(emailPos1 - 1), tmpStr.mid(emailPos1 + 1, emailPos2 - (emailPos1 + 1))); @@ -919,7 +919,7 @@ Event* VCalFormat::VEventToEvent(VObject *vevent) int emailPos1, emailPos2; if ((emailPos1 = tmpStr.tqfind('<')) > 0) { // both email address and name - emailPos2 = tmpStr.findRev('>'); + emailPos2 = tmpStr.tqfindRev('>'); a = new Attendee(tmpStr.left(emailPos1 - 1), tmpStr.mid(emailPos1 + 1, emailPos2 - (emailPos1 + 1))); @@ -1013,7 +1013,7 @@ Event* VCalFormat::VEventToEvent(VObject *vevent) // Immediately after the type is the frequency int index = tmpStr.tqfind(' '); - int last = tmpStr.findRev(' ') + 1; // find last entry + int last = tmpStr.tqfindRev(' ') + 1; // find last entry int rFreq = tmpStr.mid(typelen, (index-1)).toInt(); ++index; // advance to beginning of stuff after freq diff --git a/libkdenetwork/gpgmepp/CMakeLists.txt b/libkdenetwork/gpgmepp/CMakeLists.txt index 7fe95668a..32ee0ca8c 100644 --- a/libkdenetwork/gpgmepp/CMakeLists.txt +++ b/libkdenetwork/gpgmepp/CMakeLists.txt @@ -49,6 +49,6 @@ tde_add_library( gpgme++ SHARED verificationresult.cpp signingresult.cpp encryptionresult.cpp engineinfo.cpp VERSION 0.4.0 - LINK ${GPGME_LIBRARIES} + LINK ${TQT_LIBRARIES} ${GPGME_LIBRARIES} DESTINATION ${LIB_INSTALL_DIR} ) diff --git a/libkdenetwork/qgpgme/dataprovider.cpp b/libkdenetwork/qgpgme/dataprovider.cpp index a37684d0d..052b84c48 100644 --- a/libkdenetwork/qgpgme/dataprovider.cpp +++ b/libkdenetwork/qgpgme/dataprovider.cpp @@ -30,7 +30,7 @@ static bool resizeAndInit( TQByteArray & ba, size_t newSize ) { const size_t oldSize = ba.size(); - bool ok = ba.resize( newSize ); + bool ok = ba.tqresize( newSize ); if ( ok ) memset( ba.data() + oldSize, 0, newSize - oldSize ); return ok; diff --git a/libkdepim/addresseeemailselection.cpp b/libkdepim/addresseeemailselection.cpp index 481fc1554..589e7e334 100644 --- a/libkdepim/addresseeemailselection.cpp +++ b/libkdepim/addresseeemailselection.cpp @@ -143,8 +143,8 @@ bool AddresseeEmailSelection::itemEnabled( const KABC::Addressee &addressee, uin bool AddresseeEmailSelection::itemMatches( const KABC::Addressee &addressee, uint index, const TQString &pattern ) const { - return addressee.formattedName().startsWith( pattern, false ) || - email( addressee, index ).startsWith( pattern, false ); + return addressee.formattedName().tqstartsWith( pattern, false ) || + email( addressee, index ).tqstartsWith( pattern, false ); } bool AddresseeEmailSelection::itemEquals( const KABC::Addressee &addressee, uint index, const TQString &pattern ) const @@ -172,13 +172,13 @@ bool AddresseeEmailSelection::distributionListMatches( const KABC::DistributionL const TQString &pattern ) const { // check whether the name of the distribution list matches the pattern or one of its entries. - bool ok = distributionList->name().startsWith( pattern, false ); + bool ok = distributionList->name().tqstartsWith( pattern, false ); KABC::DistributionList::Entry::List entries = distributionList->entries(); KABC::DistributionList::Entry::List::ConstIterator it; for ( it = entries.begin(); it != entries.end(); ++it ) { - ok = ok || (*it).addressee.formattedName().startsWith( pattern, false ) || - (*it).email.startsWith( pattern, false ); + ok = ok || (*it).addressee.formattedName().tqstartsWith( pattern, false ) || + (*it).email.tqstartsWith( pattern, false ); } return ok; diff --git a/libkdepim/addresseelineedit.cpp b/libkdepim/addresseelineedit.cpp index 0d86fad44..9e42085b5 100644 --- a/libkdepim/addresseelineedit.cpp +++ b/libkdepim/addresseelineedit.cpp @@ -217,12 +217,12 @@ void AddresseeLineEdit::keyPressEvent( TQKeyEvent *e ) { bool accept = false; - if ( KStdAccel::shortcut( KStdAccel::SubstringCompletion ).tqcontains( KKey( e ) ) ) { + if ( KStdAccel::shortcut( KStdAccel::SubstringCompletion ).contains( KKey( e ) ) ) { //TODO: add LDAP substring lookup, when it becomes available in KPIM::LDAPSearch updateSearchString(); doCompletion( true ); accept = true; - } else if ( KStdAccel::shortcut( KStdAccel::TextCompletion ).tqcontains( KKey( e ) ) ) { + } else if ( KStdAccel::shortcut( KStdAccel::TextCompletion ).contains( KKey( e ) ) ) { int len = text().length(); if ( len == cursorPosition() ) { // at End? @@ -344,9 +344,9 @@ void AddresseeLineEdit::mouseReleaseEvent( TQMouseEvent *e ) { // reimplemented from TQLineEdit::mouseReleaseEvent() if ( m_useCompletion - && TQApplication::clipboard()->supportsSelection() + && TQApplication::tqclipboard()->supportsSelection() && !isReadOnly() - && e->button() == MidButton ) { + && e->button() == Qt::MidButton ) { m_smartPaste = true; } @@ -727,7 +727,7 @@ void AddresseeLineEdit::addContact( const KABC::Addressee& addr, int weight, int bool bDone = false; int i = -1; - while( ( i = name.findRev(' ') ) > 1 && !bDone ) { + while( ( i = name.tqfindRev(' ') ) > 1 && !bDone ) { TQString sLastName( name.mid( i+1 ) ); if( ! sLastName.isEmpty() && 2 <= sLastName.length() && // last names must be at least 2 chars long @@ -763,7 +763,7 @@ void AddresseeLineEdit::addCompletionItem( const TQString& string, int weight, i weight = TQMAX( ( *it ).first, weight ); ( *it ).first = weight; } else { - s_completionItemMap->insert( string, qMakePair( weight, completionItemSource ) ); + s_completionItemMap->insert( string, tqMakePair( weight, completionItemSource ) ); } if ( keyWords == 0 ) s_completion->addItem( string, weight ); @@ -798,7 +798,7 @@ void AddresseeLineEdit::startLoadingLDAPEntries() TQString s( *s_LDAPText ); // TODO cache last? TQString prevAddr; - int n = s.findRev( ',' ); + int n = s.tqfindRev( ',' ); if ( n >= 0 ) { prevAddr = s.left( n + 1 ) + ' '; s = s.mid( n + 1, 255 ).stripWhiteSpace(); @@ -872,13 +872,13 @@ void AddresseeLineEdit::setCompletedItems( const TQStringList& items, bool autoS // item, if there is one TQListBoxItem* item = 0; if ( oldCurrentText.isEmpty() - || ( item = completionBox->findItem( oldCurrentText ) ) == 0 ) { + || ( item = completionBox->tqfindItem( oldCurrentText ) ) == 0 ) { item = completionBox->item( 1 ); } if ( item ) { if ( itemUnderMouse ) { - TQListBoxItem *newItemUnderMouse = completionBox->findItem( oldTextUnderMouse ); + TQListBoxItem *newItemUnderMouse = completionBox->tqfindItem( oldTextUnderMouse ); // if the mouse was over an item, before, but now that's elsewhere, // move the cursor, so folks don't accidently click the wrong item if ( newItemUnderMouse ) { @@ -1026,7 +1026,7 @@ int KPIM::AddresseeLineEdit::addCompletionSource( const TQString &source, int we else (*s_completionSourceWeights)[source] = weight; - int sourceIndex = s_completionSources->findIndex( source ); + int sourceIndex = s_completionSources->tqfindIndex( source ); if ( sourceIndex == -1 ) { s_completionSources->append( source ); return s_completionSources->size() - 1; @@ -1037,12 +1037,12 @@ int KPIM::AddresseeLineEdit::addCompletionSource( const TQString &source, int we bool KPIM::AddresseeLineEdit::eventFilter(TQObject *obj, TQEvent *e) { - if ( obj == completionBox() ) { + if ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(completionBox()) ) { if ( e->type() == TQEvent::MouseButtonPress || e->type() == TQEvent::MouseMove || e->type() == TQEvent::MouseButtonRelease || e->type() == TQEvent::MouseButtonDblClick ) { - TQMouseEvent* me = static_cast<TQMouseEvent*>( e ); + TQMouseEvent* me = TQT_TQMOUSEEVENT( e ); // find list box item at the event position TQListBoxItem *item = completionBox()->itemAt( me->pos() ); if ( !item ) { @@ -1054,8 +1054,8 @@ bool KPIM::AddresseeLineEdit::eventFilter(TQObject *obj, TQEvent *e) // avoid selection of headers on button press, or move or release while // a button is pressed if ( e->type() == TQEvent::MouseButtonPress - || me->state() & LeftButton || me->state() & MidButton - || me->state() & RightButton ) { + || me->state() & Qt::LeftButton || me->state() & Qt::MidButton + || me->state() & Qt::RightButton ) { if ( itemIsHeader(item) ) { return true; // eat the event, we don't want anything to happen } else { @@ -1070,18 +1070,18 @@ bool KPIM::AddresseeLineEdit::eventFilter(TQObject *obj, TQEvent *e) } } } - if ( ( obj == this ) && + if ( ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(this) ) && ( e->type() == TQEvent::AccelOverride ) ) { - TQKeyEvent *ke = static_cast<TQKeyEvent*>( e ); + TQKeyEvent *ke = TQT_TQKEYEVENT( e ); if ( ke->key() == Key_Up || ke->key() == Key_Down || ke->key() == Key_Tab ) { ke->accept(); return true; } } - if ( ( obj == this ) && + if ( ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(this) ) && ( e->type() == TQEvent::KeyPress || e->type() == TQEvent::KeyRelease ) && completionBox()->isVisible() ) { - TQKeyEvent *ke = static_cast<TQKeyEvent*>( e ); + TQKeyEvent *ke = TQT_TQKEYEVENT( e ); int currentIndex = completionBox()->currentItem(); if ( currentIndex < 0 ) { return true; diff --git a/libkdepim/addresseeselector.cpp b/libkdepim/addresseeselector.cpp index c7e378179..70d587bae 100644 --- a/libkdepim/addresseeselector.cpp +++ b/libkdepim/addresseeselector.cpp @@ -227,8 +227,8 @@ class SelectionViewItem : public TQListViewItem AddresseeSelector::AddresseeSelector( Selection *selection, TQWidget *tqparent, const char *name ) : TQWidget( tqparent, name ), mSelection( selection ), mManager( 0 ) { - mMoveMapper = new TQSignalMapper( this ); - mRemoveMapper = new TQSignalMapper( this ); + mMoveMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); + mRemoveMapper = new TQSignalMapper( TQT_TQOBJECT(this) ); mAddressBookManager = new AddressBookManager(); @@ -300,7 +300,7 @@ void AddresseeSelector::initGUI() connect( listView, TQT_SIGNAL( doubleClicked( TQListViewItem*, const TQPoint&, int ) ), mRemoveMapper, TQT_SLOT( map() ) ); - mRemoveMapper->setMapping( listView, i ); + mRemoveMapper->setMapping( TQT_TQOBJECT(listView), i ); TQVBoxLayout *buttonLayout = new TQVBoxLayout( this ); buttonLayout->tqsetAlignment( TQt::AlignBottom ); @@ -313,7 +313,7 @@ void AddresseeSelector::initGUI() connect( moveButton, TQT_SIGNAL( clicked() ), mMoveMapper, TQT_SLOT( map() ) ); - mMoveMapper->setMapping( moveButton, i ); + mMoveMapper->setMapping( TQT_TQOBJECT(moveButton), i ); // remove button TQToolButton *removeButton = new TQToolButton( this ); @@ -322,7 +322,7 @@ void AddresseeSelector::initGUI() connect( removeButton, TQT_SIGNAL( clicked() ), mRemoveMapper, TQT_SLOT( map() ) ); - mRemoveMapper->setMapping( removeButton, i ); + mRemoveMapper->setMapping( TQT_TQOBJECT(removeButton), i ); buttonLayout->addWidget( moveButton ); buttonLayout->addWidget( removeButton ); diff --git a/libkdepim/addresseeview.cpp b/libkdepim/addresseeview.cpp index d8ead42b2..f291e4e1d 100644 --- a/libkdepim/addresseeview.cpp +++ b/libkdepim/addresseeview.cpp @@ -151,11 +151,11 @@ void AddresseeView::enableLinks( int linkMask ) TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *proxy, LinkMask linkMask, bool internalLoading, FieldMask fieldMask ) { - TQString image = TQString( "contact_%1_image" ).arg( addr.uid() ); + TQString image = TQString( "contact_%1_image" ).tqarg( addr.uid() ); // Style strings from Gentix; this is just an initial version. // - // These will be substituted into various HTML strings with .arg(). + // These will be substituted into various HTML strings with .tqarg(). // Search for @STYLE@ to find where. Note how we use %1 as a // placeholder where we fill in something else (in this case, // the global background color). @@ -165,12 +165,12 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr "style=\"" "padding-right: 2px; " "border-right: #000 dashed 1px; " - "background: %1;\"").arg(backgroundColor); + "background: %1;\"").tqarg(backgroundColor); TQString backgroundColor2 = KGlobalSettings::baseColor().name(); TQString cellStyle2 = TQString::tqfromLatin1( "style=\"" "padding-left: 2px; " - "background: %1;\"").arg(backgroundColor2); + "background: %1;\"").tqarg(backgroundColor2); TQString tableStyle = TQString::tqfromLatin1( "style=\"" "border: solid 1px; " @@ -216,8 +216,8 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( date.isValid() ) dynamicPart += rowFmtStr - .arg( KABC::Addressee::birthdayLabel() ) - .arg( KGlobal::locale()->formatDate( date, true ) ); + .tqarg( KABC::Addressee::birthdayLabel() ) + .tqarg( KGlobal::locale()->formatDate( date, true ) ); } if ( fieldMask & PhoneFields ) { @@ -235,15 +235,15 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( linkMask & PhoneLinks ) { TQString smsURL; if ( (*phoneIt).type() & KABC::PhoneNumber::Cell ) - smsURL = TQString(" (<a href=\"sms:%1\">%2</a>)" ).arg( number ).arg( i18n( "SMS") ); + smsURL = TQString(" (<a href=\"sms:%1\">%2</a>)" ).tqarg( number ).tqarg( i18n( "SMS") ); dynamicPart += rowFmtStr - .arg( (*phoneIt).typeLabel().tqreplace( " ", " " ) ) - .arg( TQString::tqfromLatin1( "<a href=\"%1\">%2</a>%3" ).arg( url ).arg( number ).arg( smsURL ) ); + .tqarg( (*phoneIt).typeLabel().tqreplace( " ", " " ) ) + .tqarg( TQString::tqfromLatin1( "<a href=\"%1\">%2</a>%3" ).tqarg( url ).tqarg( number ).tqarg( smsURL ) ); } else { dynamicPart += rowFmtStr - .arg( (*phoneIt).typeLabel().tqreplace( " ", " " ) ) - .arg( number ); + .tqarg( (*phoneIt).typeLabel().tqreplace( " ", " " ) ) + .tqarg( number ); } } } @@ -257,11 +257,11 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr TQUrl::encode( fullEmail ); if ( linkMask & EmailLinks ) { - dynamicPart += rowFmtStr.arg( type ) - .arg( TQString::tqfromLatin1( "<a href=\"mailto:%1\">%2</a>" ) - .arg( fullEmail, TQStyleSheet::escape( *emailIt ) ) ); + dynamicPart += rowFmtStr.tqarg( type ) + .tqarg( TQString::tqfromLatin1( "<a href=\"mailto:%1\">%2</a>" ) + .tqarg( fullEmail, TQStyleSheet::escape( *emailIt ) ) ); } else { - dynamicPart += rowFmtStr.arg( type ).arg( *emailIt ); + dynamicPart += rowFmtStr.tqarg( type ).tqarg( *emailIt ); } } } @@ -276,7 +276,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr } else { url = addr.url().prettyURL(); } - dynamicPart += rowFmtStr.arg( i18n("Homepage") ).arg( url ); + dynamicPart += rowFmtStr.tqarg( i18n("Homepage") ).tqarg( url ); } TQString blog = addr.custom( "KADDRESSBOOK", "BlogFeed" ); @@ -284,7 +284,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( linkMask & URLLinks ) { blog = KStringHandler::tagURLs( blog ); } - dynamicPart += rowFmtStr.arg( i18n("Blog Feed") ).arg( blog ); + dynamicPart += rowFmtStr.tqarg( i18n("Blog Feed") ).tqarg( blog ); } } @@ -303,12 +303,12 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( linkMask & AddressLinks ) { dynamicPart += rowFmtStr - .arg( KABC::Address::typeLabel( (*addrIt).type() ) ) - .arg( link ); + .tqarg( KABC::Address::typeLabel( (*addrIt).type() ) ) + .tqarg( link ); } else { dynamicPart += rowFmtStr - .arg( KABC::Address::typeLabel( (*addrIt).type() ) ) - .arg( formattedAddress ); + .tqarg( KABC::Address::typeLabel( (*addrIt).type() ) ) + .tqarg( formattedAddress ); } } else { TQString link = "<a href=\"addr:" + (*addrIt).id() + "\">" + @@ -316,12 +316,12 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( linkMask & AddressLinks ) { dynamicPart += rowFmtStr - .arg( KABC::Address::typeLabel( (*addrIt).type() ) ) - .arg( link ); + .tqarg( KABC::Address::typeLabel( (*addrIt).type() ) ) + .tqarg( link ); } else { dynamicPart += rowFmtStr - .arg( KABC::Address::typeLabel( (*addrIt).type() ) ) - .arg( (*addrIt).label().tqreplace( '\n', "<br>" ) ); + .tqarg( KABC::Address::typeLabel( (*addrIt).type() ) ) + .tqarg( (*addrIt).label().tqreplace( '\n', "<br>" ) ); } } } @@ -333,7 +333,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr // the data afterwards (keeps us safe from possible % signs // in either one). notes = TQStyleSheet::escape( addr.note() ); - notes = rowFmtStr.arg( i18n( "Notes" ) ).arg( notes.tqreplace( '\n', "<br>" ) ) ; + notes = rowFmtStr.tqarg( i18n( "Notes" ) ).tqarg( notes.tqreplace( '\n', "<br>" ) ) ; } TQString customData; @@ -371,7 +371,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( keyIt != titleMap.end() ) key = keyIt.data(); - customData += rowFmtStr.arg( key ).arg( TQStyleSheet::escape( value ) ) ; + customData += rowFmtStr.tqarg( key ).tqarg( TQStyleSheet::escape( value ) ) ; } } } @@ -385,7 +385,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr const TQString imAddress = addr.custom( "KADDRESSBOOK", "X-IMAddress" ); if ( !imAddress.isEmpty() ) { - customData += rowFmtStr.arg( i18n( "IM Address" ) ).arg( TQStyleSheet::escape( imAddress ) ) ; + customData += rowFmtStr.tqarg( i18n( "IM Address" ) ).tqarg( TQStyleSheet::escape( imAddress ) ) ; } if ( proxy ) { @@ -393,7 +393,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr // set image source to either a TQMimeSourceFactory key or a data:/ URL TQString imgSrc; if ( internalLoading ) { - imgSrc = TQString::tqfromLatin1( "im_status_%1_image").arg( addr.uid() ); + imgSrc = TQString::tqfromLatin1( "im_status_%1_image").tqarg( addr.uid() ); TQMimeSourceFactory::defaultFactory()->setPixmap( imgSrc, proxy->presenceIcon( addr.uid() ) ); } else imgSrc = pixmapAsDataUrl( proxy->presenceIcon( addr.uid() ) ); @@ -407,10 +407,10 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr // append our status to the rest of the dynamic part of the addressee dynamicPart += rowFmtStr - .arg( i18n( "Presence" ) ) - .arg( imtqStatus - .arg( imgSrc ) - .arg( proxy->presenceString( addr.uid() ) ) + .tqarg( i18n( "Presence" ) ) + .tqarg( imtqStatus + .tqarg( imgSrc ) + .tqarg( proxy->presenceString( addr.uid() ) ) ); } } @@ -424,44 +424,44 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr TQString strAddr = TQString::tqfromLatin1( "<div align=\"center\">" "<table cellpadding=\"1\" cellspacing=\"0\" %1>" - "<tr>").arg(tableStyle); + "<tr>").tqarg(tableStyle); strAddr.append( TQString::tqfromLatin1( "<td align=\"right\" valign=\"top\" width=\"30%\" rowspan=\"3\" %2>") - .arg( cellStyle ) ); + .tqarg( cellStyle ) ); strAddr.append( TQString::tqfromLatin1( "<img src=\"%1\" width=\"50\" vspace=\"1\">" // image "</td>") - .arg( image ) ); + .tqarg( image ) ); strAddr.append( TQString::tqfromLatin1( "<td align=\"left\" width=\"70%\" %2>") - .arg( cellStyle2 ) ); + .tqarg( cellStyle2 ) ); strAddr.append( TQString::tqfromLatin1( "<font size=\"+2\"><b>%2</b></font></td>" // name "</tr>") - .arg( name ) ); + .tqarg( name ) ); strAddr.append( TQString::tqfromLatin1( "<tr>" "<td align=\"left\" width=\"70%\" %2>") - .arg( cellStyle2 ) ); + .tqarg( cellStyle2 ) ); strAddr.append( TQString::tqfromLatin1( "%3</td>" // role "</tr>") - .arg( role ) ); + .tqarg( role ) ); strAddr.append( TQString::tqfromLatin1( "<tr>" "<td align=\"left\" width=\"70%\" %2>") - .arg( cellStyle2 ) ); + .tqarg( cellStyle2 ) ); strAddr.append( TQString::tqfromLatin1( "%4</td>" // organization "</tr>") - .arg( organization ) ); + .tqarg( organization ) ); strAddr.append( TQString::tqfromLatin1( "<tr><td %2>") - .arg( cellStyle ) ); + .tqarg( cellStyle ) ); strAddr.append( TQString::tqfromLatin1( " </td><td %2> </td></tr>") - .arg( cellStyle2 ) ); + .tqarg( cellStyle2 ) ); strAddr.append( dynamicPart ); strAddr.append( notes ); strAddr.append( customData ); @@ -476,7 +476,7 @@ TQString AddresseeView::vCardAsHTML( const KABC::Addressee& addr, ::KIMProxy *pr if ( !label.isEmpty() ) addrBookName = label; } - strAddr.append( i18n( "<p><b>Address book</b>: %1</p>" ).arg( addrBookName ) ); + strAddr.append( i18n( "<p><b>Address book</b>: %1</p>" ).tqarg( addrBookName ) ); } return strAddr; } @@ -532,11 +532,11 @@ void AddresseeView::updateView() "%3" // dynamic part "</body>" "</html>" ) - .arg( KGlobalSettings::textColor().name() ) - .arg( KGlobalSettings::baseColor().name() ) - .arg( strAddr ); + .tqarg( KGlobalSettings::textColor().name() ) + .tqarg( KGlobalSettings::baseColor().name() ) + .tqarg( strAddr ); - TQString imageURL = TQString( "contact_%1_image" ).arg( mAddressee.uid() ); + TQString imageURL = TQString( "contact_%1_image" ).tqarg( mAddressee.uid() ); KABC::Picture picture = mAddressee.photo(); if ( picture.isIntern() && !picture.data().isNull() ) @@ -544,7 +544,7 @@ void AddresseeView::updateView() else { if ( !picture.url().isEmpty() ) { if ( mImageData.count() > 0 ) - TQMimeSourceFactory::defaultFactory()->setImage( imageURL, mImageData ); + TQMimeSourceFactory::defaultFactory()->setImage( imageURL, TQImage(mImageData) ); else { mImageJob = KIO::get( KURL( picture.url() ), false, false ); connect( mImageJob, TQT_SIGNAL( data( KIO::Job*, const TQByteArray& ) ), @@ -690,27 +690,27 @@ void AddresseeView::slotHighlighted( const TQString &link ) TQString email = link.mid( 7 ); emit emailHighlighted( email ); - emit highlightedMessage( i18n( "Send mail to '%1'" ).arg( email ) ); + emit highlightedMessage( i18n( "Send mail to '%1'" ).tqarg( email ) ); } else if ( link.startsWith( "phone:" ) ) { TQString number = link.mid( 8 ); emit phoneNumberHighlighted( strippedNumber( number ) ); - emit highlightedMessage( i18n( "Call number %1" ).arg( number ) ); + emit highlightedMessage( i18n( "Call number %1" ).tqarg( number ) ); } else if ( link.startsWith( "fax:" ) ) { TQString number = link.mid( 6 ); emit faxNumberHighlighted( strippedNumber( number ) ); - emit highlightedMessage( i18n( "Send fax to %1" ).arg( number ) ); + emit highlightedMessage( i18n( "Send fax to %1" ).tqarg( number ) ); } else if ( link.startsWith( "addr:" ) ) { emit highlightedMessage( i18n( "Show address on map" ) ); } else if ( link.startsWith( "sms:" ) ) { TQString number = link.mid( 6 ); - emit highlightedMessage( i18n( "Send SMS to %1" ).arg( number ) ); + emit highlightedMessage( i18n( "Send SMS to %1" ).tqarg( number ) ); } else if ( link.startsWith( "http:" ) || link.startsWith( "https:" ) ) { emit urlHighlighted( link ); - emit highlightedMessage( i18n( "Open URL %1" ).arg( link ) ); + emit highlightedMessage( i18n( "Open URL %1" ).tqarg( link ) ); } else if ( link.startsWith( "im:" ) ) { - emit highlightedMessage( i18n( "Chat with %1" ).arg( mAddressee.realName() ) ); + emit highlightedMessage( i18n( "Chat with %1" ).tqarg( mAddressee.realName() ) ); } else emit highlightedMessage( "" ); } diff --git a/libkdepim/addressesdialog.cpp b/libkdepim/addressesdialog.cpp index b7bea2369..e874ac017 100644 --- a/libkdepim/addressesdialog.cpp +++ b/libkdepim/addressesdialog.cpp @@ -912,7 +912,7 @@ AddressesDialog::saveAs() KMessageBox::information( 0, i18n( "<qt>Distribution list with the given name <b>%1</b> " "already exists. Please select a different name.</qt>" ) - .arg( name ) ); + .tqarg( name ) ); return; } diff --git a/libkdepim/broadcaststatus.cpp b/libkdepim/broadcaststatus.cpp index 68900936a..e3f16c32d 100644 --- a/libkdepim/broadcaststatus.cpp +++ b/libkdepim/broadcaststatus.cpp @@ -57,9 +57,9 @@ void BroadcastqStatus::seStatusMsgWithTimestamp( const TQString& message ) { KLocale* locale = KGlobal::locale(); seStatusMsg( i18n( "%1 is a time, %2 is a status message", "[%1] %2" ) - .arg( locale->formatTime( TQTime::currentTime(), + .tqarg( locale->formatTime( TQTime::currentTime(), true /* with seconds */ ) ) - .arg( message ) ); + .tqarg( message ) ); } void BroadcastqStatus::seStatusMsgTransmissionCompleted( int numMessages, @@ -78,13 +78,13 @@ void BroadcastqStatus::seStatusMsgTransmissionCompleted( int numMessages, "Transmission complete. %n new messages in %1 KB " "(%2 KB remaining on the server).", numMessages ) - .arg( numBytesRead / 1024 ) - .arg( numBytes / 1024 ); + .tqarg( numBytesRead / 1024 ) + .tqarg( numBytes / 1024 ); else statusMsg = i18n( "Transmission complete. %n message in %1 KB.", "Transmission complete. %n messages in %1 KB.", numMessages ) - .arg( numBytesRead / 1024 ); + .tqarg( numBytesRead / 1024 ); } else statusMsg = i18n( "Transmission complete. %n new message.", @@ -118,17 +118,17 @@ void BroadcastqStatus::seStatusMsgTransmissionCompleted( const TQString& account "%n new messages in %1 KB " "(%2 KB remaining on the server).", numMessages ) - .arg( numBytesRead / 1024 ) - .arg( numBytes / 1024 ) - .arg( account ); + .tqarg( numBytesRead / 1024 ) + .tqarg( numBytes / 1024 ) + .tqarg( account ); else statusMsg = i18n( "Transmission for account %2 complete. " "%n message in %1 KB.", "Transmission for account %2 complete. " "%n messages in %1 KB.", numMessages ) - .arg( numBytesRead / 1024 ) - .arg( account ); + .tqarg( numBytesRead / 1024 ) + .tqarg( account ); } else statusMsg = i18n( "Transmission for account %1 complete. " @@ -136,11 +136,11 @@ void BroadcastqStatus::seStatusMsgTransmissionCompleted( const TQString& account "Transmission for account %1 complete. " "%n new messages.", numMessages ) - .arg( account ); + .tqarg( account ); } else statusMsg = i18n( "Transmission for account %1 complete. No new messages.") - .arg( account ); + .tqarg( account ); seStatusMsgWithTimestamp( statusMsg ); if ( item ) diff --git a/libkdepim/completionordereditor.cpp b/libkdepim/completionordereditor.cpp index e4821f3dc..9d4d19bd2 100644 --- a/libkdepim/completionordereditor.cpp +++ b/libkdepim/completionordereditor.cpp @@ -88,7 +88,7 @@ class LDAPCompletionItem : public CompletionItem { public: LDAPCompletionItem( LdapClient* ldapClient ) : mLdapClient( ldapClient ) {} - virtual TQString label() const { return i18n( "LDAP server %1" ).arg( mLdapClient->server().host() ); } + virtual TQString label() const { return i18n( "LDAP server %1" ).tqarg( mLdapClient->server().host() ); } virtual int completionWeight() const { return mLdapClient->completionWeight(); } virtual void save( CompletionOrderEditor* ); protected: @@ -102,7 +102,7 @@ void LDAPCompletionItem::save( CompletionOrderEditor* ) { KConfig * config = LdapSearch::config(); config->setGroup( "LDAP" ); - config->writeEntry( TQString( "SelectedCompletionWeight%1" ).arg( mLdapClient->clientNumber() ), + config->writeEntry( TQString( "SelectedCompletionWeight%1" ).tqarg( mLdapClient->clientNumber() ), mWeight ); config->sync(); } @@ -141,7 +141,7 @@ public: KABCImapSubResCompletionItem( ResourceABC* resource, const TQString& subResource ) : mResource( resource ), mSubResource( subResource ), mWeight( completionWeight() ) {} virtual TQString label() const { - return TQString( "%1 %2" ).arg( mResource->resourceName() ).arg( mResource->subresourceLabel( mSubResource ) ); + return TQString( "%1 %2" ).tqarg( mResource->resourceName() ).tqarg( mResource->subresourceLabel( mSubResource ) ); } virtual int completionWeight() const { return mResource->subresourceCompletionWeight( mSubResource ); @@ -225,12 +225,12 @@ CompletionOrderEditor::CompletionOrderEditor( KPIM::LdapSearch* ldapSearch, mUpButton = new KPushButton( upDownBox, "mUpButton" ); mUpButton->setIconSet( BarIconSet( "up", KIcon::SizeSmall ) ); mUpButton->setEnabled( false ); // b/c no item is selected yet - mUpButton->setFocusPolicy( StrongFocus ); + mUpButton->setFocusPolicy( Qt::StrongFocus ); mDownButton = new KPushButton( upDownBox, "mDownButton" ); mDownButton->setIconSet( BarIconSet( "down", KIcon::SizeSmall ) ); mDownButton->setEnabled( false ); // b/c no item is selected yet - mDownButton->setFocusPolicy( StrongFocus ); + mDownButton->setFocusPolicy( Qt::StrongFocus ); TQWidget* spacer = new TQWidget( upDownBox ); upDownBox->setStretchFactor( spacer, 100 ); diff --git a/libkdepim/csshelper.cpp b/libkdepim/csshelper.cpp index f828476f6..05f20e390 100644 --- a/libkdepim/csshelper.cpp +++ b/libkdepim/csshelper.cpp @@ -73,10 +73,10 @@ namespace KPIM { mMetrics( pdm ) { // initialize with defaults - should match the corresponding application defaults - mForegroundColor = TQApplication::palette().active().text(); + mForegroundColor = TQApplication::tqpalette().active().text(); mLinkColor = KGlobalSettings::linkColor(); mVisitedLinkColor = KGlobalSettings::visitedLinkColor(); - mBackgroundColor = TQApplication::palette().active().base(); + mBackgroundColor = TQApplication::tqpalette().active().base(); cHtmlWarning = TQColor( 0xFF, 0x40, 0x40 ); // warning frame color: light red cPgpEncrH = TQColor( 0x00, 0x80, 0xFF ); // light blue @@ -184,9 +184,9 @@ namespace KPIM { ? level % numQuoteLevels + 1 : kMin( level + 1, numQuoteLevels ) ; if ( level >= numQuoteLevels ) - return TQString( "<div class=\"deepquotelevel%1\">" ).arg( effectiveLevel ); + return TQString( "<div class=\"deepquotelevel%1\">" ).tqarg( effectiveLevel ); else - return TQString( "<div class=\"quotelevel%1\">" ).arg( effectiveLevel ); + return TQString( "<div class=\"quotelevel%1\">" ).tqarg( effectiveLevel ); } TQString CSSHelper::nonQuotedFontTag() const { @@ -214,9 +214,9 @@ namespace KPIM { TQString CSSHelper::printCssDefinitions( bool fixed ) const { const TQString headerFont = TQString( " font-family: \"%1\" ! important;\n" " font-size: %2pt ! important;\n" ) - .arg( mPrintFont.family() ) - .arg( mPrintFont.pointSize() ); - const TQColorGroup & cg = TQApplication::palette().active(); + .tqarg( mPrintFont.family() ) + .tqarg( mPrintFont.pointSize() ); + const TQColorGroup & cg = TQApplication::tqpalette().active(); const TQFont printFont = bodyFont( fixed, true /* print */ ); TQString quoteCSS; @@ -234,7 +234,7 @@ namespace KPIM { " color: #000000 ! important;\n" " background-color: #ffffff ! important\n" "}\n\n" ) - .arg( printFont.family(), + .tqarg( printFont.family(), TQString::number( printFont.pointSize() ) ) + TQString( "tr.textAtmH,\n" @@ -288,7 +288,7 @@ namespace KPIM { " display:none ! important;\n" "}\n\n" ) - .arg( headerFont, + .tqarg( headerFont, cg.background().name(), cg.foreground().name() ) + quoteCSS; @@ -300,15 +300,15 @@ namespace KPIM { const TQString linkColor = mLinkColor.name(); const TQString headerFont = TQString(" font-family: \"%1\" ! important;\n" " font-size: %2px ! important;\n") - .arg( mBodyFont.family() ) - .arg( pointsToPixel( helper->mMetrics, mBodyFont.pointSize() ) ); + .tqarg( mBodyFont.family() ) + .tqarg( pointsToPixel( helper->mMetrics, mBodyFont.pointSize() ) ); const TQString background = ( mBackingPixmapOn ? TQString( " background-image:url(file://%1) ! important;\n" ) - .arg( mBackingPixmapStr ) + .tqarg( mBackingPixmapStr ) : TQString( " background-color: %1 ! important;\n" ) - .arg( bgColor ) ); + .tqarg( bgColor ) ); const TQString bodyFontSize = TQString::number( pointsToPixel( helper->mMetrics, fontSize( fixed ) ) ) + "px" ; - const TQColorGroup & cg = TQApplication::palette().active(); + const TQColorGroup & cg = TQApplication::tqpalette().active(); TQString quoteCSS; if ( bodyFont( fixed ).italic() ) @@ -322,7 +322,7 @@ namespace KPIM { for ( int i = 0 ; i < 3 ; ++i ) { quoteCSS += TQString( "div.quotelevel%1 {\n" " color: %2 ! important;\n" ) - .arg( TQString::number(i+1), mQuoteColor[i].name() ); + .tqarg( TQString::number(i+1), mQuoteColor[i].name() ); if ( mQuoteFont[i].italic() ) quoteCSS += " font-style: italic ! important;\n"; if ( mQuoteFont[i].bold() ) @@ -337,7 +337,7 @@ namespace KPIM { for ( int i = 0 ; i < 3 ; ++i ) { quoteCSS += TQString( "div.deepquotelevel%1 {\n" " color: %2 ! important;\n" ) - .arg( TQString::number(i+1), mQuoteColor[i].name() ); + .tqarg( TQString::number(i+1), mQuoteColor[i].name() ); if ( mQuoteFont[i].italic() ) quoteCSS += " font-style: italic ! important;\n"; if ( mQuoteFont[i].bold() ) @@ -354,7 +354,7 @@ namespace KPIM { " color: %3 ! important;\n" "%4" "}\n\n" ) - .arg( bodyFont( fixed ).family(), + .tqarg( bodyFont( fixed ).family(), bodyFontSize, fgColor, background ) @@ -392,7 +392,7 @@ namespace KPIM { "tr.rfc822H {\n" "%4" "}\n\n" ) - .arg( linkColor, fgColor, bgColor, headerFont ) + .tqarg( linkColor, fgColor, bgColor, headerFont ) + TQString( "table.encr {\n" " background-color: %1 ! important;\n" @@ -404,7 +404,7 @@ namespace KPIM { "}\n\n" "tr.encrB { background-color: %4 ! important; }\n\n" ) - .arg( cPgpEncrF.name(), + .tqarg( cPgpEncrF.name(), cPgpEncrH.name(), headerFont, cPgpEncrB.name() ) @@ -419,7 +419,7 @@ namespace KPIM { "}\n\n" "tr.signOkKeyOkB { background-color: %4 ! important; }\n\n" ) - .arg( cPgpOk1F.name(), + .tqarg( cPgpOk1F.name(), cPgpOk1H.name(), headerFont, cPgpOk1B.name() ) @@ -434,7 +434,7 @@ namespace KPIM { "}\n\n" "tr.signOkKeyBadB { background-color: %4 ! important; }\n\n" ) - .arg( cPgpOk0F.name(), + .tqarg( cPgpOk0F.name(), cPgpOk0H.name(), headerFont, cPgpOk0B.name() ) @@ -449,7 +449,7 @@ namespace KPIM { "}\n\n" "tr.signWarnB { background-color: %4 ! important; }\n\n" ) - .arg( cPgpWarnF.name(), + .tqarg( cPgpWarnF.name(), cPgpWarnH.name(), headerFont, cPgpWarnB.name() ) @@ -464,7 +464,7 @@ namespace KPIM { "}\n\n" "tr.signErrB { background-color: %4 ! important; }\n\n" ) - .arg( cPgpErrF.name(), + .tqarg( cPgpErrF.name(), cPgpErrH.name(), headerFont, cPgpErrB.name() ) @@ -472,7 +472,7 @@ namespace KPIM { TQString( "div.htmlWarn {\n" " border: 2px solid %1 ! important;\n" "}\n\n" ) - .arg( cHtmlWarning.name() ) + .tqarg( cHtmlWarning.name() ) + TQString( "div.header {\n" "%1" @@ -519,12 +519,12 @@ namespace KPIM { "}\n\n" ) - .arg( headerFont ) - .arg( cg.highlight().name(), + .tqarg( headerFont ) + .tqarg( cg.highlight().name(), cg.highlightedText().name(), cg.foreground().name(), cg.background().name() ) - .arg( cg.mid().name() ) + .tqarg( cg.mid().name() ) + quoteCSS; } diff --git a/libkdepim/designerfields.cpp b/libkdepim/designerfields.cpp index 6907485d0..31a3b7f8a 100644 --- a/libkdepim/designerfields.cpp +++ b/libkdepim/designerfields.cpp @@ -83,7 +83,7 @@ void DesignerFields::initGUI( const TQString &uiFile ) if ( name.startsWith( "X_" ) ) { name = name.mid( 2 ); - TQWidget *widget = static_cast<TQWidget*>( it.current() ); + TQWidget *widget = TQT_TQWIDGET( it.current() ); if ( !name.isEmpty() ) mWidgets.insert( name, widget ); @@ -187,13 +187,13 @@ void DesignerFields::load( DesignerFields::Storage *storage ) wdg->setChecked( value == "true" || value == "1" ); } else if ( it.data()->inherits( TQDATETIMEEDIT_OBJECT_NAME_STRING ) ) { TQDateTimeEdit *wdg = static_cast<TQDateTimeEdit*>( it.data() ); - wdg->setDateTime( TQDateTime::fromString( value, TQt::ISODate ) ); + wdg->setDateTime( TQDateTime::fromString( value, Qt::ISODate ) ); } else if ( it.data()->inherits( "KDateTimeWidget" ) ) { KDateTimeWidget *wdg = static_cast<KDateTimeWidget*>( it.data() ); - wdg->setDateTime( TQDateTime::fromString( value, TQt::ISODate ) ); + wdg->setDateTime( TQDateTime::fromString( value, Qt::ISODate ) ); } else if ( it.data()->inherits( "KDatePicker" ) ) { KDatePicker *wdg = static_cast<KDatePicker*>( it.data() ); - wdg->setDate( TQDate::fromString( value, TQt::ISODate ) ); + wdg->setDate( TQDate::fromString( value, Qt::ISODate ) ); } else if ( it.data()->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) ) { TQComboBox *wdg = static_cast<TQComboBox*>( it.data() ); wdg->setCurrentText( value ); @@ -221,13 +221,13 @@ void DesignerFields::save( DesignerFields::Storage *storage ) value = ( wdg->isChecked() ? "true" : "false" ); } else if ( it.data()->inherits( TQDATETIMEEDIT_OBJECT_NAME_STRING ) ) { TQDateTimeEdit *wdg = static_cast<TQDateTimeEdit*>( it.data() ); - value = wdg->dateTime().toString( TQt::ISODate ); + value = wdg->dateTime().toString( Qt::ISODate ); } else if ( it.data()->inherits( "KDateTimeWidget" ) ) { KDateTimeWidget *wdg = static_cast<KDateTimeWidget*>( it.data() ); - value = wdg->dateTime().toString( TQt::ISODate ); + value = wdg->dateTime().toString( Qt::ISODate ); } else if ( it.data()->inherits( "KDatePicker" ) ) { KDatePicker *wdg = static_cast<KDatePicker*>( it.data() ); - value = wdg->date().toString( TQt::ISODate ); + value = wdg->date().toString( Qt::ISODate ); } else if ( it.data()->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) ) { TQComboBox *wdg = static_cast<TQComboBox*>( it.data() ); value = wdg->currentText(); diff --git a/libkdepim/distributionlist.cpp b/libkdepim/distributionlist.cpp index 97b11bcf8..4cf079c76 100644 --- a/libkdepim/distributionlist.cpp +++ b/libkdepim/distributionlist.cpp @@ -44,7 +44,7 @@ static ParseList parseCustom( const TQString& str ) Q_ASSERT( helpList.count() < 3 ); // 1 or 2 items, but not more const TQString uid = helpList.first(); const TQString email = helpList.last(); - res.append( qMakePair( uid, email ) ); + res.append( tqMakePair( uid, email ) ); } return res; } diff --git a/libkdepim/embeddedurlpage.cpp b/libkdepim/embeddedurlpage.cpp index e73911f00..d45d532d3 100644 --- a/libkdepim/embeddedurlpage.cpp +++ b/libkdepim/embeddedurlpage.cpp @@ -43,7 +43,7 @@ void EmbeddedURLPage::initGUI( const TQString &url, const TQString &/*mimetype*/ { TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); tqlayout->setAutoAdd( true ); - new TQLabel( i18n("Showing URL %1").arg( url ), this ); + new TQLabel( i18n("Showing URL %1").tqarg( url ), this ); } void EmbeddedURLPage::loadContents() @@ -55,7 +55,7 @@ void EmbeddedURLPage::loadContents() if ( mimetype == "auto" ) mimetype == KMimeType::findByURL( mUri )->name(); // "this" is both the tqparent widget and the tqparent object - mPart = KParts::ComponentFactory::createPartInstanceFromQuery<KParts::ReadOnlyPart>( mimetype, TQString(), this, 0, this, 0 ); + mPart = KParts::ComponentFactory::createPartInstanceFromQuery<KParts::ReadOnlyPart>( mimetype, TQString(), TQT_TQWIDGET(this), 0, TQT_TQOBJECT(this), 0 ); if ( mPart ) { mPart->openURL( mUri ); mPart->widget()->show(); diff --git a/libkdepim/htmldiffalgodisplay.cpp b/libkdepim/htmldiffalgodisplay.cpp index 19b99d4e4..124f23874 100644 --- a/libkdepim/htmldiffalgodisplay.cpp +++ b/libkdepim/htmldiffalgodisplay.cpp @@ -45,13 +45,13 @@ void HTMLDiffAlgoDisplay::begin() mText.append( "<html>" ); mText.append( TQString( "<body text=\"%1\" bgcolor=\"%2\">" ) - .arg( KGlobalSettings::textColor().name() ) - .arg( KGlobalSettings::baseColor().name() ) ); + .tqarg( KGlobalSettings::textColor().name() ) + .tqarg( KGlobalSettings::baseColor().name() ) ); mText.append( "<center><table>" ); mText.append( TQString( "<tr><th></th><th align=\"center\">%1</th><td> </td><th align=\"center\">%2</th></tr>" ) - .arg( mLeftTitle ) - .arg( mRightTitle ) ); + .tqarg( mLeftTitle ) + .tqarg( mRightTitle ) ); } void HTMLDiffAlgoDisplay::end() @@ -76,22 +76,22 @@ void HTMLDiffAlgoDisplay::setRightSourceTitle( const TQString &title ) void HTMLDiffAlgoDisplay::additionalLeftField( const TQString &id, const TQString &value ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td bgcolor=\"#9cff83\">%2</td><td></td><td></td></tr>" ) - .arg( id ) - .arg( textToHTML( value ) ) ); + .tqarg( id ) + .tqarg( textToHTML( value ) ) ); } void HTMLDiffAlgoDisplay::additionalRightField( const TQString &id, const TQString &value ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td></td><td></td><td bgcolor=\"#9cff83\">%2</td></tr>" ) - .arg( id ) - .arg( textToHTML( value ) ) ); + .tqarg( id ) + .tqarg( textToHTML( value ) ) ); } void HTMLDiffAlgoDisplay::conflictField( const TQString &id, const TQString &leftValue, const TQString &rightValue ) { mText.append( TQString( "<tr><td align=\"right\"><b>%1:</b></td><td bgcolor=\"#ff8686\">%2</td><td></td><td bgcolor=\"#ff8686\">%3</td></tr>" ) - .arg( id ) - .arg( textToHTML( leftValue ) ) - .arg( textToHTML( rightValue ) ) ); + .tqarg( id ) + .tqarg( textToHTML( leftValue ) ) + .tqarg( textToHTML( rightValue ) ) ); } diff --git a/libkdepim/kaddrbook.cpp b/libkdepim/kaddrbook.cpp index 7356bc2d8..3a0c7dc02 100644 --- a/libkdepim/kaddrbook.cpp +++ b/libkdepim/kaddrbook.cpp @@ -74,7 +74,7 @@ void KAddrBookExternal::openEmail( const TQString &addr, TQWidget *tqparent ) { //TODO: Enable the better message at the next string unfreeze #if 0 TQString text = i18n("<qt>The email address <b>%1</b> cannot be " - "found in your addressbook.</qt>").arg( email ); + "found in your addressbook.</qt>").tqarg( email ); #else TQString text = email + " " + i18n( "is not in address book" ); #endif @@ -150,12 +150,12 @@ void KAddrBookExternal::addEmail( const TQString& addr, TQWidget *tqparent) { if ( KAddrBookExternal::addAddressee( a ) ) { TQString text = i18n("<qt>The email address <b>%1</b> was added to your " "addressbook; you can add more information to this " - "entry by opening the addressbook.</qt>").arg( addr ); + "entry by opening the addressbook.</qt>").tqarg( addr ); KMessageBox::information( tqparent, text, TQString(), "addedtokabc" ); } } else { TQString text = i18n("<qt>The email address <b>%1</b> is already in your " - "addressbook.</qt>").arg( addr ); + "addressbook.</qt>").tqarg( addr ); KMessageBox::information( tqparent, text, TQString(), "alreadyInAddressBook" ); } diff --git a/libkdepim/kcmdesignerfields.cpp b/libkdepim/kcmdesignerfields.cpp index be4aa97bd..10edf6f8b 100644 --- a/libkdepim/kcmdesignerfields.cpp +++ b/libkdepim/kcmdesignerfields.cpp @@ -60,14 +60,14 @@ class PageItem : public TQCheckListItem : TQCheckListItem( tqparent, "", TQCheckListItem::CheckBox ), mPath( path ), mIsActive( false ) { - mName = path.mid( path.findRev( '/' ) + 1 ); + mName = path.mid( path.tqfindRev( '/' ) + 1 ); TQWidget *wdg = TQWidgetFactory::create( mPath, 0, 0 ); if ( wdg ) { setText( 0, wdg->caption() ); TQPixmap pm = TQPixmap::grabWidget( wdg ); - TQImage img = pm.convertToImage().smoothScale( 300, 300, TQImage::ScaleMin ); + TQImage img = pm.convertToImage().smoothScale( 300, 300, TQ_ScaleMin ); mPreview = img; TQObjectList *list = wdg->queryList( TQWIDGET_OBJECT_NAME_STRING ); @@ -91,7 +91,7 @@ class PageItem : public TQCheckListItem new TQListViewItem( this, name, allowedTypes[ it.current()->className() ], it.current()->className(), - TQWhatsThis::textFor( static_cast<TQWidget*>( it.current() ) ) ); + TQWhatsThis::textFor( TQT_TQWIDGET( it.current() ) ) ); } } @@ -162,7 +162,7 @@ void KCMDesignerFields::delayedInit() load(); // Install a dirwatcher that will detect newly created or removed designer files - KDirWatch *dw = new KDirWatch( this ); + KDirWatch *dw = new KDirWatch( TQT_TQOBJECT(this) ); KStandardDirs::makeDir(localUiDir()); dw->addDir( localUiDir(), true ); connect( dw, TQT_SIGNAL( created(const TQString&) ), TQT_SLOT( rebuildList() ) ); @@ -176,7 +176,7 @@ void KCMDesignerFields::deleteFile() if ( item ) { PageItem *pageItem = static_cast<PageItem*>( item->tqparent() ? item->tqparent() : item ); if (KMessageBox::warningContinueCancel(this, - i18n( "<qt>Do you really want to delete '<b>%1</b>'?</qt>").arg( pageItem->text(0) ), "", KStdGuiItem::del() ) + i18n( "<qt>Do you really want to delete '<b>%1</b>'?</qt>").tqarg( pageItem->text(0) ), "", KStdGuiItem::del() ) == KMessageBox::Continue) KIO::NetAccess::del( pageItem->path(), 0 ); } @@ -284,7 +284,7 @@ void KCMDesignerFields::initGUI() mPageView->setFullWidth( true ); hbox->addWidget( mPageView ); - TQGroupBox *box = new TQGroupBox(1, TQt::Horizontal, i18n("Preview of Selected Page"), this ); + TQGroupBox *box = new TQGroupBox(1, Qt::Horizontal, i18n("Preview of Selected Page"), this ); mPagePreview = new TQLabel( box ); mPagePreview->setMinimumWidth( 300 ); @@ -316,10 +316,10 @@ void KCMDesignerFields::initGUI() "<p><b>Important:</b> The widget will edit custom fields with an" " application name of %2. To change the application name" " to be edited, set the widget name in TQt Designer.</p></qt>" ) - .arg( applicationName(), applicationName() ); + .tqarg( applicationName(), applicationName() ); KActiveLabel *activeLabel = new KActiveLabel( - i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).arg(cwHowto), this ); + i18n( "<a href=\"whatsthis:%1\">How does this work?</a>" ).tqarg(cwHowto), this ); hbox->addWidget( activeLabel ); // ### why is this needed? Looks like a KActiveLabel bug... @@ -360,14 +360,14 @@ void KCMDesignerFields::updatePreview( TQListViewItem *item ) "<tr><td align=\"right\"><b>%5</b></td><td>%6</td></tr>" "<tr><td align=\"right\"><b>%7</b></td><td>%8</td></tr>" "</table></qt>" ) - .arg( i18n( "Key:" ) ) - .arg( item->text( 0 ).tqreplace("X_","X-") ) - .arg( i18n( "Type:" ) ) - .arg( item->text( 1 ) ) - .arg( i18n( "Classname:" ) ) - .arg( item->text( 2 ) ) - .arg( i18n( "Description:" ) ) - .arg( item->text( 3 ) ); + .tqarg( i18n( "Key:" ) ) + .tqarg( item->text( 0 ).tqreplace("X_","X-") ) + .tqarg( i18n( "Type:" ) ) + .tqarg( item->text( 1 ) ) + .tqarg( i18n( "Classname:" ) ) + .tqarg( item->text( 2 ) ) + .tqarg( i18n( "Description:" ) ) + .tqarg( item->text( 3 ) ); mPageDetails->setText( details ); diff --git a/libkdepim/kdateedit.cpp b/libkdepim/kdateedit.cpp index 1d54920d6..118c92c21 100644 --- a/libkdepim/kdateedit.cpp +++ b/libkdepim/kdateedit.cpp @@ -38,7 +38,7 @@ class DateValidator : public TQValidator { public: DateValidator( const TQStringList &keywords, TQWidget* tqparent, const char* name = 0 ) - : TQValidator( tqparent, name ), mKeywords( keywords ) + : TQValidator( TQT_TQOBJECT(tqparent), name ), mKeywords( keywords ) {} virtual State validate( TQString &str, int& ) const @@ -246,7 +246,7 @@ TQDate KDateEdit::parseDate( bool *replaced ) const bool KDateEdit::eventFilter( TQObject *object, TQEvent *event ) { - if ( object == lineEdit() ) { + if ( TQT_BASE_OBJECT(object) == TQT_BASE_OBJECT(lineEdit()) ) { // We only process the focus out event if the text has changed // since we got focus if ( (event->type() == TQEvent::FocusOut) && mTextChanged ) { @@ -286,7 +286,7 @@ bool KDateEdit::eventFilter( TQObject *object, TQEvent *event ) case TQEvent::MouseButtonDblClick: case TQEvent::MouseButtonPress: { TQMouseEvent *mouseEvent = (TQMouseEvent*)event; - if ( !mPopup->rect().tqcontains( mouseEvent->pos() ) ) { + if ( !TQT_TQRECT_OBJECT(mPopup->rect()).tqcontains( mouseEvent->pos() ) ) { TQPoint globalPos = mPopup->mapToGlobal( mouseEvent->pos() ); if ( TQApplication::widgetAt( globalPos, true ) == this ) { // The date picker is being closed by a click on the @@ -307,7 +307,7 @@ bool KDateEdit::eventFilter( TQObject *object, TQEvent *event ) void KDateEdit::mousePressEvent( TQMouseEvent *event ) { - if ( event->button() == TQt::LeftButton && mDiscardNextMousePress ) { + if ( event->button() == Qt::LeftButton && mDiscardNextMousePress ) { mDiscardNextMousePress = false; return; } diff --git a/libkdepim/kdepim.widgets b/libkdepim/kdepim.widgets index 2f1b5e24c..a2d69e654 100644 --- a/libkdepim/kdepim.widgets +++ b/libkdepim/kdepim.widgets @@ -25,5 +25,5 @@ Group=Input (KDE-PIM) ToolTip=Time Edit Combobox (KDE-PIM) WhatsThis=A widget to enter a time. It can also be selected from a drop-down list. IncludeFile=libkdepim/ktimeedit.h -ConstructorArgs=(tqparent, QTime::currentTime(), name) +ConstructorArgs=(parent, TQTime::currentTime(), name) Group=Input (KDE-PIM) diff --git a/libkdepim/kfileio.cpp b/libkdepim/kfileio.cpp index 913ee2cc1..01188f004 100644 --- a/libkdepim/kfileio.cpp +++ b/libkdepim/kfileio.cpp @@ -48,20 +48,20 @@ KDE_EXPORT TQCString kFileToString(const TQString &aFileName, bool aEnsureNL, bo if (!info.exists()) { if (aVerbose) - msgDialog(i18n("The specified file does not exist:\n%1").arg(aFileName)); + msgDialog(i18n("The specified file does not exist:\n%1").tqarg(aFileName)); return TQCString(); } if (info.isDir()) { if (aVerbose) - msgDialog(i18n("This is a folder and not a file:\n%1").arg(aFileName)); + msgDialog(i18n("This is a folder and not a file:\n%1").tqarg(aFileName)); return TQCString(); } if (!info.isReadable()) { if (aVerbose) msgDialog(i18n("You do not have read permissions " - "to the file:\n%1").arg(aFileName)); + "to the file:\n%1").tqarg(aFileName)); return TQCString(); } if (len <= 0) return TQCString(); @@ -71,13 +71,13 @@ KDE_EXPORT TQCString kFileToString(const TQString &aFileName, bool aEnsureNL, bo if (aVerbose) switch(file.status()) { case IO_ReadError: - msgDialog(i18n("Could not read file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not read file:\n%1").tqarg(aFileName)); break; case IO_OpenError: - msgDialog(i18n("Could not open file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not open file:\n%1").tqarg(aFileName)); break; default: - msgDialog(i18n("Error while reading file:\n%1").arg(aFileName)); + msgDialog(i18n("Error while reading file:\n%1").tqarg(aFileName)); } return TQCString(); } @@ -94,7 +94,7 @@ KDE_EXPORT TQCString kFileToString(const TQString &aFileName, bool aEnsureNL, bo if (readLen < len) { TQString msg = i18n("Could only read %1 bytes of %2.") - .arg(readLen).arg(len); + .tqarg(readLen).tqarg(len); msgDialog(msg); return TQCString(); } @@ -120,21 +120,21 @@ TQByteArray kFileToBytes(const TQString &aFileName, bool aVerbose) { if (aVerbose) msgDialog(i18n("The specified file does not exist:\n%1") - .arg(aFileName)); + .tqarg(aFileName)); return result; } if (info.isDir()) { if (aVerbose) msgDialog(i18n("This is a folder and not a file:\n%1") - .arg(aFileName)); + .tqarg(aFileName)); return result; } if (!info.isReadable()) { if (aVerbose) msgDialog(i18n("You do not have read permissions " - "to the file:\n%1").arg(aFileName)); + "to the file:\n%1").tqarg(aFileName)); return result; } if (len <= 0) return result; @@ -144,26 +144,26 @@ TQByteArray kFileToBytes(const TQString &aFileName, bool aVerbose) if (aVerbose) switch(file.status()) { case IO_ReadError: - msgDialog(i18n("Could not read file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not read file:\n%1").tqarg(aFileName)); break; case IO_OpenError: - msgDialog(i18n("Could not open file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not open file:\n%1").tqarg(aFileName)); break; default: - msgDialog(i18n("Error while reading file:\n%1").arg(aFileName)); + msgDialog(i18n("Error while reading file:\n%1").tqarg(aFileName)); } return result; } result.resize(len); readLen = file.readBlock(result.data(), len); - kdDebug(5300) << TQString( "len %1" ).arg(len) << endl; + kdDebug(5300) << TQString( "len %1" ).tqarg(len) << endl; if (readLen < len) { TQString msg; msg = i18n("Could only read %1 bytes of %2.") - .arg(readLen).arg(len); + .tqarg(readLen).tqarg(len); msgDialog(msg); return result; } @@ -191,7 +191,7 @@ KDE_EXPORT bool kBytesToFile(const char* aBuffer, int len, { TQString str; str = i18n("File %1 exists.\nDo you want to replace it?") - .arg(aFileName); + .tqarg(aFileName); rc = KMessageBox::warningContinueCancel(0, str, i18n("Save to File"), i18n("&Replace")); if (rc != KMessageBox::Continue) return FALSE; @@ -209,7 +209,7 @@ KDE_EXPORT bool kBytesToFile(const char* aBuffer, int len, if (!aVerbose) return FALSE; rc = KMessageBox::warningContinueCancel(0, i18n("Failed to make a backup copy of %1.\nContinue anyway?") - .arg(aFileName), + .tqarg(aFileName), i18n("Save to File"), KStdGuiItem::save() ); if (rc != KMessageBox::Continue) return FALSE; } @@ -221,14 +221,14 @@ KDE_EXPORT bool kBytesToFile(const char* aBuffer, int len, if (aVerbose) switch(file.status()) { case IO_WriteError: - msgDialog(i18n("Could not write to file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not write to file:\n%1").tqarg(aFileName)); break; case IO_OpenError: msgDialog(i18n("Could not open file for writing:\n%1") - .arg(aFileName)); + .tqarg(aFileName)); break; default: - msgDialog(i18n("Error while writing file:\n%1").arg(aFileName)); + msgDialog(i18n("Error while writing file:\n%1").tqarg(aFileName)); } return FALSE; } @@ -238,13 +238,13 @@ KDE_EXPORT bool kBytesToFile(const char* aBuffer, int len, if (writeLen < 0) { if (aVerbose) - msgDialog(i18n("Could not write to file:\n%1").arg(aFileName)); + msgDialog(i18n("Could not write to file:\n%1").tqarg(aFileName)); return FALSE; } else if (writeLen < len) { TQString msg = i18n("Could only write %1 bytes of %2.") - .arg(writeLen).arg(len); + .tqarg(writeLen).tqarg(len); if (aVerbose) msgDialog(msg); return FALSE; @@ -283,7 +283,7 @@ TQString checkAndCorrectPermissionsIfPossible( const TQString &toCheck, if ( !fiToCheck.exists() ) { error.append( i18n("%1 does not exist") - .arg(toCheck) + "\n"); + .tqarg(toCheck) + "\n"); } // check the access bit of a folder. @@ -295,7 +295,7 @@ TQString checkAndCorrectPermissionsIfPossible( const TQString &toCheck, if ( !g.isReadable() ) { if ( chmod( toCheckEnc, statbuffer.st_mode + S_IXUSR ) != 0 ) { error.append( i18n("%1 is not accessible and that is " - "unchangeable.").arg(toCheck) + "\n"); + "unchangeable.").tqarg(toCheck) + "\n"); } else { kdDebug() << "Changed access bit for " << toCheck << endl; } @@ -316,7 +316,7 @@ TQString checkAndCorrectPermissionsIfPossible( const TQString &toCheck, // Lets try changing it. if ( chmod( toCheckEnc, statbuffer.st_mode + S_IRUSR ) != 0 ) { error.append( i18n("%1 is not readable and that is unchangeable.") - .arg(toCheck) + "\n"); + .tqarg(toCheck) + "\n"); } else { kdDebug() << "Changed the read bit for " << toCheck << endl; } @@ -332,7 +332,7 @@ TQString checkAndCorrectPermissionsIfPossible( const TQString &toCheck, // Lets try changing it. if ( chmod (toCheckEnc, statbuffer.st_mode + S_IWUSR ) != 0 ) { error.append( i18n("%1 is not writable and that is unchangeable.") - .arg(toCheck) + "\n"); + .tqarg(toCheck) + "\n"); } else { kdDebug() << "Changed the write bit for " << toCheck << endl; } @@ -346,7 +346,7 @@ TQString checkAndCorrectPermissionsIfPossible( const TQString &toCheck, // First check if the folder is readable for us. If not, we get // some ugly crashes. if ( !g.isReadable() ){ - error.append(i18n("Folder %1 is inaccessible.").arg(toCheck) + "\n"); + error.append(i18n("Folder %1 is inaccessible.").tqarg(toCheck) + "\n"); } else { const TQFileInfoList *list = g.entryInfoList(); TQFileInfoListIterator it( *list ); diff --git a/libkdepim/kfoldertree.cpp b/libkdepim/kfoldertree.cpp index 0098adbb2..48398ddca 100644 --- a/libkdepim/kfoldertree.cpp +++ b/libkdepim/kfoldertree.cpp @@ -198,7 +198,7 @@ void KFolderTreeItem::setFolderSize( TQ_INT64 aSize ) TQ_INT64 recursiveSize = recursiveFolderSize(); if ( recursiveSize != mSize ) { if ( mType != Root ) - size += TQString::tqfromLatin1(" + %1").arg( KIO::convertSize( recursiveSize - mSize ) ); + size += TQString::tqfromLatin1(" + %1").tqarg( KIO::convertSize( recursiveSize - mSize ) ); else size = KIO::convertSize( recursiveSize ); } @@ -390,10 +390,10 @@ void KFolderTree::setStyleDependantFrameWidth() { // set the width of the frame to a reasonable value for the current GUI style int frameWidth; - if( style().isA("KeramikStyle") ) - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; + if( tqstyle().isA("KeramikStyle") ) + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ) - 1; else - frameWidth = style().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); + frameWidth = tqstyle().tqpixelMetric( TQStyle::PM_DefaultFrameWidth ); if ( frameWidth < 0 ) frameWidth = 0; if ( frameWidth != lineWidth() ) diff --git a/libkdepim/kincidencechooser.cpp b/libkdepim/kincidencechooser.cpp index 431d650de..b9d8758e5 100644 --- a/libkdepim/kincidencechooser.cpp +++ b/libkdepim/kincidencechooser.cpp @@ -104,7 +104,7 @@ KIncidenceChooser::KIncidenceChooser(TQWidget *tqparent, char *name) : #else mDiffBut = 0; #endif - mBg = new TQButtonGroup ( 1, TQt::Horizontal, i18n("Sync Preferences"), topFrame); + mBg = new TQButtonGroup ( 1, Qt::Horizontal, i18n("Sync Preferences"), topFrame); topLayout->addMultiCellWidget(mBg, iii,iii,0,2); ++iii; mBg->insert( new TQRadioButton ( i18n("Take local entry on conflict"), mBg ), KIncidenceChooser::local); @@ -249,7 +249,7 @@ void KIncidenceChooser::showIncidence1() void KIncidenceChooser::detailsDialogClosed() { - KDialogBase* dialog = static_cast<KDialogBase *>( const_cast<TQObject *>( sender() ) ); + KDialogBase* dialog = static_cast<KDialogBase *>( const_cast<TQWidget *>( TQT_TQWIDGET(sender()) ) ); if ( dialog == mTbL ) mShowDetails1->setText( i18n( "Show details..." ) ); else @@ -265,9 +265,9 @@ void KIncidenceChooser::showDiff() } mDisplayDiff = new KPIM::HTMLDiffAlgoDisplay (this); if ( mInc1->summary().left( 20 ) != mInc2->summary().left( 20 ) ) - mDisplayDiff->setCaption( i18n( "Differences of %1 and %2").arg( mInc1->summary().left( 20 ) ).arg( mInc2->summary().left( 20 ) ) ); + mDisplayDiff->setCaption( i18n( "Differences of %1 and %2").tqarg( mInc1->summary().left( 20 ) ).tqarg( mInc2->summary().left( 20 ) ) ); else - mDisplayDiff->setCaption( i18n( "Differences of %1").arg( mInc1->summary().left( 20 ) ) ); + mDisplayDiff->setCaption( i18n( "Differences of %1").tqarg( mInc1->summary().left( 20 ) ) ); diff = new KPIM::CalendarDiffAlgo( mInc1, mInc2); diff->setLeftSourceTitle( i18n( "Local entry")); diff --git a/libkdepim/komposer/core/pluginmanager.cpp b/libkdepim/komposer/core/pluginmanager.cpp index d46d471b2..50ef26a96 100644 --- a/libkdepim/komposer/core/pluginmanager.cpp +++ b/libkdepim/komposer/core/pluginmanager.cpp @@ -311,7 +311,7 @@ PluginManager::loadPluginInternal( const TQString &pluginId ) int error = 0; Plugin *plugin = KParts::ComponentFactory::createInstanceFromQuery<Komposer::Plugin>( TQString::tqfromLatin1( "Komposer/Plugin" ), - TQString::tqfromLatin1( "[X-KDE-PluginInfo-Name]=='%1'" ).arg( pluginId ), + TQString::tqfromLatin1( "[X-KDE-PluginInfo-Name]=='%1'" ).tqarg( pluginId ), this, 0, TQStringList(), &error ); if ( plugin ) { diff --git a/libkdepim/komposer/plugins/default/defaulteditor.cpp b/libkdepim/komposer/plugins/default/defaulteditor.cpp index 6f7dcb7df..c75f63920 100644 --- a/libkdepim/komposer/plugins/default/defaulteditor.cpp +++ b/libkdepim/komposer/plugins/default/defaulteditor.cpp @@ -86,8 +86,8 @@ DefaultEditor::changeSignature( const TQString &sig ) { TQString text = m_textEdit->text(); - int sigStart = text.findRev( "-- " ); - TQString sigText = TQString( "-- \n%1" ).arg( sig ); + int sigStart = text.tqfindRev( "-- " ); + TQString sigText = TQString( "-- \n%1" ).tqarg( sig ); text.tqreplace( sigStart, text.length(), sigText ); } diff --git a/libkdepim/kpartsdesignerplugin/kpartsdesignerplugin.cpp b/libkdepim/kpartsdesignerplugin/kpartsdesignerplugin.cpp index b25e50355..110168904 100644 --- a/libkdepim/kpartsdesignerplugin/kpartsdesignerplugin.cpp +++ b/libkdepim/kpartsdesignerplugin/kpartsdesignerplugin.cpp @@ -48,7 +48,7 @@ void KPartsGenericPart::load() delete m_part; } // "this" is both the tqparent widget and the tqparent object - m_part = KParts::ComponentFactory::createPartInstanceFromQuery<KParts::ReadOnlyPart>( mimetype, TQString(), this, 0, this, 0 ); + m_part = KParts::ComponentFactory::createPartInstanceFromQuery<KParts::ReadOnlyPart>( mimetype, TQString(), TQT_TQWIDGET(this), 0, TQT_TQOBJECT(this), 0 ); if ( m_part ) { m_part->openURL( m_url ); m_part->widget()->show(); diff --git a/libkdepim/kpixmapregionselectorwidget.cpp b/libkdepim/kpixmapregionselectorwidget.cpp index 4efcbbcb0..a6d992f54 100644 --- a/libkdepim/kpixmapregionselectorwidget.cpp +++ b/libkdepim/kpixmapregionselectorwidget.cpp @@ -144,13 +144,13 @@ KPopupMenu *KPixmapRegionSelectorWidget::createPopupMenu() popup->insertTitle(i18n("Image Operations")); KAction *action = new KAction(i18n("&Rotate Clockwise"), "rotate_cw", - 0, this, TQT_SLOT(rotateClockwise()), - popup, "rotateclockwise"); + 0, TQT_TQOBJECT(this), TQT_SLOT(rotateClockwise()), + TQT_TQOBJECT(popup), "rotateclockwise"); action->plug(popup); action = new KAction(i18n("Rotate &Counterclockwise"), "rotate_ccw", - 0, this, TQT_SLOT(rotateCounterclockwise()), - popup, "rotatecounterclockwise"); + 0, TQT_TQOBJECT(this), TQT_SLOT(rotateCounterclockwise()), + TQT_TQOBJECT(popup), "rotatecounterclockwise"); action->plug(popup); /* @@ -216,9 +216,9 @@ bool KPixmapRegionSelectorWidget::eventFilter(TQObject *obj, TQEvent *ev) if ( ev->type() == TQEvent::MouseButtonPress ) { TQMouseEvent *mev= (TQMouseEvent *)(ev); - //kdDebug() << TQString("click at %1,%2").arg( mev->x() ).arg( mev->y() ) << endl; + //kdDebug() << TQString("click at %1,%2").tqarg( mev->x() ).tqarg( mev->y() ) << endl; - if ( mev->button() == RightButton ) + if ( mev->button() == Qt::RightButton ) { KPopupMenu *popup = createPopupMenu( ); popup->exec( mev->globalPos() ); @@ -249,7 +249,7 @@ bool KPixmapRegionSelectorWidget::eventFilter(TQObject *obj, TQEvent *ev) { TQMouseEvent *mev= (TQMouseEvent *)(ev); - //kdDebug() << TQString("move to %1,%2").arg( mev->x() ).arg( mev->y() ) << endl; + //kdDebug() << TQString("move to %1,%2").tqarg( mev->x() ).tqarg( mev->y() ) << endl; if ( m_state == Resizing ) { @@ -421,7 +421,7 @@ void KPixmapRegionSelectorWidget::setMaximumWidgetSize(int width, int height) if (m_selectedRegion == m_originalPixmap.rect()) m_selectedRegion=TQRect(); // kdDebug() << TQString(" original Pixmap :") << m_originalPixmap.rect() << endl; -// kdDebug() << TQString(" unzoomed Pixmap : %1 x %2 ").arg(m_unzoomedPixmap.width()).arg(m_unzoomedPixmap.height()) << endl; +// kdDebug() << TQString(" unzoomed Pixmap : %1 x %2 ").tqarg(m_unzoomedPixmap.width()).tqarg(m_unzoomedPixmap.height()) << endl; if ( !m_originalPixmap.isNull() && ( m_originalPixmap.width() > m_maxWidth || @@ -429,7 +429,7 @@ void KPixmapRegionSelectorWidget::setMaximumWidgetSize(int width, int height) { /* We have to resize the pixmap to get it complete on the screen */ TQImage image=m_originalPixmap.convertToImage(); - m_originalPixmap.convertFromImage( image.smoothScale( width, height, TQImage::ScaleMin ) ); + m_originalPixmap.convertFromImage( image.smoothScale( width, height, TQ_ScaleMin ) ); //m_originalPixmap.convertFromImage( KImageEffect::sample( image, width, height ) ); double oldZoomFactor = m_zoomFactor; m_zoomFactor=m_originalPixmap.width()/(double)m_unzoomedPixmap.width(); diff --git a/libkdepim/kprefsdialog.cpp b/libkdepim/kprefsdialog.cpp index 547c712c5..bb2bdca79 100644 --- a/libkdepim/kprefsdialog.cpp +++ b/libkdepim/kprefsdialog.cpp @@ -401,7 +401,7 @@ KPrefsWidRadios::KPrefsWidRadios( KConfigSkeleton::ItemEnum *item, TQWidget *tqparent ) : mItem( item ) { - mBox = new TQButtonGroup( 1, TQt::Horizontal, mItem->label(), tqparent ); + mBox = new TQButtonGroup( 1, Qt::Horizontal, mItem->label(), tqparent ); connect( mBox, TQT_SIGNAL( clicked( int ) ), TQT_SIGNAL( changed() ) ); } diff --git a/libkdepim/kregexp3.cpp b/libkdepim/kregexp3.cpp index 87827e079..ca9725ba2 100644 --- a/libkdepim/kregexp3.cpp +++ b/libkdepim/kregexp3.cpp @@ -64,7 +64,7 @@ TQString KRegExp3::tqreplace( const TQString & str, pos = rx.search( replacementStr, pos ); #ifdef DEBUG_KREGEXP3 - kdDebug() << TQString(" Found match at pos %1").arg(pos) << endl; + kdDebug() << TQString(" Found match at pos %1").tqarg(pos) << endl; #endif if ( pos < 0 ) { @@ -88,13 +88,13 @@ TQString KRegExp3::tqreplace( const TQString & str, backRefs << rx.cap(i).toInt(); #ifdef DEBUG_KREGEXP3 kdDebug() << TQString(" Found %1 at position %2 in the capturedTexts.") - .arg(backRefs.last()).arg(i) << endl; + .tqarg(backRefs.last()).tqarg(i) << endl; #endif break; } pos += rx.matchedLength(); #ifdef DEBUG_KREGEXP3 - kdDebug() << TQString(" Setting new pos to %1.").arg(pos) << endl; + kdDebug() << TQString(" Setting new pos to %1.").tqarg(pos) << endl; #endif oldpos = pos; } @@ -125,7 +125,7 @@ TQString KRegExp3::tqreplace( const TQString & str, pos = search( str, pos ); #ifdef DEBUG_KREGEXP3 - kdDebug() << TQString(" Found match at pos %1").arg(pos) << endl; + kdDebug() << TQString(" Found match at pos %1").tqarg(pos) << endl; #endif if ( pos < 0 ) { @@ -168,7 +168,7 @@ TQString KRegExp3::tqreplace( const TQString & str, } pos += matchedLength(); #ifdef DEBUG_KREGEXP3 - kdDebug() << TQString(" Setting new pos to %1.").arg(pos) << endl; + kdDebug() << TQString(" Setting new pos to %1.").tqarg(pos) << endl; #endif oldpos = pos; diff --git a/libkdepim/kscoring.cpp b/libkdepim/kscoring.cpp index 8c5f737e6..58595b933 100644 --- a/libkdepim/kscoring.cpp +++ b/libkdepim/kscoring.cpp @@ -936,7 +936,7 @@ KScoringRule* KScoringManager::addRule(const ScorableArticle& a, TQString group, KScoringRule* KScoringManager::addRule(KScoringRule* expr) { - int i = allRules.findRef(expr); + int i = allRules.tqfindRef(expr); if (i == -1) { // only add a rule we don't know addRuleInternal(expr); @@ -965,7 +965,7 @@ void KScoringManager::addRuleInternal(KScoringRule *e) void KScoringManager::cancelNewRule(KScoringRule *r) { // if e was'nt previously added to the list of rules, we delete it - int i = allRules.findRef(r); + int i = allRules.tqfindRef(r); if (i == -1) { kdDebug(5100) << "deleting rule " << r->getName() << endl; deleteRule(r); @@ -1002,7 +1002,7 @@ void KScoringManager::setRuleName(KScoringRule *r, const TQString& s) void KScoringManager::deleteRule(KScoringRule *r) { - int i = allRules.findRef(r); + int i = allRules.tqfindRef(r); if (i != -1) { allRules.remove(); emit changedRules(); @@ -1019,8 +1019,8 @@ void KScoringManager::editRule(KScoringRule *e, TQWidget *w) void KScoringManager::moveRuleAbove( KScoringRule *above, KScoringRule *below ) { - int aindex = allRules.findRef( above ); - int bindex = allRules.findRef( below ); + int aindex = allRules.tqfindRef( above ); + int bindex = allRules.tqfindRef( below ); if ( aindex <= 0 || bindex < 0 ) return; if ( aindex < bindex ) @@ -1031,8 +1031,8 @@ void KScoringManager::moveRuleAbove( KScoringRule *above, KScoringRule *below ) void KScoringManager::moveRuleBelow( KScoringRule *below, KScoringRule *above ) { - int bindex = allRules.findRef( below ); - int aindex = allRules.findRef( above ); + int bindex = allRules.tqfindRef( below ); + int aindex = allRules.tqfindRef( above ); if ( bindex < 0 || bindex >= (int)allRules.count() - 1 || aindex < 0 ) return; if ( bindex < aindex ) @@ -1137,7 +1137,7 @@ TQString KScoringManager::findUniqueName() const while (nr < 99999999) { nr++; - ret = i18n("rule %1").arg(nr); + ret = i18n("rule %1").tqarg(nr); duplicated=false; TQPtrListIterator<KScoringRule> it(allRules); diff --git a/libkdepim/kscoringeditor.cpp b/libkdepim/kscoringeditor.cpp index 7cec1a7db..0c1a42946 100644 --- a/libkdepim/kscoringeditor.cpp +++ b/libkdepim/kscoringeditor.cpp @@ -301,7 +301,7 @@ ActionBase* SingleActionWidget::createAction() const case ActionBase::NOTIFY: return new ActionNotify(notifyEditor->text()); case ActionBase::COLOR: - return new ActionColor(colorEditor->color().name()); + return new ActionColor(TQString(colorEditor->color().name())); case ActionBase::MARKASREAD: return new ActionMarkAsRead(); default: diff --git a/libkdepim/ksubscription.cpp b/libkdepim/ksubscription.cpp index cff384f2b..a17ae8410 100644 --- a/libkdepim/ksubscription.cpp +++ b/libkdepim/ksubscription.cpp @@ -775,7 +775,7 @@ void KSubscription::slotUpdateStatusLabel() activeItemCount()); else text = i18n("%1: (1 matching)", "%1: (%n matching)", activeItemCount()) - .arg(account()->name()); + .tqarg(account()->name()); leftLabel->setText(text); } diff --git a/libkdepim/ktimeedit.cpp b/libkdepim/ktimeedit.cpp index 7512b89ee..c313009cb 100644 --- a/libkdepim/ktimeedit.cpp +++ b/libkdepim/ktimeedit.cpp @@ -43,7 +43,7 @@ class KOTimeValidator : public TQValidator { public: - KOTimeValidator(TQWidget* tqparent, const char* name=0) : TQValidator(tqparent, name) {} + KOTimeValidator(TQWidget* tqparent, const char* name=0) : TQValidator(TQT_TQOBJECT(tqparent), name) {} virtual State validate(TQString& str, int& /*cursorPos*/) const { @@ -126,7 +126,7 @@ KTimeEdit::KTimeEdit( TQWidget *tqparent, TQTime qt, const char *name ) insertItem( KGlobal::locale()->formatTime( TQTime( 23, 59, 59 ) ) ); updateText(); - setFocusPolicy(TQWidget::StrongFocus); + setFocusPolicy(Qt::StrongFocus); connect(this, TQT_SIGNAL(activated(int)), this, TQT_SLOT(active(int))); connect(this, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(hilit(int))); @@ -178,7 +178,7 @@ void KTimeEdit::setTime(TQTime newTime) { if ( mTime != newTime ) { - kdDebug(5300) << "KTimeEdit::setTime(): " << newTime.toString() << endl; + kdDebug(5300) << "KTimeEdit::setTime(): " << TQString(newTime.toString()) << endl; mTime = newTime; updateText(); diff --git a/libkdepim/kwidgetlister.cpp b/libkdepim/kwidgetlister.cpp index bc9d89803..98c6062be 100644 --- a/libkdepim/kwidgetlister.cpp +++ b/libkdepim/kwidgetlister.cpp @@ -125,7 +125,7 @@ void KWidgetLister::addWidgetAtEnd(TQWidget *w) { if (!w) w = this->createWidget(this); - mLayout->insertWidget( mLayout->findWidget( mButtonBox ), w ); + mLayout->insertWidget( mLayout->tqfindWidget( mButtonBox ), w ); mWidgetList.append( w ); w->show(); enableControls(); diff --git a/libkdepim/ldapclient.cpp b/libkdepim/ldapclient.cpp index 651c86159..2f29b7633 100644 --- a/libkdepim/ldapclient.cpp +++ b/libkdepim/ldapclient.cpp @@ -49,7 +49,7 @@ static KStaticDeleter<KConfig> configDeleter; TQString LdapObject::toString() const { - TQString result = TQString::tqfromLatin1( "\ndn: %1\n" ).arg( dn ); + TQString result = TQString::tqfromLatin1( "\ndn: %1\n" ).tqarg( dn ); for ( LdapAttrMap::ConstIterator it = attrs.begin(); it != attrs.end(); ++it ) { TQString attr = it.key(); for ( LdapAttrValue::ConstIterator it2 = (*it).begin(); it2 != (*it).end(); ++it2 ) { @@ -278,53 +278,53 @@ void LdapSearch::readConfig( LdapServer &server, KConfig *config, int j, bool ac { TQString prefix; if ( active ) prefix = "Selected"; - TQString host = config->readEntry( prefix + TQString( "Host%1" ).arg( j ), "" ).stripWhiteSpace(); + TQString host = config->readEntry( prefix + TQString( "Host%1" ).tqarg( j ), "" ).stripWhiteSpace(); if ( !host.isEmpty() ) server.setHost( host ); - int port = config->readNumEntry( prefix + TQString( "Port%1" ).arg( j ), 389 ); + int port = config->readNumEntry( prefix + TQString( "Port%1" ).tqarg( j ), 389 ); server.setPort( port ); - TQString base = config->readEntry( prefix + TQString( "Base%1" ).arg( j ), "" ).stripWhiteSpace(); + TQString base = config->readEntry( prefix + TQString( "Base%1" ).tqarg( j ), "" ).stripWhiteSpace(); if ( !base.isEmpty() ) server.setBaseDN( base ); - TQString user = config->readEntry( prefix + TQString( "User%1" ).arg( j ) ).stripWhiteSpace(); + TQString user = config->readEntry( prefix + TQString( "User%1" ).tqarg( j ) ).stripWhiteSpace(); if ( !user.isEmpty() ) server.setUser( user ); - TQString bindDN = config->readEntry( prefix + TQString( "Bind%1" ).arg( j ) ).stripWhiteSpace(); + TQString bindDN = config->readEntry( prefix + TQString( "Bind%1" ).tqarg( j ) ).stripWhiteSpace(); if ( !bindDN.isEmpty() ) server.setBindDN( bindDN ); - TQString pwdBindDN = config->readEntry( prefix + TQString( "PwdBind%1" ).arg( j ) ); + TQString pwdBindDN = config->readEntry( prefix + TQString( "PwdBind%1" ).tqarg( j ) ); if ( !pwdBindDN.isEmpty() ) server.setPwdBindDN( pwdBindDN ); - server.setTimeLimit( config->readNumEntry( prefix + TQString( "TimeLimit%1" ).arg( j ) ) ); - server.setSizeLimit( config->readNumEntry( prefix + TQString( "SizeLimit%1" ).arg( j ) ) ); - server.setVersion( config->readNumEntry( prefix + TQString( "Version%1" ).arg( j ), 3 ) ); - server.setSecurity( config->readNumEntry( prefix + TQString( "Security%1" ).arg( j ) ) ); - server.setAuth( config->readNumEntry( prefix + TQString( "Auth%1" ).arg( j ) ) ); - server.setMech( config->readEntry( prefix + TQString( "Mech%1" ).arg( j ) ) ); + server.setTimeLimit( config->readNumEntry( prefix + TQString( "TimeLimit%1" ).tqarg( j ) ) ); + server.setSizeLimit( config->readNumEntry( prefix + TQString( "SizeLimit%1" ).tqarg( j ) ) ); + server.setVersion( config->readNumEntry( prefix + TQString( "Version%1" ).tqarg( j ), 3 ) ); + server.setSecurity( config->readNumEntry( prefix + TQString( "Security%1" ).tqarg( j ) ) ); + server.setAuth( config->readNumEntry( prefix + TQString( "Auth%1" ).tqarg( j ) ) ); + server.setMech( config->readEntry( prefix + TQString( "Mech%1" ).tqarg( j ) ) ); } void LdapSearch::writeConfig( const LdapServer &server, KConfig *config, int j, bool active ) { TQString prefix; if ( active ) prefix = "Selected"; - config->writeEntry( prefix + TQString( "Host%1" ).arg( j ), server.host() ); - config->writeEntry( prefix + TQString( "Port%1" ).arg( j ), server.port() ); - config->writeEntry( prefix + TQString( "Base%1" ).arg( j ), server.baseDN() ); - config->writeEntry( prefix + TQString( "User%1" ).arg( j ), server.user() ); - config->writeEntry( prefix + TQString( "Bind%1" ).arg( j ), server.bindDN() ); - config->writeEntry( prefix + TQString( "PwdBind%1" ).arg( j ), server.pwdBindDN() ); - config->writeEntry( prefix + TQString( "TimeLimit%1" ).arg( j ), server.timeLimit() ); - config->writeEntry( prefix + TQString( "SizeLimit%1" ).arg( j ), server.sizeLimit() ); - config->writeEntry( prefix + TQString( "Version%1" ).arg( j ), server.version() ); - config->writeEntry( prefix + TQString( "Security%1" ).arg( j ), server.security() ); - config->writeEntry( prefix + TQString( "Auth%1" ).arg( j ), server.auth() ); - config->writeEntry( prefix + TQString( "Mech%1" ).arg( j ), server.mech() ); + config->writeEntry( prefix + TQString( "Host%1" ).tqarg( j ), server.host() ); + config->writeEntry( prefix + TQString( "Port%1" ).tqarg( j ), server.port() ); + config->writeEntry( prefix + TQString( "Base%1" ).tqarg( j ), server.baseDN() ); + config->writeEntry( prefix + TQString( "User%1" ).tqarg( j ), server.user() ); + config->writeEntry( prefix + TQString( "Bind%1" ).tqarg( j ), server.bindDN() ); + config->writeEntry( prefix + TQString( "PwdBind%1" ).tqarg( j ), server.pwdBindDN() ); + config->writeEntry( prefix + TQString( "TimeLimit%1" ).tqarg( j ), server.timeLimit() ); + config->writeEntry( prefix + TQString( "SizeLimit%1" ).tqarg( j ), server.sizeLimit() ); + config->writeEntry( prefix + TQString( "Version%1" ).tqarg( j ), server.version() ); + config->writeEntry( prefix + TQString( "Security%1" ).tqarg( j ), server.security() ); + config->writeEntry( prefix + TQString( "Auth%1" ).tqarg( j ), server.auth() ); + config->writeEntry( prefix + TQString( "Mech%1" ).tqarg( j ), server.mech() ); } KConfig* LdapSearch::config() @@ -351,7 +351,7 @@ LdapSearch::LdapSearch() void LdapSearch::readWeighForClient( LdapClient *client, KConfig *config, int clientNumber ) { - const int completionWeight = config->readNumEntry( TQString( "SelectedCompletionWeight%1" ).arg( clientNumber ), -1 ); + const int completionWeight = config->readNumEntry( TQString( "SelectedCompletionWeight%1" ).tqarg( clientNumber ), -1 ); if ( completionWeight != -1 ) client->setCompletionWeight( completionWeight ); } @@ -442,7 +442,7 @@ void LdapSearch::startSearch( const TQString& txt ) * person entries without an email address to show up, while still not showing things * like structural entries in the ldap tree. */ TQString filter = TQString( "&(|(objectclass=person)(objectclass=groupOfNames)(mail=*))(|(cn=%1*)(mail=%2*)(mail=*@%3*)(givenName=%4*)(sn=%5*))" ) - .arg( mSearchText ).arg( mSearchText ).arg( mSearchText ).arg( mSearchText ).arg( mSearchText ); + .tqarg( mSearchText ).tqarg( mSearchText ).tqarg( mSearchText ).tqarg( mSearchText ).tqarg( mSearchText ); TQValueList< LdapClient* >::Iterator it; for ( it = mClients.begin(); it != mClients.end(); ++it ) { @@ -590,7 +590,7 @@ void LdapSearch::makeSearchData( TQStringList& ret, LdapResultList& resList ) ret.append( mail ); } else { //kdDebug(5300) << "LdapSearch::makeSearchData() name: \"" << name << "\" mail: \"" << mail << "\"" << endl; - ret.append( TQString( "%1 <%2>" ).arg( name ).arg( mail ) ); + ret.append( TQString( "%1 <%2>" ).tqarg( name ).tqarg( mail ) ); } LdapResult sr; diff --git a/libkdepim/ldapsearchdialog.cpp b/libkdepim/ldapsearchdialog.cpp index 2297e17e4..36c7517b3 100644 --- a/libkdepim/ldapsearchdialog.cpp +++ b/libkdepim/ldapsearchdialog.cpp @@ -136,7 +136,7 @@ LDAPSearchDialog::LDAPSearchDialog( TQWidget* tqparent, const char* name ) page ); groupBox->setFrameShape( TQGroupBox::Box ); groupBox->setFrameShadow( TQGroupBox::Sunken ); - groupBox->setColumnLayout( 0, TQt::Vertical ); + groupBox->setColumnLayout( 0, Qt::Vertical ); TQGridLayout *boxLayout = new TQGridLayout( groupBox->tqlayout(), 2, 5, spacingHint() ); boxLayout->setColStretch( 1, 1 ); @@ -238,27 +238,27 @@ void LDAPSearchDialog::restoreSettings() for ( int j = 0; j < mNumHosts; ++j ) { KPIM::LdapServer ldapServer; - TQString host = config->readEntry( TQString( "SelectedHost%1" ).arg( j ), "" ); + TQString host = config->readEntry( TQString( "SelectedHost%1" ).tqarg( j ), "" ); if ( !host.isEmpty() ) ldapServer.setHost( host ); - int port = config->readUnsignedNumEntry( TQString( "SelectedPort%1" ).arg( j ) ); + int port = config->readUnsignedNumEntry( TQString( "SelectedPort%1" ).tqarg( j ) ); if ( port ) ldapServer.setPort( port ); - TQString base = config->readEntry( TQString( "SelectedBase%1" ).arg( j ), "" ); + TQString base = config->readEntry( TQString( "SelectedBase%1" ).tqarg( j ), "" ); if ( !base.isEmpty() ) ldapServer.setBaseDN( base ); - TQString bindDN = config->readEntry( TQString( "SelectedBind%1" ).arg( j ), "" ); + TQString bindDN = config->readEntry( TQString( "SelectedBind%1" ).tqarg( j ), "" ); if ( !bindDN.isEmpty() ) ldapServer.setBindDN( bindDN ); - TQString pwdBindDN = config->readEntry( TQString( "SelectedPwdBind%1" ).arg( j ), "" ); + TQString pwdBindDN = config->readEntry( TQString( "SelectedPwdBind%1" ).tqarg( j ), "" ); if ( !pwdBindDN.isEmpty() ) ldapServer.setPwdBindDN( pwdBindDN ); - KPIM::LdapClient* ldapClient = new KPIM::LdapClient( 0, this, "ldapclient" ); + KPIM::LdapClient* ldapClient = new KPIM::LdapClient( 0, TQT_TQOBJECT(this), "ldapclient" ); ldapClient->setServer( ldapServer ); TQStringList attrs; @@ -352,15 +352,15 @@ TQString LDAPSearchDialog::makeFilter( const TQString& query, const TQString& at if ( attr == i18n( "Name" ) ) { result += startsWith ? "|(cn=%1*)(sn=%2*)" : "|(cn=*%1*)(sn=*%2*)"; - result = result.arg( query ).arg( query ); + result = result.tqarg( query ).tqarg( query ); } else { result += (startsWith ? "%1=%2*" : "%1=*%2*"); if ( attr == i18n( "Email" ) ) { - result = result.arg( "mail" ).arg( query ); + result = result.tqarg( "mail" ).tqarg( query ); } else if ( attr == i18n( "Home Number" ) ) { - result = result.arg( "homePhone" ).arg( query ); + result = result.tqarg( "homePhone" ).tqarg( query ); } else if ( attr == i18n( "Work Number" ) ) { - result = result.arg( "telephoneNumber" ).arg( query ); + result = result.tqarg( "telephoneNumber" ).tqarg( query ); } else { // Error? result = TQString(); diff --git a/libkdepim/linklocator.cpp b/libkdepim/linklocator.cpp index 6a79dff15..e0c4c0d24 100644 --- a/libkdepim/linklocator.cpp +++ b/libkdepim/linklocator.cpp @@ -362,7 +362,7 @@ TQString LinkLocator::pngToDataUrl( const TQString & iconPath ) TQByteArray ba = pngFile.readAll(); pngFile.close(); return TQString::tqfromLatin1("data:image/png;base64,%1") - .arg( KCodecs::base64Encode( ba ) ); + .tqarg( KCodecs::base64Encode( ba ).data() ); } @@ -422,7 +422,7 @@ TQString LinkLocator::getEmoticon() // for copy & paste) representing the smiley htmlRep = TQString("<img class=\"pimsmileyimg\" src=\"%1\" " "alt=\"%2\" title=\"%3\" width=\"16\" height=\"16\"/>") - .arg( dataUrl, + .tqarg( dataUrl, TQStyleSheet::escape( smiley ), TQStyleSheet::escape( smiley ) ); } @@ -445,7 +445,7 @@ TQString LinkLocator::highlightedText() if ( ch != '/' && ch != '*' && ch != '_' ) return TQString(); - TQRegExp re = TQRegExp( TQString("\\%1([0-9A-Za-z]+)\\%2").arg( ch ).arg( ch ) ); + TQRegExp re = TQRegExp( TQString("\\%1([0-9A-Za-z]+)\\%2").tqarg( ch ).tqarg( ch ) ); if ( re.search( mText, mPos ) == mPos ) { uint length = re.matchedLength(); // there must be a whitespace after the closing formating symbol diff --git a/libkdepim/overlaywidget.cpp b/libkdepim/overlaywidget.cpp index 6ffc06d38..77ce34108 100644 --- a/libkdepim/overlaywidget.cpp +++ b/libkdepim/overlaywidget.cpp @@ -76,7 +76,7 @@ void OverlayWidget::setAlignWidget( TQWidget * w ) bool OverlayWidget::eventFilter( TQObject* o, TQEvent* e) { - if ( o == mAlignWidget && + if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(mAlignWidget) && ( e->type() == TQEvent::Move || e->type() == TQEvent::Resize ) ) { reposition(); } diff --git a/libkdepim/qutf7codec.cpp b/libkdepim/qutf7codec.cpp index db6589cd9..630dcaa25 100644 --- a/libkdepim/qutf7codec.cpp +++ b/libkdepim/qutf7codec.cpp @@ -183,7 +183,7 @@ public: qWarning("TQUtf7Decoder: 8bit char found in input. " "Parser has been re-initialized!"); resetParser(); - result += TQChar::replacement; + result += TQChar::tqreplacement; continue; } diff --git a/libkdepim/sendsmsdialog.cpp b/libkdepim/sendsmsdialog.cpp index 6a1e35417..d034fd73f 100644 --- a/libkdepim/sendsmsdialog.cpp +++ b/libkdepim/sendsmsdialog.cpp @@ -68,13 +68,13 @@ void SendSMSDialog::updateMessageLength() int length = mText->length(); if( length > 480 ) - mMessageLength->setText( TQString( "%1/%2 (%3)" ).arg( length ).arg( 500 ).arg( 4 ) ); + mMessageLength->setText( TQString( "%1/%2 (%3)" ).tqarg( length ).tqarg( 500 ).tqarg( 4 ) ); else if( length > 320 ) - mMessageLength->setText( TQString( "%1/%2 (%3)" ).arg( length ).arg( 480 ).arg( 3 ) ); + mMessageLength->setText( TQString( "%1/%2 (%3)" ).tqarg( length ).tqarg( 480 ).tqarg( 3 ) ); else if( length > 160 ) - mMessageLength->setText( TQString( "%1/%2 (%3)" ).arg( length ).arg( 320 ).arg( 2 ) ); + mMessageLength->setText( TQString( "%1/%2 (%3)" ).tqarg( length ).tqarg( 320 ).tqarg( 2 ) ); else - mMessageLength->setText( TQString( "%1/%2" ).arg( length ).arg( 160 ) ); + mMessageLength->setText( TQString( "%1/%2" ).tqarg( length ).tqarg( 160 ) ); } void SendSMSDialog::updateButtons() diff --git a/libkdepim/statusbarprogresswidget.cpp b/libkdepim/statusbarprogresswidget.cpp index 8ca46ff9b..2b2ef1dbc 100644 --- a/libkdepim/statusbarprogresswidget.cpp +++ b/libkdepim/statusbarprogresswidget.cpp @@ -268,7 +268,7 @@ bool StatusbarProgressWidget::eventFilter( TQObject *, TQEvent *ev ) if ( ev->type() == TQEvent::MouseButtonPress ) { TQMouseEvent *e = (TQMouseEvent*)ev; - if ( e->button() == LeftButton && mode != None ) { // toggle view on left mouse button + if ( e->button() == Qt::LeftButton && mode != None ) { // toggle view on left mouse button // Consensus seems to be that we should show/hide the fancy dialog when the user // clicks anywhere in the small one. mProgressDialog->slotToggleVisibility(); diff --git a/libkholidays/kholidays.cpp b/libkholidays/kholidays.cpp index 3b4ec63a2..6af3998fb 100644 --- a/libkholidays/kholidays.cpp +++ b/libkholidays/kholidays.cpp @@ -47,7 +47,7 @@ TQStringList KHolidays::locations() TQStringList::ConstIterator it; for ( it = files.begin(); it != files.end(); ++it ) - locs.append( (*it).mid((*it).findRev('_') + 1) ); + locs.append( (*it).mid((*it).tqfindRev('_') + 1) ); return locs; } diff --git a/libkmime/kmime_codecs.cpp b/libkmime/kmime_codecs.cpp index 1476477b6..bf33159e0 100644 --- a/libkmime/kmime_codecs.cpp +++ b/libkmime/kmime_codecs.cpp @@ -230,7 +230,7 @@ bool Encoder::flushOutputBuffer( char* & dcursor, const char * const dend ) { int numCharsLeft = mOutputBufferCursor - i; // push the remaining chars to the begin of the buffer: if ( numCharsLeft ) - qmemmove( mOutputBuffer, mOutputBuffer + i, numCharsLeft ); + tqmemmove( mOutputBuffer, mOutputBuffer + i, numCharsLeft ); // adjust cursor: mOutputBufferCursor = numCharsLeft; diff --git a/libkmime/kmime_content.cpp b/libkmime/kmime_content.cpp index 7ac10bbba..fc3af97b0 100644 --- a/libkmime/kmime_content.cpp +++ b/libkmime/kmime_content.cpp @@ -537,7 +537,7 @@ void Content::addContent(Content *c, bool prepend) for(Headers::Base *h=srcHdrs.first(); h; h=srcHdrs.next()) { if(h->isMimeHeader()) { //remove from this content - idx=h_eaders->findRef(h); + idx=h_eaders->tqfindRef(h); h_eaders->take(idx); //append to new content main->h_eaders->append(h); @@ -582,7 +582,7 @@ void Content::removeContent(Content *c, bool del) if(del) c_ontents->removeRef(c); else { - idx=c_ontents->findRef(c); + idx=c_ontents->tqfindRef(c); c_ontents->take(idx); } @@ -604,7 +604,7 @@ void Content::removeContent(Content *c, bool del) if(h->isMimeHeader()) { removeHeader(h->type()); //remove the old header first h_eaders->append(h); //now append the new one - idx=main->h_eaders->findRef(h); + idx=main->h_eaders->tqfindRef(h); main->h_eaders->take(idx); //remove from the old content kdDebug(5003) << "Content::removeContent(Content *c, bool del) : mime-header moved: " << h->as7BitString() << endl; diff --git a/libkmime/kmime_header_parsing.cpp b/libkmime/kmime_header_parsing.cpp index cf825a16a..59957f10b 100644 --- a/libkmime/kmime_header_parsing.cpp +++ b/libkmime/kmime_header_parsing.cpp @@ -1104,7 +1104,7 @@ bool parseParameter( const char* & scursor, const char * const send, "Chopping away \"*\"." << endl; maybeAttribute.truncate( maybeAttribute.length() - 1 ); } - result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); + result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); return true; } @@ -1128,19 +1128,19 @@ bool parseParameter( const char* & scursor, const char * const send, if ( !parseGenericQuotedString( scursor, send, maybeValue.qstring, isCRLF ) ) { scursor = oldscursor; - result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); + result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); return false; // this case needs further processing by upper layers!! } } else { // value is a token: if ( !parseToken( scursor, send, maybeValue.qpair, false /* no 8bit */ ) ) { scursor = oldscursor; - result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); + result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); return false; // this case needs further processing by upper layers!! } } - result = qMakePair( maybeAttribute.lower(), maybeValue ); + result = tqMakePair( maybeAttribute.lower(), maybeValue ); return true; } diff --git a/libkmime/kmime_headers.cpp b/libkmime/kmime_headers.cpp index a677cdd75..40a016343 100644 --- a/libkmime/kmime_headers.cpp +++ b/libkmime/kmime_headers.cpp @@ -811,7 +811,7 @@ TQDateTime Date::qdt() int Date::ageInDays() { - TQDate today=TQDate::tqcurrentDate(); + TQDate today=TQDate::currentDate(); return ( qdt().date().daysTo(today) ); } @@ -1107,10 +1107,10 @@ TQCString References::next() TQCString ret; if(p_os!=0) { - pos2=r_ef.findRev('>', p_os); + pos2=r_ef.tqfindRev('>', p_os); p_os=0; if(pos2!=-1) { - pos1=r_ef.findRev('<', pos2); + pos1=r_ef.tqfindRev('<', pos2); if(pos1!=-1) { ret=r_ef.mid(pos1, pos2-pos1+1); p_os=pos1; @@ -1129,7 +1129,7 @@ TQCString References::at(unsigned int i) while(pos1!=-1 && cnt < i+1) { pos2=pos1-1; - pos1=r_ef.findRev('<', pos2); + pos1=r_ef.tqfindRev('<', pos2); cnt++; } @@ -1174,7 +1174,7 @@ void References::append(const TQCString &s) for (int i=1;i<=3;i++) { // include the last three ids if (!lst.isEmpty()) { temp = lst.last(); - r_ef.insert(insPos,(TQString(" %1").arg(temp)).latin1()); + r_ef.insert(insPos,(TQString(" %1").tqarg(temp)).latin1()); lst.remove(temp); } else break; @@ -1183,7 +1183,7 @@ void References::append(const TQCString &s) while (!lst.isEmpty()) { // now insert the rest, up to 1000 characters temp = lst.last(); if ((15+r_ef.length()+temp.length())<1000) { - r_ef.insert(insPos,(TQString(" %1").arg(temp)).latin1()); + r_ef.insert(insPos,(TQString(" %1").tqarg(temp)).latin1()); lst.remove(temp); } else return; @@ -1475,7 +1475,7 @@ void ContentType::setParameter(const TQCString &name, const TQCString &value, bo else param=name+"="+value; - pos1=p_arams.tqfind(name, 0, false); + pos1=p_arams.tqfind(name.data(), 0, false); if(pos1==-1) { p_arams+="; "+param; } @@ -1484,7 +1484,7 @@ void ContentType::setParameter(const TQCString &name, const TQCString &value, bo if(pos2==-1) pos2=p_arams.length(); p_arams.remove(pos1, pos2-pos1); - p_arams.insert(pos1, param); + p_arams.insert(pos1, param.data()); } } diff --git a/libkmime/kmime_parsers.cpp b/libkmime/kmime_parsers.cpp index c9dc1e3d1..a7f758bf0 100644 --- a/libkmime/kmime_parsers.cpp +++ b/libkmime/kmime_parsers.cpp @@ -39,7 +39,7 @@ bool MultiPart::parse() //find the first valid boundary while(1) { - if( (pos1=s_rc.tqfind(b, pos1))==-1 || pos1==0 || s_rc[pos1-1]=='\n' ) //valid boundary found or no boundary at all + if( (pos1=s_rc.tqfind(b.data(), pos1))==-1 || pos1==0 || s_rc[pos1-1]=='\n' ) //valid boundary found or no boundary at all break; pos1+=blen; //boundary found but not valid => skip it; } @@ -60,7 +60,7 @@ bool MultiPart::parse() //now find the next valid boundary pos2=++pos1; //pos1 and pos2 point now to the beginning of the next line after the boundary while(1) { - if( (pos2=s_rc.tqfind(b, pos2))==-1 || s_rc[pos2-1]=='\n' ) //valid boundary or no more boundaries found + if( (pos2=s_rc.tqfind(b.data(), pos2))==-1 || s_rc[pos2-1]=='\n' ) //valid boundary or no more boundaries found break; pos2+=blen; //boundary is invalid => skip it; } @@ -108,7 +108,7 @@ TQCString NonMimeParser::guessMimeType(const TQCString& fileName) int pos; if(!fileName.isEmpty()) { - pos=fileName.findRev('.'); + pos=fileName.tqfindRev('.'); if(pos++ != -1) { tmp=fileName.mid(pos, fileName.length()-pos).upper(); if(tmp=="JPG" || tmp=="JPEG") mimeType="image/jpeg"; @@ -188,7 +188,7 @@ bool UUEncoded::parse() break; //too many "non-M-Lines" found, we give up } - if( (!containsBegin || !containsEnd) && s_ubject) { // message may be split up => parse subject + if( (!containsBegin || !containsEnd) && !s_ubject.isNull()) { // message may be split up => parse subject TQRegExp rx("[0-9]+/[0-9]+"); pos=rx.search(TQString(s_ubject), 0); len=rx.matchedLength(); @@ -249,7 +249,7 @@ bool YENCEncoded::yencMeta(TQCString& src, const TQCString& name, int* value) bool found = false; TQCString sought=name + "="; - int iPos=src.tqfind( sought); + int iPos=src.tqfind( sought.data() ); if (iPos>-1) { int pos1=src.tqfind(' ', iPos); int pos2=src.tqfind('\r', iPos); @@ -261,7 +261,7 @@ bool YENCEncoded::yencMeta(TQCString& src, const TQCString& name, int* value) pos1=pos3; if (pos4>=0 && (pos1<0 || pos1>pos4)) pos1=pos4; - iPos=src.findRev( '=', pos1)+1; + iPos=src.tqfindRev( '=', pos1)+1; if (iPos<pos1) { char c=src.at( iPos); if ( c>='0' && c<='9') { @@ -391,7 +391,7 @@ bool YENCEncoded::parse() ch+=256; if (totalSize>=yencSize) break; - binary.at(totalSize++)=ch; + binary.tqat(totalSize++)=ch; lineLength++; } else @@ -404,7 +404,7 @@ bool YENCEncoded::parse() ch+=256; if (totalSize>=yencSize) break; - binary.at(totalSize++)=ch; + binary.tqat(totalSize++)=ch; lineLength++; pos++; } diff --git a/libkmime/kmime_util.cpp b/libkmime/kmime_util.cpp index 167ac78d7..6fea9fc84 100644 --- a/libkmime/kmime_util.cpp +++ b/libkmime/kmime_util.cpp @@ -32,6 +32,7 @@ #include <tqtextcodec.h> #include <tqstrlist.h> // for TQStrIList #include <tqregexp.h> +#include <tqdatetime.h> #include <stdlib.h> #include <ctype.h> @@ -71,7 +72,7 @@ bool isUsAscii(const TQString &s) { uint sLength = s.length(); for (uint i=0; i<sLength; i++) - if (s.at(i).latin1()<=0) // c==0: non-latin1, c<0: non-us-ascii + if (s.tqat(i).latin1()<=0) // c==0: non-latin1, c<0: non-us-ascii return false; return true; @@ -126,7 +127,8 @@ TQString decodeRFC2047String(const TQCString &src, const char **usedCS, { TQCString result, str; TQCString declaredCS; - char *pos, *dest, *beg, *end, *mid, *endOfLastEncWord=0; + const char *beg, *end, *mid, *pos=0; + char *dest, *endOfLastEncWord=0; char encoding = '\0'; bool valid, onlySpacesSinceLastWord=false; const int maxLen=400; @@ -375,7 +377,7 @@ TQCString extractHeader(const TQCString &src, const char *name) pos1 = 0; } else { n.prepend("\n"); - pos1 = src.tqfind(n,0,false); + pos1 = src.tqfind(n.data(),0,false); } if (pos1>-1) { //there is a header with the given name @@ -681,14 +683,14 @@ DateFormatter::fancy(time_t otime) const if ( diff < 24 * 60 * 60 ) { if ( old.date().year() == mDate.date().year() && old.date().dayOfYear() == mDate.date().dayOfYear() ) - return i18n( "Today %1" ).arg( locale-> + return i18n( "Today %1" ).tqarg( locale-> formatTime( old.time(), true ) ); } if ( diff < 2 * 24 * 60 * 60 ) { TQDateTime yesterday( mDate.addDays( -1 ) ); if ( old.date().year() == yesterday.date().year() && old.date().dayOfYear() == yesterday.date().dayOfYear() ) - return i18n( "Yesterday %1" ).arg( locale-> + return i18n( "Yesterday %1" ).tqarg( locale-> formatTime( old.time(), true) ); } for ( int i = 3; i < 7; i++ ) diff --git a/libkmime/kqcstringsplitter.cpp b/libkmime/kqcstringsplitter.cpp index 4f8263133..d406691c3 100644 --- a/libkmime/kqcstringsplitter.cpp +++ b/libkmime/kqcstringsplitter.cpp @@ -52,7 +52,7 @@ bool KTQCStringSplitter::first() start=0; - end=src.tqfind(sep, start); + end=src.tqfind(sep.data(), start); if(end!=-1) { dst=src.mid(start, end); @@ -83,7 +83,7 @@ bool KTQCStringSplitter::last() end=src.length(); - start=src.findRev(sep,end); + start=src.tqfindRev(sep.data(),end); if(start!=-1) { dst=src.mid(start, end-start); @@ -106,7 +106,7 @@ bool KTQCStringSplitter::next() if(start< (int) src.length()) { - end=src.tqfind(sep, start); + end=src.tqfind(sep.data(), start); if(end!=-1) { dst=src.mid(start, end-start); @@ -142,7 +142,7 @@ bool KTQCStringSplitter::prev() if(end>0) { - start=src.findRev(sep,end); + start=src.tqfindRev(sep.data(),end); if(start!=-1) dst=src.mid(start, end-start); diff --git a/libkpgp/kpgp.cpp b/libkpgp/kpgp.cpp index f3227ac31..3abd1d79f 100644 --- a/libkpgp/kpgp.cpp +++ b/libkpgp/kpgp.cpp @@ -371,7 +371,7 @@ Module::encrypt( Block& block, TQString str = i18n("%1 = 'signing failed' error message", "%1\nDo you want to send the message unsigned, " "or cancel sending the message?") - .arg( pgp->lastErrorMessage() ); + .tqarg( pgp->lastErrorMessage() ); TQApplication::setOverrideCursor( TQCursor(TQCursor::ArrowCursor) ); int ret = KMessageBox::warningContinueCancel( 0, str, i18n("PGP Warning"), @@ -389,7 +389,7 @@ Module::encrypt( Block& block, TQString str = i18n("%1 = 'bad keys' error message", "%1\nDo you want to encrypt anyway, leave the " "message as-is, or cancel sending the message?") - .arg( pgp->lastErrorMessage() ); + .tqarg( pgp->lastErrorMessage() ); TQApplication::setOverrideCursor( TQCursor(TQCursor::ArrowCursor) ); int ret = KMessageBox::warningYesNoCancel( 0, str, @@ -416,7 +416,7 @@ Module::encrypt( Block& block, TQString str = i18n("%1 = 'missing keys' error message", "%1\nDo you want to leave the message as-is, " "or cancel sending the message?") - .arg( pgp->lastErrorMessage() ); + .tqarg( pgp->lastErrorMessage() ); TQApplication::setOverrideCursor( TQCursor(TQCursor::ArrowCursor) ); int ret = KMessageBox::warningContinueCancel( 0, str, i18n("PGP Warning"), @@ -432,10 +432,10 @@ Module::encrypt( Block& block, if( status & ERROR ) { // show error dialog errMsg = i18n( "The following error occurred:\n%1" ) - .arg( pgp->lastErrorMessage() ); + .tqarg( pgp->lastErrorMessage() ); TQString details = i18n( "This is the error message of %1:\n%2" ) - .arg( ( pgpType == tGPG ) ? "GnuPG" : "PGP" ) - .arg( block.error().data() ); + .tqarg( ( pgpType == tGPG ) ? "GnuPG" : "PGP" ) + .tqarg( block.error().data() ); TQApplication::setOverrideCursor( TQCursor(TQCursor::ArrowCursor) ); KMessageBox::detailedSorry( 0, errMsg, details ); TQApplication::restoreOverrideCursor(); @@ -1216,7 +1216,7 @@ Module::getEncryptionKeys( const TQString& person ) "encryption key(s) for \"%1\".\n\n" "Please re-select the key(s) which should " "be used for this recipient." - ).arg(person), + ).tqarg(person), keyIds, allowedKeys ); if( !keyIds.isEmpty() ) { @@ -1280,7 +1280,7 @@ Module::getEncryptionKeys( const TQString& person ) "found for \"%1\".\n\n" "Select the key(s) which should " "be used for this recipient." - ).arg(person), + ).tqarg(person), KeyIDList(), allowedKeys ); if( !keyIds.isEmpty() ) { @@ -1305,7 +1305,7 @@ Module::getEncryptionKeys( const TQString& person ) "More than one key matches \"%1\".\n\n" "Select the key(s) which should " "be used for this recipient." - ).arg(person), + ).tqarg(person), KeyIDList(), allowedKeys ); if( !keyIds.isEmpty() ) { @@ -1502,7 +1502,7 @@ Module::canonicalAddress( const TQString& _adress ) } else { - int index1 = address.findRev(" ",index); + int index1 = address.tqfindRev(" ",index); int index2 = address.tqfind(" ",index); if(index2 == -1) index2 = address.length(); return "<" + address.mid(index1+1 ,index2-index1-1) + ">"; @@ -1744,7 +1744,7 @@ Module::readAddressData() addressDataDict.clear(); for( int i=1; i<=num; i++ ) { - KConfigGroup addrGroup( config, TQString("Address #%1").arg(i).local8Bit() ); + KConfigGroup addrGroup( config, TQString("Address #%1").tqarg(i).local8Bit() ); address = addrGroup.readEntry( "Address" ); data.keyIds = KeyIDList::fromStringList( addrGroup.readListEntry( "Key IDs" ) ); data.encrPref = (EncryptPref) addrGroup.readNumEntry( "EncryptionPreference", @@ -1769,7 +1769,7 @@ Module::writeAddressData() for ( i=1, it = addressDataDict.begin(); it != addressDataDict.end(); ++it, i++ ) { - KConfigGroup addrGroup( config, TQString("Address #%1").arg(i).local8Bit() ); + KConfigGroup addrGroup( config, TQString("Address #%1").tqarg(i).local8Bit() ); addrGroup.writeEntry( "Address", it.key() ); addrGroup.writeEntry( "Key IDs", it.data().keyIds.toStringList() ); addrGroup.writeEntry( "EncryptionPreference", it.data().encrPref ); diff --git a/libkpgp/kpgpbase2.cpp b/libkpgp/kpgpbase2.cpp index da0038819..be96b5da9 100644 --- a/libkpgp/kpgpbase2.cpp +++ b/libkpgp/kpgpbase2.cpp @@ -139,12 +139,12 @@ Base2::encsign( Block& block, const KeyIDList& recipients, errMsg = i18n("Could not find public keys matching the userid(s)\n" "%1;\n" "the message is not encrypted.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); else errMsg = i18n("Could not find public keys matching the userid(s)\n" "%1;\n" "these persons will not be able to read the message.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); status |= MISSINGKEY; status |= ERROR; } @@ -171,13 +171,13 @@ Base2::encsign( Block& block, const KeyIDList& recipients, "for userid(s)\n" "%1.\n" "The message is not encrypted.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); else errMsg = i18n("Public keys not certified with trusted signature " "for userid(s)\n" "%1;\n" "these persons will not be able to read the message.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); status |= BADKEYS; status |= ERROR; return status; @@ -448,7 +448,7 @@ Base2::decrypt( Block& block, const char *passphrase ) index = error.tqfind('\'', index) + 1; index2 = error.tqfind('\'', index); block.setSignatureUserId( i18n("The keyring file %1 does not exist.\n" - "Please check your PGP setup.").arg(error.mid(index, index2-index)) ); + "Please check your PGP setup.").tqarg(TQString(error.mid(index, index2-index))) ); } else { diff --git a/libkpgp/kpgpbase5.cpp b/libkpgp/kpgpbase5.cpp index d78998475..46ded2c73 100644 --- a/libkpgp/kpgpbase5.cpp +++ b/libkpgp/kpgpbase5.cpp @@ -156,7 +156,7 @@ Base5::encsign( Block& block, const KeyIDList& recipients, else errMsg = i18n("The following key(s) are not trusted:\n%1\n" "Their owner(s) will not be able to decrypt the message.") - .arg(aStr); + .tqarg(TQString(aStr)); status |= ERROR; status |= BADKEYS; } @@ -167,9 +167,9 @@ Base5::encsign( Block& block, const KeyIDList& recipients, int index2 = error.tqfind('\n',index); errMsg = i18n("Missing encryption key(s) for:\n%1") - .arg(error.mid(index,index2-index)); + .tqarg(TQString(error.mid(index,index2-index))); // errMsg = TQString("Missing encryption key(s) for: %1") -// .arg(error.mid(index,index2-index)); +// .tqarg(error.mid(index,index2-index)); status |= ERROR; status |= MISSINGKEY; } diff --git a/libkpgp/kpgpbaseG.cpp b/libkpgp/kpgpbaseG.cpp index d9adb11a2..b04b31bf2 100644 --- a/libkpgp/kpgpbaseG.cpp +++ b/libkpgp/kpgpbaseG.cpp @@ -40,7 +40,7 @@ BaseG::BaseG() runGpg( "--version", 0 ); int eol = output.tqfind( '\n' ); if( eol > 0 ) { - int pos = output.findRev( ' ', eol - 1 ); + int pos = output.tqfindRev( ' ', eol - 1 ); if( pos != -1 ) { mVersion = output.mid( pos + 1, eol - pos - 1 ); kdDebug(5100) << "found GnuPG " << mVersion << endl; @@ -153,12 +153,12 @@ BaseG::encsign( Block& block, const KeyIDList& recipients, errMsg = i18n("Could not find public keys matching the userid(s)\n" "%1;\n" "the message is not encrypted.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); else errMsg = i18n("Could not find public keys matching the userid(s)\n" "%1;\n" "these persons will not be able to read the message.") - .arg( badkeys.data() ); + .tqarg( badkeys.data() ); status |= MISSINGKEY; status |= ERROR; } @@ -262,8 +262,8 @@ BaseG::decrypt( Block& block, const char *passphrase ) else { // Search backwards the user ID of the needed key - index2 = error.findRev('"', index) - 1; - index = error.findRev(" \"", index2) + 7; + index2 = error.tqfindRev('"', index) - 1; + index = error.tqfindRev(" \"", index2) + 7; // The conversion from UTF8 is necessary because gpg stores and // prints user IDs in UTF8 block.setRequiredUserId( TQString::fromUtf8( error.mid( index, index2 - index + 1 ) ) ); @@ -332,7 +332,7 @@ BaseG::decrypt( Block& block, const char *passphrase ) // get the primary user ID of the signer index = error.tqfind('"',index); index2 = error.tqfind('\n',index+1); - index2 = error.findRev('"', index2-1); + index2 = error.tqfindRev('"', index2-1); block.setSignatureUserId( error.mid( index+1, index2-index-1 ) ); } else if( error.tqfind("BAD signature", index) != -1 ) @@ -342,7 +342,7 @@ BaseG::decrypt( Block& block, const char *passphrase ) // get the primary user ID of the signer index = error.tqfind('"',index); index2 = error.tqfind('\n',index+1); - index2 = error.findRev('"', index2-1); + index2 = error.tqfindRev('"', index2-1); block.setSignatureUserId( error.mid( index+1, index2-index-1 ) ); } else if( error.tqfind("Can't find the right public key", index) != -1 ) diff --git a/libkpgp/kpgpui.cpp b/libkpgp/kpgpui.cpp index 11bd79294..5984c8764 100644 --- a/libkpgp/kpgpui.cpp +++ b/libkpgp/kpgpui.cpp @@ -76,7 +76,7 @@ PassphraseDialog::PassphraseDialog( TQWidget *tqparent, if (keyID.isNull()) label = new TQLabel(i18n("Please enter your OpenPGP passphrase:"),rightArea); else - label = new TQLabel(i18n("Please enter the OpenPGP passphrase for\n\"%1\":").arg(keyID), + label = new TQLabel(i18n("Please enter the OpenPGP passphrase for\n\"%1\":").tqarg(keyID), rightArea); lineedit = new KPasswordEdit( rightArea ); lineedit->setEchoMode(TQLineEdit::Password); @@ -432,7 +432,7 @@ void KeySelectionDialog::initKeylist( const KeyList& keyList, (*it)->primaryUserID() ); // select and open the given key - if( keyIds.findIndex( curKeyId ) != -1 ) { + if( keyIds.tqfindIndex( curKeyId ) != -1 ) { if( 0 == firstSelectedItem ) { firstSelectedItem = primaryUserID; } @@ -461,7 +461,7 @@ void KeySelectionDialog::initKeylist( const KeyList& keyList, childItem = new TQListViewItem( primaryUserID, "", i18n( "Fingerprint: %1" ) - .arg( beautifyFingerprint( (*it)->primaryFingerprint() ) ) ); + .tqarg( beautifyFingerprint( (*it)->primaryFingerprint() ) ) ); if( primaryUserID->isSelected() && mListView->isMultiSelection() ) { mListView->setSelected( childItem, true ); } @@ -543,15 +543,15 @@ TQString KeySelectionDialog::keyInfo( const Kpgp::Key *key ) const if( remark.isEmpty() ) { return " " + i18n("creation date and status of an OpenPGP key", "Creation date: %1, tqStatus: %2") - .arg( KGlobal::locale()->formatDate( dt.date(), true ) ) - .arg( status ); + .tqarg( KGlobal::locale()->formatDate( dt.date(), true ) ) + .tqarg( status ); } else { return " " + i18n("creation date, status and remark of an OpenPGP key", "Creation date: %1, tqStatus: %2 (%3)") - .arg( KGlobal::locale()->formatDate( dt.date(), true ) ) - .arg( status ) - .arg( remark ); + .tqarg( KGlobal::locale()->formatDate( dt.date(), true ) ) + .tqarg( status ) + .tqarg( remark ); } } @@ -920,7 +920,7 @@ void KeySelectionDialog::slotCheckSelection( TQListViewItem* plvi /* = 0 */ ) // extended selection mode a normal left click deselects // the not clicked items. if( 0 < selectedCount ) { - if( -1 == mKeyIds.findIndex( lvi->text(0).local8Bit() ) ) { + if( -1 == mKeyIds.tqfindIndex( lvi->text(0).local8Bit() ) ) { // some items of this key are selected and the key wasn't selected // before => the user selected something kdDebug(5100) << "selectedCount: "<<selectedCount<<"/"<<itemCount @@ -928,7 +928,7 @@ void KeySelectionDialog::slotCheckSelection( TQListViewItem* plvi /* = 0 */ ) userAction = SELECTED; } else if( ( itemCount > selectedCount ) && - ( -1 != mKeyIds.findIndex( lvi->text(0).local8Bit() ) ) ) { + ( -1 != mKeyIds.tqfindIndex( lvi->text(0).local8Bit() ) ) ) { // some items of this key are unselected and the key was selected // before => the user deselected something kdDebug(5100) << "selectedCount: "<<selectedCount<<"/"<<itemCount @@ -1014,7 +1014,7 @@ bool KeySelectionDialog::checkKeys( const TQValueList<TQListViewItem*>& keys ) c ++it ) { kdDebug(5100) << "Checking key 0x" << getKeyId( *it ) << "...\n"; pProgressDlg->setLabel( i18n("Checking key 0x%1...") - .arg( getKeyId( *it ) ) ); + .tqarg( TQString( getKeyId( *it ) ) ) ); kapp->processEvents(); keysAllowed = keysAllowed && ( -1 != keyAdmissibility( *it, AllowExpensiveTrustCheck ) ); pProgressDlg->progressBar()->advance( 1 ); @@ -1383,7 +1383,7 @@ KeyApprovalDialog::KeyApprovalDialog( const TQStringList& addresses, //hbox->setStretchFactor( keyidLB, 10 ); //mKeyIdListBoxes.insert( 0, keyidLB ); - new KSeparator( Horizontal, bigvbox ); + new KSeparator( Qt::Horizontal, bigvbox ); } else { mEncryptToSelf = 0; @@ -1402,7 +1402,7 @@ KeyApprovalDialog::KeyApprovalDialog( const TQStringList& addresses, ++kit; // skip the sender's key id } else { - new KSeparator( Horizontal, bigvbox ); + new KSeparator( Qt::Horizontal, bigvbox ); } TQHBox *hbox = new TQHBox( bigvbox ); @@ -1543,7 +1543,7 @@ KeyApprovalDialog::slotChangeEncryptionKey( int nr ) "Select the key(s) which should " "be used to encrypt the message " "for\n%1") - .arg( mAddressLabels[nr-1]->text() ), + .tqarg( mAddressLabels[nr-1]->text() ), keyIds, mAddressLabels[nr-1]->text(), mAllowedKeys ); diff --git a/libkpimexchange/core/CMakeLists.txt b/libkpimexchange/core/CMakeLists.txt index a91cedb00..e1d246cad 100644 --- a/libkpimexchange/core/CMakeLists.txt +++ b/libkpimexchange/core/CMakeLists.txt @@ -40,6 +40,6 @@ tde_add_library( kpimexchange SHARED AUTOMOC exchangeclient.cpp exchangeaccount.cpp exchangedownload.cpp exchangeupload.cpp exchangedelete.cpp utils.cpp exchangeprogress.cpp exchangemonitor.cpp VERSION 1.0.0 - LINK kcal-shared + LINK ${TQT_LIBRARIES} kcal-shared DESTINATION ${LIB_INSTALL_DIR} ) diff --git a/libkpimexchange/core/exchangeaccount.cpp b/libkpimexchange/core/exchangeaccount.cpp index 01ca1f02c..14b465605 100644 --- a/libkpimexchange/core/exchangeaccount.cpp +++ b/libkpimexchange/core/exchangeaccount.cpp @@ -249,7 +249,7 @@ void ExchangeAccount::slotFolderResult( KIO::Job *job ) if ( job->error() ) { kdError() << "Error: Cannot get well-know folder names; " << job->error() << endl; TQString text = i18n("ExchangeAccount\nError accessing '%1': %2") - .arg( baseURL().prettyURL() ).arg( job->errorString() ); + .tqarg( baseURL().prettyURL() ).tqarg( job->errorString() ); KMessageBox::error( 0, text ); mError = true; return; diff --git a/libkpimexchange/core/exchangedownload.cpp b/libkpimexchange/core/exchangedownload.cpp index a13672d90..cb941711f 100644 --- a/libkpimexchange/core/exchangedownload.cpp +++ b/libkpimexchange/core/exchangedownload.cpp @@ -182,8 +182,8 @@ void ExchangeDownload::slotSearchResult( KIO::Job *job ) kdError() << "ExchangeDownload::slotSearchResult() error: " << job->error() << endl; TQString text = i18n("ExchangeDownload\nError accessing '%1': %2") - .arg( mAccount->calendarURL().prettyURL() ) - .arg( job->errorString() ); + .tqarg( mAccount->calendarURL().prettyURL() ) + .tqarg( job->errorString() ); KMessageBox::error( 0, text ); finishUp( ExchangeClient::CommunicationError, job ); return; @@ -401,7 +401,7 @@ void ExchangeDownload::slotPropFindResult( KIO::Job *job ) TQString lastModified = prop.namedItem( "lastmodified" ).toElement().text(); if ( !lastModified.isEmpty() ) { - TQDateTime dt = utcAsZone( TQDateTime::fromString( lastModified, TQt::ISODate ), localTimeZoneId ); + TQDateTime dt = utcAsZone( TQDateTime::fromString( lastModified, Qt::ISODate ), localTimeZoneId ); event->setLastModified( dt ); kdDebug() << "Got lastModified:" << lastModified << ", " << dt.toString() << endl; } @@ -436,7 +436,7 @@ void ExchangeDownload::slotPropFindResult( KIO::Job *job ) TQString created = prop.namedItem( "created" ).toElement().text(); if ( !created.isEmpty() ) { - TQDateTime dt = utcAsZone( TQDateTime::fromString( created, TQt::ISODate ), + TQDateTime dt = utcAsZone( TQDateTime::fromString( created, Qt::ISODate ), localTimeZoneId ); event->setCreated( dt ); kdDebug() << "got created: " << dt.toString() << endl; @@ -444,7 +444,7 @@ void ExchangeDownload::slotPropFindResult( KIO::Job *job ) TQString dtstart = prop.namedItem( "dtstart" ).toElement().text(); if ( !dtstart.isEmpty() ) { - TQDateTime dt = utcAsZone( TQDateTime::fromString( dtstart, TQt::ISODate ), + TQDateTime dt = utcAsZone( TQDateTime::fromString( dtstart, Qt::ISODate ), localTimeZoneId ); event->setDtStart( dt ); kdDebug() << "got dtstart: " << dtstart << " becomes in timezone " << dt.toString() << endl; @@ -457,7 +457,7 @@ void ExchangeDownload::slotPropFindResult( KIO::Job *job ) TQString dtend = prop.namedItem( "dtend" ).toElement().text(); if ( !dtend.isEmpty() ) { - TQDateTime dt = utcAsZone( TQDateTime::fromString( dtend, TQt::ISODate ), + TQDateTime dt = utcAsZone( TQDateTime::fromString( dtend, Qt::ISODate ), localTimeZoneId ); // Outlook thinks differently about floating event timing than libkcal if ( floats ) dt = dt.addDays( -1 ); @@ -510,7 +510,7 @@ void ExchangeDownload::slotPropFindResult( KIO::Job *job ) list = exdate.elementsByTagNameNS( "xml:", "v" ); for( uint i=0; i < list.count(); i++ ) { TQDomElement item = list.item(i).toElement(); - TQDate date = utcAsZone( TQDateTime::fromString( item.text(), TQt::ISODate ), localTimeZoneId ).date(); + TQDate date = utcAsZone( TQDateTime::fromString( item.text(), Qt::ISODate ), localTimeZoneId ).date(); exdates.append( date ); // kdDebug() << "Got exdate: " << date.toString() << endl; } diff --git a/libkpimexchange/core/exchangemonitor.cpp b/libkpimexchange/core/exchangemonitor.cpp index ddb953135..b88510daf 100644 --- a/libkpimexchange/core/exchangemonitor.cpp +++ b/libkpimexchange/core/exchangemonitor.cpp @@ -104,7 +104,7 @@ ExchangeMonitor::ExchangeMonitor( ExchangeAccount* account, int pollMode, const // kdError() << "Error in socket listen: " << code << endl; //mSocket.enableRead( true ); kdDebug() << "Port: " << mSocket->port() << endl; - kdDebug() << "Host: " << mSocket->address().toString() << endl; + kdDebug() << "Host: " << TQString(mSocket->address().toString()) << endl; // mStream = new TQTextStream( mSocket ); } @@ -303,7 +303,7 @@ void ExchangeMonitor::slotActivated( int ) for ( it = lines.begin(); it != lines.end(); ++it ) { TQString line = (*it).stripWhiteSpace().lower(); if ( line.startsWith( "subscription-id: " ) ) - IDs = makeIDList( line.section(":",1).stripWhiteSpace() ); + IDs = makeIDList( TQString(line.section(":",1)).stripWhiteSpace() ); } if ( IDs.isEmpty() ) { diff --git a/libkpimexchange/core/exchangeprogress.cpp b/libkpimexchange/core/exchangeprogress.cpp index 84be823ae..a8fad42f9 100644 --- a/libkpimexchange/core/exchangeprogress.cpp +++ b/libkpimexchange/core/exchangeprogress.cpp @@ -65,7 +65,7 @@ void ExchangeProgress::slotTransferFinished() void ExchangeProgress::updateLabel() { progressBar()->setValue( m_finished ); - TQString str = i18n( "Downloading, %1 of %2" ).arg( m_finished ).arg( m_total ); + TQString str = i18n( "Downloading, %1 of %2" ).tqarg( m_finished ).tqarg( m_total ); setLabel( str ); } diff --git a/libkpimexchange/core/exchangeupload.cpp b/libkpimexchange/core/exchangeupload.cpp index 6582e57ea..50159fecf 100644 --- a/libkpimexchange/core/exchangeupload.cpp +++ b/libkpimexchange/core/exchangeupload.cpp @@ -253,20 +253,20 @@ void ExchangeUpload::startUpload( const KURL &url ) if ( tzOffset == 0 ) offsetString = "Z"; else if ( tzOffset > 0 ) - offsetString = TQString( "+%1:%2" ).arg(tzOffset/60, 2).arg( tzOffset%60, 2 ); + offsetString = TQString( "+%1:%2" ).tqarg(tzOffset/60, 2).tqarg( tzOffset%60, 2 ); else - offsetString = TQString( "-%1:%2" ).arg((-tzOffset)/60, 2).arg( (-tzOffset)%60, 2 ); + offsetString = TQString( "-%1:%2" ).tqarg((-tzOffset)/60, 2).tqarg( (-tzOffset)%60, 2 ); offsetString = offsetString.tqreplace( TQRegExp(" "), "0" ); kdDebug() << "Timezone offset: " << tzOffset << " : " << offsetString << endl; kdDebug() << "ExchangeUpload::mTimeZoneId=" << mTimeZoneId << endl; addElement( doc, prop, "urn:schemas:calendar:", "dtstart", - zoneAsUtc( event->dtStart(), mTimeZoneId ).toString( TQt::ISODate ) + "Z" ); + zoneAsUtc( event->dtStart(), mTimeZoneId ).toString( Qt::ISODate ) + "Z" ); // event->dtStart().toString( "yyyy-MM-ddThh:mm:ss.zzzZ" ) ); // 2002-06-04T08:00:00.000Z" ); addElement( doc, prop, "urn:schemas:calendar:", "dtend", - zoneAsUtc( event->dtEnd(), mTimeZoneId ).toString( TQt::ISODate ) + "Z" ); + zoneAsUtc( event->dtEnd(), mTimeZoneId ).toString( Qt::ISODate ) + "Z" ); #if 0 addElement( doc, prop, "urn:schemas:calendar:", "dtstart", event->dtStart().toString( "yyyy-MM-ddThh:mm:ss.zzz" )+ offsetString ); @@ -275,7 +275,7 @@ void ExchangeUpload::startUpload( const KURL &url ) addElement( doc, prop, "urn:schemas:calendar:", "dtend", event->dtEnd().toString( "yyyy-MM-ddThh:mm:ss.zzz" ) + offsetString ); #endif - addElement( doc, prop, "urn:schemas:calendar:", "lastmodified", zoneAsUtc( event->lastModified(), mTimeZoneId ).toString( TQt::ISODate )+"Z" ); + addElement( doc, prop, "urn:schemas:calendar:", "lastmodified", zoneAsUtc( event->lastModified(), mTimeZoneId ).toString( Qt::ISODate )+"Z" ); // addElement( doc, prop, "urn:schemas:calendar:", "meetingstatus", "confirmed" ); addElement( doc, prop, "urn:schemas:httpmail:", "textdescription", event->description() ); @@ -308,7 +308,7 @@ void ExchangeUpload::startUpload( const KURL &url ) KCal::DateList::iterator it; for ( it = exdates.begin(); it != exdates.end(); ++it ) { TQString date = (*it).toString( "yyyy-MM-ddT00:00:00.000" )+ offsetString; -// TQString date = zoneAsUtc( (*it), mTimeZoneId ).toString( TQt::ISODate ); +// TQString date = zoneAsUtc( (*it), mTimeZoneId ).toString( Qt::ISODate ); addElement( doc, exdate, "xml:", "v", date ); } } diff --git a/libkpimidentities/identity.cpp b/libkpimidentities/identity.cpp index 0855f8c37..1305a2603 100644 --- a/libkpimidentities/identity.cpp +++ b/libkpimidentities/identity.cpp @@ -102,7 +102,7 @@ TQString Signature::textFromCommand( bool * ok ) const if ( rc != 0 ) { if ( ok ) *ok = false; TQString wmsg = i18n("<qt>Failed to execute signature script<br><b>%1</b>:<br>%2</qt>") - .arg( mUrl ).arg( strerror(rc) ); + .tqarg( mUrl ).tqarg( strerror(rc) ); KMessageBox::error(0, wmsg); return TQString(); } diff --git a/libkpimidentities/identitycombo.cpp b/libkpimidentities/identitycombo.cpp index e1ae08b30..a673e5675 100644 --- a/libkpimidentities/identitycombo.cpp +++ b/libkpimidentities/identitycombo.cpp @@ -66,7 +66,7 @@ void IdentityCombo::setCurrentIdentity( const Identity & identity ) { } void IdentityCombo::setCurrentIdentity( const TQString & name ) { - int idx = mIdentityManager->identities().findIndex( name ); + int idx = mIdentityManager->identities().tqfindIndex( name ); if ( idx < 0 ) return; if ( idx == currentItem() ) return; @@ -78,7 +78,7 @@ void IdentityCombo::setCurrentIdentity( const TQString & name ) { } void IdentityCombo::setCurrentIdentity( uint uoid ) { - int idx = mUoidList.findIndex( uoid ); + int idx = mUoidList.tqfindIndex( uoid ); if ( idx < 0 ) return; if ( idx == currentItem() ) return; @@ -93,7 +93,7 @@ void IdentityCombo::reloadCombo() { TQStringList identities = mIdentityManager->identities(); // the IM should prevent this from happening: assert( !identities.isEmpty() ); - identities.first() = i18n("%1 (Default)").arg( identities.first() ); + identities.first() = i18n("%1 (Default)").tqarg( identities.first() ); clear(); insertStringList( identities ); } @@ -109,7 +109,7 @@ void IdentityCombo::slotIdentityManagerChanged() { uint oldIdentity = mUoidList[ currentItem() ]; reloadUoidList(); - int idx = mUoidList.findIndex( oldIdentity ); + int idx = mUoidList.tqfindIndex( oldIdentity ); blockSignals( true ); reloadCombo(); diff --git a/libkpimidentities/identitymanager.cpp b/libkpimidentities/identitymanager.cpp index dd8479d85..4cc53e816 100644 --- a/libkpimidentities/identitymanager.cpp +++ b/libkpimidentities/identitymanager.cpp @@ -201,7 +201,7 @@ void IdentityManager::writeConfig() const { int i = 0; for ( ConstIterator it = mIdentities.begin() ; it != mIdentities.end() ; ++it, ++i ) { - KConfigGroup cg( mConfig, TQString::tqfromLatin1("Identity #%1").arg(i) ); + KConfigGroup cg( mConfig, TQString::tqfromLatin1("Identity #%1").tqarg(i) ); (*it).writeConfig( &cg ); if ( (*it).isDefault() ) { // remember which one is default: diff --git a/libksieve/shared/error.cpp b/libksieve/shared/error.cpp index faf20bcc6..9fe79c1da 100644 --- a/libksieve/shared/error.cpp +++ b/libksieve/shared/error.cpp @@ -129,7 +129,7 @@ namespace KSieve { "follow \"text:\" on the same line"); break; case NumberOutOfRange: - err = i18n("Parse error: Number out of Range (must be smaller than %1)").arg(UINT_MAX); + err = i18n("Parse error: Number out of Range (must be smaller than %1)").tqarg(UINT_MAX); break; case InvalidUTF8: err = i18n("Parse error: Invalid UTF-8 sequence"); @@ -188,51 +188,51 @@ namespace KSieve { err = i18n("\"require\" must be first command"); break; case RequireMissingForCommand: - err = i18n("\"require\" missing for command \"%1\"").arg(mStringOne); + err = i18n("\"require\" missing for command \"%1\"").tqarg(mStringOne); break; case RequireMissingForTest: - err = i18n("\"require\" missing for test \"%1\"").arg(mStringOne); + err = i18n("\"require\" missing for test \"%1\"").tqarg(mStringOne); break; case RequireMissingForComparator: - err = i18n("\"require\" missing for comparator \"%1\"").arg(mStringOne); + err = i18n("\"require\" missing for comparator \"%1\"").tqarg(mStringOne); break; case UnsupportedCommand: - err = i18n("Command \"%1\" not supported").arg(mStringOne); + err = i18n("Command \"%1\" not supported").tqarg(mStringOne); break; case UnsupportedTest: - err = i18n("Test \"%1\" not supported").arg(mStringOne); + err = i18n("Test \"%1\" not supported").tqarg(mStringOne); break; case UnsupportedComparator: - err = i18n("Comparator \"%1\" not supported").arg(mStringOne); + err = i18n("Comparator \"%1\" not supported").tqarg(mStringOne); break; case TestNestingTooDeep: - err = i18n("Site Policy Limit Violation: Test nesting too deep (max. %1)").arg( mStringOne.toUInt() ); + err = i18n("Site Policy Limit Violation: Test nesting too deep (max. %1)").tqarg( mStringOne.toUInt() ); break; case BlockNestingTooDeep: - err = i18n("Site Policy Limit Violation: Block nesting too deep (max. %1)").arg( mStringOne.toUInt() ); + err = i18n("Site Policy Limit Violation: Block nesting too deep (max. %1)").tqarg( mStringOne.toUInt() ); break; case InvalidArgument: - err = i18n("Invalid Argument \"%1\" to \"%2\"").arg(mStringOne).arg(mStringTwo); + err = i18n("Invalid Argument \"%1\" to \"%2\"").tqarg(mStringOne).tqarg(mStringTwo); break; case ConflictingArguments: - err = i18n("Conflicting Arguments: \"%1\" and \"%2\"").arg(mStringOne).arg(mStringTwo); + err = i18n("Conflicting Arguments: \"%1\" and \"%2\"").tqarg(mStringOne).tqarg(mStringTwo); break; case ArgumentsRepeated: - err = i18n("Argument \"%1\" Repeated").arg(mStringOne); + err = i18n("Argument \"%1\" Repeated").tqarg(mStringOne); break; case CommandOrderingConstraintViolation: - err = i18n("Command \"%1\" violates command ordering constraints").arg(mStringOne); + err = i18n("Command \"%1\" violates command ordering constraints").tqarg(mStringOne); break; // runtime errors: case IncompatibleActionsRequested: - err = i18n("Incompatible Actions \"%1\" and \"%2\" requested").arg(mStringOne).arg(mStringTwo); + err = i18n("Incompatible Actions \"%1\" and \"%2\" requested").tqarg(mStringOne).tqarg(mStringTwo); break; case MailLoopDetected: err = i18n("Mail Loop detected"); break; case TooManyActions: - err = i18n("Site Policy Limit Violation: Too many Actions requested (max. %1)").arg( mStringOne.toUInt() ); + err = i18n("Site Policy Limit Violation: Too many Actions requested (max. %1)").tqarg( mStringOne.toUInt() ); break; default: err = i18n("Unknown error"); diff --git a/libksieve/tests/parsertest.cpp b/libksieve/tests/parsertest.cpp index ea718e4d2..f4efcee58 100644 --- a/libksieve/tests/parsertest.cpp +++ b/libksieve/tests/parsertest.cpp @@ -397,7 +397,7 @@ public: write( multiLine ? "string type=\"multiline\"" : "string type=\"quoted\"", string ); } void numberArgument( unsigned long number, char quantifier ) { - const TQString txt = "number" + ( quantifier ? TQString(" quantifier=\"%1\"").arg( quantifier ) : TQString() ) ; + const TQString txt = "number" + ( quantifier ? TQString(" quantifier=\"%1\"").tqarg( quantifier ) : TQString() ) ; write( txt.latin1(), TQString::number( number ) ); } void commandStart( const TQString & identifier ) { diff --git a/mimelib/CMakeLists.txt b/mimelib/CMakeLists.txt index 262fa1805..4c1b4878d 100644 --- a/mimelib/CMakeLists.txt +++ b/mimelib/CMakeLists.txt @@ -39,7 +39,7 @@ tde_add_library( mimelib SHARED dwstring.cpp text.cpp token.cpp uuencode.cpp binhex.cpp VERSION 1.0.1 - LINK ${TDE_LIB_DIR}/libkdefakes_pic.a + LINK ${TQT_LIBRARIES} ${TDE_LIB_DIR}/libkdefakes_pic.a DESTINATION ${LIB_INSTALL_DIR} ) diff --git a/plugins/kmail/bodypartformatter/text_calendar.cpp b/plugins/kmail/bodypartformatter/text_calendar.cpp index 87d29875d..d07e6cb11 100644 --- a/plugins/kmail/bodypartformatter/text_calendar.cpp +++ b/plugins/kmail/bodypartformatter/text_calendar.cpp @@ -344,16 +344,16 @@ class UrlHandler : public KMail::Interface::BodyPartURLHandler TQString subject; switch ( type ) { case Answer: - subject = i18n( "Answer: %1" ).arg( summary ); + subject = i18n( "Answer: %1" ).tqarg( summary ); break; case Delegation: - subject = i18n( "Delegated: %1" ).arg( summary ); + subject = i18n( "Delegated: %1" ).tqarg( summary ); break; case Forward: - subject = i18n( "Forwarded: %1" ).arg( summary ); + subject = i18n( "Forwarded: %1" ).tqarg( summary ); break; case DeclineCounter: - subject = i18n( "Declined Counter Proposal: %1" ).arg( summary ); + subject = i18n( "Declined Counter Proposal: %1" ).tqarg( summary ); break; } @@ -434,13 +434,13 @@ class UrlHandler : public KMail::Interface::BodyPartURLHandler Q_ASSERT( event ); if ( !event->doesFloat() ) { if ( event->dtEnd() < now ) { - warnStr = i18n( "\"%1\" occurred already." ).arg( event->summary() ); + warnStr = i18n( "\"%1\" occurred already." ).tqarg( event->summary() ); } else if ( event->dtStart() <= now && now <= event->dtEnd() ) { - warnStr = i18n( "\"%1\" is currently in-progress." ).arg( event->summary() ); + warnStr = i18n( "\"%1\" is currently in-progress." ).tqarg( event->summary() ); } } else { if ( event->dtEnd().date() < today ) { - warnStr = i18n( "\"%1\" occurred already." ).arg( event->summary() ); + warnStr = i18n( "\"%1\" occurred already." ).tqarg( event->summary() ); } else if ( event->dtStart().date() <= today && today <= event->dtEnd().date() ) { warnStr = i18n( "\"%1\", happening all day today, is currently in-progress." ). arg( event->summary() ); @@ -451,19 +451,19 @@ class UrlHandler : public KMail::Interface::BodyPartURLHandler if ( !todo->doesFloat() ) { if ( todo->hasDueDate() ) { if ( todo->dtDue() < now ) { - warnStr = i18n( "\"%1\" is past due." ).arg( todo->summary() ); + warnStr = i18n( "\"%1\" is past due." ).tqarg( todo->summary() ); } else if ( todo->hasStartDate() && todo->dtStart() <= now && now <= todo->dtDue() ) { - warnStr = i18n( "\"%1\" is currently in-progress." ).arg( todo->summary() ); + warnStr = i18n( "\"%1\" is currently in-progress." ).tqarg( todo->summary() ); } } else if ( todo->hasStartDate() ) { if ( todo->dtStart() < now ) { - warnStr = i18n( "\"%1\" has already started." ).arg( todo->summary() ); + warnStr = i18n( "\"%1\" has already started." ).tqarg( todo->summary() ); } } } else { if ( todo->hasDueDate() ) { if ( todo->dtDue().date() < today) { - warnStr = i18n( "\"%1\" is past due." ).arg( todo->summary() ); + warnStr = i18n( "\"%1\" is past due." ).tqarg( todo->summary() ); } else if ( todo->hasStartDate() && todo->dtStart().date() <= today && today <= todo->dtDue().date() ) { warnStr = i18n( "\"%1\", happening all-day today, is currently in-progress." ). @@ -526,12 +526,12 @@ class UrlHandler : public KMail::Interface::BodyPartURLHandler } else if ( path.startsWith( "ATTACH:" ) ) { return false; } else { - queryStr = i18n( "%1?" ).arg( path ); + queryStr = i18n( "%1?" ).tqarg( path ); } if ( KMessageBox::warningYesNo( 0, - i18n( "%1\n%2" ).arg( warnStr ).arg( queryStr ) ) == KMessageBox::No ) { + i18n( "%1\n%2" ).tqarg( warnStr ).tqarg( queryStr ) ) == KMessageBox::No ) { return true; } } @@ -820,7 +820,7 @@ class UrlHandler : public KMail::Interface::BodyPartURLHandler case KMessageBox::No: // means "send email" summary = incidence->summary(); if ( !summary.isEmpty() ) { - summary = i18n( "Re: %1" ).arg( summary ); + summary = i18n( "Re: %1" ).tqarg( summary ); } KApplication::kApplication()->invokeMailer( incidence->organizer().email(), summary ); diff --git a/plugins/kmail/bodypartformatter/text_vcard.cpp b/plugins/kmail/bodypartformatter/text_vcard.cpp index 014493a96..a084aea13 100644 --- a/plugins/kmail/bodypartformatter/text_vcard.cpp +++ b/plugins/kmail/bodypartformatter/text_vcard.cpp @@ -104,7 +104,7 @@ namespace { writer->queue( contact ); TQString addToLinkText = i18n( "[Add this contact to the addressbook]" ); - TQString op = TQString::tqfromLatin1( "addToAddressBook:%1" ).arg( count ); + TQString op = TQString::tqfromLatin1( "addToAddressBook:%1" ).tqarg( count ); writer->queue( "<div align=\"center\"><a href=\"" + bodyPart->makeLink( op ) + @@ -133,7 +133,7 @@ namespace { #else Addressee::List al = vcc.parseVCards( vCard ); #endif - int index = path.right( path.length() - path.findRev( ":" ) - 1 ).toInt(); + int index = path.right( path.length() - path.tqfindRev( ":" ) - 1 ).toInt(); if ( index == -1 ) return true; KABC::Addressee a = al[index]; if ( a.isEmpty() ) return true; @@ -151,7 +151,7 @@ namespace { #else Addressee::List al = vcc.parseVCards( vCard ); #endif - int index = path.right( path.length() - path.findRev( ":" ) - 1 ).toInt(); + int index = path.right( path.length() - path.tqfindRev( ":" ) - 1 ).toInt(); if ( index >= 0 ) { return al[index]; } @@ -195,7 +195,7 @@ namespace { if ( a.realName().isEmpty() ) { return i18n( "Add this contact to the address book." ); } else { - return i18n( "Add \"%1\" to the address book." ).arg( a.realName() ); + return i18n( "Add \"%1\" to the address book." ).tqarg( a.realName() ); } } diff --git a/wizards/groupwisewizard.cpp b/wizards/groupwisewizard.cpp index bb5275302..52b6c1af2 100644 --- a/wizards/groupwisewizard.cpp +++ b/wizards/groupwisewizard.cpp @@ -314,7 +314,7 @@ GroupwiseWizard::GroupwiseWizard() : KConfigWizard( new GroupwisePropagator ) topLayout = new TQGridLayout( mEmailPage ); topLayout->setSpacing( spacingHint() ); - mEmailBox = new TQGroupBox( 1, Horizontal, + mEmailBox = new TQGroupBox( 1, Qt::Horizontal, i18n("Create Mail Account"), mEmailPage ); mEmailBox->setCheckable( true ); topLayout->addWidget( mEmailBox, 0, 0 ); @@ -406,8 +406,8 @@ void GroupwiseWizard::slotAboutToShowPage( TQWidget *page ) if ( page == mEmailPage ) { if ( mEmailEdit->text().isEmpty() ) { TQString host = GroupwiseConfig::host(); - int pos = host.findRev( "." ); - if ( pos > 0 ) pos = host.findRev( ".", pos - 1 ); + int pos = host.tqfindRev( "." ); + if ( pos > 0 ) pos = host.tqfindRev( ".", pos - 1 ); if ( pos > 0 ) host = host.mid( pos + 1 ); TQString email = GroupwiseConfig::user() + "@" + host; mEmailEdit->setText( email ); diff --git a/wizards/kmailchanges.cpp b/wizards/kmailchanges.cpp index 66fdd2169..86fd05b3f 100644 --- a/wizards/kmailchanges.cpp +++ b/wizards/kmailchanges.cpp @@ -176,7 +176,7 @@ void CreateDisconnectedImapAccount::apply() transportId = mExistingTransportId; } - c.setGroup( TQString("Account %1").arg( accountId ) ); + c.setGroup( TQString("Account %1").tqarg( accountId ) ); int uid; if ( mExistingAccountId < 0 ) { uid = kapp->random(); @@ -240,7 +240,7 @@ void CreateDisconnectedImapAccount::apply() } - c.setGroup( TQString("Folder-%1").arg( uid ) ); + c.setGroup( TQString("Folder-%1").tqarg( uid ) ); c.writeEntry( "isOpen", true ); c.setGroup( "AccountWizard" ); @@ -249,7 +249,7 @@ void CreateDisconnectedImapAccount::apply() c.setGroup( "Composer" ); c.writeEntry( "default-transport", mAccountName ); - c.setGroup( TQString("Transport %1").arg( transportId ) ); + c.setGroup( TQString("Transport %1").tqarg( transportId ) ); c.writeEntry( "name", mAccountName ); c.writeEntry( "host", mServer ); c.writeEntry( "type", "smtp" ); @@ -318,7 +318,7 @@ void CreateOnlineImapAccount::apply() uint accCnt = c.readNumEntry( "accounts", 0 ); c.writeEntry( "accounts", accCnt+1 ); - c.setGroup( TQString("Account %1").arg(accCnt+1) ); + c.setGroup( TQString("Account %1").tqarg(accCnt+1) ); int uid = kapp->random(); c.writeEntry( "Folder", uid ); c.writeEntry( "Id", uid ); @@ -354,12 +354,12 @@ void CreateOnlineImapAccount::apply() // locally unsubscribe the default folders c.writeEntry( "locally-subscribed-folders", true ); TQString groupwareFolders = TQString("/INBOX/%1/,/INBOX/%2/,/INBOX/%3/,/INBOX/%4/,/INBOX/%5/") - .arg( i18n(s_folderContentsType[0]) ).arg( i18n(s_folderContentsType[1]) ) - .arg( i18n(s_folderContentsType[2]) ).arg( i18n(s_folderContentsType[3]) ) - .arg( i18n(s_folderContentsType[4]) ); + .tqarg( i18n(s_folderContentsType[0]) ).tqarg( i18n(s_folderContentsType[1]) ) + .tqarg( i18n(s_folderContentsType[2]) ).tqarg( i18n(s_folderContentsType[3]) ) + .tqarg( i18n(s_folderContentsType[4]) ); c.writeEntry( "locallyUnsubscribedFolders", groupwareFolders ); - c.setGroup( TQString("Folder-%1").arg( uid ) ); + c.setGroup( TQString("Folder-%1").tqarg( uid ) ); c.writeEntry( "isOpen", true ); diff --git a/wizards/kolabkmailchanges.cpp b/wizards/kolabkmailchanges.cpp index 68ff847a8..a38c7fd7b 100644 --- a/wizards/kolabkmailchanges.cpp +++ b/wizards/kolabkmailchanges.cpp @@ -34,7 +34,7 @@ class KolabCustomWriter : public CreateDisconnectedImapAccount::CustomWriter { c.setGroup( "IMAP Resource" ); c.writeEntry( "TheIMAPResourceAccount", id ); - c.writeEntry( "TheIMAPResourceFolderParent", TQString(".%1.directory/INBOX").arg( id ) ); + c.writeEntry( "TheIMAPResourceFolderParent", TQString(".%1.directory/INBOX").tqarg( id ) ); } void writeIds( int, int ) {} }; diff --git a/wizards/kolabwizard.cpp b/wizards/kolabwizard.cpp index 9deaa373c..6aad529e5 100644 --- a/wizards/kolabwizard.cpp +++ b/wizards/kolabwizard.cpp @@ -81,13 +81,13 @@ class SetupLDAPSearchAccount : public KConfigPropagator::Change bool hasMyServer = false; uint selHosts = c.readNumEntry("NumSelectedHosts", 0); for ( uint i = 0 ; i < selHosts && !hasMyServer; ++i ) - if ( c.readEntry( TQString("SelectedHost%1").arg(i) ) == host ) + if ( c.readEntry( TQString("SelectedHost%1").tqarg(i) ) == host ) hasMyServer = true; if ( !hasMyServer ) { c.writeEntry( "NumSelectedHosts", selHosts + 1 ); - c.writeEntry( TQString("SelectedHost%1").arg(selHosts), host); - c.writeEntry( TQString("SelectedBase%1").arg(selHosts), basedn); - c.writeEntry( TQString("SelectedPort%1").arg(selHosts), "389"); + c.writeEntry( TQString("SelectedHost%1").tqarg(selHosts), host); + c.writeEntry( TQString("SelectedBase%1").tqarg(selHosts), basedn); + c.writeEntry( TQString("SelectedPort%1").tqarg(selHosts), "389"); } } diff --git a/wizards/scalixkmailchanges.cpp b/wizards/scalixkmailchanges.cpp index 9b4512ddc..38c3ecfb3 100644 --- a/wizards/scalixkmailchanges.cpp +++ b/wizards/scalixkmailchanges.cpp @@ -34,7 +34,7 @@ class ScalixCustomWriter : public CreateDisconnectedImapAccount::CustomWriter { c.setGroup( "IMAP Resource" ); c.writeEntry( "TheIMAPResourceAccount", id ); - c.writeEntry( "TheIMAPResourceFolderParent", TQString(".%1.directory/INBOX").arg( id ) ); + c.writeEntry( "TheIMAPResourceFolderParent", TQString(".%1.directory/INBOX").tqarg( id ) ); c.writeEntry( "HideGroupwareFolders", false ); } void writeIds( int, int ) {} diff --git a/wizards/scalixwizard.cpp b/wizards/scalixwizard.cpp index 0291a22e0..100370508 100644 --- a/wizards/scalixwizard.cpp +++ b/wizards/scalixwizard.cpp @@ -74,13 +74,13 @@ class SetupLDAPSearchAccount : public KConfigPropagator::Change bool hasMyServer = false; uint selHosts = c.readNumEntry("NumSelectedHosts", 0); for ( uint i = 0 ; i < selHosts && !hasMyServer; ++i ) - if ( c.readEntry( TQString("SelectedHost%1").arg(i) ) == host ) + if ( c.readEntry( TQString("SelectedHost%1").tqarg(i) ) == host ) hasMyServer = true; if ( !hasMyServer ) { c.writeEntry( "NumSelectedHosts", selHosts + 1 ); - c.writeEntry( TQString("SelectedHost%1").arg(selHosts), host); - c.writeEntry( TQString("SelectedBase%1").arg(selHosts), basedn); - c.writeEntry( TQString("SelectedPort%1").arg(selHosts), "389"); + c.writeEntry( TQString("SelectedHost%1").tqarg(selHosts), host); + c.writeEntry( TQString("SelectedBase%1").tqarg(selHosts), basedn); + c.writeEntry( TQString("SelectedPort%1").tqarg(selHosts), "389"); } } |