Debugger/VariablesViewer.py

changeset 3656
441956d8fce5
parent 3621
15f23ed3f216
child 3664
78e522719af3
equal deleted inserted replaced
3654:ffeb85cdc72d 3656:441956d8fce5
11 try: 11 try:
12 str = unicode 12 str = unicode
13 except NameError: 13 except NameError:
14 pass 14 pass
15 15
16 from PyQt4.QtCore import Qt, QRegExp, qVersion 16 from PyQt5.QtCore import Qt, QRegExp, qVersion, QCoreApplication
17 from PyQt4.QtGui import QTreeWidget, QTreeWidgetItem, QApplication, \ 17 from PyQt5.QtWidgets import QTreeWidget, QTreeWidgetItem, QAbstractItemView, \
18 QAbstractItemView, QMenu 18 QMenu
19 from PyQt4.QtGui import QTextDocument # __IGNORE_WARNING__ 19 from PyQt5.QtGui import QTextDocument # __IGNORE_WARNING__
20 20
21 from E5Gui.E5Application import e5App 21 from E5Gui.E5Application import e5App
22 22
23 from DebugClients.Python3.DebugConfig import ConfigVarTypeStrings 23 from DebugClients.Python3.DebugConfig import ConfigVarTypeStrings
24 24
41 @param dvalue value string (string) 41 @param dvalue value string (string)
42 @param dtype type string (string) 42 @param dtype type string (string)
43 """ 43 """
44 self.__value = dvalue 44 self.__value = dvalue
45 if len(dvalue) > 2048: # 1024 * 2 45 if len(dvalue) > 2048: # 1024 * 2
46 dvalue = QApplication.translate("VariableItem", 46 dvalue = QCoreApplication.translate(
47 "<double click to show value>") 47 "VariableItem", "<double click to show value>")
48 self.__tooltip = dvalue 48 self.__tooltip = dvalue
49 else: 49 else:
50 if Qt.mightBeRichText(dvalue): 50 if Qt.mightBeRichText(dvalue):
51 self.__tooltip = Utilities.html_encode(dvalue) 51 self.__tooltip = Utilities.html_encode(dvalue)
52 else: 52 else:

eric ide

mercurial