There was a similar question in April, but it has no response. So far i’ve tried doing the following:
- Implementing a custom widget that simply “combines” two other widgets by drawing one over another: resulted in a crash due to an attempt to “downcast an empty state”. No idea what that means.
- Doing something around
iced::advanced::Overlay
: wasn’t able to implement it becauseWidget.layout()
needs aTree
and theOverlay
trait doesn’t provide one. - Trying to follow the modal example: the “key” to the problem in this example was the
iced::widget::stack!
macro, which simply doesn’t exist in the latest crates.io release. I tried using the git release, but the changelog is poorly maintained and there were some substantial differences from the looks of it (even the mainSandbox
trait is gone!), so this is the least attractive path to take ATM.
Is there anything else i can do to add a background image to a widget?