@univerjs/engine-render v0.5.4
Class: Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:49
Extends
Constructors
new Path()
new Path(key?, props?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:63
Parameters
Parameter | Type |
---|---|
key ? | string |
props ? | IPathProps |
Returns
Overrides
Properties
Property | Modifier | Type | Default value | Inherited from | Defined in |
---|---|---|---|---|---|
_dirty | protected | boolean | true | Shape ._dirty | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:88 |
_disposed | protected | boolean | false | Shape ._disposed | packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:96 |
_forceDirty | protected | boolean | true | Shape ._forceDirty | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:89 |
_oKey | protected | string | undefined | Shape ._oKey | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:86 |
groupKey? | public | string | undefined | Shape .groupKey | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:59 |
isInGroup | public | boolean | false | Shape .isInGroup | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:60 |
objectType | public | ObjectType | ObjectType.SHAPE | Shape .objectType | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:140 |
onDblclick$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onDblclick$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:74 |
onDispose$ | public | EventSubject <BaseObject > | undefined | Shape .onDispose$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:84 |
onDragEnter$ | public | EventSubject < | IMouseEvent | IDragEvent > | undefined | Shape .onDragEnter$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:80 |
onDragLeave$ | public | EventSubject < | IMouseEvent | IDragEvent > | undefined | Shape .onDragLeave$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:78 |
onDragOver$ | public | EventSubject < | IMouseEvent | IDragEvent > | undefined | Shape .onDragOver$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:79 |
onDrop$ | public | EventSubject < | IMouseEvent | IDragEvent > | undefined | Shape .onDrop$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:81 |
onIsAddedToParent$ | public | EventSubject <any > | undefined | Shape .onIsAddedToParent$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:83 |
onMouseWheel$ | public | EventSubject <IWheelEvent > | undefined | Shape .onMouseWheel$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:76 |
onPointerDown$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerDown$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:66 |
onPointerEnter$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerEnter$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:72 |
onPointerLeave$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerLeave$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:71 |
onPointerMove$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerMove$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:67 |
onPointerOut$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerOut$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:69 |
onPointerOver$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerOver$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:70 |
onPointerUp$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onPointerUp$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:68 |
onTransformChange$ | public | EventSubject <ITransformChangeState > | undefined | Shape .onTransformChange$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:64 |
onTripleClick$ | public | EventSubject < | IMouseEvent | IPointerEvent > | undefined | Shape .onTripleClick$ | packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:75 |
Accessors
ancestorGroup
Get Signature
get ancestorGroup(): Nullable<BaseObject>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:251
Returns
Inherited from
ancestorLeft
Get Signature
get ancestorLeft(): any
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:235
Returns
any
Inherited from
ancestorScaleX
Get Signature
get ancestorScaleX(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:225
Returns
number
Inherited from
ancestorScaleY
Get Signature
get ancestorScaleY(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:230
Returns
number
Inherited from
ancestorTop
Get Signature
get ancestorTop(): any
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:239
Returns
any
Inherited from
ancestorTransform
Get Signature
get ancestorTransform(): any
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:243
Returns
any
Inherited from
angle
Get Signature
get angle(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:213
Returns
number
Set Signature
set angle(angle): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:363
Parameters
Parameter | Type |
---|---|
angle | number |
Returns
void
Inherited from
classType
Get Signature
get classType(): RENDER_CLASS_TYPE
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:189
Returns
Inherited from
cursor
Get Signature
get cursor(): CURSOR_TYPE
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:303
Returns
Set Signature
set cursor(val): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:331
Parameters
Parameter | Type |
---|---|
val | CURSOR_TYPE |
Returns
void
Inherited from
dataArray
Get Signature
get dataArray(): IPathDataArray[]
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:131
Returns
IPathDataArray
[]
debounceParentDirty
Get Signature
get debounceParentDirty(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:299
Returns
boolean
Set Signature
set debounceParentDirty(state): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:327
Parameters
Parameter | Type |
---|---|
state | boolean |
Returns
void
Inherited from
evented
Get Signature
get evented(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:291
Returns
boolean
Set Signature
set evented(state): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:323
Parameters
Parameter | Type |
---|---|
state | boolean |
Returns
void
Inherited from
fill
Get Signature
get fill(): Nullable<string | CanvasGradient>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:176
Returns
Nullable
<string
| CanvasGradient
>
Inherited from
fillAfterStrokeEnabled
Get Signature
get fillAfterStrokeEnabled(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:180
Returns
boolean
Inherited from
fillRule
Get Signature
get fillRule(): string
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:156
Returns
string
Inherited from
flipX
Get Signature
get flipX(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:271
Returns
boolean
Set Signature
set flipX(flipX): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:383
Parameters
Parameter | Type |
---|---|
flipX | boolean |
Returns
void
Inherited from
flipY
Get Signature
get flipY(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:275
Returns
boolean
Set Signature
set flipY(flipY): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:379
Parameters
Parameter | Type |
---|---|
flipY | boolean |
Returns
void
Inherited from
globalCompositeOperation
Get Signature
get globalCompositeOperation(): string
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:160
Returns
string
Inherited from
Shape
.globalCompositeOperation
height
Get Signature
get height(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:205
Returns
number
Set Signature
set height(num): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:354
Parameters
Parameter | Type |
---|---|
num | string | number |
Returns
void
Inherited from
heightOrigin
Get Signature
get heightOrigin(): string | number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:185
Returns
string
| number
Inherited from
hitStrokeWidth
Get Signature
get hitStrokeWidth(): string | number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:184
Returns
string
| number
Inherited from
hoverCursor
Get Signature
get hoverCursor(): Nullable<string>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:148
Returns
Nullable
<string
>
Inherited from
layer
Get Signature
get layer(): Nullable<Layer>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:307
Returns
Set Signature
set layer(layer): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:335
Parameters
Parameter | Type |
---|---|
layer | Layer |
Returns
void
Inherited from
left
Get Signature
get left(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:197
Returns
number
Set Signature
set left(num): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:344
Parameters
Parameter | Type |
---|---|
num | string | number |
Returns
void
Inherited from
leftOrigin
Get Signature
get leftOrigin(): string | number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:177
Returns
string
| number
Inherited from
maxZIndex
Get Signature
get maxZIndex(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:399
Returns
number
Inherited from
moveCursor
Get Signature
get moveCursor(): null | string
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:152
Returns
null
| string
Inherited from
oKey
Get Signature
get oKey(): string
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:283
Returns
string
Inherited from
paintFirst
Get Signature
get paintFirst(): PaintFirst
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:164
Returns
Inherited from
parent
Get Signature
get parent(): any
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:279
Returns
any
Set Signature
set parent(o): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:319
Parameters
Parameter | Type |
---|---|
o | any |
Returns
void
Inherited from
printable
Get Signature
get printable(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:169
Returns
boolean
Inherited from
scaleX
Get Signature
get scaleX(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:217
Returns
number
Set Signature
set scaleX(scaleX): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:367
Parameters
Parameter | Type |
---|---|
scaleX | number |
Returns
void
Inherited from
scaleY
Get Signature
get scaleY(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:221
Returns
number
Set Signature
set scaleY(scaleY): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:371
Parameters
Parameter | Type |
---|---|
scaleY | number |
Returns
void
Inherited from
shadowBlur
Get Signature
get shadowBlur(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:200
Returns
number
Inherited from
shadowColor
Get Signature
get shadowColor(): Nullable<string>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:196
Returns
Nullable
<string
>
Inherited from
shadowEnabled
Get Signature
get shadowEnabled(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:220
Returns
boolean
Inherited from
shadowForStrokeEnabled
Get Signature
get shadowForStrokeEnabled(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:224
Returns
boolean
Inherited from
shadowOffset
Get Signature
get shadowOffset(): Nullable<Vector2>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:204
Returns
Inherited from
shadowOffsetX
Get Signature
get shadowOffsetX(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:208
Returns
number
Inherited from
shadowOffsetY
Get Signature
get shadowOffsetY(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:212
Returns
number
Inherited from
shadowOpacity
Get Signature
get shadowOpacity(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:216
Returns
number
Inherited from
skewX
Get Signature
get skewX(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:263
Returns
number
Set Signature
set skewX(skewX): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:375
Parameters
Parameter | Type |
---|---|
skewX | number |
Returns
void
Inherited from
skewY
Get Signature
get skewY(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:267
Returns
number
Set Signature
set skewY(skewY): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:387
Parameters
Parameter | Type |
---|---|
skewY | number |
Returns
void
Inherited from
stroke
Get Signature
get stroke(): Nullable<string | CanvasGradient>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:168
Returns
Nullable
<string
| CanvasGradient
>
Inherited from
strokeDashArray
Get Signature
get strokeDashArray(): Nullable<number[]>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:228
Returns
Nullable
<number
[]>
Inherited from
strokeDashOffset
Get Signature
get strokeDashOffset(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:232
Returns
number
Inherited from
strokeLineCap
Get Signature
get strokeLineCap(): LineCap
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:192
Returns
Inherited from
strokeLineJoin
Get Signature
get strokeLineJoin(): LineJoin
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:188
Returns
Inherited from
strokeMiterLimit
Get Signature
get strokeMiterLimit(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:236
Returns
number
Inherited from
strokeScaleEnabled
Get Signature
get strokeScaleEnabled(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:172
Returns
boolean
Inherited from
strokeWidth
Get Signature
get strokeWidth(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:209
Returns
number
Set Signature
set strokeWidth(width): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:359
Parameters
Parameter | Type |
---|---|
width | number |
Returns
void
Inherited from
top
Get Signature
get top(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:193
Returns
number
Set Signature
set top(num): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:339
Parameters
Parameter | Type |
---|---|
num | string | number |
Returns
void
Inherited from
topOrigin
Get Signature
get topOrigin(): string | number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:173
Returns
string
| number
Inherited from
transform
Get Signature
get transform(): Transform
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:148
Returns
Set Signature
set transform(trans): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:311
Parameters
Parameter | Type |
---|---|
trans | Transform |
Returns
void
Inherited from
transformerConfig
Get Signature
get transformerConfig(): ITransformerConfig
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:391
Returns
ITransformerConfig
Set Signature
set transformerConfig(config): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:395
Parameters
Parameter | Type |
---|---|
config | ITransformerConfig |
Returns
void
Inherited from
visible
Get Signature
get visible(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:295
Returns
boolean
Inherited from
width
Get Signature
get width(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:201
Returns
number
Set Signature
set width(num): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:349
Parameters
Parameter | Type |
---|---|
num | string | number |
Returns
void
Inherited from
widthOrigin
Get Signature
get widthOrigin(): string | number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:181
Returns
string
| number
Inherited from
zIndex
Get Signature
get zIndex(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:287
Returns
number
Set Signature
set zIndex(index): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:315
Parameters
Parameter | Type |
---|---|
index | number |
Returns
void
Inherited from
Methods
_draw()
protected _draw(ctx): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:933
Parameters
Parameter | Type |
---|---|
ctx | UniverRenderingContext |
Returns
void
Overrides
_setTransForm()
protected _setTransForm(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:849
Returns
void
Inherited from
applyTransform()
applyTransform(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:837
Returns
void
Inherited from
dispose()
dispose(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:751
Returns
void
Inherited from
disposeWithMe()
disposeWithMe(disposable): IDisposable
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:99
Parameters
Parameter | Type |
---|---|
disposable | DisposableLike |
Returns
Inherited from
ensureNotDisposed()
protected ensureNotDisposed(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/core/src/shared/lifecycle.ts:103
Returns
void
Inherited from
flip()
flip(flipX?, flipY?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:522
Parameters
Parameter | Type |
---|---|
flipX ? | boolean |
flipY ? | boolean |
Returns
Inherited from
getEngine()
getEngine(): Nullable<Engine>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:815
Returns
Inherited from
getInverseCoord()
getInverseCoord(coord): Vector2
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:845
Parameters
Parameter | Type |
---|---|
coord | Vector2 |
Returns
Inherited from
getLayerIndex()
getLayerIndex(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:830
Returns
number
Inherited from
getLength()
getLength(): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:848
Return length of the path.
Returns
number
length
Method
Example
var length = path.getLength();
getObjects()
getObjects(): BaseObject[]
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:826
Returns
Inherited from
getParent()
getParent(): any
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:580
Returns
any
Inherited from
getPointAtLength()
getPointAtLength(length):
| null
| {
x: number;
y: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:860
Get point on path at specific length of the path
Parameters
Parameter | Type | Description |
---|---|---|
length | number | length |
Returns
| null
| {
x
: number
;
y
: number
;
}
point {x,y} point
Method
Example
var point = path.getPointAtLength(10);
getRect()
getRect(): {
height: number;
left: number;
top: number;
width: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:831
Returns
{
height: number;
left: number;
top: number;
width: number;
}
getScene()
getScene(): Nullable<Scene>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:794
Returns
Inherited from
getState()
getState(): {
angle: number;
flipX: boolean;
flipY: boolean;
height: number;
left: number;
scaleX: number;
scaleY: number;
skewX: number;
skewY: number;
top: number;
width: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:814
Returns
{
angle: number;
flipX: boolean;
flipY: boolean;
height: number;
left: number;
scaleX: number;
scaleY: number;
skewX: number;
skewY: number;
top: number;
width: number;
}
Overrides
hide()
hide(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:600
Returns
void
Inherited from
isDirty()
isDirty(): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:431
Returns
boolean
Inherited from
isHit()
isHit(coord): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:614
Parameters
Parameter | Type |
---|---|
coord | Vector2 |
Returns
boolean
Inherited from
isRender()
isRender(bounds?): undefined | boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:573
Parameters
Parameter | Type |
---|---|
bounds ? | IViewportInfo |
Returns
undefined
| boolean
Inherited from
makeDirty()
makeDirty(state): undefined | Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:403
Parameters
Parameter | Type | Default value |
---|---|---|
state | boolean | true |
Returns
undefined
| Path
Inherited from
makeDirtyNoDebounce()
makeDirtyNoDebounce(state): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:422
Parameters
Parameter | Type | Default value |
---|---|---|
state | boolean | true |
Returns
Inherited from
makeForceDirty()
makeForceDirty(state): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:418
Parameters
Parameter | Type | Default value |
---|---|---|
state | boolean | true |
Returns
void
Inherited from
removeTransform()
removeTransform(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:841
Returns
void
Inherited from
render()
render(mainCtx, bounds?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:319
Parameters
Parameter | Type |
---|---|
mainCtx | UniverRenderingContext |
bounds ? | IViewportInfo |
Returns
Inherited from
resetCursor()
resetCursor(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:806
Returns
void
Inherited from
resize()
resize(width?, height?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:457
Parameters
Parameter | Type |
---|---|
width ? | string | number |
height ? | string | number |
Returns
Inherited from
scale()
scale(scaleX?, scaleY?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:478
Parameters
Parameter | Type |
---|---|
scaleX ? | number |
scaleY ? | number |
Returns
Inherited from
setCursor()
setCursor(val): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:810
Parameters
Parameter | Type |
---|---|
val | CURSOR_TYPE |
Returns
void
Inherited from
setProps()
setProps(props?): Shape<IPathProps>
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:352
this[_key] = props[key]
Parameters
Parameter | Type |
---|---|
props ? | IPathProps |
Returns
Inherited from
show()
show(): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:605
Returns
void
Inherited from
skew()
skew(skewX?, skewY?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:500
Parameters
Parameter | Type |
---|---|
skewX ? | number |
skewY ? | number |
Returns
Inherited from
toJson()
toJson(): {}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:801
Returns
{}
Overrides
transformByState()
transformByState(option): undefined | Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:547
this[pKey] = option[pKey]
Parameters
Parameter | Type |
---|---|
option | IObjectFullState |
Returns
undefined
| Path
Inherited from
transformForAngle()
transformForAngle(transform): Transform
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:153
Parameters
Parameter | Type |
---|---|
transform | Transform |
Returns
Inherited from
translate()
translate(x?, y?): Path
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:435
Parameters
Parameter | Type |
---|---|
x ? | string | number |
y ? | string | number |
Returns
Inherited from
triggerDblclick()
triggerDblclick(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:651
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerDragEnter()
triggerDragEnter(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:735
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IDragEvent |
Returns
boolean
Inherited from
triggerDragLeave()
triggerDragLeave(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:719
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IDragEvent |
Returns
boolean
Inherited from
triggerDragOver()
triggerDragOver(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:727
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IDragEvent |
Returns
boolean
Inherited from
triggerDrop()
triggerDrop(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:743
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IDragEvent |
Returns
boolean
Inherited from
triggerMouseWheel()
triggerMouseWheel(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:671
Parameters
Parameter | Type |
---|---|
evt | IWheelEvent |
Returns
boolean
Inherited from
triggerPointerCancel()
triggerPointerCancel(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:711
Parameters
Parameter | Type |
---|---|
evt | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerDown()
triggerPointerDown(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:635
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerEnter()
triggerPointerEnter(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:703
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerLeave()
triggerPointerLeave(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:687
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerMove()
triggerPointerMove(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:627
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerOut()
triggerPointerOut(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:679
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerOver()
triggerPointerOver(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:695
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerPointerUp()
triggerPointerUp(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:643
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
triggerTripleClick()
triggerTripleClick(evt): boolean
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/base-object.ts:661
Parameters
Parameter | Type |
---|---|
evt | | IMouseEvent | IPointerEvent |
Returns
boolean
Inherited from
_renderPaintInOrder()
protected static _renderPaintInOrder(ctx, props): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/shape.ts:244
Parameters
Parameter | Type |
---|---|
ctx | UniverRenderingContext |
props | IShapeProps |
Returns
void
Inherited from
calcLength()
static calcLength(
x,
y,
cmd,
points): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:647
Parameters
Parameter | Type |
---|---|
x | number |
y | number |
cmd | string |
points | number [] |
Returns
number
convertEndpointToCenterParameterization()
static convertEndpointToCenterParameterization(
x1,
y1,
x2,
y2,
fa,
fs,
rx,
ry,
psiDeg): number[]
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:737
Parameters
Parameter | Type |
---|---|
x1 | number |
y1 | number |
x2 | number |
y2 | number |
fa | number |
fs | number |
rx | number |
ry | number |
psiDeg | number |
Returns
number
[]
drawWith()
static drawWith(ctx, props): void
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:135
Parameters
Parameter | Type |
---|---|
ctx | UniverRenderingContext |
props | IPathProps | Path |
Returns
void
Overrides
getLineLength()
static getLineLength(
x1,
y1,
x2,
y2): number
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:193
Parameters
Parameter | Type |
---|---|
x1 | number |
y1 | number |
x2 | number |
y2 | number |
Returns
number
getPointOnCubicBezier()
static getPointOnCubicBezier(
pct,
P1x,
P1y,
P2x,
P2y,
P3x,
P3y,
P4x,
P4y): {
x: number;
y: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:261
Parameters
Parameter | Type |
---|---|
pct | number |
P1x | number |
P1y | number |
P2x | number |
P2y | number |
P3x | number |
P3y | number |
P4x | number |
P4y | number |
Returns
{
x: number;
y: number;
}
getPointOnEllipticalArc()
static getPointOnEllipticalArc(
cx,
cy,
rx,
ry,
theta,
psi): {
x: number;
y: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:320
Parameters
Parameter | Type |
---|---|
cx | number |
cy | number |
rx | number |
ry | number |
theta | number |
psi | number |
Returns
{
x: number;
y: number;
}
getPointOnLine()
static getPointOnLine(
dist,
P1x,
P1y,
P2x,
P2y,
fromX?,
fromY?): {
x: number;
y: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:197
Parameters
Parameter | Type |
---|---|
dist | number |
P1x | number |
P1y | number |
P2x | number |
P2y | number |
fromX ? | number |
fromY ? | number |
Returns
{
x: number;
y: number;
}
getPointOnQuadraticBezier()
static getPointOnQuadraticBezier(
pct,
P1x,
P1y,
P2x,
P2y,
P3x,
P3y): {
x: number;
y: number;
}
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:293
Parameters
Parameter | Type |
---|---|
pct | number |
P1x | number |
P1y | number |
P2x | number |
P2y | number |
P3x | number |
P3y | number |
Returns
{
x: number;
y: number;
}
parsePathData()
static parsePathData(data): IPathDataArray[]
Defined in: packages/api/tmp/univer-pro/submodules/univer/packages/engine-render/src/shape/path.ts:341
Parameters
Parameter | Type |
---|---|
data | string |
Returns
IPathDataArray
[]