title: Set constant size of JScrollPane
body: <p>I have a JTabbedPane with a Border Layout.</p>
  
  <p><img src="https://i.stack.imgur.com/sYwwP.png" alt="enter image description here"></p>
  
  <p>Here's the code I'm using to add the components:</p>
  
  <pre><code>add(columnNames, BorderLayout.NORTH);
  add(scroll, BorderLayout.CENTER);
  add(useCtrl, BorderLayout.SOUTH);
  setVisible(true);
  </code></pre>
  
  <p><strong>Question</strong>:
  Notice the excess whitespace to the right inside the JScrollPane. I don't want that there. I would like for the JScrollPane not to change size at all when changing the size of the JFrame. I have tried setSize() and setPreferredSize(), but the size of the JScrollPane always changes. I've tried using GridLayout, but I get the same result.</p>