title: Qt - How to redirect QProcess' stdout to TextEdit
body: <p>I'm trying to print the process output of downloading a website using <code>wget</code>
  in a widget (textEdit) , but it prints nothing , however in terminal it works.</p>
  
  <p><strong>Example</strong> </p>
  
  <p>Command :</p>
  
  <pre><code>wget --no-clobber --convert-links --random-wait -r -p -E -e robots=off -U mozilla http://site/path`
  </code></pre>
  
  <p>Output :</p>
  
  <pre><code>Resolving ******... 54.239.26.173
  Connecting to *****|54.239.26.173|:80... connected.
  HTTP request sent, awaiting response... 200 OK
  Length: unspecified [text/html]
  Saving to: ‘/index.html’
  ...
  </code></pre>
  
  <p>My code :</p>
  
  <pre><code>void downloadWebsite::on_pushButton_clicked()
  {
      input = ui-&gt;lineEdit-&gt;text();
      if(input.isEmpty())
      QMessageBox::information(this,"Error","Not an url / webpage !");
      else{
          QProcess *getDownload = new QProcess(this);
          getDownload-&gt;setProcessChannelMode(QProcess::MergedChannels); //it prints everything , even errors
          QString command = "wget --no-clobber --convert-links --random-wait -r -p -E -e robots=off -U mozilla " + input;
          getDownload-&gt;start("sh",QStringList() &lt;&lt; "-c" &lt;&lt;"cd ;"+command);
  
  
          QByteArray outputLog = getDownload-&gt;readAllStandardOutput();
          getDownload-&gt;waitForFinished();
          getDownload-&gt;close();
  
          QString outputToString(outputLog);
          ui-&gt;textEdit-&gt;setText(outputToString);
  
      }
  }
  </code></pre>
  
  <p>What am I doing wrong ?</p>
  
  <p>Thank you.</p>