Skip to main content

Color handling made simple.

Project description

Chroma

Chroma is a Python module for handling colors with ease.

Quickstart

import chroma

# Create a Color object
color = chroma.Color('#00FF00')

# Get RGB, HLS, and HSV in either float or 0 - 255 (8bit)
# Also, HEX
color.rgb # (0.0, 1.0, 0.0)
color.hls # (0.3333333333333333, 0.5, 1.0)
color.rgb256 # (0, 255, 0)
color.hex = # '#00FF00'

# Set RGB, HLS, HSV (float or 256) and HEX
color.rgb256 = (255, 0, 0)
color.hls = (0.0, 1.0, 0.0)

Currently supports RGB, HLS, HSV and HEX (#RRGGBB) coordinates.

BSD licensed. Hosted on Github and available on PyPI.

Installation:

pip install tungsten

History

0.1.1 (2012-12-16)

  • HLS, HSV Support
  • API changes (setter methods)
  • Bug Fixes
  • Update to README

0.1.0 (2012-12-15)

  • Initial Release
  • RGB and Hex support

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for Chroma, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size Chroma-0.1.1.tar.gz (3.4 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page