Skip to content

PythonQt.QtGui.QFileDialog · declarations 002

Back to PythonQt.QtGui.QFileDialog

fileMode instance-attribute

fileMode: Any

Qt 5 reference:

fileMode : FileMode

This property holds the file mode of the dialog

The file mode defines the number and type of items that the user is expected to select in the dialog.

By default, this property is set to AnyFile.

This function will set the labels for the FileName and Accept DialogLabels. It is possible to set custom text after the call to setFileMode().

Access functions:

QFileDialog::FileMode fileMode() const
void setFileMode(QFileDialog::FileMode mode)

See also FileMode.

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#fileMode

fileSelected

fileSelected(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.fileSelected; argument details are not documented.

Supplemental documentation: Qt 5 reference:

[signal] void QFileDialog::fileSelected(const QString \&file)

When the selection changes for local operations and the dialog is accepted, this signal is emitted with the (possibly empty) selected file.

See also currentChanged() and QDialog::Accepted.

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#fileSelected

filesSelected

filesSelected(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.filesSelected; argument details are not documented.

Supplemental documentation: Qt 5 reference:

[signal] void QFileDialog::filesSelected(const QStringList \&selected)

When the selection changes for local operations and the dialog is accepted, this signal is emitted with the (possibly empty) list of selected files.

See also currentChanged() and QDialog::Accepted.

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#filesSelected

filter

filter() -> Any

X.filter()

Supplemental documentation: Qt 5 reference:

QDir::Filters QFileDialog::filter() const

Returns the filter that is used when displaying files.

This function was introduced in Qt 4.4.

See also setFilter().

Upstream PySide2 reference signatures (binding differences may apply):

filter(self) -> PySide2.QtCore.QDir.Filters

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#filter

filterSelected

filterSelected(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.filterSelected; argument details are not documented.

Supplemental documentation: Qt 5 reference:

[signal] void QFileDialog::filterSelected(const QString \&filter)

This signal is emitted when the user selects a filter.

This function was introduced in Qt 4.3.

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#filterSelected

finished

finished(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.finished; argument details are not documented.

getExistingDirectory

getExistingDirectory(parent: Any, caption: str, dir: str, options: Any) -> str

X.getExistingDirectory(parent, caption, dir, options) -> str

Supplemental documentation: Qt 5 reference:

[static] QString QFileDialog::getExistingDirectory(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QString \&dir \= QString(), QFileDialog::Options options \= ShowDirsOnly)

This is a convenience static function that will return an existing directory selected by the user.

QString dir = QFileDialog::getExistingDirectory(this, tr("Open Directory"),
                                                "/home",
                                                QFileDialog::ShowDirsOnly
                                                | QFileDialog::DontResolveSymlinks);

This function creates a modal file dialog with the given parent widget. If parent is not nullptr, the dialog will be shown centered over the parent widget.

The dialog's working directory is set to dir, and the caption is set to caption. Either of these may be an empty string in which case the current directory and a default caption will be used respectively.

The options argument holds various options about how to run the dialog, see the QFileDialog::Option enum for more information on the flags you can pass. To ensure a native file dialog, ShowDirsOnly must be set.

On Windows and macOS, this static function will use the native file dialog and not a QFileDialog. However, the native Windows file dialog does not support displaying files in the directory chooser. You need to pass DontUseNativeDialog to display files using a QFileDialog.

Note that the macOS native file dialog does not show a title bar.

On Unix/X11, the normal behavior of the file dialog is to resolve and follow symlinks. For example, if /usr/tmp is a symlink to /var/tmp, the file dialog will change to /var/tmp after entering /usr/tmp. If options includes DontResolveSymlinks, the file dialog will treat symlinks as regular directories.

On Windows, the dialog will spin a blocking modal event loop that will not dispatch any QTimers, and if parent is not nullptr then it will position the dialog just below the parent's title bar.

Warning: Do not delete parent during the execution of the dialog. If you want to do this, you should create the dialog yourself using one of the QFileDialog constructors.

See also getOpenFileName(), getOpenFileNames(), and getSaveFileName().

Upstream PySide2 reference signatures (binding differences may apply):

getExistingDirectory(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: str=..., options: PySide2.QtWidgets.QFileDialog.Options=...) -> str

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getExistingDirectory

getExistingDirectoryUrl

getExistingDirectoryUrl(parent: Any, caption: str, dir: Any, options: Any, supportedSchemes: Any) -> Any

X.getExistingDirectoryUrl(parent, caption, dir, options, supportedSchemes) -> PythonQt.QtCore.QUrl

Supplemental documentation: Qt 5 reference:

[static] QUrl QFileDialog::getExistingDirectoryUrl(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QUrl \&dir \= QUrl(), QFileDialog::Options options \= ShowDirsOnly, const QStringList \&supportedSchemes \= QStringList())

This is a convenience static function that will return an existing directory selected by the user. If the user presses Cancel, it returns an empty url.

The function is used similarly to QFileDialog::getExistingDirectory(). In particular parent, caption, dir and options are used in the exact same way.

The main difference with QFileDialog::getExistingDirectory() comes from the ability offered to the user to select a remote directory. That's why the return type and the type of dir is QUrl.

The supportedSchemes argument allows to restrict the type of URLs the user will be able to select. It is a way for the application to declare the protocols it will support to fetch the file content. An empty list means that no restriction is applied (the default). Supported for local files ("file" scheme) is implicit and always enabled; it is not necessary to include it in the restriction.

When possible, this static function will use the native file dialog and not a QFileDialog. On platforms which don't support selecting remote files, Qt will allow to select only local files.

This function was introduced in Qt 5.2.

See also getExistingDirectory(), getOpenFileUrl(), getOpenFileUrls(), and getSaveFileUrl().

Upstream PySide2 reference signatures (binding differences may apply):

getExistingDirectoryUrl(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: PySide2.QtCore.QUrl=..., options: PySide2.QtWidgets.QFileDialog.Options=..., supportedSchemes: typing.Sequence[str]=...) -> PySide2.QtCore.QUrl

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getExistingDirectoryUrl

getOpenFileName

getOpenFileName(parent: Any, caption: str, dir: str, filter: str, selectedFilter: Any, options: Any) -> str

X.getOpenFileName(parent, caption, dir, filter, selectedFilter, options) -> str

Supplemental documentation: Qt 5 reference:

[static] QString QFileDialog::getOpenFileName(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QString \&dir \= QString(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options())

This is a convenience static function that returns an existing file selected by the user. If the user presses Cancel, it returns a null string.

QString fileName = QFileDialog::getOpenFileName(this, tr("Open File"),
                                                "/home",
                                                tr("Images (*.png *.xpm *.jpg)"));

The function creates a modal file dialog with the given parent widget. If parent is not nullptr, the dialog will be shown centered over the parent widget.

The file dialog's working directory will be set to dir. If dir includes a file name, the file will be selected. Only files that match the given filter are shown. The filter selected is set to selectedFilter. The parameters dir, selectedFilter, and filter may be empty strings. If you want multiple filters, separate them with ';;', for example:

"Images (*.png *.xpm *.jpg);;Text files (*.txt);;XML files (*.xml)"

The options argument holds various options about how to run the dialog, see the QFileDialog::Option enum for more information on the flags you can pass.

The dialog's caption is set to caption. If caption is not specified then a default caption will be used.

On Windows, and macOS, this static function will use the native file dialog and not a QFileDialog. Note that the macOS native file dialog does not show a title bar.

On Windows the dialog will spin a blocking modal event loop that will not dispatch any QTimers, and if parent is not nullptr then it will position the dialog just below the parent's title bar.

On Unix/X11, the normal behavior of the file dialog is to resolve and follow symlinks. For example, if /usr/tmp is a symlink to /var/tmp, the file dialog will change to /var/tmp after entering /usr/tmp. If options includes DontResolveSymlinks, the file dialog will treat symlinks as regular directories.

Warning: Do not delete parent during the execution of the dialog. If you want to do this, you should create the dialog yourself using one of the QFileDialog constructors.

See also getOpenFileNames(), getSaveFileName(), and getExistingDirectory().

Upstream PySide2 reference signatures (binding differences may apply):

getOpenFileName(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: str=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=...) -> typing.Tuple[str, str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getOpenFileName

getOpenFileNames

getOpenFileNames(parent: Any, caption: str, dir: str, filter: str, selectedFilter: Any, options: Any) -> tuple

X.getOpenFileNames(parent, caption, dir, filter, selectedFilter, options) -> tuple

Supplemental documentation: Qt 5 reference:

[static] QStringList QFileDialog::getOpenFileNames(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QString \&dir \= QString(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options())

This is a convenience static function that will return one or more existing files selected by the user.

QStringList files = QFileDialog::getOpenFileNames(
                        this,
                        "Select one or more files to open",
                        "/home",
                        "Images (*.png *.xpm *.jpg)");

This function creates a modal file dialog with the given parent widget. If parent is not nullptr, the dialog will be shown centered over the parent widget.

The file dialog's working directory will be set to dir. If dir includes a file name, the file will be selected. The filter is set to filter so that only those files which match the filter are shown. The filter selected is set to selectedFilter. The parameters dir, selectedFilter and filter may be empty strings. If you need multiple filters, separate them with ';;', for instance:

"Images (*.png *.xpm *.jpg);;Text files (*.txt);;XML files (*.xml)"

The dialog's caption is set to caption. If caption is not specified then a default caption will be used.

On Windows, and macOS, this static function will use the native file dialog and not a QFileDialog. Note that the macOS native file dialog does not show a title bar.

On Windows the dialog will spin a blocking modal event loop that will not dispatch any QTimers, and if parent is not nullptr then it will position the dialog just below the parent's title bar.

On Unix/X11, the normal behavior of the file dialog is to resolve and follow symlinks. For example, if /usr/tmp is a symlink to /var/tmp, the file dialog will change to /var/tmp after entering /usr/tmp. The options argument holds various options about how to run the dialog, see the QFileDialog::Option enum for more information on the flags you can pass.

Warning: Do not delete parent during the execution of the dialog. If you want to do this, you should create the dialog yourself using one of the QFileDialog constructors.

See also getOpenFileName(), getSaveFileName(), and getExistingDirectory().

Upstream PySide2 reference signatures (binding differences may apply):

getOpenFileNames(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: str=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=...) -> typing.Tuple[typing.List[str], str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getOpenFileNames

getOpenFileUrl

getOpenFileUrl(parent: Any, caption: str, dir: Any, filter: str, selectedFilter: Any, options: Any, supportedSchemes: Any) -> Any

X.getOpenFileUrl(parent, caption, dir, filter, selectedFilter, options, supportedSchemes) -> PythonQt.QtCore.QUrl

Supplemental documentation: Qt 5 reference:

[static] QUrl QFileDialog::getOpenFileUrl(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QUrl \&dir \= QUrl(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options(), const QStringList \&supportedSchemes \= QStringList())

This is a convenience static function that returns an existing file selected by the user. If the user presses Cancel, it returns an empty url.

The function is used similarly to QFileDialog::getOpenFileName(). In particular parent, caption, dir, filter, selectedFilter and options are used in the exact same way.

The main difference with QFileDialog::getOpenFileName() comes from the ability offered to the user to select a remote file. That's why the return type and the type of dir is QUrl.

The supportedSchemes argument allows to restrict the type of URLs the user will be able to select. It is a way for the application to declare the protocols it will support to fetch the file content. An empty list means that no restriction is applied (the default). Supported for local files ("file" scheme) is implicit and always enabled; it is not necessary to include it in the restriction.

When possible, this static function will use the native file dialog and not a QFileDialog. On platforms which don't support selecting remote files, Qt will allow to select only local files.

This function was introduced in Qt 5.2.

See also getOpenFileName(), getOpenFileUrls(), getSaveFileUrl(), and getExistingDirectoryUrl().

Upstream PySide2 reference signatures (binding differences may apply):

getOpenFileUrl(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: PySide2.QtCore.QUrl=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=..., supportedSchemes: typing.Sequence[str]=...) -> typing.Tuple[PySide2.QtCore.QUrl, str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getOpenFileUrl

getOpenFileUrls

getOpenFileUrls(parent: Any, caption: str, dir: Any, filter: str, selectedFilter: Any, options: Any, supportedSchemes: Any) -> tuple

X.getOpenFileUrls(parent, caption, dir, filter, selectedFilter, options, supportedSchemes) -> tuple

Supplemental documentation: Qt 5 reference:

[static] QList\<QUrl> QFileDialog::getOpenFileUrls(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QUrl \&dir \= QUrl(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options(), const QStringList \&supportedSchemes \= QStringList())

This is a convenience static function that will return one or more existing files selected by the user. If the user presses Cancel, it returns an empty list.

The function is used similarly to QFileDialog::getOpenFileNames(). In particular parent, caption, dir, filter, selectedFilter and options are used in the exact same way.

The main difference with QFileDialog::getOpenFileNames() comes from the ability offered to the user to select remote files. That's why the return type and the type of dir are respectively QList\<QUrl> and QUrl.

The supportedSchemes argument allows to restrict the type of URLs the user will be able to select. It is a way for the application to declare the protocols it will support to fetch the file content. An empty list means that no restriction is applied (the default). Supported for local files ("file" scheme) is implicit and always enabled; it is not necessary to include it in the restriction.

When possible, this static function will use the native file dialog and not a QFileDialog. On platforms which don't support selecting remote files, Qt will allow to select only local files.

This function was introduced in Qt 5.2.

See also getOpenFileNames(), getOpenFileUrl(), getSaveFileUrl(), and getExistingDirectoryUrl().

Upstream PySide2 reference signatures (binding differences may apply):

getOpenFileUrls(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: PySide2.QtCore.QUrl=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=..., supportedSchemes: typing.Sequence[str]=...) -> typing.Tuple[typing.List[PySide2.QtCore.QUrl], str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getOpenFileUrls

getSaveFileName

getSaveFileName(parent: Any, caption: str, dir: str, filter: str, selectedFilter: Any, options: Any) -> str

X.getSaveFileName(parent, caption, dir, filter, selectedFilter, options) -> str

Supplemental documentation: Qt 5 reference:

[static] QString QFileDialog::getSaveFileName(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QString \&dir \= QString(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options())

This is a convenience static function that will return a file name selected by the user. The file does not have to exist.

It creates a modal file dialog with the given parent widget. If parent is not nullptr, the dialog will be shown centered over the parent widget.

QString fileName = QFileDialog::getSaveFileName(this, tr("Save File"),
                           "/home/jana/untitled.png",
                           tr("Images (*.png *.xpm *.jpg)"));

The file dialog's working directory will be set to dir. If dir includes a file name, the file will be selected. Only files that match the filter are shown. The filter selected is set to selectedFilter. The parameters dir, selectedFilter, and filter may be empty strings. Multiple filters are separated with ';;'. For instance:

"Images (*.png *.xpm *.jpg);;Text files (*.txt);;XML files (*.xml)"

The options argument holds various options about how to run the dialog, see the QFileDialog::Option enum for more information on the flags you can pass.

The default filter can be chosen by setting selectedFilter to the desired value.

The dialog's caption is set to caption. If caption is not specified, a default caption will be used.

On Windows, and macOS, this static function will use the native file dialog and not a QFileDialog.

On Windows the dialog will spin a blocking modal event loop that will not dispatch any QTimers, and if parent is not nullptr then it will position the dialog just below the parent's title bar. On macOS, with its native file dialog, the filter argument is ignored.

On Unix/X11, the normal behavior of the file dialog is to resolve and follow symlinks. For example, if /usr/tmp is a symlink to /var/tmp, the file dialog will change to /var/tmp after entering /usr/tmp. If options includes DontResolveSymlinks the file dialog will treat symlinks as regular directories.

Warning: Do not delete parent during the execution of the dialog. If you want to do this, you should create the dialog yourself using one of the QFileDialog constructors.

See also getOpenFileName(), getOpenFileNames(), and getExistingDirectory().

Upstream PySide2 reference signatures (binding differences may apply):

getSaveFileName(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: str=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=...) -> typing.Tuple[str, str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getSaveFileName

getSaveFileUrl

getSaveFileUrl(parent: Any, caption: str, dir: Any, filter: str, selectedFilter: Any, options: Any, supportedSchemes: Any) -> Any

X.getSaveFileUrl(parent, caption, dir, filter, selectedFilter, options, supportedSchemes) -> PythonQt.QtCore.QUrl

Supplemental documentation: Qt 5 reference:

[static] QUrl QFileDialog::getSaveFileUrl(QWidget *parent \= nullptr, const QString \&caption \= QString(), const QUrl \&dir \= QUrl(), const QString \&filter \= QString(), QString *selectedFilter \= nullptr, QFileDialog::Options options \= Options(), const QStringList \&supportedSchemes \= QStringList())

This is a convenience static function that returns a file selected by the user. The file does not have to exist. If the user presses Cancel, it returns an empty url.

The function is used similarly to QFileDialog::getSaveFileName(). In particular parent, caption, dir, filter, selectedFilter and options are used in the exact same way.

The main difference with QFileDialog::getSaveFileName() comes from the ability offered to the user to select a remote file. That's why the return type and the type of dir is QUrl.

The supportedSchemes argument allows to restrict the type of URLs the user will be able to select. It is a way for the application to declare the protocols it will support to save the file content. An empty list means that no restriction is applied (the default). Supported for local files ("file" scheme) is implicit and always enabled; it is not necessary to include it in the restriction.

When possible, this static function will use the native file dialog and not a QFileDialog. On platforms which don't support selecting remote files, Qt will allow to select only local files.

This function was introduced in Qt 5.2.

See also getSaveFileName(), getOpenFileUrl(), getOpenFileUrls(), and getExistingDirectoryUrl().

Upstream PySide2 reference signatures (binding differences may apply):

getSaveFileUrl(parent: typing.Optional[PySide2.QtWidgets.QWidget]=..., caption: str=..., dir: PySide2.QtCore.QUrl=..., filter: str=..., options: PySide2.QtWidgets.QFileDialog.Options=..., supportedSchemes: typing.Sequence[str]=...) -> typing.Tuple[PySide2.QtCore.QUrl, str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#getSaveFileUrl

history

history() -> tuple

X.history() -> tuple

Supplemental documentation: Qt 5 reference:

QStringList QFileDialog::history() const

Returns the browsing history of the filedialog as a list of paths.

See also setHistory().

Upstream PySide2 reference signatures (binding differences may apply):

history(self) -> typing.List[str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#history

iconProvider

iconProvider() -> Any

X.iconProvider() -> PythonQt.QtGui.QFileIconProvider

Supplemental documentation: Qt 5 reference:

QFileIconProvider *QFileDialog::iconProvider() const

Returns the icon provider used by the filedialog.

See also setIconProvider().

Upstream PySide2 reference signatures (binding differences may apply):

iconProvider(self) -> PySide2.QtWidgets.QFileIconProvider

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#iconProvider

isNameFilterDetailsVisible

isNameFilterDetailsVisible() -> bool

X.isNameFilterDetailsVisible() -> bool

Upstream PySide2 reference signatures (binding differences may apply):

isNameFilterDetailsVisible(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#isNameFilterDetailsVisible

isReadOnly

isReadOnly() -> bool

X.isReadOnly() -> bool

Upstream PySide2 reference signatures (binding differences may apply):

isReadOnly(self) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#isReadOnly

itemDelegate

itemDelegate() -> Any

X.itemDelegate() -> PythonQt.QtGui.QAbstractItemDelegate

Supplemental documentation: Qt 5 reference:

QAbstractItemDelegate *QFileDialog::itemDelegate() const

Returns the item delegate used to render the items in the views in the filedialog.

See also setItemDelegate().

Upstream PySide2 reference signatures (binding differences may apply):

itemDelegate(self) -> PySide2.QtWidgets.QAbstractItemDelegate

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#itemDelegate

labelText

labelText(label: Any) -> str

X.labelText(label) -> str

Supplemental documentation: Qt 5 reference:

QString QFileDialog::labelText(QFileDialog::DialogLabel label) const

Returns the text shown in the filedialog in the specified label.

See also setLabelText().

Upstream PySide2 reference signatures (binding differences may apply):

labelText(self, label: PySide2.QtWidgets.QFileDialog.DialogLabel) -> str

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#labelText

mimeTypeFilters

mimeTypeFilters() -> tuple

X.mimeTypeFilters() -> tuple

Supplemental documentation: Qt 5 reference:

QStringList QFileDialog::mimeTypeFilters() const

Returns the MIME type filters that are in operation on this file dialog.

This function was introduced in Qt 5.2.

See also setMimeTypeFilters().

Upstream PySide2 reference signatures (binding differences may apply):

mimeTypeFilters(self) -> typing.List[str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#mimeTypeFilters

nameFilterDetailsVisible instance-attribute

nameFilterDetailsVisible: Any

nameFilters

nameFilters() -> tuple

X.nameFilters() -> tuple

Supplemental documentation: Qt 5 reference:

QStringList QFileDialog::nameFilters() const

Returns the file type filters that are in operation on this file dialog.

This function was introduced in Qt 4.4.

See also setNameFilters().

Upstream PySide2 reference signatures (binding differences may apply):

nameFilters(self) -> typing.List[str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#nameFilters

objectNameChanged

objectNameChanged(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.objectNameChanged; argument details are not documented.

open

open() -> None

X.open()

Supplemental documentation: Qt 5 reference:

void QFileDialog::open(QObject *receiver, const char *member)

This function connects one of its signals to the slot specified by receiver and member. The specific signal depends is filesSelected() if fileMode is ExistingFiles and fileSelected() if fileMode is anything else.

The signal will be disconnected from the slot when the dialog is closed.

This function was introduced in Qt 4.5.

Upstream PySide2 reference signatures (binding differences may apply):

open(self) -> None
open(self, receiver: PySide2.QtCore.QObject, member: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#open

options instance-attribute

options: Any

Qt 5 reference:

options : Options

This property holds the various options that affect the look and feel of the dialog

By default, all options are disabled.

Options (particularly the DontUseNativeDialogs option) should be set before changing dialog properties or showing the dialog.

Setting options while the dialog is visible is not guaranteed to have an immediate effect on the dialog (depending on the option and on the platform).

Setting options after changing other properties may cause these values to have no effect.

This property was introduced in Qt 4.5.

Access functions:

QFileDialog::Options options() const
void setOptions(QFileDialog::Options options)

See also setOption() and testOption().

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#options

proxyModel

proxyModel() -> Any

X.proxyModel() -> PythonQt.QtCore.QAbstractProxyModel

Supplemental documentation: Qt 5 reference:

QAbstractProxyModel *QFileDialog::proxyModel() const

Returns the proxy model used by the file dialog. By default no proxy is set.

See also setProxyModel().

Upstream PySide2 reference signatures (binding differences may apply):

proxyModel(self) -> PySide2.QtCore.QAbstractProxyModel

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#proxyModel

rejected

rejected(*args: Any, **kwargs: Any) -> Any

Native PythonQt.QtGui.QFileDialog.rejected; argument details are not documented.

resolveSymlinks: bool

restoreState

restoreState(state: Any) -> bool

X.restoreState(state) -> bool

Supplemental documentation: Qt 5 reference:

bool QFileDialog::restoreState(const QByteArray \&state)

Restores the dialogs's layout, history and current directory to the state specified.

Typically this is used in conjunction with QSettings to restore the size from a past session.

Returns false if there are errors

This function was introduced in Qt 4.3.

Upstream PySide2 reference signatures (binding differences may apply):

restoreState(self, state: PySide2.QtCore.QByteArray) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#restoreState

saveState

saveState() -> Any

X.saveState() -> PythonQt.QtCore.QByteArray

Supplemental documentation: Qt 5 reference:

QByteArray QFileDialog::saveState() const

Saves the state of the dialog's layout, history and current directory.

Typically this is used in conjunction with QSettings to remember the size for a future session. A version number is stored as part of the data.

This function was introduced in Qt 4.3.

Upstream PySide2 reference signatures (binding differences may apply):

saveState(self) -> PySide2.QtCore.QByteArray

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#saveState

selectFile

selectFile(filename: str) -> None

X.selectFile(filename)

Supplemental documentation: Qt 5 reference:

void QFileDialog::selectFile(const QString \&filename)

Selects the given filename in the file dialog.

See also selectedFiles().

Upstream PySide2 reference signatures (binding differences may apply):

selectFile(self, filename: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectFile

selectMimeTypeFilter

selectMimeTypeFilter(filter: str) -> None

X.selectMimeTypeFilter(filter)

Supplemental documentation: Qt 5 reference:

void QFileDialog::selectMimeTypeFilter(const QString \&filter)

Sets the current MIME type filter.

This function was introduced in Qt 5.2.

Upstream PySide2 reference signatures (binding differences may apply):

selectMimeTypeFilter(self, filter: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectMimeTypeFilter

selectNameFilter

selectNameFilter(filter: str) -> None

X.selectNameFilter(filter)

Supplemental documentation: Qt 5 reference:

void QFileDialog::selectNameFilter(const QString \&filter)

Sets the current file type filter. Multiple filters can be passed in filter by separating them with semicolons or spaces.

This function was introduced in Qt 4.4.

See also setNameFilter(), setNameFilters(), and selectedNameFilter().

Upstream PySide2 reference signatures (binding differences may apply):

selectNameFilter(self, filter: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectNameFilter

selectUrl

selectUrl(url: Any) -> None

X.selectUrl(url)

Supplemental documentation: Qt 5 reference:

void QFileDialog::selectUrl(const QUrl \&url)

Selects the given url in the file dialog.

Note: The non-native QFileDialog supports only local files.

This function was introduced in Qt 5.2.

See also selectedUrls().

Upstream PySide2 reference signatures (binding differences may apply):

selectUrl(self, url: PySide2.QtCore.QUrl) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectUrl

selectedFiles

selectedFiles() -> tuple

X.selectedFiles() -> tuple

Supplemental documentation: Qt 5 reference:

QStringList QFileDialog::selectedFiles() const

Returns a list of strings containing the absolute paths of the selected files in the dialog. If no files are selected, or the mode is not ExistingFiles or ExistingFile, selectedFiles() contains the current path in the viewport.

See also selectedNameFilter() and selectFile().

Upstream PySide2 reference signatures (binding differences may apply):

selectedFiles(self) -> typing.List[str]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectedFiles

selectedNameFilter

selectedNameFilter() -> str

X.selectedNameFilter() -> str

Supplemental documentation: Qt 5 reference:

QString QFileDialog::selectedNameFilter() const

Returns the filter that the user selected in the file dialog.

This function was introduced in Qt 4.4.

See also selectedFiles().

Upstream PySide2 reference signatures (binding differences may apply):

selectedNameFilter(self) -> str

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectedNameFilter

selectedUrls

selectedUrls() -> tuple

X.selectedUrls() -> tuple

Supplemental documentation: Qt 5 reference:

QList\<QUrl> QFileDialog::selectedUrls() const

Returns a list of urls containing the selected files in the dialog. If no files are selected, or the mode is not ExistingFiles or ExistingFile, selectedUrls() contains the current path in the viewport.

This function was introduced in Qt 5.2.

See also selectedNameFilter() and selectUrl().

Upstream PySide2 reference signatures (binding differences may apply):

selectedUrls(self) -> typing.List[PySide2.QtCore.QUrl]

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#selectedUrls

setAcceptMode

setAcceptMode(mode: Any) -> None

X.setAcceptMode(mode)

Upstream PySide2 reference signatures (binding differences may apply):

setAcceptMode(self, mode: PySide2.QtWidgets.QFileDialog.AcceptMode) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#setAcceptMode

setConfirmOverwrite

setConfirmOverwrite(enabled: bool) -> None

X.setConfirmOverwrite(enabled)

Upstream PySide2 reference signatures (binding differences may apply):

setConfirmOverwrite(self, enabled: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qfiledialog.html#setConfirmOverwrite