Skip to content

Fix/isolation geometry and numpad zoom - #5

Open
spaxxomatic wants to merge 2 commits into
dwrobel:mstanciu_Beta_1.0from
spaxxomatic:fix/isolation-geometry-and-numpad-zoom
Open

Fix/isolation geometry and numpad zoom#5
spaxxomatic wants to merge 2 commits into
dwrobel:mstanciu_Beta_1.0from
spaxxomatic:fix/isolation-geometry-and-numpad-zoom

Conversation

@spaxxomatic

Copy link
Copy Markdown

Fixed a crash during isolation routing, added numpad keys + and - for zoom in / out since '=' does not work on a german keyboard

…settings

Geometry.isolation_geometry() (and get_exteriors()/get_interiors()) return a
plain list of BaseGeometry rather than a Shapely Multi* geometry. When
generate_envelope() was called with invert=False (i.e. the default climb
milling setting, tools_iso_milling_type="cl"), that raw list was returned
as-is instead of being normalized into a single geometry object.

The caller in combined_normal() then appended the whole list as one element
of solid_geo (since it isn't a MultiLineString/MultiPolygon instance), and
flatten_shapely_geometry() raised AssertionError on that nested list when
run with the default "Complete" isolation type (iso_type=2) and default
climb milling.

Normalize geom_shp into a single geometry via unary_union() whenever it's a
list, regardless of invert, so downstream code always receives a proper
Shapely geometry as documented.
Zoom In is bound to the '=' key (Key_Equal) and Zoom Out to '-' (Key_Minus).
Key_Minus is shared between the main keyboard row and the numpad, so Zoom
Out already works from the numpad. Key_Plus (numpad +) has no such overlap
with Key_Equal, so Zoom In had no numpad equivalent and could be awkward to
reach on non-US keyboard layouts where '=' isn't a dedicated key (e.g.
German layouts, where it's Shift+0).

Accept Key_Plus alongside Key_Equal in the main view and in the Geometry,
Gerber, and Excellon editors, mirroring how Zoom Out already behaves.
@dwrobel

dwrobel commented Aug 10, 2026

Copy link
Copy Markdown
Owner

Would you please consider sending this fix upstream?
In other words, I would prefer not forking flatcam.

@spaxxomatic

Copy link
Copy Markdown
Author

I don't get it, what should I do ?

@dwrobel

dwrobel commented Aug 11, 2026

Copy link
Copy Markdown
Owner

Send the PR to https://bitbucket.org/marius_stanciu/flatcam_beta/branch/Beta_1.0 (which is the upstream).

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.

2 participants