Set GUI Form JPanel background image

I am trying to adjust a JPanel so that I can get an image as a background.

I can see the options to edit the various border controls and background color but I would really like to get an image in there.

How can this be accomplished?

1 comment
Comment actions Permalink

Hello Justen,

I am trying to adjust a JPanel so that I can get an image as a
background.

I can see the options to edit the various border controls and
background color but I would really like to get an image in there.

How can this be accomplished?


The standard JPanel component doesn't support using an image as a background.
You'll need to implement this by yourself (by custom painting of the panel)
or find a third-party component that supports this (as far as I know, there
is such a component in the free SwingX component suite).

Note that this newsgroup/forum is dedicated to IntelliJ IDEA plugin development.
Questions related to other topics should be posted in different newsgroups/forums.

--
Dmitry Jemerov
Software Developer
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.