eric6/QScintilla/MiniEditor.py

changeset 7900
72b88fb20261
parent 7864
431e6816c60c
child 7923
91e843545d9a
equal deleted inserted replaced
7899:ecf67e07b6e0 7900:72b88fb20261
3211 3211
3212 @param filename filename used to determine the associated lexer 3212 @param filename filename used to determine the associated lexer
3213 language (string) 3213 language (string)
3214 @param initTextDisplay flag indicating an initialization of the text 3214 @param initTextDisplay flag indicating an initialization of the text
3215 display is required as well (boolean) 3215 display is required as well (boolean)
3216 @keyparam pyname name of the pygments lexer to use (string) 3216 @param pyname name of the pygments lexer to use (string)
3217 """ 3217 """
3218 self.__bindLexer(filename, pyname=pyname) 3218 self.__bindLexer(filename, pyname=pyname)
3219 self.__textEdit.recolor() 3219 self.__textEdit.recolor()
3220 self.__checkLanguage() 3220 self.__checkLanguage()
3221 3221
3280 """ 3280 """
3281 Private slot to set the correct lexer depending on language. 3281 Private slot to set the correct lexer depending on language.
3282 3282
3283 @param filename filename used to determine the associated lexer 3283 @param filename filename used to determine the associated lexer
3284 language (string) 3284 language (string)
3285 @keyparam pyname name of the pygments lexer to use (string) 3285 @param pyname name of the pygments lexer to use (string)
3286 """ 3286 """
3287 if ( 3287 if (
3288 self.lexer_ is not None and 3288 self.lexer_ is not None and
3289 (self.lexer_.lexer() == "container" or 3289 (self.lexer_.lexer() == "container" or
3290 self.lexer_.lexer() is None) 3290 self.lexer_.lexer() is None)
3619 """ 3619 """
3620 Public slot to jump to the beginning of a line. 3620 Public slot to jump to the beginning of a line.
3621 3621
3622 @param line line number to go to 3622 @param line line number to go to
3623 @type int 3623 @type int
3624 @keyparam pos position in line to go to 3624 @param pos position in line to go to
3625 @type int 3625 @type int
3626 """ 3626 """
3627 self.__textEdit.setCursorPosition(line - 1, pos - 1) 3627 self.__textEdit.setCursorPosition(line - 1, pos - 1)
3628 self.__textEdit.ensureLineVisible(line - 1) 3628 self.__textEdit.ensureLineVisible(line - 1)
3629 self.__textEdit.setFirstVisibleLine(line - 1) 3629 self.__textEdit.setFirstVisibleLine(line - 1)

eric ide

mercurial