Closed aymanbagabas closed 1 month ago
Yes, that is by design. kitty is not going to block the event loop for what is a fundamentally asynchronous operation. If you want to query for the state of clipboard support use the XTGETTCAP escape code, as described here: https://sw.kovidgoyal.net/kitty/kittens/query_terminal/ this is synchronous and reports the state of the clipboard_control setting and the terminal name among many other things.
Describe the bug I'm trying to write a program to read the terminal response to a clipboard read using OSC52
\x1b]52;c;?\x07
. In order to detect if the terminal supports the sequence, I'm writing DA1\x1b[c
after the query sequence to see which one the terminal replies to first. Since reading the clipboard prompts the user, the terminal should hold writing any responses until the user provides a response to the prompt. But that seems not to be the case, Kitty writes the DA1 response, waits for a clipboard prompt response, and then writes the OSC52 read response.To Reproduce Steps to reproduce the behavior:
cat | printf '\x1b]52;c;?\x07\x1b[c'
Environment details