dCharts Widget
jqPlot Charts Wrapper
jqPlot (www.jqplot.com) is a plotting and charting plugin for the jQuery Javascript framework and is dual licensed under the MIT and GPL version 2 licenses. jqPlot produces line, bar and pie charts with many features.
dCharts is Vaadin add-on for creating charts and is a wrapper for jqPlot library. For now dCharts support:
- Bar Charts,
- Block Charts,
- Bubble Charts,
- Donut Charts,
- Line Charts,
- Meter Gauge Charts,
- OHLC, HLC and Candlestick Charts,
- Pie Charts,
- Pyramid Charts,
- Waterfall Charts.
From version 0.7.0 dCharts now allow to handle events on charts data (see demos at http://vaadin.dussan.org/dchartsdemo#chartDataEvents). dCharts support following events:
- mouse enter,
- mouse leave,
- click,
- right click.
From version 1.0.0 onwards dCharts now requires Vaadin 7. The earlier versions most likely won't be maintained any more.
From version 1.1.0 onwards you can download and save chart as image. For now only support gif or png format.
Sample code
DataSeries dataSeries = new DataSeries() .add(2, 6, 7, 10); SeriesDefaults seriesDefaults = new SeriesDefaults() .setRenderer(SeriesRenderers.BAR); Axes axes = new Axes() .addAxis( new XYaxis() .setRenderer(AxisRenderers.CATEGORY) .setTicks( new Ticks() .add("a", "b", "c", "d"))) Highlighter highlighter = new Highlighter() .setShow(false); Options options = new Options() .setSeriesDefaults(seriesDefaults) .setAxes(axes) .setHighlighter(highlighter); DCharts chart = new DCharts() .setDataSeries(dataSeries) .setOptions(options) .show();
Links
Compatibility
Was this helpful? Need more help?
Leave a comment or a question below. You can also join
the chat on Discord or
ask questions on StackOverflow.
Version
Fixed bug #112: DCharts.replot does not use the clean argument. Fixed bug #113: Chart not showing because of Ticks. Fixed bug #114: Chart with enhanced legend show inactive element shadow.
Added enhanced legend to block, bubble, donut and pie charts (see new demos).
- Released
- 2013-06-30
- Maturity
- BETA
- License
- Apache License 2.0
Compatibility
- Framework
- Vaadin 7.0+
- Vaadin 6.8+ in 0.3.0
- Browser
- Browser Independent