Add Form Controls

Methods to add UI controls to a form in Launchpad

AddHeader

Adds a header text to the form.

public void AddHeader(string text, double fontSize = 16)

Parameters:

  • text: Text of the header.

  • fontSize: Optional. Font size of the header. Default is 16.


AddLabel

Adds a label to the form.

public void AddLabel(string text, double fontSize = 11, bool isItalic = false, bool isBold = false)

Parameters:

  • text: Text of the label.

  • fontSize: Optional. Font size of the label. Default is 11.

  • isItalic: Optional. Indicates whether the text should be italic. Default is false.

  • isBold: Optional. Indicates whether the text should be bold. Default is false.


AddTextInput

Adds a text input field to the form.

Parameters:

  • label: Label for the text input.

  • defaultValue: Optional. Initial value of the text input. Default is empty string.

  • isEnabled: Optional. Indicates whether the control is enabled. Default is true.


AddComboBox

Adds a dropdown selection box to the form.

Parameters:

  • label: Label for the combo box.

  • items: List of items to display in the combo box.

  • displaySelector: Optional. Function to convert items to display strings. Default is null.

  • isBold: Optional. Indicates if the label should be bold. Default is true.

  • selectedItem: Optional. The initially selected item. Default is the default value of type T.


AddListBox

Adds a list box to the form.

Parameters:

  • label: Label for the list box.

  • items: List of items to display in the list box.

  • displaySelector: Optional. Function to convert items to display strings. Default is null.

  • allowMultiple: Optional. Indicates whether multiple selection is allowed. Default is false.

  • height: Optional. Height of the list box. Default is 100.


AddRadioButtons

Adds a group of radio buttons to the form.

Parameters:

  • label: Label for the radio button group.

  • options: List of options to display as radio buttons.

  • defaultSelected: Optional. The initially selected option. Default is the first option.


AddCheckbox

Adds a checkbox to the form.

Parameters:

  • label: Label for the checkbox.

  • isChecked: Optional. Initial checked state of the checkbox. Default is false.


AddSlider

Adds a slider control to the form.

Parameters:

  • label: Label for the slider.

  • minimum: Optional. Minimum value of the slider. Default is 0.

  • maximum: Optional. Maximum value of the slider. Default is 100.

  • value: Optional. Initial value of the slider. Default is 50.

  • tickFrequency: Optional. Frequency of tick marks. Default is 10.

  • showValue: Optional. Indicates whether to display the current value. Default is true.

  • isBold: Optional. Indicates if the label should be bold. Default is true.


Adds a hyperlink to the form.

Parameters:

  • text: Display text for the hyperlink.

  • url: URL to navigate to when the link is clicked.

  • fontSize: Optional. Font size of the link. Default is 11.


AddFileSelector

Adds a file selection control to the form.

Parameters:

  • label: Label for the file selector.

  • filter: Optional. File filter string for the file dialog. Default is "All files (.)|.".


AddMultiFileSelector

Adds a control for selecting multiple files.

Parameters:

  • label: Label for the multi-file selector.

  • filter: Optional. File filter string for the file dialog. Default is "All files (.)|.".


AddCustomControl

Adds a custom UI element to the form.

Parameters:

  • control: The UI element to add.


BeginGroupBox

Starts a group box section in the form.

Parameters:

  • header: Header text for the group box.

  • margin: Optional. Bottom margin of the group box. Default is 0.

  • includeScrollbar: Optional. Indicates whether to include a scrollbar. Default is false.

  • maxScrollHeight: Optional. Maximum height of the scroll area. Default is 200.


EndGroupBox

Ends a group box section in the form.


BeginExpander

Begins an expandable section in the form.

Parameters:

  • header: Header text for the expander.

  • isExpanded: Optional. Indicates whether the expander is initially expanded. Default is false.

  • margin: Optional. Bottom margin of the expander. Default is 0.

  • contentIndent: Optional. Indentation of content within the expander. Default is 15.

  • showBorder: Optional. Indicates whether to show a border around the content. Default is true.


EndExpander

Ends an expandable section in the form.

Last updated