As they arbitrate among components, layout managers work with information provided as follows:
When you include a reference to an applet in an HTML file, you must supply window dimensions, and your applet will have to work itself into those dimensions, however Procrustean they may be:
setSize
method called, then
that setSize
method specifies a window into which all components
must fit.
If you do not supply a setSize
method in a frame, Java will work
with the operating system to choose a frame-window size:
getMinimumSize
method and a
getPreferredSize
method help to determine component size.
If you do not supply getMinimumSize
and getPreferredSize
methods in
your components, Java works with defaults.