# Initialize attributes of the feature
self._point_data = geomDataAPI_Point2D(
- self._feature.data().attribute("PointCoordinates")
+ self._feature.data().attribute("PointCoordindates")
)
self.setValue(x, y)
self.execute()
"""Constructor"""
### Create the feature
self.my = sketch.addFeature("SketchPoint")
- geomDataAPI_Point2D( self.my.data().attribute("PointCoordinates") ).setValue(x, y)
+ geomDataAPI_Point2D( self.my.data().attribute("PointCoordindates") ).setValue(x, y)
self.my.execute()
def pointData (self):
"""Returns points attribute"""
- return geomDataAPI_Point2D( self.my.data().attribute("PointCoordinates") )
+ return geomDataAPI_Point2D( self.my.data().attribute("PointCoordindates") )
def result (self):
"""Returns result object"""
/// Coordinates of the point
inline static const std::string& COORD_ID()
{
- static const std::string MY_COORD_ID("PointCoordinates");
+ static const std::string MY_COORD_ID("PointCoordindates");
return MY_COORD_ID;
}
/// Returns the kind of a feature
aSession.startOperation()
aSketchPoint = aSketchFeature.addFeature("SketchPoint")
aSketchPointCoords = geomDataAPI_Point2D(
- aSketchPoint.attribute("PointCoordinates"))
+ aSketchPoint.attribute("PointCoordindates"))
aSketchPointCoords.setValue(50., 50.)
aSketchLine = aSketchFeature.addFeature("SketchLine")
aLineAStartPoint = geomDataAPI_Point2D(aSketchLine.attribute("StartPoint"))
# aSketchPoint = aDocument.addFeature("SketchPoint")
aSketchPoint = aSketchFeature.addFeature("SketchPoint")
assert (aSketchPoint.getKind() == "SketchPoint")
-coords = geomDataAPI_Point2D(aSketchPoint.attribute("PointCoordinates"))
+coords = geomDataAPI_Point2D(aSketchPoint.attribute("PointCoordindates"))
assert (coords.x() == 0)
assert (coords.y() == 0)
assert (not coords.isInitialized())
aSketchReflist = aSketchFeature.reflist("Features")
assert (aSketchReflist.size() == 1)
assert (len(aSketchReflist.list()) == 1)
-coords = geomDataAPI_Point2D(aSketchPoint.attribute("PointCoordinates"))
+coords = geomDataAPI_Point2D(aSketchPoint.attribute("PointCoordindates"))
assert (coords.x() == 10.0)
assert (coords.y() == 10.0)
#=========================================================================
<!--icon=":pictures/x_point.png"-->
</feature>
<feature id="SketchPoint" title="Point" tooltip="Create point" icon=":icons/point.png">
- <sketch-2dpoint_selector id="PointCoordinates" title="Point" tooltip="Point coordinates"/>
+ <sketch-2dpoint_selector id="PointCoordindates" title="Point" tooltip="Point coordinates"/>
<boolvalue id="Auxiliary" label="Auxiliary" default="false" tooltip="Construction element" obligatory="0"/>
</feature>
<feature id="SketchLine" title="Line" tooltip="Create line" icon=":icons/line.png">
mouseClick(waitForObject(":OpenParts*_AppElements_ViewPort"), annotaion_point[0], annotaion_point[1], 0, Qt.LeftButton)
waitFor("object.exists(':Distance.First object_QLineEdit')", 20000)
- test.compare(str(findObject(":Distance.First object_QLineEdit").text), "SketchPoint_1/PointCoordinates")
+ test.compare(str(findObject(":Distance.First object_QLineEdit").text), "SketchPoint_1/PointCoordindates")
waitFor("object.exists(':Distance.Second object_QLineEdit')", 20000)
test.compare(str(findObject(":Distance.Second object_QLineEdit").text), "SketchLine_1")
waitFor("object.exists(':Distance.ConstraintValue_ModuleBase_ParamSpinBox')", 20000)