pui.getDimensions( container )
This function returns the dimensions of a Rich Display File screen based on the elements occupying that screen. Â The function returns an object with the following properties:
x1 - the x-coordinate of the left-most element on the screen
y1 - the y-coordinate of the top-most element on the screen
x2 - the x-coordinate of the right-most part of the screen
y2 - the y-coordinate of the bottom-most part of the screen
Parameters:
container - a reference to the DOM object, which serves as the container for the elements on the screen; a special value pui.runtimeContainer can be used here to utilize the default container for a Rich Display File application
Example:
var dimensions = pui.getDimensions(pui.runtimeContainer);
var x1 = dimensions.x1;
var y1 = dimensions.y1;
var x2 = dimensions.x2;
var y2 = dimensions.y2;
var width = x2 - x1;
var height = y2 - y1;
Some documentation pages have recently moved to a new section: Profound AppDev. If you are having trouble finding specific pages, try the documentation search capability or reach out to our Support team!