We cannot do this via a static library, because the tests need
to compile the same files with different defines
(QMLDESIGNER_TEST). Add a function which extends a target
with the corresponding files.
Also do not hardcode resource directories in the test -
the Qt Creator app bundle is no longer in a "bin/" subdirectory
on macOS. Use the build system provided IDE_*_PATH
variables instead.
Change-Id: I21850eba3cb47b4dcfd5e66227183b2d1ff35ff2
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
We forgot to update the timestamp indicators which lead to several
triggered updates e.g. when modifying and storing a qml file inside
a watched directory.
Change-Id: I30858ea9e8073d648a84c7f188dff18ddef5b1c1
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
If the position was changed right before the document was edited the
timer might still be running.
Change-Id: Ieaa4de5cc10f25e6d58afaf9525417e11a34d1db
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Using LanguageClientManager::openDocumentWithClient function to assign a
document to a specific server. This function also takes care of
deactivating the document for the old client and opens it if necessary
in the new client.
Fixes: QTCREATORBUG-26205
Change-Id: I3c3a5fbcd3d07c2e492ebffdf7870e4d2cb517d4
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
The reap() method needs to be called from the same
thread as the passed process lives in.
In case we are passing a process that lives in a non-main
thread, we move it into the main thread and schedule a call
to reap it again, this time from the main thread.
In addition, make sure that Internal::d is accessed only
from the main thread.
Change-Id: I32c836584b5da3050f9254e53cee352c79e536b9
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
I saw this getting triggered recently, and would like to see more
information if it happens again.
Change-Id: I1c616b8126b8b5eea3709a97124968e9e706aaf3
Reviewed-by: David Schulz <david.schulz@qt.io>
The wrapper scripts of emscripten 1.39.8 (required version for Qt 5.15)
do not actively use the python interpreter which -at least on Windows-
is found under EMSDK_PYTHON.
This change appends the parent path of EMSDK_PYTHON to the environment's
PATH to make wrapper scripts (e.g. emcc.bat) work.
Fixes: QTCREATORBUG-26199
Change-Id: Icbc89f6d930f1c5ac5e4e6ac919383cfdd1b913b
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
There was no proper separation of responsibilities between these
plugins. In particular, CppTools had lots of editor-related
functionality, so it's not clear why it was separated out in the first
place.
In fact, for a lot of code, it seemed quite arbitrary where it was put
(just one example: switchHeaderSource() was in CppTools, wheras
switchDeclarationDefinition() was in CppEditor).
Merging the plugins will enable us to get rid of various convoluted
pseudo-abstractions that were only introduced to keep up the artificial
separation.
Change-Id: Iafc3bce625b4794f6d4aa03df6cddc7f2d26716a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
- Annotation Dialog structure was reworked
- Added ListView to Global Annotation Dialog
- Added Apply button to all Annotation dialogs
Task-number: QDS-2243
Change-Id: I2f271d4ae91d33b26a050287b20a86050e081830
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
If rootPath is empty, QtCreator will crash.
Fixes: QTCREATORBUG-26126
Change-Id: Iac0d29d84d7203c0ec2ac8f5e3035816f52d7cdc
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
* Change the look of the picker cross
* Cleanup custom RGB, HSL, HSV and Alpha value storage and handling
* Fix issue of alpha not updating when selecting gradient stops
* Fix initial color not shown correctly
* Fix ComboBox warning about parameter injection
* Add checkerboard image to GradientLine
* Remove GradientPopupIndicator
* Add signals to RealSpinBox in order to react to user interaction
* Cleanup code
* Change how porperty editor value emits value if old and new color are
equal
Task-number: QDS-4755
Change-Id: I1a8095664fc8ed53c52659ac20557c03b89704c9
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Especially with the "remote" scenarios synchronous operations cannot
be expected to work reasonably well.
This here starts with adding asynchronous versions to some of the
FilePath member functions, taking additional "Continuation" style.
This is not necessarily the final syntax (sugar like .then(...) comes
to mind...), but is simple enough for now for the few uses we have,
and it is too early to see what will be needed in the end.
Change-Id: Idf4dde1b77d04cafb81b6c024031145bdd91a762
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Callgrind on Remote Linux did not work for years, so its safe to ignore
the remains from the previous remote support and start over.
This here now handles the local case and the case where callgrind
runs together with the debuggee in the same docker container.
Guessing at the output file name is replaced by specifiying it in
advance.
Cross-setups are not yet supported.
Change-Id: I97edeb4eab7475727eddb26d25f8bec650a7eeb9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Measure it on demand. The printout will appear when
QTC_MEASURE_PROCESS env variable is set. It may be easily
combined with QTC_USE_QPROCESS to compare the time spent
on freezing Creator when starting Creator or when loading
a big project, like Creator project.
In order to compare the measurement between
old implementation (using directly QProcess) and
new implementation (using process launcher) of QtcProcess
do the following (linux):
1. To measure the new implementation:
QTC_MEASURE_PROCESS= ./bin/qtcreator
2. To measure the old implementation:
QTC_USE_QPROCESS= QTC_MEASURE_PROCESS= ./bin/qtcreator
How to measure (two scenarios, A and B):
A. Launch Creator (don't load any project), wait a bit
until all processes finished. Look for the last value
in the 11th column ([A/M] Total Measurement, A means
all measured functions, M means in main thread only).
This value has the greatest influence on GUI freeze -
the higher it is, the longer the GUI is frozen.
Measure it with 1. (new) and 2. (old) implementation
and share your results.
B. Launch Creator and load a Creator project.
Wait until all processes finished (taskbar should be empty).
Look for the last value in the 11th column.
Measure it with 1. (new) and 2. (old) implementation
and share your results.
C* (Additional one)
If only you notice that launching a certain QtcProcess takes
suspiciously too long, replay your scenario that triggers
this process with 1. and 2. and share your results of
the 11th column.
Change-Id: I549c0a9fd0b3d6223f3d27288130553d99ab768e
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: hjk <hjk@qt.io>
When creating a new component by dropping it to a component in the
navigator, check the parent if it contains properties that are the
same or sub type as the new created component. Those properties are
shown in a list that the created component can be binded to.
This edits the dialog that was for textures only and uses it for any
component on creation.
Task-number: QDS-4969
Change-Id: I3f1ecc6a82254f77a9bb170406ef79740359a889
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
- scroll bar only visible when needed
- change color when active
- remove useless stuff
- remove 3 warnings
Change-Id: I0fbab4ca574c060f85adb0d5b6b54381337a7eae
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Not optimal, but will suffice for docker callgrind.
Change-Id: Iac669fe9dd29206df2a4ffc61d659afce2f7a6c4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Remove the process in process launcher after error has appeared.
Remove unneeded stopStopProcedure as we are disconnecting from
process' signals inside removeProcess().
In order to behave as much similar to what QProcess does,
provide a test that:
- ensures the FailedToStart error is synchronously emitted
when waitForStarted is being executed
- ensures that process state is reset to NotRunning after
FailedToStart error
- 2nd call to start/waitForStarted doesn't block on
waitForStarted
Change-Id: I139354421d037739f1cc1a2685b66f1e5b6170c8
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Make sure returned default QVariant() is valid.
Change-Id: I323001df3505bbe740f8f660de9c199aed05aac6
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
QtcProcess is derived from QObject, it doesn't
have these methods anyway.
Change-Id: I7a334c97739d40b28a78ab98a322417256c1117c
Reviewed-by: hjk <hjk@qt.io>
... by Target::activeBuildKey.
This is effectively the same problem under the hood, but isolates
it a bit.
Change-Id: Ie37a4d67aab3e044bb99b7b8d2bd7900198c5538
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Instead of returning a pointer to LauncherSocket instance,
which might get deleted in meantime of just after,
route all calls to the LauncherSocket through the LauncherInterface.
Make all calls to LauncherInterface secured by the
instance mutex.
Change-Id: I751228de5f4263112471098ee08cc73a5245147e
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Since e755094480 we have a global option
in Qt Creator to set the (base) environment for any tools run by Qt
Creator. So it is expected that any tool actually uses
Environment::systemEnvironment() as a base, which is the system
environment modified by the global option.
QtcProcess already had a fallback to Environment::systemEnvironment for
resolving environment variables in Qt Creator macros in the command
line. Also use it as a fallback for the actual environment for the
process.
Latest occurrence where the global environment setting was ignored was
for starting language servers by our LSP client.
Change-Id: Id1a4141326d8ef3239b37d7f3daf21928605ca92
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Was missing a slash after the userResourcePath.
Broke with 8e352af0ec
Change-Id: I2f60e3dcaa07b13cd2459ee6a3aa67b51075545e
Reviewed-by: hjk <hjk@qt.io>
coreplugin.cpp:407: error: C2664: 'QString
QString::arg(qlonglong,int,int,QChar) const': cannot convert argument 1
from 'const char [11]' to 'qlonglong'
note: There is no context in which this conversion is possible
qstring.h(444): note: see declaration of 'QString::arg'
Change-Id: I2c4122c4bf0f6b35f6f7b45b2c2d014ac7863065
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
The correct type in Qt 6 is QtQml.Models.ListModel
Change-Id: Ic6e488eea1feef150bb49d0d4f873f6bd5bac3c5
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Qt 6 changed the color for QPalette::PlaceholderText to a hardcoded argb
value in qt_fusionPalette(), which does not work well with dark themes.
This change restores the rgb values for QPalette::PlaceholderText from
Qt 5 for Qt Creator's dark themes.
Task-number: QTCREATORBUG-25444
Change-Id: I197d367ac6e35085a093abfee07467291010e3ba
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
If a restart for a client has been staged for restart the
shutdown of QC may coincide with the start of the client which
leads to a crash on exit. Correctly track clients that never
successfully started to clean them up on manager destruction.
Change-Id: I639a76318d1665653fbcd37841fcaf407f3d3a83
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
Rendering effects requires actually rendering another item.
The effect is defined by another item that is rendered instead
of the original item.
For items that have an effect we do not render the children, since
the effect is only applied to the layer not the individual items.
We set layer.enabled temporarily to false, this ensures the effect
is not rendered as part of its parent item.
To detect the effect we use the source property an check if it points
to the ShaderEffectSource.
If one of the children inside the effect is transformed we have
to update the effect item.
If layer.enabled or layer.effect is changed we set the dirty flag
on the item and all children.
Change-Id: Iff61ef950e62a7a598b4bfa181ea70cb144368f3
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
No need for a copy.
Change-Id: I0308da77199942ef49e36fb04e81713cb9d9a901
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Prevent doing many copies of QFutureInterface when
running async tasks and pass it by reference instead.
Change-Id: Ic49cfd86a6c651b1b94f791d79a40c99703370ec
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
It works without nowadays, and even with Qt 6, with its
bundled QtScript version.
Update Qbs to HEAD of 1.20 for a build fix.
Change-Id: I060ddec595c989852dc5861594423d5ffa5f521d
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>