Skip to content

fix: restore reliable click-to-position cursor in 1.4.3 - #52

Merged
HelloThisWorld merged 1 commit into
mainfrom
fix/v1.4.3-click-position
Aug 27, 2026
Merged

fix: restore reliable click-to-position cursor in 1.4.3#52
HelloThisWorld merged 1 commit into
mainfrom
fix/v1.4.3-click-position

Conversation

@HelloThisWorld

@HelloThisWorld HelloThisWorld commented Aug 27, 2026

Copy link
Copy Markdown
Owner

Summary

Prepare the stable winTerm 1.4.3 hotfix and restore reliable Click to position cursor behavior when normal pointer jitter occurs between button press and release.

This PR was created as a draft because automated interaction coverage and OS-injected real-window validation passed, but the required physical-mouse validation and the five clean prompt-lifecycle repetitions are still explicitly NOT RUN. GitHub records that the repository owner merged it at 2026-08-27 00:11:07 UTC before that manual gate completed. No build label was added; tag creation and release publication remain blocked on the gate.

Related issues

No linked issue.

Detailed changes

Root cause

PointerPressed
  -> sub-threshold PointerMoved
  -> SetEndSelectionPoint called without an active selection
  -> selection-copy state marked dirty anyway
  -> PointerReleased rejected cursor repositioning
  -> stale state could poison later clicks

The Core correctly ignored selection-end updates when no selection existed, but Interactivity still treated each pointer move as a real selection change. That unrelated copy state then blocked release-time cursor repositioning.

Fix

  • Extend the selection endpoint only after crossing the existing drag threshold or while a drag selection already exists.
  • Make ControlCore::SetEndSelectionPoint report whether it actually updated a selection.
  • Mark CopyOnSelect state dirty only after a real selection update.
  • Decide plain-click repositioning from its own pending gesture state and normalize stale copy state when no selection exists.
  • Preserve existing Ctrl+Click, VT mouse, Shift+Click, double-click, triple-click, drag-selection, coordinate, padding, buffer-bound, editable-mark, full-width-glyph, and split-pane precedence and safety checks.
  • Add regression coverage for sub-threshold movement, repeated clicks, poisoned-state recovery, threshold boundaries, CopyOnSelect ownership, and stale copy state.
  • Advance all authoritative application, package, shell-module, Windows-resource, workspace-fallback, documentation, release-note, and validation references to stable 1.4.3 / 1.4.3.0 / v1.4.3.
  • Document that release installers are not Authenticode-signed and may trigger Unknown Publisher or SmartScreen warnings.

Validation performed

Environment: Windows 11 x64, local Microsoft Terminal-compatible toolchain, Debug and Release x64.

  • Focused *CursorReposition* tests: 11/11 passed.
  • Debug relevant suites: SettingsModel 245/245, TerminalApp 51/51, TerminalControl 100/100.
  • Release relevant suites: SettingsModel 245/245, TerminalApp 51/51, TerminalControl 100/100.
  • Full Release x64 application and test build: passed.
  • Smoke validation: passed.
  • scripts/winterm/verify-version.ps1: passed.
  • scripts/winterm/verify-branding.ps1: passed.
  • scripts/winterm/test-visual-progress.ps1 -SourceOnly: passed.
  • Unpackaged Release staging/layout and branding validation: passed.
  • OS-injected real-window supplemental validation: 30/30 command insertion/readback clicks passed, including actual 1px movement, beginning/middle/end positions, 20 paced clicks, and 10 rapid far-apart clicks. Paced drag, double-click word selection, and triple-click line selection also passed.
  • Physical-mouse validation: NOT RUN.
  • Five clean prompt lifecycles: NOT RUN because the validation window was closed before this gate was completed.

Checklist

  • The change is focused and does not include unrelated formatting.
  • Tests were added or updated where appropriate.
  • All tests claimed above actually ran and passed.
  • User-facing behavior and limitations are documented in this repository.
  • This source/docs commit updates the root CHANGELOG.md.
  • The Wiki Development-Changes.md ledger has been pushed with the final source SHA, link, summary, and checkpoint/release. (Wiki commit 7a39d28b40015ed149093a6264dabe0892a2a323.)
  • Documentation screenshots reuse a suitable existing sanitized winterm-site asset, or no screenshot was added. (No screenshot added.)
  • Version or schema changes include compatibility and migration notes.
  • Package identity, winterm.exe, and Microsoft Terminal coexistence remain isolated.
  • No command text, terminal output, clipboard content, credentials, or private paths are logged.
  • New source and script files contain the appropriate MIT license header. (No new source or script files.)
  • I did not include generated build output, secrets, certificates, or local absolute paths.

@HelloThisWorld
HelloThisWorld marked this pull request as ready for review August 27, 2026 00:11
@HelloThisWorld
HelloThisWorld merged commit bcfbe0e into main Aug 27, 2026
1 check failed
@HelloThisWorld
HelloThisWorld deleted the fix/v1.4.3-click-position branch August 27, 2026 00:11
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.

1 participant