title: Properly handling a keyPressEvent in a Subclassed PyQT LineEdit
body: <p>So I have a QLineEdit that I want to catch a shift keypress in. </p>
  
  <p>Here's my code:</p>
  
  <pre><code>class NoteText(QtGui.QLineEdit):
      def __init__(self, parent):
          super (NoteText, self).__init__(parent)
  
      def keyPressEvent(self, event):
          if (event.modifiers() &amp; QtCore.Qt.ShiftModifier):
              self.shift = True
              print 'Shift!'
  </code></pre>
  
  <p>As you can guess, I can catch the shift keypress, but then you cannot input text into the LineEdit. I've tried catching keypresses, but I'm not sure quite what to do with them to allow the user to continue to type into the widget.</p>
  
  <p>What am I missing? Thanks!</p>