$ | >

Selecting text shouldn't pause program

Many people run into the unexpected behavior that accidentally selecting text on the console causes their program to pause when it tries to write to the output stream.

While text is selected, the console should continue to read from the output stream, and have some different way to provide stable text selection (freeze the scrollbar, or just render the text after the selection ended?).

Here's some other users who probably find the current behavior unintuitive:
https://superuser.com/questions/555160/windows-command-prompt-freezing-on-focus
https://superuser.com/questions/459609/what-does-it-do-exactly-if-i-click-in-the-window-of-cmd

26 votes
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    Signed in as (Sign out)

    We’ll send you updates on this idea

    Carl Walsh shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    4 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)
      Submitting...
      • Paul Dilley commented  ·   ·  Flag as inappropriate

        I'm supportive of this as well. This is especially troublesome since the new Windows Subsystem for Linux feature rolled out (supported through command prompt, it seems), and I managed to timeout a network operation because I had clicked off and back onto the window.

        Please set QuickEdit to off by default, or better yet modernize the command prompt, and in doing so make it so that selections can be made, copied (e.g. by Ctrl-Shift-C), and pasted (e.g. by Ctrl-Shift-V) without needing to halt execution of programs. There are many other good reasons to modernize the command prompt, but this isn't the place.

      • Chris Billington commented  ·   ·  Flag as inappropriate

        It's a really bad idea that this is on by default. I distribute applications that are expected to be responsive to requests on network sockets from the local computer, but they also output a log to stdout. If someone inadvertently clicks in the cmd window, these apps stop functioning, and other apps relying in it get timeouts communicating with it. It's way too easy to make this happen by accident, and you can make an application non-functional without noticing.

        QuickEdit was made default briefly in the past, and rolled back once the complaints started rolling in:

        https://blogs.msdn.microsoft.com/oldnewthing/20070913-00/?p=25143

        If you want to make it possible to select text whilst an application is running, then make the view stop scrolling whilst you click and drag. That's all that's neccesary - don't block the actual application.

        If users enable QuickEdit (which was always possible), then they open themselves up to this confusion. But enabling it by default will just lead to apps that disable it (this is what I will do for my apps now), or apps that roll their own terminals.

      • M Cook commented  ·   ·  Flag as inappropriate

        While I agree that it is inconvenient to find that this behavior has been inadvertently triggered (e.g. a click gone astray) I also appreciate being able to pause certain console scripts (mostly DOS) this way.

        So: make it configurable, so I can choose the legacy behavior when I want, or as a shortcut property.

        It'd be good to have a setting to make it more apparent, like having the taskbar icon blink slowly when the console is paused this way.

      Feedback and Knowledge Base