Documentation of 'de.erichseifert.gral.plots.legends.Legend' Java class
Legend
de.erichseifert.gral.plots.legends

Interface Legend

    • Method Detail

      • add

        void add(DataSource source)
        Adds the specified data source in order to display it.
        Parameters:
        source - data source to be added.
      • contains

        boolean contains(DataSource source)
        Returns whether the specified data source was added to the legend.
        Parameters:
        source - Data source
        Returns:
        true if legend contains the data source, otherwise false
      • remove

        void remove(DataSource source)
        Removes the specified data source.
        Parameters:
        source - Data source to be removed.
      • clear

        void clear()
        Removes all data sources from the legend.
      • getBaseFont

        java.awt.Font getBaseFont()
        Returns the current font used as a default for sub-components ans for calculation of relative sizes.
        Returns:
        Current base font.
      • setBaseFont

        void setBaseFont(java.awt.Font baseFont)
        Sets the new font that will be used as a default for sub-components and for calculation of relative sizes. This method is only used internally to propagate the base font and shouldn't be used manually.
        Parameters:
        baseFont - New base font.
      • getBackground

        java.awt.Paint getBackground()
        Returns the paint used to draw the background.
        Returns:
        Paint used for background drawing.
      • setBackground

        void setBackground(java.awt.Paint background)
        Sets the paint used to draw the background.
        Parameters:
        background - Paint used for background drawing.
      • getBorderStroke

        java.awt.Stroke getBorderStroke()
        Returns the stroke used to draw the border of the legend.
        Returns:
        Stroke used for border drawing.
      • setBorderStroke

        void setBorderStroke(java.awt.Stroke borderStroke)
        Sets the stroke used to draw the border of the legend.
        Parameters:
        borderStroke - Stroke used for border drawing.
      • getFont

        java.awt.Font getFont()
        Returns the font used to display the labels.
        Returns:
        Font used for labels.
      • setFont

        void setFont(java.awt.Font font)
        Sets the font used to display the labels.
        Parameters:
        font - Font used for labels.
      • getBorderColor

        java.awt.Paint getBorderColor()
        Returns the paint used to fill the border of the legend.
        Returns:
        Paint used for border drawing.
      • setBorderColor

        void setBorderColor(java.awt.Paint borderColor)
        Sets the paint used to fill the border of the legend.
        Parameters:
        borderColor - Paint used for border drawing.
      • getOrientation

        Orientation getOrientation()
        Returns the direction of the legend's items.
        Returns:
        Item orientation.
      • setOrientation

        void setOrientation(Orientation orientation)
        Sets the direction of the legend's items.
        Parameters:
        orientation - Item orientation.
      • getSymbolSize

        java.awt.geom.Dimension2D getSymbolSize()
        Returns the size of the legend's symbols.
        Returns:
        Symbol size relative to the font height.
      • setSymbolSize

        void setSymbolSize(java.awt.geom.Dimension2D symbolSize)
        Sets the size of the legend's symbols.
        Parameters:
        symbolSize - Symbol size relative to the font height.
      • getAlignmentX

        double getAlignmentX()
        Returns the horizontal alignment of the legend relative to the plot area. 0.0 means left, 0.5 means centered, and 1.0 means right.
        Returns:
        Relative horizontal alignment.
      • setAlignmentX

        void setAlignmentX(double alignmentX)
        Sets the horizontal alignment of the legend relative to the plot area. 0.0 means left, 0.5 means centered, and 1.0 means right.
        Parameters:
        alignmentX - Relative horizontal alignment.
      • getAlignmentY

        double getAlignmentY()
        Returns the vertical alignment of the legend relative to the plot area. 0.0 means top, 0.5 means centered, and 1.0 means bottom.
        Returns:
        Relative vertical alignment.
      • setAlignmentY

        void setAlignmentY(double alignmentY)
        Sets the vertical alignment of the legend relative to the plot area. 0.0 means top, 0.5 means centered, and 1.0 means bottom.
        Parameters:
        alignmentY - Relative vertical alignment.
      • getGap

        java.awt.geom.Dimension2D getGap()
        Returns the horizontal and vertical gap between items.
        Returns:
        Gap size relative to the font height.
      • setGap

        void setGap(java.awt.geom.Dimension2D gap)
        Sets the horizontal and vertical gap between items.
        Parameters:
        gap - Gap size relative to the font height.

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.