Skip to main content

JXTextField not working Properly with substance

3 replies [Last post]
frederik88917
Offline
Joined: 2009-11-03
Points: 0

Hi everybody.

I dont know if this issue is old, but I can`t find an answer anywhere.

I`m Working in an application using JXTextfields and the Prompt Option. It happens that when I launch the application using a LookAndFeel by Substance the application get frozen and doesn`t show anything, this happens after I insert a JXTextField with a Prompt Text and Substance.

I tried without using Substance and works, I debugged with Netbeans and I got the next StackTrace:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at org.pushingpixels.substance.internal.utils.SubstanceColorUtilities.getBackgroundFillColor(SubstanceColorUtilities.java:689)
at org.pushingpixels.substance.internal.painter.BackgroundPaintingUtils.update(BackgroundPaintingUtils.java:122)
at org.pushingpixels.substance.internal.utils.SubstanceTextUtilities.paintTextCompBackground(SubstanceTextUtilities.java:580)
at org.pushingpixels.substance.internal.utils.SubstanceTextUtilities.paintTextCompBackground(SubstanceTextUtilities.java:487)
at org.pushingpixels.substance.internal.ui.SubstanceTextFieldUI.paintBackground(SubstanceTextFieldUI.java:126)
at javax.swing.plaf.basic.BasicTextUI.paintSafely(BasicTextUI.java:711)
at javax.swing.plaf.basic.BasicTextUI.paint(BasicTextUI.java:869)
at javax.swing.plaf.basic.BasicTextUI.update(BasicTextUI.java:848)

I`m using the Latest version of substance and SwingX 1.6.1

can you help me out please??

Thanks

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
kschaefe
Offline
Joined: 2006-06-08
Points: 0

Well, the first line of the stack trace is in Sustance. Have you looked into it there?

Karl

frederik88917
Offline
Joined: 2009-11-03
Points: 0

Hi Karl.

Thanks for your answer.

I`ve checked the stack trace and I went into the sources of Substance watching if I was able to find an answer. unfortunately I couldn`t find it.

I`ll check in the substance forums if thet can give me an answer.

Thanks
Frederik

kschaefe
Offline
Joined: 2006-06-08
Points: 0

Actually, I discovered that it was an issue in SwingX. I have fixed it, cf. https://swingx.dev.java.net/issues/show_bug.cgi?id=1377.
Karl