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.
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.