forked from qt-creator/qt-creator
Log Viewer: Fix UI text
Also update the string in the documentation. Task-number: QTCREATORBUG-27055 Change-Id: Idce699a7796e7cb55d8218c105ec851c369cef7b Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -83,7 +83,7 @@
|
|||||||
|
|
||||||
By default, logging categories and messages coming directly from Qt are
|
By default, logging categories and messages coming directly from Qt are
|
||||||
disabled. To display them, select \inlineimage icons/qtlogo-16.png
|
disabled. To display them, select \inlineimage icons/qtlogo-16.png
|
||||||
(\uicontrol {Toggle logging of Qt internal loggings.})
|
(\uicontrol {Toggle Qt Internal Logging}).
|
||||||
|
|
||||||
New messages automatically scroll the message display to the bottom.
|
New messages automatically scroll the message display to the bottom.
|
||||||
To stop automatic scrolling, toggle \inlineimage icons/arrowdown.png
|
To stop automatic scrolling, toggle \inlineimage icons/arrowdown.png
|
||||||
|
@@ -425,7 +425,7 @@ LoggingViewManagerWidget::LoggingViewManagerWidget(QWidget *parent)
|
|||||||
buttonsLayout->addWidget(stop);
|
buttonsLayout->addWidget(stop);
|
||||||
auto qtInternal = new QToolButton;
|
auto qtInternal = new QToolButton;
|
||||||
qtInternal->setIcon(Core::Icons::QTLOGO.icon());
|
qtInternal->setIcon(Core::Icons::QTLOGO.icon());
|
||||||
qtInternal->setToolTip(tr("Toggle logging of Qt internal loggings"));
|
qtInternal->setToolTip(tr("Toggle Qt Internal Logging"));
|
||||||
qtInternal->setCheckable(true);
|
qtInternal->setCheckable(true);
|
||||||
qtInternal->setChecked(false);
|
qtInternal->setChecked(false);
|
||||||
buttonsLayout->addWidget(qtInternal);
|
buttonsLayout->addWidget(qtInternal);
|
||||||
@@ -616,7 +616,7 @@ void LoggingViewManagerWidget::saveLoggingsToFile() const
|
|||||||
if (enabled)
|
if (enabled)
|
||||||
m_manager->setEnabled(false);
|
m_manager->setEnabled(false);
|
||||||
const Utils::FilePath fp = Utils::FileUtils::getSaveFilePath(ICore::dialogParent(),
|
const Utils::FilePath fp = Utils::FileUtils::getSaveFilePath(ICore::dialogParent(),
|
||||||
tr("Save logs as"));
|
tr("Save Logs As"));
|
||||||
if (fp.isEmpty())
|
if (fp.isEmpty())
|
||||||
return;
|
return;
|
||||||
const bool useTS = m_timestamps->isChecked();
|
const bool useTS = m_timestamps->isChecked();
|
||||||
@@ -628,7 +628,7 @@ void LoggingViewManagerWidget::saveLoggingsToFile() const
|
|||||||
if (res == -1) {
|
if (res == -1) {
|
||||||
QMessageBox::critical(
|
QMessageBox::critical(
|
||||||
ICore::dialogParent(), tr("Error"),
|
ICore::dialogParent(), tr("Error"),
|
||||||
tr("Failed to write logs to '%1'.").arg(fp.toUserOutput()));
|
tr("Failed to write logs to \"%1\".").arg(fp.toUserOutput()));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -636,14 +636,14 @@ void LoggingViewManagerWidget::saveLoggingsToFile() const
|
|||||||
} else {
|
} else {
|
||||||
QMessageBox::critical(
|
QMessageBox::critical(
|
||||||
ICore::dialogParent(), tr("Error"),
|
ICore::dialogParent(), tr("Error"),
|
||||||
tr("Failed to open file '%1' for writing logs.").arg(fp.toUserOutput()));
|
tr("Failed to open file \"%1\" for writing logs.").arg(fp.toUserOutput()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void LoggingViewManagerWidget::saveEnabledCategoryPreset() const
|
void LoggingViewManagerWidget::saveEnabledCategoryPreset() const
|
||||||
{
|
{
|
||||||
Utils::FilePath fp = Utils::FileUtils::getSaveFilePath(ICore::dialogParent(),
|
Utils::FilePath fp = Utils::FileUtils::getSaveFilePath(ICore::dialogParent(),
|
||||||
tr("Save enabled categories as"));
|
tr("Save Enabled Categories As"));
|
||||||
if (fp.isEmpty())
|
if (fp.isEmpty())
|
||||||
return;
|
return;
|
||||||
const QList<LoggingCategoryItem> enabled = m_categoryModel->enabledCategories();
|
const QList<LoggingCategoryItem> enabled = m_categoryModel->enabledCategories();
|
||||||
@@ -663,13 +663,13 @@ void LoggingViewManagerWidget::saveEnabledCategoryPreset() const
|
|||||||
if (!fp.writeFileContents(doc.toJson(QJsonDocument::Compact)))
|
if (!fp.writeFileContents(doc.toJson(QJsonDocument::Compact)))
|
||||||
QMessageBox::critical(
|
QMessageBox::critical(
|
||||||
ICore::dialogParent(), tr("Error"),
|
ICore::dialogParent(), tr("Error"),
|
||||||
tr("Failed to write preset file '%1'.").arg(fp.toUserOutput()));
|
tr("Failed to write preset file \"%1\".").arg(fp.toUserOutput()));
|
||||||
}
|
}
|
||||||
|
|
||||||
void LoggingViewManagerWidget::loadAndUpdateFromPreset()
|
void LoggingViewManagerWidget::loadAndUpdateFromPreset()
|
||||||
{
|
{
|
||||||
Utils::FilePath fp = Utils::FileUtils::getOpenFilePath(ICore::dialogParent(),
|
Utils::FilePath fp = Utils::FileUtils::getOpenFilePath(ICore::dialogParent(),
|
||||||
tr("Load enabled categories from"));
|
tr("Load Enabled Categories From"));
|
||||||
if (fp.isEmpty())
|
if (fp.isEmpty())
|
||||||
return;
|
return;
|
||||||
// read file, update categories
|
// read file, update categories
|
||||||
@@ -677,7 +677,7 @@ void LoggingViewManagerWidget::loadAndUpdateFromPreset()
|
|||||||
QJsonDocument doc = QJsonDocument::fromJson(fp.fileContents(), &error);
|
QJsonDocument doc = QJsonDocument::fromJson(fp.fileContents(), &error);
|
||||||
if (error.error != QJsonParseError::NoError) {
|
if (error.error != QJsonParseError::NoError) {
|
||||||
QMessageBox::critical(ICore::dialogParent(), tr("Error"),
|
QMessageBox::critical(ICore::dialogParent(), tr("Error"),
|
||||||
tr("Failed to read preset file '%1': %2").arg(fp.toUserOutput())
|
tr("Failed to read preset file \"%1\": %2").arg(fp.toUserOutput())
|
||||||
.arg(error.errorString()));
|
.arg(error.errorString()));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user