两种宽高比(4:3和16:9)的两种布局-自动更改 [英] Two layouts for two aspect ratios (4:3 and 16:9) - changing automatically

查看:231
本文介绍了两种宽高比(4:3和16:9)的两种布局-自动更改的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

按照 Microsoft规模指南,上面写着的部分:

Following the Microsoft scale guidelines there is a part where it says:

在设计固定布局时,请先为基线分辨率设计布局:1024x768和1366x768.

When designing a fixed layout, start by designing your layout for the baseline resolutions: 1024x768 and 1366x768.

对此,我有以下问题:

是否可以为两个长宽比定义两个固定的布局(两者都与ViewBox一起使用以按该长宽比缩放至每个分辨率),以便它们可以根据屏幕的长宽比自动更改?也许在填充模式和全屏模式之间切换,这也会改变长宽比?

Is it possible to define two fixed layouts for two aspect ratios (both to be used with the ViewBox to scale to every resolution in that aspect ratio) so they can change automatically depending on the screen's aspect ratio? And maybe change between the fill mode and full screen mode that also changes aspect ratios ?

推荐答案

LayoutAwarePage随附项目模板,该模板提供可视状态,可用于根据ApplicationView更改布局(填充,捕捉等).如果需要,可以扩展该外观覆盖InvalidateVisualState的行为.

Project Templates comes with LayoutAwarePage that provides visual states you can use to change layout according to ApplicationView (Filled, Snapped etc...) If needed you could extend that behavior there overriding InvalidateVisualState.

这篇关于两种宽高比(4:3和16:9)的两种布局-自动更改的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆