Commit Graph

72811 Commits

Author SHA1 Message Date
Christian Stenger
9a32905bcc QmlJS: Add another static check for enum values
Task-number: QTCREATORBUG-19226
Change-Id: Ic995eee2e868bbe1953c0c33d1bab5793e07ebe2
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2024-04-15 08:54:10 +00:00
Christian Stenger
e1d90a7965 QmlJS: Improve handling of user defined enums
Improves handling of Qml based enums inside qml documents.

 * completion of enums
 * follow the enum
 * highlighting values inside the declaration
 * displaying the enum declaration inside the outline
 * minor static checks

Task-number: QTCREATORBUG-19226
Change-Id: Ia07fd9a8b7fa3106f2ea53198bfdcc50eecb7307
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2024-04-15 07:56:56 +00:00
David Schulz
ee8245d8aa Core: allow multiple contexts per widget
This makes it possible to allow different sets of actions for a specific
widget depending on the defined contexts for that widget.

Fixes: QTCREATORBUG-30675
Fixes: QTCREATORBUG-30677
Change-Id: I408e0ae445b364d4f450ccdd2fbdfc81ece45015
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-15 07:45:15 +00:00
Eike Ziller
310d3cc041 Merge remote-tracking branch 'origin/13.0'
Conflicts:
	src/plugins/remotelinux/linuxdevice.cpp

Change-Id: Iad28a1bfa4632922931d351d2fe27757cf21dec3
2024-04-15 08:33:39 +02:00
Alessandro Portale
559c57e29c ExtensionSystem: Add "soft loadable" to PluginDetailsView
Change-Id: Ifc9007f07c17dcc68f1b7c62b1027e66e653646f
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2024-04-12 18:32:56 +00:00
Thomas Hartmann
c9f9804edf QmlDesigner: Fix getting the bounding rectangle for an effect
When getting the bounding rect for an effect we actually have
to find the item with the effect first.

Change-Id: I4e20f77c6b8dca9d58ccffb42d8b803f57317cb9
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2024-04-12 15:39:49 +00:00
Thomas Hartmann
8a21dc325c QmlDesigner: Fix DesignerEffects rendering
The property name changed and we adda bit more padding.

Change-Id: I9432f3d5a053d38feb32649be52a99696a9f3b6c
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
2024-04-12 15:39:41 +00:00
Thomas Hartmann
97def66414 QmlDesigner: Properly parse properties
Checking here for the property name was wrong since,
we only want to skip conversion for property changes, list elements
and connections.

Task-number: QDS-12482
Change-Id: Ibff7164b8c3a28d50c483da256450a661a472bb7
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2024-04-12 14:52:10 +00:00
hjk
a03974245a ProjectExplorer: De-QObject-ify ExtraCompilerFactory
The QObject related features are not used any more and are not meant
to be used again.

Change-Id: I03ee7929e40c3cd9fd50af020dc4d38280c205d8
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-04-12 14:49:37 +00:00
Marcus Tillmanns
77a2e2fdee Compiler Explorer: Remove unused lambda
Change-Id: Iabef84b8d778449aa0091f29b38e607ab3757b82
Reviewed-by: hjk <hjk@qt.io>
2024-04-12 14:21:54 +00:00
Miikka Heikkinen
3700eac9f3 EffectComposer: Remove invalid properties from effects in use
When effect is saved, the properties it exposed can change if nodes
are deleted from the effect. If any of those removed exposed properties
was assigned a value in the scene, those property assignments are
removed from the scene.

Fixes: QDS-12359
Change-Id: Ia3840584c6361b9e140c6840ff8fa3036c1b7d93
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-12 14:03:49 +00:00
Miikka Heikkinen
a5335f5371 EffectComposer: Remove use of native separators from file paths
Using native separators causes soft asserts in FilePath.

Change-Id: I45c5002a555a21dd3780ffd5c8df91b849a67c18
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2024-04-12 14:03:41 +00:00
Thomas Hartmann
b0eccd58f5 QmlDesigner: Fix bindings
Task-number: QDS-12471
Change-Id: Ie172b966db0e15f73868542502313f6460137543
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2024-04-12 12:56:21 +00:00
Christian Kandeler
22a1f11773 LanguageClient: Fix pre-selection of rename results
... for the case of aliased file paths.

Task-number: QTCREATORBUG-30546
Change-Id: I2cce03529c45193c20bd3508e4dcb3dc051856fa
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-04-12 12:22:43 +00:00
Christian Kandeler
25d6c4f4e9 Utils: Fix focus handling in EnvironmentWidget
Amends 8ef85e481a.

Fixes: QTCREATORBUG-30640
Change-Id: If768a0b75aa7ff2bb02d538c446d5bed64e5dc60
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2024-04-12 12:20:17 +00:00
hjk
abd538507a ProjectExplorer: Make settings access more direct
A step towards aspectification.

Change-Id: Iabf5e56e993449dc482d1d2ab6eeb2885243ab3e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-04-12 11:48:29 +00:00
David Schulz
18a867aa23 Editor: use unique id without common part
Otherwise we also got override action warnings after opening a second
editor.

Change-Id: Id600eaa120e32399a941768ae5d5e35ab969be49
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-12 11:08:16 +00:00
David Schulz
41e581d0e1 Editor: fix assist actions
Amends 411100b037

Fixes: QTCREATORBUG-30673
Change-Id: Icc82b6f5526d229a13a7061cbc44904837c25f06
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-04-12 11:08:07 +00:00
Eike Ziller
cdc4a8e42b Themes: Fix reading "Includes"
QSettings can already read QStringLists, no need to manually re-invent
the wheel - and QSettings actually handles whitespace around the
seperating comma correctly. Fixes `Includes=foo.inc, blah.inc`

Change-Id: Id1849ac0cd5f3bcc8aaaa1c574ec2d086ef3e0f3
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2024-04-12 10:06:56 +00:00
Jussi Witick
0b2759a48f Fix QSR wizard cmake-project template
Latest changes to QSR tooling added limit checking for certain properties,
so the cmake-project template needs to be updated slightly.

Additionally remove the import versioning.

Task-number: QSR-2398
Change-Id: I55542c9fd74ebd950b6aeb9b64a22dde177c5a4f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Teemu Holappa <teemu.holappa@qt.io>
(cherry picked from commit 574ad7a4a2)
2024-04-12 09:51:29 +00:00
Knud Dollereder
2c18039de8 QmlDesigner: Allow negative values in the "Edit Keyframe" Dialog
Fixes: QDS-11842
Change-Id: I03d61549d0a0155b48381f00ccdf93dfe97126cd
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-04-12 09:50:05 +00:00
Thomas Hartmann
25320c4fc4 QmlDesigner: Crash fix
Change-Id: Iabaf8d5bb6b060fc0ede2c65d8d93141b4e94773
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-04-12 09:40:23 +00:00
Christian Kandeler
3423309795 CppEditor: Move CppCodeModelSettingsPage alongside CppCodeModelSettings
The colocation will enable various improvements that we intend to do in
follow-up patches.

Change-Id: I1624396b953c80c327b971977a5fd6095ad1b5c0
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-12 09:01:06 +00:00
Mahmoud Badri
247d2dbf6d QmlDesigner: Cleanups in the content library
Change-Id: I4bbb6f6d89c3e35a265624365eb61664280e9151
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-12 08:57:24 +00:00
Miikka Heikkinen
00bbf37cff QmlDesigner: Fix composed drop shadow effect resize
Source width/height changes were not listened for. Added connections
for those. Note that Connections element was not used as it doesn't
seem to work in puppet.

Fixes: QDS-12395
Change-Id: I30abdfa3e7ea08b3f126fbafeab6cb522040f16b
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-12 07:57:51 +00:00
hjk
63cbe50780 CompilerExplorer: Remove unused lambda capture
Amends 411100b037.

Change-Id: I4835b9aed591f894943fb3625ee5b4eadd99bc0d
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2024-04-12 07:41:42 +00:00
Thiago Macieira
4c31b2ba6e Utils: explicitly search the ClientExtras child object by name only
This class is missing the Q_OBJECT macro, so findChild was searching for
a QObject with the appropriate name, then casting to ClientExtras. That
means this change is a no-op.

But it makes explicit what we meant. Plus, findChild() and
findChildren() will enforce that the class they're searching for has the
Q_OBJECT macro.

Task-number: QTBUG-105023
Change-Id: I5f663c2f9f4149af84fefffd17c024995ef0c1af
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-04-12 06:21:03 +00:00
Tim Jenssen
74d56d54f5 QmlPreviewer: fix activate setDirty
Task-number: QDS-12177
Change-Id: I9518071d188cf959811dd1942721c81e853dc94b
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2024-04-11 21:54:22 +00:00
Tim Jenssen
9791a71e06 QmlDesigner: improve texttomodelmerger log output
- use QtWarningMsg together with qCInfo(texttomodelMergerLog) to silence the output until
QT_LOGGING_RULES=qtc.rewriter.load.*=true
or
QT_LOGGING_RULES=qtc.texttomodelmerger.*=true
is set.

Change-Id: Ia7d99bfc9d3e487c3c26065ef928ae830fa7e2ed
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2024-04-11 14:43:31 +00:00
David Schulz
1636252677 Editor: fix action text for switching utf8 bom
Change-Id: I0be1f9527aa4b0681a2c1423031800eb170a3d9e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-11 13:35:18 +00:00
Marcus Tillmanns
5b595f2cd1 RemoteLinux: Parallelize Generic File copying
Change-Id: I2774cfbab8cc073a268a6cbf038ea904cc70e3de
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-04-11 13:30:53 +00:00
Miikka Heikkinen
eae76dedff QmlDesigner: Change asset import path
The only import path should be project root, so change things that
are generated under asset_imports to be generated in new folder
GeneratedComponents under project root. GeneratedComponents is prefixed
to the type names of generated items as well.

If project already contains asset_imports folder, then old location is
used.

Fixes: QDS-12430
Change-Id: I7a419fe1c5411e3d39bf3c1e659df0043c60ba33
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-04-11 12:52:27 +00:00
David Schulz
ec3a5b5fd0 Editor: move setScriptable to context actions
The scriptable info is saved to the action registered for a specific context
so we need to add this info to the action builder in the text editor that has the correct context.

Also remove all action builder constructs for the global context that have been registered before
in order to silence the add override action warning.

Change-Id: I631d71ba5eb8e975190713b33827926e868da295
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-11 12:34:40 +00:00
Thomas Hartmann
8b877e7d4c QmlDesigner: Add property editor backend for editing non selected nodes
* Nodes can be accessed via QmlModelNodeProxy
* In QML ModelNodes are simply integers, we use the internal id
* PropertyEditorSubSelectionWrapper can expose all properties of a node
* Notifiers work

Change-Id: Ic11ad7a77c851d116080139b9fd24a32e5986e30
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2024-04-11 12:27:12 +00:00
BogDan Vatra
3e4f50aeb9 Use SSH port forwarding for debugging
This feature is needed to enable debugging on remote targes which can
not expose gdbserver ports on the wild, and we must use ssh tunneling
for that job.

Change-Id: I6df712fd3b40790e89c79a7617a24430fde6805a
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-04-11 12:11:24 +00:00
Christian Kandeler
4b29ad78e3 CppEditor: Move ClangdSettingsPage alongside ClangdSettings
Change-Id: Ib22438817ff3a14904decbb23f3c2288f355e378
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-11 08:48:19 +00:00
Christian Kandeler
459cb82744 LanguageClient: Update call hierarchy on double click on item
This seems sensible and is also consistent with how the type hierarchy
widget behaves.

Fixes: QTCREATORBUG-28843
Change-Id: I2423fda68ab2a9624206b8c93f2490e1a7196173
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-04-11 08:46:44 +00:00
Mahmoud Badri
a2474d5984 QmlDesigner: Create user bundle folders if missing
Change-Id: I955b1f1e5db3208eb578172529771910453adf68
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-11 08:14:21 +00:00
Jarek Kobus
a583436365 TaskTree: Zero-initialize the Storage
Change-Id: I9d5ee11285b377abafe21d472481c941f49a5ae1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2024-04-11 07:59:56 +00:00
Sami Shalayel
1e3750c5be qmlls: add checkbox for generating qmlls ini files
Add a checkbox to the qmljseditingsettingspage that generates qmlls
ini files by default for new projects.

If this checkbox is checked, then initial CMake configurations (when
enabling a kit for a project) and reconfigurations (when pressing the
"Re-configure with Initial parameters"-button) will set
QT_QML_GENERATE_QMLLS_INI to ON if QT_QML_GENERATE_QMLLS_INI was not
set yet.

Fixes: QTCREATORBUG-30394
Change-Id: I58f89558d25ef107e501bd67702f26554bd6aeaa
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-04-11 07:22:20 +00:00
Eike Ziller
403f5daf31 Editor: Open in different editor type after renaming or saving as
After save as, and when we get notified about a file rename, check if it
makes sense to open the document in a different editor type. This covers
the File > Save As menu item, as well as renaming in the project tree
and the file system view.

In principle this can happen when the MIME type changes (this could even
happen when the contents change, in special cases, but let's ignore
this).

Open the document in a different editor type if

- the document previously was opened in the default editor, and the new
file name would result in a different default editor type
- the document was not opened in the default editor, but the available
factories for the new name does not contain this

Do not use a different editor type, if it was previously open in a non-
default editor, and that is still valid for the new name.

Uses the openEditorWith functionality that is also used when a user
explicitly selects an editor type. This gives us all the details like
what happens if the new editor type fails to handle the file (e.g. when
renaming a text file to `.gif`).

Fixes: QTCREATORBUG-30317
Change-Id: I4c0b46da1e05165ac4f157dfa15b1783e0a3f3db
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-11 06:44:01 +00:00
Thomas Hartmann
ab6bd28b22 QmlDesigner Fix regression
There was code model based code for this check that was
hard to understand and accidentally removed.

We simply check if the property does exist.

Change-Id: I7fc0b414af526f15f0bf35006f6aee151506f660
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-04-10 18:39:34 +00:00
Jochen Becher
af54306f82 Add more visual attributes for relations
Change-Id: I56af6a367c144e22c8113f69a2938080ddb2e750
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-04-10 16:46:33 +00:00
Tim Jenssen
912082e6a8 Merge remote-tracking branch 'origin/13.0' into qds/dev
Change-Id: I1f6114244514a2b786a8b0d364a303b925ad7757
2024-04-10 17:30:10 +02:00
Tim Jenssen
682514a304 QmlDesigner: silence warning for empty images
Also correct logging category the default type is already
QtDebugMsg which adds .debug

Change-Id: I87803cd2fe9dc142ca8ce271547706f8d7cba3a1
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2024-04-10 15:26:57 +00:00
Thomas Hartmann
4f3bf836a9 QmlDesigner: Remove ScopeChain dependency for QDS_USE_PROJECTSTORAGE
* possibleImports() and usedImports() has to be implemented for the
  project storage
* getQMLSingletons() is not implemented for project storage and also
  does not belong into the rewriter.
* semantic errors are fully disabled for QDS_USE_PROJECTSTORAGE, since
  they require the scope chain.

Change-Id: I200ccbc1faf2631c4764a4676553a69cc0f5cf1f
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2024-04-10 13:43:29 +00:00
Alessandro Portale
82703befa1 Core: Add "UI configuration" section to System Information
"System Information..." provides the output of qtdiag. Among other info,
it contains DPRs and font DPIs. With support of the DPI rounding policy,
those values may deviate the IDE process. This makes the "System
Information..." output in a bug report potentially lack relevant
information.

Also, the StyleHelper::UiElement* font may vary depending on DPR/DPI and
other system settings. Since these fonts are used in the Welcome screen
redesign, precise information of these fonts is missed in reports
regarding the redesign.

This change adds a "UI configuration" section to System Information. It
contains most data from the "Environment -> Interface" settings page,
and in addition a dump of all StyleHelper::UiElement fonts.

Task-number: QTCREATORBUG-30579
Task-number: QTCREATORBUG-30637
Task-number: QTCREATORBUG-30650
Change-Id: Iff2c58903c5f8d5dbae4884b0521a8b85469b188
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-10 09:06:35 +00:00
Eike Ziller
0d17a1e6fd Update qlitehtml submodule
Fixes jumping to QML properties

Fixes: QTCREATORBUG-30625
Change-Id: I420a8c37607d732d8950b8eb2388eb68b4d0bf94
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-04-10 08:57:33 +00:00
Christian Stenger
fc3047fb1b Ios: Fix qbs build
Amends e8d6e4fc34.

Change-Id: I67185c856a28071c2428ac593f54d31f99c3411d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-09 13:53:07 +00:00
Christian Kandeler
7bf7c4fbe3 ClangTools: Fix clang-tidy doc URL for versions >= 18
See https://github.com/llvm/llvm-project/commit/
4532617ae420056bf32f6403dde07fb99d276a49.

Fixes: QTCREATORBUG-30658
Change-Id: I4e171c52959d576ed752691d601ceb99691b207d
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
(cherry picked from commit cde3cfea4d)
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-04-09 13:50:29 +00:00