Documentation of 'de.erichseifert.gral.graphics.Container' Java class
Container
de.erichseifert.gral.graphics

Interface Container

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method and Description
      void add(Drawable drawable)
      Adds a new component to this container.
      void add(Drawable drawable, java.lang.Object constraints)
      Adds a new component to this container.
      boolean contains(Drawable drawable)
      Returns whether the specified Drawable is stored.
      java.awt.geom.Rectangle2D getBounds()
      Returns the bounds of this container.
      java.lang.Object getConstraints(Drawable drawable)
      Return additional information on component
      java.util.List<Drawable> getDrawables()
      Returns a list of stored components.
      java.util.List<Drawable> getDrawablesAt(java.awt.geom.Point2D point)
      Returns the components at the specified point.
      Insets2D getInsets()
      Returns the space that this container must preserve at each of its edges.
      Layout getLayout()
      Returns the layout associated with this container.
      void layout()
      Recalculates this container's layout.
      void remove(Drawable drawable)
      Removes a component from this container.
      void setBounds(java.awt.geom.Rectangle2D bounds)
      Sets the bounds of this container.
      void setInsets(Insets2D insets)
      Sets the space that this container must preserve at each of its edges.
      void setLayout(Layout layout)
      Sets the layout associated with this container.
      int size()
      Returns the number of components that are stored in this container.
      • Methods inherited from interface java.lang.Iterable

        forEach, iterator, spliterator
    • Method Detail

      • getInsets

        Insets2D getInsets()
        Returns the space that this container must preserve at each of its edges.
        Returns:
        The insets of this DrawableContainer
      • setInsets

        void setInsets(Insets2D insets)
        Sets the space that this container must preserve at each of its edges.
        Parameters:
        insets - Insets to be set.
      • getBounds

        java.awt.geom.Rectangle2D getBounds()
        Returns the bounds of this container.
        Returns:
        bounds
      • setBounds

        void setBounds(java.awt.geom.Rectangle2D bounds)
        Sets the bounds of this container.
        Parameters:
        bounds - Bounds
      • getLayout

        Layout getLayout()
        Returns the layout associated with this container.
        Returns:
        Layout manager
      • layout

        void layout()
        Recalculates this container's layout.
      • setLayout

        void setLayout(Layout layout)
        Sets the layout associated with this container.
        Parameters:
        layout - Layout to be set.
      • add

        void add(Drawable drawable)
        Adds a new component to this container.
        Parameters:
        drawable - Component
      • add

        void add(Drawable drawable,
                 java.lang.Object constraints)
        Adds a new component to this container.
        Parameters:
        drawable - Component
        constraints - Additional information (e.g. for layout)
      • contains

        boolean contains(Drawable drawable)
        Returns whether the specified Drawable is stored.
        Parameters:
        drawable - Element to be checked.
        Returns:
        true if the element is stored in the Container, false otherwise.
      • getDrawablesAt

        java.util.List<Drawable> getDrawablesAt(java.awt.geom.Point2D point)
        Returns the components at the specified point. The first component in the result List is the most specific component, i.e. the component with the deepest nesting level. If no component could be found an empty List will be returned.
        Parameters:
        point - Two-dimensional point.
        Returns:
        Components at the specified point, with the deepest nested component first.
      • getDrawables

        java.util.List<Drawable> getDrawables()
        Returns a list of stored components.
        Returns:
        Contained drawables.
      • getConstraints

        java.lang.Object getConstraints(Drawable drawable)
        Return additional information on component
        Parameters:
        drawable - Component
        Returns:
        Information object or null
      • remove

        void remove(Drawable drawable)
        Removes a component from this container.
        Parameters:
        drawable - Component
      • size

        int size()
        Returns the number of components that are stored in this container.
        Returns:
        total number of components

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.