Preferences/PreferencesLexer.py

changeset 3656
441956d8fce5
parent 3591
2f2a4a76dd22
child 3658
edcfadf0152d
equal deleted inserted replaced
3654:ffeb85cdc72d 3656:441956d8fce5
7 Module implementing a special QextScintilla lexer to handle the preferences. 7 Module implementing a special QextScintilla lexer to handle the preferences.
8 """ 8 """
9 9
10 from __future__ import unicode_literals 10 from __future__ import unicode_literals
11 11
12 from PyQt4.QtGui import QColor, QFont, QApplication 12 from PyQt5.QtGui import QColor, QFont, QCoreApplication
13 from PyQt4.Qsci import QsciLexer 13 from PyQt5.Qsci import QsciLexer
14 14
15 import Preferences 15 import Preferences
16 import Globals 16 import Globals
17 17
18 18
22 """ 22 """
23 def __init__(self): 23 def __init__(self):
24 """ 24 """
25 Constructor 25 Constructor
26 """ 26 """
27 self._errorMessage = QApplication.translate( 27 self._errorMessage = QCoreApplication.translate(
28 "PreferencesLexerError", 28 "PreferencesLexerError",
29 "Unspecific PreferencesLexer error.") 29 "Unspecific PreferencesLexer error.")
30 30
31 def __repr__(self): 31 def __repr__(self):
32 """ 32 """
54 Constructor 54 Constructor
55 55
56 @param language lexer language (string) 56 @param language lexer language (string)
57 """ 57 """
58 PreferencesLexerError.__init__(self) 58 PreferencesLexerError.__init__(self)
59 self._errorMessage = QApplication.translate( 59 self._errorMessage = QCoreApplication.translate(
60 "PreferencesLexerError", 60 "PreferencesLexerError",
61 'Unsupported Lexer Language: {0}').format(language) 61 'Unsupported Lexer Language: {0}').format(language)
62 62
63 63
64 class PreferencesLexer(QsciLexer): 64 class PreferencesLexer(QsciLexer):

eric ide

mercurial