API reference - Class QSoundEffect

Notation used in Ruby API documentation

Module: QtMultimedia

Description: Binding of QSoundEffect

Class hierarchy: QSoundEffect » QObject

Sub-classes: Status, QFlags_Status

Public constructors

new QSoundEffectnew(QObject ptr parent = 0)Constructor QSoundEffect::QSoundEffect(QObject *parent)

Public methods

void_createEnsures the C++ object is created
void_destroyExplicitly destroys the object
[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.
[const]stringcategoryMethod QString QSoundEffect::category()
voidcategory=(string category)Method void QSoundEffect::setCategory(const QString &category)
voidcategoryChangedMethod void QSoundEffect::categoryChanged()
boolevent(QEvent ptr arg1)Virtual method bool QSoundEffect::event(QEvent *)
booleventFilter(QObject ptr arg1,
QEvent ptr arg2)
Virtual method bool QSoundEffect::eventFilter(QObject *, QEvent *)
[const]boolisLoaded?Method bool QSoundEffect::isLoaded()
[const]boolisMuted?Method bool QSoundEffect::isMuted()
[const]boolisPlaying?Method bool QSoundEffect::isPlaying()
voidloadedChangedMethod void QSoundEffect::loadedChanged()
[const]intloopCountMethod int QSoundEffect::loopCount()
voidloopCount=(int loopCount)Method void QSoundEffect::setLoopCount(int loopCount)
voidloopCountChangedMethod void QSoundEffect::loopCountChanged()
[const]intloopsRemainingMethod int QSoundEffect::loopsRemaining()
voidloopsRemainingChangedMethod void QSoundEffect::loopsRemainingChanged()
[const]boolmutedMethod bool QSoundEffect::isMuted()
voidmuted=(bool muted)Method void QSoundEffect::setMuted(bool muted)
voidmutedChangedMethod void QSoundEffect::mutedChanged()
voidplayMethod void QSoundEffect::play()
[const]boolplayingMethod bool QSoundEffect::isPlaying()
voidplayingChangedMethod void QSoundEffect::playingChanged()
voidsetCategory(string category)Method void QSoundEffect::setCategory(const QString &category)
voidsetLoopCount(int loopCount)Method void QSoundEffect::setLoopCount(int loopCount)
voidsetMuted(bool muted)Method void QSoundEffect::setMuted(bool muted)
voidsetSource(const QUrl url)Method void QSoundEffect::setSource(const QUrl &url)
voidsetVolume(double volume)Method void QSoundEffect::setVolume(double volume)
[const]QUrlsourceMethod QUrl QSoundEffect::source()
voidsource=(const QUrl url)Method void QSoundEffect::setSource(const QUrl &url)
voidsourceChangedMethod void QSoundEffect::sourceChanged()
[const]QSoundEffect_StatusstatusMethod QSoundEffect::Status QSoundEffect::status()
voidstatusChangedMethod void QSoundEffect::statusChanged()
voidstopMethod void QSoundEffect::stop()
[const]doublevolumeMethod double QSoundEffect::volume()
voidvolume=(double volume)Method void QSoundEffect::setVolume(double volume)
voidvolumeChangedMethod void QSoundEffect::volumeChanged()

Public static methods and constants

[static,const]QSoundEffect_StatusErrorEnum constant QSoundEffect::Error
[static,const]QSoundEffect_StatusLoadingEnum constant QSoundEffect::Loading
[static,const]QSoundEffect_StatusNullEnum constant QSoundEffect::Null
[static,const]QSoundEffect_StatusReadyEnum constant QSoundEffect::Ready
QMetaObjectstaticMetaObjectObtains the static MetaObject for this class.
string[]supportedMimeTypesStatic method QStringList QSoundEffect::supportedMimeTypes()
stringtr(string s,
string c = nullptr,
int n = -1)
Static method QString QSoundEffect::tr(const char *s, const char *c, int n)
stringtrUtf8(string s,
string c = nullptr,
int n = -1)
Static method QString QSoundEffect::trUtf8(const char *s, const char *c, int n)

Protected methods (static, non-static and constructors)

voidchildEvent(QChildEvent ptr arg1)Virtual method void QSoundEffect::childEvent(QChildEvent *)
voidcustomEvent(QEvent ptr arg1)Virtual method void QSoundEffect::customEvent(QEvent *)
voiddisconnectNotify(const QMetaMethod signal)Virtual method void QSoundEffect::disconnectNotify(const QMetaMethod &signal)
[const]boolisSignalConnected(const QMetaMethod signal)Method bool QSoundEffect::isSignalConnected(const QMetaMethod &signal)
[const]intreceivers(string signal)Method int QSoundEffect::receivers(const char *signal)
[const]QObject ptrsenderMethod QObject *QSoundEffect::sender()
[const]intsenderSignalIndexMethod int QSoundEffect::senderSignalIndex()
voidtimerEvent(QTimerEvent ptr arg1)Virtual method void QSoundEffect::timerEvent(QTimerEvent *)

Detailed description

Error

Signature: [static,const] QSoundEffect_Status Error

Description: Enum constant QSoundEffect::Error

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

Loading

Signature: [static,const] QSoundEffect_Status Loading

Description: Enum constant QSoundEffect::Loading

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

Null

Signature: [static,const] QSoundEffect_Status Null

Description: Enum constant QSoundEffect::Null

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

Ready

Signature: [static,const] QSoundEffect_Status Ready

Description: Enum constant QSoundEffect::Ready

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

_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.

_destroy

Signature: void _destroy

Description: Explicitly destroys the object

Explicitly destroys the object on C++ side if it was owned by the script interpreter. Subsequent access to this object will throw an exception. If the object is not owned by the script, this method will do nothing.

_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.

category

Signature: [const] string category

Description: Method QString QSoundEffect::category()

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

category=

Signature: void category= (string category)

Description: Method void QSoundEffect::setCategory(const QString &category)

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

categoryChanged

Signature: void categoryChanged

Description: Method void QSoundEffect::categoryChanged()

childEvent

Signature: void childEvent (QChildEvent ptr arg1)

Description: Virtual method void QSoundEffect::childEvent(QChildEvent *)

This method can be reimplemented in a derived class.

customEvent

Signature: void customEvent (QEvent ptr arg1)

Description: Virtual method void QSoundEffect::customEvent(QEvent *)

This method can be reimplemented in a derived class.

disconnectNotify

Signature: void disconnectNotify (const QMetaMethod signal)

Description: Virtual method void QSoundEffect::disconnectNotify(const QMetaMethod &signal)

This method can be reimplemented in a derived class.

event

Signature: bool event (QEvent ptr arg1)

Description: Virtual method bool QSoundEffect::event(QEvent *)

This method can be reimplemented in a derived class.

eventFilter

Signature: bool eventFilter (QObject ptr arg1, QEvent ptr arg2)

Description: Virtual method bool QSoundEffect::eventFilter(QObject *, QEvent *)

This method can be reimplemented in a derived class.

isLoaded?

Signature: [const] bool isLoaded?

Description: Method bool QSoundEffect::isLoaded()

isMuted?

Signature: [const] bool isMuted?

Description: Method bool QSoundEffect::isMuted()

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

isPlaying?

Signature: [const] bool isPlaying?

Description: Method bool QSoundEffect::isPlaying()

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

isSignalConnected

Signature: [const] bool isSignalConnected (const QMetaMethod signal)

Description: Method bool QSoundEffect::isSignalConnected(const QMetaMethod &signal)

This method is protected and can only be called from inside a derived class.

loadedChanged

Signature: void loadedChanged

Description: Method void QSoundEffect::loadedChanged()

loopCount

Signature: [const] int loopCount

Description: Method int QSoundEffect::loopCount()

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

loopCount=

Signature: void loopCount= (int loopCount)

Description: Method void QSoundEffect::setLoopCount(int loopCount)

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

loopCountChanged

Signature: void loopCountChanged

Description: Method void QSoundEffect::loopCountChanged()

loopsRemaining

Signature: [const] int loopsRemaining

Description: Method int QSoundEffect::loopsRemaining()

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

loopsRemainingChanged

Signature: void loopsRemainingChanged

Description: Method void QSoundEffect::loopsRemainingChanged()

muted

Signature: [const] bool muted

Description: Method bool QSoundEffect::isMuted()

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

muted=

Signature: void muted= (bool muted)

Description: Method void QSoundEffect::setMuted(bool muted)

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

mutedChanged

Signature: void mutedChanged

Description: Method void QSoundEffect::mutedChanged()

new

Signature: [static] new QSoundEffect new (QObject ptr parent = 0)

Description: Constructor QSoundEffect::QSoundEffect(QObject *parent)

This method creates an object of class QSoundEffect.

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

play

Signature: void play

Description: Method void QSoundEffect::play()

playing

Signature: [const] bool playing

Description: Method bool QSoundEffect::isPlaying()

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

playingChanged

Signature: void playingChanged

Description: Method void QSoundEffect::playingChanged()

receivers

Signature: [const] int receivers (string signal)

Description: Method int QSoundEffect::receivers(const char *signal)

This method is protected and can only be called from inside a derived class.

sender

Signature: [const] QObject ptr sender

Description: Method QObject *QSoundEffect::sender()

This method is protected and can only be called from inside a derived class.

senderSignalIndex

Signature: [const] int senderSignalIndex

Description: Method int QSoundEffect::senderSignalIndex()

This method is protected and can only be called from inside a derived class.

setCategory

Signature: void setCategory (string category)

Description: Method void QSoundEffect::setCategory(const QString &category)

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

setLoopCount

Signature: void setLoopCount (int loopCount)

Description: Method void QSoundEffect::setLoopCount(int loopCount)

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

setMuted

Signature: void setMuted (bool muted)

Description: Method void QSoundEffect::setMuted(bool muted)

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

setSource

Signature: void setSource (const QUrl url)

Description: Method void QSoundEffect::setSource(const QUrl &url)

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

setVolume

Signature: void setVolume (double volume)

Description: Method void QSoundEffect::setVolume(double volume)

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

source

Signature: [const] QUrl source

Description: Method QUrl QSoundEffect::source()

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

source=

Signature: void source= (const QUrl url)

Description: Method void QSoundEffect::setSource(const QUrl &url)

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

sourceChanged

Signature: void sourceChanged

Description: Method void QSoundEffect::sourceChanged()

staticMetaObject

Signature: [static] QMetaObject staticMetaObject

Description: Obtains the static MetaObject for this class.

status

Signature: [const] QSoundEffect_Status status

Description: Method QSoundEffect::Status QSoundEffect::status()

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

statusChanged

Signature: void statusChanged

Description: Method void QSoundEffect::statusChanged()

stop

Signature: void stop

Description: Method void QSoundEffect::stop()

supportedMimeTypes

Signature: [static] string[] supportedMimeTypes

Description: Static method QStringList QSoundEffect::supportedMimeTypes()

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

timerEvent

Signature: void timerEvent (QTimerEvent ptr arg1)

Description: Virtual method void QSoundEffect::timerEvent(QTimerEvent *)

This method can be reimplemented in a derived class.

tr

Signature: [static] string tr (string s, string c = nullptr, int n = -1)

Description: Static method QString QSoundEffect::tr(const char *s, const char *c, int n)

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

trUtf8

Signature: [static] string trUtf8 (string s, string c = nullptr, int n = -1)

Description: Static method QString QSoundEffect::trUtf8(const char *s, const char *c, int n)

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

volume

Signature: [const] double volume

Description: Method double QSoundEffect::volume()

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

volume=

Signature: void volume= (double volume)

Description: Method void QSoundEffect::setVolume(double volume)

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

volumeChanged

Signature: void volumeChanged

Description: Method void QSoundEffect::volumeChanged()