Skip to main content

Make a MacOS Color palette from Python

Project description

Usage

import colorpalettegenerator as cg

# Create the palette, named "MyPythonPalette"
mypalette = cg.Palette("MyPythonPalette")

# Add a color using a key e.g. "White" and color described by (r, g, b, a)
mypalette.add_color((1,1,1,1), "White")
mypalette.add_color((1,0,0,1), "Red")
mypalette.add_color((0,1,0,1), "Green")
mypalette.add_color((0,0,1,1), "Blue")
mypalette.add_color((0,0,1,0.5), "Translucent blue")

# Save it to the default location. This will make it visible in the MacOS color palette.
mypalette.save()

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

colorpaletteconverter-0.1.tar.gz (3.0 kB view hashes)

Uploaded Source

Built Distribution

colorpaletteconverter-0.1-py3-none-any.whl (3.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page