tawasuyu/llimphi
Sovereign retained-mode GPU UI framework in Rust (wgpu+vello+taffy+parley), Elm loop, 40+ widgets.
1// Copyright 2024 the Velato Authors
2// SPDX-License-Identifier: Apache-2.0 OR MIT
3
4use super::graphic_element::GraphicElementShape;
5use crate::schema::constants::shape_direction::ShapeDirection;
6use serde::{Deserialize, Serialize};
7
8/// Drawable shape
9#[derive(Deserialize, Serialize, Debug, Clone, PartialEq)]
10pub struct Shape {
11 #[serde(flatten)]
12 pub graphic_element: GraphicElementShape,
13
14 /// Direction the shape is drawn as, mostly relevant when using trim path
15 #[serde(rename = "d")]
16 #[serde(skip_serializing_if = "Option::is_none")]
17 pub direction: Option<ShapeDirection>,
18}