Commit Graph

76860 Commits

Author SHA1 Message Date
hjk
0c10e54f68 Utils: Introduce a doCleanPath() helper function
Respecting :// separators, which QDir::cleanPath() breaks.

Note that this still uses the host-dependent QDir::cleanPath
in the implementation.

Change-Id: Icd6c41ee52b5a0c4ff7398863cb26811a61261ec
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-27 07:37:45 +00:00
Cristian Adam
a26235dab9 ProjectExplorer: Fix abi detection of static Qt builds
Qt 6.2.4 static builds, both with MSVC 2019 and MinGW 11.2.0 are
having the coff headers at the 66 offset instead of 60.

I determined the value empirically, I haven't managed to find
a reference about the magic 60 or 66 values.

Fixes: QTCREATORBUG-27735
Change-Id: Ie2e9f8d6456e765acffce4991955067964b8c0fc
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-27 07:33:23 +00:00
Eike Ziller
c95cf1c0cf Fix crash handler executable name
Amends 17129dc931

Change-Id: I28f8fca14857454ada7c0a1cbce6d5db6a5ab37e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2022-06-27 07:06:33 +00:00
Eike Ziller
ff96ea41b2 CMake build: Don't exclude GTEST tests for dependency checking
Also Googletest based tests should be disabled if dependencies
are missing.

Amends aac0f2a8f5

Change-Id: I3be6165b8a28428ba34556a1bf438b3000c00056
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-06-27 07:05:59 +00:00
Eike Ziller
ae2e57b167 Ignore .json.in and .svg files for translations
Amends 30bb32d9af
which added the .json.in files to the list of target sources.

Change-Id: I7282cfcda50cbd156403a23cce06baed9698bb4d
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-06-27 07:05:29 +00:00
Eike Ziller
92c74abbf1 Fix lupdate issues
Change-Id: I7256c8aff5eb77b264b76ba24e79c26ab2924e84
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-06-27 07:05:22 +00:00
David Schulz
abccfe0646 Callgrind: modernize callgrind marks
Use annotions instead of custom icons on marks and show tooltip on
annotations

Change-Id: I153caefb997e9688902c0ec1a8090ff741416431
Reviewed-by: hjk <hjk@qt.io>
2022-06-27 04:35:03 +00:00
Orgad Shaneh
67f98c0c83 Valgrind: Stop parsing if file open failed
Reported by Coverity.

Change-Id: Ibf12c563cb2cab50183c62a4e51cdbe238d0127e
Reviewed-by: hjk <hjk@qt.io>
2022-06-24 15:31:55 +00:00
Adam Treat
5c0ad89d91 RemoteLinux: Change the displayed names to 'Remote' instead of 'Generic'
Change-Id: I0e6edd24f10c69caf376379e1cec05bf90da9579
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-06-24 15:24:43 +00:00
hjk
2496ffe3ce Code cosmetics
Mostly unused #include's, also sort them or reduce scope.

A few namespaces, ...

Change-Id: I9ee71e07de7157c9942125672addf87dd41e78f1
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2022-06-24 14:44:13 +00:00
hjk
31db28601b CPlusPlus: Use a global variable for the undefined type instance
... and split the FullySpecifiedType in two overloads.

Initially:

        29 [1]  FullySpecifiedType::FullySpecifiedType(Type *type) :
                <+   24>        41 54                 push   %r12
                <+   26>        55                    push   %rbp
        34 [1]          static UndefinedType t;
                <+   27>        48 8b 2d 26 68 13 00  mov    0x136826(%rip),%rbp
        29 [1]  FullySpecifiedType::FullySpecifiedType(Type *type) :
                <+   34>        53                    push   %rbx
                <+   35>        48 89 fb              mov    %rdi,%rbx
        34 [1]          static UndefinedType t;
                <+   38>        0f b6 45 00           movzbl 0x0(%rbp),%eax
                <+   42>        84 c0                 test   %al,%al
                <+   44>        74 12                 je     0x7fffc135c620 <_ZN9CPlusPlus18FullySpecifiedTypeC2EPNS_4TypeE+64>
                <+   46>        4c 8b 25 5b 66 13 00  mov    0x13665b(%rip),%r12
        35 [1]          return &t;
                <+   53>        4c 89 23              mov    %r12,(%rbx)
        34 [1]  }
                <+   56>        5b                    pop    %rbx
                <+   57>        5d                    pop    %rbp
                <+   58>        41 5c                 pop    %r12
                <+   60>        c3                    ret

After making it a global variable:

        29 [1]  FullySpecifiedType::FullySpecifiedType(Type *type) :
                                f3 0f 1e fa           endbr64
        30 [1]      _type(type), _flags(0)
                <+    4>        c7 47 08 00 00 00 00  movl   $0x0,0x8(%rdi)
        32 [1]      if (! type)
                <+   11>        48 85 f6              test   %rsi,%rsi
                <+   14>        74 08                 je     0x7fffc14675f8 <_ZN9CPlusPlus18FullySpecifiedTypeC2EPNS_4TypeE+24>
                <+   16>        48 89 37              mov    %rsi,(%rdi)
        34 [1]  }
                <+   19>        c3                    ret
                <+   20>        0f 1f 40 00           nopl   0x0(%rax)
        33 [1]          _type = &UndefinedType::instance;
                <+   24>        48 8b 35 49 67 13 00  mov    0x136749(%rip),%rsi        # 0x7fffc159dd48
                <+   31>        48 89 37              mov    %rsi,(%rdi)
        34 [1]  }
                <+   34>        c3                    ret

The no-parameters branch after splitting:

        29 [1]  FullySpecifiedType::FullySpecifiedType() :
                                f3 0f 1e fa           endbr64
        30 [1]      _type(&UndefinedType::instance), _flags(0)
                <+    4>        48 8b 05 5d 67 13 00  mov    0x13675d(%rip),%rax        # 0x7fffc159dd48
                <+   11>        c7 47 08 00 00 00 00  movl   $0x0,0x8(%rdi)
                <+   18>        48 89 07              mov    %rax,(%rdi)
        31 [1]  {}
                <+   21>        c3                    ret

Change-Id: I61439d68921cf9fa422304033b75de16bb4aa0d5
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-24 14:44:06 +00:00
Ippei Sugita
290c86f55c Partially update Japanese translations
This is meant to rescue/review the translated strings.
lupdate has not been used yet.

Change-Id: Ia5a3acc25ba59709b0f638c19f6e9f40afeff7be
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2022-06-24 13:40:45 +00:00
Marcus Tillmanns
30f9f68b15 iostool: Cleanup and improve debug output
Replaced the custom command line arg parsing code
with QCommandLineParser

Change-Id: I14e8695b5ee327b1d111558271bf98afd0c942b0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-06-24 13:18:09 +00:00
Christian Kandeler
b122c1905f Update qbs submodule to HEAD of 1.23 branch
Change-Id: I049c37052ea9006a87b4cab85c5288512526eff4
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 12:03:25 +00:00
Alessandro Portale
90e691251f Fix install command in wizard generated CMake files for Android
"error: install TARGETS given no LIBRARY DESTINATION for module target
<...>."

Change-Id: I9b283e342b32c7d3df44bb5aed231b843e3e54ae
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-06-24 11:53:17 +00:00
hjk
ffa3aad576 CPlusPlus: Inline some simple central functions
Depending on context, callgrind sees contributions of >8% to
the total cost of project parsing for these functions. The
functional are actualy executed executed out-of-line, often
for a function body of one "payload" instruction only.

Inlining removes the call/endbr64/ret overhead.

Change-Id: I6886f08e322fcaa4e0f54d424279e0a8c24e4718
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-24 11:49:41 +00:00
Henning Gruendl
85cd97a334 QmlProjectManager: Update landing page
* Make landing page responsive
* Use QtCreator welcome page theme colors
* Remove CMake from landing page
* Separate colors from values to make mocking data less redundant
* Add quick version to qt version check
* Use qml singleton for backend instead of using the root context item

Change-Id: Ic303d4713c348e34197716031b303720702f3e98
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-06-24 11:48:35 +00:00
David Schulz
e3cfbc0a7b Python: improve initializing python run configuration
Sets main.py as the default script. If we cannot find a main.py we
create a runconfig for every py file in the project.

Change-Id: I93f4c9a5c9e2825a592eee3707439e69a8aea566
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 11:24:18 +00:00
David Schulz
6c8605ced2 Python: automatically disable outdated pyls settings
Change-Id: I301c6df3fdd9cf634a1abff20c6f24b9bc5fc23b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 11:23:52 +00:00
Christian Kandeler
e2b99e6b31 Unit test: Remove libclang test remains
Change-Id: Ifa2cd2727ecf80d3b29dc2bc2a10af11baa2f1dc
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 11:01:01 +00:00
Christian Kandeler
224be9add8 ClangTools: Move over a test from unittest
Change-Id: Id61a0bdb8e46ead4de8ad0298e62afb7b9fbcfb4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 10:05:54 +00:00
David Schulz
e4d692a689 Python: only add python files as targets
Change-Id: I21f0ca6035aed6306d6cbe55a6c6df0838e49f45
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 09:53:52 +00:00
Brook Cronin
21ef02a016 update fixed version of icon font
Change-Id: Iedf945b3718d4df245e24ac1ba756b20f6ed9cf1
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-06-24 09:46:21 +00:00
Jarek Kobus
9fde8511e2 QtcProcess: Be idle when incoming data is empty
Don't forward and flush empty data

Change-Id: Idb153695d7eb62905c000b70efdfb0c68f0df9ad
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-06-24 09:41:10 +00:00
Christian Kandeler
44aea533f8 ProjectExplorer: Prevent spurious soft asserts in target panel
When a kit is being removed, various signals are being emitted in
unspecified order, so there is a transient state where the target model
has to expect the kit not being present.

Fixes: QTCREATORBUG-27742
Change-Id: I2df5db780a7fcf614397e525451f3f8bcbae8b84
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-24 09:31:26 +00:00
Piotr Mućko
cf147aa4b6 McuSupport: Organize namespaces, separate legacy constants
qtc9 will use new implementation for qtForMCUs 2.3 and newer.
Legacy implementation will be used for older versions.

Change-Id: Ibb2919f25d03d6445b8328e20316d4f88203a463
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-06-24 08:32:14 +00:00
Thomas Hartmann
34491bdfc3 QmlDesigner: Only remove node with position
Extending the test case.

Change-Id: I37255de763262e069c2f9d30b1ce584a0347fbcf
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-06-24 08:32:14 +00:00
Christian Stenger
818451fa9e Debugger: Fix compile with Qt5
Amends f4ea9e09ec.

Change-Id: I642c99ffe9a932c6c74b771eab5d2122d01b1ee3
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-06-24 05:39:57 +00:00
David Schulz
c3cb262154 Editor: Fix dangling completion widgets
Set the correct assist reason when rerequesting a code assist to be able
to detect perfect matches. Also destroy the code assist context when the
processor is not running and has not returned a proposal after perform.

Change-Id: Ieb04203269076655ac3d7ffc54ea8a1d055194a4
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-24 04:15:57 +00:00
Christian Kandeler
67a08683d1 ClangCodeModel: Move a test over from unittest
Change-Id: Iac295216fff274fbe4a109477b1a4c2bd2c98d5d
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-23 13:54:14 +00:00
Christian Kandeler
7dfbe785e9 Unit test: Remove unused files
Change-Id: Ia8d8f2014f8180d5c5fa89538d5aa7fc8821bc28
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-06-23 13:43:58 +00:00
Miikka Heikkinen
93cd068d3e QmlDesigner: Create material library at import change
There are still rewriter issues with Qt5, where component library
templates for models contain materials, so create material library
when quick3d import is added to ensure we never need to create
it when models are added.

Change-Id: I7006a39228d316dbfd84f49d19c025bb42b6765c
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-06-23 13:09:15 +00:00
Miikka Heikkinen
8a8a2f5c55 QmlDesigner: Unify the background of 3D preview images
Added 3D checkerboard floor on all 3D previews.
Since shadows generally look bad for arbitrary 3D scenes, and would
mostly be obscured by the model itself as we want the light mostly
from the front, removed shadows also from the material preview to unify
the previews.

Qt5 had issues rendering the 3D floor texture, so used a static image
there, as Qt5 only generates previews of one size.

Fixes: QDS-7078
Change-Id: I74d094878ed01e6e531ad60df1f8d9d7cf415860
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-06-23 13:06:04 +00:00
Marco Bubke
7e17119e0a Disable warnings for google tests
Change-Id: I5992d0c565690a0dc8a283ab889275dec2182c17
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2022-06-23 12:15:55 +00:00
Miikka Heikkinen
7aaaccb281 QmlDesigner: Remove duplicate assert
This assert was redundant, leading to duplicate warnings if triggered.

Change-Id: I59b6a7c17345a2ccba0d51ef50a303eec2026422
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-06-23 12:09:30 +00:00
hjk
6250cf20a1 McuSupport: Delay creation of SettingsHandler
There should be no significant activity in a plugin before
the initialization phase.

Change-Id: Iee2bcff4644ac07c3867fa59ce6613e128bd0390
Reviewed-by: Piotr Mućko <piotr.mucko@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2022-06-23 11:59:12 +00:00
The Qt Project
380c247945 Merge "Merge remote-tracking branch 'origin/8.0'" 2022-06-23 10:41:37 +00:00
Marco Bubke
d87d493de2 Sqlite: Only declare the defines for the sqlite files
Change-Id: Ic5a7be63c86cf3f369309fc4d21cf6f5ceefb098
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-06-23 10:33:20 +00:00
Marco Bubke
f7fee5e023 Sqlite: Refactor static build
Don't declare all defines of the static build anymore but only the needed
structs.

Change-Id: I84567d302edbc839852b8a9e85f104c5f915e5e1
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-06-23 10:33:14 +00:00
Marco Bubke
9d99e900b4 Fix warnings
Change-Id: I49dc38853df77bcc4d72c64132700c6059fbd5d7
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-06-23 10:33:09 +00:00
Marco Bubke
220267638f UnitTests: Use Sqlite library
Because the unit tests are not self contained anymore we can use the
Sqlite library from the creator build.

Change-Id: I89dde09e6fcfb8dda002b6e2bf11528a0933cde7
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2022-06-23 10:33:05 +00:00
Christian Kandeler
c1e4c4fde8 QbsProjectManager: Fix assertion when writing to non-running process
Amends b21ed19903.

Change-Id: Ib4e8460d2e000faad49e08b39432a1c5ce6a017c
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-06-23 10:19:31 +00:00
Miikka Heikkinen
b3be9d9802 QmlDesigner: Tweak 3D asset import dialog layout
On some font scalings, spinboxes were too tight, especially when there
was just one row of options showing, so increased the row height
and tweaked layout margins a bit.

Fixes: QDS-7186
Change-Id: I0650ab976d96f27fc9cf606c4faa6fa2d7c5e8f4
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-06-23 09:47:19 +00:00
Eike Ziller
69cbcb4cd5 Merge remote-tracking branch 'origin/8.0'
Change-Id: I3f218b52bf6904daca3779fb677e51f6f51f2f9f
2022-06-23 11:17:33 +02:00
Eike Ziller
1b89bcbf5e Fix application of value to StringAspect/LineEditDisplay
It was not applying the value when changing the text via a completer.
That lead to confusing result where values were cut off (and also saved
in the settings as such) at seemingly arbitrary cases.
Ensure that the text from the line edit ends up in the aspect by also
applying it on editingFinished().

One example where that exposed, was the executable aspect in the
RemoteLinuxCustomRunConfiguration.

Change-Id: I65c434fd675eeead76a73f680c126fd204d7c996
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-23 08:45:24 +00:00
BogDan Vatra
0ce0ad6cf9 Add android-build/libs/<ABI> to solibSearchPath
All android libs that can be loaded are placed in android-build/libs/
<abi>/.
These libs are not stripped anymore, so let's add also this folder to
solibSearchPath.

Change-Id: I34de8bf7ee68725903fd7250a39b407c6ae57cac
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2022-06-23 08:44:58 +00:00
hjk
8bb22fa4f3 Debugger: Fail gracefully on systems without working base64 module
Change-Id: I341b0fdb1c9e32fda3ce80f3e7569cffbb0708d2
Reviewed-by: Rafael Roquetto <rafael.roquetto@qt.io>
2022-06-23 08:26:02 +00:00
BogDan Vatra
aaf2318a19 Fix Android debugging
- gatherFilesToPull depends on AndroidManager::setDeviceAbis
- use the same path for app_process. gatherFilesToPull pulls app_process
to AndroidManager::buildDirectory(target) which might be different than
activeRunConfig->buildTargetInfo().workingDirectory.

Change-Id: Id47c4380fed5a8b3ad922359e5f9f25e529bacff
Reviewed-by: hjk <hjk@qt.io>
2022-06-23 08:25:43 +00:00
BogDan Vatra
146f59e808 Set solibSearchPath to LLDB
Change-Id: Iedfc3850b568dc336eb3df309b2b36ab25d1aa20
Reviewed-by: hjk <hjk@qt.io>
2022-06-23 08:25:30 +00:00
Jarek Kobus
1e8139ecec CdbEngine: Don't call blocking waitForStarted()
Connect to started() signal instead and continue
setup in its handler. Handle failed to start case
inside done() signal handler.

Change-Id: I23fd222a6c73147ee439381cac79f29cffad560c
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-06-23 07:59:04 +00:00