Class HistogramPaintlet
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.gui.visualization.core.AbstractPaintlet
-
- adams.gui.visualization.core.AbstractStrokePaintlet
-
- adams.gui.visualization.stats.paintlet.AbstractColorPaintlet
-
- adams.gui.visualization.stats.paintlet.HistogramPaintlet
-
- All Implemented Interfaces:
Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,ShallowCopySupporter<Paintlet>
,SizeOfHandler
,Paintlet
,Serializable
public class HistogramPaintlet extends AbstractColorPaintlet
Paints the histogram
Valid options are:
-D <int> (property: debugLevel) The greater the number the more additional info the scheme may output to the console (0 = off). default: 0 minimum: 0
-stroke-thickness <float> (property: strokeThickness) The thickness of the stroke. default: 1.0 minimum: 0.01
-color <java.awt.Color> (property: color) Stroke color for the paintlet default: #000000
-fill-bins (property: fillBins) Fill the bins with color
-fill-color <java.awt.Color> (property: fillColor) color for filling the bins default: #ff0000
- Version:
- $Revision$
- Author:
- msf8
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
m_Fill
Whether to fill the bins with colorprotected Color
m_FillColor
Color to fill the bins with if fill is chosen-
Fields inherited from class adams.gui.visualization.stats.paintlet.AbstractColorPaintlet
m_Color, m_Data
-
Fields inherited from class adams.gui.visualization.core.AbstractStrokePaintlet
m_StrokeThickness
-
Fields inherited from class adams.gui.visualization.core.AbstractPaintlet
m_Enabled, m_Initializing, m_Panel, m_RepaintOnChange
-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description HistogramPaintlet()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
defineOptions()
Adds options to the internal list of options.protected void
doPerformPaint(Graphics g, PaintEvent.PaintMoment moment)
The paint routine of the paintlet.String
fillBinsTipText()
Tip text for the fill bins propertyString
fillColorTipText()
Tip text for the color propertyboolean
getFillBins()
get whether the bins should be filled with colorColor
getFillColor()
Get the color for filling the binsPaintEvent.PaintMoment
getPaintMoment()
Returns when this paintlet is to be executed.String
globalInfo()
Returns a string describing the object.void
setFillBins(boolean val)
Set whether the bins should be filled with colorvoid
setFillColor(Color val)
Set the color for filling the bins-
Methods inherited from class adams.gui.visualization.stats.paintlet.AbstractColorPaintlet
colorTipText, getColor, getData, setColor, setData
-
Methods inherited from class adams.gui.visualization.core.AbstractStrokePaintlet
applyStroke, getStrokeThickness, getStrokeWidth, performPaint, setStrokeThickness, strokeThicknessTipText
-
Methods inherited from class adams.gui.visualization.core.AbstractPaintlet
canPaint, finishInit, forCommandLine, forName, getPaintlets, getPanel, getPlot, getRepaintOnChange, hasPanel, initialize, isEnabled, isInitializing, memberChanged, memberChanged, paint, repaint, setEnabled, setPanel, setPanel, setRepaintOnChange, shallowCopy, shallowCopy, updatePanel
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, getDefaultLoggingLevel, getOptionManager, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_Fill
protected boolean m_Fill
Whether to fill the bins with color
-
m_FillColor
protected Color m_FillColor
Color to fill the bins with if fill is chosen
-
-
Method Detail
-
getPaintMoment
public PaintEvent.PaintMoment getPaintMoment()
Description copied from class:AbstractPaintlet
Returns when this paintlet is to be executed.- Specified by:
getPaintMoment
in interfacePaintlet
- Specified by:
getPaintMoment
in classAbstractPaintlet
- Returns:
- when this paintlet is to be executed
-
defineOptions
public void defineOptions()
Description copied from class:AbstractColorPaintlet
Adds options to the internal list of options.- Specified by:
defineOptions
in interfaceOptionHandler
- Overrides:
defineOptions
in classAbstractColorPaintlet
-
setFillBins
public void setFillBins(boolean val)
Set whether the bins should be filled with color- Parameters:
val
- True if bins filled
-
getFillBins
public boolean getFillBins()
get whether the bins should be filled with color- Returns:
- true if bins filled
-
fillBinsTipText
public String fillBinsTipText()
Tip text for the fill bins property- Returns:
- String describing the property
-
setFillColor
public void setFillColor(Color val)
Set the color for filling the bins- Parameters:
val
- Color for fill
-
getFillColor
public Color getFillColor()
Get the color for filling the bins- Returns:
- Color for fill
-
fillColorTipText
public String fillColorTipText()
Tip text for the color property- Returns:
- Color describing the property
-
doPerformPaint
protected void doPerformPaint(Graphics g, PaintEvent.PaintMoment moment)
The paint routine of the paintlet.- Specified by:
doPerformPaint
in classAbstractStrokePaintlet
- Parameters:
g
- the graphics context to use for paintingmoment
- whatPaintEvent.PaintMoment
is currently being painted
-
globalInfo
public String globalInfo()
Description copied from class:AbstractOptionHandler
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
-