Replace the use of the old API TQString::data().

The definition of -UTQT_NO_COMPAT is no longer needed.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
(cherry picked from commit eeae53f59d)
r14.0.x
Slávek Banko 3 years ago
parent febacdee5b
commit a553069ad0
No known key found for this signature in database
GPG Key ID: 608F5293A04BE668

@ -66,7 +66,7 @@ include( ConfigureChecks.cmake )
###### global compiler settings ###### global compiler settings
add_definitions( -DHAVE_CONFIG_H -UQT_NO_ASCII_CAST -UQT_NO_COMPAT -UQT_NO_STL ) add_definitions( -DHAVE_CONFIG_H -UQT_NO_ASCII_CAST -UQT_NO_STL )
set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TQT_CXX_FLAGS}" ) set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TQT_CXX_FLAGS}" )
set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined" ) set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined" )

@ -236,9 +236,9 @@ TQString GncObject::hide (TQString data, unsigned int anonClass) {
// dump current object data values // only called if gncdebug set // dump current object data values // only called if gncdebug set
void GncObject::debugDump () { void GncObject::debugDump () {
uint i; uint i;
tqDebug ("Object %s", m_elementName.latin1()); tqDebug(TQString("Object %1").arg(m_elementName));
for (i = 0; i < m_dataElementListCount; i++) { for (i = 0; i < m_dataElementListCount; i++) {
tqDebug ("%s = %s", m_dataElementList[i].latin1(), m_v.at(i)->latin1()); tqDebug(TQString("%1 = %2").arg(m_dataElementList[i]).arg(*(m_v.at(i))));
} }
} }
//***************************************************************** //*****************************************************************
@ -409,7 +409,7 @@ void GncCountData::terminate () {
if (i != 0) { if (i != 0) {
if (m_countType == "budget") pMain->setBudgetsFound(true); if (m_countType == "budget") pMain->setBudgetsFound(true);
else if (m_countType.left(7) == "gnc:Gnc") pMain->setSmallBusinessFound(true); else if (m_countType.left(7) == "gnc:Gnc") pMain->setSmallBusinessFound(true);
else if (pMain->xmldebug) tqDebug ("Unknown count type %s", m_countType.latin1()); else if (pMain->xmldebug) tqDebug(TQString("Unknown count type %1").arg(m_countType));
} }
return ; return ;
} }
@ -887,7 +887,7 @@ bool XmlReader::startDocument() {
bool XmlReader::startElement (const TQString&, const TQString&, const TQString& elName , bool XmlReader::startElement (const TQString&, const TQString&, const TQString& elName ,
const TQXmlAttributes& elAttrs) { const TQXmlAttributes& elAttrs) {
try { try {
if (pMain->gncdebug) tqDebug ("XML start - %s", elName.latin1()); if (pMain->gncdebug) tqDebug(TQString("XML start - %1").arg(elName));
#ifdef _GNCFILEANON #ifdef _GNCFILEANON
int i; int i;
TQString spaces; TQString spaces;
@ -938,9 +938,9 @@ bool XmlReader::startElement (const TQString&, const TQString&, const TQString&
#ifndef _GNCFILEANON #ifndef _GNCFILEANON
// we can't pass on exceptions here coz the XML reader won't catch them and we just abort // we can't pass on exceptions here coz the XML reader won't catch them and we just abort
KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE); KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE);
tqFatal ("%s", e->what().latin1()); tqFatal(e->what());
#else #else
tqFatal ("%s", e->latin1()); tqFatal(e);
#endif // _GNCFILEANON #endif // _GNCFILEANON
} }
return true; // to keep compiler happy return true; // to keep compiler happy
@ -948,7 +948,7 @@ bool XmlReader::startElement (const TQString&, const TQString&, const TQString&
bool XmlReader::endElement( const TQString&, const TQString&, const TQString&elName ) { bool XmlReader::endElement( const TQString&, const TQString&, const TQString&elName ) {
try { try {
if (pMain->xmldebug) tqDebug ("XML end - %s", elName.latin1()); if (pMain->xmldebug) tqDebug(TQString("XML end - %1").arg(elName));
#ifdef _GNCFILEANON #ifdef _GNCFILEANON
TQString spaces; TQString spaces;
switch (lastType) { switch (lastType) {
@ -973,9 +973,9 @@ bool XmlReader::endElement( const TQString&, const TQString&, const TQString&elN
#ifndef _GNCFILEANON #ifndef _GNCFILEANON
// we can't pass on exceptions here coz the XML reader won't catch them and we just abort // we can't pass on exceptions here coz the XML reader won't catch them and we just abort
KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE); KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE);
tqFatal ("%s", e->what().latin1()); tqFatal(e->what());
#else #else
tqFatal ("%s", e->latin1()); tqFatal(e);
#endif // _GNCFILEANON #endif // _GNCFILEANON
} }
return (true); // to keep compiler happy return (true); // to keep compiler happy
@ -985,7 +985,7 @@ bool XmlReader::characters (const TQString &data) {
if (pMain->xmldebug) tqDebug ("XML Data received - %d bytes", data.length()); if (pMain->xmldebug) tqDebug ("XML Data received - %d bytes", data.length());
TQString pData = data.stripWhiteSpace(); // data may contain line feeds and indentation spaces TQString pData = data.stripWhiteSpace(); // data may contain line feeds and indentation spaces
if (!pData.isEmpty()) { if (!pData.isEmpty()) {
if (pMain->developerDebug) tqDebug ("XML Data - %s", pData.latin1()); if (pMain->developerDebug) tqDebug(TQString("XML Data - %1").arg(pData));
m_co->storeData (pData); //go store it m_co->storeData (pData); //go store it
#ifdef _GNCFILEANON #ifdef _GNCFILEANON
TQString anonData = m_co->getData (); TQString anonData = m_co->getData ();
@ -1063,7 +1063,7 @@ void MyMoneyGncReader::readFile(TQIODevice* pDevice, IMyMoneySerialize* storage)
ft.commit(); ft.commit();
} catch (MyMoneyException *e) { } catch (MyMoneyException *e) {
KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE); KMessageBox::error(0, i18n("Import failed:\n\n%1").arg(e->what()), PACKAGE);
tqFatal ("%s", e->what().latin1()); tqFatal(e->what());
} // end catch } // end catch
signalProgress (0, 1, i18n("Import complete")); // switch off progress bar signalProgress (0, 1, i18n("Import complete")); // switch off progress bar
delete m_xr; delete m_xr;
@ -1085,7 +1085,7 @@ void MyMoneyGncReader::readFile(TQString in, TQString out) {
try { try {
m_xr->processFile (&pDevice); m_xr->processFile (&pDevice);
} catch (MyMoneyException *e) { } catch (MyMoneyException *e) {
tqFatal ("%s", e->latin1()); tqFatal(e);
} // end catch } // end catch
delete m_xr; delete m_xr;
pDevice.close(); pDevice.close();
@ -1149,7 +1149,7 @@ void MyMoneyGncReader::convertCommodity (const GncCommodity *gcm) {
m_storage->addSecurity(equ); m_storage->addSecurity(equ);
//assign the gnucash id as the key into the map to find our id //assign the gnucash id as the key into the map to find our id
if (gncdebug) tqDebug ("mapping, key = %s, id = %s", gcm->id().latin1(), equ.id().data()); if (gncdebug) tqDebug(TQString("mapping, key = %1, id = %2").arg(gcm->id()).arg(equ.id()));
m_mapEquities[gcm->id().utf8()] = equ.id(); m_mapEquities[gcm->id().utf8()] = equ.id();
} }
signalProgress (++m_commodityCount, 0); signalProgress (++m_commodityCount, 0);
@ -1168,8 +1168,8 @@ void MyMoneyGncReader::convertPrice (const GncPrice *gpr) {
m_storage->addPrice (exchangeRate); m_storage->addPrice (exchangeRate);
} else { } else {
MyMoneySecurity e = m_storage->security(m_mapEquities[gpr->commodity()->id().utf8()]); MyMoneySecurity e = m_storage->security(m_mapEquities[gpr->commodity()->id().utf8()]);
if (gncdebug) tqDebug ("Searching map, key = %s, found id = %s", if (gncdebug) tqDebug(TQString("Searching map, key = %1, found id = %2").
gpr->commodity()->id().latin1(), e.id().data()); arg(gpr->commodity()->id()).arg(e.id()));
e.setTradingCurrency (gpr->currency()->id().utf8()); e.setTradingCurrency (gpr->currency()->id().utf8());
MyMoneyPrice stockPrice(e.id(), gpr->currency()->id().utf8(), gpr->priceDate(), rate, i18n("Imported History")); MyMoneyPrice stockPrice(e.id(), gpr->currency()->id().utf8(), gpr->priceDate(), rate, i18n("Imported History"));
m_storage->addPrice (stockPrice); m_storage->addPrice (stockPrice);
@ -1272,12 +1272,12 @@ void MyMoneyGncReader::convertAccount (const GncAccount* gac) {
m_stockList.append (gac->id()); m_stockList.append (gac->id());
// set the equity type // set the equity type
MyMoneySecurity e = m_storage->security (m_mapEquities[gac->commodity()->id().utf8()]); MyMoneySecurity e = m_storage->security (m_mapEquities[gac->commodity()->id().utf8()]);
if (gncdebug) tqDebug ("Acct equity search, key = %s, found id = %s", if (gncdebug) tqDebug(TQString("Acct equity search, key = %1, found id = %2").
gac->commodity()->id().latin1(), e.id().data()); arg(gac->commodity()->id()).arg(e.id()));
acc.setCurrencyId (e.id()); // actually, the security id acc.setCurrencyId (e.id()); // actually, the security id
if ("MUTUAL" == gac->type()) { if ("MUTUAL" == gac->type()) {
e.setSecurityType (MyMoneySecurity::SECURITY_MUTUALFUND); e.setSecurityType (MyMoneySecurity::SECURITY_MUTUALFUND);
if (gncdebug) tqDebug ("Setting %s to mutual", e.name().latin1()); if (gncdebug) tqDebug(TQString("Setting %1 to mutual").arg(e.name()));
m_storage->modifySecurity (e); m_storage->modifySecurity (e);
} }
// See if he wants online quotes for this account // See if he wants online quotes for this account
@ -1313,9 +1313,10 @@ void MyMoneyGncReader::convertAccount (const GncAccount* gac) {
m_storage->addAccount(acc); m_storage->addAccount(acc);
m_mapIds[gac->id().utf8()] = acc.id(); // to link gnucash id to ours for tx posting m_mapIds[gac->id().utf8()] = acc.id(); // to link gnucash id to ours for tx posting
if (gncdebug) tqDebug("Gnucash account %s has id of %s, type of %s, parent is %s", if (gncdebug) tqDebug(TQString("Gnucash account %1 has id of %2, type of %3, parent is %4").
gac->id().latin1(), acc.id().data(), arg(gac->id()).arg(acc.id()).
KMyMoneyUtils::accountTypeToString(acc.accountType()).latin1(), acc.parentAccountId().data()); arg(KMyMoneyUtils::accountTypeToString(acc.accountType())).
arg(acc.parentAccountId()));
signalProgress (++m_accountCount, 0); signalProgress (++m_accountCount, 0);
return ; return ;
@ -1403,9 +1404,9 @@ void MyMoneyGncReader::convertSplit (const GncSplit *gsp) {
splitAccount = m_storage->account (kmmAccountId); splitAccount = m_storage->account (kmmAccountId);
// print some data so we can maybe identify this split later // print some data so we can maybe identify this split later
// TODO : prints personal data // TODO : prints personal data
//if (gncdebug) tqDebug ("Split data - gncid %s, kmmid %s, memo %s, value %s, recon state %s", //if (gncdebug) tqDebug(TQString("Split data - gncid %1, kmmid %2, memo %3, value %4, recon state %5").
// gsp->acct().latin1(), kmmAccountId.data(), gsp->memo().latin1(), gsp->value().latin1(), // arg(gsp->acct()).arg(kmmAccountId).arg(gsp->memo()).arg(gsp->value()).
// gsp->recon().latin1()); // arg(gsp->recon()));
// payee id // payee id
split.setPayeeId (m_txPayeeId.utf8()); split.setPayeeId (m_txPayeeId.utf8());
// reconciled state and date // reconciled state and date
@ -1467,9 +1468,9 @@ void MyMoneyGncReader::convertSplit (const GncSplit *gsp) {
// we can't use m_storage->security coz security list is not built yet // we can't use m_storage->security coz security list is not built yet
m_storage->currency(m_txCommodity); // will throw exception if not currency m_storage->currency(m_txCommodity); // will throw exception if not currency
e.setTradingCurrency (m_txCommodity); e.setTradingCurrency (m_txCommodity);
if (gncdebug) tqDebug ("added price for %s, %s date %s", if (gncdebug) tqDebug(TQString("added price for %1, %2 date %3").
e.name().latin1(), newPrice.toString().latin1(), arg(e.name()).arg(newPrice.toString()).
TQString(m_txDatePosted.toString(Qt::ISODate)).latin1()); arg(m_txDatePosted.toString(Qt::ISODate)));
m_storage->modifySecurity(e); m_storage->modifySecurity(e);
MyMoneyPrice dealPrice (e.id(), m_txCommodity, m_txDatePosted, newPrice, i18n("Imported Transaction")); MyMoneyPrice dealPrice (e.id(), m_txCommodity, m_txDatePosted, newPrice, i18n("Imported Transaction"));
m_storage->addPrice (dealPrice); m_storage->addPrice (dealPrice);
@ -1631,8 +1632,8 @@ void MyMoneyGncReader::convertTemplateSplit (const TQString& schedName, const Gn
} }
// all data read, now check we have everything // all data read, now check we have everything
if ((bFoundStringCreditFormula) && (bFoundStringDebitFormula) && (bFoundGuidAccountId)) { if ((bFoundStringCreditFormula) && (bFoundStringDebitFormula) && (bFoundGuidAccountId)) {
if (gncdebug) tqDebug ("Found valid slot; credit %s, debit %s, acct %s", if (gncdebug) tqDebug(TQString("Found valid slot; credit %1, debit %2, acct %3").
gncCreditFormula.latin1(), gncDebitFormula.latin1(), gncAccountId.latin1()); arg(gncCreditFormula).arg(gncDebitFormula).arg(gncAccountId));
validSlotCount++; validSlotCount++;
} }
// validate numeric, work out sign // validate numeric, work out sign
@ -1657,7 +1658,7 @@ void MyMoneyGncReader::convertTemplateSplit (const TQString& schedName, const Gn
exFormula = numericTest; exFormula = numericTest;
} }
} else { } else {
if (gncdebug) tqDebug ("%s is not numeric", numericTest.latin1()); if (gncdebug) tqDebug(TQString("%1 is not numeric").arg(numericTest));
nonNumericFormula = true; nonNumericFormula = true;
} }
split.setValue (exFormula); split.setValue (exFormula);
@ -1901,7 +1902,7 @@ void MyMoneyGncReader::terminate () {
// this code is just temporary to show us what is in the file. // this code is just temporary to show us what is in the file.
if (gncdebug) tqDebug("%d accounts found in the GnuCash file", (unsigned int)m_mapIds.count()); if (gncdebug) tqDebug("%d accounts found in the GnuCash file", (unsigned int)m_mapIds.count());
for (map_accountIds::Iterator it = m_mapIds.begin(); it != m_mapIds.end(); ++it) { for (map_accountIds::Iterator it = m_mapIds.begin(); it != m_mapIds.end(); ++it) {
if (gncdebug) tqDebug("key = %s, value = %s", it.key().data(), it.data().data()); if (gncdebug) tqDebug(TQString("key = %1, value = %2").arg(it.key()).arg(it.data()));
} }
// first step is to implement the users investment option, now we // first step is to implement the users investment option, now we
// have all the accounts available // have all the accounts available
@ -1919,34 +1920,34 @@ void MyMoneyGncReader::terminate () {
if ((*acc).parentAccountId() == m_storage->asset().id()) { if ((*acc).parentAccountId() == m_storage->asset().id()) {
MyMoneyAccount assets = m_storage->asset(); MyMoneyAccount assets = m_storage->asset();
m_storage->addAccount(assets, (*acc)); m_storage->addAccount(assets, (*acc));
if (gncdebug) tqDebug("Account id %s is a child of the main asset account", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of the main asset account").arg((*acc).id()));
} else if ((*acc).parentAccountId() == m_storage->liability().id()) { } else if ((*acc).parentAccountId() == m_storage->liability().id()) {
MyMoneyAccount liabilities = m_storage->liability(); MyMoneyAccount liabilities = m_storage->liability();
m_storage->addAccount(liabilities, (*acc)); m_storage->addAccount(liabilities, (*acc));
if (gncdebug) tqDebug("Account id %s is a child of the main liability account", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of the main liability account").arg((*acc).id()));
} else if ((*acc).parentAccountId() == m_storage->income().id()) { } else if ((*acc).parentAccountId() == m_storage->income().id()) {
MyMoneyAccount incomes = m_storage->income(); MyMoneyAccount incomes = m_storage->income();
m_storage->addAccount(incomes, (*acc)); m_storage->addAccount(incomes, (*acc));
if (gncdebug) tqDebug("Account id %s is a child of the main income account", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of the main income account").arg((*acc).id()));
} else if ((*acc).parentAccountId() == m_storage->expense().id()) { } else if ((*acc).parentAccountId() == m_storage->expense().id()) {
MyMoneyAccount expenses = m_storage->expense(); MyMoneyAccount expenses = m_storage->expense();
m_storage->addAccount(expenses, (*acc)); m_storage->addAccount(expenses, (*acc));
if (gncdebug) tqDebug("Account id %s is a child of the main expense account", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of the main expense account").arg((*acc).id()));
} else if ((*acc).parentAccountId() == m_storage->equity().id()) { } else if ((*acc).parentAccountId() == m_storage->equity().id()) {
MyMoneyAccount equity = m_storage->equity(); MyMoneyAccount equity = m_storage->equity();
m_storage->addAccount(equity, (*acc)); m_storage->addAccount(equity, (*acc));
if (gncdebug) tqDebug("Account id %s is a child of the main equity account", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of the main equity account").arg((*acc).id()));
} else if ((*acc).parentAccountId() == m_rootId) { } else if ((*acc).parentAccountId() == m_rootId) {
if (gncdebug) tqDebug("Account id %s is a child of root", (*acc).id().data()); if (gncdebug) tqDebug(TQString("Account id %1 is a child of root").arg((*acc).id()));
} else { } else {
// it is not under one of the main accounts, so find gnucash parent // it is not under one of the main accounts, so find gnucash parent
TQString parentKey = (*acc).parentAccountId(); TQString parentKey = (*acc).parentAccountId();
if (gncdebug) tqDebug ("acc %s, parent %s", (*acc).id().data(), if (gncdebug) tqDebug(TQString("acc %1, parent %2").arg((*acc).id()).
(*acc).parentAccountId().data()); arg((*acc).parentAccountId()));
map_accountIds::Iterator id = m_mapIds.find(parentKey); map_accountIds::Iterator id = m_mapIds.find(parentKey);
if (id != m_mapIds.end()) { if (id != m_mapIds.end()) {
if (gncdebug) tqDebug("Setting account id %s's parent account id to %s", if (gncdebug) tqDebug(TQString("Setting account id %1's parent account id to %1").
(*acc).id().data(), id.data().data()); arg((*acc).id()).arg(id.data()));
MyMoneyAccount parent = m_storage->account(id.data()); MyMoneyAccount parent = m_storage->account(id.data());
parent = checkConsistency (parent, (*acc)); parent = checkConsistency (parent, (*acc));
m_storage->addAccount (parent, (*acc)); m_storage->addAccount (parent, (*acc));
@ -2074,13 +2075,13 @@ TQString MyMoneyGncReader::buildReportSection (const TQString& source) {
} }
if (more) s.append (i18n("\n\nPress More for further information")); if (more) s.append (i18n("\n\nPress More for further information"));
} else { // we need to retrieve the posted messages for this source } else { // we need to retrieve the posted messages for this source
if (gncdebug) tqDebug("Building messages for source %s", source.latin1()); if (gncdebug) tqDebug(TQString("Building messages for source %1").arg(source));
unsigned int i, j; unsigned int i, j;
for (i = 0; i < m_messageList.count(); i++) { for (i = 0; i < m_messageList.count(); i++) {
GncMessageArgs *m = m_messageList.at(i); GncMessageArgs *m = m_messageList.at(i);
if (m->source == source) { if (m->source == source) {
if (gncdebug) tqDebug("%s", TQString("build text source %1, code %2, argcount %3") if (gncdebug) tqDebug(TQString("build text source %1, code %2, argcount %3")
.arg(m->source).arg(m->code).arg(m->args.count()).data()); .arg(m->source).arg(m->code).arg(m->args.count()));
TQString ss = GncMessages::text (m->source, m->code); TQString ss = GncMessages::text (m->source, m->code);
// add variable args. the .arg function seems always to replace the // add variable args. the .arg function seems always to replace the
// lowest numbered placeholder it finds, so translating messages // lowest numbered placeholder it finds, so translating messages
@ -2090,7 +2091,7 @@ TQString MyMoneyGncReader::buildReportSection (const TQString& source) {
} }
} }
} }
if (gncdebug) tqDebug ("%s", s.latin1()); if (gncdebug) tqDebug(s);
return (static_cast<const TQString>(s)); return (static_cast<const TQString>(s));
PASS PASS
} }
@ -2220,9 +2221,9 @@ void MyMoneyGncReader::checkInvestmentOption (TQString stockId) {
invAcc.setParentAccountId (parentKey); // intersperse it between old parent and child stock acct invAcc.setParentAccountId (parentKey); // intersperse it between old parent and child stock acct
m_storage->addAccount (invAcc); m_storage->addAccount (invAcc);
m_mapIds [invAcc.id()] = invAcc.id(); // so stock account gets parented (again) to investment account later m_mapIds [invAcc.id()] = invAcc.id(); // so stock account gets parented (again) to investment account later
if (gncdebug) tqDebug ("Created investment account %s as id %s, parent %s", invAcc.name().data(), invAcc.id().data(), if (gncdebug) tqDebug(TQString("Created investment account %1 as id %2, parent %3").arg(invAcc.name()).arg(invAcc.id()).
invAcc.parentAccountId().data()); arg(invAcc.parentAccountId()));
if (gncdebug) tqDebug ("Setting stock %s, id %s, as child of %s", stockAcc.name().data(), stockAcc.id().data(), invAcc.id().data()); if (gncdebug) tqDebug(TQString("Setting stock %1, id %2, as child of %3").arg(stockAcc.name()).arg(stockAcc.id()).arg(invAcc.id()));
stockAcc.setParentAccountId (invAcc.id()); stockAcc.setParentAccountId (invAcc.id());
m_storage->addAccount(invAcc, stockAcc); m_storage->addAccount(invAcc, stockAcc);
// investment option 1 creates a single investment account for all stocks // investment option 1 creates a single investment account for all stocks
@ -2243,8 +2244,8 @@ void MyMoneyGncReader::checkInvestmentOption (TQString stockId) {
singleInvAcc.setParentAccountId (m_storage->asset().id()); singleInvAcc.setParentAccountId (m_storage->asset().id());
m_storage->addAccount (singleInvAcc); m_storage->addAccount (singleInvAcc);
m_mapIds [singleInvAcc.id()] = singleInvAcc.id(); // so stock account gets parented (again) to investment account later m_mapIds [singleInvAcc.id()] = singleInvAcc.id(); // so stock account gets parented (again) to investment account later
if (gncdebug) tqDebug ("Created investment account %s as id %s, parent %s, reparenting stock", if (gncdebug) tqDebug(TQString("Created investment account %1 as id %2, parent %3, reparenting stock").
singleInvAcc.name().data(), singleInvAcc.id().data(), singleInvAcc.parentAccountId().data()); arg(singleInvAcc.name()).arg(singleInvAcc.id()).arg(singleInvAcc.parentAccountId()));
singleInvAccId = singleInvAcc.id(); singleInvAccId = singleInvAcc.id();
} else { // the account has already been created } else { // the account has already been created
singleInvAcc = m_storage->account (singleInvAccId); singleInvAcc = m_storage->account (singleInvAccId);
@ -2397,8 +2398,8 @@ void MyMoneyGncReader::postMessage (const TQString& source, const unsigned int c
// get the number of args this message requires // get the number of args this message requires
const unsigned int argCount = GncMessages::argCount (source, code); const unsigned int argCount = GncMessages::argCount (source, code);
if ((gncdebug) && (argCount != argList.count())) if ((gncdebug) && (argCount != argList.count()))
tqDebug("%s", TQString("MyMoneyGncReader::postMessage debug: Message %1, code %2, requires %3 arguments, got %4") tqDebug(TQString("MyMoneyGncReader::postMessage debug: Message %1, code %2, requires %3 arguments, got %4")
.arg(source).arg(code).arg(argCount).arg(argList.count()).data()); .arg(source).arg(code).arg(argCount).arg(argList.count()));
// store the arguments // store the arguments
for (i = 0; i < argCount; i++) { for (i = 0; i < argCount; i++) {
if (i > argList.count()) m->args.append(TQString()); if (i > argList.count()) m->args.append(TQString());

@ -477,7 +477,7 @@ const TQDate MyMoneyQifProfile::date(const TQString& datein) const
} }
} }
if(j == 13) { if(j == 13) {
tqWarning("Unknown month '%s'", scannedParts[d->m_partPos['m']].data()); tqWarning(TQString("Unknown month '%1'").arg(scannedParts[d->m_partPos['m']]));
return TQDate(); return TQDate();
} }
} }
@ -573,8 +573,8 @@ const TQDate MyMoneyQifProfile::date(const TQString& datein) const
for(i = 0; i < 2; ++i) { for(i = 0; i < 2; ++i) {
if(scannedDelim[i] != formatDelim[i] if(scannedDelim[i] != formatDelim[i]
&& scannedDelim[i] != TQChar('\'')) { && scannedDelim[i] != TQChar('\'')) {
tqWarning("MyMoneyQifProfile::date(const TQString& datein) Invalid delimiter '%s' when '%s' was expected", tqWarning(TQString("MyMoneyQifProfile::date(const TQString& datein) Invalid delimiter '%1' when '%2' was expected").
scannedDelim[i].latin1(), formatDelim[i].latin1()); arg(scannedDelim[i]).arg(formatDelim[i]));
return TQDate(); return TQDate();
} }
} }
@ -658,7 +658,7 @@ const TQDate MyMoneyQifProfile::date(const TQString& datein) const
break; break;
} }
if(!msg.isEmpty()) { if(!msg.isEmpty()) {
tqWarning("MyMoneyQifProfile::date(const TQString& datein) %s",msg.latin1()); tqWarning(TQString("MyMoneyQifProfile::date(const TQString& datein) %1").arg(msg));
return TQDate(); return TQDate();
} }
} }

@ -336,7 +336,7 @@ void MyMoneyQifReader::slotImportFinished(void)
if(!m_lineBuffer.isEmpty()) { if(!m_lineBuffer.isEmpty()) {
m_qifLines << TQString::fromUtf8(m_lineBuffer.stripWhiteSpace()); m_qifLines << TQString::fromUtf8(m_lineBuffer.stripWhiteSpace());
} }
tqDebug("Read %d bytes", m_pos); tqDebug("Read %ld bytes", m_pos);
TQTimer::singleShot(0, this, TQT_SLOT(slotProcessData())); TQTimer::singleShot(0, this, TQT_SLOT(slotProcessData()));
} }
@ -365,13 +365,13 @@ void MyMoneyQifReader::slotProcessData(void)
m_qifProfile.setInputDateFormat(list.first()); m_qifProfile.setInputDateFormat(list.first());
tqDebug("Selected date format: '%s'", list.first().data()); tqDebug(TQString("Selected date format: '%1'").arg(list.first()));
signalProgress(0, m_qifLines.count(), i18n("Importing QIF ...")); signalProgress(0, m_qifLines.count(), i18n("Importing QIF ..."));
TQStringList::iterator it; TQStringList::iterator it;
for(it = m_qifLines.begin(); m_userAbort == false && it != m_qifLines.end(); ++it) { for(it = m_qifLines.begin(); m_userAbort == false && it != m_qifLines.end(); ++it) {
++m_linenumber; ++m_linenumber;
// tqDebug("Proc: '%s'", (*it).data()); // tqDebug(TQString("Proc: '%1'").arg(*it));
if((*it).startsWith("!")) { if((*it).startsWith("!")) {
processQifSpecial(*it); processQifSpecial(*it);
m_qifEntry.clear(); m_qifEntry.clear();
@ -621,7 +621,7 @@ void MyMoneyQifReader::processQifSpecial(const TQString& _line)
m_entryType = EntrySkip; m_entryType = EntrySkip;
} else { } else {
tqWarning("Unknown export header '!Type:%s' in QIF file on line %d: Skipping section.", line.data(), m_linenumber); tqWarning(TQString("Unknown export header '!Type:%1' in QIF file on line %2: Skipping section.").arg(line).arg(m_linenumber));
m_entryType = EntrySkip; m_entryType = EntrySkip;
} }
@ -1017,7 +1017,7 @@ void MyMoneyQifReader::processTransactionEntry(void)
h = MyMoneyTransaction::hash(m_qifEntry.join(";")); h = MyMoneyTransaction::hash(m_qifEntry.join(";"));
TQString hashBase; TQString hashBase;
hashBase.sprintf("%s-%07lx", m_qifProfile.date(extractLine('D')).toString(Qt::ISODate).data(), h); hashBase.sprintf("%s-%07lx", m_qifProfile.date(extractLine('D')).toString(Qt::ISODate).latin1(), h);
int idx = 1; int idx = 1;
TQString hash; TQString hash;
for(;;) { for(;;) {
@ -1172,7 +1172,7 @@ void MyMoneyQifReader::processTransactionEntry(void)
} }
} catch (MyMoneyException *e) { } catch (MyMoneyException *e) {
kdDebug(0) << "Line " << m_linenumber << ": Account with id " << accountId.data() << " not found" << endl; kdDebug(0) << "Line " << m_linenumber << ": Account with id " << accountId << " not found" << endl;
accountId = TQString(); accountId = TQString();
delete e; delete e;
} }
@ -1231,7 +1231,7 @@ void MyMoneyQifReader::processTransactionEntry(void)
} }
} catch (MyMoneyException *e) { } catch (MyMoneyException *e) {
kdDebug(0) << "Line " << m_linenumber << ": Account with id " << accountId.data() << " not found" << endl; kdDebug(0) << "Line " << m_linenumber << ": Account with id " << accountId << " not found" << endl;
accountId = TQString(); accountId = TQString();
delete e; delete e;
} }
@ -1327,7 +1327,7 @@ void MyMoneyQifReader::processInvestmentTransactionEntry(void)
h = MyMoneyTransaction::hash(m_qifEntry.join(";")); h = MyMoneyTransaction::hash(m_qifEntry.join(";"));
TQString hashBase; TQString hashBase;
hashBase.sprintf("%s-%07lx", m_qifProfile.date(extractLine('D')).toString(Qt::ISODate).data(), h); hashBase.sprintf("%s-%07lx", m_qifProfile.date(extractLine('D')).toString(Qt::ISODate).latin1(), h);
int idx = 1; int idx = 1;
TQString hash; TQString hash;
for(;;) { for(;;) {
@ -1994,7 +1994,7 @@ TQString MyMoneyQifReader::processAccountEntry(bool resetAccountId)
TQString tmp; TQString tmp;
account.setName(extractLine('N')); account.setName(extractLine('N'));
// tqDebug("Process account '%s'", account.name().data()); // tqDebug(TQString("Process account '%1'").arg(account.name()));
account.setDescription(extractLine('D')); account.setDescription(extractLine('D'));

@ -237,7 +237,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
try { try {
m_account = MyMoneyFile::instance()->account(s.m_accountId); m_account = MyMoneyFile::instance()->account(s.m_accountId);
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Received reference '%s' to unknown account in statement", s.m_accountId.data()); tqDebug(TQString("Received reference '%1' to unknown account in statement").arg(s.m_accountId));
delete e; delete e;
} }
} }
@ -299,7 +299,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
else if(s.m_listTransactions.count() == 0) else if(s.m_listTransactions.count() == 0)
messages += i18n("Importing statement without transactions"); messages += i18n("Importing statement without transactions");
tqDebug("Importing statement for '%s'", m_account.name().data()); tqDebug(TQString("Importing statement for '%1'").arg(m_account.name()));
// //
// Process the securities // Process the securities
@ -322,7 +322,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
if ( !m_userAbort ) if ( !m_userAbort )
{ {
try { try {
tqDebug("Processing transactions (%s)", m_account.name().data()); tqDebug(TQString("Processing transactions (%1)").arg(m_account.name()));
signalProgress(0, s.m_listTransactions.count(), "Importing Statement ..."); signalProgress(0, s.m_listTransactions.count(), "Importing Statement ...");
int progress = 0; int progress = 0;
TQValueList<MyMoneyStatement::Transaction>::const_iterator it_t = s.m_listTransactions.begin(); TQValueList<MyMoneyStatement::Transaction>::const_iterator it_t = s.m_listTransactions.begin();
@ -332,13 +332,13 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
signalProgress(++progress, 0); signalProgress(++progress, 0);
++it_t; ++it_t;
} }
tqDebug("Processing transactions done (%s)", m_account.name().data()); tqDebug(TQString("Processing transactions done (%1)").arg(m_account.name()));
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
if(e->what() == "USERABORT") if(e->what() == "USERABORT")
m_userAbort = true; m_userAbort = true;
else else
tqDebug("Caught exception from processTransactionEntry() not caused by USERABORT: %s", e->what().data()); tqDebug(TQString("Caught exception from processTransactionEntry() not caused by USERABORT: %1").arg(e->what()));
delete e; delete e;
} }
signalProgress(-1, -1); signalProgress(-1, -1);
@ -369,7 +369,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
if(e->what() == "USERABORT") if(e->what() == "USERABORT")
m_userAbort = true; m_userAbort = true;
else else
tqDebug("Caught exception from processPriceEntry() not caused by USERABORT: %s", e->what().data()); tqDebug(TQString("Caught exception from processPriceEntry() not caused by USERABORT: %1").arg(e->what()));
delete e; delete e;
} }
signalProgress(-1, -1); signalProgress(-1, -1);
@ -423,7 +423,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
delete m_ft; delete m_ft;
m_ft = 0; m_ft = 0;
tqDebug("Importing statement for '%s' done", m_account.name().data()); tqDebug(TQString("Importing statement for '%1' done").arg(m_account.name()));
return rc; return rc;
} }
@ -505,7 +505,7 @@ void MyMoneyStatementReader::processTransactionEntry(const MyMoneyStatement::Tra
#if 0 #if 0
TQString dbgMsg; TQString dbgMsg;
dbgMsg = TQString("Process %1, '%3', %2").arg(t_in.m_datePosted.toString(Qt::ISODate)).arg(t_in.m_amount.formatMoney("", 2)).arg(t_in.m_strBankID); dbgMsg = TQString("Process %1, '%3', %2").arg(t_in.m_datePosted.toString(Qt::ISODate)).arg(t_in.m_amount.formatMoney("", 2)).arg(t_in.m_strBankID);
tqDebug("%s", dbgMsg.data()); tqDebug(dbgMsg);
#endif #endif
// mark it imported for the view // mark it imported for the view
@ -962,7 +962,7 @@ void MyMoneyStatementReader::processTransactionEntry(const MyMoneyStatement::Tra
try { try {
file->addPayee(payee); file->addPayee(payee);
tqDebug("Payee '%s' created", payee.name().data()); tqDebug(TQString("Payee '%1' created").arg(payee.name()));
d->payees << payee; d->payees << payee;
payeeid = payee.id(); payeeid = payee.id();
s1.setPayeeId(payeeid); s1.setPayeeId(payeeid);
@ -1161,7 +1161,7 @@ void MyMoneyStatementReader::processTransactionEntry(const MyMoneyStatement::Tra
break; break;
case TransactionMatcher::matched: case TransactionMatcher::matched:
case TransactionMatcher::matchedExact: case TransactionMatcher::matchedExact:
tqDebug("Detected as match to transaction '%s'", tm.id().data()); tqDebug(TQString("Detected as match to transaction '%1'").arg(tm.id()));
matcher.match(tm, matchedSplit, t, s1, true); matcher.match(tm, matchedSplit, t, s1, true);
d->transactionsMatched++; d->transactionsMatched++;
break; break;
@ -1230,7 +1230,7 @@ void MyMoneyStatementReader::processTransactionEntry(const MyMoneyStatement::Tra
delete o; delete o;
} catch (MyMoneyException *e) { } catch (MyMoneyException *e) {
TQString message(i18n("Problem adding or matching imported transaction with id '%1': %2").arg(t_in.m_strBankID).arg(e->what())); TQString message(i18n("Problem adding or matching imported transaction with id '%1': %2").arg(t_in.m_strBankID).arg(e->what()));
tqDebug("%s", message.data()); tqDebug(message);
delete e; delete e;
int result = KMessageBox::warningContinueCancel(0, message); int result = KMessageBox::warningContinueCancel(0, message);

@ -159,7 +159,7 @@ void Activity::setLabelText(const TQString& idx, const TQString& txt) const
if(w) { if(w) {
w->setText(txt); w->setText(txt);
} else { } else {
tqDebug("Unknown TQLabel named '%s'", idx.data()); tqDebug(TQString("Unknown TQLabel named '%1'").arg(idx));
} }
} }

@ -199,24 +199,24 @@ void KEndingBalanceDlg::slotUpdateBalances(void)
balance = balance * factor; balance = balance * factor;
endBalance = startBalance = balance; endBalance = startBalance = balance;
tracer.printf("total balance = %s", endBalance.formatMoney("", 2).data()); tracer.printf("total balance = %s", endBalance.formatMoney("", 2).local8Bit().data());
for(it = transactionList.begin(); it != transactionList.end(); ++it) { for(it = transactionList.begin(); it != transactionList.end(); ++it) {
const MyMoneySplit& split = (*it).second; const MyMoneySplit& split = (*it).second;
balance -= split.shares() * factor; balance -= split.shares() * factor;
if((*it).first.postDate() > m_statementDate->date()) { if((*it).first.postDate() > m_statementDate->date()) {
tracer.printf("Reducing balances by %s because postdate of %s/%s(%s) is past statement date", (split.shares() * factor).formatMoney("", 2).data(), (*it).first.id().data(),split.id().data(), (*it).first.postDate().toString(Qt::ISODate).data()); tracer.printf("Reducing balances by %s because postdate of %s/%s(%s) is past statement date", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), (*it).first.id().local8Bit().data(),split.id().local8Bit().data(), (*it).first.postDate().toString(Qt::ISODate).local8Bit().data());
endBalance -= split.shares() * factor; endBalance -= split.shares() * factor;
startBalance -= split.shares() * factor; startBalance -= split.shares() * factor;
} else { } else {
switch(split.reconcileFlag()) { switch(split.reconcileFlag()) {
case MyMoneySplit::NotReconciled: case MyMoneySplit::NotReconciled:
tracer.printf("Reducing balances by %s because %s/%s(%s) is not reconciled", (split.shares() * factor).formatMoney("", 2).data(), (*it).first.id().data(), split.id().data(), (*it).first.postDate().toString(Qt::ISODate).data()); tracer.printf("Reducing balances by %s because %s/%s(%s) is not reconciled", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), (*it).first.id().local8Bit().data(), split.id().local8Bit().data(), (*it).first.postDate().toString(Qt::ISODate).local8Bit().data());
endBalance -= split.shares() * factor; endBalance -= split.shares() * factor;
startBalance -= split.shares() * factor; startBalance -= split.shares() * factor;
break; break;
case MyMoneySplit::Cleared: case MyMoneySplit::Cleared:
tracer.printf("Reducing start balance by %s because %s/%s(%s) is cleared", (split.shares() * factor).formatMoney("", 2).data(), (*it).first.id().data(), split.id().data(), (*it).first.postDate().toString(Qt::ISODate).data()); tracer.printf("Reducing start balance by %s because %s/%s(%s) is cleared", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), (*it).first.id().local8Bit().data(), split.id().local8Bit().data(), (*it).first.postDate().toString(Qt::ISODate).local8Bit().data());
startBalance -= split.shares() * factor; startBalance -= split.shares() * factor;
break; break;
default: default:
@ -226,8 +226,8 @@ void KEndingBalanceDlg::slotUpdateBalances(void)
} }
m_previousBalance->setValue(startBalance); m_previousBalance->setValue(startBalance);
m_endingBalance->setValue(endBalance); m_endingBalance->setValue(endBalance);
tracer.printf("total balance = %s", endBalance.formatMoney("", 2).data()); tracer.printf("total balance = %s", endBalance.formatMoney("", 2).local8Bit().data());
tracer.printf("start balance = %s", startBalance.formatMoney("", 2).data()); tracer.printf("start balance = %s", startBalance.formatMoney("", 2).local8Bit().data());
m_interestDateEdit->setDate(m_statementDate->date()); m_interestDateEdit->setDate(m_statementDate->date());
m_chargesDateEdit->setDate(m_statementDate->date()); m_chargesDateEdit->setDate(m_statementDate->date());
@ -366,7 +366,7 @@ bool KEndingBalanceDlg::createTransaction(MyMoneyTransaction &t, const int sign,
t.modifySplit(s2); t.modifySplit(s2);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("%s", e->what().data()); tqDebug(e->what());
delete e; delete e;
t = MyMoneyTransaction(); t = MyMoneyTransaction();
return false; return false;
@ -594,7 +594,7 @@ const MyMoneyTransaction KEndingBalanceLoanDlg::adjustmentTransaction(void) cons
t.setPostDate(m_endDateEdit->date()); t.setPostDate(m_endDateEdit->date());
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to create adjustment transaction for loan reconciliation: %s", e->what().data()); tqDebug(TQString("Unable to create adjustment transaction for loan reconciliation: %1").arg(e->what()));
delete e; delete e;
return MyMoneyTransaction(); return MyMoneyTransaction();
} }

@ -369,7 +369,7 @@ void KEquityPriceUpdateDlg::storePrices(void)
ft.commit(); ft.commit();
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to add price information for %s", name.data()); tqDebug(TQString("Unable to add price information for %1").arg(name));
delete e; delete e;
} }
} }

@ -285,7 +285,7 @@ int TransactionEditor::slotEditSplits(void)
*m_transactionPtr = k; *m_transactionPtr = k;
} }
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to update commodity to second splits currency in %s: '%s'", m_transaction.id().data(), e->what().data()); tqDebug(TQString("Unable to update commodity to second splits currency in %1: '%2'").arg(m_transaction.id()).arg(e->what()));
delete e; delete e;
} }
@ -361,7 +361,7 @@ bool TransactionEditor::fixTransactionCommodity(const MyMoneyAccount& account)
(*it_t).transaction().modifySplit(splitB); (*it_t).transaction().modifySplit(splitB);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to update commodity to second splits currency in %s: '%s'", (*it_t).transaction().id().data(), e->what().data()); tqDebug(TQString("Unable to update commodity to second splits currency in %1: '%2'").arg((*it_t).transaction().id()).arg(e->what()));
delete e; delete e;
} }
break; break;
@ -398,7 +398,7 @@ bool TransactionEditor::fixTransactionCommodity(const MyMoneyAccount& account)
(*it_t).transaction().modifySplit(splitB); (*it_t).transaction().modifySplit(splitB);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to update commodity to second splits currency in %s: '%s'", (*it_t).transaction().id().data(), e->what().data()); tqDebug(TQString("Unable to update commodity to second splits currency in %1: '%2'").arg((*it_t).transaction().id()).arg(e->what()));
delete e; delete e;
} }
break; break;
@ -444,7 +444,7 @@ bool TransactionEditor::fixTransactionCommodity(const MyMoneyAccount& account)
} }
} }
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to update commodity of split currency in %s: '%s'", (*it_t).transaction().id().data(), e->what().data()); tqDebug(TQString("Unable to update commodity of split currency in %1: '%2'").arg((*it_t).transaction().id()).arg(e->what()));
delete e; delete e;
} }
break; break;
@ -711,7 +711,7 @@ bool TransactionEditor::enterTransactions(TQString& newId, bool askForSchedule,
} }
} }
} catch(MyMoneyException * e) { } catch(MyMoneyException * e) {
tqDebug("Unable to store transaction within engine: %s", e->what().latin1()); tqDebug(TQString("Unable to store transaction within engine: %1").arg(e->what()));
delete e; delete e;
newTransactionCreated = false; newTransactionCreated = false;
} }
@ -1447,7 +1447,7 @@ void StdTransactionEditor::slotUpdateCashFlow(KMyMoneyRegister::CashFlowDirectio
void StdTransactionEditor::slotUpdateCategory(const TQString& id) void StdTransactionEditor::slotUpdateCategory(const TQString& id)
{ {
TQLabel *categoryLabel = dynamic_cast<TQLabel*>(haveWidget("category-label")); TQLabel *categoryLabel = dynamic_cast<TQLabel*>(haveWidget("category-label"));
// tqDebug("Update category to %s", id.data()); // tqDebug(TQString("Update category to %1").arg(id));
if(categoryLabel) { if(categoryLabel) {
TabBar* tabbar = dynamic_cast<TabBar*>(haveWidget("tabbar")); TabBar* tabbar = dynamic_cast<TabBar*>(haveWidget("tabbar"));
@ -1526,7 +1526,7 @@ void StdTransactionEditor::slotUpdateDeposit(const TQString& txt)
void StdTransactionEditor::slotUpdateAmount(const TQString& txt) void StdTransactionEditor::slotUpdateAmount(const TQString& txt)
{ {
// tqDebug("Update amount to %s", txt.data()); // tqDebug(TQString("Update amount to %1").arg(txt));
MyMoneyMoney val(txt); MyMoneyMoney val(txt);
updateAmount(val); updateAmount(val);
updateVAT(true); updateVAT(true);
@ -1661,7 +1661,7 @@ bool StdTransactionEditor::addVatSplit(MyMoneyTransaction& tr, const MyMoneyMone
tax.setAccountId(vatAcc.id()); tax.setAccountId(vatAcc.id());
// tqDebug("vat amount is '%s'", category.value("VatAmount").latin1()); // tqDebug(TQString("vat amount is '%1'").arg(category.value("VatAmount")));
if(category.value("VatAmount").lower() != TQString("net")) { if(category.value("VatAmount").lower() != TQString("net")) {
// split value is the gross value // split value is the gross value
gv = amount; gv = amount;

@ -516,7 +516,7 @@ TDEAction* KMyMoney2App::action(const TQString& actionName) const
if(p) if(p)
return p; return p;
tqWarning("Action with name '%s' not found!", actionName.latin1()); tqWarning(TQString("Action with name '%1' not found!").arg(actionName));
return &dummyAction; return &dummyAction;
} }
@ -530,13 +530,13 @@ TDEToggleAction* KMyMoney2App::toggleAction(const TQString& actionName) const
if(q) { if(q) {
TDEToggleAction* p = dynamic_cast<TDEToggleAction*>(q); TDEToggleAction* p = dynamic_cast<TDEToggleAction*>(q);
if(!p) { if(!p) {
tqWarning("Action '%s' is not of type TDEToggleAction", actionName.latin1()); tqWarning(TQString("Action '%1' is not of type TDEToggleAction").arg(actionName));
p = &dummyAction; p = &dummyAction;
} }
return p; return p;
} }
tqWarning("Action with name '%s' not found!", actionName.latin1()); tqWarning(TQString("Action with name '%1' not found!").arg(actionName));
return &dummyAction; return &dummyAction;
} }
@ -2612,7 +2612,7 @@ void KMyMoney2App::slotManualPriceUpdate(void)
// The dialog takes care of adding the price if necessary // The dialog takes care of adding the price if necessary
calc.exec(); calc.exec();
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Error in price update: %s", e->what().data()); tqDebug(TQString("Error in price update: %1").arg(e->what()));
delete e; delete e;
} }
} }
@ -3057,14 +3057,14 @@ void KMyMoney2App::slotAccountEdit(void)
file->addSchedule(sch); file->addSchedule(sch);
ft.commit(); ft.commit();
} catch (MyMoneyException *f) { } catch (MyMoneyException *f) {
tqDebug("Cannot add schedule: '%s'", f->what().data()); tqDebug(TQString("Cannot add schedule: '%1'").arg(f->what()));
delete f; delete f;
} }
delete e; delete e;
} }
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to modify account %s: '%s'", m_selectedAccount.name().data(), tqDebug(TQString("Unable to modify account %1: '%2'").
e->what().data()); arg(m_selectedAccount.name()).arg(e->what()));
delete e; delete e;
} }
} }
@ -3143,7 +3143,7 @@ void KMyMoney2App::slotAccountReconcileStart(void)
ft.commit(); ft.commit();
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqWarning("interest transaction not stored: '%s'", e->what().data()); tqWarning(TQString("interest transaction not stored: '%s'").arg(e->what()));
delete e; delete e;
} }
@ -5459,7 +5459,7 @@ void KMyMoney2App::slotUpdateActions(void)
action("investment_online_price_update")->setEnabled(true); action("investment_online_price_update")->setEnabled(true);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Error retrieving security for investment %s: %s", m_selectedInvestment.name().data(), e->what().data()); tqDebug(TQString("Error retrieving security for investment %1: %2").arg(m_selectedInvestment.name()).arg(e->what()));
delete e; delete e;
} }
if(m_selectedInvestment.isClosed()) if(m_selectedInvestment.isClosed())
@ -5620,7 +5620,7 @@ void KMyMoney2App::slotSelectInstitution(const MyMoneyObject& institution)
return; return;
m_selectedInstitution = dynamic_cast<const MyMoneyInstitution&>(institution); m_selectedInstitution = dynamic_cast<const MyMoneyInstitution&>(institution);
// tqDebug("slotSelectInstitution('%s')", m_selectedInstitution.name().data()); // tqDebug(TQString("slotSelectInstitution('%1')").arg(m_selectedInstitution.name()));
slotUpdateActions(); slotUpdateActions();
emit institutionSelected(m_selectedInstitution); emit institutionSelected(m_selectedInstitution);
} }
@ -5635,7 +5635,7 @@ void KMyMoney2App::slotSelectAccount(const MyMoneyObject& obj)
if(!acc.isInvest()) if(!acc.isInvest())
m_selectedAccount = acc; m_selectedAccount = acc;
// tqDebug("slotSelectAccount('%s')", m_selectedAccount.name().data()); // tqDebug(TQString("slotSelectAccount('%1')").arg(m_selectedAccount.name()));
slotUpdateActions(); slotUpdateActions();
emit accountSelected(m_selectedAccount); emit accountSelected(m_selectedAccount);
} }
@ -5645,7 +5645,7 @@ void KMyMoney2App::slotSelectInvestment(const MyMoneyObject& obj)
if(typeid(obj) != typeid(MyMoneyAccount)) if(typeid(obj) != typeid(MyMoneyAccount))
return; return;
// tqDebug("slotSelectInvestment('%s')", account.name().data()); // tqDebug(TQString("slotSelectInvestment('%1')".arg(account.name()));
m_selectedInvestment = MyMoneyAccount(); m_selectedInvestment = MyMoneyAccount();
const MyMoneyAccount& acc = dynamic_cast<const MyMoneyAccount&>(obj); const MyMoneyAccount& acc = dynamic_cast<const MyMoneyAccount&>(obj);
if(acc.isInvest()) if(acc.isInvest())
@ -5657,7 +5657,7 @@ void KMyMoney2App::slotSelectInvestment(const MyMoneyObject& obj)
void KMyMoney2App::slotSelectSchedule(const MyMoneySchedule& schedule) void KMyMoney2App::slotSelectSchedule(const MyMoneySchedule& schedule)
{ {
// tqDebug("slotSelectSchedule('%s')", schedule.name().data()); // tqDebug(TQString("slotSelectSchedule('%1')").arg(schedule.name()));
m_selectedSchedule = schedule; m_selectedSchedule = schedule;
slotUpdateActions(); slotUpdateActions();
emit scheduleSelected(m_selectedSchedule); emit scheduleSelected(m_selectedSchedule);
@ -6196,7 +6196,7 @@ void KMyMoney2App::Private::unlinkStatementXML(void)
{ {
TQDir d("/home/thb", "kmm-statement*"); TQDir d("/home/thb", "kmm-statement*");
for(int i=0; i < d.count(); ++i) { for(int i=0; i < d.count(); ++i) {
tqDebug("Remove %s", d[i].data()); tqDebug(TQString("Remove %1").arg(d[i]));
d.remove(TQString("/home/thb/%1").arg(d[i])); d.remove(TQString("/home/thb/%1").arg(d[i]));
} }
statementXMLindex = 0; statementXMLindex = 0;

@ -285,7 +285,7 @@ TQString KMyMoneyUtils::findResource(const char* type, const TQString& filename)
// check that the placeholder is present // check that the placeholder is present
if(!filename.find("%1")) { if(!filename.find("%1")) {
tqWarning("%%1 not found in '%s'", filename.latin1()); tqWarning(TQString("%%1 not found in '%1'").arg(filename));
return filename; return filename;
} }
@ -297,7 +297,7 @@ TQString KMyMoneyUtils::findResource(const char* type, const TQString& filename)
rc = TDEGlobal::dirs()->findResource(type, mask.arg(language)); rc = TDEGlobal::dirs()->findResource(type, mask.arg(language));
} }
if(rc.isEmpty()) { if(rc.isEmpty()) {
// tqDebug(TQString("html/home_%1.html not found").arg(country).latin1()); // tqDebug(TQString("html/home_%1.html not found").arg(country));
rc = TDEGlobal::dirs()->findResource(type, mask.arg(country)); rc = TDEGlobal::dirs()->findResource(type, mask.arg(country));
} }
if(rc.isEmpty()) { if(rc.isEmpty()) {
@ -305,7 +305,7 @@ TQString KMyMoneyUtils::findResource(const char* type, const TQString& filename)
} }
if(rc.isEmpty()) { if(rc.isEmpty()) {
tqWarning("No resource found for (%s,%s)", type, filename.latin1()); tqWarning(TQString("No resource found for (%1,%2)").arg(type).arg(filename));
} }
return rc; return rc;
} }
@ -436,7 +436,7 @@ MyMoneyTransaction KMyMoneyUtils::scheduledTransaction(const MyMoneySchedule& sc
calculateAutoLoan(schedule, t, TQMap<TQString, MyMoneyMoney>()); calculateAutoLoan(schedule, t, TQMap<TQString, MyMoneyMoney>());
} }
} catch (MyMoneyException* e) { } catch (MyMoneyException* e) {
tqDebug("Unable to load schedule details for '%s' during transaction match: %s", schedule.name().data(), e->what().data()); tqDebug(TQString("Unable to load schedule details for '%1' during transaction match: %1").arg(schedule.name()).arg(e->what()));
delete e; delete e;
} }

@ -66,7 +66,7 @@ MyMoneyAccount::MyMoneyAccount(const TQDomElement& node) :
setName(node.attribute("name")); setName(node.attribute("name"));
// tqDebug("Reading information for account %s", acc.name().data()); // tqDebug(TQString("Reading information for account %1").arg(acc.name()));
setParentAccountId(TQStringEmpty(node.attribute("parentaccount"))); setParentAccountId(TQStringEmpty(node.attribute("parentaccount")));
setLastModified(stringToDate(TQStringEmpty(node.attribute("lastmodified")))); setLastModified(stringToDate(TQStringEmpty(node.attribute("lastmodified"))));
@ -97,7 +97,7 @@ MyMoneyAccount::MyMoneyAccount(const TQDomElement& node) :
if(bOK) { if(bOK) {
setAccountType(static_cast<MyMoneyAccount::accountTypeE>(type)); setAccountType(static_cast<MyMoneyAccount::accountTypeE>(type));
} else { } else {
tqWarning("XMLREADER: Account %s had invalid or no account type information.", name().data()); tqWarning(TQString("XMLREADER: Account %1 had invalid or no account type information.").arg(name()));
} }
if(node.hasAttribute("openingbalance")) { if(node.hasAttribute("openingbalance")) {
@ -109,7 +109,7 @@ MyMoneyAccount::MyMoneyAccount(const TQDomElement& node) :
setDescription(node.attribute("description")); setDescription(node.attribute("description"));
m_id = TQStringEmpty(node.attribute("id")); m_id = TQStringEmpty(node.attribute("id"));
// tqDebug("Account %s has id of %s, type of %d, parent is %s.", acc.name().data(), id.data(), type, acc.parentAccountId().data()); // tqDebug(TQString("Account %1 has id of %2, type of %3, parent is %4.").arg(acc.name()).arg(id).arg(type).arg(acc.parentAccountId()));
// Process any Sub-Account information found inside the account entry. // Process any Sub-Account information found inside the account entry.
m_accountList.clear(); m_accountList.clear();

@ -741,7 +741,7 @@ const MyMoneyAccount MyMoneyFile::openingBalanceAccount(const MyMoneySecurity& s
ft.commit(); ft.commit();
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Unable to create opening balance account for security %s", security.id().data()); tqDebug(TQString("Unable to create opening balance account for security %1").arg(security.id()));
delete e; delete e;
} }
return acc; return acc;
@ -1101,10 +1101,10 @@ void MyMoneyFile::warningMissingRate(const TQString& fromId, const TQString& toI
try { try {
from = security(fromId); from = security(fromId);
to = security(toId); to = security(toId);
tqWarning("Missing price info for conversion from %s to %s", from.name().latin1(), to.name().latin1()); tqWarning(TQString("Missing price info for conversion from %1 to %2").arg(from.name()).arg(to.name()));
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqFatal("Missing security caught in MyMoneyFile::warningMissingRate(): %s(%ld) %s", e->file().data(), e->line(), e->what().data()); tqFatal(TQString("Missing security caught in MyMoneyFile::warningMissingRate(): %1(%2) %3").arg(e->file()).arg(e->line()).arg(e->what()));
delete e; delete e;
} }
} }
@ -1812,11 +1812,11 @@ TQString MyMoneyFile::createCategory(const MyMoneyAccount& base, const TQString&
} }
catch (MyMoneyException *e) catch (MyMoneyException *e)
{ {
tqDebug("Unable to add account %s, %s, %s: %s", tqDebug(TQString("Unable to add account %1, %2, %3: %4").
categoryAccount.name().latin1(), arg(categoryAccount.name()).
parent.name().latin1(), arg(parent.name()).
categoryText.latin1(), arg(categoryText).
e->what().latin1()); arg(e->what()));
delete e; delete e;
} }

@ -194,7 +194,7 @@ void MyMoneyObjectContainer::refresh(const TQString& id)
const MyMoneySchedule& s = m_storage->schedule(id); const MyMoneySchedule& s = m_storage->schedule(id);
m_map[id] = new MyMoneySchedule(s); m_map[id] = new MyMoneySchedule(s);
} else { } else {
tqWarning("Ooops, should preload an unknown object with id '%s'", id.data()); tqWarning(TQString("Ooops, should preload an unknown object with id '%1'").arg(id));
} }
return; return;
} }

@ -623,7 +623,7 @@ MyMoneyAccount MyMoneySchedule::account(int cnt) const
if(!cnt) if(!cnt)
return acc; return acc;
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqWarning("Schedule '%s' references unknown account '%s'", id().data(), (*it).accountId().data()); tqWarning(TQString("Schedule '%1' references unknown account '%2'").arg(id()).arg((*it).accountId()));
delete e; delete e;
return MyMoneyAccount(); return MyMoneyAccount();
} }

@ -849,13 +849,13 @@ bool MyMoneyTransactionFilter::translateDateRange(dateOptionE id, TQDate& start,
void MyMoneyTransactionFilter::removeReference(const TQString& id) void MyMoneyTransactionFilter::removeReference(const TQString& id)
{ {
if(m_accounts.find(id)) { if(m_accounts.find(id)) {
tqDebug("%s", (TQString("Remove account '%1' from report").arg(id)).data()); tqDebug(TQString("Remove account '%1' from report").arg(id));
m_accounts.remove(id); m_accounts.remove(id);
} else if(m_categories.find(id)) { } else if(m_categories.find(id)) {
tqDebug("%s", (TQString("Remove category '%1' from report").arg(id)).data()); tqDebug(TQString("Remove category '%1' from report").arg(id));
m_categories.remove(id); m_categories.remove(id);
} else if(m_payees.find(id)) { } else if(m_payees.find(id)) {
tqDebug("%s", (TQString("Remove payee '%1' from report").arg(id)).data()); tqDebug(TQString("Remove payee '%1' from report").arg(id));
m_payees.remove(id); m_payees.remove(id);
} }
} }

@ -925,7 +925,7 @@ const MyMoneyMoney MyMoneyDatabaseMgr::balance(const TQString& id, const TQDate&
MyMoneyAccount acc; MyMoneyAccount acc;
TQMap<TQString, MyMoneyAccount> accountList = m_sql->fetchAccounts(/*TQString(id)*/); TQMap<TQString, MyMoneyAccount> accountList = m_sql->fetchAccounts(/*TQString(id)*/);
//TQMap<TQString, MyMoneyAccount>::const_iterator accpos = accountList.find(id); //TQMap<TQString, MyMoneyAccount>::const_iterator accpos = accountList.find(id);
if (date_ != TQDate()) tqDebug ("request balance for %s at %s", id.data(), TQString(date_.toString(Qt::ISODate)).latin1()); if (date_ != TQDate()) tqDebug (TQString("request balance for %1 at %2").arg(id).arg(date_.toString(Qt::ISODate)));
// if(!date_.isValid() && MyMoneyFile::instance()->account(id).accountType() != MyMoneyAccount::Stock) { // if(!date_.isValid() && MyMoneyFile::instance()->account(id).accountType() != MyMoneyAccount::Stock) {
// if(accountList.find(id) != accountList.end()) // if(accountList.find(id) != accountList.end())
// return accountList[id].balance(); // return accountList[id].balance();
@ -1224,7 +1224,7 @@ const TQValueList<MyMoneySchedule> MyMoneyDatabaseMgr::scheduleList(const TQStri
// tqDebug("scheduleList()"); // tqDebug("scheduleList()");
for(pos = scheduleList.begin(); pos != scheduleList.end(); ++pos) { for(pos = scheduleList.begin(); pos != scheduleList.end(); ++pos) {
// tqDebug(" '%s'", (*pos).id().data()); // tqDebug(TQString(" '%1'").arg((*pos).id()));
if(type != MyMoneySchedule::TYPE_ANY) { if(type != MyMoneySchedule::TYPE_ANY) {
if(type != (*pos).type()) { if(type != (*pos).type()) {
@ -1288,7 +1288,7 @@ const TQValueList<MyMoneySchedule> MyMoneyDatabaseMgr::scheduleList(const TQStri
*/ */
} }
// tqDebug("Adding '%s'", (*pos).name().latin1()); // tqDebug(TQString("Adding '%1'").arg((*pos).name()));
list << *pos; list << *pos;
} }
return list; return list;
@ -1334,7 +1334,7 @@ const TQValueList<MyMoneySchedule> MyMoneyDatabaseMgr::scheduleListEx( int sched
continue; continue;
} }
// tqDebug("\tAdding '%s'", (*pos).name().latin1()); // tqDebug(TQString("\tAdding '%1'").arg((*pos).name());
list << *pos; list << *pos;
} }

@ -874,7 +874,7 @@ const MyMoneyMoney MyMoneySeqAccessMgr::balance(const TQString& id, const TQDate
{ {
MyMoneyMoney result(0); MyMoneyMoney result(0);
MyMoneyAccount acc; MyMoneyAccount acc;
// if (date != TQDate()) tqDebug ("request balance for %s at %s", id.data(), date.toString(Qt::ISODate).latin1()); // if (date != TQDate()) tqDebug(TQString("request balance for %1 at %2").arg(id).arg(date.toString(Qt::ISODate)));
if(!date.isValid() && account(id).accountType() != MyMoneyAccount::Stock) { if(!date.isValid() && account(id).accountType() != MyMoneyAccount::Stock) {
if(m_accountList.find(id) != m_accountList.end()) if(m_accountList.find(id) != m_accountList.end())
return m_accountList[id].balance(); return m_accountList[id].balance();
@ -1252,7 +1252,7 @@ const TQValueList<MyMoneySchedule> MyMoneySeqAccessMgr::scheduleList(
// tqDebug("scheduleList()"); // tqDebug("scheduleList()");
for(pos = m_scheduleList.begin(); pos != m_scheduleList.end(); ++pos) { for(pos = m_scheduleList.begin(); pos != m_scheduleList.end(); ++pos) {
// tqDebug(" '%s'", qPrintable((*pos).id())); // tqDebug(TQString(" '%1'").arg(qPrintable((*pos).id())));
if(type != MyMoneySchedule::TYPE_ANY) { if(type != MyMoneySchedule::TYPE_ANY) {
if(type != (*pos).type()) { if(type != (*pos).type()) {
@ -1309,7 +1309,7 @@ const TQValueList<MyMoneySchedule> MyMoneySeqAccessMgr::scheduleList(
continue; continue;
} }
// tqDebug("Adding '%s'", (*pos).name().latin1()); // tqDebug(TQString("Adding '%1'").arg((*pos).name()));
list << *pos; list << *pos;
} }
return list; return list;
@ -1378,7 +1378,7 @@ const TQValueList<MyMoneySchedule> MyMoneySeqAccessMgr::scheduleListEx(int sched
continue; continue;
} }
// tqDebug("\tAdding '%s'", (*pos).name().latin1()); // tqDebug(TQString("\tAdding '%1'").arg((*pos).name()));
list << *pos; list << *pos;
} }

@ -186,7 +186,7 @@ try {
} }
break; break;
default: default:
tqFatal("%s", TQString("%1 - unknown open mode %2").arg(__func__).arg(openMode).data()); tqFatal(TQString("%1 - unknown open mode %2").arg(__func__).arg(openMode));
} }
if (rc != 0) return (rc); if (rc != 0) return (rc);
// bypass logon check if we are creating a database // bypass logon check if we are creating a database
@ -199,7 +199,7 @@ try {
.arg(m_logonUser) .arg(m_logonUser)
.arg(m_logonAt.date().toString(Qt::ISODate)) .arg(m_logonAt.date().toString(Qt::ISODate))
.arg(m_logonAt.time().toString("hh.mm.ss")); .arg(m_logonAt.time().toString("hh.mm.ss"));
tqDebug("%s", m_error.data()); tqDebug(m_error);
close(false); close(false);
rc = -1; rc = -1;
} else { } else {
@ -209,7 +209,7 @@ try {
} }
return(rc); return(rc);
} catch (TQString& s) { } catch (TQString& s) {
tqDebug("%s",s.data()); tqDebug(s);
return (1); return (1);
} }
} }
@ -925,7 +925,7 @@ bool MyMoneyStorageSql::endCommitUnit (const TQString& callingFunction) {
// as value of this method. // as value of this method.
bool rc = true; bool rc = true;
if (callingFunction != m_commitUnitStack.top()) if (callingFunction != m_commitUnitStack.top())
tqDebug("%s", TQString("%1 - %2 s/be %3").arg(__func__).arg(callingFunction).arg(m_commitUnitStack.top()).data()); tqDebug(TQString("%1 - %2 s/be %3").arg(__func__).arg(callingFunction).arg(m_commitUnitStack.top()));
m_commitUnitStack.pop(); m_commitUnitStack.pop();
if (m_commitUnitStack.isEmpty()) { if (m_commitUnitStack.isEmpty()) {
if (!commit()) throw new MYMONEYEXCEPTION(buildError (MyMoneySqlQuery(), __func__, "ending commit unit")); if (!commit()) throw new MYMONEYEXCEPTION(buildError (MyMoneySqlQuery(), __func__, "ending commit unit"));
@ -936,7 +936,7 @@ bool MyMoneyStorageSql::endCommitUnit (const TQString& callingFunction) {
void MyMoneyStorageSql::cancelCommitUnit (const TQString& callingFunction) { void MyMoneyStorageSql::cancelCommitUnit (const TQString& callingFunction) {
DBG("*** Entering MyMoneyStorageSql::cancelCommitUnit"); DBG("*** Entering MyMoneyStorageSql::cancelCommitUnit");
if (callingFunction != m_commitUnitStack.top()) if (callingFunction != m_commitUnitStack.top())
tqDebug("%s", TQString("%1 - %2 s/be %3").arg(__func__).arg(callingFunction).arg(m_commitUnitStack.top()).data()); tqDebug(TQString("%1 - %2 s/be %3").arg(__func__).arg(callingFunction).arg(m_commitUnitStack.top()));
if (m_commitUnitStack.isEmpty()) return; if (m_commitUnitStack.isEmpty()) return;
m_commitUnitStack.clear(); m_commitUnitStack.clear();
if (!rollback()) throw new MYMONEYEXCEPTION(buildError (MyMoneySqlQuery(), __func__, "cancelling commit unit")); if (!rollback()) throw new MYMONEYEXCEPTION(buildError (MyMoneySqlQuery(), __func__, "cancelling commit unit"));
@ -2921,7 +2921,7 @@ const TQMap<TQString, MyMoneyTransaction> MyMoneyStorageSql::fetchTransactions (
int obc = whereClause.contains('('); int obc = whereClause.contains('(');
int cbc = whereClause.contains(')'); int cbc = whereClause.contains(')');
if (cbc > obc) { if (cbc > obc) {
tqFatal("invalid where clause - %s", whereClause.latin1()); tqFatal(TQString("invalid where clause - %1").arg(whereClause));
} }
while (cbc < obc) { while (cbc < obc) {
whereClause.append(")"); whereClause.append(")");
@ -3801,7 +3801,7 @@ TQString& MyMoneyStorageSql::buildError (const TQSqlQuery& q, const TQString& fu
s += TQString ("\nQuery error No %1: %2").arg(e.number()).arg(e.text()); s += TQString ("\nQuery error No %1: %2").arg(e.number()).arg(e.text());
const_cast <MyMoneyStorageSql*> (this)->m_error = s; const_cast <MyMoneyStorageSql*> (this)->m_error = s;
tqDebug("%s", s.ascii()); tqDebug(s);
const_cast <MyMoneyStorageSql*> (this)->cancelCommitUnit(function); const_cast <MyMoneyStorageSql*> (this)->cancelCommitUnit(function);
return (const_cast <MyMoneyStorageSql*> (this)->m_error); return (const_cast <MyMoneyStorageSql*> (this)->m_error);
} }

@ -362,7 +362,7 @@ int KOnlineBankingSetupWizard::ofxAccountCallback(struct OfxAccountData data, vo
kvps.setValue("kmmofx-acc-ref", TQString("%1-%2").arg(kvps.value("bankid"), kvps.value("uniqueId"))); kvps.setValue("kmmofx-acc-ref", TQString("%1-%2").arg(kvps.value("bankid"), kvps.value("uniqueId")));
} else { } else {
tqDebug("Cannot setup kmmofx-acc-ref for '%s'", kvps.value("bankname").data()); tqDebug(TQString("Cannot setup kmmofx-acc-ref for '%1'").arg(kvps.value("bankname")));
} }
kvps.setValue("protocol","OFX"); kvps.setValue("protocol","OFX");

@ -361,7 +361,7 @@ MyMoneyMoney ObjectInfoTable::investmentBalance(const MyMoneyAccount& acc)
val = val.convert(acc.fraction()); val = val.convert(acc.fraction());
value += val; value += val;
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqWarning("%s", (TQString("cannot convert stock balance of %1 to base currency: %2").arg(stock.name(), e->what())).data()); tqWarning(TQString("cannot convert stock balance of %1 to base currency: %2").arg(stock.name(), e->what()));
delete e; delete e;
} }
} }

@ -76,7 +76,7 @@ Debug::Debug( const TQString& _name ): m_methodName( _name ), m_enabled( m_sEnab
if (m_enabled) if (m_enabled)
{ {
tqDebug( "%s%s(): ENTER", m_sTabs.latin1(), m_methodName.latin1() ); tqDebug(TQString("%1%2(): ENTER").arg(m_sTabs).arg(m_methodName));
m_sTabs.append("--"); m_sTabs.append("--");
} }
} }
@ -86,7 +86,7 @@ Debug::~Debug()
if ( m_enabled ) if ( m_enabled )
{ {
m_sTabs.remove(0,2); m_sTabs.remove(0,2);
tqDebug( "%s%s(): EXIT", m_sTabs.latin1(), m_methodName.latin1() ); tqDebug(TQString("%1%2(): EXIT").arg(m_sTabs).arg(m_methodName));
if (m_methodName == m_sEnableKey) if (m_methodName == m_sEnableKey)
m_enabled = false; m_enabled = false;
@ -96,7 +96,7 @@ Debug::~Debug()
void Debug::output( const TQString& _text ) void Debug::output( const TQString& _text )
{ {
if ( m_enabled ) if ( m_enabled )
tqDebug( "%s%s(): %s", m_sTabs.latin1(), m_methodName.latin1(), _text.latin1() ); tqDebug(TQString("%1%2(): %3").arg(m_sTabs).arg(m_methodName).arg(_text));
} }
PivotTable::PivotTable( const MyMoneyReport& _config_f ): PivotTable::PivotTable( const MyMoneyReport& _config_f ):
@ -194,7 +194,7 @@ void PivotTable::init(void)
try { try {
transactions = file->transactionList(m_config_f); transactions = file->transactionList(m_config_f);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("ERR: %s thrown in %s(%ld)", e->what().data(), e->file().data(), e->line()); tqDebug(TQString("ERR: %1 thrown in %2(%s)").arg(e->what()).arg(e->file()).arg(e->line()));
throw e; throw e;
} }
DEBUG_OUTPUT(TQString("Found %1 matching transactions").arg(transactions.count())); DEBUG_OUTPUT(TQString("Found %1 matching transactions").arg(transactions.count()));

@ -567,9 +567,9 @@ void TDEGlobalLedgerView::loadView(void)
paymentAmount[it_b.key()] = MyMoneyMoney(); paymentAmount[it_b.key()] = MyMoneyMoney();
} }
tracer.printf("total balance of %s = %s", m_account.name().data(), actBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("total balance of %s = %s", m_account.name().local8Bit().data(), actBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
tracer.printf("future balance of %s = %s", m_account.name().data(), futureBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("future balance of %s = %s", m_account.name().local8Bit().data(), futureBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
tracer.printf("cleared balance of %s = %s", m_account.name().data(), clearedBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("cleared balance of %s = %s", m_account.name().local8Bit().data(), clearedBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
KMyMoneyRegister::RegisterItem* p = m_register->lastItem(); KMyMoneyRegister::RegisterItem* p = m_register->lastItem();
focusItem = 0; focusItem = 0;
@ -619,11 +619,11 @@ void TDEGlobalLedgerView::loadView(void)
if(!t->isScheduled()) { if(!t->isScheduled()) {
if(split.reconcileFlag() == MyMoneySplit::NotReconciled) { if(split.reconcileFlag() == MyMoneySplit::NotReconciled) {
tracer.printf("Reducing cleared balance by %s because %s/%s(%s) is not reconciled", (split.shares() * factor).formatMoney("", 2).data(), t->transaction().id().data(), split.id().data(), t->transaction().postDate().toString(Qt::ISODate).data()); tracer.printf("Reducing cleared balance by %s because %s/%s(%s) is not reconciled", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), t->transaction().id().local8Bit().data(), split.id().local8Bit().data(), t->transaction().postDate().toString(Qt::ISODate).local8Bit().data());
clearedBalance[split.accountId()] -= split.shares() * factor; clearedBalance[split.accountId()] -= split.shares() * factor;
} }
if(isReconciliationAccount() && t->transaction().postDate() > reconciliationDate && split.reconcileFlag() == MyMoneySplit::Cleared) { if(isReconciliationAccount() && t->transaction().postDate() > reconciliationDate && split.reconcileFlag() == MyMoneySplit::Cleared) {
tracer.printf("Reducing cleared balance by %s because we are in reconciliation, %s/%s(%s)'s date is after or on reconciliation date (%s) and is cleared", (split.shares() * factor).formatMoney("", 2).data(), t->transaction().id().data(), split.id().data(), t->transaction().postDate().toString(Qt::ISODate).data(), reconciliationDate.toString(Qt::ISODate).data()); tracer.printf("Reducing cleared balance by %s because we are in reconciliation, %s/%s(%s)'s date is after or on reconciliation date (%s) and is cleared", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), t->transaction().id().local8Bit().data(), split.id().local8Bit().data(), t->transaction().postDate().toString(Qt::ISODate).local8Bit().data(), reconciliationDate.toString(Qt::ISODate).local8Bit().data());
clearedBalance[split.accountId()] -= split.shares() * factor; clearedBalance[split.accountId()] -= split.shares() * factor;
} }
@ -638,7 +638,7 @@ void TDEGlobalLedgerView::loadView(void)
} }
if(t->transaction().postDate() > TQDate::currentDate()) { 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()); tracer.printf("Reducing actual balance by %s because %s/%s(%s) is in the future", (split.shares() * factor).formatMoney("", 2).local8Bit().data(), t->transaction().id().local8Bit().data(), split.id().local8Bit().data(), t->transaction().postDate().toString(Qt::ISODate).local8Bit().data());
actBalance[split.accountId()] -= split.shares() * factor; actBalance[split.accountId()] -= split.shares() * factor;
} }
} }
@ -647,9 +647,9 @@ void TDEGlobalLedgerView::loadView(void)
p = p->prevItem(); p = p->prevItem();
} }
tracer.printf("total balance of %s = %s", m_account.name().data(), actBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("total balance of %s = %s", m_account.name().local8Bit().data(), actBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
tracer.printf("future balance of %s = %s", m_account.name().data(), futureBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("future balance of %s = %s", m_account.name().local8Bit().data(), futureBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
tracer.printf("cleared balance of %s = %s", m_account.name().data(), clearedBalance[m_account.id()].formatMoney("", 2).data()); tracer.printf("cleared balance of %s = %s", m_account.name().local8Bit().data(), clearedBalance[m_account.id()].formatMoney("", 2).local8Bit().data());
// update statement information // update statement information
if(statement) { if(statement) {
@ -850,7 +850,7 @@ void TDEGlobalLedgerView::loadAccounts(void)
try { try {
d->m_precision = MyMoneyMoney::denomToPrec(m_account.fraction()); d->m_precision = MyMoneyMoney::denomToPrec(m_account.fraction());
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Security %s for account %s not found", m_account.currencyId().data(), m_account.name().data()); tqDebug(TQString("Security %1 for account %2 not found").arg(m_account.currencyId()).arg(m_account.name()));
delete e; delete e;
d->m_precision = 2; d->m_precision = 2;
} }
@ -959,7 +959,7 @@ bool TDEGlobalLedgerView::slotSelectAccount(const TQString& id, const TQString&
m_newAccountLoaded = true; m_newAccountLoaded = true;
slotLoadView(); slotLoadView();
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Unable to retrieve account %s", id.data()); tqDebug(TQString("Unable to retrieve account %1").arg(id));
delete e; delete e;
rc = false; rc = false;
} }
@ -1217,10 +1217,10 @@ bool TDEGlobalLedgerView::focusNextPrevChild(bool next)
w = tqApp->focusWidget(); w = tqApp->focusWidget();
while(w && m_tabOrderWidgets.find(w) == -1) { while(w && m_tabOrderWidgets.find(w) == -1) {
// tqDebug("'%s' not in list, use parent", w->className()); // tqDebug(TQString("'%1' not in list, use parent").arg(w->className()));
w = w->parentWidget(); w = w->parentWidget();
} }
// if(w) tqDebug("tab order is at '%s'", w->className()); // if(w) tqDebug(TQString("tab order is at '%1'").arg(w->className()));
currentWidget = m_tabOrderWidgets.current(); currentWidget = m_tabOrderWidgets.current();
w = next ? m_tabOrderWidgets.next() : m_tabOrderWidgets.prev(); w = next ? m_tabOrderWidgets.next() : m_tabOrderWidgets.prev();
@ -1232,7 +1232,7 @@ bool TDEGlobalLedgerView::focusNextPrevChild(bool next)
if(w != currentWidget if(w != currentWidget
&& ((w->focusPolicy() & TQ_TabFocus) == TQ_TabFocus) && ((w->focusPolicy() & TQ_TabFocus) == TQ_TabFocus)
&& w->isVisible() && w->isEnabled()) { && w->isVisible() && w->isEnabled()) {
// tqDebug("Selecting '%s' as focus", w->className()); // tqDebug(TQString("Selecting '%1' as focus").arg(w->className()));
w->setFocus(); w->setFocus();
rc = true; rc = true;
break; break;
@ -1273,14 +1273,14 @@ bool TDEGlobalLedgerView::eventFilter(TQObject* o, TQEvent* e)
if(e->type() == TQEvent::KeyPress) { if(e->type() == TQEvent::KeyPress) {
TQKeyEvent *k = TQT_TQKEYEVENT(e); TQKeyEvent *k = TQT_TQKEYEVENT(e);
if(m_inEditMode) { if(m_inEditMode) {
// tqDebug("object = %s, key = %d", o->className(), k->key()); // tqDebug(TQString("object = %1, key = %2").arg(o->className()).arg(k->key()));
if(TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_register)) { if(TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_register)) {
// we hide all key press events from the register // we hide all key press events from the register
// while editing a transaction // while editing a transaction
rc = true; rc = true;
} }
} else { } else {
// tqDebug("object = %s, key = %d", o->className(), k->key()); // tqDebug(TQString("object = %1, key = %2").arg(o->className()).arg(k->key()));
if(TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_register)) { if(TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(m_register)) {
if((k->state() & TQt::KeyButtonMask) == 0) { if((k->state() & TQt::KeyButtonMask) == 0) {
switch(k->key()) { switch(k->key()) {
@ -1336,7 +1336,7 @@ void TDEGlobalLedgerView::slotSortOptions(void)
MyMoneyFile::instance()->modifyAccount(m_account); MyMoneyFile::instance()->modifyAccount(m_account);
ft.commit(); ft.commit();
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Unable to update sort order for account '%s': %s", m_account.name().latin1(), e->what().latin1()); tqDebug(TQString("Unable to update sort order for account '%1': %2").arg(m_account.name()).arg(e->what()));
delete e; delete e;
} }
} }

@ -191,8 +191,8 @@ void KHomeView::loadView(void)
{ {
tqDebug("Element id=test found!"); tqDebug("Element id=test found!");
TQString tagname = e.tagName().string(); TQString tagname = e.tagName().string();
tqDebug("%s",tagname.latin1()); tqDebug(tagname);
tqDebug("%s id=%s",e.tagName().string().latin1(),e.getAttribute("id").string().latin1()); tqDebug(TQString("%1 id=%2").arg(e.tagName().string()).arg(e.getAttribute("id").string()));
// Find the character data node // Find the character data node
DOM::Node n = e.firstChild(); DOM::Node n = e.firstChild();
@ -208,7 +208,7 @@ void KHomeView::loadView(void)
m_part->document().importNode(e,true); m_part->document().importNode(e,true);
m_part->document().updateRendering(); m_part->document().updateRendering();
tqDebug("Data is now %s",t.data().string().latin1()); tqDebug(TQString("Data is now %1").arg(t.data().string()));
} }
n = n.nextSibling(); n = n.nextSibling();
} }
@ -686,12 +686,12 @@ void KHomeView::showPaymentEntry(const MyMoneySchedule& sched, int cnt)
tmp += showColoredAmount(balance, balanceAfter.isNegative()); tmp += showColoredAmount(balance, balanceAfter.isNegative());
tmp += "</td>"; tmp += "</td>";
// tqDebug("paymentEntry = '%s'", tmp.latin1()); // tqDebug(TQString("paymentEntry = '%1'").arg(tmp));
m_part->write(tmp); m_part->write(tmp);
} }
} }
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Unable to display schedule entry: %s", e->what().data()); tqDebug(TQString("Unable to display schedule entry: %1").arg(e->what()));
delete e; delete e;
} }
} }
@ -872,7 +872,7 @@ void KHomeView::showAccountEntry(const MyMoneyAccount& acc, const MyMoneyMoney&
tmp += TQString("<td class=\"right\">%1</td>").arg(showColoredAmount(amountToMinBal, valueToMinBal.isNegative())); tmp += TQString("<td class=\"right\">%1</td>").arg(showColoredAmount(amountToMinBal, valueToMinBal.isNegative()));
} }
} }
// tqDebug("accountEntry = '%s'", tmp.latin1()); // tqDebug(TQString("accountEntry = '%1'").arg(tmp));
m_part->write(tmp); m_part->write(tmp);
} }
@ -897,7 +897,7 @@ MyMoneyMoney KHomeView::investmentBalance(const MyMoneyAccount& acc)
val = val.convert(acc.fraction()); val = val.convert(acc.fraction());
value += val; value += val;
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqWarning("%s", (TQString("cannot convert stock balance of %1 to base currency: %2").arg(stock.name(), e->what())).data()); tqWarning(TQString("cannot convert stock balance of %1 to base currency: %2").arg(stock.name(), e->what()));
delete e; delete e;
} }
} }
@ -1188,7 +1188,7 @@ void KHomeView::slotOpenURL(const KURL &url, const KParts::URLArgs& /* args */)
loadView(); loadView();
} else { } else {
tqDebug("Unknown view '%s' in KHomeView::slotOpenURL()", view.latin1()); tqDebug(TQString("Unknown view '%1' in KHomeView::slotOpenURL()").arg(view));
} }
} }
} }

@ -185,7 +185,7 @@ void KInvestmentView::loadAccounts(void)
try { try {
d->m_precision = MyMoneyMoney::denomToPrec(d->m_account.fraction()); d->m_precision = MyMoneyMoney::denomToPrec(d->m_account.fraction());
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Security %s for account %s not found", d->m_account.currencyId().data(), d->m_account.name().data()); tqDebug(TQString("Security %1 for account %2 not found").arg(d->m_account.currencyId()).arg(d->m_account.name()));
delete e; delete e;
d->m_precision = 2; d->m_precision = 2;
} }
@ -234,7 +234,7 @@ bool KInvestmentView::slotSelectAccount(const TQString& id, const TQString& tran
} }
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Unable to retrieve account %s", id.data()); tqDebug(TQString("Unable to retrieve account %1").arg(id));
delete e; delete e;
rc = false; rc = false;
} }

@ -559,7 +559,7 @@ bool KMyMoneyView::readFile(const KURL& url)
#else #else
if(url.isMalformed()) { if(url.isMalformed()) {
#endif #endif
tqDebug("Invalid URL '%s'", url.url().latin1()); tqDebug(TQString("Invalid URL '%1'").arg(url.url()));
return false; return false;
} }
@ -911,7 +911,7 @@ bool KMyMoneyView::initializeStorage()
// Check if we have to modify the file before we allow to work with it // Check if we have to modify the file before we allow to work with it
IMyMoneyStorage* s = MyMoneyFile::instance()->storage(); IMyMoneyStorage* s = MyMoneyFile::instance()->storage();
while (s->fileFixVersion() < s->currentFixVersion()) { while (s->fileFixVersion() < s->currentFixVersion()) {
tqDebug("%s", (TQString("testing fileFixVersion %1 < %2").arg(s->fileFixVersion()).arg(s->currentFixVersion())).data()); tqDebug(TQString("testing fileFixVersion %1 < %2").arg(s->fileFixVersion()).arg(s->currentFixVersion()));
switch (s->fileFixVersion()) { switch (s->fileFixVersion()) {
case 0: case 0:
fixFile_0(); fixFile_0();
@ -1308,7 +1308,7 @@ void KMyMoneyView::selectBaseCurrency(void)
file->modifyAccount(*it); file->modifyAccount(*it);
ft.commit(); ft.commit();
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Unable to setup base currency in account %s (%s): %s", (*it).name().latin1(), (*it).id().data(), e->what().latin1()); tqDebug(TQString("Unable to setup base currency in account %1 (%2): %3").arg((*it).name()).arg((*it).id()).arg(e->what()));
delete e; delete e;
} }
} }
@ -1336,7 +1336,7 @@ void KMyMoneyView::loadDefaultCurrency(const MyMoneySecurity& currency, const bo
} }
ft.commit(); ft.commit();
} catch (MyMoneyException* e) { } catch (MyMoneyException* e) {
tqDebug("Error %s loading default currency", e->what().data()); tqDebug(TQString("Error %1 loading default currency").arg(e->what()));
delete e; delete e;
} }
} }
@ -1536,7 +1536,7 @@ void KMyMoneyView::loadAncientCurrency(const TQString& id, const TQString& name,
} }
ft.commit(); ft.commit();
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Error loading currency: %s", e->what().data()); tqDebug(TQString("Error loading currency: %1").arg(e->what()));
delete e; delete e;
} }
} }
@ -1866,7 +1866,7 @@ void KMyMoneyView::fixSchedule_0(MyMoneySchedule sched)
MyMoneyFile::instance()->modifySchedule(sched); MyMoneyFile::instance()->modifySchedule(sched);
} }
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqWarning("Unable to update broken schedule: %s", e->what().latin1()); tqWarning(TQString("Unable to update broken schedule: %1").arg(e->what()));
delete e; delete e;
} }
} }
@ -2082,7 +2082,7 @@ void KMyMoneyView::fixTransactions_0(void)
file->modifyTransaction(*it_t); file->modifyTransaction(*it_t);
} }
splits = (*it_t).splits(); // update local copy splits = (*it_t).splits(); // update local copy
tqDebug("Fixed credit card assignment in %s", (*it_t).id().data()); tqDebug(TQString("Fixed credit card assignment in %1").arg((*it_t).id()));
} }
#endif #endif
@ -2104,7 +2104,7 @@ void KMyMoneyView::fixTransactions_0(void)
(*it_s).setAction(MyMoneySplit::ActionInterest); (*it_s).setAction(MyMoneySplit::ActionInterest);
(*it_t).modifySplit(*it_s); (*it_t).modifySplit(*it_s);
file->modifyTransaction(*it_t); file->modifyTransaction(*it_t);
tqDebug("Fixed interest action in %s", (*it_t).id().data()); tqDebug(TQString("Fixed interest action in %1").arg((*it_t).id()));
} }
// if it does not reference an interest account, it must not be // if it does not reference an interest account, it must not be
// of type ActionInterest // of type ActionInterest
@ -2114,7 +2114,7 @@ void KMyMoneyView::fixTransactions_0(void)
(*it_s).setAction(defaultAction); (*it_s).setAction(defaultAction);
(*it_t).modifySplit(*it_s); (*it_t).modifySplit(*it_s);
file->modifyTransaction(*it_t); file->modifyTransaction(*it_t);
tqDebug("Fixed interest action in %s", (*it_t).id().data()); tqDebug(TQString("Fixed interest action in %1").arg((*it_t).id()));
} }
} }
@ -2134,14 +2134,14 @@ void KMyMoneyView::fixTransactions_0(void)
try { try {
int fract = splitAccount.fraction(); int fract = splitAccount.fraction();
if((*it_s).shares() != (*it_s).shares().convert(fract)) { if((*it_s).shares() != (*it_s).shares().convert(fract)) {
tqDebug("adjusting fraction in %s,%s", (*it_t).id().data(), (*it_s).id().data()); tqDebug(TQString("adjusting fraction in %1,%2").arg((*it_t).id()).arg((*it_s).id()));
(*it_s).setShares((*it_s).shares().convert(fract)); (*it_s).setShares((*it_s).shares().convert(fract));
(*it_s).setValue((*it_s).value().convert(fract)); (*it_s).setValue((*it_s).value().convert(fract));
(*it_t).modifySplit(*it_s); (*it_t).modifySplit(*it_s);
file->modifyTransaction(*it_t); file->modifyTransaction(*it_t);
} }
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("Missing security '%s', split not altered", splitAccount.currencyId().data()); tqDebug(TQString("Missing security '%1', split not altered").arg(splitAccount.currencyId()));
delete e; delete e;
} }
} }
@ -2164,7 +2164,7 @@ void KMyMoneyView::fixTransactions_0(void)
void KMyMoneyView::fixDuplicateAccounts_0(MyMoneyTransaction& t) void KMyMoneyView::fixDuplicateAccounts_0(MyMoneyTransaction& t)
{ {
tqDebug("Duplicate account in transaction %s", t.id().data()); tqDebug(TQString("Duplicate account in transaction %1").arg(t.id()));
} }
void KMyMoneyView::slotPrintView(void) void KMyMoneyView::slotPrintView(void)

@ -488,7 +488,7 @@ void KScheduledView::slotSetSelectedItem(TQListViewItem* item)
emit scheduleSelected(schedule); emit scheduleSelected(schedule);
m_selectedSchedule = schedItem->scheduleId(); m_selectedSchedule = schedItem->scheduleId();
} catch(MyMoneyException* e) { } catch(MyMoneyException* e) {
tqDebug("KScheduledView::slotSetSelectedItem: %s", e->what().data()); tqDebug(TQString("KScheduledView::slotSetSelectedItem: %1").arg(e->what()));
delete e; delete e;
} }
} }

@ -188,7 +188,7 @@ void KAccountTemplateSelector::slotLoadTemplateList(void)
TQStringList::iterator it; TQStringList::iterator it;
for(it = d->dirlist.begin(); it != d->dirlist.end(); ++it) { for(it = d->dirlist.begin(); it != d->dirlist.end(); ++it) {
TQDir dir(*it); TQDir dir(*it);
// tqDebug("Reading dir '%s' with %d entries", (*it).data(), dir.count()); // tqDebug(TQSttring("Reading dir '%1' with %2 entries").arg(*it).arg(dir.count()));
dirs = dir.entryList("*", TQDir::Dirs); dirs = dir.entryList("*", TQDir::Dirs);
TQStringList::iterator it_d; TQStringList::iterator it_d;
for(it_d= dirs.begin(); it_d != dirs.end(); ++it_d) { for(it_d= dirs.begin(); it_d != dirs.end(); ++it_d) {
@ -218,7 +218,7 @@ void KAccountTemplateSelector::slotLoadTemplateList(void)
TQString country = TDEGlobal::locale()->twoAlphaToCountryName((*it_d).upper()); TQString country = TDEGlobal::locale()->twoAlphaToCountryName((*it_d).upper());
d->countries[country] = *it_d; d->countries[country] = *it_d;
} else { } else {
tqDebug("'%s/%s' not scanned", (*it).data(), (*it_d).data()); tqDebug(TQString("'%1/%2' not scanned").arg(*it).arg(*it_d));
} }
} }
} }

@ -90,7 +90,7 @@ void KMyMoneyAccountCombo::setSelected(const TQString& id)
MyMoneyAccount acc = MyMoneyFile::instance()->account(id); MyMoneyAccount acc = MyMoneyFile::instance()->account(id);
setSelected(acc); setSelected(acc);
} catch(MyMoneyException *e) { } catch(MyMoneyException *e) {
tqDebug("Account '%s' not found in %s(%d)", id.data(), __FILE__, __LINE__); tqDebug(TQString("Account '%1' not found in %2(%3)").arg(id).arg(__FILE__).arg(__LINE__));
delete e; delete e;
} }
} else { } else {

@ -637,7 +637,7 @@ void Register::dropEvent(TQDropEvent* event)
tqDebug("Drop was ok"); tqDebug("Drop was ok");
KURL::List urls; KURL::List urls;
KURLDrag::decode(event, urls); KURLDrag::decode(event, urls);
tqDebug("List is '%s'", urls.toStringList().join(";").data()); tqDebug(TQString("List is '%s'").arg(urls.toStringList().join(";")));
event->accept(); event->accept();
} }
} }
@ -671,7 +671,7 @@ void Register::slotAutoColumnSizing(int section)
} }
size += TQString("%1").arg((columnWidth(i) * 100) / w); size += TQString("%1").arg((columnWidth(i) * 100) / w);
} }
tqDebug("size = %s", size.data()); tqDebug(TQString("size = %1").arg(size));
m_account.setValue("kmm-ledger-column-width", size); m_account.setValue("kmm-ledger-column-width", size);
} }
#endif #endif

@ -570,7 +570,7 @@ void KGPGFile::publicKeyList(TQStringList& list, const TQString& pattern)
val = TQString("%1:%2").arg(currentKey).arg(fields[9]); val = TQString("%1:%2").arg(currentKey).arg(fields[9]);
map[val] = val; map[val] = val;
} else { } else {
tqDebug("'%s' is expired", fields[9].data()); tqDebug(TQString("'%1' is expired").arg(fields[9]));
} }
} else if(fields[0] == "uid") { } else if(fields[0] == "uid") {
val = TQString("%1:%2").arg(currentKey).arg(fields[9]); val = TQString("%1:%2").arg(currentKey).arg(fields[9]);

Loading…
Cancel
Save