posted 20 years ago
Actually, you've got most of the solution already. The only thing you're missing is that JScrollPane actually has a hidden component - the JViewport. So you have to set both the JScrollPane *and* it's JViewport to not be opaque.
In the following example the background of the JFrame's content pane is set to green and every component in it has setOpaque( false ) called on it so you end up with a scrollable green JTextArea -
-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.