diff --git a/dist/changelog/changes-12.0.0.md b/dist/changelog/changes-12.0.0.md
index 6e96ada76bb..dd6606dccaf 100644
--- a/dist/changelog/changes-12.0.0.md
+++ b/dist/changelog/changes-12.0.0.md
@@ -264,6 +264,8 @@ Projects
* Added parsing the dependencies from `vcpkg.json` manifest files
* Improved the addition of dependencies to `vcpkg.json`
+([Documentation](https://doc-snapshots.qt.io/qtcreator-12.0/creator-how-to-edit-vcpkg-manifest-files.html))
+
### Qt Safe Renderer
* Added a wizard for Qt Safe Renderer 2.1 and later
diff --git a/doc/qtcreator/images/icons/cmake.png b/doc/qtcreator/images/icons/cmake.png
new file mode 100644
index 00000000000..bc68b8b467d
Binary files /dev/null and b/doc/qtcreator/images/icons/cmake.png differ
diff --git a/doc/qtcreator/images/icons/vcpkg.png b/doc/qtcreator/images/icons/vcpkg.png
new file mode 100644
index 00000000000..5a0c40aa64d
Binary files /dev/null and b/doc/qtcreator/images/icons/vcpkg.png differ
diff --git a/doc/qtcreator/images/qt-creator-beautifier-options-general.png b/doc/qtcreator/images/qt-creator-beautifier-options-general.png
deleted file mode 100644
index 5a33d6c7abc..00000000000
Binary files a/doc/qtcreator/images/qt-creator-beautifier-options-general.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-eblink.png b/doc/qtcreator/images/qtcreator-baremetal-eblink.png
deleted file mode 100644
index c372292b524..00000000000
Binary files a/doc/qtcreator/images/qtcreator-baremetal-eblink.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-eblink.webp b/doc/qtcreator/images/qtcreator-baremetal-eblink.webp
new file mode 100644
index 00000000000..bdd75bd04f6
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-baremetal-eblink.webp differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-jlink.png b/doc/qtcreator/images/qtcreator-baremetal-jlink.png
deleted file mode 100644
index 1e221766dde..00000000000
Binary files a/doc/qtcreator/images/qtcreator-baremetal-jlink.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-jlink.webp b/doc/qtcreator/images/qtcreator-baremetal-jlink.webp
new file mode 100644
index 00000000000..5d1fd1f933a
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-baremetal-jlink.webp differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-openocd.png b/doc/qtcreator/images/qtcreator-baremetal-openocd.png
deleted file mode 100644
index d84b91ceec9..00000000000
Binary files a/doc/qtcreator/images/qtcreator-baremetal-openocd.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-openocd.webp b/doc/qtcreator/images/qtcreator-baremetal-openocd.webp
new file mode 100644
index 00000000000..2f04c4f8b19
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-baremetal-openocd.webp differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-stlink.png b/doc/qtcreator/images/qtcreator-baremetal-stlink.png
deleted file mode 100644
index f759eb355be..00000000000
Binary files a/doc/qtcreator/images/qtcreator-baremetal-stlink.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-baremetal-stlink.webp b/doc/qtcreator/images/qtcreator-baremetal-stlink.webp
new file mode 100644
index 00000000000..3e2502e1e78
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-baremetal-stlink.webp differ
diff --git a/doc/qtcreator/images/qtcreator-gdb-extended-options.png b/doc/qtcreator/images/qtcreator-gdb-extended-options.png
deleted file mode 100644
index 10e22f235c1..00000000000
Binary files a/doc/qtcreator/images/qtcreator-gdb-extended-options.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-gdb-options.png b/doc/qtcreator/images/qtcreator-gdb-options.png
deleted file mode 100644
index e1ec43cc37b..00000000000
Binary files a/doc/qtcreator/images/qtcreator-gdb-options.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-options-environment-system.png b/doc/qtcreator/images/qtcreator-options-environment-system.png
deleted file mode 100644
index 9d6cb599c12..00000000000
Binary files a/doc/qtcreator/images/qtcreator-options-environment-system.png and /dev/null differ
diff --git a/doc/qtcreator/images/qtcreator-preferences-beautifier-general.webp b/doc/qtcreator/images/qtcreator-preferences-beautifier-general.webp
new file mode 100644
index 00000000000..f416df0f347
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-preferences-beautifier-general.webp differ
diff --git a/doc/qtcreator/images/qtcreator-preferences-debugger-gdb.webp b/doc/qtcreator/images/qtcreator-preferences-debugger-gdb.webp
new file mode 100644
index 00000000000..9ac81bce223
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-preferences-debugger-gdb.webp differ
diff --git a/doc/qtcreator/images/qtcreator-preferences-environment-system.webp b/doc/qtcreator/images/qtcreator-preferences-environment-system.webp
new file mode 100644
index 00000000000..9b86064da52
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-preferences-environment-system.webp differ
diff --git a/doc/qtcreator/images/qtcreator-preferences-testing-googletest.webp b/doc/qtcreator/images/qtcreator-preferences-testing-googletest.webp
index 1a60a66ae90..4d75ee1c448 100644
Binary files a/doc/qtcreator/images/qtcreator-preferences-testing-googletest.webp and b/doc/qtcreator/images/qtcreator-preferences-testing-googletest.webp differ
diff --git a/doc/qtcreator/images/qtcreator-vcpkg-cmake-config.webp b/doc/qtcreator/images/qtcreator-vcpkg-cmake-config.webp
new file mode 100644
index 00000000000..fd5be5bb3cc
Binary files /dev/null and b/doc/qtcreator/images/qtcreator-vcpkg-cmake-config.webp differ
diff --git a/doc/qtcreator/images/qtcreator-vcpkg-manifest-file-editor.webp b/doc/qtcreator/images/qtcreator-vcpkg-manifest-file-editor.webp
index 1d341a081f4..485e0ea974e 100644
Binary files a/doc/qtcreator/images/qtcreator-vcpkg-manifest-file-editor.webp and b/doc/qtcreator/images/qtcreator-vcpkg-manifest-file-editor.webp differ
diff --git a/doc/qtcreator/images/qtcreator-vcpkg-package-selector.webp b/doc/qtcreator/images/qtcreator-vcpkg-package-selector.webp
index 97295b6b485..966bc3dbc43 100644
Binary files a/doc/qtcreator/images/qtcreator-vcpkg-package-selector.webp and b/doc/qtcreator/images/qtcreator-vcpkg-package-selector.webp differ
diff --git a/doc/qtcreator/src/baremetal/creator-baremetal-dev.qdoc b/doc/qtcreator/src/baremetal/creator-baremetal-dev.qdoc
index 722cf8d89ba..368e313851a 100644
--- a/doc/qtcreator/src/baremetal/creator-baremetal-dev.qdoc
+++ b/doc/qtcreator/src/baremetal/creator-baremetal-dev.qdoc
@@ -59,8 +59,9 @@
\section1 Specifying Settings for Debug Server Providers
To create connections to bare metal devices using a debug server provider,
- select \preferences > \uicontrol Devices
- > \uicontrol {Bare Metal} > \uicontrol Add > \uicontrol Default.
+ select \preferences > \uicontrol Devices > \uicontrol {Bare Metal} >
+ \uicontrol Add.
+
The available settings depend on the debug server provider.
\section2 EBlink
@@ -68,7 +69,7 @@
\l{https://github.com/EmBitz/EBlink}{EBlink} is an ARM Cortex-M debug tool
that supports squirrel scripting, live variables, and hot-plugging.
- \image qtcreator-baremetal-eblink.png "Bare metal device preferences for EBlink"
+ \image qtcreator-baremetal-eblink.webp {Bare metal device preferences for EBlink}
To specify settings for \EBlink:
@@ -105,7 +106,7 @@
\l{https://www.segger.com/products/debug-probes/j-link/}{J-Link} is a line
of debug probes by Segger.
- \image qtcreator-baremetal-jlink.png "Bare metal device preferences for J-Link"
+ \image qtcreator-baremetal-jlink.webp "Bare metal device preferences for J-Link"
To specify settings for J-Link debug probes:
@@ -137,7 +138,7 @@
(JTAG) facility. It enables source level debugging with the GDB compiled
for the ARM architecture.
- \image qtcreator-baremetal-openocd.png "Bare metal device preferences for OpenOCD"
+ \image qtcreator-baremetal-openocd.webp "Bare metal device preferences for OpenOCD"
To specify settings for \OpenOCD:
@@ -163,7 +164,7 @@
\l{https://www.st.com/en/development-tools/stm32-programmers.html#products}
{ST-LINK Utility} is used for programming STM32 microcontrollers.
- \image qtcreator-baremetal-stlink.png "Bare metal device preferences for St-Link"
+ \image qtcreator-baremetal-stlink.webp "Bare metal device preferences for St-Link"
To specify settings for St-Link:
@@ -202,7 +203,7 @@
\image qtcreator-baremetal-uvision-simulator.png "Bare metal device preferences for uVision Simulator"
- To specify settings for uVision Simulator or uVision St-Link Debugger:
+ To specify settings for uVision Simulator:
\list 1
@@ -215,11 +216,11 @@
\endlist
- \section3 uVision St-Link Debugger
+ \section3 uVision St-Link or JLink Debugger
\image qtcreator-baremetal-uvision-st-link.png "Bare metal device preferences for uVision St-Link"
- To specify settings for uVision St-Link Debugger:
+ To specify settings for uVision St-Link or JLink Debugger:
\list 1
diff --git a/doc/qtcreator/src/baremetal/creator-baremetal-settings.qdocinc b/doc/qtcreator/src/baremetal/creator-baremetal-settings.qdocinc
index cce6b41d6d4..ea35fe9855b 100644
--- a/doc/qtcreator/src/baremetal/creator-baremetal-settings.qdocinc
+++ b/doc/qtcreator/src/baremetal/creator-baremetal-settings.qdocinc
@@ -1,4 +1,4 @@
-// Copyright (C) 2020 The Qt Company Ltd.
+// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
//! [baremetal-common]
@@ -6,6 +6,8 @@
\li In the \uicontrol Name field, enter a name for the connection.
\li In the \uicontrol {Startup mode} field, select the mode to start
the debug server provider in.
+ \li In the \uicontrol {Peripheral description file} field, specify a path to
+ a file that describes the peripherals on the device.
\li In the \uicontrol Host field, select the host name and port number
to connect to the debug server provider.
\li In the \uicontrol {Executable file} field, enter the path to the
diff --git a/doc/qtcreator/src/debugger/creator-only/creator-debugger-settings.qdoc b/doc/qtcreator/src/debugger/creator-only/creator-debugger-settings.qdoc
index 06b8d05bc52..4583460cb42 100644
--- a/doc/qtcreator/src/debugger/creator-only/creator-debugger-settings.qdoc
+++ b/doc/qtcreator/src/debugger/creator-only/creator-debugger-settings.qdoc
@@ -53,7 +53,7 @@
To specify settings for managing the GDB process, select \preferences >
\uicontrol Debugger > \uicontrol GDB.
- \image qtcreator-gdb-options.png "GDB preferences"
+ \image qtcreator-preferences-debugger-gdb.webp {GDB preferences}
To specify a timeout for terminating non-responsive GDB processes, set the
number of seconds to wait in the \uicontrol {GDB timeout} field. The default
@@ -111,6 +111,8 @@
To execute arbitrary Python scripts, use
\c {python execfile('/path/to/script.py')}.
+ \section2 Extended GDB Settings
+
The settings in the \uicontrol Extended group give access to advanced
or experimental functions of GDB.
Enabling them may negatively impact your debugging experience, so use
diff --git a/doc/qtcreator/src/debugger/creator-only/creator-debugger.qdoc b/doc/qtcreator/src/debugger/creator-only/creator-debugger.qdoc
index fe61cd19eae..a39e561badd 100644
--- a/doc/qtcreator/src/debugger/creator-only/creator-debugger.qdoc
+++ b/doc/qtcreator/src/debugger/creator-only/creator-debugger.qdoc
@@ -1368,7 +1368,7 @@
\uicontrol Debugger > \uicontrol GDB > \uicontrol {Load system GDB pretty
printers}. For more information, see \l{Specifying GDB Settings}.
- \image qtcreator-gdb-options.png {GDB preferences}
+ \image qtcreator-preferences-debugger-gdb.webp {GDB preferences}
\section2 Customizing Built-In Debugging Helpers
@@ -2036,7 +2036,7 @@
when loading the same binary in the future. Select \preferences >
\uicontrol Debugger > \uicontrol GDB > \uicontrol {Use automatic symbol cache}.
- \image qtcreator-gdb-options.png {GDB preferences}
+ \image qtcreator-preferences-debugger-gdb.webp {GDB preferences}
\section2 Minimizing Number of Breakpoints
diff --git a/doc/qtcreator/src/editors/creator-only/creator-beautifier.qdoc b/doc/qtcreator/src/editors/creator-only/creator-beautifier.qdoc
index 84eef9dcc0f..0f0a2d8e67f 100644
--- a/doc/qtcreator/src/editors/creator-only/creator-beautifier.qdoc
+++ b/doc/qtcreator/src/editors/creator-only/creator-beautifier.qdoc
@@ -1,4 +1,4 @@
-// Copyright (C) 2021 The Qt Company Ltd.
+// Copyright (C) 2023 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
// **********************************************************************
@@ -57,11 +57,11 @@
\li Select \preferences >
\uicontrol Beautifier to specify settings for beautifying files.
- \li Select the \uicontrol {Enable auto format on file save} check box to
+ \li Select the \uicontrol {Automatic formatting on file save} check box to
automatically beautify files when you save them using the tool you
select in the \uicontrol Tool field.
- \image qt-creator-beautifier-options-general.png "General Beautifier preferences"
+ \image qtcreator-preferences-beautifier-general.webp {General Beautifier preferences}
\li In the \uicontrol {Restrict to MIME types} field, define the MIME
types of the files to beautify, separated by semicolons. Leave the
diff --git a/doc/qtcreator/src/howto/creator-only/creator-autotest.qdoc b/doc/qtcreator/src/howto/creator-only/creator-autotest.qdoc
index 8d72d3ba896..544c3274aa0 100644
--- a/doc/qtcreator/src/howto/creator-only/creator-autotest.qdoc
+++ b/doc/qtcreator/src/howto/creator-only/creator-autotest.qdoc
@@ -482,6 +482,12 @@
To run disabled tests, select the \uicontrol {Run disabled tests} check box.
+ To turn assertion failures into C++ exceptions, select the
+ \uicontrol {Throw on failure} check box.
+
+ To turn failures into debugger breakpoints, select the
+ \uicontrol {Break on failure while debugging} check box.
+
To run several iterations of the tests, select the \uicontrol {Repeat tests}
check box and enter the number of times to run the tests in the
\uicontrol Iterations field. To make sure that the tests are independent and
@@ -490,8 +496,6 @@
randomizer in the \uicontrol Seed field. The value 0 generates a seed
based on the current timestamp.
- To turn failures into debugger breakpoints, select the
- \uicontrol {Break on failure while debugging} check box.
To group Google tests by using a GTest filter, select
\uicontrol {GTest Filter} in the \uicontrol {Group mode} field,
diff --git a/doc/qtcreator/src/howto/creator-only/creator-how-tos.qdoc b/doc/qtcreator/src/howto/creator-only/creator-how-tos.qdoc
index 94a0f81b0fa..383537b270e 100644
--- a/doc/qtcreator/src/howto/creator-only/creator-how-tos.qdoc
+++ b/doc/qtcreator/src/howto/creator-only/creator-how-tos.qdoc
@@ -412,7 +412,7 @@
\list 1
\li Select \preferences > \uicontrol Environment > \uicontrol System.
- \image qtcreator-options-environment-system.png {System preferences}
+ \image qtcreator-preferences-environment-system.webp {System preferences}
\li In \uicontrol {Maximum number of entries in "Recent Files"}, set
the number of files to show.
\endlist
diff --git a/doc/qtcreator/src/howto/creator-only/creator-vcpkg.qdoc b/doc/qtcreator/src/howto/creator-only/creator-vcpkg.qdoc
index dd498be5db8..2a639e1808f 100644
--- a/doc/qtcreator/src/howto/creator-only/creator-vcpkg.qdoc
+++ b/doc/qtcreator/src/howto/creator-only/creator-vcpkg.qdoc
@@ -7,7 +7,7 @@
\ingroup creator-reference-build-systems
- \title Managing Packages with vcpkg
+ \title vcpkg Package Manager
\brief The experimental vcpkg plugin integrates the vcpkg C/C++ package
manager into \QC.
@@ -36,16 +36,31 @@
Select \inlineimage icons/online.png
to download vcpkg if you have not installed it yet.
- \section1 Creating vcpkg Manifest Files
+ \sa {Create vcpkg manifest files}, {Edit vcpkg manifest files},
+ {Enable and disable plugins}
+*/
+
+/*!
+ \page creator-how-to-create-vcpkg-manifest-files.html
+ \previouspage creator-how-tos.html
+
+ \ingroup creator-how-to-projects
+
+ \title Create vcpkg manifest files
To create a new vcpkg package manager manifest (vcpkg.json) file:
\list 1
\li Select \uicontrol File > \uicontrol {New File} >
- \uicontrol Vcpkg.
- \image qtcreator-file-new-file-vcpkg-manifest-file.webp {vcpkg.json Manifest File wizard page}
+ \uicontrol vcpkg > \uicontrol {vcpkg.json Manifest File} >
+ \uicontrol Choose to open the \uicontrol Location dialog.
+ \li In \uicontrol {File name}, enter a name for the manifest file.
+ \li In \uicontrol Path, enter the path for the manifest file.
+ \li Select \uicontrol Next to open the
+ \uicontrol {vcpkg.json Manifest File} dialog.
+ \image qtcreator-file-new-file-vcpkg-manifest-file.webp {vcpkg.json Manifest File dialog}
\li In \uicontrol Name, enter a name for the manifest file.
- \li In \uicontrol Version, enter a version number for the file.
+ \li In \uicontrol {Version string}, enter a version number for the file.
\li In \uicontrol Dependencies, enter the packages to manage.
You can add packages later in a manifest editor.
@@ -57,27 +72,51 @@
The wizard automatically adds the vcpkg.json file to the CMakeLists.txt file
of the project.
- \section1 Selecting Packages to Manage
+ \sa {vcpkg Package Manager}, {Edit vcpkg manifest files}
+*/
+
+/*!
+ \page creator-how-to-edit-vcpkg-manifest-files.html
+ \previouspage creator-how-tos.html
+
+ \ingroup creator-how-to-build
+
+ \title Edit vcpkg manifest files
When you open a vcpkg.json file, it opens in the manifest file editor:
\image qtcreator-vcpkg-manifest-file-editor.webp {vcpkg.json file in the manifest file editor}
+ \section1 Add packages to manage
+
To add a package to your project:
\list 1
- \li Place the cursor on the line where you want to add a package.
- \li Select the \inlineimage icons/zoom.png
- (\uicontrol {Search Package}) button.
- \image qtcreator-vcpkg-package-selector.webp {Package selector dialog}
+ \li Select the \inlineimage icons/vcpkg.png
+ (\uicontrol {Add vcpkg Package}) button on the manifest editor
+ toolbar.
+ \image qtcreator-vcpkg-package-selector.webp {Add vcpkg Package dialog}
\li Select the package to add to your project.
\li Select \uicontrol OK to return to the editor.
\li Repeat to add more packages.
\endlist
- To set the path to the directory where you installed vcpkg, select
- \inlineimage icons/settings.png
- (\uicontrol Configure) on the editor toolbar.
+ \section1 Generate code for CMake configuration files
- \sa {Enable and disable plugins}
+ To generate sample CMake code to copy to the CMakeLists.text file:
+
+ \list 1
+ \li Select the \inlineimage icons/cmake.png (\uicontrol {CMake Code})
+ button on the manifest editor toolbar.
+ \image qtcreator-vcpkg-cmake-config.webp {CMake Code dialog}
+ \li Select the example code you need and copy-paste it to the
+ CMakeLists.txt file.
+ \endlist
+
+ \section1 Set the path to vcpkg
+
+ To set the path to the directory where you installed vcpkg, select
+ \inlineimage icons/settings.png (\uicontrol Configure) on the editor toolbar.
+
+ \sa {vcpkg Package Manager}, {Create vcpkg manifest files}
*/
diff --git a/doc/qtcreator/src/projects/creator-only/creator-files-creating.qdoc b/doc/qtcreator/src/projects/creator-only/creator-files-creating.qdoc
index 21c189a6986..4d9b8b54b9f 100644
--- a/doc/qtcreator/src/projects/creator-only/creator-files-creating.qdoc
+++ b/doc/qtcreator/src/projects/creator-only/creator-files-creating.qdoc
@@ -65,8 +65,7 @@
\li Class and script files for Python projects.
\row
\li \uicontrol {vcpkg} (experimental)
- \li \l {Managing Packages with vcpkg}{vcpkg package manager} manifest
- files (vcpkg.json).
+ \li vcpkg package manager manifest files (vcpkg.json).
\row
\li \uicontrol {Nim} (experimental)
\li Empty Nim source and script files.
@@ -74,7 +73,7 @@
\sa {Create compiler explorer sessions}, {Create C++ classes},
{Create OpenGL fragment and vertex shaders}, {Create resource files},
- {Use project wizards}
+ {Create vcpkg manifest files}, {Use project wizards}
*/
/*!
diff --git a/doc/qtcreator/src/projects/creator-only/creator-projects-settings-environment.qdoc b/doc/qtcreator/src/projects/creator-only/creator-projects-settings-environment.qdoc
index dd3534bb904..4459d0b9063 100644
--- a/doc/qtcreator/src/projects/creator-only/creator-projects-settings-environment.qdoc
+++ b/doc/qtcreator/src/projects/creator-only/creator-projects-settings-environment.qdoc
@@ -23,7 +23,7 @@
\uicontrol Environment > \uicontrol System, and then select
\uicontrol Change in the \uicontrol Environment field.
- \image qtcreator-options-environment-system.png "Environment preferences System tab"
+ \image qtcreator-preferences-environment-system.webp "Environment preferences System tab"
In addition, you can specify custom environment variables in the
\uicontrol {Project Settings} > \uicontrol Environment settings.
diff --git a/doc/qtcreator/src/user-interface/creator-open-documents-view.qdoc b/doc/qtcreator/src/user-interface/creator-open-documents-view.qdoc
index e758c6c2b27..3eb7a3c2d4c 100644
--- a/doc/qtcreator/src/user-interface/creator-open-documents-view.qdoc
+++ b/doc/qtcreator/src/user-interface/creator-open-documents-view.qdoc
@@ -38,7 +38,7 @@
To set preferences for opening files and handling open files, select
\preferences > \uicontrol Environment > \uicontrol System:
- \image qtcreator-options-environment-system.png {System tab in Environment preferences}
+ \image qtcreator-preferences-environment-system.webp {System tab in Environment preferences}
\list
\li In the \uicontrol {When files are externally modified} field,
diff --git a/share/qtcreator/translations/qtcreator_de.ts b/share/qtcreator/translations/qtcreator_de.ts
index 420a51f1abc..0f9b15ff734 100644
--- a/share/qtcreator/translations/qtcreator_de.ts
+++ b/share/qtcreator/translations/qtcreator_de.ts
@@ -17857,27 +17857,27 @@ Trotzdem fortfahren?
Round Up for .5 and Above
-
+ Ab 0,5 aufrunden
Always Round Up
-
+ Immer aufrunden
Always Round Down
-
+ Immer abrunden
Round Up for .75 and Above
-
+ Ab 0,75 aufrunden
Don't Round
-
+ Nicht runden
DPI rounding policy:
-
+ DPI-Rundungsstrategie:
Text codec for tools:
@@ -17897,7 +17897,7 @@ Trotzdem fortfahren?
The DPI rounding policy change will take effect after restart.
-
+ Die Änderung der DPI-Rundungsstrategie wird nach einem Neustart wirksam.
Interface
@@ -18071,19 +18071,19 @@ Trotzdem fortfahren?
Show Menu Bar
-
+ Menüleiste anzeigen
Ctrl+Alt+M
-
+ Ctrl+Alt+M
Hide Menu Bar
-
+ Menüleiste verbergen
This will hide the menu bar completely. You can show it again by typing %1.
-
+ Dies verbirgt die Menüleiste. Sie können Sie durch Eingeben von %1 wieder anzeigen.
Version:
@@ -18313,7 +18313,7 @@ Trotzdem fortfahren?
Reset to Default
- Auf Vorgabe zurücksetzen
+ Auf Vorgabe zurücksetzen
Error Details
@@ -18394,7 +18394,7 @@ Trotzdem fortfahren?
Sort categories
-
+ Kategorien sortieren
Preferences
@@ -18735,11 +18735,11 @@ Trotzdem fortfahren?
Remove the following files from the version control system (%1)?
-
+ Möchten Sie die folgenden Dateien aus der Versionskontrolle (%1) entfernen?
Note: This might remove the local file.
-
+ Hinweis: Unter Umständen werden die lokalen Dateien gelöscht.
Add to Version Control
@@ -20549,7 +20549,7 @@ provided they were unmodified before the refactoring.
Sort results
-
+ Ergebnisse sortieren
Case sensitive:
@@ -21046,15 +21046,15 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Entry is missing a logging category name.
-
+ Der Name der Log-Kategorie fehlt im Eintrag.
Entry is missing data.
-
+ Im Eintrag fehlen Daten.
Invalid level: %1
-
+ Ungültige Stufe: %1
Category
@@ -21062,23 +21062,23 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Debug
- Debug
+ Debug
Warning
- Warnung
+ Warnung
Critical
-
+ Kritisch
Fatal
-
+ Fatal
Info
- Info
+ Info
Type
@@ -21090,15 +21090,15 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Filter Qt Internal Log Categories
-
+ Qt-interne Log-Kategorien ausschließen
Filter categories by regular expression
-
+ Kategorien mit regulärem Ausdruck filtern
Invalid regular expression: %1
- Ungültiger regulärer Ausdruck: %1
+ Ungültiger regulärer Ausdruck: %1
Start Logging
@@ -21114,15 +21114,16 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Uncheck All %1
-
+ Alle vom Typ %1 abwählen
Check All %1
-
+ Alle vom Typ %1 auswählen
Reset All %1
-
+ %1 is "Info", "Debug", etc
+ Alle vom Typ %1 zurücksetzen
Save Enabled as Preset...
@@ -21457,19 +21458,19 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Convert Comment to C-Style
-
+ Kommentar in C-Stil umwandeln
Convert Comment to C++-Style
-
+ Kommentar in C++-Stil umwandeln
Move Function Documentation to Declaration
-
+ Funktionsdokumentation zur Deklaration verschieben
Move Function Documentation to Definition
-
+ Funktionsdokumentation zur Definition verschieben
Insert Virtual Functions of Base Classes
@@ -21513,15 +21514,15 @@ Doppelklicken Sie einen Eintrag um ihn zu ändern.
Fold All Comment Blocks
-
+ Alle Kommentarblöcke einklappen
Unfold All Comment Blocks
-
+ Alle Kommentarblöcke ausklappen
C++ File Naming
-
+ Namenskonvention für C++-Dateien
The license template.
@@ -22484,9 +22485,9 @@ z.B. name = "m_test_foo_":
Checked %1 of %n function(s)
-
-
-
+
+ %1 von einer Funktion geprüft
+ %1 von %n Funktionen geprüft
@@ -22535,11 +22536,11 @@ z.B. name = "m_test_foo_":
Decision Forest
-
+ Decision Forest
Heuristics
-
+ Heuristik
Interpret ambiguous headers as C headers
@@ -22583,15 +22584,15 @@ z.B. name = "m_test_foo_":
<p>If background indexing is enabled, global symbol searches will yield more accurate results, at the cost of additional CPU load when the project is first opened. The indexing result is persisted in the project's build directory. If you disable background indexing, a faster, but less accurate, built-in indexer is used instead. The thread priority for building the background index can be adjusted since clangd 15.</p><p>Background Priority: Minimum priority, runs on idle CPUs. May leave 'performance' cores unused.</p><p>Normal Priority: Reduced priority compared to interactive work.</p><p>Low Priority: Same priority as other clangd work.</p>
-
+ <p>Wenn sie das globale Indizieren aktivieren, liefert die globale Symbolsuche genauere Resultate, es erhöht aber die CPU-Last beim ersten Öffnen von Projekten. Das Resultat der Indizierung wird im Build-Verzeichnis des Projekts gespeichert. Wenn sie das globale Indizieren deaktivieren, wird stattdessen ein schnellerer, aber weniger genauer, integrierter Indexer benutzt. Seit Clangd 15 können Sie die Priorität für die Indizierungs-Threads anpassen.</p><p>Hintergrund-Priorität: Niedrigste Priorität, läuft nur auf leerlaufenden CPUs. Kann "Performance"-Kerne ungenutzt lassen.</p><p>Normale Priorität: Geringere Priorität im Vergleich zu interaktiven Aktivitäten.</p><p>Niedrige Priorität: Dieselbe Priorität wie andere Clangd-Aktivitäten.</p>
<p>The C/C++ backend to use for switching between header and source files.</p><p>While the clangd implementation has more capabilities than the built-in code model, it tends to find false positives.</p><p>When "Try Both" is selected, clangd is used only if the built-in variant does not find anything.</p>
-
+ <p>Bestimmt, welches C/C++-Backend zum Wechseln zwischen Header- und Quelldatei benutzt wird.</p><p>Die Clangd-Implementation hat mehr Fähigkeiten, aber auch einige Fehler, die nicht in der integrierten Variante vorhanden sind.</p><p>Wenn "Beide versuchen" ausgewählt ist, wird Clangd nur benutzt, wenn die integrierte Variant nichts findet.</p>
<p>Which model clangd should use to rank possible completions.</p><p>This determines the order of candidates in the combo box when doing code completion.</p><p>The "%1" model used by default results from (pre-trained) machine learning and provides superior results on average.</p><p>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.</p>
-
+ <p>Das Modell, das Clangd für die Rangfolge der möglichen Vervollständigungen benutzen soll.</p><p>Dies bestimmt die Reihenfolge der Kandidaten im Drop-Down-Menü der Code-Vervollständigung.</p><p>Das voreingestellte Modell "%1" wurde durch maschinelles Lernen trainiert und bietet im Schnitt die besten Ergebnisse.</p><p>Falls dies für Ihren Code zu sehr von Ihren Erwartungen abweicht, können Sie auf das manuell erstellte Modell "%2" umstellen.<p>
Number of worker threads used by clangd. Background indexing also uses this many worker threads.
@@ -22655,7 +22656,7 @@ Das integrierte Codemodell übernimmt Syntaxhervorhebung, Code-Vervollständigun
Completion ranking model:
-
+ Rangfolge-Modell für die Code-Vervollständigung:
Document update threshold:
@@ -23007,7 +23008,7 @@ Flags: %3
collecting overrides...
-
+ Suche überschriebene Methoden...
@@ -28336,11 +28337,11 @@ Versuchen Sie, das Projekt neu zu erstellen.
Docker executable not found
-
+ Ausführbare Datei für Docker nicht gefunden
Failed to retrieve docker networks. Exit code: %1. Error: %2
-
+ Docker-Netzwerke konnten nicht abgerufen werden. Rückgabewert: %1. Fehler: %2
Path "%1" is not a directory or does not exist.
@@ -28356,39 +28357,39 @@ Versuchen Sie, das Projekt neu zu erstellen.
Run as outside user:
-
+ Als Benutzer von außerhalb ausführen:
Do not modify entry point:
-
+ Einstiegspunkt nicht ändern:
Enable flags needed for LLDB:
-
+ Aktiviert Optionen, die für LLDB benötigt werden:
Extra arguments:
- Zusätzliche Argumente:
+ Zusätzliche Argumente:
Extra arguments to pass to docker create.
-
+ Zusätzliche Argumente für docker create.
Network:
-
+ Netzwerk:
Error
- Fehler
+ Fehler
The path "%1" does not exist.
- Der Pfad "%1" existiert nicht.
+ Der Pfad "%1" existiert nicht.
stopped
-
+ angehalten
Error starting remote shell. No container.
@@ -28400,15 +28401,15 @@ Versuchen Sie, das Projekt neu zu erstellen.
Image "%1" is not available.
-
+ Image "%1" ist nicht verfügbar.
Failed creating Docker container. Exit code: %1, output: %2
-
+ Docker-Container konnte nicht erstellt werden. Rückgabewert: %1, Ausgabe: %2
Failed creating Docker container. No container ID received.
-
+ Docker-Container konnte nicht erstellt werden. Keine Container-ID erhalten.
Docker daemon appears to be not running. Verify daemon is up and running and reset the Docker daemon in Docker device preferences or restart %1.
@@ -28417,23 +28418,23 @@ Versuchen Sie, das Projekt neu zu erstellen.
Failed to create container shell (Out of memory).
-
+ Container-Shell konnte nicht erstellt werden (nicht genügend Speicherplatz).
Cannot start docker device from non-main thread
-
+ Docker-Gerät kann nur vom Haupt-Thread gestartet werden
Device is shut down
-
+ Das Gerät ist heruntergefahren
Docker system is not reachable
-
+ Docker-System ist nicht erreichbar
Running
- Läuft
+ Läuft
Docker Image Selection
@@ -28505,7 +28506,7 @@ Versuchen Sie, das Projekt neu zu erstellen.
Host directories to mount into the container.
- Host-Verzeichnisse die in den Container eingehängt werden sollen.
+ Host-Verzeichnisse, die in den Container eingehängt werden sollen.
Maps paths in this list one-to-one to the docker container.
@@ -28545,7 +28546,7 @@ Versuchen Sie, das Projekt neu zu erstellen.
Failed to start container.
-
+ Container konnte nicht gestartet werden.
Docker daemon appears to be stopped.
@@ -28569,11 +28570,11 @@ Versuchen Sie, das Projekt neu zu erstellen.
Container state:
-
+ Container-Status:
Command line:
- Kommandozeile:
+ Kommandozeile:
Daemon state not evaluated.
@@ -34167,27 +34168,27 @@ Ablaufdatum: %3
Symbols in Workspace
- Symbole im Arbeitsbereich
+ Symbole im Workspace
Locates symbols in the language server workspace.
- Findet Symbole im Arbeitsbereich des Language Servers.
+ Findet Symbole im Workspace des Language Servers.
Classes and Structs in Workspace
- Klassen und Strukturen im Arbeitsbereich
+ Klassen und Strukturen im Workspace
Locates classes and structs in the language server workspace.
- Findet Klassen und Strukturen im Arbeitsbereich des Language Servers.
+ Findet Klassen und Strukturen im Workspace des Language Servers.
Functions and Methods in Workspace
- Funktionen und Methoden im Arbeitsbereich
+ Funktionen und Methoden im Workspace
Locates functions and methods in the language server workspace.
- Findet Funktionen und Methoden im Arbeitsbereich des Language Servers.
+ Findet Funktionen und Methoden im Workspace des Language Servers.
Unexpectedly finished. Restarting in %1 seconds.
@@ -34265,12 +34266,13 @@ Beispiel: *.cpp%1*.h
Workspace Configuration
-
+ Workspace-Konfiguration
Additional JSON configuration sent to all running language servers for this project.
See the documentation of the specific language server for valid settings.
-
+ Zusätzliche JSON-Konfiguration, die an alle laufenden Language Server für dieses Projekt gesendet wird.
+Für gültige Einstellungen schauen Sie in die Dokumentation des benutzten Language Servers.
&Add
@@ -34310,7 +34312,7 @@ See the documentation of the specific language server for valid settings.
failed to initialize
language client state
-
+ Initialisierung fehlgeschlagen
initialized
@@ -34380,7 +34382,7 @@ See the documentation of the specific language server for valid settings.
Language Server
- Language Server
+ Language Server
Generic StdIO Language Server
@@ -34536,15 +34538,15 @@ See the documentation of the specific language server for valid settings.
Create %1
-
+ Erstelle %1
Rename %1 to %2
-
+ %1 in %2 umbenennen
Delete %1
-
+ %1 löschen
@@ -43036,19 +43038,19 @@ fails because Clang does not understand the target architecture.
Select PySide Version
-
+ PySide-Version auswählen
Select which PySide version to install:
-
+ Wählen Sie die zu installierende PySide-Version aus:
Latest PySide from the Python Package Index
-
+ Letzte PySide-Version aus dem Python-Paketindex
PySide %1 Wheel (%2)
-
+ PySide %1 Wheel (%2)
%1 installation missing for %2 (%3)
@@ -43180,7 +43182,7 @@ fails because Clang does not understand the target architecture.
Issues parsed from Python runtime output.
-
+ Probleme, die in der Laufzeitausgabe von Python gefunden wurden.
@@ -43998,11 +44000,11 @@ Die betroffenen Dateien sind:
File does not exist.
- Datei existiert nicht.
+ Datei existiert nicht.
File does not match filter.
-
+ Datei entspricht nicht dem Filter.
Library Type
@@ -44132,7 +44134,7 @@ Weder der Pfad zur Bibliothek noch der Pfad zu den Headerdateien wird zur .pro-D
Could not load kits in a reasonable amount of time.
-
+ Kits konnten nicht in angemessener Zeit geladen werden.
The application "%1" could not be found.
@@ -48453,7 +48455,7 @@ Der Kontrollprozess konnte nicht gestartet werden.
Error
- Fehler
+ Fehler
Failed: %1
@@ -48587,27 +48589,27 @@ Wenn Sie noch keinen privaten Schlüssel besitzen, können Sie hier auch einen e
Flags for rsync:
-
+ Optionen für rsync:
Transfer method:
-
+ Übertragungsmethode:
Use rsync if available. Otherwise use default transfer.
-
+ Benutze rsync, sofern verfügbar. Sonst Standardmethode verwenden.
Use sftp if available. Otherwise use default transfer.
-
+ Benutze SFTP, sofern verfügbar. Sonst Standardmethode verwenden.
Use default transfer. This might be slow.
-
+ Benutze Standardmethode. Dies könnte langsam sein.
Unknown error occurred while trying to create remote directories
-
+ Beim Erstellen von entfernten Verzeichnissen ist ein unbekannter Fehler aufgetreten
rsync failed to start: %1
@@ -48623,7 +48625,7 @@ Wenn Sie noch keinen privaten Schlüssel besitzen, können Sie hier auch einen e
Deploy files
-
+ Datei-Deployment
Ignore missing files:
@@ -55633,19 +55635,19 @@ in "%2" aus.
Parsing canceled.
-
+ Die Auswertung wurde abgebrochen.
Premature end of XML document.
-
+ Vorzeitiges Ende des XML-Dokuments.
Could not parse hex number from "%1" (%2).
-
+ "%1" konnte nicht als Hexadezimalzahl ausgewertet werden (%2).
Trying to read element text although current position is not start of element.
-
+ Es wurde versucht, Elementtext zu lesen, obwohl die aktuelle Position nicht am Beginn eines Elements ist.
Unexpected child element while reading element text
@@ -55669,7 +55671,7 @@ in "%2" aus.
Unknown %1 kind "%2"
-
+ Kein "%2" in Enum %1 gefunden
Could not parse error kind, tool not yet set.
@@ -55805,7 +55807,7 @@ in "%2" aus.
Valgrind arguments:
- Valgrind-Argumente
+ Valgrind-Argumente:
Enable cache simulation
diff --git a/src/libs/solutions/tasking/tasktree.cpp b/src/libs/solutions/tasking/tasktree.cpp
index cb71f516eea..3a4f76f1469 100644
--- a/src/libs/solutions/tasking/tasktree.cpp
+++ b/src/libs/solutions/tasking/tasktree.cpp
@@ -2701,10 +2701,7 @@ TimeoutTaskAdapter::~TimeoutTaskAdapter()
void TimeoutTaskAdapter::start()
{
- if (*task() == milliseconds::zero())
- QTimer::singleShot(0, this, [this] { emit done(true); });
- else
- m_timerId = scheduleTimeout(*task(), this, [this] { m_timerId = {}; emit done(true); });
+ m_timerId = scheduleTimeout(*task(), this, [this] { m_timerId = {}; emit done(true); });
}
} // namespace Tasking
diff --git a/src/libs/utils/aspects.cpp b/src/libs/utils/aspects.cpp
index f8923ce3ed1..aff4f8ffca8 100644
--- a/src/libs/utils/aspects.cpp
+++ b/src/libs/utils/aspects.cpp
@@ -84,6 +84,7 @@ public:
bool m_enabled = true;
bool m_readOnly = false;
bool m_autoApply = true;
+ bool m_hasEnabler = false;
int m_spanX = 1;
int m_spanY = 1;
BaseAspect::ConfigWidgetCreator m_configWidgetCreator;
@@ -348,6 +349,8 @@ void BaseAspect::setEnabler(BoolAspect *checker)
{
QTC_ASSERT(checker, return);
+ d->m_hasEnabler = true;
+
auto update = [this, checker] {
BaseAspect::setEnabled(checker->isEnabled() && checker->volatileValue());
};
@@ -647,6 +650,10 @@ void BaseAspect::readSettings()
if (settingsKey().isEmpty())
return;
QTC_ASSERT(theSettings, return);
+ // The enabler needs to be set up after reading the settings, otherwise
+ // changes from reading the settings will not update the enabled state
+ // because the updates are "quiet".
+ QTC_CHECK(!d->m_hasEnabler);
const QVariant val = theSettings->value(settingsKey());
setVariantValue(val.isValid() ? fromSettingsValue(val) : defaultVariantValue(), BeQuiet);
}
@@ -1795,8 +1802,6 @@ LayoutItem BoolAspect::adoptButton(QAbstractButton *button)
*/
void BoolAspect::addToLayout(Layouting::LayoutItem &parent)
{
- QTC_ASSERT(m_buffer == m_internal, m_buffer = m_internal);
-
QCheckBox *checkBox = createSubWidget();
addToLayoutHelper(parent, checkBox);
bufferToGui();
@@ -1904,7 +1909,6 @@ void SelectionAspect::addToLayout(Layouting::LayoutItem &parent)
QTC_CHECK(d->m_buttonGroup == nullptr);
QTC_CHECK(!d->m_comboBox);
QTC_ASSERT(d->m_buttons.isEmpty(), d->m_buttons.clear());
- QTC_ASSERT(m_buffer == m_internal, m_buffer = m_internal);
switch (d->m_displayStyle) {
case DisplayStyle::RadioButtons:
diff --git a/src/libs/utils/checkablemessagebox.cpp b/src/libs/utils/checkablemessagebox.cpp
index 8e43debc4f7..91f3c1855c0 100644
--- a/src/libs/utils/checkablemessagebox.cpp
+++ b/src/libs/utils/checkablemessagebox.cpp
@@ -60,9 +60,11 @@ static QMessageBox::StandardButton exec(
if (text.contains("append(entry);
+ found->append(start + entry);
}
}
@@ -1327,7 +1329,7 @@ void UnixDeviceFileAccess::iterateDirectory(const FilePath &filePath,
// if we do not have find - use ls as fallback
QStringList entries;
- findUsingLs(filePath.path(), filter, &entries);
+ findUsingLs(filePath.path(), filter, &entries, {});
iterateLsOutput(filePath, entries, filter, callBack);
}
diff --git a/src/libs/utils/devicefileaccess.h b/src/libs/utils/devicefileaccess.h
index 6dddbc70045..5b7c766a8a7 100644
--- a/src/libs/utils/devicefileaccess.h
+++ b/src/libs/utils/devicefileaccess.h
@@ -183,16 +183,15 @@ protected:
expected_str createTempFile(const FilePath &filePath) override;
+ void findUsingLs(const QString ¤t,
+ const FileFilter &filter,
+ QStringList *found,
+ const QString &start) const;
private:
- bool iterateWithFind(
- const FilePath &filePath,
- const FileFilter &filter,
- const FilePath::IterateDirCallback &callBack) const;
- void findUsingLs(
- const QString ¤t,
- const FileFilter &filter,
- QStringList *found) const;
+ bool iterateWithFind(const FilePath &filePath,
+ const FileFilter &filter,
+ const FilePath::IterateDirCallback &callBack) const;
QStringList statArgs(const FilePath &filePath,
const QString &linuxFormat,
diff --git a/src/libs/utils/externalterminalprocessimpl.cpp b/src/libs/utils/externalterminalprocessimpl.cpp
index 5cff874eb76..5182c2c4373 100644
--- a/src/libs/utils/externalterminalprocessimpl.cpp
+++ b/src/libs/utils/externalterminalprocessimpl.cpp
@@ -8,7 +8,11 @@
#include "terminalcommand.h"
#include "utilstr.h"
+#include
#include
+#include
+
+Q_LOGGING_CATEGORY(log, "terminal.externalprocess", QtWarningMsg)
namespace Utils {
@@ -17,22 +21,62 @@ ExternalTerminalProcessImpl::ExternalTerminalProcessImpl()
setStubCreator(new ProcessStubCreator(this));
}
+QString ExternalTerminalProcessImpl::openTerminalScriptAttached()
+{
+ static const QLatin1String script{R"(
+tell application "Terminal"
+ activate
+ set windowId to 0
+ set newTab to do script "%1 && exit"
+
+ -- Try to get window id
+ try
+ -- We have seen this work on macOS 13, and 12.5.1, but not on 14.0 or 14.1
+ set windowId to (the id of window 1 where its tab 1 = newTab) as text
+ on error eMsg number eNum
+ -- If we get an error we try to generate a known error that will contain the window id in its message
+ try
+ set windowId to window of newTab
+ on error eMsg number eNum
+ if eNum = -1728 then
+ try
+ -- Search for "window id " in the error message, examples of error messages are:
+ -- „Terminal“ hat einen Fehler erhalten: „window of tab 1 of window id 4018“ kann nicht gelesen werden.
+ -- Terminal got an error: Can't get window of tab 1 of window id 4707.
+ set windowIdPrefix to "window id "
+ set theOffset to (offset of windowIdPrefix in eMsg)
+ if theOffset = 0 then
+ log "Failed to parse window id from error message: " & eMsg
+ else
+ set windowIdPosition to theOffset + (length of windowIdPrefix)
+ set windowId to (first word of (text windowIdPosition thru -1 of eMsg)) as integer
+ end if
+ on error eMsg2 number eNum2
+ log "Failed to parse window id from error message: " & eMsg2 & " (" & eMsg & ") " & theOffset
+ end try
+ end if
+ end try
+ end try
+
+ repeat until ((count of processes of newTab) = 0)
+ delay 0.1
+ end repeat
+
+ if windowId is not equal to 0 then
+ close window id windowId
+ else
+ log "Cannot close window, sorry."
+ end if
+end tell
+ )"};
+
+ return script;
+}
+
ProcessStubCreator::ProcessStubCreator(TerminalInterface *interface)
: m_interface(interface)
{}
-static const QLatin1String TerminalAppScriptAttached{R"(
- tell application "Terminal"
- activate
- set newTab to do script "%1 && exit"
- set win to (the id of window 1 where its tab 1 = newTab) as text
- repeat until ((count of processes of newTab) = 0)
- delay 0.1
- end repeat
- close window id win
- end tell
-)"};
-
static const QLatin1String TerminalAppScriptDetached{R"(
tell application "Terminal"
activate
@@ -52,8 +96,15 @@ expected_str ProcessStubCreator::startStubProcess(const ProcessSetupData
bool detached = setupData.m_terminalMode == TerminalMode::Detached;
if (HostOsInfo::isMacHost()) {
+ // There is a bug in macOS 14.0 where the script fails if it tries to find
+ // the window id. We will have to check in future versions of macOS if they fixed
+ // the issue.
+ static const QVersionNumber osVersionNumber = QVersionNumber::fromString(
+ QSysInfo::productVersion());
+
static const QMap terminalMap = {
- {"Terminal.app", {TerminalAppScriptAttached, TerminalAppScriptDetached}},
+ {"Terminal.app",
+ {ExternalTerminalProcessImpl::openTerminalScriptAttached(), TerminalAppScriptDetached}},
};
if (terminalMap.contains(terminal.command.toString())) {
@@ -101,6 +152,17 @@ expected_str ProcessStubCreator::startStubProcess(const ProcessSetupData
Tr::tr("Failed to start terminal process: \"%1\".").arg(process->errorString()));
}
+ QObject::connect(process, &Process::readyReadStandardOutput, process, [process] {
+ const QString output = process->readAllStandardOutput();
+ if (!output.isEmpty())
+ qCWarning(log).noquote() << output;
+ });
+ QObject::connect(process, &Process::readyReadStandardError, process, [process] {
+ const QString output = process->readAllStandardError();
+ if (!output.isEmpty())
+ qCCritical(log).noquote() << output;
+ });
+
QObject::connect(process, &Process::done, m_interface, &TerminalInterface::onStubExited);
return 0;
diff --git a/src/libs/utils/externalterminalprocessimpl.h b/src/libs/utils/externalterminalprocessimpl.h
index cbb3370071b..66d337f963d 100644
--- a/src/libs/utils/externalterminalprocessimpl.h
+++ b/src/libs/utils/externalterminalprocessimpl.h
@@ -13,6 +13,8 @@ class QTCREATOR_UTILS_EXPORT ExternalTerminalProcessImpl final : public Terminal
{
public:
ExternalTerminalProcessImpl();
+
+ static QString openTerminalScriptAttached();
};
class QTCREATOR_UTILS_EXPORT ProcessStubCreator : public StubCreator
diff --git a/src/libs/utils/terminalinterface.cpp b/src/libs/utils/terminalinterface.cpp
index 9fb226ece54..de3f57145cc 100644
--- a/src/libs/utils/terminalinterface.cpp
+++ b/src/libs/utils/terminalinterface.cpp
@@ -92,6 +92,7 @@ public:
StubCreator *stubCreator{nullptr};
const bool waitOnExit;
+ bool didInferiorRun{false};
};
TerminalInterface::TerminalInterface(bool waitOnExit)
@@ -156,6 +157,11 @@ void TerminalInterface::onStubExited()
if (d->inferiorProcessId)
emitFinished(-1, QProcess::CrashExit);
+ else if (!d->didInferiorRun) {
+ emitError(QProcess::FailedToStart,
+ Tr::tr("Failed to start terminal process. The stub exited before the inferior "
+ "was started."));
+ }
}
void TerminalInterface::onStubReadyRead()
@@ -176,6 +182,7 @@ void TerminalInterface::onStubReadyRead()
d->envListFile = nullptr;
} else if (out.startsWith("pid ")) {
d->inferiorProcessId = out.mid(4).toInt();
+ d->didInferiorRun = true;
emit started(d->inferiorProcessId, d->inferiorThreadId);
} else if (out.startsWith("thread ")) { // Windows only
d->inferiorThreadId = out.mid(7).toLongLong();
@@ -349,8 +356,9 @@ void TerminalInterface::start()
return;
}
QTextStream stream(d->envListFile.get());
- finalEnv.forEachEntry([&stream](const QString &key, const QString &value, bool) {
- stream << key << '=' << value << '\0';
+ finalEnv.forEachEntry([&stream](const QString &key, const QString &value, bool enabled) {
+ if (enabled)
+ stream << key << '=' << value << '\0';
});
if (d->envListFile->error() != QFile::NoError) {
diff --git a/src/plugins/autotest/autotestplugin.cpp b/src/plugins/autotest/autotestplugin.cpp
index 0f93fb7dc75..67b264dcd00 100644
--- a/src/plugins/autotest/autotestplugin.cpp
+++ b/src/plugins/autotest/autotestplugin.cpp
@@ -136,7 +136,6 @@ AutotestPluginPrivate::AutotestPluginPrivate()
TestFrameworkManager::registerTestFramework(&theCatchFramework());
TestFrameworkManager::registerTestTool(&theCTestTool());
- TestFrameworkManager::synchronizeSettings();
m_resultsPane = TestResultsPane::instance();
diff --git a/src/plugins/autotest/boost/boosttestframework.cpp b/src/plugins/autotest/boost/boosttestframework.cpp
index 38f800357b4..9addde077b0 100644
--- a/src/plugins/autotest/boost/boosttestframework.cpp
+++ b/src/plugins/autotest/boost/boosttestframework.cpp
@@ -74,7 +74,6 @@ BoostTestFramework::BoostTestFramework()
seed.setLabelText(Tr::tr("Seed:"));
seed.setToolTip(Tr::tr("A seed of 0 means no randomization. A value of 1 uses the current "
"time, any other value is used as random seed generator."));
- seed.setEnabler(&randomize);
randomize.setSettingsKey("Randomize");
randomize.setLabelPlacement(BoolAspect::LabelPlacement::Compact);
@@ -96,6 +95,10 @@ BoostTestFramework::BoostTestFramework()
memLeaks.setDefaultValue(true);
memLeaks.setLabelText(Tr::tr("Detect memory leaks"));
memLeaks.setToolTip(Tr::tr("Enable memory leak detection."));
+
+ readSettings();
+
+ seed.setEnabler(&randomize);
}
QString BoostTestFramework::logLevelToOption(const LogLevel logLevel)
diff --git a/src/plugins/autotest/catch/catchtestframework.cpp b/src/plugins/autotest/catch/catchtestframework.cpp
index 8c312f65d15..a8ac1e9faab 100644
--- a/src/plugins/autotest/catch/catchtestframework.cpp
+++ b/src/plugins/autotest/catch/catchtestframework.cpp
@@ -49,29 +49,24 @@ CatchFramework::CatchFramework()
abortAfter.setSettingsKey("AbortAfter");
abortAfter.setRange(1, 9999);
- abortAfter.setEnabler(&abortAfterChecked);
benchmarkSamples.setSettingsKey("BenchSamples");
benchmarkSamples.setRange(1, 999999);
benchmarkSamples.setDefaultValue(100);
- benchmarkSamples.setEnabler(&samplesChecked);
benchmarkResamples.setSettingsKey("BenchResamples");
benchmarkResamples.setRange(1, 9999999);
benchmarkResamples.setDefaultValue(100000);
benchmarkResamples.setToolTip(Tr::tr("Number of resamples for bootstrapping."));
- benchmarkResamples.setEnabler(&resamplesChecked);
confidenceInterval.setSettingsKey("BenchConfInt");
confidenceInterval.setRange(0., 1.);
confidenceInterval.setSingleStep(0.05);
confidenceInterval.setDefaultValue(0.95);
- confidenceInterval.setEnabler(&confidenceIntervalChecked);
benchmarkWarmupTime.setSettingsKey("BenchWarmup");
benchmarkWarmupTime.setSuffix(Tr::tr(" ms"));
benchmarkWarmupTime.setRange(0, 10000);
- benchmarkWarmupTime.setEnabler(&warmupChecked);
abortAfterChecked.setSettingsKey("AbortChecked");
abortAfterChecked.setLabelText(Tr::tr("Abort after"));
@@ -117,6 +112,14 @@ CatchFramework::CatchFramework()
warnOnEmpty.setSettingsKey("WarnEmpty");
warnOnEmpty.setLabelText(Tr::tr("Warn on empty tests"));
warnOnEmpty.setToolTip(Tr::tr("Warns if a test section does not check any assertion."));
+
+ readSettings();
+
+ benchmarkWarmupTime.setEnabler(&warmupChecked);
+ confidenceInterval.setEnabler(&confidenceIntervalChecked);
+ benchmarkResamples.setEnabler(&resamplesChecked);
+ benchmarkSamples.setEnabler(&samplesChecked);
+ abortAfter.setEnabler(&abortAfterChecked);
}
ITestParser *CatchFramework::createTestParser()
diff --git a/src/plugins/autotest/ctest/ctesttool.cpp b/src/plugins/autotest/ctest/ctesttool.cpp
index 2dee957194f..8b82953e2c4 100644
--- a/src/plugins/autotest/ctest/ctesttool.cpp
+++ b/src/plugins/autotest/ctest/ctesttool.cpp
@@ -108,6 +108,9 @@ CTestTool::CTestTool()
threshold.setLabelText(Tr::tr("Threshold"));
threshold.setDefaultValue(1);
threshold.setRange(1, 128);
+
+ readSettings();
+
threshold.setEnabler(&testLoad);
}
diff --git a/src/plugins/autotest/gtest/gtestframework.cpp b/src/plugins/autotest/gtest/gtestframework.cpp
index 8e54e1d7255..f07de8ed52a 100644
--- a/src/plugins/autotest/gtest/gtestframework.cpp
+++ b/src/plugins/autotest/gtest/gtestframework.cpp
@@ -52,7 +52,6 @@ GTestFramework::GTestFramework()
iterations.setDefaultValue(1);
iterations.setEnabled(false);
iterations.setLabelText(Tr::tr("Iterations:"));
- iterations.setEnabler(&repeat);
seed.setSettingsKey("Seed");
seed.setSpecialValueText({});
@@ -60,7 +59,6 @@ GTestFramework::GTestFramework()
seed.setEnabled(false);
seed.setLabelText(Tr::tr("Seed:"));
seed.setToolTip(Tr::tr("A seed of 0 generates a seed based on the current timestamp."));
- seed.setEnabler(&shuffle);
runDisabled.setSettingsKey("RunDisabled");
runDisabled.setLabelText(Tr::tr("Run disabled tests"));
@@ -95,14 +93,14 @@ GTestFramework::GTestFramework()
// avoid problems if user messes around with the settings file
bool ok = false;
const int tmp = savedValue.toInt(&ok);
- return ok ? groupMode.indexForItemValue(tmp) : GTest::Constants::Directory;
+ return groupMode.indexForItemValue(ok ? tmp : GTest::Constants::Directory);
});
groupMode.setToSettingsTransformation([this](const QVariant &value) {
return groupMode.itemValueForIndex(value.toInt());
});
groupMode.addOption({Tr::tr("Directory"), {}, GTest::Constants::Directory});
groupMode.addOption({Tr::tr("GTest Filter"), {}, GTest::Constants::GTestFilter});
- groupMode.setDefaultValue(GTest::Constants::Directory);
+ groupMode.setDefaultValue(groupMode.indexForItemValue(GTest::Constants::Directory));
groupMode.setLabelText(Tr::tr("Group mode:"));
groupMode.setToolTip(Tr::tr("Select on what grouping the tests should be based."));
@@ -132,6 +130,11 @@ GTestFramework::GTestFramework()
connect(this, &AspectContainer::applied, this, [] {
TestTreeModel::instance()->rebuild({GTest::Constants::FRAMEWORK_ID});
});
+
+ readSettings();
+
+ seed.setEnabler(&shuffle);
+ iterations.setEnabler(&repeat);
}
ITestParser *GTestFramework::createTestParser()
@@ -144,6 +147,12 @@ ITestTreeItem *GTestFramework::createRootNode()
return new GTestTreeItem(this, displayName(), {}, ITestTreeItem::Root);
}
+void GTestFramework::readSettings()
+{
+ Utils::AspectContainer::readSettings();
+ gtestFilter.setEnabled(groupMode.itemValue() == GTest::Constants::GTestFilter);
+}
+
QString GTestFramework::currentGTestFilter()
{
return theGTestFramework().gtestFilter();
diff --git a/src/plugins/autotest/gtest/gtestframework.h b/src/plugins/autotest/gtest/gtestframework.h
index ff9e2766b58..80052980b1d 100644
--- a/src/plugins/autotest/gtest/gtestframework.h
+++ b/src/plugins/autotest/gtest/gtestframework.h
@@ -32,6 +32,8 @@ public:
QString groupingToolTip() const override;
ITestParser *createTestParser() override;
ITestTreeItem *createRootNode() override;
+
+ void readSettings() final;
};
GTestFramework &theGTestFramework();
diff --git a/src/plugins/autotest/qtest/qttestframework.cpp b/src/plugins/autotest/qtest/qttestframework.cpp
index a406506a675..0f854ab6f59 100644
--- a/src/plugins/autotest/qtest/qttestframework.cpp
+++ b/src/plugins/autotest/qtest/qttestframework.cpp
@@ -92,7 +92,6 @@ QtTestFramework::QtTestFramework()
maxWarnings.setRange(0, 10000);
maxWarnings.setDefaultValue(2000);
maxWarnings.setSpecialValueText(Tr::tr("Unlimited"));
- maxWarnings.setEnabler(&limitWarnings);
quickCheckForDerivedTests.setSettingsKey("QuickCheckForDerivedTests");
quickCheckForDerivedTests.setDefaultValue(false);
@@ -100,6 +99,10 @@ QtTestFramework::QtTestFramework()
quickCheckForDerivedTests.setToolTip(
Tr::tr("Search for Qt Quick tests that are derived from TestCase.\nWarning: Enabling this "
"feature significantly increases scan time."));
+
+ readSettings();
+
+ maxWarnings.setEnabler(&limitWarnings);
}
QString QtTestFramework::metricsTypeToOption(const MetricsType type)
diff --git a/src/plugins/autotest/testframeworkmanager.cpp b/src/plugins/autotest/testframeworkmanager.cpp
index d44dc3d1e7c..7d19e746c8b 100644
--- a/src/plugins/autotest/testframeworkmanager.cpp
+++ b/src/plugins/autotest/testframeworkmanager.cpp
@@ -86,14 +86,4 @@ ITestTool *testToolForBuildSystemId(Id buildSystemId)
});
}
-void synchronizeSettings()
-{
- Internal::testSettings().fromSettings();
- for (ITestFramework *framework : std::as_const(testFrameworks()))
- framework->readSettings();
-
- for (ITestTool *testTool : std::as_const(testTools()))
- testTool->readSettings();
-}
-
} // Autotest::TestframeworkManager
diff --git a/src/plugins/autotest/testframeworkmanager.h b/src/plugins/autotest/testframeworkmanager.h
index 9ced25d8fb9..48f521c863d 100644
--- a/src/plugins/autotest/testframeworkmanager.h
+++ b/src/plugins/autotest/testframeworkmanager.h
@@ -9,7 +9,6 @@ namespace Autotest::TestFrameworkManager {
void registerTestFramework(ITestFramework *framework);
void registerTestTool(ITestTool *testTool);
-void synchronizeSettings();
ITestFramework *frameworkForId(Utils::Id frameworkId);
ITestTool *testToolForId(Utils::Id testToolId);
diff --git a/src/plugins/autotest/testsettings.cpp b/src/plugins/autotest/testsettings.cpp
index 1d5230d711d..174773b757c 100644
--- a/src/plugins/autotest/testsettings.cpp
+++ b/src/plugins/autotest/testsettings.cpp
@@ -64,7 +64,6 @@ TestSettings::TestSettings()
resultDescriptionMaxSize.setSettingsKey("ResultDescriptionMaxSize");
resultDescriptionMaxSize.setDefaultValue(10);
resultDescriptionMaxSize.setRange(1, 100000);
- resultDescriptionMaxSize.setEnabler(&limitResultDescription);
autoScroll.setSettingsKey("AutoScrollResults");
autoScroll.setDefaultValue(true);
@@ -95,7 +94,6 @@ TestSettings::TestSettings()
popupOnFail.setSettingsKey("PopupOnFail");
popupOnFail.setLabelText(Tr::tr("Only for unsuccessful test runs"));
- popupOnFail.setEnabler(&popupOnFinish);
popupOnFail.setToolTip(Tr::tr("Displays test results only if the test run contains "
"failed, fatal or unexpectedly passed tests."));
@@ -105,6 +103,11 @@ TestSettings::TestSettings()
runAfterBuild.addOption(Tr::tr("None"));
runAfterBuild.addOption(Tr::tr("All"));
runAfterBuild.addOption(Tr::tr("Selected"));
+
+ fromSettings();
+
+ resultDescriptionMaxSize.setEnabler(&limitResultDescription);
+ popupOnFail.setEnabler(&popupOnFinish);
}
void TestSettings::toSettings() const
diff --git a/src/plugins/cmakeprojectmanager/cmakebuildstep.cpp b/src/plugins/cmakeprojectmanager/cmakebuildstep.cpp
index 18b02a1be7a..b2e13b84b54 100644
--- a/src/plugins/cmakeprojectmanager/cmakebuildstep.cpp
+++ b/src/plugins/cmakeprojectmanager/cmakebuildstep.cpp
@@ -773,6 +773,9 @@ void CMakeBuildStep::updateDeploymentData()
IDeviceConstPtr runDevice = DeviceKitAspect::device(buildSystem()->kit());
+ if (!runDevice)
+ return;
+
const auto appFileNames = transform>(buildSystem()->applicationTargets(),
[](const BuildTargetInfo &appTarget) { return appTarget.targetFilePath.fileName(); });
diff --git a/src/plugins/cmakeprojectmanager/cmakebuildsystem.cpp b/src/plugins/cmakeprojectmanager/cmakebuildsystem.cpp
index ff948fed01e..bd686268336 100644
--- a/src/plugins/cmakeprojectmanager/cmakebuildsystem.cpp
+++ b/src/plugins/cmakeprojectmanager/cmakebuildsystem.cpp
@@ -1004,6 +1004,30 @@ void CMakeBuildSystem::updateProjectData()
QtSupport::CppKitInfo kitInfo(kit());
QTC_ASSERT(kitInfo.isValid(), return );
+ struct QtMajorToPkgNames
+ {
+ QtMajorVersion major = QtMajorVersion::None;
+ QStringList pkgNames;
+ };
+
+ auto qtVersionFromCMake = [this](const QList &mapping) {
+ for (const QtMajorToPkgNames &m : mapping) {
+ for (const QString &pkgName : m.pkgNames) {
+ auto qt = m_findPackagesFilesHash.value(pkgName);
+ if (qt.hasValidTarget())
+ return m.major;
+ }
+ }
+ return QtMajorVersion::None;
+ };
+
+ QtMajorVersion qtVersion = kitInfo.projectPartQtVersion;
+ if (qtVersion == QtMajorVersion::None)
+ qtVersion = qtVersionFromCMake({{QtMajorVersion::Qt6, {"Qt6", "Qt6Core"}},
+ {QtMajorVersion::Qt5, {"Qt5", "Qt5Core"}},
+ {QtMajorVersion::Qt4, {"Qt4", "Qt4Core"}}
+ });
+
QString errorMessage;
RawProjectParts rpps = m_reader.createRawProjectParts(errorMessage);
if (!errorMessage.isEmpty())
@@ -1011,8 +1035,7 @@ void CMakeBuildSystem::updateProjectData()
qCDebug(cmakeBuildSystemLog) << "Raw project parts created." << errorMessage;
for (RawProjectPart &rpp : rpps) {
- rpp.setQtVersion(
- kitInfo.projectPartQtVersion); // TODO: Check if project actually uses Qt.
+ rpp.setQtVersion(qtVersion); // TODO: Check if project actually uses Qt.
const FilePath includeFileBaseDir = buildConfiguration()->buildDirectory();
QStringList cxxFlags = rpp.flagsForCxx.commandLineFlags;
QStringList cFlags = rpp.flagsForC.commandLineFlags;
diff --git a/src/plugins/cmakeprojectmanager/presetsmacros.cpp b/src/plugins/cmakeprojectmanager/presetsmacros.cpp
index 220d6d6575d..7681d2f7e13 100644
--- a/src/plugins/cmakeprojectmanager/presetsmacros.cpp
+++ b/src/plugins/cmakeprojectmanager/presetsmacros.cpp
@@ -116,8 +116,10 @@ static Environment getEnvCombined(const std::optional &optPresetEnv
Environment result = env;
if (optPresetEnv) {
- optPresetEnv->forEachEntry([&result](const QString &key, const QString &value, bool) {
- result.set(key, value);
+ optPresetEnv->forEachEntry([&result](const QString &key, const QString &value,
+ bool enabled) {
+ if (enabled)
+ result.set(key, value);
});
}
@@ -128,7 +130,9 @@ template
void expand(const PresetType &preset, Environment &env, const FilePath &sourceDirectory)
{
const Environment presetEnv = getEnvCombined(preset.environment, env);
- presetEnv.forEachEntry([&](const QString &key, const QString &value_, bool) {
+ presetEnv.forEachEntry([&](const QString &key, const QString &value_, bool enabled) {
+ if (!enabled)
+ return;
QString value = value_;
expandAllButEnv(preset, sourceDirectory, value);
value = expandMacroEnv("env", value, [presetEnv](const QString ¯oName) {
@@ -163,7 +167,9 @@ template
void expand(const PresetType &preset, EnvironmentItems &envItems, const FilePath &sourceDirectory)
{
const Environment presetEnv = preset.environment ? *preset.environment : Environment();
- presetEnv.forEachEntry([&](const QString &key, const QString &value_, bool) {
+ presetEnv.forEachEntry([&](const QString &key, const QString &value_, bool enabled) {
+ if (!enabled)
+ return;
QString value = value_;
expandAllButEnv(preset, sourceDirectory, value);
value = expandMacroEnv("env", value, [presetEnv](const QString ¯oName) {
diff --git a/src/plugins/coreplugin/systemsettings.cpp b/src/plugins/coreplugin/systemsettings.cpp
index 1477fcf747d..af4aef29113 100644
--- a/src/plugins/coreplugin/systemsettings.cpp
+++ b/src/plugins/coreplugin/systemsettings.cpp
@@ -85,7 +85,6 @@ SystemSettings::SystemSettings()
autoSaveInterval.setSuffix(Tr::tr("min"));
autoSaveInterval.setRange(1, 1000000);
autoSaveInterval.setDefaultValue(5);
- autoSaveInterval.setEnabler(&autoSaveModifiedFiles);
autoSaveInterval.setLabelText(Tr::tr("Interval:"));
autoSaveAfterRefactoring.setSettingsKey("EditorManager/AutoSaveAfterRefactoring");
@@ -107,7 +106,6 @@ SystemSettings::SystemSettings()
autoSuspendMinDocumentCount.setSettingsKey("EditorManager/AutoSuspendMinDocuments");
autoSuspendMinDocumentCount.setRange(1, 500);
autoSuspendMinDocumentCount.setDefaultValue(30);
- autoSuspendMinDocumentCount.setEnabler(&autoSuspendEnabled);
autoSuspendMinDocumentCount.setLabelText(Tr::tr("Files to keep open:"));
autoSuspendMinDocumentCount.setToolTip(
Tr::tr("Minimum number of open documents that should be kept in memory. Increasing this "
@@ -122,7 +120,6 @@ SystemSettings::SystemSettings()
bigFileSizeLimitInMB.setSuffix(Tr::tr("MB"));
bigFileSizeLimitInMB.setRange(1, 500);
bigFileSizeLimitInMB.setDefaultValue(5);
- bigFileSizeLimitInMB.setEnabler(&warnBeforeOpeningBigFiles);
maxRecentFiles.setSettingsKey("EditorManager/MaxRecentFiles");
maxRecentFiles.setRange(1, 99);
@@ -151,6 +148,11 @@ SystemSettings::SystemSettings()
showCrashButton.setSettingsKey("ShowCrashButton");
#endif
readSettings();
+
+ autoSaveInterval.setEnabler(&autoSaveModifiedFiles);
+ autoSuspendMinDocumentCount.setEnabler(&autoSuspendEnabled);
+ bigFileSizeLimitInMB.setEnabler(&warnBeforeOpeningBigFiles);
+
connect(&autoSaveModifiedFiles, &BaseAspect::changed,
this, &EditorManagerPrivate::updateAutoSave);
connect(&autoSaveInterval, &BaseAspect::changed, this, &EditorManagerPrivate::updateAutoSave);
diff --git a/src/plugins/cppeditor/cppmodelmanager.cpp b/src/plugins/cppeditor/cppmodelmanager.cpp
index e72c630cbf7..52f0ea89845 100644
--- a/src/plugins/cppeditor/cppmodelmanager.cpp
+++ b/src/plugins/cppeditor/cppmodelmanager.cpp
@@ -1647,8 +1647,8 @@ QList CppModelManager::projectPart(const FilePath &fileNa
{
{
QReadLocker locker(&d->m_projectLock);
- auto it = d->m_fileToProjectParts.find(fileName);
- if (it != d->m_fileToProjectParts.end())
+ auto it = d->m_fileToProjectParts.constFind(fileName);
+ if (it != d->m_fileToProjectParts.constEnd())
return it.value();
}
const FilePath canonicalPath = fileName.canonicalPath();
diff --git a/src/plugins/debugger/dap/dapclient.cpp b/src/plugins/debugger/dap/dapclient.cpp
index b1fa0ad1f85..4b66ac68ab4 100644
--- a/src/plugins/debugger/dap/dapclient.cpp
+++ b/src/plugins/debugger/dap/dapclient.cpp
@@ -58,10 +58,13 @@ void DapClient::sendInitialize()
postRequest("initialize", QJsonObject{{"clientID", "QtCreator"}, {"clientName", "QtCreator"}});
}
-void DapClient::sendLaunch(const Utils::FilePath &executable)
+void DapClient::sendLaunch(const Utils::CommandLine &command)
{
postRequest("launch",
- QJsonObject{{"noDebug", false}, {"program", executable.path()}, {"__restart", ""}});
+ QJsonObject{{"noDebug", false},
+ {"program", command.executable().path()},
+ {"args", command.arguments()},
+ {"__restart", ""}});
}
void DapClient::sendAttach()
diff --git a/src/plugins/debugger/dap/dapclient.h b/src/plugins/debugger/dap/dapclient.h
index b0cd30a8b26..d5a31b04a96 100644
--- a/src/plugins/debugger/dap/dapclient.h
+++ b/src/plugins/debugger/dap/dapclient.h
@@ -81,7 +81,7 @@ public:
virtual void sendInitialize();
- void sendLaunch(const Utils::FilePath &executable);
+ void sendLaunch(const Utils::CommandLine &command);
void sendAttach();
void sendConfigurationDone();
diff --git a/src/plugins/debugger/dap/dapengine.cpp b/src/plugins/debugger/dap/dapengine.cpp
index 5c6de71777d..18171f7217b 100644
--- a/src/plugins/debugger/dap/dapengine.cpp
+++ b/src/plugins/debugger/dap/dapengine.cpp
@@ -195,7 +195,7 @@ void DapEngine::handleDapInitialize()
{
QTC_ASSERT(state() == EngineRunRequested, qCDebug(logCategory()) << state());
- m_dapClient->sendLaunch(runParameters().inferior.command.executable());
+ m_dapClient->sendLaunch(runParameters().inferior.command);
qCDebug(logCategory()) << "handleDapLaunch";
}
@@ -532,6 +532,9 @@ QString DapEngine::errorMessage(QProcess::ProcessError error) const
void DapEngine::handleDapDone()
{
+ if (state() == DebuggerFinished)
+ return;
+
if (m_dapClient->dataProvider()->result() == ProcessResult::StartFailed) {
notifyEngineSetupFailed();
showMessage("ADAPTER START FAILED");
@@ -864,7 +867,7 @@ void DapEngine::refreshLocals(const QJsonArray &variables)
if (currentItem && currentItem->iname.startsWith("watch"))
currentItem->removeChildren();
- for (auto variable : variables) {
+ for (const QJsonValueConstRef &variable : variables) {
WatchItem *item = new WatchItem;
const QString name = variable.toObject().value("name").toString();
diff --git a/src/plugins/debugger/dap/gdbdapengine.cpp b/src/plugins/debugger/dap/gdbdapengine.cpp
index 1b208924e85..4e248674a1f 100644
--- a/src/plugins/debugger/dap/gdbdapengine.cpp
+++ b/src/plugins/debugger/dap/gdbdapengine.cpp
@@ -63,6 +63,8 @@ public:
void start() override
{
m_proc.setProcessMode(ProcessMode::Writer);
+ if (m_runParameters.debugger.workingDirectory.isDir())
+ m_proc.setWorkingDirectory(m_runParameters.debugger.workingDirectory);
m_proc.setEnvironment(m_runParameters.debugger.environment);
m_proc.setCommand(m_cmd);
m_proc.start();
diff --git a/src/plugins/docker/dockerdevice.cpp b/src/plugins/docker/dockerdevice.cpp
index 7dc014eadaf..03e6c0f00e8 100644
--- a/src/plugins/docker/dockerdevice.cpp
+++ b/src/plugins/docker/dockerdevice.cpp
@@ -662,9 +662,11 @@ CommandLine DockerDevicePrivate::withDockerExecCmd(const CommandLine &cmd,
dockerCmd.addArg("-t");
if (env) {
- env->forEachEntry([&](const QString &key, const QString &value, bool) {
- dockerCmd.addArg("-e");
- dockerCmd.addArg(key + "=" + env->expandVariables(value));
+ env->forEachEntry([&](const QString &key, const QString &value, bool enabled) {
+ if (enabled) {
+ dockerCmd.addArg("-e");
+ dockerCmd.addArg(key + "=" + env->expandVariables(value));
+ }
});
}
diff --git a/src/plugins/fakevim/fakevimactions.cpp b/src/plugins/fakevim/fakevimactions.cpp
index b4d568c7f07..a7c0eee43a2 100644
--- a/src/plugins/fakevim/fakevimactions.cpp
+++ b/src/plugins/fakevim/fakevimactions.cpp
@@ -156,8 +156,6 @@ FakeVimSettings::FakeVimSettings()
Row ints { shiftWidth, tabStop, scrollOff, st };
- vimRcPath.setEnabler(&readVimRc);
-
Column strings {
backspace,
isKeyword,
@@ -239,6 +237,8 @@ FakeVimSettings::FakeVimSettings()
readSettings();
+ vimRcPath.setEnabler(&readVimRc);
+
#endif
}
diff --git a/src/plugins/qmakeprojectmanager/qmakeproject.cpp b/src/plugins/qmakeprojectmanager/qmakeproject.cpp
index a21ed6bd72a..b2bca450e7f 100644
--- a/src/plugins/qmakeprojectmanager/qmakeproject.cpp
+++ b/src/plugins/qmakeprojectmanager/qmakeproject.cpp
@@ -867,8 +867,9 @@ QtSupport::ProFileReader *QmakeBuildSystem::createProFileReader(const QmakeProFi
rootProFileName,
deviceRoot());
- env.forEachEntry([&](const QString &key, const QString &value, bool) {
- m_qmakeGlobals->environment.insert(key, env.expandVariables(value));
+ env.forEachEntry([&](const QString &key, const QString &value, bool enabled) {
+ if (enabled)
+ m_qmakeGlobals->environment.insert(key, env.expandVariables(value));
});
m_qmakeGlobals->setCommandLineArguments(rootProFileName, qmakeArgs);
diff --git a/src/plugins/qmljseditor/qmljsoutline.cpp b/src/plugins/qmljseditor/qmljsoutline.cpp
index 89d2dd68320..73a9b2b0b33 100644
--- a/src/plugins/qmljseditor/qmljsoutline.cpp
+++ b/src/plugins/qmljseditor/qmljsoutline.cpp
@@ -44,9 +44,13 @@ bool QmlJSOutlineFilterModel::filterAcceptsRow(int sourceRow,
{
if (m_filterBindings) {
QModelIndex sourceIndex = sourceModel()->index(sourceRow, 0, sourceParent);
- QVariant itemType = sourceIndex.data(QmlOutlineModel::ItemTypeRole);
- if (itemType == QmlOutlineModel::NonElementBindingType)
- return false;
+ while (sourceIndex.isValid()) {
+ if (sourceIndex.data(QmlOutlineModel::ItemTypeRole)
+ == QmlOutlineModel::NonElementBindingType) {
+ return false;
+ }
+ sourceIndex = sourceIndex.parent();
+ }
}
return QSortFilterProxyModel::filterAcceptsRow(sourceRow, sourceParent);
}
diff --git a/src/plugins/qmlprofiler/qmlprofilersettings.cpp b/src/plugins/qmlprofiler/qmlprofilersettings.cpp
index 9bbac157414..32063ec947b 100644
--- a/src/plugins/qmlprofiler/qmlprofilersettings.cpp
+++ b/src/plugins/qmlprofiler/qmlprofilersettings.cpp
@@ -40,7 +40,6 @@ QmlProfilerSettings::QmlProfilerSettings()
flushInterval.setRange(1, 10000000);
flushInterval.setDefaultValue(1000);
flushInterval.setLabelText(Tr::tr("Flush interval (ms):"));
- flushInterval.setEnabler(&flushEnabled);
lastTraceFile.setSettingsKey("Analyzer.QmlProfiler.LastTraceFile");
@@ -63,6 +62,8 @@ QmlProfilerSettings::QmlProfilerSettings()
});
readSettings();
+
+ flushInterval.setEnabler(&flushEnabled);
}
// QmlProfilerSettingsPage
diff --git a/src/plugins/remotelinux/linuxdevice.cpp b/src/plugins/remotelinux/linuxdevice.cpp
index 565b0675503..3f875f1ef4b 100644
--- a/src/plugins/remotelinux/linuxdevice.cpp
+++ b/src/plugins/remotelinux/linuxdevice.cpp
@@ -768,8 +768,9 @@ CommandLine SshProcessInterfacePrivate::fullLocalCommandLine() const
inner.addArgs(QString("echo ") + s_pidMarker + "$$" + s_pidMarker + " && ", CommandLine::Raw);
const Environment &env = q->m_setup.m_environment;
- env.forEachEntry([&](const QString &key, const QString &value, bool) {
- inner.addArgs(key + "='" + env.expandVariables(value) + '\'', CommandLine::Raw);
+ env.forEachEntry([&](const QString &key, const QString &value, bool enabled) {
+ if (enabled)
+ inner.addArgs(key + "='" + env.expandVariables(value) + '\'', CommandLine::Raw);
});
if (!useTerminal && !commandLine.isEmpty())
diff --git a/src/plugins/screenrecorder/screenrecordersettings.cpp b/src/plugins/screenrecorder/screenrecordersettings.cpp
index cc00f6da065..0a94638f855 100644
--- a/src/plugins/screenrecorder/screenrecordersettings.cpp
+++ b/src/plugins/screenrecorder/screenrecordersettings.cpp
@@ -113,7 +113,6 @@ ScreenRecorderSettings::ScreenRecorderSettings()
fileSizeLimit.setDefaultValue(1024);
fileSizeLimit.setRange(100, 1024 * 1024 * 2); // Up to 2GB
fileSizeLimit.setSuffix("MB");
- fileSizeLimit.setEnabler(&enableFileSizeLimit);
enableRtBuffer.setSettingsKey("EnableRealTimeBuffer");
enableRtBuffer.setDefaultValue(true);
@@ -124,7 +123,6 @@ ScreenRecorderSettings::ScreenRecorderSettings()
rtBufferSize.setDefaultValue(1024);
rtBufferSize.setRange(100, 1024 * 1024 * 2); // Up to 2GB
rtBufferSize.setSuffix("MB");
- rtBufferSize.setEnabler(&enableRtBuffer);
logFfmpegCommandline.setSettingsKey("LogFFMpegCommandLine");
logFfmpegCommandline.setDefaultValue(false);
@@ -206,6 +204,9 @@ ScreenRecorderSettings::ScreenRecorderSettings()
readSettings();
+ rtBufferSize.setEnabler(&enableRtBuffer);
+ fileSizeLimit.setEnabler(&enableFileSizeLimit);
+
setCaptureMouseClicksVisible();
connect(&screenCaptureType, &SelectionAspect::volatileValueChanged, this,
setCaptureMouseClicksVisible);
diff --git a/src/plugins/texteditor/CMakeLists.txt b/src/plugins/texteditor/CMakeLists.txt
index 03efc189224..7d4577413bc 100644
--- a/src/plugins/texteditor/CMakeLists.txt
+++ b/src/plugins/texteditor/CMakeLists.txt
@@ -103,7 +103,6 @@ add_qtc_plugin(TextEditor
texteditor.qrc
texteditor_global.h
texteditortr.h
- texteditor_p.h
texteditoractionhandler.cpp texteditoractionhandler.h
texteditorconstants.cpp texteditorconstants.h
texteditoroverlay.cpp texteditoroverlay.h
diff --git a/src/plugins/texteditor/outlinefactory.cpp b/src/plugins/texteditor/outlinefactory.cpp
index 2c462127026..8c736a45396 100644
--- a/src/plugins/texteditor/outlinefactory.cpp
+++ b/src/plugins/texteditor/outlinefactory.cpp
@@ -120,8 +120,10 @@ OutlineWidgetStack::OutlineWidgetStack(OutlineFactory *factory) :
m_toggleSort->setToolTip(Tr::tr("Sort Alphabetically"));
connect(m_toggleSort, &QAbstractButton::clicked, this, &OutlineWidgetStack::toggleSort);
- connect(Core::EditorManager::instance(), &Core::EditorManager::currentEditorChanged,
- this, &OutlineWidgetStack::updateEditor);
+ connect(Core::EditorManager::instance(),
+ &Core::EditorManager::currentEditorChanged,
+ this,
+ &OutlineWidgetStack::updateCurrentEditor);
connect(factory, &OutlineFactory::updateOutline,
this, &OutlineWidgetStack::updateCurrentEditor);
updateCurrentEditor();
diff --git a/src/plugins/texteditor/texteditor.cpp b/src/plugins/texteditor/texteditor.cpp
index 43b0bddb3f7..d4820b16665 100644
--- a/src/plugins/texteditor/texteditor.cpp
+++ b/src/plugins/texteditor/texteditor.cpp
@@ -27,7 +27,6 @@
#include "tabsettings.h"
#include "textdocument.h"
#include "textdocumentlayout.h"
-#include "texteditor_p.h"
#include "texteditoractionhandler.h"
#include "texteditorconstants.h"
#include "texteditoroverlay.h"
@@ -563,6 +562,19 @@ struct PaintEventBlockData
struct ExtraAreaPaintEventData;
+struct TextEditorPrivateHighlightBlocks
+{
+ QList open;
+ QList close;
+ QList visualIndent;
+ inline int count() const { return visualIndent.size(); }
+ inline bool isEmpty() const { return open.isEmpty() || close.isEmpty() || visualIndent.isEmpty(); }
+ inline bool operator==(const TextEditorPrivateHighlightBlocks &o) const {
+ return (open == o.open && close == o.close && visualIndent == o.visualIndent);
+ }
+ inline bool operator!=(const TextEditorPrivateHighlightBlocks &o) const { return !(*this == o); }
+};
+
class TextEditorWidgetPrivate : public QObject
{
public:
diff --git a/src/plugins/texteditor/texteditor.qbs b/src/plugins/texteditor/texteditor.qbs
index a041fbcaa66..0c25f5bf5c6 100644
--- a/src/plugins/texteditor/texteditor.qbs
+++ b/src/plugins/texteditor/texteditor.qbs
@@ -134,7 +134,6 @@ QtcPlugin {
"texteditor.h",
"texteditor.qrc",
"texteditor_global.h", "texteditortr.h",
- "texteditor_p.h",
"texteditoractionhandler.cpp",
"texteditoractionhandler.h",
"texteditorconstants.cpp",
diff --git a/src/plugins/texteditor/texteditor_p.h b/src/plugins/texteditor/texteditor_p.h
deleted file mode 100644
index fa8232a0fb0..00000000000
--- a/src/plugins/texteditor/texteditor_p.h
+++ /dev/null
@@ -1,36 +0,0 @@
-// Copyright (C) 2016 The Qt Company Ltd.
-// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
-
-#pragma once
-
-
-#include "texteditor_global.h"
-
-#include
-#include
-
-namespace TextEditor {
-
-class TextDocument;
-
-namespace Internal {
-
-//
-// TextEditorPrivate
-//
-
-struct TextEditorPrivateHighlightBlocks
-{
- QList open;
- QList close;
- QList visualIndent;
- inline int count() const { return visualIndent.size(); }
- inline bool isEmpty() const { return open.isEmpty() || close.isEmpty() || visualIndent.isEmpty(); }
- inline bool operator==(const TextEditorPrivateHighlightBlocks &o) const {
- return (open == o.open && close == o.close && visualIndent == o.visualIndent);
- }
- inline bool operator!=(const TextEditorPrivateHighlightBlocks &o) const { return !(*this == o); }
-};
-
-} // namespace Internal
-} // namespace TextEditor
diff --git a/tests/auto/solutions/tasking/tst_tasking.cpp b/tests/auto/solutions/tasking/tst_tasking.cpp
index 4f639f3e013..c2116cbb940 100644
--- a/tests/auto/solutions/tasking/tst_tasking.cpp
+++ b/tests/auto/solutions/tasking/tst_tasking.cpp
@@ -2676,7 +2676,7 @@ void tst_Tasking::testInThread()
QFETCH(TestData, testData);
const auto onSetup = [testData](ConcurrentCall &task) {
- task.setConcurrentCallData(runInThread, testData);
+ task.setConcurrentCallData(&runInThread, testData);
};
const auto onDone = [testData](const ConcurrentCall &task) {
QVERIFY(task.future().resultCount());
diff --git a/tests/auto/utils/unixdevicefileaccess/tst_unixdevicefileaccess.cpp b/tests/auto/utils/unixdevicefileaccess/tst_unixdevicefileaccess.cpp
index 5eba8122241..a55577ef05e 100644
--- a/tests/auto/utils/unixdevicefileaccess/tst_unixdevicefileaccess.cpp
+++ b/tests/auto/utils/unixdevicefileaccess/tst_unixdevicefileaccess.cpp
@@ -48,6 +48,11 @@ public:
p.waitForFinished();
return {p.exitCode(), p.readAllStandardOutput(), p.readAllStandardError()};
}
+
+ void findUsingLs(const QString ¤t, const FileFilter &filter, QStringList *found)
+ {
+ UnixDeviceFileAccess::findUsingLs(current, filter, found, {});
+ }
};
class tst_unixdevicefileaccess : public QObject
@@ -69,6 +74,27 @@ private slots:
QCOMPARE(size, 1024);
}
+ void findUsingLs()
+ {
+ QStringList result;
+ m_dfa.findUsingLs(m_tempDir.path(),
+ {{}, QDir::NoFilter, QDirIterator::Subdirectories},
+ &result);
+
+ QCOMPARE(result, QStringList({".", "..", "size-test"}));
+
+ QDir tDir(m_tempDir.path());
+ tDir.mkdir("lsfindsubdir");
+
+ result.clear();
+ m_dfa.findUsingLs(m_tempDir.path(),
+ {{}, QDir::NoFilter, QDirIterator::Subdirectories},
+ &result);
+ QCOMPARE(result,
+ QStringList(
+ {".", "..", "lsfindsubdir/.", "lsfindsubdir/..", "lsfindsubdir", "size-test"}));
+ }
+
private:
TestDFA m_dfa;
DeviceFileAccess *m_dfaPtr = &m_dfa;
diff --git a/tests/manual/CMakeLists.txt b/tests/manual/CMakeLists.txt
index de324714a2b..1d145e1e8bb 100644
--- a/tests/manual/CMakeLists.txt
+++ b/tests/manual/CMakeLists.txt
@@ -12,6 +12,7 @@ add_subdirectory(fakevim)
# add_subdirectory(genericproject)
add_subdirectory(pluginview)
add_subdirectory(proparser)
+add_subdirectory(terminal)
# add_subdirectory(qml)
# add_subdirectory(qt4projectmanager)
# add_subdirectory(search)
diff --git a/tests/manual/manual.qbs b/tests/manual/manual.qbs
index ba774823c12..25ed3b9e183 100644
--- a/tests/manual/manual.qbs
+++ b/tests/manual/manual.qbs
@@ -15,6 +15,7 @@ Project {
"subdirfilecontainer/subdirfilecontainer.qbs",
"tasking/demo/demo.qbs",
"tasking/imagescaling/imagescaling.qbs",
+ "terminal/terminal.qbs",
"widgets/widgets.qbs",
]
}
diff --git a/tests/manual/terminal/CMakeLists.txt b/tests/manual/terminal/CMakeLists.txt
new file mode 100644
index 00000000000..f4fff9d2c43
--- /dev/null
+++ b/tests/manual/terminal/CMakeLists.txt
@@ -0,0 +1,4 @@
+add_qtc_test(tst_terminal
+ DEPENDS Utils
+ SOURCES tst_terminal.cpp
+)
diff --git a/tests/manual/terminal/terminal.qbs b/tests/manual/terminal/terminal.qbs
new file mode 100644
index 00000000000..4b7a408a1e4
--- /dev/null
+++ b/tests/manual/terminal/terminal.qbs
@@ -0,0 +1,7 @@
+import qbs
+
+QtcAutotest {
+ name: "Terminal autotest"
+ Depends { name: "Utils" }
+ files: "tst_terminal.cpp"
+}
diff --git a/tests/manual/terminal/tst_terminal.cpp b/tests/manual/terminal/tst_terminal.cpp
new file mode 100644
index 00000000000..921fdbc577a
--- /dev/null
+++ b/tests/manual/terminal/tst_terminal.cpp
@@ -0,0 +1,54 @@
+// Copyright (C) 2016 The Qt Company Ltd.
+// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
+
+#include
+
+#include
+#include
+
+//TESTED_COMPONENT=src/utils/changeset
+
+class tst_Terminal : public QObject
+{
+ Q_OBJECT
+
+private slots:
+ void terminalApp()
+ {
+ if (!Utils::HostOsInfo::isMacHost())
+ QSKIP("This test is only for macOS");
+
+ int rnd = QRandomGenerator::global()->generate();
+ QString testCode = R"(
+set theFile to POSIX file "/tmp/testoutput.txt"
+set theFile to theFile as string
+set theOpenedFile to open for access file theFile with write permission
+set eof of theOpenedFile to 0
+write "%1" to theOpenedFile starting at eof
+close access theOpenedFile
+ )";
+ QString terminalScript = Utils::ExternalTerminalProcessImpl::openTerminalScriptAttached();
+ terminalScript = terminalScript.arg("sleep 1") + "\n" + testCode.arg(rnd);
+
+ QProcess process;
+ process.setProcessChannelMode(QProcess::ProcessChannelMode::MergedChannels);
+ process.setProgram("osascript");
+ process.setArguments({"-e", terminalScript});
+
+ process.start();
+
+ QTRY_VERIFY(process.state() == QProcess::NotRunning);
+ const auto output = process.readAll();
+ if (!output.isEmpty())
+ qDebug() << "Output:" << output;
+ QVERIFY(process.exitCode() == 0);
+
+ QFile testOutputFile("/tmp/testoutput.txt");
+ QVERIFY(testOutputFile.open(QIODevice::ReadOnly));
+ QVERIFY(testOutputFile.readAll() == QByteArray::number(rnd));
+ }
+};
+
+QTEST_GUILESS_MAIN(tst_Terminal)
+
+#include "tst_terminal.moc"