BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
graphcanvaswidget.cpp
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file gui2/importdataview/graphcanvaswidget.cpp
6 //! @brief Implements class CLASS?
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2020
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
18 #include <QVBoxLayout>
19 
20 namespace gui2 {
21 
23  : QWidget(parent), m_graphCanvas(new ModelView::GraphCanvas)
24 {
25  auto layout = new QVBoxLayout(this);
26  layout->addWidget(m_graphCanvas);
27  layout->setContentsMargins(0, 5, 5, 5);
28 }
29 
31 {
32  m_graphCanvas->setItem(canvas_item);
33 }
34 
36 {
38 }
39 
40 } // namespace gui2
Widget to show scientific figure with multiple 1D graphs.
Definition: graphcanvas.h:30
void setItem(GraphViewportItem *viewport_item)
void setViewportToContent(double left, double top, double right, double bottom)
Holds a collection of GraphItem's for simultaneous plotting, as well as all information related to pl...
GraphCanvasWidget(QWidget *parent=nullptr)
void setItem(CanvasItem *canvas_item)
ModelView::GraphCanvas * m_graphCanvas
Defines class CLASS?
Defines class CLASS?
Defines class CLASS?
materialitems.h Collection of materials to populate MaterialModel.
Based on Qt example "codeeditor" Copyright (C) 2016 The Qt Company Ltd.
Definition: app_constants.h:20