/** This method is used to copy the bounds of this complex to all it contained components. */ public void copyBoundsToComponents() { if (componentsInHiearchy == null || componentsInHiearchy.size() == 0) return; for (Renderable r : componentsInHiearchy) { if (r.bounds == null) { r.bounds = new Rectangle(bounds); if (r.getPosition() == null) r.setPosition(new Point()); ((Node) r).validatePositionFromBounds(); } else { r.bounds.x = bounds.x; r.bounds.y = bounds.y; r.bounds.width = bounds.width; r.bounds.height = bounds.height; } ((Node) r).invalidateTextBounds(); } }