1 #ifndef SIMPT_EDITOR_TRANSFORMATION_WIDGET_H_INCLUDED
2 #define SIMPT_EDITOR_TRANSFORMATION_WIDGET_H_INCLUDED
72 double GetScalingY() {
return m_aspect_ratio_maintained ? m_scaling_x : m_scaling_y; }
95 void UpdateRotation(
int degrees);
97 void UpdateScalingX(
double factor);
98 void UpdateScalingX(
int value);
100 void UpdateScalingY(
double factor);
101 void UpdateScalingY(
int value);
103 void UpdateAspectRatioMaintained(
bool checked);
105 void UpdateTranslationX(
double position);
106 void UpdateTranslationX(
int position);
108 void UpdateTranslationY(
double position);
109 void UpdateTranslationY(
int position);
112 void SetupGui(
int maxScaleRatio,
double maxTranslationX,
double maxTranslationY);
118 bool m_aspect_ratio_maintained;
119 double m_translation_x;
120 double m_translation_y;
124 QDoubleSpinBox* m_scaling_x_spin_box;
125 QSlider* m_scaling_x_slider;
126 QDoubleSpinBox* m_scaling_y_spin_box;
127 QSlider* m_scaling_y_slider;
128 QDoubleSpinBox* m_translation_x_spin_box;
129 QSlider* m_translation_x_slider;
130 QDoubleSpinBox* m_translation_y_spin_box;
131 QSlider* m_translation_y_slider;
136 #endif // end-of-include-guard
void TransformationChanged()
Emitted when the transformation is changed by the user.
Namespace for SimPT tissue editor package.
Qt GUI to enter a transformation of an item.
double GetTranslationY()
Gets the y translation of the transformation.
int GetRotation()
Gets the rotation of the transformation.
TransformationWidget(int maxScaleRatio, double maxTranslationX, double maxTranslationY, QWidget *parent=nullptr)
Constructor.
virtual ~TransformationWidget()
Destructor.
double GetScalingX()
Gets the x scaling of the transformation.
double GetTranslationX()
Gets the x translation of the transformation.
double GetScalingY()
Gets the y scaling of the transformation.
see the online Qt documentation