Print with Colors!
Project description
Printed Colors
Installation
To install, just simply run:
pip install printedcolors
Usage
The usage is simple. You can use it like this in normal prints:
import printedcolors
print(printedcolors.Color.fg.red + printedcolors.Color.bold + "I'm red and bold!" + printedcolors.Color.reset)
But if you want to keep it even more simple, You can do it like this:
import printedcolors
Color = printedcolors.Color
fg = Color.fg
print(fg.red + "Hi! I'm red!" + Color.reset)
Color.reset is recommended to not affect future prints.
Both Color and Colour can be used.
Supported Colours/Colors
FG (Foreground) Colors/Color:
| Color Name | Code Example |
|---|---|
| Black | Colour.fg.black |
| Red | Colour.fg.red |
| Green | Colour.fg.green |
| Yellow | Colour.fg.yellow |
| Blue | Colour.fg.blue |
| Magenta | Colour.fg.magenta |
| Cyan | Colour.fg.cyan |
| Light Grey | Colour.fg.lightgrey |
| Dark Grey | Colour.fg.darkgrey |
| Light Red | Colour.fg.lightred |
| Light Green | Colour.fg.lightgreen |
| Light Yellow | Colour.fg.lightyellow |
| Light Blue | Colour.fg.lightblue |
| Light Magenta | Colour.fg.lightmagenta |
| Light Cyan | Colour.fg.lightcyan |
BG (Background) Colours/Color:
| Color Name | Code Example |
|---|---|
| Black | Colour.bg.black |
| Red | Colour.bg.red |
| Green | Colour.bg.green |
| Yellow | Colour.bg.yellow |
| Blue | Colour.bg.blue |
| Magenta | Colour.bg.magenta |
| Cyan | Colour.bg.cyan |
| Light Grey | Colour.bg.lightgrey |
Misc (Other):
| Style Name | Code Example |
|---|---|
| Bold | Colour.bold |
| Dim | Colour.dim |
| Underline | Colour.underline |
| Reverse | Colour.reverse |
| Strikethrough | Colour.strikethrough |
| Invisible | Colour.invisible |
| Reset | Colour.reset |
As a reminder, both Colour and Color can be used. As both is defined in the library.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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 printedcolors-1.0.0.tar.gz.
File metadata
- Download URL: printedcolors-1.0.0.tar.gz
- Upload date:
- Size: 2.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
75b997ac412855368a2d9f1684d5b2c0fc3187b5f7cd8adc6e30d715802ab77d
|
|
| MD5 |
8f2a90d736d061061f3c26f2f9ee5d4d
|
|
| BLAKE2b-256 |
95e68cc6867df18ac760ea3c65ba88640662d2b822bce4db1313fcb554256143
|
File details
Details for the file printedcolors-1.0.0-py3-none-any.whl.
File metadata
- Download URL: printedcolors-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9801e8280effeae161917f9b5f31a96cc8215b5aaa87576c02ad8c4c55df095f
|
|
| MD5 |
3d23e397596e8b3a4a0b7a2e428ddfec
|
|
| BLAKE2b-256 |
9d98161a25c5837a2e8a14c7dd2ad971fa7cfdb9c5b9afd67df421cedf99e354
|