title: Move Scrollbar of a textedit to the top
body: <p>hi i'm having some issues to move the scrollbar to the top. I put a image into a QTextEdit and when i open the scrollbar is in the bottom. I need that the scrollbar is on the top</p>
  
  <p>i tried all these but it didn't work for me. still the same.</p>
  
  <pre><code>ui.textEdit-&gt;verticalScrollBar()-&gt;setValue(0);
  </code></pre>
  
  <pre><code>myTextEdit -&gt; moveCursor (QTextCursor::Start) ;
  myTextEdit -&gt; ensureCursorVisible() ;
  </code></pre>
  
  <pre><code>QScrollBar *vScrollBar = yourTextEdit-&gt;verticalScrollBar();
  vScrollBar-&gt;triggerAction(QScrollBar::SliderToMinimum);
  </code></pre>
  
  <p>here is my code.</p>
  
  <pre><code>RulesDialog::RulesDialog(QWidget *parent) :
      QDialog(parent),
      ui(new Ui::RulesDialog)
  {
      ui-&gt;setupUi(this);    
      setWindowIcon(QIcon(":/images/icon3.png"));
      ui-&gt;textEdit-&gt;insertHtml("&lt;img src=':/images/reglas.png'&gt;");
  }
  </code></pre>