Skip to content

Fix extrusion hole assignment for nested sketch regions - #76

Open
WC3D wants to merge 4 commits into
Formsmith746:mainfrom
WC3D:fix/extrude-nested-regions
Open

Fix extrusion hole assignment for nested sketch regions#76
WC3D wants to merge 4 commits into
Formsmith746:mainfrom
WC3D:fix/extrude-nested-regions

Conversation

@WC3D

@WC3D WC3D commented Aug 25, 2026

Copy link
Copy Markdown

Note: stacked on #74 (sketch menu tools) — merge that first; this will be retargeted to main after.

When a sketch contains profiles inside other profiles (a circle within a rectangle, overlapping outlines, or a partially unselected region), the fallback mesh extrusion inferred hole nesting from outline areas. That heuristic mis-grouped geometry — for example turning sibling regions into holes — so sketches within a sketch could extrude incorrectly after modifying or clearing region selection.

Holes are now assigned per selected region: each region carries its own outer boundary and hole paths, and every selected region extrudes exactly as shown in the sketch workspace.

Review just the last commit (057adf1). Unit + real-kernel e2e suites pass.

Expand the sketch toolbar with new geometry and editing commands:

Draw tools: center-point circle, two-point circle, corner/center
rectangle, inscribed/circumscribed/edge polygon with a side-count
stepper, and placed sketch text.

Create / Transform: offset paths, mirror across an axis or selected
segment, and rectangular/circular patterns driven by a small options
panel.

Inspect: dimension tool with driving length dimensions, reference
distance dimensions between point/midpoint/intersection anchors,
and horizontal/vertical/fixed constraints with a lightweight solver.

Supporting changes: planar region detection so extrudes can target
overlapping profiles (with region-aware OCCT extrude + healing),
geometry libs for the new tools, .skf persistence for constraints/
dimensions/texts, and unit plus real-kernel e2e tests.
A CSS extraction pass dropped 33 rules for classes that existed
upstream but were restyled by the sketch menu work: selectable
extrusion regions, sketch points (incl. fixed state), constrained
segments, segment dimension labels, drag/curve handles, measurement
points, polygon side stepper, constraint inspector, image resize
handle, grid settings, and toolbar disabled states. Without them,
selected extrusion profiles gave no visual feedback.
@WC3D
WC3D force-pushed the fix/extrude-nested-regions branch from 057adf1 to b6167af Compare August 25, 2026 07:49
WC3D added 2 commits August 25, 2026 04:02
The closed-profile hit-target overlay sat above the region fill
layer in the sketch SVG, so with Select active every click inside a
profile started a whole-shape drag instead of toggling that
region's extrusion selection. Region fills now receive clicks as
intended; whole-shape dragging still works via marquee selection
and selected-shape handles.
Assign holes to outlines per selected region instead of inferring
nesting from outline areas. The area heuristic mis-grouped profiles
inside a sketch (for example an overlapping or unselected inner
profile), so editing a sketch and toggling region selection could
produce wrong geometry. Regions now carry their own outer/hole
paths, and each selected region extrudes exactly as shown.
@WC3D
WC3D force-pushed the fix/extrude-nested-regions branch from b6167af to 2b44ea2 Compare August 25, 2026 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant