130130 shlex_split ,
131131)
132132from .rich_utils import (
133- Cmd2Console ,
133+ Cmd2GeneralConsole ,
134134 RichPrintKwargs ,
135135)
136136from .styles import Cmd2Style
161161
162162# Set up readline
163163if rl_type == RlType .NONE : # pragma: no cover
164- Cmd2Console (sys .stderr ).print (rl_warning , style = Cmd2Style .WARNING )
164+ Cmd2GeneralConsole (sys .stderr ).print (rl_warning , style = Cmd2Style .WARNING )
165165else :
166166 from .rl_utils import (
167167 readline ,
@@ -1221,7 +1221,7 @@ def print_to(
12211221 terminal width; instead, any text that doesn't fit will run onto the following line(s),
12221222 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
12231223 If None (the default for this parameter), the output will default to no word-wrapping, as
1224- configured by the Cmd2Console .
1224+ configured by the Cmd2GeneralConsole .
12251225 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
12261226 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
12271227 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1230,7 +1230,7 @@ def print_to(
12301230 prepared_objects = ru .prepare_objects_for_rich_print (* objects )
12311231
12321232 try :
1233- Cmd2Console (file ).print (
1233+ Cmd2GeneralConsole (file ).print (
12341234 * prepared_objects ,
12351235 sep = sep ,
12361236 end = end ,
@@ -1245,7 +1245,7 @@ def print_to(
12451245 # warning message, then set the broken_pipe_warning attribute
12461246 # to the message you want printed.
12471247 if self .broken_pipe_warning and file != sys .stderr :
1248- Cmd2Console (sys .stderr ).print (self .broken_pipe_warning )
1248+ Cmd2GeneralConsole (sys .stderr ).print (self .broken_pipe_warning )
12491249
12501250 def poutput (
12511251 self ,
@@ -1267,7 +1267,7 @@ def poutput(
12671267 terminal width; instead, any text that doesn't fit will run onto the following line(s),
12681268 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
12691269 If None (the default for this parameter), the output will default to no word-wrapping, as
1270- configured by the Cmd2Console .
1270+ configured by the Cmd2GeneralConsole .
12711271 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
12721272 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
12731273 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1303,7 +1303,7 @@ def perror(
13031303 terminal width; instead, any text that doesn't fit will run onto the following line(s),
13041304 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
13051305 If None (the default for this parameter), the output will default to no word-wrapping, as
1306- configured by the Cmd2Console .
1306+ configured by the Cmd2GeneralConsole .
13071307 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
13081308 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
13091309 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1337,7 +1337,7 @@ def psuccess(
13371337 terminal width; instead, any text that doesn't fit will run onto the following line(s),
13381338 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
13391339 If None (the default for this parameter), the output will default to no word-wrapping, as
1340- configured by the Cmd2Console .
1340+ configured by the Cmd2GeneralConsole .
13411341 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
13421342 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
13431343 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1370,7 +1370,7 @@ def pwarning(
13701370 terminal width; instead, any text that doesn't fit will run onto the following line(s),
13711371 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
13721372 If None (the default for this parameter), the output will default to no word-wrapping, as
1373- configured by the Cmd2Console .
1373+ configured by the Cmd2GeneralConsole .
13741374 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
13751375 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
13761376 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1404,7 +1404,7 @@ def pexcept(
14041404 final_msg = Text ()
14051405
14061406 if self .debug and sys .exc_info () != (None , None , None ):
1407- console = Cmd2Console (sys .stderr )
1407+ console = Cmd2GeneralConsole (sys .stderr )
14081408 console .print_exception (word_wrap = True )
14091409 else :
14101410 final_msg += f"EXCEPTION of type '{ type (exception ).__name__ } ' occurred with message: { exception } "
@@ -1442,7 +1442,7 @@ def pfeedback(
14421442 terminal width; instead, any text that doesn't fit will run onto the following line(s),
14431443 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
14441444 If None (the default for this parameter), the output will default to no word-wrapping, as
1445- configured by the Cmd2Console .
1445+ configured by the Cmd2GeneralConsole .
14461446 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
14471447 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
14481448 method and still call `super()` without encountering unexpected keyword argument errors.
@@ -1498,7 +1498,7 @@ def ppaged(
14981498 terminal width; instead, any text that doesn't fit will run onto the following line(s),
14991499 similar to the built-in print() function. Set to False to enable automatic word-wrapping.
15001500 If None (the default for this parameter), the output will default to no word-wrapping, as
1501- configured by the Cmd2Console .
1501+ configured by the Cmd2GeneralConsole .
15021502 Note: If chop is True and a pager is used, soft_wrap is automatically set to True.
15031503 :param rich_print_kwargs: optional additional keyword arguments to pass to Rich's Console.print().
15041504 :param kwargs: Arbitrary keyword arguments. This allows subclasses to extend the signature of this
@@ -1525,7 +1525,7 @@ def ppaged(
15251525 soft_wrap = True
15261526
15271527 # Generate the bytes to send to the pager
1528- console = Cmd2Console (self .stdout )
1528+ console = Cmd2GeneralConsole (self .stdout )
15291529 with console .capture () as capture :
15301530 console .print (
15311531 * prepared_objects ,
0 commit comments