You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of the "Display all <n> possibilities (y/n)" prompt, make MenuComplete use in-place paging to show completions that exceed the -CompletionQuery threshold
#2306
Open
mklement0 opened this issue
Mar 15, 2021
· 0 comments
When a given tab completion invoked via the MenuComplete function yields more items than the threshold specified via Set-PSReadLineOption -CompletionQueryItems <n> (default is 100), the tab-completion UX changes fundamentally:
Instead of completions, a Display all <n> possibilities (y/n) prompt is shown, which is itself somewhat disruptive.
On opting in, the following UX benefits are lost, because a static list is printed before the command being edited is redisplayed:
Interactive, live filtering of completions as you type.
A real-life example of where this would be useful is to enable the -Encoding parameters to then offer all available encodings (consistent with the parameter type), without detriment to those users only interested in the PowerShell-defined ones - see #1844
Never show the Display all <n> possibilities (y/n) prompt.
Instead, provide in-place paging that preserves the UX benefits.
Loosely speaking, MenuComplete could act like the more or less utilities, only confined to the portion of the screen that fits -CompletionQueryItems values or as much as will fit on a single screen (with room for the "ToolTip" line).
PgUp / PgDown, which already work among the items shown on the one and only "page", could be used for paging (whereas Home and End act on the command line being edited).
The text was updated successfully, but these errors were encountered:
mklement0
changed the title
Instead of the "Display all <n> possibilities (y/n)" prompt, make MenuComplete use in-place paging to show completions that exceed -CompletionQuery threshold
Instead of the "Display all <n> possibilities (y/n)" prompt, make MenuComplete use in-place paging to show completions that exceed the -CompletionQuery threshold
Mar 15, 2021
Description of the new feature/enhancement
When a given tab completion invoked via the
MenuComplete
function yields more items than the threshold specified viaSet-PSReadLineOption -CompletionQueryItems <n>
(default is100
), the tab-completion UX changes fundamentally:Display all <n> possibilities (y/n)
prompt is shown, which is itself somewhat disruptive.A real-life example of where this would be useful is to enable the
-Encoding
parameters to then offer all available encodings (consistent with the parameter type), without detriment to those users only interested in the PowerShell-defined ones - see #1844Proposed technical implementation details (optional)
Display all <n> possibilities (y/n)
prompt.Loosely speaking,
MenuComplete
could act like themore
orless
utilities, only confined to the portion of the screen that fits-CompletionQueryItems
values or as much as will fit on a single screen (with room for the "ToolTip" line).PgUp / PgDown, which already work among the items shown on the one and only "page", could be used for paging (whereas Home and End act on the command line being edited).
The text was updated successfully, but these errors were encountered: