2.7 KiB
Project Native Slice Editing
Policy: reuse supplied native source, OCCT-backed geometry and already completed document workflows. No automated tests, browser checks or acceptance ran.
Completed Connection
Project previously restored Slice/CompoundFilter proxies and could display their meshes, but edits required exporting a copy back to Workbench. It now supports part.document action=setSliceProperties in the existing DocumentProbe instance.
The action calls the existing executePartSliceDocument update path; no Slice, OCCT boolean, or CompoundFilter algorithm was rewritten. A defaulted ownership parameter allows Project's existing outer transaction to cover the helper, recompute and rendered-mesh serialization. Workbench keeps its previous internally managed transaction default. Native errors propagate to rollback.
Only an actual FeatureSlice proxy enables the editor. Its Mode, Tolerance and Label are returned alongside the existing native Base/Tools and dependency graph. ProjectSliceProperties allows editing these values. The facade checks parameters and confirms the returned properties match the request before refreshing the UI.
Project's existing editNative path refreshes native object selection, tree, geometry and undo/redo counts. FCStd save, close/reopen and snapshot transfer continue using the completed document flow. Existing source dependencies and CompoundFilter synchronization are reused, including their cycle/dependent-object guards. This avoids moving a document between Workers for ordinary Slice edits.
Scope and Limits
This is direct editing of Slice parameters in Project's native document, not a generic editor for every FreeCAD property. Other modules' document owners are not unified, and no single all-module live-document instance is claimed. Workbench and Project remain separate owners connected by explicit FCStd snapshots. User runtime validation remains outstanding, including undo/redo behavior after changing piece counts and restoring Python proxies from saved documents.
Measured Build
| Step | Seconds |
|---|---|
| DocumentProbe incremental build | 32.865 |
| Incremental artifact sync | 1.279 |
| Frontend build | 2.650 |
| Public sync within frontend build | 1.079 |
All commands exited 0. Only DocumentProbe was compiled and linked; no CMake, whole OCCT or unrelated module rebuild. Artifact sync copied three changed files and skipped 95. Frontend used FREECAD_WEB_FAST_LINK=ON.
Source decisions were refreshed for this explicit helper ownership extension and frontend connection; prior workflow receipts are retained. Continue remaining module behaviors instead of recreating Slice geometry, snapshot transport or this property panel. Scheduler cooldown is not proof of complete migration.