color_tools.exporters.ase_exporter

Adobe Swatch Exchange (ASE) palette exporter.

This exporter writes color palettes in Adobe Swatch Exchange format using the optional swatch package.

ASE is a binary palette format commonly used by Adobe applications including Photoshop, Illustrator, and InDesign.

The swatch dependency is part of the image optional extra and is imported lazily so the exporter package remains usable when that extra is not installed.

Palette-aware export preserves the palette name by writing the colors inside an ASE Color Group.

class color_tools.exporters.ase_exporter.ASEExporter[source]

Bases: PaletteExporter

Export color palettes as Adobe Swatch Exchange (ASE) files.

Colors are written as RGB Process swatches. RGB channel values are normalized from 8-bit integer values (0-255) to the 0.0-1.0 range expected by the swatch package.

Color names are preserved when available.

When export_palette() is used with a palette name, all swatches are contained in a named ASE Color Group.

property metadata: ExporterMetadata

Return metadata describing the ASE exporter.