Skip to main content

Crate iced_plot

Crate iced_plot 

Source
Expand description

A GPU-accelerated plotting widget for Iced.

  • Works with large datasets (up to millions of points)
  • Retains GPU buffers between frames for fast redraws and picking
  • Axes/labels, legends, reference lines, hover/pick highlighting, crosshairs, axis linking, etc.

Quick start:

use iced_plot::{Color, PlotWidgetBuilder, Series};

let series = Series::circles((0..100).map(|i| [i as f64, i as f64]).collect(), 2.0)
    .with_color(Color::from_rgb(0.2, 0.6, 1.0))
    .with_label("points");

PlotWidgetBuilder::new()
    .with_x_label("x")
    .with_y_label("y")
    .add_series(series)
    .build()
    .unwrap();

See examples/ for more.

Structs§

AxisLink
Represents a shared axis link that can synchronize camera positions across multiple plot widgets.
Color
A color in the sRGB color space.
Fill
A filled region between two existing shapes.
GridStyle
Configures the appearance of grid lines inside the plot area.
HLine
A horizontal line at a fixed y-coordinate.
HighlightPoint
The highlight context for a point. You can modify
LineStyle
Line styling options for series lines.
MarkerStyle
Marker styling options for series points.
PlotControls
Configures user interaction behavior for crate::PlotWidget.
PlotOverlay
An Iced element anchored to a plot position and overlaid on the plot.
PlotStyle
Configures the appearance of a PlotWidget.
PlotWidget
A plot widget that renders data series with interactive features.
PlotWidgetBuilder
Builder for configuring and constructing a PlotWidget.
Point
A point in data-space with a visual size.
PointId
Identifier for a point in a series.
PositionTransform
Separate x and y coordinate transforms for a two-dimensional point.
Series
A collection of per-point styled data to be plotted.
ShapeId
Unique identifier for a shape in the plot.
Tick
A position along an axis where a grid line and tick label is placed.
TooltipContext
Context passed to hover/pick highlight callbacks.
Transform
A one-dimensional coordinate transform for a series or reference line.
VLine
A vertical line at a fixed x-coordinate.

Enums§

AxisScale
Axis scaling mode.
ClickAction
Action that can be performed by a mouse click or double-click.
CoordinateSystem
The source coordinate system consumed by a Transform.
DragAction
Action that can be performed during a mouse drag.
DragEvent
Drag interaction event in data/world coordinates.
HoverPickEvent
The hover or pick event.
KeyAction
Action that can be performed by a key press.
LineType
Line styling options for series connections.
MarkerType
Marker types for series points.
PanDirection
Direction for keyboard-style panning.
PlotRenderStrategy
Ways in which the widget can be rendered.
PlotUiMessage
Messages sent by the plot widget to the application.
ScrollAction
Action that can be performed by scrolling.
Size
Shared size modes for markers and line widths.
TickWeight
The visual weight of a tick / grid line.

Functions§

default_formatter
A default formatter that displays values with reasonable precision.
default_style
Returns the default plot style derived from the current application theme.
default_tick_producer
A default tick producer that generates tick positions with appropriate spacing.
log_formatter
A simple formatter for logarithmic ticks with an arbitrary base.
log_tick_producer
A simple powers-only base-10 tick producer.

Type Aliases§

TickFormatter
A function which formats tick values into strings for display on the axis.
TickProducer
A function which generates tick positions along an axis. Takes a range (min, max) and returns a vector of ticks with their values and weights.