Commit Graph

15 Commits

Author SHA1 Message Date
Jarek Kobus
11a8c55f38 Various plugins: Remove unused variables
Change-Id: Ie2e5eb38d81a7582c5715654f09f28deb4ab11c5
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2024-01-29 07:44:39 +00:00
Christian Kandeler
048f77b961 CppEditor: Let users specify a preferred doxygen command prefix
Fixes: QTCREATORBUG-8096
Change-Id: I08bf4e3e0092fc775b50be6e5f4cefb9ed6979a5
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-08-09 08:42:15 +00:00
Christian Kandeler
45f4ea6da5 CppEditor: Pass CommentsSettings into DoxygenGenerator
... instead of forwarding each member separately.

Change-Id: I0639cc81716df70e8f286cb4b5f02554e1f56b95
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-08-08 11:58:35 +00:00
Christian Kandeler
68c76e072d CppEditor: De-obfuscate DoxygenGenerator
- m_startComment was always false.
- One of the two public generate() functions is an internal helper.

Change-Id: I03a860bf7f44aab8f98c5656bc2b36f9fe5e1ef2
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-08-08 10:50:38 +00:00
Christian Kandeler
98b341b7cc CppEditor: Do not assume an opening brace starts a block
... when generating doxygen comments.
Otherwise, we will not properly parse declarations such as
    void f(int i = {});
or
    int m_member{};

Fixes: QTCREATORBUG-29198
Change-Id: I744041d2cd5438e4b64161bba04a088a8910024b
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
2023-06-23 09:54:07 +00:00
David Schulz
266202b6b4 CppEditor: reduce complexity of getting previous line
for a given text cursor.

Change-Id: I43591b529e9d04b3ef013db3b9b30cf37773c115
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2023-05-10 04:34:36 +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
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
hjk
e2bb204d4d CPlusPlus: Inline more simple Type related functions
Change-Id: I2103e8047b385b438e58072e8a2689f1889d2724
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-28 11:02:22 +00:00
hjk
ffa3aad576 CPlusPlus: Inline some simple central functions
Depending on context, callgrind sees contributions of >8% to
the total cost of project parsing for these functions. The
functional are actualy executed executed out-of-line, often
for a function body of one "payload" instruction only.

Inlining removes the call/endbr64/ret overhead.

Change-Id: I6886f08e322fcaa4e0f54d424279e0a8c24e4718
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
2022-06-24 11:49:41 +00:00
Artem Sokolovskii
2be4e8c5d5 CppEditor: Remove foreach / Q_FOREACH usage part 3
Task-number: QTCREATORBUG-27464
Change-Id: Icbe620a83b6c2cf6b6166b76d01ca5f3c65ea87a
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2022-05-12 07:42:02 +00:00
Christian Kandeler
137d3367cf CppEditor: Do not crash on doxygen comment creation
... for templates that were not parsed entirely successfully.
Amends a437539096.

Fixes: QTCREATORBUG-27207
Change-Id: I4d7935b30cac9ce14f442977d07417a343ecae11
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2022-03-22 11:01:18 +00:00
Christian Kandeler
a437539096 CppEditor: Fix doxygen comment magic before templates
Fixes: QTCREATORBUG-9620
Change-Id: I65a434d72adbe72d449783a917444c2ee216fc5e
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-10-28 10:05:43 +00:00
Christian Kandeler
72d52f3ac2 CppEditor: Un-export some classes
Change-Id: I285fe7bd3ac835c4a43f0a200dd7905f577ff211
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-06 14:48:17 +00:00
Christian Kandeler
284817fae6 Merge CppTools into CppEditor
There was no proper separation of responsibilities between these
plugins. In particular, CppTools had lots of editor-related
functionality, so it's not clear why it was separated out in the first
place.
In fact, for a lot of code, it seemed quite arbitrary where it was put
(just one example: switchHeaderSource() was in CppTools, wheras
switchDeclarationDefinition() was in CppEditor).
Merging the plugins will enable us to get rid of various convoluted
pseudo-abstractions that were only introduced to keep up the artificial
separation.

Change-Id: Iafc3bce625b4794f6d4aa03df6cddc7f2d26716a
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2021-09-01 14:53:58 +00:00