diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-16 09:56:17 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-16 09:56:17 -0600 |
commit | 1f9d00360b9018301630ce062d7dda0c6583edfb (patch) | |
tree | 1013b917f9a8ad41ed928d62250e9bfe1ed91414 /kmymoney2/widgets/transaction.cpp | |
parent | 252fce5a2a5384702fbcc1c9987284d7bd2e6943 (diff) | |
download | kmymoney-1f9d00360b9018301630ce062d7dda0c6583edfb.tar.gz kmymoney-1f9d00360b9018301630ce062d7dda0c6583edfb.zip |
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit 252fce5a2a5384702fbcc1c9987284d7bd2e6943.
Diffstat (limited to 'kmymoney2/widgets/transaction.cpp')
-rw-r--r-- | kmymoney2/widgets/transaction.cpp | 104 |
1 files changed, 52 insertions, 52 deletions
diff --git a/kmymoney2/widgets/transaction.cpp b/kmymoney2/widgets/transaction.cpp index b4ac7cd..5811a8c 100644 --- a/kmymoney2/widgets/transaction.cpp +++ b/kmymoney2/widgets/transaction.cpp @@ -243,7 +243,7 @@ void Transaction::markAsErronous(TQPainter* painter, int /* row */, int /* col * bool Transaction::paintRegisterCellSetup(TQPainter* painter, int& row, int& col, TQRect& cellRect, TQRect& textRect, TQColorGroup& cg, TQBrush& brush) { if(m_reducedIntensity) - cg = m_parent->palette().disabled(); + cg = m_parent->tqpalette().disabled(); if(m_alternate) cg.setColor(TQColorGroup::Base, KMyMoneyGlobalSettings::listColor()); @@ -508,7 +508,7 @@ int Transaction::formRowHeight(void) const kMyMoneyDateInput dateInput; KMyMoneyCategory category(0,0,true); - return TQMAX(dateInput.sizeHint().height(), category.sizeHint().height()); + return TQMAX(dateInput.tqsizeHint().height(), category.tqsizeHint().height()); } return m_formRowHeight; } @@ -598,7 +598,7 @@ void Transaction::setupRegisterPalette(TQMap<TQString, TQWidget*>& editWidgets) setupPalette(palette, editWidgets); } -TQWidget* Transaction::focusWidget(TQWidget* w) const +TQWidget* Transaction::tqfocusWidget(TQWidget* w) const { if(w) { while(w->focusProxy()) @@ -664,10 +664,10 @@ bool Transaction::maybeTip(const TQPoint& cpos, int row, int col, TQRect& r, TQS // qDebug("p is in r = %d", r.contains(cpos)); if(r.contains(cpos) && m_erronous) { if(m_transaction.splits().count() < 2) { - msg = TQString("<qt>%1</qt>").arg(i18n("Transaction is missing a category assignment.")); + msg = TQString("<qt>%1</qt>").tqarg(i18n("Transaction is missing a category assignment.")); } else { const MyMoneySecurity& sec = MyMoneyFile::instance()->security(m_account.currencyId()); - msg = TQString("<qt>%1</qt>").arg(i18n("The transaction has a missing assignment of <b>%1</b>.").arg(m_transaction.splitSum().abs().formatMoney(m_account, sec))); + msg = TQString("<qt>%1</qt>").tqarg(i18n("The transaction has a missing assignment of <b>%1</b>.").tqarg(m_transaction.splitSum().abs().formatMoney(m_account, sec))); } return true; } @@ -690,9 +690,9 @@ bool Transaction::maybeTip(const TQPoint& cpos, int row, int col, TQRect& r, TQS TQString category = file->accountToCategory(acc.id()); TQString amount = ((*it_s).value() * factor).formatMoney(acc, sec); - txt += TQString("<tr><td><nobr>%1</nobr></td><td align=right><nobr>%2</nobr></td></tr>").arg(category, amount); + txt += TQString("<tr><td><nobr>%1</nobr></td><td align=right><nobr>%2</nobr></td></tr>").tqarg(category, amount); } - msg = TQString("<table>%1</table>").arg(txt); + msg = TQString("<table>%1</table>").tqarg(txt); return true; } @@ -880,7 +880,7 @@ StdTransaction::StdTransaction(Register *parent, const MyMoneyTransaction& trans addon = i18n("Yield"); } if(!addon.isEmpty()) { - m_payee += TQString(" (%1)").arg(addon); + m_payee += TQString(" (%1)").tqarg(addon); } m_payeeHeader = i18n("Activity"); m_category = i18n("Investment transaction"); @@ -1253,34 +1253,34 @@ void StdTransaction::tabOrderInForm(TQWidgetList& tabOrderWidgets) const TQWidget* w; while(it_s != taborder.constEnd()) { if(*it_s == "account") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(0, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(0, ValueColumn1))); } else if(*it_s == "cashflow") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(1, LabelColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(1, LabelColumn1))); } else if(*it_s == "payee") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(1, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(1, ValueColumn1))); } else if(*it_s == "category") { // make sure to have the category field and the split button as seperate tab order widgets // ok, we have to have some internal knowledge about the KMyMoneyCategory object, but // it's one of our own widgets, so we actually don't care. Just make sure, that we don't // go haywire when someone changes the KMyMoneyCategory object ... w = m_form->cellWidget(2, ValueColumn1); - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); } else if(*it_s == "memo") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(3, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(3, ValueColumn1))); } else if(*it_s == "number") { if(haveNumberField()) { - if((w = focusWidget(m_form->cellWidget(1, ValueColumn2)))) + if((w = tqfocusWidget(m_form->cellWidget(1, ValueColumn2)))) tabOrderWidgets.append(w); } } else if(*it_s == "date") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(2, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(2, ValueColumn2))); } else if(*it_s == "amount") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(3, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(3, ValueColumn2))); } else if(*it_s == "state") { - tabOrderWidgets.append(focusWidget(m_form->cellWidget(5, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(5, ValueColumn2))); } ++it_s; } @@ -1315,31 +1315,31 @@ void StdTransaction::tabOrderInRegister(TQWidgetList& tabOrderWidgets) const while(it_s != taborder.constEnd()) { if(*it_s == "number") { if(haveNumberField()) { - if((w = focusWidget(m_parent->cellWidget(m_startRow + 0, NumberColumn)))) + if((w = tqfocusWidget(m_parent->cellWidget(m_startRow + 0, NumberColumn)))) tabOrderWidgets.append(w); } } else if(*it_s == "date") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, DateColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, DateColumn))); } else if(*it_s == "payee") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, DetailColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, DetailColumn))); } else if(*it_s == "category") { // make sure to have the category field and the split button as seperate tab order widgets // ok, we have to have some internal knowledge about the KMyMoneyCategory object, but // it's one of our own widgets, so we actually don't care. Just make sure, that we don't // go haywire when someone changes the KMyMoneyCategory object ... w = m_parent->cellWidget(m_startRow + 1, DetailColumn); - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); } else if(*it_s == "memo") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 2, DetailColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 2, DetailColumn))); } else if(*it_s == "payment") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, PaymentColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, PaymentColumn))); } else if(*it_s == "deposit") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, DepositColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, DepositColumn))); } else if(*it_s == "state") { - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 1, DateColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 1, DateColumn))); } ++it_s; } @@ -1533,7 +1533,7 @@ bool InvestTransaction::formCellText(TQString& txt, int& align, int row, int col if((fieldEditable = haveShares()) == true) { txt = m_split.shares().abs().formatMoney("", MyMoneyMoney::denomToPrec(m_security.smallestAccountFraction())); } else if(haveSplitRatio()) { - txt = TQString("1 / %1").arg(m_split.shares().abs().formatMoney("", -1)); + txt = TQString("1 / %1").tqarg(m_split.shares().abs().formatMoney("", -1)); } break; } @@ -1712,7 +1712,7 @@ void InvestTransaction::registerCellText(TQString& txt, int& align, int row, int if(haveShares()) txt = m_split.shares().abs().formatMoney("", MyMoneyMoney::denomToPrec(m_security.smallestAccountFraction())); else if(haveSplitRatio()) { - txt = TQString("1 / %1").arg(m_split.shares().abs().formatMoney("", -1)); + txt = TQString("1 / %1").tqarg(m_split.shares().abs().formatMoney("", -1)); } break; @@ -1929,54 +1929,54 @@ void InvestTransaction::arrangeWidgetsInForm(TQMap<TQString, TQWidget*>& editWid void InvestTransaction::tabOrderInForm(TQWidgetList& tabOrderWidgets) const { // activity - tabOrderWidgets.append(focusWidget(m_form->cellWidget(0, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(0, ValueColumn1))); // date - tabOrderWidgets.append(focusWidget(m_form->cellWidget(0, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(0, ValueColumn2))); // security - tabOrderWidgets.append(focusWidget(m_form->cellWidget(1, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(1, ValueColumn1))); // shares - tabOrderWidgets.append(focusWidget(m_form->cellWidget(1, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(1, ValueColumn2))); // account - tabOrderWidgets.append(focusWidget(m_form->cellWidget(2, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(2, ValueColumn1))); // price - tabOrderWidgets.append(focusWidget(m_form->cellWidget(2, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(2, ValueColumn2))); // make sure to have the fee category field and the split button as seperate tab order widgets // ok, we have to have some internal knowledge about the KMyMoneyCategory object, but // it's one of our own widgets, so we actually don't care. Just make sure, that we don't // go haywire when someone changes the KMyMoneyCategory object ... TQWidget* w = m_form->cellWidget(3, ValueColumn1); - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); // fee amount - tabOrderWidgets.append(focusWidget(m_form->cellWidget(3, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(3, ValueColumn2))); // the same applies for the interest categories w = m_form->cellWidget(4, ValueColumn1); - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); // interest amount - tabOrderWidgets.append(focusWidget(m_form->cellWidget(4, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(4, ValueColumn2))); // memo - tabOrderWidgets.append(focusWidget(m_form->cellWidget(5, ValueColumn1))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(5, ValueColumn1))); // total - tabOrderWidgets.append(focusWidget(m_form->cellWidget(5, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(5, ValueColumn2))); // state - tabOrderWidgets.append(focusWidget(m_form->cellWidget(6, ValueColumn2))); + tabOrderWidgets.append(tqfocusWidget(m_form->cellWidget(6, ValueColumn2))); } void InvestTransaction::arrangeWidgetsInRegister(TQMap<TQString, TQWidget*>& editWidgets) @@ -2009,45 +2009,45 @@ void InvestTransaction::tabOrderInRegister(TQWidgetList& tabOrderWidgets) const TQWidget* w; // date - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, DateColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, DateColumn))); // security - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, SecurityColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, SecurityColumn))); // activity - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, DetailColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, DetailColumn))); // shares - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, QuantityColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, QuantityColumn))); // price - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 0, PriceColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 0, PriceColumn))); // asset account - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 1, DetailColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 1, DetailColumn))); // make sure to have the category fields and the split button as seperate tab order widgets // ok, we have to have some internal knowledge about the KMyMoneyCategory object, but // it's one of our own widgets, so we actually don't care. Just make sure, that we don't // go haywire when someone changes the KMyMoneyCategory object ... w = m_parent->cellWidget(m_startRow + 2, DetailColumn); // interest account - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); // interest amount - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 2, QuantityColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 2, QuantityColumn))); w = m_parent->cellWidget(m_startRow + 3, DetailColumn); // fee account - tabOrderWidgets.append(focusWidget(w)); + tabOrderWidgets.append(tqfocusWidget(w)); w = dynamic_cast<TQWidget*>(w->child("splitButton")); if(w) tabOrderWidgets.append(w); // fee amount - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 3, QuantityColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 3, QuantityColumn))); // memo - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 4, DetailColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 4, DetailColumn))); // status - tabOrderWidgets.append(focusWidget(m_parent->cellWidget(m_startRow + 1, DateColumn))); + tabOrderWidgets.append(tqfocusWidget(m_parent->cellWidget(m_startRow + 1, DateColumn))); } int InvestTransaction::numRowsRegister(bool expanded) const |