Navigation: GeoDict 2025 - User Guide > Automation > GeoPy Scripting > Advanced Scripting > GeoDict API |
Scroll |
Dialog Class
Create your own customized dialog for variable input or messages.
Create an input dialog object to query the user for parameters. There is a large variety of possible input fields.
Input:
Note! In the examples for the input parameters often the notation "parameter name = parameter value" is used. This is not mandatory, but using this notation, the order and the number of optional arguments used does not matter anymore. This is very useful, if you only want to enter some of the optional parameters. Additionally it increases readability, highlighting which value belongs to which key. This can sometimes also be useful for obligatory arguments. |
Add a check box to your dialog. The value is True, when the checkbox is enabled, otherwise False Input:
Example:
![]() |
Add an integer input to your dialog. Here, integer numbers can be entered in the corresponding field. Input:
Example:
|
Add an uinteger input field to your dialog. Here, the value can also be changed by clicking the arrows on the right. Input:
Example:
![]() |
Add an floating point number input field. Here, floating point numbers can be entered. Input:
Example:
![]() |
Add an text input field to your dialog. Here, text can be entered and will be considered as string. Input:
Example:
![]() |
Add a file input field. The input box comes with a Browse button to browse for the file. The value is considered as string. Input:
Example:
![]() |
Add a folder input field. The input box comes with a Browse button to browse for the folder. The value is considered as string. Input:
Example:
![]() |
Add a combo box to your dialog. The value choice is given as list of strings. Within the script, the returned value is the index of the selected list item. Input:
Example:
![]() |
Add a combo box to your dialog. The value choice is given as list of strings. Within the script, the returned value is the string of the selected list item. Input:
Example:
![]() |
Add a material input box to your dialog. A material can be chosen from the GeoDict material database. Input:
Example:
![]() |
Add table input to your dialog. A table with multiple rows and the defined number of columns is given. Input:
Example:
![]() |
Add free-form text to your dialog in the given font size and in bold (True) or not bold (False). Input:
![]() |
Fields can be grouped within a box. Add input values or free text between the beginGroup and endGroup lines. Input:
Example:
![]() |
Fields can be grouped within a box. Add input values or free text between the beginGroup and endGroup lines. Input: None Example: see beginGroup() above. |
Add images to the dialog box. Before you can add them, they must be transformed to a 3D numpy array, which can for example be done using the Python packages PIL and numpy. Input:
Example:
![]() |
Execute the dialog. Input: None Example: see any other function above. |
Save the dialog settings as a *.gps file (GeoDict parameter settings) after calling run(). Input:
Example: see below in the examples for interaction with dialog object. |
Input explanations for the sub functions:
|
All examples in one dialog
Example:
![]() |
Examples for interaction with dialog object
If the user clicks Cancel, result will be None. Otherwise, result will be a dictionary containing the entered values, e.g.
|
©2025 created by Math2Market GmbH / Imprint / Privacy Policy