@@ -301,7 +301,6 @@ def __init__(
301301 auto_suggest : bool = True ,
302302 bottom_toolbar : bool = False ,
303303 command_sets : Iterable [CommandSet ] | None = None ,
304- complete_style : CompleteStyle = CompleteStyle .COLUMN ,
305304 include_ipy : bool = False ,
306305 include_py : bool = False ,
307306 intro : RenderableType = '' ,
@@ -343,10 +342,6 @@ def __init__(
343342 This allows CommandSets with custom constructor parameters to be
344343 loaded. This also allows the a set of CommandSets to be provided
345344 when `auto_load_commands` is set to False
346- :param complete_style: style of prompt-toolkit tab completion to use, 3 valid options are:
347- 1. CompleteStyle.COLUMN (default) - displays hints with help next to them in one big column
348- 2. CompleteStyle.MULTI_COLUMN - displays hints across multiple columns, with help when selected
349- 3. CompleteStyle.READLINE_LIKE - displays like readline, complete_in_thread doesn't work
350345 :param include_ipy: should the "ipy" command be included for an embedded IPython shell
351346 :param include_py: should the "py" command be included for an embedded Python shell
352347 :param intro: introduction to display at startup
@@ -480,7 +475,7 @@ def _(event: Any) -> None: # pragma: no cover
480475 auto_suggest = self .auto_suggest ,
481476 bottom_toolbar = self .get_bottom_toolbar if self .bottom_toolbar else None ,
482477 complete_in_thread = True ,
483- complete_style = complete_style ,
478+ complete_style = CompleteStyle . MULTI_COLUMN ,
484479 complete_while_typing = False ,
485480 completer = self .completer ,
486481 history = self .history_adapter ,
@@ -495,7 +490,7 @@ def _(event: Any) -> None: # pragma: no cover
495490 auto_suggest = self .auto_suggest ,
496491 bottom_toolbar = self .get_bottom_toolbar if self .bottom_toolbar else None ,
497492 complete_in_thread = True ,
498- complete_style = complete_style ,
493+ complete_style = CompleteStyle . MULTI_COLUMN ,
499494 complete_while_typing = False ,
500495 completer = self .completer ,
501496 history = self .history_adapter ,
@@ -2539,11 +2534,10 @@ def complete(
25392534 self .matches_sorted = True
25402535
25412536 # Swap between COLUMN and MULTI_COLUMN style based on the number of matches if not using READLINE_LIKE
2542- if self .session .complete_style != CompleteStyle .READLINE_LIKE :
2543- if len (self .completion_matches ) > self .max_column_completion_items :
2544- self .session .complete_style = CompleteStyle .MULTI_COLUMN
2545- else :
2546- self .session .complete_style = CompleteStyle .COLUMN
2537+ if len (self .completion_matches ) > self .max_column_completion_items :
2538+ self .session .complete_style = CompleteStyle .MULTI_COLUMN
2539+ else :
2540+ self .session .complete_style = CompleteStyle .COLUMN
25472541
25482542 try :
25492543 return self .completion_matches [state ]
0 commit comments