Let's create a new application based on the Dialog without Buttons template by performing the following steps:
- Since the application will prompt the user to choose the country that he/she lives, via input dialog, so drag and drop one Label widget, one Line Edit widget, and one Push Button widget onto the form.
- Set the text property of the Label widget to Your Country.
- Set the text property of the Push Button widget to Choose Country.
- Set the objectName property of the Line Edit widget to lineEditCountry.
- Set the objectName property of the Push Button widget to pushButtonCountry.
- Save the application with the name demoInputDialog.ui.
The form will now look as follows:
The user interface created with Qt Designer is stored ...