color_tools.exporters.palette_metadata
Palette-level metadata.
PaletteMetadata stores descriptive information that applies to an entire palette rather than to individual colors.
The model intentionally contains only broadly useful metadata. Format-specific features such as swatch groups, ICC profiles, spot colors, and color-space information should be modeled separately when those capabilities are added.
- class color_tools.exporters.palette_metadata.PaletteMetadata(name='', author='', description='', columns=None, tags=(), properties=<factory>)[source]
Bases:
objectDescriptive metadata associated with a palette.
- Variables:
name – Human-readable palette name.
author – Palette creator or author.
description – Optional longer description of the palette.
columns –
Preferred display column count when supported by the target format. A value of None means no preference is specified.
A value of 0 may have format-specific meaning, such as allowing the consuming application to determine the layout.
tags – Searchable or descriptive palette tags.
properties – Additional application-specific metadata that does not yet warrant a dedicated field.
- Parameters:
Example
>>> metadata = PaletteMetadata( ... name="Warm Autumn", ... author="Dave", ... description="Muted warm colors for autumn artwork.", ... columns=5, ... tags=("warm", "autumn", "muted"), ... )