ttyS3 dc36e21654 fix(tabs): mouse handling stuck after aborted tab drag on Wayland
A quick click-and-flick on a tab could leave all of kitty with mouse
input permanently redirected to the tab bar, making every window
unclickable and text selection impossible.

Starting a tab drag is asynchronous: the drag thumbnail is rendered on
the next frame before glfwStartDrag is called. If the button is
released in that window, wl_data_device_start_drag is sent with a stale
serial that no longer matches an active pointer implicit grab, so the
compositor silently ignores it. The wl_data_source then never receives
any event, on_drag_source_finished never runs, and the
tab_being_dragged state is stuck forever, hijacking all mouse events.

Fix in layers:
- glfw/Wayland: track the implicit grab (serial of the first button
  press and pressed-button count), use that serial for start_drag and
  refuse with EAGAIN when there is no active implicit grab instead of
  letting the compositor silently drop the request
- mouse.c: a left button release arriving while a tab drag is marked
  started but no system DND is active means the drag never launched
  (an active DND consumes the release on all platforms), so clear the
  drag state instead of waiting for DND events that will never come
- tabs.py: handle OSError from start_drag_with_data for tab drags the
  same way window drags already do; clear the potential-drag state when
  the release lands on the new-tab button or empty tab bar area
- tabs.py/boss.py: clear drag state on drag finish/drop even when the
  dragged tab has already been closed

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-06-10 03:43:25 +00:00
2026-06-09 06:23:34 +05:30
2026-06-09 06:23:34 +05:30

= kitty - the fast, feature-rich, cross-platform, GPU based terminal

If you live in the terminal, *kitty* is made for **you**!

See https://sw.kovidgoyal.net/kitty/[the kitty website].

image:https://github.com/kovidgoyal/kitty/workflows/CI/badge.svg["Build status", link="https://github.com/kovidgoyal/kitty/actions?query=workflow%3ACI"]

https://sw.kovidgoyal.net/kitty/faq/[Frequently Asked Questions]

To ask other questions about kitty usage, use either the https://github.com/kovidgoyal/kitty/discussions/[discussions on GitHub] or the
https://www.reddit.com/r/KittyTerminal[Reddit community]

Packaging status in various repositories:

image:https://repology.org/badge/vertical-allrepos/kitty-terminal.svg?columns=3&header=kitty["Packaging status", link="https://repology.org/project/kitty-terminal/versions"]
Description
No description provided
Readme GPL-3.0 160 MiB
Languages
Python 38.6%
C 28%
Go 26.3%
Objective-C 5.5%
Shell 1%
Other 0.5%