Class Margin


  • public final class Margin
    extends NativeObjectContainer
    Defines the margin pixels for legend such that it doesn't stick to the edge of the chart .
    Author:
    Andrea "Stock" Stocchero
    • Constructor Detail

      • Margin

        public Margin()
        Creates an empty margin object.
      • Margin

        public Margin​(int topBottom,
                      int leftRight)
        Creates an margin setting top-bottom and left-right initial values.
        Parameters:
        topBottom - a values to set top and bottom dimensions
        leftRight - a values to set left and right dimensions
      • Margin

        public Margin​(int top,
                      int right,
                      int bottom,
                      int left)
        Creates an margin setting top-bottom and left-right initial values.
        Parameters:
        top - a values to set top dimension
        right - a values to set right dimension
        bottom - a values to set bottom dimension
        left - a values to set left dimension
    • Method Detail

      • setTop

        public void setTop​(int top)
        Sets the margin top of legend.
        Parameters:
        top - the margin top of legend.
      • getTop

        public int getTop()
        Returns the margin top of legend.
        Returns:
        the margin top of legend.
      • setRight

        public void setRight​(int right)
        Sets the margin right of legend.
        Parameters:
        right - the margin right of legend.
      • getRight

        public int getRight()
        Returns the margin right of legend.
        Returns:
        the margin right of legend.
      • setBottom

        public void setBottom​(int bottom)
        Sets the margin bottom of legend.
        Parameters:
        bottom - the margin bottom of legend.
      • getBottom

        public int getBottom()
        Returns the margin bottom of legend.
        Returns:
        the margin bottom of legend.
      • setLeft

        public void setLeft​(int left)
        Sets the margin left of legend.
        Parameters:
        left - the margin left of legend.
      • getLeft

        public int getLeft()
        Returns the margin left of legend.
        Returns:
        the margin left of legend.