curses-like library for cross-platform console app in python

前端 未结 5 1817
挽巷
挽巷 2020-12-08 11:05

I\'m looking into developing a console application in python which should be able to run under Windows as well as Linux. For this, I\'d really like to use a high-level conso

5条回答
  •  我在风中等你
    2020-12-08 11:21

    I recently hit this issue for a package I was putting together (https://github.com/peterbrittain/asciimatics). I wasn't very happy with the solutions that required you to install (or worse) build separate binary executables like PDCurses or cygwin, so I created a unified API that provides console colours, cursor positioning and keyboard & mouse input for Windows, OSX and UNIX platforms.

    This is now live and has been tested on CentOS 6/7 and Windows 7/8/10 and OSX 10.11. You can install it from PYPI using pip and then use the Screen class to control your console. As you can see from the project gallery, it should provide all your console needs, but if you need some extra features, please post an enhancement request on GitHub and I'll see what I can do.

提交回复
热议问题