| setSize( object_dimension ) | ใช้กำหนด ขนาด ของ component ( ใช้ในการเปลี่ยนขนาดของ component ) |
|---|
method:setSize ( object_dimension );
return type:void
content:ใช้กำหนด ขนาด ของ component ( ใช้ในการเปลี่ยนขนาดของ component )
example:JButton button = new JButton ( "cancel" ); button.setBounds ( 0, 0, 100, 30 ); Dimension dimension = new Dimension ( 120, 30 ); button.setSize ( dimension );