Class IntensityChart
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.PanelUI
-
- org.processmining.logprojection.plugins.dottedchart.IntensityChart
-
public class IntensityChart extends javax.swing.plaf.PanelUIA general class for plotting data in the form of (x, y) pairs. This plot can use data from any class that implements theXYDatasetinterface.XYPlotmakes use of anXYItemRendererto draw each point on the plot. By using different renderers, various chart types can be produced.The
ChartFactoryclass contains static methods for creating pre-configured charts.
-
-
Field Summary
Fields Modifier and Type Field Description static java.awt.StrokeDEFAULT_STROKEThe default grid line stroke.
-
Constructor Summary
Constructors Constructor Description IntensityChart(DottedChart chart, int height, int width)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.DimensiongetPreferredSize(javax.swing.JComponent c)Returns the specified component's preferred size appropriate for the look and feel.voidpaint(java.awt.Graphics g, javax.swing.JComponent c)Paints the specified component appropriately for the look and feel.voidsetData(int[][] data, int max, java.awt.Color[] colorMap, double dataAreaXOffset)voidsetLines(int... lines)
-
-
-
Constructor Detail
-
IntensityChart
public IntensityChart(DottedChart chart, int height, int width)
-
-
Method Detail
-
setData
public void setData(int[][] data, int max, java.awt.Color[] colorMap, double dataAreaXOffset)
-
setLines
public void setLines(int... lines)
-
getPreferredSize
public java.awt.Dimension getPreferredSize(javax.swing.JComponent c)
Returns the specified component's preferred size appropriate for the look and feel. Ifnullis returned, the preferred size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method returnsnull.- Overrides:
getPreferredSizein classjavax.swing.plaf.ComponentUI- Parameters:
c- the component whose preferred size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components- See Also:
JComponent.getPreferredSize(),LayoutManager.preferredLayoutSize(java.awt.Container)
-
paint
public void paint(java.awt.Graphics g, javax.swing.JComponent c)Paints the specified component appropriately for the look and feel. This method is invoked from theComponentUI.updatemethod when the specified component is being painted. Subclasses should override this method and use the specifiedGraphicsobject to render the content of the component.- Overrides:
paintin classjavax.swing.plaf.ComponentUI- Parameters:
g- theGraphicscontext in which to paintc- the component being painted; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components- See Also:
ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)
-
-