Class LayerNameRenderer

    • Field Detail

      • USE_CLOCK_ANIMATION_KEY

        public static final String USE_CLOCK_ANIMATION_KEY
      • label

        protected JLabel label
      • PROGRESS_ICON_KEY

        public static String PROGRESS_ICON_KEY
      • FEATURE_COUNT

        public static String FEATURE_COUNT
    • Constructor Detail

      • LayerNameRenderer

        public LayerNameRenderer()
    • Method Detail

      • setIndicatingEditability

        public void setIndicatingEditability​(boolean indicatingEditability)
      • setIndicatingProgress

        public void setIndicatingProgress​(boolean indicatingProgress,
                                          RenderingManager renderingManager)
      • getLabel

        public JLabel getLabel()
      • getCheckBoxBounds

        public Rectangle getCheckBoxBounds()
        Returns:
        relative to this panel
      • getColumnWidth

        protected int getColumnWidth​(int i)
        Parameters:
        i - zero-based
      • getRowHeight

        protected int getRowHeight()
      • setProgressIconLabelVisible

        public void setProgressIconLabelVisible​(boolean visible)
      • setImageLabelVisible

        public void setImageLabelVisible​(boolean visible)
      • setColorPanelVisible

        public void setColorPanelVisible​(boolean visible)
      • setCheckBoxVisible

        public void setCheckBoxVisible​(boolean visible)
      • setLabelVisible

        public void setLabelVisible​(boolean visible)
      • setBounds

        public void setBounds​(int x,
                              int y,
                              int w,
                              int h)
        Workaround for bug 4238829 in the Java bug database: "JComboBox containing JPanel fails to display selected item at creation time"
        Overrides:
        setBounds in class Component
      • getListCellRendererComponent

        public Component getListCellRendererComponent​(JList<? extends Object> list,
                                                      String value,
                                                      int index,
                                                      boolean isSelected,
                                                      boolean cellHasFocus)
        Special getListCellRendererComponent to render simple Strings. It is not the normal use, but it makes it possible to pass special values as "All Layers" or "Selected Layers" (used in QueryDialog). [mmichaud 2011-09-27]
      • getTreeCellRendererComponent

        public Component getTreeCellRendererComponent​(JTree tree,
                                                      Object value,
                                                      boolean selected,
                                                      boolean expanded,
                                                      boolean leaf,
                                                      int row,
                                                      boolean hasFocus)
        Format the layerable name with formatLayerEntry method then adjust the font, background and foreground according to the layerable's status.
        Specified by:
        getTreeCellRendererComponent in interface TreeCellRenderer
      • filetype

        public String filetype​(File file)
      • isTable

        public static boolean isTable​(Layer layer)