Commit Graph

8 Commits

Author SHA1 Message Date
Eike Ziller
e71d7bf454 Merge remote-tracking branch 'origin/10.0' into 11.0
Change-Id: I110bc26f4469093d262a77c27623ad1dddd1b7c1
2023-05-30 10:52:47 +02:00
Christian Kandeler
2cd71a18fc CppEditor: Fix raw string highlighting with embedded empty lines
We missed an early return in highlightBlock().

Task-number: QTCREATORBUG-29200
Change-Id: I3f32c2948ff778a9b558850235058537fcd48fd1
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-05-25 13:43:26 +00:00
Christian Kandeler
b795b42980 CppEditor: More special rendering for string literals
Display prefixes and suffixes different from the actual string, like we
already did for raw string literals.
This uncovered some minor bugs in both lexer and highlighter:
  - Wrong length for a setFormat() call in highlightRawStringLiteral()
  - Missing check for user-defined literal in raw string literals
  - Missing check for user-defined literal in multi-line strings

Fixes: QTCREATORBUG-28869
Change-Id: I018717c50ddc1d09c609556161c85dfb0cc29fab
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-04-13 11:36:12 +00:00
Christian Kandeler
dd4235eb35 CppEditor: Verify proper highlighting of the concept keyword
Change-Id: I1c814da472f10539f87640a52822b188b9b7a2cd
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-03-14 14:09:21 +00:00
Christian Kandeler
d7308cc7a6 ClangCodeModel: Ignore built-in types
... in the semantic highlighter. The syntax highlighter already handles
these.

Change-Id: Ib1e80ec194021dbd2b4eca7a300db869ccddb7b0
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-02-03 10:59:41 +00:00
Christian Kandeler
7c6a00b4e7 ClangCodeModel: Ignore number literals
... in the semantic highlighter. The syntax highlighter already handles
these.

Change-Id: I26f6bca06c4fc648ffe59bd9e3639d81d2265755
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-02-03 09:33:55 +00:00
Christian Kandeler
c31522731c ClangCodeModel: Ignore boolean and pointer literals
... when doing semantic highlighting. The syntax highlighter already
handles these.

Change-Id: I048e033eda5b72d2e6eafaaccdb66040a00afe6a
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-02-02 13:36:16 +00:00
Christian Kandeler
209e3d0e66 CppEditor: Fully handle raw string literals in the syntax highlighter
As of a3af941adf, the built-in highlighter
can properly handle multi-line raw string literals, so we don't need to
abuse the semantic highlighter for this anymore.

Fixes: QTCREATORBUG-26693
Fixes: QTCREATORBUG-28284
Change-Id: If644767dfa8a97294e84a541eea44143e8d1bb88
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
2023-02-02 09:52:55 +00:00