BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
|
Widget to show scientific figure with multiple 1D graphs. More...
Classes | |
struct | GraphCanvasImpl |
Signals | |
void | axisMarginsChanged (int left, int top, int right, int bottom) |
Public Member Functions | |
GraphCanvas (QWidget *parent=nullptr) | |
~GraphCanvas () override | |
std::unique_ptr< SceneAdapterInterface > | createSceneAdapter () const |
void | setAxisMargins (int left, int top, int right, int bottom) |
Set margins between axes rectangle and widget borders. More... | |
void | setItem (GraphViewportItem *viewport_item) |
void | setViewportToContent () |
void | setViewportToContent (double left, double top, double right, double bottom) |
Private Attributes | |
std::unique_ptr< GraphCanvasImpl > | p_impl |
Widget to show scientific figure with multiple 1D graphs.
Contains embedded QCustomPlot widget, shows content of GraphViewportItem.
Definition at line 30 of file graphcanvas.h.
|
explicit |
Definition at line 83 of file graphcanvas.cpp.
References axisMarginsChanged(), and p_impl.
|
overridedefault |
|
signal |
Referenced by GraphCanvas(), and gui2::SimPlotWidget::SimPlotWidget().
std::unique_ptr< SceneAdapterInterface > GraphCanvas::createSceneAdapter | ( | ) | const |
Definition at line 112 of file graphcanvas.cpp.
References p_impl.
Referenced by gui2::GraphicsScene::createPlotProxy().
void GraphCanvas::setAxisMargins | ( | int | left, |
int | top, | ||
int | right, | ||
int | bottom | ||
) |
Set margins between axes rectangle and widget borders.
If the value is negative, leave old margin intact and allow automatic margin adjustment.
Definition at line 130 of file graphcanvas.cpp.
References p_impl.
Referenced by gui2::SimPlotWidget::SimPlotWidget().
void GraphCanvas::setItem | ( | GraphViewportItem * | viewport_item | ) |
Definition at line 107 of file graphcanvas.cpp.
References p_impl.
Referenced by gui2::GraphCanvasWidget::setItem(), gui2::GraphicsScene::setItem(), and gui2::SimPlotWidget::setModels().
void GraphCanvas::setViewportToContent | ( | ) |
Definition at line 122 of file graphcanvas.cpp.
References p_impl.
void GraphCanvas::setViewportToContent | ( | double | left, |
double | top, | ||
double | right, | ||
double | bottom | ||
) |
Definition at line 117 of file graphcanvas.cpp.
References p_impl.
Referenced by gui2::SLDEditor::SLDEditor(), gui2::GraphCanvasWidget::updateViewport(), and gui2::SimPlotWidget::updateViewport().
|
private |
Definition at line 52 of file graphcanvas.h.
Referenced by GraphCanvas(), createSceneAdapter(), setAxisMargins(), setItem(), and setViewportToContent().