QScintilla/Shell.py

changeset 5736
000ea446ff4b
parent 5712
f0d08bdeacf4
child 5752
1860eca908e4
child 5798
e4f9552f7f93
equal deleted inserted replaced
5735:f606dbe20be6 5736:000ea446ff4b
10 from __future__ import unicode_literals 10 from __future__ import unicode_literals
11 11
12 import sys 12 import sys
13 import re 13 import re
14 14
15 from PyQt5.QtCore import pyqtSignal, QFileInfo, Qt, QEvent, qVersion 15 from PyQt5.QtCore import pyqtSignal, QFileInfo, Qt, QEvent
16 from PyQt5.QtGui import QClipboard, QPalette, QFont 16 from PyQt5.QtGui import QClipboard, QPalette, QFont
17 from PyQt5.QtWidgets import QDialog, QInputDialog, QApplication, QMenu, \ 17 from PyQt5.QtWidgets import QDialog, QInputDialog, QApplication, QMenu, \
18 QWidget, QHBoxLayout, QVBoxLayout, QShortcut 18 QWidget, QHBoxLayout, QVBoxLayout, QShortcut
19 from PyQt5.Qsci import QsciScintilla 19 from PyQt5.Qsci import QsciScintilla
20 20
22 from E5Gui import E5MessageBox 22 from E5Gui import E5MessageBox
23 23
24 from .QsciScintillaCompat import QsciScintillaCompat 24 from .QsciScintillaCompat import QsciScintillaCompat
25 25
26 import Preferences 26 import Preferences
27
28 import Utilities 27 import Utilities
28 from Globals import qVersionTuple
29 29
30 import UI.PixmapCache 30 import UI.PixmapCache
31 31
32 from Debugger.DebugClientCapabilities import HasCompleter 32 from Debugger.DebugClientCapabilities import HasCompleter
33 33
998 Protected method to handle wheel events. 998 Protected method to handle wheel events.
999 999
1000 @param evt reference to the wheel event (QWheelEvent) 1000 @param evt reference to the wheel event (QWheelEvent)
1001 """ 1001 """
1002 if evt.modifiers() & Qt.ControlModifier: 1002 if evt.modifiers() & Qt.ControlModifier:
1003 if qVersion() >= "5.0.0": 1003 if qVersionTuple() >= (5, 0, 0):
1004 delta = evt.angleDelta().y() 1004 delta = evt.angleDelta().y()
1005 else: 1005 else:
1006 delta = evt.delta() 1006 delta = evt.delta()
1007 if delta < 0: 1007 if delta < 0:
1008 self.zoomOut() 1008 self.zoomOut()

eric ide

mercurial