Class DialogsPartial
- class ooodev.dialog.partial.dialogs_partial.DialogsPartial(dialog_ctl, lo_inst=None)[source]
- Parameters:
dialog_ctl (UnoControlDialog) –
lo_inst (LoInst | None) –
- __init__(dialog_ctl, lo_inst=None)[source]
DialogsPartial Constructor.
- Parameters:
dialog_ctl (UnoControlDialog) – Main Dialog Window Control.
lo_inst (LoInst, optional) – Lo Instance. Use when creating multiple documents. Defaults to None.
- Return type:
None
- control_factory(dialog_ctrl)[source]
Gets a control as a
DialogControlBase
control.- Parameters:
dialog_ctrl (XControl) – Control.
- Returns:
Returns a
DialogControlBase
such asCtlButton
orCtlCheckBox
if found, elseNone
- Return type:
DialogControlBase | None
- find_controls(control_type, dialog_ctrl=None)[source]
Finds controls by type.
- Parameters:
control_type (ControlT) – Control type.
dialog_ctrl (XControl, optional) – Control. Defaults to Instance control.
- Returns:
List of controls.
- Return type:
List[ControlT]
- find_radio_siblings(radio_button, dialog_ctrl=None)[source]
Given the name of the first radio button of a group, return all the controls of the group.
For dialogs, radio buttons are considered of the same group when their tab indexes are contiguous.
- Parameters:
radio_button (str) – Specifies the exact name of the 1st radio button of the group.
dialog_ctrl (XControl, optional) – Control. Defaults to Instance control.
- Returns:
List of the names of the 1st and the next radio buttons. belonging to the same group in their tab index order. does not include the first button.
- Return type:
List[CtlRadioButton]
See also
get_radio_group_value()
.
- get_control_class_id(dialog_ctrl)[source]
Gets control class id.
- Parameters:
dialog_ctrl (XControl) – Control.
- Returns:
class id.
- Return type:
str
- get_control_name(dialog_ctrl)[source]
Get the name of a control.
- Parameters:
dialog_ctrl (XControl) – Control.
- Returns:
control name.
- Return type:
str
- get_control_props(control_model)[source]
Gets property set for a control model.
Method is Lo Instance Safe for use with multiple documents.
- Parameters:
control_model (Any) – control model.
- Returns:
Property set.
- Return type:
XPropertySet
- get_controls_arr(dialog_ctrl)[source]
Gets all controls for a given control.
- Parameters:
dialog_ctrl (XControl) – control.
- Returns:
controls.
- Return type:
Tuple[XControl, …]
- get_name_container(dialog_ctrl)[source]
Gets Name container from control.
- Parameters:
dialog_ctrl (XControl) – Dialog control.
- Returns:
Name Container.
- Return type:
XNameContainer
- get_radio_group_value(dialog_ctrl, radio_button)[source]
Get a radio button group. Similar to
find_radio_siblings()
but also includes first radio button.- Parameters:
dialog_ctrl (XControl) – Control.
radio_button (str) – Name of the first radio button of the group.
- Returns:
Value of the selected radio button.
- Return type:
Any
See also
find_radio_siblings()
.