Skip to content

Add filename autocompletion to Open/Save dialog #185

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 19 commits into from
Jun 10, 2025

Conversation

haoruilee
Copy link
Contributor

@haoruilee haoruilee commented May 21, 2025

Implements filename autocompletion in the Open/Save file dialog (#28).

Features:

  • Shows suggestions as users type in the filename field
  • Tab to select top suggestion
  • Provides mouse click selection of suggestions
  • Limits to 5 suggestions maximum

image
image
image
image

Closes #28

@lhecker lhecker mentioned this pull request May 21, 2025
@lhecker
Copy link
Member

lhecker commented May 22, 2025

I tested this locally and this is really awesome!

I think we should move the floater to be below the editline. This is because there may not be a lot of space above the dialog.
We could also hook arrow up/down by calling consume_shortcut before the call to editline and deferring focus to the floater if it's currently open. This would then make it very comfortable switching focus into the floater.

What do you think? (Please feel free to disagree.)

@haoruilee
Copy link
Contributor Author

Looks better now:

  1. Move the floater below the editline
  2. Switch from editline to floater using ↑/↓, if at the top one then ↑ back to the editline
  3. Highlight in floater

059538195c8a0597a2cec64b386a85fd
6fca45eb069f9815ba92ff21c585d849
6bb84ca4a2891fd9df1efddf59c53860

@lhecker lhecker requested a review from DHowett June 5, 2025 15:23
Copy link
Member

@DHowett DHowett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I CANNOT WAIT to use this. Thank you!

@lhecker lhecker changed the title Add filename autocompletion to Open/Save dialog, fix #28 Add filename autocompletion to Open/Save dialog Jun 10, 2025
@lhecker lhecker merged commit 90bf080 into microsoft:main Jun 10, 2025
3 checks passed
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.

Open/Save dialog should support autocompletion for the filename
5 participants