statistics: convert HistogramMarkers to QSGNodes

This is in analogy to the quartile markers.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2021-01-14 09:48:44 +01:00 committed by bstoeger
parent 790d2b2ddb
commit 218c844ad4
6 changed files with 65 additions and 46 deletions

21
stats/histogrammarker.h Normal file
View file

@ -0,0 +1,21 @@
// A line to show median an mean in histograms
#ifndef HISTOGRAM_MARKER_H
#define HISTOGRAM_MARKER_H
#include "chartitem.h"
class StatsAxis;
class StatsView;
// A line marking median or mean in histograms
class HistogramMarker : public ChartLineItem {
public:
HistogramMarker(StatsView &view, double val, bool horizontal, QColor color, StatsAxis *xAxis, StatsAxis *yAxis);
void updatePosition();
private:
StatsAxis *xAxis, *yAxis;
double val;
bool horizontal;
};
#endif