Reputation: 44862
Is there a way to set a layouts width to be the width of it's parent -20 dip? I'm dealing with a Tablerow
Upvotes: 0
Views: 411
Reputation: 60721
Set its left and right padding as needed.
<TableRow
android:paddingLeft="10dp"
android:paddingRight="10dp"
...
/>
Upvotes: 2
Reputation: 1474
Try giving TableRow
android:paddingRight="10dip" android:paddingLeft="10dip"
which makes it look like its width is 20dpi less than that of parent.
Upvotes: 2