Package com.treemap.treeplot
Class DefaultTreePlotSettings<Color,Font>
java.lang.Object
com.treemap.treeplot.AbstractTreePlotSettings<Color,Font>
com.treemap.treeplot.DefaultTreePlotSettings<Color,Font>
- All Implemented Interfaces:
PropertyChange
,TreePlotSettings<Color,
Font>
Default implementation of the TreeMapSettings interface.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final MutableBoundedInterval
protected final MutableBoundedInterval
protected final TreeMapModel
Fields inherited from interface com.treemap.treeplot.TreePlotSettings
PROPERTY_COLOR_FIELD, PROPERTY_DEPTH, PROPERTY_GROUP_BY_FIELD, PROPERTY_HIDE_FILTER_RESULTS, PROPERTY_HIDE_SEARCH_RESULTS, PROPERTY_PROBING_COLOR, PROPERTY_RENDERING, PROPERTY_SELECTION_COLOR, PROPERTY_SIZE_FIELD, PROPERTY_TOOLTIP_BACKGROUND, PROPERTY_TOOLTIP_FIELD, PROPERTY_TREEPLOT_BACKGROUND_COLOR, PROPERTY_TREEPLOT_BUBBLE_SIZE, PROPERTY_TREEPLOT_GRID_COLOR, PROPERTY_TREEPLOT_GRID_THICKNESS, PROPERTY_TREEPLOT_GROUPBY
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultTreePlotSettings
(TreeMapModel model, com.macrofocus.igraphics.CPColorFactory<Color> colorFactory, com.macrofocus.igraphics.CPFontFactory<Font> fontFactory) -
Method Summary
Modifier and TypeMethodDescriptioncom.macrofocus.igraphics.CPColor<Color>
Returns the backgroun color to use for drawing the treeplot.MutableProperty<com.macrofocus.igraphics.CPColor<Color>>
Gets the model used to hold the field used to represent the color.getDepth()
Returns the depth to use to lay out the treemap.getFieldSettings
(TreeMapField field) com.macrofocus.igraphics.CPColor<Color>
Returns the color to use for drawing the grid.MutableProperty<com.macrofocus.igraphics.CPColor<Color>>
Returns the thickness used for drawing the grid.Returns whether the groups should be displayed.Gets the model used to hold the list of fields to be use for grouping.com.macrofocus.igraphics.CPColor<Color>
Returns the color to use for drawing the borders.Returns the rendering scheme to use to draw the treemap.com.macrofocus.igraphics.CPColor<Color>
Returns the color to use for drawing the borders.boolean
getShowPopup
(TreeMapField field) Tells whether the specified field should be shown in the popup.Gets the model used to hold the field used to represent the size.com.macrofocus.igraphics.CPColor<Color>
Returns the background color to use for drawing the tooltips.Gets the model used to hold the list of fields to be use by the tooltip.Gets the value of the specified property.Gets the model used to indicate whether filtered nodes should be hidden.Gets the model used to indicate whether nodes that do not match the search criteria should be hidden.void
void
setBackground
(com.macrofocus.igraphics.CPColor<Color> color) Sets the background color to use for drawing the treeplot.void
setColor
(int column) Defines the field to use for coloring.void
setColorByName
(String columnName) Defines the field to use for coloring.void
setColorTreeMapField
(TreeMapField field) void
Defines the depth to use to lay out the treemap.void
setGridColor
(com.macrofocus.igraphics.CPColor<Color> color) Sets the color to use for drawing the grid.void
setGridThickness
(Double value) Sets the thickness used for drawing the grid.void
setGroupBy
(int... columns) Defines the fields to be use for grouping.void
setGroupBy
(Boolean groupBy) Sets whether the groups should be displayed.void
setGroupByByNames
(String... columnNames) Defines the fields to be use for grouping.void
setGroupByTreeMapFields
(TreeMapField[] fields) void
setHideFilterResults
(Boolean hideFilterResults) void
setHideSearchResults
(Boolean hideSearchResults) void
setProbingColor
(com.macrofocus.igraphics.CPColor<Color> color) Sets the color to use for drawing the borders.void
setRendering
(Rendering rendering) Defines the rendering scheme to use to draw the treemap.void
setSelectionColor
(com.macrofocus.igraphics.CPColor<Color> color) Sets the color to use for drawing the borders.void
setShowPopup
(TreeMapField field, boolean show) Sets whether the specified field should be displayed or no in the popup.void
setSize
(int column) Defines the field to use to represent the size.void
setSizeByName
(String columnName) Defines the field to use to represent the size.void
setSizeTreeMapField
(TreeMapField field) void
setTooltipBackground
(com.macrofocus.igraphics.CPColor<Color> color) Sets the background color to use for drawing the tooltips.void
setToolTipTreeMapFields
(TreeMapField[] fields) Methods inherited from class com.treemap.treeplot.AbstractTreePlotSettings
addPropertyChangeListener, addPropertyChangeListener, addTreeMapSettingsListener, firePropertyChange, firePropertyChange, firePropertyChange, getPropertyChangeListeners, getPropertyChangeListeners, notifySettingsChanged, removePropertyChangeListener, removePropertyChangeListener, removeTreeMapSettingsListener, removeTreeMapSettingsListener
-
Field Details
-
model
-
gridThickness
-
bubbleSize
-
-
Constructor Details
-
DefaultTreePlotSettings
public DefaultTreePlotSettings(TreeMapModel model, com.macrofocus.igraphics.CPColorFactory<Color> colorFactory, com.macrofocus.igraphics.CPFontFactory<Font> fontFactory)
-
-
Method Details
-
getDefaultFieldSettings
-
getFieldSettings
-
getGroupByTreeMapFields
Gets the model used to hold the list of fields to be use for grouping.- Returns:
- the model of fields to be use for grouping
-
setGroupByTreeMapFields
-
getSizeTreeMapField
Gets the model used to hold the field used to represent the size.- Returns:
- the model holding the field that represent the size.
-
getColorTreeMapField
Gets the model used to hold the field used to represent the color.- Returns:
- the model holding the field that represent the color.
-
getToolTipTreeMapFields
Gets the model used to hold the list of fields to be use by the tooltip.- Returns:
- the model of fields to be use by the tooltip.
-
setToolTipTreeMapFields
-
isHideFilterResults
Gets the model used to indicate whether filtered nodes should be hidden.- Returns:
- the model indicating whether filtered nodes should be hidden.
-
isHideSearchResults
Gets the model used to indicate whether nodes that do not match the search criteria should be hidden.- Returns:
- the model indicating whether nodes that do not match the search criteria should be hidden.
-
setGroupBy
public void setGroupBy(int... columns) Defines the fields to be use for grouping.- Parameters:
columns
- the indexes of the columns to be used for grouping- See Also:
-
setGroupByByNames
Defines the fields to be use for grouping.- Parameters:
columnNames
- the names of the columns to be used for grouping- See Also:
-
getShowPopup
Description copied from interface:TreePlotSettings
Tells whether the specified field should be shown in the popup.- Parameters:
field
- the field.- Returns:
- true if it should be displayed, false otherwise.
-
setShowPopup
Description copied from interface:TreePlotSettings
Sets whether the specified field should be displayed or no in the popup.- Parameters:
field
- the field.show
- true if it should be displayed, false otherwise.
-
setSize
public void setSize(int column) Defines the field to use to represent the size.- Parameters:
column
- the index of the column to be used for representing the size- See Also:
-
setSizeTreeMapField
-
setSizeByName
Defines the field to use to represent the size.- Parameters:
columnName
- the name of the column to be used for representing the size- See Also:
-
setColor
public void setColor(int column) Defines the field to use for coloring.- Parameters:
column
- the index of the column to be used for coloring- See Also:
-
setColorByName
Defines the field to use for coloring.- Parameters:
columnName
- the name of the column to be used for coloring- See Also:
-
setColorTreeMapField
-
getDepth
Returns the depth to use to lay out the treemap.- Returns:
- the depth to use
- See Also:
-
setDepth
Defines the depth to use to lay out the treemap.- Parameters:
depth
- the depth to use- See Also:
-
setRendering
Defines the rendering scheme to use to draw the treemap.- Parameters:
rendering
- the rendering scheme to use- See Also:
-
setHideFilterResults
-
setHideSearchResults
-
getRendering
Returns the rendering scheme to use to draw the treemap.- Returns:
- the rendering scheme to use
- See Also:
-
getTooltipBackground
Returns the background color to use for drawing the tooltips.- Returns:
- the color to be used
- See Also:
-
setTooltipBackground
Sets the background color to use for drawing the tooltips.- Parameters:
color
- the color to be used- See Also:
-
getProbingColor
Returns the color to use for drawing the borders.- Returns:
- the color to be used
- See Also:
-
setProbingColor
Sets the color to use for drawing the borders.- Parameters:
color
- the color to be used- See Also:
-
getSelectionColor
Returns the color to use for drawing the borders.- Returns:
- the color to be used
- See Also:
-
setSelectionColor
Sets the color to use for drawing the borders.- Parameters:
color
- the color to be used- See Also:
-
getValue
Description copied from interface:TreePlotSettings
Gets the value of the specified property.- Parameters:
key
- the property name- Returns:
- the value
-
resetToDefaults
public void resetToDefaults() -
getBackground
Returns the backgroun color to use for drawing the treeplot.- Returns:
- the color to be used
-
setBackground
Sets the background color to use for drawing the treeplot.- Parameters:
color
- the color to be used
-
getBackgroundProperty
-
getGridColor
Returns the color to use for drawing the grid.- Returns:
- the color to be used
-
setGridColor
Sets the color to use for drawing the grid.- Parameters:
color
- the color to be used
-
getGridColorProperty
-
getGridThicknessInterval
-
getGridThickness
Returns the thickness used for drawing the grid.- Returns:
- the thickness
-
setGridThickness
Sets the thickness used for drawing the grid.- Parameters:
value
- the thickness
-
getGroupBy
Returns whether the groups should be displayed.- Returns:
- the font to be used
-
setGroupBy
Sets whether the groups should be displayed.- Parameters:
groupBy
- true to display the groups; false to display the leaves
-
groupByProperty
-
getBubbleSizeInterval
-