diff -r 9303f6b900fe -r 1ec5b4d244f3 editors/TextViewer.py --- a/editors/TextViewer.py Thu May 09 18:49:08 2013 +0200 +++ b/editors/TextViewer.py Thu May 09 19:36:37 2013 +0200 @@ -547,7 +547,8 @@ else: self.SetStyling(current_pos - last_styled_pos, 31) last_styled_pos = current_pos - state = SPACE + if state != DPRAGMA: + state = SPACE line = "" line_number += 1 self.RefreshLineFolding(line_number) @@ -579,7 +580,7 @@ state = SPACE elif state == DPRAGMA: if line.endswith("}}"): - self.SetStyling(current_pos - last_styled_pos + 2, 31) + self.SetStyling(current_pos - last_styled_pos + 1, 31) last_styled_pos = current_pos + 1 state = SPACE elif (line.endswith("'") or line.endswith('"')) and state not in [STRING, WSTRING]: