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

focus-follows-mouse should follow windows too #5423

Open
mitchellh opened this issue Jan 29, 2025 · 0 comments
Open

focus-follows-mouse should follow windows too #5423

mitchellh opened this issue Jan 29, 2025 · 0 comments
Labels
gui GUI or app issue regardless of platform (i.e. Swift, GTK)

Comments

@mitchellh
Copy link
Contributor

Discussed in #5383

Originally posted by edrozenberg January 26, 2025
Currently focus-follows-mouse only works for focusing different splits within a single window/tab.

ghostty.org/docs/config/reference#focus-follows-mouse

For some use-cases it would be nice to be able to set focus-follows-mouse to also work between Ghostty windows, for ex. a window on the left and a window on the right.

Maybe something like:
focus-follows-mouse = < splits | windows | all | false >

There are some Mac utilities that might enable window-based focus follow for all apps, but I'd want to enable it specifically for Ghostty.

For reference, Mac's Terminal.app currently provides window-based focus follow:
defaults write com.apple.Terminal FocusFollowsMouse -bool YES

My Q is specifically about Mac but may apply to Linux also. I'm aware Linux has long had the option to enable global focus follows mouse between windows. I don't know if it's possible to control this at the app level on Linux, not educated well enough on this topic on Linux OS's.

Mitchell's Notes

I like the proposal here, I think changing it to a packed struct would yield all of these options. I think true should by default turn them all on (which you'll get for free with a packed struct).

As noted in the discussion, I'm not sure if this is even possible with GTK but if not we should just document it as a limitation.

@mitchellh mitchellh added the gui GUI or app issue regardless of platform (i.e. Swift, GTK) label Jan 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gui GUI or app issue regardless of platform (i.e. Swift, GTK)
Projects
None yet
Development

No branches or pull requests

1 participant