Skip to content

Shape List hover highlights shape in 3D viewer #110

@trailcode

Description

@trailcode

Summary

Hovering a row in the Shape List pane highlights the corresponding solid in the OCCT 3D viewer. Highlight color is configurable in Settings and persisted in ezycad_settings.json.

Implemented

  • Shape List rows use a single ImGui group so the full row (name, visibility, shaded, material) is one hover target.
  • Occt_view::set_shape_list_hover() drives OCCT HilightWithColor / Unhilight (distinct from yellow mouse preselect in the viewer).
  • Hover clears when the pointer leaves the list or the pane is hidden; hidden shapes are not highlighted.
  • Settings → 3D view background → Shape list hover color (RGBA); updates live while a row is hovered.
  • Persisted as gui.shape_list_hover_color (default green (0, 1, 0, 1)).
  • Occt_view::refresh_shape_list_hover_highlight() reapplies highlight after color changes; hover cleared when a hovered shape is deleted.

Files

  • src/gui.cpp, src/gui.h
  • src/gui_settings.cpp
  • src/occt_view.cpp, src/occt_view.h
  • res/ezycad_settings.json

Acceptance criteria

  • Hovering a visible shape row shows a green (or user-configured) highlight on that shape in the 3D view.
  • Moving off the list or closing the pane removes the highlight.
  • Changing Shape list hover color in Settings updates the highlight immediately.
  • Saved settings restore the chosen hover color on restart.
  • 3D mouse preselect (yellow) still works when the pointer is over the viewer.

Notes

  • Sketch List parity (hover → highlight) is out of scope unless added in a follow-up.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions