Skip to main content

path_setting

Function path_setting 

Source
pub fn path_setting<G, S>(
    key: &'static str,
    prompt: &'static str,
    directories: bool,
    files: bool,
    value: G,
    set_value: S,
) -> SettingField<SharedString>
where G: Fn(&App) -> String + 'static, S: Fn(String, &mut App) + 'static,
Expand description

A path field with a Browse… button.

directories and files are passed through to PathPromptOptions. value reads the current path from the application, set_value writes the chosen or typed path back. The input is keyed by its setting position, so rebuilding the page on each frame keeps the same editor state.