When changing focus the cursor has significant delay before appearing. #5276

Closed
opened 2026-01-31 00:09:25 +00:00 by claunia · 2 comments
Owner

Originally created by @bradphelan on GitHub (Nov 28, 2019).

Environment

Platform ServicePack Version      VersionString
-------- ----------- -------      -------------
 Win32NT             10.0.18362.0 Microsoft Windows NT 10.0.18362.0

Windows Terminal (Preview)
Version: 0.7.3291.0

Steps to reproduce

Setup keybindings to change focus. For example

    , {"command": "moveFocusLeft", "keys": ["alt+h"]}
    , {"command": "moveFocusRight", "keys": ["alt+l"]}
    , {"command": "moveFocusUp", "keys": ["alt+k"]}
    , {"command": "moveFocusDown", "keys": ["alt+j"]}

Expected behavior

As soon as I change focus to another pane the cursor should immediately appear in the newly focused pane.

Actual behavior

There is a delay.

If I change focus quickly multiple times using the keybinding it is hard for the eye to track where to focus because the cursor does not ever appear until you stop pressing the focus change key.

There is also the pane border color change on focus but for some reason the color contrast there is difficult for me to track. I prefer to look for the cursor.

What I think is happening is that when you change focus to a new pane the cursor blink state machine starts again from zero and zero is the off state.

A fix might be to have the zero state of the cursor to be on rather than off.

With the mouse

The same problem happens when focusing the pane with the mouse. There is a delay.

Other Applications

I've noticed that the old power shell console and cmd.exe console seem to have the same probem.

gvim seems to get it right. Switching text editing panes quickly shows the cursor immediately.

Originally created by @bradphelan on GitHub (Nov 28, 2019). # Environment ``` Platform ServicePack Version VersionString -------- ----------- ------- ------------- Win32NT 10.0.18362.0 Microsoft Windows NT 10.0.18362.0 Windows Terminal (Preview) Version: 0.7.3291.0 ``` # Steps to reproduce Setup keybindings to change focus. For example ``` , {"command": "moveFocusLeft", "keys": ["alt+h"]} , {"command": "moveFocusRight", "keys": ["alt+l"]} , {"command": "moveFocusUp", "keys": ["alt+k"]} , {"command": "moveFocusDown", "keys": ["alt+j"]} ``` # Expected behavior As soon as I change focus to another pane the cursor should **immediately** appear in the newly focused pane. # Actual behavior There is a delay. If I change focus quickly multiple times using the keybinding it is hard for the eye to track where to focus because the cursor **does not** ever appear until you stop pressing the focus change key. There is also the pane border color change on focus but for some reason the color contrast there is difficult for me to track. I prefer to look for the cursor. What I think is happening is that when you change focus to a new pane the cursor blink state machine starts again from zero and zero is the off state. A fix might be to have the zero state of the cursor to be on rather than off. # With the mouse The same problem happens when focusing the pane with the mouse. There is a delay. # Other Applications I've noticed that the old power shell console and cmd.exe console seem to have the same probem. gvim seems to get it right. Switching text editing panes quickly shows the cursor immediately.
Author
Owner

@DHowett-MSFT commented on GitHub (Nov 30, 2019):

Good catch. Thanks!

@DHowett-MSFT commented on GitHub (Nov 30, 2019): Good catch. Thanks!
Author
Owner

@ghost commented on GitHub (Jan 14, 2020):

:tada:This issue was addressed in #4032, which has now been successfully released as Windows Terminal Preview v0.8.10091.0.🎉

Handy links:

@ghost commented on GitHub (Jan 14, 2020): :tada:This issue was addressed in #4032, which has now been successfully released as `Windows Terminal Preview v0.8.10091.0`.:tada: Handy links: * [Release Notes](https://github.com/microsoft/terminal/releases/tag/v0.8.10091.0) * [Store Download](https://www.microsoft.com/store/apps/9n0dx20hk701?cid=storebadge&ocid=badge)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#5276