Mantid
|
A widget to define a sphere. More...
#include <SampleShapeHelpers.h>
Public Member Functions | |
SphereDetails (QWidget *parent=nullptr) | |
Default constructor. More... | |
QString | writeXML () const override |
Write the XML definition. More... | |
~SphereDetails () override | |
Default destructor. More... | |
Public Member Functions inherited from MantidQt::CustomDialogs::ShapeDetails | |
bool | getComplementFlag () const |
Get complement flag. More... | |
QString | getShapeID () const |
Get the id string. More... | |
void | setComplementFlag (bool flag) |
Set the complement flag. More... | |
ShapeDetails (QWidget *parent=nullptr) | |
Constructor. More... | |
virtual QString | writeXML () const =0 |
Write out the XML definition for this shape. More... | |
~ShapeDetails () override=default | |
Constructor. More... | |
Private Attributes | |
PointGroupBox * | m_centre |
Centre point group box. More... | |
QLineEdit * | m_radius_box |
Line edit for radius value. More... | |
QComboBox * | m_runits |
Radius unit choice. More... | |
Static Private Attributes | |
static int | g_nspheres = 0 |
The number of objects that currently exist. More... | |
Additional Inherited Members | |
Public Types inherited from MantidQt::CustomDialogs::ShapeDetails | |
enum | Unit { millimetre = 0 , centimetre = 1 , metre = 2 } |
Static Public Member Functions inherited from MantidQt::CustomDialogs::ShapeDetails | |
static QString | convertToMetres (const QString &value, Unit start_unit) |
Convert a string value from the given unit to metres (static) More... | |
static QComboBox * | createLengthUnitsCombo () |
Create a new length units box. More... | |
Protected Attributes inherited from MantidQt::CustomDialogs::ShapeDetails | |
QString | m_idvalue |
ID string of this object. More... | |
A widget to define a sphere.
Definition at line 159 of file SampleShapeHelpers.h.
SphereDetails::SphereDetails | ( | QWidget * | parent = nullptr | ) |
Default constructor.
Definition at line 221 of file SampleShapeHelpers.cpp.
References MantidQt::CustomDialogs::ShapeDetails::createLengthUnitsCombo(), g_nspheres, m_centre, MantidQt::CustomDialogs::ShapeDetails::m_idvalue, m_radius_box, and m_runits.
|
inlineoverride |
|
overridevirtual |
Write the XML definition.
Implements MantidQt::CustomDialogs::ShapeDetails.
Definition at line 245 of file SampleShapeHelpers.cpp.
References MantidQt::CustomDialogs::ShapeDetails::convertToMetres(), m_centre, MantidQt::CustomDialogs::ShapeDetails::m_idvalue, m_radius_box, m_runits, and MantidQt::CustomDialogs::PointGroupBox::write3DElement().
|
staticprivate |
The number of objects that currently exist.
Static counter.
Definition at line 164 of file SampleShapeHelpers.h.
Referenced by SphereDetails(), and ~SphereDetails().
|
private |
Centre point group box.
Definition at line 182 of file SampleShapeHelpers.h.
Referenced by SphereDetails(), and writeXML().
|
private |
Line edit for radius value.
Definition at line 178 of file SampleShapeHelpers.h.
Referenced by SphereDetails(), and writeXML().
|
private |
Radius unit choice.
Definition at line 180 of file SampleShapeHelpers.h.
Referenced by SphereDetails(), and writeXML().