[Kst] kdeextragear-2/kst/kst
Rick Chern
rchern at interchange.ubc.ca
Tue Jul 6 19:49:47 CEST 2004
CVS commit by rchern:
M +6 -16 kst2dplot.cpp 1.134
--- kdeextragear-2/kst/kst/kst2dplot.cpp #1.133:1.134
@@ -87,6 +87,6 @@ Kst2DPlot::Kst2DPlot(QDomElement& e) : K
//temporary colors
- QColor *in_foreColor = 0L;
- QColor *in_backColor = 0L;
+ QColor in_foreColor = KstSettings::globalSettings()->foregroundColor;
+ QColor in_backColor = KstSettings::globalSettings()->backgroundColor;
@@ -153,7 +153,7 @@ Kst2DPlot::Kst2DPlot(QDomElement& e) : K
y_log = true;
} else if (el.tagName() == "plotforecolor") {
- in_foreColor = new QColor(el.text());
+ in_foreColor.setNamedColor(el.text());
} else if (el.tagName() == "plotbackcolor") {
- in_backColor = new QColor(el.text());
+ in_backColor.setNamedColor(el.text());
}
}
@@ -201,16 +201,6 @@ Kst2DPlot::Kst2DPlot(QDomElement& e) : K
//If no colours, use default ones
- if (in_foreColor) {
- _foregroundColor = *in_foreColor;
- } else {
- _foregroundColor = KstSettings::globalSettings()->foregroundColor;
- }
- if (in_backColor) {
- _backgroundColor = *in_backColor;
- } else {
- _backgroundColor = KstSettings::globalSettings()->backgroundColor;
- }
-
-
+ _foregroundColor = in_foreColor;
+ _backgroundColor = in_backColor;
draw();
More information about the Kst
mailing list