pythoncoloring


Namepythoncoloring JSON
Version 1.2.4 PyPI version JSON
download
home_page
SummaryCustom colorama fork, compatible with discord webhook
upload_time2023-01-28 02:12:38
maintainer
docs_urlNone
authorartley
requires_python
license
keywords colors colorama python
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Makes ANSI escape character sequences (for producing colored terminal text and cursor positioning) work under MS Windows.

PyPI for releases |pythoncolors for enterprise on Tidelift

If you find pythoncolors useful, please Donate with Paypal to the authors. Thank you!
Installation

Tested on CPython 2.7, 3.7, 3.8, 3.9 and 3.10 and Pypy 2.7 and 3.8.

No requirements other than the standard library.

pip install pythoncolors
# or
conda install -c anaconda pythoncolors

Description

ANSI escape character sequences have long been used to produce colored terminal text and cursor positioning on Unix and Macs. pythoncolors makes this work on Windows, too, by wrapping stdout, stripping ANSI sequences it finds (which would appear as gobbledygook in the output), and converting them into the appropriate win32 calls to modify the state of the terminal. On other platforms, pythoncolors does nothing.

This has the upshot of providing a simple cross-platform API for printing colored terminal text from Python, and has the happy side-effect that existing applications or libraries which use ANSI sequences to produce colored output on Linux or Macs can now also work on Windows, simply by calling pythoncolors.just_fix_windows_console() (since v0.4.6) or pythoncolors.init() (all versions, but may have other side-effects – see below).

An alternative approach is to install ansi.sys on Windows machines, which provides the same behaviour for all applications running in terminals. pythoncolors is intended for situations where that isn’t easy (e.g., maybe your app doesn’t have an installer.)
            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "pythoncoloring",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "colors,colorama,python",
    "author": "artley",
    "author_email": "<python@support.com>",
    "download_url": "https://files.pythonhosted.org/packages/bc/11/1ae513e6884a0d0a3bf24c1f77c3ea187d5f116ceaa4971bbf6199dee965/pythoncoloring-1.2.4.tar.gz",
    "platform": null,
    "description": "Makes ANSI escape character sequences (for producing colored terminal text and cursor positioning) work under MS Windows.\n\nPyPI for releases |pythoncolors for enterprise on Tidelift\n\nIf you find pythoncolors useful, please Donate with Paypal to the authors. Thank you!\nInstallation\n\nTested on CPython 2.7, 3.7, 3.8, 3.9 and 3.10 and Pypy 2.7 and 3.8.\n\nNo requirements other than the standard library.\n\npip install pythoncolors\n# or\nconda install -c anaconda pythoncolors\n\nDescription\n\nANSI escape character sequences have long been used to produce colored terminal text and cursor positioning on Unix and Macs. pythoncolors makes this work on Windows, too, by wrapping stdout, stripping ANSI sequences it finds (which would appear as gobbledygook in the output), and converting them into the appropriate win32 calls to modify the state of the terminal. On other platforms, pythoncolors does nothing.\n\nThis has the upshot of providing a simple cross-platform API for printing colored terminal text from Python, and has the happy side-effect that existing applications or libraries which use ANSI sequences to produce colored output on Linux or Macs can now also work on Windows, simply by calling pythoncolors.just_fix_windows_console() (since v0.4.6) or pythoncolors.init() (all versions, but may have other side-effects \u2013 see below).\n\nAn alternative approach is to install ansi.sys on Windows machines, which provides the same behaviour for all applications running in terminals. pythoncolors is intended for situations where that isn\u2019t easy (e.g., maybe your app doesn\u2019t have an installer.)",
    "bugtrack_url": null,
    "license": "",
    "summary": "Custom colorama fork, compatible with discord webhook",
    "version": "1.2.4",
    "split_keywords": [
        "colors",
        "colorama",
        "python"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bc111ae513e6884a0d0a3bf24c1f77c3ea187d5f116ceaa4971bbf6199dee965",
                "md5": "50b779fe551020195c03fca9f002ded7",
                "sha256": "493c43df7d41d69d111a1346e19db884ea8bbfae1725b4c3952a7cf9c441c81a"
            },
            "downloads": -1,
            "filename": "pythoncoloring-1.2.4.tar.gz",
            "has_sig": false,
            "md5_digest": "50b779fe551020195c03fca9f002ded7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 13733,
            "upload_time": "2023-01-28T02:12:38",
            "upload_time_iso_8601": "2023-01-28T02:12:38.899882Z",
            "url": "https://files.pythonhosted.org/packages/bc/11/1ae513e6884a0d0a3bf24c1f77c3ea187d5f116ceaa4971bbf6199dee965/pythoncoloring-1.2.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-01-28 02:12:38",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "pythoncoloring"
}
        
Elapsed time: 0.57720s