@@ -222,21 +223,21 @@ ClangdSettingsWidget::ClangdSettingsWidget(const ClangdSettings::Data &settingsD
"Background Priority: Minimum priority, runs on idle CPUs. May leave 'performance' "
"cores unused.
"
"Normal Priority: Reduced priority compared to interactive work.
"
- "Low Priority: Same priority as other clangd work.");
+ "Low Priority: Same priority as other clangd work.
");
const QString headerSourceSwitchToolTip = Tr::tr(
- "Which C/C++ backend to use when switching between header and source file."
- "
The clangd implementation has more capabilities, but also has some bugs not present "
- "in the built-in variant."
- "
When \"Try Both\" is selected, clangd will be employed only if the built-in variant "
- "does not find anything.");
+ "
The C/C++ backend to use for switching between header and source files.
"
+ "While the clangd implementation has more capabilities than the built-in "
+ "code model, it tends to find false positives.
"
+ "When \"Try Both\" is selected, clangd is used only if the built-in variant "
+ "does not find anything.
");
using RankingModel = ClangdSettings::CompletionRankingModel;
const QString completionRankingModelToolTip = Tr::tr(
- "Which model clangd should use to rank possible completions."
- "
This determines the order of candidates in the combo box when doing code completion."
+ "
Which model clangd should use to rank possible completions.
"
+ "This determines the order of candidates in the combo box when doing code completion.
"
"The \"%1\" model used by default results from (pre-trained) machine learning and "
- "provides superior results on average."
+ "provides superior results on average.
"
"If you feel that its suggestions stray too much from your expectations for your "
- "code base, you can try switching to the hand-crafted \"%2\" model.").arg(
+ "code base, you can try switching to the hand-crafted \"%2\" model.
").arg(
ClangdSettings::rankingModelToDisplayString(RankingModel::DecisionForest),
ClangdSettings::rankingModelToDisplayString(RankingModel::Heuristics));
const QString workerThreadsToolTip = Tr::tr(
@@ -244,10 +245,12 @@ ClangdSettingsWidget::ClangdSettingsWidget(const ClangdSettings::Data &settingsD
"worker threads.");
const QString autoIncludeToolTip = Tr::tr(
"Controls whether clangd may insert header files as part of symbol completion.");
- const QString documentUpdateToolTip = Tr::tr(
- "Defines the amount of time Qt Creator waits before sending document changes to the "
- "server.\n"
- "If the document changes again while waiting, this timeout resets.");
+ const QString documentUpdateToolTip
+ //: %1 is the application name (Qt Creator)
+ = Tr::tr("Defines the amount of time %1 waits before sending document changes to the "
+ "server.\n"
+ "If the document changes again while waiting, this timeout resets.")
+ .arg(QGuiApplication::applicationDisplayName());
const QString sizeThresholdToolTip = Tr::tr(
"Files greater than this will not be opened as documents in clangd.\n"
"The built-in code model will handle highlighting, completion and so on.");
diff --git a/src/plugins/cppeditor/cppmodelmanager.cpp b/src/plugins/cppeditor/cppmodelmanager.cpp
index 2deaea4290c..e72c630cbf7 100644
--- a/src/plugins/cppeditor/cppmodelmanager.cpp
+++ b/src/plugins/cppeditor/cppmodelmanager.cpp
@@ -568,9 +568,10 @@ static void checkNextFunctionForUnused(
return;
const int newProgress = findRefsFuture->progressValue() + 1;
findRefsFuture->setProgressValueAndText(newProgress,
- Tr::tr("Checked %1 of %n function(s)")
- .arg(newProgress)
- .arg(findRefsFuture->progressMaximum()));
+ Tr::tr("Checked %1 of %n function(s)",
+ nullptr,
+ findRefsFuture->progressMaximum())
+ .arg(newProgress));
QVariantMap data = search->userData().toMap();
QVariant &activeLinks = data["active"];
QVariantList activeLinksList = activeLinks.toList();
diff --git a/src/plugins/cppeditor/cppquickfixes.cpp b/src/plugins/cppeditor/cppquickfixes.cpp
index c4f32dc1e31..d3d244b81c0 100644
--- a/src/plugins/cppeditor/cppquickfixes.cpp
+++ b/src/plugins/cppeditor/cppquickfixes.cpp
@@ -9408,8 +9408,8 @@ public:
m_wasCxxStyle(m_kind == T_CPP_COMMENT || m_kind == T_CPP_DOXY_COMMENT),
m_isDoxygen(m_kind == T_DOXY_COMMENT || m_kind == T_CPP_DOXY_COMMENT)
{
- setDescription(m_wasCxxStyle ? Tr::tr("Convert comment to C style")
- : Tr::tr("Convert comment to C++ style"));
+ setDescription(m_wasCxxStyle ? Tr::tr("Convert Comment to C-Style")
+ : Tr::tr("Convert Comment to C++-Style"));
}
private:
@@ -9631,8 +9631,8 @@ public:
: CppQuickFixOperation(interface), m_symbol(symbol), m_commentTokens(commentTokens)
{
setDescription(direction == Direction::ToDecl
- ? Tr::tr("Move function documentation to declaration")
- : Tr::tr("Move function documentation to definition"));
+ ? Tr::tr("Move Function Documentation to Declaration")
+ : Tr::tr("Move Function Documentation to Definition"));
}
private:
diff --git a/src/plugins/cppeditor/cppvirtualfunctionassistprovider.cpp b/src/plugins/cppeditor/cppvirtualfunctionassistprovider.cpp
index 19fc0890257..34aa3d6fd07 100644
--- a/src/plugins/cppeditor/cppvirtualfunctionassistprovider.cpp
+++ b/src/plugins/cppeditor/cppvirtualfunctionassistprovider.cpp
@@ -94,7 +94,7 @@ public:
QTC_ASSERT(m_params.function, return nullptr);
auto *hintItem = new VirtualFunctionProposalItem(Utils::Link());
- hintItem->setText(Tr::tr("collecting overrides ..."));
+ hintItem->setText(Tr::tr("collecting overrides..."));
hintItem->setOrder(-1000);
QList items;
diff --git a/src/plugins/cppeditor/followsymbol_switchmethoddecldef_test.cpp b/src/plugins/cppeditor/followsymbol_switchmethoddecldef_test.cpp
index feac4e70fa7..21664ea1402 100644
--- a/src/plugins/cppeditor/followsymbol_switchmethoddecldef_test.cpp
+++ b/src/plugins/cppeditor/followsymbol_switchmethoddecldef_test.cpp
@@ -449,7 +449,7 @@ F2TestCase::F2TestCase(CppEditorAction action,
first.text = "";
expectedImmediate << first;
}
- expectedImmediate << OverrideItem(QLatin1String("collecting overrides ..."));
+ expectedImmediate << OverrideItem(QLatin1String("collecting overrides..."));
}
QCOMPARE(immediateVirtualSymbolResults, expectedImmediate);
if (useClangd) {
diff --git a/src/plugins/debugger/dap/pydapengine.cpp b/src/plugins/debugger/dap/pydapengine.cpp
index 2257aab76ad..4bbb479126f 100644
--- a/src/plugins/debugger/dap/pydapengine.cpp
+++ b/src/plugins/debugger/dap/pydapengine.cpp
@@ -253,7 +253,7 @@ void PyDapEngine::setupEngine()
Utils::InfoBarEntry
info(installDebugPyInfoBarId,
Tr::tr(
- "Python Debugging Support is not available. Please install debugpy package."),
+ "Python debugging support is not available. Install the debugpy package."),
Utils::InfoBarEntry::GlobalSuppression::Enabled);
info.addCustomButton(Tr::tr("Install debugpy"), [this] {
Core::ICore::infoBar()->removeInfo(installDebugPyInfoBarId);
diff --git a/src/plugins/debugger/lldb/lldbengine.cpp b/src/plugins/debugger/lldb/lldbengine.cpp
index 9d1717fff54..12da7a86fc4 100644
--- a/src/plugins/debugger/lldb/lldbengine.cpp
+++ b/src/plugins/debugger/lldb/lldbengine.cpp
@@ -1030,8 +1030,8 @@ void LldbEngine::fetchDisassembler(DisassemblerAgent *agent)
void LldbEngine::fetchFullBacktrace()
{
DebuggerCommand cmd("fetchFullBacktrace");
- cmd.callback = [](const DebuggerResponse &response) {
- Internal::openTextEditor("Backtrace $", fromHex(response.data.data()));
+ cmd.callback = [](const DebuggerResponse &response) {
+ Internal::openTextEditor("Backtrace $", fromHex(response.data["fulltrace"].data()));
};
runCommand(cmd);
}
diff --git a/src/plugins/docker/dockerdevice.cpp b/src/plugins/docker/dockerdevice.cpp
index 17a2e64165c..7dc014eadaf 100644
--- a/src/plugins/docker/dockerdevice.cpp
+++ b/src/plugins/docker/dockerdevice.cpp
@@ -187,7 +187,7 @@ DockerDeviceSettings::DockerDeviceSettings()
mounts.setLabelText(Tr::tr("Paths to mount:"));
mounts.setDefaultValue({Core::DocumentManager::projectsDirectory().toString()});
mounts.setToolTip(Tr::tr("Maps paths in this list one-to-one to the docker container."));
- mounts.setPlaceHolderText(Tr::tr("Host directories to mount into the container"));
+ mounts.setPlaceHolderText(Tr::tr("Host directories to mount into the container."));
extraArgs.setSettingsKey(DockerDeviceExtraArgs);
extraArgs.setLabelText(Tr::tr("Extra arguments:"));
@@ -220,7 +220,7 @@ DockerDeviceSettings::DockerDeviceSettings()
});
cb(items);
} else {
- QStandardItem *errorItem = new QStandardItem(Tr::tr("Error!"));
+ QStandardItem *errorItem = new QStandardItem(Tr::tr("Error"));
errorItem->setToolTip(result.error());
cb({errorItem});
}
@@ -247,7 +247,7 @@ DockerDeviceSettings::DockerDeviceSettings()
path = onDevicePath;
} else {
return make_unexpected(
- Tr::tr("Path \"%1\" does not exist.").arg(onDevicePath.toUserOutput()));
+ Tr::tr("The path \"%1\" does not exist.").arg(onDevicePath.toUserOutput()));
}
}
QString error;
@@ -766,32 +766,32 @@ QStringList toMountArg(const DockerDevicePrivate::TemporaryMountInfo &mi)
expected_str isValidMountInfo(const DockerDevicePrivate::TemporaryMountInfo &mi)
{
if (mi.path.needsDevice())
- return make_unexpected(QString("Path \"%1\" is not local").arg(mi.path.toUserOutput()));
+ return make_unexpected(QString("The path \"%1\" is not local.").arg(mi.path.toUserOutput()));
if (mi.path.isEmpty() && mi.containerPath.isEmpty())
- return make_unexpected(QString("Both paths are empty"));
+ return make_unexpected(QString("Both paths are empty."));
if (mi.path.isEmpty()) {
- return make_unexpected(QString("Local path is empty, container path is \"%1\"")
+ return make_unexpected(QString("The local path is empty, the container path is \"%1\".")
.arg(mi.containerPath.toUserOutput()));
}
if (mi.containerPath.isEmpty()) {
return make_unexpected(
- QString("Container path is empty, local path is \"%1\"").arg(mi.path.toUserOutput()));
+ QString("The container path is empty, the local path is \"%1\".").arg(mi.path.toUserOutput()));
}
if (!mi.path.isAbsolutePath() || !mi.containerPath.isAbsolutePath()) {
- return make_unexpected(QString("Path \"%1\" or \"%2\" is not absolute")
+ return make_unexpected(QString("The path \"%1\" or \"%2\" is not absolute.")
.arg(mi.path.toUserOutput())
.arg(mi.containerPath.toUserOutput()));
}
if (mi.containerPath.isRootPath())
- return make_unexpected(QString("Path \"%1\" is root").arg(mi.containerPath.toUserOutput()));
+ return make_unexpected(QString("The path \"%1\" is root.").arg(mi.containerPath.toUserOutput()));
if (!mi.path.exists())
- return make_unexpected(QString("Path \"%1\" does not exist").arg(mi.path.toUserOutput()));
+ return make_unexpected(QString("The path \"%1\" does not exist.").arg(mi.path.toUserOutput()));
return {};
}
@@ -913,10 +913,12 @@ expected_str DockerDevicePrivate::startContainer()
qCWarning(dockerDeviceLog) << "Container shell encountered error:" << resultData.m_error;
DockerApi::recheckDockerDaemon();
+ //: %1 is the application name (Qt Creator)
MessageManager::writeFlashing(Tr::tr("Docker daemon appears to be not running. "
"Verify daemon is up and running and reset the "
"Docker daemon in Docker device preferences "
- "or restart Qt Creator."));
+ "or restart %1.")
+ .arg(QGuiApplication::applicationDisplayName()));
});
QTC_ASSERT(m_shell,
@@ -939,7 +941,7 @@ expected_str DockerDevicePrivate::updateContainerAccess()
}
if (m_isShutdown)
- return make_unexpected(Tr::tr("Device is shutdown"));
+ return make_unexpected(Tr::tr("Device is shut down"));
if (DockerApi::isDockerDaemonAvailable(false).value_or(false) == false)
return make_unexpected(Tr::tr("Docker system is not reachable"));
@@ -1201,7 +1203,7 @@ public:
CommandLine cmd{settings().dockerBinaryPath(),
{"images", "--format", "{{.ID}}\\t{{.Repository}}\\t{{.Tag}}\\t{{.Size}}"}};
- m_log->append(Tr::tr("Running \"%1\"\n").arg(cmd.toUserOutput()));
+ m_log->append(Tr::tr("Running \"%1\"").arg(cmd.toUserOutput()) + "\n");
m_process = new Process(this);
m_process->setCommand(cmd);
diff --git a/src/plugins/docker/dockerdevicewidget.cpp b/src/plugins/docker/dockerdevicewidget.cpp
index 01d80106b68..0e269ee3972 100644
--- a/src/plugins/docker/dockerdevicewidget.cpp
+++ b/src/plugins/docker/dockerdevicewidget.cpp
@@ -173,7 +173,7 @@ DockerDeviceWidget::DockerDeviceWidget(const IDevice::Ptr &device)
deviceSettings->tag, br,
deviceSettings->imageId, br,
daemonStateLabel, m_daemonReset, m_daemonState, br,
- Tr::tr("Container State:"), deviceSettings->containerStatus, br,
+ Tr::tr("Container state:"), deviceSettings->containerStatus, br,
deviceSettings->useLocalUidGid, br,
deviceSettings->keepEntryPoint, br,
deviceSettings->enableLldbFlags, br,
@@ -187,7 +187,7 @@ DockerDeviceWidget::DockerDeviceWidget(const IDevice::Ptr &device)
If { dockerDevice->isAutoDetected(), {}, {detectionControls} },
noMargin,
},br,
- Tr::tr("Command Line:"), createLineLabel, br,
+ Tr::tr("Command line:"), createLineLabel, br,
}.attachTo(this);
// clang-format on
diff --git a/src/plugins/git/gitplugin.cpp b/src/plugins/git/gitplugin.cpp
index 693b12cc028..3f8c55b18d4 100644
--- a/src/plugins/git/gitplugin.cpp
+++ b/src/plugins/git/gitplugin.cpp
@@ -10,6 +10,7 @@
#include "gitconstants.h"
#include "giteditor.h"
#include "gitgrep.h"
+#include "gitsettings.h"
#include "gitsubmiteditor.h"
#include "gittr.h"
#include "gitutils.h"
@@ -247,8 +248,14 @@ public:
if (settings().instantBlameIgnoreSpaceChanges()
|| settings().instantBlameIgnoreLineMoves()) {
- result.append(Tr::tr("Note: Ignore whitespace changes or line moves"
- " is enabled in the instant blame settings.
"));
+ result.append(
+ ""
+ //: %1 and %2 are the "ignore whitespace changes" and "ignore line moves" options
+ + Tr::tr("Note: \"%1\" or \"%2\""
+ " is enabled in the instant blame settings.")
+ .arg(GitSettings::trIgnoreWhitespaceChanges(),
+ GitSettings::trIgnoreLineMoves())
+ + "
");
}
return result;
}
diff --git a/src/plugins/git/gitsettings.cpp b/src/plugins/git/gitsettings.cpp
index 79d85566986..cb23f55c9a8 100644
--- a/src/plugins/git/gitsettings.cpp
+++ b/src/plugins/git/gitsettings.cpp
@@ -91,14 +91,12 @@ GitSettings::GitSettings()
Tr::tr("Annotate the current line in the editor with Git \"blame\" output."));
instantBlameIgnoreSpaceChanges.setSettingsKey("GitInstantIgnoreSpaceChanges");
instantBlameIgnoreSpaceChanges.setDefaultValue(false);
- instantBlameIgnoreSpaceChanges.setLabelText(
- Tr::tr("Ignore whitespace changes"));
+ instantBlameIgnoreSpaceChanges.setLabelText(trIgnoreWhitespaceChanges());
instantBlameIgnoreSpaceChanges.setToolTip(
Tr::tr("Finds the commit that introduced the last real code changes to the line."));
instantBlameIgnoreLineMoves.setSettingsKey("GitInstantIgnoreLineMoves");
instantBlameIgnoreLineMoves.setDefaultValue(false);
- instantBlameIgnoreLineMoves.setLabelText(
- Tr::tr("Ignore line moves"));
+ instantBlameIgnoreLineMoves.setLabelText(trIgnoreLineMoves());
instantBlameIgnoreLineMoves.setToolTip(
Tr::tr("Finds the commit that introduced the line before it was moved."));
@@ -187,6 +185,16 @@ FilePath GitSettings::gitExecutable(bool *ok, QString *errorMessage) const
return resolvedBinPath;
}
+QString GitSettings::trIgnoreWhitespaceChanges()
+{
+ return Tr::tr("Ignore whitespace changes");
+}
+
+QString GitSettings::trIgnoreLineMoves()
+{
+ return Tr::tr("Ignore line moves");
+}
+
// GitSettingsPage
class GitSettingsPage final : public Core::IOptionsPage
diff --git a/src/plugins/git/gitsettings.h b/src/plugins/git/gitsettings.h
index f5a83c5e8a9..f6ec650c2e8 100644
--- a/src/plugins/git/gitsettings.h
+++ b/src/plugins/git/gitsettings.h
@@ -45,6 +45,9 @@ public:
mutable bool tryResolve = true;
Utils::FilePath gitExecutable(bool *ok = nullptr, QString *errorMessage = nullptr) const;
+
+ static QString trIgnoreWhitespaceChanges();
+ static QString trIgnoreLineMoves();
};
GitSettings &settings();
diff --git a/src/plugins/help/helpwidget.cpp b/src/plugins/help/helpwidget.cpp
index a2d9eca985a..c79bb052eb5 100644
--- a/src/plugins/help/helpwidget.cpp
+++ b/src/plugins/help/helpwidget.cpp
@@ -229,11 +229,14 @@ HelpWidget::HelpWidget(const Core::Context &context, WidgetStyle style, QWidget
m_toggleSideBarAction->setChecked(false);
cmd = Core::ActionManager::registerAction(m_toggleSideBarAction,
Core::Constants::TOGGLE_LEFT_SIDEBAR, context);
- connect(m_toggleSideBarAction, &QAction::toggled, m_toggleSideBarAction, [this](bool checked) {
- m_toggleSideBarAction->setText(::Core::Tr::tr(
- checked ? Core::Constants::TR_HIDE_LEFT_SIDEBAR
- : Core::Constants::TR_SHOW_LEFT_SIDEBAR));
- });
+ connect(m_toggleSideBarAction,
+ &QAction::toggled,
+ m_toggleSideBarAction,
+ [this](bool checked) {
+ m_toggleSideBarAction->setToolTip(
+ ::Core::Tr::tr(checked ? Core::Constants::TR_HIDE_LEFT_SIDEBAR
+ : Core::Constants::TR_SHOW_LEFT_SIDEBAR));
+ });
addSideBar();
m_toggleSideBarAction->setChecked(m_sideBar->isVisibleTo(this));
connect(m_toggleSideBarAction, &QAction::triggered, m_sideBar, &Core::SideBar::setVisible);
@@ -692,6 +695,8 @@ HelpViewer *HelpWidget::insertViewer(int index, const QUrl &url)
if (currentViewer() == viewer) {
m_addBookmarkAction->setEnabled(isBookmarkable(url));
m_openOnlineDocumentationAction->setEnabled(LocalHelpManager::canOpenOnlineHelp(url));
+ if (m_switchToHelp)
+ m_switchToHelp->setEnabled(url != QUrl("about:blank"));
}
});
connect(viewer, &HelpViewer::forwardAvailable, this, [viewer, this](bool available) {
diff --git a/src/plugins/ios/iosconfigurations.cpp b/src/plugins/ios/iosconfigurations.cpp
index 04ab69b8a25..105ba236eaa 100644
--- a/src/plugins/ios/iosconfigurations.cpp
+++ b/src/plugins/ios/iosconfigurations.cpp
@@ -12,6 +12,8 @@
#include
+#include
+
#include
#include
#include
@@ -31,6 +33,7 @@
#include
#include
+#include
#include
#include
@@ -405,7 +408,8 @@ void IosConfigurations::updateSimulators()
dev = IDevice::ConstPtr(new IosSimulator(devId));
devManager->addDevice(dev);
}
- SimulatorControl::updateAvailableSimulators(this);
+ ExtensionSystem::PluginManager::futureSynchronizer()->addFuture(
+ SimulatorControl::updateAvailableSimulators(this));
}
void IosConfigurations::setDeveloperPath(const FilePath &devPath)
diff --git a/src/plugins/languageclient/client.cpp b/src/plugins/languageclient/client.cpp
index 2fcfc0210fc..7583b065988 100644
--- a/src/plugins/languageclient/client.cpp
+++ b/src/plugins/languageclient/client.cpp
@@ -574,6 +574,8 @@ QString Client::stateString() const
//: language client state
case InitializeRequested: return Tr::tr("initialize requested");
//: language client state
+ case FailedToInitialize: return Tr::tr("failed to initialize");
+ //: language client state
case Initialized: return Tr::tr("initialized");
//: language client state
case ShutdownRequested: return Tr::tr("shutdown requested");
@@ -1696,7 +1698,7 @@ bool ClientPrivate::reset()
void Client::setError(const QString &message)
{
log(message);
- d->m_state = Error;
+ d->m_state = d->m_state < Initialized ? FailedToInitialize : Error;
}
ProgressManager *Client::progressManager()
diff --git a/src/plugins/languageclient/client.h b/src/plugins/languageclient/client.h
index da8c8166644..aba2b996754 100644
--- a/src/plugins/languageclient/client.h
+++ b/src/plugins/languageclient/client.h
@@ -77,6 +77,7 @@ public:
enum State {
Uninitialized,
InitializeRequested,
+ FailedToInitialize,
Initialized,
ShutdownRequested,
Shutdown,
diff --git a/src/plugins/languageclient/languageclient.qbs b/src/plugins/languageclient/languageclient.qbs
index 7f1899927fe..5bb5e1ac11e 100644
--- a/src/plugins/languageclient/languageclient.qbs
+++ b/src/plugins/languageclient/languageclient.qbs
@@ -67,5 +67,10 @@ QtcPlugin {
"snippet.h",
]
+ Properties {
+ condition: qbs.toolchain.contains("mingw")
+ cpp.cxxFlags: "-Wa,-mbig-obj"
+ }
+
Export { Depends { name: "LanguageServerProtocol" } }
}
diff --git a/src/plugins/languageclient/languageclientmanager.cpp b/src/plugins/languageclient/languageclientmanager.cpp
index c05b84db4aa..bb655e2d8f8 100644
--- a/src/plugins/languageclient/languageclientmanager.cpp
+++ b/src/plugins/languageclient/languageclientmanager.cpp
@@ -168,11 +168,12 @@ void LanguageClientManager::clientFinished(Client *client)
const bool unexpectedFinish = client->state() != Client::Shutdown
&& client->state() != Client::ShutdownRequested;
+ const QList &clientDocs
+ = managerInstance->m_clientForDocument.keys(client);
if (unexpectedFinish) {
if (!PluginManager::isShuttingDown()) {
- const QList &clientDocs
- = managerInstance->m_clientForDocument.keys(client);
- if (client->state() == Client::Initialized && client->reset()) {
+ const bool shouldRestart = client->state() > Client::FailedToInitialize;
+ if (shouldRestart && client->reset()) {
qCDebug(Log) << "restart unexpectedly finished client: " << client->name() << client;
client->log(
Tr::tr("Unexpectedly finished. Restarting in %1 seconds.").arg(restartTimeoutS));
@@ -186,10 +187,14 @@ void LanguageClientManager::clientFinished(Client *client)
}
qCDebug(Log) << "client finished unexpectedly: " << client->name() << client;
client->log(Tr::tr("Unexpectedly finished."));
- for (TextEditor::TextDocument *document : clientDocs)
- managerInstance->m_clientForDocument.remove(document);
}
}
+
+ if (unexpectedFinish || !QTC_GUARD(clientDocs.isEmpty())) {
+ for (TextEditor::TextDocument *document : clientDocs)
+ openDocumentWithClient(document, nullptr);
+ }
+
deleteClient(client);
if (isShutdownFinished())
emit managerInstance->shutdownFinished();
diff --git a/src/plugins/languageclient/languageclientsettings.cpp b/src/plugins/languageclient/languageclientsettings.cpp
index 95d5b1a2e1b..7b6c4a41bfe 100644
--- a/src/plugins/languageclient/languageclientsettings.cpp
+++ b/src/plugins/languageclient/languageclientsettings.cpp
@@ -1117,10 +1117,10 @@ ProjectSettingsWidget::ProjectSettingsWidget(ProjectExplorer::Project *project)
auto layout = new QVBoxLayout;
setLayout(layout);
- auto group = new QGroupBox(Tr::tr("Language Server Workspace Configuration"));
+ auto group = new QGroupBox(Tr::tr("Workspace Configuration"));
group->setLayout(new QVBoxLayout);
group->layout()->addWidget(new QLabel(Tr::tr(
- "Additional json configuration sent to all running language servers for this project.\n"
+ "Additional JSON configuration sent to all running language servers for this project.\n"
"See the documentation of the specific language server for valid settings.")));
group->layout()->addWidget(editor->widget());
layout->addWidget(group);
diff --git a/src/plugins/mcusupport/CMakeLists.txt b/src/plugins/mcusupport/CMakeLists.txt
index f52c31b82ab..aa8b4f2bf1b 100644
--- a/src/plugins/mcusupport/CMakeLists.txt
+++ b/src/plugins/mcusupport/CMakeLists.txt
@@ -1,6 +1,6 @@
add_qtc_plugin(McuSupport
DEPENDS Qt::Core QmlJS
- PLUGIN_DEPENDS Core BareMetal ProjectExplorer Debugger CMakeProjectManager QtSupport
+ PLUGIN_DEPENDS Core BareMetal ProjectExplorer Debugger CMakeProjectManager QmlJSTools QtSupport
SOURCES
mcukitaspect.cpp mcukitaspect.h
mcusupport.qrc
diff --git a/src/plugins/mcusupport/mcusupport.qbs b/src/plugins/mcusupport/mcusupport.qbs
index b14c6a90a23..e944ba5ce97 100644
--- a/src/plugins/mcusupport/mcusupport.qbs
+++ b/src/plugins/mcusupport/mcusupport.qbs
@@ -14,6 +14,7 @@ QtcPlugin {
Depends { name: "Debugger" }
Depends { name: "CMakeProjectManager" }
Depends { name: "QmlJS" }
+ Depends { name: "QmlJSTools" }
Depends { name: "QtSupport" }
Depends { name: "qtc_gtest_gmock"; condition: qtc.withPluginTests; required: false }
diff --git a/src/plugins/mcusupport/test/unittest.cpp b/src/plugins/mcusupport/test/unittest.cpp
index 5692ceee751..13ed66f8035 100644
--- a/src/plugins/mcusupport/test/unittest.cpp
+++ b/src/plugins/mcusupport/test/unittest.cpp
@@ -954,34 +954,34 @@ void McuSupportTest::test_legacy_createTargetWithToolchainPackages_data()
QTest::newRow("armgcc_mimxrt1050_evk_freertos_json")
<< armgcc_mimxrt1050_evk_freertos_json << armGccToolchainFilePath
- << armGccToolchainFileUnexpandedPath << armGccDir << armGccDirectorySetting
+ << armGccToolchainFileUnexpandedPath << armGccDir << keyFromString(armGccDirectorySetting)
<< QStringList{armGccVersion};
QTest::newRow("armgcc_mimxrt1064_evk_freertos_json")
<< armgcc_mimxrt1064_evk_freertos_json << armGccToolchainFilePath
- << armGccToolchainFileUnexpandedPath << armGccDir << armGccDirectorySetting
+ << armGccToolchainFileUnexpandedPath << armGccDir << keyFromString(armGccDirectorySetting)
<< QStringList{armGccVersion};
QTest::newRow("armgcc_mimxrt1170_evk_freertos_json")
<< armgcc_mimxrt1170_evk_freertos_json << armGccToolchainFilePath
- << armGccToolchainFileUnexpandedPath << armGccDir << armGccDirectorySetting
+ << armGccToolchainFileUnexpandedPath << armGccDir << keyFromString(armGccDirectorySetting)
<< QStringList{armGccVersion};
QTest::newRow("armgcc_stm32h750b_discovery_baremetal_json")
<< armgcc_stm32h750b_discovery_baremetal_json << armGccToolchainFilePath
- << armGccToolchainFileUnexpandedPath << armGccDir << armGccDirectorySetting
+ << armGccToolchainFileUnexpandedPath << armGccDir << keyFromString(armGccDirectorySetting)
<< QStringList{armGccVersion};
QTest::newRow("armgcc_stm32f769i_discovery_freertos_json")
<< armgcc_stm32f769i_discovery_freertos_json << armGccToolchainFilePath
- << armGccToolchainFileUnexpandedPath << armGccDir << armGccDirectorySetting
+ << armGccToolchainFileUnexpandedPath << armGccDir << keyFromString(armGccDirectorySetting)
<< QStringList{armGccVersion};
QTest::newRow("iar_stm32f469i_discovery_baremetal_json")
<< iar_stm32f469i_discovery_baremetal_json << iarToolchainFilePath
- << iarToolchainFileUnexpandedPath << iarDir << iarSetting << iarVersions;
+ << iarToolchainFileUnexpandedPath << iarDir << keyFromString(iarSetting) << iarVersions;
QTest::newRow("iar_mimxrt1064_evk_freertos_json")
<< iar_mimxrt1064_evk_freertos_json << iarToolchainFilePath
- << iarToolchainFileUnexpandedPath << iarDir << iarSetting << iarVersions;
+ << iarToolchainFileUnexpandedPath << iarDir << keyFromString(iarSetting) << iarVersions;
QTest::newRow("ghs_rh850_d1m1a_baremetal_json")
<< ghs_rh850_d1m1a_baremetal_json << greenhillToolchainFilePath
- << greenhillToolchainFileUnexpandedPath << greenhillCompilerDir << greenhillSetting
- << greenhillVersions;
+ << greenhillToolchainFileUnexpandedPath << greenhillCompilerDir
+ << keyFromString(greenhillSetting) << greenhillVersions;
}
void McuSupportTest::test_legacy_createTargetWithToolchainPackages()
@@ -1145,22 +1145,22 @@ void McuSupportTest::test_legacy_createFreeRtosPackage_data()
QTest::newRow("armgcc_mimxrt1050_evk_freertos_json")
<< armgcc_mimxrt1050_evk_freertos_json << QStringList{boardSdkVersion}
- << QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1050)
+ << keyFromString(QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1050))
<< FilePath::fromUserInput(boardSdkDir) / freeRtosNxpPathSuffix
<< FilePath::fromUserInput(freeRtosDetectionPath);
QTest::newRow("armgcc_mimxrt1064_evk_freertos_json")
<< armgcc_mimxrt1064_evk_freertos_json << QStringList{boardSdkVersion}
- << QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1064)
+ << keyFromString(QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1064))
<< FilePath::fromUserInput(boardSdkDir) / freeRtosNxpPathSuffix
<< FilePath::fromUserInput(freeRtosDetectionPath);
QTest::newRow("iar_mimxrt1064_evk_freertos_json")
<< iar_mimxrt1064_evk_freertos_json << QStringList{boardSdkVersion}
- << QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1064)
+ << keyFromString(QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(nxp1064))
<< FilePath::fromUserInput(boardSdkDir) / freeRtosNxpPathSuffix
<< FilePath::fromUserInput(freeRtosDetectionPath);
QTest::newRow("armgcc_stm32f769i_discovery_freertos_json")
<< armgcc_stm32f769i_discovery_freertos_json << QStringList{"1.16.0"}
- << QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(stm32f7)
+ << keyFromString(QString{Legacy::Constants::SETTINGS_KEY_FREERTOS_PREFIX}.append(stm32f7))
<< FilePath::fromUserInput(boardSdkDir) / freeRtosStmPathSuffix
<< FilePath::fromUserInput(freeRtosDetectionPath);
}
@@ -1495,7 +1495,7 @@ void McuSupportTest::test_legacy_createThirdPartyPackage_data()
QTest::addColumn("json");
QTest::addColumn("path");
QTest::addColumn("defaultPath");
- QTest::addColumn("setting");
+ QTest::addColumn("setting");
QTest::addColumn("cmakeVar");
QTest::addColumn("envVar");
QTest::addColumn("label");
@@ -1504,42 +1504,42 @@ void McuSupportTest::test_legacy_createThirdPartyPackage_data()
QTest::newRow("armgcc_mimxrt1050_evk_freertos_json mcuXpresso")
<< PackageCreator{[this]() { return Legacy::createMcuXpressoIdePackage(settingsMockPtr); }}
<< armgcc_mimxrt1050_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
<< xpressoIdeDetectionPath;
QTest::newRow("armgcc_mimxrt1064_evk_freertos_json mcuXpresso")
<< PackageCreator{[this]() { return Legacy::createMcuXpressoIdePackage(settingsMockPtr); }}
<< armgcc_mimxrt1064_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
- << xpressoIdeDetectionPath;
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar
+ << xpressoIdeLabel << xpressoIdeDetectionPath;
QTest::newRow("armgcc_mimxrt1170_evk_freertos_json mcuXpresso")
<< PackageCreator{[this]() { return Legacy::createMcuXpressoIdePackage(settingsMockPtr); }}
<< armgcc_mimxrt1170_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
- << xpressoIdeDetectionPath;
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar
+ << xpressoIdeLabel << xpressoIdeDetectionPath;
QTest::newRow("armgcc_stm32h750b_discovery_baremetal_json stmCubeProgrammer")
<< PackageCreator{[this]() {
return Legacy::createStm32CubeProgrammerPackage(settingsMockPtr);
}}
<< armgcc_stm32h750b_discovery_baremetal_json << stmCubeProgrammerPath
- << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty
+ << stmCubeProgrammerPath << keyFromString(stmCubeProgrammerSetting) << empty << empty
<< stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath;
QTest::newRow("armgcc_stm32f769i_discovery_freertos_json stmCubeProgrammer")
<< PackageCreator{[this]() {
return Legacy::createStm32CubeProgrammerPackage(settingsMockPtr);
}}
<< armgcc_stm32f769i_discovery_freertos_json << stmCubeProgrammerPath
- << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty
+ << stmCubeProgrammerPath << keyFromString(stmCubeProgrammerSetting) << empty << empty
<< stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath;
QTest::newRow("ghs_rh850_d1m1a_baremetal_json renesasProgrammer")
<< PackageCreator{[this]() {
return Legacy::createRenesasProgrammerPackage(settingsMockPtr);
}}
- << ghs_rh850_d1m1a_baremetal_json << empty << empty << renesasProgrammerSetting
- << renesasProgrammerCmakeVar << renesasProgrammerEnvVar << renesasProgrammerLabel
- << renesasProgrammerDetectionPath;
+ << ghs_rh850_d1m1a_baremetal_json << empty << empty
+ << keyFromString(renesasProgrammerSetting) << renesasProgrammerCmakeVar
+ << renesasProgrammerEnvVar << renesasProgrammerLabel << renesasProgrammerDetectionPath;
}
void McuSupportTest::test_legacy_createThirdPartyPackage()
@@ -1592,33 +1592,34 @@ void McuSupportTest::test_createThirdPartyPackage_data()
QTest::newRow("armgcc_mimxrt1050_evk_freertos_json mcuXpresso")
<< armgcc_mimxrt1050_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
- << xpressoIdeDetectionPath;
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar
+ << xpressoIdeLabel << xpressoIdeDetectionPath;
QTest::newRow("armgcc_mimxrt1064_evk_freertos_json mcuXpresso")
<< armgcc_mimxrt1064_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
- << xpressoIdeDetectionPath;
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar
+ << xpressoIdeLabel << xpressoIdeDetectionPath;
QTest::newRow("armgcc_mimxrt1170_evk_freertos_json mcuXpresso")
<< armgcc_mimxrt1170_evk_freertos_json << xpressoIdePath << xpressoIdePath
- << xpressoIdeSetting << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
+ << keyFromString(xpressoIdeSetting) << xpressoIdeCmakeVar << xpressoIdeEnvVar << xpressoIdeLabel
<< xpressoIdeDetectionPath;
QTest::newRow("armgcc_stm32h750b_discovery_baremetal_json stmCubeProgrammer")
<< armgcc_stm32h750b_discovery_baremetal_json << stmCubeProgrammerPath
- << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty
+ << stmCubeProgrammerPath << keyFromString(stmCubeProgrammerSetting) << empty << empty
<< stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath;
QTest::newRow("armgcc_stm32f769i_discovery_freertos_json stmCubeProgrammer")
<< armgcc_stm32f769i_discovery_freertos_json << stmCubeProgrammerPath
- << stmCubeProgrammerPath << stmCubeProgrammerSetting << empty << empty
+ << stmCubeProgrammerPath << keyFromString(stmCubeProgrammerSetting) << empty << empty
<< stmCubeProgrammerLabel << stmCubeProgrammerDetectionPath;
QTest::newRow("ghs_rh850_d1m1a_baremetal_json renesasProgrammer")
<< ghs_rh850_d1m1a_baremetal_json << renesasProgrammerDefaultPath << empty
- << "FlashProgrammerPath" << renesasProgrammerCmakeVar << "RenesasFlashProgrammer_PATH"
- << renesasProgrammerLabel << renesasProgrammerDetectionPath;
+ << keyFromString("FlashProgrammerPath") << renesasProgrammerCmakeVar
+ << "RenesasFlashProgrammer_PATH" << renesasProgrammerLabel
+ << renesasProgrammerDetectionPath;
}
void McuSupportTest::test_createThirdPartyPackage()
diff --git a/src/plugins/projectexplorer/buildmanager.cpp b/src/plugins/projectexplorer/buildmanager.cpp
index dcb0bdf87ff..6c74b5cf828 100644
--- a/src/plugins/projectexplorer/buildmanager.cpp
+++ b/src/plugins/projectexplorer/buildmanager.cpp
@@ -106,7 +106,8 @@ static const QList buildConfigsForSelection(const Target *
}
static int queue(const QList &projects, const QList