VCS: Improve tab width handling in VCS editor

Use settings for generic files that do not belong to any project for
e.g. git diff. That way a user can actually override the tab width
which used to be hardcoded to 8.

This is not perfect: Actually we should use the tab width defined for
the file type in the project it belongs to. That does require
significantly more work though.

Task-number: QTCREATORBUG-5178
Change-Id: I509b030e09c33a74ecd529294bf08afec21b2121
Reviewed-on: http://codereview.qt.nokia.com/768
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
This commit is contained in:
Tobias Hunger
2011-06-27 15:00:16 +02:00
parent 8668fb776f
commit 3ffe777f27

View File

@@ -51,6 +51,7 @@
#include <texteditor/basetextdocumentlayout.h>
#include <texteditor/fontsettings.h>
#include <texteditor/texteditorconstants.h>
#include <texteditor/texteditorsettings.h>
#include <utils/qtcassert.h>
#include <extensionsystem/invoker.h>
#include <extensionsystem/pluginmanager.h>
@@ -279,6 +280,7 @@ void VCSBaseEditorWidget::init()
}
break;
}
TextEditor::TextEditorSettings::instance()->initializeEditor(this);
}
VCSBaseEditorWidget::~VCSBaseEditorWidget()