WSL/SLF GitLab Repository
Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
snow-models
inishell
Commits
fe5591d4
Commit
fe5591d4
authored
Mar 11, 2022
by
Mathias Bavay
Browse files
More warnings fixes
parent
e3a358ef
Changes
1
Show whitespace changes
Inline
Side-by-side
src/main/SyntaxHighlighter.cc
View file @
fe5591d4
...
...
@@ -130,8 +130,8 @@ void INISyntaxHighlighter::highlightBlock(const QString &text)
for
(
const
HighlightingRule
&
rule
:
qAsConst
(
rules_
))
{
QRegularExpressionMatchIterator
mit
(
rule
.
pattern
.
globalMatch
(
text
)
);
while
(
mit
.
hasNext
())
{
//run trough regex matches and set the stored formats
QRegularExpressionMatch
match
=
mit
.
next
();
setFormat
(
match
.
capturedStart
(),
match
.
capturedLength
(),
rule
.
format
);
QRegularExpressionMatch
match
(
mit
.
next
()
)
;
setFormat
(
static_cast
<
int
>
(
match
.
capturedStart
()
)
,
static_cast
<
int
>
(
match
.
capturedLength
()
)
,
rule
.
format
);
}
}
}
...
...
@@ -194,8 +194,8 @@ void XMLSyntaxHighlighter::highlightBlock(const QString &text)
for
(
const
HighlightingRule
&
rule
:
qAsConst
(
rules_
))
{
QRegularExpressionMatchIterator
mit
(
rule
.
pattern
.
globalMatch
(
text
)
);
while
(
mit
.
hasNext
())
{
//run trough regex matches and set the stored formats
QRegularExpressionMatch
match
=
mit
.
next
();
setFormat
(
match
.
capturedStart
(),
match
.
capturedLength
(),
rule
.
format
);
QRegularExpressionMatch
match
(
mit
.
next
()
)
;
setFormat
(
static_cast
<
int
>
(
match
.
capturedStart
()
)
,
static_cast
<
int
>
(
match
.
capturedLength
()
)
,
rule
.
format
);
}
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment