title: Make window scale to screen size in PyQt5
body: <p>I'm currently developing a web browser in Python using Qt5. Just wondering: How can I make the window scale to the screen size? For example, Chromium and Firefox adapt to the size of the screen they're on when maximized. </p>
  
  <p>Here's how Chromium displays Google when maximized: </p>
  
  <p><a href="https://i.stack.imgur.com/4VdOE.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4VdOE.png" alt="enter image description here"></a></p>
  
  <p><strong>EDIT:</strong> Since I was requested to add some example code, here is the code:</p>
  
  <pre><code>from PyQt5.QtWidgets import QApplication, QWidget 
  from ui_output import Ui_Form
  
  app = QApplication(sys.argv) 
  
  
  class MainWindow(QWidget, Ui_Form):   
      def __init__(self, parent=None):     
          super(MainWindow, self).__init__(parent)     
          self.setupUi(self)     
          self.go_button.clicked.connect(self.pressed)   
      def pressed(self):     
          self.webView.setUrl(QUrl(self.lineEdit.displayText()))
  
  view = MainWindow() 
  view.show() 
  view.showMaximized()
  app.exec_()
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/0pUdF.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/0pUdF.png" alt="enter image description here"></a></p>