Subclassing GenericAudioProcessorEditor to add background image

Hi,

I’d like to re-use the functionality of GenericAudioProcessorEditor by subclassing it, but add a background image (which covers the entirety of the component bounds).

I can display the image in the paint method, but then the entire rectangle containing the child components appears as a solid color overlaying the image.

How do I prevent that from happening?

TIA,

Jerry.

perhaps paintOverChildren()

Thanks, but unfortunately that doesn’t work: the bitmap then entirely covers the children, so that they aren’t visible at all.

What I’m looking for is having the children ‘transparently overlaid’ on the bitmap, i.e. so that the default gray background that’s drawn under the children is either transparent or simply not drawn.

If that the case then you should reconsider your design hierarchy, which component should be added first to last, which component should be child of who.

If it’s just simple filled rectangle, adding a single “background” component as a member is trivial though.