getPosition

open suspend override fun getPosition(abs: Boolean): Position?

Retrieves the position of the element in the viewport.

This method calculates the position of the element based on its content quads. If abs is true, it returns the absolute position relative to the document.

Return

The position of the element, or null if it could not be determined.

Parameters

abs

If true, returns the absolute position; otherwise, returns the relative position.