Components placed in BorderLayout.CENTER expand to fill the available space in the container.
Ezzaral
Posting Genius
15,986 posts since May 2007
Reputation Points: 3,250
Solved Threads: 847
if you set JTextArea(m, 10, 15); , then scroll.setSize(500, 500); is too contraproductive, call for scroll.pack(); before scroll.setVisible(true); rather than manually set for size on the screen
mKorbel
Veteran Poster
1,141 posts since Feb 2011
Reputation Points: 480
Solved Threads: 224