braille-bars


Namebraille-bars JSON
Version 0.2 PyPI version JSON
download
home_page
Summary
upload_time2023-07-07 02:01:42
maintainer
docs_urlNone
authorMorgan Heijdemann
requires_python
licenseMIT
keywords progress bar asci braille terminal cli braille bars
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Uses ansi terminal characters to print braille barcodes.
Simple library that uses the braille unicode characters to make 4 individual barcodes in one line of text.

Installation
No dependencies, just run the braille-test.py file.

Make sure you switch terminal emulation on to allow ansi characters.


Howto:
There are two classes, the Manager to keep track of the progress bars and the Bar class to create the individual bars.

```# Create progress bar manager
    manager = ProgressBarManager()

    # Keep track of time
    start_time = time.time()

    # progress bar unique index
    bar_index = 1

    # Update and display progress bars
    while len(manager.bars) > 0 or bar_index < 15:
        # Add a new progress bar set every 3 seconds
        if time.time() - start_time > 1.3 and bar_index < 15:
            manager.add_progress_bar(f"PDF {bar_index}")
            start_time = time.time()
            bar_index += 1

        # Update progress bars
        for title in list(manager.bars.keys()):
            for index in range(4):
                increment = random.random() * 0.03
                manager.update_progress_bar(title, index, increment)

        # Remove and reposition completed progress bar sets
        for title, bar in list(manager.bars.items()):
            if all(progress >= 1 for progress in bar.progresses):
                manager.reposition_progress_bars(title)

        # Sleep before next update
        time.sleep(0.05)```

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "braille-bars",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "progress bar,asci,braille,terminal,cli,braille bars",
    "author": "Morgan Heijdemann",
    "author_email": "targhan@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/f9/bc/0f950a416ce1d9fa3915abd357177e16214df1755c0636c66570bf9c9eaa/braille-bars-0.2.tar.gz",
    "platform": null,
    "description": "Uses ansi terminal characters to print braille barcodes.\nSimple library that uses the braille unicode characters to make 4 individual barcodes in one line of text.\n\nInstallation\nNo dependencies, just run the braille-test.py file.\n\nMake sure you switch terminal emulation on to allow ansi characters.\n\n\nHowto:\nThere are two classes, the Manager to keep track of the progress bars and the Bar class to create the individual bars.\n\n```# Create progress bar manager\n    manager = ProgressBarManager()\n\n    # Keep track of time\n    start_time = time.time()\n\n    # progress bar unique index\n    bar_index = 1\n\n    # Update and display progress bars\n    while len(manager.bars) > 0 or bar_index < 15:\n        # Add a new progress bar set every 3 seconds\n        if time.time() - start_time > 1.3 and bar_index < 15:\n            manager.add_progress_bar(f\"PDF {bar_index}\")\n            start_time = time.time()\n            bar_index += 1\n\n        # Update progress bars\n        for title in list(manager.bars.keys()):\n            for index in range(4):\n                increment = random.random() * 0.03\n                manager.update_progress_bar(title, index, increment)\n\n        # Remove and reposition completed progress bar sets\n        for title, bar in list(manager.bars.items()):\n            if all(progress >= 1 for progress in bar.progresses):\n                manager.reposition_progress_bars(title)\n\n        # Sleep before next update\n        time.sleep(0.05)```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "",
    "version": "0.2",
    "project_urls": null,
    "split_keywords": [
        "progress bar",
        "asci",
        "braille",
        "terminal",
        "cli",
        "braille bars"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f9bc0f950a416ce1d9fa3915abd357177e16214df1755c0636c66570bf9c9eaa",
                "md5": "a71437e3d0f4ec8b0c46a2a6ac7076b9",
                "sha256": "2443c272ea5ccc3677f7f3002fbb13355eb58f47daec56b2a094fabdb2696763"
            },
            "downloads": -1,
            "filename": "braille-bars-0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "a71437e3d0f4ec8b0c46a2a6ac7076b9",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 2465,
            "upload_time": "2023-07-07T02:01:42",
            "upload_time_iso_8601": "2023-07-07T02:01:42.007546Z",
            "url": "https://files.pythonhosted.org/packages/f9/bc/0f950a416ce1d9fa3915abd357177e16214df1755c0636c66570bf9c9eaa/braille-bars-0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-07-07 02:01:42",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "braille-bars"
}
        
Elapsed time: 0.57533s