1 Reply Latest reply on Jul 16, 2013 8:17 PM by morgalr

    Free form layout

    rayc

      Does anyone know how to remove a component at runtime from a JPanel which has GroupLayout

      as its LayoutManager AND maintain the preferred gaps between the components in the JPanel.

        • 1. Re: Free form layout
          morgalr

          You need to replace the Component with something... either another JPanel with the perferred size set or another Component, I usually use a JPanel to leave blank space.  It works as long as your layout manager honors the perferred size.