Nov 15
|
You need to set the preferred size of the JScrollBar components.
scrollpane.getVerticalScrollBar().setPreferredSize( new Dimension(width, Integer.MAX_VALUE)); scrollpane.getHorizontalScrollBar().setPreferredSize( new Dimension(Integer.MAX_VALUE, width));