From 252fce5a2a5384702fbcc1c9987284d7bd2e6943 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 15 Dec 2011 15:31:01 -0600 Subject: Rename a number of old tq methods that are no longer tq specific --- kmymoney2/views/kaccountsview.cpp | 14 +- kmymoney2/views/kaccountsview.h | 4 +- kmymoney2/views/kaccountsviewdecl.ui | 12 +- kmymoney2/views/kbudgetview.cpp | 16 +-- kmymoney2/views/kbudgetview.h | 4 +- kmymoney2/views/kbudgetviewdecl.ui | 12 +- kmymoney2/views/kcategoriesview.cpp | 10 +- kmymoney2/views/kcategoriesview.h | 6 +- kmymoney2/views/kcategoriesviewdecl.ui | 12 +- kmymoney2/views/kforecastview.cpp | 50 +++---- kmymoney2/views/kforecastviewdecl.ui | 14 +- kmymoney2/views/kgloballedgerview.cpp | 52 ++++---- kmymoney2/views/khomeview.cpp | 216 +++++++++++++++---------------- kmymoney2/views/kinstitutionsview.h | 4 +- kmymoney2/views/kinstitutionsviewdecl.ui | 8 +- kmymoney2/views/kinvestmentlistitem.cpp | 8 +- kmymoney2/views/kinvestmentviewdecl.ui | 4 +- kmymoney2/views/kmymoneyview.cpp | 62 ++++----- kmymoney2/views/kmymoneyview.h | 2 +- kmymoney2/views/kpayeesview.cpp | 42 +++--- kmymoney2/views/kpayeesview.h | 2 +- kmymoney2/views/kpayeesviewdecl.ui | 30 ++--- kmymoney2/views/kreportsview.cpp | 34 ++--- kmymoney2/views/kscheduledlistitem.cpp | 2 +- kmymoney2/views/kscheduledlistitem.h | 2 +- kmymoney2/views/kscheduledview.cpp | 8 +- kmymoney2/views/kscheduledviewdecl.ui | 4 +- 27 files changed, 317 insertions(+), 317 deletions(-) (limited to 'kmymoney2/views') diff --git a/kmymoney2/views/kaccountsview.cpp b/kmymoney2/views/kaccountsview.cpp index 8de2b20..9c2959b 100644 --- a/kmymoney2/views/kaccountsview.cpp +++ b/kmymoney2/views/kaccountsview.cpp @@ -20,7 +20,7 @@ #include #include #include -#include +#include // ---------------------------------------------------------------------------- // KDE Includes @@ -74,11 +74,11 @@ KAccountsView::KAccountsView(TQWidget *parent, const char *name) : m_liabilityItem(0) { // create the searchline widget - // and insert it into the existing tqlayout + // and insert it into the existing layout m_searchWidget = new KListViewSearchLineWidget(m_accountTree, m_accountTree->parentWidget()); - TQVBoxLayout* tqlayout = dynamic_cast(m_accountTree->parentWidget()->tqlayout()); - if(tqlayout) { - tqlayout->insertWidget(0, m_searchWidget); + TQVBoxLayout* layout = dynamic_cast(m_accountTree->parentWidget()->layout()); + if(layout) { + layout->insertWidget(0, m_searchWidget); } // setup icons for collapse and expand button @@ -241,7 +241,7 @@ void KAccountsView::loadIconView(void) file->accountList(alist); TQValueList::const_iterator it_a; for(it_a = alist.begin(); it_a != alist.end(); ++it_a) { - accountMap[TQString("%1-%2").tqarg((*it_a).name()).tqarg((*it_a).id())] = *it_a; + accountMap[TQString("%1-%2").arg((*it_a).name()).arg((*it_a).id())] = *it_a; } bool showClosedAccounts = kmymoney2->toggleAction("view_show_all_accounts")->isChecked() @@ -583,7 +583,7 @@ void KAccountsView::slotOpenObject(TQIconViewItem* item) TQString KAccountsView::point(const TQPoint& val) const { - return TQString("%1;%2").tqarg(val.x()).tqarg(val.y()); + return TQString("%1;%2").arg(val.x()).arg(val.y()); } TQPoint KAccountsView::point(const TQString& val) const diff --git a/kmymoney2/views/kaccountsview.h b/kmymoney2/views/kaccountsview.h index a8498fb..9ed197b 100644 --- a/kmymoney2/views/kaccountsview.h +++ b/kmymoney2/views/kaccountsview.h @@ -104,8 +104,8 @@ public slots: void show(void); /** - * Override the base class behaviour to restore the tqlayout. Do not - * do this in show() because show() itself may change the tqlayout + * Override the base class behaviour to restore the layout. Do not + * do this in show() because show() itself may change the layout * in undesired ways. */ void polish(void); diff --git a/kmymoney2/views/kaccountsviewdecl.ui b/kmymoney2/views/kaccountsviewdecl.ui index 9b975f2..a8182a5 100644 --- a/kmymoney2/views/kaccountsviewdecl.ui +++ b/kmymoney2/views/kaccountsviewdecl.ui @@ -47,7 +47,7 @@ - tqlayout5 + layout5 @@ -85,7 +85,7 @@ Expanding - + 515 20 @@ -137,7 +137,7 @@ - tqlayout4 + layout4 @@ -153,7 +153,7 @@ Expanding - + 367 20 @@ -164,7 +164,7 @@ m_totalProfitsLabel - + 150 0 @@ -176,7 +176,7 @@ RichText - + WordBreak|AlignVCenter|AlignRight diff --git a/kmymoney2/views/kbudgetview.cpp b/kmymoney2/views/kbudgetview.cpp index 9002ceb..6cc6aa4 100644 --- a/kmymoney2/views/kbudgetview.cpp +++ b/kmymoney2/views/kbudgetview.cpp @@ -66,7 +66,7 @@ KBudgetListItem::KBudgetListItem(KListView *parent, const MyMoneyBudget& budget) m_budget(budget) { setText(0, budget.name()); - setText(1, TQString("%1").tqarg(budget.budgetStart().year())); + setText(1, TQString("%1").arg(budget.budgetStart().year())); // allow in column rename setRenameEnabled(0, true); @@ -230,7 +230,7 @@ void KBudgetView::loadBudgets(void) m_budgetValue->clear(); // add the correct years to the drop down list - TQDate date = TQDate::tqcurrentDate(Qt::LocalTime); + TQDate date = TQDate::currentDate(Qt::LocalTime); int iStartYear = date.year() - m_iBudgetYearsBack; m_yearList.clear(); @@ -485,8 +485,8 @@ void KBudgetView::askSave(void) // check if the content of a currently selected budget was modified // and ask to store the data if (m_updateButton->isEnabled()) { - if (KMessageBox::questionYesNo(this, TQString("%1").tqarg( - i18n("Do you want to save the changes for %1").tqarg(m_budget.name())), + if (KMessageBox::questionYesNo(this, TQString("%1").arg( + i18n("Do you want to save the changes for %1").arg(m_budget.name())), i18n("Save changes")) == KMessageBox::Yes) { m_inSelection = true; slotUpdateBudget(); @@ -609,7 +609,7 @@ void KBudgetView::slotRenameBudget(TQListViewItem* p , int /*col*/, const TQStri if (KMessageBox::questionYesNo(this, i18n("A budget with the name '%1' already exists. It is not advisable to have " "multiple budgets with the same identification name. Are you sure you would like " - "to rename the budget?").tqarg(new_name)) != KMessageBox::Yes) + "to rename the budget?").arg(new_name)) != KMessageBox::Yes) { p->setText(0,pBudget->budget().name()); return; @@ -633,7 +633,7 @@ void KBudgetView::slotRenameBudget(TQListViewItem* p , int /*col*/, const TQStri } catch(MyMoneyException *e) { KMessageBox::detailedSorry(0, i18n("Unable to modify budget"), - (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").tqarg(e->line())); + (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").arg(e->line())); delete e; } } @@ -734,7 +734,7 @@ void KBudgetView::slotResetBudget(void) loadAccounts(); } catch(MyMoneyException *e) { KMessageBox::detailedSorry(0, i18n("Unable to reset budget"), - (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").tqarg(e->line())); + (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").arg(e->line())); delete e; } } @@ -748,7 +748,7 @@ void KBudgetView::slotUpdateBudget(void) slotRefreshHideUnusedButton(); } catch(MyMoneyException *e) { KMessageBox::detailedSorry(0, i18n("Unable to modify budget"), - (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").tqarg(e->line())); + (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").arg(e->line())); delete e; } } diff --git a/kmymoney2/views/kbudgetview.h b/kmymoney2/views/kbudgetview.h index ee89007..b7b4267 100644 --- a/kmymoney2/views/kbudgetview.h +++ b/kmymoney2/views/kbudgetview.h @@ -86,8 +86,8 @@ public: void show(); /** - * Override the base class behaviour to restore the tqlayout. Do not - * do this in show() because show() itself may change the tqlayout + * Override the base class behaviour to restore the layout. Do not + * do this in show() because show() itself may change the layout * in undesired ways. */ void polish(void); diff --git a/kmymoney2/views/kbudgetviewdecl.ui b/kmymoney2/views/kbudgetviewdecl.ui index 90172ff..f4c30e0 100644 --- a/kmymoney2/views/kbudgetviewdecl.ui +++ b/kmymoney2/views/kbudgetviewdecl.ui @@ -32,7 +32,7 @@ - tqlayout7 + layout7 @@ -59,7 +59,7 @@ - tqlayout8 + layout8 @@ -165,7 +165,7 @@ - tqlayout6 + layout6 @@ -213,7 +213,7 @@ - tqlayout7 + layout7 @@ -283,7 +283,7 @@ - tqlayout9 + layout9 @@ -304,7 +304,7 @@ Expanding - + 21 20 diff --git a/kmymoney2/views/kcategoriesview.cpp b/kmymoney2/views/kcategoriesview.cpp index 6bfbbea..4c1e725 100644 --- a/kmymoney2/views/kcategoriesview.cpp +++ b/kmymoney2/views/kcategoriesview.cpp @@ -24,7 +24,7 @@ // QT Includes #include -#include +#include // ---------------------------------------------------------------------------- // KDE Includes @@ -53,11 +53,11 @@ KCategoriesView::KCategoriesView(TQWidget *parent, const char *name ) : m_needReload(false) { // create the searchline widget - // and insert it into the existing tqlayout + // and insert it into the existing layout m_searchWidget = new KListViewSearchLineWidget(m_accountTree, m_accountTree->parentWidget()); - TQVBoxLayout* tqlayout = dynamic_cast(m_accountTree->parentWidget()->tqlayout()); - if(tqlayout) { - tqlayout->insertWidget(0, m_searchWidget); + TQVBoxLayout* layout = dynamic_cast(m_accountTree->parentWidget()->layout()); + if(layout) { + layout->insertWidget(0, m_searchWidget); } // setup icons for collapse and expand button diff --git a/kmymoney2/views/kcategoriesview.h b/kmymoney2/views/kcategoriesview.h index 77fb5d7..9b39091 100644 --- a/kmymoney2/views/kcategoriesview.h +++ b/kmymoney2/views/kcategoriesview.h @@ -45,7 +45,7 @@ class KListViewSearchLineWidget; * @author Michael Edwardes, Thomas Baumgart * * While named "categories view", this view actually displays all accounts - * that are tqchildren of the global "Income" and "Expense" accounts. Even though + * that are children of the global "Income" and "Expense" accounts. Even though * categories are internally just accounts as well, the distinction between * categories and accounts in the user interface is done for better * usability and clarity. @@ -79,8 +79,8 @@ public slots: void show(void); /** - * Override the base class behaviour to restore the tqlayout. Do not - * do this in show() because show() itself may change the tqlayout + * Override the base class behaviour to restore the layout. Do not + * do this in show() because show() itself may change the layout * in undesired ways. */ void polish(void); diff --git a/kmymoney2/views/kcategoriesviewdecl.ui b/kmymoney2/views/kcategoriesviewdecl.ui index 019080c..c62c6bb 100644 --- a/kmymoney2/views/kcategoriesviewdecl.ui +++ b/kmymoney2/views/kcategoriesviewdecl.ui @@ -29,7 +29,7 @@ - tqlayout5_2 + layout5_2 @@ -67,7 +67,7 @@ Expanding - + 515 20 @@ -86,7 +86,7 @@ - tqlayout5 + layout5 @@ -102,7 +102,7 @@ Expanding - + 310 16 @@ -113,7 +113,7 @@ m_totalProfitsLabel - + 150 0 @@ -125,7 +125,7 @@ RichText - + WordBreak|AlignVCenter|AlignRight diff --git a/kmymoney2/views/kforecastview.cpp b/kmymoney2/views/kforecastview.cpp index d636ec4..9ea9f80 100644 --- a/kmymoney2/views/kforecastview.cpp +++ b/kmymoney2/views/kforecastview.cpp @@ -21,8 +21,8 @@ #include #include #include -#include -#include +#include +#include // ---------------------------------------------------------------------------- // KDE Includes @@ -68,7 +68,7 @@ KForecastView::KForecastView(TQWidget *parent, const char *name) : m_advancedList->setAllColumnsShowFocus(true); m_forecastChart = new KReportChartView(m_tabChart, "forecastChart" ); - m_forecastChart->tqsetSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ); + m_forecastChart->setSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ); loadForecastSettings(); @@ -292,13 +292,13 @@ void KForecastView::loadSummaryView(void) case -1: break; case 0: - msg = TQString("").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); - msg += i18n("The balance of %2 is below the minimum balance %3 today.").tqarg(acc.name()).tqarg(minBalance.formatMoney(acc, currency)); + msg = TQString("").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); + msg += i18n("The balance of %2 is below the minimum balance %3 today.").arg(acc.name()).arg(minBalance.formatMoney(acc, currency)); msg += TQString(""); break; default: - msg = TQString("").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); - msg += i18n("The balance of %1 will drop below the minimum balance %2 in %3 days.").tqarg(acc.name()).tqarg(minBalance.formatMoney(acc, currency)).tqarg(dropMinimum-1); + msg = TQString("").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); + msg += i18n("The balance of %1 will drop below the minimum balance %2 in %3 days.").arg(acc.name()).arg(minBalance.formatMoney(acc, currency)).arg(dropMinimum-1); msg += TQString(""); } @@ -314,25 +314,25 @@ void KForecastView::loadSummaryView(void) break; case 0: if(acc.accountGroup() == MyMoneyAccount::Asset) { - msg = TQString("").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); - msg += i18n("The balance of %1 is below %2 today.").tqarg(acc.name()).tqarg(MyMoneyMoney().formatMoney(acc, currency)); + msg = TQString("").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); + msg += i18n("The balance of %1 is below %2 today.").arg(acc.name()).arg(MyMoneyMoney().formatMoney(acc, currency)); msg += TQString(""); break; } if(acc.accountGroup() == MyMoneyAccount::Liability) { - msg = i18n("The balance of %1 is above %2 today.").tqarg(acc.name()).tqarg(MyMoneyMoney().formatMoney(acc, currency)); + msg = i18n("The balance of %1 is above %2 today.").arg(acc.name()).arg(MyMoneyMoney().formatMoney(acc, currency)); break; } break; default: if(acc.accountGroup() == MyMoneyAccount::Asset) { - msg = TQString("").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); - msg += i18n("The balance of %1 will drop below %2 in %3 days.").tqarg(acc.name()).tqarg(MyMoneyMoney().formatMoney(acc, currency)).tqarg(dropZero); + msg = TQString("").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); + msg += i18n("The balance of %1 will drop below %2 in %3 days.").arg(acc.name()).arg(MyMoneyMoney().formatMoney(acc, currency)).arg(dropZero); msg += TQString(""); break; } if(acc.accountGroup() == MyMoneyAccount::Liability) { - msg = i18n("The balance of %1 will raise above %2 in %3 days.").tqarg(acc.name()).tqarg(MyMoneyMoney().formatMoney(acc, currency)).tqarg(dropZero); + msg = i18n("The balance of %1 will raise above %2 in %3 days.").arg(acc.name()).arg(MyMoneyMoney().formatMoney(acc, currency)).arg(dropZero); break; } } @@ -344,8 +344,8 @@ void KForecastView::loadSummaryView(void) msg = TQString(); MyMoneyMoney accCycleVariation = forecast.accountCycleVariation(acc); if (accCycleVariation < MyMoneyMoney(0, 1)) { - msg = TQString("").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); - msg += i18n("The account %1 is decreasing %2 per cycle.").tqarg(acc.name()).tqarg(accCycleVariation.formatMoney(acc, currency)); + msg = TQString("").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name()); + msg += i18n("The account %1 is decreasing %2 per cycle.").arg(acc.name()).arg(accCycleVariation.formatMoney(acc, currency)); msg += TQString(""); } @@ -393,22 +393,22 @@ void KForecastView::loadAdvancedView(void) int accountColumn = m_advancedList->addColumn(i18n("Account"), -1); //if beginning of forecast is today, set the begin day to next cycle to avoid repeating the first cycle - if(TQDate::tqcurrentDate() < forecast.beginForecastDate()) { - daysToBeginDay = TQDate::tqcurrentDate().daysTo(forecast.beginForecastDate()); + if(TQDate::currentDate() < forecast.beginForecastDate()) { + daysToBeginDay = TQDate::currentDate().daysTo(forecast.beginForecastDate()); } else { daysToBeginDay = forecast.accountsCycle(); } //add columns for(int i = 1; ((i * forecast.accountsCycle()) + daysToBeginDay) <= forecast.forecastDays(); ++i) { - int col = m_advancedList->addColumn(i18n("Min Bal %1").tqarg(i), -1); + int col = m_advancedList->addColumn(i18n("Min Bal %1").arg(i), -1); m_advancedList->setColumnAlignment(col, TQt::AlignRight); - m_advancedList->addColumn(i18n("Min Date %1").tqarg(i), -1); + m_advancedList->addColumn(i18n("Min Date %1").arg(i), -1); } for(int i = 1; ((i * forecast.accountsCycle()) + daysToBeginDay) <= forecast.forecastDays(); ++i) { - int col = m_advancedList->addColumn(i18n("Max Bal %1").tqarg(i), -1); + int col = m_advancedList->addColumn(i18n("Max Bal %1").arg(i), -1); m_advancedList->setColumnAlignment(col, TQt::AlignRight); - m_advancedList->addColumn(i18n("Max Date %1").tqarg(i), -1); + m_advancedList->addColumn(i18n("Max Date %1").arg(i), -1); } int col = m_advancedList->addColumn(i18n("Average"), -1); m_advancedList->setColumnAlignment(col, TQt::AlignRight); @@ -486,10 +486,10 @@ void KForecastView::loadBudgetView(void) m_budgetList->setBaseCurrency(file->baseCurrency()); //get the settings from current page and calculate this year based on last year - TQDate historyEndDate = TQDate(TQDate::tqcurrentDate().year()-1, 12, 31); + TQDate historyEndDate = TQDate(TQDate::currentDate().year()-1, 12, 31); TQDate historyStartDate = historyEndDate.addDays(-m_accountsCycle->value() * m_forecastCycles->value()); - TQDate forecastStartDate = TQDate(TQDate::tqcurrentDate().year(), 1, 1); - TQDate forecastEndDate = TQDate::tqcurrentDate().addDays(m_forecastDays->value()); + TQDate forecastStartDate = TQDate(TQDate::currentDate().year(), 1, 1); + TQDate forecastEndDate = TQDate::currentDate().addDays(m_forecastDays->value()); forecast.setHistoryMethod(m_historyMethod->selectedId()); MyMoneyBudget budget; @@ -658,7 +658,7 @@ void KForecastView::loadChartView(void) reportCfg.setColumnsAreDays( true ); reportCfg.setConvertCurrency( true ); reportCfg.setIncludingForecast( true ); - reportCfg.setDateFilter(TQDate::tqcurrentDate(),TQDate::tqcurrentDate().addDays(m_forecastDays->value())); + reportCfg.setDateFilter(TQDate::currentDate(),TQDate::currentDate().addDays(m_forecastDays->value())); reports::PivotTable table(reportCfg); diff --git a/kmymoney2/views/kforecastviewdecl.ui b/kmymoney2/views/kforecastviewdecl.ui index 79aa702..0562f15 100644 --- a/kmymoney2/views/kforecastviewdecl.ui +++ b/kmymoney2/views/kforecastviewdecl.ui @@ -32,7 +32,7 @@ - tqlayout16 + layout16 @@ -189,7 +189,7 @@ Expanding - + 16 31 @@ -198,7 +198,7 @@ - tqlayout76 + layout76 @@ -206,7 +206,7 @@ - tqlayout17 + layout17 @@ -312,7 +312,7 @@ Expanding - + 21 6 @@ -321,7 +321,7 @@ - tqlayout75 + layout75 @@ -345,7 +345,7 @@ Expanding - + 31 21 diff --git a/kmymoney2/views/kgloballedgerview.cpp b/kmymoney2/views/kgloballedgerview.cpp index 87f8890..e9a758e 100644 --- a/kmymoney2/views/kgloballedgerview.cpp +++ b/kmymoney2/views/kgloballedgerview.cpp @@ -21,7 +21,7 @@ // QT Includes #include -#include +#include #include // ---------------------------------------------------------------------------- @@ -176,14 +176,14 @@ KGlobalLedgerView::KGlobalLedgerView(TQWidget *parent, const char *name ) //m_toolbar->setMaximumSize(50,20); m_toolbar->alignItemRight(1); #endif - m_toolbar->tqsetSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed); - tqlayout()->addWidget(m_toolbarFrame); + m_toolbar->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed); + layout()->addWidget(m_toolbarFrame); // create the register frame m_registerFrame = new TQFrame(this); TQVBoxLayout* registerFrameLayout = new TQVBoxLayout(m_registerFrame, 0, 0); - tqlayout()->addWidget(m_registerFrame); - tqlayout()->setStretchFactor(m_registerFrame, 2); + layout()->addWidget(m_registerFrame); + layout()->setStretchFactor(m_registerFrame, 2); m_register = new KMyMoneyRegister::Register(m_registerFrame); registerFrameLayout->addWidget(m_register); m_register->installEventFilter(this); @@ -210,12 +210,12 @@ KGlobalLedgerView::KGlobalLedgerView(TQWidget *parent, const char *name ) spacer = new TQSpacerItem( 20, 1, TQSizePolicy::Expanding, TQSizePolicy::Minimum ); summaryFrameLayout->addItem(spacer); summaryFrameLayout->addWidget(m_rightSummaryLabel); - tqlayout()->addWidget(m_summaryFrame); + layout()->addWidget(m_summaryFrame); // create the button frame m_buttonFrame = new TQFrame(this); TQVBoxLayout* buttonLayout = new TQVBoxLayout(m_buttonFrame, 0, 0); - tqlayout()->addWidget(m_buttonFrame); + layout()->addWidget(m_buttonFrame); m_buttonbar = new KToolBar(m_buttonFrame, 0, true); m_buttonbar->setIconText(KToolBar::IconTextRight); buttonLayout->addWidget(m_buttonbar); @@ -236,7 +236,7 @@ KGlobalLedgerView::KGlobalLedgerView(TQWidget *parent, const char *name ) frameLayout->addWidget(m_form); m_formFrame->setFrameShape( TQFrame::Panel ); m_formFrame->setFrameShadow( TQFrame::Raised ); - tqlayout()->addWidget(m_formFrame); + layout()->addWidget(m_formFrame); connect(MyMoneyFile::instance(), TQT_SIGNAL(dataChanged()), this, TQT_SLOT(slotLoadView())); connect(m_register, TQT_SIGNAL(focusChanged(KMyMoneyRegister::Transaction*)), m_form, TQT_SLOT(slotSetTransaction(KMyMoneyRegister::Transaction*))); @@ -448,7 +448,7 @@ void KGlobalLedgerView::loadView(void) // show scheduled transactions which have a scheduled postdate // within the next 'period' days. In reconciliation mode, the // period starts on the statement date. - TQDate endDate = TQDate::tqcurrentDate().addDays(period); + TQDate endDate = TQDate::currentDate().addDays(period); if(isReconciliationAccount()) endDate = reconciliationDate.addDays(period); TQValueList scheduleList = MyMoneyFile::instance()->scheduleList(m_account.id()); @@ -464,7 +464,7 @@ void KGlobalLedgerView::loadView(void) // certainly be posted in the past. So we take todays date // as the alternative if(s.isOverdue()) - t.setPostDate(TQDate::tqcurrentDate()); + t.setPostDate(TQDate::currentDate()); else t.setPostDate(s.adjustedNextDueDate()); const TQValueList& splits = t.splits(); @@ -476,7 +476,7 @@ void KGlobalLedgerView::loadView(void) } // keep track of this payment locally (not in the engine) if(s.isOverdue()) - s.setLastPayment(TQDate::tqcurrentDate()); + s.setLastPayment(TQDate::currentDate()); else s.setLastPayment(s.nextDueDate()); @@ -629,7 +629,7 @@ void KGlobalLedgerView::loadView(void) } } - if(t->transaction().postDate() > TQDate::tqcurrentDate()) { + if(t->transaction().postDate() > TQDate::currentDate()) { tracer.printf("Reducing actual balance by %s because %s/%s(%s) is in the future", (split.shares() * factor).formatMoney("", 2).data(), t->transaction().id().data(), split.id().data(), t->transaction().postDate().toString(Qt::ISODate).data()); actBalance[split.accountId()] -= split.shares() * factor; } @@ -652,11 +652,11 @@ void KGlobalLedgerView::loadView(void) arg(paymentAmount[m_account.id()].abs().formatMoney(m_account.fraction())) ); } if(pStatement) { - pStatement->setText(i18n("%1 payments (%2)").tqarg(payments[m_account.id()]). + pStatement->setText(i18n("%1 payments (%2)").arg(payments[m_account.id()]). arg(paymentAmount[m_account.id()].abs().formatMoney(m_account.fraction())) ); } if(dStatement) { - dStatement->setText(i18n("%1 deposits (%2)").tqarg(deposits[m_account.id()]). + dStatement->setText(i18n("%1 deposits (%2)").arg(deposits[m_account.id()]). arg(depositAmount[m_account.id()].abs().formatMoney(m_account.fraction())) ); } @@ -724,24 +724,24 @@ void KGlobalLedgerView::updateSummaryLine(const TQMap& a if(isReconciliationAccount()) { if(m_account.accountType() != MyMoneyAccount::Investment) { - m_leftSummaryLabel->setText(i18n("Statement: %1").tqarg(d->m_endingBalance.formatMoney("", d->m_precision))); - m_centerSummaryLabel->setText(i18n("Cleared: %1").tqarg(clearedBalance[m_account.id()].formatMoney("", d->m_precision))); - m_rightSummaryLabel->setText(i18n("Difference: %1").tqarg((clearedBalance[m_account.id()] - d->m_endingBalance).formatMoney("", d->m_precision))); + m_leftSummaryLabel->setText(i18n("Statement: %1").arg(d->m_endingBalance.formatMoney("", d->m_precision))); + m_centerSummaryLabel->setText(i18n("Cleared: %1").arg(clearedBalance[m_account.id()].formatMoney("", d->m_precision))); + m_rightSummaryLabel->setText(i18n("Difference: %1").arg((clearedBalance[m_account.id()] - d->m_endingBalance).formatMoney("", d->m_precision))); } } else { // update summary line in normal mode TQDate reconcileDate = m_account.lastReconciliationDate(); if(reconcileDate.isValid()) { - m_leftSummaryLabel->setText(i18n("Last reconciled: %1").tqarg(KGlobal::locale()->formatDate(reconcileDate, true))); + m_leftSummaryLabel->setText(i18n("Last reconciled: %1").arg(KGlobal::locale()->formatDate(reconcileDate, true))); } else { m_leftSummaryLabel->setText(i18n("Never reconciled")); } m_rightSummaryLabel->setPaletteForegroundColor(m_leftSummaryLabel->paletteForegroundColor()); if(m_account.accountType() != MyMoneyAccount::Investment) { - m_centerSummaryLabel->setText(i18n("Cleared: %1").tqarg(clearedBalance[m_account.id()].formatMoney("", d->m_precision))); - m_rightSummaryLabel->setText(i18n("Balance: %1").tqarg(actBalance[m_account.id()].formatMoney("", d->m_precision))); + m_centerSummaryLabel->setText(i18n("Cleared: %1").arg(clearedBalance[m_account.id()].formatMoney("", d->m_precision))); + m_rightSummaryLabel->setText(i18n("Balance: %1").arg(actBalance[m_account.id()].formatMoney("", d->m_precision))); bool showNegative = actBalance[m_account.id()].isNegative(); if(m_account.accountGroup() == MyMoneyAccount::Liability && !actBalance[m_account.id()].isZero()) showNegative = !showNegative; @@ -775,7 +775,7 @@ void KGlobalLedgerView::updateSummaryLine(const TQMap& a } balance += ((*it_b) * rate).convert(base.smallestAccountFraction()); } - m_rightSummaryLabel->setText(i18n("Investment value: %1%2").tqarg(approx ? "~" : "").tqarg(balance.formatMoney(base.tradingSymbol(), d->m_precision))); + m_rightSummaryLabel->setText(i18n("Investment value: %1%2").arg(approx ? "~" : "").arg(balance.formatMoney(base.tradingSymbol(), d->m_precision))); } } } @@ -1149,12 +1149,12 @@ TransactionEditor* KGlobalLedgerView::startEdit(const KMyMoneyRegister::Selected // Check if the editor has some preference on where to set the focus // If not, set the focus to the first widget in the tab order - TQWidget* tqfocusWidget = editor->firstWidget(); - if(!tqfocusWidget) - tqfocusWidget = m_tabOrderWidgets.first(); + TQWidget* focusWidget = editor->firstWidget(); + if(!focusWidget) + focusWidget = m_tabOrderWidgets.first(); // for some reason, this only works reliably if delayed a bit - TQTimer::singleShot(10, tqfocusWidget, TQT_SLOT(setFocus())); + TQTimer::singleShot(10, focusWidget, TQT_SLOT(setFocus())); // preset to 'I have no idea which type to create' for the next round. d->m_action = KMyMoneyRegister::ActionNone; @@ -1207,7 +1207,7 @@ bool KGlobalLedgerView::focusNextPrevChild(bool next) TQWidget *w = 0; TQWidget *currentWidget; - w = tqApp->tqfocusWidget(); + w = tqApp->focusWidget(); while(w && m_tabOrderWidgets.find(w) == -1) { // qDebug("'%s' not in list, use parent", w->className()); w = w->parentWidget(); diff --git a/kmymoney2/views/khomeview.cpp b/kmymoney2/views/khomeview.cpp index ba6af3a..e96744f 100644 --- a/kmymoney2/views/khomeview.cpp +++ b/kmymoney2/views/khomeview.cpp @@ -23,14 +23,14 @@ // ---------------------------------------------------------------------------- // QT Includes -#include +#include #include #include #include #include #include #include -#include +#include #include #include @@ -101,10 +101,10 @@ void KHomeView::Private::addNameIndex(TQMap &idx, cons } else if(idx[key].id() != account.id()) { key = account.name() + "[%1]"; int dup = 2; - while(!idx[key.tqarg(dup)].id().isEmpty() - && idx[key.tqarg(dup)].id() != account.id()) + while(!idx[key.arg(dup)].id().isEmpty() + && idx[key.arg(dup)].id() != account.id()) ++dup; - idx[key.tqarg(dup)] = account; + idx[key.arg(dup)] = account; } } @@ -215,7 +215,7 @@ void KHomeView::loadView(void) m_forecast.setForecastDone(false); TQString filename = KGlobal::dirs()->findResource("appdata", "html/kmymoney2.css"); - TQString header = TQString("\n\n").tqarg(filename); + TQString header = TQString("\n\n").arg(filename); header += KMyMoneyUtils::variableCSS(); @@ -226,7 +226,7 @@ void KHomeView::loadView(void) m_part->begin(); m_part->write(header); - m_part->write(TQString("
%1
").tqarg(i18n("Your Financial Summary"))); + m_part->write(TQString("
%1
").arg(i18n("Your Financial Summary"))); TQStringList settings = KMyMoneyGlobalSettings::itemList(); @@ -291,7 +291,7 @@ void KHomeView::loadView(void) void KHomeView::showNetWorthGraph(void) { #ifdef HAVE_KDCHART - m_part->write(TQString("
%1
\n
 
\n").tqarg(i18n("Networth Forecast"))); + m_part->write(TQString("
%1
\n
 
\n").arg(i18n("Networth Forecast"))); MyMoneyReport reportCfg = MyMoneyReport( MyMoneyReport::eAssetLiability, @@ -311,7 +311,7 @@ void KHomeView::showNetWorthGraph(void) reportCfg.setColumnsAreDays( true ); reportCfg.setConvertCurrency( true ); reportCfg.setIncludingForecast( true ); - reportCfg.setDateFilter(TQDate::tqcurrentDate(),TQDate::tqcurrentDate().addDays(+90)); + reportCfg.setDateFilter(TQDate::currentDate(),TQDate::currentDate().addDays(+90)); reports::PivotTable table(reportCfg); @@ -361,7 +361,7 @@ void KHomeView::showNetWorthGraph(void) m_part->write(""); m_part->write(""); - m_part->write(TQString("").tqarg(TQString(KCodecs::base64Encode(ba)))); + m_part->write(TQString("").arg(TQString(KCodecs::base64Encode(ba)))); m_part->write(""); m_part->write("
\"Networth\"
\"Networth\"
"); @@ -383,8 +383,8 @@ void KHomeView::showPayments(void) schedule = file->scheduleList("", MyMoneySchedule::TYPE_ANY, MyMoneySchedule::OCCUR_ANY, MyMoneySchedule::STYPE_ANY, - TQDate::tqcurrentDate(), - TQDate::tqcurrentDate().addMonths(1)); + TQDate::currentDate(), + TQDate::currentDate().addMonths(1)); overdues = file->scheduleList("", MyMoneySchedule::TYPE_ANY, MyMoneySchedule::OCCUR_ANY, MyMoneySchedule::STYPE_ANY, @@ -422,7 +422,7 @@ void KHomeView::showPayments(void) } m_part->write("
"); - m_part->write(TQString("
%1
\n").tqarg(i18n("Payments"))); + m_part->write(TQString("
%1
\n").arg(i18n("Payments"))); if(overdues.count() > 0) { m_part->write("
 
\n"); @@ -432,7 +432,7 @@ void KHomeView::showPayments(void) TQValueList::Iterator it_f; m_part->write(""); - m_part->write(TQString("\n").tqarg(showColoredAmount(i18n("Overdue payments"), true))); + m_part->write(TQString("\n").arg(showColoredAmount(i18n("Overdue payments"), true))); m_part->write(""); m_part->write("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); showPaymentEntry(*it, cnt); m_part->write(""); // make sure to not repeat overdues later again @@ -486,12 +486,12 @@ void KHomeView::showPayments(void) TQValueList todays; TQValueList::Iterator t_it; for (t_it=schedule.begin(); t_it!=schedule.end();) { - if ((*t_it).nextDueDate() == TQDate::tqcurrentDate()) { + if ((*t_it).nextDueDate() == TQDate::currentDate()) { todays.append(*t_it); (*t_it).setNextDueDate((*t_it).nextPayment((*t_it).nextDueDate())); - //if nextDueDate is still tqcurrentDate then remove it from scheduled payments - if ((*t_it).nextDueDate() == TQDate::tqcurrentDate()) { + //if nextDueDate is still currentDate then remove it from scheduled payments + if ((*t_it).nextDueDate() == TQDate::currentDate()) { t_it = schedule.remove(t_it); continue; } @@ -502,7 +502,7 @@ void KHomeView::showPayments(void) if (todays.count() > 0) { m_part->write("
 
\n"); m_part->write("
%1
%1
"); m_part->write(i18n("Date")); @@ -455,7 +455,7 @@ void KHomeView::showPayments(void) // determine number of overdue payments TQDate nextDate = (*it).adjustedNextDueDate(); int cnt = 0; - while(nextDate.isValid() && nextDate < TQDate::tqcurrentDate()) { + while(nextDate.isValid() && nextDate < TQDate::currentDate()) { ++cnt; nextDate = (*it).nextPayment(nextDate); // for single occurence nextDate will not change, so we @@ -464,7 +464,7 @@ void KHomeView::showPayments(void) break; } - m_part->write(TQString("
"); - m_part->write(TQString("\n").tqarg(i18n("Today's payments"))); + m_part->write(TQString("\n").arg(i18n("Today's payments"))); m_part->write(""); m_part->write(""); for(t_it = todays.begin(); t_it != todays.end(); ++t_it) { - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); showPaymentEntry(*t_it); m_part->write(""); } @@ -536,7 +536,7 @@ void KHomeView::showPayments(void) TQValueList::Iterator it; m_part->write("
%1
%1
"); m_part->write(i18n("Date")); @@ -522,7 +522,7 @@ void KHomeView::showPayments(void) m_part->write("
"); - m_part->write(TQString("\n").tqarg(i18n("Future payments"))); + m_part->write(TQString("\n").arg(i18n("Future payments"))); m_part->write(""); m_part->write("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); showPaymentEntry(*it); m_part->write(""); @@ -602,12 +602,12 @@ void KHomeView::showPayments(void) while(1); if (needMoreLess) { - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); m_part->write(""); m_part->write(""); @@ -642,16 +642,16 @@ void KHomeView::showPaymentEntry(const MyMoneySchedule& sched, int cnt) KGlobal::locale()->formatDate(sched.adjustedNextDueDate(), true) + "").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); showAccountEntry(*it_m); m_part->write(""); } @@ -812,7 +812,7 @@ void KHomeView::showAccountEntry(const MyMoneyAccount& acc) showAccountEntry(acc, value, MyMoneyMoney(), showLimit); } else { //get balance for normal accounts - value = file->balance(acc.id(), TQDate::tqcurrentDate()); + value = file->balance(acc.id(), TQDate::currentDate()); //if credit card or checkings account, show maximum credit if( acc.accountType() == MyMoneyAccount::CreditCard || @@ -846,10 +846,10 @@ void KHomeView::showAccountEntry(const MyMoneyAccount& acc, const MyMoneyMoney& } tmp = TQString(""; + link(VIEW_LEDGER, TQString("?id=%1").arg(acc.id())) + acc.name() + linkend() + ""; //show account balance - tmp += TQString("").tqarg(showColoredAmount(amount, value.isNegative())); + tmp += TQString("").arg(showColoredAmount(amount, value.isNegative())); //show minimum balance column if requested if(showMinBal) { @@ -858,7 +858,7 @@ void KHomeView::showAccountEntry(const MyMoneyAccount& acc, const MyMoneyMoney& tmp += TQString(""); } else { //show minimum balance entry - tmp += TQString("").tqarg(showColoredAmount(amountToMinBal, valueToMinBal.isNegative())); + tmp += TQString("").arg(showColoredAmount(amountToMinBal, valueToMinBal.isNegative())); } } // qDebug("accountEntry = '%s'", tmp.latin1()); @@ -886,7 +886,7 @@ MyMoneyMoney KHomeView::investmentBalance(const MyMoneyAccount& acc) val = val.convert(acc.fraction()); value += val; } catch(MyMoneyException* e) { - qWarning("%s", (TQString("cannot convert stock balance of %1 to base currency: %2").tqarg(stock.name(), e->what())).data()); + qWarning("%s", (TQString("cannot convert stock balance of %1 to base currency: %2").arg(stock.name(), e->what())).data()); delete e; } } @@ -906,7 +906,7 @@ void KHomeView::showFavoriteReports(void) { if ( (*it_report).isFavorite() ) { if(firstTime) { - m_part->write(TQString("
%1
\n
 
\n").tqarg(i18n("Favorite Reports"))); + m_part->write(TQString("
%1
\n
 
\n").arg(i18n("Favorite Reports"))); m_part->write("
%1
%1
"); m_part->write(i18n("Date")); @@ -560,7 +560,7 @@ void KHomeView::showPayments(void) cnt = (m_showAllSchedules) ? -1 : 6; bool needMoreLess = m_showAllSchedules; - TQDate lastDate = TQDate::tqcurrentDate().addMonths(1); + TQDate lastDate = TQDate::currentDate().addMonths(1); qBubbleSort(schedule); do { it = schedule.begin(); @@ -585,7 +585,7 @@ void KHomeView::showPayments(void) if(cnt > 0) --cnt; - m_part->write(TQString("
"); if(m_showAllSchedules) { - m_part->write(link(VIEW_SCHEDULE, TQString("?mode=%1").tqarg("reduced")) + i18n("Less...") + linkend()); + m_part->write(link(VIEW_SCHEDULE, TQString("?mode=%1").arg("reduced")) + i18n("Less...") + linkend()); } else { - m_part->write(link(VIEW_SCHEDULE, TQString("?mode=%1").tqarg("full")) + i18n("More...") + linkend()); + m_part->write(link(VIEW_SCHEDULE, TQString("?mode=%1").arg("full")) + i18n("More...") + linkend()); } m_part->write("
"; if(pathEnter.length() > 0) - tmp += link(VIEW_SCHEDULE, TQString("?id=%1&mode=enter").tqarg(sched.id()), i18n("Enter schedule")) + TQString("").tqarg(pathEnter) + linkend(); + tmp += link(VIEW_SCHEDULE, TQString("?id=%1&mode=enter").arg(sched.id()), i18n("Enter schedule")) + TQString("").arg(pathEnter) + linkend(); if(pathSkip.length() > 0) - tmp += " " + link(VIEW_SCHEDULE, TQString("?id=%1&mode=skip").tqarg(sched.id()), i18n("Skip schedule")) + TQString("").tqarg(pathSkip) + linkend(); + tmp += " " + link(VIEW_SCHEDULE, TQString("?id=%1&mode=skip").arg(sched.id()), i18n("Skip schedule")) + TQString("").arg(pathSkip) + linkend(); tmp += TQString(" "); - tmp += link(VIEW_SCHEDULE, TQString("?id=%1&mode=edit").tqarg(sched.id()), i18n("Edit schedule")) + sched.name() + linkend(); + tmp += link(VIEW_SCHEDULE, TQString("?id=%1&mode=edit").arg(sched.id()), i18n("Edit schedule")) + sched.name() + linkend(); //show quantity of payments overdue if any if(cnt > 1) - tmp += i18n(" (%1 payments)").tqarg(cnt); + tmp += i18n(" (%1 payments)").arg(cnt); //show account of the main split tmp += ""; @@ -788,7 +788,7 @@ void KHomeView::showAccounts(KHomeView::paymentTypeE type, const TQString& heade TQMap::const_iterator it_m; for(it_m = nameIdx.begin(); it_m != nameIdx.end(); ++it_m) { - m_part->write(TQString("
") + - link(VIEW_LEDGER, TQString("?id=%1").tqarg(acc.id())) + acc.name() + linkend() + "%1%1 %1%1
"); m_part->write("") - .tqarg(row++ & 0x01 ? "even" : "odd") - .tqarg(link(VIEW_REPORTS, TQString("?id=%1").tqarg((*it_report).id()))) - .tqarg((*it_report).name()) - .tqarg(linkend()) - .tqarg((*it_report).comment()) + .arg(row++ & 0x01 ? "even" : "odd") + .arg(link(VIEW_REPORTS, TQString("?id=%1").arg((*it_report).id()))) + .arg((*it_report).name()) + .arg(linkend()) + .arg((*it_report).comment()) ); } @@ -955,22 +955,22 @@ void KHomeView::showForecast(void) int colspan = 1; // get begin day - int beginDay = TQDate::tqcurrentDate().daysTo(m_forecast.beginForecastDate()); + int beginDay = TQDate::currentDate().daysTo(m_forecast.beginForecastDate()); // if begin day is today skip to next cycle if(beginDay == 0) beginDay = m_forecast.accountsCycle(); // Now output header - m_part->write(TQString("
%1
\n
 
\n").tqarg(i18n("%1 Day Forecast").tqarg(m_forecast.forecastDays()))); + m_part->write(TQString("
%1
\n
 
\n").arg(i18n("%1 Day Forecast").arg(m_forecast.forecastDays()))); m_part->write("
"); m_part->write(i18n("Report")); @@ -917,11 +917,11 @@ void KHomeView::showFavoriteReports(void) } m_part->write(TQString("
%2%3%4%5
"); m_part->write(""); int colWidth = 55/ (m_forecast.forecastDays() / m_forecast.accountsCycle()); for(i = 0; (i*m_forecast.accountsCycle() + beginDay) <= m_forecast.forecastDays(); ++i) { - m_part->write(TQString(""); colspan++; } @@ -983,9 +983,9 @@ void KHomeView::showForecast(void) for(it_account = nameIdx.begin(); it_account != nameIdx.end(); ++it_account) { //MyMoneyAccount acc = (*it_n); - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); m_part->write(TQString(""); + link(VIEW_LEDGER, TQString("?id=%1").arg((*it_account).id())) + (*it_account).name() + linkend() + ""); int dropZero = -1; //account dropped below zero int dropMinimum = -1; //account dropped below minimum balance @@ -1003,12 +1003,12 @@ void KHomeView::showForecast(void) } for (int f = beginDay; f <= m_forecast.forecastDays(); f += m_forecast.accountsCycle()) { - forecastBalance = m_forecast.forecastBalance(*it_account, TQDate::tqcurrentDate().addDays(f)); + forecastBalance = m_forecast.forecastBalance(*it_account, TQDate::currentDate().addDays(f)); TQString amount; amount = forecastBalance.formatMoney( *it_account, currency); amount.replace(" "," "); - m_part->write(TQString("").tqarg(showColoredAmount(amount, forecastBalance.isNegative()))); + m_part->write(TQString("").arg(showColoredAmount(amount, forecastBalance.isNegative()))); } m_part->write(""); @@ -1036,17 +1036,17 @@ void KHomeView::showForecast(void) case -1: break; case 0: - msg = i18n("The balance of %1 is below the minimum balance %2 today.").tqarg((*it_account).name()).tqarg(minBalance.formatMoney(*it_account, currency)); + msg = i18n("The balance of %1 is below the minimum balance %2 today.").arg((*it_account).name()).arg(minBalance.formatMoney(*it_account, currency)); msg = showColoredAmount(msg, true); break; default: - msg = i18n("The balance of %1 will drop below the minimum balance %2 in %3 days.").tqarg((*it_account).name()).tqarg(minBalance.formatMoney(*it_account, currency)).tqarg(dropMinimum-1); + msg = i18n("The balance of %1 will drop below the minimum balance %2 in %3 days.").arg((*it_account).name()).arg(minBalance.formatMoney(*it_account, currency)).arg(dropMinimum-1); msg = showColoredAmount(msg, true); break; } if(!msg.isEmpty()) { - m_part->write(TQString("").tqarg(msg).tqarg(colspan)); + m_part->write(TQString("").arg(msg).arg(colspan)); } } // a drop below zero is always shown @@ -1056,28 +1056,28 @@ void KHomeView::showForecast(void) break; case 0: if((*it_account).accountGroup() == MyMoneyAccount::Asset) { - msg = i18n("The balance of %1 is below %2 today.").tqarg((*it_account).name()).tqarg(MyMoneyMoney().formatMoney(*it_account, currency)); + msg = i18n("The balance of %1 is below %2 today.").arg((*it_account).name()).arg(MyMoneyMoney().formatMoney(*it_account, currency)); msg = showColoredAmount(msg, true); break; } if((*it_account).accountGroup() == MyMoneyAccount::Liability) { - msg = i18n("The balance of %1 is above %2 today.").tqarg((*it_account).name()).tqarg(MyMoneyMoney().formatMoney(*it_account, currency)); + msg = i18n("The balance of %1 is above %2 today.").arg((*it_account).name()).arg(MyMoneyMoney().formatMoney(*it_account, currency)); break; } break; default: if((*it_account).accountGroup() == MyMoneyAccount::Asset) { - msg = i18n("The balance of %1 will drop below %2 in %3 days.").tqarg((*it_account).name()).tqarg(MyMoneyMoney().formatMoney(*it_account, currency)).tqarg(dropZero); + msg = i18n("The balance of %1 will drop below %2 in %3 days.").arg((*it_account).name()).arg(MyMoneyMoney().formatMoney(*it_account, currency)).arg(dropZero); msg = showColoredAmount(msg, true); break; } if((*it_account).accountGroup() == MyMoneyAccount::Liability) { - msg = i18n("The balance of %1 will raise above %2 in %3 days.").tqarg((*it_account).name()).tqarg(MyMoneyMoney().formatMoney(*it_account, currency)).tqarg(dropZero); + msg = i18n("The balance of %1 will raise above %2 in %3 days.").arg((*it_account).name()).arg(MyMoneyMoney().formatMoney(*it_account, currency)).arg(dropZero); break; } } if(!msg.isEmpty()) { - m_part->write(TQString("").tqarg(msg).tqarg(colspan)); + m_part->write(TQString("").arg(msg).arg(colspan)); } } m_part->write("
"); m_part->write(i18n("Account")); m_part->write("").tqarg(colWidth)); + m_part->write(TQString("").arg(colWidth)); - m_part->write(i18n("%1 days").tqarg(i*m_forecast.accountsCycle() + beginDay)); + m_part->write(i18n("%1 days").arg(i*m_forecast.accountsCycle() + beginDay)); m_part->write("
") + - link(VIEW_LEDGER, TQString("?id=%1").tqarg((*it_account).id())) + (*it_account).name() + linkend() + "").tqarg(colWidth)); - m_part->write(TQString("%1").arg(colWidth)); + m_part->write(TQString("%1
%1
%1
%1
%1
"); @@ -1090,9 +1090,9 @@ const TQString KHomeView::link(const TQString& view, const TQString& query, cons TQString titlePart; TQString title(_title); if(!title.isEmpty()) - titlePart = TQString(" title=\"%1\"").tqarg(title.replace(" ", " ")); + titlePart = TQString(" title=\"%1\"").arg(title.replace(" ", " ")); - return TQString("").tqarg(view, query, titlePart); + return TQString("").arg(view, query, titlePart); } const TQString KHomeView::linkend(void) const @@ -1260,7 +1260,7 @@ void KHomeView::showAssetsLiabilities(void) TQMap::const_iterator asset_it = nameAssetsIdx.begin(); TQMap::const_iterator liabilities_it = nameLiabilitiesIdx.begin(); for(; asset_it != nameAssetsIdx.end() || liabilities_it != nameLiabilitiesIdx.end();) { - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); //write an asset account if we still have any if(asset_it != nameAssetsIdx.end()) { MyMoneyMoney value; @@ -1268,12 +1268,12 @@ void KHomeView::showAssetsLiabilities(void) if( (*asset_it).accountType() == MyMoneyAccount::Investment) { value = investmentBalance(*asset_it); } else { - value = MyMoneyFile::instance()->balance((*asset_it).id(), TQDate::tqcurrentDate()); + value = MyMoneyFile::instance()->balance((*asset_it).id(), TQDate::currentDate()); } //calculate balance for foreign currency accounts if((*asset_it).currencyId() != file->baseCurrency().id()) { ReportAccount repAcc = ReportAccount((*asset_it).id()); - MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::tqcurrentDate()); + MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::currentDate()); MyMoneyMoney baseValue = value * curPrice; baseValue = baseValue.convert(10000); netAssets += baseValue; @@ -1294,11 +1294,11 @@ void KHomeView::showAssetsLiabilities(void) //write a liability account if(liabilities_it != nameLiabilitiesIdx.end()) { MyMoneyMoney value; - value = MyMoneyFile::instance()->balance((*liabilities_it).id(), TQDate::tqcurrentDate()); + value = MyMoneyFile::instance()->balance((*liabilities_it).id(), TQDate::currentDate()); //calculate balance if foreign currency if((*liabilities_it).currencyId() != file->baseCurrency().id()) { ReportAccount repAcc = ReportAccount((*liabilities_it).id()); - MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::tqcurrentDate()); + MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::currentDate()); MyMoneyMoney baseValue = value * curPrice; baseValue = baseValue.convert(10000); netLiabilities += baseValue; @@ -1325,23 +1325,23 @@ void KHomeView::showAssetsLiabilities(void) amountLiabilities.replace(" "," "); amountNetWorth.replace(" "," "); - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); //print total for assets - m_part->write(TQString("%1%2").tqarg(i18n("Total Assets")).tqarg(showColoredAmount(amountAssets, netAssets.isNegative()))); + m_part->write(TQString("%1%2").arg(i18n("Total Assets")).arg(showColoredAmount(amountAssets, netAssets.isNegative()))); //leave the intermediate column empty m_part->write(""); //print total liabilities - m_part->write(TQString("%1%2").tqarg(i18n("Total Liabilities")).tqarg(showColoredAmount(amountLiabilities, netLiabilities.isNegative()))); + m_part->write(TQString("%1%2").arg(i18n("Total Liabilities")).arg(showColoredAmount(amountLiabilities, netLiabilities.isNegative()))); m_part->write(""); //print net worth - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); m_part->write(""); - m_part->write(TQString("%1%2").tqarg(i18n("Net Worth")).tqarg(showColoredAmount(amountNetWorth, netWorth.isNegative() ))); + m_part->write(TQString("%1%2").arg(i18n("Net Worth")).arg(showColoredAmount(amountNetWorth, netWorth.isNegative() ))); m_part->write(""); m_part->write(""); @@ -1402,9 +1402,9 @@ void KHomeView::showBudget(void) TQString totalActualAmount = totalActualValue.formatMoney(file->baseCurrency().tradingSymbol(), prec); TQString totalBudgetDiffAmount = totalBudgetDiffValue.formatMoney(file->baseCurrency().tradingSymbol(), prec); - m_part->write(TQString("%1").tqarg(showColoredAmount(totalBudgetAmount, totalBudgetValue.isNegative()))); - m_part->write(TQString("%1").tqarg(showColoredAmount(totalActualAmount, totalActualValue.isNegative()))); - m_part->write(TQString("%1").tqarg(showColoredAmount(totalBudgetDiffAmount, totalBudgetDiffValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(totalBudgetAmount, totalBudgetValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(totalActualAmount, totalActualValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(totalBudgetDiffAmount, totalBudgetDiffValue.isNegative()))); m_part->write(""); m_part->write(""); @@ -1448,10 +1448,10 @@ void KHomeView::showBudget(void) //write the outergroup if it is the first row of outergroup being shown if(i == 0) { m_part->write(""); - m_part->write(TQString("%1").tqarg(KMyMoneyUtils::accountTypeToString( rowname.accountType()))); + m_part->write(TQString("%1").arg(KMyMoneyUtils::accountTypeToString( rowname.accountType()))); m_part->write(""); } - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); //get values from grid MyMoneyMoney actualValue = it_row.data()[eActual][1]; @@ -1464,12 +1464,12 @@ void KHomeView::showBudget(void) TQString budgetDiffAmount = budgetDiffValue.formatMoney(file->baseCurrency().tradingSymbol(), prec); //account name - m_part->write(TQString("") + link(VIEW_LEDGER, TQString("?id=%1").tqarg(rowname.id())) + rowname.name() + linkend() + ""); + m_part->write(TQString("") + link(VIEW_LEDGER, TQString("?id=%1").arg(rowname.id())) + rowname.name() + linkend() + ""); //show amounts - m_part->write(TQString("%1").tqarg(showColoredAmount(budgetAmount, budgetValue.isNegative()))); - m_part->write(TQString("%1").tqarg(showColoredAmount(actualAmount, actualValue.isNegative()))); - m_part->write(TQString("%1").tqarg(showColoredAmount(budgetDiffAmount, budgetDiffValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(budgetAmount, budgetValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(actualAmount, actualValue.isNegative()))); + m_part->write(TQString("%1").arg(showColoredAmount(budgetDiffAmount, budgetDiffValue.isNegative()))); m_part->write(""); } ++it_row; @@ -1481,8 +1481,8 @@ void KHomeView::showBudget(void) //if no negative differences are found, then inform that if(i == 0) { - m_part->write(TQString("").tqarg(i++ & 0x01 ? "even" : "odd")); - m_part->write(TQString("%1").tqarg(i18n("No Budget Categories have been overrun"))); + m_part->write(TQString("").arg(i++ & 0x01 ? "even" : "odd")); + m_part->write(TQString("%1").arg(i18n("No Budget Categories have been overrun"))); m_part->write(""); } m_part->write("
"); @@ -1493,7 +1493,7 @@ TQString KHomeView::showColoredAmount(const TQString& amount, bool isNegative) { if(isNegative) { //if negative, get the settings for negative numbers - return TQString("%2").tqarg(KMyMoneyGlobalSettings::listNegativeValueColor().name(), amount); + return TQString("%2").arg(KMyMoneyGlobalSettings::listNegativeValueColor().name(), amount); } //if positive, return the same string @@ -1518,16 +1518,16 @@ void KHomeView::doForecast(void) MyMoneyMoney KHomeView::forecastPaymentBalance(const MyMoneyAccount& acc, const MyMoneyMoney& payment, TQDate& paymentDate) { - //if paymentDate before or equal to tqcurrentDate set it to current date plus 1 + //if paymentDate before or equal to currentDate set it to current date plus 1 //so we get to accumulate forecast balance correctly - if(paymentDate <= TQDate::tqcurrentDate()) - paymentDate = TQDate::tqcurrentDate().addDays(1); + if(paymentDate <= TQDate::currentDate()) + paymentDate = TQDate::currentDate().addDays(1); //check if the account is already there if(m_accountList.find(acc.id()) == m_accountList.end() || m_accountList[acc.id()].find(paymentDate) == m_accountList[acc.id()].end()) { - if(paymentDate == TQDate::tqcurrentDate()) { + if(paymentDate == TQDate::currentDate()) { m_accountList[acc.id()][paymentDate] = m_forecast.forecastBalance(acc, paymentDate); } else { m_accountList[acc.id()][paymentDate] = m_forecast.forecastBalance(acc, paymentDate.addDays(-1)); @@ -1547,8 +1547,8 @@ void KHomeView::showCashFlowSummary() int prec = MyMoneyMoney::denomToPrec(file->baseCurrency().smallestAccountFraction()); //set start and end of month dates - TQDate startOfMonth = TQDate(TQDate::tqcurrentDate().year(), TQDate::tqcurrentDate().month(), 1); - TQDate endOfMonth = TQDate(TQDate::tqcurrentDate().year(), TQDate::tqcurrentDate().month(), TQDate::tqcurrentDate().daysInMonth()); + TQDate startOfMonth = TQDate(TQDate::currentDate().year(), TQDate::currentDate().month(), 1); + TQDate endOfMonth = TQDate(TQDate::currentDate().year(), TQDate::currentDate().month(), TQDate::currentDate().daysInMonth()); //Add total income and expenses for this month //get transactions for current month @@ -1660,8 +1660,8 @@ void KHomeView::showCashFlowSummary() MyMoneyAccount acc = file->account((*it_s).accountId()); // collect all overdues on the first day TQDate schedDate = nextDate; - if(TQDate::tqcurrentDate() >= nextDate) - schedDate = TQDate::tqcurrentDate().addDays(1); + if(TQDate::currentDate() >= nextDate) + schedDate = TQDate::currentDate().addDays(1); balanceMap[acc.id()] += file->balance(acc.id()); } @@ -1680,7 +1680,7 @@ void KHomeView::showCashFlowSummary() //convert to foreign currency if needed if(repSplitAcc.currencyId() != file->baseCurrency().id()) { - MyMoneyMoney curPrice = repSplitAcc.baseCurrencyPrice(TQDate::tqcurrentDate()); + MyMoneyMoney curPrice = repSplitAcc.baseCurrencyPrice(TQDate::currentDate()); value = value * curPrice; value = value.convert(10000); } @@ -1733,11 +1733,11 @@ void KHomeView::showCashFlowSummary() case MyMoneyAccount::Savings: case MyMoneyAccount::Cash: { - MyMoneyMoney value = MyMoneyFile::instance()->balance((*account_it).id(), TQDate::tqcurrentDate()); + MyMoneyMoney value = MyMoneyFile::instance()->balance((*account_it).id(), TQDate::currentDate()); //calculate balance for foreign currency accounts if((*account_it).currencyId() != file->baseCurrency().id()) { ReportAccount repAcc = ReportAccount((*account_it).id()); - MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::tqcurrentDate()); + MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::currentDate()); MyMoneyMoney baseValue = value * curPrice; liquidAssets += baseValue; liquidAssets = liquidAssets.convert(10000); @@ -1750,11 +1750,11 @@ void KHomeView::showCashFlowSummary() case MyMoneyAccount::CreditCard: { MyMoneyMoney value; - value = MyMoneyFile::instance()->balance((*account_it).id(), TQDate::tqcurrentDate()); + value = MyMoneyFile::instance()->balance((*account_it).id(), TQDate::currentDate()); //calculate balance if foreign currency if((*account_it).currencyId() != file->baseCurrency().id()) { ReportAccount repAcc = ReportAccount((*account_it).id()); - MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::tqcurrentDate()); + MyMoneyMoney curPrice = repAcc.baseCurrencyPrice(TQDate::currentDate()); MyMoneyMoney baseValue = value * curPrice; liquidLiabilities += baseValue; liquidLiabilities = liquidLiabilities.convert(10000); @@ -1810,16 +1810,16 @@ void KHomeView::showCashFlowSummary() m_part->write(TQString("")); //print current income - m_part->write(TQString("%2").tqarg(showColoredAmount(amountIncome, incomeValue.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountIncome, incomeValue.isNegative()))); //print the scheduled income - m_part->write(TQString("%2").tqarg(showColoredAmount(amountScheduledIncome, scheduledIncome.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountScheduledIncome, scheduledIncome.isNegative()))); //print current expenses - m_part->write(TQString("%2").tqarg(showColoredAmount(amountExpense, expenseValue.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountExpense, expenseValue.isNegative()))); //print the scheduled expenses - m_part->write(TQString("%2").tqarg(showColoredAmount(amountScheduledExpense, scheduledExpense.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountScheduledExpense, scheduledExpense.isNegative()))); m_part->write(""); m_part->write(""); @@ -1852,16 +1852,16 @@ void KHomeView::showCashFlowSummary() m_part->write(TQString("")); //print current liquid assets - m_part->write(TQString("%2").tqarg(showColoredAmount(amountLiquidAssets, liquidAssets.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountLiquidAssets, liquidAssets.isNegative()))); //print the scheduled transfers - m_part->write(TQString("%2").tqarg(showColoredAmount(amountScheduledLiquidTransfer, scheduledLiquidTransfer.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountScheduledLiquidTransfer, scheduledLiquidTransfer.isNegative()))); //print current liabilities - m_part->write(TQString("%2").tqarg(showColoredAmount(amountLiquidLiabilities, liquidLiabilities.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountLiquidLiabilities, liquidLiabilities.isNegative()))); //print the scheduled transfers - m_part->write(TQString("%2").tqarg(showColoredAmount(amountScheduledOtherTransfer, scheduledOtherTransfer.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountScheduledOtherTransfer, scheduledOtherTransfer.isNegative()))); m_part->write(""); @@ -1909,13 +1909,13 @@ void KHomeView::showCashFlowSummary() m_part->write(" "); //print expected assets - m_part->write(TQString("%2").tqarg(showColoredAmount(amountExpectedAsset, expectedAsset.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountExpectedAsset, expectedAsset.isNegative()))); //print expected liabilities - m_part->write(TQString("%2").tqarg(showColoredAmount(amountExpectedLiabilities, expectedLiabilities.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountExpectedLiabilities, expectedLiabilities.isNegative()))); //print expected profit - m_part->write(TQString("%2").tqarg(showColoredAmount(amountProfit, profitValue.isNegative()))); + m_part->write(TQString("%2").arg(showColoredAmount(amountProfit, profitValue.isNegative()))); m_part->write(""); diff --git a/kmymoney2/views/kinstitutionsview.h b/kmymoney2/views/kinstitutionsview.h index 6293f35..b604ae9 100644 --- a/kmymoney2/views/kinstitutionsview.h +++ b/kmymoney2/views/kinstitutionsview.h @@ -59,8 +59,8 @@ public slots: void show(void); /** - * Override the base class behaviour to restore the tqlayout. Do not - * do this in show() because show() itself may change the tqlayout + * Override the base class behaviour to restore the layout. Do not + * do this in show() because show() itself may change the layout * in undesired ways. */ void polish(void); diff --git a/kmymoney2/views/kinstitutionsviewdecl.ui b/kmymoney2/views/kinstitutionsviewdecl.ui index 1134e3b..1fc2890 100644 --- a/kmymoney2/views/kinstitutionsviewdecl.ui +++ b/kmymoney2/views/kinstitutionsviewdecl.ui @@ -29,7 +29,7 @@
- tqlayout2 + layout2 @@ -45,7 +45,7 @@ Expanding - + 20 20 @@ -56,7 +56,7 @@ m_totalProfitsLabel - + 150 0 @@ -68,7 +68,7 @@ RichText - + WordBreak|AlignVCenter|AlignRight diff --git a/kmymoney2/views/kinvestmentlistitem.cpp b/kmymoney2/views/kinvestmentlistitem.cpp index b7617d8..d13f5d3 100644 --- a/kmymoney2/views/kinvestmentlistitem.cpp +++ b/kmymoney2/views/kinvestmentlistitem.cpp @@ -130,7 +130,7 @@ const TQString KInvestmentListItem::calculateGain(const equity_price_history& hi else { bool bFoundCurrent = false, bFoundComparison = false; - TQDate tempDate, comparisonDate = TQDate::tqcurrentDate(); + TQDate tempDate, comparisonDate = TQDate::currentDate(); if(YTD) { @@ -147,7 +147,7 @@ const TQString KInvestmentListItem::calculateGain(const equity_price_history& hi //find the current value, or closest to the current value. equity_price_history::ConstIterator itToday = history.end(); - for(tempDate = TQDate::tqcurrentDate(); tempDate >= comparisonDate; ) + for(tempDate = TQDate::currentDate(); tempDate >= comparisonDate; ) { itToday = history.find(tempDate); if(itToday != history.end()) @@ -169,7 +169,7 @@ const TQString KInvestmentListItem::calculateGain(const equity_price_history& hi //should already be sorted earliest to latest. for(equity_price_history::ConstIterator it = history.begin(); it != history.end(); ++it) { - if(it.key() >= comparisonDate && it.key() < TQDate::tqcurrentDate()) + if(it.key() >= comparisonDate && it.key() < TQDate::currentDate()) { comparisonDate = it.key(); comparisonValue = it.data(); @@ -195,7 +195,7 @@ const TQString KInvestmentListItem::calculateGain(const equity_price_history& hi bNegative = true; } - TQString ds = TQString("%1%").tqarg(result, 0, 'f', 3); + TQString ds = TQString("%1%").arg(result, 0, 'f', 3); return ds; /*MyMoneyMoney result = (currentValue / comparisonValue); diff --git a/kmymoney2/views/kinvestmentviewdecl.ui b/kmymoney2/views/kinvestmentviewdecl.ui index 7c4a028..f681c7a 100644 --- a/kmymoney2/views/kinvestmentviewdecl.ui +++ b/kmymoney2/views/kinvestmentviewdecl.ui @@ -24,7 +24,7 @@ - tqlayout2 + layout2 @@ -53,7 +53,7 @@ Expanding - + 280 20 diff --git a/kmymoney2/views/kmymoneyview.cpp b/kmymoney2/views/kmymoneyview.cpp index eba2a82..e557aab 100644 --- a/kmymoney2/views/kmymoneyview.cpp +++ b/kmymoney2/views/kmymoneyview.cpp @@ -27,14 +27,14 @@ #include #include -#include +#include #include -#include +#include #include #include #include -#include +#include #include // ---------------------------------------------------------------------------- @@ -583,7 +583,7 @@ bool KMyMoneyView::readFile(const KURL& url) } else { if(!KIO::NetAccess::download(url, filename, NULL)) { KMessageBox::detailedError(this, - i18n("Error while loading file '%1'!").tqarg(url.url()), + i18n("Error while loading file '%1'!").arg(url.url()), KIO::NetAccess::lastErrorString(), i18n("File access error")); return false; @@ -595,7 +595,7 @@ bool KMyMoneyView::readFile(const KURL& url) TQFile file(filename); TQFileInfo info(file); if(!info.isFile()) { - TQString msg=i18n("%1 is not a KMyMoney file.").tqarg(filename); + TQString msg=i18n("%1 is not a KMyMoney file.").arg(filename); KMessageBox::error(this, TQString("

")+msg, i18n("Filetype Error")); return false; } @@ -636,7 +636,7 @@ bool KMyMoneyView::readFile(const KURL& url) haveAt = false; isEncrypted = true; } else { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("GPG is not available for decryption of file %1").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("GPG is not available for decryption of file %1").arg(filename))); qfile = TQT_TQIODEVICE(new TQFile(file.name())); } } else { @@ -714,18 +714,18 @@ bool KMyMoneyView::readFile(const KURL& url) ::timetrace("done reading to memory"); } else { if(m_fileType == KmmBinary) { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 contains the old binary format used by KMyMoney. Please use an older version of KMyMoney (0.8.x) that still supports this format to convert it to the new XML based format.").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 contains the old binary format used by KMyMoney. Please use an older version of KMyMoney (0.8.x) that still supports this format to convert it to the new XML based format.").arg(filename))); } else { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 contains an unknown file format!").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 contains an unknown file format!").arg(filename))); } rc = false; } } else { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("Cannot read from file %1!").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("Cannot read from file %1!").arg(filename))); rc = false; } } catch (MyMoneyException *e) { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("Cannot load file %1. Reason: %2").tqarg(filename, e->what()))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("Cannot load file %1. Reason: %2").arg(filename, e->what()))); delete e; rc = false; } @@ -735,13 +735,13 @@ bool KMyMoneyView::readFile(const KURL& url) } qfile->close(); } else { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 not found!").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 not found!").arg(filename))); rc = false; } delete qfile; } } else { - KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 not found!").tqarg(filename))); + KMessageBox::sorry(this, TQString("%1"). arg(i18n("File %1 not found!").arg(filename))); rc = false; } @@ -805,7 +805,7 @@ bool KMyMoneyView::openDatabase (const KURL& url) { retry = false; break; case 1: // permanent error - KMessageBox::detailedError (this, i18n("Can't open database %1\n").tqarg(dbURL.prettyURL()), reader->lastError()); + KMessageBox::detailedError (this, i18n("Can't open database %1\n").arg(dbURL.prettyURL()), reader->lastError()); if (pDBMgr) { removeStorage(); delete pDBMgr; @@ -911,7 +911,7 @@ bool KMyMoneyView::initializeStorage() // Check if we have to modify the file before we allow to work with it IMyMoneyStorage* s = MyMoneyFile::instance()->storage(); while (s->fileFixVersion() < s->currentFixVersion()) { - qDebug("%s", (TQString("testing fileFixVersion %1 < %2").tqarg(s->fileFixVersion()).tqarg(s->currentFixVersion())).data()); + qDebug("%s", (TQString("testing fileFixVersion %1 < %2").arg(s->fileFixVersion()).arg(s->currentFixVersion())).data()); switch (s->fileFixVersion()) { case 0: fixFile_0(); @@ -984,7 +984,7 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter if(KMyMoneyGlobalSettings::encryptRecover()) { encryptRecover = true; if(!KGPGFile::keyAvailable(TQString(RECOVER_KEY_ID))) { - KMessageBox::sorry(this, TQString("

")+i18n("You have selected to encrypt your data also with the KMyMoney recover key, but the key with id

%1

has not been found in your keyring at this time. Please make sure to import this key into your keyring. You can find it on the
KMyMoney web-site. This time your data will not be encrypted with the KMyMoney recover key.").tqarg(RECOVER_KEY_ID), i18n("GPG-Key not found")); + KMessageBox::sorry(this, TQString("

")+i18n("You have selected to encrypt your data also with the KMyMoney recover key, but the key with id

%1

has not been found in your keyring at this time. Please make sure to import this key into your keyring. You can find it on the KMyMoney web-site. This time your data will not be encrypted with the KMyMoney recover key.").arg(RECOVER_KEY_ID), i18n("GPG-Key not found")); encryptRecover = false; } } @@ -993,7 +993,7 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter TQStringList::const_iterator it_s; for(it_s = keys.begin(); it_s != keys.begin(); ++it_s) { if(!KGPGFile::keyAvailable(*it_s)) { - KMessageBox::sorry(this, TQString("

")+i18n("You have specified to encrypt your data for the user-id

%1.

Unfortunately, a valid key for this user-id was not found in your keyring. Please make sure to import a valid key for this user-id. This time, encryption is disabled.").tqarg(*it_s), i18n("GPG-Key not found")); + KMessageBox::sorry(this, TQString("

")+i18n("You have specified to encrypt your data for the user-id

%1.

Unfortunately, a valid key for this user-id was not found in your keyring. Please make sure to import a valid key for this user-id. This time, encryption is disabled.").arg(*it_s), i18n("GPG-Key not found")); encryptedOk = false; } } @@ -1031,7 +1031,7 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter if(!dev || !dev->open(IO_WriteOnly)) { MyMoneyFile::instance()->blockSignals(blocked); delete dev; - throw new MYMONEYEXCEPTION(i18n("Unable to open file '%1' for writing.").tqarg(qfile->name())); + throw new MYMONEYEXCEPTION(i18n("Unable to open file '%1' for writing.").arg(qfile->name())); } } else if(!plaintext) { @@ -1045,7 +1045,7 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter if(!dev || !dev->open(IO_WriteOnly)) { MyMoneyFile::instance()->blockSignals(blocked); delete dev; - throw new MYMONEYEXCEPTION(i18n("Unable to open file '%1' for writing.").tqarg(qfile->name())); + throw new MYMONEYEXCEPTION(i18n("Unable to open file '%1' for writing.").arg(qfile->name())); } statusDevice = base->device(); } @@ -1054,11 +1054,11 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter ft.commit(); pWriter->setProgressCallback(&KMyMoneyView::progressCallback); - dev->resetqStatus(); + dev->reseStatus(); pWriter->writeFile(dev, dynamic_cast (MyMoneyFile::instance()->storage())); MyMoneyFile::instance()->blockSignals(blocked); if(statusDevice->status() != IO_Ok) { - throw new MYMONEYEXCEPTION(i18n("Failure while writing to '%1'").tqarg(qfile->name())); + throw new MYMONEYEXCEPTION(i18n("Failure while writing to '%1'").arg(qfile->name())); } pWriter->setProgressCallback(0); @@ -1067,7 +1067,7 @@ void KMyMoneyView::saveToLocalFile(TQFile* qfile, IMyMoneyStorageFormat* pWriter dev->close(); if(statusDevice->status() != IO_Ok) { delete dev; - throw new MYMONEYEXCEPTION(i18n("Failure while writing to '%1'").tqarg(qfile->name())); + throw new MYMONEYEXCEPTION(i18n("Failure while writing to '%1'").arg(qfile->name())); } delete dev; } else @@ -1115,7 +1115,7 @@ bool KMyMoneyView::saveFile(const KURL& url, const TQString& keyList) bool rc = true; try { if(! url.isValid()) { - throw new MYMONEYEXCEPTION(i18n("Malformed URL '%1'").tqarg(url.url())); + throw new MYMONEYEXCEPTION(i18n("Malformed URL '%1'").arg(url.url())); } if(url.isLocalFile()) { @@ -1144,10 +1144,10 @@ bool KMyMoneyView::saveFile(const KURL& url, const TQString& keyList) } catch (MyMoneyException* e) { qfile.abort(); delete e; - throw new MYMONEYEXCEPTION(i18n("Unable to write changes to '%1'").tqarg(filename)); + throw new MYMONEYEXCEPTION(i18n("Unable to write changes to '%1'").arg(filename)); } } else { - throw new MYMONEYEXCEPTION(i18n("Unable to write changes to '%1'").tqarg(filename)); + throw new MYMONEYEXCEPTION(i18n("Unable to write changes to '%1'").arg(filename)); } } chown(filename, static_cast(-1), gid); @@ -1155,7 +1155,7 @@ bool KMyMoneyView::saveFile(const KURL& url, const TQString& keyList) KTempFile tmpfile; saveToLocalFile(tmpfile.file(), pWriter, plaintext, keyList); if(!KIO::NetAccess::upload(tmpfile.name(), url, NULL)) - throw new MYMONEYEXCEPTION(i18n("Unable to upload to '%1'").tqarg(url.url())); + throw new MYMONEYEXCEPTION(i18n("Unable to upload to '%1'").arg(url.url())); tmpfile.unlink(); } m_fileType = KmmXML; @@ -1210,7 +1210,7 @@ bool KMyMoneyView::saveAsDatabase(const KURL& url) KMessageBox::detailedError (this, i18n("Can't open or create database %1\n" "Retry SaveAsDatabase and click Help" - " for further info").tqarg(url.prettyURL()), writer->lastError()); + " for further info").arg(url.prettyURL()), writer->lastError()); } delete writer; return (rc); @@ -1268,7 +1268,7 @@ void KMyMoneyView::slotSetBaseCurrency(const MyMoneySecurity& baseCurrency) MyMoneyFile::instance()->setBaseCurrency(baseCurrency); ft.commit(); } catch(MyMoneyException *e) { - KMessageBox::sorry(this, i18n("Cannot set %1 as base currency: %2").tqarg(baseCurrency.name()).tqarg(e->what()), i18n("Set base currency")); + KMessageBox::sorry(this, i18n("Cannot set %1 as base currency: %2").arg(baseCurrency.name()).arg(e->what()), i18n("Set base currency")); delete e; } } @@ -1568,7 +1568,7 @@ void KMyMoneyView::loadAncientCurrencies(void) // Source: http://www.focus.de/finanzen/news/malta-und-zypern_aid_66058.html loadAncientCurrency("MTL", i18n("Maltese Lira"), "MTL", TQDate(2008,1,1), MyMoneyMoney(429300,1000000), "EUR"); - loadAncientCurrency("CYP", i18n("Cyprus Pound"), TQString("C%1").tqarg(TQChar(0x00A3)), TQDate(2008,1,1), MyMoneyMoney(585274,1000000), "EUR"); + loadAncientCurrency("CYP", i18n("Cyprus Pound"), TQString("C%1").arg(TQChar(0x00A3)), TQDate(2008,1,1), MyMoneyMoney(585274,1000000), "EUR"); // Source: http://www.focus.de/finanzen/news/waehrungszone-slowakei-ist-neuer-euro-staat_aid_359025.html loadAncientCurrency("SKK", i18n("Slovak Koruna"), "SKK", TQDate(2008,12,31), MyMoneyMoney(1000,30126), "EUR"); @@ -1884,7 +1884,7 @@ void KMyMoneyView::fixLoanAccount_0(MyMoneyAccount acc) i18n("The account \"%1\" was previously created as loan account but some information " "is missing. The new loan wizard will be started to collect all relevant " "information. Please use a KMyMoney version >= 0.8.7 and < 0.9 to correct the problem." - ).tqarg(acc.name()), + ).arg(acc.name()), i18n("Account problem")); throw new MYMONEYEXCEPTION("Fix LoanAccount0 not supported anymore"); @@ -2189,7 +2189,7 @@ KMyMoneyViewBase* KMyMoneyView::addPage(const TQString& title, const TQString& i // ---------------------------------------------------------------------------- // QT Includes -#include +#include #include // ---------------------------------------------------------------------------- @@ -2240,7 +2240,7 @@ void KMyMoneyViewBase::addWidget(TQWidget* w) d->m_viewLayout->addWidget(w); } -TQVBoxLayout* KMyMoneyViewBase::tqlayout(void) const +TQVBoxLayout* KMyMoneyViewBase::layout(void) const { return d->m_viewLayout; } diff --git a/kmymoney2/views/kmymoneyview.h b/kmymoney2/views/kmymoneyview.h index 2c1cd38..d542110 100644 --- a/kmymoney2/views/kmymoneyview.h +++ b/kmymoney2/views/kmymoneyview.h @@ -605,7 +605,7 @@ public: virtual ~KMyMoneyViewBase(); void setTitle(const TQString& title); - TQVBoxLayout* tqlayout(void) const; + TQVBoxLayout* layout(void) const; void addWidget(TQWidget* w); /** diff --git a/kmymoney2/views/kpayeesview.cpp b/kmymoney2/views/kpayeesview.cpp index 6fa22ee..ef07db6 100644 --- a/kmymoney2/views/kpayeesview.cpp +++ b/kmymoney2/views/kpayeesview.cpp @@ -29,7 +29,7 @@ #include #include #include -#include +#include #include #include #include @@ -298,11 +298,11 @@ KTransactionListItem::~KTransactionListItem() { } -void KTransactionListItem::paintCell(TQPainter *p, const TQColorGroup &cg, int column, int width, int tqalignment) +void KTransactionListItem::paintCell(TQPainter *p, const TQColorGroup &cg, int column, int width, int alignment) { TQColorGroup _cg = cg; _cg.setColor(TQColorGroup::Base, backgroundColor()); - TQListViewItem::paintCell(p, _cg, column, width, tqalignment); + TQListViewItem::paintCell(p, _cg, column, width, alignment); } const TQColor KTransactionListItem::backgroundColor(void) @@ -323,9 +323,9 @@ KPayeesView::KPayeesView(TQWidget *parent, const char *name ) : m_inSelection(false) { // create the searchline widget - // and insert it into the existing tqlayout + // and insert it into the existing layout m_searchWidget = new KListViewSearchLineWidget(m_payeesList, this); - m_searchWidget->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed)); + m_searchWidget->setSizePolicy(TQSizePolicy(TQSizePolicy::Preferred, TQSizePolicy::Fixed)); KPayeesViewDeclLayout->insertWidget(0, m_searchWidget); m_splitter = new TQSplitter(this); @@ -333,7 +333,7 @@ KPayeesView::KPayeesView(TQWidget *parent, const char *name ) : m_tabWidget->reparent(m_splitter, TQPoint(0, 0), true); m_splitter->setResizeMode(m_tabWidget, TQSplitter::Stretch); m_splitter->setOpaqueResize(); - tqlayout10->addWidget(m_splitter); + layout10->addWidget(m_splitter); // use the size settings of the last run (if any) KConfig *config = KGlobal::config(); @@ -495,7 +495,7 @@ void KPayeesView::slotRenamePayee(TQListViewItem* p , int /* col */, const TQStr if (KMessageBox::questionYesNo(this, i18n("A payee with the name '%1' already exists. It is not advisable to have " "multiple payees with the same identification name. Are you sure you would like " - "to rename the payee?").tqarg(new_name)) != KMessageBox::Yes) + "to rename the payee?").arg(new_name)) != KMessageBox::Yes) { p->setText(0,m_payee.name()); return; @@ -521,7 +521,7 @@ void KPayeesView::slotRenamePayee(TQListViewItem* p , int /* col */, const TQStr } catch(MyMoneyException *e) { KMessageBox::detailedSorry(0, i18n("Unable to modify payee"), - (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").tqarg(e->line())); + (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").arg(e->line())); delete e; } } @@ -565,8 +565,8 @@ void KPayeesView::slotSelectPayee(void) // check if the content of a currently selected payee was modified // and ask to store the data if (m_updateButton->isEnabled()) { - if (KMessageBox::questionYesNo(this, TQString("%1").tqarg( - i18n("Do you want to save the changes for %1?").tqarg(m_newName)), + if (KMessageBox::questionYesNo(this, TQString("%1").arg( + i18n("Do you want to save the changes for %1?").arg(m_newName)), i18n("Save changes")) == KMessageBox::Yes) { m_inSelection = true; slotUpdatePayee(); @@ -664,7 +664,7 @@ void KPayeesView::showTransactions(void) m_transactionView->clear(); if(m_payee.id().isEmpty() || !m_tabWidget->isEnabled()) { - m_balanceLabel->setText(i18n("Balance: %1").tqarg(balance.formatMoney(MyMoneyFile::instance()->baseCurrency().smallestAccountFraction()))); + m_balanceLabel->setText(i18n("Balance: %1").arg(balance.formatMoney(MyMoneyFile::instance()->baseCurrency().smallestAccountFraction()))); return; } @@ -727,24 +727,24 @@ void KPayeesView::showTransactions(void) if(s.action() == MyMoneySplit::ActionAmortization) { if(acc.accountType() == MyMoneyAccount::Loan) { if(s.value().isPositive()) { - txt = i18n("Amortization of %1").tqarg(acc.name()); + txt = i18n("Amortization of %1").arg(acc.name()); } else { - txt = i18n("Payment to %1").tqarg(acc.name()); + txt = i18n("Payment to %1").arg(acc.name()); } } else if(acc.accountType() == MyMoneyAccount::AssetLoan) { if(s.value().isNegative()) { - txt = i18n("Amortization of %1").tqarg(acc.name()); + txt = i18n("Amortization of %1").arg(acc.name()); } else { - txt = i18n("Payment to %1").tqarg(acc.name()); + txt = i18n("Payment to %1").arg(acc.name()); } } else { - txt = i18n("Loan payment from %1").tqarg(acc.name()); + txt = i18n("Loan payment from %1").arg(acc.name()); } } else if (file->isTransfer(*t)) { if(!s.value().isNegative()) { - txt = i18n("Transfer to %1").tqarg(acc.name()); + txt = i18n("Transfer to %1").arg(acc.name()); } else { - txt = i18n("Transfer from %1").tqarg(acc.name()); + txt = i18n("Transfer from %1").arg(acc.name()); } } else if(t->splitCount() > 2) { txt = i18n("Split transaction (category replacement)", "Split transaction"); @@ -755,7 +755,7 @@ void KPayeesView::showTransactions(void) item->setText(2, txt); item->setText(3, s.value().formatMoney(acc.fraction())); } - m_balanceLabel->setText(i18n("Balance: %1").tqarg(balance.formatMoney(MyMoneyFile::instance()->baseCurrency().smallestAccountFraction()))); + m_balanceLabel->setText(i18n("Balance: %1").arg(balance.formatMoney(MyMoneyFile::instance()->baseCurrency().smallestAccountFraction()))); // Trick: it seems, that the initial sizing of the view does // not work correctly. At least, the columns do not get displayed @@ -872,7 +872,7 @@ void KPayeesView::slotUpdatePayee(void) } catch(MyMoneyException *e) { KMessageBox::detailedSorry(0, i18n("Unable to modify payee"), - (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").tqarg(e->line())); + (e->what() + " " + i18n("thrown in") + " " + e->file()+ ":%1").arg(e->line())); delete e; } } @@ -913,7 +913,7 @@ void KPayeesView::show(void) m_needReload = false; } - // fixup the tqlayout + // fixup the layout TQTimer::singleShot(0, this, TQT_SLOT(rearrange())); // don't forget base class implementation diff --git a/kmymoney2/views/kpayeesview.h b/kmymoney2/views/kpayeesview.h index 95be179..adbd708 100644 --- a/kmymoney2/views/kpayeesview.h +++ b/kmymoney2/views/kpayeesview.h @@ -185,7 +185,7 @@ public: /** * use my own paint method */ - void paintCell(TQPainter *p, const TQColorGroup &cg, int column, int width, int tqalignment); + void paintCell(TQPainter *p, const TQColorGroup &cg, int column, int width, int alignment); /** * use my own backgroundColor method diff --git a/kmymoney2/views/kpayeesviewdecl.ui b/kmymoney2/views/kpayeesviewdecl.ui index 05e8e09..8d3a7b8 100644 --- a/kmymoney2/views/kpayeesviewdecl.ui +++ b/kmymoney2/views/kpayeesviewdecl.ui @@ -21,7 +21,7 @@
- tqlayout10 + layout10 @@ -168,7 +168,7 @@ Balance: - + AlignVCenter|AlignRight @@ -218,7 +218,7 @@ 0
- + 90 0 @@ -240,7 +240,7 @@ 0 - + 90 0 @@ -262,7 +262,7 @@ 0 - + 90 0 @@ -284,7 +284,7 @@ 0 - + 90 0 @@ -293,7 +293,7 @@ Notes - + AlignTop|AlignLeft
@@ -350,7 +350,7 @@ 0
- + 90 0 @@ -359,7 +359,7 @@ Address: - + AlignTop|AlignLeft
@@ -375,7 +375,7 @@ Expanding - + 21 20 @@ -516,7 +516,7 @@ Expanding - + 20 20 @@ -547,7 +547,7 @@ new transactions with this payee
- tqlayout5 + layout5 @@ -586,7 +586,7 @@ new transactions with this payee Expanding - + 20 31 @@ -600,7 +600,7 @@ new transactions with this payee - tqlayout10 + layout10 @@ -632,7 +632,7 @@ new transactions with this payee Expanding - + 260 21 diff --git a/kmymoney2/views/kreportsview.cpp b/kmymoney2/views/kreportsview.cpp index 8fdcbd7..9a942e4 100755 --- a/kmymoney2/views/kreportsview.cpp +++ b/kmymoney2/views/kreportsview.cpp @@ -30,11 +30,11 @@ // ---------------------------------------------------------------------------- // QT Includes -#include +#include #include #include #include -#include +#include #include #include #include @@ -91,7 +91,7 @@ KReportsView::KReportTab::KReportTab(KTabWidget* parent, const MyMoneyReport& re m_part( new KHTMLPart( this, "reporttabpart" ) ), m_chartView( new KReportChartView( this, "reportchart" ) ), m_control( new kMyMoneyReportControlDecl( this, "reportcontrol" ) ), - m_layout( new TQVBoxLayout( this, 11, 6, "reporttabtqlayout" ) ), + m_layout( new TQVBoxLayout( this, 11, 6, "reporttablayout" ) ), m_report( report ), m_deleteMe( false ), m_showingChart( false ), @@ -105,7 +105,7 @@ KReportsView::KReportTab::KReportTab(KTabWidget* parent, const MyMoneyReport& re m_control->buttonChart->hide(); } - m_chartView->tqsetSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ); + m_chartView->setSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Expanding ); m_chartView->hide(); m_layout->addWidget( m_control ); //, 0, TQt::AlignTop ); m_layout->addWidget( m_part->view() ); @@ -141,7 +141,7 @@ void KReportsView::KReportTab::copyToClipboard(void) { TQTextDrag* pdrag = new TQTextDrag( createTable() ); pdrag->setSubtype("html"); - TQApplication::tqclipboard()->setData(pdrag); + TQApplication::clipboard()->setData(pdrag); } void KReportsView::KReportTab::saveAs( const TQString& filename, bool includeCSS ) @@ -156,7 +156,7 @@ void KReportsView::KReportTab::saveAs( const TQString& filename, bool includeCSS else { TQTextStream stream(&file); - TQRegExp exp(TQString("(.*)(()(.*)").tqarg(KGlobal::locale()->encoding())); + TQRegExp exp(TQString("(.*)(()(.*)").arg(KGlobal::locale()->encoding())); TQString table = createTable(); if(exp.search(table) != -1 && includeCSS) { TQFile cssFile(exp.cap(3)); @@ -234,13 +234,13 @@ TQString KReportsView::KReportTab::createTable(const TQString& links) { TQString filename; if(!MyMoneyFile::instance()->value("reportstylesheet").isEmpty()) - filename = KGlobal::dirs()->findResource("appdata", TQString("html/%1").tqarg(MyMoneyFile::instance()->value("reportstylesheet"))); + filename = KGlobal::dirs()->findResource("appdata", TQString("html/%1").arg(MyMoneyFile::instance()->value("reportstylesheet"))); if(filename.isEmpty()) filename = KGlobal::dirs()->findResource("appdata", "html/kmymoney2.css"); TQString header = TQString("\n") + - TQString("").tqarg(filename); + TQString("").arg(filename); - header += TQString("").tqarg(KGlobal::locale()->encoding()); + header += TQString("").arg(KGlobal::locale()->encoding()); header += KMyMoneyUtils::variableCSS(); header += "\n"; @@ -260,7 +260,7 @@ TQString KReportsView::KReportTab::createTable(const TQString& links) { kdDebug(2) << "KReportsView::KReportTab::createTable(): ERROR " << e->what() << endl; - TQString error = TQString(i18n("There was an error creating your report: \"%1\".\nPlease report this error to the developer's list: kmymoney2-developer@lists.sourceforge.net")).tqarg(e->what()); + TQString error = TQString(i18n("There was an error creating your report: \"%1\".\nPlease report this error to the developer's list: kmymoney2-developer@lists.sourceforge.net")).arg(e->what()); KMessageBox::error(this, error, i18n("Critical Error")); @@ -394,7 +394,7 @@ KReportsView::KReportGroupListItem::KReportGroupListItem(KListView* parent, cons void KReportsView::KReportGroupListItem::setNr(const int nr) { m_nr = nr; - setText(0, TQString("%1. %2").tqarg(nr).tqarg(m_name)); + setText(0, TQString("%1. %2").arg(nr).arg(m_name)); } void KReportsView::loadView(void) @@ -583,8 +583,8 @@ void KReportsView::slotSaveView(void) // adjust to our local needs (filetypes etc.) and // enhanced to show the m_saveEncrypted combo box KFileDialog dlg( ":kmymoney-export", - TQString("%1|%2\n").tqarg("*.csv").tqarg(i18n("CSV (Filefilter)", "CSV files")) + - TQString("%1|%2\n").tqarg("*.html").tqarg(i18n("HTML (Filefilter)", "HTML files")), + TQString("%1|%2\n").arg("*.csv").arg(i18n("CSV (Filefilter)", "CSV files")) + + TQString("%1|%2\n").arg("*.html").arg(i18n("HTML (Filefilter)", "HTML files")), this, "filedialog", true, vbox); connect(&dlg, TQT_SIGNAL(filterChanged(const TQString&)), this, TQT_SLOT(slotSaveFilterChanged(const TQString&))); @@ -657,7 +657,7 @@ void KReportsView::slotDuplicate(void) if(tab) { MyMoneyReport dupe = tab->report(); - dupe.setName( TQString(i18n("Copy of %1")).tqarg(dupe.name()) ); + dupe.setName( TQString(i18n("Copy of %1")).arg(dupe.name()) ); if ( dupe.comment() == i18n("Default Report") ) dupe.setComment( i18n("Custom Report") ); dupe.clearId(); @@ -688,7 +688,7 @@ void KReportsView::slotDelete(void) MyMoneyReport report = tab->report(); if ( ! report.id().isEmpty() ) { - if ( KMessageBox::Continue == KMessageBox::warningContinueCancel(this, TQString("")+i18n("Are you sure you want to delete report %1? There is no way to recover it!").tqarg(report.name())+TQString(""), i18n("Delete Report?"))) + if ( KMessageBox::Continue == KMessageBox::warningContinueCancel(this, TQString("")+i18n("Are you sure you want to delete report %1? There is no way to recover it!").arg(report.name())+TQString(""), i18n("Delete Report?"))) { // close the tab and then remove the report so that it is not // generated again during the following loadView() call @@ -700,7 +700,7 @@ void KReportsView::slotDelete(void) } } else - KMessageBox::information(this, TQString("")+i18n("Sorry, %1 is a default report. You may not delete it.").tqarg(report.name())+TQString(""), i18n("Delete Report?")); + KMessageBox::information(this, TQString("")+i18n("Sorry, %1 is a default report. You may not delete it.").arg(report.name())+TQString(""), i18n("Delete Report?")); } } @@ -1350,7 +1350,7 @@ void KReportsView::defaultReports(TQValueList& groups) list.back().setShowingRowTotals(true); list.back().setBudget("Any",true); // in case we're in January, we show the last year - if(TQDate::tqcurrentDate().month() == 1) { + if(TQDate::currentDate().month() == 1) { list.back().setDateFilter(MyMoneyTransactionFilter::lastYear); } diff --git a/kmymoney2/views/kscheduledlistitem.cpp b/kmymoney2/views/kscheduledlistitem.cpp index 9983c7d..b055b25 100644 --- a/kmymoney2/views/kscheduledlistitem.cpp +++ b/kmymoney2/views/kscheduledlistitem.cpp @@ -130,7 +130,7 @@ KScheduledListItem::KScheduledListItem(KScheduledListItem *parent, const MyMoney else setText(2, "---"); m_amount = split.shares().abs(); - setText(3, TQString("%1 ").tqarg(m_amount.formatMoney(acc, currency))); + setText(3, TQString("%1 ").arg(m_amount.formatMoney(acc, currency))); // Do the real next payment like ms-money etc if (schedule.isFinished()) { diff --git a/kmymoney2/views/kscheduledlistitem.h b/kmymoney2/views/kscheduledlistitem.h index 44d2af8..61ef12d 100644 --- a/kmymoney2/views/kscheduledlistitem.h +++ b/kmymoney2/views/kscheduledlistitem.h @@ -66,7 +66,7 @@ public: KScheduledListItem(KListView *parent, const TQString& description, const TQPixmap& pixmap = TQPixmap(), const TQString& sortKey = TQString()); /** - * This constructor is used to create a child of one of the tqchildren + * This constructor is used to create a child of one of the children * created by the above method. * * This child describes a schedule and represents the data in schedule. diff --git a/kmymoney2/views/kscheduledview.cpp b/kmymoney2/views/kscheduledview.cpp index 74ea25b..e23ba54 100644 --- a/kmymoney2/views/kscheduledview.cpp +++ b/kmymoney2/views/kscheduledview.cpp @@ -27,7 +27,7 @@ #include #include #include -#include +#include #include // ---------------------------------------------------------------------------- @@ -63,7 +63,7 @@ KScheduledView::KScheduledView(TQWidget *parent, const char *name ) : m_openLoans(true) { // create the searchline widget - // and insert it into the existing tqlayout + // and insert it into the existing layout m_searchWidget = new KListViewSearchLineWidget(m_qlistviewScheduled, m_listTab); m_listTabLayout->insertWidget(0, m_searchWidget); @@ -240,7 +240,7 @@ void KScheduledView::refresh(bool full, const TQString& schedId) TQTimer::singleShot(10, this, TQT_SLOT(slotTimerDone())); m_qlistviewScheduled->update(); - // force tqrepaint in case the filter is set + // force repaint in case the filter is set m_searchWidget->searchLine()->updateSearch(TQString()); if (m_openBills) @@ -273,7 +273,7 @@ void KScheduledView::slotTimerDone(void) m_qlistviewScheduled->ensureItemVisible(item); } - // force a tqrepaint of all items to update the branches + // force a repaint of all items to update the branches for(item = m_qlistviewScheduled->firstChild(); item != 0; item = item->itemBelow()) { m_qlistviewScheduled->repaintItem(item); } diff --git a/kmymoney2/views/kscheduledviewdecl.ui b/kmymoney2/views/kscheduledviewdecl.ui index f101b52..925dc19 100644 --- a/kmymoney2/views/kscheduledviewdecl.ui +++ b/kmymoney2/views/kscheduledviewdecl.ui @@ -21,7 +21,7 @@ - tqlayout2 + layout2 @@ -45,7 +45,7 @@ Expanding - + 80 20 -- cgit v1.2.1