editors/TextViewer.py
changeset 2409 00d90ab8a462
parent 2177 10aa87518401
child 2432 dbc065a2f7a5
equal deleted inserted replaced
2408:23978e5b039a 2409:00d90ab8a462
   961                 highlight_end_pos = self.Editor.GetLineEndPosition(end[0] - 1) + end[1] - indent + 2
   961                 highlight_end_pos = self.Editor.GetLineEndPosition(end[0] - 1) + end[1] - indent + 2
   962             if highlight_start_pos < end_pos and highlight_end_pos > start_pos:
   962             if highlight_start_pos < end_pos and highlight_end_pos > start_pos:
   963                 self.StartStyling(highlight_start_pos, 0xff)
   963                 self.StartStyling(highlight_start_pos, 0xff)
   964                 self.SetStyling(highlight_end_pos - highlight_start_pos, highlight_type)
   964                 self.SetStyling(highlight_end_pos - highlight_start_pos, highlight_type)
   965                 self.StartStyling(highlight_start_pos, 0x00)
   965                 self.StartStyling(highlight_start_pos, 0x00)
   966                 self.SetStyling(len(self.Editor.GetText()) - highlight_end_pos, wx.stc.STC_STYLE_DEFAULT)
   966                 until_end = max(0, len(self.Editor.GetText()) - highlight_end_pos)
       
   967                 self.SetStyling(until_end, wx.stc.STC_STYLE_DEFAULT)