MCPcopy Create free account
hub / github.com/donkeyteethUX/iced_plot / Size

Enum Size

src/series.rs:100–116  ·  view source on GitHub ↗

Shared size modes for markers and line widths.

Source from the content-addressed store, hash-verified

98#[derive(Debug, Clone, Copy, PartialEq)]
99/// Shared size modes for markers and line widths.
100pub enum Size {
101 /// Size in logical pixels.
102 ///
103 /// Markers are centered on the data position. Lines use this as a screen-space width.
104 ///
105 /// This is usually the right default.
106 Pixels(f32),
107
108 /// Size in world units.
109 ///
110 /// Markers are painted such that the lower-left corner is at the data position.
111 /// Lines use this as a width measured directly in plot units.
112 ///
113 /// This is useful for implementing heatmaps and similar applications where markers
114 /// need to paint an area of the plot.
115 World(f64),
116}
117
118impl From<f32> for Size {
119 fn from(size: f32) -> Self {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected