# Perspective: Dynamically resize window based on device (i.e tablet or phone)

**URL:** <https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177>\
**Category:** Ignition\
**Created:** [August 5, 2019, 8:41pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177 "2019-08-05T20:41:44Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![David.Bell](https://avatars.discourse-cdn.com/v4/letter/d/34f0e0/32.png) [@David.Bell](https://forum.inductiveautomation.com/u/David.Bell)\
**Post date:** [August 5, 2019, 8:41pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/1 "2019-08-05T20:41:45Z")

</div>

Hello, is it possible to determine screen width/height and dynamically adjust the view in Perspective?

Thanks,

David

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [August 5, 2019, 8:52pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/2 "2019-08-05T20:52:13Z")

</div>

No, you cannot get the dimensions of the page. IA are reluctant to let us have these due to the very likely chance of locking up the client with infinite loops.

You should be using all of the different container types to assist with making your pages change with client resolutions. Check out the university for how the different containers work.

---

<div class="post-metadata">

**Author:** ![PerryAJ](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/perryaj/32/3281_2.png) [@PerryAJ](https://forum.inductiveautomation.com/u/PerryAJ)\
**Post date:** [August 5, 2019, 9:05pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/3 "2019-08-05T21:05:08Z")

</div>

> [@David.Bell](#):
>
> Hello, is it possible to determine screen width/height and dynamically adjust the view in Perspective?

Definitely, but perhaps not as you might be thinking. As @nminchin stated, in Perspective you'll want to use _containers_ to accomplish _responsive behavior_ (which is what they generally call "user interface that changes or _responds_ to the available space").

Fortunately there are a number of ways to create responsive behavior, so you can create almost any UI you can imagine for almost any device you can imagine. Unfortunately, this flexibility comes with a bit of a learning curve. We've done a couple different [webinars on responsive design](https://www.inductiveautomation.com/resources/webinar/design-like-a-pro-basics-of-building-mobileresponsive-hmis) that might help you get familiar with responsive design in general, as well as some examples in Perspective.

---

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [August 5, 2019, 9:10pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/4 "2019-08-05T21:10:11Z")

</div>

You can upvote this post on the [ideas forum](https://ideas.inductiveautomation.com/ignition-features-and-ideas/p/expose-viewport-dimensions-in-perspective) if the functionality is important to you.

---

<div class="post-metadata">

**Author:** ![David.Bell](https://avatars.discourse-cdn.com/v4/letter/d/34f0e0/32.png) [@David.Bell](https://forum.inductiveautomation.com/u/David.Bell)\
**Post date:** [August 6, 2019, 3:55pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/5 "2019-08-06T15:55:44Z")

</div>

Thank you. Yes, I will do that. It is important to be able to easily switch from phone to tablet and vice versa. Thanks!

David

---

<div class="post-metadata">

**Author:** ![witman](https://avatars.discourse-cdn.com/v4/letter/w/d2c977/32.png) [@witman](https://forum.inductiveautomation.com/u/witman)\
**Post date:** [August 6, 2019, 4:51pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/6 "2019-08-06T16:51:30Z")

</div>

> [@David.Bell](#):
>
> It is important to be able to easily switch from phone to tablet

The [Perspective breakpoint container](https://docs.inductiveautomation.com/display/DOC80/Perspective+-+Breakpoint+Container?src=search) easily accomplishes this.

---

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [August 6, 2019, 5:17pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/7 "2019-08-06T17:17:48Z")

</div>

To be clear: providing insight into Viewport dimensions will in no way allow you to modify window size. As others have already posted, the responsive containers (Flex, Breakpoint, Column) are designed to allow you to adjust displays based on viewport dimensions without needing to “book-keep”.

Visibility into viewport dimensions is intended to allow for modifications like fontSize at small resolutions, or determining how many Carousel slides to display based on the current width.

---

<div class="post-metadata">

**Author:** ![David.Bell](https://avatars.discourse-cdn.com/v4/letter/d/34f0e0/32.png) [@David.Bell](https://forum.inductiveautomation.com/u/David.Bell)\
**Post date:** [August 7, 2019, 1:19pm UTC](https://forum.inductiveautomation.com/t/perspective-dynamically-resize-window-based-on-device-i-e-tablet-or-phone/27177/8 "2019-08-07T13:19:08Z")

</div>

Thanks. Hopefully this will be added in future updates.
