Commit Graph

68568 Commits

Author SHA1 Message Date
Christian Kandeler
23fb4449f1 ClangTools: Let users disable checks from text marks
Fixes: QTCREATORBUG-25622
Change-Id: Ied5ca0fca65cd12a2df7744ffc2043dc9686c973
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-04 12:45:30 +00:00
David Schulz
ffd9b7415d TextEditor: Fix snippet variable index overflow
Change-Id: Ifd224c33d5ffe56e22b85d8c1959448154d550b1
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-04 11:21:50 +00:00
Christian Stenger
1e019b1c1e TextEditor: Fix compile with Qt6
toStdList() has been removed in Qt6.
Amends a2dadb3d0b.

Change-Id: Id2032d7e0a0c3345614bc56d98152c41f199af07
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-04 11:21:44 +00:00
hjk
4c375e31a3 Python: Replace a use of SynchronousProcess
Change-Id: I93ce9a3224c88c69c3b0ef46f1416645ffca1e1e
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-04 09:55:47 +00:00
Christian Kandeler
90ff9be54a Find: Stop at the root item when updating the "checked" status
... of search result items.
Otherwise we're breaking assumptions elsewhere.

Fixes: QTCREATORBUG-25662
Change-Id: I9dce79bd58ada02988741741c09e4ce42cc7af03
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-04 07:30:10 +00:00
Christian Kandeler
6fbe88b215 TextEditor: Queue call to ICore::showOptionsDialog()
... from text marks.
Direct calls appear to be unsafe, possibly because text marks are
transient.

Fixes: QTCREATORBUG-25623
Change-Id: I929ff6310c9d93b677f66acc8869e7aeceb5564b
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-04 07:27:59 +00:00
hjk
dec9169efe Utils: Move SynchronousProcess::normalizeNewlines to QtcProcess
Change-Id: I5ba8ba1061b04b032aafd08382d34ccb62272829
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-04 07:19:55 +00:00
hjk
196b7b0f24 ClangTools: Use Utils::CommandLine for a command line
Change-Id: I489e5538fe97e7d565eed22af8d285d89b870ca3
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-04 04:38:17 +00:00
hjk
0f61bdc04f Utils: Base TerminalControllingProcess on QtcProcess
This here is a step towards making SynchronousProcess interface more
similar to QtcProcess with the final goal of unifying them.

TerminalControllingProcess is just an implementation details of
SynchronousProcess, which in turn is mostly used in Android and
VcsCommand, e.g. for 'git blame' (good test...)

In the light of 04b20a1a46 /
QTCREATORBUG-21547 and the potential need to bisect later this here
is a first baby step.

Change-Id: I48e57d9fdb7c37eb0d2a5c5eef8643d6be97c3cc
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2021-05-04 02:50:39 +00:00
hjk
dbf80d5fe2 ProjectExplorer: Whitelist DockerDevice for DesktopRunConfigurations
The idea is that "everything" that can run on the real local host also
can run in a docker container mimicking the same kind of environment.
I.e. all run configurations suitable for current "Desktop" would/should
also be runnable in a docker container, ideally without noticing.

_Desktop_RunConfiguration would then be a bit of a misnomer, it's more
"things that act like 'desktop'", but that can easily be changed later.

Change-Id: I0b284135202e64b54ee86a3815efa95d75a5e29f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 15:13:43 +00:00
hjk
a13eeae6f3 ProjectExplorer: Code cosmetics in desktoprunconfiguration.cpp
Change-Id: If5ccd9369817a2f87c7ad3b87b88e8705e110d25
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 13:56:19 +00:00
hjk
ebd8d520fc ProjectExplorer: Make AbstractProcessStep::doRun() tests work remotely
By funneling file system accesses through Utils::FilePath.

Change-Id: I13a3aac23bd5fc301edf5e5c52e0c7ebd1e6ca6c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 13:38:05 +00:00
hjk
6182f39b06 ProjectExplorer: Avoid one use of SynchronousProcess for ps output
Change-Id: I9b78810899f6d2c608092295ceef570bc136816d
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 13:37:52 +00:00
hjk
779e572ea3 QmlDesigner: Replace SynchronousProcess use in BuildableHelperLibrary
Change-Id: I064d0c53116b1f657c1b1d301b4de3e337ba9eaa
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 13:33:49 +00:00
Cristian Adam
4c2e7f4adc GitHub Actions: Update Clang to version 12.0
Change-Id: I6204f4a2a5142fff9e498dbb9fba5531f152fbc4
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-03 12:51:50 +00:00
hjk
84fbb9f605 ClangTools: Remove some use of SynchronousProcess
Change-Id: Ifaf8979f5e3d2799002322580c8cb6982c099921
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 12:32:07 +00:00
Ivan Komissarov
978f6caf1e Update Qbs submodule to the top of 1.19 branch
Change-Id: I0b62527b7fb56aad3f7696ce4356b2b4090c89a2
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
v4.15.0
2021-05-03 12:07:46 +00:00
hjk
a64ccab53d Utils: Replace some SynchronousProcess use in BuildableHelperLibrary
Change-Id: Id3b4b70b3ef29dfa8ff2eebb5b36d7213ecc8b66
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-03 12:06:04 +00:00
hjk
a9da8723fb Perforce: Avoid one use of SynchronousProcess
Change-Id: Iafa9fcbcd8e902b4fb28834f19bf0c31e3bb9149
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 11:48:41 +00:00
hjk
ecc5c042ab Utils: Shift more code from SynchronousProcess to QtcProcess
Copy for now, original will vanish once all is ported.

Idea is still to reduce the number of process related classes.

To avoid a new dependency for qmlpuppet, handle questions to
the user only inside #ifdef.

Change-Id: Ib1354fc0370a87052b4f9c8460dfcf5d762a6c4e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2021-05-03 11:47:34 +00:00
Eike Ziller
f3e4c7112b Add output panes to Projects mode
No real reason not to do it, and build systems print output there.

Change-Id: Ie0f08e3e88e585098b097e7c983d54e2fea8c6f2
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-05-03 11:47:24 +00:00
hjk
2f593d9db9 LanguageServer: Use Utils::CommandLine in StdIOClientInterface
Change-Id: Ic2516387d7308bfad05cef54467c417cc47a7655
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 11:31:17 +00:00
hjk
e5312362c8 LanguageClient: Avoid one use of SynchronousProcess
Change-Id: I39329a68691ad084128056c34cc41554776fd18b
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 11:27:31 +00:00
hjk
ada1e68e35 Qnx: Avoid some use of SynchronousProcess
Change-Id: I4ae66efc9e09196e0ce0c08c939f1d7f1386f071
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-03 11:26:40 +00:00
David Schulz
a2dadb3d0b TextEditor: Snippet ranges refactoring
Parsed snippets are now reported in chunks of texts and variables. A
variable has a index that can be used to identify matching variables and
maybe a mangler that can be used to modify the variable when applying
the snippet.

This effictively moves the variable matching logic from the overlay to
the parser of the snippet, which is needed to implement the LSP snippet
parser.

Task-number: QTCREATORBUG-22406
Change-Id: I6999554c6c6d0f1887c98bf732473f01aa1f230c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-03 11:12:34 +00:00
Christian Kandeler
4890902abf LanguageClient: Allow for custom symbol search result handling
Change-Id: If19ce24b39820afbfd48c48493e07709f4b3633e
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 11:07:08 +00:00
hjk
2014bf472d Qnx: Some style fixes
Change-Id: I90e9bbd0bfb92f9804c38bb143b8d0690ddb8991
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-03 10:56:16 +00:00
hjk
c75c6f342e Debugger: Make findQtInstallPath remote-aware
Change-Id: I3df662a182c079725e616776befead30265f22b3
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 10:49:01 +00:00
hjk
03b2920d31 Debugger: Use QtcProcess instead of SynchronousProcess::stopProcess()
Change-Id: I6206e64e098d3490738a9c2a76ff433c990aab17
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 10:22:09 +00:00
Christian Stenger
429540bdf8 Utils: Fix Qbs build
Amends 7880950eca.

Change-Id: I9d822e5271df274e28b28806e2b90333f3f8ae16
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 10:08:46 +00:00
hjk
96569f9c63 Debugger: Fix watch time column display logic
Amends 93a580395.

Change-Id: I84b5e826ab5f9202d661e9b2736a874c767faa54
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 09:19:44 +00:00
Christian Kandeler
b4e8d32189 LanguageClient: Allow to look up the document for a given file path
Change-Id: I565ce07b28008edbc9d40178069b078ff3530744
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 07:37:41 +00:00
Christian Kandeler
c63148fa21 CppTools: Export some symbol search-related functionality
We want to re-use it elsewhere.

Change-Id: Iefd8464c56ddc8bb2fc5a3349cd833b094c61da7
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 07:24:05 +00:00
Christian Kandeler
248ebb494d LanguageClient: Expose server information
Server name and version are potentially interesting information.

Change-Id: I4fc9a2556d7fd8285fe0024cf0f83baf95112e65
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-05-03 07:23:24 +00:00
Tim Jenssen
8eb5a08c1b qmlpreview: adapt to new location of debug translation protocol
Change-Id: I6bcb6e9f18724f22b10586a6550fada991ca8678
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2021-05-03 07:17:57 +00:00
David Schulz
ec2449cae4 TextEditor: move snippet overlay into own cpp file
Change-Id: I3343d9abf19e4edc7bd88077bf8fe6666a901e1b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-03 04:11:07 +00:00
Cristian Adam
7880950eca PCH build fix when building with Clang 12
Clang 12 has added a template parameter as "CALLBACK",
which conflicts with the Windows "CALLBACK" define.

Change-Id: I773899d103dcb1a852b555a1900b2de4acb6d96f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2021-05-02 11:38:01 +00:00
Eike Ziller
24739515e5 sdktool: Use newest toolchain key when writing kit
No need to write these settings with the old key from
Qt Creator 4.3 anymore.

Change-Id: If6ece7277abea20945a56917f4bb55826f4ea769
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-04-30 12:26:52 +00:00
Eike Ziller
ed6b3f2bcd Revert "ProjectExplorer: Remove toolchain settings compatibility with <= 4.3"
This reverts commit 6baf09bf91.

sdktool still writes the toolchains with the old settings key.
This should be changed in a follow-up commit, but since we missed
updating the key used in sdktool, we have to stay compatible with that
for a longer while still, or we break lots of existing Qt installations
out there (specifically Boot2Qt, which is the main user of the sdktool
operation).

Fixes: QTCREATORBUG-25647
Change-Id: Ie665c9db5fd5bb808f510c53fd4173b8a318bb7c
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2021-04-30 12:04:52 +00:00
Christian Stenger
0bcb5953ed CMake: Ensure test defines are present for tools as well
Fixes the sdktool auto test.

Change-Id: I9e1779dc17a0cb79131e17182290255aed2f7d0e
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2021-04-30 11:22:05 +00:00
Christian Stenger
db428da751 Docker: Fix qbs and cmake build
Change-Id: I61310e2736e9b5960620c1d55b268f57644b9832
Reviewed-by: hjk <hjk@qt.io>
2021-04-30 10:32:02 +00:00
hjk
dcba96d16e Utils: Copy some SynchronousProcess function to QtcProcess
Start using it in Utils::Archive.

The idea is to merge SynchronousProcess into QtcProcess (or avoid its
use) to have fewer classes to make "remote-aware".

Change-Id: Ieb08f6f66eab63fd058b75e3bafa79bfbf140387
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-04-30 09:16:28 +00:00
hjk
fe8fbf1a4a Utils: Add a synchronous property to QtcProcess interface
Use it to avoid IDevice interface clutter.

Change-Id: I4a04f04e2c343593d937a402060e56ef94fcabf1
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-04-30 09:16:12 +00:00
hjk
ba36cbfdaa Docker: Implement some DockerDevice functions
Container file system accesses are primarily done through the host
file system by prepending the appropriate path.

This is Linux-only, and only in case the volumes are mounted to
the same relative location in the container.

As a fallback, provide the functionality also via 'docker exec'.
This is, however, too slow to be used in the future.

Change-Id: I23185ae45184cb7b1de7c723a01ab96fe9c0801e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-04-30 09:15:08 +00:00
Christian Stenger
c362df32ee Unittest: Fix writing CppTools.json in cmake build
Do not write additional garbage into the json file as this
will end up in a parse error.

Change-Id: I02783b5e94b016d35962ee5729d53bc218d42b42
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2021-04-30 08:18:08 +00:00
Christian Stenger
402231c5d9 Tests: Fix build
Amends 509f40825a.

Change-Id: I4eaca8f1ad43ab8f3e5e92d313de334f42ed4905
Reviewed-by: hjk <hjk@qt.io>
2021-04-30 08:17:59 +00:00
hjk
574de2eb2a ProjectExplorer: Adapt default make command to actual device
Change-Id: I40b9f0ee85b91b95d0b16e62e20c7c8c0ec8b77e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-04-30 08:01:26 +00:00
hjk
31f6b6fbe3 ProjectExplorer: Fix gccInstallDir detection on devices
Change-Id: I5a7085a03304c1e90c7e81686578fa4d98857670
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2021-04-30 07:58:57 +00:00
hjk
4564b2c36c Git: Avoid one use of SynchronousProcess
The synchronity was not used anyway.

Change-Id: I9e724d7c01e7e89c12954ac9e2b213c65302d942
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2021-04-30 07:58:43 +00:00
Thomas Hartmann
f22ae0a726 QmlDesigner: Support QtQuick 6.0 import
Change-Id: Ie6e752d58fb5a0c7989ab5c47166c6d08937d8d5
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2021-04-29 20:46:58 +00:00