FakeVim needs some notification even in cases where the
duplication is triggered outside the EditorManager as in
QmlDesigner's qml-editor.
Fixes: QTCREATORBUG-22344
Change-Id: Ia4950ff4b02d3f89779f03ff4c106a07ccff2106
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
The coreplugin/id.h header is kept for downstream for now.
Change-Id: I8c44590f7b988b3770ecdc177c40783e12353e66
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
New icon is: Utils::Icons::RELOAD. And the toolbar variant is now
Utils::Icons::RELOAD_TOOLBAR.
Change-Id: I811d83c7340a717968430ac1ce4a5c708c8ddcf9
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
For some reason, Q_UNUSED includes already a semicolon, adding one
on the user side creates an additional empty statement.
Change-Id: I9c5e8fac381345a60792cb75e2938fd53958d3b0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.
Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Mainly to get rid of the QProcess::finished deprecation warning.
Also adjust coding style in the surrounding connects when needed.
Change-Id: I12f9b248c7974b892c4a069356e578e80f8c59e9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
warning: 'virtual' is redundant since the function is already declared
'override' [modernize-use-override]
warning: 'override' is redundant since the function is already declared
'final' [modernize-use-override]
Change-Id: I9036a0dc88ed70c4f6e37b916bb24ff65074863d
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
There is no need to enclose the argument with parentheses, and there is no
need to cast to QSharedPointer.
Change-Id: Ie8f6e4228e09203d1c42f614ee8a84de4a1e110b
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Rename it into HighlightScrollBarController.
Don't derive it anymore from QScrollBar.
Make it based on QObject and decorate
the existing instance of QAbstractScrollArea as needed.
Fix the highlight of the shared scrollbar of the SideBySideDiffEditor.
Both left and right diff editors have their own
HighlightScrollBarController and their own separate overlays, but both
overlays are created as children of the same right editor instance.
Synchronize also the cursor between left and right editors.
Make highlight current line working.
Make the overlay transparent for mouse events - this fixes
issues on macOS when scolling over invisible scrollbar.
Change-Id: Iab05c360173e09d8748658c59785da86438a7189
Reviewed-by: David Schulz <david.schulz@qt.io>
* Use member init
* Use nullptr
* Use range-for
* omit QLatin1{String|Char} where possible
Change-Id: Ib231b747cdd9073b3d4fc6779b8e0afb2b404a31
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Since e.g. whitespace can have a different foreground color than
"normal" text, we have to explicitly set the color for the underline
when hovering. Use foreground color if there is no specific text color
set for "normal" text.
Change-Id: I9825d24af0d598b039a0db9ed86966605e22ac04
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
The text editor widgets all need a TextEditorActionHandler that takes
care of the editor actions for them.
Each text editor needs its own context, so the editor with focus
receives the actions. This does not happen automatically for these text
editors, since the diff editor manages these itself.
Task-number: QTCREATORBUG-9445
Change-Id: Ib42f095ec23550e401e8ee9b36f3f49517a22877
Reviewed-by: David Schulz <david.schulz@qt.io>
Display "Waiting for data" instead of "No differences" when creating new
instance of an editor for the same document (e.g. by splitting the view)
during document reload.
Change-Id: If254006de3914ad4416c7405874e8cbea57ddd8d
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Widgets which were added to a toolbar can only be shown or hidden
by calling setVisible() on their respective action, which was
created while addWidget() was called.
Change-Id: If09257abf5a7a054513fe01b2a1c69d584865dfa
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This way we can use them from libraries, not only from plugins.
Change-Id: Ic35cfd5f04d638d87606bf272b2c00ded1267c1b
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Use the same image file and recolor it as needed,
Change-Id: I914819a53ca05d83ca5b88adf44706b460b48ac0
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
Instead of describing icons via file name or in the themed icons case
via
a string that is a list of mask/color pairs, we have now a class for it.
Icons are now listed in per-plugin *icons.h headers.
RunControl::m_icon was The only place left where an icon property was in
fact a string. This patch changes that member to be a Utils::Icon.
Change-Id: Ibcfa8bb25e6d2e330c567ee7ccc0b97ead603177
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
For non-editor documents it currently is not used, but for editors it
makes more sense to have that on the document instead of the editor.
Most actual implementations of "open" were done in the documents already
anyhow, because it is needed for reloading.
Change-Id: I29d4df2078995cbe80172b51a9bebeecb3afad3c
Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
Use more QActions in the ToolBar. Those seem to work better
than the bare widgets.
Move "ignore WS" after the Context Lines spinbox so that we
can make the editor smaller while keeping the pop-up menu working.
Change-Id: I00d707c6ee1fb8d90fef5aa5ec5abb7149d4e6a0
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
* Move all data handling into DiffEditorDocument
* Move much of the logic of how to update views into the
DiffEditor.
* Introduce a base class for the different views on the diff
to implement.
* Remove DiffEditorGuiController
* Make DiffEditorController smaller and merge the DiffEditorReloader
into the class
* Simplify communication between the classes involved
* Make much of the implementation private to the plugin
Change-Id: I7ccb9df6061923bcb34cf3090d6d8331895e83c7
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
... of the diff. Currently that is side-by-side and unified, just
as before.
Change-Id: I62a5462344c4b4ae652899f9d5b2936aa5a692b8
Reviewed-by: Jarek Kobus <jaroslaw.kobus@theqtcompany.com>
Only expose Core::IDocument and keep DiffEditorDocument internal
to the DiffEditor plugin.
Change-Id: If39b82e2f20d40a65284503b4d4fd8dad919ad3a
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>