Skip to content

Commit

Permalink
Merge branch 'dev' into sb_dev
Browse files Browse the repository at this point in the history
  • Loading branch information
qbirrer committed Nov 15, 2024
2 parents 1550cd3 + 5c4210b commit e993753
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions nxt_editor/dockwidgets/syntax.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def match_multiline(self, text, delimiter, in_state, style):
match = delimiter.match(text)
start = match.capturedStart()
# Move past this match
add = match.capturedLength()
add = match.capturedLength() + 1

# As long as there's a delimiter match on this line...
while start >= 0:
Expand All @@ -173,7 +173,10 @@ def match_multiline(self, text, delimiter, in_state, style):
# Apply formatting
self.setFormat(start, length, style)
# Look for the next match
start = match.capturedStart() + (start + length)
match = delimiter.match(text, start + length)
if not match.hasMatch():
break
start = match.capturedStart()

# Return True if still inside a multi-line string, False otherwise
if self.currentBlockState() == in_state:
Expand Down

0 comments on commit e993753

Please sign in to comment.