Class TLspMGRSGridOverlayLabelBuilder

java.lang.Object
com.luciad.view.lightspeed.painter.grid.mgrs.TLspMGRSGridOverlayLabelBuilder

public final class TLspMGRSGridOverlayLabelBuilder extends Object

Builder that makes it possible to create MGRS overlay labels. These labels are added to the view and show (part of) an MGRS coordinate. These labels can have a pre-defined content, and style.

The overlay label builder can be used in 2 ways:

  • To build a JComponent that contains a coordinate readout. This component can be used as any Swing component. It can for example be added to the overlay panel or to a UI panel.
  • To add to TLspXYGridLayerBuilder, see TLspXYGridLayerBuilder#overlayLabel. When using this method, the overlay label will be added to the overlay panel of the view. On top of that, the visibility of the overlay label will be synchronized with the visibility of the layer.

An example of how to use this builder:

    // See TLspMGRSGridStyle for more information on configuring the grid style
    JComponent component = TLspMGRSGridOverlayLabelBuilder
        .newBuilder()
        .view(view)
        .content(TLspMGRSGridOverlayLabelBuilder.Content.COORDINATE_AT_CENTER)
        .build();
Since:
2012.1