pub struct Chart {
pub kind: ChartKind,
pub title: Option<String>,
pub unit: Option<String>,
pub labels: Vec<String>,
pub series: Vec<Series>,
pub highlight: Option<usize>,
pub tone: Tone,
pub locale: Option<String>,
}Expand description
A chart to draw: labels along one axis and one to MAX_SERIES series of values.
Fields§
§kind: ChartKindHow to draw it.
title: Option<String>A title drawn in the image.
unit: Option<String>The unit of the values (kg, đồng, 円), written once under the title.
labels: Vec<String>The categories or points in order.
series: Vec<Series>The series.
highlight: Option<usize>The label drawn in the accent colour while the others are muted.
tone: ToneThe colour of a single series.
locale: Option<String>The language for numbers and the image’s description (vi, en, ja); guessed from the
labels when unset.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Chart
impl<'de> Deserialize<'de> for Chart
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Chart
Auto Trait Implementations§
impl Freeze for Chart
impl RefUnwindSafe for Chart
impl Send for Chart
impl Sync for Chart
impl Unpin for Chart
impl UnsafeUnpin for Chart
impl UnwindSafe for Chart
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more