Skip to main content

VividHues: super lite package for colored strings in Python!

Project description

VividHues :rainbow: :package:

VividHues

CodeFactor Latest SemVer Repo Size Total Lines

VividHues: super lite package for colored strings in Python!


:hammer_and_wrench: Official Installation

Pop this command in your terminal to install VividHues.
pip install VividHues

:bricks: Dependency

requirements.txt (Highly Recommended!)

Append the following to your Python packages requirements.txt.
VividHues>=5.2.0
Changelog:
VividHues==3.0.0  # only has Clr codes
VividHues>=4.1.0  # adds: abbreviations & Magic Functions
VividHues>=5.2.0  # adds: Clr.pattern()

.github/Dependabot.yml (optional, but needs requirements.txt)

First, if you don't already have a .github directory: create one.
Then, add a Dependabot.yml file to it.
version: 2
updates:
  - package-ecosystem: "pip"
    directory: "/"
    schedule:
      interval: "daily"

Dockerfile :whale: (optional)

You can use this if you have a Docker container.
# recommended
COPY requirements.txt .
RUN pip install -r requirements.txt
# alternatively...
RUN pip install VividHues

:snake: Python Example

print(Clr.BO + Clr.UL + Clr.rainbow('I love VividHues!') + Clr.RS)
print(f"{Clr.RED}It's got my fave color!{Clr.RS}")
print(f"Soooo {Clr.jazzy('jazzy') + Clr.RS}")
#                          ^^^
# you'll get an error using "" in f-string interpolations
print(Clr.pattern("Kenny Oliver", Clr.PURPLE, Clr.CYAN, Clr.LIME) + Clr.RS)

:rainbow: Available Clr codes:

Just put a code in the gap Clr.___

Clr:                RED, ORANGE, YELLOW, LIME, GREEN, BLUE, CYAN, PURPLE, PINK, BLACK, WHITE
Formatter:    UNDERLINE, UL, BOLD, BO, RESET, RS

:magic_wand: Magic Functions

:game_die: Clr.random()

print(Clr.random(string))
Paints your string in a random Clr code.

:saxophone: Clr.jazzy()

print(Clr.jazzy(string))
Paints each letter in jazzy random colors! It's a total gamble, that's guaranteed to be ugly! :)

:rainbow: Clr.rainbow()

print(Clr.rainbow(string))
Paints your string in a rainbow pattern.

:test_tube: Clr.pattern()

print(Clr.pattern(string, *color))
Paint your letters in a repeating pattern, by specifying an unlimited amount of Clr codes!

:muscle: How VividHues stacks up...

Feature VividHues Colorama termcolor
Simplicity/Abstraction :star: :star: :star:
Font Colors :star: :star: :star:
Background/Highlight :crossed_fingers: :star: :star:
Bold/Underline :star: :star:
Lightweight :star:
Auto-Reset :crossed_fingers: :star:
Cursor-Positioning :star:
Special Features :star: :star:
Total 5/8 + 2/8 = 7/8 5/8 5/8

Potentially, VividHues will have more features than the competition if they are implemented.


Kenny Oliver ©2021

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

VividHues-5.2.8.tar.gz (15.9 kB view details)

Uploaded Source

Built Distribution

VividHues-5.2.8-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

Details for the file VividHues-5.2.8.tar.gz.

File metadata

  • Download URL: VividHues-5.2.8.tar.gz
  • Upload date:
  • Size: 15.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for VividHues-5.2.8.tar.gz
Algorithm Hash digest
SHA256 da53d2993711667bf1868081da6fdb5e207fe42bfd2bdccdb7ae9af5d1366c31
MD5 749dbf2a5c4a87323881de7bc6aa4d06
BLAKE2b-256 b6e9feb6cc204edb410f5eb44a01fd30050626ea3d7230cec2b0e9e5a4fc3f89

See more details on using hashes here.

File details

Details for the file VividHues-5.2.8-py3-none-any.whl.

File metadata

  • Download URL: VividHues-5.2.8-py3-none-any.whl
  • Upload date:
  • Size: 16.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for VividHues-5.2.8-py3-none-any.whl
Algorithm Hash digest
SHA256 13df62cb955c8032b0dc9d1b6d4f171d3a225deb287fa57d53190fc930297281
MD5 3b2b2d4b8bcdbc847a86b5885166c352
BLAKE2b-256 569845055aae1240392a4754ab2a647fb12c3436ccc0481667f11dc0a5e39311

See more details on using hashes here.

Supported by

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