Editors: Move id() from editor to document.

Change-Id: Ib81076842ab1c16832224790194b001206404d64
Reviewed-by: hjk <hjk121@nokiamail.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
Eike Ziller
2014-03-05 15:58:12 +01:00
parent 424a5c1489
commit 5dd8d7cd9c
58 changed files with 96 additions and 78 deletions

View File

@@ -50,7 +50,6 @@ namespace Internal {
PythonEditor::PythonEditor(EditorWidget *editorWidget)
:BaseTextEditor(editorWidget)
{
setId(Constants::C_PYTHONEDITOR_ID);
setContext(Core::Context(Constants::C_PYTHONEDITOR_ID,
TextEditor::Constants::C_TEXTEDITOR));
}

View File

@@ -37,6 +37,7 @@
#include "tools/pythonhighlighter.h"
#include "tools/pythonindenter.h"
#include "pythoneditor.h"
#include "pythoneditorconstants.h"
#include <texteditor/fontsettings.h>
#include <texteditor/texteditorconstants.h>
@@ -50,6 +51,7 @@ namespace Internal {
EditorWidget::EditorWidget(QWidget *parent)
: TextEditor::BaseTextEditorWidget(parent)
{
baseTextDocument()->setId(Constants::C_PYTHONEDITOR_ID);
baseTextDocument()->setIndenter(new PythonIndenter());
ctor();
}