chartml_render/error.rs
1/// Errors that can occur during chart rendering.
2#[derive(Debug, thiserror::Error)]
3pub enum RenderError {
4 #[error("Chart rendering failed: {0}")]
5 Chart(#[from] chartml_core::ChartError),
6
7 #[cfg(feature = "rasterize")]
8 #[error("SVG parsing failed: {0}")]
9 SvgParse(String),
10
11 #[cfg(feature = "rasterize")]
12 #[error("PNG encoding failed: {0}")]
13 PngEncode(String),
14
15 #[cfg(feature = "rasterize")]
16 #[error("Rasterization failed: {0}")]
17 Rasterize(String),
18}