Skip to content
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

Allow arbitrary input while suggesting options #8

Open
hugoShaka opened this issue Apr 23, 2018 · 1 comment
Open

Allow arbitrary input while suggesting options #8

hugoShaka opened this issue Apr 23, 2018 · 1 comment

Comments

@hugoShaka
Copy link

The select() method returns -1 if the user input is not in options.
Currently it does not permit to recover the original input and does not allow to use rofi as a free text prompt while providing input suggestions (I may be wrong, if so please correct me 😁 ).

It may be useful to allow arbitrary user inputs while providing optional default values.
I thought of 2 ways of doing it :

  • The text_entry() method could support optional arg options (default=[] to ensure backward compatibility).
  • Creating a new method select_flex() returning index, key, user_input or user_input, key

I can submit a PR if you tell me what way suits you.

PS : thanks for the module, it made my day.

@Vresod
Copy link

Vresod commented Aug 25, 2020

If you're still active, could you tell me if/how you did this? my current project requires exactly this

Vresod added a commit to Vresod/firefox-rofi that referenced this issue Aug 25, 2020
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

No branches or pull requests

2 participants