Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kitty specific is_process_window_focused impl. #141

Merged

Conversation

jinliu
Copy link
Contributor

@jinliu jinliu commented Oct 23, 2023

This uses Kitty's remote control protocol to get the window state, so it works under Wayland.

The user can enable it by setting __done_kitty_remote_control=1 and enable allow_remote_control in kitty.conf.

Compared to the default implementation, it will send a notification when the window is focused, but the current tab is not. If this is desired, the user may want to enable this on Kitty+X11, too.

This uses Kitty's remote control, so it works under Wayland.
@franciscolourenco
Copy link
Owner

What happens when the Kitty window is not focused at all?

@jinliu
Copy link
Contributor Author

jinliu commented Oct 23, 2023

A notification will be sent, too. Sorry I didn't make that clear. It uses Kitty's tab.is_focused state, which is only true when the window is focused and the tab is active.

Copy link
Owner

@franciscolourenco franciscolourenco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At some point we should re-write the options list to make it more readable, but in the meanwhile I don't see why prevent this one from being included.

@franciscolourenco franciscolourenco merged commit e13bb0b into franciscolourenco:master Oct 23, 2023
@jinliu jinliu deleted the kitty-remote-control branch October 23, 2023 22:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants