diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-17 17:31:58 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-17 17:31:58 +0000 |
commit | b6027ae3f71e2c1961357500b9da203e3a04a194 (patch) | |
tree | f6e7cbb9ad81542a6287c7c60602d5a38cf24457 /bibletime/frontend/display/cplainwritedisplay.cpp | |
parent | 1ed307edd091effc390a7b98986fccb0f8307582 (diff) | |
download | bibletime-b6027ae3f71e2c1961357500b9da203e3a04a194.tar.gz bibletime-b6027ae3f71e2c1961357500b9da203e3a04a194.zip |
TQt4 port Bibletime
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/bibletime@1232459 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'bibletime/frontend/display/cplainwritedisplay.cpp')
-rw-r--r-- | bibletime/frontend/display/cplainwritedisplay.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/bibletime/frontend/display/cplainwritedisplay.cpp b/bibletime/frontend/display/cplainwritedisplay.cpp index 7be7c6c..7ca99dc 100644 --- a/bibletime/frontend/display/cplainwritedisplay.cpp +++ b/bibletime/frontend/display/cplainwritedisplay.cpp @@ -17,14 +17,14 @@ #include "util/scoped_resource.h" -//Qt includes +//TQt includes //KDE includes #include <kaction.h> #include <klocale.h> -CPlainWriteDisplay::CPlainWriteDisplay(CWriteWindow* parentWindow, TQWidget* parent) : TQTextEdit(parentWindow ? parentWindow : parent), CWriteDisplay(parentWindow) { - setTextFormat(Qt::PlainText); +CPlainWriteDisplay::CPlainWriteDisplay(CWriteWindow* tqparentWindow, TQWidget* tqparent) : TQTextEdit(tqparentWindow ? tqparentWindow : tqparent), CWriteDisplay(tqparentWindow) { + setTextFormat(TQt::PlainText); setAcceptDrops(true); viewport()->setAcceptDrops(true); @@ -42,8 +42,8 @@ void CPlainWriteDisplay::selectAll() { void CPlainWriteDisplay::setText( const TQString& newText ) { //make sure the text has been converted to show \n instead of <br/> TQString text = newText; -// text.replace("\n<br /><!-- BT newline -->\n", "\n"); - text.replace("<br />", "\n"); //inserted by BT or the Qt textedit widget +// text.tqreplace("\n<br /><!-- BT newline -->\n", "\n"); + text.tqreplace("<br />", "\n"); //inserted by BT or the TQt textedit widget TQTextEdit::setText(text); } @@ -58,7 +58,7 @@ TQWidget* CPlainWriteDisplay::view() { } const TQString CPlainWriteDisplay::text( const CDisplay::TextType /*format*/, const CDisplay::TextPart /*part*/) { - return TQString::null; + return TQString(); } void CPlainWriteDisplay::print( const CDisplay::TextPart, CSwordBackend::DisplayOptions displayOptions, CSwordBackend::FilterOptions filterOptions ) { @@ -80,7 +80,7 @@ const TQString CPlainWriteDisplay::plainText() { TQString ret = TQTextEdit::text(); //in plain text mode the text just contains newlines, convert them into <br/> before we return the text for display in a HTML widget - ret.replace("\n", "<br />"); + ret.tqreplace("\n", "<br />"); return ret; } @@ -138,7 +138,7 @@ void CPlainWriteDisplay::contentsDropEvent( TQDropEvent* e ) { TQString moduleText = key->strippedText(); - const TQString text = TQString::fromLatin1("%1\n(%2, %3)\n").arg(moduleText).arg((*it).bookmarkKey()).arg((*it).bookmarkModule()); + const TQString text = TQString::tqfromLatin1("%1\n(%2, %3)\n").tqarg(moduleText).tqarg((*it).bookmarkKey()).tqarg((*it).bookmarkModule()); placeCursor( e->pos() ); insert( text ); |