Add log selection actions and asynchronous clipboard copying - #89
Merged
Merged
Conversation
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.
Logs can be selected, but applications still have to poll for drag completion and supply their own native clipboard fallback. Add opt-in
on-selection-endedactions with log/text/coordinate payloads, plus asyncwindow.copy(text)and exportedcopy_to_clipboard(app, text).Native clipboard executables receive Unicode text on stdin with fixed argv, bounded waits, and cancellation cleanup. Textual's OSC 52 transport supplements native copying; the return value reports the native backend or
osc52, without claiming terminal delivery. The showcase opts into copying completed selections and reports the transport.Completion events ignore redraws, retained selections on scrollbar/button navigation, and preserve repeated selections including cross-widget drags. Normal Textual hosts still explicitly forward custom messages. Documentation and changelog describe the API.
Validation: 389 headless tests passed, 6 visual checks passed, Pyflakes and
git diff --checkpassed, Poetry metadata/lock check and wheel/sdist builds passed. An independent review found no remaining Important findings. Platform subprocess tests are mocked; no real clipboard was touched.Closes #78.