Class TabPreviewControl

    • Field Detail

      • iconLabel

        protected JLabel iconLabel
        Label for the tab icon.
      • titleLabel

        protected JLabel titleLabel
        Label for the tab title.
      • previewImagePanel

        protected JPanel previewImagePanel
        Panel for the tab preview image.
      • previewImage

        protected BufferedImage previewImage
        The preview image itself.
      • tabPane

        protected JTabbedPane tabPane
        The associated tabbed pane.
    • Constructor Detail

      • TabPreviewControl

        public TabPreviewControl​(JTabbedPane tabPane,
                                 int tabIndex)
        Creates a tab preview control.
        Parameters:
        tabPane - Tabbed pane.
        tabIndex - Tab index.
    • Method Detail

      • paintTabThumbnail

        public void paintTabThumbnail​(Graphics g)
        Paints the tab thumbnail on the specified graphics context.
        Parameters:
        g - Graphics context.
      • setTabIndex

        public void setTabIndex​(int tabIndex)
        Stes the tab index.
        Parameters:
        tabIndex - Tab index.
      • setPreviewImage

        public void setPreviewImage​(BufferedImage previewImage,
                                    boolean toAnimate)
        Sets the tab preview thumbnail.
        Parameters:
        previewImage - Tab preview thumbnail.
        toAnimate - if true, the image will be faded-in.
      • setAlpha

        public void setAlpha​(float alpha)
      • setZoom

        public void setZoom​(float zoom)
      • getZoom

        public float getZoom()