Commit Graph

74741 Commits

Author SHA1 Message Date
Jarek Kobus
da475f400d QmlProfiler: Simplify QmlProfilerRunner
Remove registerProfilerStateManager() and connect to
state manager's signal directly from the start() function.

Remove Q_OBJECT macro.

Change-Id: Id03486f077c81909fbe0889bb342ee7595631e9d
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 11:46:15 +00:00
Jarek Kobus
49a66abf1f PE: Get rid of ProcessRunner::process()
Provide stdOutData() signal instead.

Change-Id: Ie89c64c67ea383a9f2265bad3b527d3337342656
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 11:22:03 +00:00
David Schulz
ac5ca391dd QmlEditor: remove indirect QString::toUtf8/fromUtf8 roundtrip
Change-Id: Ie83ba8ff03834f10ef1b4d23827141817deb1bf3
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-07 10:30:03 +00:00
David Schulz
a822f6db98 LanguageClient: remove indirect QString::toUtf8/fromUtf8 roundtrip
Change-Id: I80146250cf5be5d408c30337869dd5baed923d5a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-07 10:29:56 +00:00
Jarek Kobus
543acde1c8 PerfProfiler: Get rid of LocalPerfRecordWorker
Use ProcessRunner instead.

Task-number: QTCREATORBUG-29168
Change-Id: Id0ef0590fb807dfc3476742cd69f7cd98b11d2f8
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 09:36:41 +00:00
Jarek Kobus
79542bb6d1 PerfProfiler: Replace LocalPerfRecordWorker::recorder with property
Do it temporarily. In a followup patch the LocalPerfRecordWorker is going
to be replaced by ProcessRunner.

Change-Id: I88dc0624b19aa105efce6b0d36d530296214c132
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 09:30:45 +00:00
Alessandro Portale
f84205dab7 Utils: Don't force an application palette on Qt::ColorScheme::Unknown
When using a dark QtC theme on "light" environment and or when using a
light QtC theme on a "dark" environment, the application palette is set
accordingly.

After switching to Qt::ColorScheme-based API, the palette got also set
for environments reporting Qt::ColorScheme::Unknown. This change avoids
it.

Amends: eb4648004f

Change-Id: Ibb5dcd02aff6e665a59fd4f67407f00a9ff6e9b0
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 09:13:44 +00:00
David Schulz
ce24a8d9f6 Editor: improve expanding block selection
Replace the main cursor with a block selection instead of a normal
selection when using alt+shift+LMB. This is more in line with other IDEs
and also feels more natural.

Change-Id: Id4dba7cec65ddeb34ab525d90a41aebf78457d0d
Reviewed-by: Andrii Semkiv <andrii.semkiv@qt.io>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2025-01-07 08:44:26 +00:00
Jarek Kobus
1285aff18a Callgrind: Remove superfluous action
Operate directly on m_startAction.

Change-Id: Ib86b2dfff664aeffa683f378d9e490a59f3f40a3
Reviewed-by: hjk <hjk@qt.io>
2025-01-07 08:23:21 +00:00
Jarek Kobus
ab27988186 PE: Rename SimpleTargetRunner into ProcessRunner
Change-Id: Ie666fe0811aa63c54edf12934c6db4e17b26c252
Reviewed-by: hjk <hjk@qt.io>
2025-01-06 14:56:13 +00:00
Eike Ziller
638874edfb Disambiguate translations for "All"
Translations can be different depending on context.
Give each usage a disambiguation text.

Task-number: QTCREATORBUG-31978
Change-Id: I5fe854f96ce285943ff47993cd6d56db603d1c27
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-06 13:54:13 +00:00
Eike Ziller
705dcb17b8 Disambiguate translations for "None"
Translations can be different depending on context.
Give each usage a disambiguation text.

Task-number: QTCREATORBUG-31978
Change-Id: I44ac524d7448787360e825fad1d430ded3f07659
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-06 13:53:53 +00:00
David Schulz
b626da4e2c Editor: fix typo
Change-Id: I9abb2e3abb44753a86445d2aea37c97b5beeeb56
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-06 13:39:27 +00:00
David Schulz
f119f3fbda CompilerExplorer: remove unused function
Change-Id: I5f32f7b9f9f56a10c8c3e02ef2d4495a20d82e33
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2025-01-06 13:36:38 +00:00
Jarek Kobus
b727460ff5 CMakeParser: Get rid of the std::optional holding a container
There is no need to enclose a container inside the std::optional,
as if the container is empty, it indicates that no values are in.
Holding optional for a container class may lead to the confusing
behavior, that the optional itself isn't empty, but holding an
empty container.

Instead, introduce a m_callStackDetected flag.

Task-number: QTCREATORBUG-29965
Change-Id: If8d43e0633286c076e3da436eb61114aa68f4c35
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2025-01-06 13:19:31 +00:00
Alexis Jeandet
9a8f5b687e MesonProjectManager: Replace recursive templates by fold expressions
Change-Id: I07000adac1294abdf9b4b2d033ce01e552d40f3b
Reviewed-by: hjk <hjk@qt.io>
2025-01-06 12:51:06 +00:00
Jarek Kobus
fe2fe1a60d Axivion: Reuse resolveDashboardInfoUrl()
Change-Id: Ic8627be0353e7a789cd569030da91bb46751c885
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2025-01-06 12:29:58 +00:00
Andrii Semkiv
754bb5847f Debugger: Fix enabling breakpoints on click
Calling `BreakpointItem::setEnabled` from `BreakpointMarker::clicked` is
wrong and dangerous. It never actually enables a global breakpoint,
just updates the marker. While doing so, it calls
`BreakpointItem::adjustMarker`, which in turn calls
`BreakpointItem::destroyMarker`, which destroys the original marker,
hence the dangerous part.

What we actually want is simply enable the corresponding global
breakpoint instead.

Amends 8f3a0ebabb.

Change-Id: I423752be4e4f51198e9e2968a978b57bce43a3ec
Reviewed-by: hjk <hjk@qt.io>
2025-01-06 09:47:15 +00:00
Jarek Kobus
42e25dcd4d ProcessRunner: Simplify handleDone()
Change-Id: I026511906542eea126bb6d6c3c3cbc96e46934a8
Reviewed-by: hjk <hjk@qt.io>
2025-01-06 09:32:24 +00:00
hjk
4c5c33eb80 Core: Remove one functional indirection in copyPostOperation
And replace a FilePath::toString() by .path()

Change-Id: I5e4c36f8fd9cc0494cf76f274f259d97231b2dc0
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2025-01-06 09:21:59 +00:00
hjk
bcdf7d71b6 Utils: Remove parent argument from FileUtils dialogs
Some were using ICore::dialogParent() directly and the 'nullptr' users
were using that implicitly, but quite a few actually effectively changed
now from some local widget to (implicit) ICore::dialogParent().

Change-Id: Ibb2767b1289221dd26757361235ee88df4a1695e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2025-01-06 09:20:58 +00:00
Olivier De Cannière
0c5c42a6d6 About: Fix typo
Amends 810a855b42

Change-Id: Ie20b77f06768ddea42ead137bd6bffc29c73618f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2025-01-06 08:02:37 +00:00
Sami Shalayel
cb80977937 qmlls: display executable path after name
Add the executable path of qmlls after its name, so that it is actually
displayed to the user which version of qmlls it is currently using. This
should help us when/if users will report more bugs with qmlls in the
future.

Task-number: QTCREATORBUG-31897
Change-Id: I5fded78cd5c0c2a3a2f4b40128d3668c5720709e
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-06 07:58:12 +00:00
Sami Shalayel
70a0cf1601 qmlls: be invalid if no qmlls was found
Make the qmlls client invalid if it can't find the latest qmlls version
(if there is no qmlls version installed for example).

Task-number: QTCREATORBUG-31897
Change-Id: I74fa72bd2a95126a2a091f88c64dfa60155e4508
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-06 07:15:23 +00:00
Sami Shalayel
7a8dfd2ce3 qmlls: don't pass import paths for qmlls < 6.8
Add a missing braces to avoid passing import path to qmlls versions that
don't support it.

Task-number: QTCREATORBUG-31897
Change-Id: Ia247ebe34790a2b5cf93ffd6080e0784ee317ee7
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-06 07:15:06 +00:00
Alessandro Portale
dcbfc31b41 Core: Implement "Tertiary" Figma-designed button variant
Fixes: QTCREATORBUG-32285
Change-Id: Ic3214b7d88eb568a59488211161a6d544602bb3e
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2025-01-05 22:44:16 +00:00
Kai Köhne
881b6f8c7b Fix typo in QmlDesignerBasePlugin function name
Change-Id: Ia98224e254d8b131bbb4ad37916773c808f5e6de
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2025-01-03 15:13:36 +00:00
Sami Shalayel
f29bbc1cad qmlls: make a warning translatable
Add a missing Tr::tr() to make the warning translatable.
Amends c783ac4f81.

Task-number: QTCREATORBUG-31897
Change-Id: Iaf86dbae222fc355ba78b5c7637c3f319634a810
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-03 10:38:12 +00:00
Alessandro Portale
946dadfdb2 Core: Rename Button::Role::Medium* to Button::Role::Large*
The variations were renamed in Figma. Follow suit here in order to stay
aligned.

Change-Id: I797e00a3dfcdee4302e8b0b06d13392a1c0979bd
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2025-01-02 17:05:11 +00:00
Alessandro Portale
c8041374f2 Core: Implement disabled state for Figma designed components
The components partially looked enabled while being disabled.

Fixes: QTCREATORBUG-32281
Change-Id: Ifa267e8bc9bc77c4a38a214acf71530f2122425a
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2025-01-02 16:55:13 +00:00
Sami Shalayel
da6f5f24ba LSP: avoid duplicates in sortedSettingsForDocument()
Avoid returning the same BaseSettings* multiple times in the list
returned by sortedSettingsForDocument(). This leads to duplicate work
later on.
Amends 2e96194681.

Change-Id: I27e530a8cdd1cd13153236a651636511b2f0603d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2025-01-02 14:44:27 +00:00
Alexis Jeandet
bd481fa300 MesonProjectManager: Tidy sources list
Some source were not used anymore and others were not listed in
CMakelists.txt.

Change-Id: Icfb6ef4302fb0cd712ab6db46e982e0fb2596310
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2025-01-02 13:16:45 +00:00
The Qt Project
cf79505b4b Merge "Merge remote-tracking branch 'origin/15.0'" 2025-01-02 09:48:31 +00:00
Sami Shalayel
6ecfb9da36 qmlls: use import paths also used in old codemodel
Add the import paths used by the old codemodel to qmlls via "-I"
commandline parameter. This includes import paths passed from the
QML_IMPORT_PATH CMake variable.

The downside of passing the import paths as commandline parameters to
qmlls is that all QML module end up using the same import path. In
general, this is not the case, QML Modules with "DEPENDENCIES TARGET" or
"IMPORT_PATH" in their qt_add_qml_module()-call might have extra import
paths that other modules don't have.

An example for this is a QML Module linking to another static QML
module. It builds fine but qmlls can't find the static QML module
if its outside the Qml import path.

This scenario works fine when using QT_QML_GENERATE_QMLLS_INI.

Add a manual test project with such a QML_IMPORT_PATH CMake variable,
where qmlls should not warn about importing MyModule in Main.qml.

Task-number: QTCREATORBUG-31897
Change-Id: Ic4c048dfdacfc2de11db8973dcbdca83989af320
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2025-01-02 09:35:00 +00:00
Sami Shalayel
c783ac4f81 qmlls: disable and warn on broken Qt kits
Warn the user that qmlls can't start when using an invalid Qt kit,
instead of trying to start an empty CommandLine.

Task-number: QTCREATORBUG-31897
Change-Id: I7bb7a473b1ffad34dd6c77a23fd700d829ea2216
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-02 08:48:00 +00:00
Sami Shalayel
617aec1fce LSP: add BaseSettings::isValidOnProject() virtual method
Add a method to BaseSettings that allow language clients to tell whether
they can be used on a certain project. This allows BaseSettings to be
disabled on certain projects, for example qmlls can't be enabled on a
project that has an invalid Qt version.

Task-number: QTCREATORBUG-31897
Change-Id: Id8d6c05bc31c8596f685852ff20179d7f728feda
Reviewed-by: David Schulz <david.schulz@qt.io>
2025-01-02 08:47:45 +00:00
Eike Ziller
74d527b295 Merge remote-tracking branch 'origin/15.0'
Conflicts:
	src/plugins/qmljseditor/qmljseditordocument.cpp
	src/plugins/qmljseditor/qmllsclient.cpp

Change-Id: I0fce4ae6240a8f14257de8e134bceb6e64ddf4a5
2025-01-02 08:55:58 +01:00
Orgad Shaneh
7b48d08df9 Valgrind: Fix Windows build
Amends 9d78bf899e.

Change-Id: Ie69bd56e7b60ea717f15c3977f192127072273fd
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-12-31 08:14:20 +00:00
Christian Kandeler
6ba42154f4 Update qbs submodule to HEAD of 2.5 branch
Change-Id: I0a356f18bc62052af6c8d6242214de7b1996a620
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
2024-12-21 16:37:24 +00:00
Christian Kandeler
27ef562958 QbsProjectManager: Adapt to upstream API change
Task-number: QBS-1818
Change-Id: Ie367e14f91531311569079a3b1cc6225366f79ee
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
2024-12-20 20:05:11 +00:00
hjk
9d78bf899e ProjectExplorer: Introduce a RunControl::start()
And use it in various places.

Change-Id: I525d6fe89652ceba9f675b0b8c9e7ea6a8bcf4be
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-12-20 16:28:12 +00:00
Alessandro Portale
eb4648004f Utils: Use Qt::ColorScheme-based API
The OS specific handling of light/dark system theming in Qt Creator was
implemented by passing around bool values. Qt 6.5 comes with a new enum
Qt::ColorScheme and respecive themeing API.

This change replaces some of the legacy code with the new Qt API.

"System Information" displays the color schemes of the current theme and
the one of the system.

Change-Id: Id39af399dd54ea239bd750c45ea74a48be5efbd2
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-12-20 16:27:32 +00:00
hjk
5ec8021ffe Debugger: De-pimpl AttachCoreDialog
Change-Id: Ic2835ead1c707a8264549c361415b410218051f5
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-12-20 16:12:22 +00:00
hjk
0f0ceeabe7 Debugger: Move all core dialog handling to loadcoredialog.cpp
Change-Id: Ide3d3ce73e756799bc3c1105935a8c2040a41835
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-12-20 16:12:17 +00:00
Cristian Adam
fc32f15233 CMakePM: Only set CMAKE_COLOR_DIAGNOSTICS for new projects
Amends d7f44cdd24

By having CMAKE_COLOR_DIAGNOSTICS in initial parameters we make sure
that imported projects will not get rebuild.

Having CMAKE_COLOR_DIAGNOSTICS as an environment variable will cause
CMake to set CMAKE_COLOR_DIAGNOSTICS as parameter, and in combination
with CLICOLOR_FORCE would cause on gcc/clang the modification of the
compiler command lines.

See https://cmake.org/cmake/help/latest/variable/
CMAKE_COLOR_DIAGNOSTICS.html for details.

Fixes: QTCREATORBUG-32196
Change-Id: Ia5aa72695ecf7b605bc99caf5b46b2d2f9c6ed20
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2024-12-20 14:25:14 +00:00
Christian Kandeler
6fac43514f QmlDesignerBase: Fix WindowManager includes
In particular, include <QRect> in the header, as moc needs the complete
definition of Q_INVOKABLE return types.

Change-Id: Ied1b0df4b32d4a1f6fe37f672deca80976ab00f3
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2024-12-20 14:20:02 +00:00
hjk
2e99d3a909 Debugger: Move AddressDialog handling to debuggerdialogs.cpp
Change-Id: Icb1658d9bcf997a1d5ceb85670070f1981c8083f
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-12-20 14:13:56 +00:00
Christian Kandeler
f406088717 ProjectExplorer: More FilePath usage in ProjectWizardPage
Otherwise, remote Linux paths are displayed with backslashes on Windows.

Change-Id: I2c918364200a3420836328ee3d81a4bbd32bbc90
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2024-12-20 13:02:35 +00:00
hjk
e12a9242df ProjectExplorer: Move output pane raising to RunControl
Easier to discover there.

Change-Id: Iba549379254aeb253a0b029eb1b5c02cc647c742
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-12-20 11:35:49 +00:00
hjk
b5d1d7641a Debugger/ProjectExplorer: Promote run configuration aspect widgets
These are the widgets at the bottom of the run config settings that
share the ability to switch between a global and per-target setting.

There is nothing inherently debugger specific here, except for the
common history.

Change-Id: I4c57c138bb05c2a505f1bac13161352417bd8fe4
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-12-20 11:35:41 +00:00