Skip to content

Unify search panel results-mode behavior: typing should re-enter input mode on both backends #334

Description

@JDonaghy

Summary

In the TUI, typing a printable character while in search results mode (navigating with j/k) automatically switches back to input mode and appends the character to the query. In GTK, the same keypress is ignored — the user must click the query field to re-enter input mode.

Expected behavior

Both backends should behave the same. The TUI behavior (typing re-enters input mode) matches VS Code's search panel UX and is more ergonomic.

What needs to change

  • Move the "printable char in results mode → re-enter input mode" logic into the engine (e.g. a new handle_search_results_key() method or extend handle_search_input_key())
  • GTK should call the same method so the behavior is unified
  • The char should be inserted via search_input_insert_char() (not .push()) to respect caret position

Context

Found during #311 (search panel cursor movement). The TUI path at tui_main/mod.rs:~2477 directly manipulates engine state. GTK has no equivalent path.

Priority

Low — UX polish for cross-backend consistency.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions