KLayout 0.29.8 (2024-11-26 926dac96c) [master]

API reference - Class QStandardPaths

Notation used in Ruby API documentation

Module: QtCore

Description: Binding of QStandardPaths

Sub-classes: LocateOption, QFlags_LocateOption, StandardLocation, QFlags_StandardLocation

Public constructors

new QStandardPaths ptrnewCreates a new object of this class

Public methods

[const]QStandardPaths ptr_const_castReturns a non-const reference to self.
void_createEnsures the C++ object is created
[const]bool_destroyed?Returns a value indicating whether the object was already destroyed
[const]bool_is_const_object?Returns a value indicating whether the reference is a const reference
void_manageMarks the object as managed by the script side.
void_unmanageMarks the object as no longer owned by the script side.

Public static methods and constants

[static,const]QStandardPaths_StandardLocationAppConfigLocationEnum constant QStandardPaths::AppConfigLocation
[static,const]QStandardPaths_StandardLocationAppDataLocationEnum constant QStandardPaths::AppDataLocation
[static,const]QStandardPaths_StandardLocationAppLocalDataLocationEnum constant QStandardPaths::AppLocalDataLocation
[static,const]QStandardPaths_StandardLocationApplicationsLocationEnum constant QStandardPaths::ApplicationsLocation
[static,const]QStandardPaths_StandardLocationCacheLocationEnum constant QStandardPaths::CacheLocation
[static,const]QStandardPaths_StandardLocationConfigLocationEnum constant QStandardPaths::ConfigLocation
[static,const]QStandardPaths_StandardLocationDataLocationEnum constant QStandardPaths::DataLocation
[static,const]QStandardPaths_StandardLocationDesktopLocationEnum constant QStandardPaths::DesktopLocation
[static,const]QStandardPaths_StandardLocationDocumentsLocationEnum constant QStandardPaths::DocumentsLocation
[static,const]QStandardPaths_StandardLocationDownloadLocationEnum constant QStandardPaths::DownloadLocation
[static,const]QStandardPaths_StandardLocationFontsLocationEnum constant QStandardPaths::FontsLocation
[static,const]QStandardPaths_StandardLocationGenericCacheLocationEnum constant QStandardPaths::GenericCacheLocation
[static,const]QStandardPaths_StandardLocationGenericConfigLocationEnum constant QStandardPaths::GenericConfigLocation
[static,const]QStandardPaths_StandardLocationGenericDataLocationEnum constant QStandardPaths::GenericDataLocation
[static,const]QStandardPaths_StandardLocationHomeLocationEnum constant QStandardPaths::HomeLocation
[static,const]QStandardPaths_LocateOptionLocateDirectoryEnum constant QStandardPaths::LocateDirectory
[static,const]QStandardPaths_LocateOptionLocateFileEnum constant QStandardPaths::LocateFile
[static,const]QStandardPaths_StandardLocationMoviesLocationEnum constant QStandardPaths::MoviesLocation
[static,const]QStandardPaths_StandardLocationMusicLocationEnum constant QStandardPaths::MusicLocation
[static,const]QStandardPaths_StandardLocationPicturesLocationEnum constant QStandardPaths::PicturesLocation
[static,const]QStandardPaths_StandardLocationRuntimeLocationEnum constant QStandardPaths::RuntimeLocation
[static,const]QStandardPaths_StandardLocationTempLocationEnum constant QStandardPaths::TempLocation
stringdisplayName(const QStandardPaths_StandardLocation type)Static method QString QStandardPaths::displayName(QStandardPaths::StandardLocation type)
voidenableTestMode(bool testMode)Static method void QStandardPaths::enableTestMode(bool testMode)
stringfindExecutable(string executableName,
string[] paths = QStringList())
Static method QString QStandardPaths::findExecutable(const QString &executableName, const QStringList &paths)
boolisTestModeEnabled?Static method bool QStandardPaths::isTestModeEnabled()
stringlocate(const QStandardPaths_StandardLocation type,
string fileName,
QStandardPaths_QFlags_LocateOption options = QStandardPaths::LocateFile)
Static method QString QStandardPaths::locate(QStandardPaths::StandardLocation type, const QString &fileName, QFlags<QStandardPaths::LocateOption> options)
string[]locateAll(const QStandardPaths_StandardLocation type,
string fileName,
QStandardPaths_QFlags_LocateOption options = QStandardPaths::LocateFile)
Static method QStringList QStandardPaths::locateAll(QStandardPaths::StandardLocation type, const QString &fileName, QFlags<QStandardPaths::LocateOption> options)
voidsetTestModeEnabled(bool testMode)Static method void QStandardPaths::setTestModeEnabled(bool testMode)
string[]standardLocations(const QStandardPaths_StandardLocation type)Static method QStringList QStandardPaths::standardLocations(QStandardPaths::StandardLocation type)
booltestModeEnabledStatic method bool QStandardPaths::isTestModeEnabled()
voidtestModeEnabled=(bool testMode)Static method void QStandardPaths::setTestModeEnabled(bool testMode)
stringwritableLocation(const QStandardPaths_StandardLocation type)Static method QString QStandardPaths::writableLocation(QStandardPaths::StandardLocation type)

Deprecated methods (protected, public, static, non-static and constructors)

voidcreateUse of this method is deprecated. Use _create instead
[const]booldestroyed?Use of this method is deprecated. Use _destroyed? instead
[const]boolis_const_object?Use of this method is deprecated. Use _is_const_object? instead

Detailed description

AppConfigLocation

Signature: [static,const] QStandardPaths_StandardLocation AppConfigLocation

Description: Enum constant QStandardPaths::AppConfigLocation

Python specific notes:
The object exposes a readable attribute 'AppConfigLocation'. This is the getter.

AppDataLocation

Signature: [static,const] QStandardPaths_StandardLocation AppDataLocation

Description: Enum constant QStandardPaths::AppDataLocation

Python specific notes:
The object exposes a readable attribute 'AppDataLocation'. This is the getter.

AppLocalDataLocation

Signature: [static,const] QStandardPaths_StandardLocation AppLocalDataLocation

Description: Enum constant QStandardPaths::AppLocalDataLocation

Python specific notes:
The object exposes a readable attribute 'AppLocalDataLocation'. This is the getter.

ApplicationsLocation

Signature: [static,const] QStandardPaths_StandardLocation ApplicationsLocation

Description: Enum constant QStandardPaths::ApplicationsLocation

Python specific notes:
The object exposes a readable attribute 'ApplicationsLocation'. This is the getter.

CacheLocation

Signature: [static,const] QStandardPaths_StandardLocation CacheLocation

Description: Enum constant QStandardPaths::CacheLocation

Python specific notes:
The object exposes a readable attribute 'CacheLocation'. This is the getter.

ConfigLocation

Signature: [static,const] QStandardPaths_StandardLocation ConfigLocation

Description: Enum constant QStandardPaths::ConfigLocation

Python specific notes:
The object exposes a readable attribute 'ConfigLocation'. This is the getter.

DataLocation

Signature: [static,const] QStandardPaths_StandardLocation DataLocation

Description: Enum constant QStandardPaths::DataLocation

Python specific notes:
The object exposes a readable attribute 'DataLocation'. This is the getter.

DesktopLocation

Signature: [static,const] QStandardPaths_StandardLocation DesktopLocation

Description: Enum constant QStandardPaths::DesktopLocation

Python specific notes:
The object exposes a readable attribute 'DesktopLocation'. This is the getter.

DocumentsLocation

Signature: [static,const] QStandardPaths_StandardLocation DocumentsLocation

Description: Enum constant QStandardPaths::DocumentsLocation

Python specific notes:
The object exposes a readable attribute 'DocumentsLocation'. This is the getter.

DownloadLocation

Signature: [static,const] QStandardPaths_StandardLocation DownloadLocation

Description: Enum constant QStandardPaths::DownloadLocation

Python specific notes:
The object exposes a readable attribute 'DownloadLocation'. This is the getter.

FontsLocation

Signature: [static,const] QStandardPaths_StandardLocation FontsLocation

Description: Enum constant QStandardPaths::FontsLocation

Python specific notes:
The object exposes a readable attribute 'FontsLocation'. This is the getter.

GenericCacheLocation

Signature: [static,const] QStandardPaths_StandardLocation GenericCacheLocation

Description: Enum constant QStandardPaths::GenericCacheLocation

Python specific notes:
The object exposes a readable attribute 'GenericCacheLocation'. This is the getter.

GenericConfigLocation

Signature: [static,const] QStandardPaths_StandardLocation GenericConfigLocation

Description: Enum constant QStandardPaths::GenericConfigLocation

Python specific notes:
The object exposes a readable attribute 'GenericConfigLocation'. This is the getter.

GenericDataLocation

Signature: [static,const] QStandardPaths_StandardLocation GenericDataLocation

Description: Enum constant QStandardPaths::GenericDataLocation

Python specific notes:
The object exposes a readable attribute 'GenericDataLocation'. This is the getter.

HomeLocation

Signature: [static,const] QStandardPaths_StandardLocation HomeLocation

Description: Enum constant QStandardPaths::HomeLocation

Python specific notes:
The object exposes a readable attribute 'HomeLocation'. This is the getter.

LocateDirectory

Signature: [static,const] QStandardPaths_LocateOption LocateDirectory

Description: Enum constant QStandardPaths::LocateDirectory

Python specific notes:
The object exposes a readable attribute 'LocateDirectory'. This is the getter.

LocateFile

Signature: [static,const] QStandardPaths_LocateOption LocateFile

Description: Enum constant QStandardPaths::LocateFile

Python specific notes:
The object exposes a readable attribute 'LocateFile'. This is the getter.

MoviesLocation

Signature: [static,const] QStandardPaths_StandardLocation MoviesLocation

Description: Enum constant QStandardPaths::MoviesLocation

Python specific notes:
The object exposes a readable attribute 'MoviesLocation'. This is the getter.

MusicLocation

Signature: [static,const] QStandardPaths_StandardLocation MusicLocation

Description: Enum constant QStandardPaths::MusicLocation

Python specific notes:
The object exposes a readable attribute 'MusicLocation'. This is the getter.

PicturesLocation

Signature: [static,const] QStandardPaths_StandardLocation PicturesLocation

Description: Enum constant QStandardPaths::PicturesLocation

Python specific notes:
The object exposes a readable attribute 'PicturesLocation'. This is the getter.

RuntimeLocation

Signature: [static,const] QStandardPaths_StandardLocation RuntimeLocation

Description: Enum constant QStandardPaths::RuntimeLocation

Python specific notes:
The object exposes a readable attribute 'RuntimeLocation'. This is the getter.

TempLocation

Signature: [static,const] QStandardPaths_StandardLocation TempLocation

Description: Enum constant QStandardPaths::TempLocation

Python specific notes:
The object exposes a readable attribute 'TempLocation'. This is the getter.

_const_cast

Signature: [const] QStandardPaths ptr _const_cast

Description: Returns a non-const reference to self.

Basically, this method allows turning a const object reference to a non-const one. This method is provided as last resort to remove the constness from an object. Usually there is a good reason for a const object reference, so using this method may have undesired side effects.

This method has been introduced in version 0.29.6.

_create

Signature: void _create

Description: Ensures the C++ object is created

Use this method to ensure the C++ object is created, for example to ensure that resources are allocated. Usually C++ objects are created on demand and not necessarily when the script object is created.

_destroyed?

Signature: [const] bool _destroyed?

Description: Returns a value indicating whether the object was already destroyed

This method returns true, if the object was destroyed, either explicitly or by the C++ side. The latter may happen, if the object is owned by a C++ object which got destroyed itself.

_is_const_object?

Signature: [const] bool _is_const_object?

Description: Returns a value indicating whether the reference is a const reference

This method returns true, if self is a const reference. In that case, only const methods may be called on self.

_manage

Signature: void _manage

Description: Marks the object as managed by the script side.

After calling this method on an object, the script side will be responsible for the management of the object. This method may be called if an object is returned from a C++ function and the object is known not to be owned by any C++ instance. If necessary, the script side may delete the object if the script's reference is no longer required.

Usually it's not required to call this method. It has been introduced in version 0.24.

_unmanage

Signature: void _unmanage

Description: Marks the object as no longer owned by the script side.

Calling this method will make this object no longer owned by the script's memory management. Instead, the object must be managed in some other way. Usually this method may be called if it is known that some C++ object holds and manages this object. Technically speaking, this method will turn the script's reference into a weak reference. After the script engine decides to delete the reference, the object itself will still exist. If the object is not managed otherwise, memory leaks will occur.

Usually it's not required to call this method. It has been introduced in version 0.24.

create

Signature: void create

Description: Ensures the C++ object is created

Use of this method is deprecated. Use _create instead

Use this method to ensure the C++ object is created, for example to ensure that resources are allocated. Usually C++ objects are created on demand and not necessarily when the script object is created.

destroyed?

Signature: [const] bool destroyed?

Description: Returns a value indicating whether the object was already destroyed

Use of this method is deprecated. Use _destroyed? instead

This method returns true, if the object was destroyed, either explicitly or by the C++ side. The latter may happen, if the object is owned by a C++ object which got destroyed itself.

displayName

Signature: [static] string displayName (const QStandardPaths_StandardLocation type)

Description: Static method QString QStandardPaths::displayName(QStandardPaths::StandardLocation type)

This method is static and can be called without an instance.

enableTestMode

Signature: [static] void enableTestMode (bool testMode)

Description: Static method void QStandardPaths::enableTestMode(bool testMode)

This method is static and can be called without an instance.

findExecutable

Signature: [static] string findExecutable (string executableName, string[] paths = QStringList())

Description: Static method QString QStandardPaths::findExecutable(const QString &executableName, const QStringList &paths)

This method is static and can be called without an instance.

isTestModeEnabled?

Signature: [static] bool isTestModeEnabled?

Description: Static method bool QStandardPaths::isTestModeEnabled()

This method is static and can be called without an instance.

Python specific notes:
The object exposes a readable attribute 'testModeEnabled'. This is the getter.

is_const_object?

Signature: [const] bool is_const_object?

Description: Returns a value indicating whether the reference is a const reference

Use of this method is deprecated. Use _is_const_object? instead

This method returns true, if self is a const reference. In that case, only const methods may be called on self.

locate

Signature: [static] string locate (const QStandardPaths_StandardLocation type, string fileName, QStandardPaths_QFlags_LocateOption options = QStandardPaths::LocateFile)

Description: Static method QString QStandardPaths::locate(QStandardPaths::StandardLocation type, const QString &fileName, QFlags<QStandardPaths::LocateOption> options)

This method is static and can be called without an instance.

locateAll

Signature: [static] string[] locateAll (const QStandardPaths_StandardLocation type, string fileName, QStandardPaths_QFlags_LocateOption options = QStandardPaths::LocateFile)

Description: Static method QStringList QStandardPaths::locateAll(QStandardPaths::StandardLocation type, const QString &fileName, QFlags<QStandardPaths::LocateOption> options)

This method is static and can be called without an instance.

new

Signature: [static] new QStandardPaths ptr new

Description: Creates a new object of this class

Python specific notes:
This method is the default initializer of the object.

setTestModeEnabled

Signature: [static] void setTestModeEnabled (bool testMode)

Description: Static method void QStandardPaths::setTestModeEnabled(bool testMode)

This method is static and can be called without an instance.

Python specific notes:
The object exposes a writable attribute 'testModeEnabled'. This is the setter.

standardLocations

Signature: [static] string[] standardLocations (const QStandardPaths_StandardLocation type)

Description: Static method QStringList QStandardPaths::standardLocations(QStandardPaths::StandardLocation type)

This method is static and can be called without an instance.

testModeEnabled

Signature: [static] bool testModeEnabled

Description: Static method bool QStandardPaths::isTestModeEnabled()

This method is static and can be called without an instance.

Python specific notes:
The object exposes a readable attribute 'testModeEnabled'. This is the getter.

testModeEnabled=

Signature: [static] void testModeEnabled= (bool testMode)

Description: Static method void QStandardPaths::setTestModeEnabled(bool testMode)

This method is static and can be called without an instance.

Python specific notes:
The object exposes a writable attribute 'testModeEnabled'. This is the setter.

writableLocation

Signature: [static] string writableLocation (const QStandardPaths_StandardLocation type)

Description: Static method QString QStandardPaths::writableLocation(QStandardPaths::StandardLocation type)

This method is static and can be called without an instance.