Ejemplo n.º 1
0
 def mousePressEvent(self, event):
     """
     When the execution fail, allow to press the links in the traceback,
     to go to the line when the error occur.
     """
     QPlainTextEdit.mousePressEvent(self, event)
     self.go_to_error(event)
Ejemplo n.º 2
0
 def mousePressEvent(self, event):
     """
     When the execution fail, allow to press the links in the traceback,
     to go to the line when the error occur.
     """
     QPlainTextEdit.mousePressEvent(self, event)
     self.go_to_error(event)
Ejemplo n.º 3
0
 def mousePressEvent(self, event):
     if event.modifiers() == Qt.ControlModifier:
         cursor = self.cursorForPosition(event.pos())
         self.setTextCursor(cursor)
         self.go_to_definition(cursor)
     elif event.button() == Qt.RightButton and \
     not self.textCursor().hasSelection():
         cursor = self.cursorForPosition(event.pos())
         self.setTextCursor(cursor)
     QPlainTextEdit.mousePressEvent(self, event)
Ejemplo n.º 4
0
 def mousePressEvent(self, event):
     if event.modifiers() == Qt.ControlModifier:
         cursor = self.cursorForPosition(event.pos())
         self.setTextCursor(cursor)
         self.go_to_definition(cursor)
     elif event.button() == Qt.RightButton and \
     not self.textCursor().hasSelection():
         cursor = self.cursorForPosition(event.pos())
         self.setTextCursor(cursor)
     QPlainTextEdit.mousePressEvent(self, event)
Ejemplo n.º 5
0
 def mousePressEvent(self, event):
     """Reimplement Qt method"""
     if os.name != 'posix' and event.button() == Qt.MidButton:
         self.setFocus()
         event = QMouseEvent(QEvent.MouseButtonPress, event.pos(),
                             Qt.LeftButton, Qt.LeftButton, Qt.NoModifier)
         QPlainTextEdit.mousePressEvent(self, event)
         QPlainTextEdit.mouseReleaseEvent(self, event)
         self.paste()
     else:
         QPlainTextEdit.mousePressEvent(self, event)
Ejemplo n.º 6
0
 def mousePressEvent(self, event):
     """Reimplement Qt method"""
     if os.name != 'posix' and event.button() == Qt.MidButton:
         self.setFocus()
         event = QMouseEvent(QEvent.MouseButtonPress, event.pos(),
                             Qt.LeftButton, Qt.LeftButton, Qt.NoModifier)
         QPlainTextEdit.mousePressEvent(self, event)
         QPlainTextEdit.mouseReleaseEvent(self, event)
         self.paste()
     else:
         QPlainTextEdit.mousePressEvent(self, event)
Ejemplo n.º 7
0
 def mousePressEvent(self, event):
     QPlainTextEdit.mousePressEvent(self, event)
     self.go_to_error(event)
Ejemplo n.º 8
0
 def mousePressEvent(self, event):
     QPlainTextEdit.mousePressEvent(self, event)
     self.go_to_error(event)