diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kugar/kudesigner_lib/propertyserializer.cpp | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kugar/kudesigner_lib/propertyserializer.cpp')
-rw-r--r-- | kugar/kudesigner_lib/propertyserializer.cpp | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/kugar/kudesigner_lib/propertyserializer.cpp b/kugar/kudesigner_lib/propertyserializer.cpp index dc3e91e6..32ebe470 100644 --- a/kugar/kudesigner_lib/propertyserializer.cpp +++ b/kugar/kudesigner_lib/propertyserializer.cpp @@ -20,8 +20,8 @@ ***************************************************************************/ #include "propertyserializer.h" -#include <qcolor.h> -#include <qfont.h> +#include <tqcolor.h> +#include <tqfont.h> #include <kdebug.h> @@ -34,13 +34,13 @@ PropertySerializer::PropertySerializer() PropertySerializer::~PropertySerializer() {} -QString PropertySerializer::toString( Property *prop ) +TQString PropertySerializer::toString( Property *prop ) { - QVariant val = prop->value(); + TQVariant val = prop->value(); switch ( prop->type() ) { case KoProperty::Color: - return QString( "%1,%2,%3" ).arg( val.toColor().red() ).arg( val.toColor().green() ).arg( val.toColor().blue() ); + return TQString( "%1,%2,%3" ).tqarg( val.toColor().red() ).tqarg( val.toColor().green() ).tqarg( val.toColor().blue() ); case KoProperty::Boolean: return val.toBool() ? "true" : "false"; case KoProperty::Font: @@ -50,26 +50,26 @@ QString PropertySerializer::toString( Property *prop ) } } -QVariant PropertySerializer::fromString( Property *prop, const QString &str ) +TQVariant PropertySerializer::fromString( Property *prop, const TQString &str ) { switch ( prop->type() ) { case KoProperty::Color: - return QVariant( QColor( str.section( ',', 0, 0 ).toInt(), + return TQVariant( TQColor( str.section( ',', 0, 0 ).toInt(), str.section( ',', 1, 1 ).toInt(), str.section( ',', 2, 2 ).toInt() ) ); case KoProperty::Integer: - return QVariant( str.toInt() ); + return TQVariant( str.toInt() ); case KoProperty::Boolean: - return QVariant( str == "true", 3 ); + return TQVariant( str == "true", 3 ); case KoProperty::Font: - return QVariant( QFont( str ) ); + return TQVariant( TQFont( str ) ); case KoProperty::LineStyle: - return QVariant( str.toInt() ); + return TQVariant( str.toInt() ); case KoProperty::Symbol: - return QVariant( str.at( 0 ).latin1() ); + return TQVariant( str.tqat( 0 ).latin1() ); default: - return QVariant( str ); + return TQVariant( str ); } } |