Class providing funcionality to a RobRotation panel inside the TaskView. More...
Public Member Functions | |
def | __init__ (self, robot_joints, forms) |
Initialization method for RobotPanel. More... | |
def | sliderChanged (self, value, form, joint) |
Feedback method called when any slider position is changed. More... | |
def | reject (self) |
Feedback method called when 'Close' button was pressed to close the panel. More... | |
def | getStandardButtons (self, *args) |
Method to set just one button (close) to close the dialog. More... | |
def | isAllowedAlterSelection (self) |
Method to tell FreeCAD if dialog is allowed to alter a selection. More... | |
def | isAllowedAlterView (self) |
Method to tell FreeCAD if dialog is allowed to alter a view. More... | |
def | isAllowedAlterDocument (self) |
Method to tell FreeCAD if dialog is allowed to alter a document. More... | |
Public Attributes | |
robot_joints | |
A list of RobRotation and RobTranslation instances. More... | |
previous_joint_values | |
form | |
A list of QDialog instances to show in the TaskView. More... | |
Class providing funcionality to a RobRotation panel inside the TaskView.
This class enables user to see a manipulator in different configurations. It provides a dialogs to be shown in the TaskView. These dialogs have sliders which allow user to go through a joint range.
Definition at line 51 of file RobotPanel.py.
def RobotPanel.RobotPanel.__init__ | ( | self, | |
robot_joints, | |||
forms | |||
) |
Initialization method for RobotPanel.
A class instance is created. A list of proxies for associated RobRotation
and RobTranslation
instances are loaded as well as corresponding QDialog forms. Previously visible properties are set to be read-only as not to change when a RobotPanel
is open. Finally all sliders on dialogs are moved to a position corresponding to current a RobRotation
angle / RobTranslation
displacement. If current value exceeds given joint range, the slider is placed to minimum or maximum.
robot_joints | A list of RobRotation and RobTranslation instances. |
forms | A list of QDialog instances to show in the TaskView. |
Definition at line 74 of file RobotPanel.py.
def RobotPanel.RobotPanel.getStandardButtons | ( | self, | |
* | args | ||
) |
Method to set just one button (close) to close the dialog.
*args: A tuple of unused arguments from Qt.
Definition at line 195 of file RobotPanel.py.
def RobotPanel.RobotPanel.isAllowedAlterDocument | ( | self | ) |
Method to tell FreeCAD if dialog is allowed to alter a document.
Definition at line 222 of file RobotPanel.py.
def RobotPanel.RobotPanel.isAllowedAlterSelection | ( | self | ) |
Method to tell FreeCAD if dialog is allowed to alter a selection.
Definition at line 204 of file RobotPanel.py.
def RobotPanel.RobotPanel.isAllowedAlterView | ( | self | ) |
Method to tell FreeCAD if dialog is allowed to alter a view.
Definition at line 213 of file RobotPanel.py.
def RobotPanel.RobotPanel.reject | ( | self | ) |
Feedback method called when 'Close' button was pressed to close the panel.
Joint properties are return to be editable/read-only/invisible as they were before. After that RobotPanel
is closed.
RobRotation and RobTranslation joint variables are set to the original values. RobotPanel
is closed. FreeCAD and FreeCADGui documents are updated.
Definition at line 154 of file RobotPanel.py.
def RobotPanel.RobotPanel.sliderChanged | ( | self, | |
value, | |||
form, | |||
joint | |||
) |
Feedback method called when any slider position is changed.
A joint value is extrapolated from the slider position. The value is shown on the dialog and set to a joint. Finally, the FreeCAD document and the FreeCADGui document are updated.
value | A slider position. |
form | A Dialog panel on which slider was moved. |
joint | A RobRotation or RobTranslation associated with the form . |
Definition at line 128 of file RobotPanel.py.
RobotPanel.RobotPanel.form |
A list of QDialog instances to show in the TaskView.
Definition at line 96 of file RobotPanel.py.
RobotPanel.RobotPanel.robot_joints |
A list of RobRotation and RobTranslation instances.
Definition at line 76 of file RobotPanel.py.