Commit Graph

71171 Commits

Author SHA1 Message Date
Robert Löhning
f529051b58 Squish: Be fuzzy when comparing snippet fetched from Pastebin.Com
Change-Id: If08b2b9136d55e2dddca6181c1075d845422a30b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-16 07:17:55 +00:00
Robert Löhning
a1eb505fbd Squish: Use Qt 5.14 in tst_openqtcreator_qbs
Change-Id: If214c32a0a62ebdada455a325ad1b2d02adc67c0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-16 07:17:37 +00:00
Christian Stenger
64e438ed83 Docker: Implement directoryEntries alternative
Use 'find' on a docker image to search for diretory entries
if it is available.
If the find call fails we still may fallback to using 'ls'.
This silences currently active soft asserts regarding the
usage of sort or file filters when we are able to use 'find'.
Only support the most common and currently used options and
bark if some unsupported option is in use.

Task-number: QTCREATORBUG-26258
Change-Id: I9a082ea7aca1b6db7dcb668cfe40ed0ed48cd567
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-16 06:18:59 +00:00
Leena Miettinen
4b678f50bb Doc: Update first part of entry-level tutorial
Task-number: QDS-5001
Change-Id: I2520d843a292f80473411ee94df8253bb097b22f
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-09-15 16:11:25 +00:00
Cristian Adam
3f0a54d41c CMake: Add option to link with Qt
The named option is BUILD_LINK_WITH_QT, which when set to ON will
generate the QtCreator.ini file needed for Qt Creator to find the
installed Qt.

Change-Id: If3a47a463510fbfc90a314829378c6c4e505d2f7
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-09-15 14:26:27 +00:00
Henning Gruendl
aa0a682c11 QmlDesigner: Fix floating dock widget behavior
Fix floating dock widget being covered by the main window if not having
focus on macOS.

Task-number: QDS-3144
Change-Id: I25230819a567a5582b97a0a52f0e46594dbab6ea
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2021-09-15 14:05:44 +00:00
Jarek Kobus
844cfe70b7 Valgrind: Fix parsing of remote pid
Before we have matched actually "grep valgrind" process pid
and the intention was to match valgrind process pid itself.

Change-Id: I87576aa6fcf4ac302feb28f046421f7c21c1bcb4
Reviewed-by: hjk <hjk@qt.io>
2021-09-15 13:04:33 +00:00
Artem Sokolovskii
464f665735 FilePath: Add const to iterateDirectory
Change-Id: I49c1366ca16ca295d0f54a17740a501a6d7a9442
Reviewed-by: hjk <hjk@qt.io>
2021-09-15 11:41:07 +00:00
Assam Boudjelthia
a2b6dba0bc Android: fix for retrieving the path to deployment file and build dir
The Android deployment file for CMake project was constructed based
on the main project target and thus was always expecting the file
to be under the build folder root path. This makes sure the correct
path to the output path is retrieved.

This practically different problems with running examples when the
main project is a Qt module, for both qmake and cmake.

Fixes: QTCREATORBUG-25793
Change-Id: I5fdedd94c7c4c84c351c28476ca14b0f95f99f22
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2021-09-15 11:02:21 +00:00
Artem Sokolovskii
d543ab0fbd FilePath: Add function which iterates through the directory
Change-Id: Iaebd2b08341781307b98b6aae61b0b44b127ce18
Reviewed-by: hjk <hjk@qt.io>
2021-09-15 10:51:45 +00:00
Eike Ziller
342a24d56a Merge remote-tracking branch 'origin/5.0'
Change-Id: I0ef7cd302ba7cba64fec401f3426dd682b8dc036
2021-09-15 11:18:11 +02:00
Christian Kandeler
1206ac03cc LanguageClient: Do not update semantic tokens on every document update
Due to the potential cost of the re-highlighting procedure, we'd like to
delay the semantic tokens update request to a time where the new token
information won't get invalidated right away due to further document
changes. While the document updates in principle have such a delay
already, it is often "sabotaged", for instance due to auto-completion
requests which require the server to know the current document contents
right away.
Therefore, we request new semantic tokens along with a document update
only if it's the "regular" delayed one, and otherwise add an additional
delay.

Change-Id: I074647d1cdfdbcc6aa5fc5ec2a2d5ae6ccd493ba
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-15 09:12:18 +00:00
Christian Kandeler
2b09c81682 TextEditor: Handle context help requests like tooltip requests
That is, don't just ask one random hover handler, but try all of them
and use the best one.

Change-Id: I38d0a90e96090c56240314a90f0f428c88fd222c
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-15 09:11:29 +00:00
Eike Ziller
dc71f32483 Change log: Move item to right category
Change-Id: I913fa52d6d5c9f0d3935f732ccbfd0c26a1a8c54
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2021-09-15 08:45:47 +00:00
Eike Ziller
9121372f9c macOS: Remove absolute RPATH from clazy-standalone
Remove the absolute RPATH to somewhere on the build machine,
which creates issues when loading Qt Creator on macOS 10.14,
and of course is bogus in any case.

Fixes: QTCREATORBUG-26196
Change-Id: Ic92deb9b2c6fe32f377fc31004779a2a43794054
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-15 08:33:07 +00:00
Eike Ziller
e8c6a0d470 Update change log for 5.0.1
Change-Id: Ie2beddeee91bedcb505641f52433fb170d191789
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2021-09-15 08:17:49 +00:00
Christian Stenger
0f58258e04 AutoTest: Silence soft assert
We synchronize the test tools now earlier and may
not have finished setting up the configuration of
the current project.
This means the project might have no valid target
yet.
Amends 481070d808.

Change-Id: Ic0c1817318a343e68587930c492397a6094a4ce2
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-15 08:13:54 +00:00
Piotr Mikolajczyk
41f4313012 Add const to getters
stdErr, stdOut and exitMessage made const

Change-Id: Ia84d1441d632e4e08c24f817c6bdf742c154bed7
Reviewed-by: Alp Öz <aoz@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2021-09-15 07:52:35 +00:00
Leena Miettinen
2c5672a3c7 Doc: Remove Cluster Tutorial docs
The videos were removed.

Change-Id: If6812255fada581ca98aecbc4c5079e21bd1677e
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-09-15 07:14:45 +00:00
Eike Ziller
877bfa4056 Add FileSystemWatcher::clear()
Change-Id: I9f28e763c943a6d8c5cf3082755e64d7e4df7155
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-09-15 06:40:38 +00:00
Mahmoud Badri
7fe61d1f97 QmlDesigner: Provide a descriptive message for invalid IDs
Fixes: QDS-5044
Change-Id: I12f78851f5200e417fe6f323a0773587400cd90f
Reviewed-by: Johanna Vanhatapio <johanna.vanhatapio@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-09-14 18:47:54 +00:00
Christian Kandeler
30cbda2b2d LanguageClient: Improve use of Client::m_documentsToUpdate
In particular, calling keys() and then take() for all the keys is
wasteful (and obscures what's going on).

Change-Id: Ic66803cf3579a39c23c32f1fc65e2c9399dcc583
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-14 12:50:22 +00:00
David Schulz
e397394090 CMake: skip auto-setup.cmake for docker kits
Change-Id: Iaf9e98f8368167b0e665687a118f29d196c20941
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2021-09-14 12:30:41 +00:00
Eike Ziller
1d466499f6 Fix bug in mime type magic rules with Qt 6.2
There was a bug in the copying and comparison of mime magic rules, that
did not copy/compare the sub-rules.

With Qt 5 this was probably never actually used, because we save the
magic rules in a QList, and that didn't use MimeMagicRule as "values",
but internally used pointers to heap-allocated objects, so e.g.
appending a list of rules to another list of rules would only copy the
pointers to the actual objects (as long as the items were never
modified).

In Qt 6, QList has the same semantics as QVector, so MimeMagicRule is
actually used as values, which uses the copy operations. As a result,
the moment the MimeMagicRule was copied from the parser to the mime
type, it would loose its sub-rules. Which breaks the whole mime magic
logic, and leads to wrong mime type resolution, e.g. for *.ui files.

Change-Id: I90c46264423f18f73a6efc01887a0b8b6199d35d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-14 12:21:34 +00:00
David Schulz
1831a7a6ad Core: use default icons for remote FilePaths
Change-Id: Iecf4b7c9498bd7f3ddca9455b2e5b9886e86628f
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-09-14 11:44:54 +00:00
Christian Kandeler
268f4ac406 LanguageClient: Merge adjacent change events
This saves a lot of data going over the wire.

Change-Id: Iac1220c72797643ba09bf90b02f7b5155cda4b0f
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-14 10:05:10 +00:00
Christian Kandeler
719f51445e ClangCodeModel: Use dedicated completion assist provider for clangd
The pure LSP-based implementation is too inflexible with regards to
activation characters.

Change-Id: I386a60b80f59e1b48254d55c2a47f1a1ffe1f97f
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-14 09:11:33 +00:00
Artem Sokolovskii
a1cb438fdf QtWizard: Fix qmake and qbs build for Qt6.2
Change-Id: I250e02ade6df908b0c6e200b6ea3f0b8d5bac4e4
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2021-09-14 09:00:46 +00:00
hjk
d1478a94be ResourceEditor: Use more FilePath
Change-Id: I1bc1582243104ec55ad1dd5c365d22565d332cb9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2021-09-14 08:36:01 +00:00
Christian Kandeler
50046dbc54 CppEditor: Fix "decl from def" quickfix with templated return type
We must treat return and parameters types of the function differently
from the function itself with regards to template parameters. This was
already done for parameters, but not for the return type.

Fixes: QTCREATORBUG-26248
Change-Id: I44cf6f0bda7b5e3c38f9f73e13f51f2c12ab7dc4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-14 08:22:27 +00:00
Christian Kandeler
1faff324cd LanguageClient: Remove spurious declaration
Change-Id: I400d446172680e7ee5ec6764a46faf8e2fee5baa
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Alp Öz <aoz@qt.io>
2021-09-14 08:21:30 +00:00
David Schulz
af4b84b52b ModelEditor: replace QFileInfo api with FilePath
Change-Id: I3081932e679c3f0b70e0a476fae887ff332d5b14
Reviewed-by: hjk <hjk@qt.io>
2021-09-14 07:44:29 +00:00
hjk
f6f7f410dd Utils: Remove Utils::FileUtils::renameFile()
There's FilePath::renameFile() nowadays.

Change-Id: Id37f24910f0c608ccfa6e52c5608c6707353a073
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-14 07:22:45 +00:00
hjk
64324db662 Utils: Remove FilePath::isChildOf(QDir) overload
After replacing its use in the two remaining places.

Change-Id: I6900ccdaf4ba4cf035e59b1222f06b037e7da512
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-14 07:22:08 +00:00
David Schulz
7acb8e90f3 CMake: create generated file paths without QDir::cleanPath
Change-Id: I49913032fb95aff8357da7aa077eabd5907d53ca
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2021-09-14 05:07:52 +00:00
David Schulz
3369948b1a CMake: use FilePaths to generate relative source entries
Change-Id: I5df67517e269d650166f72a625e5835e780fca9d
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2021-09-14 05:07:46 +00:00
hjk
4aea533fe5 Utils: Remove compatibility typedef SynchronousProcess
Change-Id: Iad80129668142bd518fc8c88bf03a7b3afd8be47
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Alp Öz <aoz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-09-14 03:29:08 +00:00
hjk
cb4f75426d ProjectExplorer: Remove one constructor overload of DeployableFile
Change-Id: I87e444349129e9370b5fec505444723d36e21448
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-09-14 03:28:48 +00:00
The Qt Project
e65827c04a Merge "Merge remote-tracking branch 'origin/5.0'" 2021-09-13 17:06:43 +00:00
Eike Ziller
3d4d7c7e14 Merge remote-tracking branch 'origin/5.0'
Conflicts:
	src/plugins/clangtools/clangtoolssettings.cpp
	src/plugins/clangtools/executableinfo.cpp
	src/plugins/clangtools/executableinfo.h

Change-Id: Id8caf63e3e594792467d3447870086bd2d8f73b9
2021-09-13 17:03:55 +02:00
hjk
64f439fdaf Utils: Sprinkle [[nodiscard]] across FilePath API
Change-Id: I896a08df417acd113c0953edb78edd364da5265e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-09-13 13:57:13 +00:00
Artem Sokolovskii
c941f7d0f5 Font settings: Add import and export functions
Fixed: QTCREATORBUG-6833

Change-Id: I23eec56aeb53ed10dd7f04c071318f5cc335b14e
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-13 13:11:36 +00:00
Andre Hartmann
c572ca0e87 VCS: Remove unused local variable
Why didn't this give a warning?

Change-Id: I866aa5ddf3107866bcf5da395f1312e50e75561c
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2021-09-13 13:08:07 +00:00
David Schulz
0057c73080 CMake: use FilePaths to parse source and build dir
Change-Id: I59523a525fd07402e3ade6cd6b7eaee69aa5abe0
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2021-09-13 12:59:46 +00:00
David Schulz
ed8b87d4f6 CMake: correctly track remote cmake files
Change-Id: I6685ed7ba77282d9d5154ba4192841f5bd093783
Reviewed-by: hjk <hjk@qt.io>
2021-09-13 12:59:33 +00:00
Christian Kandeler
99790aaa42 CppEditor: Do not format strings in the basic highlighter
... if a semantic highlighter is available.
Otherwise, raw string literals can introduce formatting artifacts, in
particular when using clangd.

Task-number: QTCREATORBUG-26211
Change-Id: If76c173fa98188930221e89e2665b66deb91c5e0
Reviewed-by: Alp Öz <aoz@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-13 12:13:52 +00:00
Christian Kandeler
a0bf5448a1 TextEditor: Fix clearing of semantic highlights
This was broken for multi-line results, potentially erasing the
formatting of continuation lines. This is particularly relevant for raw
string literals.

Change-Id: I68092f57024422137ca5483d1be17e02294f7a9f
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-09-13 12:13:34 +00:00
David Schulz
0caa8cbd60 Docker: reset process working directory if it needs a device
Change-Id: Ided00a328279b7b82814dcbb79434063ed7ec5f6
Reviewed-by: hjk <hjk@qt.io>
2021-09-13 12:00:20 +00:00
David Schulz
8edbba43aa ProjectExplorer: Fix build dir path
Clean path on a remote path like docker://foo removes double slashes and
results in docker:/foo. Which can not parsed as a remote path by
FilePath::fromString

Change-Id: Ia7ed6ae63e609d2cb5fc2e9bc886c6fb721b4ccd
Reviewed-by: hjk <hjk@qt.io>
2021-09-13 11:18:49 +00:00
Christian Stenger
6786d585e0 Tests: Fix running dumper tests on Win
Using QtcProcess needs more setup, so use consistently
QProcess for all processes inside the dumper tests.

Change-Id: I7c09c6705c8b8d52ba7b27b054b825c4147647d3
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2021-09-13 11:18:48 +00:00