Background image in widget

Can I use a jpg image as a background in a widget?
Making a custom widget for my robot vacuum and would like to have a picture as a background,
stretcehd to fill the whole widget. Help appreciated.