????Java??GUI???漲??????awt???swing???????????????????????????????????????????????????????????????????С?????????У?????????ЩС??????η?????????????????????????????????LayoutManager??????ɡ?

?????????Java??GUI??????????????????Awt???swing???????????????????????????к????????????????????????????????????????Java?????????????飬??GUI?????????????????????????????????????????

????????????????Java?в?????????????????????????????Java?е???????Container??????????????С????Meta?????????????????????add????????????????????С?????????????Щ???????????С????????????????container.getComponentCount????????????С????????????container.getComponent??i??????????С???????????LayoutManager??????????Щ??????????????е?С?????

????Java?????????????????????????????????磺BorderLayout??FlowLayout??GridBagLayout????????????????????????????????????????????????????????????????????????????????????VflowLayout?????BoxLayout??GridBagLayout????????????????????????swing???????????????????applet???????????????????????????????????????????????????????????????д???????????????????????????????????е?LayoutManager???????????????LayoutManager Inerface?????????????????LayoutManager2 Interface?????????????????????????GridCardLayout??LayoutManager??????????????????????

????1??public void addLayoutComponent??String name?? Component comp??;

????2??public void removeLayoutComponent??Component comp??;

????3??public Dimension preferredLayoutSize??Container container??;

????4??public Dimension minimumLayoutSize??Container container??;

????5??public void layoutContainer??Container container??;

?????????????????????????container.add??String name??component comp??;???????????????BorderLayout?????????????????FlowLayout?????????????????????????????????????????????????????????????????????????????????????????????????????????????Container?ж???????????????Container?и???С???????λ????????????????????container.setLayout??LayoutManager?????????С????????????????????LayoutManager. layoutContainer??container??;??container.setSize??LayoutManager. PreferredLayoutSize??container????;??

?????????????????VflowLayout

package render_account;
import java.awt.*;
import java.io.*;
public class VFlowLayout implements LayoutManager??Serializable{
?? int hgap;
?? int vgap;