Example #1
0
 def test_scintillawrapper_void_position_int(self):
     editor.setText('Hello world')
     editor.setLexer(LEXER.CONTAINER)
     editor.startStyling(0, 31)
     editor.setStyling(5, 29)
     styledText = editor.getStyledText(0, 5)
     editor.setLexer(LEXER.NULL)
     self.assertEqual(styledText, ('Hello', [29, 29, 29, 29, 29]))
Example #2
0
 def style_it(match, STYLE):
     ''' Inform scintilla to do the styling'''
     if match[1] - match[0] >= 0:
         editor.startStyling(start_pos + match[0], 31)
         editor.setStyling(match[1] - match[0], STYLE)
Example #3
0
 def style_it(start, length, STYLE):
     ''' Inform scintilla to do the styling'''
     if length >= 0:
         editor.startStyling(start, 31)
         editor.setStyling(length, STYLE)
Example #4
0
 def style_it(match, STYLE):
     ''' Inform scintilla to do the styling'''
     if match[1]-match[0] >= 0:
         editor.startStyling(start_pos + match[0], 31)
         editor.setStyling(match[1]-match[0], STYLE)
Example #5
0
 def style_it(start, length, STYLE):
     ''' Inform scintilla to do the styling'''
     if length >= 0:
         editor.startStyling(start, 31)
         editor.setStyling(length, STYLE)