Skip to content

PythonQt.QtCore.QCoreApplication · declarations 002

Back to PythonQt.QtCore.QCoreApplication

setApplicationName

setApplicationName(application: str) -> None

X.setApplicationName(application)

Upstream PySide2 reference signatures (binding differences may apply):

setApplicationName(application: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setApplicationName

setApplicationVersion

setApplicationVersion(version: str) -> None

X.setApplicationVersion(version)

Upstream PySide2 reference signatures (binding differences may apply):

setApplicationVersion(version: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setApplicationVersion

setAttribute

setAttribute(attribute: Any, on: bool) -> None

X.setAttribute(attribute, on)

Supplemental documentation: Qt 5 reference:

[static] void QCoreApplication::setAttribute(Qt::ApplicationAttribute attribute, bool on \= true)

Sets the attribute attribute if on is true; otherwise clears the attribute.

Note: Some application attributes must be set before creating a QCoreApplication instance. Refer to the Qt::ApplicationAttribute documentation for more information.

See also testAttribute().

Upstream PySide2 reference signatures (binding differences may apply):

setAttribute(attribute: PySide2.QtCore.Qt.ApplicationAttribute, on: bool=...) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setAttribute

setEventDispatcher

setEventDispatcher(eventDispatcher: Any) -> None

X.setEventDispatcher(eventDispatcher)

Supplemental documentation: Qt 5 reference:

[static] void QCoreApplication::setEventDispatcher(QAbstractEventDispatcher *eventDispatcher)

Sets the event dispatcher for the main thread to eventDispatcher. This is only possible as long as there is no event dispatcher installed yet. That is, before QCoreApplication has been instantiated. This method takes ownership of the object.

See also eventDispatcher().

Upstream PySide2 reference signatures (binding differences may apply):

setEventDispatcher(eventDispatcher: PySide2.QtCore.QAbstractEventDispatcher) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setEventDispatcher

setLibraryPaths

setLibraryPaths(arg__1: Any) -> None

X.setLibraryPaths(arg__1)

Supplemental documentation: Qt 5 reference:

[static] void QCoreApplication::setLibraryPaths(const QStringList \&paths)

Sets the list of directories to search when loading plugins with QLibrary to paths. All existing paths will be deleted and the path list will consist of the paths given in paths and the path to the application.

The library paths are reset to the default when an instance of QCoreApplication is destructed.

See also libraryPaths(), addLibraryPath(), removeLibraryPath(), and QLibrary.

Upstream PySide2 reference signatures (binding differences may apply):

setLibraryPaths(arg__1: typing.Sequence[str]) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setLibraryPaths

setOrganizationDomain

setOrganizationDomain(orgDomain: str) -> None

X.setOrganizationDomain(orgDomain)

Upstream PySide2 reference signatures (binding differences may apply):

setOrganizationDomain(orgDomain: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setOrganizationDomain

setOrganizationName

setOrganizationName(orgName: str) -> None

X.setOrganizationName(orgName)

Upstream PySide2 reference signatures (binding differences may apply):

setOrganizationName(orgName: str) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setOrganizationName

setQuitLockEnabled

setQuitLockEnabled(enabled: bool) -> None

X.setQuitLockEnabled(enabled)

Upstream PySide2 reference signatures (binding differences may apply):

setQuitLockEnabled(enabled: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setQuitLockEnabled

setSetuidAllowed

setSetuidAllowed(allow: bool) -> None

X.setSetuidAllowed(allow)

Supplemental documentation: Qt 5 reference:

[static] void QCoreApplication::setSetuidAllowed(bool allow)

Allows the application to run setuid on UNIX platforms if allow is true.

If allow is false (the default) and Qt detects the application is running with an effective user id different than the real user id, the application will be aborted when a QCoreApplication instance is created.

Qt is not an appropriate solution for setuid programs due to its large attack surface. However some applications may be required to run in this manner for historical reasons. This flag will prevent Qt from aborting the application when this is detected, and must be set before a QCoreApplication instance is created.

Note: It is strongly recommended not to enable this option since it introduces security risks.

This function was introduced in Qt 5.3.

See also isSetuidAllowed().

Upstream PySide2 reference signatures (binding differences may apply):

setSetuidAllowed(allow: bool) -> None

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#setSetuidAllowed

startingUp

startingUp() -> bool

X.startingUp() -> bool

Supplemental documentation: Qt 5 reference:

[static] bool QCoreApplication::startingUp()

Returns true if an application object has not been created yet; otherwise returns false.

See also closingDown().

Upstream PySide2 reference signatures (binding differences may apply):

startingUp() -> bool

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#startingUp

testAttribute

testAttribute(attribute: Any) -> bool

X.testAttribute(attribute) -> bool

Supplemental documentation: Qt 5 reference:

[static] bool QCoreApplication::testAttribute(Qt::ApplicationAttribute attribute)

Returns true if attribute attribute is set; otherwise returns false.

See also setAttribute().

Upstream PySide2 reference signatures (binding differences may apply):

testAttribute(attribute: PySide2.QtCore.Qt.ApplicationAttribute) -> bool

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#testAttribute

translate

translate(context: str, key: str, disambiguation: Any, n: int) -> str

X.translate(context, key, disambiguation, n) -> str

Supplemental documentation: Qt 5 reference:

[static] QString QCoreApplication::translate(const char *context, const char *sourceText, const char *disambiguation \= nullptr, int n \= -1)

Returns the translation text for sourceText, by querying the installed translation files. The translation files are searched from the most recently installed file back to the first installed file.

QObject::tr() provides this functionality more conveniently.

context is typically a class name (e.g., "MyDialog") and sourceText is either English text or a short identifying text.

disambiguation is an identifying string, for when the same sourceText is used in different roles within the same context. By default, it is nullptr.

See the QTranslator and QObject::tr() documentation for more information about contexts, disambiguations and comments.

n is used in conjunction with %n to support plural forms. See QObject::tr() for details.

If none of the translation files contain a translation for sourceText in context, this function returns a QString equivalent of sourceText.

This function is not virtual. You can use alternative translation techniques by subclassing QTranslator.

Note: This function is thread-safe.

See also QObject::tr(), installTranslator(), removeTranslator(), and translate().

Upstream PySide2 reference signatures (binding differences may apply):

translate(context: str, key: str, disambiguation: typing.Optional[str]=..., n: int=...) -> str

Source: https://doc.qt.io/archives/qt-5.15/qcoreapplication.html#translate