API Reference
@univerjs
@univerjs/engine-render
classes
Border

@univerjs/engine-render v0.4.2Docs


Class: Border

Extends

Constructors

new Border()

new Border(): Border

Returns

Border

Inherited from

SheetExtension.constructor

Properties

PropertyTypeDefault valueOverridesInherited fromDefined in
Z_INDEXnumberBORDER_Z_INDEXSheetExtension.Z_INDEX-submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:45 (opens in a new tab)
extensionOffsetIExtensionConfig{}-SheetExtension.extensionOffsetsubmodules/univer/packages/engine-render/src/components/extension.ts:53 (opens in a new tab)
parentNullable<BaseObject>undefined-SheetExtension.parentsubmodules/univer/packages/engine-render/src/components/extension.ts:47 (opens in a new tab)
preColorstringundefined--submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:48 (opens in a new tab)
preStyleBorderStyleTypesundefined--submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:47 (opens in a new tab)
translateXnumber0-SheetExtension.translateXsubmodules/univer/packages/engine-render/src/components/extension.ts:49 (opens in a new tab)
translateYnumber0-SheetExtension.translateYsubmodules/univer/packages/engine-render/src/components/extension.ts:51 (opens in a new tab)
typeSHEET_EXTENSION_TYPESHEET_EXTENSION_TYPE.GRID-SheetExtension.typesubmodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:34 (opens in a new tab)
uKeystringUNIQUE_KEYSheetExtension.uKey-submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:43 (opens in a new tab)

Accessors

zIndex

get zIndex(): number

Returns

number

Inherited from

SheetExtension.zIndex

Defined in

submodules/univer/packages/engine-render/src/components/extension.ts:55 (opens in a new tab)

Methods

_getScale()

protected _getScale(parentScale): number

Parameters

ParameterType
parentScaleIScale

Returns

number

Inherited from

SheetExtension._getScale

Defined in

submodules/univer/packages/engine-render/src/components/extension.ts:67 (opens in a new tab)


clearCache()

clearCache(): void

Returns

void

Inherited from

SheetExtension.clearCache

Defined in

submodules/univer/packages/engine-render/src/components/extension.ts:63 (opens in a new tab)


dispose()

dispose(): void

Returns

void

Inherited from

SheetExtension.dispose

Defined in

submodules/univer/packages/engine-render/src/components/extension.ts:71 (opens in a new tab)


draw()

draw(
   ctx, 
   _parentScale, 
   spreadsheetSkeleton, 
   diffRanges, 
   __namedParameters): void

Parameters

ParameterType
ctxUniverRenderingContext
_parentScaleIScale
spreadsheetSkeletonSpreadsheetSkeleton
diffRangesIRange[]
__namedParametersIDrawInfo

Returns

void

Overrides

SheetExtension.draw

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:50 (opens in a new tab)


getCellByIndex()

getCellByIndex(
   rowIndex, 
   columnIndex, 
   rowHeightAccumulation, 
   columnWidthAccumulation, 
   dataMergeCache): ISelectionCellWithMergeInfo

Parameters

ParameterType
rowIndexnumber
columnIndexnumber
rowHeightAccumulationnumber[]
columnWidthAccumulationnumber[]
dataMergeCacheIRange[]

Returns

ISelectionCellWithMergeInfo

cell Position & mergeInfo

Deprecated

The function maybe cause performance issue, use spreadsheetSkeleton.getCellByIndexWithNoHeader instead. Get ISelectionCellWithMergeInfo by cell rowIndex and cell columnIndex. The startXY in return value does not include rowHeader and columnHeader.

Inherited from

SheetExtension.getCellByIndex

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:48 (opens in a new tab)


isRenderDiffRangesByCell()

isRenderDiffRangesByCell(rangeP, diffRanges?): boolean

Parameters

ParameterType
rangePIRange
diffRanges?IRange[]

Returns

boolean

Inherited from

SheetExtension.isRenderDiffRangesByCell

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:60 (opens in a new tab)


isRenderDiffRangesByColumn()

isRenderDiffRangesByColumn(
   curStartColumn, 
   curEndColumn, 
   diffRanges?): boolean

Parameters

ParameterType
curStartColumnnumber
curEndColumnnumber
diffRanges?IRange[]

Returns

boolean

Inherited from

SheetExtension.isRenderDiffRangesByColumn

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:97 (opens in a new tab)


isRenderDiffRangesByRow()

isRenderDiffRangesByRow(
   curStartRow, 
   curEndRow, 
   diffRanges?): boolean

Parameters

ParameterType
curStartRownumber
curEndRownumber
diffRanges?IRange[]

Returns

boolean

Inherited from

SheetExtension.isRenderDiffRangesByRow

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:130 (opens in a new tab)


isRowInRanges()

isRowInRanges(
   curStartRow, 
   curEndRow, 
   viewranges?): boolean

传入的 row 范围和 diffRanges 有相交, 返回 true

Parameters

ParameterType
curStartRownumber
curEndRownumber
viewranges?IRange[]

Returns

boolean

Inherited from

SheetExtension.isRowInRanges

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/sheet-extension.ts:169 (opens in a new tab)


renderBorderByCell()

renderBorderByCell(
   renderBorderContext, 
   row, 
   col, 
   borderCacheItem): undefined | true

Parameters

ParameterType
renderBorderContextIRenderBorderContext
rownumber
colnumber
borderCacheItemBorderCache

Returns

undefined | true

Defined in

submodules/univer/packages/engine-render/src/components/sheets/extensions/border.ts:97 (opens in a new tab)


Copyright © 2021-2024 DreamNum Co,Ltd. All Rights Reserved.