KDECore
kurl.h
Go to the documentation of this file.
111class KDECORE_EXPORT KUrl : public QUrl // krazy:exclude=dpointer,qclasses (krazy can't deal with embedded classes)
546 QString encodedPathAndQuery( AdjustPathOption trailing = LeaveTrailingSlash, const EncodedPathAndQueryOptions &options = PermitEmptyPath ) const;
849 QString pathOrUrl(AdjustPathOption trailing) const; // KDE5: merge with above. Rename to toUrlOrLocalFile?
1171KDECORE_EXPORT_DEPRECATED bool urlcmp( const QString& _url1, const QString& _url2 ); // KDE5: remove, KUrl::equals is better API
1187KDECORE_EXPORT_DEPRECATED bool urlcmp( const QString& _url1, const QString& _url2, const KUrl::EqualsOptions& options ); // KDE5: remove, KUrl::equals is better API
KUrl::List is a QList that contains KUrls with a few convenience methods.
Definition kurl.h:147
@ PreferLocalUrls
When the mimedata contains both KDE-style URLs (eg: desktop:/foo) and the "most local" version of the...
Definition kurl.h:296
@ PreferKdeUrls
When the mimedata contains both KDE-style URLs (eg: desktop:/foo) and the "most local" version of the...
Definition kurl.h:303
void populateMimeData(QMimeData *mimeData, const MetaDataMap &metaData=MetaDataMap(), MimeDataFlags flags=DefaultMimeDataFlags) const
Adds URL data into the given QMimeData.
Definition kurl.cpp:1880
@ AppendTrailingSlash
tells whether the returned result should end with '/' or not.
Definition kurl.h:754
@ IgnoreTrailingSlash
Opposite of ObeyTrailingSlash (default) fileName("file:/foo/") and fileName("file:/foo") is "foo" in ...
Definition kurl.h:759
static QString encode_string_no_slash(const QString &str)
Convert unicoded string to local encoding and use %-style encoding for all common delimiters / non-as...
Definition kurl.h:1074
@ AvoidEmptyPath
If set to true then an empty path is substituted by "/" (this is the opposite of PermitEmptyPath)
Definition kurl.h:534
static QString encode_string(const QString &str)
Convert unicoded string to local encoding and use %-style encoding for all common delimiters / non-as...
Definition kurl.h:1057
@ RemoveTrailingSlash
strips a trailing '/', except when the path is already just "/".
Definition kurl.h:125
QString url(AdjustPathOption trailing=LeaveTrailingSlash) const
Returns the URL as string, with all escape sequences intact, encoded in a given charset.
Definition kurl.cpp:1035
@ SimplifyDirSeparators
if set, occurrences of consecutive directory separators (e.g.
Definition kurl.h:469
EqualsOption
Flags to be used in URL comparison functions like equals, or urlcmp.
Definition kurl.h:906
@ AllowEmptyPath
Treat a URL with no path as equal to a URL with a path of "/", when CompareWithoutTrailingSlash is se...
Definition kurl.h:931
static QString decode_string(const QString &str)
Decode %-style encoding and convert from local encoding to unicode.
Definition kurl.h:1090
Definition kaboutdata.h:33
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Tue Mar 25 2025 00:00:00 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.