Android: How to make all elements inside LinearLayout same size?

后端 未结 3 1236
离开以前
离开以前 2020-11-27 02:27

I would like to create a dialog to display a video title and tags. Below text I would like to add buttons View, Edit and Delete and make these elements same size. Does anyon

3条回答
  •  余生分开走
    2020-11-27 03:20

    Use android:layout_width="0px" and android:layout_weight="1" on the three Buttons. That says the buttons should take up no more than 0 pixels, but the three of them should split any extra space between them. That should give you the visual effect you wish.

提交回复
热议问题