Skip to main content

LensStudio:Ui.Dialogs.Params

Class

Configuration parameters for file dialogs including caption, file filter, and display options.

Index

Example

// Dialogs.Params configures file/folder dialog behavior.
// Properties: caption, filter, options.
const gui = this.pluginSystem.findInterface(IGui.interfaceId) as IGui;
if (Editor.isNull(gui)) {
console.log('IGui not available');
return;
}
const dialogs: IDialogs = gui.dialogs;

// Dialogs.Params has caption, filter, and options fields.
// Use it with selectFolderToOpen to pick a directory:
const params = {} as Dialogs.Params;
params.caption = 'Select Export Folder';
params.filter = '';
params.options = Dialogs.Options.DirectoriesOnly;

const defaultPath = new Editor.Path('');
const selected = dialogs.selectFolderToOpen(params, defaultPath);
console.log('Selected folder:', selected.toString());

Properties

caption

caption: string

Title text displayed in the dialog.


filter

filter: string

File type filter pattern for the dialog.


options

options: Options

Additional dialog behavior options.