|
@ -178,7 +178,7 @@ class Console(QtWidgets.QPlainTextEdit): |
|
|
def getHistory(self): |
|
|
def getHistory(self): |
|
|
return self.history |
|
|
return self.history |
|
|
|
|
|
|
|
|
def setHisory(self, history): |
|
|
def setHistory(self, history): |
|
|
self.history = history |
|
|
self.history = history |
|
|
|
|
|
|
|
|
def addToHistory(self, command): |
|
|
def addToHistory(self, command): |
|
@ -357,6 +357,5 @@ welcome_message = ''' |
|
|
if __name__ == '__main__': |
|
|
if __name__ == '__main__': |
|
|
app = QtWidgets.QApplication(sys.argv) |
|
|
app = QtWidgets.QApplication(sys.argv) |
|
|
console = Console(startup_message=welcome_message) |
|
|
console = Console(startup_message=welcome_message) |
|
|
console.updateNamespace({'myVar1' : app, 'myVar2' : 1234}) |
|
|
|
|
|
console.show() |
|
|
console.show() |
|
|
sys.exit(app.exec_()) |
|
|
sys.exit(app.exec_()) |
|
|