Blue and yellow colors for matplotlib.
Project description
B/Y Colors
A Python package for working with colors, providing an intuitive interface for color manipulation, transformation, and variant generation. Based palette is blue and yellow, which gives the name of the package.
Features
- Simple and intuitive color manipulation
- Support for RGB, RGBA, and HEX color formats
- Color brightness adjustment (relative and absolute)
- Opacity/transparency control
- Automatic dark and light variant generation
- Background color compositing for transparent colors
Installation
Install using pip:
pip install bycolors
Quick Start
from bycolors import colors as byc
# Basic color usage
blue = byc.blue
yellow = byc.yellow
# Color variants
dark_blue = blue.dark
light_yellow = yellow.light
# Custom brightness
custom_blue = blue.brightness(0.7) # 70% relative brightness
very_dark = blue.absolute_brightness(0.2) # 20% absolute brightness
# Transparency
semi_transparent = blue.opacity(0.5)
fully_transparent = blue.transparent
# Color format conversion
# here for illustration blue is a perfect blue (#0000FF)
rgb_values = blue.rgb # (0, 0, 1)
rgba_values = blue.rgba # (0, 0, 1, 1)
hex_value = blue.hex # "#0000FF"
# Custom background for transparent colors
blue_on_white = blue.opacity(0.5, background_color=(1, 1, 1)).rgb # (0.5, 0.5, 1)
Documentation
For detailed documentation, visit:
Contributing
Contributions are welcome! For any suggestions or issues:
- Open an issue to discuss the proposed changes
- Fork the repository
- Create a pull request
License
This project is licensed under the MIT License - see the LICENSE file for details.
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 bycolors-0.3.2.tar.gz.
File metadata
- Download URL: bycolors-0.3.2.tar.gz
- Upload date:
- Size: 7.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b9142118638ac90b84711f505e86eba008d3c0bad8967d6744085249cd412f8a
|
|
| MD5 |
1ed031bf6b1c7c610f096835cb325d62
|
|
| BLAKE2b-256 |
1824d73abd8b7d3e61674f85e3a912fd9791b6c638dc852543586135c038cde0
|
File details
Details for the file bycolors-0.3.2-py3-none-any.whl.
File metadata
- Download URL: bycolors-0.3.2-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.10.16
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0521aeaf141e74c473a1de392ad1e610793ce6aca18eb3d372c9dd0c2f8c386d
|
|
| MD5 |
ac0645dfffe396c2ec0116bbf22384a9
|
|
| BLAKE2b-256 |
b14be7aff62e71cfaaaf189ce32b96b4210554055189d217b85420a4d4d7fc39
|