Skip to content

Report node size changes made while the node editor is zoomed - #637

Merged
matt-edmondson merged 1 commit into
mainfrom
claude/node-editor-zoom-size-71jukb
Oct 14, 2026
Merged

matt-edmondson merged 1 commit into
mainfrom
claude/node-editor-zoom-size-71jukb

Conversation

@matt-edmondson

Copy link
Copy Markdown
Contributor

Requested by Matt · project thread

Before: a node that grew or shrank while the canvas was zoomed kept its old size in the engine until the view returned to zoom 1, so FitToView centred on stale sizes and cut off nodes that grew.

After: a measurement that changes while the zoom holds still is reported, scaled back by the zoom, and replaced by the exact size the next time the view is at its own scale. A change of zoom alone is still never read as a resize, so zooming never re-spaces the graph.

How: GetNodeDimensionUpdates remembers, per node, the measurement, the zoom Render drew it at, and the size last reported. A different zoom only updates the memory (reporting the exact size at zoom 1 if it differs); the same zoom with a different measurement is a content change. New ZoomTests cover a node that grows while zoomed (fails without the fix) and the correction at zoom 1.

Fixes #636

🤖 Generated with Claude Code

https://claude.ai/code/session_01Nmg4pHCiNuGWLdXBSa6Njj


Generated by Claude Code

A node whose content grew at a zoom other than 1 kept its old size in the
engine, so FitToView centred on stale sizes. A change of zoom alone is still
never read as a resize; a measurement that changes while the zoom holds is
reported scaled back, and corrected once the view is at its own scale.

Fixes #636

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Nmg4pHCiNuGWLdXBSa6Njj
@matt-edmondson matt-edmondson self-assigned this Oct 14, 2026
@sonarqubecloud

Copy link
Copy Markdown

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.

NodeEditorRenderer ignores node size changes while the canvas is zoomed

2 participants