Showing the changes to interface/src/ui/ScriptEditorWidget.cpp (1 of 4 files). Show all
Unified · Split
| @@ -20,6 +20,7 @@ · 19 unmodified lines | |||
| 20 | #include <QWidget> | 20 | #include <QWidget> |
| 21 | 21 | ||
| 22 | #include "Application.h" | 22 | #include "Application.h" |
| 23 | #include "ScriptHighlighting.h" | ||
| 23 | #include "ui_scriptEditorWidget.h" | 24 | #include "ui_scriptEditorWidget.h" |
| 24 | 25 | ||
| 25 | #include "ScriptEditorWidget.h" | 26 | #include "ScriptEditorWidget.h" |
| @@ -31,7 +32,9 @@ ScriptEditorWidget::ScriptEditorWidget() : · 5 unmodified lines | |||
| 31 | 32 | ||
| 32 | // remove the title bar (see the Qt docs on setTitleBarWidget) | 33 | // remove the title bar (see the Qt docs on setTitleBarWidget) |
| 33 | setTitleBarWidget(new QWidget()); | 34 | setTitleBarWidget(new QWidget()); |
| 34 | //QSyntaxHighlighter* highlighter = new QSyntaxHighlighter(); | 35 | QFontMetrics fm(this->ui->scriptEdit->font()); |
| 36 | this->ui->scriptEdit->setTabStopWidth(fm.width('0') * 4); | ||
| 37 | ScriptHighlighting* highlighting = new ScriptHighlighting(this->ui->scriptEdit->document()); | ||
| 35 | } | 38 | } |
| 36 | 39 | ||
| 37 | ScriptEditorWidget::~ScriptEditorWidget() { | 40 | ScriptEditorWidget::~ScriptEditorWidget() { |