Commit Graph

249 Commits

Author SHA1 Message Date
Alessandro Portale
a0e37a76fa Plugins: Add URLs to manual page to plugin metadata
Fixes: QTCREATORBUG-31199
Change-Id: Ideadc75499f32a8f1d1c95cd38dc4669a3d422c3
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-07-29 07:27:29 +00:00
Marcus Tillmanns
cba0f779a9 Terminal: Add error checking
Change-Id: I28395f50f03b853468a229416d5942fc591f9957
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-07-10 05:51:57 +00:00
hjk
2c40765e86 Core: Add a static IContext::attach() function
... to simplify the user code.

Some, but not all, potential beneficiaries are adapted.

Change-Id: Ia7d514a0114a4f99f8ee745523435f5b990bd095
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-07-04 10:09:53 +00:00
Eike Ziller
0283b81392 Merge remote-tracking branch 'origin/14.0'
Conflicts:
	cmake/QtCreatorIDEBranding.cmake
	qbs/modules/qtc/qtc.qbs

Change-Id: If39fe80197537c489361810e91ee221c6c52ea01
2024-07-01 12:01:27 +02:00
Eike Ziller
38e005692e Plugin meta data: Add full stop to descriptions
Where they were missing. The text is shown as a paragraph in the
extension manager.

Change-Id: I6e15c89fe4023b222e9c476f4312e13fcb0905c0
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2024-06-28 06:46:52 +00:00
Marcus Tillmanns
454c505184 Terminal: Remove object registration
Its unnecessary to register the object in the plugin system.

Change-Id: I0a356b9a040879503e38090939008277e4eea4f0
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-06-25 11:31:44 +00:00
Leena Miettinen
6cd7aed8eb Add long descriptions to some plugins
Edited the short descriptions to answer the question
"What can I do with this extension" to help users decide
whether they need it.

In long descriptions, tell users what else they need to
be able to use the plugin.

Change-Id: Iefce7505b61fc77cf38cc915f1f7dbd25c9cb570
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-05-31 06:42:53 +00:00
hjk
efae651924 Utils: Introduce a convenience function creatorColor()
... forwarding to creatorTheme()->color(...)

Change-Id: Iefaa043495127b3e500ed225584481d3ec0f8c1f
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2024-05-29 13:49:25 +00:00
Alessandro Portale
7bc65cf9f3 PluginSpecs: Change URLs from http:// to https://
Avoid the redirect that is inevitable nowerdays.

Also, change necessitas.kde.org to www.qt.io, since the orgininal page
is offline.

Change-Id: Ib1823f0df97d2df87822fd2bb7552e2f2c7e971e
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
2024-05-28 20:13:29 +00:00
Jarek Kobus
982ad24243 CommandLine: Reuse new c'tor
Change-Id: Id154881b4f5d8c488e5c1f5e0f843d36bf838759
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-05-22 09:13:41 +00:00
Jarek Kobus
53de9701f4 CommandLine: Use more 1-arg c'tor
Change-Id: If52c4094f94859d51e31862d913b1756e333e512
Reviewed-by: hjk <hjk@qt.io>
2024-05-16 12:45:42 +00:00
Eike Ziller
0f4efacb91 Merge remote-tracking branch 'origin/13.0'
Conflicts:
	doc/qtcreator/src/overview/creator-only/creator-reference.qdoc
	doc/qtcreator/src/qtcreator-toc.qdoc

Change-Id: Ibea5488fda972321c448c64fad7f657e84d62cdb
2024-04-30 14:23:09 +02:00
Marcus Tillmanns
8b682ac7f5 Terminal: Fix TERM env variable
Some (Fedora) OS/Distros set a default value for TERM such as "dumb", which then breaks
command line tools such as "clear" which try to figure out what terminal they are
running in. Therefore we have to force-set our own TERM value.

Fixes: QTCREATORBUG-30737
Change-Id: I50ac86f17c92dc7bc477cc59ed43ec22025593fb
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2024-04-30 07:11:01 +00:00
Eike Ziller
7f8adab0d0 Translations: Fix various \n, full stops, spaces
Add missing full stops, remove space at beginning and end, remove end
lines at end

Change-Id: I4ce28f578e13e100dcfbd8ef70630462faf407fc
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2024-04-18 06:06:45 +00:00
Eike Ziller
90e1d96019 Merge remote-tracking branch 'origin/13.0'
Conflicts:
	cmake/QtCreatorIDEBranding.cmake
	doc/qtcreator/src/overview/creator-only/creator-keyboard-shortcuts.qdoc
	qbs/modules/qtc/qtc.qbs
	src/plugins/remotelinux/linuxdevicetester.cpp

Change-Id: I8434e41dcfbb50f6ed032a3e0af1591eb19b79eb
2024-03-20 15:05:58 +01:00
Marcus Tillmanns
3d8d85b5b9 Terminal: Ignore "height = 0" resize events
ConPTY on windows will send "clear line" characters in response
to resizing the PTY.

During re-showing the terminal pane the widget receives a "height=0"
resize event. We have to ignore this otherwise the conpty might try to
clear the screen.

Another issue was that we are calling resize on the pty even thought the
process has ended and won't be able to respond to the clear attempty by
the pty anymore.

Fixes: QTCREATORBUG-30523
Change-Id: I24caeaffb31d255a0640952e2d35bda23fd16280
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-03-18 10:03:02 +00:00
Eike Ziller
c19f97bd23 Merge remote-tracking branch 'origin/13.0'
Conflicts:
	src/plugins/cmakeprojectmanager/cmaketool.cpp
	src/plugins/python/pythonutils.cpp
	src/plugins/qtsupport/baseqtversion.cpp

Change-Id: Ia3e35c763ff9475d17ad922718b54152209893b8
2024-03-14 11:35:07 +01:00
Marcus Tillmanns
da3bc4e86e Terminal: Rename "Close" action
Fixes: QTCREATORBUG-30520
Change-Id: I0fc2eaba533e6260763c0c02657cf3a7de7c9dce
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-03-12 08:34:50 +00:00
Marcus Tillmanns
726b023c78 Terminal: Remove Close action
A remnant of a wrong refactoring.

Fixes: QTCREATORBUG-30519
Change-Id: I2fadb353b83762d4d821444a58f7631dcfd22b0d
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2024-03-12 08:33:48 +00:00
Eike Ziller
5af531cd39 Utils: Fix build with MSVC with C++20
Rename process.h back to qtcprocess.h

MSVC's "threads" standard header includes <process.h>, and that ends up
including our process.h from Utils.

There already was a hacky workaround in place for a similar issue with
MINGW, but that doesn't work with MSVC because that doesn't have

Simply use a name that doesn't conflict.

Change-Id: I1159cd2096b4f2dbc4a1728d0131dd6edd30ebd3
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
2024-02-28 08:09:05 +00:00
Marcus Tillmanns
8313190ee9 Terminal: Fix nullopt access
Change-Id: I758dadc481b3ebe6b7274ab0dde52ec5f2d7dfa3
Reviewed-by: hjk <hjk@qt.io>
2024-02-13 08:21:54 +00:00
Marcus Tillmanns
e073c54d01 Terminal: Fix opening terminals on remote devices
When the active project is on a remote device the working directory
is set to its root directory. In this case we need to find the right shell
binary from the remote device.

Change-Id: I6b541273d23a8de5442ac041b28d81984ed5ef65
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-02-09 07:40:59 +00:00
Cristian Adam
426dbc2f94 Terminal: Escape spaces for powershell paths
For the users that have a space in their user name, the location of the
shellintegration.ps1 is a path with a space in it.

This patchset fixes the escaping of that space.

Change-Id: Iae84b2e8a8f1b4e2b7e523e28417caaeb77bc5cd
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2024-02-07 08:24:40 +00:00
Marcus Tillmanns
3ec09a1c3d Terminal: Fix powershell integration
Previously a "1" was printed every time a powershell terminal
was started.

Change-Id: Ibd6f9dc9de8ba11ede98e13ca2f65ba5a99536fb
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-02-07 08:05:11 +00:00
Marcus Tillmanns
3259b1cb25 Terminal: Fix Cwd escaping
The shellintegration script escape the current working dir.
We were missing the code to unescape the paths.

This was particularly visible on Windows powershell
where backslash was escaped by "\x5c".

Change-Id: If697722986c72ebbc19d5ec8e3930321f3af7b6a
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-02-07 08:05:04 +00:00
Jarek Kobus
656a30b407 IDevice: Replace QSharedPointer with std::shared_ptr
According to https://wiki.qt.io/Things_To_Look_Out_For_In_Reviews
QSharedPointer impl is poor and it's going to be removed from Qt 7.

Replace QWeakPointer with std::weak_ptr.
Replace QEnableSharedFromThis with std::enable_shared_from_this.
Use std::static_pointer_cast and std::dynamic_pointer_cast
for casts used with QSharedPointer before.

Change-Id: If255a100c790860934f36d52906b93f33c31cfe8
Reviewed-by: hjk <hjk@qt.io>
2024-02-02 16:45:57 +00:00
Marcus Tillmanns
a25bbf23c6 Utils: Fix error prone default value of appendOrSet
It was not readily clear that Environment::appendOrSet/prependOrSet
needed a value for "sep", otherwise it would just concat the values without separator. This got apparent when looking at usages of
appendOrSet.

Instead there are now three options, "Auto", "Colon" or "Semicolon"
with the default being "Auto", which determines the separator based on
the Environment::OsType.

Usages of appendOrSet and prependOrSet are also fixed with this commit.

Change-Id: I868e14ce38f50be9cd07292fe3f22663a62d116d
Reviewed-by: hjk <hjk@qt.io>
2024-01-26 10:10:03 +00:00
Marcus Tillmanns
56f42c319e Terminal: Fix env separator
Change-Id: I738ff27d37df95170bbdc9f55fbaf6430ebb5a40
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-26 09:36:33 +00:00
Marcus Tillmanns
273656c927 Terminal: Fix fish shell integration
Change-Id: Ib9156be851d092db2a28641a292ae32e76314bec
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2024-01-25 12:15:27 +00:00
Marcus Tillmanns
87999abead Terminal: Linkify git commits
Allows the user to Ctrl(Cmd)+Click "version like" text (e.g. text that
only contains 0-9 and a-f) and starts a "vcsDescribe" if a version control
can be found for the current directory.

Fixes: QTCREATORBUG-29213
Change-Id: I462092b58bf595a6968f4765f83a207506f0cf87
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-25 05:43:17 +00:00
hjk
58396a5da1 Terminal: Use new ActionBuilder syntax
Change-Id: I1d739ca80f41073a55755816468c47f743838f81
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2024-01-08 14:19:10 +00:00
Marcus Tillmanns
a3b9393bc5 Terminal: Do not unlock the locator
Ctrl+K is a useful shortcut for some users, so we have to block the locator if the keyboard is locked.

Fixes: QTCREATORBUG-30032
Change-Id: I211e0bc449d3981513cc77bd14baf70a9acc3ae1
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-08 08:25:07 +00:00
Marcus Tillmanns
3795a94144 Terminal: Block Close Terminal
Fixes: QTCREATORBUG-30070
Change-Id: Id775bea9f3db851f07f6e86aedb02f975b5a7ee4
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2024-01-08 08:24:53 +00:00
Eike Ziller
2ce9f9d97d Move most acknowledgments to qt_attributions.json
Create a qt_attributions.json and generate a documentation file from it
automatically when building documentation. The result is included as a
table in the acknowledgments page in the documentation.

Some attributions cannot (yet) move to qt_attributions.json, because
that requires the sources to be available in the project's source tree,
which is not the case for LLVM, Clazy, etc.

Remove the attributions from the README and instead point to the
documentation from there, so we get rid of that duplication.

Change-Id: I22623fe7495593ffce2e2c6c26255c27c5a8cb71
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-12-15 09:02:23 +00:00
David Schulz
e743da1cbf Terminal: do not block Qt Creator shortcuts by default
Change-Id: I8709f89912d05242d4841518dd3a4544c63ee160
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-12-14 14:34:11 +00:00
hjk
b442ca3873 Core: Rename ActionBuilder::setOn* to addOn*
There could be multiple connections.

Change-Id: I7dbca9d24599f776b7d1f1bfa11826e3eeb5640a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-12-13 13:00:00 +00:00
hjk
5e2bc6f398 Terminal: Restrict shortcuts
Amends a0c05cabcc. Specifically Ctrl+Shift+T conflicts with
opening the type hiearchy pane when in a C++-editor.

Change-Id: Id4da738162ad9c90d6b45c4142a207ea22511d18
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-12-13 08:27:49 +00:00
Marcus Tillmanns
5f3950c620 Terminal: Defer shell model init
Speculative fix for sometimes slow load times of the Terminal
plugin on Windows

Task-number: QTCREATORBUG-29840
Change-Id: I6782db075bfaa25fbabe2bac2a8f0f3b4af4f833
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-12-12 12:05:25 +00:00
hjk
016936a450 Clean up some lambdas
Change-Id: Id947c0935b1aa4579e1c64d3e510db41103fbe27
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2023-12-12 10:55:32 +00:00
Jarek Kobus
8d2cee31e4 TerminalWidget: Fix a warning about no return value
Amends a0c05cabcc

Change-Id: Ieb969f7a6c61469f69e8503089e4985fa8380e3c
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-12-12 09:34:12 +00:00
Marcus Tillmanns
a0c05cabcc Terminal: Refactor actions
Change actions to use ActionBuilder and
use ToggleAspects for tool buttons.

Change-Id: I0f4a58c3a98cb2804e3d387ea02cac043bd71ae7
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-12-12 05:46:33 +00:00
Marcus Tillmanns
2da12ddc60 Terminal: Add select all action
Fixes: QTCREATORBUG-29922
Change-Id: I565f2f9f570610e1bb7f528cd874a0dd9c47dbe8
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-11-27 11:32:01 +00:00
Eike Ziller
f0f4780ec0 Merge remote-tracking branch 'origin/12.0'
Change-Id: I22e6a20e5a6fc84f777b6cffbd9fb484c90bc51d
2023-11-16 08:45:30 +01:00
Marcus Tillmanns
7819fc5dfb Terminal: Only unlock exit on macOS
Fixes: QTCREATORBUG-29902
Change-Id: Ifbb1f12c874f2f68483a34ac6e117214211e5be4
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2023-11-15 14:13:48 +00:00
Eike Ziller
056168beca Merge remote-tracking branch 'gerrit/12.0'
Conflicts:
	src/plugins/texteditor/texteditor.cpp

Change-Id: I76620975760a8f9e64f6d381c948d457e949a87c
2023-11-15 10:32:59 +01:00
Xavier BESSON
223deb5968 Shortcut to enable/disable shortcuts routing to terminal
Fixes: QTCREATORBUG-29876
Change-Id: I8b04c09ce1de7dab968499773179f663c1c6fe7d
Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
2023-11-13 13:41:04 +00:00
Eike Ziller
4bd29f741c Merge remote-tracking branch 'origin/12.0'
Change-Id: I517dc84e975a570edd363253ad444a01799dbc4b
2023-11-06 10:51:11 +01:00
Marcus Tillmanns
201857fa68 Terminal: Fix Url handling
FilePath::toUrl does not pass queries correctly to QUrl.
So we use QUrl::fromUserInput directly.

Fixes: QTCREATORBUG-29850
Change-Id: If0706b3b37d03eeea87247b44f07f8a0f8915a95
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
2023-11-06 08:22:02 +00:00
Eike Ziller
a724bd40f5 Merge remote-tracking branch 'origin/12.0'
Change-Id: I17c37a6fd474c3441343e91a67817c8179d0c7cc
2023-10-30 13:20:46 +01:00
Marcus Tillmanns
a3853ecc44 Terminal: Q_ASSERT workaround
Change-Id: I7e1bf06db437b523e8b06695c3b12f2562a73ce8
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-10-27 10:13:02 +00:00