Struct vega_lite::HeaderConfig

source ·
pub struct HeaderConfig {
Show 13 fields pub label_angle: Option<f64>, pub label_color: Option<String>, pub label_font: Option<String>, pub label_font_size: Option<f64>, pub label_limit: Option<f64>, pub title_anchor: Option<String>, pub title_angle: Option<f64>, pub title_baseline: Option<TextBaseline>, pub title_color: Option<String>, pub title_font: Option<String>, pub title_font_size: Option<f64>, pub title_font_weight: Option<FontWeight>, pub title_limit: Option<f64>,
}
Expand description

Header configuration, which determines default properties for all header. For a full list of header configuration options, please see the corresponding section of in the header documentation.

Fields§

§label_angle: Option<f64>

The rotation angle of the header labels.

Default value: 0.

§label_color: Option<String>

The color of the header label, can be in hex color code or regular color name.

§label_font: Option<String>

The font of the header label.

§label_font_size: Option<f64>

The font size of the header label, in pixels.

§label_limit: Option<f64>

The maximum length of the header label in pixels. The text value will be automatically truncated if the rendered size exceeds the limit.

Default value: 0, indicating no limit

§title_anchor: Option<String>

The anchor position for placing the title. One of "start", "middle", or "end". For example, with an orientation of top these anchor positions map to a left-, center-, or right-aligned title.

Default value: "middle" for single and layered views. "start" for other composite views.

Note: For now, anchor is only customizable only for single and layered views. For other composite views, anchor is always "start".

§title_angle: Option<f64>

The rotation angle of the header title.

Default value: 0.

§title_baseline: Option<TextBaseline>

Vertical text baseline for the header title. One of "top", "bottom", "middle".

Default value: "middle"

§title_color: Option<String>

Color of the header title, can be in hex color code or regular color name.

§title_font: Option<String>

Font of the header title. (e.g., "Helvetica Neue").

§title_font_size: Option<f64>

Font size of the header title.

§title_font_weight: Option<FontWeight>

Font weight of the header title. This can be either a string (e.g "bold", "normal") or a number (100, 200, 300, …, 900 where "normal" = 400 and "bold" = 700).

§title_limit: Option<f64>

The maximum length of the header title in pixels. The text value will be automatically truncated if the rendered size exceeds the limit.

Default value: 0, indicating no limit

Trait Implementations§

Formats the value using the given formatter. Read more
Deserialize this value from the given Serde deserializer. Read more
Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.