- improved layout - automatically switch to output component when start is clicked - coloured output for succes/error message - highlighter for pg_dump output that highlights error lines Note: all output of pg_dump goes to stderr because stdout is reserved for output of the backup data.
20 lines
446 B
C++
20 lines
446 B
C++
#ifndef PGDUMPOUTPUTHIGHLIGHTER_H
|
|
#define PGDUMPOUTPUTHIGHLIGHTER_H
|
|
|
|
#include <QSyntaxHighlighter>
|
|
#include <QTextFormat>
|
|
|
|
class PgDumpOutputHighlighter : public QSyntaxHighlighter
|
|
{
|
|
Q_OBJECT
|
|
public:
|
|
PgDumpOutputHighlighter(QTextDocument *parent = nullptr);
|
|
~PgDumpOutputHighlighter() override;
|
|
protected:
|
|
void highlightBlock(const QString &text) override;
|
|
|
|
private:
|
|
QTextCharFormat m_errorFormat;
|
|
};
|
|
|
|
#endif // PGDUMPOUTPUTHIGHLIGHTER_H
|