Small widget to provide a variable number of spinners to create a slice. More...
#include <TBPlotter.qo.h>
Public Member Functions | |
| PlotSlicer () | |
| Default Constructor. | |
| ~PlotSlicer () | |
| bool | setDimension (std::vector< int > *d, bool complex=false) |
| Sets the dimensions of the slicer to the given vector. | |
| bool | setDimension (std::vector< int > *d, bool complex, bool index) |
| void | getDimension (std::vector< int > &d, bool &complex, bool &) |
| Retrieves the array slice into the given vector. | |
| void | getDimension (std::vector< int > &d, bool &complex, bool &, int &axis) |
Private Slots | |
| void | axisChosen (int axis) |
Private Attributes | |
| std::vector< QSpinBox * > | spinners |
| All current spinners. | |
| QComboBox * | complexChooser |
| Complex chooser. | |
| bool | complex |
| Whether the current slice is for a complex or not. | |
| QSpinBox * | plotAxisChooser |
| Spinbox and Label to choose axis. | |
| QLabel * | axisLabel |
Small widget to provide a variable number of spinners to create a slice.
A PlotSlicer provides a variable number of QSpinBoxes to allow the user to enter an array slice. The number of spinners depends on the dimensionality (i.e., a two-dimensional array will have two spinners). The range of the spinners depends on the array's shape (i.e., a 4x2 array will have a [0, 3] range on the first spinner and a [0, 1] range on the second spinner). A PlotSlicer can also display a QComboBox to allow the user to choose between phase and amplitude for complex numbers.
Definition at line 132 of file TBPlotter.qo.h.
| casa::PlotSlicer::PlotSlicer | ( | ) |
Default Constructor.
| casa::PlotSlicer::~PlotSlicer | ( | ) |
| void casa::PlotSlicer::axisChosen | ( | int | axis | ) | [private, slot] |
| void casa::PlotSlicer::getDimension | ( | std::vector< int > & | d, | |
| bool & | complex, | |||
| bool & | amp, | |||
| int & | axis | |||
| ) |
| void casa::PlotSlicer::getDimension | ( | std::vector< int > & | d, | |
| bool & | complex, | |||
| bool & | amp | |||
| ) |
Retrieves the array slice into the given vector.
complex is set to true if the slice is for complex numbers; if complex is true, amp indicates whether the slice is for the amplitude (true) or the phase (false).
| bool casa::PlotSlicer::setDimension | ( | std::vector< int > * | d, | |
| bool | complex, | |||
| bool | index | |||
| ) |
| bool casa::PlotSlicer::setDimension | ( | std::vector< int > * | d, | |
| bool | complex = false | |||
| ) |
Sets the dimensions of the slicer to the given vector.
If complex is true, a combobox to choose between phase and amplitude is also shown. If index is true, a spinbox to select plot axis is also shown.
QLabel* casa::PlotSlicer::axisLabel [private] |
Definition at line 166 of file TBPlotter.qo.h.
bool casa::PlotSlicer::complex [private] |
Whether the current slice is for a complex or not.
Definition at line 162 of file TBPlotter.qo.h.
QComboBox* casa::PlotSlicer::complexChooser [private] |
Complex chooser.
Definition at line 159 of file TBPlotter.qo.h.
QSpinBox* casa::PlotSlicer::plotAxisChooser [private] |
Spinbox and Label to choose axis.
Definition at line 165 of file TBPlotter.qo.h.
std::vector<QSpinBox*> casa::PlotSlicer::spinners [private] |
All current spinners.
Definition at line 156 of file TBPlotter.qo.h.
1.6.1