nodeguy/website/docs/api/generated/classes/qgraphicseffect.md
2020-06-09 19:37:29 +02:00

6.9 KiB
Raw Permalink Blame History

id title sidebar_label
qgraphicseffect QGraphicsEffect QGraphicsEffect

This is the abstract base class of graphicseffect, providing their functionality.

This class is a JS wrapper around Qt's QGraphicsEffect class

The QGraphicsEffect class is an abstract class and therefore, technically, no further instances actually have to be created. It is inherited by QGraphicsBlurEffect, QGraphicsColorizeEffect, QGraphicsDropShadowEffect, and QGraphicsOpacityEffect.

Type parameters

Signals: QGraphicsEffectSignals

Hierarchy

NodeObjectSignals

QGraphicsEffect

QGraphicsBlurEffect

QGraphicsDropShadowEffect

Index

Constructors

Properties

Methods

Constructors

constructor

+ new QGraphicsEffect(native: NativeElement): QGraphicsEffect

Inherited from EventWidget.constructor

Overrides Component.constructor

Parameters:

Name Type
native NativeElement

Returns: QGraphicsEffect

Properties

Abstract native

native: NativeElement

Inherited from Component.native


nodeChildren

nodeChildren: SetComponent

Inherited from Component.nodeChildren


Optional nodeParent

nodeParent? : Component

Inherited from Component.nodeParent

Methods

addEventListener

addEventListenerSignalType(signalType: SignalType, callback: Signals[SignalType]): void

Inherited from EventWidget.addEventListener

Type parameters:

SignalType: keyof Signals

Parameters:

Name Type Description
signalType SignalType SignalType is a signal from the widgets signals interface.
callback Signals[SignalType] Corresponding callback for the signal as mentioned in the widget's signal interface

Returns: void

void

For example in the case of QPushButton:

const button = new QPushButton();
button.addEventListener('clicked',(checked)=>console.log("clicked"));
// here clicked is a value from QPushButtonSignals interface

addEventListener(eventType: WidgetEventTypes, callback: function): void

Inherited from EventWidget.addEventListener

Parameters:

eventType: WidgetEventTypes

callback: function

For example in the case of QPushButton:

const button = new QPushButton();
button.addEventListener(WidgetEventTypes.HoverEnter,()=>console.log("hovered"));

▸ (event?: NativeRawPointer"QEvent"): void

Parameters:

Name Type
event? NativeRawPointer"QEvent"

Returns: void


inherits

inherits(className: string): boolean

Inherited from NodeObject.inherits

Parameters:

Name Type
className string

Returns: boolean


isEnabled

isEnabled(): boolean

Returns: boolean


objectName

objectName(): string

Inherited from NodeObject.objectName

Returns: string


property

property(name: string): QVariant

Inherited from NodeObject.property

Parameters:

Name Type
name string

Returns: QVariant


removeEventListener

removeEventListenerSignalType(signalType: SignalType, callback: Signals[SignalType]): void

Inherited from EventWidget.removeEventListener

Type parameters:

SignalType: keyof Signals

Parameters:

Name Type
signalType SignalType
callback Signals[SignalType]

Returns: void

removeEventListener(eventType: WidgetEventTypes, callback: function): void

Inherited from EventWidget.removeEventListener

Parameters:

eventType: WidgetEventTypes

callback: function

▸ (event?: NativeRawPointer"QEvent"): void

Parameters:

Name Type
event? NativeRawPointer"QEvent"

Returns: void


setEnabled

setEnabled(enable: boolean): void

Parameters:

Name Type
enable boolean

Returns: void


setNodeParent

setNodeParent(parent?: Component): void

Inherited from Component.setNodeParent

Parameters:

Name Type
parent? Component

Returns: void


setObjectName

setObjectName(objectName: string): void

Inherited from NodeObject.setObjectName

Parameters:

Name Type
objectName string

Returns: void


setProperty

setProperty(name: string, value: QVariantType): boolean

Inherited from NodeObject.setProperty

Parameters:

Name Type
name string
value QVariantType

Returns: boolean