All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, org.gvsig.app.project.documents.view.legend.gui.LegendsPanel, org.gvsig.propertypage.PropertiesPage, org.gvsig.tools.swing.api.Component

public class LegendManager extends AbstractThemeManagerPage implements org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
Implements the panel which allows the user to control all the information about the legends of a layer in order to improve the information that it offers to the user. There are options to create, save or load an existing legend.
Author:
jaume dominguez faus - jaume.dominguez@iver.es
See Also:
  • Field Details

    • defaultLegendFolderPath

      public static String defaultLegendFolderPath
  • Constructor Details

    • LegendManager

      public LegendManager()
  • Method Details

    • addLegendPage

      public static void addLegendPage(Class<? extends org.gvsig.app.project.documents.view.legend.gui.ILegendPanel> iLegendPanelClass)

      Adds a new fully-featured legend panel to the LegendManager.

      CAUTION: Trying to add a child page whose parent hasn't been added yet causes the application to fall in an infinite loop. This is a known bug, sorry. Just avoid this case or try to fix it (lol).

      Parameters:
      iLegendPanelClass -
    • setActivePage

      public void setActivePage(org.gvsig.app.project.documents.view.legend.gui.ILegendPanel page)
      Specified by:
      setActivePage in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • getActivePage

      public org.gvsig.app.project.documents.view.legend.gui.ILegendPanel getActivePage()
      Specified by:
      getActivePage in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • getName

      public String getName()
      Description copied from class: AbstractThemeManagerPage
      Returns the name of this ThemeManagerPage's tab, the text returned by this method will be shown in the text of this panel's tab.
      Specified by:
      getName in class AbstractThemeManagerPage
    • acceptAction

      public void acceptAction()
      Description copied from class: AbstractThemeManagerPage

      Method invoked when the Ok button is pressed from the ThemeManagerWindow. It will cause the changes performed by the user to take effect into the layer if the Apply button wasn't pressed yet. In case Apply button was pressed, then the programmer can choose between apply the changes again or not.

      It shouldn't be a problem rather than the potential consumption of time required in when applying such changes.

      Notice that after the call of this method the ThemeManagerWindow will be closed.

      Specified by:
      acceptAction in class AbstractThemeManagerPage
    • cancelAction

      public void cancelAction()
      Description copied from class: AbstractThemeManagerPage

      Method invoked when the Cancel button is pressed from the ThemeManagerWindow. It will cause that the changes performed will be discarded.

      Specified by:
      cancelAction in class AbstractThemeManagerPage
    • applyAction

      public void applyAction()
      Description copied from class: AbstractThemeManagerPage
      Method invoked when the Apply button is pressed from the ThemeManagerWindow. It will cause the changes performed by the user to take effect inmediately into the the layer.
      Specified by:
      applyAction in class AbstractThemeManagerPage
    • setModel

      public void setModel(org.gvsig.fmap.mapcontext.layers.FLayer layer)
      Description copied from class: AbstractThemeManagerPage
      This method is invoked during the initialization of the ThemeManagerWindow and causes the dialog to be updated to reflect the current settings of the layer in the context that this panel was designed for.
      Specified by:
      setModel in class AbstractThemeManagerPage
      Parameters:
      layer - , the target FLayer
    • getPriority

      public int getPriority()
      Description copied from class: AbstractThemeManagerPage
      Retorna la prioridad usada para determinar la posicion de la pestaña. Cuanto mas alta sea esta mas a la izquierda estara la pestaña.
      Specified by:
      getPriority in interface org.gvsig.propertypage.PropertiesPage
      Overrides:
      getPriority in class AbstractThemeManagerPage
      Returns:
      La prioridad
    • getLegend

      public org.gvsig.fmap.mapcontext.rendering.legend.ILegend getLegend()
      Specified by:
      getLegend in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • setLegend

      public void setLegend(org.gvsig.fmap.mapcontext.rendering.legend.ILegend legend)
      Specified by:
      setLegend in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • getLayer

      public org.gvsig.fmap.mapcontext.layers.FLayer getLayer()
      Specified by:
      getLayer in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • setLayer

      public void setLayer(org.gvsig.fmap.mapcontext.layers.FLayer layer)
      Specified by:
      setLayer in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • getPage

      public org.gvsig.app.project.documents.view.legend.gui.ILegendPanel getPage(Class<? extends org.gvsig.app.project.documents.view.legend.gui.ILegendPanel> pageClass)
      Specified by:
      getPage in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel
    • getPages

      public Collection<org.gvsig.app.project.documents.view.legend.gui.ILegendPanel> getPages()
      Specified by:
      getPages in interface org.gvsig.app.project.documents.view.legend.gui.LegendsPanel