ucar.unidata.idv.ui
Class SideLegend

java.lang.Object
  extended by ucar.unidata.idv.ui.IdvLegend
      extended by ucar.unidata.idv.ui.SideLegend

public class SideLegend
extends IdvLegend

This class provides the side legend for display controls in view managers. It organizes the set of display controls hierarhcically, according to their display category. It provides facilities to show/hide, in the legend, both categories of display controls as well as the GUI details of individual display controls.

Author:
IDV development team

Nested Class Summary
static class SideLegend.CategoryPanel
          Class CategoryPanel is used to hold the set of display control legends for a particular display category.
 
Field Summary
 
Fields inherited from class ucar.unidata.idv.ui.IdvLegend
ICON_DOCKED, ICON_FLOAT, ICON_PROPERTIES, ICON_REMOVE, STATE_DOCKED, STATE_FLOAT, STATE_HIDDEN, viewManager
 
Constructor Summary
SideLegend()
          Parameterless constructor for xml encoding.
SideLegend(ViewManager viewManager)
          Create me with the given ViewManager
 
Method Summary
protected  JComponent doMakeContents()
          Override the base class method to create the GUI contents.
protected  void fillLegendSafely()
          Override the case class method to refill the legend.
 Hashtable getCategoryToPanelOpen()
          Get the CategoryToPanel property.
 void initWith(SideLegend that)
          Apply the category visibility state from the given that legend to this legend
 void setCategoryToPanelOpen(Hashtable value)
          Set the CategoryToPanel property.
 
Methods inherited from class ucar.unidata.idv.ui.IdvLegend
doClose, fillLegend, floatLegend, getContainer, getContents, getFloatButton, getTitle, makePropertiesButton, setColors, setTheContainer, setViewManager, showLegend, unFloatLegend
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SideLegend

public SideLegend()
Parameterless constructor for xml encoding.


SideLegend

public SideLegend(ViewManager viewManager)
Create me with the given ViewManager

Parameters:
viewManager - The view manager I am part of
Method Detail

doMakeContents

protected JComponent doMakeContents()
Override the base class method to create the GUI contents.

Specified by:
doMakeContents in class IdvLegend
Returns:
The GUI contents

initWith

public void initWith(SideLegend that)
Apply the category visibility state from the given that legend to this legend

Parameters:
that - The that legend

fillLegendSafely

protected void fillLegendSafely()
Override the case class method to refill the legend. This gets called from within a synchronized block when the display controls we are showing have changed in some way.

Specified by:
fillLegendSafely in class IdvLegend

setCategoryToPanelOpen

public void setCategoryToPanelOpen(Hashtable value)
Set the CategoryToPanel property.

Parameters:
value - The new value for CategoryToPanel

getCategoryToPanelOpen

public Hashtable getCategoryToPanelOpen()
Get the CategoryToPanel property.

Returns:
The CategoryToPanel