I have the following code in the constructor of my JFrame class.
The problem is i want to color the JPanel so I can see it when I add other panels (to help me w/doing layout stuff).
public void windowClosing(WindowEvent anEvent)
Why wont the panel color turn red?????
Attention everyone, I have an announcement
I am an IDIOT!!!!!
I guess if i want to change the color of the actual JPanel, I should use the .setbBackground method, instead of the .setForeground method.
Isnt it crappy how the stupidest little mistakes can drive you crazy for hours!
I'm glad you found your own mistake.
If you are having difficulty building layouts, why not try a better layout system?
I encourage you to try the Oculus Layout System at javalayout.com.
It makes creating layouts with Swing fast and easy. Things stretch and align the way you'd expect, and there is no need to understand or use complicated constraints. It comes with a visual drag-and-drop GUI builder for immediate layout design feedback. It generates Java code which is simple and organized. This makes it readable and maintainable.
It has saved me tons of time building GUIs!
You must be a sales man for that layout designer... The only 2 posts that you've done are pushing for people to try that. Better yet, its like you copied one post, and pasted it to another thread...
I don't think these boards are for advertisement purposes.
-- Android Development Center
-- Cloud Development Project Center
-- HTML5 Development Center
-- Windows Mobile Development Center