简体   繁体   中英

Combine two portrait layouts in one landscape

I designed my application for phones mostly so all my layouts are portraits. However I think I can place my two portrait layouts standing side by side making one landscape layout for a tablet. Anyone has an idea how to make it simple? Generally I assume I can use table layout, however most samples going in row route, when I need columns one, so two columns should have equal width. Another wish if I could utilize simple include statement to include nested layouts instead of copying them, because if I decide to change one, then I need to replicate my changes in tablet layout which is generally bad practice of code duplication.

我建议您使用weightSum = 2和水平方向的LinearLayout,然后可以将include标签用于权重为1的肖像布局。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM