class arty5
(QtGui.
QMainWindow, arty_5new.
Ui_MainWindow):
def __init__(self, parent=None):
super(arty5, self).__init__(parent)
self.setupUi(self)
def connectActions(self):
self.artyTextMain = QPlainText(self)
self.artyTextMain.setTextFormat(QPlainText)
self.textedit = QPlainTextEdit(self)
self.connect(self.process, SIGNAL("readyReadStdout()"), self.readOutput)
self.connect(self.process, SIGNAL("readyReadStdin()"), self.readInput)
self.connect(self.textEdit,SIGNAL("returnPressed()"),self.usr_enter)
print "show input: %s" % self.textEditInput.toPlainText()
self.process.start()
myProcess(start("arty_5new.py"));
def main(self):
self.show()
def readOutput(self):
self.
textEdit.
append(QString(self.
process.
readStdout())) if self.process.isRunning()==False:
self.textEdit.append("\n Completed Successfully")
def startCommand(self):
self.
process.
setArguments(QStringList.
split(" ", self.
Textedit.
text())) self.process.closeStdin()
class arty5(QtGui.QMainWindow, arty_5new.Ui_MainWindow):
def __init__(self, parent=None):
super(arty5, self).__init__(parent)
self.setupUi(self)
def connectActions(self):
self.artyTextMain = QPlainText(self)
self.artyTextMain.setTextFormat(QPlainText)
self.textedit = QPlainTextEdit(self)
self.process = QProcess()
self.connect(self.process, SIGNAL("readyReadStdout()"), self.readOutput)
self.connect(self.process, SIGNAL("readyReadStdin()"), self.readInput)
self.connect(self.textEdit,SIGNAL("returnPressed()"),self.usr_enter)
print "show input: %s" % self.textEditInput.toPlainText()
self.process.start()
QString("arty_5new.py");
myProcess(start("arty_5new.py"));
QProcess(execute(ex, args));
def main(self):
self.show()
def readOutput(self):
self.textEdit.append(QString(self.process.readStdout()))
if self.process.isRunning()==False:
self.textEdit.append("\n Completed Successfully")
def startCommand(self):
self.process.setArguments(QStringList.split(" ", self.Textedit.text()))
self.process.closeStdin()
To copy to clipboard, switch view to plain text mode
I've tossed several different bits and pieces together in vein trying to get it to kick. I get the GUI to open, but my input and output is still through the shell instead of the GUI.
Bookmarks