summaryrefslogtreecommitdiffstats
path: root/Doc/library/cmd.rst
diff options
context:
space:
mode:
authorNikita Sobolev <mail@sobolevn.me>2022-01-02 18:33:20 (GMT)
committerGitHub <noreply@github.com>2022-01-02 18:33:20 (GMT)
commitce4d25f3cd0a1c6e65b64015140fb5e1397c8ac5 (patch)
tree6d0fbabc63624ed9ac4b7dd6ff343805b1be7116 /Doc/library/cmd.rst
parent7a8796dc67d691e43eed69969e7706fefe0f16e9 (diff)
downloadcpython-ce4d25f3cd0a1c6e65b64015140fb5e1397c8ac5.zip
cpython-ce4d25f3cd0a1c6e65b64015140fb5e1397c8ac5.tar.gz
cpython-ce4d25f3cd0a1c6e65b64015140fb5e1397c8ac5.tar.bz2
bpo-46196: document method cmd.Cmd.columnize (#30303)
The method is already written and tested, now it's officially public.
Diffstat (limited to 'Doc/library/cmd.rst')
-rw-r--r--Doc/library/cmd.rst7
1 files changed, 7 insertions, 0 deletions
diff --git a/Doc/library/cmd.rst b/Doc/library/cmd.rst
index d57edb7..fd5df96 100644
--- a/Doc/library/cmd.rst
+++ b/Doc/library/cmd.rst
@@ -121,6 +121,13 @@ A :class:`Cmd` instance has the following methods:
:meth:`complete_\*` method is available. By default, it returns an empty list.
+.. method:: Cmd.columnize(list, displaywidth=80)
+
+ Method called to display a list of strings as a compact set of columns.
+ Each column is only as wide as necessary.
+ Columns are separated by two spaces for readability.
+
+
.. method:: Cmd.precmd(line)
Hook method executed just before the command line *line* is interpreted, but