summaryrefslogtreecommitdiffstats
path: root/filesharing/simple/krichtextlabel.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
commit47c8a359c5276062c4bc17f0e82410f29081b502 (patch)
tree2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /filesharing/simple/krichtextlabel.cpp
parent6f82532777a35e0e60bbd2b290b2e93e646f349b (diff)
downloadtdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz
tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'filesharing/simple/krichtextlabel.cpp')
-rw-r--r--filesharing/simple/krichtextlabel.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/filesharing/simple/krichtextlabel.cpp b/filesharing/simple/krichtextlabel.cpp
index 458ade62..089635d7 100644
--- a/filesharing/simple/krichtextlabel.cpp
+++ b/filesharing/simple/krichtextlabel.cpp
@@ -18,35 +18,35 @@
#include "krichtextlabel.h"
-#include <qtooltip.h>
-#include <qstylesheet.h>
-#include <qsimplerichtext.h>
+#include <tqtooltip.h>
+#include <tqstylesheet.h>
+#include <tqsimplerichtext.h>
#include <kglobalsettings.h>
-static QString qrichtextify( const QString& text )
+static TQString qrichtextify( const TQString& text )
{
if ( text.isEmpty() || text[0] == '<' )
return text;
- QStringList lines = QStringList::split('\n', text);
- for(QStringList::Iterator it = lines.begin(); it != lines.end(); ++it)
+ TQStringList lines = TQStringList::split('\n', text);
+ for(TQStringList::Iterator it = lines.begin(); it != lines.end(); ++it)
{
- *it = QStyleSheet::convertFromPlainText( *it, QStyleSheetItem::WhiteSpaceNormal );
+ *it = TQStyleSheet::convertFromPlainText( *it, TQStyleSheetItem::WhiteSpaceNormal );
}
- return lines.join(QString::null);
+ return lines.join(TQString::null);
}
-KRichTextLabel::KRichTextLabel( const QString &text , QWidget *parent, const char *name )
- : QLabel ( parent, name ) {
+KRichTextLabel::KRichTextLabel( const TQString &text , TQWidget *parent, const char *name )
+ : TQLabel ( parent, name ) {
m_defaultWidth = QMIN(400, KGlobalSettings::desktopGeometry(this).width()*2/5);
setAlignment( Qt::WordBreak );
setText(text);
}
-KRichTextLabel::KRichTextLabel( QWidget *parent, const char *name )
- : QLabel ( parent, name ) {
+KRichTextLabel::KRichTextLabel( TQWidget *parent, const char *name )
+ : TQLabel ( parent, name ) {
m_defaultWidth = QMIN(400, KGlobalSettings::desktopGeometry(this).width()*2/5);
setAlignment( Qt::WordBreak );
}
@@ -57,17 +57,17 @@ void KRichTextLabel::setDefaultWidth(int defaultWidth)
updateGeometry();
}
-QSizePolicy KRichTextLabel::sizePolicy() const
+TQSizePolicy KRichTextLabel::sizePolicy() const
{
- return QSizePolicy(QSizePolicy::MinimumExpanding, QSizePolicy::Minimum, false);
+ return TQSizePolicy(TQSizePolicy::MinimumExpanding, TQSizePolicy::Minimum, false);
}
-QSize KRichTextLabel::minimumSizeHint() const
+TQSize KRichTextLabel::minimumSizeHint() const
{
- QString qt_text = qrichtextify( text() );
+ TQString qt_text = qrichtextify( text() );
int pref_width = 0;
int pref_height = 0;
- QSimpleRichText rt(qt_text, font());
+ TQSimpleRichText rt(qt_text, font());
pref_width = m_defaultWidth;
rt.setWidth(pref_width);
int used_width = rt.widthUsed();
@@ -94,16 +94,16 @@ QSize KRichTextLabel::minimumSizeHint() const
pref_width = used_width;
}
- return QSize(pref_width, rt.height());
+ return TQSize(pref_width, rt.height());
}
-QSize KRichTextLabel::sizeHint() const
+TQSize KRichTextLabel::sizeHint() const
{
return minimumSizeHint();
}
-void KRichTextLabel::setText( const QString &text ) {
- QLabel::setText(text);
+void KRichTextLabel::setText( const TQString &text ) {
+ TQLabel::setText(text);
}
void KRichTextLabel::virtual_hook( int, void* )