开发者

Wraping EditText Boxes in Layout

I have a UI that has 6 EditText boxes. 3 of those EditText boxes don't show up when in vertical orientation. I was hoping that wrap_content would wrap the non-showing 3 to the next line but found out that LinearLayout only allows for one row.

When in horizontal orientation I get all 6 of them showing.

I tried a TableView with two rows of 3 each. That looks dorky when in horizontal orientation.

Do I need code to determine when the orientation changes to redraw th开发者_运维百科ose EditText boxes so it looks better or is there some layout that will automatically wrap when in vertical orientation?


You can create a layout with the same name and put it in res/layout-land. It'll use that when in landscape mode.


u can determine the orientation by this this.getResources().getConfiguration().orientation

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜