Commit Graph

82976 Commits

Author SHA1 Message Date
hjk
6ed56f640a Utils: Make it possible to change internal aspect updates
... without subclassing. This is useful in situations where there
are small modifications needed for simple aspects that are themselves
exposed as members of an aspect container in a header but we
don't want to create a subclass for it.

Change-Id: I058643137c38e564072af9a2f45b1576ea058651
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-28 07:31:00 +00:00
hjk
2559654132 GenericProject: Use the right kit in example creation
Change-Id: I1743f3bdcda0658ef5062f1a1784597b95e9bfec
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-07-28 06:38:19 +00:00
hjk
b51747b92c Utils: Remove AspectContainer::addAspect "factory"
Aspects are supposed to self-register in their constructor, or
if really necessary, by manually calling AC::registerAspect.

Change-Id: I6c6c46162d49d70c3cefebad8fec968a27faeadb
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-28 06:26:39 +00:00
Thiago Macieira
e8ca1877de Use Qt 6.7's QProcess::UnixProcessFlag::CreateNewSession
Allow QProcess to do the setsid() call for us. Unfortunately, the
nice()-setting feature wasn't approved, so we need to keep the modifier
for that.

Change-Id: Icfe44ecf285a480fafe4fffd174d111b806eb3a8
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 23:30:38 +00:00
Jarek Kobus
eaa9f0f4c1 QbsProject: Remove unused method
Change-Id: I44494c28a631850f215d7ae45209ef4be3c398d1
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-07-27 17:21:21 +00:00
Jarek Kobus
1c3ce50c3d QbsProject: Fix enum value name typo
Change-Id: I7808c784123bac2ce06579d30ae22253255a0ed5
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-07-27 17:21:15 +00:00
hjk
429ad78bc7 Utils: Finally split FilePathAspect and StringAspect
The patch was done by
    - duplicating StringAspectPrivate to FilePathAspectPrivate
    - basing FilePathAspect on TypedAspect<QString>,
      duplicating the needed used parts of StringAspect interface
      and implementation
    - dropping m_pathChooserDisplay from StringPathAspectPrivate and
      all other *displays from FilePathAspect private
    - remove related things until it compile
    - remove now unused members in the privates.

Change-Id: I6ad710135dc4d3fc2f48bb620b502c20e717aa42
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-27 14:38:53 +00:00
Christian Stenger
4ca7dd8763 Terminal: Adapt to recent restructuring
Amends 42ed82973c.

Change-Id: I5845d1fe15ee88862742ee81486ba57062ab0158
Reviewed-by: hjk <hjk@qt.io>
2023-07-27 13:47:38 +00:00
hjk
9a78f717e4 ProjectExplorer: Change signature to Project::toMap(QVariantMap &)
More aspect-friendly.

Change-Id: Ia107dbab65f3772b315d735e4c46f9dfe1043d5a
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 13:24:24 +00:00
hjk
07de94237c Nim: Simplify error message creation for missing compilers
NimToolChains are the only ones with Constants::C_NIMLANGUAGE_ID,
no need to double-check with dynamic cast.

Change-Id: I1542128903261f8cfd2e20533b0589f9ceb7bc50
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 13:15:57 +00:00
Marcus Tillmanns
80b23292b1 Core: Add searchable terminal
Change-Id: Id058fb1a97c967fc253b08edf3910f019e708b50
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-27 13:13:06 +00:00
hjk
68c3103f76 Android: Use a more direct access to the tools' path
Change-Id: I49c574144fd4d6b2edd829538c424465c1fe7f05
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 13:03:41 +00:00
hjk
1e35f09251 Core: Remove PagedSettings again
Turned out to create a too strict tie between settings and
settings pages, we are more flexible with delaying/avoiding
initialization without these.

Change-Id: I948af675e29c7da34bfccd490c1c1b999923f279
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 13:00:28 +00:00
hjk
c326f049dc CMake: Prepare postponing formatter settings creation
This is still an overall quirky setup.

Change-Id: I7c1d22267bb76d434fe2f9b77ed8d0bfef5ac952
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-27 12:08:01 +00:00
Jarek Kobus
31cf0dfb74 BuildStep: Hide some API in protected / private sections
Change-Id: I3345afa871bbb900beb739b2a283145392262658
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-07-27 12:06:28 +00:00
Jarek Kobus
77cee300f6 BuildStep: Some cleanup
Remove unused BuildStep API.
Remove outdated docs.
Cleanup includes.

Don't repeat custom cancel messages from build/deploy steps,
as in case of cancel action the follow-up message:
"Canceled build/deployment." always appears anyway.

Change-Id: I50b31e0cc688ee66d76a3a1dbe58eb72702112ad
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-07-27 12:06:17 +00:00
Marcus Tillmanns
42ed82973c Terminal: Create Terminal solution
Change-Id: If271fd23a84c49bbc25fcc3b9bc0939c7237d095
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-27 12:03:17 +00:00
Robert Löhning
b95aba56b5 SquishTests: Don't use lists of dicts
...when that doesn't have any advantages.

Change-Id: I0c58e30ae0b9e278e3336646332279f6243719d0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 11:52:25 +00:00
Christian Stenger
b57f72e3c8 SquishTests: Adapt test of navigation tree
Explicitly disable loading ClangCodeModel plugin to avoid slowing
down the load and parse of the projects by the indexer as we are
measuring the time for these.
Beside this adapt the expected tree for macOS - there are a couple
of files and subtrees that are present only conditionally.

Change-Id: Ibc000d0908e652700820f8eee4b17effdf48f637
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-07-27 11:48:26 +00:00
Robert Löhning
a521114519 SquishTests: Don't initialize an entire list for reading one item
The point of Python3 returning objects instead of lists is that
it will iterate just as far as items are actually being used.

Change-Id: If4d9742bb47aa9cac1166a0ff6f10d211829fd85
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 11:41:40 +00:00
hjk
209f3ba579 Nim: Merge Toolchain related file pairs
Change-Id: Ia8526bc55934e6f2b29aa291a6269050309e3b4f
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-27 11:37:26 +00:00
hjk
fa2124f037 Core: Move GeneralSettings setup structure closer to new normal
Change-Id: I3ffbe1b28971912510582a174bf37a0e3f9d4ff4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 11:31:01 +00:00
hjk
424898873d Core: Move settings category icon creation closer to its first use
No real difference in performance, just stuff closer to its use.

Change-Id: Ib41209fc90872743a3baa692c9bc32c87e951ad5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-07-27 11:25:53 +00:00
Marcus Tillmanns
4c5e3aa6ba Utils: Fix BoolAspect::action
Change-Id: I6c82dfd5ec15eae16091e4ab52b552b636fbcca6
Reviewed-by: hjk <hjk@qt.io>
2023-07-27 10:58:23 +00:00
Christian Stenger
4a8c08a349 SquishTests: Skip too old Qt on Windows
When creating a command line project from wizard we end up
with code that is not compilable on Windows when using too
old Qt versions. Explicitly do not use the older Qt versions
as this fails to build and the whole tests would need to get
adapted to handle this appropriate instead.

Change-Id: Ia8a253a0c5d8d20ea181dd33dc8d31cb83cb31c3
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-07-27 10:37:50 +00:00
Christian Stenger
488f1b3d11 SquishTests: Adapt cmake based speedcrunch test
Change-Id: Ic4c22311828f2c0364cbc514b98d2cb4e7d1b86a
Reviewed-by: Robert Löhning <robert.loehning@qt.io>
2023-07-27 10:29:43 +00:00
Cristian Adam
e321b3d6fc Debugger: Allow usage of Python 2 based GDB versions
Amends 7a210c41b4

Fixes: QTCREATORBUG-29440
Change-Id: I5991f7954c4831b732ea2b391e5542fab96a308e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-27 10:25:05 +00:00
Jarek Kobus
ddbfdb6f3f ProjectExplorer: Fix 10 seconds hang on shutdown
Delete the RunControl directly when it's not running.
Do it in two cases: when tab is closed and when
tab is reused with a new RunControl instance.

In other case, queue the call to initiateStop,
so that any possible deleteLater() is called when
the nested event loop of the shutdown is already spinning.

It looks like the amended changes introduced the hang
when compiled against Qt 6.5. When compiled against
Qt 6.4 the regression doesn't occur.
The regression is caused by
449b45ff34ce4a45e5d6a24967566f69f43ebbb6.

Amends c1f6d70445
Amends 6e16512eba

Change-Id: Icb3ba757f32bccb3daae675b2eb516f75b84530a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-07-27 10:14:39 +00:00
hjk
323e94c2fa Debugger: Use AspectContainer directly for L&E settings page layout
Change-Id: I538362541e67499ee1a93fbd5452bdd76694f87b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-27 06:05:32 +00:00
Marcus Tillmanns
55b9e3d151 LibVTerm: Integrate upstream changes
Change-Id: I9636eead9f9426f4d7754af8dede19956bc1fb8c
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-07-27 04:48:01 +00:00
Jarek Kobus
44189c4590 BuildStep: Drop using ProjectConfiguration::parent
The parent function isn't used anymore after the amended change.
Originally, it was introduced in
9d206a2bc4, when things still relied
on QObject hierarchy.

Amends 06a57f8c42

Change-Id: I9e3a2bbaf4c4cac308a18cbe5cf5905f2655443f
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2023-07-26 16:35:39 +00:00
hjk
b880525e68 Vcs: Use a StringAspect again for settings().path()
This holds a path list, i.e. possibly several directories, separated
by ';' or ':'. PathChooser can't handle that. Long term this could
be something more sophisticate, but for now it's more a "string" than
one FilePath.

Change-Id: I6665c131e698db3afd268d6ab9bcf3d76a7c7289
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 15:02:33 +00:00
Marcus Tillmanns
79e839b29f Terminal: Add mouse support
Change-Id: Ibeb8e13b5f8f75f16ec86f64536235587c844ffc
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-26 14:06:38 +00:00
hjk
75d9dc2d31 CppEditor: Apply 'static pattern' to CppToolsSettings
Change-Id: I1632787e1a1ebf60427c92b302b25a1a2550853f
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-07-26 13:35:28 +00:00
Jarek Kobus
a140a93067 BuildManager: Employ task tree for running
Task-number: QTCREATORBUG-29168
Change-Id: Ibdc1882f3a019855bc06e7a7e49e2ae6e3bf17f1
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-07-26 13:22:04 +00:00
hjk
86e11befca Perf: Move config widget setup closer to settingspage
Change-Id: Idda753dc07103dc0f6d0c3ff9759d0ff083ac2d9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-26 13:14:13 +00:00
hjk
a478b9682e Utils: Introduce a helper function to prepend or set paths
This is meant for cases where we get a raw ':'/';' separated list of
directories.

Change-Id: I9ef8888f71700d553213949a867f62dec763054c
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 10:42:22 +00:00
hjk
778a1d75ba Git: Initialize GitClient on first access
This does not change the current timing of construction a lot as
the GerritPlugin may need it immediately in some cases, in any
case the gitGrep instance will need it.

There's nothing big going on at destruction time, so the prolonged
lifetime until really close to the end does not hurt.

The reason here is that this way we will avoid cases like in change
5e5b90a9a1.

Change-Id: I326d83c1a3d21114322ac6cce8d9e9b782faacdc
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-26 10:25:43 +00:00
Eike Ziller
8d5897b8eb Designer: Add command line arguments for plugin paths
Add a command line argument for overriding the default plugin path
(useful if you have installed custom designer plugins in a different,
compatible Qt version), and one for adding plugin paths (for example to
separate builds of custom designer plugins that haven't been installed
anywhere).

This feature is only enabled when building with Qt >= 6.7, which added
the option to change the plugin paths for designer.

Change-Id: I990b26056477e3e41c6afe82479383d8bc7c45d0
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-07-26 10:20:41 +00:00
hjk
8ea41af94f ProjectExplorer: Use FilePathChooser for alternative executable
... also for the manual fallback (ExecutableAspect::makeOverridable)

Change-Id: If660c9e26005ce88b3712472d44cf46c95379acb
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 10:05:51 +00:00
hjk
0e284ba50c Nim: Use FilePathChooser for working directory
Change-Id: I08cd734dec1e810a113edfa646036242736fe9e1
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 10:05:44 +00:00
hjk
bcb083bd99 Python: Use a connect that will remain valid
... after a StringAspect/FileAspect split, instead of relying on
the  current inheritance.

Change-Id: I7dd91f402636d35a15e9d1618b73c0981777b06e
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 10:00:51 +00:00
Marcus Tillmanns
def291f260 Terminal: Improve paste performance
Pasting large amounts of data on macos would block the App indefinitely.

The issue was a blocking call to ::write. The first fix for that was to
set O_NONBLOCK on the tty stdout fd. The second fix was to pass the
actual result of the write back to the caller so they can react to it.

In the TerminalSurface we now check if the write was successful and
if not we buffer the data and try again later.

Change-Id: Ibc92cce57fad88b5e9aa325197b42e17bec5e746
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-26 09:48:17 +00:00
hjk
59ce7c14f7 Debugger: Use CommonSettings::setLayouter
... instead of a IOptionsPage-derived class.

Change-Id: Ica45b1752fc4e6f83e9dfae25c5e9dcd1fd9c9ba
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-26 09:39:22 +00:00
hjk
56f38e4171 Use path chooser for selection local debug symbol files
Change-Id: I7aa3f58389ea3608cc09b1e2cf2d167c463e6c6c
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-07-26 09:39:11 +00:00
Eike Ziller
e3567ddc71 Build: Remove outdated argument handling
No longer used

Change-Id: Ife7edad49c66ee2a59d67ea4eca72767f8d73a7a
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-26 09:16:19 +00:00
Eike Ziller
c7d0c73587 Build: Rename deployqt.py to deploy.py
It hasn't been about just deploying Qt for a very long time.

Change-Id: I72fb070db505909500d2e68f2bafb198c3342c2b
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-07-26 09:16:05 +00:00
Christian Stenger
4ffbf6ec63 PerfProfiler: Disable auto apply on settings
Change-Id: I67dc03f15e66e55e18b0bba41dc6365e8e6889ff
Reviewed-by: hjk <hjk@qt.io>
2023-07-26 07:58:10 +00:00
hjk
84250d3daf Valgrind: Rename ValgrindOptionsPage into ValgrindSettingsPage
That's the usual naming nowadays.

Change-Id: I10c20e857f20ee4e1d36107e1cc1bf77449e7b17
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-07-26 07:25:33 +00:00
hjk
c828ba2f30 Beautifier: Rename some entities called 'command'
A confusing amount of TextCommand or Utils::Command objects or
-returning functions were called 'command'. Rename a few to make
future reasoning simpler.

Change-Id: I872b2e841cb40a4533e5ebcd37cb05489158cec7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2023-07-26 06:10:57 +00:00