How to disable auto-scaling on UWP mobile

别来无恙 提交于 2020-01-07 02:48:09

问题


I´m doing a Windows Universal app that will run only on Lumia 640XL devices. That device has a native resolution of 1280 x 720 and a pixel density of 259 ppi. There will be no desktop version so I just care about the mobile layout.

The design guide lines for my app are huge and full of pixel measures (sizes, margins, paddings, font sizes) everywhere, so what I´d like is to make the mobile app respect the physical pixels (rather than "effective pixels"), as the desktop version does.

How can I disable auto-scaling?

There is a link here saying how to disable scaling on Xbox:

bool result = Windows.UI.ViewManagement.ApplicationViewScaling.TrySetDisableLayoutScaling(true);

but that ApplicationViewScaling does not seam to be available on mobile:

The UAP version I´m using is 10.0.10586.0

来源:https://stackoverflow.com/questions/40020631/how-to-disable-auto-scaling-on-uwp-mobile

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!