thickness

 1from SketchAPI import *
 2
 3from salome.shaper import model
 4
 5model.begin()
 6partSet = model.moduleDocument()
 7
 8### Create Part
 9Part_1 = model.addPart(partSet)
10Part_1_doc = Part_1.document()
11
12### Create Box
13Box_1 = model.addBox(Part_1_doc, 200, 200, 200)
14Box_2 = model.addBox(Part_1_doc, 200, 200, 200)
15
16### Create Shell
17Shell_1 = model.addShell(Part_1_doc, [model.selection("FACE", "Box_1_1/Top"),
18                                      model.selection("FACE", "Box_1_1/Front"),
19                                      model.selection("FACE", "Box_1_1/Left")])
20
21# Thickness mode 1: thicken a shell/face
22# isInside = False, so thicken towards outside
23Thickness_1 = model.addThickness(Part_1_doc, model.selection("SHELL", "Shell_1_1"), 30, False)
24
25# Thickness mode 2: hollowed solid
26# isInside = True, so thicken towards inside
27Thickness_2 = model.addHollowedSolid(Part_1_doc,
28                                     model.selection("SOLID", "Box_2_1"),
29                                     40,
30                                     [model.selection("FACE", "Box_2_1/Top"),
31                                      model.selection("FACE", "Box_2_1/Left")],
32                                     True)
33
34model.end()

Download this script