Interface Paintlet

    • Method Detail

      • setPanel

        void setPanel​(PaintablePanel value)
        Sets the spectrum panel to use, null to disable painting.
        Parameters:
        value - the panel to paint on
      • setPanel

        void setPanel​(PaintablePanel value,
                      boolean register)
        Sets the spectrum panel to use, null to disable painting.
        Parameters:
        value - the panel to paint on
        register - whether to register the panel
      • getPanel

        PaintablePanel getPanel()
        Returns the spectrum panel currently in use.
        Returns:
        the panel in use
      • hasPanel

        boolean hasPanel()
        Returns whether a panel has been set.
        Returns:
        true if a panel is currently set
      • getPlot

        PlotPanel getPlot()
        Returns the plot panel of the panel, null if no panel present.
        Returns:
        the plot panel
      • setEnabled

        void setEnabled​(boolean value)
        Sets whether the paintlet is enabled or not. Setting it to true automatically initiates a repaint. Is not affected by m_RepaintOnChange.
        Parameters:
        value - if true then the paintlet is enabled
        See Also:
        #m_RepaintOnChange
      • isEnabled

        boolean isEnabled()
        Returns whether the paintlet is currently enabled.
        Returns:
        true if the paintlet is enabled.
      • setRepaintOnChange

        void setRepaintOnChange​(boolean value)
        Sets whether the paintlet reacts with repaints to changes of its members.
        Parameters:
        value - if true then the paintlet repaints whenever members get changed
      • getRepaintOnChange

        boolean getRepaintOnChange()
        Returns whether the paintlet reacts with repaints to changes of its members.
        Returns:
        true if paintlet repaints whenever members get changed
      • getPaintMoment

        PaintEvent.PaintMoment getPaintMoment()
        Returns when this paintlet is to be executed.
        Returns:
        when this paintlet is to be executed
      • paint

        void paint​(Graphics g)
        The paint routine of the paintlet.
        Parameters:
        g - the graphics context to use for painting
        See Also:
        isEnabled()