Class LayoutManipulator
- java.lang.Object
- 
- com.inductiveautomation.factorypmi.designer.workspace.LayoutManipulator
 
- 
 public class LayoutManipulator extends java.lang.Object
- 
- 
Field SummaryFields Modifier and Type Field Description static intCOLUMNstatic intHORIZONTALstatic intROWstatic intVERTICAL
 - 
Constructor SummaryConstructors Constructor Description LayoutManipulator(VisionDesignerImpl context)
 - 
Method SummaryAll Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.Componentadd(VisionContainer panel, javax.swing.JComponent comp)Adds the component to the panel.static booleancomponentsAreSiblings(java.util.List<javax.swing.JComponent> components)Checks to see if all of the components are siblings (have the same .getParent()) and that there is at least 1 component in the liststatic voidrepositionComponent(javax.swing.JComponent component, java.awt.geom.Rectangle2D newPosition)static voidrepositionComponent(javax.swing.JComponent component, java.awt.geom.Rectangle2D newPosition, boolean delayValidation)Moves the given component to the specified rectangle, which should be relative to the component's parent.static voidsetPositionDelta(javax.swing.JComponent comp, double dx, double dy)Moves a component by dx, dystatic voidvalidateRoot(java.awt.Component c)
 
- 
- 
- 
Field Detail- 
COLUMNpublic static final int COLUMN - See Also:
- Constant Field Values
 
 - 
ROWpublic static final int ROW - See Also:
- Constant Field Values
 
 - 
HORIZONTALpublic static final int HORIZONTAL - See Also:
- Constant Field Values
 
 - 
VERTICALpublic static final int VERTICAL - See Also:
- Constant Field Values
 
 
- 
 - 
Constructor Detail- 
LayoutManipulatorpublic LayoutManipulator(VisionDesignerImpl context) 
 
- 
 - 
Method Detail- 
repositionComponentpublic static void repositionComponent(javax.swing.JComponent component, java.awt.geom.Rectangle2D newPosition)
 - 
repositionComponentpublic static void repositionComponent(javax.swing.JComponent component, java.awt.geom.Rectangle2D newPosition, boolean delayValidation)Moves the given component to the specified rectangle, which should be relative to the component's parent.
 - 
setPositionDeltapublic static void setPositionDelta(javax.swing.JComponent comp, double dx, double dy)Moves a component by dx, dy
 - 
addpublic java.awt.Component add(VisionContainer panel, javax.swing.JComponent comp) Adds the component to the panel. Component should already have its location set on it, but it may be then adjusted to fit within its parent. Will startup the component if it is a ComponentLifecycle
 - 
validateRootpublic static void validateRoot(java.awt.Component c) 
 - 
componentsAreSiblingspublic static boolean componentsAreSiblings(java.util.List<javax.swing.JComponent> components) Checks to see if all of the components are siblings (have the same .getParent()) and that there is at least 1 component in the list
 
- 
 
-