FlowEditer temp = (FlowEditer)v;
Graphics2D g2d = (Graphics2D) temp.getGraphics();
g2d.translate(temp.getBounds().x , temp.getBounds().y);
g2d.scale(temp.getBounds().x * this.scale , temp.getBounds().y * this.scale;FlowEditer这个类是我要放大的类,我继承了JComponent
另外就是上边的参数那样写对吗?this.scale是我要放大或缩小的比例

解决方案 »

  1.   

    顶  http://community.csdn.net/Expert/topic/5415/5415516.xml?temp=.4929468
      

  2.   

    如果使用空布局,就可以自定义你的组件大小和位置其它布局各有各的显示方式,比如在BorderLayout布局中,中心组建会放到最大,而四周组建会被分布压缩到最小尺寸。你可以查看javadoc文档了解,不是有中文的javadoc文档可看吗^_^
      

  3.   

    用了GridBagLayout 这个以后呢,我设放大怎么做呢
      

  4.   

    设成NULL,用VE手工布局,很方便的