Package org.meteoinfo.legend
Class ItemNode
- java.lang.Object
-
- org.meteoinfo.legend.ItemNode
-
- Direct Known Subclasses:
GroupNode,LayerNode,LegendNode,MapFrame
public abstract class ItemNode extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ItemNode()Constructor
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidcollapse()Collapse the nodevoidexpand()Expand the nodejava.awt.ColorgetBackColor()Get background colorabstract intgetDrawHeight()Get drawing heightabstract intgetExpandedHeight()Get expanded heightjava.awt.ColorgetForeColor()Get foreground colorintgetHeight()Get heightNodeTypesgetNodeType()Get node typeLayersLegendgetParentLegend()Get parent layers legendjava.lang.StringgetText()Get textintgetTop()Get topbooleanisChecked()Get if is checkedbooleanisExpanded()Get if is expandedbooleanisSelected()Get if is selectedvoidsetBackColor(java.awt.Color backColor)Set background colorvoidsetChecked(boolean checked)Set if is checkedvoidsetForeColor(java.awt.Color foreColor)Set foreground colorvoidsetHeight(int height)Set heightvoidsetNodeType(NodeTypes nodeType)Set node typevoidsetParentLegend(LayersLegend aLegend)Set parent legendvoidsetSelected(boolean sel)Set if is selectedvoidsetText(java.lang.String text)Set textvoidsetTop(int top)Set top
-
-
-
Method Detail
-
getParentLegend
public LayersLegend getParentLegend()
Get parent layers legend- Returns:
- LayersLegend
-
getTop
public int getTop()
Get top- Returns:
- Top
-
setTop
public void setTop(int top)
Set top- Parameters:
top- Top
-
getHeight
public int getHeight()
Get height- Returns:
- Height
-
setHeight
public void setHeight(int height)
Set height- Parameters:
height- Height
-
isExpanded
public boolean isExpanded()
Get if is expanded- Returns:
- Boolean
-
isChecked
public boolean isChecked()
Get if is checked- Returns:
- Boolean
-
setChecked
public void setChecked(boolean checked)
Set if is checked- Parameters:
checked- Boolean
-
getText
public java.lang.String getText()
Get text- Returns:
- The text
-
setText
public void setText(java.lang.String text)
Set text- Parameters:
text- The text
-
getBackColor
public java.awt.Color getBackColor()
Get background color- Returns:
- Background color
-
setBackColor
public void setBackColor(java.awt.Color backColor)
Set background color- Parameters:
backColor- Background color
-
getForeColor
public java.awt.Color getForeColor()
Get foreground color- Returns:
- foreground color
-
setForeColor
public void setForeColor(java.awt.Color foreColor)
Set foreground color- Parameters:
foreColor- Foreground color
-
getNodeType
public NodeTypes getNodeType()
Get node type- Returns:
- The node type
-
setNodeType
public void setNodeType(NodeTypes nodeType)
Set node type- Parameters:
nodeType- The node type
-
isSelected
public boolean isSelected()
Get if is selected- Returns:
- Boolean
-
setSelected
public void setSelected(boolean sel)
Set if is selected- Parameters:
sel- Boolean
-
setParentLegend
public void setParentLegend(LayersLegend aLegend)
Set parent legend- Parameters:
aLegend- The layers legend
-
expand
public void expand()
Expand the node
-
collapse
public void collapse()
Collapse the node
-
getExpandedHeight
public abstract int getExpandedHeight()
Get expanded height- Returns:
- The expanded height
-
getDrawHeight
public abstract int getDrawHeight()
Get drawing height- Returns:
- The drawing height
-
-