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 /kchart/kdchart/KDChartPropertySet.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 'kchart/kdchart/KDChartPropertySet.cpp')
-rw-r--r-- | kchart/kdchart/KDChartPropertySet.cpp | 60 |
1 files changed, 30 insertions, 30 deletions
diff --git a/kchart/kdchart/KDChartPropertySet.cpp b/kchart/kdchart/KDChartPropertySet.cpp index 6abec756..247a9182 100644 --- a/kchart/kdchart/KDChartPropertySet.cpp +++ b/kchart/kdchart/KDChartPropertySet.cpp @@ -31,8 +31,8 @@ #include "KDChartParams.h" #include <KDXMLTools.h> -#include <qpainter.h> -#include <qvaluestack.h> +#include <tqpainter.h> +#include <tqvaluestack.h> #include <stdlib.h> @@ -78,7 +78,7 @@ const KDChartPropertySet* KDChartPropertySet::clone() const return newSet; } -void KDChartPropertySet::quickReset( const QString& name, int idParent ) +void KDChartPropertySet::quickReset( const TQString& name, int idParent ) { // set the name mName = name; @@ -107,7 +107,7 @@ void KDChartPropertySet::quickReset( const QString& name, int idParent ) mIdAreaBrush = idParent; } -void KDChartPropertySet::fullReset( const QString& name, int idParent ) +void KDChartPropertySet::fullReset( const TQString& name, int idParent ) { quickReset( name, idParent ); fillValueMembersWithDummyValues(); @@ -117,32 +117,32 @@ void KDChartPropertySet::fillValueMembersWithDummyValues() { // fill with dummy values to avoid problems when saving us into a stream mLineWidth = 1; - mLineColor = Qt::black; + mLineColor = TQt::black; mLineStyle = Qt::SolidLine; mShowMarker = true; - mMarkerAlign = Qt::AlignCenter; - mMarkerSize = QSize(6,6); - mMarkerColor = Qt::black; + mMarkerAlign = TQt::AlignCenter; + mMarkerSize = TQSize(6,6); + mMarkerColor = TQt::black; mMarkerStyle = 0; - mExtraLinesAlign = Qt::AlignLeft|Qt::AlignTop; + mExtraLinesAlign = TQt::AlignLeft|TQt::AlignTop; mExtraLinesInFront = false; mExtraLinesLength = -20; mExtraLinesWidth = 1; - mExtraLinesColor = Qt::black; + mExtraLinesColor = TQt::black; mExtraLinesStyle = Qt::SolidLine; - mExtraMarkersAlign = Qt::AlignLeft|Qt::AlignTop; - mExtraMarkersSize = QSize(6,6); - mExtraMarkersColor = Qt::black; + mExtraMarkersAlign = TQt::AlignLeft|TQt::AlignTop; + mExtraMarkersSize = TQSize(6,6); + mExtraMarkersColor = TQt::black; mExtraMarkersStyle = 0; mShowBar = true; - mBarColor = Qt::black; - mAreaBrush = QBrush( Qt::blue ); + mBarColor = TQt::black; + mAreaBrush = TQBrush( TQt::blue ); } -QDomElement KDChartPropertySet::saveXML(QDomDocument& doc) const +TQDomElement KDChartPropertySet::saveXML(TQDomDocument& doc) const { - QDomElement propertySetElement = doc.createElement( "PropertySet" ); + TQDomElement propertySetElement = doc.createElement( "PropertySet" ); propertySetElement.setAttribute( "OwnID", mOwnID ); KDXML::createStringNode( doc, propertySetElement, "Name", mName ); // normal bar properties: @@ -159,7 +159,7 @@ QDomElement KDChartPropertySet::saveXML(QDomDocument& doc) const KDXML::createIntNode( doc, propertySetElement, "IDLineColor", mIdLineColor ); KDXML::createColorNode( doc, propertySetElement, "LineColor", mLineColor ); KDXML::createIntNode( doc, propertySetElement, "IDLineStyle", mIdLineStyle ); - QDomElement lineStyleElement = doc.createElement( "LineStyle" ); + TQDomElement lineStyleElement = doc.createElement( "LineStyle" ); propertySetElement.appendChild( lineStyleElement ); lineStyleElement.setAttribute( "Style", KDXML::penStyleToString( mLineStyle)); // normal marker properties: @@ -172,7 +172,7 @@ QDomElement KDChartPropertySet::saveXML(QDomDocument& doc) const KDXML::createIntNode( doc, propertySetElement, "IDMarkerColor", mIdMarkerColor ); KDXML::createColorNode( doc, propertySetElement, "MarkerColor", mMarkerColor ); KDXML::createIntNode( doc, propertySetElement, "IDMarkerStyle", mIdMarkerStyle ); - QDomElement markerStElem = doc.createElement( "MarkerStyle" ); + TQDomElement markerStElem = doc.createElement( "MarkerStyle" ); propertySetElement.appendChild( markerStElem ); markerStElem.setAttribute("Style", KDChartParams::lineMarkerStyleToString( (KDChartParams::LineMarkerStyle)mMarkerStyle)); @@ -188,7 +188,7 @@ QDomElement KDChartPropertySet::saveXML(QDomDocument& doc) const KDXML::createIntNode( doc, propertySetElement, "IDExtraLinesColor", mIdExtraLinesColor ); KDXML::createColorNode( doc, propertySetElement, "ExtraLinesColor", mExtraLinesColor ); KDXML::createIntNode( doc, propertySetElement, "IDExtraLinesStyle", mIdExtraLinesStyle ); - QDomElement specLineStElem = doc.createElement( "ExtraLinesStyle" ); + TQDomElement specLineStElem = doc.createElement( "ExtraLinesStyle" ); propertySetElement.appendChild( specLineStElem ); specLineStElem.setAttribute( "Style", KDXML::penStyleToString( mExtraLinesStyle)); // extra markers: @@ -199,20 +199,20 @@ QDomElement KDChartPropertySet::saveXML(QDomDocument& doc) const KDXML::createIntNode( doc, propertySetElement, "IDExtraMarkersColor", mIdExtraMarkersColor ); KDXML::createColorNode( doc, propertySetElement, "ExtraMarkersColor", mExtraMarkersColor ); KDXML::createIntNode( doc, propertySetElement, "IDExtraMarkersStyle", mIdExtraMarkersStyle ); - QDomElement specMarkerStElem = doc.createElement( "ExtraMarkersStyle" ); + TQDomElement specMarkerStElem = doc.createElement( "ExtraMarkersStyle" ); propertySetElement.appendChild( specMarkerStElem ); specMarkerStElem.setAttribute("Style", KDChartParams::lineMarkerStyleToString( (KDChartParams::LineMarkerStyle)mExtraMarkersStyle)); return propertySetElement; } -bool KDChartPropertySet::loadXML( const QDomElement& element, KDChartPropertySet& set ) +bool KDChartPropertySet::loadXML( const TQDomElement& element, KDChartPropertySet& set ) { bool bOwnIDFound = false; - QString s; - QColor color; - QBrush brush; - QSize size; + TQString s; + TQColor color; + TQBrush brush; + TQSize size; bool bValue; int i; // initialize the property set with default values @@ -222,11 +222,11 @@ bool KDChartPropertySet::loadXML( const QDomElement& element, KDChartPropertySet i = element.attribute( "OwnID" ).toInt( &bOwnIDFound ); if( bOwnIDFound ){ set.mOwnID = i; - QDomNode node = element.firstChild(); + TQDomNode node = element.firstChild(); while( !node.isNull() ) { - QDomElement element = node.toElement(); + TQDomElement element = node.toElement(); if( !element.isNull() ) { // was really an element - QString tagName = element.tagName(); + TQString tagName = element.tagName(); if( tagName == "Name" ) { if( KDXML::readStringNode( element, s ) ) set.mName = s; @@ -251,7 +251,7 @@ bool KDChartPropertySet::loadXML( const QDomElement& element, KDChartPropertySet set.mIdAreaBrush = i; } else if( tagName == "AreaBrush" ) { if( KDXML::readBrushNode( element, brush ) ) - set.mAreaBrush = color; + set.mAreaBrush = TQBrush(color); } else // normal line properties: if( tagName == "IDLineWidth" ) { |