title: Using C++, how can I run a python file in Qt Designer?
body: <p>I've finally decided to make the transition from WxPython to QT! I'm using Qt Designer5.9, but I'm having issues placing a new slot. My goal is to press a <code>button</code> on the GUI and have a function run that I have written in another python program.</p>
  
  <p>In Qt Designer, I "<code>go to slot</code>", select <code>clicked()</code> and this appears.</p>
  
  <p>mainwindow.cpp</p>
  
  <pre><code>void MainWindow::on_pushButton_2_clicked()
  {
  
  }
  </code></pre>
  
  <p>Which is exactly what I want, but the wrong language! My python is bad enough let alone anything else. So by running <a href="https://www.bing.com/videos/search?q=first+qt5+app+tutorial&amp;&amp;view=detail&amp;mid=A46E3B63D4A22D57B4ECA46E3B63D4A22D57B4EC&amp;FORM=VRDGAR" rel="nofollow noreferrer">this tutorial</a> I know that if I pass through <code>ui-&gt;textEdit-&gt;append(("Hello World"));</code> I can do something custom, but after converting using <strong>pyuic</strong> to convert to <strong>.py</strong> it's not obvious how it's being implemented. My function is easy to import as shown below, I just need to know where to put it.</p>
  
  <pre><code>import myfunction
  myfunction()
  </code></pre>
  
  <p>Can anyone give me an example of what needs to be written in C++ in Qt Designer so I can call my python function after .ui conversion??</p>