简体   繁体   中英

autocompletion without dialog

Does the prompt-toolkit module supports autocompletion without displaying a dialog box (using tab to autocomplete)? I find the dialog box a bit bulky and overkill when there are a fairly large number of options to autocomplete with.

A-la bash-shell or comparable, using either prompt() or session.prompt()?

在此处输入图片说明

Thank you for looking.

from prompt_toolkit.shortcuts import CompleteStyle
[...]
session = PromptSession(lexer=PygmentsLexer(...), completer=commands, complete_while_typing=True, complete_style=CompleteStyle.READLINE_LIKE)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM