# HG changeset patch
# User Laurent Bessard
# Date 1350574949 -7200
# Node ID daafaa8a28fda78b7b71b8ba7a142e944388a672
# Parent  9695969796d01e05fa3bf0216251031b90002113
Fix bug in TextViewer when starting text with '{' character

diff -r 9695969796d0 -r daafaa8a28fd editors/TextViewer.py
--- a/editors/TextViewer.py	Thu Oct 18 16:30:12 2012 +0200
+++ b/editors/TextViewer.py	Thu Oct 18 17:42:29 2012 +0200
@@ -596,7 +596,7 @@
                     current_context = self.Variables
                 state = COMMENT
             elif line.endswith("{") and state != PRAGMA:
-                self.SetStyling(current_pos - last_styled_pos - 1, 31)
+                self.SetStyling(current_pos - last_styled_pos, 31)
                 last_styled_pos = current_pos
                 if state == WORD:
                     current_context = self.Variables