Repository navigation
fix(search): Enables moving cursor position in input - #26
Open
adamcbrewer wants to merge 3 commits into
Open
adamcbrewer wants to merge 3 commits into
adamcbrewer wants to merge 3 commits into
Conversation
Uses a native text input so queries can be corrected in place while keeping launcher navigation and shortcuts. Fixes typecraft-dev#25
This was referenced Oct 22, 2026
) Keeps cursor editing alongside upstream command arguments, popups and clipboard paste (typecraft-dev#27). Pasted text respects the query cursor and selection. Refs typecraft-dev#25, typecraft-dev#27
cpreston321
added a commit
to cpreston321/oma-cast
that referenced
this pull request
Oct 26, 2026
…ueries The query is now a native TextInput, so typing moves out of handleKey. Resolution: keep the fork's guard against popping an empty quicklink form on Backspace, and cap the input at a script prompt's maxLength (setQuery refuses longer text, which the field would otherwise show). typecraft-dev#21 and typecraft-dev#26 both added tests/launcher-input.test.js. It is now typecraft-dev#26's, with the editor helpers its alias test routes through; typecraft-dev#21's numpad tests move to tests/launcher-keypad.test.js, where printable numpad keys in the query now pass through to the native input.
Keeps input composition reset alongside upstream search cancellation and updates paste tests for panels loaded on demand. Refs typecraft-dev#25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Left and Right don't move the query cursor because the launcher draws plain text and appends every character. Correcting the middle of a calculation means deleting everything after it.
Change
Uses a native Qt text input for root search, submenu searches and aliases. Arrow keys, Home/End, selection and deletion work at the cursor, and long queries scroll as it moves. Launcher shortcuts, result navigation, search history and action-panel input keep their existing behaviour.
The input also keeps upstream's argument pills and popups, with focus restored to the query when they close. Clipboard paste inserts at the cursor or replaces the selection.
For example, typing
12+34, pressing Left twice and inserting5now gives12+534.Fixes #25. Related to #23, which also changes launcher input.
Testing
OMA_CAST_QML_RUNNER=/usr/bin/qs node --test tests/*.test.js: 148 passed; one optional native search-helper integration test skipped because the binary wasn't built locally. Includes the native Qt suite with 9 editing cases.The installed desktop plugin points to another checkout and wasn't reloaded. Live fcitx5/ibus composition hasn't been checked.