文件切割合并器 6  GBC 简化

来源:互联网 发布:卷皮网站源码 编辑:程序博客网 时间:2024/05/16 10:53

import java.awt.*;


public class GBC extends GridBagConstraints
{
   
   
private static final long serialVersionUID = 1L;


public GBC(int gridx, int gridy)
   {
     this.gridx = gridx;
     this.gridy = gridy;
   }

   
   public GBC(int gridx, intgridy, int gridwidth, int gridheight)
   {
     this.gridx = gridx;
     this.gridy = gridy;
     this.gridwidth = gridwidth;
     this.gridheight = gridheight;
   }

   
   public GBC setAnchor(intanchor)
   {
     this.anchor = anchor;
     return this;
   }

   
   public GBC setFill(intfill)
   {
     this.fill = fill;
     return this;
   }

   
   public GBCsetWeight(double weightx, double weighty)
   {
     this.weightx = weightx;
     this.weighty = weighty;
     return this;
   }

   
   public GBC setInsets(intdistance)
   {
     this.insets = new Insets(distance, distance, distance,distance);
     return this;
   }

   
   public GBC setInsets(inttop, int left, int bottom, int right)
   {
     this.insets = new Insets(top, left, bottom, right);
     return this;
   }

   
   public GBC setIpad(intipadx, int ipady)
   {
     this.ipadx = ipadx;
     this.ipady = ipady;
     return this;
   }
}

0 0
原创粉丝点击