[Kst] [Bug 111850] Data Wizard mungs Axis Labels when no label generation requested
netterfield@astro.utoronto.ca
netterfield at astro.utoronto.ca
Sun Sep 4 00:28:28 CEST 2005
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
http://bugs.kde.org/show_bug.cgi?id=111850
netterfield astro utoronto ca changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution| |FIXED
------- Additional Comments From netterfield astro utoronto ca 2005-09-04 00:28 -------
SVN commit 456870 by netterfield:
BUG: 111850
Selecting to update labels updates the labels (adds new curve to the
list)
Selecting to not update labels does nothing to the labels.
There is now no way to add a curve but delete the labels from
the data manager.
M +3 -12 datawizard.ui.h
M +7 -4 kst2dplot.cpp
M +1 -1 kst2dplot.h
--- trunk/extragear/graphics/kst/kst/datawizard.ui.h #456869:456870
@ -6,6 +6,7 @
** init() function in place of a constructor, and a destroy() function in
** place of a destructor.
*****************************************************************************/
+#include <stdio.h>
const QString& DataWizard::defaultTag = KGlobal::staticQString("<Auto Name>");
void DataWizard::init()
@ -741,7 +742,7 @
KST::dataObjectList.append(KstDataObjectPtr(c));
KST::dataObjectList.lock().writeUnlock();
if (plot) {
- plot->addCurve(KstBaseCurvePtr(c));
+ plot->addCurve(KstBaseCurvePtr(c));
}
if (!_onePlot->isChecked()) { // change plots if we are not onePlot
if (_radioButtonPlotDataPSD->isChecked()) { // if xy and psd
@ -852,16 +853,7 @
++pit;
continue;
}
- pp->GenerateDefaultLabels();
- if (!xl) {
- pp->setXLabel(QString::null);
- }
- if (!yl) {
- pp->setYLabel(QString::null);
- }
- if (!tl) {
- pp->setTopLabel(QString::null);
- }
+ pp->GenerateDefaultLabels(xl, yl, tl);
if (_legendsOn->isChecked()) {
pp->Legend->setShowing(true);
pp->Legend->setFront(true);
@ -873,7 +865,6 @
pp->Legend->setFront(true);
}
}
-
++pit;
}
--- trunk/extragear/graphics/kst/kst/kst2dplot.cpp #456869:456870
@ -2877,7 +2877,7 @
}
-void Kst2DPlot::GenerateDefaultLabels() {
+void Kst2DPlot::GenerateDefaultLabels(bool xl, bool yl, bool tl) {
QStringList xlabels, ylabels, toplabels;
QString label, xlabel, ylabel, toplabel;
int n_curves, i_curve, i_count;
@ -2946,9 +2946,12 @
EscapeSpecialChars(ylabel);
EscapeSpecialChars(toplabel);
- setXLabel(xlabel);
- setYLabel(ylabel);
- setTopLabel(toplabel);
+ if (xl)
+ setXLabel(xlabel);
+ if (yl)
+ setYLabel(ylabel);
+ if (tl)
+ setTopLabel(toplabel);
}
--- trunk/extragear/graphics/kst/kst/kst2dplot.h #456869:456870
@ -197,7 +197,7 @
KstBaseCurveList Curves;
- void GenerateDefaultLabels();
+ void GenerateDefaultLabels(bool xl = TRUE, bool yl = TRUE, bool zl = TRUE);
/* kstview tells kstplot where to offset the plot to */
void setPixRect(const QRect& RelPlotRegion, const QRect& RelWinRegion, const QRect& RelPlotAndAxisRegion);
More information about the Kst
mailing list