[general]
name=Align Edge
qgisMinimumVersion=3.28
qgisMaximumVersion=4.99
description=Preview and align shared topology edges, with protected reference targets, exact endpoints and undo support.
about=Adds an Align Edge tool to the Advanced Digitizing toolbar. It builds a map topology from visible editable line and polygon layers and configured target-only references. Hover to preview the moving edge, target edge, gap area and maximum shift. Click to align every editable owner, using exact target XY and source-derived Z/M. Unsafe endpoint moves are blocked. Tab cycles targets; Esc cancels highlights and queued clicks. Results are validated and written with undo support; failed multi-layer writes roll back without losing prior edits. Reference layers never move and need not be in edit mode.
version=1.4.2
author=Charles
email=pwizzle77@gmail.com
homepage=https://github.com/pwizzle77-cmd/qgis-align-edge
repository=https://github.com/pwizzle77-cmd/qgis-align-edge
tracker=https://github.com/pwizzle77-cmd/qgis-align-edge/issues
category=Vector
tags=topology,align,edge,digitizing,editing,arcgis,snapping,gap,sliver
experimental=False
deprecated=False
icon=icons/align_edge.svg
hasProcessingProvider=no
changelog=1.4.2 - The clustered-vertex safety check now allows target owners whose vertices are within the cluster tolerance of each other, instead of demanding bit-for-bit equality. Fixes alignment being refused in one direction when adjoining layers were digitized a hair's-width apart.
 1.4.1 - Optional generic Keystone placement: the existing action appears automatically in Edit > Tools and Modify Features > Alignment, with its original toggle, enabled state and Settings action. Unloading removes the declaration and stale actions. Alignment calculations are unchanged.
 1.4.0 - Multi-layer failures roll back without losing earlier edits. Esc cancels queued clicks. Alignment copies exact target endpoints and blocks moves that would disconnect unchanged edges. New Z/M values are interpolated from the source. Dense topology work yields in smaller chunks. Restore Defaults stays local until OK. Layer roles include target-only references that do not need edit mode. Source and target versions are checked before writing; stale builds are discarded.
 1.3.3 - Clicking the Align Edge button again turns the tool off and returns to the previous map tool; Esc with nothing highlighted does the same.
 1.3.2 - Error handlers flagged by the plugin security scan now write the error to the diagnostic log instead of silently ignoring it (same fallbacks, no change in behaviour). Metadata: removed the deprecated Qt6 support flag (QGIS 4 support is declared by qgisMaximumVersion=4.99).
 1.3.1 - A redraw that never finishes no longer keeps rebuilding topology on the main thread. While the tool is on, the map draws one layer at a time and preview redraws are paused. A redraw still busy after 2 s is cancelled and painted once; layer data is not read on that turn.
 1.3.0 - Features are cached and kept current from the layers' edit signals, so aligning, undo, panning and tooltips no longer read the data source. Data is only read while the map is not drawing, with no time limit (v1.2.0 could freeze by reading behind a map render that never finished).
 1.2.0 - No worker threads: topology builds in short slices on the main thread (fixes the map getting stuck "drawing" with layers missing after several aligns). Waiting for the map is capped at 2 s. Target selection: nearest edges are offered by enclosed area instead of the strict 0.5 length ratio, so fat gaps such as triangles are offered from both sides. Diagnostic log align_edge_debug.log (can be turned off in settings).
 1.1.0 - Fix QGIS freezing: topology is built in a background task; layer data is only read when the map is not drawing (busy cursor while waiting); feature iterators are always closed; hover distance calculation is indexed (long edges went from ~18 s to ~0.2 s); faster noding with no large memory use; tooltip no longer forces canvas repaints.
 1.0.0 - First release.
