The scriptable info is saved to the action registered for a specific context
so we need to add this info to the action builder in the text editor that has the correct context.
Also remove all action builder constructs for the global context that have been registered before
in order to silence the add override action warning.
Change-Id: I631d71ba5eb8e975190713b33827926e868da295
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Give each editor a context and register editor actions individually for
that context. This removes the need to tell the action handler the
current editor. Additionally all actions are now available in editor
widgets outside of the EditorManager.
Change-Id: I0109866b180889762f8bd8aa07874d8d7c55bfa6
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
We want to support more than one back-end in the future.
Task-number: QTCREATORBUG-28116
Change-Id: I72020c94b36072a297e13f44130e5e2482922cd4
Reviewed-by: David Schulz <david.schulz@qt.io>
The FindInFiles definition cannot go yet to the .cpp yet as there
are some exported functions.
Change-Id: I2d2f02ae80b560e3147f461fcbee0fa62b8085a3
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Since the plugin class is in the .cpp now pimpling is not really
useful, this goes a step into the direction of removing it.
Change-Id: Ia55d60749372d868a94884337f0e0f52ec2cc1b5
Reviewed-by: David Schulz <david.schulz@qt.io>
Since the book mark support is nowadays part of the text editor plugin
we can directly access the bookmark manager from within the editor
without the indirection over the TextEditorPluginPrivate.
Change-Id: I5c04679d6583c06d615d489d3891431adcb64834
Reviewed-by: hjk <hjk@qt.io>
This is similar to the recently promoted setupXXX() pattern, not
100% there, though.
Change-Id: Ia6b302af5c8b647ed073ec45179eb2413e988885
Reviewed-by: David Schulz <david.schulz@qt.io>
This is quite special due to the extra signal, but at least that's
hidden in the implementation now.
Change-Id: Id1130669fd1fdfb631d89460cfb884fb53858eec
Reviewed-by: David Schulz <david.schulz@qt.io>
- Created HighlighterHelper namespace and static functions
were moved there from the highlighter class
Change-Id: Ib93785a3819317d7c1d5cc480652d4635cb9339b
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This needs not be stored somewhere but does its work latest
at destruction automatically.
Change-Id: If929f5a5ccc15b085f110d8d9db8f72ff2a5fac5
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Idea is to have a bit more "object { propertySetter }" kind of pattern
for common cases and to couple actions and menus only via Ids, not
real objects.
In a LayoutBuilder context this might later look like
Menu {
id(BOOKMARKS_MENU),
title(Tr::tr("&Bookmarks")),
container(Core::Constants::M_TOOLS)
}
in the end.
Overall line count increases but I claim it reduces complexity on the
user code side.
Change-Id: I166e0c8c6b3036430dc464fd652fb37ded21c09a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Fixes missing "Line in Current Document" locator filter.
Locator filters need to be created during startup.
This reverts commit 8af6d16b6c.
Change-Id: I53ec1c1079b4a719169e8db95b6d77f703264b65
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
One of the two non-standard items exposed in the TextEditorPlugin class
interface.
Change-Id: I89755c6a2b168f31b69d3904d6d043273b462ea6
Reviewed-by: David Schulz <david.schulz@qt.io>
Use an EditorFactory that sets up a custom indenter for json files.
Change-Id: Id5ade9f9f551835131a62e381a972f0b6032e7c0
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
These settings can clearly differ per project.
Note that the classes have to live in the ProjectExplorer plugin, which
has a (questionable) dependency on TextEditor.
Change-Id: I7e3816da30cecd1ccb66549a2226b44dc0a26cb4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...
While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only
Change was done by running
find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;
Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
To display the parent function, first we find it in displayResults and
store the information to SearchResultItem, then
SearchResultTreeItemDelegate gets the information and renders it.
Similar approach is applied to ClangdClient, in addSearchResultsForFile.
This change also adds default style for containing function highlight in
the search.
Default foreground and background colors are same as usual text colors.
Task-number: QTCREATORBUG-27550
Change-Id: Id1251afa192f8d1232524742b7c211770bcb83fb
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
So it can be accessed from a wider range of places.
Change-Id: I282883addecf7bb070a65d9f4f7b8e6e2e4b5e47
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: David Schulz <david.schulz@qt.io>