posted 19 years ago
Hello,
I am having trouble with scrolling a JPanel. When it displays the JPanel it is scrolled all the way to the bottom and I can't seem to find a method where I can force the initial location of the "knob" on the Scrollbar.
Here is how I implement the JPanel
I am using a GridBagLayout for the JPanel where I place some buttons and text. Right now I am doing an uber-ugly hack where I place a empty JTextArea at the very top of the JPanel and set the caret position to 0 on that component, but what is the reason it is scrolling all the way to the bottom?
Thanks,
Casen