API Reference
@univerjs
@univerjs/engine-render
functions
Gettranslateinspreadcontextwithpixelratio

@univerjs/engine-render v0.4.2Docs


Function: getTranslateInSpreadContextWithPixelRatio()

function getTranslateInSpreadContextWithPixelRatio(): {
  left: offset;
  top: offset;
}

Align the resolution, an alignment needs to be done in special cases where the resolution is 1.5, 1.25, etc.

Returns

{
  left: offset;
  top: offset;
}

offset

NameTypeDefault valueDefined in
leftnumberoffsetsubmodules/univer/packages/engine-render/src/basics/draw.ts:408 (opens in a new tab)
topnumberoffsetsubmodules/univer/packages/engine-render/src/basics/draw.ts:409 (opens in a new tab)

Defined in

submodules/univer/packages/engine-render/src/basics/draw.ts:405 (opens in a new tab)


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