plotters
A Rust drawing library focus on data plotting for both WASM and native applications
0.3.7
210M downloads/mo
#485 most downloaded on crates.io
plotters-rs/plotters
What this package is like to depend on
Last release 2 years ago
no release in 18 months
Release timing varies
gaps range from 3 weeks to 1.1 years
Most releases are documented
notes for 22 of 36 stable releases
3 versions withdrawn
withdrawn after publishing
7 years old
39 releases · first in 2019
0 releases in the last 12 months
see the full history below
Release timeline
39 releases · Apr 2019 to Sep 2024Releases
latest 39-
0.3.708 Sep 2024Nothing published for this version
-
0.3.620 May 2024Release notes
Open source →Added
- Add Clone and PartialEq traits to SeriesLabelPosition and ShapeStyle
- Add function to draw and save an evcxr figure
- Add dotted line style
Fixed
- Fix bug with infinite size for collinear line segments as coordinates
- Fix overflow in blit_bitmap
- Fix dashed line algorithm
-
0.3.516 Jun 2023Release notes
Open source →Added
- Add ab_glyph font backend
- Color maps
Fixed
- Fix broken unaligned read in unsafe code
- A lot of broken links and typos
-
0.3.408 Sep 2022Release notes
Open source →Fixed
- EvcxR feature compiling issue without bitmap backend enabled
Improved
- Color types manipulations
-
0.3.319 Aug 2022Release notes
Open source →Improved
- The EvcxR integration now supports bitmap output. (Thanks to @lisanhu)
Fixed
- Fix the plotters crate's edition requirement
-
0.3.205 Jul 2022 withdrawnRelease notes
Open source →Added
- Pie element (by @hhamana)
Improved
- Improved documentation for predefined colors. (Thanks to @siefkenj)
- Introduce the full Material Design 2014 Color Palette. (Thanks to @siefkenj)
- Massive documentation improvements (Thanks to @facorread and many others)
Fixed
- More float point axis key point algorithm fixes (@38)
- Default rasterizer fixes (@shinmili and @38)
-
0.3.121 May 2021Release notes
Open source →Improved
- Surface series now supports more customizations
- Z-orde support for 3D plots
- Allow passing colors by value and reference (thanks to chrisduerr)
Fixed
- Infinite loop / panic when the axis range is zero
- UB in minifb example (thanks to TheEdward162)
- Examples that uses old APIs (thanks to chrisduerr)
-
0.3.003 Sep 2020Release notes
Open source →This is the next major release of Plotters, see release notes for more details.
Added
- The plotters backend API crate is introduced which allows third-party backend.
- Allow slice used as a coordinate if the item type implements
PartialOrd. - Linspace coordinate type, which allows define a discrete coordinate on continuous value types (such as f32, DateTime, etc) with a step specification
- Nested coordinate type, now we support define pair of category and nested values as nested coordinate.
- Introduce backend crates: plotters-bitmap, plotters-svg, plotters-cairo, plotters-canvas, plotters-console
- 3D Plotting features
Fixed
- Adjust Canvas backend size with DPR (Thanks to Marius-Mueller)
Improvement
- Enhanced key point algorithms: New key point hint trait are used for key point algorithms && many improvement on key point algorithms for different types
- Renamed
MeshStyle::line\_style\_1andMeshStyle::line\_style\_2tobold\_line\_styleandlight\_line\_style - Reorganize the "plotters::coord" namespace
- Improved discrete coordinate trait
- Split backend code into isolated crates and can be maintained indepdendenly
- Category coordinate is now replaced by slice coordinate
- Removing the requirement for
Debugtrait for chart coordinate, allows ranged coordinate define its own formatting function.
Removed
- The
Pathname alias forPathElement - Most code
plotters::drawing::backend\_impl::\*(expectMockedBackendfor testing purpose) is removed due to crate split. - Piston backend due to the Piston project seems not actively developing
-
0.2.1526 May 2020Release notes
Open source →Fixed
- Division by zero with logarithmic coord (issue #143)
- Update dependencies
-
0.2.1405 May 2020 -
0.2.1304 May 2020 withdrawnRelease notes
Open source →Added
- Line width is supported for SVG
Fixed
- Updated dependencies
- Default rasterizer causing bitmap backend draw out-of-range pixels
- Depdendicy fix
-
0.2.1206 Dec 2019Release notes
Open source →Added
- BitMapBackend now is able to support different pixel format natively. Check our new minifb demo for details.
- Incremental Rendering by saving the previous chart context into a state and restore it on a different drawing area.
- BoxPlot support (See boxplot example for more details) (Thanks to @nuald)
- Category coordinate spec which allows use a list of given values as coordinate (Thanks to @nuald)
- New text positioning model which allows develvoper specify the anchor point. This is critical for layouting SVG correctly. See
plotters::style::text::text_anchorfor details. (Thanks to @nuald)
Improved
- Faster bitmap blending algorithm, which is 5x faster than the original one.
- Text alignment improvement, now we can suggest the invariant point by giving
TextAlignmentto the text style (Thanks to @nauld) - More controls on features, allows opt in and out series types
- Remove dependency to svg crate, since it doesn't provide more feature than a plain string.
-
0.2.1128 Oct 2019Release notes
Open source →Added
- Add font style support, now we are able to set font variations: normal, oblique, italic or bold.
Improved
- Font description is greatly improved, general font family is supported:
serif,serif-sans,monospace(Thanks to @Tatrix) - Tested the font loading on Linux, OSX and Windowns. Make font loading more reliable.
BitMapBackendisn't depends onimagecrate now. Only the image encoding part relies on theimagecrate- Refactored WASM demo use ES6 and
wasm-pack(Thanks to @Tatrix) - Label style for X axis and Y axis can be set separately now using
x\_label\_styleandy\_label\_style. (Thanks to @zhiburt)
-
0.2.1024 Oct 2019Release notes
Open source →Improved
- Refactored and simplified TTF font cache, use RwLock instead of mutex which may benefit for parallel rendering. (Thanks to @Tatrix)
Bug Fix
- The fast bitmap filling algorithm may overflow the framebuffer and cause segfault
-
0.2.921 Oct 2019 withdrawnRelease notes
Open source →Improvement
- Avoid copying image buffer when manipulate the image. (Thanks to @ralfbiedert)
- Bitmap element which allows blit the image to another drawing area.
- Performance improvement: now the bitmap backend is 8 times faster
- Added benchmarks to monitor the performance change
Bug Fix
- Performance fix: '?' operator is very slow
- Dynamic Element lifetime bound: Fix a bug that prevents area series draws on non-static lifetime backend
-
0.2.812 Oct 2019Release notes
Open source →Added
- Cairo backend, which supports using Plotters draw a GTK surface.
- Allow secondary axis to be configured with different label style.
- Relative Sizing, now font and size can use relative scale:
(10).percent\_height()means we want the size is 10% of parent's height. - Allow the axis overlapping with the plotting area with
ChartBuilder::set\_\label\_area\_overlap. - Allow label area is on the top of the drawing area by setting the label area size to negative (Thanks to @serzhiio).
- Allow configure the tick mark size, when the tick mark size is negative the axis becomes inward (Thanks to @serzhiio).
Bug Fix
FontErrorfrom rusttype isn'tSyncandSend. We don't have trait bound to ensure this. (Thanks to @dalance)
Improvement
- New convenient functions:
disable_meshanddisable_axes
-
0.2.701 Oct 2019Release notes
Open source →Added
- GIF Support, now bitmap backend is able to render gif animation
Bug Fix
- Fixed several polygon filling bugs.
- Completely DateTime coordinate system support
-
0.2.620 Sep 2019Release notes
Open source →Added
- Allowing axis be placed on top or right by setting
right_y_label_areaandtop_x_label_area - Dual-coord system chart support: Now we are able to attach a secondary coord system to the chart using
ChartContext::set_secondary_coord. Anddraw_secondary_axesto configure the style of secondary axes. Usedraw_secondary axisto draw series under the secondary coordinate system. - Add support for
y_label_offset. Previously only X axis label supports offset attribute. - New label area size API
set_label_area_sizecan be used for all 4 label area - Added new error bar element
- New axis specification type
PartialAxiswhich allows the partially rendered axis. For example, we can define the chart's axis range as0..1, but only0.3..0.7is rendered on axis. This can be done by(0.0..1.0).partial_axis(0.3..0.7) - Drawing backend now support fill polygon and introduce polygon element
- Area Chart Support
Improvement
- More examples are included
- Date coordinate now support using monthly or yearly axis. This is useful when plotting some data in monthly or yearly basis.
- Make margin on different side of a chart can be configured separately.
- Better test coverage
- Allowing axis be placed on top or right by setting
-
0.2.507 Sep 2019Release notes
Open source →Bug Fix
- Key points algorithm for numeric coordinate might not respect the constraint
-
0.2.405 Sep 2019Release notes
Open source →Improvement
- Add
i128andu128as coordinate type (Credit to @Geemili)
Bug Fix
- Date coordinate is working for a long time span now
- Add
-
0.2.319 Aug 2019Release notes
Open source →Improvement
- Color system now is based on
palettecrate (Credit to @Veykril)
- Color system now is based on
-
0.2.225 Jun 2019Release notes
Open source →Added
- More documentation: a Jupyter interactive notebook of Plotters tutorial
- Add more quadrants to the
SeriesLabelPosition(Credit to @wolfjagger).
Improvement
- Histogram improvements, horizontal bar is supported, new creation API which compiler can infer the type
- Supporting split the drawing area with a list of breakpoints using
DrawingArea::split_by_breakpoints - Enable SVG support for WASM
- Make the
BitMapBackendtakes an in memory mutable buffer
Fix
- Rectangle drawing bug when the axis is reversed
-
0.2.110 Jun 2019Release notes
Open source →Improvement
- Move the sample images and other documentation data out of this repository.
Fix
- Make drawing errors shareable across threads. Otherwise, it causes compile error in some cases. (Thanks to @rkarp)
-
0.2.008 Jun 2019Release notes
Open source →Added
- Add relative sizing by added function
DrawingArea::relative_to_heightandDrawingArea::relative_to_width. - Added piston backend, now we can render plot on a window and dynamically render the plot
Improved
- Creating drawing area with
&Rc<RefCell<DrawingBackend>>. Previously, the drawing area creation requires take over the drawing backend ownership. But sometimes the drawing backend may have additional options. With new API, this can be done by putting the backend drawing area into smart pointers, thus, the drawing backend is accessible after creates the root drawing area.
- Add relative sizing by added function
-
0.1.1407 Jun 2019Release notes
Open source →Added
- Font is now support rotation transformation. Use
FontDesc::transformto apply an rotation to transformation. For example,font.transform(FontTransform::Rotate90). - ChartContext now support drawing axis description. Use
MeshStyle::x_descandMeshStyle::y_descto specify the axis description text. - Add series label support.
ChartContext::draw_seriesnow returns a structSeriesAnnothat collects the additional information for series labeling.ChartContext::draw_series_labelsare used to actually draw the series label. (Seeexamples/chart.rsfor detailed examples) - Mocking drawing backend.
- evcxr Support
Improvement
- Unify
OwnedTextandTextintoText. Previously,OwnedTextandTextare two separate types, one holds aStringanother holds a&str. NowOwnedTextis removed. useText::new("text".to_string(),...)for owned text element andText::new("text", ...)for borrowed text. - Refactor the color representation code, since previously it's heavily relies on the trait object and hard to use
- More test cases
- Font is now support rotation transformation. Use
-
0.1.1301 Jun 2019Release notes
Open source →Added
- New abstraction of backend style with
BackendStyletrait which should be able to extend easier in the future - Backend support features, now feature options can be used to control which backend should be supported
- Add new trait
IntoDrawingArea, now we can usebackend.into_drawing_area()to convert the backend into a raw drawing area - Now elements support dynamic dispatch, use
element.into_dyn()to convert the element into a runtime dispatching element
Improvement
- Improved the overall code quality
- Documentation polish
- Stabilized APIs
- New conversion traits implementations
- Now transparent color is ignored by SVG, bitmap and HTML Canvas backend
Fix
- Changed the open-close pattern to a
presentfunction which indicates the end of drawing one frame - Fix the but that
ChartBuilder::titleandChartBuilder::margincannot be called at the same time &&build_rangednow returning a result.
- New abstraction of backend style with
-
0.1.1225 May 2019Nothing published for this version
-
0.1.1111 May 2019Nothing published for this version
-
0.1.1010 May 2019Nothing published for this version
-
0.1.904 May 2019Nothing published for this version
-
0.1.804 May 2019Nothing published for this version
-
0.1.703 May 2019Nothing published for this version
-
0.1.603 May 2019Nothing published for this version
-
0.1.503 May 2019Nothing published for this version
-
0.1.403 May 2019Nothing published for this version
-
0.1.326 Apr 2019Nothing published for this version
-
0.1.226 Apr 2019Nothing published for this version
-
0.1.126 Apr 2019Nothing published for this version
-
0.1.024 Apr 2019Nothing published for this version