1[package] 2name = "plotters" 3version = "0.3.5" 4authors = ["Hao Hou <haohou302@gmail.com>"] 5edition = "2018" 6license = "MIT" 7description = "A Rust drawing library focus on data plotting for both WASM and native applications" 8repository = "https://github.com/plotters-rs/plotters" 9homepage = "https://plotters-rs.github.io/" 10keywords = ["WebAssembly", "Visualization", "Plotting", "Drawing"] 11categories = ["visualization", "wasm"] 12readme = "README.md" 13exclude = ["doc-template", "plotters-doc-data"] 14 15[dependencies] 16num-traits = "0.2.14" 17chrono = { version = "0.4.20", optional = true } 18 19[dependencies.plotters-backend] 20version = "0.3.5" 21path = "../plotters-backend" 22 23[dependencies.plotters-bitmap] 24version = "0.3.3" 25default_features = false 26optional = true 27path = "../plotters-bitmap" 28 29[dependencies.plotters-svg] 30version = "0.3.5" 31optional = true 32path = "../plotters-svg" 33 34[target.'cfg(not(all(target_arch = "wasm32", not(target_os = "wasi"))))'.dependencies] 35ttf-parser = { version = "0.17.0", optional = true } 36lazy_static = { version = "1.4.0", optional = true } 37pathfinder_geometry = { version = "0.5.1", optional = true } 38font-kit = { version = "0.11.0", optional = true } 39ab_glyph = { version = "0.2.12", optional = true } 40once_cell = { version = "1.8.0", optional = true } 41 42 43[target.'cfg(not(all(target_arch = "wasm32", not(target_os = "wasi"))))'.dependencies.image] 44version = "0.24.3" 45optional = true 46default-features = false 47features = ["jpeg", "png", "bmp"] 48 49[target.'cfg(all(target_arch = "wasm32", not(target_os = "wasi")))'.dependencies.wasm-bindgen] 50version = "0.2.62" 51 52[target.'cfg(all(target_arch = "wasm32", not(target_os = "wasi")))'.dependencies.web-sys] 53version = "0.3.51" 54features = [ 55 "Document", 56 "DomRect", 57 "Element", 58 "HtmlElement", 59 "Node", 60 "Window", 61 "HtmlCanvasElement", 62 "CanvasRenderingContext2d", 63] 64 65[features] 66default = [ 67 "bitmap_backend", "bitmap_encoder", "bitmap_gif", 68 "svg_backend", 69 "chrono", 70 "ttf", 71 "image", 72 "deprecated_items", "all_series", "all_elements", 73 "full_palette", 74 "colormaps" 75] 76all_series = ["area_series", "line_series", "point_series", "surface_series"] 77all_elements = ["errorbar", "candlestick", "boxplot", "histogram"] 78 79# Tier 1 Backends 80bitmap_backend = ["plotters-bitmap"] 81bitmap_encoder = ["plotters-bitmap/image_encoder"] 82bitmap_gif = ["plotters-bitmap/gif_backend"] 83svg_backend = ["plotters-svg"] 84 85# Colors 86full_palette = [] 87colormaps = [] 88 89# Elements 90errorbar = [] 91candlestick = [] 92boxplot = [] 93 94# Series 95histogram = [] 96area_series = [] 97line_series = [] 98point_series = [] 99surface_series = [] 100 101# Font implementation 102ttf = ["font-kit", "ttf-parser", "lazy_static", "pathfinder_geometry"] 103# dlopen fontconfig C library at runtime instead of linking at build time 104# Can be useful for cross compiling, especially considering fontconfig has lots of C dependencies 105fontconfig-dlopen = ["font-kit/source-fontconfig-dlopen"] 106 107ab_glyph = ["dep:ab_glyph", "once_cell"] 108 109# Misc 110datetime = ["chrono"] 111evcxr = ["svg_backend"] 112evcxr_bitmap = ["evcxr", "bitmap_backend", "plotters-svg/bitmap_encoder"] 113deprecated_items = [] # Keep some of the deprecated items for backward compatibility 114 115[dev-dependencies] 116itertools = "0.10.0" 117criterion = "0.4.0" 118rayon = "1.5.1" 119serde_json = "1.0.82" 120serde = "1.0.139" 121serde_derive = "1.0.140" 122 123[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies] 124rand = "0.8.3" 125rand_distr = "0.4.0" 126rand_xorshift = "0.3.0" 127 128[target.'cfg(all(target_arch = "wasm32", not(target_os = "wasi")))'.dev-dependencies] 129wasm-bindgen-test = "0.3.24" 130 131[[bench]] 132name = "benchmark" 133harness = false 134path = "benches/main.rs" 135