输出彩色文字
Project description
cprints
安装说明
使用pip
或其他 PyPi 软件包进行安装
pip install cprints
使用 cprints 输出彩色文本
您可以试试:
from cprints import cp
# 红色文字 文字样式: 下划线
cp.print_red("Hello World", style=cp.underline)
# 绿色文字 红色背景
cp.print_green("Hello World", bg="red")
# 黄色文字 黑色背景 文字样式: 下换线 and 高亮
cp.cprint(
"Hello World",
fg="yellow",
bg=cp.black,
style=["underline", "高亮"]
)
# color着色文字
# 黑色文字 白色背景 文字样式: 反显
text = cp.color("Hello World", fg=cp.black, bg=cp.white, style=cp.reverse)
print(text)
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
cprints-1.0.7.tar.gz
(5.6 kB
view details)
Built Distribution
File details
Details for the file cprints-1.0.7.tar.gz
.
File metadata
- Download URL: cprints-1.0.7.tar.gz
- Upload date:
- Size: 5.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 041cf4516cae9699ef687d20b372d3540b3e94c1ab38711338145abb204be570 |
|
MD5 | 37b903663f5b367582afa9e5b24e490e |
|
BLAKE2b-256 | d801317894bfba1b5482e0df55f42d7deb34b6273620193f8ab1feffe4e4ce93 |
File details
Details for the file cprints-1.0.7-py3-none-any.whl
.
File metadata
- Download URL: cprints-1.0.7-py3-none-any.whl
- Upload date:
- Size: 5.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bab3b4c5369bc6c22261c6ab496fc09b9748fd1d251c7e6aa6755e5baf52b365 |
|
MD5 | cc2638a0a7f210691a737ab7cc5bce68 |
|
BLAKE2b-256 | 03a1b05f9cb81ee2005461904f8e0c0d0fbba24aa01f46d6cd688384b447df38 |