Check documentation for the latest version 6.0 of dhtmlxSuite setViewport DHTMLX Docs

setViewport

sets a user-defined viewport

void setViewport(number x,number y,number width,number height,HTMLElement parentObj);

Parameters

xnumbertop-left viewport corner's X-coordinate
ynumbertop-left viewport corner's Y-coordinate
widthnumberviewport's width
heightnumberviewport's height
parentObjHTMLElementcreate inside of parentObj object

Example

myWins.setViewport(x, y, width, height, parentObj);

Details

Creates a new viewport with the specified position and dimensions. If parentObj is specified, attaches the viewport to it; otherwise, attaches the viewport to the document.body.

Back to top