]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Icon added and debug output is removed
authorsbh <sergey.belash@opencascade.com>
Mon, 17 Nov 2014 14:56:41 +0000 (17:56 +0300)
committersbh <sergey.belash@opencascade.com>
Mon, 17 Nov 2014 14:56:41 +0000 (17:56 +0300)
src/PythonFeaturesPlugin/PythonFeaturesPlugin_Box.py
src/PythonFeaturesPlugin/plugin-PythonFeatures.xml

index b08f98b412d439c9a3885f88167fdb589b719bb7..2a4f5b8191b3bceba5d0bee9455bc447845e8fda 100644 (file)
@@ -25,8 +25,8 @@ class PythonFeaturesPlugin_Box(ModelAPI.ModelAPI_Feature):
     return PythonFeaturesPlugin_Box.ID()
 
   def initAttributes(self):
-    # C++ static methods (in example Type() of ModelAPI_AttributeDouble
-    # should be called like this: moduleName.ClassName_StaticMethod()
+    # C++ static methods (in example "type()" of the ModelAPI_AttributeDouble
+    # should be called like this: moduleName.ClassName_staticMethod()
     self.data().addAttribute(PythonFeaturesPlugin_Box.WIDTH_ID(), ModelAPI.ModelAPI_AttributeDouble_type())
     self.data().addAttribute(PythonFeaturesPlugin_Box.LENGTH_ID(), ModelAPI.ModelAPI_AttributeDouble_type())
     self.data().addAttribute(PythonFeaturesPlugin_Box.HEIGHT_ID(), ModelAPI.ModelAPI_AttributeDouble_type())
@@ -35,7 +35,7 @@ class PythonFeaturesPlugin_Box(ModelAPI.ModelAPI_Feature):
     aWidth  = self.real(PythonFeaturesPlugin_Box.WIDTH_ID()).value()
     aLength = self.real(PythonFeaturesPlugin_Box.LENGTH_ID()).value()
     aHeight = self.real(PythonFeaturesPlugin_Box.HEIGHT_ID()).value()
-    print ("Box W:{0} L:{1} H:{2}".format(aWidth, aLength, aHeight))
+    print ("Box W:{0} L:{1} H:{2}".format(aWidth, aLength, aHeight))
     # aResult = document().createBody(data())
     # aResult.store(UserPackage.makeBox(aLength, aWidth, aHeight)
     # self.setResult(aResult)
index 679cd22aabc2618004150d0c7d8d31a5322595b8..2f7b97bc5163ea2d7649559786dc87e92d1ff63b 100644 (file)
@@ -1,7 +1,7 @@
 <plugin>
   <workbench id="Features" document="Part">
     <group id="Basic">
-      <feature id="Box" title="Box" tooltip="Create a box" icon="">
+      <feature id="Box" title="Box" tooltip="Create a box" icon=":pictures/part_ico.png">
           <source path="box_widget.xml"/>
       </feature>
     </group>