Convert DrawableComposite to Drawable?


I was wondering, if there is any recommended way to convert a DrawableComposite to a Drawable. I am asking, because I want to use it on a DrawableButton. A DrawableButton only allows Drawables, but not DrawablesComposites as images (as far as I can see).

I saw there exists a function DrawableComposite::createCopy(), which returns a Drawable. But the function is flagged as "internal" in the code. So I am not sure, whether I am allowed to use it?


A DrawableComposite is a Drawable? (It inherits from Drawable).

You should be able to pass a DrawableComposite to anything that accepts a Drawable.



Yes, you are right. Don't know, why I did not see that!