RobRotation.ViewProviderRobRotationProxy Class Reference

Proxy class for Gui.ViewProviderDocumentObject RobRotation.ViewObject. More...

Public Member Functions

def __init__ (self, vp)
 Initialization method for ViewProviderRobRotationProxy. More...
 
def attach (self, vp)
 Method called by FreeCAD after initialization to attach Coin3D constructs. More...
 
def updateData (self, fp, prop)
 Method called after DocumentObjectGroupPython RobRotation was changed. More...
 
def onChanged (self, vp, prop)
 Method called after RobRotation.ViewObject was changed. More...
 
def claimChildren (self)
 Method called by FreeCAD to retrieve assigned children. More...
 
def canDropObject (self, obj)
 Method called by FreeCAD to ask if an object obj can be dropped into a Group. More...
 
def getIcon (self)
 Method called by FreeCAD to supply an icon for the Tree View. More...
 
def __getstate__ (self)
 Necessary method to avoid errors when trying to save unserializable objects. More...
 
def __setstate__ (self, state)
 Necessary method to avoid errors when trying to restore unserializable objects. More...
 
def setProperties (self, vp)
 Method to hide unused properties. More...
 
def doubleClicked (self, vp)
 Method called by FreeCAD when RobRotation is double-clicked in the Tree View. More...
 
def setupContextMenu (self, vp, menu)
 Method called by the FreeCAD to customize a RobRotation context menu. More...
 
def makeLabels (self)
 Method which makes Coin3D labels to be displayed in the FreeCAD View. More...
 
def makeFrame (self, frame_labels)
 Method which makes a Coin3D frame to show a current pose in a RobRotation. More...
 

Public Attributes

 tf_object2world
 A SoTransform transformation from object to world frame. More...
 
 font
 A SoFontStyle font for axes labels. More...
 
 frame
 A SoSeparator with a coordinate frame made from 3 RGB arrows. More...
 
 visualisations
 A SoSwitch with all visualisations (frame & rotation axis). More...
 
 label_texts
 A list of SoText2s labels denoting all axes and an origin. More...
 
 label_translations
 A list of SoTranslations moving labels. More...
 
 labels
 A list of SoSwitches containing colored translated labels. More...
 
 frame_shaft
 A SoLineSet shaft for frame axes. More...
 
 frame_arrowhead_translation
 A SoTranslation moving frame arrowheads. More...
 
 frame_arrowhead_cone
 A SoCone arrowhead cone for frame axes. More...
 
 frame_arrowhead
 A SoSwitch translated cone for frame axes. More...
 
 frame_color_x
 A SoPackedColor red color for an X axis. More...
 
 frame_color_y
 A SoPackedColor green color for an Y axis. More...
 
 frame_color_z
 A SoPackedColor blue color for an Z axis. More...
 
 frame_drawstyle
 A SoDrawStyle controlling frame axes shaft line width. More...
 

Static Public Attributes

 panel = None
 A RobotPanel if one is active or None. More...
 
 fp = None
 A RobRotation object. More...
 

Detailed Description

Proxy class for Gui.ViewProviderDocumentObject RobRotation.ViewObject.

A ViewProviderRobRotationProxy instance provides a RobRotation's icon, double-click response and context menu with a Check joint range option.

To connect this Proxy object to a Gui.ViewProviderDocumentObject RobRotation.ViewObject do:

a = FreeCAD.ActiveDocument.addObject("App::DocumentObjectGroupPython",
"RobRotation")
ViewProviderRobRotationProxy(a.ViewObject)

Definition at line 589 of file RobRotation.py.

Constructor & Destructor Documentation

◆ __init__()

def RobRotation.ViewProviderRobRotationProxy.__init__ (   self,
  vp 
)

Initialization method for ViewProviderRobRotationProxy.

A class instance is created and made a Proxy for a generic Gui.ViewProviderDocumentObject RobRotation.ViewObject. During initialization number of properties are specified and preset.

Parameters
vpA barebone Gui.ViewProviderDocumentObject RobRotation.ViewObject.

Definition at line 656 of file RobRotation.py.

656  def __init__(self, vp):
657  self.setProperties(vp)
658  vp.Proxy = self
659 

Member Function Documentation

◆ __getstate__()

def RobRotation.ViewProviderRobRotationProxy.__getstate__ (   self)

Necessary method to avoid errors when trying to save unserializable objects.

This method is used by JSON to serialize unserializable objects during autosave. Without this an Error would rise when JSON would try to do that itself.

We need this for unserializable fp attribute, but we don't serialize it, because it's enough to reset it when object is restored.

Returns
None, because we don't serialize anything.

Definition at line 887 of file RobRotation.py.

887  def __getstate__(self):
888  return None
889 

◆ __setstate__()

def RobRotation.ViewProviderRobRotationProxy.__setstate__ (   self,
  state 
)

Necessary method to avoid errors when trying to restore unserializable objects.

This method is used during a document restoration. We need this for unserializable fp attribute, but we do not restore it, because it's enough to reset it.

Definition at line 897 of file RobRotation.py.

897  def __setstate__(self, state):
898  pass
899 

◆ attach()

def RobRotation.ViewProviderRobRotationProxy.attach (   self,
  vp 
)

Method called by FreeCAD after initialization to attach Coin3D constructs.

A coordinate frame made of RGB arrows corresponding to X, Y and Z axes. This frame shows current pose in a rotation. This method adds RobRotation as the fp attribute.

Parameters
vpA RobRotation.ViewObject after initialization.

Definition at line 670 of file RobRotation.py.

670  def attach(self, vp):
671  # prepare transformation to keep pose corresponding to placement
672  self.tf_object2world = coin.SoTransform()
673 
674  labels = self.makeLabels()
675  self.font = coin.SoFontStyle()
676 
677  frame = self.makeFrame(labels[:3])
678  frame.insertChild(self.tf_object2world, 0)
679  frame.insertChild(self.font, 1)
680  self.frame = coin.SoSwitch()
681  self.frame.addChild(frame)
682 
683  self.visualisations = coin.SoSwitch()
684  self.visualisations.addChild(self.frame)
685  self.visualisations.whichChild.setValue(coin.SO_SWITCH_ALL)
686  vp.RootNode.addChild(self.visualisations)
687 
688  vp.Object.Proxy.setProperties(vp.Object)
689  self.setProperties(vp)
690  self.fp = vp.Object
691 

◆ canDropObject()

def RobRotation.ViewProviderRobRotationProxy.canDropObject (   self,
  obj 
)

Method called by FreeCAD to ask if an object obj can be dropped into a Group.

Only FreeCAD objects of a RobRotation and RobTranslation type are allowed to drop inside a RobRotation group.

Parameters
objA FreeCAD object hovering above a RobRotation item in the Tree View.

Definition at line 856 of file RobRotation.py.

856  def canDropObject(self, obj):
857  if hasattr(obj, "Proxy") and \
858  (obj.Proxy.__class__.__name__ == "RobRotationProxy" or
859  obj.Proxy.__class__.__name__ == "RobTranslationProxy"):
860  return True
861  return False
862 

◆ claimChildren()

def RobRotation.ViewProviderRobRotationProxy.claimChildren (   self)

Method called by FreeCAD to retrieve assigned children.

When a property of a RobRotation is touched the RobRotation and the FreeCAD ActiveDocument are notified. The FreeCAD ActiveDocument then emits a signal to inform all its observers e.g. the FreeCADGui ActiveDocument. The FreeCADGui document then emits a new signal to inform e.g. the tree view. The tree view then invokes claimChildren().

Definition at line 842 of file RobRotation.py.

842  def claimChildren(self):
843  if hasattr(self, "fp") and self.fp:
844  return self.fp.Group
845  return []
846 

◆ doubleClicked()

def RobRotation.ViewProviderRobRotationProxy.doubleClicked (   self,
  vp 
)

Method called by FreeCAD when RobRotation is double-clicked in the Tree View.

If no dialog is opened in the Task View, a new RobotPanel is opened. If another RobotPanel is opened, it is closed and all its QDialogs are added to a new RobotPanel. If a RobotPanel is already opened, the Model tab on the Combo View is swapped for the Tasks tab so that the panel becomes visible. If another dialog is opened a warning is shown.

Parameters
vpA Gui.ViewProviderDocumentObject RobRotation.ViewObject.
Returns
True confirmation that this method was implemented.

Definition at line 927 of file RobRotation.py.

927  def doubleClicked(self, vp):
928  # Switch to the Task View if a RobotPanel is already opened
929  if self.panel:
930  FreeCADGui.Control.showTaskView()
931 
932  # Try to open new RobotPanel
933  else:
934  # Load the QDialog from a file and name it after this object
935  new_form = [FreeCADGui.PySideUic.loadUi(path.join(PATH_TO_UI,
936  "AnimationJoint.ui"))]
937  new_form[0].setWindowTitle(vp.Object.Label)
938 
939  # Create a control panel and try to show it
940  self.panel = RobotPanel([vp.Object], new_form)
941  try:
942  FreeCADGui.Control.showDialog(self.panel)
943  except RuntimeError as e:
944  # Reset the panel
945  self.panel = None
946 
947  # Find all RobRotation/RobTranslation feature python objects
948  # with a reference to a RobotPanel
949  robot_joints = []
950  for obj in FreeCAD.ActiveDocument.Objects:
951  if hasattr(obj, "Proxy") and \
952  (obj.Proxy.__class__.__name__
953  == "RobRotationProxy"
954  or obj.Proxy.__class__.__name__
955  == "RobTranslationProxy"):
956  if obj.ViewObject.Proxy.panel is not None:
957  robot_joints.append(obj)
958 
959  if len(robot_joints) > 0:
960  # Close opened Trajecotry panel
961  robot_joints[0].ViewObject.Proxy.panel.reject()
962 
963  # Load the QDialog form for each RobRotation/RobTranslation
964  # which had a reference to the panel
965  forms = []
966  for joint in robot_joints:
967  form = FreeCADGui.PySideUic.loadUi(
968  path.join(PATH_TO_UI, "AnimationJoint.ui"))
969  form.setWindowTitle(joint.Label)
970  forms.append(form)
971 
972  # Load one more QDialog for this RobRotation
973  forms.append(new_form[0])
974 
975  # Add this RobRotation to the list of robot_joints
976  robot_joints.append(vp.Object)
977 
978  # Add a reference to the new panel to view providers
979  # of all robot_joints
980  self.panel = RobotPanel(robot_joints, forms)
981  for joint in robot_joints:
982  joint.ViewObject.Proxy.panel = self.panel
983  FreeCADGui.Control.showDialog(self.panel)
984  return True
985 
986  # Diffeerent Task panel is opened, inform the user
987  else:
988  QMessageBox.warning(
989  None,
990  'Error while opening RobotPanel',
991  "A different panel is already active.\n"
992  + "Close it before opening this one.")
993  FreeCADGui.Control.showTaskView()
994  return True
995 
RobotPanel class for the Animate Workbench.
Definition: RobotPanel.py:1

◆ getIcon()

def RobRotation.ViewProviderRobRotationProxy.getIcon (   self)

Method called by FreeCAD to supply an icon for the Tree View.

A full path to an icon is supplied for the FreeCADGui.

Returns
A str path to an icon.

Definition at line 871 of file RobRotation.py.

871  def getIcon(self):
872  return path.join(PATH_TO_ICONS, "RobRotation.png")
873 

◆ makeFrame()

def RobRotation.ViewProviderRobRotationProxy.makeFrame (   self,
  frame_labels 
)

Method which makes a Coin3D frame to show a current pose in a RobRotation.

A frame is made from 3 red, green and blue arrows representing X, Y and Z. Arrows are each constructed from a shaft and an arrowhead. Their dimensions and other attributes are unassigned as they are extracted from appropriate RobRotation properties.

Returns
A SoSeparator with the frame shown in the FreeCAD View.

Definition at line 1060 of file RobRotation.py.

1060  def makeFrame(self, frame_labels):
1061  # make a generic shaft from 0 in Y direction
1062  shaft_vertices = coin.SoVertexProperty()
1063  shaft_vertices.vertex.setNum(2)
1064  shaft_vertices.vertex.set1Value(0, 0, 0, 0)
1065  self.frame_shaft = coin.SoLineSet()
1066  self.frame_shaft.vertexProperty.setValue(shaft_vertices)
1067  self.frame_shaft.numVertices.setNum(1)
1068  self.frame_shaft.numVertices.setValue(2)
1069 
1070  # make a generic conic arrowhead oriented in Y axis direction and
1071  # move it at the end of the shaft
1072  self.frame_arrowhead_translation = coin.SoTranslation()
1073  self.frame_arrowhead_cone = coin.SoCone()
1074  self.frame_arrowhead = coin.SoSwitch()
1075  self.frame_arrowhead.addChild(self.frame_arrowhead_translation)
1076  self.frame_arrowhead.addChild(self.frame_arrowhead_cone)
1077 
1078  # make rotations to rotate prepared shaft and arrowhead for Y axis
1079  # direction also to X and Z
1080  rot_y2x = coin.SoRotation()
1081  rot_y2x.rotation.setValue(coin.SbRotation(coin.SbVec3f(0, 1, 0),
1082  coin.SbVec3f(1, 0, 0)))
1083  rot_y2z = coin.SoRotation()
1084  rot_y2z.rotation.setValue(coin.SbRotation(coin.SbVec3f(0, 1, 0),
1085  coin.SbVec3f(0, 0, 1)))
1086 
1087  # prepare colors for X,Y,Z which will correspond to R,G,B as customary
1088  self.frame_color_x = coin.SoPackedColor()
1089  self.frame_color_y = coin.SoPackedColor()
1090  self.frame_color_z = coin.SoPackedColor()
1091 
1092  # make complete colored and rotated arrows
1093  x_arrow = coin.SoSeparator()
1094  x_arrow.addChild(rot_y2x)
1095  x_arrow.addChild(self.frame_color_x)
1096  x_arrow.addChild(self.frame_shaft)
1097  x_arrow.addChild(self.frame_arrowhead)
1098  x_arrow.addChild(frame_labels[0])
1099  y_arrow = coin.SoSeparator()
1100  y_arrow.addChild(self.frame_color_y)
1101  y_arrow.addChild(self.frame_shaft)
1102  y_arrow.addChild(self.frame_arrowhead)
1103  y_arrow.addChild(frame_labels[1])
1104  z_arrow = coin.SoSeparator()
1105  z_arrow.addChild(rot_y2z)
1106  z_arrow.addChild(self.frame_color_z)
1107  z_arrow.addChild(self.frame_shaft)
1108  z_arrow.addChild(self.frame_arrowhead)
1109  z_arrow.addChild(frame_labels[2])
1110 
1111  # prepare draw style to control shaft width
1112  self.frame_drawstyle = coin.SoDrawStyle()
1113 
1114  # make complete frame and it to shaded display mode
1115  separated_frame = coin.SoSeparator()
1116  separated_frame.addChild(self.frame_drawstyle)
1117  separated_frame.addChild(x_arrow)
1118  separated_frame.addChild(y_arrow)
1119  separated_frame.addChild(z_arrow)
1120 
1121  return separated_frame
1122 
1123 

◆ makeLabels()

def RobRotation.ViewProviderRobRotationProxy.makeLabels (   self)

Method which makes Coin3D labels to be displayed in the FreeCAD View.

Frame labels for axes X, Y and Z are made. The labels have the same color as the axes.

Returns
A SoSwitch with colored text label to be shown in the FreeCAD View.

Definition at line 1022 of file RobRotation.py.

1022  def makeLabels(self):
1023  label_strings = ["X", "Y", "Z"]
1024  colors = [0xFF0000FF, 0x00FF00FF, 0x0000FFFF]
1025  self.label_texts = []
1026  self.label_translations = []
1027  # frame translation
1028  self.label_translations.append(coin.SoTranslation())
1029  # axis translation
1030  self.label_translations.append(coin.SoTranslation())
1031  self.labels = []
1032  for i in range(3):
1033  label_group = coin.SoSeparator()
1034  label_group.addChild(self.label_translations[0])
1035  frame_axis_color = coin.SoPackedColor()
1036  frame_axis_color.orderedRGBA.setValue(colors[i])
1037  label_group.addChild(frame_axis_color)
1038  self.label_texts.append(coin.SoText2())
1039  self.label_texts[i].string.setValues(
1040  0, 3, ["", label_strings[i], ""])
1041  self.label_texts[i].justification.setValue(
1042  self.label_texts[i].CENTER)
1043  self.label_texts[i].spacing.setValue(0.45)
1044  label_group.addChild(self.label_texts[i])
1045  self.labels.append(coin.SoSwitch())
1046  self.labels[i].addChild(label_group)
1047  return self.labels
1048 

◆ onChanged()

def RobRotation.ViewProviderRobRotationProxy.onChanged (   self,
  vp,
  prop 
)

Method called after RobRotation.ViewObject was changed.

If visibility changed, an appropriate Coin3D construct hides the frame showing current pose.

Parameters
vpA RobRotation.ViewObject.
propA str name of a changed property.

Definition at line 826 of file RobRotation.py.

826  def onChanged(self, vp, prop):
827  if prop == "Visibility":
828  if vp.Visibility:
829  self.visualisations.whichChild.setValue(coin.SO_SWITCH_ALL)
830  else:
831  self.visualisations.whichChild.setValue(coin.SO_SWITCH_NONE)
832 

◆ setProperties()

def RobRotation.ViewProviderRobRotationProxy.setProperties (   self,
  vp 
)

Method to hide unused properties.

Property Display Mode is set to be invisible as they are unused.

Parameters
vpA Gui.ViewProviderDocumentObject RobRotation.ViewObject.

Definition at line 908 of file RobRotation.py.

908  def setProperties(self, vp):
909  # hide unnecessary view properties
910  vp.setEditorMode("DisplayMode", 2)
911 

◆ setupContextMenu()

def RobRotation.ViewProviderRobRotationProxy.setupContextMenu (   self,
  vp,
  menu 
)

Method called by the FreeCAD to customize a RobRotation context menu.

The Transform and Set colors... items are removed from the context menu shown upon right click on DocumentObjectGroupPython RobRotation in the Tree View. The option to Check joint range is added instead.

Parameters
vpA rightclicked Gui.ViewProviderDocumentObject RobRotation.ViewObject.
menuA Qt's QMenu to be edited.

Definition at line 1007 of file RobRotation.py.

1007  def setupContextMenu(self, vp, menu):
1008  menu.clear()
1009  action = menu.addAction("Check joint range")
1010  action.triggered.connect(lambda f=self.doubleClicked,
1011  arg=vp: f(arg))
1012 

◆ updateData()

def RobRotation.ViewProviderRobRotationProxy.updateData (   self,
  fp,
  prop 
)

Method called after DocumentObjectGroupPython RobRotation was changed.

This method is used to update Coin3D constructs, if associated properties changed e.g. if the FrameArrowheadRadius changes, all Coin3D cones representing frame arrowheads will change their radius accordingly.

Parameters
fpA DocumentObjectGroupPython RobRotation object.
propA str name of the changed property.

Definition at line 703 of file RobRotation.py.

703  def updateData(self, fp, prop):
704  # Placement changes
705  if prop == "Placement" and hasattr(fp, "Placement"):
706  trans = fp.Placement.Base
707  rot = fp.Placement.Rotation
708  self.tf_object2world.translation.setValue((trans.x, trans.y,
709  trans.z))
710  self.tf_object2world.rotation.setValue(rot.Q)
711 
712  # Frame changes
713  elif prop == "ShowFrame" and hasattr(fp, "ShowFrame"):
714  if fp.ShowFrame:
715  self.frame.whichChild.setValue(coin.SO_SWITCH_ALL)
716  else:
717  self.frame.whichChild.setValue(coin.SO_SWITCH_NONE)
718 
719  elif prop == "FrameTransparency" and hasattr(fp, "FrameTransparency"):
720  self.frame_color_x.orderedRGBA.\
721  setValue(0xff0000ff - (0xff*fp.FrameTransparency)//100)
722  self.frame_color_y.orderedRGBA.\
723  setValue(0x00ff00ff - (0xff*fp.FrameTransparency)//100)
724  self.frame_color_z.orderedRGBA.\
725  setValue(0x0000ffff - (0xff*fp.FrameTransparency)//100)
726 
727  elif prop == "ShaftLength" and hasattr(fp, "ShaftLength"):
728  self.frame_shaft.vertexProperty.getValue().vertex.\
729  set1Value(1, 0, fp.ShaftLength, 0)
730  if hasattr(fp, "FrameArrowheadLength"):
731  self.frame_arrowhead_translation.translation.setValue(
732  0, fp.ShaftLength + fp.FrameArrowheadLength/2, 0)
733  if not fp.ShowFrameArrowheads and hasattr(fp, "DistanceToAxis"):
734  self.label_translations[0].translation.setValue(
735  0, fp.ShaftLength + fp.DistanceToAxis, 0)
736 
737  elif prop == "FrameArrowheadLength" and \
738  hasattr(fp, "FrameArrowheadLength"):
739  self.frame_arrowhead_cone.height.setValue(fp.FrameArrowheadLength)
740  if hasattr(fp, "ShaftLength"):
741  self.frame_arrowhead_translation.translation.setValue(
742  0, fp.ShaftLength + fp.FrameArrowheadLength/2, 0)
743  if fp.ShowFrameArrowheads and hasattr(fp, "DistanceToAxis"):
744  self.label_translations[0].translation.setValue(
745  0, fp.FrameArrowheadLength/2 + fp.DistanceToAxis, 0)
746 
747  elif prop == "ShaftWidth" and hasattr(fp, "ShaftWidth"):
748  self.frame_drawstyle.lineWidth.setValue(fp.ShaftWidth)
749 
750  elif prop == "FrameArrowheadRadius" and \
751  hasattr(fp, "FrameArrowheadRadius"):
752  self.frame_arrowhead_cone.bottomRadius.setValue(
753  fp.FrameArrowheadRadius)
754 
755  elif prop == "ShowFrameArrowheads" and \
756  hasattr(fp, "ShowFrameArrowheads"):
757  if fp.ShowFrameArrowheads:
758  self.frame_arrowhead.whichChild.setValue(coin.SO_SWITCH_ALL)
759  if hasattr(fp, "FrameArrowheadLength") and \
760  hasattr(fp, "DistanceToAxis"):
761  self.label_translations[0].translation.setValue(
762  0, fp.FrameArrowheadLength/2 + fp.DistanceToAxis, 0)
763  else:
764  self.frame_arrowhead.whichChild.setValue(coin.SO_SWITCH_NONE)
765  if hasattr(fp, "ShaftLength") and \
766  hasattr(fp, "DistanceToAxis"):
767  self.label_translations[0].translation.setValue(
768  0, fp.ShaftLength + fp.DistanceToAxis, 0)
769 
770  elif prop == "ShowFrameLabels" and hasattr(fp, "ShowFrameLabels"):
771  for label in self.labels[:3]:
772  if fp.ShowFrameLabels:
773  label.whichChild.setValue(coin.SO_SWITCH_ALL)
774  else:
775  label.whichChild.setValue(coin.SO_SWITCH_NONE)
776 
777  # Changes to the labels
778  elif prop == "Subscription" and hasattr(fp, "Subscription"):
779  for l in self.label_texts:
780  l.string.setValues(2, 1, [fp.Subscription])
781 
782  elif prop == "Superscription" and hasattr(fp, "Superscription"):
783  for l in self.label_texts:
784  l.string.setValues(0, 1, [fp.Superscription])
785 
786  elif prop == "FontFamily" and hasattr(fp, "FontFamily"):
787  if fp.FontFamily == "SERIF":
788  self.font.family.setValue(self.font.SERIF)
789  if fp.FontFamily == "SANS":
790  self.font.family.setValue(self.font.SANS)
791  if fp.FontFamily == "TYPEWRITER":
792  self.font.family.setValue(self.font.TYPEWRITER)
793 
794  elif prop == "FontStyle" and hasattr(fp, "FontStyle"):
795  if fp.FontStyle == "NONE":
796  self.font.style.setValue(self.font.NONE)
797  if fp.FontStyle == "BOLD":
798  self.font.style.setValue(self.font.BOLD)
799  if fp.FontStyle == "ITALIC":
800  self.font.style.setValue(self.font.ITALIC)
801  if fp.FontStyle == "BOLD ITALIC":
802  self.font.style.setValue(self.font.BOLD | self.font.ITALIC)
803 
804  elif prop == "FontSize" and hasattr(fp, "FontSize"):
805  self.font.size.setValue(fp.FontSize)
806 
807  elif prop == "DistanceToAxis" and hasattr(fp, "DistanceToAxis") and \
808  hasattr(fp, "ShowFrameArrowheads"):
809  if fp.ShowFrameArrowheads and hasattr(fp, "FrameArrowheadLength"):
810  self.label_translations[0].translation.setValue(
811  0, fp.FrameArrowheadLength/2 + fp.DistanceToAxis, 0)
812  elif hasattr(fp, "ShaftLength"):
813  self.label_translations[0].translation.setValue(
814  0, fp.ShaftLength + fp.DistanceToAxis, 0)
815 

Member Data Documentation

◆ font

RobRotation.ViewProviderRobRotationProxy.font

A SoFontStyle font for axes labels.

Definition at line 675 of file RobRotation.py.

◆ fp

RobRotation.ViewProviderRobRotationProxy.fp = None
static

A RobRotation object.

Definition at line 643 of file RobRotation.py.

◆ frame

RobRotation.ViewProviderRobRotationProxy.frame

A SoSeparator with a coordinate frame made from 3 RGB arrows.

Definition at line 680 of file RobRotation.py.

◆ frame_arrowhead

RobRotation.ViewProviderRobRotationProxy.frame_arrowhead

A SoSwitch translated cone for frame axes.

Definition at line 1074 of file RobRotation.py.

◆ frame_arrowhead_cone

RobRotation.ViewProviderRobRotationProxy.frame_arrowhead_cone

A SoCone arrowhead cone for frame axes.

Definition at line 1073 of file RobRotation.py.

◆ frame_arrowhead_translation

RobRotation.ViewProviderRobRotationProxy.frame_arrowhead_translation

A SoTranslation moving frame arrowheads.

Definition at line 1072 of file RobRotation.py.

◆ frame_color_x

RobRotation.ViewProviderRobRotationProxy.frame_color_x

A SoPackedColor red color for an X axis.

Definition at line 1088 of file RobRotation.py.

◆ frame_color_y

RobRotation.ViewProviderRobRotationProxy.frame_color_y

A SoPackedColor green color for an Y axis.

Definition at line 1089 of file RobRotation.py.

◆ frame_color_z

RobRotation.ViewProviderRobRotationProxy.frame_color_z

A SoPackedColor blue color for an Z axis.

Definition at line 1090 of file RobRotation.py.

◆ frame_drawstyle

RobRotation.ViewProviderRobRotationProxy.frame_drawstyle

A SoDrawStyle controlling frame axes shaft line width.

Definition at line 1112 of file RobRotation.py.

◆ frame_shaft

RobRotation.ViewProviderRobRotationProxy.frame_shaft

A SoLineSet shaft for frame axes.

Definition at line 1065 of file RobRotation.py.

◆ label_texts

RobRotation.ViewProviderRobRotationProxy.label_texts

A list of SoText2s labels denoting all axes and an origin.

Definition at line 1025 of file RobRotation.py.

◆ label_translations

RobRotation.ViewProviderRobRotationProxy.label_translations

A list of SoTranslations moving labels.

Definition at line 1026 of file RobRotation.py.

◆ labels

RobRotation.ViewProviderRobRotationProxy.labels

A list of SoSwitches containing colored translated labels.

Definition at line 1031 of file RobRotation.py.

◆ panel

RobRotation.ViewProviderRobRotationProxy.panel = None
static

A RobotPanel if one is active or None.

Definition at line 642 of file RobRotation.py.

◆ tf_object2world

RobRotation.ViewProviderRobRotationProxy.tf_object2world

A SoTransform transformation from object to world frame.

Definition at line 672 of file RobRotation.py.

◆ visualisations

RobRotation.ViewProviderRobRotationProxy.visualisations

A SoSwitch with all visualisations (frame & rotation axis).

Definition at line 683 of file RobRotation.py.


The documentation for this class was generated from the following file: