diff --git a/doc/howtos/python_api_introduction/script_dialogs_introduction.md b/doc/howtos/python_api_introduction/script_dialogs_introduction.md index c8063ff..f4239c3 100644 --- a/doc/howtos/python_api_introduction/script_dialogs_introduction.md +++ b/doc/howtos/python_api_introduction/script_dialogs_introduction.md @@ -41,13 +41,13 @@ --> ```{code-block} python - :caption: Example: Script with separate dialog file + :caption: Example: Script with separate dialog file RESULT=gom.script.sys.execute_user_defined_dialog (file=':dialog.gdlg') ``` ```{code-block} python - :caption: Example: Script with embedded dialog + :caption: Example: Script with embedded dialog RESULT=gom.script.sys.execute_user_defined_dialog (dialog={ "content": [ @@ -292,21 +292,20 @@ Continuous text widget | ![](assets/edit_text.png) | ![](assets/widget_text.png) | -[//]: # (* The keywords displayed in text field widgets can originate from different source:) - -[//]: # ( * Global application keywords) - -[//]: # ( * project related keywords) - -[//]: # ( * local script variables.) - -[//]: # (⚠️ Local script variables can be displayed in text fields by inserting them via the 'insert expression' dialog.) - -[//]: # ( * Local script variables are invalid until the variable assignment is reached. They cannot be displayed statically in the text) - -[//]: # (field editor prior to script execution, so an invalid value will most certainly be displayed instead.) - -[//]: # (To Do: Check how to insert local variables) +%* The keywords displayed in text field widgets can originate from different source: +% +% * Global application keywords +% +% * project related keywords +% +% * local script variables. +% +%⚠️ Local script variables can be displayed in text fields by inserting them via the 'insert expression' dialog. +% +% * Local script variables are invalid until the variable assignment is reached. They cannot be displayed statically in the text +% field editor prior to script execution, so an invalid value will most certainly be displayed instead. +% +% To Do: Check how to insert local variables | Property | Type | Example | | ------------------- | ---- | ---------------------------------------------------------- | @@ -667,9 +666,8 @@ userInput = RESULT.decimalWidget | precision | double |
# Set precision to 2 decimals| | unit | str |
DIALOG.input.precision = 2
# Set unit ID| -[//]: # ( No visible effect ) - -[//]: # ( background_style - str - Set style sheet based background color - red, green, blue ) +% No visible effect: +% background_style - str - Set style sheet based background color - red, green, blue #### Text entry field ![](assets/widget_text_entry.png) @@ -721,9 +719,8 @@ print( RESULT.sliderWidget ) # some text | step | double |
DIALOG.input.unit = 'LENGTH'
# Set step size to 15| | orientation | str |
DIALOG.input.step = 15
print(DIALOG.input.orientation)⚠️ read-only | -[//]: # ( ticks are not drawn ) - -[//]: # ( tick_interval - double - Interval of ticks drawn ) +% ticks are not drawn: +% tick_interval - double - Interval of ticks drawn #### Checkbox widget @@ -770,9 +767,8 @@ File widget | file_types | list |
# Show only specified file types; each list item must consist of \[\⚠️ ``limited`` must be set to ``True`` in order to apply the filter! | | limited | bool |, \ \]
DIALOG.inputFile.file_types = \[\['*.g3d', 'Mesh data'\], \['*.stp', 'CAD data'\]\]
# Limit file selection to 'file_types'| -[//]: # (Clarify this) - -[//]: # (selection_type - str - File selector type; any, directory, executable, file, multi_file ) +% Clarify this: +% selection_type - str - File selector type; any, directory, executable, file, multi_file #### Date widget @@ -926,7 +922,7 @@ print("Chosen system plane:", RESULT.input_new.name) The complete code of the example is attached to this document. -[//]: # (To Do: attach example) +% To Do: attach example #### Selection list widget @@ -1014,7 +1010,7 @@ Abort button widget ![](assets/built-in_progressbar.png) -[//]: # (To Do: Add enabled abort button. Check if the button still exists in ZEISS Inspect.) +% To Do: Add enabled abort button. Check if the button still exists in ZEISS Inspect. #### Tolerances widget diff --git a/doc/python_api/scripted_elements_api.md b/doc/python_api/scripted_elements_api.md index 1f51b58..70f28bd 100644 --- a/doc/python_api/scripted_elements_api.md +++ b/doc/python_api/scripted_elements_api.md @@ -174,8 +174,8 @@ result = [ { 'points': [gom.Vec3D, gom.Vec3D, ...] } ] ```{code-block} python result = { 'default': [ - {'points': [gom.Vec3d, gom.Vec3d, …], 'normals': [gom.Vec3d, gom.Vec3d, …]}, - {…}, + {'points': [gom.Vec3d, gom.Vec3d, …], 'normals': [gom.Vec3d, gom.Vec3d, ...]}, + {...}, ... ] } diff --git a/doc/python_examples/index.md b/doc/python_examples/index.md index 647aaf9..a80f6fb 100644 --- a/doc/python_examples/index.md +++ b/doc/python_examples/index.md @@ -54,14 +54,14 @@ The following project files are included: ## Examples by topic -| Folder | Description | -| ---------------------------------------- | ------------------------------------------------------------ | -| [data_interfaces](data_interfaces.rst) | Access to data of GOM "elements" | -| [dialog_widgets](dialog_widgets.rst) | Examples how use custom dialogs and handle user input events | -| [misc](misc.rst) | Miscellaneous examples | -| [script_icons](script_icons.rst) | Set icons for scripts or buttons | -| [script_resources](script_resources.rst) | How to access binary data of your add-on (resources) | -| [scripted_actuals](scripted_actuals.rst) | Building actual elements with custom python code | -| [scripted_checks](scripted_checks.rst) | Building custom checks with python code | +| Folder | Description | +| --------------------------------------- | ------------------------------------------------------------ | +| [data_interfaces](data_interfaces.md) | Access to data of GOM "elements" | +| [dialog_widgets](dialog_widgets.md) | Examples how use custom dialogs and handle user input events | +| [misc](misc.md) | Miscellaneous examples | +| [script_icons](script_icons.md) | Set icons for scripts or buttons | +| [script_resources](script_resources.md) | How to access binary data of your add-on (resources) | +| [scripted_actuals](scripted_actuals.md) | Building actual elements with custom python code | +| [scripted_checks](scripted_checks.md) | Building custom checks with python code | \ No newline at end of file
DIALOG.inputFile.limited = True