sketch UX, planar-face pick, extrude distance, dimensions
Summary
Branch Trailcode/b6 bundles reliability fixes for sketch-from-face picking, length-dimension presentation, face extrude with typed distance, permanent node markers, and consistent shape display modes. It also renames the edge-length dimension mode to Sketch_dim_anno for clearer naming.
Suggested branch for follow-up PR: merge Trailcode/b6 into main, or open a PR titled e.g. Sketch: planar face pick, dim_anno rename, extrude finalize, display mode.
Bug fixes
Improvements / refactors
Acceptance criteria
- Sketch from planar face: On a solid, LMB reliably selects the intended planar face and creates the sketch without requiring workarounds.
- Length dimensions: New dimensions show clean geometry (no extra spheres at endpoints) in typical views.
- Extrude: Typing a distance and committing completes extrusion with preview matching final direction; Enter does not prematurely finalize in a way that conflicts with distance edit (per current design: refresh only on Enter for extrude mode).
- Permanent nodes: “+” markers appear only while adding nodes, not in inspection or other sketch modes.
- New shapes / load: Display respects each shape’s configured display mode where applicable.
Technical notes (files touched)
| Area |
Files |
| Picking / modes / display |
occt_view.cpp, occt_view.h |
| Dimensions |
geom.cpp |
| Extrude |
shp_extrude.cpp, shp_extrude.h |
| Sketch / modes |
sketch.cpp, sketch.h, modes.h, modes.cpp, gui.cpp, gui_mode.cpp |
| Docs |
usage-sketch.md |
Related
- Oblique-view visibility for
Sketch_dim_anno is tracked separately: issue-sketch-dim-anno-oblique.md.
sketch UX, planar-face pick, extrude distance, dimensions
Summary
Branch
Trailcode/b6bundles reliability fixes for sketch-from-face picking, length-dimension presentation, face extrude with typed distance, permanent node markers, and consistent shape display modes. It also renames the edge-length dimension mode toSketch_dim_annofor clearer naming.Suggested branch for follow-up PR: merge
Trailcode/b6intomain, or open a PR titled e.g. Sketch: planar face pick, dim_anno rename, extrude finalize, display mode.Bug fixes
src/occt_view.cpp,src/occt_view.h): Runcreate_sketch_from_planar_face_()on LMB press beforeAIS_ViewController::PressMouseButton, and skip the paired controllerReleaseMouseButtonso detection state is not altered in a way that blocks face hits on solids.src/geom.cpp): BuildPrsDim_LengthDimensionfromgp_Pntinstead of temporaryTopoDS_Vertex, so OCCT does not draw vertex attachment spheres at dimension endpoints.src/shp_extrude.cpp,src/shp_extrude.h,src/occt_view.cpp): Enter only refreshes preview; finalize runs when the distance editor commits (finalize_sketch_extrude_()). TrackPlane_side m_extrude_sideso extrude direction matches the last valid cursor side relative to the sketch plane.src/shp_extrude.cpp): Centralize in_update_extrude_preview_(dist, side)withEZY_ASSERT(side != Plane_side::On)and guard near-zero distance.src/sketch.cpp): Show only inMode::Sketch_add_node; callsync_permanent_node_annos_()fromon_mode()so markers update when leaving add-node or switching tools.Improvements / refactors
Sketch_toggle_edge_dim→Sketch_dim_anno;toggle_edge_dim→toggle_edge_dim_anno(modes.h,modes.cpp,gui.cpp,gui_mode.cpp,occt_view.cpp,sketch.cpp,sketch.h). Toolbar string shortened;usage-sketch.mdstep label updated.modes.h: TidierEZY_MODE_LISTformatting (enum order unchanged — persistence).shp->get_disp_mode()instead of hardcodedAIS_Shaded(src/occt_view.cpp); extruded preview body uses the same.Acceptance criteria
Technical notes (files touched)
occt_view.cpp,occt_view.hgeom.cppshp_extrude.cpp,shp_extrude.hsketch.cpp,sketch.h,modes.h,modes.cpp,gui.cpp,gui_mode.cppusage-sketch.mdRelated
Sketch_dim_annois tracked separately:issue-sketch-dim-anno-oblique.md.