KEncodingFileDialog Class Reference
from PyKDE4.kio import *
Inherits: KFileDialog → KDialog → QDialog → QWidget → QObject
Detailed Description
Provides a user (and developer) friendly way to select files with support for choosing encoding
The dialog has been designed to allow applications to customize it by subclassing. It uses geometry management to ensure that subclasses can easily add children that will be incorporated into the layout.
Methods | |
__init__ (self, QString startDir=QString(), QString encoding=QString(), QString filter=QString(), QString caption=QString(), KFileDialog.OperationMode type=KFileDialog.Opening, QWidget parent=0) | |
QString | selectedEncoding (self) |
Static Methods | |
KEncodingFileDialog.Result | getOpenFileNameAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
KEncodingFileDialog.Result | getOpenFileNamesAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
KEncodingFileDialog.Result | getOpenUrlAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
KEncodingFileDialog.Result | getOpenUrlsAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
KEncodingFileDialog.Result | getSaveFileNameAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
KEncodingFileDialog.Result | getSaveUrlAndEncoding (QString encoding=QString(), QString startDir=QString(), QString filter=QString(), QWidget parent=0, QString caption=QString()) |
Method Documentation
KEncodingFileDialog.Result getOpenFileNameAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and return the selected filename or an empty string if none was chosen additionally a chosen encoding value is returned.
Note that with this method the user must select an existing filename.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
KEncodingFileDialog.Result getOpenFileNamesAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and returns the selected encoding and the selected filenames or an empty list if none was chosen.
Note that with this method the user must select an existing filename.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
KEncodingFileDialog.Result getOpenUrlAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and returns the selected encoding and URL or an empty string if none was chosen.
Note that with this method the user must select an existing URL.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
KEncodingFileDialog.Result getOpenUrlsAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and returns the selected encoding URLs or an empty list if none was chosen.
Note that with this method the user must select an existing filename.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
KEncodingFileDialog.Result getSaveFileNameAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and returns the selected encoding and filename or an empty string if none was chosen.
Note that with this method the user need not select an existing filename.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
KEncodingFileDialog.Result getSaveUrlAndEncoding | ( | QString | encoding=QString(), | |
QString | startDir=QString(), | |||
QString | filter=QString(), | |||
QWidget | parent=0, | |||
QString | caption=QString() | |||
) |
Creates a modal file dialog and returns the selected encoding and filename or an empty string if none was chosen.
Note that with this method the user need not select an existing filename.
- Parameters:
-
encoding The encoding shown in the encoding combo. startDir This can either be
- Parameters:
-
filter A shell glob or a mime-type-filter that specifies which files to display. The preferred option is to set a list of mimetype names, see setMimeFilter() for details. Otherwise you can set the text to be displayed for the each glob, and provide multiple globs, see setFilter() for details. parent The widget the dialog will be centered on initially. caption The name of the dialog widget.
QString selectedEncoding | ( | self ) |
- Returns:
- The selected encoding if the constructor with the encoding parameter was used, otherwise QString().