0

I'm trying to create a layout that has a background (shown below) and have 10 check boxes (2 columns of 5 rows) in the white area. I can make this work via trial and error for one size view but how would i get this to keep the same aspect ratios for different screen sizes?

I'm open to any ideas, whether it's multiple layouts for different sizes or something more clever.

enter image description here

Goku
  • 1,565
  • 1
  • 29
  • 62

2 Answers2

1

As you want to build a table of checkboxes (and associated text labels, I assume), I would suggest you use TableLayout.

Sébastien
  • 13,831
  • 10
  • 55
  • 70
1

Basically wrap your check boxes with LinearLayout and don't give hard coded values for

android:layout_width=""

android:layout_height=""

If you can't, my answer will change. Also TableLayout another approach for your work.

hakki
  • 6,181
  • 6
  • 62
  • 106