title: How to resize an image inside QLabel
body: <p>I am developing a custom plugin in Qt and there is this situation where I have to build a widget which has some an Image on it. So I am using QLabel as base class for my custom widget. Here's the code for paint event</p>
  
  <pre><code>     QPixmap pic("/general/source/pic.png");
       setAutoFillBackground(true);
       QPalette palette;
       palette.setBrush(QPalette::Window, QBrush(pic));
  
       this-&gt;setPalette(palette);
  </code></pre>
  
  <p>Now the image is rendered on the QLabel, but this is not what I desired. </p>
  
  <ol>
  <li>I want the image to scale to the size of the QLabel.</li>
  <li>I do not want the image repeating it self when the size of the QLabel goes beyond the size the image.</li>
  </ol>
  
  <p>Please help.</p>