Function TRAP::Utils::Dialogs::OpenFile#
Function Documentation#
-
std::vector<std::string> TRAP::Utils::Dialogs::OpenFile(const std::string &title, const std::string &defaultPathAndFile = "", const std::vector<std::pair<std::string, std::string>> &filterPatterns = {}, bool allowMultipleSelects = false, bool allFiles = true)#
Opens an open file dialog.
- Parameters:
title – Title for the dialog.
defaultPathAndFile – Sets a default path and file.
filterPatterns – File filters (separate multiple extensions for the same filter with a ‘;’. Example: {“Test File”, “*.Test;*.TS”}.
allowMultipleSelects – Whether to allow multiple file selections or not.
allFiles – Whether to add a filter for “All Files (*.*)” or not.
- Returns:
Physical path(s) of the dialog or empty string or vector.