MoveRotateGroup Class Reference


Detailed Description
A group of properties and controls for moving and rotating objects.This group is divided into a "Move" tab and a "Rotate" tab.
- The "Move" tab contains
Fl_Value_Inputwidgets for inputting movement coordinates, as well as radio buttons for selecting which coordinate system to view the coordinates in. It also features a check box for viewing absolute or relative coordinates. - The "Rotate" tab contains
Fl_Value_Inputwidgets for inputting degrees for rotational transformation. It also features radio button groups for selecting the rotational center and axis.
Based on user input, the group will generate transformation actions and have UserInterfaceUtilities forward them to the inbound actions queue.
This group uses the CoordinateTrigger to fill and update its coordinate fields with data from the selected objects.
Public Member Functions | |
| MoveRotateGroup (int x, int y) | |
Creates a new MoveRotateGroup object. | |
| virtual | ~MoveRotateGroup () |
| Deletes the trigger allocated for this group. | |
| virtual void | set_properties (const std::set< ObjectID > &objects) |
| Virtual method for preparing this property group for displaying the properties of the selected objects. | |
| void | clear_updates () |
| Removes all pending updates for this group. | |
| void | register_triggers (const std::set< ObjectID > &objects, SceneTreePtr &ptr) |
Registers a CoordinateTrigger with all objects in the set passed to the method. | |
| void | deregister_triggers (const std::set< ObjectID > &objects, SceneTreePtr &ptr) |
Deregisters the CoordinateTrigger from all objects in the set passed to the method. | |
Static Private Member Functions | |
| static void | relative_coordinates_callback (Fl_Widget *w, void *data) |
| Callback for the "Relative coordinates" checkbox. | |
| static void | coordinate_choice_callback (Fl_Widget *w, void *data) |
| static void | rotational_system_callback (Fl_Widget *w, void *data) |
Private Attributes | |
| std::set< ObjectID > | m_objects |
A list of the SceneObject objects this group is displaying the properties of. | |
| Vector4ru | m_average_position |
| The averaged position of a selection of multiple objects. | |
| Vector4ru | m_local_position |
| Vector4ru | m_parent_position |
| MoveInput * | m_x_coordinate |
Pointers to the Fl_Value_Input widget for changing this coordinate. | |
| MoveInput * | m_y_coordinate |
| MoveInput * | m_z_coordinate |
| Fl_Round_Button * | m_world_coordinates |
Pointers to the Fl_Round_Button widget for selecting this coordinate system. | |
| Fl_Round_Button * | m_parent_coordinates |
| Fl_Round_Button * | m_local_coordinates |
| Fl_Check_Button * | m_relative_coordinates |
Pointers to the Fl_Check_Button widget for selecting whether to use relative or absolute coordinates. | |
| RotateInput * | m_x_axis |
Pointers to the Fl_Value_Input widget for rotating about this axis. | |
| RotateInput * | m_y_axis |
| RotateInput * | m_z_axis |
| Fl_Round_Button * | m_world_center |
Pointers to the Fl_Round_Button widget for selecting this rotational center. | |
| Fl_Round_Button * | m_parent_center |
| Fl_Round_Button * | m_local_center |
| Fl_Round_Button * | m_world_axis |
Pointers to the Fl_Round_Button widget for selecting this rotational axis. | |
| Fl_Round_Button * | m_local_axis |
| Fl_Round_Button * | m_parent_axis |
| CoordinateTrigger * | m_trigger |
| The coordinate trigger this group registered with the selected objects. | |
Friends | |
| class | MoveInput |
| class | RotateInput |
Constructor & Destructor Documentation
| MoveRotateGroup | ( | int | x, | |
| int | y | |||
| ) |
Creates a new MoveRotateGroup object.
Allocates and adds the sub widgets and makes sure they are filled with properties by registering a CoordinateTrigger for them.
Member Function Documentation
| void set_properties | ( | const std::set< ObjectID > & | objects | ) | [virtual] |
Virtual method for preparing this property group for displaying the properties of the selected objects.
For multiple selections, this method disallows all transformations except movement in relative world coordinates, and rotation around local center.
It also registers a CoordinateTrigger with the currently selected objects to fill the coordinate input fields with values. It also it also deregisters triggers for objects that have been deselected.
This method is called by the PropertyVisitor upon creation, and whenever the selection changes.
Implements PropertyGroup.
| void relative_coordinates_callback | ( | Fl_Widget * | w, | |
| void * | data | |||
| ) | [static, private] |
Callback for the "Relative coordinates" checkbox.
This will either set each coordinate input box to 0, or fill them with coordinate information, depending on whether the button is checked or not.
- Parameters:
-
w A pointer to the Fl_Value_Inputcontrol triggering the callback.data A pointer to void, as required by FLTK (not used).
Member Data Documentation
A list of the SceneObject objects this group is displaying the properties of.
Reimplemented from PropertyGroup.
Vector4ru m_average_position [private] |
The averaged position of a selection of multiple objects.
- Deprecated:
- {This is now handled by
CoordinateTrigger.}
The documentation for this class was generated from the following files:
- src/gui/MoveRotateGroup.hh
- src/gui/MoveRotateGroup.cc