Monday, November 12, 2012

Java Exercise #51: Demonstrate Flow Layout

Flow Layout is a simple layout manager in Java GUI. The components are arranged in the container from left to right (depending on the alignment configuration used) in the order in which they are used. When one row is filled, the other row gets started.

You can specify the alignement using the following 3 constants: FlowLayout.LEFT, FlowLayout.RIGHT or FlowLayout.CENTER. Re-arranging the size of the frame, will automatically re-arrange the layout of the components.

Exercise: Write a program that demonstrates Flow Layout.

Download Code: Flow Layout

No comments:

Post a Comment