title: How to make responsive Dialog from PyQt so that Contents will fit while resizing size
body: <p>I have simple dialog with one Line Edit  and one Push Button widgets. After running applciation and while resizing the dialog
  size these widgets(LineEdit and PushButton) does not fit to the dialog.How can i make these item responsive while resizing the
  dialog box.</p>
  
  <pre><code>class Ui_ZValue(object):
      def setupUi(self, ZValue):
          ZValue.setObjectName("ZValue")
          ZValue.resize(400, 300)
          ZValue.setModal(False)
          self.lineEdit = QtWidgets.QLineEdit(ZValue)
          self.lineEdit.setGeometry(QtCore.QRect(130, 70, 131, 41))
          self.lineEdit.setObjectName("lineEdit")
          self.pushButton = QtWidgets.QPushButton(ZValue)
          self.pushButton.setGeometry(QtCore.QRect(130, 150, 131, 41))
          self.pushButton.setObjectName("pushButton")
  
          self.retranslateUi(ZValue)
          QtCore.QMetaObject.connectSlotsByName(ZValue)
  
      def retranslateUi(self, ZValue):
          _translate = QtCore.QCoreApplication.translate
          ZValue.setWindowTitle(_translate("ZValue", "Copy Z Cordinate"))
          self.pushButton.setText(_translate("ZValue", "Cofirm"))
  
  
  import sys
  from PyQt5.QtWidgets import QDialog,QApplication
  from  makebeautiful import *
  class MyForm(QDialog):
      def __init__(self):
          super().__init__()
          self.ui=Ui_ZValue()
          self.ui.setupUi(self）
          self.ui.pushButton.clicked.connect(self.dispmessage)
          self.show()
      def dispmessage(self):
          self.ui.lineEdit.setText("clicked")
  if __name__=="__main__":
      app=QApplication(sys.argv)
  
      w=MyForm()
      w.show()
      sys.exit(app.exec_())
  </code></pre>