mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
statistics: don't replot chart when changing features
Up to now, when the user changed the visibility of chart features (legend, quartiles, labels, etc.) the whole chart was replot. Instead, only change the visibility status of these items. After all, this modularity is one of the things the conversion to QSG was all about. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
e32e6d63a7
commit
ff536e98fc
5 changed files with 107 additions and 99 deletions
|
@ -21,7 +21,7 @@ public:
|
|||
// If keepOrder is false, bins will be sorted by size, otherwise the sorting
|
||||
// of the shown bins will be retained. Small bins are omitted for clarity.
|
||||
PieSeries(StatsView &view, StatsAxis *xAxis, StatsAxis *yAxis, const QString &categoryName,
|
||||
const std::vector<std::pair<QString, int>> &data, bool keepOrder, bool labels);
|
||||
const std::vector<std::pair<QString, int>> &data, bool keepOrder);
|
||||
~PieSeries();
|
||||
|
||||
void updatePositions() override;
|
||||
|
@ -45,7 +45,7 @@ private:
|
|||
int count;
|
||||
QPointF innerLabelPos, outerLabelPos; // With respect to a (-1, -1)-(1, 1) rectangle.
|
||||
Item(StatsView &view, const QString &name, int from, int count, int totalCount,
|
||||
int bin_nr, int numBins, bool labels);
|
||||
int bin_nr, int numBins);
|
||||
void updatePositions(const QPointF ¢er, double radius);
|
||||
void highlight(ChartPieItem &item, int bin_nr, bool highlight, int numBins);
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue