title: Change background color of QWidget using animation
body: <p>I want to change background color of widgets (like qlabel) using animation. In fact, I want to run fade in and fade out animation for background color of child widgets on QMainWindow. So, I wrote afew codes as below:</p>
  
  <pre><code>QPropertyAnimation *animation = new QPropertyAnimation(ui-&gt;label1, "styleSheet");
  
  animation-&gt;setStartValue("background-color: rgb(240, 240, 240)");
  animation-&gt;setEndValue("background-color: rgb(126, 194, 66)");
  animation-&gt;setDuration(3000);
  
  animation-&gt;start();
  </code></pre>
  
  <p>But there was no changes!!!<br />
  How can I do it?</p>
  
  <p>Thanks :-)</p>
  
  <hr>
  
  <p>It solved :-)</p>