Make the buffer size for the Application Output window configurable

Task-number: QTCREATORBUG-4531
This commit is contained in:
con
2011-04-29 09:36:04 +02:00
parent f6eef7fa0f
commit 5e6d92dd66
9 changed files with 88 additions and 17 deletions

View File

@@ -116,7 +116,7 @@ AppOutputPane::AppOutputPane() :
connect(ProjectExplorerPlugin::instance()->session(), SIGNAL(aboutToUnloadSession()),
this, SLOT(aboutToUnloadSession()));
connect(ProjectExplorerPlugin::instance(), SIGNAL(settingsChanged()),
this, SLOT(updateWordWrapMode()));
this, SLOT(updateFromSettings()));
}
AppOutputPane::~AppOutputPane()
@@ -264,6 +264,7 @@ void AppOutputPane::createNewOutputWindow(RunControl *rc)
ow->setWindowIcon(QIcon(QLatin1String(Qt4ProjectManager::Constants::ICON_WINDOW)));
ow->setFormatter(formatter);
ow->setWordWrapEnabled(ProjectExplorerPlugin::instance()->projectExplorerSettings().wrapAppOutput);
ow->setMaxLineCount(ProjectExplorerPlugin::instance()->projectExplorerSettings().maxAppOutputLines);
Aggregation::Aggregate *agg = new Aggregation::Aggregate;
agg->add(ow);
agg->add(new Find::BaseTextFind(ow));
@@ -281,12 +282,13 @@ void AppOutputPane::handleOldOutput(Core::OutputWindow *window) const
window->grayOutOldContent();
}
void AppOutputPane::updateWordWrapMode()
void AppOutputPane::updateFromSettings()
{
const int size = m_runControlTabs.size();
for (int i = 0; i < size; i++) {
RunControlTab &tab =m_runControlTabs[i];
tab.window->setWordWrapEnabled(ProjectExplorerPlugin::instance()->projectExplorerSettings().wrapAppOutput);
tab.window->setMaxLineCount(ProjectExplorerPlugin::instance()->projectExplorerSettings().maxAppOutputLines);
}
}