title: BoxLayout stretches component to fit parent panel
body: <p>Hi I am using a <code>BoxLayout</code> to stack <code>JPanel</code>s on top of each other (<code>BoxLayout.Y_AXIS</code>), for example if my parent <code>JPanel</code> is of height 500 pixels and I add two child panels to it both of height 100 pixels. The <code>BoxLayout</code> stretches them so that together they occupy the the 500px space. Does anyone know how to disable this feature?</p>