Skip to main content

Color-Fi is a tool to color and format strings in python.

Project description

Color-Fi

Color-Fi is a tool to color and format strings in python to enhance user experience and to highlight important information so it does not go unnoticed.

Installation

Color-Fi is a python package which can be found on Python Package Index (PyPi). Run the following command to install:

pip install Color-Fi

Import Color-Fi into your projects

from ColorFi.color_fi import ColorFi

Usage

Display key options:

color_fi = ColorFi()

# Display key options:
color_fi.display_key_options()

Output:

Ground Options: foreground, background
Color Options: black, red, green, yellow, blue, magenta, cyan, white, bright-black, bright-red, bright-green, bright-yellow, bright-blue, bright-magenta, bright-cyan, bright-white
Formatting Options: reset, default, bold, dim, italic, underline, double-underline, slow-blink, rapid-blink, invert, hide, strike

Display all formatting options to help you choose what you want to use in your project:

# Display samples:
color_fi.display_all_formatting_options()

Output as a gif:
Formatting Samples

View selected formatting options on console

# print message to console with formatting options:
color_fi.print_message('Test Message', 'red', 'foreground', 'invert')

Output as png:
message Sample

Format message without printing directly to console

msg = color_fi.format_message('Test Message', 'red', 'foreground', 'invert')
print(msg)

Output as png:
message Sample

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

Color-Fi-1.0.1.tar.gz (15.4 kB view hashes)

Uploaded Source

Built Distribution

Color_Fi-1.0.1-py3-none-any.whl (15.7 kB view hashes)

Uploaded Python 3

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