A Python library for generating ASCII art from text
Project description
asciigenator
A lightweight Python library for generating ASCII art from text.
Table of Contents
Installation
-
Clone the repository:
git clone https://github.com/bhatishan2003/asciigenator.git cd asciigenator
-
Install the package:
pip install .
-
For development (editable mode):
pip install -e .
Usage
Basic Python Usage
import asciigenator
# Test simple font
print("=== Simple Font ===")
print(asciigenator.generate("Hello", font="simple"))
# === Simple Font ===
# * ** ** *** *** ** *** * *
# * * * * * * * * ** *
# *** * * * * * * ** * * *
# * * * * * * * * * * **
# * * ** ** *** *** ** *** * *
print("\n=== Block Font ===")
print(asciigenator.generate("Ishan", font="block"))
# === Block Font ===
# █
# █ █ ████ ████ █████ █████ ████ █████ █ █
# █ █ █ █ █ █ █ █ ██ █
# █████ ███ █ █ █ █ ██ ████ █ █ █
# █ █ █ █ █ █ █ █ █ █ ██
# █ █ ████ ████ █████ █████ ████ █████ █ █
print("\n=== Available Fonts ===")
print(asciigenator.list_fonts())
# === Available Fonts ===
# ['block', 'simple']
Command Line Usage
asciigenator "Hello World"
asciigenator "Hello World" --font block
asciigenator --list-fonts
asciigenator "Hello World" --font block --border "#"
asciigenator "Hello World" --font block --color magenta
Testing
Run all tests:
pytest -v
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
asciigenator-0.0.6.tar.gz
(8.6 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file asciigenator-0.0.6.tar.gz.
File metadata
- Download URL: asciigenator-0.0.6.tar.gz
- Upload date:
- Size: 8.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cfd1ec86fc3c0b5d484b30ab6af68f24b0c6be64b45921046a54872db2aa3b6d
|
|
| MD5 |
8f02e847ec74a58cc104303ac848c53c
|
|
| BLAKE2b-256 |
610580d6fd4505f07f39edb096ee750de6f39c21fdd0924af8cca58eb73507ea
|
File details
Details for the file asciigenator-0.0.6-py3-none-any.whl.
File metadata
- Download URL: asciigenator-0.0.6-py3-none-any.whl
- Upload date:
- Size: 6.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ea1eb8c504234cde1cd40220a68a66a71b2765e35c9eaeee8c7f941411b95b64
|
|
| MD5 |
c1100b5472c34da52fd7981b31622f60
|
|
| BLAKE2b-256 |
1321f628f1e942e223197ab65f6e316d26dfaf024028ea49c9a01c3b8f3ab5cc
|