Class AbstractSelectionControls

    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static java.awt.geom.Rectangle2D getBoundingRect​(DesignPanel panel, DesignableDelegate delegate, java.util.List<javax.swing.JComponent> objects, java.awt.geom.Rectangle2D rect)
      Calculates a rectangle that is the smallest rectangle that encloses object's bounds, in logical (unzoomed) space.
      java.awt.Insets getInsets()
      These insets describe the area around the selection control in which its painting and handles are allowed to draw themselves.
      void initialize​(DesignPanel panel, DesignableContainer container, DesignableDelegate delegate, java.util.List<javax.swing.JComponent> selection)  
      java.util.Iterator<IHandle> iterator()  
      void paintBackground​(java.awt.Graphics2D g)
      A chance to paint the background of the selection area before the IHandles are painted
      protected java.awt.geom.Rectangle2D selectionRect()
      Calculates a rectangle that is the smallest rectangle that encloses all selected object's bounds.
      void uninstall()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.lang.Iterable

        forEach, spliterator
    • Field Detail

      • selection

        protected java.util.List<javax.swing.JComponent> selection
      • insets

        protected java.awt.Insets insets
      • handles

        protected java.util.List<IHandle> handles
    • Constructor Detail

      • AbstractSelectionControls

        public AbstractSelectionControls()
    • Method Detail

      • selectionRect

        protected java.awt.geom.Rectangle2D selectionRect()
        Calculates a rectangle that is the smallest rectangle that encloses all selected object's bounds. Rectangle is in logical (unzoomed) coordinates.
      • getBoundingRect

        public static java.awt.geom.Rectangle2D getBoundingRect​(DesignPanel panel,
                                                                DesignableDelegate delegate,
                                                                java.util.List<javax.swing.JComponent> objects,
                                                                java.awt.geom.Rectangle2D rect)
        Calculates a rectangle that is the smallest rectangle that encloses object's bounds, in logical (unzoomed) space.
      • iterator

        public java.util.Iterator<IHandle> iterator()
        Specified by:
        iterator in interface java.lang.Iterable<IHandle>
      • getInsets

        public java.awt.Insets getInsets()
        Description copied from interface: ISelectionControl
        These insets describe the area around the selection control in which its painting and handles are allowed to draw themselves. Should be in un-zoomed (logical) space.
        Specified by:
        getInsets in interface ISelectionControl
      • paintBackground

        public void paintBackground​(java.awt.Graphics2D g)
        Description copied from interface: ISelectionControl
        A chance to paint the background of the selection area before the IHandles are painted
        Specified by:
        paintBackground in interface ISelectionControl