code: def resizeEvent(self, event):
          
          if not self.isMaximized() and not self.fullscreen_flag:
              self.window_size = self.size()
          QMainWindow.resizeEvent(self, event)
  
          # To be used by the tour to be able to resize
          self.sig_resized.emit(event)
docs: Reimplement Qt method