adobe-swatch-exchange

Crates.ioadobe-swatch-exchange
lib.rsadobe-swatch-exchange
version2.0.2
sourcesrc
created_at2023-10-03 16:33:05.344391
updated_at2024-08-07 11:03:31.906767
descriptionRead and write .ase files
homepagehttps://github.com/FineFindus/adobe-swatch-exchange-rs
repositoryhttps://github.com/FineFindus/adobe-swatch-exchange-rs
max_upload_size
id991224
size79,890
(FineFindus)

documentation

README

Adobe Swatch Exchange

A small, dependencies-free Rust library for writing and reading from .ase files.

ASE has the option to either store single colors or colors in a named group. Each color consists of a name, the actual color data (in RGB, CMYK, LAB or Gray format), and a color type, which indicates how the color behaves in the document.

Usage

use adobe_swatch_exchange::{ColorBlock, ColorType, ColorValue};

let color = ColorBlock::new(
        "#BF616A".to_owned(),
        ColorValue::Rgb(0.749_019_6, 0.380_392_16, 0.415_686_28),
        ColorType::Normal);

// write colors as ASE
let ase = adobe_swatch_exchange::create_ase(vec![], vec![color]);

// read colors from ASE
let (groups, colors) = adobe_swatch_exchange::read_ase(&*ase).unwrap();

License

This Project is licensed under MPL-2.0. It has no affiliation with Adobe Inc.

Commit count: 0

cargo fmt