[PATCH] Detect console width on Windows
Dirkjan Ochtman
dirkjan at ochtman.nl
Sun Apr 25 03:01:38 CDT 2010
On Sun, Apr 25, 2010 at 08:59, anatoly techtonik <techtonik at gmail.com> wrote:
> Hello. I've added support for detection of console width on Windows.
> It moves one piece of POSIX code, and this move is untested unlike
> Windows part. The patch uses pywin32, and is based on the ctypes code
> from http://bitbucket.org/techtonik/python-pager/src/tip/pager.py that
> I would like to propose for inclusion in Python stdlib one day as
> console module.
You should probably just move the current termwidth() to posix.py and
implement your new termwidth() in win32.py. Don't call it
get_console_width(), that doesn't mash well with our coding style (see
the CodingStyle page in the wiki).
Cheers,
Dirkjan
More information about the Mercurial-devel
mailing list