Commit Graph

61529 Commits

Author SHA1 Message Date
Nikolai Kosjar
9034c6ade6 Utils: Add logging category to SynchronousProcess
This helps to debug e.g. runGcc(), which is used for detecting
predefined macros or header paths for the code model.

The log gives also a (limited) overview of the (blocking) processes that
are run on Qt Creator start up.

The produced command line is copy-pastable.

The generated output looks like this:

  qtc.utils.synchronousprocess: Starting blocking: /usr/bin/x86_64-linux-gnu-gcc-8 -dumpmachine
  qtc.utils.synchronousprocess: SynchronousProcessResponse: result=0 ex=0
  17 bytes stdout, stderr=""

  qtc.utils.synchronousprocess: Starting blocking: /usr/lib/icecc/bin/clang++ -x c++ -E -dM -
  qtc.utils.synchronousprocess: SynchronousProcessResponse: result=1 ex=115
  0 bytes stdout, stderr="ICECC[9867] 2019-07-03 13:00:35: couldn't find any clang++\nICECC[9867] 2019-07-03 13:00:35: could not find clang++ in PATH.\n"

  "The command \"/usr/lib/icecc/bin/clang++\" terminated with exit code 115."

Change-Id: I9bc7b24121801b0c98c52416848734d850aa9f4d
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-04 06:26:13 +00:00
Robert Loehning
c4512f466a QmlDesigner: Consistently capizalize "Flickable"
Change-Id: Ie291f5cd2b5091a885945d074c9ea08aa14d7f84
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-03 17:11:53 +00:00
Andre Hartmann
89dda94dca QtOutputFormatter: Support relative file:// links
QUrl does not have good support for relative file paths, and it
seems there is little interest to change it: QTBUG-44921

Work around this by constructing the QUrl again on failure with
fromLocalFile(). In this case, the "file://" scheme has to be omitted.

This issue was detected because some compilers generate paths with
native Windows separators, like "..\main.cpp" for the __FILE__ macro.

Debugging the issue showed, that rather the relative path was the
problem, as the QUrl constructor does not support it.

Change-Id: I30074a3d11f9f43e05cd202f6d86c752ce184785
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-03 16:00:25 +00:00
Denis Shienkov
881f4d5f38 BareMetal: Fix typo in option to enable C++ language for IAR
We need to use the '--c++' option instead of '--ec++'
to dump the macroses and headers for the C++ language.

Change-Id: I545e661babc1ffa84ef189d28b2dd59bc3ccf29b
Reviewed-by: hjk <hjk@qt.io>
2019-07-03 15:42:36 +00:00
hjk
9b0feb726e Use more toList/toSet to avoid deprecation warnings
Change-Id: I43575a54ff944bf0e89d452d13944fcaee270208
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-03 15:39:59 +00:00
Nikolai Kosjar
6f6949125a Clang: Fix typo in function name
Change-Id: I8beb948071c0f33b664d05a5ce3a9390ebeeff11
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
2019-07-03 14:55:06 +00:00
Friedemann Kleint
a27b50dcaf algorithm.h: Fix compilation with Qt 5.13.1
Fix the version check for the developer branch.

Amends c2fd7743e0.

Change-Id: I552330bcbbd00367d8b7044d3bf5dc6952d1a469
Reviewed-by: hjk <hjk@qt.io>
2019-07-03 13:44:43 +00:00
hjk
c2fd7743e0 Fix compilation with Qt 5.13
Change-Id: I6e95bf74dc3a123aa635f0a44a2ea357a6dd7da2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2019-07-03 13:26:53 +00:00
Henning Gruendl
a5bb85c76b QmlDesigner: Fix shortcut override
Change-Id: I34867b463ce480542a894404f749fa46db06cc84
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-03 12:56:06 +00:00
Henning Gruendl
e62eeb5aeb QmlDesigner: Fix DoubleSpinBox in-/decrease issue
Change-Id: I072600fa8ca43828d6e03515af34caef6c8cefbe
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-03 12:43:52 +00:00
Ulf Hermann
5daae2cf6c QmlDebug: Queue the socket error and disconnect signals
Apparently these can be sent synchronously on trying to send something
over the wire. Synchronously handling the signals at that point is
dangerous as the rest of the system might be in some transitional state
(e.g. just destroying the clients).

Fixes: QTCREATORBUG-22640
Change-Id: I21a0c92a6334d401390cf6d92b9b855b83cc6307
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-03 12:26:24 +00:00
Ulf Hermann
96a3c80609 QmlProfiler: deleteLater() the debug message and engine control clients
Nesting the dtors of the different clients is dangerous as the
connection might call back into a virtual function of a half-destructed
object this way.

Fixes: QTCREATORBUG-22640
Change-Id: I91fccc41fbea40a7f78ef344759abe26d140434d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-03 11:52:42 +00:00
Christian Kandeler
bf0d84074f Let users configure the number of recent files shown
Fixes: QTCREATORBUG-21898
Change-Id: Ie804e722f9bb88762da57f157833e4dc43d8ccbf
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-03 09:09:06 +00:00
Thomas Hartmann
7cd504511c QmlDesigner: Hide the cursor when dragging in SpinBox
Change-Id: I3900c510bc5510eaba51ea2ae8700aa9ca72f59a
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-03 07:49:40 +00:00
Thomas Hartmann
572a3c8937 QmlDesigner: Use backspace on macOS
Change-Id: I8398d60b32e5bb65b47bf87b6309c805be4c48b5
Reviewed-by: Brook Cronin <brook.cronin@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-03 07:49:26 +00:00
Thomas Hartmann
e16c948ab7 QmlDesigner: Increase size of SpinBox for Flickable
Change-Id: Ie1343d8cf0dbe41eefd2027a1daa0133cbd109c3
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:23:10 +00:00
Thomas Hartmann
370b436650 QmlDesigner: Fix ListView property editor layout
We have to use Layout.fillWidth consistently.

Change-Id: I6052fb8c1a2b2cdc704bba70db1f2bf26730232f
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:22:56 +00:00
Thomas Hartmann
76d0a16a81 QmlDesigner: Hide label if text is empty
Otherwise we get padding on the left.

Change-Id: I62d78bf988cefe8c91f55268a71c70094f163d5d
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:22:39 +00:00
Thomas Hartmann
1a4aedf568 QmlDesigner: Increase the compression timer for SpinBox
Change-Id: I8fe7b2b3645d053255b2486e0584f7f16f77997c
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:21:40 +00:00
Thomas Hartmann
868b07853d QmlDesigner: Use new combobox for layout properties
Change-Id: I52e353011b290a59c66003db8b2becd4cd160820
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:21:20 +00:00
Thomas Hartmann
a93e9d7a7a QmlDesigner: Improve custom property editor for URL
Change-Id: I1bf81df8df94bc7d1469b484f6a66f874887b214
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:11:27 +00:00
Thomas Hartmann
6eb0bec95c QmlDesigner: Add editors for font, Text and Rectangle
This requires adjustments of FontSection.qml.

Change-Id: I60eb17c299c73da42726dead0d8713a91d4af932
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:11:11 +00:00
Thomas Hartmann
feaf2a3b95 QmlDesigner: Extend support for custom property editor
* Allow custom '.' properties to show up in custom editor
* Allow custom property editors to span multiple sections

This allows us to support alias proprties to e.g. Text and Rectangle
items.

Change-Id: I7939a5cf5769387dbb3a27df0fd9e74c493a577c
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 16:10:40 +00:00
Christian Kandeler
4fc3ee8e5b clangsupport: Fix compiler warning about initialization re-ordering
Change-Id: I330940e05fe29632f7cb0628151fdec11708b826
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 14:39:04 +00:00
Christian Kandeler
7b2d41a972 qbs build: Suppress some GCC 9 warnings
Otherwise, we get thousands of warnings from Qt, e.g.:
    qvariant.h:275:25: warning: implicitly-declared ‘constexpr QVariant::Private& QVariant::Private::operator=(const QVariant::Private&)’ is deprecated [-Wdeprecated-copy]

Change-Id: I8b3bbfae6791adca8bcfacc7ad5ab46701474aa4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 13:47:56 +00:00
Leena Miettinen
5a9505d7b8 Doc: Add info about dynamic properties
Change-Id: I366cefbee393b44afb4ef0fa5a8ab978eb0d5c69
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-02 13:20:21 +00:00
Leena Miettinen
5b68dde3ca Doc: Fix the path to Timeline editor images
The icon files were moved to a new location.

Change-Id: I45b2ed9e78cb9fd3b00a75a37598df2beba745e2
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-02 13:19:55 +00:00
hjk
0715917414 ProjectExplorer: Rename one ToolChainFactory::autoDetect overload
... to detectForImport(). The overloads have different purposes,
sharing the name makes reasoning about them hard.

Change-Id: I57bfbbc1aa06ef85251e39c404bdbe5584a2ea41
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-02 13:03:31 +00:00
hjk
36fcd52136 Utils: Add toSet/toList functions
As replacement for functionality that's being deprecated
in Qt but still useful or needed, or that cannot easily be handled
without resorting to #if QT_VERSION checks in user code.

Change-Id: Id3575a54ff944bf0e89d452d13944fcaee270208
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-02 12:48:54 +00:00
hjk
ed2371fb3b ProjectExplorer: Remove now unused code in MinGW toolchain detection
Change-Id: If2903a8f188ae581c30c47d3b036898987d4134a
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-02 12:43:24 +00:00
Henning Gruendl
a6d5da5af2 QmlDesigner: Add RealSpinBox and refactor SpinBox
* Transfer all changes which came up while Qt Creator integration
 * Refactor states by using dedicated edit property
 * Refactor alias properties
 * Set SpinBox slider indicator default to false
 * Add CheckBox tri-state
 * Fix Menu closePolicy
 * Remove some connections
 * Fix TranslationIndicator
 * Add new values and fix some missing scale factor multiplications
 * Add new icon font
 * Use MenuItem instead of Action for context menu due to shortcut issue
 * Add RealSpinBox due to the following bug QDS-806
 * Refactor SpinBox with findings during RealSpiBox implementation
 * Fix SpinBoxIndicator enable/disable state
 * Fix RealSpinBoxIndicator enable/disable with a new property called
   realEnabled and synching between the actual property and the new one
 * Make RealSpinBoxIndicator increase/decrease on release
 * Add drag start/end signals
 * Fix indicator behavior exiting/entering while pressing (and holding)
 * Fix wheel and dragging step size for increase/decrease
 * Fix reset of step size for cursor keys
 * Fix press and hold timer
 * Set decimals 0 by default (int by default)
 * Replace SpinBox with RealSpinBox in HelperWidgets

Change-Id: Ieda049595e6483b052fcdf4ca597f6af66e5f4dc
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-02 12:12:12 +00:00
Christian Stenger
7c4209416c PE: Fix tool tip of invalid toolchain
Change-Id: I1b0c387217fbd766b867266d7af3036b6a25d9c3
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-02 11:57:17 +00:00
Christian Kandeler
6ec55e06ce ProjectExplorer: Add tests for GCC 9 output parsing
Task-number: QTCREATORBUG-22107
Change-Id: Ifbda4ac2e55c8e07bd71cd6386d289a4c31bdd76
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 11:52:52 +00:00
Andre Hartmann
b950936d45 Git: Correctly handle aborting pull commands
For example, aborting a "git pull --rebase" command
did not work, because the old code tried to run
"git pull --abort" instead of "git rebase --abort".

As side effect, this patch also enables the Skip commit
button in handleMergeConflicts(), that was not shown
before.

Change-Id: Ifa43a4ba0199c97fdf8a361eb9e0207704d93e26
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-07-02 11:04:54 +00:00
David Schulz
9aef0c2ad3 Debugger: Fix rvalue dumper test for cdb
Change-Id: I4c977944928e97c69f7d1f4b1c666a42b443481a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 09:22:02 +00:00
Thomas Hartmann
05a53204fd QmlDesigner: Set property editor scale factor to 1.1
Change-Id: Ibf2db6490ec908d8a2952fa88ca42e7d4c049f3f
Reviewed-by: Brook Cronin <brook.cronin@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2019-07-02 09:12:01 +00:00
Robert Loehning
fdc7086c5f Squish: Update Designer tests
Change-Id: I64a63a69bb6e62c29af73918d98e9a924a221f80
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 09:10:10 +00:00
Christian Stenger
9da3077651 VCS: FakeVim: Ensure log editor is handled as readonly
Fixes: QTCREATORBUG-22595
Change-Id: Iab51eda5e55d36e98cf0ba5116853d6bee1dbd10
Reviewed-by: hjk <hjk@qt.io>
2019-07-02 08:41:51 +00:00
David Schulz
853f1226e0 Debugger: Fix QStandardItem dumper test
Change-Id: Ic4b965da9589a7bade4f96226bff3bb14987602c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 08:26:23 +00:00
David Schulz
1571384e49 Debugger: add dptr child to QDir for msvc targets
Makes it possible to access the entry lists if these were populated by
the code.

Change-Id: I066824d2ce7f75a38d208155156c93d06458f8b3
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 08:26:14 +00:00
David Schulz
302be8acb9 Debugger: Fix qdir dumper test for cdb
entryInfoList and entryList is not supported by cdb, because we cannot
call the count function to populate these lists.

Change-Id: I6f1f2b5905232d4b220120b1b0a20bfea029c9f0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-02 07:59:36 +00:00
Orgad Shaneh
a1ba347fa5 Git: Fix popping of branch-stash after checkout
Checking out a branch that has a saved stash, when
Pop branch stash is checked, is broken since checkout
became asynchronous.

We must wait for checkout to complete before popping
the branch stash.

Change-Id: Ia4d43649e742ced0121ffe106986b4d6ed1e7b38
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2019-07-01 19:57:02 +00:00
hjk
0d7f33aa71 Core: Work around upstream introduction of std::hash<QString>
Change-Id: I51d7e97011d03b1b1af921e55ccc40a61d8822f7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-01 16:05:23 +00:00
Christian Kandeler
dfb6fbed7c "New Class" wizard: Add option for adding the Q_OBJECT macro
This lets users specify that a class derived from a custom base should
have a Q_OBJECT macro, and it also allows them to opt out of it for
classes derived directly from QObject & friends.

Fixes: QTCREATORBUG-21810
Change-Id: I850bd3bcb7b6eb71720afe5fa097178ff5d5c620
Reviewed-by: hjk <hjk@qt.io>
2019-07-01 15:19:18 +00:00
Michael Weghorn
cf7fa03866 Add tests for printers with custom allocators
Add tests for the cases where std::vector and
std::basic_string are used with custom allocators,
which were fixed by commits
01f26bd5b7
("Fix std::vector<bool> printer with custom allocator")
and 5eba3bde93
("Fix std::basic_string printer with custom allocator").

Change-Id: I4de9de551d329b7d2ea821d09b04d39da13f1edf
Reviewed-by: hjk <hjk@qt.io>
2019-07-01 14:50:16 +00:00
hjk
725ed099b7 Qbs: Inline qbsbuildstepwidget.ui
In preparation of aspectification.

Change-Id: I9461045db9f997d7ce74cf0c99e0a9159a682e1c
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2019-07-01 13:38:42 +00:00
Christian Kandeler
42d331a90c QmlDesigner: Remove some unused members
Change-Id: I31c92d2c9d5ab08acc9a32016b761e8bc27ddbeb
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2019-07-01 13:24:24 +00:00
Orgad Shaneh
55653db029 Dumper: Fix std::map<K, V>::iterator dumper
The iterator type is std::_Rb_tree_iterator<std::pair<K, V>>

Change-Id: I0ed2f2e6955deb4b402277fe0f3eb32b6af2d477
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-01 12:51:37 +00:00
Christian Kandeler
a503c00fd4 ProjectExplorer: Do not emit notifications from Kit::copyFrom()
This function is a building block for other operations. Emitting a
signal from it will likely provide subscribers with invalid state.

Fixes: QTCREATORBUG-22628
Change-Id: I975638dfa3b453a54c747186b0f6b834c02be035
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-07-01 12:21:47 +00:00
Christian Kandeler
1a416840a1 DocumentManager: Fix off-by-one error in max number of recent files
Also update the value so we don't introduce a behavior change.

Change-Id: Ie6d474c0d62f041afd84acdd90c1c09d23c57d46
Reviewed-by: hjk <hjk@qt.io>
2019-07-01 11:51:16 +00:00