Skip to content

Interface: ILeaferImage

Implemented by

Table of contents

Properties

Methods

Properties

innerId

Readonly innerId: number

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:31


url

Readonly url: string

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:32


view

view: unknown

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:34


width

width: number

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:35


height

height: number

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:36


isSVG

isSVG: boolean

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:38


hasOpacityPixel

hasOpacityPixel: boolean

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:39


completed

Readonly completed: boolean

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:41


ready

ready: boolean

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:42


error

error: IObject

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:43


loading

loading: boolean

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:44


use

use: number

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:46


config

config: ILeaferImageConfig

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:47

Methods

load

load(onSuccess?, onError?): number

Parameters

NameType
onSuccess?ILeaferImageOnLoaded
onError?ILeaferImageOnError

Returns

number

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:49


unload

unload(index, stopEvent?): void

Parameters

NameType
indexnumber
stopEvent?boolean

Returns

void

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:50


getCanvas

getCanvas(width, height, opacity?, _filters?): unknown

Parameters

NameType
widthnumber
heightnumber
opacity?number
_filters?IObject

Returns

unknown

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:51


getPattern

getPattern(canvas, repeat, transform?, paint?): CanvasPattern

Parameters

NameType
canvasany
repeatstring
transform?IMatrixData
paint?IObject

Returns

CanvasPattern

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:52


destroy

destroy(): void

Returns

void

Defined in

leafer/packages/interface/src/image/ILeaferImage.ts:53

Released under the MIT License.