MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / Line

Class Line

src/Mod/TemplatePyMod/FeaturePython.py:122–131  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

120# -----------------------------------------------------------------------------
121
122class Line:
123 def __init__(self, obj):
124 ''' Add two point properties '''
125 obj.addProperty("App::PropertyVector","p1","Line","Start point", locked=True)
126 obj.addProperty("App::PropertyVector","p2","Line","End point", locked=True).p2=FreeCAD.Vector(1,0,0)
127 obj.Proxy = self
128
129 def execute(self, fp):
130 ''' Print a short message when doing a recomputation, this method is mandatory '''
131 fp.Shape = Part.makeLine(fp.p1,fp.p2)
132
133class ViewProviderLine:
134 def __init__(self, obj):

Callers 1

makeLineFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected