title: QT QGraphicsView rotation
body: <p>Disclaimer: I am pretty much a beginner with QT.
  I've been struggling for some time to rotate a QGraphicsView (no 3D rotation) but, despite what i do, it doesn't work. I have tried:</p>
  
  <pre><code>QTransform transform;
  transform.rotate(45);
  ui-&gt;graphicsView-&gt;setTransform(transform);
  </code></pre>
  
  <p>or more simply:</p>
  
  <pre><code>ui-&gt;graphicsView-&gt;rotate(45);
  </code></pre>
  
  <p>These seem like very straightforward ways to do it that should work, but for some reason, whenever i run it, the QGraphicsView doesn't rotate at all. If possible, i'd like some direct and easy to understand code snippets, and/or what i'm doing wrong.
  EDIT: This is the code in the widget cpp file i have problems with. It should be a simple timer with an animated hourglass icon. It gets repeated every .5 seconds.</p>
  
  <pre><code>void Widget::timerEvent(QTimerEvent *event)
  {
    ++timeFlag;
    ++timerFlag;
    if (timerFlag &lt; 115){
        animateTimer = QString("\":/new/100/timerFrames/timerIconFrame%1.png\"").arg(timerFlag);
                QPixmap pix(animateTimer);
                pixmapitem.setPixmap(pix);
                scene.addItem(&amp;pixmapitem);
                ui-&gt;graphicsView_2-&gt;setScene(&amp;scene);
    }    
    if (timerFlag &gt;= 115 &amp;&amp; timerFlag &lt; 119){
    //
    }
    if(timerFlag == 119){
       ui-&gt;graphicsView_2-&gt;setStyleSheet("border-image:url(:/new/100/timerIconPix.PNG);border:0px;}");
    }
    if(timerFlag == 120){
      timerFlag = 0;
    }
    if (timeFlag==2){
      timeFlag = 0;
      if(sec&gt;=10){
        ui-&gt;label_2-&gt;setText(QString("%1:%2").arg(min).arg(sec));
      } else {
        ui-&gt;label_2-&gt;setText(QString("%1:0%2").arg(min).arg(sec));
      }
      ++sec;
      if (sec == 60) {
        sec = 0;
        ++min;
      }
    }
  }
  </code></pre>