You can use different foreground and background colors in terminal using ColorChalks module.
Project description
🖌️Module for terminal string styling
Installation
pip install ColorChalks
Usage
from ColorChalks import ColorChalks
# Print "Hello World!" in yellow color.
print(ColorChalks.FCOLORS.Yellow + "Hello World!")
# Print "Hello World!" with green background color.
# but first you have to reset
print(COLORS.Reset + BCOLORS.Green + "Hello World!")
## Print "Hello World!" with green background color with blue foreground color
print(COLORS.Reset + BCOLORS.Green + FCOLORS.Blue + "Hello World!")
Note: Version 1.0.3 comes with foreground colors (FCOLORS) and background colors (BCOLORS)
Colors
BlackRedGreenYellowBlueMagentaCyanWhiteBrightBlackBrightRedBrightGreenBrightYellowBrightBlueBrightMagentaBrightCyanBrightWhite
NOTE: Use the following command to reset to default color. Prefer to use this command before jumping from Bright colors to normal colors.
print(ColorChalks.COLORS.Reset)
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
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 ColorChalks-1.0.3.tar.gz.
File metadata
- Download URL: ColorChalks-1.0.3.tar.gz
- Upload date:
- Size: 3.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
96a58f97806497ccb2f5f90d7f22cefd783fa4bc299822f8e388d5f052808668
|
|
| MD5 |
88168e0b3173e39c51077bfc7af3af48
|
|
| BLAKE2b-256 |
a1cbbc51a5b83abf2f33318e7f96540d5e81311e2e769f7560a538d37f45956e
|
File details
Details for the file ColorChalks-1.0.3-py3-none-any.whl.
File metadata
- Download URL: ColorChalks-1.0.3-py3-none-any.whl
- Upload date:
- Size: 3.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
282ab71a086764bfbc74c412d948af74fb395731613b69e58be84bc454f021b4
|
|
| MD5 |
ba11e20440e57d9dc5a4c5d086b21b1a
|
|
| BLAKE2b-256 |
0bf8f4a028edfc4f7e43ed1d265b4d79c23b6a8cea4571b2749fa5cd27d1732a
|