Skip to content

Commit

Permalink
re ran black
Browse files Browse the repository at this point in the history
  • Loading branch information
Jojain committed Nov 8, 2024
1 parent 80acfa3 commit f2d4524
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/build123d/topology.py
Original file line number Diff line number Diff line change
Expand Up @@ -366,7 +366,8 @@

Shapes = Literal["Vertex", "Edge", "Wire", "Face", "Shell", "Solid", "Compound"]

TrimmingTool = Union[Plane,"Shell", "Face"]
TrimmingTool = Union[Plane, "Shell", "Face"]


def tuplify(obj: Any, dim: int) -> tuple:
"""Create a size tuple"""
Expand Down Expand Up @@ -2782,7 +2783,9 @@ def split(self, tool: TrimmingTool, keep: Keep = Keep.TOP) -> Self:
shape_list.Append(self.wrapped)

# Define the splitting tool
trim_tool = Face.make_plane(tool).wrapped if isinstance(tool, Plane) else tool.wrapped
trim_tool = (
Face.make_plane(tool).wrapped if isinstance(tool, Plane) else tool.wrapped
)
tool_list = TopTools_ListOfShape()
tool_list.Append(trim_tool)

Expand Down Expand Up @@ -6481,7 +6484,9 @@ def is_coplanar(self, plane: Plane) -> bool:
and 1 - abs(plane.z_dir.dot(Vector(normal))) < TOLERANCE
)

def thicken(self, depth: float, normal_override: Optional[VectorLike] = None) -> Solid:
def thicken(
self, depth: float, normal_override: Optional[VectorLike] = None
) -> Solid:
"""Thicken Face
Create a solid from a potentially non planar face by thickening along the normals.
Expand Down Expand Up @@ -6997,6 +7002,7 @@ def thicken(self, depth: float) -> Solid:
"""
return _thicken(self.wrapped, depth)


class Solid(Mixin3D, Shape):
"""A Solid in build123d represents a three-dimensional solid geometry
in a topological structure. A solid is a closed and bounded volume, enclosing
Expand Down Expand Up @@ -8856,6 +8862,7 @@ def symbol(self) -> Compound: # pragma: no cover
"""A CAD object positioned in global space to illustrate the joint"""
raise NotImplementedError


def _thicken(obj: TopoDS_Shape, depth: float):
solid = BRepOffset_MakeOffset()
solid.Initialize(
Expand All @@ -8879,6 +8886,7 @@ def _thicken(obj: TopoDS_Shape, depth: float):

return result.clean()


def _make_loft(
objs: Iterable[Union[Vertex, Wire]],
filled: bool,
Expand Down

0 comments on commit f2d4524

Please sign in to comment.