File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed
Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -118,6 +118,23 @@ Diag::DiagramPtr Chart::diagram(
118118 stylesheet.getFullParams ());
119119}
120120
121+ Draw::CoordinateSystem Chart::getCoordSystem () const
122+ {
123+ const auto &plotArea = layout.plotArea ;
124+
125+ if (actDiagram)
126+ {
127+ const auto &options = *actDiagram->getOptions ();
128+
129+ return Draw::CoordinateSystem (plotArea,
130+ options.angle .get (),
131+ options.polar .get (),
132+ actDiagram->keepAspectRatio );
133+ }
134+ return Draw::CoordinateSystem (plotArea, 0.0 ,
135+ Math::FuzzyBool (), Math::FuzzyBool ());
136+ }
137+
121138const Diag::Marker *Chart::markerAt (const Geom::Point &point) const
122139{
123140 if (animator->isRunning ()) return nullptr ;
Original file line number Diff line number Diff line change 1414#include " chart/main/layout.h"
1515#include " chart/main/stylesheet.h"
1616#include " chart/options/descriptor.h"
17+ #include " chart/rendering/painter/coordinatesystem.h"
1718#include " data/table/datatable.h"
1819#include " events.h"
1920
@@ -40,6 +41,7 @@ class Chart :
4041 Anim::Options &getAnimOptions () { return nextAnimOptions; }
4142 Events &getEvents () { return events; }
4243 Util::EventDispatcher &getEventDispatcher () { return eventDispatcher; }
44+ Draw::CoordinateSystem getCoordSystem () const ;
4345
4446 Diag::Descriptor getDescriptor ();
4547
You can’t perform that action at this time.
0 commit comments