Commit Graph

67787 Commits

Author SHA1 Message Date
Christian Stenger
ae7aa56733 KSyntaxHighlighter: Fix compile
Amends 6b9cad8b05.

Change-Id: I9f254e254edfadeb4fa1e41c20514463477d7184
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-08 09:40:22 +00:00
Leena Miettinen
2fa0e96f19 Welcome: Add links to Quick Tips in the Tutorials tab
Update the link to the Qt Creator introduction and remove some
links that are less relevant in the Qt Creator context.

Fixes: QTCREATORBUG-24603
Change-Id: Ieebf4b051f5a34db84ba4f35c250d67f71168a43
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-09-08 09:17:28 +00:00
Christian Kandeler
cba414d501 ProjectExplorer: Fix crash when setting up run control
Amends 215b284666.

Change-Id: I2d820113153fc1c3326de00f38a5d14d71a501c9
Reviewed-by: David Schulz <david.schulz@qt.io>
2020-09-08 08:52:39 +00:00
Eike Ziller
7aa0b1ea6b TextEditor: Fix build with Qt6
Adapt to QStringRef and QAbstractItemView::viewOptions() removal

Task-number: QTCREATORBUG-24098
Change-Id: Ia2d446312f68bd60143796284d31f5bba56aa0ed
Reviewed-by: David Schulz <david.schulz@qt.io>
2020-09-08 07:47:30 +00:00
Eike Ziller
6b9cad8b05 KSyntaxHighlighting: Use QStringView instead of QStringRef
QStringRef will be removed for Qt6, or moved into a Qt 5 compatibility
library, but the QString API will be removed.
Switch to QStringView instead.

Task-number: QTCREATORBUG-24098
Change-Id: Ia3cab3de24ba36b5db64e1eff18d92e66ccd3d94
Reviewed-by: hjk <hjk@qt.io>
2020-09-08 07:10:39 +00:00
Eike Ziller
5de5686179 KSyntaxHighlighter: Replace usage of deprecated enum value
QNetworkRequest::FollowRedirectsAttribute is removed in Qt6,
use the semantic equivalent.

Task-number: QTCREATORBUG-24098
Change-Id: I73822f87bd8b6464e9b5d0ba871fec322cbdd8b9
Reviewed-by: hjk <hjk@qt.io>
2020-09-08 07:10:24 +00:00
David Schulz
5299eb5bec TextEditor: Fix clean whitespace action
This is a partial revert of: e7f784ca73

Fixes: QTCREATORBUG-24565
Change-Id: Iffa149e0f97c315355f211f6ae3856fad08f4f3d
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-09-08 04:23:14 +00:00
Knud Dollereder
d64ebc0f8b Fix easing-curve-editor context menu for macOS
Change-Id: I99eac383dbd247e42392424712eed001e2750008
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-07 15:04:37 +00:00
Eike Ziller
b7fda95477 Core/fileutils: Do not use QTextStream::setCodec
Gone in Qt6. Write into a string buffer and bulk convert and write that
into the file with QTextCodec.

Task-number: QTCREATORBUG-24098
Change-Id: I266e90e166a22c8b34b2963458af1cc4f5d2df82
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-09-07 12:40:27 +00:00
Eike Ziller
8d09191d2d Core: Fix compilation issues with Qt 6
- qrand() is gone
- adapt to incompatible change to QVariant constructor with custom types
- QAbstractItemView::viewOptions() is gone

Change-Id: I931d963fc4370077d628740ed90ca36c4e9ba1d5
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 11:59:10 +00:00
Eike Ziller
e223e2480a Core: Do not use QStringRef
It is gone in Qt6.
QXmlStreamReader changed return values from QStringRef to QStringView,
so use auto there.

Task-number: QTCREATORBUG-24098
Change-Id: I806f01c20574721bfaa4b100747ef0bba75874a0
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 11:59:02 +00:00
The Qt Project
7721d5c29a Merge "Merge remote-tracking branch 'origin/4.13' into master" 2020-09-07 11:58:43 +00:00
Miikka Heikkinen
2387b56012 QmlDesigner: Don't set ALWAYS_SAVE_IN_CRUMBLEBAR when no changes in qml
Core::DocumentManager::saveModifiedDocument doesn't set the alwaysSave
flag if there is nothing to save, which led to undefined results as
the flag was left to uninitialized state.

Change-Id: I9417775241123b9e1bb3b57b6ced96bc555fb635
Fixes: QDS-2718
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2020-09-07 11:39:35 +00:00
Miikka Heikkinen
b7e660471f QmlDesigner: Fix typo in settings key
ALWAYS_SAFE_IN_CRUMBLEBAR -> ALWAYS_SAVE_IN_CRUMBLEBAR
AlwaysSafeInCrumbleBar -> AlwaysSaveInCrumbleBar

Change-Id: I939c5631301ea8edcac6f07bbc08af2994907117
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2020-09-07 11:38:13 +00:00
Eike Ziller
df97d40a0d Merge remote-tracking branch 'origin/4.13' into master
Change-Id: Iab93dc48b4a38fb4c698481bbf02a5a65e08206b
2020-09-07 13:19:38 +02:00
Eike Ziller
f1806621f8 LanguageUtils: Don't use leftRef/midRef which is gone in Qt 6
Task-number: QTCREATORBUG-24098
Change-Id: I033a2ec3fcbb4569a7c60b39489c7dee8779d31f
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 10:14:14 +00:00
Eike Ziller
102d8d48db CMake build: Make Qt6::Core5Compat available in a portable way
While porting to Qt6 we'll need the compat library at some places.
Add a custom Qt6Core5Compat target that we can unconditionally use.
For Qt5 it refers to a dummy target.
For Qt6 it refers to the actual compat library.

Task-number: QTCREATORBUG-24098
Change-Id: Idd2b9f285352f685cfe715eee3fa046dfb468873
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2020-09-07 10:13:39 +00:00
Eike Ziller
7e8c3e91a1 Utils: Fix build with Qt6
Do not use QStringRef related API, replace with QStringView where
appropriate.

Adapt to removal of QAbstractItemView::viewOptions().

Task-number: QTCREATORBUG-24098
Change-Id: I5a7a9821984583222083733f91b46df39c21d592
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 09:07:57 +00:00
Eike Ziller
3dd224c466 DockingSystem: Add missing include
That is no longer indirectly included with Qt 6.

Change-Id: Ia1e73ad7ffee023dec2145811e7796aaa423e5ba
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 09:07:43 +00:00
Christian Kandeler
b0cad9e9c7 OutputFormatter: Fix visual glitch
When inserting a line into an output window, we have to delay appending
the line feed character. Otherwise strange visual effects appear under
certain circumstances.
I have no idea why.

Fixes: QTCREATORBUG-24411
Change-Id: If8842ae4d9db36d514996b1f34dcca0432fafbfc
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
qds/v1.6.0-rc1 qds/1.6.0-rc1
2020-09-07 08:35:15 +00:00
Orgad Shaneh
f73f11d8c6 Git: Highlight newly added keywords in interactive rebase editor
Change-Id: I571e9576fcb781fda4dc5ce2df8a6bbc3a8abf9e
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: David Schulz <david.schulz@qt.io>
2020-09-07 08:32:37 +00:00
Christian Kandeler
9c99aa223d ProjectExplorer: Delay task icon creation
Parsers can change the initial task type when accumulating output, and
then the original icon would no longer match.
To the user, the problem manifested itself by a missing error symbol in
the issues pane and a missing text marker in the editor.
Fix this by delaying creation of the icon until it is used.

Change-Id: I5349f21c6c0d9bc39a5000ceb33faf88ea62eeac
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 07:33:45 +00:00
Alessandro Portale
a650997448 QtSupport: Add supportsMultipleQtAbis getter
Introduce bool QtSupport::supportsMultipleQtAbis().

Let AndroidQtVersion respond according to the QVersionNumber.

This allows to replace the version arithmetics in several
places with straight forward (and better findable) function calls.

Task-number: QTCREATORBUG-24471
Change-Id: Ib6e39fd6485a54e08ad66f84d4e2582989043419
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 07:10:26 +00:00
Eike Ziller
13b72eb621 FileSearch: Remove usage of QTextStream::setCodec
Gone in Qt6. Read the whole file contents and decode instead.
This is not ideal since we possibly load big files into memory.
But otherwise we'd have to implement a buffering, file-based IODevice
that reads into a buffer, part by part converting to unicode with
QTextCodec::toUnicode(const char *input, int size,
QTextCodec::ConverterState *state), similar to how it is done in
QTextStream from Qt5 (QTextStreamPrivate::fillReadBuffer).

Task-number: QTCREATORBUG-24098
Change-Id: I22e251c8217d49880df59980cf32a8febf93364b
Reviewed-by: hjk <hjk@qt.io>
2020-09-07 06:25:41 +00:00
David Schulz
568cd8066e QmlDesigner: Fix compile for CMake/qbs
amends 913dc6473d

Change-Id: I1337ca5016ca3111ef0b3d714b909b40cdb93ff3
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-09-07 06:13:20 +00:00
Leena Miettinen
86da0a006a Doc: Update change from "+" to "Create New State" label
States view layout was also changed, so update screenshots.

Change-Id: I0e4535add8720375e40fcf0e65b20061d94c5150
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-04 15:09:24 +00:00
Orgad Shaneh
9a7535d9e9 Debugger: Support C structs in dumpers
The lookup for qdump function was done by "struct Foo" instead of just
"Foo".

Change-Id: I325d00910a0c13c5e67692737033531e18392247
Reviewed-by: hjk <hjk@qt.io>
2020-09-04 14:51:13 +00:00
Christian Kandeler
b74d620bf0 CppEditor: Fix crash with adjacent raw string literals
Our lexer is not good at handling newlines embedded in raw string
literals; basically, it sees every continuation line as a new string. So
if such a continuation is followed directly by a new raw string literal,
we have to take care to tell them apart properly. In particular, it can
happen that an end delimiter occurs before an opening delimiter.

Fixes: QTCREATORBUG-24577
Change-Id: I631d0617d85e91f49a25d309d53778da0170eb3b
Reviewed-by: David Schulz <david.schulz@qt.io>
2020-09-04 13:51:55 +00:00
Christian Kandeler
3b415f5ebd Vcs: Add "bulk delete" feature to API
... and use it to improve the user experience when removing several files
at once from a project.

Fixes: QTCREATORBUG-24385
Change-Id: I8e8c39ee9dc0046f1715a5143a7649fab06e5ad8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-09-04 13:41:08 +00:00
Orgad Shaneh
e504d96934 Merge remote-tracking branch 'origin/4.13' into master
Change-Id: I8a2dca29595a0770f4162786b15a145f3f4133af
2020-09-04 16:11:12 +03:00
Christian Stenger
b7573a7400 QmakePM: Fix possible nullptr access
Amends fc1fc6a07a.

Change-Id: I0a77c3834fc8e68de2f2d3ab379256c7adc00260
Reviewed-by: hjk <hjk@qt.io>
2020-09-04 12:30:38 +00:00
Miikka Heikkinen
913dc6473d QmlDesigner: Choose target property when dragging image to material
When dragging an image to a Quick3D default or principled material,
pop up a dialog to choose the target texture property.

Change-Id: I8d97ef5bf7c5192c2651fcd8cf64a7f4a87c9847
Fixes: QDS-2326
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-04 11:58:15 +00:00
Miikka Heikkinen
5cc7dae965 QmlPuppet: Improve gizmo precision
At high zoom levels, picking precision of the gizmos was not good,
because compounding inaccuracies from multiple floating point
operations required. Fixed by reimplementing many operations using
double precision math.

Change-Id: I013876b816379a20b552eb06d2f9cbb3f2aa2d21
Fixes: QDS-2676
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2020-09-04 11:58:04 +00:00
Miikka Heikkinen
e6343c296a QmlDesigner: Generate qml id from image file name
When dragging an image file to create a Image or Texture item,
base the id on the file name rather than setting it to generic name
based on type.

This includes cleanup of AbstractView::generateNewId to remove
redundant and unused code as well as an option to provide a fallback
id prefix.

Change-Id: I563f1760ffbace9c5c2145477ec8736836f36c45
Fixes: QDS-2328
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
Reviewed-by: Mahmoud Badri <mahmoud.badri@qt.io>
2020-09-04 11:48:27 +00:00
David Schulz
ef10f3b937 ClangTools: Add QuickFixes to the editor
Change-Id: I9862231f0aa8e8274e8529e57e80eac5ececded9
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-09-04 10:14:39 +00:00
David Schulz
b55a313b3d TextEditor: make TextEditorWidget constructor explicit
Change-Id: I0b2e5b8c09706697efa4c2fbc3bc7483d02f68d3
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2020-09-04 10:14:30 +00:00
David Schulz
dba4bff703 TextEditor: use Utils::FilePath as file member in AssistInterface
Change-Id: I3bf9b013b9350411f918efdb9d1a36a2c22bf972
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-09-04 10:14:21 +00:00
David Schulz
339db00f85 Core: replace QString with Utils::FilePath to get documents
Change-Id: I01777c227398be8bd3bf877c5429b84a75aa361b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-04 10:14:14 +00:00
David Schulz
e4dec0484c ClangTools: Remove useless member FixitsRefactoringFile::m_filePath
Change-Id: I686eddeea7c52096175c3b2fe1a519e8fbf2c876
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-09-04 10:14:02 +00:00
Leena Miettinen
f1bb1bf572 Doc: Describe using uniforms in custom effects and materials
Fixes: QDS-2723
Change-Id: Iea02261220026ab210fc82fb27ceee0277abb62d
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
2020-09-04 09:58:44 +00:00
David Schulz
7bbbdeac52 ClangTools: use VFSoverlay if the clang tool supports it
check the help output of a clang tool whether virtual file
system overlay is supported. Prepares for the vfso support
of clazy-standalone.

Change-Id: I157c94de1dda41c83945c9bc8a4c2e132b2e6551
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2020-09-04 09:48:44 +00:00
Aleksei German
3f99be2ee8 QmlDesigner: Fix for Animation Properties LineEdit
Deactivated an option to translate properties names.

Task: QDS-2737

Change-Id: Ieadd4cd56094f09c961234a5b2790c2380e1106a
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-04 09:12:55 +00:00
Leena Miettinen
c11c09386c Doc: Fix link to Adding Dynamics from online doc sidebar TOC
Change-Id: I7e4de42079cde8c6b7b0315968e5f17c529648e6
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2020-09-04 08:53:57 +00:00
Christian Kandeler
215b284666 ProjectExplorer: Properly set up the output formatter
... for the app output window.

Fixes: QTCREATORBUG-24560
Change-Id: I199d7b16f445db498027094792c6cf344d920a88
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-09-04 08:50:13 +00:00
Vikas Pachdha
f6e013c80e Doc: Add asset export documentation
Task-number: QDS-2729
Change-Id: I0af45f22a49cf0a8a74bc6bd9a0b0c3fd4091e1f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2020-09-04 08:42:32 +00:00
Thomas Hartmann
2f77a9bcfc QmlDesigner: Fix crash
Change-Id: Ibb6a14b4b684482b8c6098933a79929c2bd09add
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-04 08:40:11 +00:00
Eike Ziller
43ee53c233 CMake build: Qt6 build fixes
Set Qt5_VERSION for version checks (e.g. currently still JavaScript
locator filter).

Export special FindQt5.cmake for external plugins and super-repo builds.

Change-Id: I5edb8b0e8bef1a341cd2ff04a13d0a6ce22f6558
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2020-09-04 07:41:57 +00:00
Christian Stenger
f9600b7335 CMakePM: Fix removing cmake tools
The id might be destroyed with its parent before trying to
reference it again and put it into the list.

Change-Id: Ic7bb053293b24f0f0109a1c6479f73b7cbec2dc0
Reviewed-by: hjk <hjk@qt.io>
2020-09-04 04:32:49 +00:00
Christian Stenger
80054d1971 Utils: Do not try to parse empty files
Change-Id: I204a20bf1fee3b1163f841de0e98c4da86c9a943
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2020-09-04 04:31:38 +00:00
Aleksei German
f849319d11 QmlDesigner: Disable more properties for QUL
Turned off Controls properties and Animations.

Task-number: QDS-943
Change-Id: I4b9868734c74f5319fd7d3e66b57d59007300340
Reviewed-by: Thomas Hartmann <thomas.hartmann@qt.io>
2020-09-03 16:17:52 +00:00