Skip to main content

img_gen_spec/
lib.rs

1//! Validation types and error handling for image generation specifications.
2//!
3//! This crate defines the public data model shared by the renderer and higher-level API.
4#![deny(
5    clippy::unwrap_used,
6    clippy::expect_used,
7    clippy::panic,
8    clippy::unimplemented,
9    clippy::todo,
10    missing_docs
11)]
12
13/// Public validation types used to describe layouts, layers, and styling.
14pub mod validators;
15pub use validators::{
16    Arc, Background, Border, ColorGradient, ColorKind, ConicalGradient, Corners, Debug, Ellipse,
17    Font, HEIGHT, Icon, IrregularPolygonSides, Layer, LayerOffset, Layout, Line, LineHeight,
18    LinearGradient, Mask, Polygon, PolygonSides, PreserveAspect, Presets, RadialGradient,
19    Rectangle, RegularPolygonSides, Size, SolidColor, Spread, TRANSPARENT, Typography,
20    TypographyAlign, WIDTH, Weight,
21};
22
23/// Error types returned while parsing or validating image generation specifications.
24pub mod error;
25pub use error::{ImgGenSpecError, Result};
26
27#[cfg(feature = "pyo3")]
28mod python_binding;