Library of color palettes for CICC WM slides, reports and tables.
Project description
CICC Colors
Library of color palettes for CICC WM slides, reports and tables. CICC调色板可以用于在使用Python生成图表或报告时,能够匹配CICC的颜色模板。
Install
pip install cicc_colors
How to Use
- 直接使用模板颜色,颜色使用 ppt_x_y 来标记, x, y 是CICC PPT模板中色版的位置。
from cicc_colors import colors
colors.ppt_1_1
>>> Color(203,170,123,255)
colors.ppt_1_1.hex()
>>> 'CBAA7B'
colors.ppt_1_1.rgb()
>>> (203,170,123)
colors.ppt_1_1.normal_rgb()
>>> (0.796078431372549, 0.6666666666666666, 0.4823529411764706)
- 自定义颜色,使用 r,g,b 来定义颜色后使用
from cicc_colors import colors
user_color = colors.Color(115,30,0)
>>> Color(115,30,0)
user_color.hex()
>>> '731E00'
user_color.hex(with_hash=True)
>>> '#731E00'
user_color.rgb()
>>> (115, 30, 0)
user_color.normal_rgb()
>>> (0.45098039215686275, 0.11764705882352941, 0.0)
- rgb 转 hex
from cicc_colors import colors
colors.RGB2Hex(203,170,123)
>>> 'CBAA7B'
colors.RGB2Hex(203,170,123, with_hash=True)
>>> '#CBAA7B'
- hex 转 rgb
from cicc_colors import colors
colors.Hex2RGB('#FF0FF0')
>>> (255, 15, 240)
How to Contribute
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
cicc_colors-0.3.1.tar.gz
(2.8 kB
view details)
Built Distribution
File details
Details for the file cicc_colors-0.3.1.tar.gz
.
File metadata
- Download URL: cicc_colors-0.3.1.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 20da38840c3d87f19e0b5330ade3f3dc46cef1689ca5ab656fb01593e658be6e |
|
MD5 | bd64d32db17d40dd3ad5adbca324ab3a |
|
BLAKE2b-256 | c47e92ab86c6f4f39070e7396709cf200bbace3a5baafe474708b029ea19e885 |
File details
Details for the file cicc_colors-0.3.1-py3-none-any.whl
.
File metadata
- Download URL: cicc_colors-0.3.1-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.3
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5fae88591eec3a9c8934525c05e01652bf535705e0aedab71443f8f986230c8a |
|
MD5 | 7c1949e6f577ed4e3876387f96fa60ba |
|
BLAKE2b-256 | 9619446385fb5c6b3ab37f87125602e5a80b2deca5404d97acd4ab629e16ed4a |