Skip to content

Add keyboard-searchable code picker for text coding - #1511

Draft
willowsipling wants to merge 1 commit into
ccbogel:masterfrom
willowsipling:feature/searchable-code-picker
Draft

Add keyboard-searchable code picker for text coding#1511
willowsipling wants to merge 1 commit into
ccbogel:masterfrom
willowsipling:feature/searchable-code-picker

Conversation

@willowsipling

Copy link
Copy Markdown

Closes #1493

Status

Draft for discussion toward QualCoder 4.1.

This implementation began as a working prototype for the workflow discussed in #1493. This is a draft per suggestions for potential merging into the 4.1.

Feature

Adds a keyboard-first searchable code picker in Code Text:

  • In the Code Text editor view, user selects text, then presses F
  • A new dialogue box appears, with a search text field, which is in focus automatically
  • In the same dialogue box, underneath the search search text field, is a box in which all codes are displayed
  • The code box is filtered live as a user types in the search text field, searching for their intended code
  • Up/down arrows change the highlighted returned code, while typing focus remains in the search text field
  • Enter applies the highlighted code to the text, and also closes the dialogue box
  • Escape cancels the dialogue box

This was most-directly modeled on Zotero's citation picker, but, it's similar to most command palettes or the Spotlight search on MacOS.

Testing

Tested locally on macOS while running QualCoder from source:

  • Dialogue box activation
  • Selector opening only when text is selected
  • Does live filtering correctly
  • Arrow key navigation while maintaining search focus (aka, you don't have to re-select the search text box if you use the arrow keys to navigate through the list of returned codes)
  • Continued typing after navigation
  • Single assignment on enter, after which auto-closed the dialogue box
  • Cancellation with Esc
  • No action when no text is selected

Future Directions

  • Could play more nicely with Recent Codes? E.g, maintain the GUI (instead of dialogue box) of Recent Codes? Or, perhaps recently-used codes could be what's auto-populated when a user first presses F?
  • This is a skill issue on my part, but I don't understand the localization/translation functions, so this would need to be implemented. I am reading some Python books to learn more.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: to add a keyboard-first, searchable code picker for selected text.

1 participant