[][src]Struct charts::HorizontalBarView

pub struct HorizontalBarView<'a> { /* fields omitted */ }

A View that represents data as horizontal bars.

Methods

impl<'a> HorizontalBarView<'a>[src]

pub fn new() -> Self[src]

Create a new empty instance of the view.

pub fn set_x_scale(self, scale: &'a impl Scale<f32>) -> Self[src]

Set the scale for the X dimension.

pub fn set_y_scale(self, scale: &'a impl Scale<String>) -> Self[src]

Set the scale for the Y dimension.

pub fn set_keys(self, keys: Vec<String>) -> Self[src]

Set the keys in case of a stacked bar chart.

pub fn set_label_position(self, label_position: BarLabelPosition) -> Self[src]

Set the positioning of the labels.

pub fn set_colors(self, colors: Vec<Color>) -> Self[src]

Set the color palette of the view.

pub fn set_label_visibility(self, label_visibility: bool) -> Self[src]

Set labels visibility.

pub fn set_custom_data_label(self, label: String) -> Self[src]

Set custom label for the dataset. This will work when the dataset represents only a single type of data (i.e. there are no different "keys" by which to differentiate data), otherwise, this will have no effect.

pub fn set_label_rounding_precision(self, nr_of_digits: usize) -> Self[src]

Set the precision to which value labels should be rounded.

pub fn load_data(self, data: &Vec<impl BarDatum>) -> Result<Self, String>[src]

Load and process a dataset of BarDatum points.

Auto Trait Implementations

impl<'a> !RefUnwindSafe for HorizontalBarView<'a>

impl<'a> !Send for HorizontalBarView<'a>

impl<'a> !Sync for HorizontalBarView<'a>

impl<'a> Unpin for HorizontalBarView<'a>

impl<'a> !UnwindSafe for HorizontalBarView<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.