Commit Graph

44349 Commits

Author SHA1 Message Date
Jochen Becher
80e5259999 ModelEditor: Implement zoom of diagrams.
All elements of a zoomed diagram must be dran anti-aliased. This change
removes the extra handling of drawing vertical or horizontal lines
without anti-alias. The complete graphics view is drawn anti-aliased
instead.

Change-Id: I6fc041b6d70da5a7a7bcb8e97d07990517380b90
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-24 16:58:30 +00:00
Eike Ziller
5fcf0c438f PluginManager: Code clean up
Mostly refactor some explicit loops, and nicer reverse looping.

Change-Id: I102b86da597b37cd496762bd776af73ec407d838
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-24 12:30:05 +00:00
Marc Reilly
9ccb089870 tooltip: make TextTip links clickable
This enables the text to contain links which the user can click on to
follow.

Change-Id: I892d1d915a48974e72adb0e712d46220560f5537
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-24 12:21:14 +00:00
David Schulz
34f75be322 Git: Add a do not ask again checkbox to the pre checkout message box.
Makes it possible to not query the user on every checkout if he wants to
create a local branch.

Change-Id: I22d8ef03fb98648cafb3f11a008bb24c291cb807
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-24 11:50:17 +00:00
hjk
438697219f ProjectExplorer: Fix comparison with default-constructed Runnables
Regression was introduced with 3f11ef9216.

The original check asserting 'that != 0' is still needed without
dynamic_cast, as d-pointer of 'other' can be statically 0 for
default-constructed Runnable objects.

Change-Id: Ibee898ffc61fb2f4a6a6276390fdf6d517fde546
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-24 11:31:46 +00:00
Eike Ziller
b06cc736f4 Fix compilation with QT_NO_ACCESSIBILITY
Task-number: QTCREATORBUG-16446
Change-Id: If75122c23a697f26ccf56391fe2e8d316aad6367
Reviewed-by: hjk <hjk@theqtcompany.com>
2016-06-24 10:21:25 +00:00
David Schulz
1a68968c22 ClangBackEnd: Fix unsaved file printer for default constructed object.
Change-Id: Ifcc8c2b60521e1f48ca2921d568b4e18d9d0a4eb
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2016-06-24 09:15:23 +00:00
Nikolai Kosjar
05c1efd8ef Clang: Fix dot-arrow-correction for not-yet-parsed unsaved content
The issue was re-producible with e.g.:

    void g()
    {
        // Type 'foo.' as fast as possible in the next line

    }

This led to "foo->" with completion results as if there was no "foo." at
all in that line.

We relied on a correct position for
translationUnit.sourceLocationAtWithoutReparsing(), but the just typed
characters were not yet reparsed. And we do not want to reparse at that
point since takes too long. We already determine the utf8 position for
the dot character, so simply use that instead.

This completes commit 17c1325cc4.

Change-Id: I669888b5c17ee63b2aec7b16c9921f9d79e281f9
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-24 08:31:28 +00:00
Tobias Hunger
82a5320a42 Core: Stop crash in systemsettings
Do not crash when updating the Git path settings.

Task-number: QTCREATORBUG-16305
Change-Id: Ia6b7f529aa243b5e0b2778aeaddbbd86da9e265a
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-24 08:14:38 +00:00
Tobias Hunger
d5dc6f7f70 Utils: Use runBlocking in shellcommand
This is run in a background thread, so there is no need to keep the UI
alive.

Change-Id: I81267b918ef2350a180b0a8ee55244feca2406b4
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-24 08:14:32 +00:00
hjk
2536c2bfc7 TreeModel: Re-order template arguments for tree levels
More natural and easier to extend to use parameter packs later.

Adjust users.

Change-Id: Ic167196cc969d18bb1615084397e884f769d1e85
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-06-24 07:34:13 +00:00
Nikolai Kosjar
a1749f9a14 Clang: Fix dot-arrow-correction for zero results
If there are no completion items, do not add snippets since these will
otherwise pop-up at undesired positions, e.g. when:

 1) Typing float/doubles: 0.
 2) Typing file suffix in include directives: #include "stdio.

Task-number: QTCREATORBUG-16188
Change-Id: Ie1c29826dc62dc447b2ff57b0c5537eb9d9511ef
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-24 07:29:27 +00:00
Christian Stenger
075a6f6805 Extensionsystem: Fix compile for gcc 4.7.3/Qt5.5...
...and avoid warning.

Change-Id: I1291c02b6c4a707f43235582db211933da0072a4
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-06-24 03:03:48 +00:00
Orgad Shaneh
573958e79f Git: Prompt for unchanged file after custom mergetool fails
To reproduce, create a conflict and configure a custom mergetool that does
nothing:

git config mergetool.my.cmd true
git config merge.tool my

Then execute merge tool from Qt Creator. The merge tool process hangs
while asking how to handle the unchanged file, and can only be killed
externally.

Change-Id: I4d2a91061bd7549e308f6a25f106e6a7afc5cadb
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2016-06-24 03:00:43 +00:00
Marco Bubke
7d342471a4 SmallString: Fix ambiguity of iterators
std::size_t is a undefined unsigned integer type and std::ptrdiff_t is a
undefined signed integer type. So sometimes the compiler doesn't know
which to choose because both could represent a integer.

Change-Id: I669cd44c6f16854dfe3f3cc44edbfc422e1cbd6a
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-23 14:08:43 +00:00
Christian Stenger
8219188738 AutoTest: Disable QmlDebugger for debugging tests
Currently debugging tests is enabled only for C++ based projects
and starting QmlDebugger although not needed feels wrong and results
additionally in a fail message which might be confusing for users.

Change-Id: I1f62b67ea6d3d8bb56d9723ea1132257d0b96b9b
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-23 13:44:32 +00:00
Orgad Shaneh
53c4b36e4a Git: Resize columns in branches dialog when data is changed
When setting a tracking branch, creating or deleting a branch.

Change-Id: I58dd06912fbf23900674a8714224ee414f1da4b7
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-23 13:05:27 +00:00
Orgad Shaneh
3d63136836 Git: Show date and time for newly created branches
Task-number: QTCREATORBUG-16484
Change-Id: I18b262d2d03f6a793123cc655f415a1d46d1a4e3
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-23 13:05:23 +00:00
Tobias Hunger
bd63402fb8 Fix warnings about missing overrides
Change-Id: I655a0678ae55cf47c6014c52e0f62f7a85cf2dc7
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-23 13:05:14 +00:00
Thomas Hartmann
78be4281c1 QmlDesigner: Fixing DocumentWarningWidget
* Connect was missing
* The check box contains the opposite truth value of the setting.

Change-Id: If6ef86e0e1107ce537ee05ddf983131f65ee9e20
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-23 12:57:44 +00:00
Marco Benelli
8f474cbfbe QmlJs: fixes bug in module import search.
Task-number: QTCREATORBUG-16425
Change-Id: I5fdd1a5882730c0f52dba5edb8cf8ca7092a4409
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
2016-06-23 11:55:42 +00:00
Christian Kandeler
e54b53cdaa qbs build: Use precompiled headers.
It was an oversight that we haven't done this before.

Change-Id: Ic338503f6c1ca5e6c52c9af3bdbdb92b7776cac1
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-23 11:45:37 +00:00
Eike Ziller
b9bd611e25 PluginView: Functional style dependency list creation
Change-Id: I08c6aeb8be55e73a9d8e55e264046afc19c9e4b9
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-23 08:34:07 +00:00
Nikolai Kosjar
73dbcb49fd QmlDesigner: Fix build (missing include)
rewritertransaction.cpp:84:56: error: invalid use of incomplete type
'class QmlDesigner::RewriterView'

Change-Id: Ibbd757ef99a75633337722caa54630baba929cc6
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-06-23 07:12:54 +00:00
Christian Stenger
8562abbb56 AutoTest: Avoid crash when accessing uninitialized runnable
Change-Id: I87bbf5b824a693a2c8d653bf5093e088f01b84b5
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-23 07:11:02 +00:00
Nikolai Kosjar
90bd65479b Clang: Fix warning
readmessageblock.cpp:95:36: warning: comparison between signed and
unsigned integer expressions [-Wsign-compare]

Change-Id: I24c5125f2116e5538b7d0e2389e66bf5d318640a
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-23 06:41:21 +00:00
Nikolai Kosjar
438bd85b84 Clang: Fix updating revision number for all translation units
Change-Id: I1ad305ed081aecadde968e041f7b99a24a1c4784
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2016-06-23 06:29:14 +00:00
Nikita Baryshnikov
0ad2ae3e57 VcsBaseOptionsPage: deinline dtor
Change-Id: I314ce3b6b95d0e04ca548b3ae6e6975b670e8336
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-06-22 22:29:02 +00:00
Jean Gressmann
d9d2d638f7 Fixes parsing of MSVC file locations for parallel builds
Change-Id: I2a8456d2f1bb14dc8fff1df02b7580fa708d0249
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-22 18:52:20 +00:00
Takumi ASAKI
88819d0490 Beautifier: Fix untranslated DISPLAY_NAME
Change-Id: Ifad91eaada5f7614767b6332a643723de79fc6b2
Reviewed-by: Lorenz Haas <lorenz.haas@histomatics.de>
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-22 17:52:10 +00:00
Thiago Macieira
74fed1d5b7 Fix build on PPC: PPC is defined to 1
$ powerpc-poky-linux-gcc -dM -E -xc /dev/null | grep -i PPC
 #define _ARCH_PPC 1
 #define __PPC__ 1
 #define __PPC 1
 #define PPC 1

Not on PPC64, though (only __PPC__ and __PPC64__ are defined).

Change-Id: Ib57b52598e2f452985e9fffd145812f5098e441d
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2016-06-22 17:51:20 +00:00
Dmitry Ashkadov
43075f5fb1 C++: Add support of ref-qualifier for functions.
Now the ref-qualifier (& or &&) of the function declaration
is propagated to GUI. For example,  'Refactor' -> 'Add Definition'
preserves the ref-qualifier.

Change-Id: I8ac4e1cad4e44985e94230aabbd9858a7e929fee
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-06-22 17:47:59 +00:00
Philip Lorenz
c0f3094866 C++: Fix lexing of >> / >>=
The current code always ends up setting the token to T_GREATER_GREATER.

Change-Id: If75ff1f5bccffd5918ec2bf491724cd0981220ae
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2016-06-22 17:46:40 +00:00
Thomas Hartmann
a073cbe214 QmlDesigner: Adding logging category to TextToModelMerger
This allows some easy benchmarking.

Change-Id: Ib9e16542870d0fc47fc2a0441311020730b79203
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 16:17:45 +00:00
Thomas Hartmann
9410a812b9 QmlDesigner: Allow to disable semantic checks in transaction
The semantic checks are slow and sometimes we knoe that they
are not required.

Change-Id: I43cae131e4c5f47d2a61d34975913dd8cb6370fc
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 16:17:38 +00:00
Thomas Hartmann
e31a389b0f QmlDesigner: Ignore semantic checks in form editor
Those checks are slow and not required for moving and resizing.

Change-Id: If9ad047cf2401d39f729134beb813e095ef96abd
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 16:17:34 +00:00
Thomas Hartmann
3fb0dc379a QmlDesigner: Use correct overload of QGraphicsScene:items
QGraphicsScene:items() is deprecated and returns incorrect results
if the scene contains items that ignore transformations.
We have to use the overload that takes a QTransform instead
and define itemsAt for convenience.

Task-number: QTBUG-49627
Change-Id: I388c62dd23a61c569ec6b99d756f4fbe1024e5db
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 16:17:30 +00:00
Thomas Hartmann
add3828389 QmlJSEditor: Do not allow child items for states
Task-number: QTCREATORBUG-13003
Change-Id: I30bcee12803d2b3af804625ffdf417316e3d6c32
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 15:52:56 +00:00
Leena Miettinen
d04f103602 QtQuickDesigner: QML Design Mode > Design Mode
Change-Id: I1756704b4121fb8d60b9e895413ce4f7b0069551
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-06-22 14:13:03 +00:00
Thomas Hartmann
adae324aba QmlDesigner: Adding tooltip for canvas color
Task-number: QTCREATORBUG-14819
Change-Id: I0929f899e84e6bc5415d8c699fc4df53a2fe561b
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2016-06-22 14:02:44 +00:00
Eike Ziller
5838874b1d Plugin Tests: Make 'all' override previous args, and give sensible order
If you write "all" it should mean "all", and "load" order makes more
sense than "alphabetic".

Change-Id: If90b665d714efaf0919ad418fbbe02c50a0fced2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
2016-06-22 13:50:12 +00:00
Tim Jenssen
4cc69911e9 QmlDesigner: refactor populateQrcMapping
no behavior change

Change-Id: If932cb51b4179a1f79824f9b6660bf45db1e8aee
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-06-22 13:17:17 +00:00
Tim Jenssen
9271770c64 QmlDesigner: show output for valid items
Change-Id: I1de98626ff9f2b3cac594bf9a0f802623c16ce90
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-06-22 13:17:00 +00:00
Tim Jenssen
d21c90983b QmlDesinger: remove QtQuick 1 items
Change-Id: I439e3bacbe8bde7a82194e247bcb47dff926bcc2
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-06-22 13:16:52 +00:00
Tim Jenssen
5a11d5cd5b QmlDesigner: use initializer lists
Change-Id: Ie93861c7d8a5b2863ec8b111afceacc2c163715b
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@theqtcompany.com>
2016-06-22 13:16:33 +00:00
David Schulz
c8ef91f789 Revert "TextEditor: Do not delete both quotes on backspace"
We have a more intelligent placing of double quotes, that should
eliminate some of the incorrect/unwanted placed closing quotes.

Additionally we introduced an animation and highlight of automatically
inserted text. So it should be definitely clear that the closing quote
is going to be removed.

If there is still someone who gets annoyed by this reintroduced behavior
there is now a setting that lets you control the deletion of
automatically inserted text.

So it is safe to reintroduce the deletion of closing quotes on
backspace.

This reverts commit 4a0b2039c0.

Change-Id: I92500ac218dc4c2e07a3b0ad01b06e6baa2e2c6c
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2016-06-22 12:50:36 +00:00
Marco Bubke
eba6da37c6 Clang: Fix aliasing
Task-number: QTCREATORBUG-15888
Change-Id: I0f2e28e9e0da53481c03707ab0a9abf728c7419f
Reviewed-by: hjk <hjk@theqtcompany.com>
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
2016-06-22 12:44:25 +00:00
Nikolai Kosjar
1ea6404337 CppTools: Allow prefering getter names with "get" prefix
We default to "foo()" for e.g. a member variable "m_foo", but other
coding styles require "getFoo()".

Task-number: QTCREATORBUG-16452
Change-Id: I9ccfdf88e4c469bc1c06fde855ad754faf2bd238
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2016-06-22 12:22:57 +00:00
Nikolai Kosjar
b928a1ce46 CppEditor: Extract determineGetterSetterNames()
...and make it a bit more readable since we are going to make some
changes there.

Change-Id: Ic1d0c47a36ef4547a4842508c2404e9fc12f5220
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-22 12:20:25 +00:00
David Schulz
5a78fcb434 Editor: Restrict deletion of automatically inserted characters.
Remove automatically inserted characters only when the cursor wasn't
explicitly moved or the editor hasn't lost the focus after the
completion.

Change-Id: I9e995dc4ce79194b073b1bce3fa4dbc025a09a94
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
2016-06-22 10:53:00 +00:00