Skip to content

Zigzag deselect - #88

Merged
m-beau merged 1 commit into
m-beau:devfrom
tabedzki:tabedzki/feat/zigzag-deselect
Nov 2, 2026
Merged

m-beau merged 1 commit into
m-beau:devfrom
tabedzki:tabedzki/feat/zigzag-deselect

Conversation

@tabedzki

@tabedzki tabedzki commented Nov 2, 2026

Copy link
Copy Markdown
Collaborator

Implements the ZigZag deselect as requested by a user. The user interacted and verified that this implementation achieved what they were looking for.

@tabedzki tabedzki changed the title Tabedzki/feat/zigzag deselect Zigzag deselect Nov 2, 2026
@tabedzki
tabedzki changed the base branch from main to dev November 2, 2026 15:28
@tabedzki
tabedzki requested review from m-beau and a balanced review from Copilot and removed request for m-beau November 2, 2026 15:29
@codecov-commenter

codecov-commenter commented Nov 2, 2026 •

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (dev@9abfc40). Learn more about missing BASE report.
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@          Coverage Diff           @@
##             dev      #88   +/-   ##
======================================
  Coverage       ?   84.46%           
======================================
  Files          ?       21           
  Lines          ?     3411           
  Branches       ?        0           
======================================
  Hits           ?     2881           
  Misses         ?      530           
  Partials       ?        0           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The GUI help and guide incorrectly promise that red electrodes inside the selection box remain selected, although _deselect_dependents can deselect them as blockers regardless of location.

1 open issue
What changed in this PR

Adds a Zigzag-deselect dependents tool to the channel-map GUI, allowing users to free blocked zigzag-pattern sites before selecting them.

Changes:

  • Shares dependent-deselection logic and adds zigzag filtering.
  • Integrates the sixth toolbar tool and passes tool descriptions directly to JavaScript callbacks.
  • Adds regression coverage and updates GUI help and documentation.
File Description
tests/​test_zigzag_dependent_deselect.py Tests filtering, selection behavior, undo, and toolbar integration.
pixelmap/​gui/​gui.py Implements the new mode, shared helper, toolbar integration, and help text.
docs/​gui-guide.md Documents the sixth tool and the two-step zigzag selection workflow.

Review effort: Balanced

Comment thread pixelmap/gui/gui.py Resolved
tabedzki added a commit to tabedzki/pixelmap that referenced this pull request Nov 2, 2026
…he box

The in-GUI help and the GUI guide said red electrodes inside the box are
left alone, but a red zigzag site in the box is deselected when it blocks
a targeted black zigzag site. Reword both to say blockers are deselected
wherever they sit, and add a regression test pinning that behaviour.

Addresses review feedback on m-beau#88.

Assisted-by: ClaudeCode:claude-opus-5-5
@tabedzki
tabedzki force-pushed the tabedzki/feat/zigzag-deselect branch from c6d3e66 to 2a9e69d Compare November 2, 2026 15:50
@m-beau

m-beau commented Nov 2, 2026

Copy link
Copy Markdown
Owner

Need to

  • add an SVG for the button
  • add the relevant section to the documentation (in the readthedocs, and in the GUI side panel, alngside the other buttons)

@tabedzki
tabedzki force-pushed the tabedzki/feat/zigzag-deselect branch from b9520c5 to 1c9c8b9 Compare November 2, 2026 16:09

@m-beau m-beau left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

doc needs fixing thats all!

Comment thread docs/gui-guide.md Resolved
Comment thread docs/gui-guide.md Resolved
Comment thread docs/gui-guide.md Resolved
Add a sixth drag-box tool, "Zigzag-deselect Dependents". It filters the
box to the zigzag-pattern sites (the same filter Zigzag-select uses) and
then runs the existing deselect-dependents logic on them, through a
shared `_deselect_dependents` helper. Only the zigzag half of a blocked
region is freed, and the complementary half of the blocking selection
stays selected, so a following Zigzag-select drag finishes the job
without re-selecting the blocking region.

Pass tool descriptions to the active-tool JS via CustomJS args instead of
order-dependent placeholder replacement. Use the upstream icon exported
from selector_boxes.svg, and mirror it and the updated Deselect
dependents icon into docs/_static. Document the tool in the GUI guide and
the in-GUI selection tools panel, and clarify that red blockers are deselected
wherever they sit, inside or outside the box.

Tests pin the wiring closure property (zigzag sites only conflict with
zigzag sites) on all four probe types, filtered freeing, in-box red
blockers, no-op cases, single-tap toggling, one undo step per drag, the
unchanged existing tool, toolbar wiring, and that the side-panel help covers every box tool.

Assisted-by: Codex:gpt-6.1-sol
Assisted-by: ClaudeCode:claude-opus-5-5
@tabedzki
tabedzki force-pushed the tabedzki/feat/zigzag-deselect branch from 1c9c8b9 to c0d1372 Compare November 2, 2026 16:24
@m-beau
m-beau merged commit f3e0c69 into m-beau:dev Nov 2, 2026
2 checks passed
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.

4 participants