Class TLcdGXYLayerTreeNodeCellRenderer

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, TreeCellRenderer

public class TLcdGXYLayerTreeNodeCellRenderer extends TLcdLayerTreeNodeCellRenderer
Extension of TLcdLayerTreeNodeCellRenderer that displays layers that are out of scale range disabled. Note that scale range is a property of an ILcdGXYLayer, and not of an ILcdLayer.
Since:
9.0
See Also:
  • Constructor Details

    • TLcdGXYLayerTreeNodeCellRenderer

      public TLcdGXYLayerTreeNodeCellRenderer(ILcdGXYView aGXYView)

      Create a new renderer for a layer tree with an icon height and width of 16. This renderer can only be used on one LayerTree at the same time.

      Parameters:
      aGXYView - the ILcdGXYView containing the layers which will be displayed in the layer tree
    • TLcdGXYLayerTreeNodeCellRenderer

      public TLcdGXYLayerTreeNodeCellRenderer(ILcdGXYView aGXYView, int aIconWidth, int aIconHeight)

      Create a new renderer for a layer tree with the specified icon height and width. This renderer can only be used on one TLcdLayerTree at the same time.

      Depending on the scale of the view and the scale range of the layer, the layer will be disabled/enabled in the layer control.

      Parameters:
      aGXYView - the ILcdGXYView containing the layers which will be displayed in the layer tree
      aIconWidth - the height of the icon
      aIconHeight - the width of the icon
  • Method Details

    • updateRendererFromLayer

      protected void updateRendererFromLayer(JTree aTree, ILcdLayer aLayer, boolean aSelected, boolean aExpanded, boolean aLeaf, int aRow, boolean aHasFocus)
      Description copied from class: TLcdLayerTreeNodeCellRenderer
      Update the state of the renderer to match the state of the given layer. Override this method if you want to customize, for example, the appearance or content of the label, or the displayed tool tip text.
      Overrides:
      updateRendererFromLayer in class TLcdLayerTreeNodeCellRenderer
      Parameters:
      aTree - the tree which is currently rendered
      aLayer - the layer which state the renderer should match
      aSelected - if true, the cell must be drawn as if selected
      aExpanded - if true, the node is currently expanded
      aLeaf - if true, the node represents a leaf
      aRow - the row number
      aHasFocus - if true, the node currently has focus