dlg_set_modal()

Sets a dialog to be modal or non-modal.

A modal dialog prevents user interaction with other parts of the application until it is closed.

Syntax

planetcnc.dlg_set_modal(handle, is_modal)

Parameters

Parameter Type Description Comment
handle string Handle of the dialog to modify.
is_modal bool `True` to set the dialog as modal, `False` for non-modal.

Return Value

Examples

#! /usr/bin/env python
 
import planetcnc
 
# Set an existing dialog to be modal
dialog_handle = "MyDialogHandle"
planetcnc.dlg_set_modal(dialog_handle, True)
 
print("Dialog is now modal.")

See also

dlg_set_modal
dlg_set_resizable
dlg_set_pos
dlg_set_size
dlg_set_btn
dlg_set_name
dlg_set_color