pub struct Chart {
pub id: u64,
pub name: String,
pub chart_type: ChartType,
pub data_range: String,
pub title: Option<String>,
pub xlabel: Option<String>,
pub ylabel: Option<String>,
pub show_legend: bool,
pub anchor_row: usize,
pub anchor_col: usize,
}Expand description
A chart over a range of cells.
Workbook-level rather than sheet-scoped: WorkbookManager::charts owns
these, and which worksheet a chart is drawn on comes from data_range’s
sheet prefix.
Fields§
§id: u64Workbook-unique identifier, stable across renames.
name: StringDisplay name.
chart_type: ChartTypeWhat shape to draw.
data_range: StringThe source cells, in A1 notation with a sheet prefix
("table_1!A1:B10"). The prefix also decides which worksheet the
chart is anchored to.
title: Option<String>Chart title, if it has one.
xlabel: Option<String>X-axis label, if it has one.
ylabel: Option<String>Y-axis label, if it has one.
show_legend: boolWhether to draw a legend.
anchor_row: usize0-based row/col of the cell the chart’s top-left corner is anchored
to on its worksheet (which worksheet that is comes from
data_range’s sheet/table prefix, same as today).
anchor_col: usizeColumn half of that anchor; see Chart::anchor_row.
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