Commit Graph

86167 Commits

Author SHA1 Message Date
Alessandro Portale
d501cb3ad4 Axivion: Put icons into SVG
Change-Id: If666ce24c664dbff8c46e75bd6ac5de79e38c939
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-01-24 09:21:24 +00:00
Christian Stenger
0ba1e17797 Axivion: Prepare ui for displaying issues
UI preparation which may change when adding the functionality
of retrieving respective information from the dashboard.

Change-Id: I9ec8069d780f925b00ba63982af6b410ddec9a5a
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-01-24 09:20:52 +00:00
Pranta Dastider
e63b88c7dd QmlDesigner: Update image in the Live Preview documents
This patch updates the old image to include lock the views features
in the document screenshot. Also it updates the text description to match
the change.

Fixes: QDS-11565
Change-Id: I262be3392552920607725becda6e21d3e571c122
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
2024-01-24 09:19:48 +00:00
Jarek Kobus
0a7dc1ac1e Axivion: Refactor fetching serializable data
Change-Id: I5a5c07238abf7440c4f8686a1a06b96da6125ef8
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-01-24 09:09:52 +00:00
Jarek Kobus
948352d937 Axivion: Extract getting credential into a separate task
Change-Id: Iab7fe76fc11a2a3407c8111d2ea6a0cd22a1c194
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-01-24 09:09:36 +00:00
Jarek Kobus
40a0d1db88 Axivion: Employ TaskTree
Change-Id: I55678f67d990c569073571055dbfe820b2fd324e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-01-24 09:08:59 +00:00
hjk
d77f1b09c5 CppEditor: Simplify access to FileSettingForProject
Change-Id: I382a6cce314eafaeb21ae4c9fa42015b79a0cb0e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-24 08:02:04 +00:00
Thiago Macieira
7b04bdf491 CPlusPlus: deal with QByteArray::(c)begin() return nullptr
You should either use begin() and end(), or data() and size(), and
either way you shouldn't dereference the first iterator if the size is
zero.

Roberto's parser in 3rdparty/cplusplus assumes you've passed at least
one character (I'm guessing the null terminator) and does pointer
manipulation there:

void Lexer::setSource(const char *firstChar, const char *lastChar)
{
    _firstChar = firstChar;
    _lastChar = lastChar;
    _currentChar = _firstChar - 1;
    _currentCharUtf16 = ~0;
    _tokenStart = _currentChar;
    _yychar = '\n';
}

Note the _firstChar - 1 math is technically UB if firstChar is the
actual first character of any buffer allocation or string.

Fixes: QTCREATORBUG-30044
Change-Id: I76ffba14ece04f24b43efffd17abcb8102497813
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-23 20:36:57 +00:00
Ali Kianian
479380c799 QmlDesigner: Fix the bug for adding a property to the left side
Fixes: QDS-11659
Fixes: QDS-11661
Change-Id: Iabeae683c4ca33721f4e08137312cea0f6cb435e
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Shrief Gabr <shrief.gabr@qt.io>
2024-01-23 13:51:39 +00:00
Ali Kianian
43f3969617 QmlDesigner: Model should have at least one cell
* If all of the columns are deleted, all of the objects will be deleted
and a single column, with one empty row will be created.
* A bug is fixed for the cases that we have invalid selected column.

Task-number: QDS-11649
Fixes: QDS-11678
Change-Id: I8bdbd0176ad76dd761e98b5030cdc77379a8642b
Reviewed-by: Shrief Gabr <shrief.gabr@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-23 13:33:38 +00:00
Mahmoud Badri
9723ebe7b4 EffectMaker: Wrap long names in the nodes ComboBox
In practice this applied only to "Mipmap Drop Shadow"

Fixes: QDS-11717
Change-Id: Ia731370a1101a9bce17ae558ae8761b99afcd896
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2024-01-23 13:29:44 +00:00
Miikka Heikkinen
6826987c7e QmlDesigner: Hide duplicates from UrlChooser combobox
Files with same name but different path will now be removed from
UrlChooser combobox on the assumption that they are in fact copies of
the same file.

Fixes: QDS-11471
Change-Id: Ic65153a1a65865982ee1c11e4e20171d66221b76
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-23 13:28:21 +00:00
hjk
9aff30f7c7 CppEditor: Hide CppFileSettingsPage class in .cpp
Change-Id: Ic095d7d45681a1970fb8362667f50d632ee6d3e5
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-23 11:43:03 +00:00
hjk
d0d0d3b83a Rename a few more ToolChain items to Toolchain
Change-Id: I78e12e6923242fcb72cdde6284185574b8792fc6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-23 11:09:32 +00:00
hjk
d7c1fe129f McuSupport: Rename remaining ToolChain things to Toolchain
Change-Id: Icd90402501b3ca2197e124731e26d2f9b0704e0a
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-23 11:09:23 +00:00
Christian Kandeler
8ef85e481a ProjectExplorer: Re-do the EnvironmentWidget
Editing in the item view was cumbersome and did not generally allow one
variable to refer to another, as there was no defined order on the
assignments.
Therefore, we make the item view read-only and promote the batch editing
widget to be the standard input method. User changes are not sorted
anymore, except in the summary text of the details widget.

Fixes: QTCREATORBUG-28480
Change-Id: I225cf86fff7b001a57d663e1fd267a4645e695c4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
2024-01-23 09:54:13 +00:00
Ali Kianian
72162e8ee7 QmlDesigner: Set minimum size for collection editor cells
Fixes: QDS-11463
Change-Id: I33a4d33adc75e0132a20a78bc3519ff4a191e907
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2024-01-23 09:47:14 +00:00
Jarek Kobus
10ff747a0f Use more std::chrono and std::chrono_literals namespaces
Change-Id: Ib8c83988d7afe35d81b87ff8c5c87eef2082f12d
Reviewed-by: hjk <hjk@qt.io>
2024-01-23 09:32:43 +00:00
Ali Kianian
362e6f7b73 QmlDesigner: Close the header context menu on click
Since the context menu is defined inside the horizontal header view,
it didn't close by clicking on another column. The reason is that the
close policy works when we click outside the parent.
To resolve this, we can simply close the menu when the user clicks
on the header scope.
For right clicks, it's not mandatory to close the menu, since it will
be moved and opened again.

Fixes: QDS-11731
Change-Id: I5e0bb4c88dafdc54d0900a4c9e3bb584243373e4
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Shrief Gabr <shrief.gabr@qt.io>
2024-01-23 09:21:00 +00:00
David Schulz
9e73dc1f09 ProjectExplorer: add async toolchain autodetection
Change-Id: I82c6d0b22a9d36674c58561ef654d7ffde8574da
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2024-01-23 08:28:55 +00:00
Thomas Hartmann
14b63a2ba0 QmlDesigner: Change Twitter Button to Figma Button
Change-Id: I9c0ab2c6211c2d1ebc607401123497058fdb717d
Reviewed-by: Henning Gründl <henning.gruendl@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Brook Cronin <brook.cronin@qt.io>
2024-01-23 08:28:08 +00:00
Leena Miettinen
1a29f87440 Doc: Fix the location of the "Request Copilot Suggestion" action
It is in the locator, not in the context menu.

Fixes: QTCREATORBUG-30227
Change-Id: I35bea968a936e8872cdadcec3b8f53559e654c94
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2024-01-23 08:01:37 +00:00
Jarek Kobus
00ba645fe1 ProcessBlockingInterface: Change signature of waitForSignal()
Change the arg to QDeadlineTimer type.

Change-Id: I7087648fd4f248b0b5024dc0d51d65171037934d
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-23 07:09:33 +00:00
Jarek Kobus
63fc22e274 Process: Change signature of waitForXxx() functions
Change the arg to QDeadlineTimer type.

Change-Id: Id3dee0717e44130c16baf7925e5b06346a1a1ad1
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2024-01-23 07:09:22 +00:00
Jarek Kobus
f86ada790a QtSingleApplication: Simplify chrono duration initialization
Change-Id: Id75505b67e7e37ca4be9566a70ccda89b7168971
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 20:47:54 +00:00
Jarek Kobus
665beaead9 Process: Change signature of setReaperTimeout()
Change the arg to std::chrono::milliseconds type.

Change-Id: I7b79fc318e2fd06971148038a31fecd4c1805a79
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 20:42:36 +00:00
Jarek Kobus
e98f6e31e7 Process: Change signature of exitMessage()
Change the last arg to std::chrono::milliseconds type.

Change-Id: Ifb818f76ee33e03997cb5b1dd17336248f401238
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 20:28:41 +00:00
Jarek Kobus
afc67468e6 Process: Get rid of setTimeoutS()
Add an extra arg to runBlocking() function instead.
Use std::chrono::seconds for timeout.

Change-Id: I7c3c21e8f26a2ccbed157d15083d6ef0b4cd2f7e
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 20:27:51 +00:00
Jarek Kobus
f6be85b1d2 Process: Refactor timeout handling
Rename ProcessResult::Hang into Canceled.

Change the behavior of the Process:
Whenever the terminate() or kill() is called, including
indirect calls through stop() or runBlocking()'s timeout,
mark the process result as Canceled.
In this way the Process running by a call to start()
may also finish with Canceled state. Before it was only
happening for processes started via runBlocking().

Adapt the runBlockingStdOut_data() test accordingly.

Get rid of ProcessInterface::m_canceledByUser field.
Use ProcessResult::Canceled state instead.

Fix existing 3 usages of m_canceledByUser field.
Use standarized exitMessage() method for them.

Add automatic measurement of process execution.
Introduce processDuration() getter.
Use it for reporting exitMessage() instead of timeoutS().

Change-Id: I1a68559ce844caef863a97a6b0577b0238011f70
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 20:27:38 +00:00
Ali Kianian
2144a57f2e QmlDesigner: Fix the size problems of the model editor
* The minimum size for the collection editor is modified.
* Layouts of the top toolbar are modified to show the buttons when
there is adequate space.
* A text display warning is fixed.

Fixes: QDS-11646
Fixes: QDS-11725
Change-Id: I7fe1aaf75abe13bb71f216cef13ea2b8f2cf9a9b
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-22 17:51:18 +00:00
Jarek Kobus
886ac041e5 Process: Simplify the implementation of runBlocking(Off)
Extract the common part of handling the timeout into the
handleTimeout lambda.

Change-Id: I3c55c76cbc3d1217322c1b2a7002285bf2e649d3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2024-01-22 16:29:54 +00:00
hjk
4d7a86dc5c CppEditor: Move CppFileSettingsForProjectWidget to .cpp
... and de-pimpl/re-order there.

Change-Id: I01b8e3d56ae28b0206dcd56a6cc04acf8c7b1942
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-22 15:57:50 +00:00
hjk
74cf4efb8a ClangCodeModel: Use ActionBuilder for Generating Compilation DB action
Change-Id: I89d8345351cb6da26b7ae899066a7ddfdb17fe9c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-22 15:57:35 +00:00
hjk
610a110341 TextEditor: Move test creation closer to tested code
Change-Id: I0f132dddd405bf17161e0e032f9496a90cdc5ab9
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-22 15:57:17 +00:00
Mahmoud Badri
16c7fe7e0c EffectMaker: Open effect maker doc page when help button is clicked
Fixes: QDS-11715
Change-Id: Ie360575e6af3da1ad1588a38679b5e6725cf8403
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2024-01-22 15:42:41 +00:00
hjk
2c78f260d4 Fix some compler warnings
1x warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
2x warning: class with destructor marked 'final' cannot be inherited from [-Wfinal-dtor-non-final-class]

Change-Id: I762fbe935156de9600064512bc405c6f4b2b1477
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-01-22 15:38:02 +00:00
Mahmoud Badri
7d36e0be4c QmlDesigner: Add currentProjectName() to DocumentManager
Also refactor one place that needs it

Change-Id: I9b88a5b8d9a540601897d19628a2d857bc16808d
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2024-01-22 15:29:54 +00:00
Mahmoud Badri
860e87993d QmlDesigner: Limit clearing effect maker to starting a new project
Fixes: QDS-11713
Change-Id: I8d1c33ed7ad731e710646b330af8251b61f425db
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2024-01-22 15:00:00 +00:00
Miikka Heikkinen
44f0e0819a QmlDesigner: Delete related resources if .qep file is deleted
Effect maker effects consist of .qep file under project content and
an imported module under asset_imports containing effect resources.
Now the resources module is also deleted when .qep file is deleted.

Fixes: QDS-11365
Change-Id: If3a91419970f6b26c4fc4df6d6d891b591ebedd3
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-22 14:21:48 +00:00
Xavier BESSON
df9b802842 Show color previews for QML functions
Task-number: QTCREATORBUG-29966
Change-Id: I41aa37bdc446d2b238a6a9ec0f3bd73b3fae550a
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-22 14:13:46 +00:00
Eike Ziller
ed1b6b958a ExtensionSystem/Core: Use more std::chrono
It is more descriptive than an int.

Change-Id: Ibcb8c3c6210bfa414bb33e36ee401c97ca5fab75
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2024-01-22 13:51:00 +00:00
Eike Ziller
52fb6f925b Use std::chrono for TaskProgress::setHalfLifeTimePerTask
It is more descriptive than an int.

Change-Id: I6add6a74850a9976c92509c404edb0c9fc403d21
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2024-01-22 13:50:54 +00:00
Eike Ziller
d53c5344ec ProgressManager: Use std::chrono for timed tasks
It is more descriptive than an int.

Change-Id: I129dc931b7dd137846eb97747a5277911b94e06f
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-22 13:50:46 +00:00
Eike Ziller
1a84ae038d Build nanotrace profiling by default
And enable its availability for startup performance measurement.
Makes it possible to run with `-trace <filepath>`, creating a CTF for
startup performance, without requiring a special QtC build.

Usage in QmlDesigner/DesignStudio is guarded by an additional
DESIGNSTUDIO_USE_NANOTRACE CMake option (default off), since that adds a
menu item that should usually not be shown.

Change-Id: I87200745cc32f256bcaaba21f139b4104459e49a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
2024-01-22 13:50:39 +00:00
hjk
7d7f97a747 CppEditor: Simplify setup of global file settings
Change-Id: Icef29d5ac7417bf59a21318a1fa13750f2136221
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-22 11:39:52 +00:00
Henning Gruendl
0707cca359 QmlDesigner: Fix ColorPalette Connections trigger
Fix ColorPalette Connections being triggered on all previously opened
ColorEditorPopups.

Task-number: QDS-11569
Change-Id: I2a6e44b631f4ff1187f9fbcd0afb8295b708f626
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-22 11:14:33 +00:00
Ali Kianian
1aee25bbc2 QmlDesigner: Create DataStore on demand
Task-number: QDS-11708
Change-Id: Ie08ab6260a1b720640c2c85f4b49b8093ec622d8
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-22 10:58:37 +00:00
Miikka Heikkinen
1b4a79ad92 EffectMaker: Fix loading empty value for sampler uniform
E.g. MultiEffect doesn't provide default sampler image for mask, so
we need to properly support empty values for samplers.

Change-Id: I3e000127305b79bfa04e0a661ab45137f4dec237
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2024-01-22 10:56:34 +00:00
hjk
a6f57dc25e CppEditor: Simplify CppCodeModelSettings setup
Change-Id: Ie6849caf8ded2c0901a9d2daeda6a1f81b68ed72
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-22 09:56:52 +00:00
David Schulz
628560a60e LanguageClient: deactivate a document if it was opened by the client
Do not always call deactivateDocument for all
Core::EditorManager::documentClosed emits containing textDocuments.

Change-Id: I5d9bf4c0d634837167fced4202f7edf34952c46d
Reviewed-by: Artem Sokolovskii <artem.sokolovskii@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-01-22 09:47:55 +00:00