feat: integrate interactive annotations into main (+ CI binary-build fixes)#7
Merged
Conversation
E1: GLE print-based calibration protocol injected into preview temp scripts only; per-axes data/cm/pixel transforms with log-axis support (PreviewGeometry, geometry_ready signal, never blocks rendering). E2: SVG vector preview as default with QtSvg validation, sticky PNG fallback and View-menu toggle; Cairo-safe font injection for SVG mode (GLE default PostScript font silently truncates Cairo output at exit 0); frozen view_mapping contract for the annotation overlay. E3: generated .dat sidecars carry sanitized named headers by default; column_names round-trip through model/writer/recognizer; GLE auto-key from headers neutralized with explicit key clauses (byte-identical rendering verified). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
F1: AnnotationOverlay on the live preview - transparent hit-areas over rendered text, drag with ghost and anti-jump sequencing around the debounced re-render, mid-render drag preservation, inline editing, add-text mode (shortcut T, Esc cancels), Delete removal, log-axis inverse mapping, pan suspension while hovering items. F2: TextsPanel property tab (content, position, color, size, alignment; honest disabled state for fields GLE never renders). MF integration: Texts tab wired with loop-free two-way selection sync between panel and overlay, surviving re-render rebuilds, with cross-axes retargeting. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… fix G1: double-click header renaming for figure-owned sidecars with full propagation (table, combos, series column_names, next save); external referenced files stay read-only - gleplot never rewrites user source data. G2: guide sections for on-canvas annotations, preview rendering modes, and named headers; README/rst sync; example regenerated with three synthetic annotations, verified warning-free parse and real GLE compile. Fix: .gitignore ignored *.gle and data_*.dat repo-wide, so the shipped example figure was never actually committed (docs referenced files absent from clones). Negation patterns added; example files tracked. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Data safety (critical): import-vs-reference classification now trusts only the gleplot metadata block; the filename heuristic is removed, so hand-written .gle files can never cause gleplot to rewrite a user data file (reviewer repro: md5-unchanged guarantee test). Loader: all- missing first rows are data not headers; multi-word whitespace headers fall back to positional names with a warning. Panel ownership resolves by sidecar basename, fixing stale propagation after Save As. Overlay: annotations disarm in read-only GLE-preview mode (drags there mutated the hidden document); undo/redo actions stay authoritative in preview mode; figure_replaced aborts active interactions (no phantom items after undo mid-drag); mapping fingerprints abort drags across PNG/SVG switches (no wrong-space commits); degenerate calibrations (non-positive log bounds, zero ranges) are skipped with warnings, not clamped; Texts panel rejects non-finite coordinates and no longer clobbers focused editors; orphaned-dict commits drop silently. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Text clusters: set hei/color/just are now optional and sticky across clusters (matching GLE interpreter semantics; writer suppresses redundant set lines to keep the fixed point); blank lines between clusters no longer abort recognition; TeX markup in write strings round-trips byte-exact. Column headers: GLE-style indexed comment blocks (! c N = name) are recovered as column names with full-coverage validation and unicode preserved; last-comment-line fallback retained; both display-only so vouched sidecar round-trips stay byte-identical. Texts panel: selection changes during list rebuilds are explicitly guarded (spurious currentRowChanged during QListWidget.clear); remove flow guard aligned; field-isolation audit encoded as tests. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
# Conflicts: # docs/guides/GUI_EDITOR.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The interactive-annotations feature (PR #2,
feature/gui-annotations) never reachedmain: it was merged into the v1 branch (feature/pyside-gui-editor) 11 seconds after that branch had already been snapshotted intomainvia PR #1. So every release to date — including the v1.4.0 desktop build — shipped the older recognizer with none of the annotation work. Symptom: annotations don't parse correctly in the built app.This brings that work onto current
mainvia a real merge (Git auto-merged all code; the only textual conflict was one docs paragraph, resolved to keep both the GLE-setup and annotations tab descriptions).What lands
From PR #2:
gui/geometry.py,gui/annotations.py,gui/panels/texts_panel.py).Also included (folds in PR #6)
The CI fixes required for this release to actually build installers — otherwise v1.5.0 would hit the same failures v1.4.0 did:
release.yml:actions: writeso the release can dispatch the binary build (was HTTP 403)..gitignore+packaging/gleplot.spec: the hand-authored spec was swallowed by the*.specrule and never committed (build died with "Spec file not found").PR #6 is superseded by this PR and can be closed.
Validation
main_window.py/preview.py.--smoke-testpasses; annotation + GLE-setup modules import cleanly.On merge: semantic-release cuts v1.5.0, which auto-dispatches
release-binaries.ymland attaches the Windows.exe+ macOS arm64.dmg.🤖 Generated with Claude Code