Commit Graph

85691 Commits

Author SHA1 Message Date
Thomas Hartmann
87df3f1307 QmlDesigner: Catch exception when refactoring id
Task-number: QDS-11576
Change-Id: I1081be20e0885fc460852e1d51cb7e85cab73a99
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-01-05 07:18:21 +00:00
Jarek Kobus
bc3e30e7ec Process test: Fix flakiness on linux / mac
Since it's not clear why the flakiness existed, leave a TODO note.

Change-Id: Ief1104870c008e056d5b87880b508fd66266bce4
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-01-04 20:44:38 +00:00
Artem Sokolovskii
b3bdbf395b LanguageClient: Add mimetype for .clangformat
It enables language server functionality for .clang-format files.

Change-Id: I911a254c777b4b5e15a73bf0abdb273156a0d0c7
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-04 15:09:44 +00:00
Jarek Kobus
fc4a9a3897 DapEngine: Avoid using keys()
Iterate directly over container instead.

Change-Id: I6b7b6ba13f5fb3d7feeb0030fc2cc0d92e949e73
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-04 15:02:30 +00:00
Jarek Kobus
f53db77230 GuiUtils: Rename attachWheelBlocker into setWheelScrollingWithoutFocusBlocked
This name corresponds better to e.g. SH_ComboBox_AllowWheelScrolling,
SH_TabBar_AllowWheelScrolling or wheelScrollLines.

Change-Id: I244774584e293ca45cc4be4d4526f925c2da9598
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-04 14:15:32 +00:00
David Schulz
a4f9267df1 TextEditor: avoid creating an highlighter to check a type
check the type after construcing the highlighter instead and save that
information.

Change-Id: I7d942dae4be8471dba90dd266267ff7fa1b6f440
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-04 12:38:44 +00:00
David Schulz
e1535f5f39 TextEditor: simplify SyntaxHighlighterRunner::cloneDocument
Change-Id: I2cf2673bd79dd92de43392dc890f4f7482b483f6
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-04 12:38:39 +00:00
Eike Ziller
6831e11c3e Markdown: Add anchors for headings
It looks like GitHub creates heading IDs by

- converting spaces to '-'
- removing anything that is not '-', '_', a number, or a letter
- converting to lower case

Task-number: QTBUG-120518
Change-Id: If09a8e2e0d964e751869eaebd3326a6f983ac495
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-04 12:25:07 +00:00
David Schulz
76ec7e1599 TextEditor: use blocknumber instead of position to identify blocks
It is used more commenly in the code for that purpose.

Change-Id: I48112d2c80485d204137da36fadbe85ad1db802b
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-04 11:55:37 +00:00
David Schulz
562cf9eb4f TextEditor: simplify SyntaxHighlighterRunnerPrivate contruction
Change-Id: I40e4df9f56b67f550e74c463b2f98a15740eb43b
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-04 11:54:50 +00:00
Jarek Kobus
3a53648209 GuiUtils: Make wheel blocker transitive
Instead of consuming the wheel event, pass it to the target
widget's parent. This should allow for further scrolling
the possible parent scroll area.

Modify the focus policy only in case of WheelFocus.

Change-Id: I00c628a9e3d7608222b0700e71469c6cef6dea88
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-04 11:22:58 +00:00
Eike Ziller
298bd125c0 Markdown: Fix that file links were shown as blank in preview
Handle links ourselves since QTextBrowser doesn't do what we want.

- anchors without file path just jump to anchor
- local files (potentially relative to the markdown file) open in
  Qt Creator (anchors ignored)
- otherwise QDesktopServices is used

Fixes: QTCREATORBUG-30120
Change-Id: I9a68607a0b32255ec075c698a1265cc6d1387e0c
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-04 10:47:38 +00:00
Jarek Kobus
e928c19d27 ClangFormat: Get rid of EXPLICIT_MOC
Otherwise it generates the following:
"No relevant classes found. No output generated."
during compilation.

Change-Id: Ia0299db40412a8ba1543f6990a728b2ac3af07ac
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-01-03 21:22:50 +00:00
Cristian Adam
d959a0c8c2 GitHub Actions: Update ccache to v4.9
Also use the upstream version since upstream has binaries for all
platforms.

Change-Id: I83e94c57149b27d54cb14390f6da678be365a2ed
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-03 16:21:27 +00:00
David Schulz
b825d97e1e LanguageClient: auto setup yaml and json ls
Change-Id: I8fff750594cfbd25a0401cd24068c89b86dcf5fc
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-03 14:04:34 +00:00
Eike Ziller
10d389f59f Merge remote-tracking branch 'origin/12.0'
Conflicts:
	src/plugins/clangformat/clangformatconfigwidget.cpp

Change-Id: I84fba4e6f952e9aca606951e7fb7763b451e35d9
2024-01-03 13:05:56 +01:00
Jarek Kobus
afd979a6d9 CMakeManager: Simplify mutable lambda
Make lambda non-mutable. Pass CMakeManager as a context object
into the connection.

Amends ed1568309b

Change-Id: I022a8c468374eaf694acd7d8dbab0579c37bd8df
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-01-03 11:17:03 +00:00
David Schulz
5117ca3280 Debugger: Adjust lldbbridge and test for lldb on windows
Since frame 0 points to the Windows DebugBreak function it does not hold
any usable locals, so we have to pass the correct frame to the
lldbbridge test infrastructure in order to get usable data.

Change-Id: I2595be87a718d73fda3429017efd564e5d0ed9be
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-03 10:06:21 +00:00
David Schulz
9f69a87523 Update .clang-format
Define the to be used schema and update various values.

Change-Id: Id99859914447825d65419b1d467e7d8cee5d69ca
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2024-01-03 06:10:55 +00:00
Leena Miettinen
acf5c2e602 Doc: Move sources for "Jump to the Code" to qtdesignstudio\src
To fix QDoc warnings.

Also, hide the topic from the Qt Creator Manual.

Change-Id: I499f338a6f4adc3fff7f6b38eb2363437f1a84d5
Reviewed-by: Johanna Vanhatapio <johanna.vanhatapio@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Pranta Ghosh Dastider <pranta.dastider@qt.io>
2024-01-02 13:56:36 +00:00
Andre Hartmann
1481012f37 Git: Better error output when gitk cannot be launched
Error messages should stand out and not be hidden within
other output.

Before it looked like this (with the last sentence in red):
```
13:24:54 Running in "/home/user/project": /usr/bin/gitk .
Cannot launch "/usr/bin/gitk".
13:24:54 Running in "/home/user/project": /cmd/gitk .
Cannot launch "/cmd/gitk".Cannot launch "gitk".
```

and now like this (also last sentence in red):
```
13:28:07 Running in "/home/user/project": /usr/bin/gitk .
Cannot launch "/usr/bin/gitk".

13:28:07 Running in "/home/user/project": /cmd/gitk .
Cannot launch "/cmd/gitk".
Cannot launch "gitk".
```

Change-Id: If165a0a2ad800fde27c7252cf8af924c55b60197
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2023-12-25 04:53:41 +00:00
Shrief Gabr
9ca5b7fea2 QmlDesigner: Fix cells' unpredictable yellow outlines
Task-number: QDS-11573
Change-Id: I00a57e39804e54ce2fc25f4430975267c61a953a
Reviewed-by: Ali Kianian <ali.kianian@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2023-12-22 13:24:59 +00:00
Dominik Holland
ca3fab3a93 CMake: Add information about all sourceFiles to the CMakeBuildTarget
Change-Id: I13b978b2cd344c499c405ce11213261bf224296a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-12-22 10:25:01 +00:00
Jarek Kobus
a2567684d0 TaskTree: Don't activate the storage when calling storage handler
This addresses one of the TODOs.

Change-Id: I46dc978f83613ecb2e5668b8c8c2f24396e0f4f3
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-12-22 09:33:50 +00:00
Jarek Kobus
778a17bb50 TaskTree: Simplify internals
Drop QSet from StorageThreadData. Drop some asserts that
require locking the mutex.

This change causes the task tree tests execute twice as fast.

Change-Id: I58f6ec509f5fdd26d7f9a95d1223fad3a790cd3d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-12-22 09:33:18 +00:00
Jarek Kobus
6af0f3cc60 TaskTree: Optimize storage activation
Drop hash lookup upon storage activation.

Change-Id: Idc963300e14ff95bb829e5942c73c409bc80b839
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-12-22 09:32:58 +00:00
Jarek Kobus
ec22f5e759 TaskTree: Adapt docs for the removed List element
Change-Id: I9adab7a12a590fac4ffb797564fe7cb8988c4584
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2023-12-22 09:32:51 +00:00
Jarek Kobus
7d3f50f784 TaskTree: Remove explicit List element
Replace it with additional GroupItem's c'tors.

This addresses the 27th point in the report below.

Task-number: QTCREATORBUG-28741
Change-Id: I7f0620993e7c9bf61868e7bc7b112eea4dae6471
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-12-22 09:32:26 +00:00
David Schulz
4b088bd226 Debugger: simpify cdb test setup
Change-Id: I196cee8fa6b35b78dae0b2e7db2c708736b39daa
Reviewed-by: hjk <hjk@qt.io>
2023-12-22 09:27:23 +00:00
Cristian Adam
aec3e7dbf2 Debugger: Enable lldb with MSVC binaries
This commit will enable running of tst_dumpers on Windows using a MSVC
setup and lldb.exe as debugger.

Change-Id: I17611cc90ba2a04ec21aae11af16f1d0ff8e894f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-22 09:25:37 +00:00
hjk
cf4f221065 CMakeProjectManager: Move CMakeIndenter class definition to .cpp
Leaner internal interface.

Change-Id: I297c74e667891efbeab0edabbfc82fb058501aa2
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-12-21 14:59:10 +00:00
hjk
bdeded45a9 CppEditor: Move CppQtStyleIndenter class definition to .cpp
Change-Id: I2803ab51bbfe6a23223d63ad28a75b732abc67bd
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2023-12-21 14:59:01 +00:00
hjk
2945dc379f ClangFormat: Dont create a style factory to only use the indenter
Change-Id: I2bfe7c7a68341a4a11439067581f5704b1388164
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2023-12-21 14:33:33 +00:00
hjk
37c9b41273 ClangFormat: Remove some unused includes
Change-Id: I8d382b91acc60f62be2055c0124704d38b3c7f46
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2023-12-21 14:33:26 +00:00
Ali Kianian
6e75d21f84 QmlDesigner: Fix lambda unique connections for CollectionSourceModel
Fixes: QDS-11572
Change-Id: I25f3cbd8b6f806c347102ddea3855c23b30bf8f9
Reviewed-by: Shrief Gabr <shrief.gabr@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2023-12-21 14:16:50 +00:00
David Schulz
0f30dcee1f TextEditor: avoid unnecessary highlighter creation
Change-Id: I6e5cdabab26eb9f2d026f073c3d3db3e299a6c80
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2023-12-21 13:18:58 +00:00
hjk
12065e70d5 Utils: Add comments to the PathChooser::Kind values
They are documented properly, but sometimes simpler to look here.

Change-Id: Ibe48a30bf0e7909c1cea1d414748a09962691615
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
2023-12-21 13:17:55 +00:00
Tim Jenssen
238bc38f88 QmlDesigner: QDir -> FilePath to get a saver removeRecursively
Change-Id: I89bf782e8e6e119de44ee4540e8d2ab7dbef738c
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2023-12-21 12:14:25 +00:00
Tim Jenssen
506ff2eea7 Utils: add more removeRecursively checks
Change-Id: I0b8bbe99132157cc5a73355c9b396201ec259aaa
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2023-12-21 12:13:15 +00:00
Miikka Heikkinen
c046dc42c1 QmlDesigner: Always render items with effects
Items with effects may lose their cached layers if they are not
rendered every frame, so make sure we always render items with effects
if anything else is rendered.

Fixes: QDS-11561
Change-Id: I7aa6542fc619e634fa06fe7c8d59fd485a150296
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2023-12-21 12:03:07 +00:00
Artem Sokolovskii
a0cc2e3c3e ClangFormat: Fix preview update
Fixes: QTCREATORBUG-30089
Change-Id: Id89e8b2ee0439c5235755256e8410f42ad94b432
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-21 12:02:50 +00:00
Thomas Hartmann
8738057967 QmlDesigner: Do not scatter pasted nodes anymore
Scattering/moving pasted nodes does more harm than good.

Task-number: QDS-10972
Change-Id: I625cf228fb688c48715152eb6471728ca7202a23
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Ali Kianian <ali.kianian@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2023-12-21 07:43:06 +00:00
Eike Ziller
7443ca977b Merge remote-tracking branch 'origin/12.0'
Change-Id: Iee11f97dbd0114957e856d02f0ad295813a05431
2023-12-20 16:05:55 +01:00
Xavier BESSON
90368e2bba QmlJsEditor: navigate from QML code to C++ code
Fixes: QTCREATORBUG-28086
Change-Id: I00acfe49b8e74aa057cb59d8c951d477f8ad487e
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2023-12-20 15:03:39 +00:00
Alessandro Portale
42c1b15874 QmlPreview: Add QML Preview button to QML editor toolbar
This adds the action from "Build->QML Preview" into the QML
editor toolbar.

Fixes: QTCREATORBUG-30078
Change-Id: I848b33f006b51866dde2565bd7f76c1eac0f3d28
Reviewed-by: hjk <hjk@qt.io>
2023-12-20 13:53:25 +00:00
hjk
f19cb7b296 CppEditor: Hide ClangdSettingsPage setup in .cpp
Change-Id: I3606e503ea512750b06a94901e5391ce6dae86e3
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-20 13:48:06 +00:00
Eike Ziller
4d3eb3d578 KSyntaxHighlighting: Remove highlighting files with unclear license
Makefiles are less relevant nowadays with CMake and Ninja, and the
Python plugin does highlighting on its own.
And users will still be prompted for downloading the highlighting files
anyway.

Change-Id: If80f1e8215375ed3985d9327c031f0c69fc15654
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-20 11:48:36 +00:00
Eike Ziller
8d0238db23 KSyntaxHighlighting: Remove unused files
The original patches for switching to KSyntaxHighlighting are no longer
used.
Remove empty readme file.

Change-Id: I6b55b63bf19a04ef16f34b4764ddfc2800959b11
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-12-20 11:48:22 +00:00
Eike Ziller
bbf02473e0 COIN: Do not try to download qtquickcontrols2
It doesn't exist anymore

Change-Id: I0bb50e0fc247022b563c370cd36cf046191c9c7f
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-20 11:48:01 +00:00
Dominik Holland
eccc244537 ProjectExplorer: Allow an extraInit function to be called
... when BuildSteps are created. Potentially useful to tweak
step behavior without the need to inherit or such.

Change-Id: I8c8e9bdec84fafc454db9dc9a492d399b00b7f57
Reviewed-by: hjk <hjk@qt.io>
2023-12-20 09:59:40 +00:00