microsoft / terminal

The new Windows Terminal and the original Windows console host, all in the same place!
MIT License
95.01k stars 8.22k forks source link

Use independent animations for panes (WAS: delay duplicate or split pane) #13105

Open hmz22 opened 2 years ago

hmz22 commented 2 years ago

Windows Terminal version

1.12.10983.0

Windows build number

10.0.22000.675

Other Software

No response

Steps to reproduce

When duplicate pane with hotkey delay to duplicate pan

https://user-images.githubusercontent.com/36853974/168461908-f9061372-3886-4993-9c70-c358696ad9af.mp4

e

in version 1.12.10732.0 haven't this problem.

Expected Behavior

No response

Actual Behavior

fix it

zadjii-msft commented 2 years ago

Hey so I can't really tell from the video where the delay is. Is there any way you could add some sort of overlay to the recording for when you actually press the keys?

FWIW, I can't really repro this locally. For me, there's no difference between opening a pane with a keybinding vs via the command palette. Is this something that you noticed on the latest upgrade (1.12), or was this happening on earlier versions as well/?

hmz22 commented 2 years ago

when use hotkey or command palette delay for create pane and I can't show in video u can tell me how record video in latest version have this problem. the older version haven't this problem

in this video add mouse effect and see after click on duplicate pane delay for run this command and duplicate pane

https://user-images.githubusercontent.com/36853974/168587466-88417856-8aa3-412f-a836-061ae91643db.mp4

Shyked commented 2 years ago

I think I am experiencing the same issue, there is a new delay that did not exist around a month ago. The delay is present when opening a pane using keyboard shortcuts or the command palette.

In this example, I am opening 3 panes to make my usual 2x2 layout (Split right, Split down, Select left, Split down). The changes used to be instant before. Now it takes around 3 to 6 seconds (in the video, it started at 0:07 when the cursor stopped blinking, the terminal freezes during this time, and the result appears at 0:11). The terminal becomes unresponsive during that time.

https://user-images.githubusercontent.com/11818711/172617611-28043e85-de09-4d1c-aa7c-3b99175116b0.mp4

I also experience the same behavior on another computer, with maybe half the delay due to better hardware.

My settings.json file ```json { "$help": "https://aka.ms/terminal-documentation", "$schema": "https://aka.ms/terminal-profiles-schema", "actions": [ { "command": { "action": "commandPalette" }, "keys": "ctrl+shift+p" }, { "command": { "action": "splitPane", "split": "right", "splitMode": "duplicate" }, "keys": "alt+shift+d" }, { "command": { "action": "copy", "singleLine": false }, "keys": "ctrl+c" }, { "command": "paste", "keys": "ctrl+v" }, { "command": "find", "keys": "ctrl+shift+f" }, { "command": { "action": "splitPane", "split": "down", "splitMode": "duplicate" }, "keys": "alt+shift+f" }, { "command": "closePane", "keys": "alt+shift+w" }, { "command": { "action": "closeTab" }, "keys": "ctrl+w" } ], "copyFormatting": "none", "copyOnSelect": false, "defaultProfile": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}", "profiles": { "defaults": {}, "list": [ { "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}", "hidden": false, "name": "Windows PowerShell" }, { "closeOnExit": "graceful", "colorScheme": "Campbell", "cursorColor": "#FFFFFF", "cursorShape": "bar", "font": { "face": "Consolas", "size": 10 }, "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}", "hidden": false, "historySize": 9001, "name": "Invite de commandes", "opacity": 80, "padding": "8, 8, 8, 8", "useAcrylic": false }, { "closeOnExit": "graceful", "colorScheme": "Campbell", "cursorColor": "#FFFFFF", "cursorShape": "bar", "font": { "face": "Consolas", "size": 10 }, "guid": "{2c4de342-38b7-51cf-b940-2309a097f518}", "hidden": false, "historySize": 25000, "name": "Ubuntu", "opacity": 80, "padding": "8, 8, 8, 8", "source": "Windows.Terminal.Wsl", "useAcrylic": false }, { "closeOnExit": "graceful", "colorScheme": "Campbell", "commandline": "REDACTED", "cursorColor": "#FFFFFF", "cursorShape": "bar", "font": { "face": "Consolas", "size": 10 }, "guid": "{a3a4f773-35fd-5592-87b5-88515c9c096d}", "hidden": false, "historySize": 9001, "name": "REDACTED", "opacity": 80, "padding": "8, 8, 8, 8", "useAcrylic": false }, { "closeOnExit": "graceful", "colorScheme": "Campbell", "commandline": "REDACTED", "cursorColor": "#FFFFFF", "cursorShape": "bar", "font": { "face": "Consolas", "size": 10 }, "guid": "{0069d0f5-b79f-5814-a371-451d7a1f3362}", "hidden": false, "historySize": 9001, "name": "REDACTED", "opacity": 80, "padding": "8, 8, 8, 8", "useAcrylic": false }, { "closeOnExit": "graceful", "colorScheme": "Campbell", "commandline": "REDACTED", "cursorColor": "#FFFFFF", "cursorShape": "bar", "font": { "face": "Consolas", "size": 10 }, "guid": "{d6244081-624b-5f96-a2d0-de6ecdf283b2}", "hidden": false, "historySize": 9001, "name": "REDACTED", "opacity": 80, "padding": "8, 8, 8, 8", "useAcrylic": false }, { "guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}", "hidden": false, "name": "Azure Cloud Shell", "source": "Windows.Terminal.Azure" }, { "guid": "{f6495219-c616-5738-b6c1-0221cafc5a6e}", "hidden": false, "name": "Developer Command Prompt for VS 2017", "source": "Windows.Terminal.VisualStudio" } ] }, "schemes": [ { "background": "#000000", "black": "#0C0C0C", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#3B78FF", "brightCyan": "#61D6D6", "brightGreen": "#16C60C", "brightPurple": "#B4009E", "brightRed": "#E74856", "brightWhite": "#F2F2F2", "brightYellow": "#F9F1A5", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#CCCCCC", "green": "#13A10E", "name": "Campbell", "purple": "#881798", "red": "#C50F1F", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#C19C00" }, { "background": "#012456", "black": "#0C0C0C", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#3B78FF", "brightCyan": "#61D6D6", "brightGreen": "#16C60C", "brightPurple": "#B4009E", "brightRed": "#E74856", "brightWhite": "#F2F2F2", "brightYellow": "#F9F1A5", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#CCCCCC", "green": "#13A10E", "name": "Campbell Powershell", "purple": "#881798", "red": "#C50F1F", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#C19C00" }, { "background": "#282C34", "black": "#282C34", "blue": "#61AFEF", "brightBlack": "#5A6374", "brightBlue": "#61AFEF", "brightCyan": "#56B6C2", "brightGreen": "#98C379", "brightPurple": "#C678DD", "brightRed": "#E06C75", "brightWhite": "#DCDFE4", "brightYellow": "#E5C07B", "cursorColor": "#FFFFFF", "cyan": "#56B6C2", "foreground": "#DCDFE4", "green": "#98C379", "name": "One Half Dark", "purple": "#C678DD", "red": "#E06C75", "selectionBackground": "#FFFFFF", "white": "#DCDFE4", "yellow": "#E5C07B" }, { "background": "#FAFAFA", "black": "#383A42", "blue": "#0184BC", "brightBlack": "#4F525D", "brightBlue": "#61AFEF", "brightCyan": "#56B5C1", "brightGreen": "#98C379", "brightPurple": "#C577DD", "brightRed": "#DF6C75", "brightWhite": "#FFFFFF", "brightYellow": "#E4C07A", "cursorColor": "#4F525D", "cyan": "#0997B3", "foreground": "#383A42", "green": "#50A14F", "name": "One Half Light", "purple": "#A626A4", "red": "#E45649", "selectionBackground": "#FFFFFF", "white": "#FAFAFA", "yellow": "#C18301" }, { "background": "#002B36", "black": "#002B36", "blue": "#268BD2", "brightBlack": "#073642", "brightBlue": "#839496", "brightCyan": "#93A1A1", "brightGreen": "#586E75", "brightPurple": "#6C71C4", "brightRed": "#CB4B16", "brightWhite": "#FDF6E3", "brightYellow": "#657B83", "cursorColor": "#FFFFFF", "cyan": "#2AA198", "foreground": "#839496", "green": "#859900", "name": "Solarized Dark", "purple": "#D33682", "red": "#DC322F", "selectionBackground": "#FFFFFF", "white": "#EEE8D5", "yellow": "#B58900" }, { "background": "#FDF6E3", "black": "#002B36", "blue": "#268BD2", "brightBlack": "#073642", "brightBlue": "#839496", "brightCyan": "#93A1A1", "brightGreen": "#586E75", "brightPurple": "#6C71C4", "brightRed": "#CB4B16", "brightWhite": "#FDF6E3", "brightYellow": "#657B83", "cursorColor": "#002B36", "cyan": "#2AA198", "foreground": "#657B83", "green": "#859900", "name": "Solarized Light", "purple": "#D33682", "red": "#DC322F", "selectionBackground": "#FFFFFF", "white": "#EEE8D5", "yellow": "#B58900" }, { "background": "#000000", "black": "#000000", "blue": "#3465A4", "brightBlack": "#555753", "brightBlue": "#729FCF", "brightCyan": "#34E2E2", "brightGreen": "#8AE234", "brightPurple": "#AD7FA8", "brightRed": "#EF2929", "brightWhite": "#EEEEEC", "brightYellow": "#FCE94F", "cursorColor": "#FFFFFF", "cyan": "#06989A", "foreground": "#D3D7CF", "green": "#4E9A06", "name": "Tango Dark", "purple": "#75507B", "red": "#CC0000", "selectionBackground": "#FFFFFF", "white": "#D3D7CF", "yellow": "#C4A000" }, { "background": "#FFFFFF", "black": "#000000", "blue": "#3465A4", "brightBlack": "#555753", "brightBlue": "#729FCF", "brightCyan": "#34E2E2", "brightGreen": "#8AE234", "brightPurple": "#AD7FA8", "brightRed": "#EF2929", "brightWhite": "#EEEEEC", "brightYellow": "#FCE94F", "cursorColor": "#000000", "cyan": "#06989A", "foreground": "#555753", "green": "#4E9A06", "name": "Tango Light", "purple": "#75507B", "red": "#CC0000", "selectionBackground": "#FFFFFF", "white": "#D3D7CF", "yellow": "#C4A000" }, { "background": "#000000", "black": "#000000", "blue": "#000080", "brightBlack": "#808080", "brightBlue": "#0000FF", "brightCyan": "#00FFFF", "brightGreen": "#00FF00", "brightPurple": "#FF00FF", "brightRed": "#FF0000", "brightWhite": "#FFFFFF", "brightYellow": "#FFFF00", "cursorColor": "#FFFFFF", "cyan": "#008080", "foreground": "#C0C0C0", "green": "#008000", "name": "Vintage", "purple": "#800080", "red": "#800000", "selectionBackground": "#FFFFFF", "white": "#C0C0C0", "yellow": "#808000" } ] } ```
lhecker commented 2 years ago

I've just compared 1.13.1143 against 1.11.3471 and there's indeed a drastic difference when splitting panes, especially on my less powerful hardware.

But even on my workstation the difference is immediately noticeable: When I create a pane in 1.11 it transitions in smoothly and closes just the same. In 1.13 however creating a new pane is very stuttery to a point where it appears as if there was no animation at all. Only closing a pane remains smooth.

zadjii-msft commented 2 years ago

~https://github.com/microsoft/terminal/compare/v1.13.10336.0...v1.11.3471.0 Maybe I'm choosing the wrong commits here. I'm not immediately seeing Pane, TerminalPage, or TermControl that hop out at me. https://github.com/microsoft/terminal/compare/v1.12.10982.0...v1.12.10732.0 doesn't have... anything?~

~Maybe, (this would be crazy), we don't PGO that path anymore, so it ends up being stuttery? I don't even know if there's a delta to support that hypothesis.~

I'm a dingus and had the compare backwards.

https://github.com/microsoft/terminal/compare/v1.12.10732.0...v1.12.10982.0

lhecker commented 1 year ago

An improved animation would be preferable, but in the meantime we can just default pane animations to disabled to band-aid it.