android - Show many radio buttons -


i have 7 radio buttons under 1 radio group. rendered them horizontally using orientation = "horizontal". 4 can visible @ time, rest not.

is there way show rest of them in second row while keeping these 'radiobuttons' in 1 'radiogroup`?

in case need code -

    <radiogroup             android:layout_width="match_parent"             android:layout_height="wrap_content"             android:orientation="horizontal">              <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="1 bhk" />              <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="1.5 bhk" />              <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="2 bhk" />              <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="2.5 bhk" />             <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="2 bhk" />              <radiobutton                 android:layout_width="wrap_content"                 android:layout_height="wrap_content"                 android:text="2.5 bhk" /> </radiogroup> 

you can't place radiobuttons @ different places on screen while keeping them in same radiogroup. can't keep them in different rows either (like want achieve). yes, hate too.

you can make checkboxes intead, place them way want, , use setoncheckedchangedlistener on each of them. if 1 of them checked, call setchecked(false) on others.

use custom drawable radio buttons , not checkboxes.


Popular posts from this blog