Get rid of code repetition. Use some lambdas.
Change-Id: Ib344a2fdb0079faa86091d67e78c0c67c7ed077b
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
... from the syntactic highlighter.
For instance, in this piece of code:
void myfunc()
{
const auto rawString = R"(abc
de)fg"hij)";
}
The closing parenthesis inside the raw string literal is mis-interpreted
by SimpleLexer as closing the string, causing the next one to be
interpreted as an actual parenthesis, which would then be erroneously
matched against the opening brace of the function.
We fix this by removing parentheses that the semantic highlighter knows
are not actual punctuation tokens.
Change-Id: I057b9e747ed81282cdddd71a805c12db9616da65
Reviewed-by: David Schulz <david.schulz@qt.io>
Unix only for now, opt-in, by setting QTC_BACKTRACE_MAXDEPTH=<number>
in the environment.
Change-Id: Ice110dbf5d25003706a947b27c279fec464df7a1
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Apparently, we used to rely on relative paths being resolved elsewhere,
but we shouldn't.
Fixes: QTCREATORBUG-26304
Change-Id: Ia52b728909abc87c1225f8e935f4548a32ca9b63
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
- Update screenshots
- Add missing properties
- Divide the Group topic into Node and Group topics because
the Node properties are common to all components that inherit
Node.
Task-number: QDS-4888
Change-Id: Iaf114cd09ead755c9754423fb6b47eff0292cb3f
Reviewed-by: Johanna Vanhatapio <johanna.vanhatapio@qt.io>
A QPainter on a QPixmap behaves differently on Qt 5 and 6 when it comes
to the pixmap's devicePixelRatio. On Qt6/DPR>1, the text in this code
would be rendered outside the pixmap. Forcing the DPR of the pixmap
to 1 while rendering the text fixes the issue.
Since I cannot test on all platforms, nor have a multi monitor setup
with different scalings, I added some cargo cult code which resets the
original DPR after rendering. Just to be on the safe side.
Fixes: QTCREATORBUG-26315
Change-Id: I32ce78a45d52a4c75eb437574b925c85b9295402
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Linux mingw uses lowercase headers, so cross-building on Linux for Windows
target must use the correct form. Windows is case-insensitive, so it won't
affect host-native builds.
Change-Id: Ic2140412bb367bbce83b5e2546d70e0936928c5c
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: David Schulz <david.schulz@qt.io>
Correct size policy for Add and Remove Ndk buttons to take the size
allowed to them.
Change-Id: I71f046eb18986c4d1215867efdf381105a16842f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Collapse AdvancedSection and LayerSection by default.
Task-number: QDS-5136
Change-Id: Ia60c47095749e7181156a79a652d6a56633ee3a6
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Make the auto test wizard available also without the AutoTest plugin
being loaded.
For the wizard it suffices to depend on the presence of CppEditor
and all of the projects generated are basically C++ based.
Change-Id: I76b8d397e819b2865ad597f487084ad4c618c6a5
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
... after updating the parenthesis in the layout
Task-number: QTCREATORBUG-26183
Change-Id: I346046fbc3932b94227c1ac5bee6b0d7c44651e1
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Do not clear out "semantic parentheses" in the syntactic highlighter.
Fixes: QTCREATORBUG-26183
Change-Id: I88f085b63da2469341dbb29eabc7f033367e6f19
Reviewed-by: David Schulz <david.schulz@qt.io>
It's not worth the extra effort to restrict the identifier <-> file name
check to data types: There is hardly any possibility for a completely
false positive, as local variables do not pass through this code path.
Change-Id: Ia92549c8c6723e520789a2ad820a2606620d4efe
Reviewed-by: David Schulz <david.schulz@qt.io>
I don't see any explicit sorting of the references in clangd, so let's
continue to not rely on that.
Change-Id: I65269af4995ab851e49f52686a10cc96697fbe64
Reviewed-by: David Schulz <david.schulz@qt.io>
* Fix offset calculation (arrived at top in less than 200ms)
* Use "OutQuad" easing for the speed of the sliding text
* "Fade in" separator line and description during animation
* Animate covering of image by background color
* Draw rectangles with qdrawutil (fixes HighDpi)
* Change refresh timer from 5 to 10 ms
Change-Id: I53899227d875a3faf086ebc6b3d83e5eb9dcaa12
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
That filter (by default included with 'a') could end up showing files
from projects that were no longer open. In some situations the
directories for this filter could be saved in the settings even though
they are supposed to be automatically managed when opening and closing
projects. It could happend that they never were removed again, for
example after saving the locator settings via apply in the options
dialog, and then killing Qt Creator.
Simply never save or restore which directories the filter handles, and
the file cache, by overriding the save/restoreState methods.
Change-Id: I2912d64443b5e5ec5a21e0df61d14ffda799a0e7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Callers can have legitimate reasons to use it in a non-const manner.
Change-Id: Id91a4708dd95845661b291ce7cc9ee1581bdade8
Reviewed-by: David Schulz <david.schulz@qt.io>
Partially reverts 6a142dfd95
Looks like this was used by 3rdparty plugin(s) for a mode that is only
useful for some time and then should not be shown again.
Re-add removeMode from before 5.0, but do not trigger that automatically
from the mode destructor, so it doesn't interfere at shutdown.
This patch is just a binary compatible partial revert. Since removeMode
is broken in several aspects (e.g. corresponding commands are not
removed) and we don't really support adding and removing modes during
runtime, this should be replaced later on by a different way to handle
the usecase, like a "visible" property for modes, which could be useful
in other ways too.
Fixes: QTCREATORBUG-26270
Change-Id: Ief2a36d94bd09b0511a14f528b33fdbcc4c4222b
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Using a regular expression to search for possible macro usages
will not omit commented out lines.
So, check matches for being commented out to be able to filter
out false positives.
Change-Id: Ie8f982ef418a4538e87567354adb0eb54ea918de
Reviewed-by: David Schulz <david.schulz@qt.io>
Can be used to easily reproduce the current windows state that has no
way to map the remote file system to a local path on other systems like
linux.
Change-Id: I32cd1852dd0b4fc0890a503c244f34065c29e18c
Reviewed-by: hjk <hjk@qt.io>
Drop the macroExpander argument, at the cost of complicating internal
ProjectConfiguration setup a bit.
Simpler code at the user side.
Change-Id: Ie9ea0b719f6e402b44d9ba7ce6047aa4e15441fe
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
- Keep the Window, but move the page into a separate QML file
to which you add states
- Explain how to bind the icon to the rectangles in the states
to make the UI scalable
- Update the transparent icon and instructions for setting the border
transparent
- Add and update screenshots
Fixes: QTCREATORBUG-26291
Change-Id: I68c6b7b897c7824b43b9e0fa719e37864841ba9b
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
CMake doesn't associate header files in a compiler group in the
file-api export. But it does list them as source files if added
to the source files of a target.
By using the CppEditor::ProjectFileCategorizer we can sort the
header files to the right compiler group.
This way one could have the clang-tidy and clazy run on a header
file. Or the TODO plugin find TODOs in header files. Or the Autotest
plugin finding Google Tests in header files.
Fixes: QTCREATORBUG-23783
Fixes: QTCREATORBUG-23843
Fixes: QTCREATORBUG-26201
Fixes: QTCREATORBUG-26238
Change-Id: I8acace48e89fd9b3da8bce1c479dec7891e1bbd4
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This is only enabled if no QmlDesigner plugin is found.
When a .ui.qml file is opened we check for a QDS installation.
If QDS is installed we propose to open QDS instead, if not
we show information on QDS.
Search oder for .qmlproject file. QDS requires a project file.
* Check if current project is .qmlproject
* Check if the current folder contains a .qmlproject
* Check folder for .qmlproject that contains the .ui.qml file
* Check parent folder for .qmlproject ...
If not .qmlproject is found we show an error message.
Enabling external link support for InfoBar.
Task-number: QDS-5065
Task-number: QDS-5066
Change-Id: I2c70c400c4d11b83a4848f9e002e180fa119f6e2
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
dialog was just created and cannot be null.
CID 1506796: Null pointer dereferences (REVERSE_INULL)
Null-checking "dialog" suggests that it may be null,
but it has already been dereferenced on all paths leading to the check.
Change-Id: I53c116620c91b5b41b4028e367cb286e13193cf7
Reviewed-by: Tony Leinonen <tony.leinonen@qt.io>
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>