Commit Graph

63610 Commits

Author SHA1 Message Date
Christian Kandeler
2ce03eae18 QtSupport: Relax ABI matching when fixing a Qt kit
E.g. consider MSVC 2019 a candidate when filling in the toolchain in a
Qt kit that doesn't have one yet.

Task-number: QTCREATORBUG-23653
Change-Id: I90aeb6f80c8f95faafa1e345f51fde77ddd0d2bd
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2020-03-02 11:21:22 +00:00
hjk
7dd8858fa2 CMake: Remove unused CMakeBuildConfiguration::emitBuildTypeChanged()
Change-Id: I4cb93a7f89ff4bcada2083bebd8e9e96770f4818
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2020-03-02 11:12:11 +00:00
Christian Stenger
26e4a2a758 Qbs: Fix build target key of project part
The build target key is the basic mapping of project
part to run configuration and this went out of sync
with the latest refactorings of the Qbs project
manager.
This fixes execution of tests inside the AutoTest
plugin for qbs based projects.

Change-Id: I7d7a703a341df98a015f9c83d3c2a320d46779c3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-03-02 10:12:32 +00:00
David Schulz
b718f47893 LanguageClient: Request symbols in outline combo box constructor
Change-Id: Ib7bc4f828b6e3abc4344ff96b7561015ac0cf66f
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-03-02 10:07:44 +00:00
hjk
8a8c49eb2e ProjectExplorer: Simplify update logic after active target change
Change-Id: Ia1d9366b1f2ff2b7ae02604bc43b38ca4b914c17
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-03-02 10:07:33 +00:00
David Schulz
df2525a54e LanguageClient: request symbols for all compressed uris
Change-Id: Ib6d08f7d4f1efaaa2b484af312599b8b338fbcf5
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-03-02 10:07:27 +00:00
David Schulz
6f35a66201 LanguageClient: clear compressed uri after requesting symbols
Change-Id: I1247959d657c5449a37a9e2ac16380eb9b14afe0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-03-02 10:07:18 +00:00
hjk
722705e1e7 AutoTest: Use normal object for settings
Ownership is clear here.

However, since this is accessed via the static plugin interface,
this needed some change that access.

Change-Id: I9488a242442303dee89006240f787677afab730a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-03-02 09:56:10 +00:00
Alexis Murzeau
9da71b940a MsvcToolchain: Rework detection of supportedAbis
Commit 9912a409da made changes to
implement user MSVC toolchains allowing to set custom arguments to
vcvars bat file.

This commit introduced the possibility to have multiple supported Abis
for a MSVC toolchain.
But the supported ABI detection broke with older toolchain that are
initialized with a vcvars32.bat and the like (as defined in
MsvcPlatform platforms).

msvc2010 and VC2015 build tools got affected, the detected Abis were
empty and made Qt Creator to fail to load these toolchain from
toolchain.xml (as a non empty m_supportedAbis list was required).

The effect of this is that any Kit that was referring to these compilers
was reset to "No compiler" every time Qt Creator is started.
In that case, the user could workaround the issue by reconfiguring Kits
after each Qt Creator startup or never close QtCreator which is
impractical.

This commit is a rework of the fix introduced in
708179285d which was a minimal fix
introducted in 4.10.2.

This commit fix this issue by removing the notion of multiple ABI per
MSVC toolchain and instead iterate all detected toolchain for matching
ones when populating the ABI widget via setAbis.

This also makes only one proposed ABI in the mainComboBox of AbiWidget
for any selected varsBatArchCombo. So it is no more possible to have a
32 bits proposed ABI with a /x64 varsBatArchCombo for example.

At any time, if the user wants to set a different ABI for a given
varsBatPath/varsBatArch, he can still select the "custom" item and
manually configure each part of the ABI.

Task-number: QTCREATORBUG-22960
Change-Id: I753e96db3b0e83371fa39d91c4a3592bd1552b8e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-03-01 14:44:24 +00:00
Andre Hartmann
d76a2f4fcd Deduplicate elapsed time formatting
While it's nice to see my code spreading,
I still prefer to have it at one place.

Change-Id: I7bdb13c47ed7e96227deeb14b0a8070aa40148de
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-02-29 18:21:47 +00:00
Andre Hartmann
41cb713370 SubmitEditorWidget: Inline two small functions
Change-Id: Ia9b2c451a587d418ccf39707c25d8aff062f6ed8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-02-29 18:21:29 +00:00
Assam Boudjelthia
3f61e9a391 Android: Allow adding custom NDKs and auto detect their toolchains
This adds the option for the user to add a custom NDK out of the
predefined list installed from SDK manager. Once an NDK is added and
settings saved, both the toolchains and debuggers will be detected
automatically. The user then can create a custom kit with those added
toolchains and debuggers.

Task-number: QTCREATORBUG-23286
Change-Id: I46200accca6fc956b73f211213bfe2a495093934
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-28 19:19:12 +00:00
Alessandro Portale
b4dfda5814 McuSupport: Let application wizard generate a .qmlproject in addition
It sets the qtForMCUs flag to true, so the the QmlDesigner plugin
can filter out the unsupported imports and properties.

Change-Id: Ic5728ff334b410742518c564d88d72957d6c979d
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-02-28 16:03:40 +00:00
Alessandro Portale
33904afa73 QmlProjectManager: Fix setting of QmlProjectItem.qtForMCUs
Change-Id: I0f98d21b7d343685f6e696526486ef17dc7b632e
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-02-28 16:03:21 +00:00
hjk
fb447f9999 ProjectExplorer: Trigger updates more directly
Changes of active run and build config impact some visible state, but
instead of connecting and disconnecting signals to the target, make the
call explicit.

Also, triggering only updateAction is sufficient, as this will already
run updateRunAction. This makes the number of doUpdateRunAction calls
when opening a normal QMake project with one target, three build configs
drops from 17 to 15.

There was some mechanism on the receiver side originally meant to
prevent excessive updates, which broke with 7ae3589 when remembering the
previous configurations was accidentally removed.

This here drops the mechanism completely, as active changed signals
would not trigger twice in succession for the same config anyway.

Change-Id: Id9f87e542d8871733966ab79118734b7e9ad1e8a
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-02-28 15:31:52 +00:00
Thomas Hartmann
620e17cf7b QmlDesigner: Implement usage of qtForMCUs property
If qtForMCUs is set in the qmlproject file we disable unsupported
properties like roation, transformOrigin or layer.

Change-Id: I75d9677beca3d4ce71f975b4f0ae75e63967d143
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-02-28 15:27:36 +00:00
Thomas Hartmann
ea7457410b QmlDesigner: Fix potential crash
Change-Id: I99cbddfed3d343638d707d2915e77bd962200498
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2020-02-28 15:12:41 +00:00
Thomas Hartmann
87d18ec0dc QmlDesigner: Add import filtering for QtForMCUs
This implements basic import filtering for QtForMCUs.

Change-Id: I3b8bfbee11b26f1512cd5864057a347afe09c93f
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2020-02-28 15:12:26 +00:00
Leena Miettinen
0750af7049 Doc: Describe the "Go to Last Edit" function
Returns to the last location where you made a change.

Change-Id: I35cda32d28b51b0fcfe31fd17e03ce103a87b447
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 13:54:08 +00:00
Leena Miettinen
d07d118b44 Doc: Add missing separators to menu paths
Change-Id: I58fe828d204ebc636fd529be9759bdeb5a8fe76a
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2020-02-28 13:34:53 +00:00
Mahmoud Badri
55b3d53213 Handle the case when there is no 3D Nodes in the qml doc
When there is no 3D node in the qml doc, the view 3D will still be
enabled and manipulate-able. Also few relevant tweaks.

Task-number: QDS-1693
Change-Id: I758f783108b317a6971703bee8e3fb564400ed8b
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-02-28 13:19:44 +00:00
David Schulz
4165d16053 Core: Fix rounding issue in highlight scrollbar
Fixes: QTCREATORBUG-23660
Change-Id: Ifcaf4e705a0a037c58ffedf36605b3eecfc698de
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 12:47:39 +00:00
Assam Boudjelthia
a75cb04442 Android: keep the debuggers list updated with auto detected toolchains
Current autoDetected Android debuggers list is never cleaned, if one
sets up many NDKs it could get really big and messy. This change tries
to keep it clean from old or duplicate entries, as well as keep it
chained to the autodection mechanism of Android toolchains and kits.

Relies on 291807 to allow autoDection for kits, toolchains, debuggers
to work out-of-box.

Change-Id: I320a021f0435d80fd3d56c060caa316def533afa
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-28 12:39:48 +00:00
Cristian Adam
bafa0d9495 CMakeProjectManager: Add elapsed timer
Change-Id: I1e7bcd60cae0193b4d16f20175b76550aaefbf9c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 12:33:13 +00:00
Leena Miettinen
85bcef044c Doc: Fix typo "fil" > "file"
Change-Id: Iaa0f25c9ef0c76f2923f91354304e3b0c6bb78b1
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2020-02-28 12:04:42 +00:00
Leena Miettinen
fb185eef11 Doc: Update screen shot to show the list of locator filters
Change-Id: If6b4068676e994ce5ec684432983df3f173dfab5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 11:57:45 +00:00
hjk
fbd1574a85 ProjectExplorer: Fix use of build step list preamble messages
The step list names are computed separately anyway, having an
extra preamble consisting of concatenated build list names on
one line looks unnecessary.

Change-Id: If754c6363042927210dfd09c23f2f494081f8c47
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-02-28 11:48:35 +00:00
Assam Boudjelthia
94a9528156 Android: deduce the NDK path of saved toolchains from compilerCommand()
The change 290840, made AndroidToolchain tied to an NDK location, but
when restoring a toolchain the NDK wasn't being assigned. This deduces
the NDK location from the toolchain compilerCommand().

Change-Id: I3cd936ac48570fadbec15ac1e13496706718c0ea
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-28 11:42:43 +00:00
Assam Boudjelthia
351f39fb3b Android: fix sdkmanager duplicating packages list
It seems that forcing sdkmanager reloadPackages is causing a duplication
in all packages and ndk listings.

Change-Id: I7e92d1c6dcec2a09db088d9596aca31a3d8b437f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-28 11:42:28 +00:00
Jochen Becher
e7784b592d modeleditor: Add icon name to object outline for intersection
Change-Id: I09b65a675e4d2205d0be2b1ca1687f2ceffe4285
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-02-28 11:42:14 +00:00
Orgad Shaneh
ba87fb2083 Git: Add actions for changes in output window context menu
Change-Id: I5aa46f87b82670286ac225d71a3a045133976e86
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 09:53:51 +00:00
Orgad Shaneh
ab3e2ac0fc VcsBaseEditor: Fix tr context for Copy action
This amends commit 7677e3e197368bd206dc565368cb3f33d951d092.

Change-Id: Ib07dc2a8110a8e09f43c035989d9ffa84e0427d3
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 09:44:55 +00:00
Orgad Shaneh
a01035fefb VcsBaseEditor: Highlight default actions on context menu
Change-Id: Idc493658dbc829394bd2898a59ba5686036bc3fe
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 09:39:14 +00:00
Leena Miettinen
a8c9d394fd Doc: Replace "Qt Bug Tracker" with "Qt Project Bug Tracker"
Add links where they were missing.

Change-Id: I218c1160226ec5223e6bd055d73e82092f254792
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 09:30:42 +00:00
Leena Miettinen
d119258c9d Doc: Describe new help options
- Only latest docs are registered by default
- Users can change the settings for displaying help in
  the detached help window

Change-Id: Id7efb98e11eb8a27b7d01422e65ac63b860c868e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 08:58:56 +00:00
David Schulz
0776340ad8 Dumper: unify Codestyle
generated with autopep8 and the introduced setup.cfg

Change-Id: I5b55a7937f2cde81be59d2b434e94ada1a4af5ab
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-02-28 08:35:05 +00:00
David Schulz
8940522fe2 Core: calculate highlight scrollbar margins at compile time
Change-Id: I9ce008c438f888df1c7f97df5ccb1868705e0636
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 08:34:31 +00:00
Leena Miettinen
ae98f91f1b Doc: Update info about finding with the locator
- Describe the new bug filter
- Describe the new URL template custom filter type
- Update screenshots

Change-Id: I830b3953e89e97a7e5a405687915b67153412d9a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-28 08:10:00 +00:00
Orgad Shaneh
d9ca238ffe VcsBaseEditor: Remove default actions when right-clicking a reference
Change-Id: I2e8abd4487756be2535934ca8ab4d6b9105e6088
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 07:06:49 +00:00
Orgad Shaneh
9455b144b2 VcsBaseEditor: Remove unused functions
Change-Id: Ida1df50aee0c146d8070e62292163d34cd53f65a
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 07:02:44 +00:00
hjk
488bd7eddb CMake: Check parseGuard.guardsProject()
... before overwriting the current guard, retaining the
state of the current guard in the error case.

Change-Id: I45ec43d48a9a13b9b59a5bbe6415a457b974b654
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-02-27 16:27:34 +00:00
Fawzi Mohamed
a670e203b1 Ensure that null dereference in test is not optimized away
Change-Id: Icf8eb894a8277353448f46b18d5d6614be1d2350
Reviewed-by: hjk <hjk@qt.io>
2020-02-27 16:08:09 +00:00
hjk
b3ca796d97 Qmake: Use buildableFileProFile(node) for Build File action
Should be at least theoretically the right one, but is mainly
done to always feed a QmakeProFileNode * to the 5-args
handleSubDirContextMenu().

In practice it does not seem to impact the current level of brokenness:
In case of Build->File with not-synchronized editors the action shows
the name of the file selected in the project view, while it actually
builds the file in the current editor.

Change-Id: I47f8f22eb80be18d1be5997a861cea89bd069d1b
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-02-27 15:54:41 +00:00
Eike Ziller
956fd44c3e TextEditor: Improve splitting top/bottom
If the text cursor is visible, but in the bottom area of the editor, it
would be no longer visible after splitting. That makes the probable
"area of interest" vanish from sight.

Check that condition (visible before, but would not be visible
afterwards), and if that is the case center the text cursor in both
resulting editors.

Change-Id: I8c8dccd2d9db439c82d0aca34b8ef99fa97aa48e
Reviewed-by: David Schulz <david.schulz@qt.io>
2020-02-27 14:25:58 +00:00
Christian Kandeler
bd03041428 QtSupport: Prevent misleading message about ABI mismatch
MSVC 2015/17/19 are ABI compatible, but BaseQtVersion::validateKit()
would emit a warning when using e.g. a Qt MSVC 2017 build with an MSVC
2019 toolchain.

Change-Id: I50ba026ae7b55e052b26826076ef962f369a05a1
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2020-02-27 14:21:06 +00:00
hjk
a84e626b67 ProjectExplorer: De-QObject-ify ToolChainFactory
As collateral damage, use a capital C in  KeilToolchain*.

Change-Id: If9d64de2108366546683144975d975d9d1727712
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-02-27 13:58:24 +00:00
Christian Kandeler
bcc2b5e08d "New Class" wizard: Try to find a base class header
If the project has a header file whose name suggests that it might
declare the base class, then add an include statement for it.
While we cannot guarantee that the include statement is resolvable as-
is, it's at least a basis for the user to adapt accordingly, while
without any include statement the class will definitely not compile.

Fixes: QTCREATORBUG-3855
Change-Id: I55ec43d58a9a13b9b59a5bbe6415a457b974b654
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-27 13:28:23 +00:00
Leena Miettinen
171ad62aed Doc: Describe linking Qt Creator to a Qt installation
... for sharing auto-detected Qt versions and kits

Change-Id: Ie0063b0a66a58508bb848b2b8fb4b29cadc35c26
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-02-27 12:07:04 +00:00
Leena Miettinen
5278f69851 Doc: Fix typo "ajust"
Change-Id: I6a974dc9e9f9439392cf8029740fe72415f80e54
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2020-02-27 10:03:58 +00:00
Eike Ziller
0585ad0f64 Merge remote-tracking branch 'origin/4.12'
Change-Id: I4523ea36332772a310fd462df55683c93c61bb18
2020-02-27 09:41:05 +01:00