Create Distance constraint

 1from salome.shaper import model
 2
 3model.begin()
 4partSet = model.moduleDocument()
 5Part_1 = model.addPart(partSet)
 6Part_1_doc = Part_1.document()
 7Sketch_1 = model.addSketch(Part_1_doc, model.defaultPlane("XOY"))
 8SketchCircle_1 = Sketch_1.addCircle(24.1, 24.5, 18.2)
 9SketchLine_1 = Sketch_1.addLine(54.3, 93.4, 91.2, 56.4)
10SketchConstraintDistance_1 = Sketch_1.setDistance(SketchCircle_1.center(), SketchLine_1.result(), 70.0, True)
11model.do()
12model.end()

Download this script