public void setOrientation (int orientation)
    {
        GroupLayout gl = (orientation == HORIZONTAL) ?
            (GroupLayout)new HGroupLayout() : new VGroupLayout();
        gl.setPolicy(GroupLayout.EQUALIZE);
        setLayout(gl);
    }
public void setOrientation ( int orientation ) { GroupLayout gl = ( orientation == HORIZONTAL ) ? ( GroupLayout ) new HGroupLayout ( ) : new VGroupLayout ( ) ; gl . setPolicy ( GroupLayout . EQUALIZE ) ; setLayout ( gl ) ; }
Sets the orientation of the box (either {@link #HORIZONTAL} or
{@link #VERTICAL}.