diff options
Diffstat (limited to 'libkdchart/KDChartObjectFactory.cpp')
-rw-r--r-- | libkdchart/KDChartObjectFactory.cpp | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/libkdchart/KDChartObjectFactory.cpp b/libkdchart/KDChartObjectFactory.cpp index b1dac73..6e2a128 100644 --- a/libkdchart/KDChartObjectFactory.cpp +++ b/libkdchart/KDChartObjectFactory.cpp @@ -15,42 +15,42 @@ // PENDING(blackie) Clean up code in this file, so it uses the correct getter methods like getBool. KDChartObjectFactory::KDChartObjectFactory() { - registerClass( TQString::tqfromLatin1( "KDChartWidget" ) ); - registerClass( TQString::tqfromLatin1( "KDChartParams" ), new KDChartParams ); - registerClass( TQString::tqfromLatin1( "KDChartTableData" ) ); - registerClass( TQString::tqfromLatin1( "KDChartAxisParams" ), new KDChartAxisParams ); - registerClass( TQString::tqfromLatin1( "KDChartEnums" ), 0, new KDChartEnums ); - registerClass( TQString::tqfromLatin1( "KDChartTextPiece" ) ); - registerClass( TQString::tqfromLatin1( "KDChartCustomBox" ), new KDChartCustomBox ); - registerClass( TQString::tqfromLatin1( "KDChartPropertySet" ), new KDChartPropertySet ); - registerClass( TQString::tqfromLatin1( "KDFrame" ), TQString(), new KDFrame ); - - registerClass( TQString::tqfromLatin1( "TQt" ), TQString(), new TQtFactory() ); - registerClass( TQString::tqfromLatin1( "TQFont" ), TQString(), new TQFontFactory ); + registerClass( TQString::fromLatin1( "KDChartWidget" ) ); + registerClass( TQString::fromLatin1( "KDChartParams" ), new KDChartParams ); + registerClass( TQString::fromLatin1( "KDChartTableData" ) ); + registerClass( TQString::fromLatin1( "KDChartAxisParams" ), new KDChartAxisParams ); + registerClass( TQString::fromLatin1( "KDChartEnums" ), 0, new KDChartEnums ); + registerClass( TQString::fromLatin1( "KDChartTextPiece" ) ); + registerClass( TQString::fromLatin1( "KDChartCustomBox" ), new KDChartCustomBox ); + registerClass( TQString::fromLatin1( "KDChartPropertySet" ), new KDChartPropertySet ); + registerClass( TQString::fromLatin1( "KDFrame" ), TQString(), new KDFrame ); + + registerClass( TQString::fromLatin1( "TQt" ), TQString(), new TQtFactory() ); + registerClass( TQString::fromLatin1( "TQFont" ), TQString(), new TQFontFactory ); } TQObject* KDChartObjectFactory::create( const TQString& className, const TQSArgumentList& args, TQObject* /*context*/ ) { - if ( className == TQString::tqfromLatin1( "KDChartWidget" ) ) + if ( className == TQString::fromLatin1( "KDChartWidget" ) ) return createKDChartWidget( args ); - if ( className == TQString::tqfromLatin1("KDChartParams") ) + if ( className == TQString::fromLatin1("KDChartParams") ) return new KDChartParams(); - else if ( className == TQString::tqfromLatin1("KDChartTableData") ) + else if ( className == TQString::fromLatin1("KDChartTableData") ) return createKDChartTableData( args ); - else if ( className == TQString::tqfromLatin1("KDChartAxisParams") ) + else if ( className == TQString::fromLatin1("KDChartAxisParams") ) return new KDChartAxisParams(); - else if ( className == TQString::tqfromLatin1( "KDChartTextPiece" ) ) + else if ( className == TQString::fromLatin1( "KDChartTextPiece" ) ) return createKDChartTextPiece( args ); - else if ( className == TQString::tqfromLatin1( "KDChartCustomBox" ) ) + else if ( className == TQString::fromLatin1( "KDChartCustomBox" ) ) return createKDChartCustomBox( args ); - else if ( className == TQString::tqfromLatin1( "KDChartPropertySet" ) ) + else if ( className == TQString::fromLatin1( "KDChartPropertySet" ) ) return createKDChartPropertySet( args ); else @@ -98,7 +98,7 @@ TQObject* KDChartObjectFactory::createKDChartTextPiece( const TQSArgumentList& a TQString str; if ( !getString( args, 1, &str, "KDChartTextPiece" ) ) return 0; - if ( !checkIsTQtVariant( args, 2, TQVariant::Font, TQString::tqfromLatin1( "TQFont" ), "KDChartTextPiece" ) ) return 0; + if ( !checkIsTQtVariant( args, 2, TQVariant::Font, TQString::fromLatin1( "TQFont" ), "KDChartTextPiece" ) ) return 0; TQFont font = args[1].variant().toFont(); return new KDChartTextPiece( str, font ); @@ -145,13 +145,13 @@ TQObject* KDChartObjectFactory::createKDChartCustomBox( const TQSArgumentList& a TQColor color = TQt::black; if ( args.count() >= 9 ) { - if ( !checkIsTQtVariant( args, 9, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartCustomBox" ) ) return 0; + if ( !checkIsTQtVariant( args, 9, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartCustomBox" ) ) return 0; color = args[8].variant().toColor(); } TQBrush paper = TQt::NoBrush; if ( args.count() >= 10 ) { - if ( !checkIsTQtVariant( args, 10, TQVariant::Brush, TQString::tqfromLatin1( "TQBrush" ), "KDChartCustomBox" ) ) return 0; + if ( !checkIsTQtVariant( args, 10, TQVariant::Brush, TQString::fromLatin1( "TQBrush" ), "KDChartCustomBox" ) ) return 0; paper = args[9].variant().toBrush(); } @@ -235,13 +235,13 @@ TQObject* KDChartObjectFactory::createKDChartCustomBox( const TQSArgumentList& a TQColor color = TQt::black; if ( args.count() >= 8 ) { - if ( !checkIsTQtVariant( args, 8, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartCustomBox" ) ) return 0; + if ( !checkIsTQtVariant( args, 8, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartCustomBox" ) ) return 0; color = args[7].variant().toColor(); } TQBrush paper = TQt::NoBrush; if ( args.count() >= 9 ) { - if ( !checkIsTQtVariant( args, 9, TQVariant::Brush, TQString::tqfromLatin1( "TQBrush" ), "KDChartCustomBox" ) ) return 0; + if ( !checkIsTQtVariant( args, 9, TQVariant::Brush, TQString::fromLatin1( "TQBrush" ), "KDChartCustomBox" ) ) return 0; paper = args[8].variant().toBrush(); } @@ -318,7 +318,7 @@ TQObject* KDChartObjectFactory::createKDChartPropertySet(const TQSArgumentList& if ( !getNumber( args, 4,&idLineColor, "KDChartPropertySet" ) ) return 0; - if ( !checkIsTQtVariant( args, 5, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; + if ( !checkIsTQtVariant( args, 5, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; TQColor lineColor = args[4].variant().toColor(); int idLineStyle; @@ -362,7 +362,7 @@ TQObject* KDChartObjectFactory::createKDChartPropertySet(const TQSArgumentList& int idExtraLinesColor; if ( !getNumber( args, 18,&idExtraLinesColor, "KDChartPropertySet" ) ) return 0; - if ( !checkIsTQtVariant( args, 19, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; + if ( !checkIsTQtVariant( args, 19, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; TQColor extraLinesColor = args[18].variant().toColor(); int idExtraLinesStyle; @@ -380,13 +380,13 @@ TQObject* KDChartObjectFactory::createKDChartPropertySet(const TQSArgumentList& int idExtraMarkersSize; if ( !getNumber( args, 24,&idExtraMarkersSize, "KDChartPropertySet" ) ) return 0; - if ( !checkIsTQtVariant( args, 25, TQVariant::Size, TQString::tqfromLatin1( "TQSize" ), "KDChartPropertySet" ) ) return 0; + if ( !checkIsTQtVariant( args, 25, TQVariant::Size, TQString::fromLatin1( "TQSize" ), "KDChartPropertySet" ) ) return 0; TQSize extraMarkersSize = args[24].variant().toSize(); int idExtraMarkersColor; if ( !getNumber( args, 26,&idExtraMarkersColor, "KDChartPropertySet" ) ) return 0; - if ( !checkIsTQtVariant( args, 27, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; + if ( !checkIsTQtVariant( args, 27, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; TQColor extraMarkersColor = args[26].variant().toColor(); int idExtraMarkersStyle; @@ -404,7 +404,7 @@ TQObject* KDChartObjectFactory::createKDChartPropertySet(const TQSArgumentList& int idBarColor; if ( !getNumber( args, 32,&idBarColor, "KDChartPropertySet" ) ) return 0; - if ( !checkIsTQtVariant( args, 33, TQVariant::Color, TQString::tqfromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; + if ( !checkIsTQtVariant( args, 33, TQVariant::Color, TQString::fromLatin1( "TQColor" ), "KDChartPropertySet" ) ) return 0; TQColor barColor = args[32].variant().toColor(); KDChartPropertySet* set = new KDChartPropertySet; |