BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Converts QGraphicsScene coordinates in the coordinates of local system of QCustomPlot and vice versa. More...
Classes | |
struct | CustomPlotSceneAdapterImpl |
Public Member Functions | |
CustomPlotSceneAdapter (QCustomPlot *custom_plot) | |
~CustomPlotSceneAdapter () override | |
double | fromSceneX (double scene_x) const override |
convert scene x-coordinate to local axis coordinate More... | |
double | fromSceneY (double scene_y) const override |
convert scene y-coordinate to local axis coordinate More... | |
double | toSceneX (double customplot_x) const override |
convert local x-coordinate to scene coordinate More... | |
double | toSceneY (double customplot_y) const override |
convert local y-coordinate to scene coordinate More... | |
QRectF | viewportRectangle () const override |
returns viewport rectangle in scene coordinates More... | |
Private Attributes | |
std::unique_ptr< CustomPlotSceneAdapterImpl > | p_impl |
Converts QGraphicsScene coordinates in the coordinates of local system of QCustomPlot and vice versa.
Definition at line 28 of file customplotsceneadapter.h.
|
explicit |
Definition at line 63 of file customplotsceneadapter.cpp.
References p_impl.
|
override |
Definition at line 71 of file customplotsceneadapter.cpp.
References p_impl.
|
overridevirtual |
convert scene x-coordinate to local axis coordinate
Implements ModelView::SceneAdapterInterface.
Definition at line 87 of file customplotsceneadapter.cpp.
References p_impl.
|
overridevirtual |
convert scene y-coordinate to local axis coordinate
Implements ModelView::SceneAdapterInterface.
Definition at line 92 of file customplotsceneadapter.cpp.
References p_impl.
|
overridevirtual |
convert local x-coordinate to scene coordinate
Implements ModelView::SceneAdapterInterface.
Definition at line 77 of file customplotsceneadapter.cpp.
References p_impl.
|
overridevirtual |
convert local y-coordinate to scene coordinate
Implements ModelView::SceneAdapterInterface.
Definition at line 82 of file customplotsceneadapter.cpp.
References p_impl.
|
overridevirtual |
returns viewport rectangle in scene coordinates
Implements ModelView::SceneAdapterInterface.
Definition at line 97 of file customplotsceneadapter.cpp.
References p_impl.
|
private |
Definition at line 45 of file customplotsceneadapter.h.
Referenced by CustomPlotSceneAdapter(), ~CustomPlotSceneAdapter(), fromSceneX(), fromSceneY(), toSceneX(), toSceneY(), and viewportRectangle().