![](/img/trans.png)
[英]FindViewById and multiple layouts for different screen densities (Android)
[英]Support-Screen Manifest with multiple layouts
我发现了这一点,但我不清楚的是; 当有许多带有片段的布局时,如何添加
/res/layout/layout.xml // Default layout
/res/layout-small/layout.xml // Small screens
/res/layout-large/layout.xml // Large screens
/res/layout-xlarge/layout.xml // Ex
/res/layout-small-land/layout.xml // Small screens, landscape view
/res/layout-small-portrait/layout.xml // Small screens, portrait view
使应用程序与任何屏幕尺寸兼容? 同样对于一个 UI,是否需要设计所需的屏幕尺寸 x6(布局、小、大、xlarge、small-land、small-portrait)倍的视图?
You can check this :
res/layout/main_activity.xml # For handsets
res/layout-land/main_activity.xml # For handsets in landscape
res/layout-sw600dp/main_activity.xml # For 7” tablets
res/layout-sw600dp-land/main_activity.xml # For 7” tablets in landscape
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.