Skip to main content

make terminal ui's beautiful.

Project description

pygradientify

make terminal UI'S beautiful.

Installation

pip install pygradientify

pacman -S python-pygradientify

Usage / examples

from pygradientify import Colors

# ps: dir is horizontal by default.
"""
Normal
"""
print(Colors.red_to_blue("Hello World!", dir="h"))
print(Colors.mystic("Hello World!", dir="h"))

"""
ascii
"""
art = """
╔═╗╦ ╦╔═╗╦═╗╔═╗╔╦╗╦╔═╗╔╗╔╔╦╗╦╔═╗╦ ╦
╠═╝╚╦╝║ ╦╠╦╝╠═╣ ║║║║╣ ║║║ ║ ║╠╣ ╚╦╝
╩   ╩ ╚═╝╩╚═╩ ╩═╩╝╩╚═╝╝╚╝ ╩ ╩╚   ╩  
"""

print(Colors.blue_to_cyan(art, dir="h"))
print(Colors.purple_to_white(art, dir="h"))
print(Colors.orange_to_pink(art, dir="h"))
print(Colors.rainbow(art, dir="h"))  # 🌈 horizontal rainbow

"""
vertical will not work with rainbow it will fallback to horizontal
"""
print(Colors.rainbow(art, dir="v"))

"""
all gradients.
"""
for gradient_name in Colors.ls():
    grad = getattr(Colors, gradient_name)
    print(grad(f"{gradient_name}: The quick brown fox jumps over the lazy dog", dir="h"))

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

pygradientify-1.0.3.tar.gz (3.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pygradientify-1.0.3-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file pygradientify-1.0.3.tar.gz.

File metadata

  • Download URL: pygradientify-1.0.3.tar.gz
  • Upload date:
  • Size: 3.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for pygradientify-1.0.3.tar.gz
Algorithm Hash digest
SHA256 a702b105316ec678ece071b0108c2055d25c33f6a267f1dd1e9b927e6cff6b9b
MD5 c917af8c3808a3d44c3e09f93866b4c6
BLAKE2b-256 a55ea0fbd0eb47668e3aa5314852f46ef7a0cb440540390c63a576db229bb578

See more details on using hashes here.

File details

Details for the file pygradientify-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: pygradientify-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 3.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.11

File hashes

Hashes for pygradientify-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 5c64e4c8e323632e67f44b9c94f8614d29babf49a4dc09ec5393e0f8eb06b815
MD5 6b09c878287f28a7c66ca39e4a9718fe
BLAKE2b-256 e81696efe783a66087d03ed5fe3286f98995002f7f1b91c066ce9071232bfee5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page