tablerpy


Nametablerpy JSON
Version 0.1.0 PyPI version JSON
download
home_pageNone
SummaryTabler Icons library for Python
upload_time2025-01-25 09:53:12
maintainerNone
docs_urlNone
authorThibaud Gambier
requires_python>=3.8
licenseMIT License Copyright (c) 2025 Thibaud Gambier Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # tablerpy

[![PyPI - Version](https://img.shields.io/pypi/v/tablerpy?logo=pypi&label=PyPI&logoColor=white)](https://pypi.org/project/tablerpy/)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/tablerpy?logo=python&label=Python&logoColor=white)](https://pypi.org/project/tablerpy/)
[![License](https://img.shields.io/github/license/tahv/tablerpy?label=License)](https://github.com/tahv/tablerpy/blob/main/LICENSE)
[![CI - Tests](https://img.shields.io/github/actions/workflow/status/tahv/tablerpy/tests.yml?logo=github&logoColor=white&label=Tests)](https://github.com/tahv/tablerpy/actions/workflows/tests.yml)

[Tabler Icons](https://github.com/tabler/tabler-icons) library for Python.

> _Tabler Icons is a set of free MIT-licensed high-quality SVG icons.
> Each icon is designed on a 24x24 grid and a 2px stroke._
>
> _**[Browse at tabler.io/icons →](https://tabler.io/icons)**_

## Installation

```bash
pip install tablerpy
```

## Usage

The function `tablerpy.get_icon` accepts a `OutlineIcon | FilledIcon`
and return a `Traversable` (`pathlib.Path`) to the icon `.svg` file.

```python
from tablerpy import OutlineIcon, FilledIcon, get_icon

outline_icon_path = get_icon(OutlineIcon.BRAND_GITHUB)
filled_icon_path = get_icon(FilledIcon.BRAND_GITHUB)
```

Icon names match those on _tabler.io/icons_,
except they are uppercased and hyphens `-` are replaced with underscores `_`.
For example, [`brand-github`](https://tabler.io/icons/icon/brand-github)
becomes `BRAND_GITHUB`.

## Contributing

### Generating icons and enums

To keep up with Tabler Icons releases,
most of this package is generated using a script.

```console
$ python scripts/generator.py --help
usage: generator.py [-h] --version VERSION [--package PACKAGE]

Download Tabler Icons release from github.com/tabler/tabler-icons and generate Python files.

options:
  -h, --help         show this help message and exit
  --version VERSION  Tabler Icons release version
  --package PACKAGE  Target package directory
```

For instance, to generate files from Tabler Icons
[Release 3.29.0](https://github.com/tabler/tabler-icons/releases/tag/v3.29.0):

```bash
python scripts/generator.py --version 3.29.0
```

## Acknowledgements

- [pytablericons](https://github.com/niklashenning/pytablericons)
  for providing inspiration.
  The package include features for using icons with `Pillow`, `PyQt` or `PySide`.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "tablerpy",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": "Thibaud Gambier",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/88/fe/9b3aa8f1f4c5fb85b52f8237b3fb486944e60fcc8f9629989557d9174082/tablerpy-0.1.0.tar.gz",
    "platform": null,
    "description": "# tablerpy\n\n[![PyPI - Version](https://img.shields.io/pypi/v/tablerpy?logo=pypi&label=PyPI&logoColor=white)](https://pypi.org/project/tablerpy/)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/tablerpy?logo=python&label=Python&logoColor=white)](https://pypi.org/project/tablerpy/)\n[![License](https://img.shields.io/github/license/tahv/tablerpy?label=License)](https://github.com/tahv/tablerpy/blob/main/LICENSE)\n[![CI - Tests](https://img.shields.io/github/actions/workflow/status/tahv/tablerpy/tests.yml?logo=github&logoColor=white&label=Tests)](https://github.com/tahv/tablerpy/actions/workflows/tests.yml)\n\n[Tabler Icons](https://github.com/tabler/tabler-icons) library for Python.\n\n> _Tabler Icons is a set of free MIT-licensed high-quality SVG icons.\n> Each icon is designed on a 24x24 grid and a 2px stroke._\n>\n> _**[Browse at tabler.io/icons \u2192](https://tabler.io/icons)**_\n\n## Installation\n\n```bash\npip install tablerpy\n```\n\n## Usage\n\nThe function `tablerpy.get_icon` accepts a `OutlineIcon | FilledIcon`\nand return a `Traversable` (`pathlib.Path`) to the icon `.svg` file.\n\n```python\nfrom tablerpy import OutlineIcon, FilledIcon, get_icon\n\noutline_icon_path = get_icon(OutlineIcon.BRAND_GITHUB)\nfilled_icon_path = get_icon(FilledIcon.BRAND_GITHUB)\n```\n\nIcon names match those on _tabler.io/icons_,\nexcept they are uppercased and hyphens `-` are replaced with underscores `_`.\nFor example, [`brand-github`](https://tabler.io/icons/icon/brand-github)\nbecomes `BRAND_GITHUB`.\n\n## Contributing\n\n### Generating icons and enums\n\nTo keep up with Tabler Icons releases,\nmost of this package is generated using a script.\n\n```console\n$ python scripts/generator.py --help\nusage: generator.py [-h] --version VERSION [--package PACKAGE]\n\nDownload Tabler Icons release from github.com/tabler/tabler-icons and generate Python files.\n\noptions:\n  -h, --help         show this help message and exit\n  --version VERSION  Tabler Icons release version\n  --package PACKAGE  Target package directory\n```\n\nFor instance, to generate files from Tabler Icons\n[Release 3.29.0](https://github.com/tabler/tabler-icons/releases/tag/v3.29.0):\n\n```bash\npython scripts/generator.py --version 3.29.0\n```\n\n## Acknowledgements\n\n- [pytablericons](https://github.com/niklashenning/pytablericons)\n  for providing inspiration.\n  The package include features for using icons with `Pillow`, `PyQt` or `PySide`.\n",
    "bugtrack_url": null,
    "license": "MIT License\n        \n        Copyright (c) 2025 Thibaud Gambier\n        \n        Permission is hereby granted, free of charge, to any person obtaining a copy\n        of this software and associated documentation files (the \"Software\"), to deal\n        in the Software without restriction, including without limitation the rights\n        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n        copies of the Software, and to permit persons to whom the Software is\n        furnished to do so, subject to the following conditions:\n        \n        The above copyright notice and this permission notice shall be included in all\n        copies or substantial portions of the Software.\n        \n        THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\n        SOFTWARE.\n        ",
    "summary": "Tabler Icons library for Python",
    "version": "0.1.0",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "962c3d60d99b2b8ac95c8b3f4e27757330b0e5193e3b560a0cf1ed4b80521bcb",
                "md5": "4fce3ab10c1f83dbc9641ea27c0d244a",
                "sha256": "2a4cc1f818a3ca99ce3ce5a61e15fba94f944868ea963711c4197371dfc6407f"
            },
            "downloads": -1,
            "filename": "tablerpy-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "4fce3ab10c1f83dbc9641ea27c0d244a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 2937756,
            "upload_time": "2025-01-25T09:53:09",
            "upload_time_iso_8601": "2025-01-25T09:53:09.767327Z",
            "url": "https://files.pythonhosted.org/packages/96/2c/3d60d99b2b8ac95c8b3f4e27757330b0e5193e3b560a0cf1ed4b80521bcb/tablerpy-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "88fe9b3aa8f1f4c5fb85b52f8237b3fb486944e60fcc8f9629989557d9174082",
                "md5": "ab48b21edd7915d4679a0b1071ac8ccd",
                "sha256": "f8bb15c46692ad1db3674066fa56a77eeead1ce955ba220b780da316f969f9cd"
            },
            "downloads": -1,
            "filename": "tablerpy-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "ab48b21edd7915d4679a0b1071ac8ccd",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 622336,
            "upload_time": "2025-01-25T09:53:12",
            "upload_time_iso_8601": "2025-01-25T09:53:12.459706Z",
            "url": "https://files.pythonhosted.org/packages/88/fe/9b3aa8f1f4c5fb85b52f8237b3fb486944e60fcc8f9629989557d9174082/tablerpy-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-25 09:53:12",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "tablerpy"
}
        
Elapsed time: 0.73445s