Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Skip to main content
useKeplerWindowDimensionsV2 returns the DisplayMetricsKepler entry for each surface that currently exists. DisplayMetricsKepler Type:
useKeplerWindowDimensionsV2 automatically updates values when the size of any surface changes. The following example shows how to get a surface window’s width and height:

Example

Properties

fontScale

The scale of the font currently used.

height

The height in pixels of the window or screen your app occupies.

scale

The pixel ratio of the device your app is running on. A value of 1 indicates PPI/DPI of 96 (76 on some platforms). 2 indicates a Retina or high DPI display.

width

The width in pixels of the window or screen your app occupies.

rootTag

The unique root tag for the surface that corresponds with this entry. Root tag also takes care of multiple instances of the same interactive component to be able to uniquely identify each instance.
Last modified on December 10, 2025