Welcome to the Ranch joaquim,
In order to understand the LayoutManagers just execute examples like this one and try to understand the behaviour. Before that,
Using LayoutManagers from the Java Tutorial might be helpul.
___________________________________________________________________________
_______________________
|=======NORTH===========|
|_______________________|
|W=|==============|==E==|
|E=|==============|==A==|
|S=|====CENTER====|==S==|
|T=|==============|==T==|
|__|______________|_____|
|=======SOUTH===========|
|=======================|
|=======================|
|_______________________|
If you remember the way the components are laid out by a BorderLayout it is easy to deduce how they are going to behave regarding resizing.
Observe that NORTH and SOUTH are given the whole width. That is going to be preserved if the container varies its width, thus NORTH and SOUTH will have their width changing to accomodate the resizing. I have depicted diferent heights for NORTH and SOUTH because BorderLayout honors components' heights.
I think BorderLayout concedes component's preferred height for NORTH and SOUTH. However when changing container's heigth they will not vary.
Observe that WEST and EAST are given the same height. Thus when the container height changes, both heights will accomodate. I think BorderLayout respects preferred witdh for WEST and EAST. They will not change due to resizing.
CENTER component is given the rest of the room, and it will accomodate to any change in container.
________________________________________________________________________
To answer the question apply the explanation above, but there is a trick.
North button is inside a Panel. Thus FlowLayout, not BorderLayout, is responsible for it. Flowlayout centers their components and honors preferred width and height.
Give it a try, post your conclusions and ask for help if you need.
[ September 05, 2003: Message edited by: Jose Botella ]