question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Integrated terminal: Inserting X selections requires precise mouse positioning

See original GitHub issue

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.70.0
  • OS Version: Debian 11.4, Gnome Shell 3.38.6, X11 7.7+22

I’ve noticed this being an issue for few months now.

Steps to Reproduce:

  1. Open the embedded terminal (<kbd>Ctrl+`</kbd>)
  2. Select a word (either in the terminal, in the editor window, or another window), to copy the selection into the primary X selection buffer. Do not hit <kbd>(Shift+)Ctrl+C</kbd>
  3. Ensure the selection is copied, by clicking with the middle mouse into an editor. This should paste the previous selection.
  4. Try the same in the terminal window:
    • if you click on an area free of text, the selection is inserted
    • if you click on an area with text in it, the selection does not appear (this is the bug)

https://user-images.githubusercontent.com/327411/183039470-9d834491-8748-453c-b2fb-a3585556374e.mp4

Workarounds:

  1. Use the clipboard. This is annoying, because for me, selecting text with the mouse, moving the mouse a few 100 pixel down and clicking the middle mouse button (or the scroll wheel in my case) is much faster than <kbd>Ctrl+C</kbd>, <kbd>Ctrl+`</kbd>, <kbd>Ctrl+Shift+V</kbd>.
  2. Click on an area without text. This is annoying, because I need to be precise with the mouse positioning. If the terminal is full of program output, I need to hit the last line (containing the prompt).

See also:

Issue Analytics

  • State:open
  • Created a year ago
  • Reactions:2
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
Tyriarcommented, Aug 19, 2022

Created the upstream issue for this: https://github.com/xtermjs/xterm.js/issues/4052

1reaction
dmkecommented, Aug 24, 2022

In code-insiders, using xterm.js v5.0.0-beta, this issue persist as well:

$ code-insiders --version
1.71.0-insider
7ed02a69658fc07f08740b98fa0d8d96c1a61ed4
x64

As mentioned in https://github.com/xtermjs/xterm.js/issues/4052#issuecomment-1226155474, xterm.js standalone is unaffected, at least in my testing.

Read more comments on GitHub >

github_iconTop Results From Across the Web

July 2018 (version 1.26) - Visual Studio Code
Terminal column selection - Alt+click to select blocks of text in the integrated terminal. Add all missing imports - Single action to add...
Read more >
kitty.conf - Kovid Goyal
kitty is highly customizable, everything from keyboard shortcuts, to rendering frames-per-second. See below for an overview of all customization ...
Read more >
Comments on CopyAndPaste - EmacsWiki
One of the drawbacks of integrating the GNU Emacs copy-and-paste mechanism with X is that Emacs will grab the clipboard or selection every...
Read more >
Linux xterm command help and examples - Computer Hope
xterm is the standard terminal emulator of the X Window System, ... xterm was quickly integrated into X, and today most X terminal...
Read more >
Documentation - iTerm2 - macOS Terminal Replacement
If you accidentally close a session, you get five seconds (by default; configurable in Preferences > Profiles > Session) to undo it by...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found