Commit Graph

73 Commits

Author SHA1 Message Date
Eike Ziller
6e7bb28f09 Tr: Add missing full stops
Change-Id: I2debc56d0740eaa30c7d597eae18910f319c1d98
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-05-26 13:50:18 +00:00
Eike Ziller
f2c1455025 Tr: Wrap file paths with ""
Change-Id: Iee0e941ff503ff485e8e9c0d9fe3e52eea9042d5
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2023-05-26 13:50:07 +00:00
Jarek Kobus
a0f6e8dc04 Utils: Rename qtcprocess.{cpp,h} -> process.{cpp,h}
Follows QtcProcess -> Process rename.

Change-Id: I97235a9a40cb7fd52944515b7ab878d96528f919
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-05-04 05:52:26 +00:00
hjk
fa7dd2fd3b VcsBase: Convert to Tr::tr
To reduce the amount of duplicated strings for translators to handle.
The problem is not very prominent in vcsbase, but that's where we
are moving everywhere else.

Change-Id: Icb11fad3bccfea8a1408420e729566a75adccb66
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2023-01-18 15:33:59 +00:00
Kai Köhne
56baf8c058 Remove GPL-3.0+ from license identifiers
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>
2023-01-06 11:15:13 +00:00
Jarek Kobus
ce161d0b16 VcsBase & dependent: Fix const correctness
And some minor cleanups.

Change-Id: Id0c2df6865ba84c054f0fb97c0ac42a76a128355
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-12-14 16:57:14 +00:00
Christian Stenger
8dd939bb27 Vcs: Do not expose passwords to the output windows
Partially reverts bbde6ac9bf and
3be9f52980.

Fixes: QTCREATORBUG-28413
Change-Id: Iccfb787a5261f3963e862554fa266d62ac49ca50
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
2022-11-11 14:28:11 +00:00
Jarek Kobus
34f9229eef VcsOutputWindow: Use toVariant() when storing FilePath
Amends 4edb238073

Change-Id: Ied6f2d9fd78a40f70393eae1c685198ab119e575
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-10-04 11:51:11 +00:00
Eike Ziller
5ae23f8c66 Merge remote-tracking branch 'origin/8.0'
Conflicts:
	.github/workflows/build_cmake.yml
	src/plugins/qmldesigner/components/connectioneditor/dynamicpropertiesmodel.cpp
	src/plugins/qmldesigner/components/materialeditor/materialeditorview.h
	src/plugins/qmldesigner/components/propertyeditor/propertyeditorqmlbackend.cpp
	src/plugins/qmldesigner/designercore/model/model.cpp

Change-Id: I111b9140375b894a5487cc012b17cc32100bdb8d
2022-09-13 11:15:16 +02:00
Jarek Kobus
fa9008c7f8 VcsOutputWindow: Don't append \n when line ends with \r
Amends a2797ec80e

Fixes: QTCREATORBUG-27615
Change-Id: I5b2d2bc442696a1560a2af3dfe14e70a9c42cc88
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-09-09 11:29:49 +00:00
Lucie Gérard
a7956df3ca Use SPDX license identifiers
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>
2022-08-26 12:27:18 +00:00
Jarek Kobus
4edb238073 VcsOutputWindow: Use FilePath for repository
Change-Id: Ie6669c94a1fa29e48524b9338e74413bb0830229
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-08-03 12:23:52 +00:00
Jarek Kobus
83739bde38 VcsCommand: Merge with VcsCommandDecorator
Change-Id: I84df1779377648624984c9e57806f1307ae62b5b
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-08-01 17:24:53 +00:00
Jarek Kobus
0da525d65c VcsBase: Cleanup some Utils:: in cpp files
We are using namespace Utils in these files.

Change-Id: I0526f7e4fff2fe0d24d1e2b9fa087298d5331955
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2022-07-13 16:01:35 +00:00
Orgad Shaneh
a2797ec80e VCS: Append newlines to system messages in output pane
Change-Id: I3ca2d2e90ea0a97dd75feb7d1f8220564a138fb5
Reviewed-by: hjk <hjk@qt.io>
2022-05-19 06:15:44 +00:00
Alessandro Portale
1464238eb5 VcsBase: Apply text editor's font settings to the output pane
Some of Git's output is formatted in a way that benefits from a
monospace font. Therefore, it would be useful to be able to set such a
font.

This change syncs the font of the Version Control output pane with the
text editor font. This is also the standard with other output panes.

Fixes: QTCREATORBUG-27164
Change-Id: Id579f18aef741d18f7434ecef35081ffc155ef1c
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2022-04-04 08:50:04 +00:00
Eike Ziller
195abefe7d EditorManager: Remove QString openEditor(At) overloads
In favor of the FilePath/Link ones.

Change-Id: I5caf9e0f8de304ff4ee12329557aa50a6f3a0c69
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: David Schulz <david.schulz@qt.io>
2021-11-02 08:11:14 +00:00
Eike Ziller
29df497d25 Add text search functionality to output window centrally
All output windows should be searchable with Edit > Find/Replace
(Ctrl+F), no reason for every single instance setting that up
individually.

Add a find placeholder for the build system output in Projects mode, so
the search functionality is available there as well.

Change-Id: Idad6824bfb21e6ae9ab923191a7e83b43256e68b
Reviewed-by: Cristian Adam <cristian.adam@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
2021-09-20 13:58:45 +00:00
Christian Kandeler
3be9f52980 Fix some warnings
Unused functions & variables, initialization order, signedness, non-
virtual destructor.

Change-Id: I405d768fe0e02a36a16c2cead9e1bc2f6a23fb75
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-02 13:47:07 +00:00
hjk
bbde6ac9bf VCS: Use more FilePath in ShellCommand and surroundings
Change-Id: Ie8c5fac09b45a54bcbe9a876044b653e7fccede5
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2021-08-17 07:16:04 +00:00
hjk
ff57cb548d Vcs: Use more FilePath for file paths
Change-Id: I855cde65d034a9647972a7fddf1e8266d7ccfa88
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2021-08-02 14:40:33 +00:00
hjk
f2f40efa03 Utils: Move process arguments class out of QtcProcess
The main QtcProcess interface is nowadays a CommandLine, with no
explicit references left to QtcProcess::Arguments and related static
helper functions, so it only clutters the QtcProcess class interface

So move these items out of QtcProcess, later potentially to a separate
file pair.

Change-Id: I45c300b656f5b30e2e2717232c855fdd97c2d1d7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-05-11 09:45:24 +00:00
Jarek Kobus
d2e1feceac Don't clash signal names with other methods
In case when signal name clashes with other method name -
rename accordingly.
Remove some repeated signal declarations - they are already
declared in superclass.

Change-Id: Ie1430b85d6436d26996494fa44c7554fb354b6ce
Reviewed-by: hjk <hjk@qt.io>
2020-11-18 12:20:43 +00:00
Orgad Shaneh
7e4364fb70 VCS: Do not focus on the pane every time it becomes visible
Fixes: QTCREATORBUG-24425
Change-Id: I727913eeeae34e6d656bfc5b17a737c5bcbffe88
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-10-09 05:23:28 +00:00
Orgad Shaneh
92a4c0d38a VCS: Pass links to the correct VCS
Current implementation requires each VCS to connect to the referenceClicked
signal. Only Git does it, but this is conceptually wrong. If other VCSs
would connect to the same signal, all of them will act upon clicking a
link, which can result in multiple editors, most of them are likely to be
invalid anyway.

By default executes vcsDescribe. Can be extended or modified by subclasses.

Change-Id: Ib953009efd77446a4b2963f0aa8a2f3f3d26509f
Reviewed-by: Artur Shepilko <artur.shepilko@nomadbyte.com>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-06-21 06:47:20 +00:00
Andre Hartmann
9c71e41ad1 VcsOutputWindow: Modernize password obfuscation
Use QRegularExpression and the QString::replace()
function with capturing groups to replace the
existing loop.

Change-Id: Ia9c0587dcdae40cff2b09379ac3ba84db4d30ce8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-05-16 19:09:43 +00:00
Andre Hartmann
c2c5731d50 VcsOutputWindow: Fix creating links from command output
After the refactoring of the output parsers in
1c6e4fbd32, NormalMessageFormat and
ErrorMessageFormat are no longer parsed.

To allow parsing and therefore generating links,
the command output has to be declared as stdout
or stderr, depending on the severity.

Our own log and command messages are now
(in contrast to Creator 4.12) no longer parsed for
commit hashes and links, but this is acceptable.
Parsing the command output is often more interesting.

Change-Id: I7e7a96f4ff98edd88f5d9b8abddf94363768c0a6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2020-05-15 12:05:05 +00:00
Christian Kandeler
98ce70480a Vcs: Fix output pane
Amends c0c2df203d.

Change-Id: I77d022f2b3a4d3cab4713d9cbd2bc66102ee58a3
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-04-17 14:52:12 +00:00
Christian Kandeler
d42920d372 OutputFormatter: Take ownership of the line parsers
For symmetry with IOutputParser.

Task-number: QTCREATORBUG-22665
Change-Id: I92e93b32e87ff4f3fa163a2d2fe13768e56bfa24
Reviewed-by: hjk <hjk@qt.io>
2020-04-15 09:07:17 +00:00
Christian Kandeler
c0c2df203d Utils: Split up OutputFormatter class
An OutputFormatter takes some string and prints it into a text edit.
In addition, it can ask any number of registered OutputLineParsers
whether they think any special formatting should be applied to the
current line.
This mechanism is now properly modeled by our class design, rather than
being hidden in a monolithic class where everything had the same type,
no matter what its purpose was.
Prospective contributors can now simply be pointed to the
OutputLineParser class and will see at one glance what they have to do.

Change-Id: I9844499f062c94fb038ce73fd6f26576910148c2
Reviewed-by: hjk <hjk@qt.io>
2020-04-14 14:15:26 +00:00
Christian Kandeler
04a99c1de1 Remove the limitation that output formatters have to be exclusive
Introduce an aggregating output formatter that forwards its input to a
sub-formatter that feels responsible for it, or otherwise lets the base
class handle it.
Our output panes now use such an aggregating formatter.
In particular, this means that in the future, we won't have to stuff all
run control output formatting into the Qt output formatter anymore.

Change-Id: I5498f200a61db10ccff3ec8974c6825da7f7072d
Reviewed-by: hjk <hjk@qt.io>
2020-03-20 13:48:15 +00:00
Christian Kandeler
0ff5bf75e1 Move some code from OutputWindow to OutputFormatter
That's where it belongs: The logic there is applicable to all output
formatters, not just those used via an output window.

Change-Id: Idf4ca8d22631ca96feb97553f28724c0275e0bf8
Reviewed-by: hjk <hjk@qt.io>
2020-03-17 09:39:12 +00:00
Orgad Shaneh
ba87fb2083 Git: Add actions for changes in output window context menu
Change-Id: I5aa46f87b82670286ac225d71a3a045133976e86
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2020-02-28 09:53:51 +00:00
Andre Hartmann
4cbb24906f Git: Allow clicking references in VcsOutputWindow
Fixes: QTCREATORBUG-16477
Change-Id: If1f36bec0826a3116e5261a270cd63a1536e13f5
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-02-16 19:13:53 +00:00
Miklos Marton
8f88b89d81 Make http(s) urls clickable in the VCS output pane
Fixes: QTCREATORBUG-23536
Fixes: QTCREATORBUG-19171
Change-Id: Ibf6d632031068c7f52cb15f534960e8238bdb21d
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2020-02-05 22:02:39 +00:00
Eike Ziller
10098b2508 Merge remote-tracking branch 'origin/4.10'
Conflicts:
	CMakeLists.txt
	tests/unit/unittest/unittest.pro

Change-Id: I64296ad31502d9b35012da129a28e9277e9fcf8e
2019-06-28 12:50:03 +02:00
Orgad Shaneh
81ee28fc98 VCS: Add seconds to timestamp in output window
Useful when there are multiple commands at the same minute.

Change-Id: Ie5c344fe3d19e54e5b2fce1a5b3dc0cfdeb267e2
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2019-06-26 14:25:19 +00:00
Orgad Shaneh
d97e677be4 VCS: Do not use monospace font in output window
Change-Id: Id022a55152880a999c6c6c81ca88f70abfa88b8b
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2019-06-25 13:24:04 +00:00
Christian Kandeler
41ade463da Output panes: Support keyboard shortcuts for zooming
Fixes: QTCREATORBUG-22567
Change-Id: I3c7419c7b464c329d8f8dae11db9a0b01e51f32c
Reviewed-by: André Hartmann <aha_1980@gmx.de>
2019-06-24 14:14:07 +00:00
hjk
00b692e67e Utils: Use CommandLine in ShellCommand
... and adapt users.

Change-Id: I218523ffe34720d5fe199aa0ca6892a8dc2985fc
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-06-11 11:01:16 +00:00
hjk
473a741c9f Utils: Rename FileName to FilePath
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>
2019-05-28 12:23:26 +00:00
Alessandro Portale
c453e896a0 Core: Fix enabling/disabling of zoomIn/Out buttons in output panes
Amends 48073b2990 to avoid the creation of extra toplevel windows (and
warnings on MS Windows on startup).

Also, ensure that that the initial tab-less application output pane
shows the buttons, albeit in disabled state. All other output panes do
not have to explicitly enable them.

Change-Id: I6c6ef374c09c77e2eb953743071917d9346ca85d
Reviewed-by: hjk <hjk@qt.io>
2019-04-23 16:39:24 +00:00
Andre Hartmann
b2700d2da4 VCS: Add font settings and zoom to output pane
Change-Id: I2848bce2a851d9db953d1c218f1694877874e7df
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-04-16 14:20:41 +00:00
Andre Hartmann
48073b2990 IOutputPane: Refactor zoom function into base class
Try to make zoom and font handling in the panes more
similar and put common stuff into IOutputPane.

Change-Id: I59c38c5eecbf67b7ca6c9d84a6f61b1292a787df
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2019-04-16 14:20:22 +00:00
Eike Ziller
b5e7522237 Merge remote-tracking branch 'origin/4.9'
Conflicts:
	qbs/modules/qtc/qtc.qbs
	qtcreator.pri
	src/plugins/pythoneditor/pythoneditorplugin.cpp

Change-Id: I9a95df5e16b34538539ced7dfc5d326b700794e6
2019-04-02 12:22:48 +02:00
Andre Hartmann
335d277731 VCS: Make commands in output window bold again
Most likely broken by 639017783a

While at it, also fix the comment that exactly
states this format.

Change-Id: I8f1ad5a4009ca0cb0d9828bca63e8edf8b6cd5a8
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-03-30 17:40:40 +00:00
Andre Hartmann
ea8a1c85c1 VcsOutputWindow: Cleanup and modernize
Change-Id: I3239fb232207fb661bbcdf460ee01fb297720353
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
2019-03-10 18:52:25 +00:00
Alessandro Portale
710e57a628 Fix warning: "Use midRef() instead of mid()"
[-Wclazy-qstring-ref]

Change-Id: If8a0844b39377feb3772542559655854a92b93cd
Reviewed-by: hjk <hjk@qt.io>
2019-01-17 13:00:37 +00:00
Orgad Shaneh
5873612767 VCS: Unbold messages and errors in output pane
Change-Id: Id154d75c07cf95b9ceaad3ee26fcac08e66b3200
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2018-11-24 16:01:55 +00:00
Orgad Shaneh
5170dd0858 Merge remote-tracking branch 'origin/4.8'
Change-Id: Ia8bf92c8effdee0e1085730cb975ff88c8ad85fc
2018-11-20 19:13:13 +02:00