Maximar sem aumentar os componetes

eaê javeiros,

criei um jpanel e joguei dentro de um jframe…mas o jpanel aparece com os jlabels e jtextfield enormes…tentei o setMaximunSize() mas não surtiu efeito…alguém me tem uma solução[?] :idea:

Use um Layout Manager decente :wink:

http://www.jgoodies.com :smiley:

[quote]Use um Layout Manager decente
[/quote]

não dá pra fazer isso com um GridLayout da vida…
tinha tentado com o JInternal …mas naão consegui muita coisa…

[quote=“ednázio_fernandes”][quote]Use um Layout Manager decente
[/quote]

não dá pra fazer isso com um GridLayout da vida…
tinha tentado com o JInternal …mas naão consegui muita coisa…[/quote]

Cara esse negocio de layout eh complicado…
Com relação ao BorderLayout, ai vao algumas dicas que acho que vao te ajudar:

[quote]GridLayout calculates the siz of its associates container by examining the dimensions of each child component whithin the container and recording the largest width and height values it finds. For example, when a GridLayout is asked for the container´s preffered size, it calls getPreferredSize() for each child component and records the largest preferred height value returned by a component. That maximum preferred component height is then multiplied by the number of rows to be displayed and added to the container´s top and bottom insets, along with the number of pixels needes to provide the vertical spacing between component rows.
The same equation is used to calculate a container´s minimum size, but the largestComponentWidth and largestComponentHeight values are obtained by calling the getMinimumSize() instead of getPreferredSize().[/quote]