diff options
author | Timothy Pearson <[email protected]> | 2011-12-16 09:56:28 -0600 |
---|---|---|
committer | Timothy Pearson <[email protected]> | 2011-12-16 09:56:28 -0600 |
commit | 1bc598742e8dcd7c3f72d892b2c3dd618496b79c (patch) | |
tree | 9a10a647deb5047c499f26e3c19380d9bea64a7f /src/notes.cpp | |
parent | 58ed6eb0cbce97f0c662eaafc536fd0399466ede (diff) | |
download | knowit-1bc598742e8dcd7c3f72d892b2c3dd618496b79c.tar.gz knowit-1bc598742e8dcd7c3f72d892b2c3dd618496b79c.zip |
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit 58ed6eb0cbce97f0c662eaafc536fd0399466ede.
Diffstat (limited to 'src/notes.cpp')
-rw-r--r-- | src/notes.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/notes.cpp b/src/notes.cpp index faf0786..870c7af 100644 --- a/src/notes.cpp +++ b/src/notes.cpp @@ -19,8 +19,8 @@ #include <tqstringlist.h> #include <tqfile.h> #include <tqdatetime.h> -#include <textstream.h> -#include <textcodec.h> +#include <tqtextstream.h> +#include <tqtextcodec.h> #include <klocale.h> #include <klistview.h> #include <kglobal.h> @@ -51,8 +51,8 @@ TQString TNoteLink::text(int fmt) const if (fmt == LinkOnly || description.isEmpty()) return link; else if (fmt == DescriptionOnly) return description; else if (fmt == LinkDescription) - return TQString("%1 (%2)").arg(link).arg(description); - else return TQString("%1 (%2)").arg(description).arg(link); + return TQString("%1 (%2)").tqarg(link).tqarg(description); + else return TQString("%1 (%2)").tqarg(description).tqarg(link); } TQPixmap TNoteLink::icon() const @@ -238,7 +238,7 @@ bool TNote::saveHTML(const KURL& fname, const TQString& origname, const TQString ts << "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\">\n" "<html>\n<head>\n <title>" << i18n("KnowIt document") << TQString("</title>\n <meta http-equiv=\"Content-Type\" " - "content=\"text/html; charset=%1\">\n").arg(ts.codec()->mimeName()); + "content=\"text/html; charset=%1\">\n").tqarg(ts.codec()->mimeName()); if (!style.isEmpty()) ts << " <style type=\"text/css\">\n " << style << "\n </style>\n"; ts << "</head>\n\n<body>\n"; @@ -246,7 +246,7 @@ bool TNote::saveHTML(const KURL& fname, const TQString& origname, const TQString TQValueVector<int> Depths; Depths.append(0); if (flags & TOC) { - ts << TQString("<h1>%1</h1>\n").arg(i18n("Table of contents")); + ts << TQString("<h1>%1</h1>\n").tqarg(i18n("Table of contents")); saveHTMLTocEntry(ts, Depths, flags); ts << "\n\n"; } @@ -256,9 +256,9 @@ bool TNote::saveHTML(const KURL& fname, const TQString& origname, const TQString saveHTMLBuf(ts, Depths, flags); TQString epilog = i18n("Exported from %1 by KnowIt %2, %3."); - ts << "<br><br><br><small>" << epilog.arg(origname) - .arg(VERSION) - .arg(TQDateTime::currentDateTime().toString()) << "</small>\n\n"; + ts << "<br><br><br><small>" << epilog.tqarg(origname) + .tqarg(VERSION) + .tqarg(TQDateTime::tqcurrentDateTime().toString()) << "</small>\n\n"; ts << "</body>\n</html>\n\n"; return true; } @@ -272,12 +272,12 @@ bool TNote::saveHTMLBuf(TQTextStream& ts, TQValueVector<int>& depths, else if (hlevel > 3) hlevel = 3; TQString id, number; for (uint i=0; i<depths.count(); i++) - id += TQString("%1.").arg(depths[i]); + id += TQString("%1.").tqarg(depths[i]); if (flags & Enumerate) number = id + " "; - ts << TQString("<h%1 id=\"S%2\">%3%4</h%5>").arg(hlevel).arg(id).arg(number) - .arg(item->text(0)).arg(hlevel); + ts << TQString("<h%1 id=\"S%2\">%3%4</h%5>").tqarg(hlevel).tqarg(id).tqarg(number) + .tqarg(item->text(0)).tqarg(hlevel); TQString htmltext = text; int begin = htmltext.find("<body"); if (begin >= 0) begin = htmltext.find(">", begin); @@ -289,14 +289,14 @@ bool TNote::saveHTMLBuf(TQTextStream& ts, TQValueVector<int>& depths, /* save links */ for (TQValueList<TNoteLink>::Iterator LinkList = links.begin(); LinkList != links.end(); ++LinkList) - ts << TQString("<a href=\"%1\">%2</a><br>\n").arg((*LinkList).link) - .arg((*LinkList).text(TNoteLink::DescriptionOnly)); + ts << TQString("<a href=\"%1\">%2</a><br>\n").tqarg((*LinkList).link) + .tqarg((*LinkList).text(TNoteLink::DescriptionOnly)); /* save rule */ if (flags & AddRule) ts << "<hr size=\"1\" noshade>\n\n"; else ts << "\n\n"; - /* save children */ + /* save tqchildren */ if ((SaveSubnotes | SaveAll) & flags && item->childCount()) { depths.append(0); collection->find(item->firstChild())->saveHTMLBuf(ts, depths, flags); @@ -321,11 +321,11 @@ bool TNote::saveHTMLTocEntry(TQTextStream& ts, TQValueVector<int>& depths, int f TQString id, number; for (uint i=0; i<depths.count(); i++) - id += TQString("%1.").arg(depths[i]); + id += TQString("%1.").tqarg(depths[i]); if (flags & Enumerate) number = id + " "; ts << space; - ts << TQString("<dt><a href=\"#S%1\">%2%3</a></dt>\n").arg(id).arg(number). + ts << TQString("<dt><a href=\"#S%1\">%2%3</a></dt>\n").tqarg(id).tqarg(number). arg(item->text(0)); if ((SaveSubnotes | SaveAll) & flags && item->childCount()) { depths.append(0); @@ -397,9 +397,9 @@ void TNote::save(TQTextStream& ts, bool current) const TQString activeheader = "\\CurrentEntry %1 %2\n"; if (current) - ts << activeheader.arg(item->depth()).arg(item->text(0)); + ts << activeheader.tqarg(item->depth()).tqarg(item->text(0)); else - ts << header.arg(item->depth()).arg(item->text(0)); + ts << header.tqarg(item->depth()).tqarg(item->text(0)); for (TQValueList<TNoteLink>::Iterator LinkList = links.begin(); LinkList != links.end(); ++LinkList) (*LinkList).save(ts); |