Add Python console option to save history across sessions

This commit is contained in:
Yorik van Havre
2019-09-03 20:51:00 -03:00
committed by wmayer
parent 5eb06381d6
commit b264e34083
2 changed files with 75 additions and 5 deletions

View File

@@ -79,13 +79,13 @@ public:
void append(const QString &inputLine);
const QStringList& values() const;
void restart();
void markScratch( void );
void doScratch( void );
void markScratch( void );
void doScratch( void );
private:
QStringList _history;
QStringList::ConstIterator _it;
int _scratchBegin;
int _scratchBegin;
QString _prefix;
};
@@ -150,6 +150,8 @@ private:
void insertPythonError (const QString&);
void runSourceFromMimeData(const QString&);
void appendOutput(const QString&, int);
void loadHistory() const;
void saveHistory() const;
Q_SIGNALS:
void pendingSource( void );
@@ -162,7 +164,8 @@ private:
private:
PythonConsoleHighlighter* pythonSyntax;
QString *_sourceDrain;
QString *_sourceDrain;
QString _historyFile;
};
/**