@@ -2784,6 +2784,7 @@ def cutEach(
2784
2784
2785
2785
return self .newObject ([s ])
2786
2786
2787
+ # TODO: almost all code duplicated!
2787
2788
# but parameter list is different so a simple function pointer won't work
2788
2789
def cboreHole (
2789
2790
self : T ,
@@ -2811,9 +2812,15 @@ def cboreHole(
2811
2812
One hole is created for each item on the stack. A very common use case is to use a
2812
2813
construction rectangle to define the centers of a set of holes, like so::
2813
2814
2814
- s = Workplane(Plane.XY()).box(2,4,0.5).faces(">Z").workplane()\
2815
- .rect(1.5,3.5,forConstruction=True)\
2816
- .vertices().cboreHole(0.125, 0.25,0.125,depth=None)
2815
+ s = (
2816
+ Workplane()
2817
+ .box(2, 4, 0.5)
2818
+ .faces(">Z")
2819
+ .workplane()
2820
+ .rect(1.5, 3.5, forConstruction=True)
2821
+ .vertices()
2822
+ .cboreHole(0.125, 0.25, 0.125, depth=None)
2823
+ )
2817
2824
2818
2825
This sample creates a plate with a set of holes at the corners.
2819
2826
@@ -2866,9 +2873,15 @@ def cskHole(
2866
2873
One hole is created for each item on the stack. A very common use case is to use a
2867
2874
construction rectangle to define the centers of a set of holes, like so::
2868
2875
2869
- s = Workplane(Plane.XY()).box(2,4,0.5).faces(">Z").workplane()\
2870
- .rect(1.5,3.5,forConstruction=True)\
2871
- .vertices().cskHole(0.125, 0.25,82,depth=None)
2876
+ s = (
2877
+ Workplane()
2878
+ .box(2, 4, 0.5)
2879
+ .faces(">Z")
2880
+ .workplane()
2881
+ .rect(1.5, 3.5, forConstruction=True)
2882
+ .vertices()
2883
+ .cskHole(0.125, 0.25, 82, depth=None)
2884
+ )
2872
2885
2873
2886
This sample creates a plate with a set of holes at the corners.
2874
2887
@@ -2914,9 +2927,15 @@ def hole(
2914
2927
One hole is created for each item on the stack. A very common use case is to use a
2915
2928
construction rectangle to define the centers of a set of holes, like so::
2916
2929
2917
- s = Workplane(Plane.XY()).box(2,4,0.5).faces(">Z").workplane()\
2918
- .rect(1.5,3.5,forConstruction=True)\
2919
- .vertices().hole(0.125, 0.25,82,depth=None)
2930
+ s = (
2931
+ Workplane()
2932
+ .box(2, 4, 0.5)
2933
+ .faces(">Z")
2934
+ .workplane()
2935
+ .rect(1.5, 3.5, forConstruction=True)
2936
+ .vertices()
2937
+ .hole(0.125, 0.25, 82, depth=None)
2938
+ )
2920
2939
2921
2940
This sample creates a plate with a set of holes at the corners.
2922
2941
0 commit comments