Skip to content
Last updated

JChart

Release Notes

For more information about J/Chart, see the J/Chart Javadoc Reference.

May 2015

  • cgHistogramChartVisual and cgRoseHistogramVisual use an updated cgHistogramBinDisc which implements HdrHistogram, an external library designed for recoding histograms of value measurements in latency and performance sensitive applications.
  • Added support for cgBarChartVisual.BarType.PERCENTAGE in cgHistogramChartVisual.
  • Added support for cgBarChartVisual.BarType.BESIDE, STACKED, and PERCENTAGE to cgRoseHistogramVisual. The functions setMinimumTickDistance(int) and setTickPrecision(int) have been added to customize the adaptive tick placement.

3.4 Release

  • Polar chart improvements: added new base class cgPolarChartVisual that is extended by cgRoseDiagramVisual and cgRoseHistogramVisual. Allows improved API to the polar charts. cgPolarChartVisual objects do not support shadow or 3D effects.
  • Added cgRoseHistogramControlPanel.
  • Improved javadocs in the polar charts.
  • Removed the deprecated cgChartVisualControl and its subclasses. Methods in cgChartAnnotationVisual, cgLegendVisual, cgChartLabel, cgChartAxisVisual, cgChartGridVisual that returned these objects now return a dummy controller and are themselves deprecated.
  • Made curve fill be accurate when the data visual is moved up in the chart frame.
  • Added Tornado chart (cgTornadoChartVisual and associated tutorial TornadoChartDemo).

3.3 Release

Add shaded grids. This allows the grid to shade alternating rows with light grey or arbitrary colors. We added the following methods to cgChartGridVisual.

The tutorial showing this feature is RoundedBarDemo.java.

Added rounded bar tops for the bar chart. We added the following methods to cgBarChartVisual2D:

  • setEnableRoundedBars
  • isRoundedBars
  • setRoundedBarHorizontalRadius
  • getRoundedBarHorizontalRadius
  • setRoundedBarVerticalRadius
  • getRoundedBarVerticalRadius

The demonstration tutorial is RoundedBarDemo.java.

We added the feature to have internal axes This allows the axes for a chart to be displayed inside the central component. This feature is useful to save space when user has ony a small screen area for the display.

On cgChartFrameVisual, we added enums AxesType {INTERNAL,EXTERNAL} and AxesEndClip {BOTH, HORIZONTAL, NONE, VERTICAL} and new methods.

We added to cgChartFrameVisual the following constructors and/or methods:

  • cgChartFrameVisual(cgChartDataVisual dataVisual, cgCrossLayout.Position legendPosition, cgChartFrameVisual.AxesEndClip axisClip))
  • cgChartFrameVisual(cgFrameAxisSpec[] specs, cgCrossLayout.Position legendPosition, cgChartFrameVisual.AxesEndClip axisClip)
  • AxesType getAxesType()
  • setInternalAxesClip(AxesEndClip axesEndClip)
  • AxesEndClip getInternalAxesClip()

The tutorial is InternalAxesChartDemo.

Removed artificial limit to the number of points in the cgPolarLineChartVisual.

Added new interface cgClippable. Changed cgChartAnnotationVisual to implement this new interface (it already implemented the two methods in this interface). Changed cgChartDataVisual to implement this new interface and provided new methods to implement the interface. This change allows users to clip all drawing to the central data visual area. For example, sometime the line in a line chart was going beyond the bounds of the central data visual area. By enabling clipping on the cgChartDataVisual, that can now be prevented.

Added logarithmic scale ability to the Y axis of cgHistogramChartVisual. This class now implements cgScaleModeSelectable. The tutorial, HistogramDemo, has been changed to show this new capability. To see it, change the source code line

private boolean useLogarithmicScale = false;

So that useLogarithmicScale is true.

Added methods cgChartAxisVisual.isDetailSelfAdjustable() and setDetailSelfAdjustable(boolean) so that users can get better performance by disabling the axis behavior that changes the level of detail based on the view scale.

Added new tutorial variants/ResizingChart to demonstrate how to make a chart that resizes when its container resizes.

Improved docs in LogLineDemo.

Fixed set-ManualRange -- chart now updates self after this method is called.

Details of the API changes

com.interactive.jchart.shapes.cgChartAxisVisual

  • Added : method public boolean com.interactive.jchart.shapes.cgChartAxisVisual.isDetailSelfAdjustable()
  • Added : method public void com.interactive.jchart.shapes.cgChartAxisVisual.setDetailSelfAdjustable(boolean)

com.interactive.jchart.shapes.data.cgHistogramChartVisual

  • Added : method public com.interactive.jchart.shapes.data.cgScaleModeSelectable$ScaleMode com.interactive.jchart.shapes.data.cgHistogramChartVisual.getXDisplayScaleMode()
  • Added : method public com.interactive.jchart.shapes.data.cgScaleModeSelectable$ScaleMode com.interactive.jchart.shapes.data.cgHistogramChartVisual.getYDisplayScaleMode()
  • Added : method public void com.interactive.jchart.shapes.data.cgHistogramChartVisual.setXDisplayScaleMode(com.interactive.jchart.shapes.data.cgScaleModeSelectable$ScaleMode)
  • Added : method public void com.interactive.jchart.shapes.data.cgHistogramChartVisual.setYDisplayScaleMode(com.interactive.jchart.shapes.data.cgScaleModeSelectable$ScaleMode)

3.2 Release

Added ability to have multiple axis for a chart, see tutorial MultipleCharts and changes to cgChartFrameVisual.

Added a completely new editor for charts.

Added new chart types: cgRoseDiagramVisual, cgRoseHistogramVisual, cgPolarLineChartVisual.

We deprecated cgChartDefaultSeries and cgChartDefaultDataSource. We also added some new classes that should be preferred instead of these deprecated classes: cgImmutableDataSource, cgStandardDataSource, cgImmutableDataSeries, cgStandardDataSeries, cgImmutableStringSeries, cgStandardStringSeries, and cgStandardSelectionSeries.

We also added two implementations of cgChartInvalidater: cgStandardChartInvalidater and cgEmptyChartInvalidater. These classes are useful on their own and also to serve as a base class that can be extended when you need to write a class that must implement cgChartInvalidater.

  • In cgChartDefaultDataSource, changed the visibility of the methods addLabelSeries, addSelectionSeries, addAnnotation, and clear from protected to public.
  • In cgChartDefaultSeries, changed the visibility of the methods addValue(double), addString(String) and clear() from protected to public.
  • Added new class cgAbstractLegendVisual.
  • Added three methods to cgChartFrame: getAxis(cgCrossLayout.Position), getAnnotation(cgCrossLayout.Position), and setLegend(cgAbstractLegendVisual, cgCrossLayout.Position position).
  • Changed cgChartFrame.getLegend() to return a cgAbstractLegendVisual.
  • Removed the protected field _defAttr from cgChartVisual, and replaced it with a new protected method getDefaultAttribute().
  • Changed cgChartDataSeries.getValue to return a double instead of a Double.
  • Also changed cgChartDefaultSeries.addValue to accept a double instead of a Double.
  • Added method getDataVisual() to cgChartFrameVisual.
  • Fixed broken implementation of cgChartDefaultDatasource.clearSelection().
  • Added convenience methods to cgChartFrameVisual and cgChartAxisVisual to set the fonts.
  • Made axis tick and tick labels smaller to improve the look.
  • Fixed clipping problem while printing.
  • Allow user to set and get a chart title (new methods on cgChartFrameVisual).
  • Axis width now follows the width of the widest axis tick label automatically.
  • Histogram chart now listens to changes in the histogram bin description.

Removed the deprecated method removeAllChartAttributeEventListener from the interface cgChartInvalidater.

Removed support for the clone method from all data component interfaces. This entailed the below changes.

  • Removed Object clone() method and extends Cloneable from the interfaces cgChartStringSeries, cgChartSelectionSeries, cgChartDataSeries, cgChartDataSource, and cgLegendSource.
  • Changed the clone method in cgChartDefaultSeries and cgChartDefaultDataSource so that it is protected and always throws CloneNotSupportedException.
  • Removed clone method from gallery.RandomDataSource and chart.data.RandomDataSource.

The cgHistogramEdges.initInterval method was changed to remove any assumptions that the bins start or end on integer values. Callers that desire this behavior should modify their calling code to perform the appropriate Math.floor or Math.ceil on the parameters to this method.

cgHistogramChartVisual was changed so that after a call to setEdges, this class will stop automatically managing the edges. Any users who call cgHistogramChartVisual.setEdges should listen for changes in their data and make calls to cgHistogramChartVisual.setEdges when appropriate.

Added new tutorial Simplest that shows a very simple line chart.

Details of the API changes can be found in JChart_32changes.txt.

3.1 Release

The 3.1 release is the first release for J/Chart. This module depends on J/CarnacPro jars and the int util jars, and does not have any other dependencies.

Support Contacts

Copyright © 2004-2026 by SLB.

All rights reserved.