From anonymous, 1 Month ago, written in Plain Text.
Embed
  1. import logging
  2. from PyQt5.QtWidgets import QWidget
  3.  
  4. class Test(QWidget):
  5.     def mousePressEvent(self, ev):
  6.         logging.info(ev.button())
  7.  
  8. w = Test()
  9. w.show()