BornAgain  1.19.79
Simulate and fit neutron and x-ray scattering at grazing incidence
SphericalDetectorEditor.cpp
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file GUI/View/Instrument/SphericalDetectorEditor.cpp
6 //! @brief Implement class SphericalDetectorEditor
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2018
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
19 #include <QGridLayout>
20 
22  : QWidget(parent)
23 {
24  ASSERT(item);
25  auto* grid = new QGridLayout(this);
26  grid->setColumnStretch(0, 1);
27  grid->setColumnStretch(1, 1);
28  grid->setColumnStretch(2, 1);
29 
30  auto* phiAxisEditor = new AxisPropertyEditor(this, u8"\u03c6 axis", &item->phiAxis());
31  grid->addWidget(phiAxisEditor, 1, 0);
32 
33  auto* alphaAxisEditor = new AxisPropertyEditor(this, u8"\u03b1 axis", &item->alphaAxis());
34  grid->addWidget(alphaAxisEditor, 1, 1);
35 
36  auto* resolutionFunctionEditor =
38  grid->addWidget(resolutionFunctionEditor, 1, 2);
39 
40  grid->setRowStretch(2, 1);
41 
42  connect(phiAxisEditor, &AxisPropertyEditor::dataChanged, this,
44 
45  connect(alphaAxisEditor, &AxisPropertyEditor::dataChanged, this,
47 
48  connect(resolutionFunctionEditor, &ResolutionFunctionEditor::dataChanged, this,
50 }
Defines class AxisPropertyEditor.
A widget for editing the alignment of a detector.
Defines class SphericalDetectorEditor.
Defines class SphericalDetectorItem.
Use this to edit an AxisProperty.
Widget for selecting the resolution function of a detector (combo box) and input of the corresponding...
SphericalDetectorEditor(QWidget *parent, SphericalDetectorItem *item)