[issue13041] argparse: terminal width is not detected properly
Denilson Figueiredo de Sá
report at bugs.python.org
Sun Sep 25 16:18:43 CEST 2011
Denilson Figueiredo de Sá <denilsonsa at gmail.com> added the comment:
> #8408 was proposing a new module, which seems a bit overkill
If a module seems overkill, then maybe add this useful function to os module. Don't leave it private to argparse module. Maybe something along these lines:
>>> import os
>>> print(os.get_terminal_size())
(80, 25)
Why do I believe a module could be better? Because I'd also like some way to detect when the terminal size has changed (without probing it all the time).
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue13041>
_______________________________________
More information about the Python-bugs-list
mailing list