diff --git a/src/dialogs/LoadNewTypesDialog.cpp b/src/dialogs/LoadNewTypesDialog.cpp index f0c2c9ad..67d5d3bf 100644 --- a/src/dialogs/LoadNewTypesDialog.cpp +++ b/src/dialogs/LoadNewTypesDialog.cpp @@ -3,6 +3,7 @@ #include "Cutter.h" #include "common/Configuration.h" +#include "common/SyntaxHighlighter.h" #include "widgets/TypesWidget.h" #include @@ -14,6 +15,8 @@ LoadNewTypesDialog::LoadNewTypesDialog(QWidget *parent) : { ui->setupUi(this); ui->plainTextEdit->setPlainText(""); + syntaxHighLighter = new SyntaxHighlighter(ui->plainTextEdit->document()); + ui->buttonBox->button(QDialogButtonBox::Ok)->setEnabled(false); } diff --git a/src/dialogs/LoadNewTypesDialog.h b/src/dialogs/LoadNewTypesDialog.h index 97dfbf75..802ad0e5 100644 --- a/src/dialogs/LoadNewTypesDialog.h +++ b/src/dialogs/LoadNewTypesDialog.h @@ -7,6 +7,7 @@ namespace Ui { class LoadNewTypesDialog; } +class SyntaxHighlighter; class LoadNewTypesDialog : public QDialog { @@ -38,6 +39,7 @@ private slots: private: std::unique_ptr ui; + SyntaxHighlighter *syntaxHighLighter; signals: /*!