We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpIntegration › Problems with Sketch in JScrollPane
Page Index Toggle Pages: 1
Problems with Sketch in JScrollPane (Read 753 times)
Problems with Sketch in JScrollPane
May 16th, 2009, 12:57am
 
Hi guys,

I´m new to processing and I hope somebody can help me.
I created a sketch with a timeline and everything works fine. Now, I wanted to integrate the sketch into my Java application (I´m using eclipse) and some problems occured.
I have a frame with a JscrollPane in it. The maximum size of the JScroll Pane is (300,300). Now I wanted to integrate my timeline sketch into the JScrollPane. If I set the size of my sketch to (300,300) it works but this is really too small. The normal size of the sketch should be about (2000,300) and I hoped that it is possible to scroll the whole width, but it isnt´t, because only the visible part is rendered and the rest is white.
What can I do that it works???


Ben
Re: Problems with Sketch in JScrollPane
Reply #1 - May 18th, 2009, 4:53am
 
Mmm, there are still the duplicate threads (network lag): since moderator hadn't time to kill them, you should delete them yourself.

While answering another question, I found an answer relevant to your problem. See Mixing heavy and light components article:
Quote:
Do not place heavyweight (AWT) components inside a JScrollPane. If  you need to scroll areas containing heavyweight components, use AWT's  ScrollPane instead.

AFAIK, Processing (the core, not the PDE) uses only AWT, not Swing.
(Except for JFileChooser and some method(s) from SwingUtilities.)
Page Index Toggle Pages: 1