Got it working. just my stylesheet was wrong.

self.label.setStyleSheet("background-image:url('/image.png')")


not it works fine. thanks.



On 01/21/2013 09:12 PM, Justin Israel wrote:
One way if you are avoiding stylesheets is to set a QPixmap into a QLabel, and parent it to the widget (not in a layout). If the widget is resizeable, then you would have to implement the resizeEvent of the widget to also match the new size on the QLabel.

What does your stylesheet code look like? Does it work as standalone code, and just not within Maya?


On Tue, Jan 22, 2013 at 7:30 AM, Ricardo Viana <[email protected] <mailto:[email protected]>> wrote:

    Hi guys been looking for a way to put an image in the background
    of a pyqt widget in maya.
    i thought it would be easy but cant seem to find a way. tried with
    setStyleSheet but no sucess.
    also with qpixmap and also a fail. no image displayed. any thoughts?

-- ////////////////////////////////////
    Ricardo Viana
    VFX Generalist

-- You received this message because you are subscribed to the Google
    Groups "Python Programming for Autodesk Maya" group.
    To post to this group, send email to
    [email protected]
    <mailto:[email protected]>.
    To unsubscribe from this group, send email to
    [email protected]
    <mailto:python_inside_maya%[email protected]>.



--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].




--
////////////////////////////////////
Ricardo Viana
VFX Generalist

--
You received this message because you are subscribed to the Google Groups "Python 
Programming for Autodesk Maya" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].


Reply via email to