You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Holding alt+backspace long press remove extra characters after release (should stop immediately) #3301
Issue: When a backspace is held down for a long press, the system correctly generates a rapid series of deletion events. However, upon releasing the key, the deletion process does not stop immediately and continues to remove characters. The longer the key is held, the more characters are erroneously deleted after release.
Observed: The root cause is that for every repeated key press event generated during the long press, the application queues a corresponding deletion action. When we release the key, the application is still working through this backlog of queued actions. It doesn't acknowledge the "key up" event until this queue is empty, leading to the observed "overshoot" in deletion. The low-level input system correctly reports KeyReleaseEvent and IsRepeat flags, but the higher-level application logic isn't using this information to halt the process.
Fix: The event handling logic must be changed to properly manage actions initiated by a long press.
Instead of blindly queueing an action for every single repeated KeyPressEvent, the application should initiate the deletion on the first press and then continuously process it. Once receiving the KeyReleaseEvent, it must immediately terminate the deletion loop and clear any pending deletion actions related to that key. This ensures the action stops precisely when the user releases the key, fixing the "overshoot" problem.
I've been testing this fix locally and I'm ready to push once approved, thank you!
OpenCode version
v0.15.8 - local built
Steps to reproduce
Write a long text in the input, then long press alt+backspace for 2-3 seconds and release it
Activity
rekram1-node commentedon Oct 20, 2025
yeah I think this will be fixed once opentui version of opencode ships this week
adolfousier commentedon Oct 20, 2025
I've fixed this, if need I can push a PR.
Screencast.From.2025-10-20.21-57-57.mp4
Thank you. Cheers
rekram1-node commentedon Oct 20, 2025
sure pr welcome
thdxr commentedon Mar 25, 2026
To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.