Skip to content

vterm.py: Adds support for bracketed paste mode. Fixes #452 #594

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 17, 2023
Merged

vterm.py: Adds support for bracketed paste mode. Fixes #452 #594

merged 2 commits into from
Aug 17, 2023

Conversation

danschwarz
Copy link
Contributor

@danschwarz danschwarz commented Aug 17, 2023

NOTE, this is a new PR replacing #576 . All the same code, plus automated tests included now.
Please refer to the #576 comment thread for discussion of what's going on here and why.

Checklist
  • I've ensured that similar functionality has not already been implemented
  • I've ensured that similar functionality has not earlier been proposed and declined
  • I've branched off the master or python-dual-support branch
  • I've merged fresh upstream into my branch recently
  • I've ran tox successfully in local environment
  • I've included docstrings and/or documentation and/or examples for my code (if this is a new feature)
Description:

Note that bracketed paste mode is NOT automatically enabled for applications; this would cause problems for any apps that aren't bracketed-paste-aware.

There's an example of how to enable it in your urwid application in examples/terminal.py.

Then you need to actually handle the 'paste begin' / 'paste end' key sequences in your application's keypress method. There's no example code for this yet.

For more info on bracketed paste mode, see Wikipedia
or https://cirw.in/blog/bracketed-paste

@coveralls
Copy link

coveralls commented Aug 17, 2023

Coverage Status

coverage: 73.458% (+0.3%) from 73.188% when pulling bced054 on danschwarz:bracketed2 into 2e3a7ec on urwid:master.

@penguinolog penguinolog merged commit a8c0d71 into urwid:master Aug 17, 2023
@danschwarz danschwarz deleted the bracketed2 branch December 7, 2023 15:10
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.

3 participants