Commit Graph

80147 Commits

Author SHA1 Message Date
Jarek Kobus
12b639970f MathUtils: Add exponential interpolation
Change-Id: I58bb26a6e921cbd1f5532bddcd6a6700ff80b94f
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-28 10:45:13 +00:00
Christian Kandeler
ed06978830 ClangCodeModel: Switch off clangd persistently
... after failed machine suitability check.

Fixes: QTCREATORBUG-28441
Change-Id: Ic0fb956168204d8023ff96f92ae3fcd7cea8b0e9
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-28 10:43:43 +00:00
Thomas Hartmann
ee10ba1909 QmlDesigner: Add support for tooltip in item library
This allows to define tool tips in the .metainfo files.

Change-Id: I3236c6e9f374a052e99b18d8c3983bfd0f072162
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-11-28 10:35:25 +00:00
Miikka Heikkinen
5544cdc276 QmlDesigner: Don't create duplicate default texture instance
Whenever an operation involving an asset image would result in
creation of a new texture node, it now checks first if
a matching texture node already exists and uses that instead.

Fixes: QDS-8435
Change-Id: I3d091aafcd09afdec897bc4da79789c1d84056e8
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-28 10:20:44 +00:00
Jarek Kobus
23f53dcbda MathUtils: Add tangential interpolation
Reuse it in TaskProgress and in ProgressTimer.
Rename MathUtils::interpolate() into interpolateLinear()

Change-Id: Iff4cda1e3b8782cd26277ec75046ca5526be92c0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-28 10:07:30 +00:00
Jarek Kobus
6f299f19ac Utils: Move DiffUtils::interpolate into MathUtils
Change-Id: Iac4a21a6c760d8fbf0dce380b1a9a587a9d3468e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-28 10:07:18 +00:00
Henning Gruendl
7d13c82750 QmlDesigner: Expose realValue from SpinBox
Task-number: QDS-8191
Change-Id: I265c4a95e84f6ef10a4c69f9a0089970f16f4bbf
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-28 10:06:25 +00:00
Henning Gruendl
62d86837e9 QmlDesigner: Fix states editor none visual items
When using any none visual item as root (e.g. Window) which don't have
a state property the support for adding a state on the root item needs
to be deactivated otherwise QtDS is crashing. The new states editor was
missing that.
On the other hand the use of StatesGroup with none visual items is
supported.

Change-Id: I194913719a13099ce8ac7cde5f78083ef84dc37f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-11-28 10:06:08 +00:00
Mahmoud Badri
ea55e01051 QmlDesigner: Focus material browser's sections separately
Focus is shown by a thicker selection border for material and
texture items. Delete shortcut works on the selected focused item.

Fixes: QDS-8401
Change-Id: I1ddbbd595a0da3f0e2b7cf2bb9e611532770bc3c
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2022-11-28 09:32:58 +00:00
Eike Ziller
ef6bf3cb52 UpdateInfo: Merge "new Qt" and "updates" available
if both are availabe. Instead of showing two info bars, show just one
with a combined title.

Change-Id: I31c1c53459209492c5f62277829bc761a36f63a1
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2022-11-28 08:46:15 +00:00
Fabian Kosmale
d15c102af8 InfoBar: Do not synchronously delete widgets in update
Deleting the widgets can trigger use after free errors if those widgets
are stil supposed to handle events.
This can for instance be observed with an ASAN build of Qt when pressing
the "Link Qt" button - the button still has a pending MouseReleaseEvent,
when update is called, and by deleting the InfoBarWidget that contains
the button, we run into the use-after-free.

That might also be relevant to the comment about a "complictated crash"
in infoBarDestroyed.

Change-Id: I9f807aa26db1169a5a749692922e580dc5874254
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-28 08:34:34 +00:00
Tim Jenssen
98a40b3690 CMake build: Make errors of execute_process fail the build
Instead of silenty failing and resulting in broken builds/packages.

The property is only available since CMake 3.19, so limit the feature to
that.

Change-Id: I82b06e78540e81a809f7fdfe130648becfc9672e
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-11-28 08:29:42 +00:00
Miikka Heikkinen
ddecd338a8 QmlDesigner: Unify texture image providers
Texture editor, material browser, and UrlChooser all had separate
texture providers that served nearly identical purpose.
Unified all use cases to use same PropertyEditorImageProvider.
This provider is asynchronous, which combined with enabling caching on
Image elements, significantly improves responsiveness of the material
browser UI when there are many textures shown in the browser.

Fixes: QDS-8387
Change-Id: I2888aee2f4320dba9456fa046c9ede319673a3d9
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-25 15:31:04 +00:00
Eike Ziller
e24ad7ac55 JSON wizards: Print parsing issues only with -customwizard-verbose
Some wizards will miss required components when corresponding plugins
are disabled. That is fine, and not an error per se. When actually
developing a wizard, these kind of errors should of course be posted,
but that is what -customwizard-verbose is for.

Fixes: QTCREATORBUG-28502
Change-Id: I3647d37ef7ca4dace7592c5443bdd13720290016
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-25 15:04:52 +00:00
Miikka Heikkinen
3a899b34c7 QmlDesigner: Skip imported files that already exist and are the same
When importing files to project, if the target file already exists
and has the same modified timestamp, silently skip copying the file
instead of asking if it should be overwritten.

Fixes: QDS-8402
Change-Id: If963e997c6bcfb3e46db6e74c46081784bdddc7e
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-25 14:54:22 +00:00
Miikka Heikkinen
674ad1ead1 QmlDesigner: Fix compiler warnings
Removed unused code.

Change-Id: I40f94b6be1f9a1700c4024e78bae5df67513c839
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 14:51:42 +00:00
Christian Stenger
c210ffb2d6 AutoTest: Fix debugging of gtest based tests
Amends 6ae6390661.

Fixes: QTCREATORBUG-28504
Change-Id: I7617b080f4ac872c1f806a8e89fa9084a0ac948f
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-11-25 14:47:25 +00:00
Tim Jenssen
c071547aa5 qmljs: fix warning
Change-Id: I69714d6626d9135c5489258346f79b1c4bfbcd19
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-11-25 14:47:20 +00:00
Samuel Ghinet
907a64ac32 Fix bug: drag state remain on after dragging asset to texture
Task-number: QDS-8341
Change-Id: If9bc7c0e3f2e017df4fde2cf94e7ffc168644eef
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-25 14:27:03 +00:00
Jarek Kobus
133099aa81 AbstractRemoteLinuxDeployService: Simplify internals
Change-Id: Ib24c00405f863788f3b72107891193b566feb3e7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 13:35:34 +00:00
hjk
49d6456b66 CppEditor: Remove WorkingCopy::get(QString) overload
... and fix fallout.

Change-Id: I8fe67616f8f327428b1c166ae69ec34c2924ee9f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-25 13:34:34 +00:00
hjk
9ceaf39929 CppEditor: Remove WorkingCopy::{revision,source}(QString) overloads
... and fix fallout.

Change-Id: I3748d0f90345c0d92321d465abfc3d324ee49a0c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-25 13:34:17 +00:00
Jarek Kobus
f2f1b7c2d7 AbstractRemoteLinuxDeployService: Refactor API
Instead of implementing two virtual methods:
- doDeploy
- stopDeployment
provide just one to be implemented:
- deployRecipe

The new method returns task tree description enclosed in
Group recipe. The abstract deploy service constructs the
TaskTree when needed, applies the recipe and starts the tree.

Change-Id: I36e52935f98736dafeea6be32fde5595410db077
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 13:33:47 +00:00
Jarek Kobus
bec3b9279b CustomCommandDeployService: Reuse TaskTree
Change-Id: I9ed0a9279bbbf88b810331e100c7799191d93602
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-11-25 13:24:42 +00:00
Jarek Kobus
c01ab460c8 QdbMakeDefaultAppService: Reuse TaskTree
Change-Id: I03ee1935e7b0b0cc82f139f7f435d3194ff29f01
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 13:21:41 +00:00
Jarek Kobus
9e810acfbe QdbStopApplicationService: Reuse TaskTree
Change-Id: I6086ccda3b3b5489f9553fbd2cb7c7b8950e17f9
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 13:18:39 +00:00
Jarek Kobus
2853d39065 KillAppService: Reuse TaskTree
Change-Id: I250542724d537219a8c1ce222d7e941474671adf
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-11-25 13:18:16 +00:00
Jarek Kobus
0c18fbc31f ProjectExplorer: Provide task tree adapter for DeviceProcessKiller
Change-Id: I45133dcba07d5fc5fa721c0af13ba86f75985a5e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-11-25 13:17:48 +00:00
Jarek Kobus
c99dd6650d UpdateInfoPlugin: Readd vanished comment
Amends d4871731bd

Change-Id: I34288f977ac913a77c98a201873783d3d879369d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-25 13:08:45 +00:00
Jarek Kobus
c38a00513e ProjectExplorer: Introduce DeviceProcessKiller
It will be much easier to integrate it into TaskTree,
comparing to hierarchical DeviceProcessSignalOperation.

Change-Id: I6bc9580a3d88d7bfd01e641b09094c6fa8fb94d3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-11-25 13:03:52 +00:00
Jarek Kobus
d4871731bd UpdateInfoPlugin: Reuse TaskProgress
Change-Id: I35ad1005adb269d016b35fabfbccf27e92d3dfb9
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-25 13:03:36 +00:00
Jarek Kobus
7afe536a5c AdvancedDockingSystem: WorkspaceDialog: Use Layouting
Change-Id: I998147908941b4390c810983a5676628f07b1250
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-11-25 12:56:15 +00:00
Jarek Kobus
bcdfe1cedc TaskProgress: Add missing features needed by UpdateInfoPlugin
Change-Id: Iabfbebd07699fbe45da6007347ed45517d593cfd
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 12:49:19 +00:00
Jarek Kobus
d90b1946d4 TaskProgress: Improve fluency of progress
Change-Id: I8efb0242c035223bb52cb2684a30b57f44b489f2
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2022-11-25 12:49:14 +00:00
Eike Ziller
cb8742ccab Make it possible to select default session from menu
when we are in the limbo state where no session has been loaded, and the
default session has not been explicitly created or loaded yet.

Fixes: QTCREATORBUG-28393
Change-Id: I66d69561e18b5073a477d90c1926074e3cd97cee
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-11-25 12:37:40 +00:00
Jarek Kobus
16f671874f BuildStep: Remove unused runInThread() and cancelChecker()
Change-Id: I9d4a858a25ab93b17f1018cecc785b42dd76ecc0
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-11-25 12:15:32 +00:00
Jarek Kobus
1e632d0c25 AndroidDeployQtStep: Make it cancelable
And use QFutureInterface for it.

Change-Id: I1145b70b119d92af7316977c813f4f29b1f20b74
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2022-11-25 12:15:18 +00:00
David Schulz
3cd3bba720 Debugger: update thread selector after setting current thread manually
The issue is only reproducible when interrupting a running inferior with
cdb.

Change-Id: I336413d7f36aad28108623eb1bf8015b42f3dbb4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-25 12:13:45 +00:00
Thomas Hartmann
21c659400a StudioPlugin: Use custom openOpenProjectDialog() to only allow qmlproject
Task-number: QDS-2549
Change-Id: I7393877b5f0306eafc6dbd5b5919e6592e664c16
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2022-11-25 11:59:40 +00:00
Thomas Hartmann
caccbe8377 QmlDesigner: Rename setting to avoid any interference
Rename setting to avoid any interference
with old installations.

Change-Id: Id8cb3ad4a3be6e416c4ad935856c57fc29c07503
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2022-11-25 11:59:25 +00:00
Orgad Shaneh
4225f475a4 FilePath: Do not strip macros when normalizing path
Fixes: QTCREATORBUG-28484
Change-Id: Id6bcd2aef048bd355c196013c54799e4944135bd
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2022-11-25 11:57:04 +00:00
Samuel Ghinet
056165d071 Use double underscores instead of single ones in QML
Also, fixed some QML errors -- they didn't have any real consequence,
so they could be considered warnings. Also, AssetsView._modelIndex()
was being called with two arguments instead of one -- this didn't
result in any warnings.

Change-Id: I08274a49531a4082fa94fb89e4230fdac5b1b658
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-25 11:57:02 +00:00
David Schulz
ead1b7aa4a Editor: extend visual whitespace documentation
Tell users where the color of the visual whitespace can be configured.

Task-number: QTCREATORBUG-28501
Change-Id: I9c12cbe9d7be61dd96ad27c1eaa1a2daf69cf31d
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2022-11-25 11:51:44 +00:00
Samuel Ghinet
afc7cd2c98 QmlDesigner: Use a vertical scrollbar for "Confirm Delete Files"
Also, replaced the widgets code with QML.

Task-number: QDS-8033
Change-Id: I29f4e0bc02294e839e352096c3d4394a764cfe76
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2022-11-25 11:50:42 +00:00
hjk
038771051d CppEditor: Switch to FilePath in IndexItem
... and fix fallout.

Change-Id: I45d27146806bdcb5ceb728b710eca51c7cd32ee2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-11-25 11:16:38 +00:00
Mahmoud Badri
6747e666b9 QmlDesigner: Open TextureEditor by double-clicking a texture
Change-Id: I58645f31f244cf4e5909b35f1cae224a55f4e9a4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Samuel Ghinet <samuel.ghinet@qt.io>
2022-11-25 11:02:42 +00:00
Samuel Ghinet
45c7a6b8e6 Implement drag-and-drop from Assets View to Texture Editor
The asset (i.e. image) can now be dragged to the "Source" property of
the Texture Editor.

Task-number: QDS-8341
Change-Id: I2d30bdf245a8328a864c116c727d3faaaad347cc
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-11-25 10:57:55 +00:00
Christian Kandeler
0f202ea724 ClangCodeModel: Restrict opening non-project files to headers
We cannot tell clangd to opt out of indexing for certain files, so we
must prevent "foreign" sources from ever getting opened, or we will have
strange effects in the case of non-unique symbols.
Note that there are more (upstream) problems in this area, but this
patch limits the damage at least.
Amends 8ad7ab2d2a.

Fixes: QTCREATORBUG-28452
Change-Id: I131be699a35da8eacea6415c630e9012cc905a47
Reviewed-by: David Schulz <david.schulz@qt.io>
2022-11-25 10:21:21 +00:00
Jarek Kobus
dbdabf9c27 Use M_PI for 3.14
Change-Id: I19078a791afa1c74cd34e59b033525e029755d7e
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-11-25 10:10:37 +00:00
Leena Miettinen
1966591c7f Doc: Use fixed links to Qt 5 Graphical Effects
To suppress qdoc errors.

Change-Id: I48556e98c7f58d9f0b59ad47051bf166edf50387
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2022-11-25 10:02:52 +00:00