summaryrefslogtreecommitdiffstats
path: root/grapher/Graph.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'grapher/Graph.hxx')
-rw-r--r--grapher/Graph.hxx8
1 files changed, 8 insertions, 0 deletions
diff --git a/grapher/Graph.hxx b/grapher/Graph.hxx
index d9f615b3..0853d988 100644
--- a/grapher/Graph.hxx
+++ b/grapher/Graph.hxx
@@ -51,6 +51,14 @@ public:
int64_t getTimeAtPoint(double x);
void window2GraphCoords(double x, double y, double& xgraph, double& ygraph);
static void setCurrentTime(int64_t time) { _currentTime = time; }
+
+ /*
+ * universal horizontal factor
+ */
+ double getHorizontalScale()
+ {
+ return _zoomFactor * _graphWidth / static_cast<double>(_right - _left);
+ }
protected:
GraphDataList _datasets;
int64_t _left;