RadioGroup with two columns which have ten RadioButtons

后端 未结 12 1964
难免孤独
难免孤独 2020-11-27 07:16

I have a RadioGroup and I want to align buttons next to each other in two columns and five rows and I am unable to achieve it. Things I have tried:

12条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-11-27 07:36

    The RadioGroup is extended from LinearLayout.

    the linearlayout can not do it, so RadioGroup can not do it.

    Why not implement it self.

    Use RelativeLayout to layout the child view. And record the state of the child view. use setLevel to control the states.

    Good luck for you!.

提交回复
热议问题