debugging swing problem in open source package

T

T.J. Willis

Hi All,

I'm having some Swing problems with a subsystem of an open source
project and request some help.

The problem is this: I have a component, HTMLPane (
http://cvs.sourceforge.net/viewcvs....w/src/net/sourceforge/sillyview/HTMLPane.java)
that's a subclass of JEditorPane which is specialized for handling
HTML documents. When it catches a call to setUI(), it tries to convert
some aspects of the new UI to a Cascading Stylesheet and applies the
new CSS to the document -- so the HTML "matches" the rest of the UI.

I can put a HTMLPane in a JPanel, a JFrame, a JInternalPane, etc etc
and apply new UI's to it all day with no problems.

So, then I put the HTMLPane in a JSplitPane and apply a new UI once --
no problem. Twice -- a bit slow. Three times, the program goes berserk
and I have to kill the process. I have a feeling that the problem is
in JSplitPane.setLayout, but am having a lot of trouble narrowing it
down.

A program that demonstrates the problem is at:
http://cvs.sourceforge.net/viewcvs....mo/SillyViewDemo.java?rev=1.1.1.1&view=markup
and the whole system can be downloaded at
https://sourceforge.net/projects/sillyview


If someone can come up with a fix for this problem, I'd be happy to
sing your praises in the package's README.

Thanks in advance!
TJ

p.s. The project requires jdk1.5.B1 to run.
 
S

Sudsy

T.J. Willis wrote:
If someone can come up with a fix for this problem, I'd be happy to
sing your praises in the package's README.

Thanks in advance!
TJ

p.s. The project requires jdk1.5.B1 to run.

....and velocity, and junit, and ant...
Sorry, kiddo, but if you want this level of debugging with all those
dependencies then you're looking for someone with a lot more time on
their hands than I have...
But if you're willing to pay market rates then we might be able to
come to an accommodation. :)
No?
Didn't think so.

But best wishes in your pursuits.
 
T

T.J. Willis

nevermind, I fixed it... I was adding the cascading stylesheet tree
to itself in the HTMLPane.setTheme() code.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,152
Latest member
LorettaGur
Top