@@ -346,7 +346,7 @@ def set_option(
346346 self ,
347347 option : str ,
348348 value : t .Union [int , str ],
349- format : t .Optional [bool ] = None ,
349+ _format : t .Optional [bool ] = None ,
350350 unset : t .Optional [bool ] = None ,
351351 unset_panes : t .Optional [bool ] = None ,
352352 prevent_overwrite : t .Optional [bool ] = None ,
@@ -385,8 +385,8 @@ def set_option(
385385 assert isinstance (unset_panes , bool )
386386 flags .append ("-U" )
387387
388- if format is not None and format :
389- assert isinstance (format , bool )
388+ if _format is not None and _format :
389+ assert isinstance (_format , bool )
390390 flags .append ("-F" )
391391
392392 if prevent_overwrite is not None and prevent_overwrite :
@@ -419,11 +419,18 @@ def set_option(
419419 return self
420420
421421 def show_window_options (self , g : t .Optional [bool ] = False ) -> "WindowOptionDict" :
422- """Return dict of options for window.
422+ """Show options for tmux window. Deprecated by :meth:`Window.show_options()` .
423423
424- .. versionchanged:: 0.13.0
424+ .. deprecated:: 0.26
425+
426+ Deprecated by :meth:`Window.show_options()`.
427+
428+ """
429+ warnings .warn ("Window.show_window_options() is deprecated" , stacklevel = 2 )
430+ return self .show_options (g = g )
425431
426- ``option`` removed, use show_window_option to return an individual option.
432+ def show_options (self , g : t .Optional [bool ] = False ) -> "WindowOptionDict" :
433+ """Return a dict of options for the window.
427434
428435 Parameters
429436 ----------
@@ -462,6 +469,19 @@ def show_window_option(
462469 self ,
463470 option : str ,
464471 g : bool = False ,
472+ ) -> t .Optional [t .Union [str , int ]]:
473+ """Return option for target window. Deprecated by :meth:`Window.show_option()`.
474+
475+ .. deprecated:: 0.26
476+
477+ Deprecated by :meth:`Window.show_option()`.
478+
479+ """
480+ warnings .warn ("Window.show_window_option() is deprecated" , stacklevel = 2 )
481+ return self .show_option (option = option , g = g )
482+
483+ def show_option (
484+ self , option : str , g : bool = False
465485 ) -> t .Optional [t .Union [str , int ]]:
466486 """Return option value for the target window.
467487
0 commit comments